@commercetools-uikit/card 19.9.0 → 19.10.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.
|
@@ -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 = "19.
|
|
106
|
+
var version = "19.10.0";
|
|
107
107
|
|
|
108
108
|
exports["default"] = Card$1;
|
|
109
109
|
exports.version = version;
|
|
@@ -1,14 +1,41 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import type { LocationDescriptor } from 'history';
|
|
3
3
|
export type TCardProps = {
|
|
4
|
+
/**
|
|
5
|
+
* Determines the visual effect of the card. A raised card has a box shadow while a flat card has just a border.
|
|
6
|
+
*/
|
|
4
7
|
type: 'raised' | 'flat';
|
|
8
|
+
/**
|
|
9
|
+
* Determines the spacing (padding) that the content should have from the card borders. In case there is no space needed, you can pass `none`.
|
|
10
|
+
*/
|
|
5
11
|
insetScale: 'none' | 's' | 'm' | 'l' | 'xl';
|
|
12
|
+
/**
|
|
13
|
+
* Determines the background color of the card.
|
|
14
|
+
*/
|
|
6
15
|
theme: 'light' | 'dark';
|
|
16
|
+
/**
|
|
17
|
+
* Pass a custom CSS class, useful to override the styles.
|
|
18
|
+
* <br>
|
|
19
|
+
* NOTE: This is not recommended and should only be used for building new components
|
|
20
|
+
* that require special style adjustments.
|
|
21
|
+
*/
|
|
7
22
|
className?: string;
|
|
8
23
|
children?: ReactNode;
|
|
24
|
+
/**
|
|
25
|
+
* The callback function to be executed when the Card component is clicked. Prefer this for managing side effects rather than navigation.
|
|
26
|
+
*/
|
|
9
27
|
onClick?: () => void;
|
|
28
|
+
/**
|
|
29
|
+
* The URL that the Card should point to. If provided, the Card will be rendered as an anchor element.
|
|
30
|
+
*/
|
|
10
31
|
to?: string | LocationDescriptor;
|
|
32
|
+
/**
|
|
33
|
+
* A flag to indicate if the Card points to an external source.
|
|
34
|
+
*/
|
|
11
35
|
isExternalLink?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Indicates that a clickable Card should not allow clicks. This allows consumers to temporarily disable a clickable Card.
|
|
38
|
+
*/
|
|
12
39
|
isDisabled?: boolean;
|
|
13
40
|
};
|
|
14
41
|
declare const Card: {
|
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": "19.
|
|
4
|
+
"version": "19.10.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": "19.
|
|
25
|
-
"@commercetools-uikit/spacings-inset": "19.
|
|
26
|
-
"@commercetools-uikit/utils": "19.
|
|
24
|
+
"@commercetools-uikit/design-system": "19.10.0",
|
|
25
|
+
"@commercetools-uikit/spacings-inset": "19.10.0",
|
|
26
|
+
"@commercetools-uikit/utils": "19.10.0",
|
|
27
27
|
"@emotion/react": "^11.10.5",
|
|
28
28
|
"@emotion/styled": "^11.10.5",
|
|
29
29
|
"@types/react-router-dom": "^5.3.3",
|