@tspro/web-music-score 5.0.0 → 5.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/CHANGELOG.md +27 -0
- package/README.md +16 -13
- package/dist/audio/index.d.mts +15 -2
- package/dist/audio/index.d.ts +16 -3
- package/dist/audio/index.js +37 -78
- package/dist/audio/index.mjs +34 -68
- package/dist/audio-cg/index.d.mts +6 -1
- package/dist/audio-cg/index.d.ts +6 -1
- package/dist/audio-cg/index.js +1 -1
- package/dist/audio-cg/index.mjs +3 -3
- package/dist/audio-synth/index.d.mts +15 -0
- package/dist/audio-synth/index.d.ts +15 -0
- package/dist/audio-synth/index.js +95 -0
- package/dist/audio-synth/index.mjs +58 -0
- package/dist/{chunk-AAL3CMRO.mjs → chunk-6S5BDSCM.mjs} +2 -2
- package/dist/{chunk-J3KU3U4W.mjs → chunk-LC5JMIVF.mjs} +2 -2
- package/dist/{chunk-EYFT3RWB.mjs → chunk-XUGM7SCC.mjs} +5 -6
- package/dist/core/index.js +2 -2
- package/dist/core/index.mjs +3 -3
- package/dist/{guitar-CaZJDA05.d.ts → guitar-BsSayRsH.d.ts} +1 -1
- package/dist/iife/audio-cg.global.js +9 -2
- package/dist/iife/index.global.js +11 -11
- package/dist/{music-objects-3Hxlkxy6.d.mts → music-objects-CB05XryE.d.mts} +121 -45
- package/dist/{music-objects-CI7IjsjE.d.ts → music-objects-CwPOlqFi.d.ts} +123 -47
- package/dist/{note-eA2xPPiG.d.ts → note-CgCIBwvR.d.ts} +1 -1
- package/dist/pieces/index.d.mts +1 -1
- package/dist/pieces/index.d.ts +3 -3
- package/dist/pieces/index.js +1 -1
- package/dist/pieces/index.mjs +2 -2
- package/dist/react-ui/index.d.mts +34 -15
- package/dist/react-ui/index.d.ts +38 -19
- package/dist/react-ui/index.js +41 -32
- package/dist/react-ui/index.mjs +42 -33
- package/dist/{scale-DGx3tJH4.d.ts → scale-CBW4eTz7.d.ts} +2 -2
- package/dist/score/index.d.mts +2 -2
- package/dist/score/index.d.ts +5 -5
- package/dist/score/index.js +1951 -1514
- package/dist/score/index.mjs +1664 -1226
- package/dist/{tempo-GrstpD9G.d.ts → tempo-DMt3iwz9.d.ts} +1 -1
- package/dist/theory/index.d.ts +6 -6
- package/dist/theory/index.js +3 -4
- package/dist/theory/index.mjs +3 -3
- package/package.json +12 -2
package/dist/theory/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { N as Note } from '../note-
|
|
2
|
-
export { A as Accidental, d as DefaultGuitarNoteLabel, D as DefaultPitchNotation, G as GuitarNoteLabel, e as GuitarNoteLabelList, a as NoteLetter, P as ParsedNote, b as PitchNotation, c as PitchNotationList, S as SymbolSet, g as getPitchNotationName, f as validateGuitarNoteLabel, v as validatePitchNotation } from '../note-
|
|
3
|
-
import { D as Degree } from '../scale-
|
|
4
|
-
export { b as Interval, I as IntervalDirection, a as IntervalQuality, c as Scale, d as ScaleFactory, S as ScaleType, i as getDefaultScale, h as getScale, e as getScaleFactory, g as getScaleFactoryList, v as validateIntervalQuality, f as validateScaleType } from '../scale-
|
|
5
|
-
export { D as DefaultHandedness, a as DefaultTuningName, H as Handedness, T as TuningNameList, g as getTuningStrings, v as validateHandedness, b as validateTuningName } from '../guitar-
|
|
6
|
-
export { A as AccidentalType, B as BeamGrouping, K as KeySignature, M as Mode, N as NoteLength, j as NoteLengthProps, i as NoteLengthStr, R as RhythmProps, d as Tempo, b as TimeSignature, a as TimeSignatureString, T as TimeSignatures, m as Tuplet, k as TupletRatio, h as alterTempoSpeed, g as getDefaultKeySignature, e as getDefaultTempo, c as getDefaultTimeSignature, f as getTempoString, v as validateNoteLength, l as validateTupletRatio } from '../tempo-
|
|
1
|
+
import { N as Note } from '../note-CgCIBwvR.js';
|
|
2
|
+
export { A as Accidental, d as DefaultGuitarNoteLabel, D as DefaultPitchNotation, G as GuitarNoteLabel, e as GuitarNoteLabelList, a as NoteLetter, P as ParsedNote, b as PitchNotation, c as PitchNotationList, S as SymbolSet, g as getPitchNotationName, f as validateGuitarNoteLabel, v as validatePitchNotation } from '../note-CgCIBwvR.js';
|
|
3
|
+
import { D as Degree } from '../scale-CBW4eTz7.js';
|
|
4
|
+
export { b as Interval, I as IntervalDirection, a as IntervalQuality, c as Scale, d as ScaleFactory, S as ScaleType, i as getDefaultScale, h as getScale, e as getScaleFactory, g as getScaleFactoryList, v as validateIntervalQuality, f as validateScaleType } from '../scale-CBW4eTz7.js';
|
|
5
|
+
export { D as DefaultHandedness, a as DefaultTuningName, H as Handedness, T as TuningNameList, g as getTuningStrings, v as validateHandedness, b as validateTuningName } from '../guitar-BsSayRsH.js';
|
|
6
|
+
export { A as AccidentalType, B as BeamGrouping, K as KeySignature, M as Mode, N as NoteLength, j as NoteLengthProps, i as NoteLengthStr, R as RhythmProps, d as Tempo, b as TimeSignature, a as TimeSignatureString, T as TimeSignatures, m as Tuplet, k as TupletRatio, h as alterTempoSpeed, g as getDefaultKeySignature, e as getDefaultTempo, c as getDefaultTimeSignature, f as getTempoString, v as validateNoteLength, l as validateTupletRatio } from '../tempo-DMt3iwz9.js';
|
|
7
7
|
|
|
8
8
|
/** Chord info type. */
|
|
9
9
|
type ChordInfo = {
|
package/dist/theory/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* WebMusicScore v5.
|
|
1
|
+
/* WebMusicScore v5.2.0 | (c) 2023 PahkaSoft | MIT License | Includes: Tone.js (MIT License) */
|
|
2
2
|
"use strict";
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -1882,7 +1882,6 @@ var import_ts_utils_lib9 = require("@tspro/ts-utils-lib");
|
|
|
1882
1882
|
// src/theory/rhythm.ts
|
|
1883
1883
|
var import_ts_utils_lib8 = require("@tspro/ts-utils-lib");
|
|
1884
1884
|
var import_core8 = require("@tspro/web-music-score/core");
|
|
1885
|
-
var cmp = (a, b) => a === b ? 0 : a < b ? -1 : 1;
|
|
1886
1885
|
var MaxTupletRatioValue = 12;
|
|
1887
1886
|
var TicksMultiplier = 12 * 11 * 9 * 7 * 5;
|
|
1888
1887
|
var NoteLength = /* @__PURE__ */ ((NoteLength3) => {
|
|
@@ -1998,7 +1997,7 @@ var _NoteLengthProps = class _NoteLengthProps {
|
|
|
1998
1997
|
static cmp(a, b) {
|
|
1999
1998
|
let aNoteSize = a instanceof _NoteLengthProps ? a.noteSize : typeof a === "number" ? a : _NoteLengthProps.get(a).noteSize;
|
|
2000
1999
|
let bNoteSize = b instanceof _NoteLengthProps ? b.noteSize : typeof b === "number" ? b : _NoteLengthProps.get(b).noteSize;
|
|
2001
|
-
return cmp(bNoteSize, aNoteSize);
|
|
2000
|
+
return import_ts_utils_lib8.Utils.Math.cmp(bNoteSize, aNoteSize);
|
|
2002
2001
|
}
|
|
2003
2002
|
/**
|
|
2004
2003
|
* Compare note lengths/sizes for equality.
|
|
@@ -2113,7 +2112,7 @@ var _RhythmProps = class _RhythmProps {
|
|
|
2113
2112
|
* @returns - -1: a < b, 0: a === b, +1: a > b (duration comparisons)
|
|
2114
2113
|
*/
|
|
2115
2114
|
static cmp(a, b) {
|
|
2116
|
-
return cmp(a.ticks, b.ticks);
|
|
2115
|
+
return import_ts_utils_lib8.Utils.Math.cmp(a.ticks, b.ticks);
|
|
2117
2116
|
}
|
|
2118
2117
|
/**
|
|
2119
2118
|
* Compare duration equality of rhythm props.
|
package/dist/theory/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* WebMusicScore v5.
|
|
1
|
+
/* WebMusicScore v5.2.0 | (c) 2023 PahkaSoft | MIT License | Includes: Tone.js (MIT License) */
|
|
2
2
|
import {
|
|
3
3
|
NoteLength,
|
|
4
4
|
NoteLengthProps,
|
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
Tuplet,
|
|
7
7
|
validateNoteLength,
|
|
8
8
|
validateTupletRatio
|
|
9
|
-
} from "../chunk-
|
|
9
|
+
} from "../chunk-XUGM7SCC.mjs";
|
|
10
10
|
import {
|
|
11
11
|
__publicField
|
|
12
|
-
} from "../chunk-
|
|
12
|
+
} from "../chunk-LC5JMIVF.mjs";
|
|
13
13
|
|
|
14
14
|
// src/theory/chord.ts
|
|
15
15
|
import { Utils as Utils6 } from "@tspro/ts-utils-lib";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tspro/web-music-score",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.2.0",
|
|
4
4
|
"author": "PahkaSoft",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
@@ -33,6 +33,16 @@
|
|
|
33
33
|
"default": "./dist/audio/index.mjs"
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
|
+
"./audio-synth": {
|
|
37
|
+
"require": {
|
|
38
|
+
"types": "./dist/audio-synth/index.d.ts",
|
|
39
|
+
"default": "./dist/audio-synth/index.js"
|
|
40
|
+
},
|
|
41
|
+
"import": {
|
|
42
|
+
"types": "./dist/audio-synth/index.d.mts",
|
|
43
|
+
"default": "./dist/audio-synth/index.mjs"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
36
46
|
"./audio-cg": {
|
|
37
47
|
"require": {
|
|
38
48
|
"types": "./dist/audio-cg/index.d.ts",
|
|
@@ -96,7 +106,7 @@
|
|
|
96
106
|
"package.json"
|
|
97
107
|
],
|
|
98
108
|
"dependencies": {
|
|
99
|
-
"@tspro/ts-utils-lib": "^1.
|
|
109
|
+
"@tspro/ts-utils-lib": "^1.8.0",
|
|
100
110
|
"tone": "^15.1.22"
|
|
101
111
|
},
|
|
102
112
|
"peerDependencies": {
|