@draftbit/core 46.10.3-177666.2 → 46.10.3-17bcb4.2
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/lib/commonjs/components/AvatarEdit.js +15 -4
- package/lib/commonjs/components/Banner.js +23 -4
- package/lib/commonjs/components/Checkbox/Checkbox.js +3 -4
- package/lib/commonjs/components/Checkbox/CheckboxGroup.js +17 -2
- package/lib/commonjs/components/CircularProgress.js +26 -8
- package/lib/commonjs/components/DeprecatedButton.js +20 -3
- package/lib/commonjs/components/DeprecatedCardWrapper.js +54 -0
- package/lib/commonjs/components/DeprecatedFAB.js +157 -0
- package/lib/commonjs/components/Elevation.js +14 -2
- package/lib/commonjs/components/FormRow.js +16 -2
- package/lib/commonjs/components/IconButton.js +19 -4
- package/lib/commonjs/components/Layout.js +40 -19
- package/lib/commonjs/components/NumberInput.js +12 -3
- package/lib/commonjs/components/Picker/Picker.js +9 -6
- package/lib/commonjs/components/Picker/PickerComponent.web.js +20 -3
- package/lib/commonjs/components/Portal/Portal.js +27 -3
- package/lib/commonjs/components/Portal/PortalHost.js +44 -15
- package/lib/commonjs/components/Pressable.js +15 -2
- package/lib/commonjs/components/ProgressIndicator.js +55 -0
- package/lib/commonjs/components/RadioButton/RadioButton.js +13 -2
- package/lib/commonjs/components/RadioButton/RadioButtonGroup.js +15 -2
- package/lib/commonjs/components/RadioButton/context.js +1 -1
- package/lib/commonjs/components/ResizeMode.js +5 -0
- package/lib/commonjs/components/ScreenContainer.js +24 -6
- package/lib/commonjs/components/Slider.js +21 -4
- package/lib/commonjs/components/StarRating.js +23 -4
- package/lib/commonjs/components/StepIndicator.js +57 -18
- package/lib/commonjs/components/Surface.js +14 -2
- package/lib/commonjs/components/Switch.js +19 -10
- package/lib/commonjs/components/ToggleButton.js +15 -2
- package/lib/commonjs/constants.js +1 -1
- package/lib/commonjs/hooks.js +1 -2
- package/lib/commonjs/mappings/CardBlock.js +126 -0
- package/lib/commonjs/mappings/CardContainer.js +108 -0
- package/lib/commonjs/mappings/CardContainerRating.js +130 -0
- package/lib/commonjs/mappings/CardContainerShortImage.js +124 -0
- package/lib/commonjs/mappings/CardInline.js +59 -0
- package/lib/commonjs/mappings/HeaderLarge.js +34 -0
- package/lib/commonjs/mappings/HeaderMedium.js +60 -0
- package/lib/commonjs/mappings/HeaderOverline.js +60 -0
- package/lib/commonjs/mappings/ProgressIndicator.js +188 -0
- package/lib/commonjs/styles/overlay.js +1 -3
- package/lib/module/components/Accordion/AccordionItem.js +4 -25
- package/lib/module/components/AnimatedCircularProgress.js +13 -1
- package/lib/module/components/AvatarEdit.js +15 -4
- package/lib/module/components/Banner.js +25 -4
- package/lib/module/components/Button.js +33 -10
- package/lib/module/components/Checkbox/CheckboxGroup.js +16 -2
- package/lib/module/components/Checkbox/CheckboxGroupRow.js +24 -5
- package/lib/module/components/Checkbox/CheckboxRow.js +24 -6
- package/lib/module/components/DatePicker/DatePicker.js +27 -13
- package/lib/module/components/DeprecatedCardWrapper.js +32 -0
- package/lib/module/components/DeprecatedFAB.js +167 -0
- package/lib/module/components/Divider.js +18 -1
- package/lib/module/components/Layout.js +42 -21
- package/lib/module/components/Picker/PickerComponent.android.js +21 -3
- package/lib/module/components/Portal/PortalConsumer.js +22 -7
- package/lib/module/components/ProgressIndicator.js +45 -0
- package/lib/module/components/RadioButton/RadioButton.js +13 -1
- package/lib/module/components/RadioButton/RadioButtonFieldGroup.js +10 -1
- package/lib/module/components/RadioButton/context.js +1 -1
- package/lib/module/components/ResizeMode.js +1 -0
- package/lib/module/components/StepIndicator.js +58 -18
- package/lib/module/components/Surface.js +15 -1
- package/lib/module/components/Switch.js +21 -10
- package/lib/module/components/TabView/TabView.js +17 -7
- package/lib/module/components/TabView/TabViewItem.js +4 -3
- package/lib/module/components/Table/Table.js +6 -5
- package/lib/module/components/TextField.js +78 -28
- package/lib/module/components/ToggleButton.js +16 -2
- package/lib/module/constants.js +1 -0
- package/lib/module/mappings/CardBlock.js +119 -0
- package/lib/module/mappings/CardContainer.js +101 -0
- package/lib/module/mappings/CardContainerRating.js +123 -0
- package/lib/module/mappings/CardContainerShortImage.js +117 -0
- package/lib/module/mappings/CardInline.js +52 -0
- package/lib/module/mappings/HeaderLarge.js +27 -0
- package/lib/module/mappings/HeaderMedium.js +53 -0
- package/lib/module/mappings/HeaderOverline.js +53 -0
- package/lib/module/mappings/ProgressIndicator.js +181 -0
- package/lib/typescript/src/components/DeprecatedCardWrapper.d.ts +15 -0
- package/lib/typescript/src/components/DeprecatedCardWrapper.d.ts.map +1 -0
- package/lib/typescript/src/components/DeprecatedFAB.d.ts +56 -0
- package/lib/typescript/src/components/DeprecatedFAB.d.ts.map +1 -0
- package/lib/typescript/src/components/ProgressIndicator.d.ts +24 -0
- package/lib/typescript/src/components/ProgressIndicator.d.ts.map +1 -0
- package/lib/typescript/src/components/ResizeMode.d.ts +2 -0
- package/lib/typescript/src/components/ResizeMode.d.ts.map +1 -0
- package/lib/typescript/src/mappings/CardBlock.d.ts +289 -0
- package/lib/typescript/src/mappings/CardBlock.d.ts.map +1 -0
- package/lib/typescript/src/mappings/CardContainer.d.ts +102 -0
- package/lib/typescript/src/mappings/CardContainer.d.ts.map +1 -0
- package/lib/typescript/src/mappings/CardContainerRating.d.ts +108 -0
- package/lib/typescript/src/mappings/CardContainerRating.d.ts.map +1 -0
- package/lib/typescript/src/mappings/CardContainerShortImage.d.ts +139 -0
- package/lib/typescript/src/mappings/CardContainerShortImage.d.ts.map +1 -0
- package/lib/typescript/src/mappings/CardInline.d.ts +62 -0
- package/lib/typescript/src/mappings/CardInline.d.ts.map +1 -0
- package/lib/typescript/src/mappings/HeaderLarge.d.ts +34 -0
- package/lib/typescript/src/mappings/HeaderLarge.d.ts.map +1 -0
- package/lib/typescript/src/mappings/HeaderMedium.d.ts +53 -0
- package/lib/typescript/src/mappings/HeaderMedium.d.ts.map +1 -0
- package/lib/typescript/src/mappings/HeaderOverline.d.ts +53 -0
- package/lib/typescript/src/mappings/HeaderOverline.d.ts.map +1 -0
- package/lib/typescript/src/mappings/ProgressIndicator.d.ts +181 -0
- package/lib/typescript/src/mappings/ProgressIndicator.d.ts.map +1 -0
- package/package.json +3 -3
- package/src/components/DeprecatedCardWrapper.js +18 -0
- package/src/components/DeprecatedCardWrapper.tsx +46 -0
- package/src/components/DeprecatedFAB.js +114 -0
- package/src/components/DeprecatedFAB.tsx +231 -0
- package/src/components/ProgressIndicator.js +27 -0
- package/src/components/ProgressIndicator.tsx +71 -0
- package/src/components/ResizeMode.js +1 -0
- package/src/components/ResizeMode.ts +7 -0
- package/src/mappings/CardBlock.js +123 -0
- package/src/mappings/CardBlock.ts +136 -0
- package/src/mappings/CardContainer.js +104 -0
- package/src/mappings/CardContainer.ts +116 -0
- package/src/mappings/CardContainerRating.js +126 -0
- package/src/mappings/CardContainerRating.ts +137 -0
- package/src/mappings/CardContainerShortImage.js +120 -0
- package/src/mappings/CardContainerShortImage.ts +130 -0
- package/src/mappings/CardInline.js +52 -0
- package/src/mappings/CardInline.ts +61 -0
- package/src/mappings/HeaderLarge.js +29 -0
- package/src/mappings/HeaderLarge.ts +38 -0
- package/src/mappings/HeaderMedium.js +55 -0
- package/src/mappings/HeaderMedium.ts +63 -0
- package/src/mappings/HeaderOverline.js +55 -0
- package/src/mappings/HeaderOverline.ts +63 -0
- package/src/mappings/ProgressIndicator.js +181 -0
- package/src/mappings/ProgressIndicator.ts +190 -0
|
@@ -13,7 +13,6 @@ var _theming = require("../theming");
|
|
|
13
13
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
14
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
15
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
16
|
-
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); }
|
|
17
16
|
function maybeParseValue(value) {
|
|
18
17
|
if (value === undefined) {
|
|
19
18
|
return undefined;
|
|
@@ -73,9 +72,10 @@ function Slider(_ref) {
|
|
|
73
72
|
setInternalValue(newValue);
|
|
74
73
|
onValueChange(newValue);
|
|
75
74
|
};
|
|
76
|
-
return /*#__PURE__*/React.createElement(_reactNative.View,
|
|
77
|
-
style: [styles.container, style]
|
|
78
|
-
|
|
75
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
76
|
+
style: [styles.container, style],
|
|
77
|
+
...rest
|
|
78
|
+
}, leftIcon ? /*#__PURE__*/React.createElement(Icon, {
|
|
79
79
|
color: leftIconThemeColor,
|
|
80
80
|
name: leftIcon,
|
|
81
81
|
size: 24
|
|
@@ -108,4 +108,21 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
108
108
|
}
|
|
109
109
|
});
|
|
110
110
|
var _default = (0, _theming.withTheme)(Slider);
|
|
111
|
+
exports.default = _default;or: rightIconThemeColor,
|
|
112
|
+
name: rightIcon,
|
|
113
|
+
size: 24
|
|
114
|
+
}) : null);
|
|
115
|
+
}
|
|
116
|
+
const styles = _reactNative.StyleSheet.create({
|
|
117
|
+
container: {
|
|
118
|
+
height: 40,
|
|
119
|
+
flexDirection: "row",
|
|
120
|
+
alignItems: "center"
|
|
121
|
+
},
|
|
122
|
+
slider: {
|
|
123
|
+
flex: 1,
|
|
124
|
+
marginHorizontal: 12
|
|
125
|
+
}
|
|
126
|
+
});
|
|
127
|
+
var _default = (0, _theming.withTheme)(Slider);
|
|
111
128
|
exports.default = _default;
|
|
@@ -9,7 +9,6 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _theming = require("../theming");
|
|
10
10
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
-
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); }
|
|
13
12
|
const StarRating = _ref => {
|
|
14
13
|
let {
|
|
15
14
|
Icon,
|
|
@@ -40,9 +39,10 @@ const StarRating = _ref => {
|
|
|
40
39
|
!!onPress && onPress(r);
|
|
41
40
|
}, [onPress]);
|
|
42
41
|
const ratingRounded = Math.round(localRating * 2) / 2;
|
|
43
|
-
return /*#__PURE__*/React.createElement(_reactNative.View,
|
|
44
|
-
style: [styles.container, style]
|
|
45
|
-
|
|
42
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
43
|
+
style: [styles.container, style],
|
|
44
|
+
...rest
|
|
45
|
+
}, [...Array(maxStars)].map((_, i) => /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
46
46
|
key: i,
|
|
47
47
|
style: {
|
|
48
48
|
display: "flex"
|
|
@@ -83,4 +83,23 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
83
83
|
}
|
|
84
84
|
});
|
|
85
85
|
var _default = (0, _theming.withTheme)(StarRating);
|
|
86
|
+
exports.default = _default;lignItems: "center"
|
|
87
|
+
},
|
|
88
|
+
touchContainer: {
|
|
89
|
+
display: "flex",
|
|
90
|
+
flexDirection: "row",
|
|
91
|
+
position: "absolute",
|
|
92
|
+
top: 0,
|
|
93
|
+
right: 0,
|
|
94
|
+
left: 0,
|
|
95
|
+
bottom: 0,
|
|
96
|
+
zIndex: 1
|
|
97
|
+
},
|
|
98
|
+
pressable: {
|
|
99
|
+
flex: 1,
|
|
100
|
+
height: "100%",
|
|
101
|
+
width: "50%"
|
|
102
|
+
}
|
|
103
|
+
});
|
|
104
|
+
var _default = (0, _theming.withTheme)(StarRating);
|
|
86
105
|
exports.default = _default;
|
|
@@ -8,9 +8,8 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
10
10
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
11
|
+
// @ts-nocheck
|
|
12
|
+
|
|
14
13
|
const STEP_STATUS = {
|
|
15
14
|
CURRENT: "current",
|
|
16
15
|
FINISHED: "finished",
|
|
@@ -19,7 +18,7 @@ const STEP_STATUS = {
|
|
|
19
18
|
class StepIndicator extends _react.Component {
|
|
20
19
|
constructor(props) {
|
|
21
20
|
super(props);
|
|
22
|
-
|
|
21
|
+
this.renderProgressBarBackground = () => {
|
|
23
22
|
const {
|
|
24
23
|
stepCount,
|
|
25
24
|
direction
|
|
@@ -62,8 +61,8 @@ class StepIndicator extends _react.Component {
|
|
|
62
61
|
},
|
|
63
62
|
style: progressBarBackgroundStyle
|
|
64
63
|
});
|
|
65
|
-
}
|
|
66
|
-
|
|
64
|
+
};
|
|
65
|
+
this.renderProgressBar = () => {
|
|
67
66
|
const {
|
|
68
67
|
stepCount,
|
|
69
68
|
direction
|
|
@@ -93,8 +92,8 @@ class StepIndicator extends _react.Component {
|
|
|
93
92
|
return /*#__PURE__*/_react.default.createElement(_reactNative.Animated.View, {
|
|
94
93
|
style: progressBarStyle
|
|
95
94
|
});
|
|
96
|
-
}
|
|
97
|
-
|
|
95
|
+
};
|
|
96
|
+
this.renderStepIndicator = () => {
|
|
98
97
|
let steps = [];
|
|
99
98
|
const {
|
|
100
99
|
stepCount,
|
|
@@ -125,8 +124,8 @@ class StepIndicator extends _react.Component {
|
|
|
125
124
|
height: this.state.customStyles.currentStepIndicatorSize
|
|
126
125
|
}]
|
|
127
126
|
}, steps);
|
|
128
|
-
}
|
|
129
|
-
|
|
127
|
+
};
|
|
128
|
+
this.renderStepLabels = () => {
|
|
130
129
|
const {
|
|
131
130
|
labels,
|
|
132
131
|
direction,
|
|
@@ -168,8 +167,8 @@ class StepIndicator extends _react.Component {
|
|
|
168
167
|
alignItems: this.state.customStyles.labelAlign
|
|
169
168
|
}]
|
|
170
169
|
}, labelViews);
|
|
171
|
-
}
|
|
172
|
-
|
|
170
|
+
};
|
|
171
|
+
this.renderStep = position => {
|
|
173
172
|
const {
|
|
174
173
|
renderStepIndicator
|
|
175
174
|
} = this.props;
|
|
@@ -236,8 +235,8 @@ class StepIndicator extends _react.Component {
|
|
|
236
235
|
}) : /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
237
236
|
style: indicatorLabelStyle
|
|
238
237
|
}, "".concat(position + 1)));
|
|
239
|
-
}
|
|
240
|
-
|
|
238
|
+
};
|
|
239
|
+
this.getStepStatus = stepPosition => {
|
|
241
240
|
const {
|
|
242
241
|
currentPosition
|
|
243
242
|
} = this.props;
|
|
@@ -248,8 +247,8 @@ class StepIndicator extends _react.Component {
|
|
|
248
247
|
} else {
|
|
249
248
|
return STEP_STATUS.UNFINISHED;
|
|
250
249
|
}
|
|
251
|
-
}
|
|
252
|
-
|
|
250
|
+
};
|
|
251
|
+
this.onCurrentPositionChanged = position => {
|
|
253
252
|
let {
|
|
254
253
|
stepCount
|
|
255
254
|
} = this.props;
|
|
@@ -269,7 +268,7 @@ class StepIndicator extends _react.Component {
|
|
|
269
268
|
toValue: this.state.customStyles.currentStepIndicatorSize / 2,
|
|
270
269
|
duration: 100
|
|
271
270
|
})])]).start();
|
|
272
|
-
}
|
|
271
|
+
};
|
|
273
272
|
const defaultStyles = {
|
|
274
273
|
stepIndicatorSize: 30,
|
|
275
274
|
currentStepIndicatorSize: 40,
|
|
@@ -335,7 +334,6 @@ class StepIndicator extends _react.Component {
|
|
|
335
334
|
// ),
|
|
336
335
|
// }));
|
|
337
336
|
// }
|
|
338
|
-
|
|
339
337
|
if (prevProps.currentPosition !== this.props.currentPosition) {
|
|
340
338
|
this.onCurrentPositionChanged(this.props.currentPosition);
|
|
341
339
|
}
|
|
@@ -377,6 +375,47 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
377
375
|
justifyContent: "center"
|
|
378
376
|
}
|
|
379
377
|
});
|
|
378
|
+
StepIndicator.defaultProps = {
|
|
379
|
+
currentPosition: 0,
|
|
380
|
+
stepCount: 5,
|
|
381
|
+
customStyles: {},
|
|
382
|
+
direction: "horizontal"
|
|
383
|
+
};exports.default = StepIndicator;
|
|
384
|
+
const styles = _reactNative.StyleSheet.create({
|
|
385
|
+
container: {
|
|
386
|
+
backgroundColor: "transparent"
|
|
387
|
+
},
|
|
388
|
+
stepIndicatorContainer: {
|
|
389
|
+
flexDirection: "row",
|
|
390
|
+
alignItems: "center",
|
|
391
|
+
justifyContent: "space-around",
|
|
392
|
+
backgroundColor: "transparent"
|
|
393
|
+
},
|
|
394
|
+
stepLabelsContainer: {
|
|
395
|
+
justifyContent: "space-around"
|
|
396
|
+
},
|
|
397
|
+
step: {
|
|
398
|
+
alignItems: "center",
|
|
399
|
+
justifyContent: "center",
|
|
400
|
+
zIndex: 2
|
|
401
|
+
},
|
|
402
|
+
stepContainer: {
|
|
403
|
+
flex: 1,
|
|
404
|
+
flexDirection: "row",
|
|
405
|
+
alignItems: "center",
|
|
406
|
+
justifyContent: "center"
|
|
407
|
+
},
|
|
408
|
+
stepLabel: {
|
|
409
|
+
fontSize: 12,
|
|
410
|
+
textAlign: "center",
|
|
411
|
+
fontWeight: "500"
|
|
412
|
+
},
|
|
413
|
+
stepLabelItem: {
|
|
414
|
+
flex: 1,
|
|
415
|
+
alignItems: "center",
|
|
416
|
+
justifyContent: "center"
|
|
417
|
+
}
|
|
418
|
+
});
|
|
380
419
|
StepIndicator.defaultProps = {
|
|
381
420
|
currentPosition: 0,
|
|
382
421
|
stepCount: 5,
|
|
@@ -12,7 +12,8 @@ var _theming = require("../theming");
|
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
|
-
|
|
15
|
+
/* Copied from https://github.com/callstack/react-native-paper/blob/main/src/components/Surface.tsx */
|
|
16
|
+
|
|
16
17
|
const Surface = _ref => {
|
|
17
18
|
let {
|
|
18
19
|
elevation: propElevation,
|
|
@@ -42,7 +43,18 @@ const Surface = _ref => {
|
|
|
42
43
|
return colors.surface;
|
|
43
44
|
}
|
|
44
45
|
};
|
|
45
|
-
return /*#__PURE__*/React.createElement(_reactNative.Animated.View,
|
|
46
|
+
return /*#__PURE__*/React.createElement(_reactNative.Animated.View, {
|
|
47
|
+
...rest,
|
|
48
|
+
style: [{
|
|
49
|
+
backgroundColor: getBackgroundColor(),
|
|
50
|
+
elevation,
|
|
51
|
+
...evalationStyles,
|
|
52
|
+
...restStyle
|
|
53
|
+
}]
|
|
54
|
+
}, children);
|
|
55
|
+
};
|
|
56
|
+
var _default = (0, _theming.withTheme)(Surface);
|
|
57
|
+
exports.default = _default;xtends({}, rest, {
|
|
46
58
|
style: [{
|
|
47
59
|
backgroundColor: getBackgroundColor(),
|
|
48
60
|
elevation,
|
|
@@ -13,7 +13,6 @@ var _hooks = require("../hooks");
|
|
|
13
13
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
14
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
15
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
16
|
-
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); }
|
|
17
16
|
function Switch(_ref) {
|
|
18
17
|
let {
|
|
19
18
|
value,
|
|
@@ -38,7 +37,6 @@ function Switch(_ref) {
|
|
|
38
37
|
setChecked(value);
|
|
39
38
|
}
|
|
40
39
|
}, [value, checked]);
|
|
41
|
-
|
|
42
40
|
// This special logic is to handle weird APIs like Airtable that return
|
|
43
41
|
// true or undefined for a boolean
|
|
44
42
|
const previousDefaultValue = (0, _hooks.usePrevious)(defaultValue);
|
|
@@ -47,24 +45,24 @@ function Switch(_ref) {
|
|
|
47
45
|
setChecked(Boolean(defaultValue));
|
|
48
46
|
}
|
|
49
47
|
}, [defaultValue, previousDefaultValue]);
|
|
50
|
-
return /*#__PURE__*/React.createElement(_reactNative.Switch,
|
|
48
|
+
return /*#__PURE__*/React.createElement(_reactNative.Switch, {
|
|
51
49
|
value: checked,
|
|
52
50
|
disabled: disabled,
|
|
53
51
|
trackColor: {
|
|
54
52
|
false: inactiveTrackThemeColor,
|
|
55
53
|
true: activeTrackThemeColor
|
|
56
54
|
},
|
|
57
|
-
thumbColor: value ? activeThumbThemeColor : inactiveThumbThemeColor
|
|
55
|
+
thumbColor: value ? activeThumbThemeColor : inactiveThumbThemeColor,
|
|
58
56
|
// @ts-ignore react-native-web only
|
|
59
|
-
,
|
|
60
57
|
activeThumbColor: activeThumbThemeColor,
|
|
61
58
|
ios_backgroundColor: inactiveTrackThemeColor,
|
|
62
59
|
style: style,
|
|
63
60
|
onValueChange: bool => {
|
|
64
61
|
setChecked(bool);
|
|
65
62
|
onValueChange && onValueChange(bool);
|
|
66
|
-
}
|
|
67
|
-
|
|
63
|
+
},
|
|
64
|
+
...rest
|
|
65
|
+
});
|
|
68
66
|
}
|
|
69
67
|
function Row(_ref2) {
|
|
70
68
|
let {
|
|
@@ -93,7 +91,7 @@ function Row(_ref2) {
|
|
|
93
91
|
setChecked(defaultValue);
|
|
94
92
|
}
|
|
95
93
|
}, [defaultValue]);
|
|
96
|
-
return /*#__PURE__*/React.createElement(_FormRow.default,
|
|
94
|
+
return /*#__PURE__*/React.createElement(_FormRow.default, {
|
|
97
95
|
disabled: disabled,
|
|
98
96
|
onPress: () => {
|
|
99
97
|
setChecked(!checked);
|
|
@@ -101,8 +99,9 @@ function Row(_ref2) {
|
|
|
101
99
|
},
|
|
102
100
|
label: label,
|
|
103
101
|
direction: direction,
|
|
104
|
-
style: style
|
|
105
|
-
|
|
102
|
+
style: style,
|
|
103
|
+
...rest
|
|
104
|
+
}, /*#__PURE__*/React.createElement(Switch, {
|
|
106
105
|
theme: theme,
|
|
107
106
|
value: checked,
|
|
108
107
|
disabled: disabled,
|
|
@@ -116,4 +115,14 @@ function Row(_ref2) {
|
|
|
116
115
|
const SwitchRow = (0, _theming.withTheme)(Row);
|
|
117
116
|
exports.SwitchRow = SwitchRow;
|
|
118
117
|
var _default = (0, _theming.withTheme)(Switch);
|
|
118
|
+
exports.default = _default;hange: onValueChange,
|
|
119
|
+
activeTrackColor: activeTrackColor,
|
|
120
|
+
inactiveTrackColor: inactiveTrackColor,
|
|
121
|
+
activeThumbColor: activeThumbColor,
|
|
122
|
+
inactiveThumbColor: inactiveThumbColor
|
|
123
|
+
}));
|
|
124
|
+
}
|
|
125
|
+
const SwitchRow = (0, _theming.withTheme)(Row);
|
|
126
|
+
exports.SwitchRow = SwitchRow;
|
|
127
|
+
var _default = (0, _theming.withTheme)(Switch);
|
|
119
128
|
exports.default = _default;
|
|
@@ -11,7 +11,6 @@ var _IconButton = _interopRequireDefault(require("./IconButton"));
|
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
|
-
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); }
|
|
15
14
|
const ToggleButton = _ref => {
|
|
16
15
|
let {
|
|
17
16
|
Icon,
|
|
@@ -47,7 +46,7 @@ const ToggleButton = _ref => {
|
|
|
47
46
|
setInternalValue(!internalValue);
|
|
48
47
|
onPress(!internalValue);
|
|
49
48
|
};
|
|
50
|
-
return /*#__PURE__*/React.createElement(_IconButton.default,
|
|
49
|
+
return /*#__PURE__*/React.createElement(_IconButton.default, {
|
|
51
50
|
Icon: Icon,
|
|
52
51
|
icon: icon,
|
|
53
52
|
size: iconSize,
|
|
@@ -59,6 +58,20 @@ const ToggleButton = _ref => {
|
|
|
59
58
|
height,
|
|
60
59
|
backgroundColor: internalValue ? colors[colorSecondary] : colors[color],
|
|
61
60
|
borderColor: colors[borderColor]
|
|
61
|
+
}, style],
|
|
62
|
+
...rest
|
|
63
|
+
});
|
|
64
|
+
};
|
|
65
|
+
const styles = _reactNative.StyleSheet.create({
|
|
66
|
+
mainContainer: {
|
|
67
|
+
borderWidth: 1
|
|
68
|
+
}
|
|
69
|
+
});
|
|
70
|
+
var _default = (0, _theming.withTheme)(ToggleButton);
|
|
71
|
+
exports.default = _default;idth,
|
|
72
|
+
height,
|
|
73
|
+
backgroundColor: internalValue ? colors[colorSecondary] : colors[color],
|
|
74
|
+
borderColor: colors[borderColor]
|
|
62
75
|
}, style]
|
|
63
76
|
}, rest));
|
|
64
77
|
};
|
|
@@ -12,4 +12,4 @@ const APPROX_STATUSBAR_HEIGHT = _reactNative.Platform.select({
|
|
|
12
12
|
android: DEFAULT_STATUSBAR_HEIGHT_EXPO,
|
|
13
13
|
ios: _reactNative.Platform.Version < 11 ? DEFAULT_STATUSBAR_HEIGHT_EXPO : 0
|
|
14
14
|
});
|
|
15
|
-
exports.APPROX_STATUSBAR_HEIGHT = APPROX_STATUSBAR_HEIGHT;
|
|
15
|
+
exports.APPROX_STATUSBAR_HEIGHT = APPROX_STATUSBAR_HEIGHT;AR_HEIGHT;
|
package/lib/commonjs/hooks.js
CHANGED
|
@@ -10,12 +10,11 @@ function usePrevious(value) {
|
|
|
10
10
|
// The ref object is a generic container whose current property is mutable
|
|
11
11
|
// and can hold any value, similar to an instance property on a class
|
|
12
12
|
const ref = _react.default.useRef();
|
|
13
|
-
|
|
14
13
|
// Store current value in ref
|
|
15
14
|
_react.default.useEffect(() => {
|
|
16
15
|
ref.current = value;
|
|
17
16
|
}, [value]);
|
|
18
|
-
|
|
19
17
|
// Return previous value (happens before update in useEffect above)
|
|
20
18
|
return ref.current;
|
|
19
|
+
}
|
|
21
20
|
}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SEED_DATA = void 0;
|
|
7
|
+
var _types = require("@draftbit/types");
|
|
8
|
+
const SEED_DATA_PROPS = {
|
|
9
|
+
image: {
|
|
10
|
+
group: _types.GROUPS.data,
|
|
11
|
+
label: "Image",
|
|
12
|
+
description: "Image",
|
|
13
|
+
formType: _types.FORM_TYPES.image,
|
|
14
|
+
propType: _types.PROP_TYPES.ASSET,
|
|
15
|
+
defaultValue: null,
|
|
16
|
+
editable: true,
|
|
17
|
+
required: false
|
|
18
|
+
},
|
|
19
|
+
title: {
|
|
20
|
+
group: _types.GROUPS.data,
|
|
21
|
+
label: "Title",
|
|
22
|
+
description: "Text to display",
|
|
23
|
+
formType: _types.FORM_TYPES.string,
|
|
24
|
+
propType: _types.PROP_TYPES.STRING,
|
|
25
|
+
defaultValue: "Beautiful West Coast Villa",
|
|
26
|
+
editable: true,
|
|
27
|
+
required: false
|
|
28
|
+
},
|
|
29
|
+
leftDescription: {
|
|
30
|
+
group: _types.GROUPS.data,
|
|
31
|
+
label: "Left description",
|
|
32
|
+
description: "Text to display on the left",
|
|
33
|
+
formType: _types.FORM_TYPES.string,
|
|
34
|
+
propType: _types.PROP_TYPES.STRING,
|
|
35
|
+
defaultValue: "San Diego",
|
|
36
|
+
editable: true,
|
|
37
|
+
required: false
|
|
38
|
+
},
|
|
39
|
+
rightDescription: {
|
|
40
|
+
group: _types.GROUPS.data,
|
|
41
|
+
label: "Right description",
|
|
42
|
+
description: "Text to display on the right",
|
|
43
|
+
formType: _types.FORM_TYPES.string,
|
|
44
|
+
propType: _types.PROP_TYPES.STRING,
|
|
45
|
+
defaultValue: "$100",
|
|
46
|
+
editable: true,
|
|
47
|
+
required: false
|
|
48
|
+
},
|
|
49
|
+
aspectRatio: {
|
|
50
|
+
group: _types.GROUPS.basic,
|
|
51
|
+
label: "Aspect ratio",
|
|
52
|
+
description: "Aspect ratio of the image",
|
|
53
|
+
formType: _types.FORM_TYPES.aspectRatio,
|
|
54
|
+
propType: _types.PROP_TYPES.NUMBER,
|
|
55
|
+
defaultValue: 1.5,
|
|
56
|
+
editable: true,
|
|
57
|
+
required: false
|
|
58
|
+
},
|
|
59
|
+
titleCentered: {
|
|
60
|
+
group: _types.GROUPS.basic,
|
|
61
|
+
label: "Title centered",
|
|
62
|
+
description: "Whether to center the title",
|
|
63
|
+
formType: _types.FORM_TYPES.boolean,
|
|
64
|
+
propType: _types.PROP_TYPES.BOOLEAN,
|
|
65
|
+
defaultValue: false,
|
|
66
|
+
editable: true,
|
|
67
|
+
required: false
|
|
68
|
+
},
|
|
69
|
+
elevation: (0, _types.createElevationType)(2)
|
|
70
|
+
};
|
|
71
|
+
const SEED_DATA = [{
|
|
72
|
+
name: "Small Card",
|
|
73
|
+
tag: "CardBlock",
|
|
74
|
+
description: "An elevated card with a title and description, that takes up one third of its container.",
|
|
75
|
+
category: _types.COMPONENT_TYPES.card,
|
|
76
|
+
props: {
|
|
77
|
+
...SEED_DATA_PROPS,
|
|
78
|
+
numColumns: (0, _types.createNumColumnsType)({
|
|
79
|
+
defaultValue: 1
|
|
80
|
+
})
|
|
81
|
+
}
|
|
82
|
+
}, {
|
|
83
|
+
name: "Medium Block Card",
|
|
84
|
+
tag: "CardBlock",
|
|
85
|
+
description: "An elevated card with a title and description, that takes up one half of its container.",
|
|
86
|
+
category: _types.COMPONENT_TYPES.card,
|
|
87
|
+
props: {
|
|
88
|
+
...SEED_DATA_PROPS,
|
|
89
|
+
icon: {
|
|
90
|
+
group: _types.GROUPS.basic,
|
|
91
|
+
label: "Icon",
|
|
92
|
+
description: "Icon to display on the top right",
|
|
93
|
+
formType: _types.FORM_TYPES.icon,
|
|
94
|
+
propType: _types.PROP_TYPES.STRING,
|
|
95
|
+
defaultValue: null,
|
|
96
|
+
editable: true,
|
|
97
|
+
required: true
|
|
98
|
+
},
|
|
99
|
+
numColumns: (0, _types.createNumColumnsType)({
|
|
100
|
+
defaultValue: 2
|
|
101
|
+
})
|
|
102
|
+
}
|
|
103
|
+
}, {
|
|
104
|
+
name: "Large Block Card",
|
|
105
|
+
tag: "CardBlock",
|
|
106
|
+
description: "An elevated card with a title and description, that takes up the full width its container.",
|
|
107
|
+
category: _types.COMPONENT_TYPES.card,
|
|
108
|
+
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
109
|
+
props: {
|
|
110
|
+
...SEED_DATA_PROPS,
|
|
111
|
+
icon: {
|
|
112
|
+
group: _types.GROUPS.basic,
|
|
113
|
+
label: "Icon",
|
|
114
|
+
description: "Icon to display on the top right",
|
|
115
|
+
formType: _types.FORM_TYPES.icon,
|
|
116
|
+
propType: _types.PROP_TYPES.STRING,
|
|
117
|
+
defaultValue: null,
|
|
118
|
+
editable: true,
|
|
119
|
+
required: true
|
|
120
|
+
},
|
|
121
|
+
numColumns: (0, _types.createNumColumnsType)({
|
|
122
|
+
defaultValue: 3
|
|
123
|
+
})
|
|
124
|
+
}
|
|
125
|
+
}];
|
|
126
|
+
exports.SEED_DATA = SEED_DATA;
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SEED_DATA = void 0;
|
|
7
|
+
var _types = require("@draftbit/types");
|
|
8
|
+
const SEED_DATA_PROPS = {
|
|
9
|
+
image: {
|
|
10
|
+
label: "Image",
|
|
11
|
+
description: "Image",
|
|
12
|
+
formType: _types.FORM_TYPES.image,
|
|
13
|
+
propType: _types.PROP_TYPES.ASSET,
|
|
14
|
+
defaultValue: null,
|
|
15
|
+
editable: true,
|
|
16
|
+
required: true,
|
|
17
|
+
group: _types.GROUPS.data
|
|
18
|
+
},
|
|
19
|
+
title: {
|
|
20
|
+
label: "Title",
|
|
21
|
+
description: "Text to display",
|
|
22
|
+
formType: _types.FORM_TYPES.string,
|
|
23
|
+
propType: _types.PROP_TYPES.STRING,
|
|
24
|
+
defaultValue: "Beautiful West Coast Villa",
|
|
25
|
+
editable: true,
|
|
26
|
+
required: false,
|
|
27
|
+
group: _types.GROUPS.data
|
|
28
|
+
},
|
|
29
|
+
leftDescription: {
|
|
30
|
+
label: "Left description",
|
|
31
|
+
description: "Text to display on the left",
|
|
32
|
+
formType: _types.FORM_TYPES.string,
|
|
33
|
+
propType: _types.PROP_TYPES.STRING,
|
|
34
|
+
defaultValue: "San Diego",
|
|
35
|
+
editable: true,
|
|
36
|
+
required: false,
|
|
37
|
+
group: _types.GROUPS.data
|
|
38
|
+
},
|
|
39
|
+
rightDescription: {
|
|
40
|
+
label: "Right description",
|
|
41
|
+
description: "Text to display on the right",
|
|
42
|
+
formType: _types.FORM_TYPES.string,
|
|
43
|
+
propType: _types.PROP_TYPES.STRING,
|
|
44
|
+
defaultValue: "$100",
|
|
45
|
+
editable: true,
|
|
46
|
+
required: false,
|
|
47
|
+
group: _types.GROUPS.data
|
|
48
|
+
},
|
|
49
|
+
icon: {
|
|
50
|
+
label: "Icon",
|
|
51
|
+
description: "Icon to display on the top right",
|
|
52
|
+
formType: _types.FORM_TYPES.icon,
|
|
53
|
+
propType: _types.PROP_TYPES.STRING /* OR ASSET TODO TEST ME */,
|
|
54
|
+
defaultValue: null,
|
|
55
|
+
editable: true,
|
|
56
|
+
required: false,
|
|
57
|
+
group: _types.GROUPS.basic
|
|
58
|
+
},
|
|
59
|
+
aspectRatio: {
|
|
60
|
+
label: "Aspect ratio",
|
|
61
|
+
description: "Aspect ratio of the image",
|
|
62
|
+
formType: _types.FORM_TYPES.aspectRatio,
|
|
63
|
+
propType: _types.PROP_TYPES.NUMBER,
|
|
64
|
+
defaultValue: 1.5,
|
|
65
|
+
editable: true,
|
|
66
|
+
required: false,
|
|
67
|
+
group: _types.GROUPS.basic
|
|
68
|
+
},
|
|
69
|
+
textCentered: {
|
|
70
|
+
label: "Centered Text",
|
|
71
|
+
description: "Whether to center the text",
|
|
72
|
+
formType: _types.FORM_TYPES.boolean,
|
|
73
|
+
propType: _types.PROP_TYPES.BOOLEAN,
|
|
74
|
+
defaultValue: false,
|
|
75
|
+
editable: true,
|
|
76
|
+
required: false,
|
|
77
|
+
group: _types.GROUPS.basic
|
|
78
|
+
},
|
|
79
|
+
elevation: (0, _types.createElevationType)(2)
|
|
80
|
+
};
|
|
81
|
+
const SEED_DATA = [{
|
|
82
|
+
name: "Medium Card",
|
|
83
|
+
tag: "CardContainer",
|
|
84
|
+
description: "An elevated card with a title and description, that takes up half of its container.",
|
|
85
|
+
category: _types.COMPONENT_TYPES.card,
|
|
86
|
+
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
87
|
+
layout: null,
|
|
88
|
+
props: {
|
|
89
|
+
...SEED_DATA_PROPS,
|
|
90
|
+
numColumns: (0, _types.createNumColumnsType)({
|
|
91
|
+
defaultValue: 2
|
|
92
|
+
})
|
|
93
|
+
}
|
|
94
|
+
}, {
|
|
95
|
+
name: "Large Card",
|
|
96
|
+
tag: "CardContainer",
|
|
97
|
+
description: "An elevated card with a title and description, that takes up its full container.",
|
|
98
|
+
category: _types.COMPONENT_TYPES.card,
|
|
99
|
+
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
100
|
+
layout: null,
|
|
101
|
+
props: {
|
|
102
|
+
...SEED_DATA_PROPS,
|
|
103
|
+
numColumns: (0, _types.createNumColumnsType)({
|
|
104
|
+
defaultValue: 3
|
|
105
|
+
})
|
|
106
|
+
}
|
|
107
|
+
}];
|
|
108
|
+
exports.SEED_DATA = SEED_DATA;
|