Port Hufnagel font switching to production Verovio worker#1376
Open
zih-syuan wants to merge 22 commits into
Open
Port Hufnagel font switching to production Verovio worker#1376zih-syuan wants to merge 22 commits into
zih-syuan wants to merge 22 commits into
Conversation
diva.js#master no longer exists; pin to last known good commit. See #1365. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds assets/Hufnagel.zip for Verovio fontAddCustom integration. Font source files live in zih-syuan/hufnagel-font; this branch only tracks the packaged artifact. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds a Square/Hufnagel selector below Display Options. Clicking updates the label and logs to console; engine wiring (setFont / setNotationType) is the next step. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- VerovioWorker: add setFont handler (lazy-loads Hufnagel.zip as base64, calls toolkit.setOptions with full options) - NeonCore: add setNotationFont() — sends setFont to worker, clears lastPageLoaded to bypass cache on next render - NeonView: add setNotationType() — calls setNotationFont then re-renders - DisplayControls/DisplayPanel: thread neonView through setDisplayListeners → initDisplayControls → setNotationTypeControls so dropdown is wired - Interfaces/SingleView/DivaView: update setDisplayListeners signature Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…fallback Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
E99F is absent from Hufnagel.zip so Bravura fallback showed a square notation glyph. Generate a two-diamond icon via Verovio and use it as pngFallback for the distropha button in Hufnagel mode. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…back Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Verovio segfaults on staffDef notationtype="neume.hufnagel" (and "neume.square" is unverified) and doesn't render @con, so canonical Hufnagel connections (@con="e") and the real notationtype must never reach the Verovio worker directly. Add a temporary conversion shim in ConvertMei.ts (stripHufnagelForVerovio / restoreHufnagelForStorage) applied unconditionally at the two real boundaries - NeonCore.loadData() before anything reaches Verovio, and NeonCore.updateDatabase()/save()/ export() before anything is persisted or downloaded - so every load path (fresh fetch, cache hit, undo, redo) and every persistence path (save, export, download) stays consistent. See issues #1360, #1366. Co-Authored-By: Claude <noreply@anthropic.com>
Drop the hufnagel liquescent down primitive and the alternate F clef variant (fClefHufnagel) from the Insert panel, leaving one F clef button shared with square notation.
Nudge virga, virgaReversed, and custos icon offsets in the Insert panel so they align visually with the rest of the hufnagel primitives.
…handling - Upload modal now has a Notation Type choice, written into the MEI and synced to the Editing page dropdown. - Removed the auto con->ligated conversion before Verovio; it was corrupting real content. @con now passes through untouched. - Save no longer converts @ligated back to @con (only Download does), so a manually toggled connection survives a reload. Co-Authored-By: Claude <noreply@anthropic.com>
Member
|
Is this still using the Verovio version from RISM Digital with no modification? |
Author
|
Yes, this still uses the unmodified Verovio build from RISM Digital. This PR only changes how Neon configures the toolkit: for Hufnagel, it loads the custom font through Verovio's existing For |
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.
Related issues
Related to #1367 (font switching implemented; dropdown-freeze and switch-warning behavior still open for discussion, not closed by this PR)
Closes #1368
What this does
fetchHufnagelBase64,setFontcase) fromVerovioWorker-dev.jsto the production workerVerovioWorker.js, so the feature actually works once live on neon.simssa.ca.Testing
yarn cypress:test: all passing (44 passing, 6 pending — unrelated to this change)VerovioWorker.js(not the dev version) loads, and Hufnagel font renders correctly