summaryrefslogtreecommitdiff
path: root/animism-align/frontend/app/views/viewer/viewer.actions.js
diff options
context:
space:
mode:
Diffstat (limited to 'animism-align/frontend/app/views/viewer/viewer.actions.js')
-rw-r--r--animism-align/frontend/app/views/viewer/viewer.actions.js9
1 files changed, 1 insertions, 8 deletions
diff --git a/animism-align/frontend/app/views/viewer/viewer.actions.js b/animism-align/frontend/app/views/viewer/viewer.actions.js
index c1b11be..3b6fbdd 100644
--- a/animism-align/frontend/app/views/viewer/viewer.actions.js
+++ b/animism-align/frontend/app/views/viewer/viewer.actions.js
@@ -11,6 +11,7 @@ import {
import { floatInRange } from 'app/utils'
import { buildParagraphs } from 'app/utils/transcript.utils'
import { annotationFadeTimings } from 'app/utils/annotation.utils'
+import { getNextSection } from 'app/utils/viewer.utils'
const newSection = (annotation, index, mediaIndex) => ({
start_ts: annotation.start_ts,
@@ -176,14 +177,6 @@ export const toggleComponent = key => dispatch => {
dispatch({ type: types.viewer.toggle_component, key, value: !store.getState().viewer[key] })
}
-const getNextSection = section => {
- const { sections } = store.getState().viewer
- if (section.index === sections.length - 1) {
- return null
- }
- return sections[section.index + 1]
-}
-
export const reachedEndOfSection = () => dispatch => {
actions.audio.pause()
dispatch({ type: types.viewer.reached_end_of_section })