Commit Graph

15 Commits

Author SHA1 Message Date
c0dev0id
bf35441b77 refactor: functional style in exporter.js and subobject-kinds.js 2026-07-06 21:20:32 +02:00
c0dev0id
d3a55cb663 refactor: remove WHAT-comments, keep WHY and RFC references 2026-07-06 21:17:46 +02:00
c0dev0id
884955195a refactor: underscore-prefix all non-exported functions 2026-07-06 21:14:36 +02:00
c0dev0id
9a2e76ba4f refactor: extract coerce and stressorToString into util.js 2026-07-06 21:09:36 +02:00
c0dev0id
66c1f2c151 Add delete buttons and bar add/create to sub-objects pane 2026-06-30 13:18:29 +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
097d4488ef Export metadata edits (title, composer, source, encrypter) via patchScore 2026-06-24 17:52:25 +02:00
c0dev0id
89198ec37e Fix serializeModulation field names; add mod:base test assertion 2026-06-24 16:41:12 +02:00
c0dev0id
e4b5cf6887 Rename serializeFm to serializeModulation 2026-06-24 16:22:50 +02:00
c0dev0id
923aa5d41a Add AM modulation support to parser and exporter 2026-06-24 16:19:24 +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
f318b155cc Fix VOLUMES/TIMBRE/FM placement: variation properties, not instrument-level
Per RFC §3.2.1.3, VOLUMES, TIMBRE and FM are variation properties. The
previous exporter incorrectly appended them to the first ATTR variation;
they now go into a synthetic root variation (no ATTR) as required.
variationLines() handles these fields directly.

Fix test-parser.mjs fixture paths for standalone execution from repo root.
2026-06-22 19:30:45 +02:00
c0dev0id
c8b8d03e3f Apply RFC-compliant ast-parser and exporter
- ast-parser: railsbackCurve moved to variation level, FM shape child
  parsing, buildLabelSpec direct A/S/R handling, bar IDs as opaque strings
- exporter: RFC-compact shape format, correct instrument NAME: key,
  patchScore regex fixed, RAILSBACK_CURVE emitted from variationLines
- .gitignore: exclude test-parser.mjs pending author confirmation
2026-06-22 10:52:32 +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