Skip to content

Commit 1f4e0f4

Browse files
committed
fix: alphatab event registration hook
1 parent 3eb4d4a commit 1f4e0f4

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

package-lock.json

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"generate-alphatabdoc": "tsx scripts/generate-alphatabdoc.mts"
1717
},
1818
"dependencies": {
19-
"@coderline/alphatab": "^1.7.0-alpha.1452",
19+
"@coderline/alphatab": "^1.6.2",
2020
"@docusaurus/core": "^3.7.0",
2121
"@docusaurus/preset-classic": "^3.7.0",
2222
"@docusaurus/theme-mermaid": "^3.7.0",

src/components/AlphaTabPlayground/index.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,6 @@ export const AlphaTabPlayground: React.FC = () => {
142142
if (!api) {
143143
return;
144144
}
145-
146145
api.pause();
147146
switch (mediaType.type) {
148147
case MediaType.Synth:
@@ -202,7 +201,7 @@ export const AlphaTabPlayground: React.FC = () => {
202201

203202
break;
204203
}
205-
}, [api, mediaType]);
204+
}, [api, mediaType.type]);
206205

207206
return (
208207
<>

src/hooks.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ export function useAlphaTabEvent<
5757
api[event].off(handler as any);
5858
};
5959
}
60-
}, [api, event, handler, ...(deps ?? [])]);
60+
}, [api, event, ...(deps ?? [])]);
6161
}
6262

6363
export const useIsMount = () => {

0 commit comments

Comments
 (0)