@flodesk/grain 11.55.0 → 11.55.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/es/components/card.js +48 -10
- package/package.json +1 -1
package/es/components/card.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const _excluded = ["children", "
|
|
1
|
+
const _excluded = ["children", "width", "minWidth", "maxWidth", "height", "minHeight", "maxHeight", "padding", "radius", "position", "zIndex"];
|
|
2
2
|
|
|
3
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
4
|
|
|
@@ -9,11 +9,11 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
9
9
|
import React from 'react';
|
|
10
10
|
import PropTypes from 'prop-types';
|
|
11
11
|
import { Box } from './box';
|
|
12
|
+
import { types } from '../types';
|
|
12
13
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
13
14
|
export const Card = _ref => {
|
|
14
15
|
let {
|
|
15
16
|
children,
|
|
16
|
-
shadow,
|
|
17
17
|
width,
|
|
18
18
|
minWidth,
|
|
19
19
|
maxWidth,
|
|
@@ -37,22 +37,60 @@ export const Card = _ref => {
|
|
|
37
37
|
left: 0,
|
|
38
38
|
right: 0,
|
|
39
39
|
bottom: 0,
|
|
40
|
-
zIndex: zIndex
|
|
41
|
-
|
|
40
|
+
zIndex: zIndex
|
|
42
41
|
}, ___EmotionJSX(Box, _extends({
|
|
43
42
|
className: "grn-card",
|
|
44
|
-
width: "100%"
|
|
45
|
-
// minWidth={minWidth}
|
|
46
|
-
// maxWidth={maxWidth}
|
|
47
|
-
,
|
|
43
|
+
width: "100%",
|
|
48
44
|
padding: padding,
|
|
49
45
|
radius: radius,
|
|
50
|
-
shadow: shadow,
|
|
51
46
|
height: height,
|
|
52
47
|
minHeight: minHeight,
|
|
53
48
|
maxHeight: maxHeight
|
|
54
49
|
}, props), children));
|
|
55
50
|
};
|
|
56
51
|
Card.propTypes = {
|
|
57
|
-
|
|
52
|
+
color: types.color,
|
|
53
|
+
colorHover: types.color,
|
|
54
|
+
backgroundColor: types.color,
|
|
55
|
+
backgroundColorHover: types.color,
|
|
56
|
+
borderColor: types.color,
|
|
57
|
+
borderColorHover: types.color,
|
|
58
|
+
borderWidth: types.borderWidth,
|
|
59
|
+
borderSide: types.side,
|
|
60
|
+
width: types.responsiveDimension,
|
|
61
|
+
minWidth: types.responsiveDimension,
|
|
62
|
+
maxWidth: types.responsiveDimension,
|
|
63
|
+
height: types.responsiveDimension,
|
|
64
|
+
minHeight: types.responsiveDimension,
|
|
65
|
+
maxHeight: types.responsiveDimension,
|
|
66
|
+
radius: types.radius,
|
|
67
|
+
shadow: types.shadow,
|
|
68
|
+
shadowHover: types.shadow,
|
|
69
|
+
padding: types.responsiveSpace,
|
|
70
|
+
margin: types.responsiveSpace,
|
|
71
|
+
marginTop: types.responsiveSpace,
|
|
72
|
+
marginBottom: types.responsiveSpace,
|
|
73
|
+
marginLeft: types.responsiveSpace,
|
|
74
|
+
marginRight: types.responsiveSpace,
|
|
75
|
+
marginX: types.responsiveSpace,
|
|
76
|
+
marginY: types.responsiveSpace,
|
|
77
|
+
position: types.position,
|
|
78
|
+
top: types.responsiveSpace,
|
|
79
|
+
bottom: types.responsiveSpace,
|
|
80
|
+
left: types.responsiveSpace,
|
|
81
|
+
right: types.responsiveSpace,
|
|
82
|
+
overflow: types.overflow,
|
|
83
|
+
overflowX: types.overflow,
|
|
84
|
+
overflowY: types.overflow,
|
|
85
|
+
aspectRatio: PropTypes.string,
|
|
86
|
+
zIndex: types.zIndex,
|
|
87
|
+
opacity: PropTypes.string,
|
|
88
|
+
opacityHover: PropTypes.string,
|
|
89
|
+
order: PropTypes.oneOfType([PropTypes.string, PropTypes.number, PropTypes.object]),
|
|
90
|
+
alignSelf: types.alignSelf,
|
|
91
|
+
flex: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),
|
|
92
|
+
transition: types.transition,
|
|
93
|
+
transitionHover: types.transition,
|
|
94
|
+
cursor: types.cursor,
|
|
95
|
+
tag: PropTypes.string
|
|
58
96
|
};
|