hr-design-system-handlebars 1.11.9 → 1.11.10

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.11.10 (Mon Apr 17 2023)
2
+
3
+ #### 🐛 Bug Fix
4
+
5
+ - DPE 2227: JSON modellieren für Storybook [#605](https://github.com/mumprod/hr-design-system-handlebars/pull/605) (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.11.9 (Wed Apr 12 2023)
2
15
 
3
16
  #### 🐛 Bug Fix
@@ -2679,7 +2679,7 @@ video {
2679
2679
  transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
2680
2680
  }
2681
2681
  .counter-reset {
2682
- counter-reset: cnt1681323182167;
2682
+ counter-reset: cnt1681728211612;
2683
2683
  }
2684
2684
  .line-clamp-4 {
2685
2685
  overflow: hidden;
@@ -2909,7 +2909,7 @@ video {
2909
2909
  --tw-ring-color: rgba(255, 255, 255, 0.5);
2910
2910
  }
2911
2911
  .-ordered {
2912
- counter-increment: cnt1681323182167 1;
2912
+ counter-increment: cnt1681728211612 1;
2913
2913
  }
2914
2914
  .-ordered::before {
2915
2915
  position: absolute;
@@ -2925,7 +2925,7 @@ video {
2925
2925
  letter-spacing: .0125em;
2926
2926
  --tw-text-opacity: 1;
2927
2927
  color: rgba(0, 0, 0, var(--tw-text-opacity));
2928
- content: counter(cnt1681323182167);
2928
+ content: counter(cnt1681728211612);
2929
2929
  }
2930
2930
  /*! ****************************/
2931
2931
  /*! text-shadow */
@@ -38,4 +38,7 @@
38
38
  {{#case "components/multimedia/livestream/label_byline.ssi"}}
39
39
  {{> components/multimedia/livestream/label_byline.ssi _context}}
40
40
  {{/case}}
41
+ {{#case "components/teaser/ticker/teaser_ticker"}}
42
+ {{> components/teaser/ticker/teaser_ticker}}
43
+ {{/case}}
41
44
  {{/switch}}
@@ -0,0 +1,29 @@
1
+ <article class="items-start relative col-span-12 flex {{if this.displayTeaserBodyAsImageOverlay '' 'gap-y-3'}} gap-x-4
2
+ {{~inline-switch this.teaserSize '["25","33","50"]' '[" md:col-span-3"," md:col-span-4"," md:col-span-6",""]'}}
3
+ {{~#if this.isMobile1to1}} js-is1to1 px-5 sm:px-0 md:flex-col{{else}} flex-col{{/if~}}
4
+ "
5
+ x-data="{ avStart: false }"
6
+ {{#if this.isMobile1to1}}
7
+ :class="avStart ? 'flex-col' : 'flex-row'"
8
+ {{/if}}
9
+ >
10
+ {{#if this.teaserImage}}
11
+ <figure class="{{> components/teaser/utilities/teaser_image_cypress_hook_classes}}relative
12
+ {{~#if this.isMobile1to1}} basis-2/5 w-2/5 ar-1-1 md:basis-full md:w-full md:ar-16-9{{else}} ar-16-9 w-full{{/if~}}"
13
+ {{~#if this.isMobile1to1}} :class="{'ar-16-9 w-full basis-full': avStart,'ar-1-1 basis-2/5 w-2/5':!avStart}"{{/if}} >
14
+ {{> components/teaser/components/teaser_lead _isMobile1to1=this.isMobile1to1 _teaserSize=this.teaserSize _teaserType=this.teaserType _aspectRatio=(if this.isMobile1to1 'ar-1-1 md:ar-16-9' (inline-switch this.teaserSize '["25"]' '["ar-1-1 md:ar-16-9", "ar-16-9"]')) }}
15
+ </figure>
16
+ {{#if this.displayTeaserBodyAsImageOverlay}}
17
+ {{#decorator 'components/teaser/components/teaser_image_overlay' _noOverlayInMobileViewports=true _cssClasses=" relative md:absolute w-full bottom-0"}}
18
+ <div class="flex flex-col items-center justify-center p-4 border-r border-gray-400 border-dashed basis-1/12">
19
+ {{> components/event/instant_dates}}
20
+ </div>
21
+ {{> components/teaser/components/teaser_body _outerCssClasses=(if this.isMobile1to1 'basis-11/12 py-4 sm:px-4 basis-3/5 w-3/5 md:basis-full md:w-full' 'basis-11/12 py-4 sm:px-4')}}
22
+ {{/decorator}}
23
+ {{else}}
24
+ {{> components/teaser/components/teaser_body _outerCssClasses=(if this.isMobile1to1 'basis-3/5 w-3/5 md:basis-full md:w-full')}}
25
+ {{/if}}
26
+ {{else}}
27
+ {{> components/teaser/components/teaser_body _outerCssClasses="basis-full"}}
28
+ {{/if}}
29
+ </article>
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.11.9",
9
+ "version": "1.11.10",
10
10
  "scripts": {
11
11
  "test": "echo \"Error: no test specified\" && exit 1",
12
12
  "storybook": "start-storybook -p 6006 public",
@@ -0,0 +1,121 @@
1
+ {
2
+ "tickerTeaser": {
3
+ "isSsi": true,
4
+ "logicItem": {
5
+ "includePath": "components/teaser/ticker/teaser_ticker",
6
+ "includeModel": {
7
+ "byline": "Byline",
8
+ "title": "Eintracht: +++ Eintracht-Halbfinale terminiert +++ Frankfurter Gala in Barcelona jährt sich +++ Berichte: Aouar in Gesprächen mit AS Rom +++",
9
+ "topline": "",
10
+ "headingFontVariant": "serif",
11
+ "extendedTitle": "",
12
+ "teaserType": "standard",
13
+ "teaserSize": "hero",
14
+ "realTeaserSize": "hero",
15
+ "isMobile1to1": false,
16
+ "teaserDate": {
17
+ "htmlDateTime": "2022-04-17T19:30+0200",
18
+ "htmlDate": "20.02.1983",
19
+ "date": "17.04.22",
20
+ "dateSeparatorTime": "17.04.22, 19:30"
21
+ },
22
+ "hasByline": false,
23
+ "teaserInfo": {
24
+ "showTeaserInfo": false,
25
+ "showTeaserInfoSection": true,
26
+ "showTeaserInfoChannel": false,
27
+ "showTeaserInfoAll": false,
28
+ "showTeaserInfoDate": false,
29
+ "showTeaserInfoDateTime": true,
30
+ "showTeaserInfoProgramRef": false
31
+ },
32
+ "teaserImage": {
33
+ "@->jsoninclude": "teaser/teaser_images.inc.json",
34
+ "@->contentpath": "teaser_standard",
35
+ "@->replaceToken": [
36
+ {
37
+ "@->token": "image",
38
+ "@->value": "sportschau-image-5708"
39
+ }
40
+ ]
41
+ },
42
+ "displayTeaserBodyAsImageOverlay": false,
43
+ "hasMediaButtons": false,
44
+ "dontLazyload": true,
45
+ "isStandardTeaser": true,
46
+ "isHeroTeaser": true,
47
+ "isMediaTeaser": false,
48
+ "isGuide": false,
49
+ "isProgram": false,
50
+ "isEvent": false,
51
+ "isTicker": true,
52
+ "isAudio": false,
53
+ "isVideo": false,
54
+ "isPodcast": false,
55
+ "isPodcastEpisode": false,
56
+ "isExtOrBrandLink": false,
57
+ "isAuthor": false,
58
+ "copyright": "Copyright Text",
59
+ "audioAuthor": "Audio Author",
60
+ "hasStatus": false,
61
+ "hasTeaserItem": true,
62
+ "moreThenOneEvent": false,
63
+ "moreThenTwoEvents": false,
64
+ "firstInstant": {
65
+ "startDate": {
66
+ "monthNameShort": "APR",
67
+ "weekdayNameShort": "Do",
68
+ "day": "9"
69
+ }
70
+ },
71
+ "lastInstant": {
72
+ "startDate": {
73
+ "monthNameShort": "APR",
74
+ "weekdayNameShort": "Fr",
75
+ "day": "10"
76
+ }
77
+ },
78
+ "allowAVConsumption": false,
79
+ "displayEpgInfos": false,
80
+ "aspectRatio": "ar--teaserTop",
81
+ "hideGeotag": false,
82
+ "hideEditableByline": true,
83
+ "doTracking": true,
84
+ "trackingForArdMediatheksLink": false,
85
+ "showMediatheksLink": false,
86
+ "showAirdate": false,
87
+ "showProfileInfoAsByline": false,
88
+ "obsolet_brandOfTeaser": "hessenschau",
89
+ "documentSection": "Gesellschaft",
90
+ "headlineTag": "h1",
91
+ "icon": "ortsmarke",
92
+ "imageVariant": "topteaser",
93
+ "shorttext": "Hier bekommen Sie immer die neuesten Nachrichten über Eintracht Frankfurt.",
94
+ "hideBylineAndShorttext": false,
95
+ "sophoraId": "rueckkehr-nach-abschiebung-wolfhagen--100",
96
+ "profiles": "",
97
+ "teaserLead": {
98
+ "avDocument": "",
99
+ "image": ""
100
+ },
101
+ "geotag": [
102
+ {
103
+ "title": "Frankfurt"
104
+ }
105
+ ],
106
+ "link": {
107
+ "url": "/teaser1",
108
+ "webviewUrl": "/teaser1#webview",
109
+ "isTargetBlank": false,
110
+ "hasIcon": false,
111
+ "iconName": "iconName",
112
+ "readMoreText": {
113
+ "readMoreScreenreader": "Zum Artikel",
114
+ "readMore": "mehr",
115
+ "readMoreLong": "read More Long"
116
+ }
117
+ }
118
+ }
119
+ }
120
+ }
121
+ }
@@ -0,0 +1,25 @@
1
+ {
2
+ "@->jsoninclude": "teaser/teaser_ticker.inc.json",
3
+ "@->contentpath": "tickerTeaser",
4
+ "@->overrides": [
5
+ {
6
+ "@->contentpath": "logicItem.includeModel.teaserSize",
7
+ "@->value": "100"
8
+ },
9
+ {
10
+ "@->contentpath": "logicItem.includeModel.realTeaserSize",
11
+ "@->value": "100"
12
+ },
13
+ {
14
+ "@->contentpath": "logicItem.includeModel.topline",
15
+ "@->value": ""
16
+ },
17
+ {
18
+ "@->contentpath": "logicItem.includeModel.label",
19
+ "@->value": {
20
+ "@->jsoninclude": "teaser/teaser_labels.inc.json",
21
+ "@->contentpath": "ticker"
22
+ }
23
+ }
24
+ ]
25
+ }
@@ -38,4 +38,7 @@
38
38
  {{#case "components/multimedia/livestream/label_byline.ssi"}}
39
39
  {{> components/multimedia/livestream/label_byline.ssi _context}}
40
40
  {{/case}}
41
+ {{#case "components/teaser/ticker/teaser_ticker"}}
42
+ {{> components/teaser/ticker/teaser_ticker}}
43
+ {{/case}}
41
44
  {{/switch}}
@@ -0,0 +1 @@
1
+ {"isSsi":true,"logicItem":{"includePath":"components/teaser/ticker/teaser_ticker","includeModel":{"byline":"Byline","title":"Eintracht: +++ Eintracht-Halbfinale terminiert +++ Frankfurter Gala in Barcelona jährt sich +++ Berichte: Aouar in Gesprächen mit AS Rom +++","topline":"","headingFontVariant":"serif","extendedTitle":"","teaserType":"standard","teaserSize":"100","realTeaserSize":"100","isMobile1to1":false,"teaserDate":{"htmlDateTime":"2022-04-17T19:30+0200","htmlDate":"20.02.1983","date":"17.04.22","dateSeparatorTime":"17.04.22, 19:30"},"hasByline":false,"teaserInfo":{"showTeaserInfo":false,"showTeaserInfoSection":true,"showTeaserInfoChannel":false,"showTeaserInfoAll":false,"showTeaserInfoDate":false,"showTeaserInfoDateTime":true,"showTeaserInfoProgramRef":false},"teaserImage":{"alttext":"Lorem ipsum","copyrightWithLinks":"Vorname Nachname","responsiveImage":{"asPicture":false,"asImage":true,"fallback":"images/sportschau-image-5708_v-16to9__medium.jpg","sources":[{"sizes":"(min-width: 1024px) 960px, (min-width: 640px) calc(100vw - 4rem), 100vw","srcset":"images/sportschau-image-5708_v-16to9__small.jpg 320w, images/sportschau-image-5708_v-16to9__medium.jpg 480w, images/sportschau-image-5708_v-16to9__medium__extended.jpg 640w, images/sportschau-image-5708_v-16to9.jpg 960w, images/sportschau-image-5708_v-16to9__retina.jpg 1920w"}]}},"displayTeaserBodyAsImageOverlay":false,"hasMediaButtons":false,"dontLazyload":true,"isStandardTeaser":true,"isHeroTeaser":true,"isMediaTeaser":false,"isGuide":false,"isProgram":false,"isEvent":false,"isTicker":true,"isAudio":false,"isVideo":false,"isPodcast":false,"isPodcastEpisode":false,"isExtOrBrandLink":false,"isAuthor":false,"copyright":"Copyright Text","audioAuthor":"Audio Author","hasStatus":false,"hasTeaserItem":true,"moreThenOneEvent":false,"moreThenTwoEvents":false,"firstInstant":{"startDate":{"monthNameShort":"APR","weekdayNameShort":"Do","day":"9"}},"lastInstant":{"startDate":{"monthNameShort":"APR","weekdayNameShort":"Fr","day":"10"}},"allowAVConsumption":false,"displayEpgInfos":false,"aspectRatio":"ar--teaserTop","hideGeotag":false,"hideEditableByline":true,"doTracking":true,"trackingForArdMediatheksLink":false,"showMediatheksLink":false,"showAirdate":false,"showProfileInfoAsByline":false,"obsolet_brandOfTeaser":"hessenschau","documentSection":"Gesellschaft","headlineTag":"h1","icon":"ortsmarke","imageVariant":"topteaser","shorttext":"Hier bekommen Sie immer die neuesten Nachrichten über Eintracht Frankfurt.","hideBylineAndShorttext":false,"sophoraId":"rueckkehr-nach-abschiebung-wolfhagen--100","profiles":"","teaserLead":{"avDocument":"","image":""},"geotag":[{"title":"Frankfurt"}],"link":{"url":"/teaser1","webviewUrl":"/teaser1#webview","isTargetBlank":false,"hasIcon":false,"iconName":"iconName","readMoreText":{"readMoreScreenreader":"Zum Artikel","readMore":"mehr","readMoreLong":"read More Long"}},"label":{"type":"ticker","loca":"label_ticker","byline":{"bylineSsi":"BylineText aus ssi","bylineText":"BylineText"}}}}}
@@ -0,0 +1,29 @@
1
+ <article class="items-start relative col-span-12 flex {{if this.displayTeaserBodyAsImageOverlay '' 'gap-y-3'}} gap-x-4
2
+ {{~inline-switch this.teaserSize '["25","33","50"]' '[" md:col-span-3"," md:col-span-4"," md:col-span-6",""]'}}
3
+ {{~#if this.isMobile1to1}} js-is1to1 px-5 sm:px-0 md:flex-col{{else}} flex-col{{/if~}}
4
+ "
5
+ x-data="{ avStart: false }"
6
+ {{#if this.isMobile1to1}}
7
+ :class="avStart ? 'flex-col' : 'flex-row'"
8
+ {{/if}}
9
+ >
10
+ {{#if this.teaserImage}}
11
+ <figure class="{{> components/teaser/utilities/teaser_image_cypress_hook_classes}}relative
12
+ {{~#if this.isMobile1to1}} basis-2/5 w-2/5 ar-1-1 md:basis-full md:w-full md:ar-16-9{{else}} ar-16-9 w-full{{/if~}}"
13
+ {{~#if this.isMobile1to1}} :class="{'ar-16-9 w-full basis-full': avStart,'ar-1-1 basis-2/5 w-2/5':!avStart}"{{/if}} >
14
+ {{> components/teaser/components/teaser_lead _isMobile1to1=this.isMobile1to1 _teaserSize=this.teaserSize _teaserType=this.teaserType _aspectRatio=(if this.isMobile1to1 'ar-1-1 md:ar-16-9' (inline-switch this.teaserSize '["25"]' '["ar-1-1 md:ar-16-9", "ar-16-9"]')) }}
15
+ </figure>
16
+ {{#if this.displayTeaserBodyAsImageOverlay}}
17
+ {{#decorator 'components/teaser/components/teaser_image_overlay' _noOverlayInMobileViewports=true _cssClasses=" relative md:absolute w-full bottom-0"}}
18
+ <div class="flex flex-col items-center justify-center p-4 border-r border-gray-400 border-dashed basis-1/12">
19
+ {{> components/event/instant_dates}}
20
+ </div>
21
+ {{> components/teaser/components/teaser_body _outerCssClasses=(if this.isMobile1to1 'basis-11/12 py-4 sm:px-4 basis-3/5 w-3/5 md:basis-full md:w-full' 'basis-11/12 py-4 sm:px-4')}}
22
+ {{/decorator}}
23
+ {{else}}
24
+ {{> components/teaser/components/teaser_body _outerCssClasses=(if this.isMobile1to1 'basis-3/5 w-3/5 md:basis-full md:w-full')}}
25
+ {{/if}}
26
+ {{else}}
27
+ {{> components/teaser/components/teaser_body _outerCssClasses="basis-full"}}
28
+ {{/if}}
29
+ </article>
@@ -0,0 +1,33 @@
1
+ import { ArgsTable, Meta, Story, Canvas, Preview } from '@storybook/addon-docs'
2
+
3
+ import ticker from './teaser_ticker.hbs'
4
+ import tickerTeaser100Standard from '../fixtures/ticker_teaser_standard_100.json'
5
+
6
+ <Meta
7
+ title="Komponenten/Teaser/Ticker"
8
+ parameters={{
9
+ layout: '',
10
+ }}
11
+ argTypes={{}}
12
+ decorators={[
13
+ (Story) => {
14
+ return `<div class="grid grid-page"><div class="grid grid-cols-12 py-6 col-full gap-x-6 gap-y-6 sm:px-9.5 sm:col-main">
15
+ ${Story()}
16
+ </div></div>`
17
+ },
18
+ ]}
19
+ />
20
+
21
+ export const Template = (args, { globals: { customConditionalToolbar } }) => {
22
+ // You can either use a function to create DOM elements or use a plain html string!
23
+ // return `<div>${label}</div>`;
24
+ let brand =
25
+ undefined !== customConditionalToolbar ? customConditionalToolbar['brands'] : 'hessenschau'
26
+ return ticker({ brand, ...args })
27
+ }
28
+
29
+ <Preview withToolbar>
30
+ <Story name="Ticker Teaser 100" args={tickerTeaser100Standard.logicItem.includeModel} >
31
+ {Template.bind({})}
32
+ </Story>
33
+ </Preview>