Commit Graph

17 Commits

Author SHA1 Message Date
c0dev0id
e823608325 refactor: extract shortView into node-views.js 2026-07-06 21:10:28 +02:00
c0dev0id
66c1f2c151 Add delete buttons and bar add/create to sub-objects pane 2026-06-30 13:18:29 +02:00
c0dev0id
67c75781d8 Drop custom auth dialog; rely on browser Basic Auth handling
Remove ImportDialog and all manual credential management. The browser
handles 401 challenges natively for same-origin fetch requests — it
shows its own credential prompt, retries, and caches the result for
the session. No JS-level auth code is needed.

- api.js: remove authHeader() and all credentials parameters
- store.js: remove credentials field
- ImportDialog.js: deleted
- AppShell.js: remove showImport/openImport/onMounted dialog machinery;
  pass importOnLoad through to PaneCP
- PaneCP.js: inline doImport() (was in ImportDialog); auto-triggers on
  mount when importOnLoad is true; shows inline import error on failure
- StatusPoller.js: remove credentials arg from fetchStatus()
- style.css: remove .se-import-dialog and .se-overlay blocks
2026-06-30 09:32:44 +02:00
c0dev0id
86b14dfaa3 Article export + Bootstrap toggle + export change log
- patchScore() now accepts articles[] and returns { text, log } instead
  of a plain string. Dirty articles are re-serialized into the articles:
  block (block style, replacing any existing flow-style entries). Clean
  articles bypass the patcher entirely.
- article.isDirty is set on direct property edits so the exporter can
  distinguish directly changed entities from propagated dirty state.
- patchScore() log collects { level:'changed', path } for each patched
  article/instrument/bar, and a { level:'info', message } entry for the
  count of bar documents passed through unchanged.
- CP pane shows the export log above the status poller after each export.
- Article scope toggle replaced with Bootstrap form-check form-switch;
  hand-rolled .se-toggle CSS removed.
- Test suite updated for { text, log } return; 11 new assertions (188 total).
2026-06-30 06:27:12 +02:00
c0dev0id
5bec1a1d1e PaneCP article label + PaneFO editable property rows
Article entries in the CP path list now show the article label
(letter/extension) instead of just "article", with a property count
in the meta column. In the FO pane, each property is rendered as an
editable row: key input, value input (coerced via ast-parser.coerce),
scope toggle, morphing default/overwrite label, and per-row remove
button. A "+ add property" button appends a blank defaults entry.
Every edit marks the score dirty.

`coerce` is now exported from ast-parser.js so the FO pane can apply
the same type-inference rules to user input as the parser does to
AST values.
2026-06-29 08:17:57 +02:00
c0dev0id
b887341df4 Add motif/stem_note display and offset note hierarchy
- parseAstLog: abort on depth jump >1 or missing slot (depth>0)
- buildStemNote: full clause tree (notes/pauses/stacks), editable fields
- buildClause: replaces buildCluster; filters nested clause.chain silently
- buildMotif: builds from voice.motif; sets isStatic
- buildOffset: uses buildStemNote; drops old clusters/chains arrays
- buildVoice: motifs are now objects, not label strings
- PaneSubObjects: static motifs before offsets; motif/offset→stem_note drill-down
- PaneFO: motif + stem_note FO cases; unknownProps display helper
- PaneCP: motif + stem_note shortView cases
- test-parser.mjs: 21 new synthetic tests for motif/clause/stack/guards
2026-06-27 16:14:56 +02:00
c0dev0id
be338c2de0 Add audiowidget endpoint: Blueprint renders audiowidget.tmpl, PaneCP fetches it on synthesis completion 2026-06-24 18:52:26 +02:00
c0dev0id
c4804f0b55 Fix hardcoded API paths: inject URLs via url_for() in template, read from window.NEUSICIAN_URLS in api.js 2026-06-24 18:19:56 +02:00
c0dev0id
097d4488ef Export metadata edits (title, composer, source, encrypter) via patchScore 2026-06-24 17:52:25 +02:00
c0dev0id
1706404b7e Simplify: remove dead code and redundancy across vue app
- Delete ObjectBasic (defined, never imported)
- ObjectShort: remove unused node prop
- exporter: export stressorToString; use in patchBarMeta (removes inline duplicate)
- PaneFO: import stressorToString from exporter; extract H4 style constant,
  shapeSection() helper, instrOnChange() helper; remove apply param from
  makeChangeHandler (was always () => markDirty()); remove unnecessary ?.
  on always-initialized arrays (variations, labelSpecs, subvariations)
- PaneSubObjects: explicit hasChildren on all item kinds; bars at score
  level get hasChildren based on voices; remove stale kind-list fallback
- ast-parser coerce(): remove unreachable s.trim() check ('' handled above)
- PaneCP: fix post-export synthesisStatus reset to use real field names
2026-06-24 16:08:52 +02:00
c0dev0id
9eb4add695 Make bars navigable and editable with _meta export
Navigation:
- SubObjects: bar → voice (with chevron when offsets exist) → offsets
- PaneCP shortView handles voice and offset types

FO pane:
- Bar: editable beats_per_minute, stress_pattern (serialized as
  groups string), upper/lower stress bounds and tempo shape via
  ShapeEditor; sets bar.isDirty on change
- Voice: read-only name, articles, motifs, offset count
- Offset: read-only tick, stem notes and clusters as label strings
  (note re-serialization deferred)

Export:
- exporter.patchScore() now accepts optional bars[] parameter
- Splits rawScoreText by \n---\n; instruments patched in header,
  dirty bar _meta blocks regenerated, voice note lines kept verbatim
- ast-parser buildBar() adds isDirty:false
- PaneCP passes scoreModel.bars to patchScore
2026-06-24 13:25:23 +02:00
c0dev0id
338ea5be49 Fix result display: audio player, error message, correct field names
- Use file_accomplished (not frozen+!error) to gate audio player
- Use errors field (was .error — wrong name, always falsy)
- Render <audio controls> instead of bare download link
- Add audiowidget.tmpl.stub for server-side customization
2026-06-24 13:16:28 +02:00
c0dev0id
c52b0bf9cf Switch to FO pane on any label click in CP or SubObjects panes 2026-06-23 21:36:46 +02:00
c0dev0id
2060f109b6 Show numeric sub-variation edge values as bare numbers
Numeric dependsOn values (merge-type variations) are RFC edge values,
not ATTR names. Display them as the number, not as "ATTR: N" or
"subvariation N".
2026-06-23 18:49:17 +02:00
c0dev0id
06b2bab5d3 Redesign PaneCP as vertical focus-path menu; add score metadata to FO pane
PaneCP: replace horizontal breadcrumb with vertical list of short views
for each node in the focus path (type tag + label/identifier). Clicking
any item above current navigates up.

PaneFO: show score info fields (title, composer, source, encrypter) as
editable DL when at score level instead of 'Nothing selected'.
2026-06-23 18:45:13 +02:00
c0dev0id
4afabea837 Fix hidden panes: remove duplicate se-pane wrapper from PaneCP and PaneSubObjects
AppShell already wraps each component in div.se-pane; the inner se-pane
had display:none without .active, hiding all content.
Also drop stale movement/part/line/measure bar fields (bar IDs are opaque).
2026-06-23 17:35:29 +02:00
Florian "flowdy" Heß
822e2c9f42 Added files generated by Claude, prompted by sdk based on the md files 2026-06-21 19:23:54 +02:00