MCPcopy Create free account
hub / github.com/Moebytes/Frame-Player / usePlaybackSelector

Function usePlaybackSelector

reducers/playbackReducer.ts:90–124  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

88} = playbackSlice.actions
89
90export const usePlaybackSelector = () => {
91 const selector = useSelector.withTypes<StoreState>()
92 return {
93 originalSrc: selector((state) => state.playback.originalSrc),
94 forwardSrc: selector((state) => state.playback.forwardSrc),
95 reverseSrc: selector((state) => state.playback.reverseSrc),
96 subtitleSrc: selector((state) => state.playback.subtitleSrc),
97 reverse: selector((state) => state.playback.reverse),
98 speed: selector((state) => state.playback.speed),
99 preservesPitch: selector((state) => state.playback.preservesPitch),
100 duration: selector((state) => state.playback.duration),
101 prevVolume: selector((state) => state.playback.prevVolume),
102 volume: selector((state) => state.playback.volume),
103 paused: selector((state) => state.playback.paused),
104 subtitles: selector((state) => state.playback.subtitles),
105 subtitleColor: selector((state) => state.playback.subtitleColor),
106 subtitleSize: selector((state) => state.playback.subtitleSize),
107 outlineColor: selector((state) => state.playback.outlineColor),
108 outlineThickness: selector((state) => state.playback.outlineThickness),
109 originalStyle: selector((state) => state.playback.originalStyle),
110 loop: selector((state) => state.playback.loop),
111 abloop: selector((state) => state.playback.abloop),
112 loopStart: selector((state) => state.playback.loopStart),
113 loopEnd: selector((state) => state.playback.loopEnd),
114 savedLoop: selector((state) => state.playback.savedLoop),
115 stepFlag: selector((state) => state.playback.stepFlag),
116 progress: selector((state) => state.playback.progress),
117 secondsProgress: selector((state) => state.playback.secondsProgress),
118 seekTo: selector((state) => state.playback.seekTo),
119 dragging: selector((state) => state.playback.dragging),
120 abDragging: selector((state) => state.playback.abDragging),
121 dragProgress: selector((state) => state.playback.dragProgress),
122 animation: selector((state) => state.playback.animation)
123 }
124}
125
126export const usePlaybackActions = () => {
127 const dispatch = useDispatch.withTypes<StoreDispatch>()()

Callers 1

VideoPlayerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected