hr-design-system-handlebars 1.114.94 → 1.114.95

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 CHANGED
@@ -1,3 +1,16 @@
1
+ # v1.114.95 (Mon Feb 17 2025)
2
+
3
+ #### 🐛 Bug Fix
4
+
5
+ - Dpe 3556 [#1243](https://github.com/mumprod/hr-design-system-handlebars/pull/1243) (saad.elbaciri@hr.de [@selbaciri](https://github.com/selbaciri))
6
+
7
+ #### Authors: 2
8
+
9
+ - Saad El Baciri ([@selbaciri](https://github.com/selbaciri))
10
+ - selbaciri (saad.elbaciri@hr.de)
11
+
12
+ ---
13
+
1
14
  # v1.114.94 (Mon Feb 17 2025)
2
15
 
3
16
  #### 🐛 Bug Fix
@@ -3846,7 +3846,7 @@ article #commentList {
3846
3846
  border-bottom-color: var(--color-secondary-ds);
3847
3847
  }
3848
3848
  .counter-reset {
3849
- counter-reset: cnt1739785841928;
3849
+ counter-reset: cnt1739790727302;
3850
3850
  }
3851
3851
  .animate-delay-100 {
3852
3852
  --tw-animate-delay: 100ms;
@@ -4291,7 +4291,7 @@ html { scroll-behavior: smooth; }
4291
4291
  --tw-ring-color: rgba(255, 255, 255, 0.5);
4292
4292
  }
4293
4293
  .-ordered {
4294
- counter-increment: cnt1739785841928 1;
4294
+ counter-increment: cnt1739790727302 1;
4295
4295
  }
4296
4296
  .-ordered::before {
4297
4297
  position: absolute;
@@ -4309,7 +4309,7 @@ html { scroll-behavior: smooth; }
4309
4309
  --tw-text-opacity: 1;
4310
4310
  color: rgba(0, 0, 0, 1);
4311
4311
  color: rgba(0, 0, 0, var(--tw-text-opacity));
4312
- content: counter(cnt1739785841928);
4312
+ content: counter(cnt1739790727302);
4313
4313
  }
4314
4314
  /*! ****************************/
4315
4315
  /*! DataPolicy stuff */
@@ -111,6 +111,9 @@ const ExternalService = function (context) {
111
111
  case 'wahl-gemeinde-ergebnis':
112
112
  createWahlGemeindeErgebnisEmbed()
113
113
  break
114
+ case 'wer-waehlte-wen':
115
+ werWaehlteWenEmbed()
116
+ break
114
117
  default:
115
118
  console.error('No JS Config for external service ' + id)
116
119
  break
@@ -168,6 +171,39 @@ const ExternalService = function (context) {
168
171
  script.type = 'text/javascript'
169
172
  rootElement.appendChild(script)
170
173
  }
174
+
175
+ const werWaehlteWenEmbed = function () {
176
+ let iframe = document.createElement('iframe');
177
+ let cleanUrl;
178
+ const parts = embedCode.split('*');
179
+ if (parts.length === 2) {
180
+ const params = parts[1].split(' ');
181
+ cleanUrl = parts[0].trim();
182
+ for (const param of params) {
183
+ const [key, value] = param.split('=');
184
+ if (key === 'id') {
185
+ iframe.id = value;
186
+ } else {
187
+ iframe.setAttribute(key, value);
188
+ }
189
+ }
190
+ }
191
+
192
+ iframe.src = cleanUrl;
193
+ iframe.style.width = "100%";
194
+ iframe.style.border = "0";
195
+ rootElement.appendChild(iframe);
196
+
197
+ window.addEventListener("message", function (e) {
198
+ if (e.data.contentUrl && e.data.contentUrl.includes("/wahl/embed/2025-02-23-BT-DE/wer-waehlte-wen/")) {
199
+ let h = parseInt(e.data.height, 10) + 2;
200
+ if (iframe.id === "ts-embed-wer-waehlte-wen-2025-02-23-BT-DE") {
201
+ iframe.style.height = h + "px";
202
+ }
203
+ }
204
+ });
205
+ }
206
+
171
207
  const createUniqueID = function () {
172
208
  console.log("Erzeuge einzigartige ID")
173
209
  uniqueId = Math.random().toString(36).replace(/[^a-z]+/g, '').substring(2, 10)
package/package.json CHANGED
@@ -6,7 +6,7 @@
6
6
  "license": "MIT",
7
7
  "main": "dist/index.js",
8
8
  "repository": "https://github.com/szuelch/hr-design-system-handlebars",
9
- "version": "1.114.94",
9
+ "version": "1.114.95",
10
10
  "scripts": {
11
11
  "test": "echo \"Error: no test specified\" && exit 1",
12
12
  "storybook": "storybook dev -p 6006 public",
@@ -111,6 +111,9 @@ const ExternalService = function (context) {
111
111
  case 'wahl-gemeinde-ergebnis':
112
112
  createWahlGemeindeErgebnisEmbed()
113
113
  break
114
+ case 'wer-waehlte-wen':
115
+ werWaehlteWenEmbed()
116
+ break
114
117
  default:
115
118
  console.error('No JS Config for external service ' + id)
116
119
  break
@@ -168,6 +171,39 @@ const ExternalService = function (context) {
168
171
  script.type = 'text/javascript'
169
172
  rootElement.appendChild(script)
170
173
  }
174
+
175
+ const werWaehlteWenEmbed = function () {
176
+ let iframe = document.createElement('iframe');
177
+ let cleanUrl;
178
+ const parts = embedCode.split('*');
179
+ if (parts.length === 2) {
180
+ const params = parts[1].split(' ');
181
+ cleanUrl = parts[0].trim();
182
+ for (const param of params) {
183
+ const [key, value] = param.split('=');
184
+ if (key === 'id') {
185
+ iframe.id = value;
186
+ } else {
187
+ iframe.setAttribute(key, value);
188
+ }
189
+ }
190
+ }
191
+
192
+ iframe.src = cleanUrl;
193
+ iframe.style.width = "100%";
194
+ iframe.style.border = "0";
195
+ rootElement.appendChild(iframe);
196
+
197
+ window.addEventListener("message", function (e) {
198
+ if (e.data.contentUrl && e.data.contentUrl.includes("/wahl/embed/2025-02-23-BT-DE/wer-waehlte-wen/")) {
199
+ let h = parseInt(e.data.height, 10) + 2;
200
+ if (iframe.id === "ts-embed-wer-waehlte-wen-2025-02-23-BT-DE") {
201
+ iframe.style.height = h + "px";
202
+ }
203
+ }
204
+ });
205
+ }
206
+
171
207
  const createUniqueID = function () {
172
208
  console.log("Erzeuge einzigartige ID")
173
209
  uniqueId = Math.random().toString(36).replace(/[^a-z]+/g, '').substring(2, 10)