@bonniernews/dn-design-system-web 3.0.0-alpha.31 → 3.0.0-alpha.32

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
@@ -3,6 +3,15 @@
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
+ ## [3.0.0-alpha.32](https://github.com/BonnierNews/dn-design-system/compare/@bonniernews/dn-design-system-web@3.0.0-alpha.31...@bonniernews/dn-design-system-web@3.0.0-alpha.32) (2023-04-21)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **web:** set vip text in component and change property to boolean ([#768](https://github.com/BonnierNews/dn-design-system/issues/768)) ([5004120](https://github.com/BonnierNews/dn-design-system/commit/500412093b8caf4ea5e46d6a529a390da33b2b6d))
12
+
13
+
14
+
6
15
  ## 3.0.0-alpha.31 (2023-04-20)
7
16
 
8
17
 
@@ -10,7 +10,7 @@
10
10
 
11
11
  |parameter | type | required | options | default | description |
12
12
  |:--- | :--- | :--- | :--- | :--- | :--- |
13
- |text | string | no | | | |
13
+ |showText | bool | no | | false | By default only icon is shown |
14
14
  |attributes | Object | no | | | Ex. { target: "_blank", "data-test": "lorem ipsum" } |
15
15
  |classNames | String | no | | | Ex. "my-special-class" |
16
16
  |forcePx | bool | no | true, false | false | Fixed pixel value is used for typography to prevent scaling based on html font-size |
@@ -25,7 +25,7 @@ These are copy paste friendly examples to quickliy get started using a component
25
25
  {% from '@bonniernews/dn-design-system-web/components/vip-badge/vip-badge.njk' import VipBadge %}
26
26
 
27
27
  {{ VipBadge({
28
- text: "För dig som prenumererar"
28
+ showText: true
29
29
  })}}
30
30
  ```
31
31
 
@@ -9,7 +9,7 @@
9
9
  {%- if params.classNames %}
10
10
  {% set additionalClasses = (additionalClasses.push(params.classNames), additionalClasses) %}
11
11
  {% endif %}
12
- {%- if params.text %}
12
+ {%- if params.showText %}
13
13
  {% set additionalClasses = (additionalClasses.push(classNamePrefix + "text"), additionalClasses) %}
14
14
  {% endif%}
15
15
  {%- if params.forcePx %}
@@ -18,8 +18,6 @@
18
18
  {%- set classes = componentClassName + " " + additionalClasses | join(" ") %}
19
19
  <div class="{{ classes }}" {{- attributes | safe }} aria-hidden="true">
20
20
  {{ Icon({ icon: 'vip' | safe }) }}
21
- {%- if params.text %}
22
- {{ params.text }}
23
- {% endif %}
21
+ {{ "För dig som prenumererar" if params.showText else "" }}
24
22
  </div>
25
23
  {% endmacro %}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bonniernews/dn-design-system-web",
3
- "version": "3.0.0-alpha.31",
3
+ "version": "3.0.0-alpha.32",
4
4
  "description": "DN design system for web.",
5
5
  "main": "index.js",
6
6
  "homepage": "https://github.com/BonnierNews/dn-design-system/tree/main/web/src#readme",