@bonniernews/dn-design-system-web 20.2.0 → 20.3.1
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 +26 -0
- package/components/pagination/README.md +2 -2
- package/components/profile-header/README.md +1 -0
- package/components/profile-header/profile-header.njk +3 -0
- package/components/profile-header/profile-header.scss +8 -2
- package/components/tag-header/README.md +1 -0
- package/components/tag-header/tag-header.njk +3 -0
- package/components/tag-header/tag-header.scss +6 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,32 @@ All changes to @bonniernews/dn-design-system-web will be documented in this file
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
+
## [20.3.1](https://github.com/BonnierNews/dn-design-system/compare/@bonniernews/dn-design-system-web@20.3.0...@bonniernews/dn-design-system-web@20.3.1) (2024-09-16)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Bug Fixes
|
|
11
|
+
|
|
12
|
+
* **web:** remove trailing commas from pagination readme njk example ([#1403](https://github.com/BonnierNews/dn-design-system/issues/1403)) ([6c65b1f](https://github.com/BonnierNews/dn-design-system/commit/6c65b1f3a657e9b7c8d3f7b86c6a347e3dade967))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Maintenance
|
|
16
|
+
|
|
17
|
+
* **deps-dev:** bump remove-markdown from 0.5.2 to 0.5.5 ([#1393](https://github.com/BonnierNews/dn-design-system/issues/1393)) ([1310aa0](https://github.com/BonnierNews/dn-design-system/commit/1310aa0392048140748325593f9797dc86e9977b))
|
|
18
|
+
* **deps:** bump express to 4.21.0 ([#1400](https://github.com/BonnierNews/dn-design-system/issues/1400)) ([ddd6612](https://github.com/BonnierNews/dn-design-system/commit/ddd66129828845f96f574ee05f327f32ccff77f6))
|
|
19
|
+
* prerelease packages ([94dd232](https://github.com/BonnierNews/dn-design-system/commit/94dd23255267ddf5a1bc653282dd4a91dbfdfb0e))
|
|
20
|
+
|
|
21
|
+
## [20.3.0](https://github.com/BonnierNews/dn-design-system/compare/@bonniernews/dn-design-system-web@20.2.0...@bonniernews/dn-design-system-web@20.3.0) (2024-09-12)
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
### Features
|
|
25
|
+
|
|
26
|
+
* **web:** add articlecount to tagheader and profileheader ([#1395](https://github.com/BonnierNews/dn-design-system/issues/1395)) ([90eba4a](https://github.com/BonnierNews/dn-design-system/commit/90eba4a4e132c0748bf126d5e0f6bc1f733d4e76))
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
### Maintenance
|
|
30
|
+
|
|
31
|
+
* **deps:** bump express from 4.19.2 to 4.20.0 in /web ([#1398](https://github.com/BonnierNews/dn-design-system/issues/1398)) ([67314ce](https://github.com/BonnierNews/dn-design-system/commit/67314ce6e2983cc8752650c95e2d199c1522ce67))
|
|
32
|
+
|
|
7
33
|
## [20.2.0](https://github.com/BonnierNews/dn-design-system/compare/@bonniernews/dn-design-system-web@20.1.1...@bonniernews/dn-design-system-web@20.2.0) (2024-09-12)
|
|
8
34
|
|
|
9
35
|
|
|
@@ -42,10 +42,10 @@ These are copy paste friendly examples to quickliy get started using a component
|
|
|
42
42
|
{ label: '7' , url: 'https://www.dn.se/om/danmark/?offset=32' },
|
|
43
43
|
{ label: '8' , url: 'https://www.dn.se/om/danmark/?offset=40', current: true },
|
|
44
44
|
{ label: '9' , url: 'https://www.dn.se/om/danmark/?offset=48' },
|
|
45
|
-
{ label: '10' , url: 'https://www.dn.se/om/danmark/?offset=56' }
|
|
45
|
+
{ label: '10' , url: 'https://www.dn.se/om/danmark/?offset=56' }
|
|
46
46
|
],
|
|
47
47
|
attributes: {},
|
|
48
|
-
classNames: undefined
|
|
48
|
+
classNames: undefined
|
|
49
49
|
})}}
|
|
50
50
|
```
|
|
51
51
|
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
|title | String | yes | | | H1 Title |
|
|
14
14
|
|mediaHtml | String | no | | | Main image |
|
|
15
15
|
|descriptionHtml | String | no | | | Intended use is text, links |
|
|
16
|
+
|articleCount | int | no | | | Total articles on this list-page |
|
|
16
17
|
|toggle | Bool | no | true, false | false | Show/hide toggle button |
|
|
17
18
|
|toggleText | text | no | | | `text` parameter to ToggleButton (only if `toggle` is enabled) |
|
|
18
19
|
|toggleSelectedText | text | no | | | `selectedText` parameter to ToggleButton (only if `toggle` is enabled) |
|
|
@@ -39,6 +39,9 @@
|
|
|
39
39
|
{{ params.descriptionHtml | safe }}
|
|
40
40
|
</div>
|
|
41
41
|
{% endif %}
|
|
42
|
+
{% if params.articleCount %}
|
|
43
|
+
<p class="{{ componentClassName }}__article-count">{{ params.articleCount }} {% if params.articleCount === 1 %}artikel{% else %}artiklar{% endif %}</p>
|
|
44
|
+
{% endif %}
|
|
42
45
|
</div>
|
|
43
46
|
</div>
|
|
44
47
|
{% endmacro %}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
.ds-profile-header {
|
|
5
5
|
width: 100%;
|
|
6
6
|
background-color: $ds-color-surface-background;
|
|
7
|
-
padding:
|
|
7
|
+
padding-bottom: ds-spacing($ds-s-100);
|
|
8
8
|
display: flex;
|
|
9
9
|
|
|
10
10
|
.ds-profile-header__content {
|
|
@@ -43,12 +43,18 @@
|
|
|
43
43
|
margin: 0;
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
+
.ds-profile-header__article-count {
|
|
47
|
+
margin: ds-spacing($ds-s-050 $ds-s-100 0);
|
|
48
|
+
@include ds-typography($ds-typography-functionalbody02);
|
|
49
|
+
color: $ds-color-text-primary-02;
|
|
50
|
+
}
|
|
51
|
+
|
|
46
52
|
.ds-profile-header__description {
|
|
47
53
|
@include ds-typography($ds-typography-functionalbody02);
|
|
48
54
|
color: $ds-color-text-primary;
|
|
49
55
|
margin: ds-spacing(0 $ds-s-100 0);
|
|
50
56
|
border-top: ds-border-width(x1) solid $ds-color-border-primary;
|
|
51
|
-
padding: ds-spacing($ds-s-100 0);
|
|
57
|
+
padding: ds-spacing($ds-s-100 0 0 0);
|
|
52
58
|
|
|
53
59
|
a {
|
|
54
60
|
@include ds-link($ds-link-article-body);
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
|vignetteTargetUrl | String | no | | | Target URL for the vignette |
|
|
16
16
|
|mediaHtml | String | no | | | Main image |
|
|
17
17
|
|descriptionHtml | String | no | | | Intended use is text, links |
|
|
18
|
+
|articleCount | int | no | | | Total articles on this list-page |
|
|
18
19
|
|theme | String | no | nyheter, kultur, ekonomi, sport, sthlm | (empty) | The theme-class to apply to the vignette |
|
|
19
20
|
|toggle | Bool | no | true, false | false | Show/hide toggle button |
|
|
20
21
|
|toggleText | text | no | | | `text` parameter to ToggleButton (only if `toggle` is enabled) |
|
|
@@ -47,6 +47,9 @@
|
|
|
47
47
|
{{ params.descriptionHtml | safe }}
|
|
48
48
|
</div>
|
|
49
49
|
{% endif %}
|
|
50
|
+
{% if params.articleCount %}
|
|
51
|
+
<p class="{{ componentClassName }}__article-count">{{ params.articleCount }} {% if params.articleCount === 1 %}artikel{% else %}artiklar{% endif %}</p>
|
|
52
|
+
{% endif %}
|
|
50
53
|
</div>
|
|
51
54
|
</div>
|
|
52
55
|
{% endmacro %}
|
|
@@ -70,6 +70,12 @@
|
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
72
|
|
|
73
|
+
.ds-tag-header__article-count {
|
|
74
|
+
margin: ds-spacing($ds-s-050 $ds-s-100 0);
|
|
75
|
+
@include ds-typography($ds-typography-functionalbody02);
|
|
76
|
+
color: $ds-color-text-primary-02;
|
|
77
|
+
}
|
|
78
|
+
|
|
73
79
|
.ds-tag-header__description {
|
|
74
80
|
@include ds-typography($ds-typography-functionalbody02);
|
|
75
81
|
color: $ds-color-text-primary;
|
package/package.json
CHANGED