@draftbit/core 46.6.0 → 46.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/components/AvatarEdit.js +15 -4
- package/lib/commonjs/components/CardContainer.js +4 -13
- package/lib/commonjs/components/CardContainerShortImage.js +4 -15
- package/lib/commonjs/components/Carousel.js +30 -8
- package/lib/commonjs/components/Checkbox/Checkbox.js +4 -22
- package/lib/commonjs/components/Checkbox/CheckboxGroup.js +2 -17
- package/lib/commonjs/components/Checkbox/CheckboxGroupRow.js +23 -5
- package/lib/commonjs/components/DatePicker/DatePicker.js +26 -13
- package/lib/commonjs/components/Divider.js +14 -1
- package/lib/commonjs/components/Elevation.js +2 -14
- package/lib/commonjs/components/FieldSearchBarFull.js +2 -1
- package/lib/commonjs/components/IconButton.js +19 -4
- package/lib/commonjs/components/Image.js +2 -17
- package/lib/commonjs/components/Layout.js +19 -40
- package/lib/commonjs/components/Picker/Picker.js +4 -9
- package/lib/commonjs/components/Picker/PickerComponent.web.js +3 -20
- package/lib/commonjs/components/Portal/Portal.js +27 -3
- package/lib/commonjs/components/Portal/PortalConsumer.js +22 -7
- package/lib/commonjs/components/Pressable.js +2 -15
- package/lib/commonjs/components/ProgressBar.js +7 -37
- package/lib/commonjs/components/RadioButton/context.js +1 -1
- package/lib/commonjs/components/StarRating.js +23 -4
- package/lib/commonjs/components/StepIndicator.js +18 -57
- package/lib/commonjs/components/Switch.js +10 -19
- package/lib/commonjs/components/Touchable.js +2 -15
- package/lib/commonjs/constants.js +1 -1
- package/lib/commonjs/hooks.js +1 -2
- package/lib/commonjs/mappings/StarRating.js +6 -2
- package/lib/commonjs/styles/overlay.js +1 -3
- package/lib/commonjs/utilities.js +1 -2
- package/lib/module/components/AnimatedCircularProgress.js +13 -1
- package/lib/module/components/AspectRatio.js +18 -1
- package/lib/module/components/Banner.js +25 -4
- package/lib/module/components/CardBlock.js +14 -4
- package/lib/module/components/CardContainerRating.js +14 -4
- package/lib/module/components/CardContainerShortImage.js +18 -4
- package/lib/module/components/Carousel.js +8 -32
- package/lib/module/components/Checkbox/Checkbox.js +4 -25
- package/lib/module/components/Checkbox/CheckboxGroupRow.js +5 -24
- package/lib/module/components/CircularProgress.js +8 -28
- package/lib/module/components/Container.js +17 -4
- package/lib/module/components/DatePicker/DatePicker.js +13 -27
- package/lib/module/components/DeprecatedButton.js +3 -21
- package/lib/module/components/DeprecatedFAB.js +23 -3
- package/lib/module/components/FieldSearchBarFull.js +2 -1
- package/lib/module/components/FormRow.js +17 -2
- package/lib/module/components/Image.js +2 -18
- package/lib/module/components/Picker/Picker.js +4 -10
- package/lib/module/components/Picker/PickerComponent.ios.js +11 -36
- package/lib/module/components/Picker/PickerComponent.web.js +3 -21
- package/lib/module/components/Portal/Portal.js +28 -3
- package/lib/module/components/Portal/PortalHost.js +45 -15
- package/lib/module/components/Portal/PortalManager.js +33 -7
- package/lib/module/components/ProgressBar.js +39 -7
- package/lib/module/components/RadioButton/RadioButton.js +13 -1
- package/lib/module/components/RadioButton/RadioButtonGroup.js +16 -2
- package/lib/module/components/RadioButton/context.js +1 -1
- package/lib/module/components/ScreenContainer.js +4 -21
- package/lib/module/components/Slider.js +21 -4
- package/lib/module/components/StepIndicator.js +58 -18
- package/lib/module/components/Surface.js +15 -1
- package/lib/module/components/Text.js +4 -50
- package/lib/module/mappings/StarRating.js +2 -7
- package/package.json +3 -3
- package/src/Provider.js +0 -9
- package/src/components/Accordion/AccordionGroup.js +0 -44
- package/src/components/Accordion/AccordionItem.js +0 -32
- package/src/components/Accordion/index.js +0 -2
- package/src/components/ActionSheet/ActionSheet.js +0 -45
- package/src/components/ActionSheet/ActionSheetCancel.js +0 -6
- package/src/components/ActionSheet/ActionSheetItem.js +0 -30
- package/src/components/ActionSheet/index.js +0 -3
- package/src/components/AnimatedCircularProgress.js +0 -43
- package/src/components/AspectRatio.js +0 -18
- package/src/components/AvatarEdit.js +0 -30
- package/src/components/Banner.js +0 -109
- package/src/components/Button.js +0 -114
- package/src/components/Card.js +0 -57
- package/src/components/CardBlock.js +0 -54
- package/src/components/CardContainer.js +0 -69
- package/src/components/CardContainerRating.js +0 -79
- package/src/components/CardContainerShortImage.js +0 -33
- package/src/components/CardInline.js +0 -36
- package/src/components/Carousel.js +0 -68
- package/src/components/Checkbox/Checkbox.js +0 -62
- package/src/components/Checkbox/CheckboxGroup.js +0 -21
- package/src/components/Checkbox/CheckboxGroupRow.js +0 -76
- package/src/components/Checkbox/CheckboxRow.js +0 -77
- package/src/components/Checkbox/context.js +0 -14
- package/src/components/Checkbox/index.js +0 -3
- package/src/components/CircleImage.js +0 -8
- package/src/components/CircularProgress.js +0 -81
- package/src/components/Config.js +0 -64
- package/src/components/Container.js +0 -43
- package/src/components/DatePicker/DatePicker.js +0 -377
- package/src/components/DatePicker/DatePickerComponent.js +0 -13
- package/src/components/DatePicker/DatePickerComponent.web.js +0 -30
- package/src/components/DatePicker/DatePickerComponentType.js +0 -1
- package/src/components/DeprecatedButton.js +0 -83
- package/src/components/DeprecatedCardWrapper.js +0 -18
- package/src/components/DeprecatedFAB.js +0 -114
- package/src/components/Divider.js +0 -13
- package/src/components/Elevation.js +0 -20
- package/src/components/FAB.js +0 -46
- package/src/components/FieldSearchBarFull.js +0 -53
- package/src/components/FormRow.js +0 -19
- package/src/components/Header.js +0 -44
- package/src/components/HeaderLarge.js +0 -7
- package/src/components/HeaderMedium.js +0 -7
- package/src/components/HeaderOverline.js +0 -7
- package/src/components/IconButton.js +0 -35
- package/src/components/Image.js +0 -47
- package/src/components/Justification.js +0 -1
- package/src/components/Layout.js +0 -50
- package/src/components/NumberInput.js +0 -49
- package/src/components/Picker/Picker.js +0 -267
- package/src/components/Picker/PickerComponent.android.js +0 -69
- package/src/components/Picker/PickerComponent.ios.js +0 -79
- package/src/components/Picker/PickerComponent.web.js +0 -70
- package/src/components/Picker/PickerTypes.js +0 -1
- package/src/components/Portal/Portal.js +0 -35
- package/src/components/Portal/PortalConsumer.js +0 -27
- package/src/components/Portal/PortalHost.js +0 -107
- package/src/components/Portal/PortalManager.js +0 -32
- package/src/components/Pressable.js +0 -12
- package/src/components/ProgressBar.js +0 -118
- package/src/components/ProgressCircle.js +0 -13
- package/src/components/ProgressIndicator.js +0 -27
- package/src/components/RadioButton/RadioButton.js +0 -17
- package/src/components/RadioButton/RadioButtonFieldGroup.js +0 -17
- package/src/components/RadioButton/RadioButtonGroup.js +0 -43
- package/src/components/RadioButton/RadioButtonRow.js +0 -76
- package/src/components/RadioButton/context.js +0 -14
- package/src/components/RadioButton/index.js +0 -4
- package/src/components/ResizeMode.js +0 -1
- package/src/components/Row.js +0 -48
- package/src/components/RowBodyIcon.js +0 -8
- package/src/components/RowHeadlineImageCaption.js +0 -12
- package/src/components/RowHeadlineImageIcon.js +0 -14
- package/src/components/SVG.js +0 -13
- package/src/components/ScreenContainer.js +0 -34
- package/src/components/Slider.js +0 -63
- package/src/components/StarRating.js +0 -50
- package/src/components/StepIndicator.js +0 -346
- package/src/components/Stepper.js +0 -41
- package/src/components/Surface.js +0 -32
- package/src/components/Swiper/Swiper.js +0 -29
- package/src/components/Swiper/SwiperItem.js +0 -9
- package/src/components/Swiper/index.js +0 -2
- package/src/components/Switch.js +0 -56
- package/src/components/Text.js +0 -33
- package/src/components/TextField.js +0 -428
- package/src/components/ToggleButton.js +0 -39
- package/src/components/Touchable.js +0 -12
- package/src/components/Touchable.web.js +0 -2
- package/src/components/Typography.js +0 -36
- package/src/components/useAuthState.js +0 -31
- package/src/constants.js +0 -10
- package/src/hooks.js +0 -12
- package/src/index.js +0 -53
- package/src/interfaces/Icon.js +0 -8
- package/src/mappings/Accordion.js +0 -41
- package/src/mappings/AccordionItem.js +0 -16
- package/src/mappings/ActionSheet.js +0 -13
- package/src/mappings/ActionSheetCancel.js +0 -19
- package/src/mappings/ActionSheetItem.js +0 -23
- package/src/mappings/ActivityIndicator.js +0 -58
- package/src/mappings/AudioPlayer.js +0 -57
- package/src/mappings/AvatarEdit.js +0 -38
- package/src/mappings/Banner.js +0 -32
- package/src/mappings/BlurView.js +0 -42
- package/src/mappings/Button.js +0 -116
- package/src/mappings/Card.js +0 -52
- package/src/mappings/CardBlock.js +0 -123
- package/src/mappings/CardContainer.js +0 -104
- package/src/mappings/CardContainerRating.js +0 -126
- package/src/mappings/CardContainerShortImage.js +0 -120
- package/src/mappings/CardInline.js +0 -52
- package/src/mappings/Carousel.js +0 -19
- package/src/mappings/Checkbox.js +0 -46
- package/src/mappings/CheckboxGroup.js +0 -26
- package/src/mappings/CheckboxRow.js +0 -61
- package/src/mappings/CircleImage.js +0 -25
- package/src/mappings/Container.js +0 -30
- package/src/mappings/CustomCode.js +0 -8
- package/src/mappings/DatePicker.js +0 -176
- package/src/mappings/Divider.js +0 -27
- package/src/mappings/FAB.js +0 -37
- package/src/mappings/Fetch.js +0 -13
- package/src/mappings/FieldSearchBarFull.js +0 -50
- package/src/mappings/FlashList.js +0 -79
- package/src/mappings/FlatList.js +0 -36
- package/src/mappings/HeaderLarge.js +0 -29
- package/src/mappings/HeaderMedium.js +0 -55
- package/src/mappings/HeaderOverline.js +0 -55
- package/src/mappings/Icon.js +0 -32
- package/src/mappings/IconButton.js +0 -35
- package/src/mappings/Image.js +0 -35
- package/src/mappings/ImageBackground.js +0 -29
- package/src/mappings/KeyboardAvoidingView.js +0 -41
- package/src/mappings/KeyboardAwareScrollView.js +0 -50
- package/src/mappings/Layout.js +0 -200
- package/src/mappings/LinearGradient.js +0 -77
- package/src/mappings/MapCallout.js +0 -21
- package/src/mappings/MapMarker.js +0 -47
- package/src/mappings/MapView.js +0 -139
- package/src/mappings/Modal.js +0 -42
- package/src/mappings/NumberInput.js +0 -254
- package/src/mappings/Picker.js +0 -148
- package/src/mappings/ProgressBar.js +0 -101
- package/src/mappings/ProgressCircle.js +0 -109
- package/src/mappings/ProgressIndicator.js +0 -181
- package/src/mappings/RadioButton.js +0 -51
- package/src/mappings/RadioButtonGroup.js +0 -17
- package/src/mappings/RadioButtonRow.js +0 -42
- package/src/mappings/RowBodyIcon.js +0 -75
- package/src/mappings/RowHeadlineImageCaption.js +0 -167
- package/src/mappings/RowHeadlineImageIcon.js +0 -99
- package/src/mappings/SVG.js +0 -20
- package/src/mappings/SafeAreaView.js +0 -33
- package/src/mappings/ScrollView.js +0 -31
- package/src/mappings/Slider.js +0 -60
- package/src/mappings/StarRating.js +0 -43
- package/src/mappings/Stepper.js +0 -32
- package/src/mappings/Surface.js +0 -14
- package/src/mappings/Swiper.js +0 -62
- package/src/mappings/SwiperItem.js +0 -8
- package/src/mappings/Switch.js +0 -81
- package/src/mappings/Text.js +0 -251
- package/src/mappings/TextArea.js +0 -274
- package/src/mappings/TextField.js +0 -391
- package/src/mappings/TextInput.js +0 -402
- package/src/mappings/ToggleButton.js +0 -50
- package/src/mappings/Touchable.js +0 -60
- package/src/mappings/Video.js +0 -81
- package/src/mappings/View.js +0 -207
- package/src/mappings/WebView.js +0 -88
- package/src/styles/DarkTheme.js +0 -26
- package/src/styles/DefaultTheme.js +0 -111
- package/src/styles/fonts.js +0 -62
- package/src/styles/overlay.js +0 -60
- package/src/styles/shadow.js +0 -51
- package/src/theming.js +0 -3
- package/src/utilities.js +0 -102
|
@@ -12,7 +12,6 @@ var _theming = require("../theming");
|
|
|
12
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
16
15
|
const AvatarEdit = _ref => {
|
|
17
16
|
let {
|
|
18
17
|
Icon,
|
|
@@ -32,9 +31,10 @@ const AvatarEdit = _ref => {
|
|
|
32
31
|
width: size,
|
|
33
32
|
height: size
|
|
34
33
|
};
|
|
35
|
-
return /*#__PURE__*/React.createElement(_reactNative.View,
|
|
36
|
-
style: [style, dimensions]
|
|
37
|
-
|
|
34
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
35
|
+
style: [style, dimensions],
|
|
36
|
+
...rest
|
|
37
|
+
}, /*#__PURE__*/React.createElement(_Touchable.default, {
|
|
38
38
|
onPress: onPress
|
|
39
39
|
}, /*#__PURE__*/React.createElement(_CircleImage.default, {
|
|
40
40
|
source: image,
|
|
@@ -56,4 +56,15 @@ const AvatarEdit = _ref => {
|
|
|
56
56
|
}))));
|
|
57
57
|
};
|
|
58
58
|
var _default = (0, _theming.withTheme)(AvatarEdit);
|
|
59
|
+
exports.default = _default;r: colorStyles.editBackgroundColor,
|
|
60
|
+
borderRadius: size * (3 / 16),
|
|
61
|
+
padding: size * (3 / 32)
|
|
62
|
+
}
|
|
63
|
+
}, /*#__PURE__*/React.createElement(Icon, {
|
|
64
|
+
name: "MaterialIcons/edit",
|
|
65
|
+
color: colorStyles.editIconColor,
|
|
66
|
+
size: size * (3 / 16)
|
|
67
|
+
}))));
|
|
68
|
+
};
|
|
69
|
+
var _default = (0, _theming.withTheme)(AvatarEdit);
|
|
59
70
|
exports.default = _default;
|
|
@@ -13,6 +13,7 @@ var _Elevation = _interopRequireDefault(require("./Elevation"));
|
|
|
13
13
|
var _theming = require("../theming");
|
|
14
14
|
var _Config = _interopRequireDefault(require("./Config"));
|
|
15
15
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
16
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
16
17
|
const ICON_CONTAINER_SIZE = _Config.default.cardIconSize * 2;
|
|
17
18
|
const ICON_CONTAINER_PADDING = _Config.default.cardIconSize / 2 - 1;
|
|
18
19
|
const CardContainer = _ref => {
|
|
@@ -51,12 +52,11 @@ const CardContainer = _ref => {
|
|
|
51
52
|
titleStyle = typography.headline5;
|
|
52
53
|
break;
|
|
53
54
|
}
|
|
54
|
-
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default, {
|
|
55
|
+
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default, _extends({
|
|
55
56
|
style: style,
|
|
56
57
|
onPress: onPress,
|
|
57
|
-
numColumns: numColumns
|
|
58
|
-
|
|
59
|
-
}, /*#__PURE__*/_react.default.createElement(_Elevation.default, {
|
|
58
|
+
numColumns: numColumns
|
|
59
|
+
}, rest), /*#__PURE__*/_react.default.createElement(_Elevation.default, {
|
|
60
60
|
style: {
|
|
61
61
|
elevation,
|
|
62
62
|
borderRadius: roundness
|
|
@@ -126,13 +126,4 @@ const CardContainer = _ref => {
|
|
|
126
126
|
})) : null)));
|
|
127
127
|
};
|
|
128
128
|
var _default = (0, _theming.withTheme)(CardContainer);
|
|
129
|
-
exports.default = _default;0, _color.default)(colors.strong).alpha(_Config.default.cardIconBackgroundOpacity).rgb().string()
|
|
130
|
-
}
|
|
131
|
-
}, /*#__PURE__*/_react.default.createElement(Icon, {
|
|
132
|
-
name: icon,
|
|
133
|
-
size: _Config.default.cardIconSize,
|
|
134
|
-
color: colors.surface
|
|
135
|
-
})) : null)));
|
|
136
|
-
};
|
|
137
|
-
var _default = (0, _theming.withTheme)(CardContainer);
|
|
138
129
|
exports.default = _default;
|
|
@@ -12,6 +12,7 @@ var _Elevation = _interopRequireDefault(require("./Elevation"));
|
|
|
12
12
|
var _theming = require("../theming");
|
|
13
13
|
var _Config = _interopRequireDefault(require("./Config"));
|
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
15
16
|
const CardContainerShortImage = _ref => {
|
|
16
17
|
let {
|
|
17
18
|
image = _Config.default.squareImageUrl,
|
|
@@ -29,11 +30,10 @@ const CardContainerShortImage = _ref => {
|
|
|
29
30
|
onPress,
|
|
30
31
|
...rest
|
|
31
32
|
} = _ref;
|
|
32
|
-
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default, {
|
|
33
|
+
return /*#__PURE__*/_react.default.createElement(_DeprecatedCardWrapper.default, _extends({
|
|
33
34
|
style: style,
|
|
34
|
-
onPress: onPress
|
|
35
|
-
|
|
36
|
-
}, /*#__PURE__*/_react.default.createElement(_Elevation.default, {
|
|
35
|
+
onPress: onPress
|
|
36
|
+
}, rest), /*#__PURE__*/_react.default.createElement(_Elevation.default, {
|
|
37
37
|
style: {
|
|
38
38
|
elevation,
|
|
39
39
|
borderRadius: roundness
|
|
@@ -81,15 +81,4 @@ const CardContainerShortImage = _ref => {
|
|
|
81
81
|
}))));
|
|
82
82
|
};
|
|
83
83
|
var _default = (0, _theming.withTheme)(CardContainerShortImage);
|
|
84
|
-
exports.default = _default; }, subtitle) : null), mode === "right" && /*#__PURE__*/_react.default.createElement(_Image.default, {
|
|
85
|
-
style: {
|
|
86
|
-
aspectRatio
|
|
87
|
-
},
|
|
88
|
-
source: typeof image === "string" ? {
|
|
89
|
-
uri: image
|
|
90
|
-
} : image,
|
|
91
|
-
resizeMode: "cover"
|
|
92
|
-
}))));
|
|
93
|
-
};
|
|
94
|
-
var _default = (0, _theming.withTheme)(CardContainerShortImage);
|
|
95
84
|
exports.default = _default;
|
|
@@ -11,7 +11,6 @@ var _Image = _interopRequireDefault(require("./Image"));
|
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
15
14
|
const screenWidth = _reactNative.Dimensions.get("window").width;
|
|
16
15
|
function Pager(_ref) {
|
|
17
16
|
let {
|
|
@@ -39,7 +38,6 @@ function Pager(_ref) {
|
|
|
39
38
|
}));
|
|
40
39
|
}
|
|
41
40
|
function Carousel(_ref2) {
|
|
42
|
-
var _data$length;
|
|
43
41
|
let {
|
|
44
42
|
data,
|
|
45
43
|
children,
|
|
@@ -47,9 +45,10 @@ function Carousel(_ref2) {
|
|
|
47
45
|
style,
|
|
48
46
|
...rest
|
|
49
47
|
} = _ref2;
|
|
48
|
+
var _a;
|
|
50
49
|
const [index, setIndex] = React.useState(0);
|
|
51
50
|
const length = React.Children.count(children);
|
|
52
|
-
const itemsLength = ((
|
|
51
|
+
const itemsLength = ((_a = data === null || data === void 0 ? void 0 : data.length) !== null && _a !== void 0 ? _a : 0) + length;
|
|
53
52
|
const slides = Array.isArray(data) ? data : [];
|
|
54
53
|
const {
|
|
55
54
|
width,
|
|
@@ -57,9 +56,10 @@ function Carousel(_ref2) {
|
|
|
57
56
|
} = _reactNative.StyleSheet.flatten(style || {});
|
|
58
57
|
const slideWidth = width || screenWidth;
|
|
59
58
|
const slideHeight = height || 250;
|
|
60
|
-
return /*#__PURE__*/React.createElement(_reactNative.View,
|
|
61
|
-
style: [styles.container, style]
|
|
62
|
-
|
|
59
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
60
|
+
style: [styles.container, style],
|
|
61
|
+
...rest
|
|
62
|
+
}, /*#__PURE__*/React.createElement(_reactNative.ScrollView, {
|
|
63
63
|
pagingEnabled: true,
|
|
64
64
|
horizontal: true,
|
|
65
65
|
decelerationRate: "fast",
|
|
@@ -87,8 +87,8 @@ function Carousel(_ref2) {
|
|
|
87
87
|
}]
|
|
88
88
|
});
|
|
89
89
|
}) : null, React.Children.map(children, child => {
|
|
90
|
-
var
|
|
91
|
-
const s = (child === null || child === void 0 ? void 0 :
|
|
90
|
+
var _a;
|
|
91
|
+
const s = ((_a = child === null || child === void 0 ? void 0 : child.props) === null || _a === void 0 ? void 0 : _a.style) || {};
|
|
92
92
|
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
93
93
|
style: {
|
|
94
94
|
width: slideWidth
|
|
@@ -127,4 +127,26 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
127
127
|
}
|
|
128
128
|
});
|
|
129
129
|
var _default = (0, _theming.withTheme)(Carousel);
|
|
130
|
+
exports.default = _default;ate({
|
|
131
|
+
container: {
|
|
132
|
+
backgroundColor: "#eee"
|
|
133
|
+
},
|
|
134
|
+
pager: {
|
|
135
|
+
position: "absolute",
|
|
136
|
+
bottom: 12,
|
|
137
|
+
left: 0,
|
|
138
|
+
right: 0,
|
|
139
|
+
flexDirection: "row",
|
|
140
|
+
justifyContent: "center",
|
|
141
|
+
alignItems: "center"
|
|
142
|
+
},
|
|
143
|
+
bullet: {
|
|
144
|
+
marginHorizontal: 2,
|
|
145
|
+
width: 10,
|
|
146
|
+
height: 10,
|
|
147
|
+
borderRadius: 20,
|
|
148
|
+
backgroundColor: "#000"
|
|
149
|
+
}
|
|
150
|
+
});
|
|
151
|
+
var _default = (0, _theming.withTheme)(Carousel);
|
|
130
152
|
exports.default = _default;
|
|
@@ -10,6 +10,7 @@ var _theming = require("../../theming");
|
|
|
10
10
|
var _hooks = require("../../hooks");
|
|
11
11
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
12
|
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; }
|
|
13
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
14
|
const Checkbox = _ref => {
|
|
14
15
|
let {
|
|
15
16
|
Icon,
|
|
@@ -33,6 +34,7 @@ const Checkbox = _ref => {
|
|
|
33
34
|
setInternalValue(status);
|
|
34
35
|
}
|
|
35
36
|
}, [status]);
|
|
37
|
+
|
|
36
38
|
// This special logic is to handle weird APIs like Airtable that return
|
|
37
39
|
// true or undefined for a boolean
|
|
38
40
|
const previousDefaultValue = (0, _hooks.usePrevious)(defaultValue);
|
|
@@ -56,8 +58,7 @@ const Checkbox = _ref => {
|
|
|
56
58
|
onUncheck === null || onUncheck === void 0 ? void 0 : onUncheck();
|
|
57
59
|
}
|
|
58
60
|
};
|
|
59
|
-
return /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
60
|
-
...rest,
|
|
61
|
+
return /*#__PURE__*/React.createElement(_reactNative.Pressable, _extends({}, rest, {
|
|
61
62
|
onPress: handlePress,
|
|
62
63
|
disabled: disabled,
|
|
63
64
|
accessibilityState: {
|
|
@@ -69,7 +70,7 @@ const Checkbox = _ref => {
|
|
|
69
70
|
width: size,
|
|
70
71
|
height: size
|
|
71
72
|
}]
|
|
72
|
-
}, /*#__PURE__*/React.createElement(Icon, {
|
|
73
|
+
}), /*#__PURE__*/React.createElement(Icon, {
|
|
73
74
|
style: styles.icon,
|
|
74
75
|
name: internalValue ? checkedIcon : uncheckedIcon,
|
|
75
76
|
size: size,
|
|
@@ -103,23 +104,4 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
103
104
|
}
|
|
104
105
|
});
|
|
105
106
|
var _default = Checkbox;
|
|
106
|
-
exports.default = _default; styles = _reactNative.StyleSheet.create({
|
|
107
|
-
container: {
|
|
108
|
-
borderRadius: 18
|
|
109
|
-
},
|
|
110
|
-
fillContainer: {
|
|
111
|
-
alignItems: "center",
|
|
112
|
-
justifyContent: "center"
|
|
113
|
-
},
|
|
114
|
-
icon: {
|
|
115
|
-
alignSelf: "center"
|
|
116
|
-
},
|
|
117
|
-
fill: {
|
|
118
|
-
borderRadius: 5,
|
|
119
|
-
width: 30,
|
|
120
|
-
height: 30,
|
|
121
|
-
alignSelf: "center"
|
|
122
|
-
}
|
|
123
|
-
});
|
|
124
|
-
var _default = Checkbox;
|
|
125
107
|
exports.default = _default;
|
|
@@ -9,6 +9,7 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _context = require("./context");
|
|
10
10
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
12
13
|
const {
|
|
13
14
|
Provider
|
|
14
15
|
} = _context.checkboxGroupContext;
|
|
@@ -30,23 +31,7 @@ const CheckboxGroup = _ref => {
|
|
|
30
31
|
alignItems: "center"
|
|
31
32
|
});
|
|
32
33
|
}
|
|
33
|
-
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
34
|
-
style: [{
|
|
35
|
-
minHeight: 40
|
|
36
|
-
}, style],
|
|
37
|
-
...rest
|
|
38
|
-
}, /*#__PURE__*/React.createElement(Provider, {
|
|
39
|
-
value: {
|
|
40
|
-
values,
|
|
41
|
-
onValueChange,
|
|
42
|
-
direction
|
|
43
|
-
}
|
|
44
|
-
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
45
|
-
style: _containerStyle
|
|
46
|
-
}, children)));
|
|
47
|
-
};
|
|
48
|
-
var _default = CheckboxGroup;
|
|
49
|
-
exports.default = _default;s({
|
|
34
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, _extends({
|
|
50
35
|
style: [{
|
|
51
36
|
minHeight: 40
|
|
52
37
|
}, style]
|
|
@@ -13,8 +13,7 @@ var _utilities = require("../../utilities");
|
|
|
13
13
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
14
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
15
15
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
16
|
-
|
|
17
|
-
let Direction;
|
|
16
|
+
var Direction;
|
|
18
17
|
exports.Direction = Direction;
|
|
19
18
|
(function (Direction) {
|
|
20
19
|
Direction["Row"] = "row";
|
|
@@ -72,13 +71,14 @@ const CheckboxGroupRow = _ref => {
|
|
|
72
71
|
textStyles,
|
|
73
72
|
viewStyles
|
|
74
73
|
} = (0, _utilities.extractStyles)(style);
|
|
75
|
-
return /*#__PURE__*/React.createElement(_reactNative.Pressable,
|
|
74
|
+
return /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
76
75
|
onPress: handlePress,
|
|
77
76
|
style: [styles.mainParent, {
|
|
78
77
|
flexDirection: direction
|
|
79
78
|
}, viewStyles],
|
|
80
|
-
disabled: disabled
|
|
81
|
-
|
|
79
|
+
disabled: disabled,
|
|
80
|
+
...rest
|
|
81
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
82
82
|
style: [styles.label, {
|
|
83
83
|
alignItems: direction === Direction.Row ? "flex-start" : "flex-end"
|
|
84
84
|
}, labelContainerStyle]
|
|
@@ -117,4 +117,22 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
117
117
|
}
|
|
118
118
|
});
|
|
119
119
|
var _default = CheckboxGroupRow;
|
|
120
|
+
exports.default = _default;center",
|
|
121
|
+
justifyContent: "space-around",
|
|
122
|
+
paddingStart: 20,
|
|
123
|
+
minHeight: 50,
|
|
124
|
+
paddingEnd: 20,
|
|
125
|
+
display: "flex",
|
|
126
|
+
..._reactNative.Platform.select({
|
|
127
|
+
web: {
|
|
128
|
+
cursor: "pointer",
|
|
129
|
+
userSelect: "none"
|
|
130
|
+
}
|
|
131
|
+
})
|
|
132
|
+
},
|
|
133
|
+
label: {
|
|
134
|
+
flex: 3
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
var _default = CheckboxGroupRow;
|
|
120
138
|
exports.default = _default;
|
|
@@ -16,7 +16,6 @@ var _utilities = require("../../utilities");
|
|
|
16
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
17
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
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
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
20
19
|
const AnimatedText = _reactNative.Animated.createAnimatedComponent(_reactNative.Text);
|
|
21
20
|
const FOCUS_ANIMATION_DURATION = 150;
|
|
22
21
|
const BLUR_ANIMATION_DURATION = 180;
|
|
@@ -91,24 +90,20 @@ const DatePicker = _ref => {
|
|
|
91
90
|
focused ? _handleBlur() : _handleFocus();
|
|
92
91
|
};
|
|
93
92
|
const insets = (0, _reactNativeSafeAreaContext.useSafeAreaInsets)();
|
|
94
|
-
|
|
95
93
|
// const _restoreLabel = () =>
|
|
96
94
|
// Animated.timing(labeled, {
|
|
97
95
|
// toValue: 1,
|
|
98
96
|
// duration: FOCUS_ANIMATION_DURATION,
|
|
99
97
|
// useNativeDriver: true,
|
|
100
98
|
// }).start();
|
|
101
|
-
|
|
102
99
|
// const _minmizeLabel = () =>
|
|
103
100
|
// Animated.timing(labeled, {
|
|
104
101
|
// toValue: 0,
|
|
105
102
|
// duration: BLUR_ANIMATION_DURATION,
|
|
106
103
|
// useNativeDriver: true,
|
|
107
104
|
// }).start();
|
|
108
|
-
|
|
109
105
|
// const _showPlaceholder = () =>
|
|
110
106
|
// setTimeout(() => setPlaceholder1(placeholder || ""), 50);
|
|
111
|
-
|
|
112
107
|
const _hidePlaceholder = () => {
|
|
113
108
|
setPlaceholder1("");
|
|
114
109
|
};
|
|
@@ -251,9 +246,7 @@ const DatePicker = _ref => {
|
|
|
251
246
|
const inputStyles = [styles.input, inputStyle, type === "solid" ? {
|
|
252
247
|
marginHorizontal: 12
|
|
253
248
|
} : {}];
|
|
254
|
-
|
|
255
249
|
// const render = (props) => <NativeTextInput {...props} />;
|
|
256
|
-
|
|
257
250
|
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
258
251
|
style: [styles.container, style]
|
|
259
252
|
}, /*#__PURE__*/React.createElement(_Touchable.default, {
|
|
@@ -263,9 +256,10 @@ const DatePicker = _ref => {
|
|
|
263
256
|
pointerEvents: "none"
|
|
264
257
|
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
265
258
|
style: [styles.container, style]
|
|
266
|
-
}, leftIconName && leftIconMode === "outset" ? /*#__PURE__*/React.createElement(Icon,
|
|
259
|
+
}, leftIconName && leftIconMode === "outset" ? /*#__PURE__*/React.createElement(Icon, {
|
|
260
|
+
...leftIconProps,
|
|
267
261
|
style: leftIconStyle
|
|
268
|
-
})
|
|
262
|
+
}) : null, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
269
263
|
style: [containerStyle, style ? {
|
|
270
264
|
height: style.height
|
|
271
265
|
} : {}, viewStyles]
|
|
@@ -314,12 +308,13 @@ const DatePicker = _ref => {
|
|
|
314
308
|
opacity: hasActiveOutline ? labeled : 1
|
|
315
309
|
}],
|
|
316
310
|
numberOfLines: 1
|
|
317
|
-
}, label)) : null, leftIconName && leftIconMode === "inset" ? /*#__PURE__*/React.createElement(Icon,
|
|
311
|
+
}, label)) : null, leftIconName && leftIconMode === "inset" ? /*#__PURE__*/React.createElement(Icon, {
|
|
312
|
+
...leftIconProps,
|
|
318
313
|
style: {
|
|
319
314
|
...leftIconStyle,
|
|
320
315
|
marginLeft: type === "solid" ? 16 : 0
|
|
321
316
|
}
|
|
322
|
-
})
|
|
317
|
+
}) : null, /*#__PURE__*/React.createElement(_reactNative.TextInput, {
|
|
323
318
|
value: formatDate(),
|
|
324
319
|
placeholder: label ? placeholder1 : placeholder,
|
|
325
320
|
editable: !disabled,
|
|
@@ -328,8 +323,9 @@ const DatePicker = _ref => {
|
|
|
328
323
|
onFocus: _handleFocus,
|
|
329
324
|
onBlur: _handleBlur,
|
|
330
325
|
underlineColorAndroid: "transparent",
|
|
331
|
-
style: [inputStyles, textStyles]
|
|
332
|
-
|
|
326
|
+
style: [inputStyles, textStyles],
|
|
327
|
+
...props
|
|
328
|
+
})), rightIconName ? /*#__PURE__*/React.createElement(Icon, {
|
|
333
329
|
name: rightIconName,
|
|
334
330
|
size: ICON_SIZE,
|
|
335
331
|
color: colors.light,
|
|
@@ -401,4 +397,21 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
401
397
|
}
|
|
402
398
|
});
|
|
403
399
|
var _default = (0, _theming.withTheme)(DatePicker);
|
|
400
|
+
exports.default = _default; margin: 0,
|
|
401
|
+
textAlign: _reactNative.I18nManager.isRTL ? "right" : "left"
|
|
402
|
+
},
|
|
403
|
+
placeholder: {
|
|
404
|
+
position: "absolute",
|
|
405
|
+
left: 0
|
|
406
|
+
},
|
|
407
|
+
pickerContainer: {
|
|
408
|
+
flexDirection: "column",
|
|
409
|
+
width: "100%",
|
|
410
|
+
zIndex: 100
|
|
411
|
+
},
|
|
412
|
+
closeButton: {
|
|
413
|
+
alignSelf: "flex-end"
|
|
414
|
+
}
|
|
415
|
+
});
|
|
416
|
+
var _default = (0, _theming.withTheme)(DatePicker);
|
|
404
417
|
exports.default = _default;
|
|
@@ -9,7 +9,6 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _theming = require("../theming");
|
|
10
10
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
12
|
const Divider = _ref => {
|
|
14
13
|
let {
|
|
15
14
|
style,
|
|
@@ -19,6 +18,20 @@ const Divider = _ref => {
|
|
|
19
18
|
},
|
|
20
19
|
...rest
|
|
21
20
|
} = _ref;
|
|
21
|
+
return /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
22
|
+
style: [{
|
|
23
|
+
backgroundColor: color || colors.divider,
|
|
24
|
+
height: _reactNative.StyleSheet.hairlineWidth
|
|
25
|
+
}, style],
|
|
26
|
+
...rest
|
|
27
|
+
});
|
|
28
|
+
};
|
|
29
|
+
var _default = (0, _theming.withTheme)(Divider);
|
|
30
|
+
exports.default = _default;eme: {
|
|
31
|
+
colors
|
|
32
|
+
},
|
|
33
|
+
...rest
|
|
34
|
+
} = _ref;
|
|
22
35
|
return /*#__PURE__*/React.createElement(_reactNative.View, _extends({
|
|
23
36
|
style: [{
|
|
24
37
|
backgroundColor: color || colors.divider,
|
|
@@ -11,6 +11,7 @@ var _theming = require("../theming");
|
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
14
15
|
/* directly copied from https://github.com/callstack/react-native-paper/blob/main/src/components/Surface.tsx#L62 */
|
|
15
16
|
const Elevation = _ref => {
|
|
16
17
|
let {
|
|
@@ -27,24 +28,11 @@ const Elevation = _ref => {
|
|
|
27
28
|
colors
|
|
28
29
|
} = theme;
|
|
29
30
|
const borderRadius = radius;
|
|
30
|
-
return /*#__PURE__*/React.createElement(_reactNative.Animated.View, {
|
|
31
|
-
...rest,
|
|
31
|
+
return /*#__PURE__*/React.createElement(_reactNative.Animated.View, _extends({}, rest, {
|
|
32
32
|
style: [{
|
|
33
33
|
borderRadius,
|
|
34
34
|
backgroundColor: colors.surface
|
|
35
35
|
}, elevation ? (0, _shadow.default)(elevation) : null, style]
|
|
36
|
-
}, /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
37
|
-
style: {
|
|
38
|
-
overflow: "hidden",
|
|
39
|
-
borderRadius
|
|
40
|
-
}
|
|
41
|
-
}, children));
|
|
42
|
-
};
|
|
43
|
-
var _default = (0, _theming.withTheme)(Elevation);
|
|
44
|
-
exports.default = _default;
|
|
45
|
-
borderRadius,
|
|
46
|
-
backgroundColor: colors.surface
|
|
47
|
-
}, elevation ? (0, _shadow.default)(elevation) : null, style]
|
|
48
36
|
}), /*#__PURE__*/React.createElement(_reactNative.View, {
|
|
49
37
|
style: {
|
|
50
38
|
overflow: "hidden",
|
|
@@ -55,6 +55,7 @@ const FieldSearchBarFull = _ref => {
|
|
|
55
55
|
lineHeight,
|
|
56
56
|
...typeStyles
|
|
57
57
|
} = typography.body2; // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
58
|
+
|
|
58
59
|
const handleChangeText = newValue => {
|
|
59
60
|
setInternalValue(newValue);
|
|
60
61
|
if (onChange) {
|
|
@@ -93,4 +94,4 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
93
94
|
}
|
|
94
95
|
});
|
|
95
96
|
var _default = (0, _theming.withTheme)(FieldSearchBarFull);
|
|
96
|
-
exports.default = _default
|
|
97
|
+
exports.default = _default;
|
|
@@ -9,7 +9,6 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _theming = require("../theming");
|
|
10
10
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
12
|
const IconButton = _ref => {
|
|
14
13
|
let {
|
|
15
14
|
Icon,
|
|
@@ -24,7 +23,7 @@ const IconButton = _ref => {
|
|
|
24
23
|
...props
|
|
25
24
|
} = _ref;
|
|
26
25
|
const iconColor = customColor || theme.colors.primary;
|
|
27
|
-
return /*#__PURE__*/React.createElement(_reactNative.Pressable,
|
|
26
|
+
return /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
28
27
|
onPress: onPress,
|
|
29
28
|
disabled: disabled || loading,
|
|
30
29
|
style: _ref2 => {
|
|
@@ -38,8 +37,9 @@ const IconButton = _ref => {
|
|
|
38
37
|
alignItems: "center",
|
|
39
38
|
justifyContent: "center"
|
|
40
39
|
}, style];
|
|
41
|
-
}
|
|
42
|
-
|
|
40
|
+
},
|
|
41
|
+
...props
|
|
42
|
+
}, /*#__PURE__*/React.createElement(_reactNative.View, null, icon && !loading ? /*#__PURE__*/React.createElement(Icon, {
|
|
43
43
|
name: icon,
|
|
44
44
|
size: size - 2,
|
|
45
45
|
color: iconColor
|
|
@@ -61,4 +61,19 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
61
61
|
}
|
|
62
62
|
});
|
|
63
63
|
var _default = (0, _theming.withTheme)(IconButton);
|
|
64
|
+
exports.default = _default; }) : null));
|
|
65
|
+
};
|
|
66
|
+
const styles = _reactNative.StyleSheet.create({
|
|
67
|
+
container: {
|
|
68
|
+
alignItems: "center",
|
|
69
|
+
justifyContent: "center",
|
|
70
|
+
..._reactNative.Platform.select({
|
|
71
|
+
web: {
|
|
72
|
+
cursor: "pointer",
|
|
73
|
+
userSelect: "none"
|
|
74
|
+
}
|
|
75
|
+
})
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
var _default = (0, _theming.withTheme)(IconButton);
|
|
64
79
|
exports.default = _default;
|
|
@@ -9,8 +9,7 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _Config = _interopRequireDefault(require("./Config"));
|
|
10
10
|
var _AspectRatio = _interopRequireDefault(require("./AspectRatio"));
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
14
13
|
const generateDimensions = _ref => {
|
|
15
14
|
let {
|
|
16
15
|
aspectRatio,
|
|
@@ -63,27 +62,13 @@ const Image = _ref2 => {
|
|
|
63
62
|
height,
|
|
64
63
|
aspectRatio
|
|
65
64
|
}]
|
|
66
|
-
}, /*#__PURE__*/_react.default.createElement(_reactNative.Image, {
|
|
67
|
-
...props,
|
|
65
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Image, _extends({}, props, {
|
|
68
66
|
source: imageSource,
|
|
69
67
|
resizeMode: resizeMode,
|
|
70
68
|
style: [style, {
|
|
71
69
|
height: "100%",
|
|
72
70
|
width: "100%"
|
|
73
71
|
}]
|
|
74
|
-
}));
|
|
75
|
-
}
|
|
76
|
-
return /*#__PURE__*/_react.default.createElement(_reactNative.Image, {
|
|
77
|
-
...props,
|
|
78
|
-
source: source,
|
|
79
|
-
resizeMode: resizeMode,
|
|
80
|
-
style: style
|
|
81
|
-
});
|
|
82
|
-
};
|
|
83
|
-
var _default = Image;
|
|
84
|
-
exports.default = _default; "100%",
|
|
85
|
-
width: "100%"
|
|
86
|
-
}]
|
|
87
72
|
})));
|
|
88
73
|
}
|
|
89
74
|
return /*#__PURE__*/_react.default.createElement(_reactNative.Image, _extends({}, props, {
|