@draftbit/core 43.4.15 → 43.4.16-cbc807.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/components/ActionSheet/ActionSheetCancel.js.map +1 -1
- package/lib/commonjs/components/CardContainerRating.js +16 -5
- package/lib/commonjs/components/CardContainerRating.js.map +1 -1
- package/lib/commonjs/components/Config.js.map +1 -1
- package/lib/commonjs/components/DatePicker/DatePickerComponent.js.map +1 -1
- package/lib/commonjs/components/Header.js.map +1 -1
- 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/Portal/PortalConsumer.js.map +1 -1
- package/lib/commonjs/components/Portal/PortalManager.js.map +1 -1
- package/lib/commonjs/components/RadioButton/RadioButton.js +15 -3
- package/lib/commonjs/components/RadioButton/RadioButton.js.map +1 -1
- package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js +11 -2
- package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js.map +1 -1
- package/lib/commonjs/components/RadioButton/RadioButtonGroup.js +17 -5
- package/lib/commonjs/components/RadioButton/RadioButtonGroup.js.map +1 -1
- package/lib/commonjs/components/ScreenContainer.js +3 -3
- package/lib/commonjs/components/ScreenContainer.js.map +1 -1
- package/lib/commonjs/components/Surface.js +14 -2
- package/lib/commonjs/components/Surface.js.map +1 -1
- package/lib/commonjs/components/Swiper/SwiperItem.js.map +1 -1
- package/lib/commonjs/mappings/Accordion.js.map +1 -1
- package/lib/commonjs/mappings/BlurView.js.map +1 -1
- package/lib/commonjs/mappings/Container.js.map +1 -1
- package/lib/commonjs/mappings/FAB.js.map +1 -1
- package/lib/commonjs/mappings/RowBodyIcon.js.map +1 -1
- package/lib/commonjs/mappings/Slider.js.map +1 -1
- package/lib/commonjs/mappings/TextArea.js.map +1 -1
- package/lib/module/components/IconButton.js +21 -5
- package/lib/module/components/IconButton.js.map +1 -1
- package/lib/module/components/RowHeadlineImageIcon.js.map +1 -1
- package/lib/module/components/ScreenContainer.js +3 -3
- package/lib/module/components/ScreenContainer.js.map +1 -1
- package/lib/module/components/Surface.js +14 -2
- package/lib/module/components/Surface.js.map +1 -1
- package/lib/typescript/src/components/ScreenContainer.d.ts +2 -2
- package/package.json +2 -2
- package/src/components/ScreenContainer.js +1 -1
- package/src/components/ScreenContainer.tsx +5 -5
- package/src/components/Surface.js +16 -5
- package/src/components/Surface.tsx +16 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["ActionSheetCancel.
|
|
1
|
+
{"version":3,"sources":["ActionSheetCancel.js"],"names":["ActionSheetCancel","label","color","style","onPress","React","createElement","ActionSheetItem"],"mappings":";;;;;;;AAAA;;AACA;;;;AACA,MAAMA,iBAAiB,GAAG,QAAkD;AAAA,MAAjD;AAAEC,IAAAA,KAAK,GAAG,QAAV;AAAoBC,IAAAA,KAApB;AAA2BC,IAAAA,KAA3B;AAAkCC,IAAAA;AAAlC,GAAiD;AACxE,sBAAQC,eAAMC,aAAN,CAAoBC,wBAApB,EAAqC;AAAEN,IAAAA,KAAK,EAAEA,KAAT;AAAgBC,IAAAA,KAAK,EAAEA,KAAK,IAAI,SAAhC;AAA2CC,IAAAA,KAAK,EAAE,CAACA,KAAD,CAAlD;AAA2DC,IAAAA,OAAO,EAAEA;AAApE,GAArC,CAAR;AACH,CAFD;;eAGeJ,iB","sourcesContent":["import React from \"react\";\nimport ActionSheetItem from \"./ActionSheetItem\";\nconst ActionSheetCancel = ({ label = \"Cancel\", color, style, onPress, }) => {\n return (React.createElement(ActionSheetItem, { label: label, color: color || \"#FF453A\", style: [style], onPress: onPress }));\n};\nexport default ActionSheetCancel;\n"]}
|
|
@@ -25,8 +25,6 @@ var _Config = _interopRequireDefault(require("./Config"));
|
|
|
25
25
|
|
|
26
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
27
27
|
|
|
28
|
-
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); }
|
|
29
|
-
|
|
30
28
|
const ICON_CONTAINER_SIZE = _Config.default.cardIconSize * 2;
|
|
31
29
|
const ICON_CONTAINER_PADDING = _Config.default.cardIconSize / 2 - 1;
|
|
32
30
|
|
|
@@ -65,11 +63,12 @@ const CardContainerRating = _ref => {
|
|
|
65
63
|
break;
|
|
66
64
|
}
|
|
67
65
|
|
|
68
|
-
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default,
|
|
66
|
+
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default, {
|
|
69
67
|
style: style,
|
|
70
68
|
onPress: onPress,
|
|
71
|
-
numColumns: numColumns
|
|
72
|
-
|
|
69
|
+
numColumns: numColumns,
|
|
70
|
+
...rest
|
|
71
|
+
}, /*#__PURE__*/_react.default.createElement(_Elevation.default, {
|
|
73
72
|
style: {
|
|
74
73
|
elevation,
|
|
75
74
|
borderRadius: roundness
|
|
@@ -148,5 +147,17 @@ const CardContainerRating = _ref => {
|
|
|
148
147
|
|
|
149
148
|
var _default = (0, _theming.withTheme)(CardContainerRating);
|
|
150
149
|
|
|
150
|
+
exports.default = _default;
|
|
151
|
+
//# sourceMappingURL=CardContainerRating.js.mapcity).rgb().string()
|
|
152
|
+
}
|
|
153
|
+
}, /*#__PURE__*/_react.default.createElement(Icon, {
|
|
154
|
+
name: icon,
|
|
155
|
+
size: _Config.default.cardIconSize,
|
|
156
|
+
color: colors.surface
|
|
157
|
+
})) : null)));
|
|
158
|
+
};
|
|
159
|
+
|
|
160
|
+
var _default = (0, _theming.withTheme)(CardContainerRating);
|
|
161
|
+
|
|
151
162
|
exports.default = _default;
|
|
152
163
|
//# sourceMappingURL=CardContainerRating.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["CardContainerRating.
|
|
1
|
+
{"version":3,"sources":["CardContainerRating.js"],"names":["ICON_CONTAINER_SIZE","Config","cardIconSize","ICON_CONTAINER_PADDING","CardContainerRating","Icon","icon","image","cardImageUrl","title","leftDescription","rightDescription","rating","aspectRatio","elevation","numColumns","theme","colors","roundness","typography","style","onPress","rest","titleStyle","rightDescriptionStyle","headline6","body2","headline5","caption","React","createElement","Card","Elevation","borderRadius","View","overflow","backgroundColor","background","Image","source","uri","resizeMode","padding","flexDirection","alignItems","justifyContent","Text","numberOfLines","color","strong","medium","marginTop","StarRating","starSize","marginLeft","cardIconElevation","position","top","right","width","height","alpha","cardIconBackgroundOpacity","rgb","string","name","size","surface"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;AACA,MAAMA,mBAAmB,GAAGC,gBAAOC,YAAP,GAAsB,CAAlD;AACA,MAAMC,sBAAsB,GAAGF,gBAAOC,YAAP,GAAsB,CAAtB,GAA0B,CAAzD;;AACA,MAAME,mBAAmB,GAAG,QAAwN;AAAA,MAAvN;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,IAAR;AAAcC,IAAAA,KAAK,GAAGN,gBAAOO,YAA7B;AAA2CC,IAAAA,KAA3C;AAAkDC,IAAAA,eAAlD;AAAmEC,IAAAA,gBAAnE;AAAqFC,IAAAA,MAArF;AAA6FC,IAAAA,WAAW,GAAG,GAA3G;AAAgHC,IAAAA,SAAS,GAAG,CAA5H;AAA+HC,IAAAA,UAAU,GAAG,CAA5I;AAA+IC,IAAAA,KAAK,EAAE;AAAEC,MAAAA,MAAF;AAAUC,MAAAA,SAAV;AAAqBC,MAAAA;AAArB,KAAtJ;AAAyLC,IAAAA,KAAzL;AAAgMC,IAAAA,OAAhM;AAAyM,OAAGC;AAA5M,GAAuN;AAChP,MAAIC,UAAJ,EAAgBC,qBAAhB;;AACA,UAAQT,UAAR;AACI,SAAK,CAAL;AACIQ,MAAAA,UAAU,GAAGJ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;AAAE1B,IAAAA,KAAK,EAAE,CAC3BI,qBAD2B,EAE3B;AACIwB,MAAAA,KAAK,EAAE/B,MAAM,CAACiC,MADlB;AAEII,MAAAA,UAAU,EAAE;AAFhB,KAF2B,CAAT;AAMnBP,IAAAA,aAAa,EAAE;AANI,GAA1B,EAM2BpC,gBAN3B,CAPJ,CAhBJ,CAPJ,EAqCIL,IAAI,gBAAIuB,eAAMC,aAAN,CAAoBE,kBAApB,EAA+B;AAAEZ,IAAAA,KAAK,EAAE;AACxCN,MAAAA,SAAS,EAAEb,gBAAOsD,iBADsB;AAExCC,MAAAA,QAAQ,EAAE,UAF8B;AAGxCC,MAAAA,GAAG,EAAE,EAHmC;AAIxCC,MAAAA,KAAK,EAAE,EAJiC;AAKxCC,MAAAA,KAAK,EAAE3D,mBALiC;AAMxC4D,MAAAA,MAAM,EAAE5D,mBANgC;AAOxC0C,MAAAA,OAAO,EAAEvC,sBAP+B;AAQxC8B,MAAAA,YAAY,EAAEjC,mBAR0B;AASxCoC,MAAAA,eAAe,EAAE,oBAAMnB,MAAM,CAACgC,MAAb,EACZY,KADY,CACN5D,gBAAO6D,yBADD,EAEZC,GAFY,GAGZC,MAHY;AATuB;AAAT,GAA/B,eAcJnC,eAAMC,aAAN,CAAoBzB,IAApB,EAA0B;AAAE4D,IAAAA,IAAI,EAAE3D,IAAR;AAAc4D,IAAAA,IAAI,EAAEjE,gBAAOC,YAA3B;AAAyC8C,IAAAA,KAAK,EAAE/B,MAAM,CAACkD;AAAvD,GAA1B,CAdI,CAAJ,GAcgG,IAnDxG,CADJ,CADI,CAAR;AAsDH,CAlED;;eAmEe,wBAAU/D,mBAAV,C","sourcesContent":["import React from \"react\";\nimport { View, Text, } from \"react-native\";\nimport color from \"color\";\nimport Image from \"./Image\";\nimport Card from \"./DeprecatedCardWrapper\";\nimport Elevation from \"./Elevation\";\nimport StarRating from \"./StarRating\";\nimport { withTheme } from \"../theming\";\nimport Config from \"./Config\";\nconst ICON_CONTAINER_SIZE = Config.cardIconSize * 2;\nconst ICON_CONTAINER_PADDING = Config.cardIconSize / 2 - 1;\nconst CardContainerRating = ({ Icon, icon, image = Config.cardImageUrl, title, leftDescription, rightDescription, rating, aspectRatio = 1.5, elevation = 2, numColumns = 3, theme: { colors, roundness, typography }, style, onPress, ...rest }) => {\n let titleStyle, rightDescriptionStyle;\n switch (numColumns) {\n case 2:\n titleStyle = typography.headline6;\n rightDescriptionStyle = typography.body2;\n break;\n case 3:\n titleStyle = typography.headline5;\n rightDescriptionStyle = typography.caption;\n break;\n }\n return (React.createElement(Card, { style: style, onPress: onPress, numColumns: numColumns, ...rest },\n React.createElement(Elevation, { style: { elevation, borderRadius: roundness } },\n React.createElement(View, { style: {\n borderRadius: roundness,\n overflow: \"hidden\",\n backgroundColor: colors.background,\n //background color is needed for bug on android 9 - https://github.com/facebook/react-native/issues/25093\n } },\n React.createElement(Image, { style: { aspectRatio }, source: typeof image === \"string\" ? { uri: image } : image, resizeMode: \"cover\" }),\n React.createElement(View, { style: {\n padding: numColumns === 1 ? 8 : 16,\n } },\n title ? (React.createElement(View, { style: {\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n } },\n React.createElement(Text, { numberOfLines: 1, style: [titleStyle, { color: colors.strong }] }, title))) : null,\n leftDescription ? (React.createElement(Text, { numberOfLines: 1, style: [\n typography.body2,\n {\n color: colors.medium,\n marginTop: numColumns === 3 ? 4 : 4 / 2,\n },\n ] }, leftDescription)) : null,\n React.createElement(View, { style: {\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n marginTop: numColumns === 3 ? 16 : 12,\n } },\n React.createElement(StarRating, { Icon: Icon, starSize: numColumns === 1 ? 10 : 16, rating: rating }),\n React.createElement(Text, { style: [\n rightDescriptionStyle,\n {\n color: colors.medium,\n marginLeft: 8,\n },\n ], numberOfLines: 1 }, rightDescription))),\n icon ? (React.createElement(Elevation, { style: {\n elevation: Config.cardIconElevation,\n position: \"absolute\",\n top: 12,\n right: 12,\n width: ICON_CONTAINER_SIZE,\n height: ICON_CONTAINER_SIZE,\n padding: ICON_CONTAINER_PADDING,\n borderRadius: ICON_CONTAINER_SIZE,\n backgroundColor: color(colors.strong)\n .alpha(Config.cardIconBackgroundOpacity)\n .rgb()\n .string(),\n } },\n React.createElement(Icon, { name: icon, size: Config.cardIconSize, color: colors.surface }))) : null))));\n};\nexport default withTheme(CardContainerRating);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Config.
|
|
1
|
+
{"version":3,"sources":["Config.js"],"names":["getWindowDimensions","width","height","Dimensions","get","windowWidth","windowHeight","getFilters","options","filters","push","join","buildImageUrl","name","getExtension","Platform","OS","avatarImageUrl","avatarImageSize","cardImageSize","cardImageUrl","cardIconSize","cardIconBackgroundOpacity","cardIconElevation","placeholderImageURL","getPlaceholderImageUrl","size","squareImageUrl","FABSize","FABBorderRadius","FABFixedHeight","cardContainerShortImageAspectRatio","rowSingleLineImageSize","rowMultiLineImageSize","rowSingleLineIconSize","rowMultiLineIconSize","headerIconSize","buttonIconSize","swiperInactiveDotSize","swiperActiveDotSize","fieldSearchBarFullIconSize","stepperButtonSize","radioButtonSize","topSafeAreaViewHeight"],"mappings":";;;;;;;AAAA;;AACA,MAAMA,mBAAmB,GAAG,MAAM;AAC9B,QAAM;AAAEC,IAAAA,KAAF;AAASC,IAAAA;AAAT,MAAoBC,wBAAWC,GAAX,CAAe,QAAf,CAA1B;;AACA,SAAO;AACHC,IAAAA,WAAW,EAAEJ,KADV;AAEHK,IAAAA,YAAY,EAAEJ;AAFX,GAAP;AAIH,CAND;;AAOA,MAAM;AAAEG,EAAAA,WAAF;AAAeC,EAAAA;AAAf,IAAgCN,mBAAmB,EAAzD;;AACA,MAAMO,UAAU,GAAIC,OAAD,IAAa;AAC5B,QAAM;AAAEP,IAAAA,KAAF;AAASC,IAAAA;AAAT,MAAoBM,OAA1B;AACA,QAAMC,OAAO,GAAG,CAAC,SAAD,EAAY,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AAEX,IAAAA,KAAK,EAAE,GAAT;AAAcC,IAAAA,MAAM,EAAE;AAAtB,GAAD,EAA8B,QAA9B,CAflB;AAgBX0B,EAAAA,OAAO,EAAE,EAhBE;AAiBXC,EAAAA,eAAe,EAAE,EAjBN;AAkBXC,EAAAA,cAAc,EAAE,EAlBL;AAmBXC,EAAAA,kCAAkC,EAAE,CAnBzB;AAoBXC,EAAAA,sBAAsB,EAAE,EApBb;AAqBXC,EAAAA,qBAAqB,EAAE,EArBZ;AAsBXC,EAAAA,qBAAqB,EAAE,EAtBZ;AAuBXC,EAAAA,oBAAoB,EAAE,EAvBX;AAwBXC,EAAAA,cAAc,EAAE,EAxBL;AAyBXC,EAAAA,cAAc,EAAE,EAzBL;AA0BXC,EAAAA,qBAAqB,EAAE,CA1BZ;AA2BXC,EAAAA,mBAAmB,EAAE,EA3BV;AA4BXC,EAAAA,0BAA0B,EAAE,EA5BjB;AA6BXC,EAAAA,iBAAiB,EAAE,EA7BR;AA8BXC,EAAAA,eAAe,EAAE,EA9BN;AA+BXC,EAAAA,qBAAqB,EAAE,CA/BZ,CAgCX;;AAhCW,C","sourcesContent":["import { Dimensions, Platform } from \"react-native\";\nconst getWindowDimensions = () => {\n const { width, height } = Dimensions.get(\"window\");\n return {\n windowWidth: width,\n windowHeight: height,\n };\n};\nconst { windowWidth, windowHeight } = getWindowDimensions();\nconst getFilters = (options) => {\n const { width, height } = options;\n const filters = [\"c_scale\", \"q_auto\", \"dpr_auto\"];\n if (width)\n filters.push(`w_${width}`);\n if (height)\n filters.push(`h_${height}`);\n return filters.join(\",\");\n};\nconst buildImageUrl = (options, name) => {\n const filters = getFilters(options);\n return [\n \"https://res.cloudinary.com/altos/image/upload\",\n filters,\n `${name}.png`,\n ].join(\"/\");\n};\nconst getExtension = () => {\n return Platform.OS === \"web\" ? \".svg\" : \".png\";\n};\nexport default {\n windowWidth,\n windowHeight,\n avatarImageUrl: buildImageUrl({\n width: 60,\n height: 60,\n }, \"Avatar\"),\n avatarImageSize: 60,\n cardImageSize: 200,\n cardImageUrl: \"https://static.draftbit.com/images/placeholder-image\" + getExtension(),\n cardIconSize: 16,\n cardIconBackgroundOpacity: 0.24,\n cardIconElevation: 1,\n placeholderImageURL: \"https://static.draftbit.com/images/placeholder-image\" + getExtension(),\n getPlaceholderImageUrl: (size) => buildImageUrl({ width: size.width, height: size.height }, \"image-placeholder_1\"),\n squareImageUrl: buildImageUrl({ width: 100, height: 100 }, \"Avatar\"),\n FABSize: 40,\n FABBorderRadius: 20,\n FABFixedHeight: 64,\n cardContainerShortImageAspectRatio: 1,\n rowSingleLineImageSize: 24,\n rowMultiLineImageSize: 48,\n rowSingleLineIconSize: 24,\n rowMultiLineIconSize: 16,\n headerIconSize: 24,\n buttonIconSize: 24,\n swiperInactiveDotSize: 6,\n swiperActiveDotSize: 10,\n fieldSearchBarFullIconSize: 24,\n stepperButtonSize: 40,\n radioButtonSize: 24,\n topSafeAreaViewHeight: 0,\n // topSafeAreaViewHeight: Platform.OS === \"android\" ? Constants.statusBarHeight : 0\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["DatePickerComponent.
|
|
1
|
+
{"version":3,"sources":["DatePickerComponent.js"],"names":["DatePickerComponent","value","onChange","mode","toggleVisibility","Platform","OS","React","createElement","DateTimePickerModal","date","isVisible","display","onCancel","console","log","onConfirm","data","DateTimePicker"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;AACA,MAAMA,mBAAmB,GAAG,QAAkD;AAAA,MAAjD;AAAEC,IAAAA,KAAF;AAASC,IAAAA,QAAT;AAAmBC,IAAAA,IAAnB;AAAyBC,IAAAA;AAAzB,GAAiD;AAC1E,SAAOC,sBAASC,EAAT,KAAgB,KAAhB,IAAyBD,sBAASC,EAAT,KAAgB,SAAzC,gBAAsDC,eAAMC,aAAN,CAAoBC,uCAApB,EAAyC;AAAEC,IAAAA,IAAI,EAAET,KAAR;AAAeE,IAAAA,IAAI,EAAEA,IAArB;AAA2BQ,IAAAA,SAAS,EAAE,IAAtC;AAA4CC,IAAAA,OAAO,EAAEP,sBAASC,EAAT,KAAgB,KAAhB,GAAwB,SAAxB,GAAoC,SAAzF;AAAoGO,IAAAA,QAAQ,EAAE,MAAM;AAClNC,MAAAA,OAAO,CAACC,GAAR,CAAY,6CAAZ;AACAX,MAAAA,gBAAgB;AACnB,KAHiG;AAG/FY,IAAAA,SAAS,EAAGC,IAAD,IAAU;AACpBf,MAAAA,QAAQ,CAAC,IAAD,EAAOe,IAAP,CAAR;AACH;AALiG,GAAzC,CAAtD,gBAKMV,eAAMC,aAAN,CAAoBU,uBAApB,EAAoC;AAAEjB,IAAAA,KAAK,EAAEA,KAAT;AAAgBE,IAAAA,IAAI,EAAEA,IAAtB;AAA4BD,IAAAA,QAAQ,EAAEA,QAAtC;AAAgDU,IAAAA,OAAO,EAAE;AAAzD,GAApC,CALb;AAMH,CAPD;;eAQeZ,mB","sourcesContent":["import React from \"react\";\nimport { Platform } from \"react-native\";\nimport DateTimePicker from \"@react-native-community/datetimepicker\";\nimport DateTimePickerModal from \"react-native-modal-datetime-picker\";\nconst DatePickerComponent = ({ value, onChange, mode, toggleVisibility, }) => {\n return Platform.OS === \"ios\" || Platform.OS === \"android\" ? (React.createElement(DateTimePickerModal, { date: value, mode: mode, isVisible: true, display: Platform.OS === \"ios\" ? \"spinner\" : \"default\", onCancel: () => {\n console.log(\"Picker cancelled before selecting anything.\");\n toggleVisibility();\n }, onConfirm: (data) => {\n onChange(null, data);\n } })) : (React.createElement(DateTimePicker, { value: value, mode: mode, onChange: onChange, display: \"default\" }));\n};\nexport default DatePickerComponent;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Header.
|
|
1
|
+
{"version":3,"sources":["Header.js"],"names":["Header","Icon","titleTypeStyle","titleColor","title","buttonText","dividerTopMargin","icon","onPress","style","theme","colors","typography","React","createElement","View","styles","container","topContainer","Text","color","flex","numberOfLines","Touchable","alignSelf","marginLeft","buttonContainer","subtitle2","light","marginRight","name","size","Config","headerIconSize","Divider","marginTop","StyleSheet","create","flexDirection","justifyContent","alignItems"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;AACA,MAAMA,MAAM,GAAG,QAAqI;AAAA,MAApI;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,cAAR;AAAwBC,IAAAA,UAAxB;AAAoCC,IAAAA,KAApC;AAA2CC,IAAAA,UAA3C;AAAuDC,IAAAA,gBAAvD;AAAyEC,IAAAA,IAAzE;AAA+EC,IAAAA,OAA/E;AAAwFC,IAAAA,KAAxF;AAA+FC,IAAAA,KAAK,EAAE;AAAEC,MAAAA,MAAF;AAAUC,MAAAA;AAAV;AAAtG,GAAoI;AAChJ,sBAAQC,KAAK,CAACC,aAAN,CAAoBC,iBAApB,EAA0B;AAAEN,IAAAA,KAAK,EAAE,CAACO,MAAM,CAACC,SAAR,EAAmBR,KAAnB;AAAT,GAA1B,eACJI,KAAK,CAACC,aAAN,CAAoBC,iBAApB,EAA0B;AAAEN,IAAAA,KAAK,EAAEO,MAAM,CAACE;AAAhB,GAA1B,eACIL,KAAK,CAACC,aAAN,CAAoBK,iBAApB,EAA0B;AAAEV,IAAAA,KAAK,EAAE,CAC3BP,cAD2B,EAE3B;AACIkB,MAAAA,KAAK,EAAEjB,UADX;AAEIkB,MAAAA,IAAI,EAAE;AAFV,KAF2B,CAAT;AAMnBC,IAAAA,aAAa,EAAE;AANI,GAA1B,EAM2BlB,KAN3B,CADJ,EAQII,OAAO,iBAAKK,KAAK,CAACC,aAAN,CAAoBS,kBAApB,EAA+B;AAAEd,IAAAA,KAAK,EAAE;AAAEe,MAAAA,SAAS,EAAE,QAAb;AAAuBC,MAAAA,UAAU,EAAE;AAAnC,KAAT;AAAkDjB,IAAAA,OAAO,EAAEA;AAA3D,GAA/B,eACRK,KAAK,CAACC,aAAN,CAAoBC,iBAApB,EAA0B;AAAEN,IAAAA,KAAK,EAAEO,MAAM,CAACU;AAAhB,GAA1B,eACIb,KAAK,CAACC,aAAN,CAAoBK,iBAApB,EAA0B;AAAEV,IAAAA,KAAK,EAAE,CAC3BG,UAAU,CAACe,SADgB,EAE3B;AACIP,MAAAA,KAAK,EAAET,MAAM,CAACiB,KADlB;AAEIC,MAAAA,WAAW,EAAE;AAFjB,KAF2B,CAAT;AAMnBP,IAAAA,aAAa,EAAE;AANI,GAA1B,EAM2BjB,UAN3B,CADJ,eAQIQ,KAAK,CAACC,aAAN,CAAoBb,IAApB,EAA0B;AAAE6B,IAAAA,IAAI,EAAEvB,IAAR;AAAcwB,IAAAA,IAAI,EAAEC,gBAAOC,cAA3B;AAA2Cb,IAAAA,KAAK,EAAET,MAAM,CAACiB;AAAzD,GAA1B,CARJ,CADQ,CARhB,CADI,eAmBJf,KAAK,CAACC,aAAN,CAAoBoB,gBAApB,EAA6B;AAAEzB,IAAAA,KAAK,EAAE;AAAE0B,MAAAA,SAAS,EAAE7B,gBAAgB,IAAI;AAAjC;AAAT,GAA7B,CAnBI,CAAR;AAoBH,CArBD;;AAsBA,MAAMU,MAAM,GAAGoB,wBAAWC,MAAX,CAAkB;AAC7BpB,EAAAA,SAAS,EAAE;AACPO,IAAAA,SAAS,EAAE;AADJ,GADkB;AAI7BN,EAAAA,YAAY,EAAE;AACVoB,IAAAA,aAAa,EAAE,KADL;AAEVC,IAAAA,cAAc,EAAE,eAFN;AAGVC,IAAAA,UAAU,EAAE;AAHF,GAJe;AAS7Bd,EAAAA,eAAe,EAAE;AACbY,IAAAA,aAAa,EAAE,KADF;AAEbC,IAAAA,cAAc,EAAE,QAFH;AAGbC,IAAAA,UAAU,EAAE;AAHC;AATY,CAAlB,CAAf;;eAee,wBAAUxC,MAAV,C","sourcesContent":["import * as React from \"react\";\nimport { View, Text, StyleSheet, } from \"react-native\";\nimport { withTheme } from \"../theming\";\nimport Divider from \"./Divider\";\nimport Touchable from \"./Touchable\";\nimport Config from \"./Config\";\nconst Header = ({ Icon, titleTypeStyle, titleColor, title, buttonText, dividerTopMargin, icon, onPress, style, theme: { colors, typography }, }) => {\n return (React.createElement(View, { style: [styles.container, style] },\n React.createElement(View, { style: styles.topContainer },\n React.createElement(Text, { style: [\n titleTypeStyle,\n {\n color: titleColor,\n flex: 1,\n },\n ], numberOfLines: 1 }, title),\n onPress && (React.createElement(Touchable, { style: { alignSelf: \"center\", marginLeft: 12 }, onPress: onPress },\n React.createElement(View, { style: styles.buttonContainer },\n React.createElement(Text, { style: [\n typography.subtitle2,\n {\n color: colors.light,\n marginRight: 8,\n },\n ], numberOfLines: 1 }, buttonText),\n React.createElement(Icon, { name: icon, size: Config.headerIconSize, color: colors.light }))))),\n React.createElement(Divider, { style: { marginTop: dividerTopMargin || 16 } })));\n};\nconst styles = StyleSheet.create({\n container: {\n alignSelf: \"stretch\",\n },\n topContainer: {\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n },\n buttonContainer: {\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n});\nexport default withTheme(Header);\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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C;AAAE3D,IAAAA,KAAK,EAAE;AAAEiB,MAAAA,eAAe,EAAE;AAAnB,KAAT;AAAuCd,IAAAA,aAAa,EAAEA,aAAtD;AAAqEE,IAAAA,aAAa,EAAEA;AAApF,GAAlC,EAAuIJ,OAAO,CAAC2D,GAAR,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":["PortalConsumer.
|
|
1
|
+
{"version":3,"sources":["PortalConsumer.js"],"names":["PortalConsumer","React","Component","componentDidMount","checkManager","Promise","resolve","key","props","manager","mount","children","componentDidUpdate","update","componentWillUnmount","unmount","Error","render"],"mappings":";;;;;;;AAAA;;;;;;;;AACe,MAAMA,cAAN,SAA6BC,KAAK,CAACC,SAAnC,CAA6C;AAAA;AAAA;;AAAA;AAAA;;AACjC,QAAjBC,iBAAiB,GAAG;AACtB,SAAKC,YAAL,GADsB,CAEtB;;AACA,UAAMC,OAAO,CAACC,OAAR,EAAN;AACA,SAAKC,GAAL,GAAW,KAAKC,KAAL,CAAWC,OAAX,CAAmBC,KAAnB,CAAyB,KAAKF,KAAL,CAAWG,QAApC,CAAX;AACH;;AACDC,EAAAA,kBAAkB,GAAG;AACjB,SAAKR,YAAL;AACA,SAAKI,KAAL,CAAWC,OAAX,CAAmBI,MAAnB,CAA0B,KAAKN,GAA/B,EAAoC,KAAKC,KAAL,CAAWG,QAA/C;AACH;;AACDG,EAAAA,oBAAoB,GAAG;AACnB,SAAKV,YAAL;AACA,SAAKI,KAAL,CAAWC,OAAX,CAAmBM,OAAnB,CAA2B,KAAKR,GAAhC;AACH;;AAEDH,EAAAA,YAAY,GAAG;AACX,QAAI,CAAC,KAAKI,KAAL,CAAWC,OAAhB,EAAyB;AACrB,YAAM,IAAIO,KAAJ,CAAU,+GACZ,iGADY,GAEZ,qEAFE,CAAN;AAGH;AACJ;;AACDC,EAAAA,MAAM,GAAG;AACL,WAAO,IAAP;AACH;;AAzBuD","sourcesContent":["import * as React from \"react\";\nexport default class PortalConsumer extends React.Component {\n async componentDidMount() {\n this.checkManager();\n // Delay updating to prevent React from going to infinite loop\n await Promise.resolve();\n this.key = this.props.manager.mount(this.props.children);\n }\n componentDidUpdate() {\n this.checkManager();\n this.props.manager.update(this.key, this.props.children);\n }\n componentWillUnmount() {\n this.checkManager();\n this.props.manager.unmount(this.key);\n }\n key;\n checkManager() {\n if (!this.props.manager) {\n throw new Error(\"Looks like you forgot to wrap your root component with `Provider` component from `react-native-paper`.\\n\\n\" +\n \"Please read our getting-started guide and make sure you've followed all the required steps.\\n\\n\" +\n \"https://callstack.github.io/react-native-paper/getting-started.html\");\n }\n }\n render() {\n return null;\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["PortalManager.
|
|
1
|
+
{"version":3,"sources":["PortalManager.js"],"names":["PortalManager","React","PureComponent","portals","key","children","setState","state","map","item","filter","render","createElement","View","collapsable","pointerEvents","style","StyleSheet","absoluteFill"],"mappings":";;;;;;;AAAA;;AACA;;;;;;;;AACA;AACA;AACA;AACe,MAAMA,aAAN,SAA4BC,KAAK,CAACC,aAAlC,CAAgD;AAAA;AAAA;;AAAA,mCACnD;AACJC,MAAAA,OAAO,EAAE;AADL,KADmD;;AAAA,mCAInD,CAACC,GAAD,EAAMC,QAAN,KAAmB;AACvB,WAAKC,QAAL,CAAeC,KAAD,KAAY;AACtBJ,QAAAA,OAAO,EAAE,CAAC,GAAGI,KAAK,CAACJ,OAAV,EAAmB;AAAEC,UAAAA,GAAF;AAAOC,UAAAA;AAAP,SAAnB;AADa,OAAZ,CAAd;AAGH,KAR0D;;AAAA,oCASlD,CAACD,GAAD,EAAMC,QAAN,KAAmB,KAAKC,QAAL,CAAeC,KAAD,KAAY;AAClDJ,MAAAA,OAAO,EAAEI,KAAK,CAACJ,OAAN,CAAcK,GAAd,CAAmBC,IAAD,IAAU;AACjC,YAAIA,IAAI,CAACL,GAAL,KAAaA,GAAjB,EAAsB;AAClB,iBAAO,EAAE,GAAGK,IAAL;AAAWJ,YAAAA;AAAX,WAAP;AACH;;AACD,eAAOI,IAAP;AACH,OALQ;AADyC,KAAZ,CAAd,CAT+B;;AAAA,qCAiBhDL,GAAD,IAAS,KAAKE,QAAL,CAAeC,KAAD,KAAY;AACzCJ,MAAAA,OAAO,EAAEI,KAAK,CAACJ,OAAN,CAAcO,MAAd,CAAsBD,IAAD,IAAUA,IAAI,CAACL,GAAL,KAAaA,GAA5C;AADgC,KAAZ,CAAd,CAjBwC;AAAA;;AAoB3DO,EAAAA,MAAM,GAAG;AACL,WAAO,KAAKJ,KAAL,CAAWJ,OAAX,CAAmBK,GAAnB,CAAuB;AAAA,UAAC;AAAEJ,QAAAA,GAAF;AAAOC,QAAAA;AAAP,OAAD;AAAA,0BAAwBJ,KAAK,CAACW,aAAN,CAAoBC,iBAApB,EAA0B;AAAET,QAAAA,GAAG,EAAEA,GAAP;AAAYU,QAAAA,WAAW,EAAE;AAAM;AAA/B;AAAyIC,QAAAA,aAAa,EAAE,UAAxJ;AAAoKC,QAAAA,KAAK,EAAEC,wBAAWC;AAAtL,OAA1B,EAAgOb,QAAhO,CAAxB;AAAA,KAAvB,CAAP;AACH;;AAtB0D","sourcesContent":["import * as React from \"react\";\nimport { View, StyleSheet } from \"react-native\";\n/**\n * Portal host is the component which actually renders all Portals.\n */\nexport default class PortalManager extends React.PureComponent {\n state = {\n portals: [],\n };\n mount = (key, children) => {\n this.setState((state) => ({\n portals: [...state.portals, { key, children }],\n }));\n };\n update = (key, children) => this.setState((state) => ({\n portals: state.portals.map((item) => {\n if (item.key === key) {\n return { ...item, children };\n }\n return item;\n }),\n }));\n unmount = (key) => this.setState((state) => ({\n portals: state.portals.filter((item) => item.key !== key),\n }));\n render() {\n return this.state.portals.map(({ key, children }) => (React.createElement(View, { key: key, collapsable: false /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */, pointerEvents: \"box-none\", style: StyleSheet.absoluteFill }, children)));\n }\n}\n"]}
|
|
@@ -21,8 +21,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
21
21
|
|
|
22
22
|
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; }
|
|
23
23
|
|
|
24
|
-
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); }
|
|
25
|
-
|
|
26
24
|
const RadioButton = _ref => {
|
|
27
25
|
let {
|
|
28
26
|
Icon,
|
|
@@ -51,7 +49,21 @@ const RadioButton = _ref => {
|
|
|
51
49
|
onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
|
|
52
50
|
};
|
|
53
51
|
|
|
54
|
-
return /*#__PURE__*/React.createElement(_IconButton.default,
|
|
52
|
+
return /*#__PURE__*/React.createElement(_IconButton.default, {
|
|
53
|
+
Icon: Icon,
|
|
54
|
+
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
55
|
+
color: isSelected ? color : unselectedColor,
|
|
56
|
+
disabled: disabled,
|
|
57
|
+
onPress: handlePress,
|
|
58
|
+
size: size,
|
|
59
|
+
style: style,
|
|
60
|
+
...rest
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
var _default = RadioButton;
|
|
65
|
+
exports.default = _default;
|
|
66
|
+
//# sourceMappingURL=RadioButton.js.maptends({
|
|
55
67
|
Icon: Icon,
|
|
56
68
|
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
57
69
|
color: isSelected ? color : unselectedColor,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButton.
|
|
1
|
+
{"version":3,"sources":["RadioButton.js"],"names":["RadioButton","Icon","disabled","color","value","selected","unselectedColor","onPress","size","Config","radioButtonSize","selectedIcon","unselectedIcon","style","rest","contextValue","onValueChange","realValue","realContextValue","isSelected","handlePress","React","createElement","IconButton","icon"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;;;;;AACA,MAAMA,WAAW,GAAG,QAAoP;AAAA,MAAnP;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,QAAQ,GAAG,KAAnB;AAA0BC,IAAAA,KAA1B;AAAiCC,IAAAA,KAAK,GAAG,EAAzC;AAA6CC,IAAAA,QAA7C;AAAuDC,IAAAA,eAAvD;AAAwEC,IAAAA,OAAxE;AAAiFC,IAAAA,IAAI,GAAGC,gBAAOC,eAA/F;AAAgHC,IAAAA,YAAY,GAAG,oCAA/H;AAAqKC,IAAAA,cAAc,GAAG,sCAAtL;AAA8NC,IAAAA,KAA9N;AAAqO,OAAGC;AAAxO,GAAmP;AACpQ,QAAM;AAAEV,IAAAA,KAAK,EAAEW,YAAT;AAAuBC,IAAAA;AAAvB,MAAyC,0CAA/C;AACA,QAAMC,SAAS,GAAG,uCAAuBb,KAAvB,CAAlB;AACA,QAAMc,gBAAgB,GAAG,uCAAuBH,YAAvB,CAAzB;AACA,QAAMI,UAAU,GAAGd,QAAH,aAAGA,QAAH,cAAGA,QAAH,GAAea,gBAAgB,KAAKD,SAApD;;AACA,QAAMG,WAAW,GAAG,MAAM;AACtBb,IAAAA,OAAO,SAAP,IAAAA,OAAO,WAAP,YAAAA,OAAO,CAAGU,SAAH,CAAP;AACAD,IAAAA,aAAa,SAAb,IAAAA,aAAa,WAAb,YAAAA,aAAa,CAAGC,SAAH,CAAb;AACH,GAHD;;AAIA,sBAAQI,KAAK,CAACC,aAAN,CAAoBC,mBAApB,EAAgC;AAAEtB,IAAAA,IAAI,EAAEA,IAAR;AAAcuB,IAAAA,IAAI,EAAEL,UAAU,GAAGR,YAAH,GAAkBC,cAAhD;AAAgET,IAAAA,KAAK,EAAEgB,UAAU,GAAGhB,KAAH,GAAWG,eAA5F;AAA6GJ,IAAAA,QAAQ,EAAEA,QAAvH;AAAiIK,IAAAA,OAAO,EAAEa,WAA1I;AAAuJZ,IAAAA,IAAI,EAAEA,IAA7J;AAAmKK,IAAAA,KAAK,EAAEA,KAA1K;AAAiL,OAAGC;AAApL,GAAhC,CAAR;AACH,CAVD;;eAWed,W","sourcesContent":["import * as React from \"react\";\nimport Config from \"../Config\";\nimport IconButton from \"../IconButton\";\nimport { getValueForRadioButton } from \"../../utilities\";\nimport { useRadioButtonGroupContext } from \"./context\";\nconst RadioButton = ({ Icon, disabled = false, color, value = \"\", selected, unselectedColor, onPress, size = Config.radioButtonSize, selectedIcon = \"MaterialIcons/radio-button-checked\", unselectedIcon = \"MaterialIcons/radio-button-unchecked\", style, ...rest }) => {\n const { value: contextValue, onValueChange } = useRadioButtonGroupContext();\n const realValue = getValueForRadioButton(value);\n const realContextValue = getValueForRadioButton(contextValue);\n const isSelected = selected ?? realContextValue === realValue;\n const handlePress = () => {\n onPress?.(realValue);\n onValueChange?.(realValue);\n };\n return (React.createElement(IconButton, { Icon: Icon, icon: isSelected ? selectedIcon : unselectedIcon, color: isSelected ? color : unselectedColor, disabled: disabled, onPress: handlePress, size: size, style: style, ...rest }));\n};\nexport default RadioButton;\n"]}
|
|
@@ -17,8 +17,6 @@ var _RadioButtonGroup = _interopRequireDefault(require("./RadioButtonGroup"));
|
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
|
|
20
|
-
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); }
|
|
21
|
-
|
|
22
20
|
const RadioButtonFieldGroup = _ref => {
|
|
23
21
|
let {
|
|
24
22
|
label,
|
|
@@ -35,6 +33,17 @@ const RadioButtonFieldGroup = _ref => {
|
|
|
35
33
|
fontSize: theme.typography.headline4.fontSize,
|
|
36
34
|
color: theme.typography.headline4.color
|
|
37
35
|
}, labelStyle]
|
|
36
|
+
}, label), /*#__PURE__*/_react.default.createElement(_RadioButtonGroup.default, {
|
|
37
|
+
theme: theme,
|
|
38
|
+
...rest
|
|
39
|
+
}, children));
|
|
40
|
+
};
|
|
41
|
+
|
|
42
|
+
var _default = (0, _theming.withTheme)(RadioButtonFieldGroup);
|
|
43
|
+
|
|
44
|
+
exports.default = _default;
|
|
45
|
+
//# sourceMappingURL=RadioButtonFieldGroup.js.mapography.headline4.color
|
|
46
|
+
}, labelStyle]
|
|
38
47
|
}, label), /*#__PURE__*/_react.default.createElement(_RadioButtonGroup.default, _extends({
|
|
39
48
|
theme: theme
|
|
40
49
|
}, rest), children));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButtonFieldGroup.
|
|
1
|
+
{"version":3,"sources":["RadioButtonFieldGroup.js"],"names":["RadioButtonFieldGroup","label","children","theme","labelStyle","style","rest","React","createElement","View","Text","fontSize","typography","headline4","color","RadioButtonGroup"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;AACA,MAAMA,qBAAqB,GAAG,QAA4D;AAAA,MAA3D;AAAEC,IAAAA,KAAF;AAASC,IAAAA,QAAT;AAAmBC,IAAAA,KAAnB;AAA0BC,IAAAA,UAA1B;AAAsCC,IAAAA,KAAtC;AAA6C,OAAGC;AAAhD,GAA2D;AACtF,sBAAQC,eAAMC,aAAN,CAAoBC,iBAApB,EAA0B;AAAEJ,IAAAA,KAAK,EAAEA;AAAT,GAA1B,eACJE,eAAMC,aAAN,CAAoBE,aAApB,EAA0B;AAAEL,IAAAA,KAAK,EAAE,CAC3B;AACIM,MAAAA,QAAQ,EAAER,KAAK,CAACS,UAAN,CAAiBC,SAAjB,CAA2BF,QADzC;AAEIG,MAAAA,KAAK,EAAEX,KAAK,CAACS,UAAN,CAAiBC,SAAjB,CAA2BC;AAFtC,KAD2B,EAK3BV,UAL2B;AAAT,GAA1B,EAMSH,KANT,CADI,eAQJM,eAAMC,aAAN,CAAoBO,yBAApB,EAAsC;AAAEZ,IAAAA,KAAK,EAAEA,KAAT;AAAgB,OAAGG;AAAnB,GAAtC,EAAiEJ,QAAjE,CARI,CAAR;AASH,CAVD;;eAWe,wBAAUF,qBAAV,C","sourcesContent":["import React from \"react\";\nimport { View } from \"react-native\";\nimport Text from \"../Text\";\nimport { withTheme } from \"../../theming\";\nimport RadioButtonGroup from \"./RadioButtonGroup\";\nconst RadioButtonFieldGroup = ({ label, children, theme, labelStyle, style, ...rest }) => {\n return (React.createElement(View, { style: style },\n React.createElement(Text, { style: [\n {\n fontSize: theme.typography.headline4.fontSize,\n color: theme.typography.headline4.color,\n },\n labelStyle,\n ] }, label),\n React.createElement(RadioButtonGroup, { theme: theme, ...rest }, children)));\n};\nexport default withTheme(RadioButtonFieldGroup);\n"]}
|
|
@@ -17,8 +17,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
17
17
|
|
|
18
18
|
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; }
|
|
19
19
|
|
|
20
|
-
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); }
|
|
21
|
-
|
|
22
20
|
const {
|
|
23
21
|
Provider
|
|
24
22
|
} = _context.radioButtonGroupContext;
|
|
@@ -63,11 +61,25 @@ const RadioButtonGroup = _ref => {
|
|
|
63
61
|
});
|
|
64
62
|
}
|
|
65
63
|
|
|
66
|
-
return /*#__PURE__*/React.createElement(_reactNative.View,
|
|
64
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
67
65
|
style: [{
|
|
68
66
|
minHeight: 40
|
|
69
|
-
}, style]
|
|
70
|
-
|
|
67
|
+
}, style],
|
|
68
|
+
...rest
|
|
69
|
+
}, /*#__PURE__*/React.createElement(Provider, {
|
|
70
|
+
value: {
|
|
71
|
+
value: internalValue,
|
|
72
|
+
onValueChange: handleValueChange,
|
|
73
|
+
direction
|
|
74
|
+
}
|
|
75
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
76
|
+
style: _containerStyle
|
|
77
|
+
}, children)));
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
var _default = RadioButtonGroup;
|
|
81
|
+
exports.default = _default;
|
|
82
|
+
//# sourceMappingURL=RadioButtonGroup.js.maper, {
|
|
71
83
|
value: {
|
|
72
84
|
value: internalValue,
|
|
73
85
|
onValueChange: handleValueChange,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButtonGroup.
|
|
1
|
+
{"version":3,"sources":["RadioButtonGroup.js"],"names":["Provider","radioButtonGroupContext","RadioButtonGroup","direction","Direction","Vertical","value","onValueChange","defaultValue","style","children","rest","internalValue","setInternalValue","React","useState","useEffect","realValue","realDefaultValue","handleValueChange","newValue","realNewValue","_containerStyle","flexDirection","Horizontal","push","alignItems","createElement","View","minHeight"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;AACA,MAAM;AAAEA,EAAAA;AAAF,IAAeC,gCAArB;;AACA,MAAMC,gBAAgB,GAAG,QAA2G;AAAA,MAA1G;AAAEC,IAAAA,SAAS,GAAGC,mBAAUC,QAAxB;AAAkCC,IAAAA,KAAK,GAAG,EAA1C;AAA8CC,IAAAA,aAA9C;AAA6DC,IAAAA,YAA7D;AAA2EC,IAAAA,KAA3E;AAAkFC,IAAAA,QAAlF;AAA4F,OAAGC;AAA/F,GAA0G;AAChI,QAAM,CAACC,aAAD,EAAgBC,gBAAhB,IAAoCC,KAAK,CAACC,QAAN,CAAe,EAAf,CAA1C;AACAD,EAAAA,KAAK,CAACE,SAAN,CAAgB,MAAM;AAClB,QAAIV,KAAK,IAAI,IAAb,EAAmB;AACf,YAAMW,SAAS,GAAG,uCAAuBX,KAAvB,CAAlB;AACAO,MAAAA,gBAAgB,CAACI,SAAD,CAAhB;AACH;AACJ,GALD,EAKG,CAACX,KAAD,CALH;AAMAQ,EAAAA,KAAK,CAACE,SAAN,CAAgB,MAAM;AAClB,QAAIR,YAAY,IAAI,IAApB,EAA0B;AACtB,YAAMU,gBAAgB,GAAG,uCAAuBV,YAAvB,CAAzB;AACAK,MAAAA,gBAAgB,CAACK,gBAAD,CAAhB;AACH;AACJ,GALD,EAKG,CAACV,YAAD,CALH;;AAMA,QAAMW,iBAAiB,GAAIC,QAAD,IAAc;AACpC,UAAMC,YAAY,GAAG,uCAAuBD,QAAvB,CAArB;AACAP,IAAAA,gBAAgB,CAACQ,YAAD,CAAhB;AACAd,IAAAA,aAAa,SAAb,IAAAA,aAAa,WAAb,YAAAA,aAAa,CAAGc,YAAH,CAAb;AACH,GAJD;;AAKA,QAAMC,eAAe,GAAG,CACpB;AACIC,IAAAA,aAAa,EAAEpB,SAAS,KAAKC,mBAAUoB,UAAxB,GAAqC,KAArC,GAA6C;AADhE,GADoB,CAAxB;;AAKA,MAAIrB,SAAS,KAAKC,mBAAUC,QAA5B,EAAsC;AAClCiB,IAAAA,eAAe,CAACG,IAAhB,CAAqB;AACjBC,MAAAA,UAAU,EAAE;AADK,KAArB;AAGH;;AACD,sBAAQZ,KAAK,CAACa,aAAN,CAAoBC,iBAApB,EAA0B;AAAEnB,IAAAA,KAAK,EAAE,CAAC;AAAEoB,MAAAA,SAAS,EAAE;AAAb,KAAD,EAAoBpB,KAApB,CAAT;AAAqC,OAAGE;AAAxC,GAA1B,eACJG,KAAK,CAACa,aAAN,CAAoB3B,QAApB,EAA8B;AAAEM,IAAAA,KAAK,EAAE;AAC/BA,MAAAA,KAAK,EAAEM,aADwB;AAE/BL,MAAAA,aAAa,EAAEY,iBAFgB;AAG/BhB,MAAAA;AAH+B;AAAT,GAA9B,eAKIW,KAAK,CAACa,aAAN,CAAoBC,iBAApB,EAA0B;AAAEnB,IAAAA,KAAK,EAAEa;AAAT,GAA1B,EAAsDZ,QAAtD,CALJ,CADI,CAAR;AAOH,CApCD;;eAqCeR,gB","sourcesContent":["import * as React from \"react\";\nimport { View } from \"react-native\";\nimport { getValueForRadioButton } from \"../../utilities\";\nimport { radioButtonGroupContext, Direction } from \"./context\";\nconst { Provider } = radioButtonGroupContext;\nconst RadioButtonGroup = ({ direction = Direction.Vertical, value = \"\", onValueChange, defaultValue, style, children, ...rest }) => {\n const [internalValue, setInternalValue] = React.useState(\"\");\n React.useEffect(() => {\n if (value != null) {\n const realValue = getValueForRadioButton(value);\n setInternalValue(realValue);\n }\n }, [value]);\n React.useEffect(() => {\n if (defaultValue != null) {\n const realDefaultValue = getValueForRadioButton(defaultValue);\n setInternalValue(realDefaultValue);\n }\n }, [defaultValue]);\n const handleValueChange = (newValue) => {\n const realNewValue = getValueForRadioButton(newValue);\n setInternalValue(realNewValue);\n onValueChange?.(realNewValue);\n };\n const _containerStyle = [\n {\n flexDirection: direction === Direction.Horizontal ? \"row\" : \"column\",\n },\n ];\n if (direction !== Direction.Vertical) {\n _containerStyle.push({\n alignItems: \"center\",\n });\n }\n return (React.createElement(View, { style: [{ minHeight: 40 }, style], ...rest },\n React.createElement(Provider, { value: {\n value: internalValue,\n onValueChange: handleValueChange,\n direction,\n } },\n React.createElement(View, { style: _containerStyle }, children))));\n};\nexport default RadioButtonGroup;\n"]}
|
|
@@ -21,10 +21,10 @@ function _extends() { _extends = Object.assign || function (target) { for (var i
|
|
|
21
21
|
|
|
22
22
|
function ScreenContainer(_ref) {
|
|
23
23
|
let {
|
|
24
|
-
hasSafeArea
|
|
24
|
+
hasSafeArea,
|
|
25
25
|
scrollable = false,
|
|
26
|
-
hasBottomSafeArea,
|
|
27
|
-
hasTopSafeArea,
|
|
26
|
+
hasBottomSafeArea = false,
|
|
27
|
+
hasTopSafeArea = false,
|
|
28
28
|
theme,
|
|
29
29
|
style,
|
|
30
30
|
children,
|