@scorelabs/core 1.0.7 → 1.0.9

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.
Files changed (74) hide show
  1. package/dist/importers/MusicXMLParser.d.ts +2 -2
  2. package/dist/importers/MusicXMLParser.js +75 -17
  3. package/dist/index.d.ts +2 -2
  4. package/dist/index.js +2 -2
  5. package/dist/models/Instrument.d.ts +8 -19
  6. package/dist/models/Instrument.js +77 -23
  7. package/dist/models/Measure.d.ts +2 -0
  8. package/dist/models/Measure.js +6 -0
  9. package/dist/models/NoteSet.d.ts +40 -38
  10. package/dist/models/NoteSet.js +5 -2
  11. package/dist/models/Pitch.js +4 -0
  12. package/dist/models/PreMeasure.d.ts +24 -0
  13. package/dist/models/PreMeasure.js +30 -0
  14. package/dist/models/Score.d.ts +16 -1
  15. package/dist/models/Score.js +190 -5
  16. package/dist/models/index.d.ts +1 -0
  17. package/dist/models/index.js +1 -0
  18. package/dist/models/types.d.ts +2 -213
  19. package/dist/models/types.js +2 -213
  20. package/dist/types/Accidental.d.ts +7 -0
  21. package/dist/types/Accidental.js +8 -0
  22. package/dist/types/Arpeggio.d.ts +5 -0
  23. package/dist/types/Arpeggio.js +6 -0
  24. package/dist/types/Articulation.d.ts +10 -0
  25. package/dist/types/Articulation.js +11 -0
  26. package/dist/types/BarlineStyle.d.ts +9 -0
  27. package/dist/types/BarlineStyle.js +10 -0
  28. package/dist/types/Bowing.d.ts +4 -0
  29. package/dist/types/Bowing.js +5 -0
  30. package/dist/types/Clef.d.ts +10 -0
  31. package/dist/types/Clef.js +11 -0
  32. package/dist/types/Duration.d.ts +20 -0
  33. package/dist/types/Duration.js +60 -0
  34. package/dist/types/Dynamic.d.ts +12 -0
  35. package/dist/types/Dynamic.js +13 -0
  36. package/dist/types/Fretboard.d.ts +19 -0
  37. package/dist/types/Fretboard.js +1 -0
  38. package/dist/types/Genre.d.ts +27 -0
  39. package/dist/types/Genre.js +28 -0
  40. package/dist/types/Glissando.d.ts +8 -0
  41. package/dist/types/Glissando.js +5 -0
  42. package/dist/types/Hairpin.d.ts +10 -0
  43. package/dist/types/Hairpin.js +11 -0
  44. package/dist/types/InstrumentPreset.d.ts +11 -0
  45. package/dist/types/InstrumentPreset.js +12 -0
  46. package/dist/types/InstrumentType.d.ts +8 -0
  47. package/dist/types/InstrumentType.js +9 -0
  48. package/dist/types/KeySignature.d.ts +3 -0
  49. package/dist/types/KeySignature.js +1 -0
  50. package/dist/types/Lyric.d.ts +11 -0
  51. package/dist/types/Lyric.js +7 -0
  52. package/dist/types/NoteheadShape.d.ts +8 -0
  53. package/dist/types/NoteheadShape.js +9 -0
  54. package/dist/types/Ornament.d.ts +8 -0
  55. package/dist/types/Ornament.js +9 -0
  56. package/dist/types/Ottava.d.ts +10 -0
  57. package/dist/types/Ottava.js +7 -0
  58. package/dist/types/Pedal.d.ts +4 -0
  59. package/dist/types/Pedal.js +1 -0
  60. package/dist/types/Repeat.d.ts +8 -0
  61. package/dist/types/Repeat.js +1 -0
  62. package/dist/types/Slur.d.ts +4 -0
  63. package/dist/types/Slur.js +1 -0
  64. package/dist/types/StemDirection.d.ts +4 -0
  65. package/dist/types/StemDirection.js +5 -0
  66. package/dist/types/Tempo.d.ts +8 -0
  67. package/dist/types/Tempo.js +1 -0
  68. package/dist/types/TimeSignature.d.ts +6 -0
  69. package/dist/types/TimeSignature.js +3 -0
  70. package/dist/types/Tuplet.d.ts +5 -0
  71. package/dist/types/Tuplet.js +1 -0
  72. package/dist/types/index.d.ts +26 -0
  73. package/dist/types/index.js +26 -0
  74. package/package.json +1 -1
@@ -0,0 +1,8 @@
1
+ export var Accidental;
2
+ (function (Accidental) {
3
+ Accidental["Sharp"] = "sharp";
4
+ Accidental["Flat"] = "flat";
5
+ Accidental["Natural"] = "natural";
6
+ Accidental["DoubleSharp"] = "double-sharp";
7
+ Accidental["DoubleFlat"] = "double-flat";
8
+ })(Accidental || (Accidental = {}));
@@ -0,0 +1,5 @@
1
+ export declare enum Arpeggio {
2
+ Normal = "normal",
3
+ Up = "up",
4
+ Down = "down"
5
+ }
@@ -0,0 +1,6 @@
1
+ export var Arpeggio;
2
+ (function (Arpeggio) {
3
+ Arpeggio["Normal"] = "normal";
4
+ Arpeggio["Up"] = "up";
5
+ Arpeggio["Down"] = "down";
6
+ })(Arpeggio || (Arpeggio = {}));
@@ -0,0 +1,10 @@
1
+ export declare enum Articulation {
2
+ Staccato = "staccato",
3
+ Accent = "accent",
4
+ Tenuto = "tenuto",
5
+ Marcato = "marcato",
6
+ Fermata = "fermata",
7
+ Staccatissimo = "staccatissimo",
8
+ Caesura = "caesura",
9
+ BreathMark = "breath-mark"
10
+ }
@@ -0,0 +1,11 @@
1
+ export var Articulation;
2
+ (function (Articulation) {
3
+ Articulation["Staccato"] = "staccato";
4
+ Articulation["Accent"] = "accent";
5
+ Articulation["Tenuto"] = "tenuto";
6
+ Articulation["Marcato"] = "marcato";
7
+ Articulation["Fermata"] = "fermata";
8
+ Articulation["Staccatissimo"] = "staccatissimo";
9
+ Articulation["Caesura"] = "caesura";
10
+ Articulation["BreathMark"] = "breath-mark";
11
+ })(Articulation || (Articulation = {}));
@@ -0,0 +1,9 @@
1
+ export declare enum BarlineStyle {
2
+ Regular = "regular",
3
+ Double = "light-light",
4
+ Final = "light-heavy",
5
+ Dotted = "dotted",
6
+ Dashed = "dashed",
7
+ Heavy = "heavy",
8
+ None = "none"
9
+ }
@@ -0,0 +1,10 @@
1
+ export var BarlineStyle;
2
+ (function (BarlineStyle) {
3
+ BarlineStyle["Regular"] = "regular";
4
+ BarlineStyle["Double"] = "light-light";
5
+ BarlineStyle["Final"] = "light-heavy";
6
+ BarlineStyle["Dotted"] = "dotted";
7
+ BarlineStyle["Dashed"] = "dashed";
8
+ BarlineStyle["Heavy"] = "heavy";
9
+ BarlineStyle["None"] = "none";
10
+ })(BarlineStyle || (BarlineStyle = {}));
@@ -0,0 +1,4 @@
1
+ export declare enum Bowing {
2
+ DownBow = "down-bow",
3
+ UpBow = "up-bow"
4
+ }
@@ -0,0 +1,5 @@
1
+ export var Bowing;
2
+ (function (Bowing) {
3
+ Bowing["DownBow"] = "down-bow";
4
+ Bowing["UpBow"] = "up-bow";
5
+ })(Bowing || (Bowing = {}));
@@ -0,0 +1,10 @@
1
+ export declare enum Clef {
2
+ Treble = "treble",
3
+ Bass = "bass",
4
+ Alto = "alto",
5
+ Tenor = "tenor",
6
+ Percussion = "percussion",
7
+ Tab = "tab",
8
+ Treble8vaBassa = "treble8vabassa",
9
+ Bass8vaBassa = "bass8vabassa"
10
+ }
@@ -0,0 +1,11 @@
1
+ export var Clef;
2
+ (function (Clef) {
3
+ Clef["Treble"] = "treble";
4
+ Clef["Bass"] = "bass";
5
+ Clef["Alto"] = "alto";
6
+ Clef["Tenor"] = "tenor";
7
+ Clef["Percussion"] = "percussion";
8
+ Clef["Tab"] = "tab";
9
+ Clef["Treble8vaBassa"] = "treble8vabassa";
10
+ Clef["Bass8vaBassa"] = "bass8vabassa";
11
+ })(Clef || (Clef = {}));
@@ -0,0 +1,20 @@
1
+ export declare enum Duration {
2
+ Whole = "whole",
3
+ Half = "half",
4
+ Quarter = "quarter",
5
+ Eighth = "eighth",
6
+ Sixteenth = "sixteenth",
7
+ ThirtySecond = "thirty-second",
8
+ SixtyFourth = "sixty-fourth",
9
+ OneHundredTwentyEighth = "one-hundred-twenty-eighth",
10
+ TwoHundredFiftySixth = "two-hundred-fifty-sixth"
11
+ }
12
+ export declare const DURATION_VALUES: Record<Duration, number>;
13
+ /**
14
+ * Decomposes a duration value (quarter = 1) into a list of duration/dot pairs.
15
+ */
16
+ export declare function decomposeDuration(value: number): {
17
+ duration: Duration;
18
+ isDotted: boolean;
19
+ val: number;
20
+ }[];
@@ -0,0 +1,60 @@
1
+ export var Duration;
2
+ (function (Duration) {
3
+ Duration["Whole"] = "whole";
4
+ Duration["Half"] = "half";
5
+ Duration["Quarter"] = "quarter";
6
+ Duration["Eighth"] = "eighth";
7
+ Duration["Sixteenth"] = "sixteenth";
8
+ Duration["ThirtySecond"] = "thirty-second";
9
+ Duration["SixtyFourth"] = "sixty-fourth";
10
+ Duration["OneHundredTwentyEighth"] = "one-hundred-twenty-eighth";
11
+ Duration["TwoHundredFiftySixth"] = "two-hundred-fifty-sixth";
12
+ })(Duration || (Duration = {}));
13
+ // Duration values in terms of quarter note = 1
14
+ export const DURATION_VALUES = {
15
+ [Duration.Whole]: 4,
16
+ [Duration.Half]: 2,
17
+ [Duration.Quarter]: 1,
18
+ [Duration.Eighth]: 0.5,
19
+ [Duration.Sixteenth]: 0.25,
20
+ [Duration.ThirtySecond]: 0.125,
21
+ [Duration.SixtyFourth]: 0.0625,
22
+ [Duration.OneHundredTwentyEighth]: 0.03125,
23
+ [Duration.TwoHundredFiftySixth]: 0.015625,
24
+ };
25
+ /**
26
+ * Decomposes a duration value (quarter = 1) into a list of duration/dot pairs.
27
+ */
28
+ export function decomposeDuration(value) {
29
+ const result = [];
30
+ let remaining = value;
31
+ const options = [
32
+ { val: 4, dur: Duration.Whole, dot: false },
33
+ { val: 3, dur: Duration.Half, dot: true },
34
+ { val: 2, dur: Duration.Half, dot: false },
35
+ { val: 1.5, dur: Duration.Quarter, dot: true },
36
+ { val: 1, dur: Duration.Quarter, dot: false },
37
+ { val: 0.75, dur: Duration.Eighth, dot: true },
38
+ { val: 0.5, dur: Duration.Eighth, dot: false },
39
+ { val: 0.375, dur: Duration.Sixteenth, dot: true },
40
+ { val: 0.25, dur: Duration.Sixteenth, dot: false },
41
+ { val: 0.1875, dur: Duration.ThirtySecond, dot: true },
42
+ { val: 0.125, dur: Duration.ThirtySecond, dot: false },
43
+ { val: 0.09375, dur: Duration.SixtyFourth, dot: true },
44
+ { val: 0.0625, dur: Duration.SixtyFourth, dot: false },
45
+ ];
46
+ // Protect against infinite loop with max iterations
47
+ let loops = 0;
48
+ while (remaining > 0.001 && loops < 100) {
49
+ const match = options.find((o) => o.val <= remaining + 0.001);
50
+ if (match) {
51
+ result.push({ duration: match.dur, isDotted: match.dot, val: match.val });
52
+ remaining -= match.val;
53
+ }
54
+ else {
55
+ break;
56
+ }
57
+ loops++;
58
+ }
59
+ return result;
60
+ }
@@ -0,0 +1,12 @@
1
+ export declare enum Dynamic {
2
+ PPP = "ppp",
3
+ PP = "pp",
4
+ P = "p",
5
+ MP = "mp",
6
+ MF = "mf",
7
+ F = "f",
8
+ FF = "ff",
9
+ FFF = "fff",
10
+ SFZ = "sfz",
11
+ FP = "fp"
12
+ }
@@ -0,0 +1,13 @@
1
+ export var Dynamic;
2
+ (function (Dynamic) {
3
+ Dynamic["PPP"] = "ppp";
4
+ Dynamic["PP"] = "pp";
5
+ Dynamic["P"] = "p";
6
+ Dynamic["MP"] = "mp";
7
+ Dynamic["MF"] = "mf";
8
+ Dynamic["F"] = "f";
9
+ Dynamic["FF"] = "ff";
10
+ Dynamic["FFF"] = "fff";
11
+ Dynamic["SFZ"] = "sfz";
12
+ Dynamic["FP"] = "fp";
13
+ })(Dynamic || (Dynamic = {}));
@@ -0,0 +1,19 @@
1
+ export interface FretboardDot {
2
+ string: number;
3
+ fret: number;
4
+ label?: string;
5
+ }
6
+ export interface FretboardBarre {
7
+ fret: number;
8
+ startString: number;
9
+ endString: number;
10
+ }
11
+ export interface FretboardDiagram {
12
+ strings: number;
13
+ frets: number;
14
+ startingFret?: number;
15
+ dots: FretboardDot[];
16
+ barres?: FretboardBarre[];
17
+ openStrings?: number[];
18
+ mutedStrings?: number[];
19
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,27 @@
1
+ export declare enum Genre {
2
+ Blues = "Blues",
3
+ Children = "Children",
4
+ Christian = "Christian",
5
+ Christmas = "Christmas",
6
+ Classical = "Classical",
7
+ ContestFestival = "Contest/Festival",
8
+ Country = "Country",
9
+ Educational = "Educational",
10
+ FilmTV = "Film/TV",
11
+ Folk = "Folk",
12
+ Games = "Games",
13
+ Gospel = "Gospel",
14
+ Holiday = "Holiday",
15
+ Jazz = "Jazz",
16
+ Latin = "Latin",
17
+ Musicals = "Musicals",
18
+ Pop = "Pop",
19
+ RBHipHop = "R&B/Hip-Hop",
20
+ Rock = "Rock",
21
+ Standards = "Standards",
22
+ Traditional = "Traditional",
23
+ Wedding = "Wedding",
24
+ World = "World",
25
+ Worship = "Worship",
26
+ Unknown = "unknown"
27
+ }
@@ -0,0 +1,28 @@
1
+ export var Genre;
2
+ (function (Genre) {
3
+ Genre["Blues"] = "Blues";
4
+ Genre["Children"] = "Children";
5
+ Genre["Christian"] = "Christian";
6
+ Genre["Christmas"] = "Christmas";
7
+ Genre["Classical"] = "Classical";
8
+ Genre["ContestFestival"] = "Contest/Festival";
9
+ Genre["Country"] = "Country";
10
+ Genre["Educational"] = "Educational";
11
+ Genre["FilmTV"] = "Film/TV";
12
+ Genre["Folk"] = "Folk";
13
+ Genre["Games"] = "Games";
14
+ Genre["Gospel"] = "Gospel";
15
+ Genre["Holiday"] = "Holiday";
16
+ Genre["Jazz"] = "Jazz";
17
+ Genre["Latin"] = "Latin";
18
+ Genre["Musicals"] = "Musicals";
19
+ Genre["Pop"] = "Pop";
20
+ Genre["RBHipHop"] = "R&B/Hip-Hop";
21
+ Genre["Rock"] = "Rock";
22
+ Genre["Standards"] = "Standards";
23
+ Genre["Traditional"] = "Traditional";
24
+ Genre["Wedding"] = "Wedding";
25
+ Genre["World"] = "World";
26
+ Genre["Worship"] = "Worship";
27
+ Genre["Unknown"] = "unknown";
28
+ })(Genre || (Genre = {}));
@@ -0,0 +1,8 @@
1
+ export declare enum GlissandoType {
2
+ Wavy = "wavy",
3
+ Straight = "straight"
4
+ }
5
+ export interface Glissando {
6
+ type: GlissandoType;
7
+ placement: 'start' | 'stop';
8
+ }
@@ -0,0 +1,5 @@
1
+ export var GlissandoType;
2
+ (function (GlissandoType) {
3
+ GlissandoType["Wavy"] = "wavy";
4
+ GlissandoType["Straight"] = "straight";
5
+ })(GlissandoType || (GlissandoType = {}));
@@ -0,0 +1,10 @@
1
+ export declare enum HairpinType {
2
+ Crescendo = "crescendo",
3
+ Decrescendo = "decrescendo"
4
+ }
5
+ export interface Hairpin {
6
+ type: HairpinType;
7
+ placement: 'start' | 'stop';
8
+ }
9
+ export declare function isCrescendo(hairpin: Hairpin): boolean;
10
+ export declare function isDecrescendo(hairpin: Hairpin): boolean;
@@ -0,0 +1,11 @@
1
+ export var HairpinType;
2
+ (function (HairpinType) {
3
+ HairpinType["Crescendo"] = "crescendo";
4
+ HairpinType["Decrescendo"] = "decrescendo";
5
+ })(HairpinType || (HairpinType = {}));
6
+ export function isCrescendo(hairpin) {
7
+ return hairpin.type === HairpinType.Crescendo;
8
+ }
9
+ export function isDecrescendo(hairpin) {
10
+ return hairpin.type === HairpinType.Decrescendo;
11
+ }
@@ -0,0 +1,11 @@
1
+ export declare enum InstrumentPreset {
2
+ Piano = "piano",
3
+ Violin = "violin",
4
+ Cello = "cello",
5
+ Guitar = "guitar",
6
+ ElectricGuitar = "electric-guitar",
7
+ Bass = "bass",
8
+ Flute = "flute",
9
+ Trumpet = "trumpet",
10
+ Drums = "drums"
11
+ }
@@ -0,0 +1,12 @@
1
+ export var InstrumentPreset;
2
+ (function (InstrumentPreset) {
3
+ InstrumentPreset["Piano"] = "piano";
4
+ InstrumentPreset["Violin"] = "violin";
5
+ InstrumentPreset["Cello"] = "cello";
6
+ InstrumentPreset["Guitar"] = "guitar";
7
+ InstrumentPreset["ElectricGuitar"] = "electric-guitar";
8
+ InstrumentPreset["Bass"] = "bass";
9
+ InstrumentPreset["Flute"] = "flute";
10
+ InstrumentPreset["Trumpet"] = "trumpet";
11
+ InstrumentPreset["Drums"] = "drums";
12
+ })(InstrumentPreset || (InstrumentPreset = {}));
@@ -0,0 +1,8 @@
1
+ export declare enum InstrumentType {
2
+ String = "string",
3
+ Brass = "brass",
4
+ Woodwind = "woodwind",
5
+ Percussion = "percussion",
6
+ Keyboard = "keyboard",
7
+ Synth = "synth"
8
+ }
@@ -0,0 +1,9 @@
1
+ export var InstrumentType;
2
+ (function (InstrumentType) {
3
+ InstrumentType["String"] = "string";
4
+ InstrumentType["Brass"] = "brass";
5
+ InstrumentType["Woodwind"] = "woodwind";
6
+ InstrumentType["Percussion"] = "percussion";
7
+ InstrumentType["Keyboard"] = "keyboard";
8
+ InstrumentType["Synth"] = "synth";
9
+ })(InstrumentType || (InstrumentType = {}));
@@ -0,0 +1,3 @@
1
+ export interface KeySignature {
2
+ fifths: number;
3
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ export declare enum Syllabic {
2
+ Single = "single",
3
+ Begin = "begin",
4
+ Middle = "middle",
5
+ End = "end"
6
+ }
7
+ export interface Lyric {
8
+ text: string;
9
+ syllabic?: Syllabic;
10
+ isExtension?: boolean;
11
+ }
@@ -0,0 +1,7 @@
1
+ export var Syllabic;
2
+ (function (Syllabic) {
3
+ Syllabic["Single"] = "single";
4
+ Syllabic["Begin"] = "begin";
5
+ Syllabic["Middle"] = "middle";
6
+ Syllabic["End"] = "end";
7
+ })(Syllabic || (Syllabic = {}));
@@ -0,0 +1,8 @@
1
+ export declare enum NoteheadShape {
2
+ Normal = "normal",
3
+ Cross = "cross",// X shape (percussion, spoken)
4
+ Diamond = "diamond",// Harmonics
5
+ Slash = "slash",// Rhythmic notation
6
+ Triangle = "triangle",// Percussion
7
+ Square = "square"
8
+ }
@@ -0,0 +1,9 @@
1
+ export var NoteheadShape;
2
+ (function (NoteheadShape) {
3
+ NoteheadShape["Normal"] = "normal";
4
+ NoteheadShape["Cross"] = "cross";
5
+ NoteheadShape["Diamond"] = "diamond";
6
+ NoteheadShape["Slash"] = "slash";
7
+ NoteheadShape["Triangle"] = "triangle";
8
+ NoteheadShape["Square"] = "square";
9
+ })(NoteheadShape || (NoteheadShape = {}));
@@ -0,0 +1,8 @@
1
+ export declare enum Ornament {
2
+ Trill = "trill",
3
+ Mordent = "mordent",
4
+ InvertedMordent = "inverted-mordent",
5
+ Turn = "turn",
6
+ InvertedTurn = "inverted-turn",
7
+ Tremolo = "tremolo"
8
+ }
@@ -0,0 +1,9 @@
1
+ export var Ornament;
2
+ (function (Ornament) {
3
+ Ornament["Trill"] = "trill";
4
+ Ornament["Mordent"] = "mordent";
5
+ Ornament["InvertedMordent"] = "inverted-mordent";
6
+ Ornament["Turn"] = "turn";
7
+ Ornament["InvertedTurn"] = "inverted-turn";
8
+ Ornament["Tremolo"] = "tremolo";
9
+ })(Ornament || (Ornament = {}));
@@ -0,0 +1,10 @@
1
+ export declare enum OttavaType {
2
+ OttavaAlta = "8va",
3
+ OttavaBassa = "8vb",
4
+ QuindicesimaAlta = "15ma",
5
+ QuindicesimaBassa = "15mb"
6
+ }
7
+ export interface Ottava {
8
+ type: OttavaType;
9
+ placement: 'start' | 'stop';
10
+ }
@@ -0,0 +1,7 @@
1
+ export var OttavaType;
2
+ (function (OttavaType) {
3
+ OttavaType["OttavaAlta"] = "8va";
4
+ OttavaType["OttavaBassa"] = "8vb";
5
+ OttavaType["QuindicesimaAlta"] = "15ma";
6
+ OttavaType["QuindicesimaBassa"] = "15mb";
7
+ })(OttavaType || (OttavaType = {}));
@@ -0,0 +1,4 @@
1
+ export interface Pedal {
2
+ type: 'sustain' | 'una-corda';
3
+ placement: 'start' | 'stop';
4
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,8 @@
1
+ export interface Repeat {
2
+ type: 'start' | 'end';
3
+ times?: number;
4
+ }
5
+ export interface Volta {
6
+ type: 'start' | 'stop' | 'both';
7
+ numbers: number[];
8
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ export interface Slur {
2
+ placement: 'start' | 'stop';
3
+ direction?: 'up' | 'down';
4
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ export declare enum StemDirection {
2
+ Up = "up",
3
+ Down = "down"
4
+ }
@@ -0,0 +1,5 @@
1
+ export var StemDirection;
2
+ (function (StemDirection) {
3
+ StemDirection["Up"] = "up";
4
+ StemDirection["Down"] = "down";
5
+ })(StemDirection || (StemDirection = {}));
@@ -0,0 +1,8 @@
1
+ import { Duration } from './Duration.js';
2
+ export interface Tempo {
3
+ bpm: number;
4
+ duration: Duration;
5
+ isDotted: boolean;
6
+ text?: string;
7
+ gradual?: 'ritardando' | 'accelerando';
8
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,6 @@
1
+ export interface TimeSignature {
2
+ beats: number;
3
+ beatType: number;
4
+ symbol?: 'common' | 'cut' | 'normal';
5
+ }
6
+ export declare function isSymbolicTimeSignature(timeSignature: TimeSignature): boolean;
@@ -0,0 +1,3 @@
1
+ export function isSymbolicTimeSignature(timeSignature) {
2
+ return timeSignature.symbol === 'common' || timeSignature.symbol === 'cut';
3
+ }
@@ -0,0 +1,5 @@
1
+ export interface Tuplet {
2
+ actual: number;
3
+ normal: number;
4
+ type: 'start' | 'stop' | 'middle';
5
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,26 @@
1
+ export * from './InstrumentPreset.js';
2
+ export * from './InstrumentType.js';
3
+ export * from './StemDirection.js';
4
+ export * from './Clef.js';
5
+ export * from './Duration.js';
6
+ export * from './Accidental.js';
7
+ export * from './Articulation.js';
8
+ export * from './Dynamic.js';
9
+ export * from './Genre.js';
10
+ export * from './BarlineStyle.js';
11
+ export * from './Lyric.js';
12
+ export * from './Bowing.js';
13
+ export * from './NoteheadShape.js';
14
+ export * from './Ornament.js';
15
+ export * from './Fretboard.js';
16
+ export * from './TimeSignature.js';
17
+ export * from './KeySignature.js';
18
+ export * from './Tempo.js';
19
+ export * from './Hairpin.js';
20
+ export * from './Ottava.js';
21
+ export * from './Arpeggio.js';
22
+ export * from './Glissando.js';
23
+ export * from './Pedal.js';
24
+ export * from './Slur.js';
25
+ export * from './Tuplet.js';
26
+ export * from './Repeat.js';
@@ -0,0 +1,26 @@
1
+ export * from './InstrumentPreset.js';
2
+ export * from './InstrumentType.js';
3
+ export * from './StemDirection.js';
4
+ export * from './Clef.js';
5
+ export * from './Duration.js';
6
+ export * from './Accidental.js';
7
+ export * from './Articulation.js';
8
+ export * from './Dynamic.js';
9
+ export * from './Genre.js';
10
+ export * from './BarlineStyle.js';
11
+ export * from './Lyric.js';
12
+ export * from './Bowing.js';
13
+ export * from './NoteheadShape.js';
14
+ export * from './Ornament.js';
15
+ export * from './Fretboard.js';
16
+ export * from './TimeSignature.js';
17
+ export * from './KeySignature.js';
18
+ export * from './Tempo.js';
19
+ export * from './Hairpin.js';
20
+ export * from './Ottava.js';
21
+ export * from './Arpeggio.js';
22
+ export * from './Glissando.js';
23
+ export * from './Pedal.js';
24
+ export * from './Slur.js';
25
+ export * from './Tuplet.js';
26
+ export * from './Repeat.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scorelabs/core",
3
- "version": "1.0.7",
3
+ "version": "1.0.9",
4
4
  "description": "Core logic and models for ScoreLabs music notation",
5
5
  "type": "module",
6
6
  "files": [