hr-design-system-handlebars 1.124.10 → 1.125.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.
- package/CHANGELOG.md +25 -0
- package/dist/assets/index.css +6 -3
- package/dist/assets/js/alpine.js +1 -0
- package/dist/assets/js/components/appBanner/appBanner.alpine.js +24 -3
- package/dist/assets/js/components/appBanner/nativeAppBanner.alpine.js +7 -1
- package/dist/assets/js/components/external-service/dataWrapperContentRefresher.subfeature.js +73 -65
- package/dist/assets/js/components/external-service/dataWrapperNoResponsiveIframe.subfeature.js +50 -72
- package/dist/assets/js/components/external-service/externalServiceDs.feature.js +119 -149
- package/dist/views/components/appBanner/appBanner.hbs +1 -1
- package/dist/views/components/appBanner/nativeAppBanner.hbs +1 -1
- package/dist/views/components/external-service/external_service_with_datapolicy_check.hbs +1 -1
- package/dist/views/components/page/index/page.hbs +1 -0
- package/dist/views/components/top_button/top_button.hbs +1 -1
- package/dist/views_static/components/appBanner/appBanner.hbs +1 -1
- package/dist/views_static/components/appBanner/nativeAppBanner.hbs +1 -1
- package/dist/views_static/components/external-service/external_service_with_datapolicy_check.hbs +1 -1
- package/dist/views_static/components/page/index/page.hbs +1 -0
- package/dist/views_static/components/top_button/top_button.hbs +1 -1
- package/package.json +1 -1
- package/src/assets/js/alpine.js +1 -0
- package/src/stories/views/components/appBanner/appBanner.alpine.js +24 -3
- package/src/stories/views/components/appBanner/appBanner.hbs +1 -1
- package/src/stories/views/components/appBanner/nativeAppBanner.alpine.js +7 -1
- package/src/stories/views/components/appBanner/nativeAppBanner.hbs +1 -1
- package/src/stories/views/components/external-service/dataWrapperContentRefresher.subfeature.js +73 -65
- package/src/stories/views/components/external-service/dataWrapperNoResponsiveIframe.subfeature.js +50 -72
- package/src/stories/views/components/external-service/externalServiceDs.feature.js +119 -149
- package/src/stories/views/components/external-service/external_service_with_datapolicy_check.hbs +1 -1
- package/src/stories/views/components/page/index/page.hbs +1 -0
- package/src/stories/views/components/top_button/top_button.hbs +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,28 @@
|
|
|
1
|
+
# v1.125.1 (Wed Dec 17 2025)
|
|
2
|
+
|
|
3
|
+
#### 🐛 Bug Fix
|
|
4
|
+
|
|
5
|
+
- Dpe 3046 b - added cookie and some top button fixes [#1331](https://github.com/mumprod/hr-design-system-handlebars/pull/1331) ([@vascoeduardo](https://github.com/vascoeduardo) [@eduardo-hr](https://github.com/eduardo-hr))
|
|
6
|
+
|
|
7
|
+
#### Authors: 2
|
|
8
|
+
|
|
9
|
+
- [@eduardo-hr](https://github.com/eduardo-hr)
|
|
10
|
+
- Vasco ([@vascoeduardo](https://github.com/vascoeduardo))
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# v1.125.0 (Tue Dec 16 2025)
|
|
15
|
+
|
|
16
|
+
#### 🚀 Enhancement
|
|
17
|
+
|
|
18
|
+
- Recycle/external service js [#1330](https://github.com/mumprod/hr-design-system-handlebars/pull/1330) ([@szuelch](https://github.com/szuelch))
|
|
19
|
+
|
|
20
|
+
#### Authors: 1
|
|
21
|
+
|
|
22
|
+
- [@szuelch](https://github.com/szuelch)
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
1
26
|
# v1.124.10 (Tue Dec 16 2025)
|
|
2
27
|
|
|
3
28
|
#### 🐛 Bug Fix
|
package/dist/assets/index.css
CHANGED
|
@@ -1741,6 +1741,9 @@ article #commentList {
|
|
|
1741
1741
|
.h-2 {
|
|
1742
1742
|
height: 0.5rem;
|
|
1743
1743
|
}
|
|
1744
|
+
.h-22 {
|
|
1745
|
+
height: 5.5rem;
|
|
1746
|
+
}
|
|
1744
1747
|
.h-3 {
|
|
1745
1748
|
height: 0.75rem;
|
|
1746
1749
|
}
|
|
@@ -3906,7 +3909,7 @@ article #commentList {
|
|
|
3906
3909
|
border-bottom-color: var(--color-secondary-ds);
|
|
3907
3910
|
}
|
|
3908
3911
|
.counter-reset {
|
|
3909
|
-
counter-reset:
|
|
3912
|
+
counter-reset: cnt1765981088136;
|
|
3910
3913
|
}
|
|
3911
3914
|
.animate-delay-100 {
|
|
3912
3915
|
--tw-animate-delay: 100ms;
|
|
@@ -4367,7 +4370,7 @@ html { scroll-behavior: smooth; }
|
|
|
4367
4370
|
--tw-ring-color: rgba(255, 255, 255, 0.5);
|
|
4368
4371
|
}
|
|
4369
4372
|
.-ordered {
|
|
4370
|
-
counter-increment:
|
|
4373
|
+
counter-increment: cnt1765981088136 1;
|
|
4371
4374
|
}
|
|
4372
4375
|
.-ordered::before {
|
|
4373
4376
|
position: absolute;
|
|
@@ -4385,7 +4388,7 @@ html { scroll-behavior: smooth; }
|
|
|
4385
4388
|
--tw-text-opacity: 1;
|
|
4386
4389
|
color: rgba(0, 0, 0, 1);
|
|
4387
4390
|
color: rgba(0, 0, 0, var(--tw-text-opacity));
|
|
4388
|
-
content: counter(
|
|
4391
|
+
content: counter(cnt1765981088136);
|
|
4389
4392
|
}
|
|
4390
4393
|
/*! ****************************/
|
|
4391
4394
|
/*! DataPolicy stuff */
|
package/dist/assets/js/alpine.js
CHANGED
|
@@ -46,6 +46,7 @@ Alpine.store('serviceID', {
|
|
|
46
46
|
Alpine.store('navIsVisible', true)
|
|
47
47
|
Alpine.store('subNavIsVisible', false)
|
|
48
48
|
Alpine.store('footerIsVisible', false)
|
|
49
|
+
Alpine.store('appBannerIsVisible', false)
|
|
49
50
|
Alpine.store('sectionNavIsVisible', false)
|
|
50
51
|
Alpine.store('sharingIsVisible', false)
|
|
51
52
|
Alpine.store('sharingIsOpen', {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { uxAction } from 'base/tracking/pianoHelper.subfeature'
|
|
2
|
+
import { getJSONCookie, setJSONCookie } from 'hrQuery'
|
|
2
3
|
|
|
3
4
|
export default function appBanner() {
|
|
4
5
|
return {
|
|
@@ -6,24 +7,37 @@ export default function appBanner() {
|
|
|
6
7
|
deferredPrompt: null,
|
|
7
8
|
isAndroid: /Android/i.test(navigator.userAgent),
|
|
8
9
|
packageId: "de.hr.hessenschau",
|
|
10
|
+
cookie: {},
|
|
11
|
+
cookieLifetime: 1000 * 60 * 60 * 24 * 30,
|
|
9
12
|
init: function () {
|
|
10
|
-
|
|
11
|
-
if(this.
|
|
13
|
+
this.readTrackingCookie()
|
|
14
|
+
if(this.cookie["closed"] !== true){
|
|
15
|
+
if(this.isAndroid){
|
|
16
|
+
this.showBanner = true;
|
|
17
|
+
this.$store.appBannerIsVisible = true;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
if(window.IS_STORYBOOK){
|
|
12
21
|
this.showBanner = true;
|
|
22
|
+
this.$store.appBannerIsVisible = true;
|
|
13
23
|
}
|
|
14
24
|
|
|
15
|
-
if(window.IS_STORYBOOK){ this.showBanner = true;}
|
|
16
25
|
},
|
|
17
26
|
installClickHandler: function(){
|
|
18
27
|
this.openPlayStore()
|
|
28
|
+
this.writeCookie()
|
|
19
29
|
this.showBanner = false
|
|
30
|
+
this.$store.appBannerIsVisible = false
|
|
20
31
|
},
|
|
21
32
|
closeClickHandler: function(){
|
|
22
33
|
uxAction('appBanner::bannerClosed');
|
|
23
34
|
this.showBanner = false
|
|
35
|
+
this.$store.appBannerIsVisible = false
|
|
36
|
+
this.writeCookie()
|
|
24
37
|
},
|
|
25
38
|
openPlayStore: function() {
|
|
26
39
|
let fallbackTriggered = false;
|
|
40
|
+
uxAction('appBanner::playStoreOpened');
|
|
27
41
|
|
|
28
42
|
const fallback = () => {
|
|
29
43
|
if (fallbackTriggered) return;
|
|
@@ -45,6 +59,13 @@ export default function appBanner() {
|
|
|
45
59
|
`#Intent;scheme=market;package=com.android.vending;end`;
|
|
46
60
|
|
|
47
61
|
setTimeout(fallback, 700);
|
|
62
|
+
},
|
|
63
|
+
writeCookie: function() {
|
|
64
|
+
this.cookie["closed"] = true
|
|
65
|
+
setJSONCookie('appBanner', this.cookie, this.cookieLifetime)
|
|
66
|
+
},
|
|
67
|
+
readTrackingCookie: function() {
|
|
68
|
+
this.cookie = getJSONCookie('appBanner') || {}
|
|
48
69
|
}
|
|
49
70
|
}
|
|
50
71
|
}
|
|
@@ -14,9 +14,13 @@ export default function nativeAppBanner() {
|
|
|
14
14
|
// Update UI notify the user they can add to home screen
|
|
15
15
|
if(this.isAndroid){
|
|
16
16
|
this.showBanner = true;
|
|
17
|
+
this.$store.appBannerIsVisible = true;
|
|
17
18
|
}
|
|
18
19
|
});
|
|
19
|
-
if(window.IS_STORYBOOK){
|
|
20
|
+
if(window.IS_STORYBOOK){
|
|
21
|
+
this.showBanner = true;
|
|
22
|
+
this.$store.appBannerIsVisible = true;
|
|
23
|
+
}
|
|
20
24
|
},
|
|
21
25
|
installClickHandler: function(){
|
|
22
26
|
if(this.deferredPrompt){
|
|
@@ -35,10 +39,12 @@ export default function nativeAppBanner() {
|
|
|
35
39
|
});
|
|
36
40
|
}
|
|
37
41
|
this.showBanner = false
|
|
42
|
+
this.$store.appBannerIsVisible = false
|
|
38
43
|
},
|
|
39
44
|
closeClickHandler: function(){
|
|
40
45
|
uxAction('nativeAppBanner::bannerClosed');
|
|
41
46
|
this.showBanner = false
|
|
47
|
+
this.$store.appBannerIsVisible = false
|
|
42
48
|
}
|
|
43
49
|
}
|
|
44
50
|
}
|
package/dist/assets/js/components/external-service/dataWrapperContentRefresher.subfeature.js
CHANGED
|
@@ -1,88 +1,95 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
const DataWrapperContentRefresher = function ({
|
|
2
|
+
rootElement,
|
|
3
|
+
id,
|
|
4
|
+
refreshIntervall,
|
|
5
|
+
isWebcomponent,
|
|
6
|
+
datapolicy,
|
|
7
|
+
}) {
|
|
4
8
|
let remainingTime
|
|
5
9
|
let timer
|
|
6
|
-
let uniqueID = id
|
|
7
10
|
let intervall = refreshIntervall
|
|
8
11
|
let container
|
|
9
|
-
let script
|
|
12
|
+
let script
|
|
10
13
|
let iframeRefresh
|
|
11
|
-
|
|
12
|
-
if (
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
iframeRefresh = document.getElementById('datawrapper-chart-' + uniqueID)
|
|
14
|
+
|
|
15
|
+
if (isWebcomponent) {
|
|
16
|
+
container = document.getElementById(`datawrapper-chart-${id}`)
|
|
17
|
+
script = document.getElementById('datawrapper-component-js')
|
|
18
|
+
} else {
|
|
19
|
+
iframeRefresh = document.getElementById(`datawrapper-chart-${id}`)
|
|
18
20
|
}
|
|
19
|
-
|
|
21
|
+
|
|
20
22
|
const createRefresher = function () {
|
|
21
|
-
console.log(
|
|
22
|
-
|
|
23
|
+
console.log('Refresher bauen')
|
|
24
|
+
const divCounter = document.createElement('div')
|
|
25
|
+
divCounter.id = 'counter' + id
|
|
26
|
+
Object.assign(divCounter.style, {
|
|
27
|
+
backgroundColor: '#006dc1',
|
|
28
|
+
color: '#fff',
|
|
29
|
+
fontSize: '12px',
|
|
30
|
+
padding: '8px',
|
|
31
|
+
borderRadius: '0 0 4px 4px',
|
|
32
|
+
})
|
|
33
|
+
|
|
23
34
|
let divOverlay = document.createElement('div')
|
|
35
|
+
divOverlay.id = 'overlay' + id
|
|
36
|
+
Object.assign(divOverlay.style, {
|
|
37
|
+
position: 'absolute',
|
|
38
|
+
top: '0',
|
|
39
|
+
display: 'none',
|
|
40
|
+
alignItems: 'center',
|
|
41
|
+
justifyContent: 'center',
|
|
42
|
+
backgroundColor: '#d8e9f6',
|
|
43
|
+
width: '100%',
|
|
44
|
+
height: 'calc(100% - 36px)',
|
|
45
|
+
})
|
|
46
|
+
|
|
24
47
|
let divTextOverlay = document.createElement('div')
|
|
25
|
-
divOverlay.id = 'overlay' + uniqueID
|
|
26
|
-
divOverlay.style.position = 'absolute'
|
|
27
|
-
divOverlay.style.top = '0'
|
|
28
|
-
divOverlay.style.display = 'none'
|
|
29
|
-
divOverlay.style.alignItems = 'center'
|
|
30
|
-
divOverlay.style.justifyContent = 'center'
|
|
31
|
-
divOverlay.style.backgroundColor = '#fff'
|
|
32
|
-
divOverlay.style.width = '100%'
|
|
33
|
-
divOverlay.style.height = 'calc(100% - 36px)'
|
|
34
|
-
divOverlay.style.backgroundColor = '#d8e9f6'
|
|
35
48
|
divTextOverlay.innerHTML = 'Lade Inhalt neu...'
|
|
36
|
-
divTextOverlay.style
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
49
|
+
Object.assign(divTextOverlay.style, {
|
|
50
|
+
backgroundColor: '#005293',
|
|
51
|
+
padding: '8px',
|
|
52
|
+
color: '#fff',
|
|
53
|
+
fontWeight: '800',
|
|
54
|
+
fontFamily: 'RobotoSlab',
|
|
55
|
+
borderRadius: '6px',
|
|
56
|
+
})
|
|
57
|
+
|
|
42
58
|
divOverlay.appendChild(divTextOverlay)
|
|
43
|
-
|
|
44
|
-
divCounter.style.backgroundColor = '#006dc1'
|
|
45
|
-
divCounter.style.color = '#fff'
|
|
46
|
-
divCounter.style.fontSize = '12px'
|
|
47
|
-
divCounter.style.padding = '8px'
|
|
48
|
-
divCounter.style.borderRadius = '0 0 4px 4px'
|
|
49
|
-
|
|
59
|
+
|
|
50
60
|
rootElement.style.position = 'relative'
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
else {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
61
|
+
|
|
62
|
+
if (!datapolicy) {
|
|
63
|
+
rootElement.appendChild(divCounter)
|
|
64
|
+
rootElement.appendChild(divOverlay)
|
|
65
|
+
startCountdown()
|
|
66
|
+
} else {
|
|
67
|
+
rootElement.removeChild(divCounter)
|
|
68
|
+
rootElement.removeChild(divOverlay)
|
|
69
|
+
stopCountdown()
|
|
60
70
|
}
|
|
61
71
|
}
|
|
62
72
|
|
|
63
73
|
const refreshIframe = function () {
|
|
64
74
|
console.log('Reload')
|
|
65
|
-
if(
|
|
75
|
+
if (isWebcomponent) {
|
|
66
76
|
container.style.opacity = '0'
|
|
67
77
|
script.src = script.src.split('?')[0] + '?_=' + new Date().getTime()
|
|
68
|
-
}
|
|
69
|
-
else{
|
|
78
|
+
} else {
|
|
70
79
|
iframeRefresh.style.opacity = '0'
|
|
71
|
-
iframeRefresh.src =
|
|
72
|
-
iframeRefresh.src.split('?')[0] + '?_=' + new Date().getTime()
|
|
80
|
+
iframeRefresh.src = iframeRefresh.src.split('?')[0] + '?_=' + new Date().getTime()
|
|
73
81
|
}
|
|
74
82
|
clearInterval(timer)
|
|
75
83
|
}
|
|
76
84
|
const startCountdown = function () {
|
|
77
85
|
remainingTime = Number(intervall)
|
|
78
86
|
setTimeout(function () {
|
|
79
|
-
if(
|
|
80
|
-
container.style.opacity = '1'
|
|
81
|
-
}
|
|
82
|
-
else{
|
|
87
|
+
if (isWebcomponent) {
|
|
88
|
+
container.style.opacity = '1'
|
|
89
|
+
} else {
|
|
83
90
|
iframeRefresh.style.opacity = '1'
|
|
84
91
|
}
|
|
85
|
-
document.getElementById('overlay' +
|
|
92
|
+
document.getElementById('overlay' + id).style.display = 'none'
|
|
86
93
|
}, 1000)
|
|
87
94
|
timer = setInterval(function () {
|
|
88
95
|
checkTimer()
|
|
@@ -92,33 +99,34 @@ const DataWrapperContentRefresher = function (context, id, refreshIntervall, web
|
|
|
92
99
|
clearInterval(timer)
|
|
93
100
|
}
|
|
94
101
|
const checkTimer = function () {
|
|
95
|
-
if(document.getElementById('counter' +
|
|
102
|
+
if (document.getElementById('counter' + id) !== null) {
|
|
96
103
|
if (remainingTime >= 0) {
|
|
97
|
-
document.getElementById('counter' +
|
|
104
|
+
document.getElementById('counter' + id).innerHTML =
|
|
98
105
|
'Dieser Inhalt wird automatisch aktualisiert in ' +
|
|
99
106
|
secondsToTimeString(remainingTime) +
|
|
100
107
|
' Min.'
|
|
101
108
|
remainingTime -= 1
|
|
102
109
|
if (remainingTime == -1) {
|
|
103
|
-
document.getElementById('overlay' +
|
|
104
|
-
document.getElementById('counter' +
|
|
110
|
+
document.getElementById('overlay' + id).style.display = 'flex'
|
|
111
|
+
document.getElementById('counter' + id).innerHTML =
|
|
105
112
|
'Zeitintervall wird neu gestartet...'
|
|
106
113
|
}
|
|
107
114
|
} else {
|
|
108
115
|
refreshIframe()
|
|
109
116
|
startCountdown()
|
|
110
117
|
}
|
|
111
|
-
}else{
|
|
112
|
-
console.log(
|
|
118
|
+
} else {
|
|
119
|
+
console.log('Element wurde entfernt')
|
|
113
120
|
clearInterval(timer)
|
|
114
121
|
}
|
|
115
122
|
}
|
|
123
|
+
|
|
116
124
|
const secondsToTimeString = function (seconds) {
|
|
117
125
|
return new Date(seconds * 1000).toISOString().substr(14, 5)
|
|
118
126
|
}
|
|
119
127
|
return {
|
|
120
|
-
createRefresher: createRefresher
|
|
128
|
+
createRefresher: createRefresher,
|
|
121
129
|
}
|
|
122
130
|
}
|
|
123
131
|
|
|
124
|
-
export default DataWrapperContentRefresher
|
|
132
|
+
export default DataWrapperContentRefresher
|
package/dist/assets/js/components/external-service/dataWrapperNoResponsiveIframe.subfeature.js
CHANGED
|
@@ -1,83 +1,61 @@
|
|
|
1
|
-
const DataWrapperNoResponsiveIframe = function (
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
const DataWrapperNoResponsiveIframe = function ({
|
|
2
|
+
rootElement,
|
|
3
|
+
aspectRatio,
|
|
4
|
+
fixedHeight,
|
|
5
|
+
id,
|
|
6
|
+
embedCode,
|
|
7
|
+
lazyLoad,
|
|
8
|
+
}) {
|
|
8
9
|
const createNoResponsiveIframe = function () {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
//Keine Aspect-Ratio ausgewählt aber eine feste Höhe
|
|
16
|
-
|
|
17
|
-
console.log(aspectRatio)
|
|
18
|
-
console.log(configAR)
|
|
19
|
-
if (aspectRatio === undefined) {
|
|
10
|
+
const parentDiv = document.createElement('div')
|
|
11
|
+
//Auflösen nach Tailwind-Klassen //copytext__scrollWrapper
|
|
12
|
+
parentDiv.className = '!h-full'
|
|
13
|
+
const div = document.createElement('div')
|
|
14
|
+
//Keine Aspect-Ratio ausgewählt aber eine feste Höhe
|
|
15
|
+
if (aspectRatio === undefined) {
|
|
20
16
|
//Auflösen nach Tailwind-Klassen //noaspect_datawrapper_cdn
|
|
21
17
|
div.className = 'relative overflow-hidden w-0 border-0 !min-w-full'
|
|
22
18
|
div.style.height = fixedHeight + 'px'
|
|
23
19
|
div.style.width = '100%'
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
break;
|
|
42
|
-
case '7x16':
|
|
43
|
-
tailwindCSS = "ar-7-16"
|
|
44
|
-
break;
|
|
45
|
-
case '4x3':
|
|
46
|
-
tailwindCSS = "ar-4-3"
|
|
47
|
-
break;
|
|
48
|
-
case '100x27':
|
|
49
|
-
tailwindCSS = "ar-100-27"
|
|
50
|
-
break;
|
|
51
|
-
default:
|
|
52
|
-
tailwindCSS = "ar-16-9"
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
div.className = tailwindCSS + " w-full sm480:h-full h-[560px]"
|
|
56
|
-
}
|
|
57
|
-
var iframe = document.createElement('iframe')
|
|
20
|
+
}
|
|
21
|
+
// Aspect-Ratio ausgewählt
|
|
22
|
+
else {
|
|
23
|
+
//ar-- in Tailwind-Klassen
|
|
24
|
+
const aspectRatiosToCssClasses = {
|
|
25
|
+
'100': 'ar-1-1',
|
|
26
|
+
'16x9': 'ar-16-9',
|
|
27
|
+
'9x16': 'ar-9-16',
|
|
28
|
+
'16x7': 'ar-16-7',
|
|
29
|
+
'7x16': 'ar-7-16',
|
|
30
|
+
'4x3': 'ar-4-3',
|
|
31
|
+
'100x27': 'ar-100-27',
|
|
32
|
+
}
|
|
33
|
+
const tailwindCSS = aspectRatiosToCssClasses[aspectRatio] || 'ar-16-9'
|
|
34
|
+
div.className = `${tailwindCSS} w-full sm480:h-full h-[560px]`
|
|
35
|
+
}
|
|
36
|
+
var iframe = document.createElement('iframe')
|
|
58
37
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
rootElement.appendChild(parentDiv)
|
|
38
|
+
//Auflösen nach Tailwind-Klassen //ar_iframe datawrapper_cdn
|
|
39
|
+
iframe.className = 'border-0 top-0 left-0 w-full h-full overflow-y-hidden'
|
|
40
|
+
iframe.id = 'datawrapper-chart-' + id
|
|
41
|
+
iframe.setAttribute('data-isloaded', '0')
|
|
42
|
+
iframe.setAttribute('webkitallowfullscreen', '')
|
|
43
|
+
iframe.setAttribute('mozallowfullscreen', '')
|
|
44
|
+
iframe.setAttribute('allowfullscreen', '')
|
|
45
|
+
iframe.setAttribute('scrolling', 'no')
|
|
46
|
+
iframe.setAttribute('frameborder', '0')
|
|
47
|
+
iframe.src = embedCode
|
|
48
|
+
if (lazyLoad) {
|
|
49
|
+
iframe.loading = 'lazy'
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
div.appendChild(iframe)
|
|
53
|
+
parentDiv.appendChild(div)
|
|
54
|
+
rootElement.appendChild(parentDiv)
|
|
77
55
|
}
|
|
78
56
|
return {
|
|
79
|
-
createNoResponsiveIframe: createNoResponsiveIframe
|
|
57
|
+
createNoResponsiveIframe: createNoResponsiveIframe,
|
|
80
58
|
}
|
|
81
59
|
}
|
|
82
60
|
|
|
83
|
-
export default DataWrapperNoResponsiveIframe
|
|
61
|
+
export default DataWrapperNoResponsiveIframe
|