@internetstiftelsen/styleguide 5.0.1 → 5.0.3-beta.0.1
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.
|
@@ -18,7 +18,6 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
18
18
|
|
|
19
19
|
// TODO: Should probably implement a way to localize texts in the styleguide
|
|
20
20
|
var consent = (0, _hasCookieConsent2.default)('C0004');
|
|
21
|
-
var YT = void 0;
|
|
22
21
|
var missingConsentMessage = 'För att spela Youtubefilmer krävs att "Riktade kakor" tillåts. Tryck för att "Anpassa kakor"';
|
|
23
22
|
|
|
24
23
|
function loadYoutubeAPI() {
|
|
@@ -37,7 +36,8 @@ function loadYoutubeAPI() {
|
|
|
37
36
|
firstScript.parentNode.insertBefore(tag, firstScript);
|
|
38
37
|
}
|
|
39
38
|
|
|
40
|
-
function onPlayerStateChange(el, e
|
|
39
|
+
function onPlayerStateChange(el, e) {
|
|
40
|
+
/* eslint-disable no-undef */
|
|
41
41
|
if (e.data === YT.PlayerState.PLAYING) {
|
|
42
42
|
el.getElementsByTagName('img')[0].style.zIndex = '-1';
|
|
43
43
|
el.getElementsByTagName('button')[0].style.display = 'none';
|
package/package.json
CHANGED
package/src/assets/js/youtube.js
CHANGED
|
@@ -3,7 +3,6 @@ import className from './className';
|
|
|
3
3
|
import hasCookieConsent from './hasCookieConsent';
|
|
4
4
|
|
|
5
5
|
let consent = hasCookieConsent('C0004');
|
|
6
|
-
let YT;
|
|
7
6
|
const missingConsentMessage = 'För att spela Youtubefilmer krävs att "Riktade kakor" tillåts. Tryck för att "Anpassa kakor"';
|
|
8
7
|
|
|
9
8
|
function loadYoutubeAPI() {
|
|
@@ -22,7 +21,8 @@ function loadYoutubeAPI() {
|
|
|
22
21
|
firstScript.parentNode.insertBefore(tag, firstScript);
|
|
23
22
|
}
|
|
24
23
|
|
|
25
|
-
function onPlayerStateChange(el, e
|
|
24
|
+
function onPlayerStateChange(el, e) {
|
|
25
|
+
/* eslint-disable no-undef */
|
|
26
26
|
if (e.data === YT.PlayerState.PLAYING) {
|
|
27
27
|
el.getElementsByTagName('img')[0].style.zIndex = '-1';
|
|
28
28
|
el.getElementsByTagName('button')[0].style.display = 'none';
|
|
@@ -283,19 +283,19 @@ html {
|
|
|
283
283
|
margin-right: auto;
|
|
284
284
|
|
|
285
285
|
@include breakpoint.bp-up(sm) {
|
|
286
|
-
width: make_col(16);
|
|
286
|
+
width: func.make_col(16);
|
|
287
287
|
}
|
|
288
288
|
|
|
289
289
|
@include breakpoint.bp-up(md) {
|
|
290
|
-
width: make_col(12);
|
|
290
|
+
width: func.make_col(12);
|
|
291
291
|
}
|
|
292
292
|
|
|
293
293
|
@include breakpoint.bp-up(lg) {
|
|
294
|
-
width: make_col(12);
|
|
294
|
+
width: func.make_col(12);
|
|
295
295
|
}
|
|
296
296
|
|
|
297
297
|
@include breakpoint.bp-up(xl) {
|
|
298
|
-
width: make_col(9);
|
|
298
|
+
width: func.make_col(9);
|
|
299
299
|
}
|
|
300
300
|
}
|
|
301
301
|
|