hr-design-system-handlebars 1.67.0 β 1.67.2
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/.github/workflows/chromatic.yml +1 -1
- package/.storybook/main.js +2 -0
- package/CHANGELOG.md +25 -0
- package/dist/assets/index.css +3 -3
- package/dist/assets/js/components/externalService/externalServiceDs.feature.js +16 -0
- package/package.json +7 -2
- package/src/stories/views/components/externalService/externalServiceDs.feature.js +16 -0
- package/src/stories/views/components/modal/modal.stories.js +19 -1
- package/src/stories/views/components/podcast/podcast_subscribe_button.stories.js +8 -3
|
@@ -21,7 +21,7 @@ jobs:
|
|
|
21
21
|
run: yarn
|
|
22
22
|
- name: create partials
|
|
23
23
|
run: yarn partialsToJs
|
|
24
|
-
- uses: chromaui/action@
|
|
24
|
+
- uses: chromaui/action@v11.3.0
|
|
25
25
|
with:
|
|
26
26
|
# π Chromatic projectToken, refer to the manage page to obtain it.
|
|
27
27
|
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
package/.storybook/main.js
CHANGED
|
@@ -9,6 +9,7 @@ const config = {
|
|
|
9
9
|
'../src/**/*.mdx',
|
|
10
10
|
'../src/**/*.stories.@(js|jsx|ts|tsx)',
|
|
11
11
|
],
|
|
12
|
+
features: { buildStoriesJson: true },
|
|
12
13
|
addons: [
|
|
13
14
|
'@storybook/addon-links',
|
|
14
15
|
{
|
|
@@ -44,6 +45,7 @@ const config = {
|
|
|
44
45
|
},
|
|
45
46
|
},
|
|
46
47
|
},
|
|
48
|
+
'@storybook/addon-interactions'
|
|
47
49
|
],
|
|
48
50
|
webpackFinal: async (config, { configType }) => {
|
|
49
51
|
// `configType` has a value of 'DEVELOPMENT' or 'PRODUCTION'
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,28 @@
|
|
|
1
|
+
# v1.67.2 (Thu May 02 2024)
|
|
2
|
+
|
|
3
|
+
#### π Bug Fix
|
|
4
|
+
|
|
5
|
+
- Feature/dpe 3061 [#919](https://github.com/mumprod/hr-design-system-handlebars/pull/919) ([@szuelch](https://github.com/szuelch))
|
|
6
|
+
|
|
7
|
+
#### Authors: 1
|
|
8
|
+
|
|
9
|
+
- [@szuelch](https://github.com/szuelch)
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# v1.67.1 (Mon Apr 29 2024)
|
|
14
|
+
|
|
15
|
+
#### π Bug Fix
|
|
16
|
+
|
|
17
|
+
- Adding wahl-o-mat [#918](https://github.com/mumprod/hr-design-system-handlebars/pull/918) ([@Paul-Atreidis](https://github.com/Paul-Atreidis) [@szuelch](https://github.com/szuelch))
|
|
18
|
+
|
|
19
|
+
#### Authors: 2
|
|
20
|
+
|
|
21
|
+
- [@Paul-Atreidis](https://github.com/Paul-Atreidis)
|
|
22
|
+
- [@szuelch](https://github.com/szuelch)
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
1
26
|
# v1.67.0 (Thu Apr 25 2024)
|
|
2
27
|
|
|
3
28
|
#### π Enhancement
|
package/dist/assets/index.css
CHANGED
|
@@ -3353,7 +3353,7 @@ article.indexTextDS .indexTextHighlighted .link {
|
|
|
3353
3353
|
border-bottom-color: var(--color-secondary-ds);
|
|
3354
3354
|
}
|
|
3355
3355
|
.counter-reset {
|
|
3356
|
-
counter-reset:
|
|
3356
|
+
counter-reset: cnt1714630422823;
|
|
3357
3357
|
}
|
|
3358
3358
|
.hyphens-auto {
|
|
3359
3359
|
-webkit-hyphens: auto;
|
|
@@ -3732,7 +3732,7 @@ article.indexTextDS .indexTextHighlighted .link {
|
|
|
3732
3732
|
--tw-ring-color: rgba(255, 255, 255, 0.5);
|
|
3733
3733
|
}
|
|
3734
3734
|
.-ordered {
|
|
3735
|
-
counter-increment:
|
|
3735
|
+
counter-increment: cnt1714630422823 1;
|
|
3736
3736
|
}
|
|
3737
3737
|
.-ordered::before {
|
|
3738
3738
|
position: absolute;
|
|
@@ -3748,7 +3748,7 @@ article.indexTextDS .indexTextHighlighted .link {
|
|
|
3748
3748
|
letter-spacing: .0125em;
|
|
3749
3749
|
--tw-text-opacity: 1;
|
|
3750
3750
|
color: rgba(0, 0, 0, var(--tw-text-opacity));
|
|
3751
|
-
content: counter(
|
|
3751
|
+
content: counter(cnt1714630422823);
|
|
3752
3752
|
}
|
|
3753
3753
|
/*! ****************************/
|
|
3754
3754
|
/*! DataPolicy stuff */
|
|
@@ -100,6 +100,9 @@ const ExternalService = function (context) {
|
|
|
100
100
|
case 'wahlkreiskarte':
|
|
101
101
|
createWahlEmbed()
|
|
102
102
|
break
|
|
103
|
+
case 'wahlomat':
|
|
104
|
+
createWahlOMatEmbed()
|
|
105
|
+
break
|
|
103
106
|
default:
|
|
104
107
|
console.error('No JS Config for external service ' + id)
|
|
105
108
|
break
|
|
@@ -110,6 +113,19 @@ const ExternalService = function (context) {
|
|
|
110
113
|
}
|
|
111
114
|
}
|
|
112
115
|
|
|
116
|
+
const createWahlOMatEmbed = function () {
|
|
117
|
+
|
|
118
|
+
const divTag = document.createElement('div')
|
|
119
|
+
divTag.id = 'wahl-o-mat'
|
|
120
|
+
rootElement.insertBefore(divTag, null)
|
|
121
|
+
loadScript(
|
|
122
|
+
'wahl-o-mat-js',
|
|
123
|
+
'https://static.hr.de/wahl-o-mat/embed.js',
|
|
124
|
+
true
|
|
125
|
+
)
|
|
126
|
+
|
|
127
|
+
}
|
|
128
|
+
|
|
113
129
|
const createWahlEmbed = function () {
|
|
114
130
|
let script = document.createElement('script')
|
|
115
131
|
let cleanUrl
|
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.67.
|
|
9
|
+
"version": "1.67.2",
|
|
10
10
|
"scripts": {
|
|
11
11
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
12
12
|
"storybook": "storybook dev -p 6006 public",
|
|
@@ -27,7 +27,8 @@
|
|
|
27
27
|
"preparePartialsForDelivery": "gulp preparePartialsForDelivery",
|
|
28
28
|
"create-modernizr-config": "gulp createModernizrConfig",
|
|
29
29
|
"merge-locatags": "gulp mergeLocatags",
|
|
30
|
-
"prepare": "yarn build"
|
|
30
|
+
"prepare": "yarn build",
|
|
31
|
+
"test-storybook": "test-storybook"
|
|
31
32
|
},
|
|
32
33
|
"browserslist": [
|
|
33
34
|
"last 2 versions",
|
|
@@ -46,12 +47,16 @@
|
|
|
46
47
|
"@storybook/addon-actions": "7.5.3",
|
|
47
48
|
"@storybook/addon-console": "^2.0.0",
|
|
48
49
|
"@storybook/addon-essentials": "7.5.3",
|
|
50
|
+
"@storybook/addon-interactions": "7.6.16",
|
|
49
51
|
"@storybook/addon-links": "^7.2.1",
|
|
50
52
|
"@storybook/addon-styling": "^1.3.5",
|
|
51
53
|
"@storybook/addons": "^7.2.1",
|
|
52
54
|
"@storybook/blocks": "7.2.1",
|
|
53
55
|
"@storybook/html": "^7.2.1",
|
|
54
56
|
"@storybook/html-webpack5": "7.2.1",
|
|
57
|
+
"@storybook/jest": "^0.2.3",
|
|
58
|
+
"@storybook/test-runner": "~0.16.0",
|
|
59
|
+
"@storybook/testing-library": "^0.2.2",
|
|
55
60
|
"@storybook/theming": "^7.2.1",
|
|
56
61
|
"auto": "^11.0.5",
|
|
57
62
|
"autoprefixer": "^10.4.2",
|
|
@@ -100,6 +100,9 @@ const ExternalService = function (context) {
|
|
|
100
100
|
case 'wahlkreiskarte':
|
|
101
101
|
createWahlEmbed()
|
|
102
102
|
break
|
|
103
|
+
case 'wahlomat':
|
|
104
|
+
createWahlOMatEmbed()
|
|
105
|
+
break
|
|
103
106
|
default:
|
|
104
107
|
console.error('No JS Config for external service ' + id)
|
|
105
108
|
break
|
|
@@ -110,6 +113,19 @@ const ExternalService = function (context) {
|
|
|
110
113
|
}
|
|
111
114
|
}
|
|
112
115
|
|
|
116
|
+
const createWahlOMatEmbed = function () {
|
|
117
|
+
|
|
118
|
+
const divTag = document.createElement('div')
|
|
119
|
+
divTag.id = 'wahl-o-mat'
|
|
120
|
+
rootElement.insertBefore(divTag, null)
|
|
121
|
+
loadScript(
|
|
122
|
+
'wahl-o-mat-js',
|
|
123
|
+
'https://static.hr.de/wahl-o-mat/embed.js',
|
|
124
|
+
true
|
|
125
|
+
)
|
|
126
|
+
|
|
127
|
+
}
|
|
128
|
+
|
|
113
129
|
const createWahlEmbed = function () {
|
|
114
130
|
let script = document.createElement('script')
|
|
115
131
|
let cleanUrl
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { userEvent, within } from '@storybook/testing-library';
|
|
2
|
+
|
|
1
3
|
const handlebars = require('hrHandlebars')
|
|
2
4
|
|
|
3
5
|
const defaultModalTemplate = (args, { globals: { customConditionalToolbar } }) => {
|
|
@@ -28,7 +30,7 @@ const userConsentModalTemplate = (args, { globals: { customConditionalToolbar }
|
|
|
28
30
|
{{> components/modal/user_consent _headline=(loca "modal_user_consent_headline") _text=(loca "modal_user_consent_text") _labelOk=(loca "modal_user_consent_label_ok") _labelCancel=(loca "modal_user_consent_label_cancel")}}
|
|
29
31
|
{{/components/modal/modal}}
|
|
30
32
|
|
|
31
|
-
<a href="https://hessenschau.de" class="js-user-consent-needed" rel="noopener" target="_blank">User Consent Modal</a>
|
|
33
|
+
<a data-testid="modal-hook" href="https://hessenschau.de" class="js-user-consent-needed" rel="noopener" target="_blank">User Consent Modal</a>
|
|
32
34
|
`)
|
|
33
35
|
return hbsTemplate({ brand, ...args })
|
|
34
36
|
}
|
|
@@ -77,3 +79,19 @@ export const userConsentModal = {
|
|
|
77
79
|
},
|
|
78
80
|
}
|
|
79
81
|
|
|
82
|
+
export const openedUserConsentModal = {
|
|
83
|
+
render: userConsentModalTemplate.bind({}),
|
|
84
|
+
name: 'User Consent Modal geΓΆffnet',
|
|
85
|
+
args: {
|
|
86
|
+
_trigger: '.js-user-consent-needed',
|
|
87
|
+
_type: 'userConsent'
|
|
88
|
+
},
|
|
89
|
+
play: async ({ canvasElement }) => {
|
|
90
|
+
const canvas = within(canvasElement);
|
|
91
|
+
|
|
92
|
+
const link = canvas.getByTestId('modal-hook');
|
|
93
|
+
|
|
94
|
+
await userEvent.click(link);
|
|
95
|
+
},
|
|
96
|
+
}
|
|
97
|
+
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { resetComponents } from '@storybook/components'
|
|
2
|
+
import { userEvent, within } from '@storybook/testing-library';
|
|
2
3
|
import subscribeButtonJson from 'components/teaser/fixtures/teaser_podcast.json'
|
|
3
4
|
|
|
4
5
|
import subscribeButton from 'components/podcast/components/podcast_subscribe_button.hbs'
|
|
@@ -44,8 +45,12 @@ export const SubscribeButtonOpen = {
|
|
|
44
45
|
render: Template.bind({}),
|
|
45
46
|
name: 'Subscribe Button Open',
|
|
46
47
|
|
|
47
|
-
args:
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
args: subscribeButtonJson.logicItem.includeModel.podcastChannel,
|
|
49
|
+
play: async ({ canvasElement }) => {
|
|
50
|
+
const canvas = within(canvasElement);
|
|
51
|
+
|
|
52
|
+
const button = canvas.getByRole('button');
|
|
53
|
+
|
|
54
|
+
await userEvent.click(button);
|
|
50
55
|
},
|
|
51
56
|
}
|