@internetstiftelsen/styleguide 2.22.3-beta.0.3 → 2.22.3-beta.0.32
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.
- package/dist/molecules/continue-video-guide/continue-video-guide.js +6 -6
- package/dist/molecules/glider/glider-hero.js +23 -0
- package/dist/organisms/timeline/timeline.js +17 -16
- package/dist/organisms/video-guide/video-guide.js +32 -18
- package/package.json +1 -1
- package/src/assets/.DS_Store +0 -0
- package/src/assets/video/chapters.vtt +8 -8
- package/src/assets/video/metadata.vtt +4 -1
- package/src/configurations/colors/_colors-functions.scss +2 -3
- package/src/configurations/grid/_grid.scss +9 -5
- package/src/configurations/typography/_typography.scss +9 -8
- package/src/molecules/continue-video-guide/continue-video-guide.js +6 -6
- package/src/molecules/glider/_glider-hero.scss +2 -0
- package/src/molecules/glider/glider-hero.js +23 -0
- package/src/organisms/hero/_hero--dynamic-headline.scss +19 -8
- package/src/organisms/hero/hero.config.js +1 -1
- package/src/organisms/timeline/_timeline.scss +48 -4
- package/src/organisms/timeline/timeline.js +4 -1
- package/src/organisms/video-guide/_video-guide.scss +165 -17
- package/src/organisms/video-guide/video-guide.js +32 -18
- package/src/structures/_article.scss +2 -3
- package/src/utilities/_hide.scss +4 -0
- package/src/utilities/_links.scss +11 -0
|
@@ -66,15 +66,15 @@ var ProgressRing = function (_CustomElement2) {
|
|
|
66
66
|
|
|
67
67
|
window.customElements.define('progress-ring', ProgressRing);
|
|
68
68
|
|
|
69
|
-
// Get value from
|
|
70
|
-
if (
|
|
71
|
-
var videoCurrentTime =
|
|
72
|
-
var videoDuration =
|
|
69
|
+
// Get value from localStorage if present
|
|
70
|
+
if (localStorage.getItem('InmsCurrentTime')) {
|
|
71
|
+
var videoCurrentTime = localStorage.getItem('InmsCurrentTime');
|
|
72
|
+
var videoDuration = localStorage.getItem('InmsDuration');
|
|
73
73
|
var continueElement = document.querySelector('.js-guide-continue');
|
|
74
74
|
var progressRing = document.querySelector('progress-ring');
|
|
75
75
|
var continueLink = document.querySelector('.js-guide-continue-link');
|
|
76
|
-
var guideURL =
|
|
77
|
-
var guideImage =
|
|
76
|
+
var guideURL = localStorage.getItem('InmsCurrentGuideURL');
|
|
77
|
+
var guideImage = localStorage.getItem('InmsCurrentGuideImage');
|
|
78
78
|
|
|
79
79
|
if (videoCurrentTime > 0 && progressRing && continueElement && guideImage && continueLink) {
|
|
80
80
|
var alternativeText = continueLink.dataset.altText;
|
|
@@ -19,5 +19,28 @@ if (gliderElementHero) {
|
|
|
19
19
|
}
|
|
20
20
|
});
|
|
21
21
|
|
|
22
|
+
var autoplayDelay = gliderElementHero.dataset.timeout;
|
|
23
|
+
|
|
24
|
+
if (autoplayDelay) {
|
|
25
|
+
var autoplay = setInterval(function () {
|
|
26
|
+
GliderHero.scrollItem('next');
|
|
27
|
+
}, autoplayDelay);
|
|
28
|
+
|
|
29
|
+
gliderElementHero.addEventListener('mouseover', function () {
|
|
30
|
+
if (autoplay !== null) {
|
|
31
|
+
clearInterval(autoplay);
|
|
32
|
+
autoplay = null;
|
|
33
|
+
}
|
|
34
|
+
}, 0);
|
|
35
|
+
|
|
36
|
+
gliderElementHero.addEventListener('mouseout', function () {
|
|
37
|
+
if (autoplay === null) {
|
|
38
|
+
autoplay = setInterval(function () {
|
|
39
|
+
GliderHero.scrollItem('next');
|
|
40
|
+
}, autoplayDelay);
|
|
41
|
+
}
|
|
42
|
+
}, 0);
|
|
43
|
+
}
|
|
44
|
+
|
|
22
45
|
module.exports = GliderHero;
|
|
23
46
|
}
|
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
require('../../assets/js/parallax');
|
|
4
4
|
|
|
5
|
-
function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
|
|
6
|
-
|
|
7
5
|
var _require = require('../../assets/js/offset'),
|
|
8
6
|
offsetTop = _require.offsetTop,
|
|
9
7
|
offsetBottom = _require.offsetBottom,
|
|
@@ -103,21 +101,22 @@ if (progressBar) {
|
|
|
103
101
|
}
|
|
104
102
|
|
|
105
103
|
// DUMMY TIMELINE ITEM OPEN/CLOSE
|
|
104
|
+
/*
|
|
106
105
|
function wrap(el, wrapper) {
|
|
107
106
|
el.parentNode.insertBefore(wrapper, el);
|
|
108
107
|
wrapper.classList.add('wrapper');
|
|
109
108
|
wrapper.appendChild(el);
|
|
110
109
|
}
|
|
111
110
|
|
|
112
|
-
|
|
113
|
-
|
|
111
|
+
const timeLineItems = document.querySelectorAll('.js-timeline-item');
|
|
112
|
+
let timeLineItemScrollPosition = 0;
|
|
114
113
|
|
|
115
|
-
[].forEach.call(timeLineItems,
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
114
|
+
[].forEach.call(timeLineItems, (timeLineItem) => {
|
|
115
|
+
const timeLineItemLink = timeLineItem.querySelector('a');
|
|
116
|
+
const timeLineItemClose = timeLineItem.querySelector('.js-timeline-item-close');
|
|
117
|
+
const timeLineItemBottomClose = timeLineItem.querySelector('.js-timeline-item-bottom-close');
|
|
119
118
|
|
|
120
|
-
timeLineItemLink.addEventListener('click',
|
|
119
|
+
timeLineItemLink.addEventListener('click', () => {
|
|
121
120
|
timeLineItemScrollPosition = window.pageYOffset;
|
|
122
121
|
sessionStorage.setItem('scroll-position', timeLineItemScrollPosition);
|
|
123
122
|
|
|
@@ -126,19 +125,20 @@ var timeLineItemScrollPosition = 0;
|
|
|
126
125
|
timeLineItem.closest('.row').classList.add('row-has-open-child');
|
|
127
126
|
|
|
128
127
|
// Wrap open timeline item
|
|
129
|
-
wrap(timeLineItem.querySelector('.wp-block-iis-
|
|
128
|
+
wrap(timeLineItem.querySelector('.wp-block-iis-timeline-post'),
|
|
129
|
+
document.createElement('div'));
|
|
130
130
|
}
|
|
131
131
|
});
|
|
132
132
|
|
|
133
|
-
timeLineItemClose.addEventListener('click',
|
|
133
|
+
timeLineItemClose.addEventListener('click', () => {
|
|
134
134
|
timeLineItem.classList.remove('is-open');
|
|
135
135
|
timeLineItem.closest('.row').classList.remove('row-has-open-child');
|
|
136
136
|
|
|
137
137
|
// Destroy generated wrapper
|
|
138
|
-
|
|
139
|
-
wrapper.replaceWith
|
|
138
|
+
const wrapper = timeLineItemClose.nextElementSibling;
|
|
139
|
+
wrapper.replaceWith(...wrapper.childNodes);
|
|
140
140
|
|
|
141
|
-
|
|
141
|
+
const top = sessionStorage.getItem('scroll-position');
|
|
142
142
|
if (top !== null) {
|
|
143
143
|
window.scrollTo(0, parseInt(top, 10));
|
|
144
144
|
}
|
|
@@ -148,7 +148,8 @@ var timeLineItemScrollPosition = 0;
|
|
|
148
148
|
window.dispatchEvent(new CustomEvent('scroll'));
|
|
149
149
|
});
|
|
150
150
|
|
|
151
|
-
timeLineItemBottomClose.addEventListener('click',
|
|
151
|
+
timeLineItemBottomClose.addEventListener('click', () => {
|
|
152
152
|
timeLineItemClose.click();
|
|
153
153
|
});
|
|
154
|
-
});
|
|
154
|
+
});
|
|
155
|
+
*/
|
|
@@ -17,6 +17,8 @@ var metadataTrack = trackMetadataElement === null ? '' : trackMetadataElement.tr
|
|
|
17
17
|
var forwardsButton = document.querySelector('.js-next-chapter');
|
|
18
18
|
var backwardsButton = document.querySelector('.js-previous-chapter');
|
|
19
19
|
var timelinePosts = document.querySelectorAll('.js-timeline-post');
|
|
20
|
+
var navigationButton = document.querySelector('.js-show-timelineposts');
|
|
21
|
+
var timeLinePosts = document.querySelector('.js-timeline-posts');
|
|
20
22
|
var currentChapter = 1;
|
|
21
23
|
var manualStep = false;
|
|
22
24
|
var sourceElement = null;
|
|
@@ -35,20 +37,20 @@ if (sourceElement) {
|
|
|
35
37
|
|
|
36
38
|
// Store current time in on page reload
|
|
37
39
|
window.addEventListener('unload', function () {
|
|
38
|
-
// Set
|
|
40
|
+
// Set localStorage if video has started playing
|
|
39
41
|
if (video.currentTime > 0) {
|
|
40
42
|
var currentGuideURL = window.location.href;
|
|
41
43
|
var currentGuideImage = document.querySelector('.js-guide-continue-image').src;
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
44
|
+
localStorage.setItem('InmsCurrentTime', video.currentTime);
|
|
45
|
+
localStorage.setItem('InmsDuration', video.duration); // Get totalt duration of video
|
|
46
|
+
localStorage.setItem('InmsCurrentGuideURL', currentGuideURL);
|
|
47
|
+
localStorage.setItem('InmsCurrentGuideImage', currentGuideImage);
|
|
46
48
|
}
|
|
47
49
|
});
|
|
48
50
|
|
|
49
|
-
// Get value from
|
|
50
|
-
if (
|
|
51
|
-
var videoCurrentTime =
|
|
51
|
+
// Get value from localStorage in present
|
|
52
|
+
if (localStorage.getItem('InmsCurrentTime')) {
|
|
53
|
+
var videoCurrentTime = localStorage.getItem('InmsCurrentTime');
|
|
52
54
|
|
|
53
55
|
if (videoCurrentTime > 0) {
|
|
54
56
|
video.currentTime = videoCurrentTime;
|
|
@@ -93,10 +95,10 @@ if (sourceElement) {
|
|
|
93
95
|
manualStep = false;
|
|
94
96
|
forwardsButton.removeAttribute('disabled');
|
|
95
97
|
subtitlesContainer.innerHTML = '';
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
98
|
+
localStorage.removeItem('InmsCurrentTime');
|
|
99
|
+
localStorage.removeItem('InmsDuration');
|
|
100
|
+
localStorage.removeItem('InmsCurrentGuideURL');
|
|
101
|
+
localStorage.removeItem('InmsCurrentGuideImage');
|
|
100
102
|
});
|
|
101
103
|
}
|
|
102
104
|
|
|
@@ -109,13 +111,20 @@ if (sourceElement) {
|
|
|
109
111
|
forwardsButton.removeAttribute('disabled');
|
|
110
112
|
currentChapter = 1;
|
|
111
113
|
manualStep = false;
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
114
|
+
localStorage.removeItem('InmsCurrentTime');
|
|
115
|
+
localStorage.removeItem('InmsDuration');
|
|
116
|
+
localStorage.removeItem('InmsCurrentGuideURL');
|
|
117
|
+
localStorage.removeItem('InmsCurrentGuideImage');
|
|
116
118
|
window.location.href = urlTarget;
|
|
117
119
|
});
|
|
118
120
|
}
|
|
121
|
+
|
|
122
|
+
if (navigationButton) {
|
|
123
|
+
navigationButton.addEventListener('click', function () {
|
|
124
|
+
navigationButton.classList.toggle('is-toggeled');
|
|
125
|
+
timeLinePosts.classList.toggle('is-visible');
|
|
126
|
+
});
|
|
127
|
+
}
|
|
119
128
|
}
|
|
120
129
|
|
|
121
130
|
function displayChapters() {
|
|
@@ -153,7 +162,7 @@ function displayChapters() {
|
|
|
153
162
|
});
|
|
154
163
|
|
|
155
164
|
// If not set in sessionStorgare, set first cue on forward button on page load
|
|
156
|
-
if (!
|
|
165
|
+
if (!localStorage.getItem('InmsCurrentTime')) {
|
|
157
166
|
forwardsButton.setAttribute('data-id', chapterTrack.cues[0].endTime);
|
|
158
167
|
}
|
|
159
168
|
}, 100);
|
|
@@ -253,7 +262,12 @@ function displayChapters() {
|
|
|
253
262
|
timelinePost.classList.remove('is-current');
|
|
254
263
|
});
|
|
255
264
|
|
|
256
|
-
document.
|
|
265
|
+
var idSelectors = document.querySelectorAll('[data-id="' + metadataCueMatch + '"]');
|
|
266
|
+
|
|
267
|
+
[].forEach.call(idSelectors, function (idSelector) {
|
|
268
|
+
idSelector.classList.add('is-current');
|
|
269
|
+
idSelector.focus();
|
|
270
|
+
});
|
|
257
271
|
|
|
258
272
|
if (chapterCues) {
|
|
259
273
|
var chapterStartTime = chapterCues.startTime;
|
package/package.json
CHANGED
package/src/assets/.DS_Store
CHANGED
|
Binary file
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
WEBVTT
|
|
2
2
|
|
|
3
3
|
00:00:00.000 --> 00:00:39.000
|
|
4
|
-
1 / 8: Introduktion
|
|
4
|
+
Kapitel 1 / 8: Introduktion
|
|
5
5
|
|
|
6
6
|
00:00:39.000 --> 00:01:51.500
|
|
7
|
-
2 / 8: Idén om internet
|
|
7
|
+
Kapitel 2 / 8: Idén om internet
|
|
8
8
|
|
|
9
9
|
00:01:51.500 --> 00:02:53.000
|
|
10
|
-
3 / 8: Arpanet blir till
|
|
10
|
+
Kapitel 3 / 8: Arpanet blir till
|
|
11
11
|
|
|
12
12
|
00:02:53.000 --> 00:03:27.000
|
|
13
|
-
4 / 8: TCP/IP uppfinns
|
|
13
|
+
Kapitel 4 / 8: TCP/IP uppfinns
|
|
14
14
|
|
|
15
15
|
00:03:27.000 --> 00:03:56.500
|
|
16
|
-
5 / 8: Sveriges första internetnod
|
|
16
|
+
Kapitel 5 / 8: Sveriges första internetnod
|
|
17
17
|
|
|
18
18
|
00:03:56.500 --> 00:04:34.000
|
|
19
|
-
6 / 8: Toppdomänen .se registreras
|
|
19
|
+
Kapitel 6 / 8: Toppdomänen .se registreras
|
|
20
20
|
|
|
21
21
|
00:04:34.000 --> 00:05:17.000
|
|
22
|
-
7 / 8: World Wide Web
|
|
22
|
+
Kapitel 7 / 8: World Wide Web
|
|
23
23
|
|
|
24
24
|
00:05:17.000 --> 00:06:28.000
|
|
25
|
-
8 / 8: Mosaic - den grafiska webbläsaren
|
|
25
|
+
Kapitel 8 / 8: Mosaic - den grafiska webbläsaren
|
|
@@ -76,7 +76,7 @@ $colors: (
|
|
|
76
76
|
@each $key, $value in $map {
|
|
77
77
|
&#{if($key != $base, #{$separator}#{$key}, '')} {
|
|
78
78
|
@if type-of($value) == 'map' {
|
|
79
|
-
@include color_classes($value, $attribute, $prefix, $separator: '-', $element: $element);
|
|
79
|
+
@include color_classes($value, $attribute, $prefix: '.', $separator: '-', $element: $element);
|
|
80
80
|
}
|
|
81
81
|
@else {
|
|
82
82
|
@if ($element != '') {
|
|
@@ -94,13 +94,12 @@ $colors: (
|
|
|
94
94
|
}
|
|
95
95
|
|
|
96
96
|
/// Generate wordpress color classes with attribute and value
|
|
97
|
-
/// Generates this: .has-color
|
|
97
|
+
/// Generates this: .has-colorname-color
|
|
98
98
|
/// @group Colors
|
|
99
99
|
@mixin wordpress_color_classes($map, $attribute, $separator: '-', $suffix: '', $base: 'base') {
|
|
100
100
|
@each $key, $value in $map {
|
|
101
101
|
@if type-of($value) == 'map' {
|
|
102
102
|
&#{if($key != $base, #{$separator}#{$key}, '')} {
|
|
103
|
-
content: str-replace($key, 'color-', '');
|
|
104
103
|
@include wordpress_color_classes($value, $attribute, $separator, '-color');
|
|
105
104
|
}
|
|
106
105
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
@charset 'UTF-8';
|
|
2
2
|
|
|
3
|
+
@use "sass:math";
|
|
4
|
+
|
|
3
5
|
// Grid only
|
|
4
6
|
//
|
|
5
7
|
// Includes relevant variables and mixins for the flexbox grid
|
|
@@ -83,15 +85,15 @@
|
|
|
83
85
|
}
|
|
84
86
|
|
|
85
87
|
@include bp-up(sm) {
|
|
86
|
-
$bp-gap: $gap * 1.25;
|
|
87
|
-
|
|
88
88
|
margin: rhythm($margin * 1.25) 0 0;
|
|
89
89
|
|
|
90
90
|
&:not(.asymmetric-reversed) {
|
|
91
|
+
$bp-gap: $gap * 1.25;
|
|
91
92
|
@include make-asymmetric-cols($bp-gap);
|
|
92
93
|
}
|
|
93
94
|
|
|
94
95
|
&.asymmetric-reversed {
|
|
96
|
+
$bp-gap: math.div($gap, 2);
|
|
95
97
|
@include make-asymmetric-cols($bp-gap, true);
|
|
96
98
|
}
|
|
97
99
|
}
|
|
@@ -103,30 +105,32 @@
|
|
|
103
105
|
}
|
|
104
106
|
|
|
105
107
|
@include bp-up(lg) {
|
|
106
|
-
|
|
108
|
+
|
|
107
109
|
|
|
108
110
|
margin: rhythm($margin * 1.5) 0 0;
|
|
109
111
|
|
|
110
112
|
&:not(.asymmetric-reversed) {
|
|
113
|
+
$bp-gap: $gap * 1.5;
|
|
111
114
|
@include make-asymmetric-cols($bp-gap);
|
|
112
115
|
}
|
|
113
116
|
|
|
114
117
|
&.asymmetric-reversed {
|
|
118
|
+
$bp-gap: $gap;
|
|
115
119
|
@include make-asymmetric-cols($bp-gap, true);
|
|
116
120
|
margin-bottom: calc(180px);
|
|
117
121
|
}
|
|
118
122
|
}
|
|
119
123
|
|
|
120
124
|
@include bp-up(xl) {
|
|
121
|
-
$bp-gap: $gap * 2;
|
|
122
|
-
|
|
123
125
|
margin: rhythm($margin * 2) 0 0;
|
|
124
126
|
|
|
125
127
|
&:not(.asymmetric-reversed) {
|
|
128
|
+
$bp-gap: $gap * 2;
|
|
126
129
|
@include make-asymmetric-cols($bp-gap);
|
|
127
130
|
}
|
|
128
131
|
|
|
129
132
|
&.asymmetric-reversed {
|
|
133
|
+
$bp-gap: $gap;
|
|
130
134
|
@include make-asymmetric-cols($bp-gap, true);
|
|
131
135
|
margin-bottom: calc(216px);
|
|
132
136
|
}
|
|
@@ -145,7 +145,8 @@ small {
|
|
|
145
145
|
);
|
|
146
146
|
}
|
|
147
147
|
|
|
148
|
-
.supersize
|
|
148
|
+
.supersize,
|
|
149
|
+
%supersize {
|
|
149
150
|
@include plumber(
|
|
150
151
|
$font-size: 3,
|
|
151
152
|
$line-height: 4,
|
|
@@ -178,30 +179,30 @@ small {
|
|
|
178
179
|
$leading-bottom: 0
|
|
179
180
|
);
|
|
180
181
|
|
|
181
|
-
line-height:
|
|
182
|
+
line-height: 79px;
|
|
182
183
|
font-size: 120px;
|
|
183
184
|
font-family: $font-family-bold;
|
|
184
185
|
letter-spacing: -#{rem(5px)};
|
|
185
186
|
|
|
186
187
|
@include bp-up(sm) {
|
|
187
|
-
line-height:
|
|
188
|
+
line-height: 100px;
|
|
188
189
|
font-size: 150px;
|
|
189
190
|
}
|
|
190
191
|
|
|
191
192
|
@include bp-up(md) {
|
|
192
|
-
line-height:
|
|
193
|
+
line-height: 135px;
|
|
193
194
|
font-size: 200px;
|
|
194
195
|
letter-spacing: -#{rem(10px)};
|
|
195
196
|
}
|
|
196
197
|
|
|
197
198
|
@include bp-up(lg) {
|
|
198
|
-
line-height:
|
|
199
|
+
line-height: 201px;
|
|
199
200
|
font-size: 295px;
|
|
200
201
|
letter-spacing: -#{rem(20px)};
|
|
201
202
|
}
|
|
202
203
|
|
|
203
204
|
@include bp-up(xl) {
|
|
204
|
-
line-height:
|
|
205
|
+
line-height: 247px;
|
|
205
206
|
font-size: 360px;
|
|
206
207
|
}
|
|
207
208
|
|
|
@@ -225,8 +226,8 @@ small {
|
|
|
225
226
|
%preamble {
|
|
226
227
|
|
|
227
228
|
@include plumber(
|
|
228
|
-
$font-size: 2.
|
|
229
|
-
$line-height:
|
|
229
|
+
$font-size: 2.55555,
|
|
230
|
+
$line-height: 4,
|
|
230
231
|
$leading-bottom: 4
|
|
231
232
|
);
|
|
232
233
|
|
|
@@ -55,15 +55,15 @@ class ProgressRing extends HTMLElement {
|
|
|
55
55
|
|
|
56
56
|
window.customElements.define('progress-ring', ProgressRing);
|
|
57
57
|
|
|
58
|
-
// Get value from
|
|
59
|
-
if (
|
|
60
|
-
const videoCurrentTime =
|
|
61
|
-
const videoDuration =
|
|
58
|
+
// Get value from localStorage if present
|
|
59
|
+
if (localStorage.getItem('InmsCurrentTime')) {
|
|
60
|
+
const videoCurrentTime = localStorage.getItem('InmsCurrentTime');
|
|
61
|
+
const videoDuration = localStorage.getItem('InmsDuration');
|
|
62
62
|
const continueElement = document.querySelector('.js-guide-continue');
|
|
63
63
|
const progressRing = document.querySelector('progress-ring');
|
|
64
64
|
const continueLink = document.querySelector('.js-guide-continue-link');
|
|
65
|
-
const guideURL =
|
|
66
|
-
const guideImage =
|
|
65
|
+
const guideURL = localStorage.getItem('InmsCurrentGuideURL');
|
|
66
|
+
const guideImage = localStorage.getItem('InmsCurrentGuideImage');
|
|
67
67
|
|
|
68
68
|
if ((videoCurrentTime > 0)
|
|
69
69
|
&& progressRing
|
|
@@ -13,5 +13,28 @@ if (gliderElementHero) {
|
|
|
13
13
|
},
|
|
14
14
|
});
|
|
15
15
|
|
|
16
|
+
const autoplayDelay = gliderElementHero.dataset.timeout;
|
|
17
|
+
|
|
18
|
+
if (autoplayDelay) {
|
|
19
|
+
let autoplay = setInterval(() => {
|
|
20
|
+
GliderHero.scrollItem('next');
|
|
21
|
+
}, autoplayDelay);
|
|
22
|
+
|
|
23
|
+
gliderElementHero.addEventListener('mouseover', () => {
|
|
24
|
+
if (autoplay !== null) {
|
|
25
|
+
clearInterval(autoplay);
|
|
26
|
+
autoplay = null;
|
|
27
|
+
}
|
|
28
|
+
}, 0);
|
|
29
|
+
|
|
30
|
+
gliderElementHero.addEventListener('mouseout', () => {
|
|
31
|
+
if (autoplay === null) {
|
|
32
|
+
autoplay = setInterval(() => {
|
|
33
|
+
GliderHero.scrollItem('next');
|
|
34
|
+
}, autoplayDelay);
|
|
35
|
+
}
|
|
36
|
+
}, 0);
|
|
37
|
+
}
|
|
38
|
+
|
|
16
39
|
module.exports = GliderHero;
|
|
17
40
|
}
|
|
@@ -18,6 +18,10 @@
|
|
|
18
18
|
right: 0;
|
|
19
19
|
bottom: 0;
|
|
20
20
|
z-index: -1;
|
|
21
|
+
|
|
22
|
+
@include bp-up(xxl) {
|
|
23
|
+
object-position: 50% 50%;
|
|
24
|
+
}
|
|
21
25
|
}
|
|
22
26
|
|
|
23
27
|
@include e(caption) {
|
|
@@ -32,7 +36,7 @@
|
|
|
32
36
|
|
|
33
37
|
> h1 {
|
|
34
38
|
--minFontSize: 22px;
|
|
35
|
-
--maxFontSize:
|
|
39
|
+
--maxFontSize: 200px;
|
|
36
40
|
--scaler: 10vw;
|
|
37
41
|
|
|
38
42
|
font-size: clamp( var(--minFontSize), var(--scaler), var(--maxFontSize) );
|
|
@@ -40,6 +44,14 @@
|
|
|
40
44
|
margin: 0;
|
|
41
45
|
padding: 0;
|
|
42
46
|
line-height: 1.2;
|
|
47
|
+
|
|
48
|
+
@include bp-up(md) {
|
|
49
|
+
line-height: 1.1;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
@include bp-up(lg) {
|
|
53
|
+
line-height: 1;
|
|
54
|
+
}
|
|
43
55
|
}
|
|
44
56
|
|
|
45
57
|
@include bp-up(sm-xs) {
|
|
@@ -88,7 +100,6 @@
|
|
|
88
100
|
|
|
89
101
|
@include bp-up(xxl) {
|
|
90
102
|
font-size: 24px !important;
|
|
91
|
-
margin-left: rhythm(2);
|
|
92
103
|
}
|
|
93
104
|
}
|
|
94
105
|
}
|
|
@@ -126,29 +137,29 @@
|
|
|
126
137
|
|
|
127
138
|
@keyframes pulse2 {
|
|
128
139
|
0% {
|
|
129
|
-
transform: translateY(
|
|
140
|
+
transform: translateY(0) scale(2);
|
|
130
141
|
}
|
|
131
142
|
|
|
132
143
|
50% {
|
|
133
|
-
transform: translateY(-
|
|
144
|
+
transform: translateY(-25%) scale(2);
|
|
134
145
|
}
|
|
135
146
|
|
|
136
147
|
100% {
|
|
137
|
-
transform: translateY(
|
|
148
|
+
transform: translateY(0) scale(2);
|
|
138
149
|
}
|
|
139
150
|
}
|
|
140
151
|
|
|
141
152
|
@keyframes pulse3 {
|
|
142
153
|
0% {
|
|
143
|
-
transform: translateY(
|
|
154
|
+
transform: translateY(0) scale(3);
|
|
144
155
|
}
|
|
145
156
|
|
|
146
157
|
50% {
|
|
147
|
-
transform: translateY(-
|
|
158
|
+
transform: translateY(-25%) scale(3);
|
|
148
159
|
}
|
|
149
160
|
|
|
150
161
|
100% {
|
|
151
|
-
transform: translateY(
|
|
162
|
+
transform: translateY(0) scale(3);
|
|
152
163
|
}
|
|
153
164
|
}
|
|
154
165
|
|
|
@@ -1,6 +1,19 @@
|
|
|
1
1
|
@charset "UTF-8";
|
|
2
2
|
|
|
3
|
+
@keyframes smoothscroll1 {
|
|
4
|
+
from, to { scroll-behavior: smooth; }
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
@keyframes smoothscroll2 {
|
|
8
|
+
from, to { scroll-behavior: smooth; }
|
|
9
|
+
}
|
|
10
|
+
|
|
3
11
|
html {
|
|
12
|
+
animation: smoothscroll1 1s;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
html:focus-within {
|
|
16
|
+
animation-name: smoothscroll2;
|
|
4
17
|
scroll-behavior: smooth;
|
|
5
18
|
}
|
|
6
19
|
|
|
@@ -118,7 +131,7 @@ html {
|
|
|
118
131
|
transition: opacity 1s ease-out, transform 5s cubic-bezier(0, 1, 0, 1);
|
|
119
132
|
transform: translateY(200px);
|
|
120
133
|
will-change: opacity, transform;
|
|
121
|
-
transition-delay: 0.
|
|
134
|
+
//transition-delay: 0.25s;
|
|
122
135
|
flex: 100%;
|
|
123
136
|
|
|
124
137
|
&.animate {
|
|
@@ -135,6 +148,20 @@ html {
|
|
|
135
148
|
display: none;
|
|
136
149
|
padding-bottom: 0;
|
|
137
150
|
margin-top: 0;
|
|
151
|
+
min-height: 45px;
|
|
152
|
+
background-image: url("data:image/svg+xml,%3Csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='xMidYMid' class='lds-ring' style='background: none;'%3E%3Ccircle cx='50' cy='50' ng-attr-r='%7B%7Bconfig.radius%7D%7D' ng-attr-stroke='%7B%7Bconfig.base%7D%7D' ng-attr-stroke-width='%7B%7Bconfig.width%7D%7D' fill='none' r='43' stroke='%23a7d8fd' stroke-width='7'%3E%3C/circle%3E%3Ccircle cx='50' cy='50' ng-attr-r='%7B%7Bconfig.radius%7D%7D' ng-attr-stroke='%7B%7Bconfig.stroke%7D%7D' ng-attr-stroke-width='%7B%7Bconfig.innerWidth%7D%7D' ng-attr-stroke-linecap='%7B%7Bconfig.linecap%7D%7D' fill='none' r='43' stroke='%2350b2fc' stroke-width='7' stroke-linecap='square' transform='rotate(27.6965 50 50)'%3E%3CanimateTransform attributeName='transform' type='rotate' calcMode='linear' values='0 50 50;180 50 50;720 50 50' keyTimes='0;0.5;1' dur='2.5s' begin='0s' repeatCount='indefinite'%3E%3C/animateTransform%3E%3Canimate attributeName='stroke-dasharray' calcMode='linear' values='9.42477796076938 179.0707812546182;188.4955592153876 -2.842170943040401e-14;9.42477796076938 179.0707812546182' keyTimes='0;0.5;1' dur='2.5' begin='0s' repeatCount='indefinite'%3E%3C/animate%3E%3C/circle%3E%3C/svg%3E%0A");
|
|
153
|
+
background-repeat: no-repeat;
|
|
154
|
+
background-position: center center;
|
|
155
|
+
background-size: 45px 45px;
|
|
156
|
+
|
|
157
|
+
@include bp-up(lg) {
|
|
158
|
+
min-height: 100px;
|
|
159
|
+
background-size: 100px 100px;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
&[data-timeline-post-expanded-content="true"] {
|
|
163
|
+
background-image: none;
|
|
164
|
+
}
|
|
138
165
|
|
|
139
166
|
@include e(meta) {
|
|
140
167
|
@include e(related) {
|
|
@@ -176,9 +203,26 @@ html {
|
|
|
176
203
|
h3,
|
|
177
204
|
h4,
|
|
178
205
|
p,
|
|
179
|
-
|
|
180
|
-
|
|
206
|
+
li,
|
|
207
|
+
dt,
|
|
208
|
+
dd {
|
|
209
|
+
color: $color-snow;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
p a,
|
|
213
|
+
li a,
|
|
214
|
+
dt a,
|
|
215
|
+
dd a,
|
|
216
|
+
h1 a,
|
|
217
|
+
h2 a,
|
|
218
|
+
h3 a,
|
|
219
|
+
h4 a {
|
|
181
220
|
color: $color-snow;
|
|
221
|
+
|
|
222
|
+
&:hover,
|
|
223
|
+
&:focus {
|
|
224
|
+
color: $color-cyberspace;
|
|
225
|
+
}
|
|
182
226
|
}
|
|
183
227
|
|
|
184
228
|
a[data-scroll-ignore] {
|
|
@@ -203,7 +247,7 @@ html {
|
|
|
203
247
|
@extend %preamble;
|
|
204
248
|
}
|
|
205
249
|
|
|
206
|
-
.wp-block-iis-
|
|
250
|
+
.wp-block-iis-timeline-post {
|
|
207
251
|
margin-left: auto;
|
|
208
252
|
margin-right: auto;
|
|
209
253
|
|
|
@@ -95,6 +95,7 @@ if (progressBar) {
|
|
|
95
95
|
}
|
|
96
96
|
|
|
97
97
|
// DUMMY TIMELINE ITEM OPEN/CLOSE
|
|
98
|
+
/*
|
|
98
99
|
function wrap(el, wrapper) {
|
|
99
100
|
el.parentNode.insertBefore(wrapper, el);
|
|
100
101
|
wrapper.classList.add('wrapper');
|
|
@@ -118,7 +119,8 @@ let timeLineItemScrollPosition = 0;
|
|
|
118
119
|
timeLineItem.closest('.row').classList.add('row-has-open-child');
|
|
119
120
|
|
|
120
121
|
// Wrap open timeline item
|
|
121
|
-
wrap(timeLineItem.querySelector('.wp-block-iis-
|
|
122
|
+
wrap(timeLineItem.querySelector('.wp-block-iis-timeline-post'),
|
|
123
|
+
document.createElement('div'));
|
|
122
124
|
}
|
|
123
125
|
});
|
|
124
126
|
|
|
@@ -144,3 +146,4 @@ let timeLineItemScrollPosition = 0;
|
|
|
144
146
|
timeLineItemClose.click();
|
|
145
147
|
});
|
|
146
148
|
});
|
|
149
|
+
*/
|
|
@@ -1,14 +1,26 @@
|
|
|
1
1
|
@charset "UTF-8";
|
|
2
2
|
|
|
3
|
-
@include
|
|
3
|
+
@include organism(video-guide) {
|
|
4
4
|
flex-direction: column;
|
|
5
5
|
background-color: $color-snow;
|
|
6
6
|
|
|
7
|
+
@include e(inner-wrapper) {
|
|
8
|
+
width: 100%;
|
|
9
|
+
position: relative;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
> figure {
|
|
13
|
+
display: flex;
|
|
14
|
+
overflow: hidden;
|
|
15
|
+
position: relative;
|
|
16
|
+
}
|
|
17
|
+
|
|
7
18
|
@include e(video-container) {
|
|
8
19
|
position: relative;
|
|
9
20
|
padding-top: 70vh;
|
|
10
21
|
width: 100%;
|
|
11
22
|
display: flex;
|
|
23
|
+
flex-direction: column;
|
|
12
24
|
justify-content: center;
|
|
13
25
|
|
|
14
26
|
@include bp-up(sm) {
|
|
@@ -28,13 +40,14 @@
|
|
|
28
40
|
bottom: 0;
|
|
29
41
|
z-index: 1;
|
|
30
42
|
justify-content: center;
|
|
31
|
-
|
|
43
|
+
opacity: 0;
|
|
44
|
+
transition: opacity 0.25s ease-out;
|
|
32
45
|
margin: 0;
|
|
33
46
|
padding: 0;
|
|
34
47
|
|
|
35
48
|
&:first-child,
|
|
36
49
|
&.is-current {
|
|
37
|
-
|
|
50
|
+
opacity: 1;
|
|
38
51
|
}
|
|
39
52
|
|
|
40
53
|
img {
|
|
@@ -48,8 +61,8 @@
|
|
|
48
61
|
@include e(text) {
|
|
49
62
|
position: absolute;
|
|
50
63
|
top: 50%;
|
|
51
|
-
left:
|
|
52
|
-
right:
|
|
64
|
+
left: 0;
|
|
65
|
+
right: 0;
|
|
53
66
|
text-align: center;
|
|
54
67
|
padding-left: rhythm(2);
|
|
55
68
|
padding-right: rhythm(2);
|
|
@@ -69,16 +82,38 @@
|
|
|
69
82
|
@include bp-up(xl) {
|
|
70
83
|
left: rhythm(8);
|
|
71
84
|
width: calc(100% - rhythm(16));
|
|
72
|
-
max-width: 70%;
|
|
73
85
|
text-align: left;
|
|
74
86
|
}
|
|
75
87
|
|
|
76
|
-
|
|
88
|
+
@include e(headline) {
|
|
77
89
|
font-family: $font-family-bold;
|
|
78
90
|
color: $color-snow;
|
|
79
91
|
text-shadow: 0 0 rem(50px) rgba($color-black, 1),
|
|
80
92
|
0 0 rem(10px) rgba($color-black, 1),
|
|
81
93
|
rem(1px) rem(1px) rem(2px) rgba($color-black, 0.6);
|
|
94
|
+
|
|
95
|
+
@include plumber(
|
|
96
|
+
$font-size: 3,
|
|
97
|
+
$line-height: 4,
|
|
98
|
+
$leading-bottom: 1,
|
|
99
|
+
$baseline: $headings-baseline
|
|
100
|
+
);
|
|
101
|
+
|
|
102
|
+
@include bp-up(sm) {
|
|
103
|
+
@include plumber(
|
|
104
|
+
$font-size: 4.5,
|
|
105
|
+
$line-height: 5,
|
|
106
|
+
$leading-bottom: 1
|
|
107
|
+
);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
@include bp-up(lg) {
|
|
111
|
+
@include plumber(
|
|
112
|
+
$font-size: 7,
|
|
113
|
+
$line-height: 8,
|
|
114
|
+
$leading-bottom: 2
|
|
115
|
+
);
|
|
116
|
+
}
|
|
82
117
|
}
|
|
83
118
|
|
|
84
119
|
> a {
|
|
@@ -160,10 +195,7 @@
|
|
|
160
195
|
display: flex;
|
|
161
196
|
align-items: center;
|
|
162
197
|
justify-content: space-between;
|
|
163
|
-
padding
|
|
164
|
-
padding-bottom: rhythm(2);
|
|
165
|
-
padding-left: rhythm(1);
|
|
166
|
-
padding-right: rhythm(1);
|
|
198
|
+
padding: rhythm(2);
|
|
167
199
|
flex-direction: column-reverse;
|
|
168
200
|
overflow: hidden;
|
|
169
201
|
|
|
@@ -174,8 +206,6 @@
|
|
|
174
206
|
@include bp-up(md) {
|
|
175
207
|
align-items: stretch;
|
|
176
208
|
flex-direction: row;
|
|
177
|
-
padding-left: rhythm(2);
|
|
178
|
-
padding-right: rhythm(2);
|
|
179
209
|
}
|
|
180
210
|
}
|
|
181
211
|
|
|
@@ -219,9 +249,115 @@
|
|
|
219
249
|
}
|
|
220
250
|
}
|
|
221
251
|
|
|
252
|
+
@include e(timelineposts) {
|
|
253
|
+
z-index: 2;
|
|
254
|
+
width: 250px;
|
|
255
|
+
min-width: 250px;
|
|
256
|
+
background-color: $color-cyberspace;
|
|
257
|
+
position: relative;
|
|
258
|
+
transform: translateX(100%);
|
|
259
|
+
transition: transform 0.25s ease-out;
|
|
260
|
+
flex-shrink: 0;
|
|
261
|
+
position: absolute;
|
|
262
|
+
top: 0;
|
|
263
|
+
right: 0;
|
|
264
|
+
bottom: 0;
|
|
265
|
+
|
|
266
|
+
@include bp-up(md) {
|
|
267
|
+
transform: translateX(0);
|
|
268
|
+
position: relative;
|
|
269
|
+
top: auto;
|
|
270
|
+
right: auto;
|
|
271
|
+
bottom: auto;
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
@include bp-up(xl) {
|
|
275
|
+
width: 350px;
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
&.is-visible {
|
|
279
|
+
transform: translateX(0);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
@include e(list) {
|
|
283
|
+
position: absolute;
|
|
284
|
+
top: 0;
|
|
285
|
+
left: 0;
|
|
286
|
+
right: 0;
|
|
287
|
+
bottom: 0;
|
|
288
|
+
overflow-y: auto;
|
|
289
|
+
|
|
290
|
+
dt {
|
|
291
|
+
color: $color-snow;
|
|
292
|
+
font-family: $font-family-headings;
|
|
293
|
+
padding: rhythm(1) rhythm(2);
|
|
294
|
+
|
|
295
|
+
@include bp-up(md) {
|
|
296
|
+
padding-top: rhythm(2);
|
|
297
|
+
padding-bottom: rhythm(2);
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
dd {
|
|
302
|
+
padding: 0;
|
|
303
|
+
margin: 0;
|
|
304
|
+
display: block;
|
|
305
|
+
border-top: 1px solid lighten($color-cyberspace, 10%);
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
@include e(link) {
|
|
310
|
+
display: flex;
|
|
311
|
+
padding: rhythm(1) rhythm(2);
|
|
312
|
+
color: $color-snow;
|
|
313
|
+
text-decoration: none;
|
|
314
|
+
font-size: $size-medium;
|
|
315
|
+
position: relative;
|
|
316
|
+
line-height: 1.5;
|
|
317
|
+
|
|
318
|
+
&:hover,
|
|
319
|
+
&:focus,
|
|
320
|
+
&.is-current {
|
|
321
|
+
background-color: lighten($color-cyberspace, 10%);
|
|
322
|
+
|
|
323
|
+
&::after {
|
|
324
|
+
content: attr(data-label);
|
|
325
|
+
display: block;
|
|
326
|
+
background-color: $color-peacock;
|
|
327
|
+
font-family: $font-family-headings;
|
|
328
|
+
padding: rhythm(1);
|
|
329
|
+
line-height: 1;
|
|
330
|
+
align-self: flex-end;
|
|
331
|
+
white-space: nowrap;
|
|
332
|
+
border-radius: $border-radius;
|
|
333
|
+
transform: translateX(rhythm(0.5));
|
|
334
|
+
margin-left: rhythm(1);
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
&.is-current {
|
|
339
|
+
font-family: $font-family-headings;
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
@include e(button-navigation) {
|
|
344
|
+
transform: translateX(-100%);
|
|
345
|
+
|
|
346
|
+
@include bp-up(md) {
|
|
347
|
+
display: none;
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
&.is-toggeled {
|
|
351
|
+
transform: translateX(0) scaleX(-1);
|
|
352
|
+
position: absolute;
|
|
353
|
+
right: rhythm(1);
|
|
354
|
+
z-index: 2;
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
|
|
222
359
|
@include e(buttons) {
|
|
223
360
|
display: flex;
|
|
224
|
-
width: 100%;
|
|
225
361
|
}
|
|
226
362
|
|
|
227
363
|
@include e(button) {
|
|
@@ -284,6 +420,7 @@
|
|
|
284
420
|
width: auto;
|
|
285
421
|
position: absolute;
|
|
286
422
|
bottom: rhythm(1);
|
|
423
|
+
right: rhythm(1);
|
|
287
424
|
z-index: 3;
|
|
288
425
|
font-family: $font-family-headings;
|
|
289
426
|
min-width: 200px;
|
|
@@ -309,12 +446,16 @@
|
|
|
309
446
|
@include bp-up(lg) {
|
|
310
447
|
font-size: $size-base * 1.7;
|
|
311
448
|
min-width: 500px;
|
|
312
|
-
max-width:
|
|
449
|
+
max-width: 700px;
|
|
313
450
|
bottom: rhythm(2);
|
|
314
451
|
align-self: flex-end;
|
|
315
452
|
right: rhythm(2);
|
|
316
453
|
}
|
|
317
454
|
|
|
455
|
+
@include bp-up(xxl) {
|
|
456
|
+
max-width: 800px;
|
|
457
|
+
}
|
|
458
|
+
|
|
318
459
|
&.is-visible {
|
|
319
460
|
display: inline-block;
|
|
320
461
|
|
|
@@ -330,8 +471,15 @@
|
|
|
330
471
|
}
|
|
331
472
|
|
|
332
473
|
@include e(button-abort) {
|
|
333
|
-
|
|
334
|
-
|
|
474
|
+
position: absolute;
|
|
475
|
+
top: rhythm(1);
|
|
476
|
+
left: rhythm(1);
|
|
335
477
|
flex-grow: 0;
|
|
478
|
+
z-index: 2;
|
|
479
|
+
font-size: $size-small;
|
|
480
|
+
|
|
481
|
+
@include bp-up(md) {
|
|
482
|
+
font-size: initial;
|
|
483
|
+
}
|
|
336
484
|
}
|
|
337
485
|
}
|
|
@@ -15,6 +15,8 @@ const metadataTrack = (trackMetadataElement === null) ? '' : trackMetadataElemen
|
|
|
15
15
|
const forwardsButton = document.querySelector('.js-next-chapter');
|
|
16
16
|
const backwardsButton = document.querySelector('.js-previous-chapter');
|
|
17
17
|
const timelinePosts = document.querySelectorAll('.js-timeline-post');
|
|
18
|
+
const navigationButton = document.querySelector('.js-show-timelineposts');
|
|
19
|
+
const timeLinePosts = document.querySelector('.js-timeline-posts');
|
|
18
20
|
let currentChapter = 1;
|
|
19
21
|
let manualStep = false;
|
|
20
22
|
let sourceElement = null;
|
|
@@ -33,20 +35,20 @@ if (sourceElement) {
|
|
|
33
35
|
|
|
34
36
|
// Store current time in on page reload
|
|
35
37
|
window.addEventListener('unload', () => {
|
|
36
|
-
// Set
|
|
38
|
+
// Set localStorage if video has started playing
|
|
37
39
|
if (video.currentTime > 0) {
|
|
38
40
|
const currentGuideURL = window.location.href;
|
|
39
41
|
const currentGuideImage = document.querySelector('.js-guide-continue-image').src;
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
localStorage.setItem('InmsCurrentTime', video.currentTime);
|
|
43
|
+
localStorage.setItem('InmsDuration', video.duration); // Get totalt duration of video
|
|
44
|
+
localStorage.setItem('InmsCurrentGuideURL', currentGuideURL);
|
|
45
|
+
localStorage.setItem('InmsCurrentGuideImage', currentGuideImage);
|
|
44
46
|
}
|
|
45
47
|
});
|
|
46
48
|
|
|
47
|
-
// Get value from
|
|
48
|
-
if (
|
|
49
|
-
const videoCurrentTime =
|
|
49
|
+
// Get value from localStorage in present
|
|
50
|
+
if (localStorage.getItem('InmsCurrentTime')) {
|
|
51
|
+
const videoCurrentTime = localStorage.getItem('InmsCurrentTime');
|
|
50
52
|
|
|
51
53
|
if (videoCurrentTime > 0) {
|
|
52
54
|
video.currentTime = videoCurrentTime;
|
|
@@ -91,10 +93,10 @@ if (sourceElement) {
|
|
|
91
93
|
manualStep = false;
|
|
92
94
|
forwardsButton.removeAttribute('disabled');
|
|
93
95
|
subtitlesContainer.innerHTML = '';
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
96
|
+
localStorage.removeItem('InmsCurrentTime');
|
|
97
|
+
localStorage.removeItem('InmsDuration');
|
|
98
|
+
localStorage.removeItem('InmsCurrentGuideURL');
|
|
99
|
+
localStorage.removeItem('InmsCurrentGuideImage');
|
|
98
100
|
});
|
|
99
101
|
}
|
|
100
102
|
|
|
@@ -107,13 +109,20 @@ if (sourceElement) {
|
|
|
107
109
|
forwardsButton.removeAttribute('disabled');
|
|
108
110
|
currentChapter = 1;
|
|
109
111
|
manualStep = false;
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
112
|
+
localStorage.removeItem('InmsCurrentTime');
|
|
113
|
+
localStorage.removeItem('InmsDuration');
|
|
114
|
+
localStorage.removeItem('InmsCurrentGuideURL');
|
|
115
|
+
localStorage.removeItem('InmsCurrentGuideImage');
|
|
114
116
|
window.location.href = urlTarget;
|
|
115
117
|
});
|
|
116
118
|
}
|
|
119
|
+
|
|
120
|
+
if (navigationButton) {
|
|
121
|
+
navigationButton.addEventListener('click', () => {
|
|
122
|
+
navigationButton.classList.toggle('is-toggeled');
|
|
123
|
+
timeLinePosts.classList.toggle('is-visible');
|
|
124
|
+
});
|
|
125
|
+
}
|
|
117
126
|
}
|
|
118
127
|
|
|
119
128
|
function displayChapters() {
|
|
@@ -151,7 +160,7 @@ function displayChapters() {
|
|
|
151
160
|
});
|
|
152
161
|
|
|
153
162
|
// If not set in sessionStorgare, set first cue on forward button on page load
|
|
154
|
-
if (!
|
|
163
|
+
if (!localStorage.getItem('InmsCurrentTime')) {
|
|
155
164
|
forwardsButton.setAttribute('data-id', chapterTrack.cues[0].endTime);
|
|
156
165
|
}
|
|
157
166
|
}, 100);
|
|
@@ -252,7 +261,12 @@ function displayChapters() {
|
|
|
252
261
|
timelinePost.classList.remove('is-current');
|
|
253
262
|
});
|
|
254
263
|
|
|
255
|
-
document.
|
|
264
|
+
const idSelectors = document.querySelectorAll(`[data-id="${metadataCueMatch}"]`);
|
|
265
|
+
|
|
266
|
+
[].forEach.call(idSelectors, (idSelector) => {
|
|
267
|
+
idSelector.classList.add('is-current');
|
|
268
|
+
idSelector.focus();
|
|
269
|
+
});
|
|
256
270
|
|
|
257
271
|
if (chapterCues) {
|
|
258
272
|
const chapterStartTime = chapterCues.startTime;
|
|
@@ -38,9 +38,9 @@
|
|
|
38
38
|
> ul,
|
|
39
39
|
> ol,
|
|
40
40
|
> div:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
41
|
+
> figure:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
41
42
|
> .wp-block-iis-card,
|
|
42
43
|
> .wp-block-image > figure,
|
|
43
|
-
> figure,
|
|
44
44
|
> blockquote {
|
|
45
45
|
&:not(.alignfull):not(.alignleft):not(.alignright):not(.alignwide) {
|
|
46
46
|
max-width: calc(#{rem(612px)} + #{($indent * 2)});
|
|
@@ -75,8 +75,8 @@
|
|
|
75
75
|
> ul,
|
|
76
76
|
> ol,
|
|
77
77
|
> div:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
78
|
+
> figure:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
78
79
|
> .wp-block-iis-card,
|
|
79
|
-
> figure,
|
|
80
80
|
> blockquote {
|
|
81
81
|
&:not(.alignfull):not(.alignleft):not(.alignright):not(.alignwide) {
|
|
82
82
|
max-width: 46.364%;
|
|
@@ -105,7 +105,6 @@
|
|
|
105
105
|
> div:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
106
106
|
> figure:not(.wp-block-iis-info):not(.wp-block-image):not(.wp-block-iis-hero):not(.wp-block-iis-grid):not([class*='accordion']),
|
|
107
107
|
> .wp-block-iis-card,
|
|
108
|
-
> figure,
|
|
109
108
|
> blockquote {
|
|
110
109
|
&:not(.alignfull):not(.alignleft):not(.alignright):not(.alignwide) {
|
|
111
110
|
margin-right: $grid-margin-right;
|
package/src/utilities/_hide.scss
CHANGED
|
@@ -79,3 +79,14 @@
|
|
|
79
79
|
text-decoration: underline;
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
+
|
|
83
|
+
// Generate parent element link color classes e.g. .u-color-ruby a
|
|
84
|
+
/// @group Colors
|
|
85
|
+
.u-link-color {
|
|
86
|
+
@include color_classes (
|
|
87
|
+
$map: $colors,
|
|
88
|
+
$separator: '-',
|
|
89
|
+
$attribute: 'color',
|
|
90
|
+
$element: 'a'
|
|
91
|
+
);
|
|
92
|
+
}
|