@draftbit/core 43.4.1 → 43.4.2-9ce900.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/lib/commonjs/Provider.js.map +1 -1
- package/lib/commonjs/components/DeprecatedFAB.js +4 -20
- package/lib/commonjs/components/DeprecatedFAB.js.map +1 -1
- package/lib/commonjs/components/Divider.js +3 -13
- package/lib/commonjs/components/Divider.js.map +1 -1
- package/lib/commonjs/components/Elevation.js +14 -3
- package/lib/commonjs/components/Elevation.js.map +1 -1
- package/lib/commonjs/components/FAB.js +19 -5
- package/lib/commonjs/components/FAB.js.map +1 -1
- package/lib/commonjs/components/HeaderOverline.js.map +1 -1
- package/lib/commonjs/components/Justification.js +1 -2
- package/lib/commonjs/components/Picker/PickerComponent.ios.js +30 -10
- package/lib/commonjs/components/Picker/PickerComponent.ios.js.map +1 -1
- package/lib/commonjs/components/Swiper/Swiper.js.map +1 -1
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/mappings/Fetch.js.map +1 -1
- package/lib/commonjs/mappings/HeaderLarge.js.map +1 -1
- package/lib/commonjs/mappings/Icon.js.map +1 -1
- package/lib/commonjs/mappings/RadioButtonGroup.js.map +1 -1
- package/lib/commonjs/mappings/RadioButtonRow.js.map +1 -1
- package/lib/commonjs/mappings/RowBodyIcon.js.map +1 -1
- package/lib/commonjs/mappings/RowHeadlineImageCaption.js.map +1 -1
- package/lib/commonjs/mappings/RowHeadlineImageIcon.js.map +1 -1
- package/lib/commonjs/mappings/ToggleButton.js.map +1 -1
- package/lib/commonjs/styles/overlay.js.map +1 -1
- package/lib/module/components/RadioButton/RadioButtonGroup.js +16 -5
- package/lib/module/components/RadioButton/RadioButtonGroup.js.map +1 -1
- package/lib/module/mappings/CheckboxGroup.js.map +1 -1
- package/lib/module/mappings/Container.js.map +1 -1
- package/package.json +2 -2
- package/lib/commonjs/mappings/DeprecatedButton.js +0 -111
- package/lib/commonjs/mappings/DeprecatedButton.js.map +0 -1
- package/lib/commonjs/mappings/DeprecatedFAB.js +0 -147
- package/lib/commonjs/mappings/DeprecatedFAB.js.map +0 -1
- package/lib/module/mappings/DeprecatedButton.js +0 -102
- package/lib/module/mappings/DeprecatedButton.js.map +0 -1
- package/lib/module/mappings/DeprecatedFAB.js +0 -138
- package/lib/module/mappings/DeprecatedFAB.js.map +0 -1
- package/lib/typescript/src/mappings/DeprecatedButton.d.ts +0 -89
- package/lib/typescript/src/mappings/DeprecatedFAB.d.ts +0 -178
- package/src/mappings/DeprecatedButton.js +0 -106
- package/src/mappings/DeprecatedButton.ts +0 -115
- package/src/mappings/DeprecatedFAB.js +0 -146
- package/src/mappings/DeprecatedFAB.ts +0 -153
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Provider.
|
|
1
|
+
{"version":3,"sources":["Provider.js"],"names":["Provider","React","Component","render","createElement","PortalHost","ThemeProvider","theme","props","children"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;;;;;;;AACe,MAAMA,QAAN,SAAuBC,KAAK,CAACC,SAA7B,CAAuC;AAClDC,EAAAA,MAAM,GAAG;AACL,wBAAQF,KAAK,CAACG,aAAN,CAAoBC,mBAApB,EAAgC,IAAhC,eACJJ,KAAK,CAACG,aAAN,CAAoBE,sBAApB,EAAmC;AAAEC,MAAAA,KAAK,EAAE,KAAKC,KAAL,CAAWD;AAApB,KAAnC,EAAgE,KAAKC,KAAL,CAAWC,QAA3E,CADI,CAAR;AAEH;;AAJiD","sourcesContent":["import * as React from \"react\";\nimport { ThemeProvider } from \"./theming\";\nimport PortalHost from \"./components/Portal/PortalHost\";\nexport default class Provider extends React.Component {\n render() {\n return (React.createElement(PortalHost, null,\n React.createElement(ThemeProvider, { theme: this.props.theme }, this.props.children)));\n }\n}\n"]}
|
|
@@ -27,6 +27,8 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
27
27
|
|
|
28
28
|
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; }
|
|
29
29
|
|
|
30
|
+
function _extends() { _extends = Object.assign || 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); }
|
|
31
|
+
|
|
30
32
|
const FAB = _ref => {
|
|
31
33
|
let {
|
|
32
34
|
Icon,
|
|
@@ -128,7 +130,7 @@ const FAB = _ref => {
|
|
|
128
130
|
style: [{
|
|
129
131
|
elevation
|
|
130
132
|
}, style]
|
|
131
|
-
}, /*#__PURE__*/React.createElement(_Touchable.default, {
|
|
133
|
+
}, /*#__PURE__*/React.createElement(_Touchable.default, _extends({}, rest, {
|
|
132
134
|
onPress: onPress,
|
|
133
135
|
accessibilityState: {
|
|
134
136
|
disabled
|
|
@@ -136,7 +138,7 @@ const FAB = _ref => {
|
|
|
136
138
|
accessibilityRole: "button",
|
|
137
139
|
disabled: disabled || loading,
|
|
138
140
|
style: buttonStyles
|
|
139
|
-
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
141
|
+
}), /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
140
142
|
style: styles.content
|
|
141
143
|
}, icon && loading !== true ? /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
142
144
|
style: iconStyle
|
|
@@ -179,23 +181,5 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
179
181
|
|
|
180
182
|
var _default = (0, _theming.withTheme)(FAB);
|
|
181
183
|
|
|
182
|
-
exports.default = _default;
|
|
183
|
-
//# sourceMappingURL=DeprecatedFAB.js.map },
|
|
184
|
-
icon: {
|
|
185
|
-
alignItems: "center",
|
|
186
|
-
justifyContent: "center",
|
|
187
|
-
width: _Config.default.buttonIconSize
|
|
188
|
-
},
|
|
189
|
-
fixed: {
|
|
190
|
-
left: 0,
|
|
191
|
-
right: 0,
|
|
192
|
-
bottom: 0,
|
|
193
|
-
height: 64,
|
|
194
|
-
borderRadius: 0
|
|
195
|
-
}
|
|
196
|
-
});
|
|
197
|
-
|
|
198
|
-
var _default = (0, _theming.withTheme)(FAB);
|
|
199
|
-
|
|
200
184
|
exports.default = _default;
|
|
201
185
|
//# sourceMappingURL=DeprecatedFAB.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["DeprecatedFAB.js"],"names":["FAB","Icon","icon","disabled","type","loading","color","colorOverride","label","onPress","elevation","style","theme","colors","disabledOpacity","roundness","typography","rest","backgroundColor","borderColor","textColor","borderWidth","buttonColor","primary","surface","alpha","rgb","string","StyleSheet","hairlineWidth","buttonStyle","borderRadius","alignItems","justifyContent","buttonStyles","styles","button","contentStyle","content","textStyle","textAlign","iconStyle","width","Config","buttonIconSize","FABSize","height","FABBorderRadius","push","marginLeft","marginRight","margin","FABFixedHeight","alignSelf","React","createElement","Elevation","Touchable","accessibilityState","accessibilityRole","View","name","size","ActivityIndicator","Text","numberOfLines","create","borderStyle","flexDirection","fixed","left","right","bottom"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;AACA,MAAMA,GAAG,GAAG,QAAuM;AAAA,MAAtM;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,IAAR;AAAcC,IAAAA,QAAQ,GAAG,KAAzB;AAAgCC,IAAAA,IAAI,GAAG,OAAvC;AAAgD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AEc,SAAxB;AAAmCT,IAAAA,KAAK,EAAE8B;AAA1C,GAAvC,CAAJ,GAAqG,IAHhH,EAIIjC,KAAK,gBAAI8C,KAAK,CAACC,aAAN,CAAoBS,aAApB,EAA0B;AAAEC,IAAAA,aAAa,EAAE,CAAjB;AAAoBtD,IAAAA,KAAK,EAAE,CAAC4B,SAAD,EAAYvB,UAAU,CAACoB,MAAvB;AAA3B,GAA1B,EAAuF5B,KAAvF,CAAJ,GAAqG,IAJ9G,CADJ,CADI,CAAR;AAOH,CAnFD;;AAoFA,MAAM2B,MAAM,GAAGP,wBAAWsC,MAAX,CAAkB;AAC7B9B,EAAAA,MAAM,EAAE;AACJ+B,IAAAA,WAAW,EAAE;AADT,GADqB;AAI7B7B,EAAAA,OAAO,EAAE;AACL8B,IAAAA,aAAa,EAAE,KADV;AAELpC,IAAAA,UAAU,EAAE,QAFP;AAGLC,IAAAA,cAAc,EAAE;AAHX,GAJoB;AAS7B/B,EAAAA,IAAI,EAAE;AACF8B,IAAAA,UAAU,EAAE,QADV;AAEFC,IAAAA,cAAc,EAAE,QAFd;AAGFS,IAAAA,KAAK,EAAEC,gBAAOC;AAHZ,GATuB;AAc7ByB,EAAAA,KAAK,EAAE;AACHC,IAAAA,IAAI,EAAE,CADH;AAEHC,IAAAA,KAAK,EAAE,CAFJ;AAGHC,IAAAA,MAAM,EAAE,CAHL;AAIH1B,IAAAA,MAAM,EAAE,EAJL;AAKHf,IAAAA,YAAY,EAAE;AALX;AAdsB,CAAlB,CAAf;;eAsBe,wBAAU/B,GAAV,C","sourcesContent":["import * as React from \"react\";\nimport { ActivityIndicator, View, StyleSheet, } from \"react-native\";\nimport color from \"color\";\nimport Config from \"./Config\";\nimport Text from \"./Text\";\nimport Touchable from \"./Touchable\";\nimport Elevation from \"./Elevation\";\nimport { withTheme } from \"../theming\";\nconst FAB = ({ Icon, icon, disabled = false, type = \"solid\", loading = false, color: colorOverride, label, onPress, elevation = 0, style, theme: { colors, disabledOpacity, roundness, typography }, ...rest }) => {\n let backgroundColor, borderColor, textColor, borderWidth;\n const buttonColor = colorOverride || colors.primary;\n if (type === \"standard\" || type === \"extended\" || type === \"fixed\") {\n backgroundColor = buttonColor;\n if (disabled) {\n textColor = color(colors.surface).alpha(disabledOpacity).rgb().string();\n }\n else {\n textColor = colors.surface;\n }\n }\n else {\n backgroundColor = \"transparent\";\n if (disabled) {\n textColor = color(buttonColor).alpha(disabledOpacity).rgb().string();\n }\n else {\n textColor = buttonColor;\n }\n }\n if (type === \"outline\") {\n if (disabled) {\n borderColor = color(buttonColor).alpha(disabledOpacity).rgb().string();\n }\n else {\n borderColor = buttonColor;\n }\n borderWidth = StyleSheet.hairlineWidth;\n }\n else {\n borderColor = \"transparent\";\n borderWidth = 0;\n }\n const buttonStyle = {\n backgroundColor,\n borderColor,\n borderWidth,\n borderRadius: roundness,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n const buttonStyles = [styles.button, buttonStyle];\n const contentStyle = [styles.content];\n const textStyle = {\n textAlign: \"center\",\n color: textColor,\n };\n const iconStyle = [\n styles.icon,\n {\n width: Config.buttonIconSize,\n },\n ];\n if (type === \"standard\" || type === \"outline\") {\n buttonStyle.width = Config.FABSize;\n buttonStyle.height = Config.FABSize;\n buttonStyle.borderRadius = Config.FABBorderRadius;\n contentStyle.push({\n width: Config.FABSize,\n height: Config.FABSize,\n });\n }\n if (type === \"extended\" || type === \"fixed\") {\n iconStyle.push({\n marginLeft: 16,\n marginRight: -8,\n });\n textStyle.margin = 16;\n }\n if (type === \"fixed\") {\n buttonStyles.push({\n height: Config.FABFixedHeight,\n alignSelf: \"stretch\",\n });\n }\n return (React.createElement(Elevation, { style: [{ elevation }, style] },\n React.createElement(Touchable, { ...rest, onPress: onPress, accessibilityState: { disabled }, accessibilityRole: \"button\", disabled: disabled || loading, style: buttonStyles },\n React.createElement(View, { style: styles.content },\n icon && loading !== true ? (React.createElement(View, { style: iconStyle },\n React.createElement(Icon, { name: icon, size: Config.buttonIconSize, color: textColor }))) : null,\n loading ? (React.createElement(ActivityIndicator, { size: \"small\", color: textColor, style: iconStyle })) : null,\n label ? (React.createElement(Text, { numberOfLines: 1, style: [textStyle, typography.button] }, label)) : null))));\n};\nconst styles = StyleSheet.create({\n button: {\n borderStyle: \"solid\",\n },\n content: {\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n icon: {\n alignItems: \"center\",\n justifyContent: \"center\",\n width: Config.buttonIconSize,\n },\n fixed: {\n left: 0,\n right: 0,\n bottom: 0,\n height: 64,\n borderRadius: 0,\n },\n});\nexport default withTheme(FAB);\n"]}
|
|
1
|
+
{"version":3,"sources":["DeprecatedFAB.tsx"],"names":["FAB","Icon","icon","disabled","type","loading","color","colorOverride","label","onPress","elevation","style","theme","colors","disabledOpacity","roundness","typography","rest","backgroundColor","borderColor","textColor","borderWidth","buttonColor","primary","surface","alpha","rgb","string","StyleSheet","hairlineWidth","buttonStyle","borderRadius","alignItems","justifyContent","buttonStyles","styles","button","contentStyle","content","textStyle","textAlign","iconStyle","width","Config","buttonIconSize","FABSize","height","FABBorderRadius","push","marginLeft","marginRight","margin","FABFixedHeight","alignSelf","create","borderStyle","flexDirection","fixed","left","right","bottom"],"mappings":";;;;;;;AAAA;;AACA;;AASA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;AAuDA,MAAMA,GAAoB,GAAG,QAavB;AAAA,MAbwB;AAC5BC,IAAAA,IAD4B;AAE5BC,IAAAA,IAF4B;AAG5BC,IAAAA,QAAQ,GAAG,KAHiB;AAI5BC,IAAAA,IAAI,GAAG,OAJqB;AAK5BC,IAAAA,OAAO,GAAG,KALkB;AAM5BC,IAAAA,KAAK,EAAEC,aANqB;AAO5BC,IAAAA,KAP4B;AAQ5BC,IAAAA,OAR4B;AAS5BC,IAAAA,SAAS,GAAG,CATgB;AAU5BC,IAAAA,KAV4B;AAW5BC,IAAAA,KAAK,EAAE;AAAEC,MAAAA,MAAF;AAAUC,MAAAA,eAAV;A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c,EAAE;AAHT,GAJsB;AAS/B/B,EAAAA,IAAI,EAAE;AACJ8B,IAAAA,UAAU,EAAE,QADR;AAEJC,IAAAA,cAAc,EAAE,QAFZ;AAGJS,IAAAA,KAAK,EAAEC,gBAAOC;AAHV,GATyB;AAc/Ba,EAAAA,KAAK,EAAE;AACLC,IAAAA,IAAI,EAAE,CADD;AAELC,IAAAA,KAAK,EAAE,CAFF;AAGLC,IAAAA,MAAM,EAAE,CAHH;AAILd,IAAAA,MAAM,EAAE,EAJH;AAKLf,IAAAA,YAAY,EAAE;AALT;AAdwB,CAAlB,CAAf;;eAuBe,wBAAU/B,GAAV,C","sourcesContent":["import * as React from \"react\";\nimport {\n ActivityIndicator,\n View,\n StyleSheet,\n TouchableHighlightProps,\n StyleProp,\n ViewStyle,\n TextStyle,\n} from \"react-native\";\nimport color from \"color\";\nimport Config from \"./Config\";\nimport Text from \"./Text\";\nimport Touchable from \"./Touchable\";\nimport Elevation from \"./Elevation\";\nimport { withTheme } from \"../theming\";\n\nimport type { Theme } from \"../styles/DefaultTheme\";\nimport type { IconSlot } from \"../interfaces/Icon\";\n\n/**\n * A floating action button represents the primary action in an application.\n *\n * <div class=\"screenshots\">\n * <img src=\"screenshots/fab-1.png\" />\n * <img src=\"screenshots/fab-2.png\" />\n * </div>\n *\n * ## Usage\n * ```js\n * import * as React from 'react';\n * import { StyleSheet } from 'react-native';\n * import { FAB } from '@draftbit/ui';\n *\n * const MyComponent = () => (\n * <FAB\n * style={styles.fab}\n * type=\"outline\"\n * icon=\"add\"\n * onPress={() => console.log('Pressed')}\n * />\n * );\n *\n * const styles = StyleSheet.create({\n * fab: {\n * position: 'absolute',\n * margin: 16,\n * right: 0,\n * bottom: 0,\n * },\n * })\n *\n * export default MyComponent;\n * ```\n */\n\ntype Props = {\n disabled?: boolean;\n type?: \"solid\" | \"extended\" | \"outline\" | \"fixed\" | \"standard\";\n loading?: boolean;\n icon?: string;\n color?: string;\n label?: string;\n onPress: () => void;\n elevation?: number;\n theme: Theme;\n style?: StyleProp<ViewStyle>;\n} & TouchableHighlightProps &\n IconSlot;\n\nconst FAB: React.FC<Props> = ({\n Icon,\n icon,\n disabled = false,\n type = \"solid\",\n loading = false,\n color: colorOverride,\n label,\n onPress,\n elevation = 0,\n style,\n theme: { colors, disabledOpacity, roundness, typography },\n ...rest\n}) => {\n let backgroundColor, borderColor, textColor, borderWidth;\n const buttonColor = colorOverride || colors.primary;\n\n if (type === \"standard\" || type === \"extended\" || type === \"fixed\") {\n backgroundColor = buttonColor;\n\n if (disabled) {\n textColor = color(colors.surface).alpha(disabledOpacity).rgb().string();\n } else {\n textColor = colors.surface;\n }\n } else {\n backgroundColor = \"transparent\";\n\n if (disabled) {\n textColor = color(buttonColor).alpha(disabledOpacity).rgb().string();\n } else {\n textColor = buttonColor;\n }\n }\n\n if (type === \"outline\") {\n if (disabled) {\n borderColor = color(buttonColor).alpha(disabledOpacity).rgb().string();\n } else {\n borderColor = buttonColor;\n }\n borderWidth = StyleSheet.hairlineWidth;\n } else {\n borderColor = \"transparent\";\n borderWidth = 0;\n }\n\n const buttonStyle: StyleProp<ViewStyle> = {\n backgroundColor,\n borderColor,\n borderWidth,\n borderRadius: roundness,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n\n const buttonStyles: StyleProp<ViewStyle>[] = [styles.button, buttonStyle];\n\n const contentStyle: StyleProp<ViewStyle>[] = [styles.content];\n\n const textStyle: StyleProp<TextStyle> = {\n textAlign: \"center\",\n color: textColor,\n };\n\n const iconStyle: StyleProp<ViewStyle>[] = [\n styles.icon,\n {\n width: Config.buttonIconSize,\n },\n ];\n\n if (type === \"standard\" || type === \"outline\") {\n buttonStyle.width = Config.FABSize;\n buttonStyle.height = Config.FABSize;\n buttonStyle.borderRadius = Config.FABBorderRadius;\n\n contentStyle.push({\n width: Config.FABSize,\n height: Config.FABSize,\n });\n }\n\n if (type === \"extended\" || type === \"fixed\") {\n iconStyle.push({\n marginLeft: 16,\n marginRight: -8,\n });\n\n textStyle.margin = 16;\n }\n\n if (type === \"fixed\") {\n buttonStyles.push({\n height: Config.FABFixedHeight,\n alignSelf: \"stretch\",\n });\n }\n\n return (\n <Elevation style={[{ elevation }, style]}>\n <Touchable\n {...rest}\n onPress={onPress}\n accessibilityState={{ disabled }}\n accessibilityRole=\"button\"\n disabled={disabled || loading}\n style={buttonStyles}\n >\n <View style={styles.content}>\n {icon && loading !== true ? (\n <View style={iconStyle}>\n <Icon\n name={icon}\n size={Config.buttonIconSize}\n color={textColor}\n />\n </View>\n ) : null}\n {loading ? (\n <ActivityIndicator\n size=\"small\"\n color={textColor}\n style={iconStyle}\n />\n ) : null}\n {label ? (\n <Text numberOfLines={1} style={[textStyle, typography.button]}>\n {label}\n </Text>\n ) : null}\n </View>\n </Touchable>\n </Elevation>\n );\n};\n\nconst styles = StyleSheet.create({\n button: {\n borderStyle: \"solid\",\n },\n content: {\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n icon: {\n alignItems: \"center\",\n justifyContent: \"center\",\n width: Config.buttonIconSize,\n },\n fixed: {\n left: 0,\n right: 0,\n bottom: 0,\n height: 64,\n borderRadius: 0,\n },\n});\n\nexport default withTheme(FAB);\n"]}
|
|
@@ -15,6 +15,8 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
15
15
|
|
|
16
16
|
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; }
|
|
17
17
|
|
|
18
|
+
function _extends() { _extends = Object.assign || 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); }
|
|
19
|
+
|
|
18
20
|
const Divider = _ref => {
|
|
19
21
|
let {
|
|
20
22
|
style,
|
|
@@ -24,19 +26,7 @@ const Divider = _ref => {
|
|
|
24
26
|
},
|
|
25
27
|
...rest
|
|
26
28
|
} = _ref;
|
|
27
|
-
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
28
|
-
style: [{
|
|
29
|
-
backgroundColor: color || colors.divider,
|
|
30
|
-
height: _reactNative.StyleSheet.hairlineWidth
|
|
31
|
-
}, style],
|
|
32
|
-
...rest
|
|
33
|
-
});
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
var _default = (0, _theming.withTheme)(Divider);
|
|
37
|
-
|
|
38
|
-
exports.default = _default;
|
|
39
|
-
//# sourceMappingURL=Divider.js.map /*#__PURE__*/React.createElement(_reactNative.View, _extends({
|
|
29
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, _extends({
|
|
40
30
|
style: [{
|
|
41
31
|
backgroundColor: color || colors.divider,
|
|
42
32
|
height: _reactNative.StyleSheet.hairlineWidth
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Divider.
|
|
1
|
+
{"version":3,"sources":["Divider.tsx"],"names":["Divider","style","color","theme","colors","rest","backgroundColor","divider","height","StyleSheet","hairlineWidth"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;;;;;;;AASA,MAAMA,OAAwB,GAAG,QAK3B;AAAA,MAL4B;AAChCC,IAAAA,KADgC;AAEhCC,IAAAA,KAFgC;AAGhCC,IAAAA,KAAK,EAAE;AAAEC,MAAAA;AAAF,KAHyB;AAIhC,OAAGC;AAJ6B,GAK5B;AACJ,sBACE,oBAAC,iBAAD;AACE,IAAA,KAAK,EAAE,CACL;AACEC,MAAAA,eAAe,EAAEJ,KAAK,IAAIE,MAAM,CAACG,OADnC;AAEEC,MAAAA,MAAM,EAAEC,wBAAWC;AAFrB,KADK,EAKLT,KALK;AADT,KAQMI,IARN,EADF;AAYD,CAlBD;;eAoBe,wBAAUL,OAAV,C","sourcesContent":["import * as React from \"react\";\nimport { StyleSheet, View, StyleProp, ViewStyle } from \"react-native\";\nimport { withTheme } from \"../theming\";\nimport theme from \"../styles/DefaultTheme\";\n\ntype Props = {\n style?: StyleProp<ViewStyle>;\n color?: string;\n theme: typeof theme;\n};\n\nconst Divider: React.FC<Props> = ({\n style,\n color,\n theme: { colors },\n ...rest\n}) => {\n return (\n <View\n style={[\n {\n backgroundColor: color || colors.divider,\n height: StyleSheet.hairlineWidth,\n },\n style,\n ]}\n {...rest}\n />\n );\n};\n\nexport default withTheme(Divider);\n"]}
|
|
@@ -19,8 +19,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
19
19
|
|
|
20
20
|
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; }
|
|
21
21
|
|
|
22
|
-
function _extends() { _extends = Object.assign || 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); }
|
|
23
|
-
|
|
24
22
|
/* directly copied from https://github.com/callstack/react-native-paper/blob/main/src/components/Surface.tsx#L62 */
|
|
25
23
|
const Elevation = _ref => {
|
|
26
24
|
let {
|
|
@@ -37,11 +35,24 @@ const Elevation = _ref => {
|
|
|
37
35
|
colors
|
|
38
36
|
} = theme;
|
|
39
37
|
const borderRadius = radius;
|
|
40
|
-
return /*#__PURE__*/React.createElement(_reactNative.Animated.View,
|
|
38
|
+
return /*#__PURE__*/React.createElement(_reactNative.Animated.View, { ...rest,
|
|
41
39
|
style: [{
|
|
42
40
|
borderRadius,
|
|
43
41
|
backgroundColor: colors.surface
|
|
44
42
|
}, elevation ? (0, _shadow.default)(elevation) : null, style]
|
|
43
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
44
|
+
style: {
|
|
45
|
+
overflow: "hidden",
|
|
46
|
+
borderRadius
|
|
47
|
+
}
|
|
48
|
+
}, children));
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
var _default = (0, _theming.withTheme)(Elevation);
|
|
52
|
+
|
|
53
|
+
exports.default = _default;
|
|
54
|
+
//# sourceMappingURL=Elevation.js.mape
|
|
55
|
+
}, elevation ? (0, _shadow.default)(elevation) : null, style]
|
|
45
56
|
}), /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
46
57
|
style: {
|
|
47
58
|
overflow: "hidden",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Elevation.
|
|
1
|
+
{"version":3,"sources":["Elevation.js"],"names":["Elevation","style","theme","children","rest","elevation","borderRadius","radius","StyleSheet","flatten","colors","React","createElement","Animated","View","backgroundColor","surface","overflow"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;;;AACA;AACA,MAAMA,SAAS,GAAG,QAAyC;AAAA,MAAxC;AAAEC,IAAAA,KAAF;AAASC,IAAAA,KAAT;AAAgBC,IAAAA,QAAhB;AAA0B,OAAGC;AAA7B,GAAwC;AACvD,QAAM;AAAEC,IAAAA,SAAS,GAAG,CAAd;AAAiBC,IAAAA,YAAY,EAAEC;AAA/B,MAA0CC,wBAAWC,OAAX,CAAmBR,KAAnB,KAA6B,EAA7E;AACA,QAAM;AAAES,IAAAA;AAAF,MAAaR,KAAnB;AACA,QAAMI,YAAY,GAAGC,MAArB;AACA,sBAAQI,KAAK,CAACC,aAAN,CAAoBC,sBAASC,IAA7B,EAAmC,EAAE,GAAGV,IAAL;AAAWH,IAAAA,KAAK,EAAE,CACrD;AACIK,MAAAA,YADJ;AAEIS,MAAAA,eAAe,EAAEL,MAAM,CAACM;AAF5B,KADqD,EAKrDX,SAAS,GAAG,qBAAOA,SAAP,CAAH,GAAuB,IALqB,EAMrDJ,KANqD;AAAlB,GAAnC,eAQJU,KAAK,CAACC,aAAN,CAAoBE,iBAApB,EAA0B;AAAEb,IAAAA,KAAK,EAAE;AAAEgB,MAAAA,QAAQ,EAAE,QAAZ;AAAsBX,MAAAA;AAAtB;AAAT,GAA1B,EAA2EH,QAA3E,CARI,CAAR;AASH,CAbD;;eAce,wBAAUH,SAAV,C","sourcesContent":["import * as React from \"react\";\nimport { Animated, StyleSheet, View, } from \"react-native\";\nimport shadow from \"../styles/shadow\";\nimport { withTheme } from \"../theming\";\n/* directly copied from https://github.com/callstack/react-native-paper/blob/main/src/components/Surface.tsx#L62 */\nconst Elevation = ({ style, theme, children, ...rest }) => {\n const { elevation = 4, borderRadius: radius } = StyleSheet.flatten(style) || {};\n const { colors } = theme;\n const borderRadius = radius;\n return (React.createElement(Animated.View, { ...rest, style: [\n {\n borderRadius,\n backgroundColor: colors.surface,\n },\n elevation ? shadow(elevation) : null,\n style,\n ] },\n React.createElement(View, { style: { overflow: \"hidden\", borderRadius } }, children)));\n};\nexport default withTheme(Elevation);\n"]}
|
|
@@ -15,8 +15,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
15
15
|
|
|
16
16
|
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; }
|
|
17
17
|
|
|
18
|
-
function _extends() { _extends = Object.assign || 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); }
|
|
19
|
-
|
|
20
18
|
const FAB = _ref => {
|
|
21
19
|
let {
|
|
22
20
|
onPress,
|
|
@@ -40,7 +38,7 @@ const FAB = _ref => {
|
|
|
40
38
|
borderRadius: size / 2,
|
|
41
39
|
overflow: "hidden"
|
|
42
40
|
}, style]
|
|
43
|
-
}, /*#__PURE__*/React.createElement(_reactNative.Pressable,
|
|
41
|
+
}, /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
44
42
|
onPress: onPress,
|
|
45
43
|
disabled: loading || disabled,
|
|
46
44
|
android_ripple: {
|
|
@@ -58,8 +56,9 @@ const FAB = _ref => {
|
|
|
58
56
|
borderRadius: size / 2,
|
|
59
57
|
backgroundColor
|
|
60
58
|
}];
|
|
61
|
-
}
|
|
62
|
-
|
|
59
|
+
},
|
|
60
|
+
...props
|
|
61
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, null, loading ? /*#__PURE__*/React.createElement(_reactNative.ActivityIndicator, {
|
|
63
62
|
style: size > 50 ? {
|
|
64
63
|
marginTop: 2,
|
|
65
64
|
marginLeft: 2
|
|
@@ -89,5 +88,20 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
89
88
|
|
|
90
89
|
var _default = (0, _theming.withTheme)(FAB);
|
|
91
90
|
|
|
91
|
+
exports.default = _default;
|
|
92
|
+
//# sourceMappingURL=FAB.js.map backgroundColor: "#5a45ff",
|
|
93
|
+
justifyContent: "center",
|
|
94
|
+
alignItems: "center",
|
|
95
|
+
..._reactNative.Platform.select({
|
|
96
|
+
web: {
|
|
97
|
+
cursor: "pointer",
|
|
98
|
+
userSelect: "none"
|
|
99
|
+
}
|
|
100
|
+
})
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
var _default = (0, _theming.withTheme)(FAB);
|
|
105
|
+
|
|
92
106
|
exports.default = _default;
|
|
93
107
|
//# sourceMappingURL=FAB.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["FAB.
|
|
1
|
+
{"version":3,"sources":["FAB.js"],"names":["FAB","onPress","disabled","loading","iconName","style","theme","iconColor","bgColor","size","Icon","props","backgroundColor","colors","primary","color","React","createElement","View","width","height","borderRadius","overflow","Pressable","android_ripple","radius","pressed","styles","button","opacity","ActivityIndicator","marginTop","marginLeft","undefined","name","StyleSheet","create","justifyContent","alignItems","Platform","select","web","cursor","userSelect"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;;;;;AACA,MAAMA,GAAG,GAAG,QAAiI;AAAA,MAAhI;AAAEC,IAAAA,OAAF;AAAWC,IAAAA,QAAX;AAAqBC,IAAAA,OAArB;AAA8BC,IAAAA,QAAQ,GAAG,mBAAzC;AAA8DC,IAAAA,KAA9D;AAAqEC,IAAAA,KAArE;AAA4EC,IAAAA,SAA5E;AAAuFC,IAAAA,OAAvF;AAAgGC,IAAAA,IAAI,GAAG,EAAvG;AAA2GC,IAAAA,IAA3G;AAAiH,OAAGC;AAApH,GAAgI;AACzI,QAAMC,eAAe,GAAGJ,OAAO,IAAI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AZ,GAA8CC,SAAvD;AAAkExB,IAAAA,IAAI,EAAEA,IAAI,IAAI,EAAR,GAAa,OAAb,GAAuB,OAA/F;AAAwGM,IAAAA,KAAK,EAAEA;AAA/G,GAAvC,CAAJ,gBAAuKC,KAAK,CAACC,aAAN,CAAoBP,IAApB,EAA0B;AAAEwB,IAAAA,IAAI,EAAE9B,QAAR;AAAkBK,IAAAA,IAAI,EAAEA,IAAxB;AAA8BM,IAAAA,KAAK,EAAEA;AAArC,GAA1B,CAA9M,CAfJ,CATI,CAAR;AAyBH,CA5BD;;AA6BA,MAAMY,MAAM,GAAGQ,wBAAWC,MAAX,CAAkB;AAC7BR,EAAAA,MAAM,EAAE;AACJhB,IAAAA,eAAe,EAAE,SADb;AAEJyB,IAAAA,cAAc,EAAE,QAFZ;AAGJC,IAAAA,UAAU,EAAE,QAHR;AAIJ,OAAGC,sBAASC,MAAT,CAAgB;AACfC,MAAAA,GAAG,EAAE;AACDC,QAAAA,MAAM,EAAE,SADP;AAEDC,QAAAA,UAAU,EAAE;AAFX;AADU,KAAhB;AAJC;AADqB,CAAlB,CAAf;;eAae,wBAAU3C,GAAV,C","sourcesContent":["import * as React from \"react\";\nimport { View, StyleSheet, Pressable, ActivityIndicator, Platform, } from \"react-native\";\nimport { withTheme } from \"../theming\";\nconst FAB = ({ onPress, disabled, loading, iconName = \"MaterialIcons/add\", style, theme, iconColor, bgColor, size = 50, Icon, ...props }) => {\n const backgroundColor = bgColor || theme.colors.primary;\n const color = iconColor || \"#FFF\";\n return (React.createElement(View, { style: [\n {\n width: size,\n height: size,\n borderRadius: size / 2,\n overflow: \"hidden\",\n },\n style,\n ] },\n React.createElement(Pressable, { onPress: onPress, disabled: loading || disabled, android_ripple: {\n color: \"#333\",\n radius: size / 4,\n }, style: ({ pressed }) => {\n return [\n styles.button,\n {\n opacity: pressed || disabled ? 0.75 : 1,\n width: size,\n height: size,\n borderRadius: size / 2,\n backgroundColor,\n },\n ];\n }, ...props },\n React.createElement(View, null, loading ? (React.createElement(ActivityIndicator, { style: size > 50 ? { marginTop: 2, marginLeft: 2 } : undefined, size: size <= 50 ? \"small\" : \"large\", color: color })) : (React.createElement(Icon, { name: iconName, size: size, color: color }))))));\n};\nconst styles = StyleSheet.create({\n button: {\n backgroundColor: \"#5a45ff\",\n justifyContent: \"center\",\n alignItems: \"center\",\n ...Platform.select({\n web: {\n cursor: \"pointer\",\n userSelect: \"none\",\n },\n }),\n },\n});\nexport default withTheme(FAB);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["HeaderOverline.
|
|
1
|
+
{"version":3,"sources":["HeaderOverline.tsx"],"names":["HeaderOverline","Icon","title","buttonText","icon","onPress","style","theme","colors","typography","overline","light","toUpperCase"],"mappings":";;;;;;;AAAA;;AACA;;AAIA;;;;;;;;AAYA,MAAMA,cAA+B,GAAG,QAQlC;AAAA,MARmC;AACvCC,IAAAA,IADuC;AAEvCC,IAAAA,KAFuC;AAGvCC,IAAAA,UAHuC;AAIvCC,IAAAA,IAJuC;AAKvCC,IAAAA,OAAO,GAAG,MAAM,CAAE,CALqB;AAMvCC,IAAAA,KANuC;AAOvCC,IAAAA,KAAK,EAAE;AAAEC,MAAAA,MAAF;AAAUC,MAAAA;AAAV;AAPgC,GAQnC;AACJ,sBACE,oBAAC,eAAD;AACE,IAAA,IAAI,EAAER,IADR;AAEE,IAAA,cAAc,EAAEQ,UAAU,CAACC,QAF7B;AAGE,IAAA,UAAU,EAAEF,MAAM,CAACG,KAHrB;AAIE,IAAA,KAAK,EAAET,KAAK,IAAIA,KAAK,CAACU,WAAN,EAJlB;AAKE,IAAA,UAAU,EAAET,UALd;AAME,IAAA,IAAI,EAAEC,IANR;AAOE,IAAA,gBAAgB,EAAE,EAPpB;AAQE,IAAA,OAAO,EAAEC,OARX;AASE,IAAA,KAAK,EAAEC;AATT,IADF;AAaD,CAtBD;;eAwBe,wBAAUN,cAAV,C","sourcesContent":["import * as React from \"react\";\nimport { withTheme } from \"../theming\";\nimport type { Theme } from \"../styles/DefaultTheme\";\nimport type { IconSlot } from \"../interfaces/Icon\";\n\nimport Header from \"./Header\";\nimport { StyleProp, ViewStyle } from \"react-native\";\n\ntype Props = {\n title: string;\n buttonText: string;\n icon: string;\n onPress?: () => void;\n style?: StyleProp<ViewStyle>;\n theme: Theme;\n} & IconSlot;\n\nconst HeaderOverline: React.FC<Props> = ({\n Icon,\n title,\n buttonText,\n icon,\n onPress = () => {},\n style,\n theme: { colors, typography },\n}) => {\n return (\n <Header\n Icon={Icon}\n titleTypeStyle={typography.overline}\n titleColor={colors.light}\n title={title && title.toUpperCase()}\n buttonText={buttonText}\n icon={icon}\n dividerTopMargin={12}\n onPress={onPress}\n style={style}\n />\n );\n};\n\nexport default withTheme(HeaderOverline);\n"]}
|
|
@@ -33,8 +33,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
33
33
|
|
|
34
34
|
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; }
|
|
35
35
|
|
|
36
|
-
function _extends() { _extends = Object.assign || 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); }
|
|
37
|
-
|
|
38
36
|
const Picker = _ref => {
|
|
39
37
|
var _options$find$label, _options$find;
|
|
40
38
|
|
|
@@ -98,18 +96,17 @@ const Picker = _ref => {
|
|
|
98
96
|
}, /*#__PURE__*/React.createElement(_Touchable.default, {
|
|
99
97
|
disabled: disabled,
|
|
100
98
|
onPress: toggleVisibility
|
|
101
|
-
}, /*#__PURE__*/React.createElement(_TextField.default,
|
|
99
|
+
}, /*#__PURE__*/React.createElement(_TextField.default, { ...props,
|
|
102
100
|
value: String(selectedLabel),
|
|
103
|
-
placeholder: placeholder
|
|
104
|
-
|
|
105
|
-
ref: textField
|
|
106
|
-
,
|
|
101
|
+
placeholder: placeholder,
|
|
102
|
+
// @ts-ignore
|
|
103
|
+
ref: textField,
|
|
107
104
|
disabled: disabled,
|
|
108
|
-
pointerEvents: "none"
|
|
109
|
-
|
|
105
|
+
pointerEvents: "none",
|
|
106
|
+
// @ts-expect-error
|
|
110
107
|
style: stylesWithoutMargin,
|
|
111
108
|
Icon: Icon
|
|
112
|
-
}))
|
|
109
|
+
})), pickerVisible && /*#__PURE__*/React.createElement(_Portal.default, null, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
113
110
|
style: [styles.picker, {
|
|
114
111
|
backgroundColor: colors.divider
|
|
115
112
|
}]
|
|
@@ -157,5 +154,28 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
157
154
|
|
|
158
155
|
var _default = (0, _theming.withTheme)(Picker);
|
|
159
156
|
|
|
157
|
+
exports.default = _default;
|
|
158
|
+
//# sourceMappingURL=PickerComponent.ios.js.mapretch"
|
|
159
|
+
},
|
|
160
|
+
picker: {
|
|
161
|
+
position: "absolute",
|
|
162
|
+
bottom: 0,
|
|
163
|
+
left: 0,
|
|
164
|
+
right: 0,
|
|
165
|
+
flexDirection: "row",
|
|
166
|
+
justifyContent: "center"
|
|
167
|
+
},
|
|
168
|
+
pickerContainer: {
|
|
169
|
+
backgroundColor: "white",
|
|
170
|
+
flexDirection: "column",
|
|
171
|
+
width: "100%"
|
|
172
|
+
},
|
|
173
|
+
closeButton: {
|
|
174
|
+
alignSelf: "flex-end"
|
|
175
|
+
}
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
var _default = (0, _theming.withTheme)(Picker);
|
|
179
|
+
|
|
160
180
|
exports.default = _default;
|
|
161
181
|
//# sourceMappingURL=PickerComponent.ios.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["PickerComponent.ios.
|
|
1
|
+
{"version":3,"sources":["PickerComponent.ios.js"],"names":["Picker","Icon","style","options","placeholder","selectedValue","disabled","onValueChange","theme","colors","props","viewStyles","borderRadius","borderWidth","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","borderColor","backgroundColor","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","textField","React","useRef","undefined","pickerVisible","setIsPickerVisible","useState","toggleVisibility","current","toggleFocus","stylesWithoutMargin","StyleSheet","flatten","selectedLabel","find","o","value","label","createElement","View","styles","container","Touchable","onPress","TextField","String","ref","pointerEvents","Portal","picker","divider","SafeAreaView","pickerContainer","Button","type","closeButton","NativePicker","map","Item","key","create","alignSelf","position","bottom","left","right","flexDirection","justifyContent","width"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;AACA,MAAMA,MAAM,GAAG,QAAoI;AAAA;;AAAA,MAAnI;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,KAAR;AAAeC,IAAAA,OAAf;AAAwBC,IAAAA,WAAxB;AAAqCC,IAAAA,aAArC;AAAoDC,IAAAA,QAAQ,GAAG,KAA/D;AAAsEC,IAAAA,aAAa,GAAG,MAAM,CAAG,CAA/F;AAAiGC,IAAAA,KAAK,EAAE;AAAEC,MAAAA;AAAF,KAAxG;AAAoH,OAAGC;AAAvH,GAAmI;AAC/I,QAAM;AAAEC,IAAAA,UAAU,EAAE;AAAEC,MAAAA,YAAF;AAAgB;AACpCC,MAAAA,WADoB;AACP;AACbC,MAAAA,cAFoB;AAEJ;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,CAAatB,CAAD,iBAAQd,KAAK,CAACiB,aAAN,CAAoBkB,eAAaE,IAAjC,EAAuC;AAAErB,IAAAA,KAAK,EAAEF,CAAC,CAACE,KAAX;AAAkBD,IAAAA,KAAK,EAAED,CAAC,CAACC,KAA3B;AAAkCuB,IAAAA,GAAG,EAAExB,CAAC,CAACC;AAAzC,GAAvC,CAApB,CAAvI,CAFJ,CADJ,CADc,CAPd,CAAR;AAYH,CA5CD;;AA6CA,MAAMI,MAAM,GAAGT,wBAAW6B,MAAX,CAAkB;AAC7BnB,EAAAA,SAAS,EAAE;AACPoB,IAAAA,SAAS,EAAE;AADJ,GADkB;AAI7BZ,EAAAA,MAAM,EAAE;AACJa,IAAAA,QAAQ,EAAE,UADN;AAEJC,IAAAA,MAAM,EAAE,CAFJ;AAGJC,IAAAA,IAAI,EAAE,CAHF;AAIJC,IAAAA,KAAK,EAAE,CAJH;AAKJC,IAAAA,aAAa,EAAE,KALX;AAMJC,IAAAA,cAAc,EAAE;AANZ,GAJqB;AAY7Bf,EAAAA,eAAe,EAAE;AACbtC,IAAAA,eAAe,EAAE,OADJ;AAEboD,IAAAA,aAAa,EAAE,QAFF;AAGbE,IAAAA,KAAK,EAAE;AAHM,GAZY;AAiB7Bb,EAAAA,WAAW,EAAE;AACTM,IAAAA,SAAS,EAAE;AADF;AAjBgB,CAAlB,CAAf;;eAqBe,wBAAUlE,MAAV,C","sourcesContent":["import * as React from \"react\";\nimport { View, StyleSheet } from \"react-native\";\nimport { SafeAreaView } from \"react-native-safe-area-context\";\nimport omit from \"lodash.omit\";\nimport { Picker as NativePicker } from \"@react-native-picker/picker\";\nimport { withTheme } from \"../../theming\";\nimport Portal from \"../Portal/Portal\";\nimport Button from \"../DeprecatedButton\";\nimport TextField from \"../TextField\";\nimport Touchable from \"../Touchable\";\nimport { extractStyles } from \"../../utilities\";\nconst Picker = ({ Icon, style, options, placeholder, selectedValue, disabled = false, onValueChange = () => { }, theme: { colors }, ...props }) => {\n const { viewStyles: { borderRadius, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderWidth, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderTopWidth, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderRightWidth, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderBottomWidth, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderLeftWidth, // eslint-disable-line @typescript-eslint/no-unused-vars\n borderColor, // eslint-disable-line @typescript-eslint/no-unused-vars\n backgroundColor, // eslint-disable-line @typescript-eslint/no-unused-vars\n padding, // eslint-disable-line @typescript-eslint/no-unused-vars\n paddingTop, // eslint-disable-line @typescript-eslint/no-unused-vars\n paddingRight, // eslint-disable-line @typescript-eslint/no-unused-vars\n paddingBottom, // eslint-disable-line @typescript-eslint/no-unused-vars\n paddingLeft, // eslint-disable-line @typescript-eslint/no-unused-vars\n ...viewStyles }, } = extractStyles(style);\n const textField = React.useRef(undefined);\n const [pickerVisible, setIsPickerVisible] = React.useState(false);\n const toggleVisibility = () => {\n setIsPickerVisible(!pickerVisible);\n // @ts-ignore\n textField.current.toggleFocus(); // cannot determine if method exists due to component being wrapped in a withTheme()\n };\n const stylesWithoutMargin = style &&\n omit(StyleSheet.flatten(style), [\n \"margin\",\n \"marginTop\",\n \"marginRight\",\n \"marginBottom\",\n \"marginLeft\",\n ]);\n const selectedLabel = selectedValue &&\n (options.find((o) => o.value === selectedValue)?.label ?? selectedValue);\n return (React.createElement(View, { style: [styles.container, viewStyles] },\n React.createElement(Touchable, { disabled: disabled, onPress: toggleVisibility },\n React.createElement(TextField, { ...props, value: String(selectedLabel), placeholder: placeholder, \n // @ts-ignore\n ref: textField, disabled: disabled, pointerEvents: \"none\", \n // @ts-expect-error\n style: stylesWithoutMargin, Icon: Icon })),\n pickerVisible && (React.createElement(Portal, null,\n React.createElement(View, { style: [styles.picker, { backgroundColor: colors.divider }] },\n React.createElement(SafeAreaView, { style: styles.pickerContainer },\n React.createElement(Button, { Icon: Icon, type: \"text\", onPress: toggleVisibility, style: styles.closeButton }, \"Close\"),\n React.createElement(NativePicker, { style: { backgroundColor: \"white\" }, selectedValue: selectedValue, onValueChange: onValueChange }, options.map((o) => (React.createElement(NativePicker.Item, { label: o.label, value: o.value, key: o.value }))))))))));\n};\nconst styles = StyleSheet.create({\n container: {\n alignSelf: \"stretch\",\n },\n picker: {\n position: \"absolute\",\n bottom: 0,\n left: 0,\n right: 0,\n flexDirection: \"row\",\n justifyContent: \"center\",\n },\n pickerContainer: {\n backgroundColor: \"white\",\n flexDirection: \"column\",\n width: \"100%\",\n },\n closeButton: {\n alignSelf: \"flex-end\",\n },\n});\nexport default withTheme(Picker);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Swiper.
|
|
1
|
+
{"version":3,"sources":["Swiper.js"],"names":["Swiper","vertical","loop","timeout","from","prevTitle","nextTitle","prevTitleColor","nextTitleColor","dotsTouchable","dotColor","dotActiveColor","children","style","React","createElement","View","SwiperComponent","controlsProps","prevTitleStyle","color","nextTitleStyle","dotProps","badgeStyle","backgroundColor","dotActiveStyle"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;;;AACA,MAAMA,MAAM,GAAG;AAAA,MAAC;AAAEC,IAAAA,QAAQ,GAAG,KAAb;AAAoBC,IAAAA,IAAI,GAAG,KAA3B;AAAkCC,IAAAA,OAAO,GAAG,CAA5C;AAA+CC,IAAAA,IAAI,GAAG,CAAtD;AAAyDC,IAAAA,SAAS,GAAG,EAArE;AAAyEC,IAAAA,SAAS,GAAG,EAArF;AAAyFC,IAAAA,cAAzF;AAAyGC,IAAAA,cAAzG;AAAyHC,IAAAA,aAAa,GAAG,IAAzI;AAA+IC,IAAAA,QAA/I;AAAyJC,IAAAA,cAAzJ;AAAyKC,IAAAA,QAAzK;AAAmLC,IAAAA;AAAnL,GAAD;AAAA,sBAAkMC,eAAMC,aAAN,CAAoBC,iBAApB,EAA0B;AAAEH,IAAAA,KAAK,EAAEA;AAAT,GAA1B,eAC7MC,eAAMC,aAAN,CAAoBE,6BAApB,EAAqC;AAAEb,IAAAA,IAAI,EAAEA,IAAR;AAAcF,IAAAA,IAAI,EAAEA,IAApB;AAA0BC,IAAAA,OAAO,EAAEA,OAAnC;AAA4CF,IAAAA,QAAQ,EAAEA,QAAtD;AAAgEiB,IAAAA,aAAa,EAAE;AAC5Gb,MAAAA,SAD4G;AAE5GC,MAAAA,SAF4G;AAG5Ga,MAAAA,cAAc,EAAE;AAAEC,QAAAA,KAAK,EAAEb;AAAT,OAH4F;AAI5Gc,MAAAA,cAAc,EAAE;AAAED,QAAAA,KAAK,EAAEZ;AAAT,OAJ4F;AAK5GC,MAAAA,aAL4G;AAM5G,UAAIC,QAAQ,GACN;AAAEY,QAAAA,QAAQ,EAAE;AAAEC,UAAAA,UAAU,EAAE;AAAEC,YAAAA,eAAe,EAAEd;AAAnB;AAAd;AAAZ,OADM,GAEN,EAFN,CAN4G;AAS5G,UAAIC,cAAc,GACZ;AAAEc,QAAAA,cAAc,EAAE;AAAED,UAAAA,eAAe,EAAEb;AAAnB;AAAlB,OADY,GAEZ,EAFN;AAT4G;AAA/E,GAArC,EAYSC,QAZT,CAD6M,CAAlM;AAAA,CAAf;;eAceZ,M","sourcesContent":["import React from \"react\";\nimport { View } from \"react-native\";\nimport SwiperComponent from \"react-native-web-swiper\";\nconst Swiper = ({ vertical = false, loop = false, timeout = 0, from = 0, prevTitle = \"\", nextTitle = \"\", prevTitleColor, nextTitleColor, dotsTouchable = true, dotColor, dotActiveColor, children, style, }) => (React.createElement(View, { style: style },\n React.createElement(SwiperComponent, { from: from, loop: loop, timeout: timeout, vertical: vertical, controlsProps: {\n prevTitle,\n nextTitle,\n prevTitleStyle: { color: prevTitleColor },\n nextTitleStyle: { color: nextTitleColor },\n dotsTouchable,\n ...(dotColor\n ? { dotProps: { badgeStyle: { backgroundColor: dotColor } } }\n : {}),\n ...(dotActiveColor\n ? { dotActiveStyle: { backgroundColor: dotActiveColor } }\n : {}),\n } }, children)));\nexport default Swiper;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["index.
|
|
1
|
+
{"version":3,"sources":["index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA","sourcesContent":["export { injectIcon } from \"./interfaces/Icon\";\nexport { withTheme, ThemeProvider } from \"./theming\";\nexport { default as Provider } from \"./Provider\";\nexport { default as DefaultTheme } from \"./styles/DefaultTheme\";\nexport { Link } from \"./components/Text\";\nexport { ButtonSolid, ButtonOutline } from \"./components/Button\";\nexport { default as Avatar } from \"./components/CircleImage\";\nexport { default as AvatarEdit } from \"./components/AvatarEdit\";\nexport { default as Card } from \"./components/Card\";\nexport { default as Carousel } from \"./components/Carousel\";\nexport { Checkbox, CheckboxGroup, CheckboxRow } from \"./components/Checkbox\";\nexport { default as CircleImage } from \"./components/CircleImage\";\nexport { default as Container } from \"./components/Container\";\nexport { default as Divider } from \"./components/Divider\";\nexport { default as FAB } from \"./components/FAB\";\nexport { default as FieldSearchBarFull } from \"./components/FieldSearchBarFull\";\nexport { default as IconButton } from \"./components/IconButton\";\nexport { default as Image } from \"./components/Image\";\nexport { default as NumberInput } from \"./components/NumberInput\";\nexport { default as ScreenContainer } from \"./components/ScreenContainer\";\nexport { default as StarRating } from \"./components/StarRating\";\nexport { default as Surface } from \"./components/Surface\";\nexport { default as Switch, SwitchRow } from \"./components/Switch\";\nexport { default as TextField } from \"./components/TextField\";\nexport { default as ToggleButton } from \"./components/ToggleButton\";\nexport { default as Touchable } from \"./components/Touchable\";\nexport { AccordionGroup, AccordionItem } from \"./components/Accordion\";\nexport { ActionSheet, ActionSheetItem, ActionSheetCancel, } from \"./components/ActionSheet\";\nexport { Swiper, SwiperItem } from \"./components/Swiper\";\nexport { Center, Circle, Square, Row, Stack, Spacer, } from \"./components/Layout\";\nexport { RadioButton, RadioButtonGroup, RadioButtonRow, RadioButtonFieldGroup, } from \"./components/RadioButton/index\";\n/* Deprecated: Fix or Delete! */\nexport { default as Button } from \"./components/DeprecatedButton\";\nexport { default as CardBlock } from \"./components/CardBlock\";\nexport { default as CardContainer } from \"./components/CardContainer\";\nexport { default as CardContainerRating } from \"./components/CardContainerRating\";\nexport { default as CardInline } from \"./components/CardInline\";\nexport { default as DatePicker } from \"./components/DatePicker/DatePicker\";\nexport { default as HeaderLarge } from \"./components/HeaderLarge\";\nexport { default as HeaderMedium } from \"./components/HeaderMedium\";\nexport { default as HeaderOverline } from \"./components/HeaderOverline\";\nexport { default as Picker } from \"./components/Picker/Picker\";\nexport { default as ProgressBar } from \"./components/ProgressBar\";\nexport { default as ProgressCircle } from \"./components/ProgressCircle\";\nexport { default as RowBodyIcon } from \"./components/RowBodyIcon\";\nexport { default as RowHeadlineImageCaption } from \"./components/RowHeadlineImageCaption\";\nexport { default as RowHeadlineImageIcon } from \"./components/RowHeadlineImageIcon\";\nexport { default as Slider } from \"./components/Slider\";\nexport { default as Stepper } from \"./components/Stepper\";\nexport { useAuthState } from \"./components/useAuthState\";\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Fetch.
|
|
1
|
+
{"version":3,"sources":["Fetch.js"],"names":["SEED_DATA","name","tag","description","category","COMPONENT_TYPES","data","layout","minHeight","props"],"mappings":";;;;;;;AAAA;;AACA;AACO,MAAMA,SAAS,GAAG;AACrBC,EAAAA,IAAI,EAAE,OADe;AAErBC,EAAAA,GAAG,EAAE,OAFgB;AAGrBC,EAAAA,WAAW,EAAE,qEAHQ;AAIrBC,EAAAA,QAAQ,EAAEC,uBAAgBC,IAJL;AAKrBC,EAAAA,MAAM,EAAE;AACJC,IAAAA,SAAS,EAAE;AADP,GALa;AAQrBC,EAAAA,KAAK,EAAE;AARc,CAAlB","sourcesContent":["import { COMPONENT_TYPES } from \"@draftbit/types\";\n/* TODO remove, still used inside the builder in a weird way */\nexport const SEED_DATA = {\n name: \"Fetch\",\n tag: \"Fetch\",\n description: \"Rest API Declarative Fetch component. Uses react-request internally\",\n category: COMPONENT_TYPES.data,\n layout: {\n minHeight: 40,\n },\n props: {},\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["HeaderLarge.
|
|
1
|
+
{"version":3,"sources":["HeaderLarge.js"],"names":["SEED_DATA","name","tag","description","category","COMPONENT_TYPES","header","layout","triggers","Triggers","OnPress","props","onPress","title","label","defaultValue","buttonText","icon","required"],"mappings":";;;;;;;AAAA;;AACO,MAAMA,SAAS,GAAG,CACrB;AACIC,EAAAA,IAAI,EAAE,cADV;AAEIC,EAAAA,GAAG,EAAE,aAFT;AAGIC,EAAAA,WAAW,EAAE,wEAHjB;AAIIC,EAAAA,QAAQ,EAAEC,uBAAgBC,MAJ9B;AAKIC,EAAAA,MAAM,EAAE,EALZ;AAMIC,EAAAA,QAAQ,EAAE,CAACC,gBAASC,OAAV,CANd;AAOIC,EAAAA,KAAK,EAAE;AACHC,IAAAA,OAAO,EAAE,8BADN;AAEHC,IAAAA,KAAK,EAAE,2BAAe;AAClBC,MAAAA,KAAK,EAAE,OADW;AAElBX,MAAAA,WAAW,EAAE,iBAFK;AAGlBY,MAAAA,YAAY,EAAE;AAHI,KAAf,CAFJ;AAOHC,IAAAA,UAAU,EAAE,2BAAe;AACvBF,MAAAA,KAAK,EAAE,aADgB;AAEvBX,MAAAA,WAAW,EAAE,sCAFU;AAGvBY,MAAAA,YAAY,EAAE;AAHS,KAAf,CAPT;AAYHE,IAAAA,IAAI,EAAE,2BAAe;AACjBF,MAAAA,YAAY,EAAE,IADG;AAEjBG,MAAAA,QAAQ,EAAE;AAFO,KAAf;AAZH;AAPX,CADqB,CAAlB","sourcesContent":["import { COMPONENT_TYPES, createIconProp, createTextProp, createActionProp, Triggers, } from \"@draftbit/types\";\nexport const SEED_DATA = [\n {\n name: \"Header Large\",\n tag: \"HeaderLarge\",\n description: \"A large header with an optional touchable right aligned text and icon.\",\n category: COMPONENT_TYPES.header,\n layout: {},\n triggers: [Triggers.OnPress],\n props: {\n onPress: createActionProp(),\n title: createTextProp({\n label: \"Title\",\n description: \"Text to display\",\n defaultValue: \"Title\",\n }),\n buttonText: createTextProp({\n label: \"Button text\",\n description: \"Right aligned button text to display\",\n defaultValue: \"See All\",\n }),\n icon: createIconProp({\n defaultValue: null,\n required: false,\n }),\n },\n },\n];\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Icon.
|
|
1
|
+
{"version":3,"sources":["Icon.js"],"names":["SEED_DATA","name","tag","description","category","COMPONENT_TYPES","basic","layout","props","color","size","group","GROUPS","label","defaultValue","min","max","step","precision"],"mappings":";;;;;;;AAAA;;AACO,MAAMA,SAAS,GAAG;AACrBC,EAAAA,IAAI,EAAE,MADe;AAErBC,EAAAA,GAAG,EAAE,MAFgB;AAGrBC,EAAAA,WAAW,EAAE,SAHQ;AAIrBC,EAAAA,QAAQ,EAAEC,uBAAgBC,KAJL;AAKrBC,EAAAA,MAAM,EAAE,EALa;AAMrBC,EAAAA,KAAK,EAAE;AACHP,IAAAA,IAAI,EAAE,4BADH;AAEHQ,IAAAA,KAAK,EAAE,6BAFJ;AAGHC,IAAAA,IAAI,EAAE,6BAAiB;AACnBC,MAAAA,KAAK,EAAEC,cAAON,KADK;AAEnBO,MAAAA,KAAK,EAAE,MAFY;AAGnBV,MAAAA,WAAW,EAAE,+BAHM;AAInBW,MAAAA,YAAY,EAAE,EAJK;AAKnBC,MAAAA,GAAG,EAAE,EALc;AAMnBC,MAAAA,GAAG,EAAE,GANc;AAOnBC,MAAAA,IAAI,EAAE,CAPa;AAQnBC,MAAAA,SAAS,EAAE;AARQ,KAAjB;AAHH;AANc,CAAlB","sourcesContent":["import { COMPONENT_TYPES, GROUPS, createNumberProp, createColorProp, createIconProp, } from \"@draftbit/types\";\nexport const SEED_DATA = {\n name: \"Icon\",\n tag: \"Icon\",\n description: \"An icon\",\n category: COMPONENT_TYPES.basic,\n layout: {},\n props: {\n name: createIconProp(),\n color: createColorProp(),\n size: createNumberProp({\n group: GROUPS.basic,\n label: \"Size\",\n description: \"Width and height of your icon\",\n defaultValue: 24,\n min: 16,\n max: 128,\n step: 1,\n precision: 0,\n }),\n },\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButtonGroup.
|
|
1
|
+
{"version":3,"sources":["RadioButtonGroup.ts"],"names":["SEED_DATA","name","tag","category","COMPONENT_TYPES","input","layout","triggers","Triggers","OnValueChange","props","direction","fieldName","handlerPropName","valuePropName","defaultValue"],"mappings":";;;;;;;AAAA;;AAOO,MAAMA,SAAS,GAAG;AACvBC,EAAAA,IAAI,EAAE,oBADiB;AAEvBC,EAAAA,GAAG,EAAE,kBAFkB;AAGvBC,EAAAA,QAAQ,EAAEC,uBAAgBC,KAHH;AAIvBC,EAAAA,MAAM,EAAE,EAJe;AAKvBC,EAAAA,QAAQ,EAAE,CAACC,gBAASC,aAAV,CALa;AAMvBC,EAAAA,KAAK,EAAE;AACLC,IAAAA,SAAS,EAAE,iCADN;AAELC,IAAAA,SAAS,EAAE,gCAAoB;AAC7BC,MAAAA,eAAe,EAAE,eADY;AAE7BC,MAAAA,aAAa,EAAE,OAFc;AAG7BC,MAAAA,YAAY,EAAE;AAHe,KAApB;AAFN;AANgB,CAAlB","sourcesContent":["import {\n COMPONENT_TYPES,\n createFieldNameProp,\n createDirectionProp,\n Triggers,\n} from \"@draftbit/types\";\n\nexport const SEED_DATA = {\n name: \"Radio Button Group\",\n tag: \"RadioButtonGroup\",\n category: COMPONENT_TYPES.input,\n layout: {},\n triggers: [Triggers.OnValueChange],\n props: {\n direction: createDirectionProp(),\n fieldName: createFieldNameProp({\n handlerPropName: \"onValueChange\",\n valuePropName: \"value\",\n defaultValue: \"radioButtonGroupValue\",\n }),\n },\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButtonRow.
|
|
1
|
+
{"version":3,"sources":["RadioButtonRow.ts"],"names":["SEED_DATA","name","tag","category","COMPONENT_TYPES","input","layout","props","label","description","required","defaultValue","direction","options","value","color","group","GROUPS","basic","unselectedColor"],"mappings":";;;;;;;AAAA;;AAQO,MAAMA,SAAS,GAAG;AACvBC,EAAAA,IAAI,EAAE,kBADiB;AAEvBC,EAAAA,GAAG,EAAE,gBAFkB;AAGvBC,EAAAA,QAAQ,EAAEC,uBAAgBC,KAHH;AAIvBC,EAAAA,MAAM,EAAE,EAJe;AAKvBC,EAAAA,KAAK,EAAE;AACLC,IAAAA,KAAK,EAAE,2BAAe;AACpBA,MAAAA,KAAK,EAAE,OADa;AAEpBC,MAAAA,WAAW,EAAE,qCAFO;AAGpBC,MAAAA,QAAQ,EAAE,IAHU;AAIpBC,MAAAA,YAAY,EAAE;AAJM,KAAf,CADF;AAOLC,IAAAA,SAAS,EAAE,+BAAmB;AAC5BJ,MAAAA,KAAK,EAAE,WADqB;AAE5BC,MAAAA,WAAW,EACT,8DAH0B;AAI5BI,MAAAA,OAAO,EAAE,CAAC,KAAD,EAAQ,aAAR;AAJmB,KAAnB,CAPN;AAaLC,IAAAA,KAAK,EAAE,2BAAe;AACpBN,MAAAA,KAAK,EAAE,OADa;AAEpBC,MAAAA,WAAW,EAAE,2BAFO;AAGpBE,MAAAA,YAAY,EAAE,IAHM;AAIpBD,MAAAA,QAAQ,EAAE;AAJU,KAAf,CAbF;AAmBLK,IAAAA,KAAK,EAAE,4BAAgB;AACrBC,MAAAA,KAAK,EAAEC,cAAOC,KADO;AAErBT,MAAAA,WAAW,EAAE,sBAFQ;AAGrBE,MAAAA,YAAY,EAAE;AAHO,KAAhB,CAnBF;AAwBLQ,IAAAA,eAAe,EAAE,4BAAgB;AAC/BH,MAAAA,KAAK,EAAEC,cAAOC,KADiB;AAE/BV,MAAAA,KAAK,EAAE,kBAFwB;AAG/BC,MAAAA,WAAW,EAAE,iCAHkB;AAI/BE,MAAAA,YAAY,EAAE;AAJiB,KAAhB;AAxBZ;AALgB,CAAlB","sourcesContent":["import {\n createTextProp,\n createTextEnumProp,\n COMPONENT_TYPES,\n createColorProp,\n GROUPS,\n} from \"@draftbit/types\";\n\nexport const SEED_DATA = {\n name: \"Radio Button Row\",\n tag: \"RadioButtonRow\",\n category: COMPONENT_TYPES.input,\n layout: {},\n props: {\n label: createTextProp({\n label: \"Label\",\n description: \"Label to show with the radio button\",\n required: true,\n defaultValue: \"First Option\",\n }),\n direction: createTextEnumProp({\n label: \"Direction\",\n description:\n \"Whether the checkbox will appear on the left or on the right\",\n options: [\"row\", \"row-reverse\"],\n }),\n value: createTextProp({\n label: \"Value\",\n description: \"Value of the radio button\",\n defaultValue: null,\n required: true,\n }),\n color: createColorProp({\n group: GROUPS.basic,\n description: \"Color for the button\",\n defaultValue: \"primary\",\n }),\n unselectedColor: createColorProp({\n group: GROUPS.basic,\n label: \"Unselected Color\",\n description: \"Unselected Color for the button\",\n defaultValue: \"primary\",\n }),\n },\n};\n"]}
|