Skip to content

Copy markdown source, gradient icon, and renderer modularization - #21

Merged
sorenwacker merged 3 commits into
mainfrom
feature/copy-source-and-modularize
Jun 19, 2026
Merged

sorenwacker merged 3 commits into
mainfrom
feature/copy-source-and-modularize

Conversation

@sorenwacker

Copy link
Copy Markdown
Owner

Summary

  • Copy markdown source: a header button and Cmd/Ctrl+Shift+C copy the raw markdown of the active document to the clipboard (clipboard write routed through the main process).
  • Gradient app icon: the logo M now morphs through the three palette colors as one edge-to-edge gradient stroke instead of three solid segments.
  • Renderer modularization: renderer.js (was 1196 LOC) is split into ES modules under modules/ and loaded with type="module"; styles.css (was 1100 LOC) is split into css/ partials combined via @import. No source file now exceeds the 1000-line limit.
  • Review hardening: guarded recent-docs JSON.parse, reset the copy-button confirmation on tab switch, renamed the sidebar pane switcher (switchSidebarPane), and skipped the file-watch reparse when no window is open.

Commits

  1. morph the logo M through the palette as an edge-to-edge gradient
  2. split the stylesheet into concern files to stay within the 1000-line limit
  3. let users copy a document's markdown source and keep the renderer maintainable

Validation

  • ESLint clean (added a sourceType: module block for the renderer files).
  • 25/25 Playwright tests pass, including new cases for copy-to-clipboard, the copy-confirmation reset on tab switch, and the corrupt-recent-docs guard.
  • package.json build.files now bundles modules/**/*.js and css/**/*.css; verified they ship inside app.asar.
  • Findings and remediation recorded in docs/REVIEW.md.

…ntainable

Add a copy-source button and Cmd/Ctrl+Shift+C shortcut so the raw markdown of the active document can be copied.

Harden review findings: guard recent-docs JSON parsing, reset the copy-button confirmation on tab switch, rename the sidebar pane switcher, and skip the file-watch reparse when no window is open.

Split renderer.js into ES modules and load it with type=module so no source file exceeds the 1000-line limit.
@sorenwacker
sorenwacker merged commit 480009e into main Jun 19, 2026
4 checks passed
@sorenwacker
sorenwacker deleted the feature/copy-source-and-modularize branch June 19, 2026 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant