-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Decoupled visualizer from MinimlAudioPlayer a little (wrote a composa…
…ble to pass audio el), rest of decoupling was just bad logic, no need to call methods from MinimlAudioPlayer on the visualizer, fixed the logic around previous and next buttons, now if you hit previous or next in paused mode you go to next track without playing it, unless you are in play mode, so all play is controlled by play pause buttons
- Loading branch information
1 parent
3ad3c13
commit 7e7828f
Showing
8 changed files
with
93 additions
and
72 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+8.37 MB
...o/Stockholm Syndrome, Young Squage - Hysteria (feat. Stockholm Syndrome) (Radio Edit).mp3
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { shallowRef, toRef, type ShallowRef } from "vue"; | ||
import type { Ref } from "vue"; | ||
|
||
const store: Ref<Record<string, ShallowRef<HTMLElement | null>>> = shallowRef({}) | ||
|
||
export const useStoreRef = () => { | ||
|
||
const addElem = (key: string, el: ShallowRef<HTMLElement | null>) => { | ||
store.value[key] = el; | ||
} | ||
|
||
const getElem = (key: string) => { | ||
const sRef = toRef(store.value[key]) | ||
return { sRef } | ||
} | ||
|
||
return { addElem, getElem }; | ||
} | ||
|
||
|
||
|