musicxml-io 0.3.6 → 0.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{index-DFwIbWZu.d.mts → index-BhQcAxLm.d.mts} +1 -1
- package/dist/{index-BWaC45uP.d.ts → index-DUXUhmaM.d.ts} +1 -1
- package/dist/index.d.mts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +20 -15
- package/dist/index.mjs +20 -15
- package/dist/operations/index.d.mts +2 -2
- package/dist/operations/index.d.ts +2 -2
- package/dist/query/index.d.mts +1 -1
- package/dist/query/index.d.ts +1 -1
- package/dist/{types-BFmNsRNw.d.mts → types-CgndcKdd.d.mts} +1 -0
- package/dist/{types-BFmNsRNw.d.ts → types-CgndcKdd.d.ts} +1 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { S as Score, M as Measure, n as TimeSignature, f as Part, P as Pitch, N as NoteEntry, K as KeySignature, C as Clef, ac as ArticulationType, m as DynamicsValue, ad as OrnamentType, i as NoteType } from './types-
|
|
1
|
+
import { S as Score, M as Measure, n as TimeSignature, f as Part, P as Pitch, N as NoteEntry, K as KeySignature, C as Clef, ac as ArticulationType, m as DynamicsValue, ad as OrnamentType, i as NoteType } from './types-CgndcKdd.mjs';
|
|
2
2
|
|
|
3
3
|
type ValidationErrorCode = 'MISSING_DIVISIONS' | 'INVALID_DIVISIONS' | 'MEASURE_DURATION_MISMATCH' | 'MEASURE_DURATION_OVERFLOW' | 'MEASURE_DURATION_UNDERFLOW' | 'VOICE_INCOMPLETE' | 'VOICE_GAP' | 'NEGATIVE_POSITION' | 'BACKUP_EXCEEDS_POSITION' | 'TIE_START_WITHOUT_STOP' | 'TIE_STOP_WITHOUT_START' | 'TIE_PITCH_MISMATCH' | 'BEAM_BEGIN_WITHOUT_END' | 'BEAM_END_WITHOUT_BEGIN' | 'SLUR_START_WITHOUT_STOP' | 'SLUR_STOP_WITHOUT_START' | 'TUPLET_START_WITHOUT_STOP' | 'TUPLET_STOP_WITHOUT_START' | 'PART_ID_NOT_IN_PART_LIST' | 'PART_LIST_ID_NOT_IN_PARTS' | 'PART_MEASURE_COUNT_MISMATCH' | 'PART_MEASURE_NUMBER_MISMATCH' | 'PART_GROUP_START_WITHOUT_STOP' | 'PART_GROUP_STOP_WITHOUT_START' | 'DUPLICATE_PART_ID' | 'INVALID_VOICE_NUMBER' | 'INVALID_STAFF_NUMBER' | 'STAFF_EXCEEDS_STAVES' | 'MISSING_STAVES_DECLARATION' | 'STAVES_DECLARATION_MISMATCH' | 'MISSING_CLEF_FOR_STAFF' | 'CLEF_STAFF_EXCEEDS_STAVES' | 'INVALID_DURATION' | 'EMPTY_MEASURE';
|
|
4
4
|
type ValidationLevel = 'error' | 'warning' | 'info';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { S as Score, M as Measure, n as TimeSignature, f as Part, P as Pitch, N as NoteEntry, K as KeySignature, C as Clef, ac as ArticulationType, m as DynamicsValue, ad as OrnamentType, i as NoteType } from './types-
|
|
1
|
+
import { S as Score, M as Measure, n as TimeSignature, f as Part, P as Pitch, N as NoteEntry, K as KeySignature, C as Clef, ac as ArticulationType, m as DynamicsValue, ad as OrnamentType, i as NoteType } from './types-CgndcKdd.js';
|
|
2
2
|
|
|
3
3
|
type ValidationErrorCode = 'MISSING_DIVISIONS' | 'INVALID_DIVISIONS' | 'MEASURE_DURATION_MISMATCH' | 'MEASURE_DURATION_OVERFLOW' | 'MEASURE_DURATION_UNDERFLOW' | 'VOICE_INCOMPLETE' | 'VOICE_GAP' | 'NEGATIVE_POSITION' | 'BACKUP_EXCEEDS_POSITION' | 'TIE_START_WITHOUT_STOP' | 'TIE_STOP_WITHOUT_START' | 'TIE_PITCH_MISMATCH' | 'BEAM_BEGIN_WITHOUT_END' | 'BEAM_END_WITHOUT_BEGIN' | 'SLUR_START_WITHOUT_STOP' | 'SLUR_STOP_WITHOUT_START' | 'TUPLET_START_WITHOUT_STOP' | 'TUPLET_STOP_WITHOUT_START' | 'PART_ID_NOT_IN_PART_LIST' | 'PART_LIST_ID_NOT_IN_PARTS' | 'PART_MEASURE_COUNT_MISMATCH' | 'PART_MEASURE_NUMBER_MISMATCH' | 'PART_GROUP_START_WITHOUT_STOP' | 'PART_GROUP_STOP_WITHOUT_START' | 'DUPLICATE_PART_ID' | 'INVALID_VOICE_NUMBER' | 'INVALID_STAFF_NUMBER' | 'STAFF_EXCEEDS_STAVES' | 'MISSING_STAVES_DECLARATION' | 'STAVES_DECLARATION_MISMATCH' | 'MISSING_CLEF_FOR_STAFF' | 'CLEF_STAFF_EXCEEDS_STAVES' | 'INVALID_DURATION' | 'EMPTY_MEASURE';
|
|
4
4
|
type ValidationLevel = 'error' | 'warning' | 'info';
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { S as Score, P as Pitch, M as Measure, D as DirectionType, a as DirectionEntry, N as NoteEntry, b as PartListEntry, c as PartInfo } from './types-
|
|
2
|
-
export { A as Accidental, j as AccidentalInfo, O as AdjacentNotes, a4 as AssembledLyrics, B as BackupEntry, p as Barline, a5 as BarlineWithContext, a0 as BeamGroup, k as BeamInfo, s as Chord, C as Clef, aa as ClefChangeInfo, w as Credit, v as Defaults, Q as DirectionKind, z as DirectionWithContext, R as DynamicWithContext, m as DynamicsValue, a7 as EndingInfo, E as EntryWithContext, F as ForwardEntry, a2 as HarmonyWithContext, a8 as KeyChangeInfo, K as KeySignature, L as Lyric, a3 as LyricWithContext, g as MeasureAttributes, h as MeasureEntry, l as Notation, a1 as NotationType, t as NoteIteratorItem, i as NoteType, y as NoteWithContext, r as NoteWithPosition, Y as OctaveShiftWithContext, f as Part, e as PartGroup, W as PedalWithContext, H as PositionQueryOptions, u as Print, a6 as RepeatInfo, d as ScoreMetadata, _ as SlurSpan, q as StaffGroup, G as StaffRange, ab as StructuralChanges, U as TempoWithContext, T as TieInfo, Z as TiedNoteGroup, a9 as TimeChangeInfo, n as TimeSignature, o as Transpose, $ as TupletGroup, I as VerticalSlice, V as VoiceGroup, J as VoiceLine, x as VoiceToStaffMap, X as WedgeWithContext } from './types-
|
|
3
|
-
import { V as ValidateOptions, a as ValidationResult } from './index-
|
|
4
|
-
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, cM as LocalValidateOptions, b0 as LowerAccidentalOptions, cL as MeasureValidationContext, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, cJ as ValidationErrorCode, cD as ValidationException, cK as ValidationLevel, cI as ValidationLocation, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, cG as assertMeasureValid, co as assertValid, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, cC as formatLocation, cF as getMeasureContext, P as insertClefChange, E as insertMeasure, i as insertNote, cn as isValid, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric, cm as validate, cr as validateBackupForward, ct as validateBeams, cp as validateDivisions, cq as validateMeasureDuration, cE as validateMeasureLocal, cw as validatePartReferences, cx as validatePartStructure, cu as validateSlurs, cB as validateSlursAcrossMeasures, cy as validateStaffStructure, cs as validateTies, cA as validateTiesAcrossMeasures, cv as validateTuplets, cz as validateVoiceStaff } from './index-
|
|
1
|
+
import { S as Score, P as Pitch, M as Measure, D as DirectionType, a as DirectionEntry, N as NoteEntry, b as PartListEntry, c as PartInfo } from './types-CgndcKdd.mjs';
|
|
2
|
+
export { A as Accidental, j as AccidentalInfo, O as AdjacentNotes, a4 as AssembledLyrics, B as BackupEntry, p as Barline, a5 as BarlineWithContext, a0 as BeamGroup, k as BeamInfo, s as Chord, C as Clef, aa as ClefChangeInfo, w as Credit, v as Defaults, Q as DirectionKind, z as DirectionWithContext, R as DynamicWithContext, m as DynamicsValue, a7 as EndingInfo, E as EntryWithContext, F as ForwardEntry, a2 as HarmonyWithContext, a8 as KeyChangeInfo, K as KeySignature, L as Lyric, a3 as LyricWithContext, g as MeasureAttributes, h as MeasureEntry, l as Notation, a1 as NotationType, t as NoteIteratorItem, i as NoteType, y as NoteWithContext, r as NoteWithPosition, Y as OctaveShiftWithContext, f as Part, e as PartGroup, W as PedalWithContext, H as PositionQueryOptions, u as Print, a6 as RepeatInfo, d as ScoreMetadata, _ as SlurSpan, q as StaffGroup, G as StaffRange, ab as StructuralChanges, U as TempoWithContext, T as TieInfo, Z as TiedNoteGroup, a9 as TimeChangeInfo, n as TimeSignature, o as Transpose, $ as TupletGroup, I as VerticalSlice, V as VoiceGroup, J as VoiceLine, x as VoiceToStaffMap, X as WedgeWithContext } from './types-CgndcKdd.mjs';
|
|
3
|
+
import { V as ValidateOptions, a as ValidationResult } from './index-BhQcAxLm.mjs';
|
|
4
|
+
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, cM as LocalValidateOptions, b0 as LowerAccidentalOptions, cL as MeasureValidationContext, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, cJ as ValidationErrorCode, cD as ValidationException, cK as ValidationLevel, cI as ValidationLocation, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, cG as assertMeasureValid, co as assertValid, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, cC as formatLocation, cF as getMeasureContext, P as insertClefChange, E as insertMeasure, i as insertNote, cn as isValid, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric, cm as validate, cr as validateBackupForward, ct as validateBeams, cp as validateDivisions, cq as validateMeasureDuration, cE as validateMeasureLocal, cw as validatePartReferences, cx as validatePartStructure, cu as validateSlurs, cB as validateSlursAcrossMeasures, cy as validateStaffStructure, cs as validateTies, cA as validateTiesAcrossMeasures, cv as validateTuplets, cz as validateVoiceStaff } from './index-BhQcAxLm.mjs';
|
|
5
5
|
export { FindNotesFilter, NormalizedPositionOptions, PitchRange, RoundtripMetrics, VoiceFilter, buildVoiceToStaffMap, buildVoiceToStaffMapForPart, countNotes, findBarlines, findDirectionsByType, findNotes, findNotesWithNotation, getAbsolutePosition, getAdjacentNotes, getAllNotes, getAttributesAtMeasure, getBeamGroups, getChordProgression, getChords, getClefChanges, getClefForStaff, getDirections, getDirectionsAtPosition, getDivisions, getDuration, getDynamics, getEffectiveStaff, getEndings, getEntriesAtPosition, getEntriesForStaff, getEntriesInRange, getHarmonies, getHarmonyAtPosition, getKeyChanges, getLyricText, getLyrics, getMeasure, getMeasureByIndex, getMeasureCount, getNextNote, getNormalizedDuration, getNormalizedPosition, getNotesAtPosition, getNotesForStaff, getNotesForVoice, getNotesInRange, getOctaveShifts, getPartById, getPartByIndex, getPartCount, getPartIds, getPartIndex, getPedalMarkings, getPrevNote, getRepeatStructure, getSlurSpans, getStaffRange, getStaveCount, getStaves, getStructuralChanges, getTempoMarkings, getTiedNoteGroups, getTimeChanges, getTupletGroups, getVerseCount, getVerticalSlice, getVoiceLine, getVoiceLineInRange, getVoices, getVoicesForStaff, getWedges, groupByStaff, groupByVoice, hasMultipleStaves, hasNotes, inferStaff, isRestMeasure, iterateEntries, iterateNotes, measureRoundtrip, scoresEqual, withAbsolutePositions } from './query/index.mjs';
|
|
6
6
|
|
|
7
7
|
declare function parse(xmlString: string): Score;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { S as Score, P as Pitch, M as Measure, D as DirectionType, a as DirectionEntry, N as NoteEntry, b as PartListEntry, c as PartInfo } from './types-
|
|
2
|
-
export { A as Accidental, j as AccidentalInfo, O as AdjacentNotes, a4 as AssembledLyrics, B as BackupEntry, p as Barline, a5 as BarlineWithContext, a0 as BeamGroup, k as BeamInfo, s as Chord, C as Clef, aa as ClefChangeInfo, w as Credit, v as Defaults, Q as DirectionKind, z as DirectionWithContext, R as DynamicWithContext, m as DynamicsValue, a7 as EndingInfo, E as EntryWithContext, F as ForwardEntry, a2 as HarmonyWithContext, a8 as KeyChangeInfo, K as KeySignature, L as Lyric, a3 as LyricWithContext, g as MeasureAttributes, h as MeasureEntry, l as Notation, a1 as NotationType, t as NoteIteratorItem, i as NoteType, y as NoteWithContext, r as NoteWithPosition, Y as OctaveShiftWithContext, f as Part, e as PartGroup, W as PedalWithContext, H as PositionQueryOptions, u as Print, a6 as RepeatInfo, d as ScoreMetadata, _ as SlurSpan, q as StaffGroup, G as StaffRange, ab as StructuralChanges, U as TempoWithContext, T as TieInfo, Z as TiedNoteGroup, a9 as TimeChangeInfo, n as TimeSignature, o as Transpose, $ as TupletGroup, I as VerticalSlice, V as VoiceGroup, J as VoiceLine, x as VoiceToStaffMap, X as WedgeWithContext } from './types-
|
|
3
|
-
import { V as ValidateOptions, a as ValidationResult } from './index-
|
|
4
|
-
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, cM as LocalValidateOptions, b0 as LowerAccidentalOptions, cL as MeasureValidationContext, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, cJ as ValidationErrorCode, cD as ValidationException, cK as ValidationLevel, cI as ValidationLocation, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, cG as assertMeasureValid, co as assertValid, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, cC as formatLocation, cF as getMeasureContext, P as insertClefChange, E as insertMeasure, i as insertNote, cn as isValid, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric, cm as validate, cr as validateBackupForward, ct as validateBeams, cp as validateDivisions, cq as validateMeasureDuration, cE as validateMeasureLocal, cw as validatePartReferences, cx as validatePartStructure, cu as validateSlurs, cB as validateSlursAcrossMeasures, cy as validateStaffStructure, cs as validateTies, cA as validateTiesAcrossMeasures, cv as validateTuplets, cz as validateVoiceStaff } from './index-
|
|
1
|
+
import { S as Score, P as Pitch, M as Measure, D as DirectionType, a as DirectionEntry, N as NoteEntry, b as PartListEntry, c as PartInfo } from './types-CgndcKdd.js';
|
|
2
|
+
export { A as Accidental, j as AccidentalInfo, O as AdjacentNotes, a4 as AssembledLyrics, B as BackupEntry, p as Barline, a5 as BarlineWithContext, a0 as BeamGroup, k as BeamInfo, s as Chord, C as Clef, aa as ClefChangeInfo, w as Credit, v as Defaults, Q as DirectionKind, z as DirectionWithContext, R as DynamicWithContext, m as DynamicsValue, a7 as EndingInfo, E as EntryWithContext, F as ForwardEntry, a2 as HarmonyWithContext, a8 as KeyChangeInfo, K as KeySignature, L as Lyric, a3 as LyricWithContext, g as MeasureAttributes, h as MeasureEntry, l as Notation, a1 as NotationType, t as NoteIteratorItem, i as NoteType, y as NoteWithContext, r as NoteWithPosition, Y as OctaveShiftWithContext, f as Part, e as PartGroup, W as PedalWithContext, H as PositionQueryOptions, u as Print, a6 as RepeatInfo, d as ScoreMetadata, _ as SlurSpan, q as StaffGroup, G as StaffRange, ab as StructuralChanges, U as TempoWithContext, T as TieInfo, Z as TiedNoteGroup, a9 as TimeChangeInfo, n as TimeSignature, o as Transpose, $ as TupletGroup, I as VerticalSlice, V as VoiceGroup, J as VoiceLine, x as VoiceToStaffMap, X as WedgeWithContext } from './types-CgndcKdd.js';
|
|
3
|
+
import { V as ValidateOptions, a as ValidationResult } from './index-DUXUhmaM.js';
|
|
4
|
+
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, cM as LocalValidateOptions, b0 as LowerAccidentalOptions, cL as MeasureValidationContext, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, cJ as ValidationErrorCode, cD as ValidationException, cK as ValidationLevel, cI as ValidationLocation, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, cG as assertMeasureValid, co as assertValid, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, cC as formatLocation, cF as getMeasureContext, P as insertClefChange, E as insertMeasure, i as insertNote, cn as isValid, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric, cm as validate, cr as validateBackupForward, ct as validateBeams, cp as validateDivisions, cq as validateMeasureDuration, cE as validateMeasureLocal, cw as validatePartReferences, cx as validatePartStructure, cu as validateSlurs, cB as validateSlursAcrossMeasures, cy as validateStaffStructure, cs as validateTies, cA as validateTiesAcrossMeasures, cv as validateTuplets, cz as validateVoiceStaff } from './index-DUXUhmaM.js';
|
|
5
5
|
export { FindNotesFilter, NormalizedPositionOptions, PitchRange, RoundtripMetrics, VoiceFilter, buildVoiceToStaffMap, buildVoiceToStaffMapForPart, countNotes, findBarlines, findDirectionsByType, findNotes, findNotesWithNotation, getAbsolutePosition, getAdjacentNotes, getAllNotes, getAttributesAtMeasure, getBeamGroups, getChordProgression, getChords, getClefChanges, getClefForStaff, getDirections, getDirectionsAtPosition, getDivisions, getDuration, getDynamics, getEffectiveStaff, getEndings, getEntriesAtPosition, getEntriesForStaff, getEntriesInRange, getHarmonies, getHarmonyAtPosition, getKeyChanges, getLyricText, getLyrics, getMeasure, getMeasureByIndex, getMeasureCount, getNextNote, getNormalizedDuration, getNormalizedPosition, getNotesAtPosition, getNotesForStaff, getNotesForVoice, getNotesInRange, getOctaveShifts, getPartById, getPartByIndex, getPartCount, getPartIds, getPartIndex, getPedalMarkings, getPrevNote, getRepeatStructure, getSlurSpans, getStaffRange, getStaveCount, getStaves, getStructuralChanges, getTempoMarkings, getTiedNoteGroups, getTimeChanges, getTupletGroups, getVerseCount, getVerticalSlice, getVoiceLine, getVoiceLineInRange, getVoices, getVoicesForStaff, getWedges, groupByStaff, groupByVoice, hasMultipleStaves, hasNotes, inferStaff, isRestMeasure, iterateEntries, iterateNotes, measureRoundtrip, scoresEqual, withAbsolutePositions } from './query/index.js';
|
|
6
6
|
|
|
7
7
|
declare function parse(xmlString: string): Score;
|
package/dist/index.js
CHANGED
|
@@ -220,7 +220,7 @@ var xmlParser = new (0, _fastxmlparser.XMLParser)({
|
|
|
220
220
|
textNodeName: "#text",
|
|
221
221
|
parseAttributeValue: false,
|
|
222
222
|
parseTagValue: false,
|
|
223
|
-
trimValues:
|
|
223
|
+
trimValues: false,
|
|
224
224
|
preserveOrder: true
|
|
225
225
|
});
|
|
226
226
|
function parse(xmlString) {
|
|
@@ -253,9 +253,12 @@ function findElement(elements, tagName) {
|
|
|
253
253
|
function getElementContent(elements, tagName) {
|
|
254
254
|
return findElement(elements, tagName);
|
|
255
255
|
}
|
|
256
|
-
function extractText(elements) {
|
|
256
|
+
function extractText(elements, preserveWhitespace = false) {
|
|
257
257
|
for (const item of elements) {
|
|
258
|
-
if (item["#text"] !== void 0)
|
|
258
|
+
if (item["#text"] !== void 0) {
|
|
259
|
+
const text = String(item["#text"]);
|
|
260
|
+
return preserveWhitespace ? text : text.trim();
|
|
261
|
+
}
|
|
259
262
|
}
|
|
260
263
|
return "";
|
|
261
264
|
}
|
|
@@ -565,7 +568,7 @@ function parseCredits(elements) {
|
|
|
565
568
|
if (attrs["page"]) credit.page = parseInt(attrs["page"], 10);
|
|
566
569
|
const types = collectElements(content, "credit-type", (c) => extractText(c));
|
|
567
570
|
const words = collectElements(content, "credit-words", (c, a) => {
|
|
568
|
-
const cw = { text: extractText(c) };
|
|
571
|
+
const cw = { text: extractText(c, true) };
|
|
569
572
|
if (a["default-x"]) cw.defaultX = parseFloat(a["default-x"]);
|
|
570
573
|
if (a["default-y"]) cw.defaultY = parseFloat(a["default-y"]);
|
|
571
574
|
if (a["font-family"]) cw.fontFamily = a["font-family"];
|
|
@@ -1596,7 +1599,7 @@ function parseNotations(elements, notationsIndex = 0) {
|
|
|
1596
1599
|
let text;
|
|
1597
1600
|
for (const item of glissContent) {
|
|
1598
1601
|
if (item["#text"] !== void 0) {
|
|
1599
|
-
text = String(item["#text"]);
|
|
1602
|
+
text = String(item["#text"]).trim();
|
|
1600
1603
|
break;
|
|
1601
1604
|
}
|
|
1602
1605
|
}
|
|
@@ -1634,7 +1637,7 @@ function parseLyric(elements, attrs) {
|
|
|
1634
1637
|
const content = el["syllabic"];
|
|
1635
1638
|
for (const item of content) {
|
|
1636
1639
|
if (item["#text"] !== void 0) {
|
|
1637
|
-
const syl = String(item["#text"]);
|
|
1640
|
+
const syl = String(item["#text"]).trim();
|
|
1638
1641
|
if (syl === "single" || syl === "begin" || syl === "middle" || syl === "end") {
|
|
1639
1642
|
currentSyllabic = syl;
|
|
1640
1643
|
}
|
|
@@ -1882,7 +1885,7 @@ function parseDirectionTypes(elements) {
|
|
|
1882
1885
|
const buContent = met["beat-unit"];
|
|
1883
1886
|
for (const item of buContent) {
|
|
1884
1887
|
if (item["#text"] !== void 0) {
|
|
1885
|
-
beatUnits.push(String(item["#text"]));
|
|
1888
|
+
beatUnits.push(String(item["#text"]).trim());
|
|
1886
1889
|
dotForPrev = true;
|
|
1887
1890
|
break;
|
|
1888
1891
|
}
|
|
@@ -1905,6 +1908,7 @@ function parseDirectionTypes(elements) {
|
|
|
1905
1908
|
if (beatUnitDots[1]) result.beatUnitDot2 = true;
|
|
1906
1909
|
}
|
|
1907
1910
|
if (metAttrs["parentheses"] === "yes") result.parentheses = true;
|
|
1911
|
+
if (metAttrs["print-object"] === "no") result.printObject = false;
|
|
1908
1912
|
if (metAttrs["default-y"]) result.defaultY = parseFloat(metAttrs["default-y"]);
|
|
1909
1913
|
if (metAttrs["font-family"]) result.fontFamily = metAttrs["font-family"];
|
|
1910
1914
|
if (metAttrs["font-size"]) result.fontSize = metAttrs["font-size"];
|
|
@@ -1914,7 +1918,7 @@ function parseDirectionTypes(elements) {
|
|
|
1914
1918
|
}
|
|
1915
1919
|
if (el["words"]) {
|
|
1916
1920
|
const a = getAttributes(el);
|
|
1917
|
-
const text = extractText(el["words"]);
|
|
1921
|
+
const text = extractText(el["words"], true);
|
|
1918
1922
|
const result = { kind: "words", text: text || "" };
|
|
1919
1923
|
if (a["default-x"]) result.defaultX = parseFloat(a["default-x"]);
|
|
1920
1924
|
if (a["default-y"]) result.defaultY = parseFloat(a["default-y"]);
|
|
@@ -2002,7 +2006,7 @@ function parseDirectionTypes(elements) {
|
|
|
2002
2006
|
const otherContent = el["other-direction"];
|
|
2003
2007
|
for (const o of otherContent) {
|
|
2004
2008
|
if (o["#text"] !== void 0) {
|
|
2005
|
-
const result = { kind: "other-direction", text: String(o["#text"]) };
|
|
2009
|
+
const result = { kind: "other-direction", text: String(o["#text"]).trim() };
|
|
2006
2010
|
if (otherAttrs["default-x"]) result.defaultX = parseFloat(otherAttrs["default-x"]);
|
|
2007
2011
|
if (otherAttrs["default-y"]) result.defaultY = parseFloat(otherAttrs["default-y"]);
|
|
2008
2012
|
if (otherAttrs["halign"]) result.halign = otherAttrs["halign"];
|
|
@@ -2134,8 +2138,8 @@ function parseDirectionTypes(elements) {
|
|
|
2134
2138
|
} else if (sw["swing-type"]) {
|
|
2135
2139
|
const stContent = sw["swing-type"];
|
|
2136
2140
|
for (const item of stContent) {
|
|
2137
|
-
if (item["#text"] !== void 0 && isValidNoteType(String(item["#text"]))) {
|
|
2138
|
-
result.swingType = String(item["#text"]);
|
|
2141
|
+
if (item["#text"] !== void 0 && isValidNoteType(String(item["#text"]).trim())) {
|
|
2142
|
+
result.swingType = String(item["#text"]).trim();
|
|
2139
2143
|
break;
|
|
2140
2144
|
}
|
|
2141
2145
|
}
|
|
@@ -2406,7 +2410,7 @@ function parseHarmony(elements, attrs) {
|
|
|
2406
2410
|
const kindContent = el["kind"];
|
|
2407
2411
|
for (const item of kindContent) {
|
|
2408
2412
|
if (item["#text"] !== void 0) {
|
|
2409
|
-
harmony.kind = String(item["#text"]);
|
|
2413
|
+
harmony.kind = String(item["#text"]).trim();
|
|
2410
2414
|
break;
|
|
2411
2415
|
}
|
|
2412
2416
|
}
|
|
@@ -2529,7 +2533,7 @@ function parseFiguredBass(elements, attrs) {
|
|
|
2529
2533
|
const prefixContent = figEl["prefix"];
|
|
2530
2534
|
for (const item of prefixContent) {
|
|
2531
2535
|
if (item["#text"] !== void 0) {
|
|
2532
|
-
figure.prefix = String(item["#text"]);
|
|
2536
|
+
figure.prefix = String(item["#text"]).trim();
|
|
2533
2537
|
break;
|
|
2534
2538
|
}
|
|
2535
2539
|
}
|
|
@@ -2537,7 +2541,7 @@ function parseFiguredBass(elements, attrs) {
|
|
|
2537
2541
|
const suffixContent = figEl["suffix"];
|
|
2538
2542
|
for (const item of suffixContent) {
|
|
2539
2543
|
if (item["#text"] !== void 0) {
|
|
2540
|
-
figure.suffix = String(item["#text"]);
|
|
2544
|
+
figure.suffix = String(item["#text"]).trim();
|
|
2541
2545
|
break;
|
|
2542
2546
|
}
|
|
2543
2547
|
}
|
|
@@ -2600,7 +2604,7 @@ function parseSound(elements, attrs) {
|
|
|
2600
2604
|
const typeContent = swingEl["swing-type"];
|
|
2601
2605
|
for (const item of typeContent) {
|
|
2602
2606
|
if (item["#text"] !== void 0) {
|
|
2603
|
-
swing.swingType = String(item["#text"]);
|
|
2607
|
+
swing.swingType = String(item["#text"]).trim();
|
|
2604
2608
|
break;
|
|
2605
2609
|
}
|
|
2606
2610
|
}
|
|
@@ -5760,6 +5764,7 @@ function serializeDirectionType(dirType, indent) {
|
|
|
5760
5764
|
}
|
|
5761
5765
|
case "metronome": {
|
|
5762
5766
|
let metAttrs = "";
|
|
5767
|
+
if (dirType.printObject === false) metAttrs += ' print-object="no"';
|
|
5763
5768
|
if (dirType.parentheses) metAttrs += ' parentheses="yes"';
|
|
5764
5769
|
if (dirType.defaultY !== void 0) metAttrs += ` default-y="${dirType.defaultY}"`;
|
|
5765
5770
|
if (dirType.fontFamily) metAttrs += ` font-family="${escapeXml(dirType.fontFamily)}"`;
|
package/dist/index.mjs
CHANGED
|
@@ -220,7 +220,7 @@ var xmlParser = new XMLParser({
|
|
|
220
220
|
textNodeName: "#text",
|
|
221
221
|
parseAttributeValue: false,
|
|
222
222
|
parseTagValue: false,
|
|
223
|
-
trimValues:
|
|
223
|
+
trimValues: false,
|
|
224
224
|
preserveOrder: true
|
|
225
225
|
});
|
|
226
226
|
function parse(xmlString) {
|
|
@@ -253,9 +253,12 @@ function findElement(elements, tagName) {
|
|
|
253
253
|
function getElementContent(elements, tagName) {
|
|
254
254
|
return findElement(elements, tagName);
|
|
255
255
|
}
|
|
256
|
-
function extractText(elements) {
|
|
256
|
+
function extractText(elements, preserveWhitespace = false) {
|
|
257
257
|
for (const item of elements) {
|
|
258
|
-
if (item["#text"] !== void 0)
|
|
258
|
+
if (item["#text"] !== void 0) {
|
|
259
|
+
const text = String(item["#text"]);
|
|
260
|
+
return preserveWhitespace ? text : text.trim();
|
|
261
|
+
}
|
|
259
262
|
}
|
|
260
263
|
return "";
|
|
261
264
|
}
|
|
@@ -565,7 +568,7 @@ function parseCredits(elements) {
|
|
|
565
568
|
if (attrs["page"]) credit.page = parseInt(attrs["page"], 10);
|
|
566
569
|
const types = collectElements(content, "credit-type", (c) => extractText(c));
|
|
567
570
|
const words = collectElements(content, "credit-words", (c, a) => {
|
|
568
|
-
const cw = { text: extractText(c) };
|
|
571
|
+
const cw = { text: extractText(c, true) };
|
|
569
572
|
if (a["default-x"]) cw.defaultX = parseFloat(a["default-x"]);
|
|
570
573
|
if (a["default-y"]) cw.defaultY = parseFloat(a["default-y"]);
|
|
571
574
|
if (a["font-family"]) cw.fontFamily = a["font-family"];
|
|
@@ -1596,7 +1599,7 @@ function parseNotations(elements, notationsIndex = 0) {
|
|
|
1596
1599
|
let text;
|
|
1597
1600
|
for (const item of glissContent) {
|
|
1598
1601
|
if (item["#text"] !== void 0) {
|
|
1599
|
-
text = String(item["#text"]);
|
|
1602
|
+
text = String(item["#text"]).trim();
|
|
1600
1603
|
break;
|
|
1601
1604
|
}
|
|
1602
1605
|
}
|
|
@@ -1634,7 +1637,7 @@ function parseLyric(elements, attrs) {
|
|
|
1634
1637
|
const content = el["syllabic"];
|
|
1635
1638
|
for (const item of content) {
|
|
1636
1639
|
if (item["#text"] !== void 0) {
|
|
1637
|
-
const syl = String(item["#text"]);
|
|
1640
|
+
const syl = String(item["#text"]).trim();
|
|
1638
1641
|
if (syl === "single" || syl === "begin" || syl === "middle" || syl === "end") {
|
|
1639
1642
|
currentSyllabic = syl;
|
|
1640
1643
|
}
|
|
@@ -1882,7 +1885,7 @@ function parseDirectionTypes(elements) {
|
|
|
1882
1885
|
const buContent = met["beat-unit"];
|
|
1883
1886
|
for (const item of buContent) {
|
|
1884
1887
|
if (item["#text"] !== void 0) {
|
|
1885
|
-
beatUnits.push(String(item["#text"]));
|
|
1888
|
+
beatUnits.push(String(item["#text"]).trim());
|
|
1886
1889
|
dotForPrev = true;
|
|
1887
1890
|
break;
|
|
1888
1891
|
}
|
|
@@ -1905,6 +1908,7 @@ function parseDirectionTypes(elements) {
|
|
|
1905
1908
|
if (beatUnitDots[1]) result.beatUnitDot2 = true;
|
|
1906
1909
|
}
|
|
1907
1910
|
if (metAttrs["parentheses"] === "yes") result.parentheses = true;
|
|
1911
|
+
if (metAttrs["print-object"] === "no") result.printObject = false;
|
|
1908
1912
|
if (metAttrs["default-y"]) result.defaultY = parseFloat(metAttrs["default-y"]);
|
|
1909
1913
|
if (metAttrs["font-family"]) result.fontFamily = metAttrs["font-family"];
|
|
1910
1914
|
if (metAttrs["font-size"]) result.fontSize = metAttrs["font-size"];
|
|
@@ -1914,7 +1918,7 @@ function parseDirectionTypes(elements) {
|
|
|
1914
1918
|
}
|
|
1915
1919
|
if (el["words"]) {
|
|
1916
1920
|
const a = getAttributes(el);
|
|
1917
|
-
const text = extractText(el["words"]);
|
|
1921
|
+
const text = extractText(el["words"], true);
|
|
1918
1922
|
const result = { kind: "words", text: text || "" };
|
|
1919
1923
|
if (a["default-x"]) result.defaultX = parseFloat(a["default-x"]);
|
|
1920
1924
|
if (a["default-y"]) result.defaultY = parseFloat(a["default-y"]);
|
|
@@ -2002,7 +2006,7 @@ function parseDirectionTypes(elements) {
|
|
|
2002
2006
|
const otherContent = el["other-direction"];
|
|
2003
2007
|
for (const o of otherContent) {
|
|
2004
2008
|
if (o["#text"] !== void 0) {
|
|
2005
|
-
const result = { kind: "other-direction", text: String(o["#text"]) };
|
|
2009
|
+
const result = { kind: "other-direction", text: String(o["#text"]).trim() };
|
|
2006
2010
|
if (otherAttrs["default-x"]) result.defaultX = parseFloat(otherAttrs["default-x"]);
|
|
2007
2011
|
if (otherAttrs["default-y"]) result.defaultY = parseFloat(otherAttrs["default-y"]);
|
|
2008
2012
|
if (otherAttrs["halign"]) result.halign = otherAttrs["halign"];
|
|
@@ -2134,8 +2138,8 @@ function parseDirectionTypes(elements) {
|
|
|
2134
2138
|
} else if (sw["swing-type"]) {
|
|
2135
2139
|
const stContent = sw["swing-type"];
|
|
2136
2140
|
for (const item of stContent) {
|
|
2137
|
-
if (item["#text"] !== void 0 && isValidNoteType(String(item["#text"]))) {
|
|
2138
|
-
result.swingType = String(item["#text"]);
|
|
2141
|
+
if (item["#text"] !== void 0 && isValidNoteType(String(item["#text"]).trim())) {
|
|
2142
|
+
result.swingType = String(item["#text"]).trim();
|
|
2139
2143
|
break;
|
|
2140
2144
|
}
|
|
2141
2145
|
}
|
|
@@ -2406,7 +2410,7 @@ function parseHarmony(elements, attrs) {
|
|
|
2406
2410
|
const kindContent = el["kind"];
|
|
2407
2411
|
for (const item of kindContent) {
|
|
2408
2412
|
if (item["#text"] !== void 0) {
|
|
2409
|
-
harmony.kind = String(item["#text"]);
|
|
2413
|
+
harmony.kind = String(item["#text"]).trim();
|
|
2410
2414
|
break;
|
|
2411
2415
|
}
|
|
2412
2416
|
}
|
|
@@ -2529,7 +2533,7 @@ function parseFiguredBass(elements, attrs) {
|
|
|
2529
2533
|
const prefixContent = figEl["prefix"];
|
|
2530
2534
|
for (const item of prefixContent) {
|
|
2531
2535
|
if (item["#text"] !== void 0) {
|
|
2532
|
-
figure.prefix = String(item["#text"]);
|
|
2536
|
+
figure.prefix = String(item["#text"]).trim();
|
|
2533
2537
|
break;
|
|
2534
2538
|
}
|
|
2535
2539
|
}
|
|
@@ -2537,7 +2541,7 @@ function parseFiguredBass(elements, attrs) {
|
|
|
2537
2541
|
const suffixContent = figEl["suffix"];
|
|
2538
2542
|
for (const item of suffixContent) {
|
|
2539
2543
|
if (item["#text"] !== void 0) {
|
|
2540
|
-
figure.suffix = String(item["#text"]);
|
|
2544
|
+
figure.suffix = String(item["#text"]).trim();
|
|
2541
2545
|
break;
|
|
2542
2546
|
}
|
|
2543
2547
|
}
|
|
@@ -2600,7 +2604,7 @@ function parseSound(elements, attrs) {
|
|
|
2600
2604
|
const typeContent = swingEl["swing-type"];
|
|
2601
2605
|
for (const item of typeContent) {
|
|
2602
2606
|
if (item["#text"] !== void 0) {
|
|
2603
|
-
swing.swingType = String(item["#text"]);
|
|
2607
|
+
swing.swingType = String(item["#text"]).trim();
|
|
2604
2608
|
break;
|
|
2605
2609
|
}
|
|
2606
2610
|
}
|
|
@@ -5760,6 +5764,7 @@ function serializeDirectionType(dirType, indent) {
|
|
|
5760
5764
|
}
|
|
5761
5765
|
case "metronome": {
|
|
5762
5766
|
let metAttrs = "";
|
|
5767
|
+
if (dirType.printObject === false) metAttrs += ' print-object="no"';
|
|
5763
5768
|
if (dirType.parentheses) metAttrs += ' parentheses="yes"';
|
|
5764
5769
|
if (dirType.defaultY !== void 0) metAttrs += ` default-y="${dirType.defaultY}"`;
|
|
5765
5770
|
if (dirType.fontFamily) metAttrs += ` font-family="${escapeXml(dirType.fontFamily)}"`;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import '../types-
|
|
2
|
-
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, b0 as LowerAccidentalOptions, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, P as insertClefChange, E as insertMeasure, i as insertNote, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric } from '../index-
|
|
1
|
+
import '../types-CgndcKdd.mjs';
|
|
2
|
+
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, b0 as LowerAccidentalOptions, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, P as insertClefChange, E as insertMeasure, i as insertNote, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric } from '../index-BhQcAxLm.mjs';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import '../types-
|
|
2
|
-
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, b0 as LowerAccidentalOptions, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, P as insertClefChange, E as insertMeasure, i as insertNote, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric } from '../index-
|
|
1
|
+
import '../types-CgndcKdd.js';
|
|
2
|
+
export { ba as AddArticulationOptions, bj as AddBeamOptions, c8 as AddBowingOptions, ch as AddBreathMarkOptions, ck as AddCaesuraOptions, aW as AddChordOptions, c2 as AddChordSymbolOptions, bS as AddCodaOptions, bc as AddDynamicsOptions, bM as AddEndingOptions, bz as AddFermataOptions, c5 as AddFingeringOptions, bU as AddGraceNoteOptions, b$ as AddHarmonyOptions, bX as AddLyricOptions, bT as AddNavigationOptions, cd as AddOctaveShiftOptions, bB as AddOrnamentOptions, b2 as AddPartOptions, bD as AddPedalOptions, bH as AddRehearsalMarkOptions, bI as AddRepeatBarlineOptions, bK as AddRepeatOptions, bR as AddSegnoOptions, b8 as AddSlurOptions, ca as AddStringNumberOptions, bu as AddTempoOptions, bF as AddTextDirectionOptions, bG as AddTextOptions, b6 as AddTieOptions, b1 as AddVoiceOptions, bx as AddWedgeOptions, bl as AutoBeamOptions, bQ as BarStyle, c7 as BowingType, cg as BreathMarkValue, cj as CaesuraValue, bO as ChangeBarlineOptions, bg as ChangeClefOptions, aX as ChangeNoteDurationOptions, bW as ConvertToGraceOptions, br as CopyNotesMultiMeasureOptions, bo as CopyNotesOptions, bh as CreateTupletOptions, bq as CutNotesOptions, b3 as DuplicatePartOptions, b_ as HarmonyKind, bf as InsertClefChangeOptions, aU as InsertNoteOptions, b0 as LowerAccidentalOptions, be as ModifyDynamicsOptions, bw as ModifyTempoOptions, b5 as MoveNoteToStaffOptions, bs as MultiMeasureSelection, bn as NoteSelection, cc as OctaveShiftType, aT as OperationErrorCode, aS as OperationResult, bt as PasteNotesMultiMeasureOptions, bp as PasteNotesOptions, a$ as RaiseAccidentalOptions, bb as RemoveArticulationOptions, bk as RemoveBeamOptions, c9 as RemoveBowingOptions, ci as RemoveBreathMarkOptions, cl as RemoveCaesuraOptions, c3 as RemoveChordSymbolOptions, bd as RemoveDynamicsOptions, bN as RemoveEndingOptions, bA as RemoveFermataOptions, c6 as RemoveFingeringOptions, bV as RemoveGraceNoteOptions, c0 as RemoveHarmonyOptions, bY as RemoveLyricOptions, aV as RemoveNoteOptions, cf as RemoveOctaveShiftOptions, bC as RemoveOrnamentOptions, bE as RemovePedalOptions, bJ as RemoveRepeatBarlineOptions, bL as RemoveRepeatOptions, b9 as RemoveSlurOptions, cb as RemoveStringNumberOptions, bv as RemoveTempoOptions, b7 as RemoveTieOptions, bi as RemoveTupletOptions, by as RemoveWedgeOptions, bP as SetBarlineOptions, bm as SetBeamingOptions, aZ as SetNotePitchBySemitoneOptions, aY as SetNotePitchOptions, b4 as SetStavesOptions, a_ as ShiftNotePitchOptions, ce as StopOctaveShiftOptions, c4 as UpdateChordSymbolOptions, c1 as UpdateHarmonyOptions, bZ as UpdateLyricOptions, cH as ValidationError, K as addArticulation, T as addBeam, aH as addBowing, aO as addBreathMark, aQ as addCaesura, b as addChord, j as addChordNote, p as addChordNoteChecked, aC as addChordSymbol, ao as addCoda, ap as addDaCapo, aq as addDalSegno, M as addDynamics, aj as addEnding, a6 as addFermata, ar as addFine, aF as addFingering, at as addGraceNote, az as addHarmony, aw as addLyric, g as addNote, n as addNoteChecked, aL as addOctaveShift, a8 as addOrnament, x as addPart, aa as addPedal, ae as addRehearsalMark, ah as addRepeat, af as addRepeatBarline, an as addSegno, I as addSlur, aJ as addStringNumber, a1 as addTempo, ad as addText, ac as addTextDirection, G as addTie, as as addToCoda, w as addVoice, a4 as addWedge, W as autoBeam, al as changeBarline, Q as changeClef, C as changeKey, e as changeNoteDuration, D as changeTime, av as convertToGrace, Y as copyNotes, $ as copyNotesMultiMeasure, R as createTuplet, _ as cutNotes, F as deleteMeasure, h as deleteNote, o as deleteNoteChecked, z as duplicatePart, P as insertClefChange, E as insertMeasure, i as insertNote, l as lowerAccidental, O as modifyDynamics, k as modifyNoteDuration, u as modifyNoteDurationChecked, m as modifyNotePitch, q as modifyNotePitchChecked, a3 as modifyTempo, B as moveNoteToStaff, Z as pasteNotes, a0 as pasteNotesMultiMeasure, f as raiseAccidental, L as removeArticulation, U as removeBeam, aI as removeBowing, aP as removeBreathMark, aR as removeCaesura, aD as removeChordSymbol, N as removeDynamics, ak as removeEnding, a7 as removeFermata, aG as removeFingering, au as removeGraceNote, aA as removeHarmony, ax as removeLyric, r as removeNote, aN as removeOctaveShift, a9 as removeOrnament, y as removePart, ab as removePedal, ai as removeRepeat, ag as removeRepeatBarline, J as removeSlur, aK as removeStringNumber, a2 as removeTempo, H as removeTie, S as removeTuplet, a5 as removeWedge, am as setBarline, X as setBeaming, s as setNotePitch, c as setNotePitchBySemitone, A as setStaves, d as shiftNotePitch, aM as stopOctaveShift, t as transpose, v as transposeChecked, aE as updateChordSymbol, aB as updateHarmony, ay as updateLyric } from '../index-DUXUhmaM.js';
|
package/dist/query/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as Measure, N as NoteEntry, V as VoiceGroup, q as StaffGroup, r as NoteWithPosition, s as Chord, S as Score, t as NoteIteratorItem, h as MeasureEntry, x as VoiceToStaffMap, f as Part, C as Clef, G as StaffRange, H as PositionQueryOptions, I as VerticalSlice, J as VoiceLine, E as EntryWithContext, y as NoteWithContext, O as AdjacentNotes, z as DirectionWithContext, a as DirectionEntry, Q as DirectionKind, R as DynamicWithContext, U as TempoWithContext, W as PedalWithContext, X as WedgeWithContext, Y as OctaveShiftWithContext, Z as TiedNoteGroup, _ as SlurSpan, $ as TupletGroup, a0 as BeamGroup, a1 as NotationType, a2 as HarmonyWithContext, ae as HarmonyEntry, a3 as LyricWithContext, a4 as AssembledLyrics, a6 as RepeatInfo, a5 as BarlineWithContext, a7 as EndingInfo, a8 as KeyChangeInfo, a9 as TimeChangeInfo, aa as ClefChangeInfo, ab as StructuralChanges, g as MeasureAttributes, P as Pitch } from '../types-
|
|
1
|
+
import { M as Measure, N as NoteEntry, V as VoiceGroup, q as StaffGroup, r as NoteWithPosition, s as Chord, S as Score, t as NoteIteratorItem, h as MeasureEntry, x as VoiceToStaffMap, f as Part, C as Clef, G as StaffRange, H as PositionQueryOptions, I as VerticalSlice, J as VoiceLine, E as EntryWithContext, y as NoteWithContext, O as AdjacentNotes, z as DirectionWithContext, a as DirectionEntry, Q as DirectionKind, R as DynamicWithContext, U as TempoWithContext, W as PedalWithContext, X as WedgeWithContext, Y as OctaveShiftWithContext, Z as TiedNoteGroup, _ as SlurSpan, $ as TupletGroup, a0 as BeamGroup, a1 as NotationType, a2 as HarmonyWithContext, ae as HarmonyEntry, a3 as LyricWithContext, a4 as AssembledLyrics, a6 as RepeatInfo, a5 as BarlineWithContext, a7 as EndingInfo, a8 as KeyChangeInfo, a9 as TimeChangeInfo, aa as ClefChangeInfo, ab as StructuralChanges, g as MeasureAttributes, P as Pitch } from '../types-CgndcKdd.mjs';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Filter options for voice/staff selection
|
package/dist/query/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as Measure, N as NoteEntry, V as VoiceGroup, q as StaffGroup, r as NoteWithPosition, s as Chord, S as Score, t as NoteIteratorItem, h as MeasureEntry, x as VoiceToStaffMap, f as Part, C as Clef, G as StaffRange, H as PositionQueryOptions, I as VerticalSlice, J as VoiceLine, E as EntryWithContext, y as NoteWithContext, O as AdjacentNotes, z as DirectionWithContext, a as DirectionEntry, Q as DirectionKind, R as DynamicWithContext, U as TempoWithContext, W as PedalWithContext, X as WedgeWithContext, Y as OctaveShiftWithContext, Z as TiedNoteGroup, _ as SlurSpan, $ as TupletGroup, a0 as BeamGroup, a1 as NotationType, a2 as HarmonyWithContext, ae as HarmonyEntry, a3 as LyricWithContext, a4 as AssembledLyrics, a6 as RepeatInfo, a5 as BarlineWithContext, a7 as EndingInfo, a8 as KeyChangeInfo, a9 as TimeChangeInfo, aa as ClefChangeInfo, ab as StructuralChanges, g as MeasureAttributes, P as Pitch } from '../types-
|
|
1
|
+
import { M as Measure, N as NoteEntry, V as VoiceGroup, q as StaffGroup, r as NoteWithPosition, s as Chord, S as Score, t as NoteIteratorItem, h as MeasureEntry, x as VoiceToStaffMap, f as Part, C as Clef, G as StaffRange, H as PositionQueryOptions, I as VerticalSlice, J as VoiceLine, E as EntryWithContext, y as NoteWithContext, O as AdjacentNotes, z as DirectionWithContext, a as DirectionEntry, Q as DirectionKind, R as DynamicWithContext, U as TempoWithContext, W as PedalWithContext, X as WedgeWithContext, Y as OctaveShiftWithContext, Z as TiedNoteGroup, _ as SlurSpan, $ as TupletGroup, a0 as BeamGroup, a1 as NotationType, a2 as HarmonyWithContext, ae as HarmonyEntry, a3 as LyricWithContext, a4 as AssembledLyrics, a6 as RepeatInfo, a5 as BarlineWithContext, a7 as EndingInfo, a8 as KeyChangeInfo, a9 as TimeChangeInfo, aa as ClefChangeInfo, ab as StructuralChanges, g as MeasureAttributes, P as Pitch } from '../types-CgndcKdd.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Filter options for voice/staff selection
|