1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
|
import { mapNameToSelectOption } from 'app/utils'
export const { NODE_ENV } = process.env
export const ENV_DEVELOPMENT = NODE_ENV !== 'production'
export const ENV_PRODUCTION = NODE_ENV === 'production'
export const URLS = ENV_PRODUCTION ? {
share_url: 'https://animism.e-flux.com/episode1/',
audio: '/episode1/media/animism_episode_01.mp3',
eflux_logo: 'https://e-flux.com/',
} : {
audio: '/static/data_store/peaks/animism_episode_01_2810.mp3',
peaks: '/static/data_store/peaks/peaks.json',
text: '/static/data_store/peaks/text.txt',
eflux_logo: '/',
share_url: 'https://animism.e-flux.com/',
}
export const WAVEFORM_SIZE = 300
export const ZOOM_STEPS = [
1,
2,
3,
10,
20,
30,
60,
]
export const ZOOM_LABEL_STEPS = [
20,
60,
60,
300,
600,
600,
1200,
]
export const ZOOM_TICK_STEPS = [
5,
10,
30,
60,
60,
60,
600,
]
export const HEADER_MARGIN = 50
export const INNER_HEIGHT = window.innerHeight - HEADER_MARGIN
export const ROMAN_NUMERALS = [
'I', 'II', 'III', 'IV', 'V', 'VI', 'VII', 'VIII', 'IX', 'X',
'XI', 'XII', 'XIII', 'XIV', 'XV', 'XVI', 'XVII', 'XVIII', 'XIX', 'XX',
]
export const ANNOTATION_SELECT_LABELS = {
'section_heading': 'Chapter Title',
'heading_text': 'Heading',
'video_set_volume': '(cue) Set Volume',
'gallery_advance': '(cue) Advance Frame',
}
const mapNameToAnnotationFunction = mapNameToSelectOption(ANNOTATION_SELECT_LABELS)
export const ANNOTATION_SELECT_OPTIONS = [
{
name: "text",
options: [
'sentence',
'section_heading',
'heading_text',
'pullquote_credit',
'paragraph_end',
'footnote',
'text_plate',
].map(mapNameToAnnotationFunction)
},
{
name: "image",
options: [
'curtain',
'image',
].map(mapNameToAnnotationFunction)
},
{
name: "video",
options: [
'video',
'subtitle',
'video_set_volume',
].map(mapNameToAnnotationFunction)
},
{
name: "gallery",
options: [
'carousel',
'gallery_advance',
'grid',
'vitrine',
'gallery',
].map(mapNameToAnnotationFunction)
},
{
name: "intro",
options: [
'intro',
'subtitle',
].map(mapNameToAnnotationFunction)
},
]
export const TEXT_ANNOTATION_TYPES = new Set([
'section_heading', 'heading_text', 'sentence', 'paragraph_end', 'pullquote_credit',
'footnote', 'text_plate', 'subtitle',
])
export const MEDIA_ANNOTATION_TYPES = new Set([
'image', 'carousel', 'grid', 'gallery',
'video',
'vitrine',
])
export const MEDIA_LABEL_TYPES = {
image: 'Image Gallery',
gallery: 'Image Gallery',
carousel: 'Image Gallery',
grid: 'Image Gallery',
video: 'Video',
vitrine: 'Vitrine',
}
export const INLINE_UTILITY_ANNOTATION_TYPES = new Set([
'intro', 'schedule',
])
export const FULLSCREEN_UTILITY_ANNOTATION_TYPES = new Set([
'curtain', 'text_plate', 'subtitle',
])
export const CUE_UTILITY_ANNOTATION_TYPES = new Set([
'gallery_advance', 'video_set_volume',
])
// elements which, if fullscreen, will not disappear if the episode is paused
export const PERSISTENT_FULLSCREEN_ELEMENTS = new Set([
'video', 'gallery', 'carousel', 'vitrine',
])
export const CURTAIN_COLORS = [
{ label: 'white', backgroundColor: 'rgba(255,255,255,1.0)', textColor: '#000000' },
{ label: 'light gray', backgroundColor: 'rgba(238,238,238,1.0)', textColor: '#000000' },
{ label: 'dark blue', backgroundColor: 'rgba(26,31,51,1.0)', textColor: '#ffffff' },
{ label: 'dark gray', backgroundColor: 'rgba(34,34,34,1.0)', textColor: '#ffffff' },
{ label: 'black', backgroundColor: 'rgba(0,0,0,1.0)', textColor: '#ffffff' },
]
export const BLACK_WHITE_SELECT_OPTIONS = [
{ label: 'white', name: 'white'},
{ label: 'black', name: 'black'},
]
export const CURTAIN_STYLE_SELECT_OPTIONS = [
{ label: 'chapter heading', name: 'section_heading'},
{ label: 'video title', name: 'video_title'},
{ label: 'default', name: 'default'},
]
export const CURTAIN_COLOR_SELECT_OPTIONS = CURTAIN_COLORS.map(color => ({
label: color.label,
name: color.label,
}))
export const CURTAIN_COLOR_LOOKUP = CURTAIN_COLORS.reduce((a,b) => {
a[b.label] = b
a[b.label].name = b.label.replace(" ", "-")
return a
}, {})
export const IMAGE_BACKGROUND_SIZE_OPTIONS = [
{ label: 'Cover', name: 'cover' },
{ label: 'Contain', name: 'contain' },
{ label: '90% Width', name: '90% auto' },
{ label: '90% Height', name: 'auto 90%' },
{ label: 'Hidden', name: 'hidden' },
]
export const IMAGE_INLINE_SIZE_OPTIONS = [
{ label: 'Fullscreen', name: 'fullscreen' },
{ label: 'Normal', name: 'normal' },
{ label: 'Narrow column width', name: 'narrow-column-width' },
{ label: 'Wide column width', name: 'wide-column-width' },
]
export const DISPLAY_SIZE = 2000
export const DISPLAY_QUALITY= 80
export const THUMBNAIL_SIZE = 320
export const THUMBNAIL_QUALITY = 80
export const GROWL = {
OPENING_MESSAGE: "Start the episode by clicking play or scroll to browse on your own.",
REACHED_END_OF_FIRST_SECTION: "Click \"Next\" to advance the exhibition.",
}
export const EPILEPSY_WARNING = "WARNING: This video may potentially trigger seizures for people with photosensitive epilepsy. Viewer discretion is advised."
export const VIDEO_SCRUBBER_HIDE_DELAY = 1000
export const VIDEO_SCRUBBER_HOVER_AREA = 12 * 16 // 12 rem
|