Skip to content

Releases: zoharbabin/fen

v0.2.9

Choose a tag to compare

@github-actions github-actions released this 06 Jul 00:03

Fixed

  • Task-list checkboxes rendered on their own line, above the item text. cmark-gfm emits GFM task-list checkboxes as <li><input type="checkbox"> with no wrapping element, but tasklist.js looked for a .task-list-item class that never existed, so the checkbox-inline CSS rule never matched. The script now selects li > input[type="checkbox"] directly, and all 7 bundled theme stylesheets get a matching rule to keep the checkbox and its text on the same line.
  • [TOC] links pointed at anchors that didn't exist. MarkdownRenderer computed a slug for each heading to build the table of contents, but never wrote a matching id attribute onto the heading itself — so every generated link 404'd within the page. Headings now get deduplicated ids (GitHub-style -1, -2 suffixes for repeated titles) that the TOC links actually target.

Changed

  • Prism → highlight.js for code syntax highlighting. Prism's line-numbers plugin needed a separate script and CSS file per theme and lagged on language coverage; highlight.js covers more languages through one init script. The highlighting theme picker in Settings is now a proper Picker populated from the bundled themes, instead of a free-text field.

Testing

  • Added WKWebView-driven end-to-end coverage (GFMFeatureCoverageTests, PreviewThemeCoverageTests, BundleResolutionTests) asserting against real rendered DOM — heading ids/TOC links, checkbox layout, and highlight.js tokenization — across all 7 bundled themes, light and dark.

Full Changelog: v0.2.8...v0.2.9

v0.2.8

Choose a tag to compare

@github-actions github-actions released this 05 Jul 21:15

Fixed

  • Relative-path images never loaded in the live preview. DocumentGroup's FileDocumentConfiguration.fileURL was never bridged to MarkdownDocument.fileURL — and the property was internal, not public, so nothing outside FenCore could have set it even if it tried. The preview's base directory was always nil as a result, so any Markdown image (or other asset) referenced by relative path silently failed to render for every real document. Fixed on both macOS and iOS by bridging file.fileURL on appear and on change, and exposing MarkdownDocument.fileURL publicly.
  • Local SVGs rendered as a broken-image placeholder. The fen-preview:// scheme handler served every local asset with mimeType: nil, relying on WKWebView to sniff the content type from the byte stream. That works for PNG/JPEG/GIF/WebP, which have reliable magic-byte signatures, but SVG is plain XML text with none — so it never rendered. The handler now derives the MIME type from the file extension.
  • Help menu showed "Help isn't available for Fen." Replaced the non-functional default Help menu item with one that opens the README on GitHub.

Added

  • A custom About window (Fen → About Fen) replacing the generic system panel — matches the landing page branding and includes links to the website, source, issue tracker, release notes, and license, plus MacDown/Mou attribution.
  • assets/image-formats-test.md — a test fixture exercising the preview fixes above across PNG, JPEG, GIF, SVG, and WebP, as local files, remote HTTPS URLs, reference-style links, and a linked thumbnail.

Full Changelog: v0.2.7...v0.2.8

v0.2.7

Choose a tag to compare

@github-actions github-actions released this 05 Jul 19:56

Fixed

  • MathJax loaded from a CDN (cdnjs.cloudflare.com) at render time — every other script and style in Fen ships vendored inside the app, but MathJax was the one exception, adding a delay on first render, breaking the math-rendering feature offline, and making an unnecessary network call from an app whose trust model is local-first. MathJax is now vendored the same way as Mermaid: Shared/Resources/Extensions/mathjax-tex-svg.js bundles MathJax v3's tex-svg output (SVG glyphs, no separate web-font files), with attribution in LICENSE/mathjax.txt (Apache License 2.0). Fen now makes zero runtime network calls to render anything.
  • The inline-dollar math config ($...$ delimiters) is rewritten for MathJax v3's config API — the old MathJax.Hub.Config/tex2jax block was v2-only and incompatible with the vendored tex-svg.js bundle.

Added

  • A regression test (MathJax is vendored locally, not loaded from a CDN) asserts the composed preview/export HTML never contains a cdnjs.cloudflare.com reference, so this can't silently regress.
  • Mermaid diagrams in docs/ARCHITECTURE.md covering the FenCore/macOS/iOS target structure, the editor-to-preview rendering pipeline, coreBundle's resource-resolution flow, the fen-preview:// scheme handler's path-traversal guard, and the CI/release pipeline.

Changed

  • ARCHITECTURE.md, RELEASING.md, and ROADMAP.md moved into a new docs/ directory; every cross-reference across the repo (README, CONTRIBUTING, issue templates, workflow comments) updated accordingly.
  • README rewritten: logo and badges at the top, a hero screenshot, and the MacDown-origin attribution moved to the very bottom under "Origin and thanks."
  • Removed the "Start a discussion" link from the landing page (GitHub Discussions isn't enabled for this repo).
  • This repository is no longer a GitHub fork of mfbergmann/macdown-swift — detached via GitHub's fork-network settings.

Full Changelog: v0.2.6...v0.2.7

v0.2.6

Choose a tag to compare

@github-actions github-actions released this 04 Jul 17:25

Fixed

  • Scroll sync could stay half-broken on documents that exactly fill the
    viewport
    — the preview's scroll-fraction math divided by
    scrollHeight - clientHeight, which is 0 when there's no overflow to
    scroll yet. That produced NaN, which poisoned a duplicate-suppression
    check downstream and could stop scroll sync from engaging until you
    scrolled the preview manually once. Guarded with Math.max(1, ...) so it
    never divides by zero.

Added

  • Automated UI test coverage for scroll syncScrollSyncUITests
    drives the real app end-to-end (types a long document, scrolls one pane,
    asserts the other pane's exposed scroll position updates) covering both
    sync directions, so this class of regression gets caught before release.
  • The editor and preview panes now expose their live scroll position as an
    accessibility value/label, which both the new UI tests and assistive
    tech can read directly.

Full Changelog: v0.2.5...v0.2.6

v0.2.5

Choose a tag to compare

@github-actions github-actions released this 04 Jul 04:07

What's fixed

  • Editor/preview scroll sync — the two panes scrolled completely
    independently before; scrolling one now scrolls the other to match.
  • ⌘F now opens Find — Cmd+F previously did nothing. Find (⌘F), Find Next
    (⌘G), Find Previous (⇧⌘G), and Find and Replace (⌥⌘F) now drive the
    built-in AppKit find bar.

Also in this release

  • SwiftLint/SwiftFormat cleanup across the codebase, with the two tools'
    configs reconciled so they no longer disagree on trailing commas and
    multiline-statement brace placement.

Full Changelog: v0.2.4...v0.2.5

v0.2.4

Choose a tag to compare

@github-actions github-actions released this 28 Jun 18:04

Full Changelog: v0.2.3...v0.2.4

v0.2.3

Choose a tag to compare

@github-actions github-actions released this 28 Jun 17:57

Full Changelog: v0.2.2...v0.2.3

v0.2.2

Choose a tag to compare

@github-actions github-actions released this 28 Jun 04:59

Full Changelog: v0.2.1...v0.2.2

v0.2.1

Choose a tag to compare

@github-actions github-actions released this 28 Jun 04:35

Full Changelog: v0.2.0...v0.2.1

v0.2.0

Choose a tag to compare

@github-actions github-actions released this 28 Jun 04:27

Full Changelog: v0.1.0...v0.2.0