pageflow 13.1.0 → 13.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pageflow might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +17 -45
- data/Rakefile +4 -0
- data/app/assets/images/pageflow/themes/default/{player_controls/slim/scroller_mask.png → mask_bottom.png} +0 -0
- data/app/assets/javascripts/pageflow/base.js +1 -0
- data/app/assets/javascripts/pageflow/browser/request_animation_frame_support.js +3 -0
- data/app/assets/javascripts/pageflow/components.js +4 -4
- data/app/assets/javascripts/pageflow/dist/react-client.js +31320 -0
- data/app/assets/javascripts/pageflow/dist/{react.js → react-server.js} +1514 -869
- data/app/assets/javascripts/pageflow/editor/views/configuration_editors/audio.js +20 -0
- data/app/assets/javascripts/pageflow/react.js +1 -1
- data/app/assets/javascripts/pageflow/slideshow/scroller_widget.js +9 -4
- data/app/assets/javascripts/pageflow/theme.js +6 -0
- data/app/assets/stylesheets/pageflow/mixins/shadow.scss +5 -0
- data/app/assets/stylesheets/pageflow/page.scss +0 -11
- data/app/assets/stylesheets/pageflow/page_types/audio.scss +0 -4
- data/app/assets/stylesheets/pageflow/page_types/video.scss +0 -1
- data/app/assets/stylesheets/pageflow/slideshow.scss +8 -0
- data/app/assets/stylesheets/pageflow/themes/default/base.scss +1 -0
- data/app/assets/stylesheets/pageflow/themes/default/definitions.scss +1 -0
- data/app/assets/stylesheets/pageflow/themes/default/mixins/masks.scss +11 -0
- data/app/assets/stylesheets/pageflow/themes/default/page.scss +19 -0
- data/app/assets/stylesheets/pageflow/themes/default/page/content_text_margin.scss +18 -0
- data/app/assets/stylesheets/pageflow/themes/default/page/scroller.scss +5 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls.scss +2 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/shared/menu_bar.scss +6 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/slim/scroller.scss +2 -6
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform.scss +25 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform/info_box.scss +30 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform/play_button.scss +31 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform/times_display.scss +20 -0
- data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform/wave.scss +29 -0
- data/app/assets/stylesheets/pageflow/themes/default/probes.scss +3 -0
- data/app/helpers/pageflow/entries_helper.rb +10 -3
- data/app/views/layouts/pageflow/_theme_probes.html.erb +1 -0
- data/app/views/layouts/pageflow/application.html.erb +1 -0
- data/config/initializers/features.rb +1 -0
- data/config/locales/de.yml +12 -0
- data/config/locales/en.yml +12 -0
- data/lib/pageflow/version.rb +1 -1
- data/lib/tasks/pageflow_tasks.rake +11 -1
- metadata +18 -6
@@ -20,8 +20,28 @@ pageflow.ConfigurationEditorView.register('audio', {
|
|
20
20
|
});
|
21
21
|
|
22
22
|
this.tab('options', function() {
|
23
|
+
if (pageflow.features.isEnabled('waveform_player_controls')) {
|
24
|
+
this.input('audio_player_controls_variant', pageflow.SelectInputView, {
|
25
|
+
values: ['default', 'waveform']
|
26
|
+
});
|
27
|
+
}
|
28
|
+
|
29
|
+
this.input('waveform_color', pageflow.ColorInputView, {
|
30
|
+
visibleBinding: 'audio_player_controls_variant',
|
31
|
+
visibleBindingValue: 'waveform',
|
32
|
+
|
33
|
+
defaultValue: pageflow.theme.mainColor(),
|
34
|
+
swatches: usedWaveformColors()
|
35
|
+
});
|
36
|
+
|
23
37
|
this.input('autoplay', pageflow.CheckBoxInputView);
|
24
38
|
this.group('options', {canPauseAtmo: true});
|
25
39
|
});
|
40
|
+
|
41
|
+
function usedWaveformColors() {
|
42
|
+
return _.chain(pageflow.pages.map(function(page) {
|
43
|
+
return page.configuration.get('waveform_color');
|
44
|
+
})).uniq().compact().value();
|
45
|
+
}
|
26
46
|
}
|
27
47
|
});
|
@@ -13,12 +13,17 @@
|
|
13
13
|
doubleBumpThreshold: 500,
|
14
14
|
|
15
15
|
_create: function() {
|
16
|
+
this.eventListenerTarget = this.options.eventListenerTarget ?
|
17
|
+
$(this.options.eventListenerTarget) :
|
18
|
+
this.element;
|
19
|
+
|
16
20
|
this.iscroll = new IScroll(this.element[0], _.extend({
|
17
21
|
mouseWheel: true,
|
18
22
|
bounce: false,
|
19
23
|
keyBindings: true,
|
20
24
|
probeType: 2,
|
21
|
-
preventDefault: false
|
25
|
+
preventDefault: false,
|
26
|
+
eventListenerTarget: this.eventListenerTarget[0]
|
22
27
|
}, _.pick(this.options, 'freeScroll', 'scrollX', 'noMouseWheelScrollX')));
|
23
28
|
|
24
29
|
this.iscroll.disable();
|
@@ -218,7 +223,7 @@
|
|
218
223
|
allowRight = false,
|
219
224
|
startX, startY;
|
220
225
|
|
221
|
-
this.
|
226
|
+
this.eventListenerTarget.on('touchstart MSPointerDown pointerdown', _.bind(function(event) {
|
222
227
|
var point = event.originalEvent.touches ?
|
223
228
|
event.originalEvent.touches[0] : event.originalEvent;
|
224
229
|
|
@@ -233,7 +238,7 @@
|
|
233
238
|
}
|
234
239
|
}, this));
|
235
240
|
|
236
|
-
this.
|
241
|
+
this.eventListenerTarget.on('touchmove MSPointerMove pointermove', _.bind(function(event) {
|
237
242
|
var point = event.originalEvent.touches ?
|
238
243
|
event.originalEvent.touches[0] : event.originalEvent;
|
239
244
|
|
@@ -266,7 +271,7 @@
|
|
266
271
|
}
|
267
272
|
}, this));
|
268
273
|
|
269
|
-
this.
|
274
|
+
this.eventListenerTarget.on('touchend MSPointerUp pointerup', _.bind(function(event) {
|
270
275
|
var point = event.originalEvent.touches ?
|
271
276
|
event.originalEvent.changedTouches[0] : event.originalEvent;
|
272
277
|
|
@@ -79,3 +79,8 @@
|
|
79
79
|
background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iIzAwMDAwMCIgc3RvcC1vcGFjaXR5PSIwIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjElIiBzdG9wLWNvbG9yPSIjMDAwMDAwIiBzdG9wLW9wYWNpdHk9IjAiLz4KICAgIDxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iIzAwMDAwMCIgc3RvcC1vcGFjaXR5PSIwLjciLz4KICA8L2xpbmVhckdyYWRpZW50PgogIDxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIGZpbGw9InVybCgjZ3JhZC11Y2dnLWdlbmVyYXRlZCkiIC8+Cjwvc3ZnPg==);
|
80
80
|
@include linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent, $fallback: transparent);
|
81
81
|
}
|
82
|
+
|
83
|
+
@mixin shadow-bottom-inverted {
|
84
|
+
@include linear-gradient(to top, rgba(255, 255, 255, 0.7), transparent, $fallback: transparent);
|
85
|
+
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#007db9e8', endColorstr='#ffffff',GradientType=0 )
|
86
|
+
}
|
@@ -0,0 +1,11 @@
|
|
1
|
+
// scss-lint:disable VendorPrefix
|
2
|
+
|
3
|
+
@mixin mask-bottom {
|
4
|
+
-webkit-mask-image: image-url("pageflow/themes/default/mask_bottom.png");
|
5
|
+
-webkit-mask-position: bottom left;
|
6
|
+
-webkit-mask-repeat: repeat-x;
|
7
|
+
}
|
8
|
+
|
9
|
+
@mixin mask-none {
|
10
|
+
-webkit-mask-image: none;
|
11
|
+
}
|
@@ -11,6 +11,9 @@ $page-header-typography: () !default;
|
|
11
11
|
/// Typography for header tagline.
|
12
12
|
$page-header-tagline-typography: () !default;
|
13
13
|
|
14
|
+
/// Typography for header tagline in phone layout.
|
15
|
+
$page-header-tagline-phone-typography: () !default;
|
16
|
+
|
14
17
|
/// Typography for header title.
|
15
18
|
$page-header-title-typography: () !default;
|
16
19
|
|
@@ -26,6 +29,9 @@ $page-header-first-page-title-phone-typography: () !default;
|
|
26
29
|
/// Typography for header subtitle.
|
27
30
|
$page-header-subtitle-typography: () !default;
|
28
31
|
|
32
|
+
/// Typography for header subtitle in phone layout.
|
33
|
+
$page-header-subtitle-phone-typography: () !default;
|
34
|
+
|
29
35
|
/// Typography for content text.
|
30
36
|
$page-content-text-typography: () !default;
|
31
37
|
|
@@ -86,6 +92,7 @@ $page-content-text-line-height: 1.5em !default;
|
|
86
92
|
@import "./page/anchors";
|
87
93
|
@import "./page/hyphenate";
|
88
94
|
@import "./page/paddings";
|
95
|
+
@import "./page/content_text_margin";
|
89
96
|
@import "./page/scroller";
|
90
97
|
@import "./page/shadow";
|
91
98
|
|
@@ -142,6 +149,12 @@ $page-content-text-line-height: 1.5em !default;
|
|
142
149
|
letter-spacing: 0
|
143
150
|
)
|
144
151
|
);
|
152
|
+
|
153
|
+
@include phone {
|
154
|
+
@include typography(
|
155
|
+
$page-header-tagline-phone-typography
|
156
|
+
);
|
157
|
+
}
|
145
158
|
}
|
146
159
|
|
147
160
|
.title {
|
@@ -182,6 +195,12 @@ $page-content-text-line-height: 1.5em !default;
|
|
182
195
|
margin-bottom: $page-header-subtitle-margin-bottom
|
183
196
|
)
|
184
197
|
);
|
198
|
+
|
199
|
+
@include phone {
|
200
|
+
@include typography(
|
201
|
+
$page-header-subtitle-phone-typography
|
202
|
+
);
|
203
|
+
}
|
185
204
|
}
|
186
205
|
}
|
187
206
|
|
@@ -0,0 +1,18 @@
|
|
1
|
+
.contentText {
|
2
|
+
// This has to be the default behavior since all non-React pages
|
3
|
+
// still do not apply additional modifier classes to the content
|
4
|
+
// text
|
5
|
+
@include phone {
|
6
|
+
margin-bottom: 40px;
|
7
|
+
}
|
8
|
+
|
9
|
+
&-margin_none {
|
10
|
+
@include phone {
|
11
|
+
margin-bottom: 0;
|
12
|
+
}
|
13
|
+
}
|
14
|
+
|
15
|
+
&-margin_for_player_controls {
|
16
|
+
margin-bottom: 200px;
|
17
|
+
}
|
18
|
+
}
|
@@ -1,5 +1,7 @@
|
|
1
1
|
$player-controls-menu-icon-color: #fff !default;
|
2
2
|
|
3
|
+
$player-controls-menu-inverted-icon-color: #333 !default;
|
4
|
+
|
3
5
|
$player-controls-menu-popup-background-color: rgba(17, 17, 17, 0.9) !default;
|
4
6
|
|
5
7
|
$player-controls-menu-popup-link-color: #fff !default;
|
@@ -62,6 +64,10 @@ $player-controls-quality-menu-annotation-color: #ff0000 !default;
|
|
62
64
|
fill: $player-controls-menu-icon-color;
|
63
65
|
}
|
64
66
|
|
67
|
+
&-menu_bar-inverted .player_controls-menu_bar_button_icon {
|
68
|
+
fill: $player-controls-menu-inverted-icon-color;
|
69
|
+
}
|
70
|
+
|
65
71
|
&-menu_bar_button-sub_menu_visible .player_controls-quality_menu_button_icon {
|
66
72
|
@include transform(translate(-50%, -50%) rotate(40deg));
|
67
73
|
}
|
@@ -1,13 +1,9 @@
|
|
1
|
-
// scss-lint:disable VendorPrefix
|
2
|
-
|
3
1
|
%player_controls {
|
4
2
|
&-scroller-playing {
|
5
3
|
@include desktop {
|
6
4
|
bottom: 80px;
|
7
5
|
overflow: hidden;
|
8
|
-
|
9
|
-
-webkit-mask-position: bottom left;
|
10
|
-
-webkit-mask-repeat: repeat-x;
|
6
|
+
@include mask-bottom;
|
11
7
|
}
|
12
8
|
}
|
13
9
|
|
@@ -15,7 +11,7 @@
|
|
15
11
|
&-scroller-fading {
|
16
12
|
@include desktop {
|
17
13
|
bottom: 0;
|
18
|
-
|
14
|
+
@include mask-none;
|
19
15
|
}
|
20
16
|
}
|
21
17
|
}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
@import "./waveform/info_box";
|
2
|
+
@import "./waveform/play_button";
|
3
|
+
@import "./waveform/times_display";
|
4
|
+
@import "./waveform/wave";
|
5
|
+
|
6
|
+
.waveform_player_controls {
|
7
|
+
position: absolute;
|
8
|
+
left: 0;
|
9
|
+
right: 0;
|
10
|
+
bottom: 0;
|
11
|
+
z-index: 2;
|
12
|
+
pointer-events: none;
|
13
|
+
|
14
|
+
@include shadow-bottom;
|
15
|
+
|
16
|
+
&-inverted {
|
17
|
+
@include shadow-bottom-inverted;
|
18
|
+
}
|
19
|
+
|
20
|
+
&-container {
|
21
|
+
padding-top: 10px;
|
22
|
+
margin-bottom: 55px;
|
23
|
+
width: 100%;
|
24
|
+
}
|
25
|
+
}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
$waveform-player-controls-info-box-typography: () !default;
|
2
|
+
|
3
|
+
.waveform_player_controls {
|
4
|
+
&-info_box {
|
5
|
+
padding-left: 8%;
|
6
|
+
padding-right: 14%;
|
7
|
+
margin-top: 10px;
|
8
|
+
max-width: 900px;
|
9
|
+
|
10
|
+
&-title,
|
11
|
+
&-description {
|
12
|
+
@include typography(
|
13
|
+
$waveform-player-controls-info-box-typography, (
|
14
|
+
font-size: 1.1em,
|
15
|
+
margin: 15px 0
|
16
|
+
)
|
17
|
+
);
|
18
|
+
|
19
|
+
display: inline;
|
20
|
+
width: auto;
|
21
|
+
max-width: none;
|
22
|
+
}
|
23
|
+
|
24
|
+
&-title-with_separator:after {
|
25
|
+
content: "\2014";
|
26
|
+
display: inline;
|
27
|
+
padding: 0 5px;
|
28
|
+
}
|
29
|
+
}
|
30
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
$waveform-player-controls-play-button-fill: #fff !default;
|
2
|
+
|
3
|
+
$waveform-player-controls-play-button-stroke: #444 !default;
|
4
|
+
|
5
|
+
$waveform-player-controls-play-button-inverted-fill: #222 !default;
|
6
|
+
|
7
|
+
$waveform-player-controls-play-button-inverted-stroke: #ddd !default;
|
8
|
+
|
9
|
+
.waveform_player_controls {
|
10
|
+
&-play_button {
|
11
|
+
display: block;
|
12
|
+
position: absolute;
|
13
|
+
top: 50%;
|
14
|
+
@include transform(translateY(-50%));
|
15
|
+
left: 8%;
|
16
|
+
z-index: 2;
|
17
|
+
|
18
|
+
svg {
|
19
|
+
width: 100px;
|
20
|
+
height: 100px;
|
21
|
+
fill: $waveform-player-controls-play-button-fill;
|
22
|
+
stroke: $waveform-player-controls-play-button-stroke;
|
23
|
+
stroke-width: 3px;
|
24
|
+
}
|
25
|
+
|
26
|
+
&-inverted svg {
|
27
|
+
fill: $waveform-player-controls-play-button-inverted-fill;
|
28
|
+
stroke: $waveform-player-controls-play-button-inverted-stroke;
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|
data/app/assets/stylesheets/pageflow/themes/default/player_controls/waveform/times_display.scss
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
$waveform-player-controls-times-display-typography: ();
|
2
|
+
|
3
|
+
.waveform_player_controls-times_display {
|
4
|
+
margin-top: 10px;
|
5
|
+
padding-left: 8%;
|
6
|
+
@include standard-typography($waveform-player-controls-times-display-typography);
|
7
|
+
|
8
|
+
&-current_time,
|
9
|
+
&-duration {
|
10
|
+
display: inline;
|
11
|
+
}
|
12
|
+
|
13
|
+
&-current_time {
|
14
|
+
padding-right: 5px;
|
15
|
+
}
|
16
|
+
|
17
|
+
&-duration {
|
18
|
+
padding-left: 5px;
|
19
|
+
}
|
20
|
+
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
.waveform_player_controls {
|
2
|
+
canvas {
|
3
|
+
opacity: 0.8;
|
4
|
+
}
|
5
|
+
|
6
|
+
&-wave_wrapper {
|
7
|
+
position: absolute;
|
8
|
+
bottom: 0;
|
9
|
+
left: 20px;
|
10
|
+
right: 20px;
|
11
|
+
}
|
12
|
+
|
13
|
+
&-wave {
|
14
|
+
@extend %pageflow_widget_margin_right_max !optional;
|
15
|
+
|
16
|
+
position: relative;
|
17
|
+
z-index: 1;
|
18
|
+
pointer-events: all;
|
19
|
+
height: 70px;
|
20
|
+
|
21
|
+
@media (min-height: 600px) {
|
22
|
+
height: 150px;
|
23
|
+
}
|
24
|
+
|
25
|
+
@media (min-height: 800px) {
|
26
|
+
height: 270px;
|
27
|
+
}
|
28
|
+
}
|
29
|
+
}
|