Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Users can select a desktop CSS theme folder, keep Markra’s default folder, or import a Typora stylesheet and apply its basic appearance in Markra. Light and dark appearances have independent sources, and Refresh themes reloads external edits across open windows.
Closes #722
Changes
css-treeto adapt palette colors, installed fonts, heading sizes/weights/spacing, links, code fonts/backgrounds and common syntax colors into Markra's existing theme variables.!important, and custom-property inheritance/fallbacks. Detect variable cycles, including references inside unused fallbacks, and bound dependency traversal and substitution.--editor-code-font-familywhile retaining CodeMirror's row geometry safeguards. Handle missing files, stale reads, startup readiness and cross-window changes; constrain long filenames in settings.The English and Chinese READMEs and bundled theme guide explain folder selection, refresh, fallback behavior and Typora compatibility.
Validation
corepack pnpm test— 2,851 tests passed across 273 files.corepack pnpm typecheck:test— passed.corepack pnpm build— passed, including desktop and web builds and vendor-chunk verification.cargo fmt --manifest-path apps/desktop/src-tauri/Cargo.toml -- --check— passed.cargo test --manifest-path apps/desktop/src-tauri/Cargo.toml --lib— 294 tests passed.Compatibility boundaries
Typora support is a basic appearance adapter. Arbitrary layouts and spacing, pseudo-elements, interactive selectors, nested/conditional rules, cascade layers, font shorthands and complex heading sizes are skipped. Theme fonts/images and imported stylesheets are not loaded; installed or fallback fonts are used. This does not promise complete Typora visual parity.
Automatic file watching, theme-resource bundles and export-style parity remain outside this change. Desktop gets theme-folder access; web users can use the same adapter through settings CSS/import. HTML/PDF exports retain their own styles. CI covers Linux native tests and Windows compilation; local UI testing was on macOS.