@dsebastien/music-notation 0.13.0 → 0.14.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 +2 -2
- package/dist/index.js +661 -431
- package/dist/index.js.map +9 -7
- package/dist/music-notation.css +93 -50
- package/dist/music-notation.publish.min.js +120 -77
- package/dist/music-notation.tab.min.js +94 -51
- package/dist/playback/bar-parts.d.ts +46 -0
- package/dist/playback/block-bar.d.ts +80 -0
- package/dist/playback/controls.d.ts +32 -9
- package/dist/playback/progression-bar.d.ts +3 -2
- package/dist/playback/strum-bar.d.ts +4 -4
- package/dist/publish/index.js +568 -381
- package/dist/publish/index.js.map +9 -7
- package/dist/render/dom.d.ts +2 -0
- package/dist/tab/index.js +2 -1
- package/dist/tab/index.js.map +3 -3
- package/dist/voicings/index.js +2 -1
- package/dist/voicings/index.js.map +3 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -158,7 +158,7 @@ if (!result.ok) console.warn(result.error)
|
|
|
158
158
|
|
|
159
159
|
- `renderBlock(language, source, host, options)` appends the rendering to `host` and never throws. It returns `{ ok, el, error, destroy() }`.
|
|
160
160
|
- `@dsebastien/music-notation/voicings` adds about 1,800 guitar voicings, found by chord symbol (`chord` blocks with only a symbol). It's a separate entry point because the data weighs about 230 KB.
|
|
161
|
-
- **Hear the diagrams**: the `play` option
|
|
161
|
+
- **Hear the diagrams**: with the `play` option, a click on a diagram plays it and a click on a dot or a key plays that note; one bar under each block plays the selected diagram or all of them in turn, with loop, speed and the sound (the volume is the app's setting). Guitar chords strum, piano chords strike as a block, scales run from their tonic up and back. While it plays, each note lights up on the drawing when you hear it.
|
|
162
162
|
- **Strumming patterns**: `strum` blocks draw a pattern (`D DU UDU`, `D - D U - U D U`) on a beat grid with counts, accents, muted and ghost strums and chord changes; with playback on, they play over their chords, with loop, tempo and a count-in. `playStrum(pattern, { bpm, chord, tuning })` plays one from code.
|
|
163
163
|
- **Practice in time**: `progression` blocks and ChordPro charts get a bar that plays their chords in time, one chord a bar (or as a chart's bar lines say), with a metronome click, a count-in and a loop. Each chord is strummed on the beats, once a bar, as an arpeggio or to a strumming pattern, and the chord playing lights up. `playProgression(chords, { bpm, strum, pattern, click, countIn, loop })` does it from code, with your own player.
|
|
164
164
|
- **Harmonize a scale**: a `progression` block with `harmonize: triads`, `sevenths`, `sus` or `power` and any 7-note scale as its `key:` (`A harmonic minor`, `D dorian`) draws the chord on each degree with its numeral and a diagram, ready to play in time. `harmonize(scale, { kind })` gives the same chords from code.
|
|
@@ -184,7 +184,7 @@ Add this to your site's `publish.js`. It loads the bundle only on pages that hav
|
|
|
184
184
|
|
|
185
185
|
```js
|
|
186
186
|
;(() => {
|
|
187
|
-
const VERSION = '0.
|
|
187
|
+
const VERSION = '0.13.0'
|
|
188
188
|
const CDN = `https://cdn.jsdelivr.net/npm/@dsebastien/music-notation@${VERSION}/dist`
|
|
189
189
|
const selector = (languages) => languages.map((l) => `pre > code.language-${l}`).join(', ')
|
|
190
190
|
const BLOCKS = selector([
|