jpfun 1.0.0 → 1.2.0
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/README.md +1 -1
- package/dist/diagnostic.d.ts +1 -0
- package/dist/diagnostic.js +1 -0
- package/dist/functions/ASTtypes.d.ts +2 -3
- package/dist/functions/ASTtypes.js +2 -3
- package/dist/functions/adjust/index.js +15 -67
- package/dist/functions/bar/index.js +11 -7
- package/dist/functions/beam/auto.js +15 -11
- package/dist/functions/beam/layout.js +22 -48
- package/dist/functions/br/index.d.ts +9 -3
- package/dist/functions/br/index.js +20 -16
- package/dist/functions/dash/index.js +13 -11
- package/dist/functions/default.js +2 -1
- package/dist/functions/div/index.d.ts +2 -2
- package/dist/functions/div/index.js +5 -9
- package/dist/functions/dot/index.js +5 -9
- package/dist/functions/dyn/index.js +125 -53
- package/dist/functions/gliss/index.js +81 -7
- package/dist/functions/grace/index.d.ts +3 -10
- package/dist/functions/grace/index.js +25 -57
- package/dist/functions/head/index.js +6 -7
- package/dist/functions/key/index.js +1 -0
- package/dist/functions/meter/index.js +7 -5
- package/dist/functions/note/index.d.ts +5 -2
- package/dist/functions/note/index.js +162 -19
- package/dist/functions/note/source-transform.d.ts +8 -2
- package/dist/functions/note/source-transform.js +25 -11
- package/dist/functions/ottava/index.js +8 -7
- package/dist/functions/page/index.d.ts +1 -36
- package/dist/functions/page/index.js +11 -15
- package/dist/functions/pagebreak/index.js +2 -1
- package/dist/functions/rest/index.js +5 -5
- package/dist/functions/set/index.js +2 -2
- package/dist/functions/stack/index.js +7 -7
- package/dist/functions/symbol/symbols/dynamics.d.ts +3 -0
- package/dist/functions/symbol/symbols/dynamics.js +10 -1
- package/dist/functions/tempo/index.js +8 -3
- package/dist/functions/temporal.d.ts +21 -6
- package/dist/functions/temporal.js +1 -1
- package/dist/functions/text/index.js +3 -5
- package/dist/functions/up/index.js +37 -34
- package/dist/functions/voice/connections.js +2 -2
- package/dist/functions/voice/lyrics.d.ts +2 -0
- package/dist/functions/voice/lyrics.js +4 -4
- package/dist/functions/voice/voice.d.ts +2 -1
- package/dist/functions/voice/voice.js +9 -15
- package/dist/functions/voice/voices.d.ts +6 -4
- package/dist/functions/voice/voices.js +10 -10
- package/dist/index.d.ts +6 -34
- package/dist/index.js +6 -34
- package/dist/jpfun.min.js +49 -46
- package/dist/layout/engine.js +237 -232
- package/dist/layout/model.d.ts +1 -1
- package/dist/layout/page.d.ts +2 -2
- package/dist/layout/page.js +8 -22
- package/dist/layout/types.d.ts +4 -5
- package/dist/lowering/accidentalMemory.d.ts +33 -0
- package/dist/lowering/accidentalMemory.js +84 -0
- package/dist/lowering/loweringContext.d.ts +12 -7
- package/dist/lowering/loweringContext.js +54 -51
- package/dist/lowering/types.d.ts +2 -3
- package/dist/parser/grammarType.d.ts +10 -4
- package/dist/parser/parse-utils/brace-utils.js +4 -3
- package/dist/parser/parse-utils/call-utils.js +7 -7
- package/dist/parser/parse-utils/string-utils.d.ts +1 -1
- package/dist/parser/parse-utils/string-utils.js +1 -1
- package/dist/parser/parserContext.d.ts +30 -34
- package/dist/parser/parserContext.js +77 -181
- package/dist/parser/preprocess.js +10 -23
- package/dist/parser/syntax.d.ts +9 -0
- package/dist/parser/syntax.js +109 -0
- package/dist/parser/types.d.ts +2 -1
- package/dist/pipeline.js +3 -2
- package/dist/playback/compile.js +26 -18
- package/dist/playback/event.d.ts +1 -2
- package/dist/playback/event.js +2 -3
- package/dist/playback/types.d.ts +0 -1
- package/dist/render/index.d.ts +1 -0
- package/dist/render/index.js +1 -0
- package/grammar.md +8 -6
- package/package.json +2 -2
- package/dist/functions/voice/index.d.ts +0 -2
- package/dist/functions/voice/index.js +0 -2
package/dist/index.d.ts
CHANGED
|
@@ -4,25 +4,20 @@ export * from "./functions/temporal.js";
|
|
|
4
4
|
export * from "./functions/default.js";
|
|
5
5
|
export * from "./functions/adjust/index.js";
|
|
6
6
|
export * from "./functions/arpeggio/index.js";
|
|
7
|
-
export
|
|
8
|
-
export * from "./functions/bar/index.js";
|
|
7
|
+
export { BarNode } from "./functions/bar/index.js";
|
|
9
8
|
export * from "./functions/beam/index.js";
|
|
10
|
-
export * from "./functions/beam/auto.js";
|
|
11
|
-
export * from "./functions/beam/layout.js";
|
|
12
9
|
export * from "./functions/box/index.js";
|
|
13
10
|
export * from "./functions/br/index.js";
|
|
14
11
|
export * from "./functions/dash/index.js";
|
|
15
|
-
export
|
|
12
|
+
export { DivNode } from "./functions/div/index.js";
|
|
16
13
|
export * from "./functions/dot/index.js";
|
|
17
14
|
export * from "./functions/dyn/index.js";
|
|
18
15
|
export * from "./functions/gliss/index.js";
|
|
19
16
|
export * from "./functions/grace/index.js";
|
|
20
17
|
export * from "./functions/head/index.js";
|
|
21
18
|
export * from "./functions/key/index.js";
|
|
22
|
-
export
|
|
23
|
-
export * from "./functions/meter/shape.js";
|
|
19
|
+
export { MeterNode } from "./functions/meter/index.js";
|
|
24
20
|
export * from "./functions/note/index.js";
|
|
25
|
-
export * from "./functions/note/accidentals.js";
|
|
26
21
|
export * from "./functions/note/noteName.js";
|
|
27
22
|
export * from "./functions/note/source-transform.js";
|
|
28
23
|
export * from "./functions/ottava/index.js";
|
|
@@ -34,28 +29,7 @@ export * from "./functions/set/index.js";
|
|
|
34
29
|
export * from "./functions/slide/index.js";
|
|
35
30
|
export * from "./functions/stack/index.js";
|
|
36
31
|
export * from "./functions/symbol/index.js";
|
|
37
|
-
export * from "./functions/symbol/ornament.js";
|
|
38
|
-
export * from "./functions/symbol/shape.js";
|
|
39
|
-
export * from "./functions/symbol/symbols/accent.js";
|
|
40
|
-
export * from "./functions/symbol/symbols/coda.js";
|
|
41
|
-
export * from "./functions/symbol/symbols/dc.js";
|
|
42
|
-
export * from "./functions/symbol/symbols/ds.js";
|
|
43
|
-
export * from "./functions/symbol/symbols/dynamics.js";
|
|
44
|
-
export * from "./functions/symbol/symbols/fermata.js";
|
|
45
|
-
export * from "./functions/symbol/symbols/fine.js";
|
|
46
|
-
export * from "./functions/symbol/symbols/harmonic.js";
|
|
47
|
-
export * from "./functions/symbol/symbols/marcato.js";
|
|
48
|
-
export * from "./functions/symbol/symbols/mordent.js";
|
|
49
|
-
export * from "./functions/symbol/symbols/prall.js";
|
|
50
|
-
export * from "./functions/symbol/symbols/segno.js";
|
|
51
|
-
export * from "./functions/symbol/symbols/staccato.js";
|
|
52
|
-
export * from "./functions/symbol/symbols/tenuto.js";
|
|
53
|
-
export * from "./functions/symbol/symbols/tocoda.js";
|
|
54
|
-
export * from "./functions/symbol/symbols/tr.js";
|
|
55
|
-
export * from "./functions/symbol/symbols/turn.js";
|
|
56
|
-
export * from "./functions/symbol/symbols/wheel.js";
|
|
57
32
|
export * from "./functions/tempo/index.js";
|
|
58
|
-
export * from "./functions/tempo/glyph.js";
|
|
59
33
|
export * from "./functions/text/index.js";
|
|
60
34
|
export * from "./functions/tie/index.js";
|
|
61
35
|
export * from "./functions/tremolo/index.js";
|
|
@@ -63,7 +37,7 @@ export * from "./functions/tuplet/index.js";
|
|
|
63
37
|
export * from "./functions/up/index.js";
|
|
64
38
|
export * from "./functions/voice/voice.js";
|
|
65
39
|
export * from "./functions/voice/voices.js";
|
|
66
|
-
export
|
|
40
|
+
export { parseConnections, resolveConnections, serializeConnections, type ConnectionSpec, type VoiceConnection, } from "./functions/voice/connections.js";
|
|
67
41
|
export * from "./functions/voice/lyrics.js";
|
|
68
42
|
export * from "./functions/volta/index.js";
|
|
69
43
|
export * from "./diagnostic.js";
|
|
@@ -78,20 +52,18 @@ export * from "./parser/parse-utils/label-utils.js";
|
|
|
78
52
|
export * from "./parser/parse-utils/length-utils.js";
|
|
79
53
|
export * from "./parser/parse-utils/note-utils.js";
|
|
80
54
|
export * from "./parser/parse-utils/string-utils.js";
|
|
81
|
-
export { quote as quoteSourceString } from "./parser/parse-utils/string-utils.js";
|
|
82
55
|
export * from "./lowering/types.js";
|
|
83
56
|
export * from "./lowering/loweringContext.js";
|
|
84
57
|
export * from "./lowering/track.js";
|
|
58
|
+
export * from "./lowering/accidentalMemory.js";
|
|
85
59
|
export * from "./playback/types.js";
|
|
86
|
-
export * from "./playback/event.js";
|
|
87
60
|
export * from "./playback/time.js";
|
|
88
61
|
export * from "./playback/compile.js";
|
|
89
62
|
export * from "./layout/types.js";
|
|
90
63
|
export * from "./layout/model.js";
|
|
91
64
|
export * from "./layout/default.js";
|
|
92
|
-
export
|
|
65
|
+
export { DEFAULT_PAGE_CONFIG, normalizePageConfig, paginateLayoutLines, type DocumentLayoutPage, } from "./layout/page.js";
|
|
93
66
|
export * from "./layout/engine.js";
|
|
94
67
|
export * from "./layout/path.js";
|
|
95
68
|
export * from "./layout/range.js";
|
|
96
69
|
export * from "./render/index.js";
|
|
97
|
-
export * from "./render/translate.js";
|
package/dist/index.js
CHANGED
|
@@ -4,25 +4,20 @@ export * from "./functions/temporal.js";
|
|
|
4
4
|
export * from "./functions/default.js";
|
|
5
5
|
export * from "./functions/adjust/index.js";
|
|
6
6
|
export * from "./functions/arpeggio/index.js";
|
|
7
|
-
export
|
|
8
|
-
export * from "./functions/bar/index.js";
|
|
7
|
+
export { BarNode } from "./functions/bar/index.js";
|
|
9
8
|
export * from "./functions/beam/index.js";
|
|
10
|
-
export * from "./functions/beam/auto.js";
|
|
11
|
-
export * from "./functions/beam/layout.js";
|
|
12
9
|
export * from "./functions/box/index.js";
|
|
13
10
|
export * from "./functions/br/index.js";
|
|
14
11
|
export * from "./functions/dash/index.js";
|
|
15
|
-
export
|
|
12
|
+
export { DivNode } from "./functions/div/index.js";
|
|
16
13
|
export * from "./functions/dot/index.js";
|
|
17
14
|
export * from "./functions/dyn/index.js";
|
|
18
15
|
export * from "./functions/gliss/index.js";
|
|
19
16
|
export * from "./functions/grace/index.js";
|
|
20
17
|
export * from "./functions/head/index.js";
|
|
21
18
|
export * from "./functions/key/index.js";
|
|
22
|
-
export
|
|
23
|
-
export * from "./functions/meter/shape.js";
|
|
19
|
+
export { MeterNode } from "./functions/meter/index.js";
|
|
24
20
|
export * from "./functions/note/index.js";
|
|
25
|
-
export * from "./functions/note/accidentals.js";
|
|
26
21
|
export * from "./functions/note/noteName.js";
|
|
27
22
|
export * from "./functions/note/source-transform.js";
|
|
28
23
|
export * from "./functions/ottava/index.js";
|
|
@@ -34,28 +29,7 @@ export * from "./functions/set/index.js";
|
|
|
34
29
|
export * from "./functions/slide/index.js";
|
|
35
30
|
export * from "./functions/stack/index.js";
|
|
36
31
|
export * from "./functions/symbol/index.js";
|
|
37
|
-
export * from "./functions/symbol/ornament.js";
|
|
38
|
-
export * from "./functions/symbol/shape.js";
|
|
39
|
-
export * from "./functions/symbol/symbols/accent.js";
|
|
40
|
-
export * from "./functions/symbol/symbols/coda.js";
|
|
41
|
-
export * from "./functions/symbol/symbols/dc.js";
|
|
42
|
-
export * from "./functions/symbol/symbols/ds.js";
|
|
43
|
-
export * from "./functions/symbol/symbols/dynamics.js";
|
|
44
|
-
export * from "./functions/symbol/symbols/fermata.js";
|
|
45
|
-
export * from "./functions/symbol/symbols/fine.js";
|
|
46
|
-
export * from "./functions/symbol/symbols/harmonic.js";
|
|
47
|
-
export * from "./functions/symbol/symbols/marcato.js";
|
|
48
|
-
export * from "./functions/symbol/symbols/mordent.js";
|
|
49
|
-
export * from "./functions/symbol/symbols/prall.js";
|
|
50
|
-
export * from "./functions/symbol/symbols/segno.js";
|
|
51
|
-
export * from "./functions/symbol/symbols/staccato.js";
|
|
52
|
-
export * from "./functions/symbol/symbols/tenuto.js";
|
|
53
|
-
export * from "./functions/symbol/symbols/tocoda.js";
|
|
54
|
-
export * from "./functions/symbol/symbols/tr.js";
|
|
55
|
-
export * from "./functions/symbol/symbols/turn.js";
|
|
56
|
-
export * from "./functions/symbol/symbols/wheel.js";
|
|
57
32
|
export * from "./functions/tempo/index.js";
|
|
58
|
-
export * from "./functions/tempo/glyph.js";
|
|
59
33
|
export * from "./functions/text/index.js";
|
|
60
34
|
export * from "./functions/tie/index.js";
|
|
61
35
|
export * from "./functions/tremolo/index.js";
|
|
@@ -63,7 +37,7 @@ export * from "./functions/tuplet/index.js";
|
|
|
63
37
|
export * from "./functions/up/index.js";
|
|
64
38
|
export * from "./functions/voice/voice.js";
|
|
65
39
|
export * from "./functions/voice/voices.js";
|
|
66
|
-
export
|
|
40
|
+
export { parseConnections, resolveConnections, serializeConnections, } from "./functions/voice/connections.js";
|
|
67
41
|
export * from "./functions/voice/lyrics.js";
|
|
68
42
|
export * from "./functions/volta/index.js";
|
|
69
43
|
export * from "./diagnostic.js";
|
|
@@ -78,20 +52,18 @@ export * from "./parser/parse-utils/label-utils.js";
|
|
|
78
52
|
export * from "./parser/parse-utils/length-utils.js";
|
|
79
53
|
export * from "./parser/parse-utils/note-utils.js";
|
|
80
54
|
export * from "./parser/parse-utils/string-utils.js";
|
|
81
|
-
export { quote as quoteSourceString } from "./parser/parse-utils/string-utils.js";
|
|
82
55
|
export * from "./lowering/types.js";
|
|
83
56
|
export * from "./lowering/loweringContext.js";
|
|
84
57
|
export * from "./lowering/track.js";
|
|
58
|
+
export * from "./lowering/accidentalMemory.js";
|
|
85
59
|
export * from "./playback/types.js";
|
|
86
|
-
export * from "./playback/event.js";
|
|
87
60
|
export * from "./playback/time.js";
|
|
88
61
|
export * from "./playback/compile.js";
|
|
89
62
|
export * from "./layout/types.js";
|
|
90
63
|
export * from "./layout/model.js";
|
|
91
64
|
export * from "./layout/default.js";
|
|
92
|
-
export
|
|
65
|
+
export { DEFAULT_PAGE_CONFIG, normalizePageConfig, paginateLayoutLines, } from "./layout/page.js";
|
|
93
66
|
export * from "./layout/engine.js";
|
|
94
67
|
export * from "./layout/path.js";
|
|
95
68
|
export * from "./layout/range.js";
|
|
96
69
|
export * from "./render/index.js";
|
|
97
|
-
export * from "./render/translate.js";
|