@bonniernews/dn-design-system-web 8.0.9 → 8.1.0
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 +18 -0
- package/assets/article-image/article-image.njk +1 -1
- package/components/teaser-list-vertical/README.md +1 -1
- package/components/teaser-list-vertical/teaser-list-vertical.njk +14 -6
- package/components/teaser-list-vertical/teaser-list-vertical.scss +17 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,24 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## 8.1.0 (2023-11-13)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* **web:** implement vignette, highlight, and italic headlines on media lists ([#1089](https://github.com/BonnierNews/dn-design-system/issues/1089)) ([5ffb9c4](https://github.com/BonnierNews/dn-design-system/commit/5ffb9c4ef06afc9880b802e010faa25fcd984bdd))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
## 8.0.10 (2023-11-10)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Bug Fixes
|
|
19
|
+
|
|
20
|
+
* **web:** remove legacy class name for article-full-width-element ([#1082](https://github.com/BonnierNews/dn-design-system/issues/1082)) ([8eb02d4](https://github.com/BonnierNews/dn-design-system/commit/8eb02d442470fd3364c213a84eb5c7a999a6b0b9))
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
6
24
|
## 8.0.9 (2023-11-10)
|
|
7
25
|
|
|
8
26
|
|
|
@@ -43,7 +43,7 @@ These are copy paste friendly examples to quickliy get started using a component
|
|
|
43
43
|
listTitle: "Senaste klippen",
|
|
44
44
|
listType: "media",
|
|
45
45
|
mediaIcon: "play_arrow-filled",
|
|
46
|
-
teasers: [ { title: 'Svenska hjältehunden Killian arbetar mot klockan i Marocko – är det försent?', targetLink: '#', publicationTime: 'I går 21:22', mediaHtml: '<div class="picture"><img class="picture__img" src="??"></div>', video: 'true', attributes: { "data-test": "list-item-test-data" } } ]
|
|
46
|
+
teasers: [ { title: 'Svenska hjältehunden Killian arbetar mot klockan i Marocko – är det försent?', vignette: "VÄRLDEN", targetLink: '#', isItalicHeadline: false, publicationTime: 'I går 21:22', mediaHtml: '<div class="picture"><img class="picture__img" src="??"></div>', video: 'true', attributes: { "data-test": "list-item-test-data" } } ]
|
|
47
47
|
})}}
|
|
48
48
|
```
|
|
49
49
|
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
|
|
29
29
|
<div class="{{ componentClassName + '__content'}}">
|
|
30
30
|
{% for teaser in params.teasers %}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
31
|
+
{% if isMediaList %}
|
|
32
|
+
{{ TeaserListVerticalMediaItem(teaser) }}
|
|
33
|
+
{% else %}
|
|
34
|
+
{{ TeaserListVerticalItem(teaser) }}
|
|
35
|
+
{% endif %}
|
|
36
36
|
{% endfor %}
|
|
37
37
|
</div>
|
|
38
38
|
{% if showButton %}
|
|
@@ -72,12 +72,20 @@
|
|
|
72
72
|
{% set attributes = getAttributes(teaser.attributes) %}
|
|
73
73
|
{%- set classes = [
|
|
74
74
|
"ds-teaser-list-vertical__media-item",
|
|
75
|
+
"ds-teaser-list-vertical__media-item--italic" if teaser.isItalicHeadline,
|
|
75
76
|
teaser.classNames if teaser.classNames
|
|
76
77
|
] | join(" ") %}
|
|
77
78
|
|
|
78
79
|
<a href="{{teaser.targetLink}}" class="{{ classes }}" {{- attributes | safe }}>
|
|
79
80
|
<div class="ds-teaser-list-vertical__media-item-text">
|
|
80
|
-
|
|
81
|
+
{% if teaser.vignette %}
|
|
82
|
+
<div class="ds-teaser-list-vertical__media-item-vignette">{{ teaser.vignette }}</div>
|
|
83
|
+
{% endif %}
|
|
84
|
+
<h3 class="ds-teaser-list-vertical__media-item-title">
|
|
85
|
+
{%- if teaser.highlight %}
|
|
86
|
+
<span class="ds-teaser-list-vertical__media-item-highlight">{{ teaser.highlight }}</span>
|
|
87
|
+
{% endif %}
|
|
88
|
+
{{- teaser.title }}</h3>
|
|
81
89
|
{% if teaser.publicationTime or teaser.sectionName %}
|
|
82
90
|
<div class="ds-teaser-list-vertical__media-item-notes">
|
|
83
91
|
<span>{{ teaser.publicationTime }}</span>
|
|
@@ -101,10 +101,27 @@ $ds-teaser-list-vertical-media-icon-size: 20px;
|
|
|
101
101
|
margin: 0;
|
|
102
102
|
}
|
|
103
103
|
|
|
104
|
+
.ds-teaser-list-vertical__media-item-vignette {
|
|
105
|
+
display: block;
|
|
106
|
+
@include ds-typography($ds-typography-detailarticle-label);
|
|
107
|
+
color: $ds-theme-color;
|
|
108
|
+
margin-bottom: ds-spacing($ds-s-025);
|
|
109
|
+
}
|
|
110
|
+
|
|
104
111
|
.ds-teaser-list-vertical__media-item-title {
|
|
105
112
|
@include ds-typography($ds-typography-expressive-heading01bold);
|
|
106
113
|
color: $ds-color-text-primary;
|
|
107
114
|
word-break: break-word;
|
|
115
|
+
|
|
116
|
+
.ds-teaser-list-vertical__media-item-highlight {
|
|
117
|
+
color: $ds-theme-color;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
&.ds-teaser-list-vertical__media-item--italic {
|
|
122
|
+
.ds-teaser-list-vertical__media-item-title {
|
|
123
|
+
@include ds-typography($ds-typography-expressive-heading01italicregular);
|
|
124
|
+
}
|
|
108
125
|
}
|
|
109
126
|
|
|
110
127
|
.ds-teaser-list-vertical__media-item-notes {
|
package/package.json
CHANGED