hr-design-system-handlebars 1.67.2 → 1.67.4
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/icons/icons/svgmap/print.svg +16 -16
- package/dist/assets/icons/icons/svgmap.min.svg +1 -1
- package/dist/assets/index.css +3 -9
- package/dist/assets/js/components/site_header/mainNavigationHandler.alpine.js +1 -1
- package/dist/views/components/page/index/page_test_story.hbs +14 -19
- package/dist/views/components/page/story/story_article.hbs +6 -3
- package/dist/views/components/social_sharing/social_sharing_compact.hbs +42 -44
- package/dist/views/components/social_sharing/social_sharing_compact_icons.hbs +10 -1
- package/dist/views_static/components/page/index/page_test_story.hbs +14 -19
- package/dist/views_static/components/page/story/story_article.hbs +6 -3
- package/dist/views_static/components/social_sharing/social_sharing_compact.hbs +42 -44
- package/dist/views_static/components/social_sharing/social_sharing_compact_icons.hbs +10 -1
- package/package.json +1 -1
- package/src/assets/icons/icons/svgmap/print.svg +16 -16
- package/src/assets/icons/icons/svgmap.min.svg +1 -1
- package/src/stories/views/components/page/index/page_test_story.hbs +14 -19
- package/src/stories/views/components/page/story/story_article.hbs +6 -3
- package/src/stories/views/components/site_header/mainNavigationHandler.alpine.js +1 -1
- package/src/stories/views/components/social_sharing/social_sharing_compact.hbs +42 -44
- package/src/stories/views/components/social_sharing/social_sharing_compact.stories.js +5 -12
- package/src/stories/views/components/social_sharing/social_sharing_compact_icons.hbs +10 -1
|
@@ -20,9 +20,12 @@
|
|
|
20
20
|
{{/if}}
|
|
21
21
|
{{/with}}
|
|
22
22
|
{{/unless}}
|
|
23
|
-
|
|
24
|
-
{{
|
|
25
|
-
|
|
23
|
+
|
|
24
|
+
{{#unless _webview}}
|
|
25
|
+
{{~#with this.socialSharing ~}}
|
|
26
|
+
{{> components/social_sharing/social_sharing_copytext}}
|
|
27
|
+
{{~/with~}}
|
|
28
|
+
{{/unless}}
|
|
26
29
|
{{~> components/content/copytext/copytext _isWebview=_webview ~}}
|
|
27
30
|
|
|
28
31
|
{{> components/page/components/comments }}
|
|
@@ -52,7 +52,7 @@ export default () => ({
|
|
|
52
52
|
},
|
|
53
53
|
|
|
54
54
|
checkFooterTopForSharingBottomPos(){
|
|
55
|
-
this.$store.footerIsVisible ? this.$store.sharingBottomPos.current = window.innerHeight - document.querySelector('.js-pageFooter').getBoundingClientRect().top + 16 +'px' : null
|
|
55
|
+
this.$store.footerIsVisible ? this.$store.sharingBottomPos.current = Math.round(window.innerHeight - document.querySelector('.js-pageFooter').getBoundingClientRect().top) + 16 +'px' : null
|
|
56
56
|
},
|
|
57
57
|
|
|
58
58
|
//Holds the percentage of scrolled viewport
|
|
@@ -1,48 +1,47 @@
|
|
|
1
|
-
|
|
2
|
-
x-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
<div :class="{ '
|
|
11
|
-
<div :
|
|
12
|
-
:
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
</button>
|
|
1
|
+
{{~#with this.socialSharing ~}}
|
|
2
|
+
<div x-data="stickySharingHandler"
|
|
3
|
+
x-on:keydown.escape.prevent.stop="close($refs.button)"
|
|
4
|
+
x-on:focusin.window="! $refs.panel.contains($event.target) && close()"
|
|
5
|
+
x-id="['dropdown-button']"
|
|
6
|
+
class="flex self-center justify-end ml-3 grow"
|
|
7
|
+
x-intersect:leave="$store.sharingIsVisible=false"
|
|
8
|
+
x-intersect:enter="$store.sharingIsVisible=true"
|
|
9
|
+
>
|
|
10
|
+
<div :class="{ 'grid grid-page z-110 fixed bottom-feature-box-height left-0 w-full': $store.sharingIsVisible == false}">
|
|
11
|
+
<div :class="{ 'flex justify-start col-full sm:col-main relative': $store.sharingIsVisible == false }">
|
|
12
|
+
<div :style="($store.footerIsVisible && !$screen('lg')) && {bottom:$store.sharingBottomPos.current}"
|
|
13
|
+
:class="{ 'bottom-5 flex-col absolute mt-3 rounded-md': $store.sharingIsVisible == false && $store.footerIsVisible == false,
|
|
14
|
+
'flex-col absolute mt-3' : $store.footerIsVisible == true }"
|
|
15
|
+
class="flex self-center gap-3 bg-white left-5">
|
|
16
|
+
<button
|
|
17
|
+
class="order-2 p-2 text-white border border-button bg-button ds-button font-heading hover:bg-button--dark hover:border-button--dark active:bg-button--dark group"
|
|
18
|
+
x-show="!$screen('lg')"
|
|
19
|
+
x-ref="button"
|
|
20
|
+
x-on:click="toggle()"
|
|
21
|
+
:aria-expanded="open"
|
|
22
|
+
:aria-controls="$id('dropdown-button')">
|
|
23
|
+
{{> components/base/image/icon _addClass="w-5 h-5 fill-current group-hover:fill-link--dark" _icon="sharing" _iconmap="icons" }}
|
|
24
|
+
</button>
|
|
26
25
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
</
|
|
26
|
+
<!-- Panel -->
|
|
27
|
+
<div
|
|
28
|
+
x-ref="panel"
|
|
29
|
+
x-show="open || $screen('lg') && $store.sharingIsOpen == true || $screen('lg') && $store.sharingIsVisible == true"
|
|
30
|
+
x-transition.origin.bottom.right
|
|
31
|
+
x-on:click.outside="close($refs.button)"
|
|
32
|
+
:id="$id('dropdown-button')"
|
|
33
|
+
class="self-center bg-white"
|
|
34
|
+
:class="$store.sharingIsVisible == true ? 'h-8 absolute right-[68px] md:relative md:right-0 md:h-auto' : 'relative right-0 md:h-auto lg:hidden '"
|
|
35
|
+
>
|
|
36
|
+
<ul class="flex gap-3" :class="{ 'flex-col': $store.sharingIsVisible == false }">
|
|
37
|
+
{{> components/social_sharing/social_sharing_compact_icons }}
|
|
38
|
+
</ul>
|
|
39
|
+
</div>
|
|
41
40
|
</div>
|
|
42
41
|
</div>
|
|
43
42
|
</div>
|
|
44
43
|
</div>
|
|
45
|
-
|
|
44
|
+
{{/with}}
|
|
46
45
|
<script>
|
|
47
46
|
function stickySharingHandler(){
|
|
48
47
|
return {
|
|
@@ -55,9 +54,9 @@
|
|
|
55
54
|
var isMobile= isMobileApple || isMobileOther;
|
|
56
55
|
if (navigator.share && isMobile) {
|
|
57
56
|
navigator.share({
|
|
58
|
-
title:
|
|
59
|
-
text: '
|
|
60
|
-
url:
|
|
57
|
+
title: document.title,
|
|
58
|
+
text: 'Schau mal was ich auf hessenschau.de gefunden habe!',
|
|
59
|
+
url: window.location.href,
|
|
61
60
|
})
|
|
62
61
|
.then(() => console.log('Shared successfully'))
|
|
63
62
|
.catch((error) => console.error('Sharing failed:', error));
|
|
@@ -73,7 +72,6 @@
|
|
|
73
72
|
},
|
|
74
73
|
close(focusAfter) {
|
|
75
74
|
if (! this.open) return
|
|
76
|
-
|
|
77
75
|
this.open = false
|
|
78
76
|
this.$store.sharingIsOpen = false
|
|
79
77
|
focusAfter && focusAfter.focus()
|
|
@@ -1,25 +1,18 @@
|
|
|
1
1
|
import story_template from './social_sharing_compact.hbs'
|
|
2
|
+
import socialSharing from '../page/story/fixtures/story.json'
|
|
2
3
|
|
|
4
|
+
console.log(socialSharing)
|
|
3
5
|
const Template = ({ ...args }) => {
|
|
4
|
-
// You can either use a function to create DOM elements or use a plain html string!
|
|
5
|
-
// return `<span>${topline}</span>`;
|
|
6
6
|
return story_template({ ...args })
|
|
7
7
|
}
|
|
8
8
|
|
|
9
9
|
export default {
|
|
10
10
|
title: 'Komponenten/Social Sharing',
|
|
11
|
-
}
|
|
11
|
+
}
|
|
12
12
|
|
|
13
13
|
export const Default = {
|
|
14
14
|
render: Template.bind({}),
|
|
15
15
|
name: 'Social Sharing Kompakt',
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
decorators: [
|
|
19
|
-
(Story) => {
|
|
20
|
-
return `<div class="w-full mt-40 h-[500rem]">
|
|
21
|
-
${Story()}
|
|
22
|
-
</div>`
|
|
23
|
-
},
|
|
24
|
-
],
|
|
16
|
+
args: socialSharing
|
|
17
|
+
|
|
25
18
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
{{~#with this.twitterLink ~}}
|
|
1
2
|
<li>
|
|
2
3
|
<a class="{{if (isUserConsentNeeded this) 'js-user-consent-needed ' ''}}{{#with ../../this.content.trackingData}} js-load{{/with}} flex order-2 ds-button font-heading active:scale-95 w-8 h-8"
|
|
3
4
|
|
|
@@ -12,6 +13,8 @@
|
|
|
12
13
|
{{~> components/base/image/icon _addClass="w-full h-full fill-link hover:scale-105 " _icon="x-ds" _iconmap="icons" ~}}
|
|
13
14
|
</a>
|
|
14
15
|
</li>
|
|
16
|
+
{{/with}}
|
|
17
|
+
{{~#with this.facebookLink}}
|
|
15
18
|
<li class="">
|
|
16
19
|
<a class="{{if (isUserConsentNeeded this) 'js-user-consent-needed ' ''}}{{#with ../../this.content.trackingData}} js-load{{/with}} flex order-2 ds-button font-heading active:scale-95 w-8 h-8"
|
|
17
20
|
|
|
@@ -26,6 +29,8 @@
|
|
|
26
29
|
{{~> components/base/image/icon _addClass="w-full h-full fill-link hover:scale-105" _icon="facebook-ds" _iconmap="icons" ~}}
|
|
27
30
|
</a>
|
|
28
31
|
</li>
|
|
32
|
+
{{/with}}
|
|
33
|
+
{{~#with this.whatsappLink}}
|
|
29
34
|
<li class="">
|
|
30
35
|
<a class="{{if (isUserConsentNeeded this) 'js-user-consent-needed ' ''}}{{#with ../../this.content.trackingData}} js-load{{/with}} flex order-2 ds-button font-heading active:scale-95 w-8 h-8"
|
|
31
36
|
|
|
@@ -40,6 +45,8 @@
|
|
|
40
45
|
{{~> components/base/image/icon _addClass="w-full h-full fill-link hover:scale-105" _icon="whatsapp-ds" _iconmap="icons" ~}}
|
|
41
46
|
</a>
|
|
42
47
|
</li>
|
|
48
|
+
{{/with}}
|
|
49
|
+
{{~#with this.mailtoLink}}
|
|
43
50
|
<li class="">
|
|
44
51
|
<a class="{{if (isUserConsentNeeded this) 'js-user-consent-needed ' ''}}{{#with ../../this.content.trackingData}} js-load{{/with}} flex order-2 ds-button font-heading active:scale-95 w-8 h-8"
|
|
45
52
|
|
|
@@ -52,6 +59,8 @@
|
|
|
52
59
|
{{~> components/base/image/icon _addClass="w-full h-full fill-link hover:scale-105" _icon="kontakt-ds" _iconmap="icons" ~}}
|
|
53
60
|
</a>
|
|
54
61
|
</li>
|
|
62
|
+
{{/with}}
|
|
63
|
+
|
|
55
64
|
<li class="">
|
|
56
65
|
<a class="{{#with ../this.content.trackingData}} js-load{{/with}} flex order-2 ds-button font-heading active:scale-95 w-8 h-8"
|
|
57
66
|
|
|
@@ -63,4 +72,4 @@
|
|
|
63
72
|
>
|
|
64
73
|
{{~> components/base/image/icon _addClass="w-full h-full fill-link hover:scale-105" _icon="copy-ds" _iconmap="icons" ~}}
|
|
65
74
|
</a>
|
|
66
|
-
</li>
|
|
75
|
+
</li>
|