@commercetools-uikit/card 18.0.0 → 18.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/README.md CHANGED
@@ -20,11 +20,11 @@ npm --save install @commercetools-uikit/card
20
20
  Additionally install the peer dependencies (if not present)
21
21
 
22
22
  ```
23
- yarn add react
23
+ yarn add react react-router-dom
24
24
  ```
25
25
 
26
26
  ```
27
- npm --save install react
27
+ npm --save install react react-router-dom
28
28
  ```
29
29
 
30
30
  ## Usage
@@ -50,7 +50,15 @@ export default Example;
50
50
  | `theme` | `union`<br/>Possible values:<br/>`'light' , 'dark'` | | `'light'` | Determines the background color of the card. |
51
51
  | `className` | `string` | | | Pass a custom CSS class, useful to override the styles.&#xA;<br>&#xA;NOTE: This is not recommended and should only be used for building new components&#xA;that require special style adjustments. |
52
52
  | `children` | `ReactNode` | | | |
53
- | `onClick` | `() => void` | | | The callback function to be executed when the Card component is clicked. Prefer this for managing side effects rather than navigation. |
54
- | `to` | `union`<br/>Possible values:<br/>`string , LocationDescriptor` | | | The URL that the Card should point to. When provided, the Card will render as a react-router `<Link>`. Use with `isExternal` to determine if an internal or external link should be used. |
55
- | `isExternalLink` | `boolean` | | | A flag to indicate if the Card points to an external source. When true, the Card will render as an `<a>` tag with appropriate attributes for external links. |
56
- | `isDisabled` | `boolean` | | | Indicates that a clickable Card should not allow clicks. This is useful for temporarily disabling a clickable Card. Use in conjunction with `to` and/or `onClick`. |
53
+ | `onClick` | `Function`<br/>[See signature.](#signature-onClick) | | | The callback function to be executed when the Card component is clicked. Prefer this for managing side effects rather than navigation. |
54
+ | `to` | `union`<br/>Possible values:<br/>`string , LocationDescriptor` | | | The URL that the Card should point to. If provided, the Card will be rendered as an anchor element. |
55
+ | `isExternalLink` | `boolean` | | | A flag to indicate if the Card points to an external source. |
56
+ | `isDisabled` | `boolean` | | | Indicates that a clickable Card should not allow clicks. This allows consumers to temporarily disable a clickable Card. |
57
+
58
+ ## Signatures
59
+
60
+ ### Signature `onClick`
61
+
62
+ ```ts
63
+ () => void
64
+ ```
@@ -103,7 +103,7 @@ Card.defaultProps = defaultProps;
103
103
  var Card$1 = Card;
104
104
 
105
105
  // NOTE: This string will be replaced on build time with the package version.
106
- var version = "18.0.0";
106
+ var version = "18.1.0";
107
107
 
108
108
  exports["default"] = Card$1;
109
109
  exports.version = version;
@@ -91,7 +91,7 @@ Card.defaultProps = defaultProps;
91
91
  var Card$1 = Card;
92
92
 
93
93
  // NOTE: This string will be replaced on build time with the package version.
94
- var version = "18.0.0";
94
+ var version = "18.1.0";
95
95
 
96
96
  exports["default"] = Card$1;
97
97
  exports.version = version;
@@ -86,6 +86,6 @@ Card.defaultProps = defaultProps;
86
86
  var Card$1 = Card;
87
87
 
88
88
  // NOTE: This string will be replaced on build time with the package version.
89
- var version = "18.0.0";
89
+ var version = "18.1.0";
90
90
 
91
91
  export { Card$1 as default, version };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@commercetools-uikit/card",
3
3
  "description": "Cards are used to display content and actions on a single topic.",
4
- "version": "18.0.0",
4
+ "version": "18.1.0",
5
5
  "bugs": "https://github.com/commercetools/ui-kit/issues",
6
6
  "repository": {
7
7
  "type": "git",
@@ -21,9 +21,9 @@
21
21
  "dependencies": {
22
22
  "@babel/runtime": "^7.20.13",
23
23
  "@babel/runtime-corejs3": "^7.20.13",
24
- "@commercetools-uikit/design-system": "18.0.0",
25
- "@commercetools-uikit/spacings-inset": "18.0.0",
26
- "@commercetools-uikit/utils": "18.0.0",
24
+ "@commercetools-uikit/design-system": "18.1.0",
25
+ "@commercetools-uikit/spacings-inset": "18.1.0",
26
+ "@commercetools-uikit/utils": "18.1.0",
27
27
  "@emotion/react": "^11.10.5",
28
28
  "@emotion/styled": "^11.10.5",
29
29
  "@types/react-router-dom": "^5.3.3",