Commit f2a0799
Adopt core's shipped types; drop drifting local duplicates
The core `@arraypress/waveform-player` v1.8.0 now ships a hand-authored
`index.d.ts`, so this wrapper no longer needs to re-declare the shared
option surface.
- Delete `src/core-module-shim.d.ts` (the loose ambient module shim that
existed only while the core had no types).
- `src/types.ts`: re-export `WaveformStyle`, `ColorPreset`, `AudioMode`,
`AudioPreload`, `ButtonAlign`, `WaveformMarker`, `WaveformPeaks` from
the core, and make `WaveformPlayerProps extend
Omit<WaveformPlayerOptions, url | callbacks>` instead of re-declaring
every field. Callbacks and `WaveformPlayerHandle.instance` are now
typed with the core's `WaveformPlayer` class. `accessibleSeek`,
`seekLabel`, `barRadius`, and gradient-array colours are exposed for
free.
- `src/WaveformPlayer.tsx`: type the callback wrappers and `instance`
getter with the (aliased) core class, and forward `accessibleSeek` /
`seekLabel` through to the player.
- Bump `@arraypress/waveform-player` peer + dev dependency to `^1.8.0`.
- CHANGELOG: add Unreleased entry.
typecheck, build (tsup), and the 19-test suite all pass.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 2398224 commit f2a0799
5 files changed
Lines changed: 111 additions & 257 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
8 | 40 | | |
9 | 41 | | |
10 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| |||
71 | 71 | | |
72 | 72 | | |
73 | 73 | | |
74 | | - | |
| 74 | + | |
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
60 | 63 | | |
61 | 64 | | |
62 | 65 | | |
| |||
111 | 114 | | |
112 | 115 | | |
113 | 116 | | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
114 | 121 | | |
115 | 122 | | |
116 | 123 | | |
| |||
244 | 251 | | |
245 | 252 | | |
246 | 253 | | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | | - | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
252 | 259 | | |
253 | | - | |
| 260 | + | |
254 | 261 | | |
255 | 262 | | |
256 | 263 | | |
| |||
307 | 314 | | |
308 | 315 | | |
309 | 316 | | |
| 317 | + | |
| 318 | + | |
310 | 319 | | |
311 | 320 | | |
312 | 321 | | |
| |||
381 | 390 | | |
382 | 391 | | |
383 | 392 | | |
384 | | - | |
| 393 | + | |
385 | 394 | | |
386 | 395 | | |
387 | 396 | | |
| |||
This file was deleted.
0 commit comments