@synerise/ds-card 1.2.10 → 1.2.11
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,14 @@
|
|
|
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
|
+
## [1.2.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-card@1.2.10...@synerise/ds-card@1.2.11) (2025-09-25)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @synerise/ds-card
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
6
14
|
## [1.2.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-card@1.2.9...@synerise/ds-card@1.2.10) (2025-09-19)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @synerise/ds-card
|
package/dist/Card/Card.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type CardProps } from './Card.types';
|
|
3
|
-
declare const Card: ({ children, raised, disabled,
|
|
3
|
+
declare const Card: ({ children, raised, disabled, className, lively, withHeader, defaultHeaderBackgroundColor, title, description, compactHeader, icon, avatar, renderBadge, iconColor, headerSideChildren, onHeaderClick, withoutPadding, headerBorderBottom, background, hideContent, staticContent, titleTag, showSideChildrenWhenHeaderHidden, ...htmlAttributes }: CardProps) => React.JSX.Element;
|
|
4
4
|
export default Card;
|
package/dist/Card/Card.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _excluded = ["children", "raised", "disabled", "
|
|
1
|
+
var _excluded = ["children", "raised", "disabled", "className", "lively", "withHeader", "defaultHeaderBackgroundColor", "title", "description", "compactHeader", "icon", "avatar", "renderBadge", "iconColor", "headerSideChildren", "onHeaderClick", "withoutPadding", "headerBorderBottom", "background", "hideContent", "staticContent", "titleTag", "showSideChildrenWhenHeaderHidden"];
|
|
2
2
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
3
3
|
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
4
4
|
import React, { useState } from 'react';
|
|
@@ -11,7 +11,6 @@ var Card = function Card(_ref) {
|
|
|
11
11
|
var children = _ref.children,
|
|
12
12
|
raised = _ref.raised,
|
|
13
13
|
disabled = _ref.disabled,
|
|
14
|
-
style = _ref.style,
|
|
15
14
|
className = _ref.className,
|
|
16
15
|
lively = _ref.lively,
|
|
17
16
|
withHeader = _ref.withHeader,
|
|
@@ -33,7 +32,7 @@ var Card = function Card(_ref) {
|
|
|
33
32
|
staticContent = _ref.staticContent,
|
|
34
33
|
titleTag = _ref.titleTag,
|
|
35
34
|
showSideChildrenWhenHeaderHidden = _ref.showSideChildrenWhenHeaderHidden,
|
|
36
|
-
|
|
35
|
+
htmlAttributes = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
37
36
|
var fatTitle = !description || description && compactHeader;
|
|
38
37
|
var _useState = useState(false),
|
|
39
38
|
headerActionsVisible = _useState[0],
|
|
@@ -54,13 +53,12 @@ var Card = function Card(_ref) {
|
|
|
54
53
|
return /*#__PURE__*/React.createElement(S.Container, _extends({
|
|
55
54
|
raised: raised,
|
|
56
55
|
disabled: disabled,
|
|
57
|
-
style: style,
|
|
58
56
|
className: "ds-card " + (className || ''),
|
|
59
57
|
lively: lively,
|
|
60
58
|
"data-testid": "card-wrapper",
|
|
61
59
|
background: background
|
|
62
60
|
/** Necessary for passing down data-* attributes */
|
|
63
|
-
},
|
|
61
|
+
}, htmlAttributes), withHeader && /*#__PURE__*/React.createElement(S.Header, {
|
|
64
62
|
onClick: onHeaderClick,
|
|
65
63
|
headerBorderBottom: headerBorderBottom,
|
|
66
64
|
defaultHeaderBackgroundColor: defaultHeaderBackgroundColor
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type CSSProperties, type ReactNode, type SyntheticEvent } from 'react';
|
|
2
|
+
import { type WithHTMLAttributes } from '@synerise/ds-utils';
|
|
2
3
|
export type Backgrounds = 'white' | 'white-shadow' | 'grey' | 'grey-shadow' | 'outline';
|
|
3
|
-
export
|
|
4
|
+
export type CardProps = WithHTMLAttributes<HTMLDivElement, {
|
|
4
5
|
raised?: boolean;
|
|
5
6
|
disabled?: boolean;
|
|
6
7
|
className?: string;
|
|
@@ -25,4 +26,4 @@ export interface CardProps {
|
|
|
25
26
|
hideContent?: boolean;
|
|
26
27
|
showSideChildrenWhenHeaderHidden?: boolean;
|
|
27
28
|
titleTag?: ReactNode;
|
|
28
|
-
}
|
|
29
|
+
}>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type CardGroupProps } from './CardGroup.types';
|
|
3
|
-
declare const CardGroup: ({
|
|
3
|
+
declare const CardGroup: ({ children, columns, ...htmlAttributes }: CardGroupProps) => React.JSX.Element;
|
|
4
4
|
export default CardGroup;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
+
var _excluded = ["children", "columns"];
|
|
2
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
3
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
1
4
|
import React from 'react';
|
|
2
5
|
import * as S from './CardGroup.styles';
|
|
3
6
|
var CardGroup = function CardGroup(_ref) {
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
return /*#__PURE__*/React.createElement(S.Container, {
|
|
8
|
-
className: className,
|
|
7
|
+
var children = _ref.children,
|
|
8
|
+
columns = _ref.columns,
|
|
9
|
+
htmlAttributes = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
10
|
+
return /*#__PURE__*/React.createElement(S.Container, _extends({
|
|
9
11
|
items: columns
|
|
10
|
-
}, children);
|
|
12
|
+
}, htmlAttributes), children);
|
|
11
13
|
};
|
|
12
14
|
export default CardGroup;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
import { type WithHTMLAttributes } from '@synerise/ds-utils';
|
|
3
|
+
export type CardGroupProps = WithHTMLAttributes<HTMLDivElement, {
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
columns: number;
|
|
6
|
-
}
|
|
6
|
+
}>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synerise/ds-card",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.11",
|
|
4
4
|
"description": "Card UI Component for the Synerise Design System",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"repository": "Synerise/synerise-design",
|
|
@@ -35,9 +35,9 @@
|
|
|
35
35
|
],
|
|
36
36
|
"types": "dist/index.d.ts",
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@synerise/ds-avatar": "^1.0.
|
|
38
|
+
"@synerise/ds-avatar": "^1.0.23",
|
|
39
39
|
"@synerise/ds-icon": "^1.7.2",
|
|
40
|
-
"@synerise/ds-tag": "^1.
|
|
40
|
+
"@synerise/ds-tag": "^1.3.0",
|
|
41
41
|
"@synerise/ds-typography": "^1.0.21",
|
|
42
42
|
"@synerise/ds-utils": "^1.4.2",
|
|
43
43
|
"react-animate-height": "^2.0.23",
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"react": ">=16.9.0 <= 18.3.1",
|
|
51
51
|
"styled-components": "^5.3.3"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "6a2e6e20a480aafe5d67748d04fbe3d4ce91a544"
|
|
54
54
|
}
|