barmark 0.24.0 → 0.25.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 +20 -1
- package/dist/chords/parse.js +2 -2
- package/dist/chords/vocabulary.d.ts +7 -3
- package/dist/chords/vocabulary.js +11 -7
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -9,6 +9,24 @@ Releases follow the process in [RELEASING.md](RELEASING.md).
|
|
|
9
9
|
|
|
10
10
|
## [Unreleased]
|
|
11
11
|
|
|
12
|
+
## [0.25.0] - 2026-11-19
|
|
13
|
+
|
|
14
|
+
Grammar changes: more spellings of the major seventh (Kevin, 2026-11-18).
|
|
15
|
+
No chord that read before changes meaning.
|
|
16
|
+
|
|
17
|
+
### Added
|
|
18
|
+
|
|
19
|
+
- **More spellings of the major seventh** (Kevin, 2026-11-18, with
|
|
20
|
+
Claude's rulings the same day; grammar decisions log): `Maj` and `ma`
|
|
21
|
+
before 9 and 13 as before 7 (`CMaj9` and `Cma9` are `Cmaj9`, `Cma13` is
|
|
22
|
+
`Cmaj13`); the delta after `m`, `-` or `min` (`CmΔ`, `C-Δ7` and `CminΔ`
|
|
23
|
+
are `Cmmaj7`, `CmΔ9` is `Cmmaj9`); and the increment sign `∆` (a Mac's
|
|
24
|
+
Option-J) and the triangles `△` and `▵` as the delta (`C∆7` is `Cmaj7`,
|
|
25
|
+
`Cm△9` is `Cmmaj9`), each with whatever may follow its canonical
|
|
26
|
+
spelling (`CMaj9(#11)`, `CmΔ/Eb`). They print canonically. `Δ11`,
|
|
27
|
+
`Maj11`, `mΔ13`, `CmMaj7` and `Cmma7` stay errors, and no chord that
|
|
28
|
+
read before changes.
|
|
29
|
+
|
|
12
30
|
## [0.24.0] - 2026-11-14
|
|
13
31
|
|
|
14
32
|
Grammar changes: the flat sixth, `add` before any tone, and `Δ9`/`Δ13`
|
|
@@ -911,7 +929,8 @@ The first working release: the reference parser and printer for the
|
|
|
911
929
|
|
|
912
930
|
- **A placeholder package that holds the `barmark` name** while the spec and parser are written.
|
|
913
931
|
|
|
914
|
-
[Unreleased]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.
|
|
932
|
+
[Unreleased]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.25.0...HEAD
|
|
933
|
+
[0.25.0]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.24.0...barmark-v0.25.0
|
|
915
934
|
[0.24.0]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.23.1...barmark-v0.24.0
|
|
916
935
|
[0.23.1]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.23.0...barmark-v0.23.1
|
|
917
936
|
[0.23.0]: https://github.com/kevinpeckham/barmark/compare/barmark-v0.22.0...barmark-v0.23.0
|
package/dist/chords/parse.js
CHANGED
|
@@ -141,8 +141,8 @@ function aliased(rest) {
|
|
|
141
141
|
rest = rest.replace(pattern, replacement);
|
|
142
142
|
return rest;
|
|
143
143
|
}
|
|
144
|
-
/** The text a symbol is read from: ♯ and ♭ as # and b (Appendix A.5). */
|
|
145
|
-
const ascii = (symbol) => symbol.replace(/♯/g, "#").replace(/♭/g, "b");
|
|
144
|
+
/** The text a symbol is read from: ♯ and ♭ as # and b, ∆ △ ▵ as Δ (Appendix A.5). */
|
|
145
|
+
const ascii = (symbol) => symbol.replace(/♯/g, "#").replace(/♭/g, "b").replace(/[∆△▵]/g, "Δ");
|
|
146
146
|
/** Appendix A.5 and A.6: rejections, then aliases into canonical vocabulary. */
|
|
147
147
|
function normalizeSymbol(text) {
|
|
148
148
|
const rejected = rejection(text, noteSemitone);
|
|
@@ -49,9 +49,13 @@ export declare function chordIntervals(parts: ChordParts, symbol: string): {
|
|
|
49
49
|
alteredOpen: boolean;
|
|
50
50
|
};
|
|
51
51
|
/**
|
|
52
|
-
* Appendix A.5, applied in this order after ♯/♭ become #/b
|
|
53
|
-
*
|
|
54
|
-
* own accidental.
|
|
52
|
+
* Appendix A.5, applied in this order after ♯/♭ become #/b and the
|
|
53
|
+
* increment sign and the triangles become Δ. Each pattern reads the text
|
|
54
|
+
* after the root, so a rule can never touch the root's own accidental.
|
|
55
|
+
* `ma` is read only at the start, before `min` and `-` become `m`, so it
|
|
56
|
+
* is never an alias after `m`, `-` or `min` (`Cmma7` stays an error); the
|
|
57
|
+
* delta is read after, so it follows any of the three. `Maj` after them
|
|
58
|
+
* (`CmMaj7`) is not an alias: Kevin, 2026-11-09.
|
|
55
59
|
*/
|
|
56
60
|
export declare const ALIASES: [RegExp, string][];
|
|
57
61
|
/** Appendix A.6: a rejection with its suggestion, or null when the symbol is not one. */
|
|
@@ -134,23 +134,27 @@ export function chordIntervals(parts, symbol) {
|
|
|
134
134
|
return { intervals, warnings, alteredOpen: parts.extension === "7alt" };
|
|
135
135
|
}
|
|
136
136
|
/**
|
|
137
|
-
* Appendix A.5, applied in this order after ♯/♭ become #/b
|
|
138
|
-
*
|
|
139
|
-
* own accidental.
|
|
137
|
+
* Appendix A.5, applied in this order after ♯/♭ become #/b and the
|
|
138
|
+
* increment sign and the triangles become Δ. Each pattern reads the text
|
|
139
|
+
* after the root, so a rule can never touch the root's own accidental.
|
|
140
|
+
* `ma` is read only at the start, before `min` and `-` become `m`, so it
|
|
141
|
+
* is never an alias after `m`, `-` or `min` (`Cmma7` stays an error); the
|
|
142
|
+
* delta is read after, so it follows any of the three. `Maj` after them
|
|
143
|
+
* (`CmMaj7`) is not an alias: Kevin, 2026-11-09.
|
|
140
144
|
*/
|
|
141
145
|
export const ALIASES = [
|
|
142
|
-
[/^Δ9/, "maj9"],
|
|
143
|
-
[/^Δ13/, "maj13"],
|
|
144
|
-
[/^Δ7?/, "maj7"],
|
|
145
146
|
[/^ø7?/, "m7(b5)"],
|
|
146
147
|
[/^°7/, "dim7"],
|
|
147
148
|
[/^°/, "dim"],
|
|
148
149
|
[/^\+7/, "aug7"],
|
|
149
150
|
[/^\+/, "aug"],
|
|
150
151
|
[/^(minmaj7|m\(maj7\))/, "mmaj7"],
|
|
151
|
-
[/^(
|
|
152
|
+
[/^(Maj|ma)(?=7|9|13)/, "maj"],
|
|
152
153
|
[/^min/, "m"],
|
|
153
154
|
[/^-/, "m"],
|
|
155
|
+
[/^(m?)Δ9/, "$1maj9"],
|
|
156
|
+
[/^(m?)Δ13/, "$1maj13"],
|
|
157
|
+
[/^(m?)Δ7?/, "$1maj7"],
|
|
154
158
|
[/^maj(?=$|\/)/, ""],
|
|
155
159
|
[/sus(?![24])/, "sus4"],
|
|
156
160
|
];
|