mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-26 13:26:40 +07:00
AudioPlayer initial
This commit is contained in:
parent
d1e369f723
commit
f66825a9ea
12 changed files with 190 additions and 26 deletions
20
src/redux/player/actions.ts
Normal file
20
src/redux/player/actions.ts
Normal file
|
@ -0,0 +1,20 @@
|
|||
import { IPlayerState } from './reducer';
|
||||
import { PLAYER_ACTIONS } from './constants';
|
||||
|
||||
export const playerSetFile = (file: IPlayerState['file']) => ({
|
||||
type: PLAYER_ACTIONS.SET_FILE,
|
||||
file,
|
||||
});
|
||||
|
||||
export const playerSetStatus = (status: IPlayerState['status']) => ({
|
||||
type: PLAYER_ACTIONS.SET_STATUS,
|
||||
status,
|
||||
});
|
||||
|
||||
export const playerPlay = () => ({
|
||||
type: PLAYER_ACTIONS.PLAY,
|
||||
});
|
||||
|
||||
export const playerPause = () => ({
|
||||
type: PLAYER_ACTIONS.PAUSE,
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue