mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-12 19:01:47 +00:00
feat(plugin): add onPlayerApiReady hook
Co-authored-by: JellyBrick <shlee1503@naver.com>
This commit is contained in:
@ -41,10 +41,7 @@ const exponentialVolume = () => {
|
||||
};
|
||||
|
||||
export default builder.createRenderer(() => ({
|
||||
onLoad() {
|
||||
return document.addEventListener('apiLoaded', exponentialVolume, {
|
||||
once: true,
|
||||
passive: true,
|
||||
});
|
||||
onPlayerApiReady() {
|
||||
exponentialVolume();
|
||||
},
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user