@draftbit/core 46.6.2 → 46.6.5-427e0d.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/Accordion/AccordionItem.js +4 -23
- package/lib/commonjs/components/AvatarEdit.js +4 -15
- package/lib/commonjs/components/Banner.js +4 -23
- package/lib/commonjs/components/Button.js +10 -33
- package/lib/commonjs/components/Carousel.js +8 -30
- package/lib/commonjs/components/Checkbox/CheckboxGroupRow.js +5 -23
- package/lib/commonjs/components/Container.js +4 -15
- package/lib/commonjs/components/DatePicker/DatePicker.js +13 -26
- package/lib/commonjs/components/DeprecatedCardWrapper.js +1 -15
- package/lib/commonjs/components/Divider.js +1 -14
- package/lib/commonjs/components/FAB.js +4 -18
- package/lib/commonjs/components/IconButton.js +4 -19
- package/lib/commonjs/components/Picker/PickerComponent.ios.js +11 -36
- package/lib/commonjs/components/Portal/Portal.js +3 -27
- package/lib/commonjs/components/Portal/PortalConsumer.js +7 -22
- package/lib/commonjs/components/Portal/PortalManager.js +8 -34
- package/lib/commonjs/components/RadioButton/RadioButtonFieldGroup.js +1 -9
- package/lib/commonjs/components/RadioButton/context.js +1 -1
- package/lib/commonjs/components/ScreenContainer.js +4 -20
- package/lib/commonjs/components/StarRating.js +4 -23
- package/lib/commonjs/components/Surface.js +2 -14
- package/lib/commonjs/components/TextField.js +28 -76
- package/lib/commonjs/components/ToggleButton.js +2 -15
- package/lib/commonjs/constants.js +1 -1
- package/lib/commonjs/hooks.js +2 -1
- package/lib/commonjs/mappings/StarRating.js +2 -6
- package/lib/commonjs/styles/overlay.js +3 -1
- package/lib/commonjs/utilities.js +2 -1
- package/lib/module/components/AnimatedCircularProgress.js +1 -13
- package/lib/module/components/AspectRatio.js +1 -18
- package/lib/module/components/AvatarEdit.js +4 -15
- package/lib/module/components/Banner.js +4 -25
- package/lib/module/components/Button.js +10 -33
- package/lib/module/components/CardBlock.js +4 -14
- package/lib/module/components/CardContainerRating.js +4 -14
- package/lib/module/components/CardContainerShortImage.js +4 -18
- package/lib/module/components/Checkbox/CheckboxGroup.js +2 -16
- package/lib/module/components/Container.js +4 -17
- package/lib/module/components/DeprecatedFAB.js +3 -23
- package/lib/module/components/Elevation.js +2 -14
- package/lib/module/components/FormRow.js +2 -17
- package/lib/module/components/Layout.js +21 -42
- package/lib/module/components/NumberInput.js +3 -12
- package/lib/module/components/Portal/Portal.js +3 -28
- package/lib/module/components/Portal/PortalConsumer.js +7 -22
- package/lib/module/components/Portal/PortalHost.js +15 -45
- package/lib/module/components/Portal/PortalManager.js +7 -33
- package/lib/module/components/ProgressBar.js +7 -39
- package/lib/module/components/RadioButton/RadioButton.js +1 -13
- package/lib/module/components/RadioButton/RadioButtonGroup.js +2 -16
- package/lib/module/components/RadioButton/RadioButtonRow.js +5 -24
- package/lib/module/components/RadioButton/context.js +1 -1
- package/lib/module/components/Slider.js +4 -21
- package/lib/module/components/StepIndicator.js +18 -58
- package/lib/module/components/Surface.js +1 -15
- package/lib/module/components/Switch.js +10 -21
- package/lib/module/components/TextField.js +28 -78
- package/lib/module/constants.js +2 -1
- package/lib/module/mappings/FieldSearchBarFull.js +1 -4
- package/package.json +4 -4
- package/src/Provider.js +9 -0
- package/src/components/Accordion/AccordionGroup.js +44 -0
- package/src/components/Accordion/AccordionItem.js +32 -0
- package/src/components/Accordion/index.js +2 -0
- package/src/components/ActionSheet/ActionSheet.js +45 -0
- package/src/components/ActionSheet/ActionSheetCancel.js +6 -0
- package/src/components/ActionSheet/ActionSheetItem.js +30 -0
- package/src/components/ActionSheet/index.js +3 -0
- package/src/components/AnimatedCircularProgress.js +43 -0
- package/src/components/AspectRatio.js +18 -0
- package/src/components/AvatarEdit.js +30 -0
- package/src/components/Banner.js +109 -0
- package/src/components/Button.js +114 -0
- package/src/components/Card.js +57 -0
- package/src/components/CardBlock.js +54 -0
- package/src/components/CardContainer.js +69 -0
- package/src/components/CardContainerRating.js +79 -0
- package/src/components/CardContainerShortImage.js +33 -0
- package/src/components/CardInline.js +36 -0
- package/src/components/Carousel.js +68 -0
- package/src/components/Checkbox/Checkbox.js +62 -0
- package/src/components/Checkbox/CheckboxGroup.js +21 -0
- package/src/components/Checkbox/CheckboxGroupRow.js +76 -0
- package/src/components/Checkbox/CheckboxRow.js +77 -0
- package/src/components/Checkbox/context.js +14 -0
- package/src/components/Checkbox/index.js +3 -0
- package/src/components/CircleImage.js +8 -0
- package/src/components/CircularProgress.js +81 -0
- package/src/components/Config.js +64 -0
- package/src/components/Container.js +43 -0
- package/src/components/DatePicker/DatePicker.js +377 -0
- package/src/components/DatePicker/DatePickerComponent.js +13 -0
- package/src/components/DatePicker/DatePickerComponent.web.js +30 -0
- package/src/components/DatePicker/DatePickerComponentType.js +1 -0
- package/src/components/DeprecatedButton.js +83 -0
- package/src/components/DeprecatedCardWrapper.js +18 -0
- package/src/components/DeprecatedFAB.js +114 -0
- package/src/components/Divider.js +13 -0
- package/src/components/Elevation.js +20 -0
- package/src/components/FAB.js +46 -0
- package/src/components/FieldSearchBarFull.js +53 -0
- package/src/components/FormRow.js +19 -0
- package/src/components/Header.js +44 -0
- package/src/components/HeaderLarge.js +7 -0
- package/src/components/HeaderMedium.js +7 -0
- package/src/components/HeaderOverline.js +7 -0
- package/src/components/IconButton.js +35 -0
- package/src/components/Image.js +47 -0
- package/src/components/Justification.js +1 -0
- package/src/components/Layout.js +50 -0
- package/src/components/NumberInput.js +49 -0
- package/src/components/Picker/Picker.js +267 -0
- package/src/components/Picker/PickerComponent.android.js +69 -0
- package/src/components/Picker/PickerComponent.ios.js +79 -0
- package/src/components/Picker/PickerComponent.web.js +70 -0
- package/src/components/Picker/PickerTypes.js +1 -0
- package/src/components/Portal/Portal.js +35 -0
- package/src/components/Portal/PortalConsumer.js +27 -0
- package/src/components/Portal/PortalHost.js +107 -0
- package/src/components/Portal/PortalManager.js +32 -0
- package/src/components/Pressable.js +12 -0
- package/src/components/ProgressBar.js +118 -0
- package/src/components/ProgressCircle.js +13 -0
- package/src/components/ProgressIndicator.js +27 -0
- package/src/components/RadioButton/RadioButton.js +17 -0
- package/src/components/RadioButton/RadioButtonFieldGroup.js +17 -0
- package/src/components/RadioButton/RadioButtonGroup.js +43 -0
- package/src/components/RadioButton/RadioButtonRow.js +76 -0
- package/src/components/RadioButton/context.js +14 -0
- package/src/components/RadioButton/index.js +4 -0
- package/src/components/ResizeMode.js +1 -0
- package/src/components/Row.js +48 -0
- package/src/components/RowBodyIcon.js +8 -0
- package/src/components/RowHeadlineImageCaption.js +12 -0
- package/src/components/RowHeadlineImageIcon.js +14 -0
- package/src/components/SVG.js +13 -0
- package/src/components/ScreenContainer.js +34 -0
- package/src/components/Slider.js +63 -0
- package/src/components/StarRating.js +50 -0
- package/src/components/StepIndicator.js +346 -0
- package/src/components/Stepper.js +41 -0
- package/src/components/Surface.js +32 -0
- package/src/components/Swiper/Swiper.js +29 -0
- package/src/components/Swiper/SwiperItem.js +9 -0
- package/src/components/Swiper/index.js +2 -0
- package/src/components/Switch.js +56 -0
- package/src/components/Text.js +33 -0
- package/src/components/TextField.js +428 -0
- package/src/components/ToggleButton.js +39 -0
- package/src/components/Touchable.js +12 -0
- package/src/components/Touchable.web.js +2 -0
- package/src/components/Typography.js +36 -0
- package/src/components/useAuthState.js +31 -0
- package/src/constants.js +10 -0
- package/src/hooks.js +12 -0
- package/src/index.js +53 -0
- package/src/interfaces/Icon.js +8 -0
- package/src/mappings/Accordion.js +41 -0
- package/src/mappings/AccordionItem.js +16 -0
- package/src/mappings/ActionSheet.js +13 -0
- package/src/mappings/ActionSheetCancel.js +19 -0
- package/src/mappings/ActionSheetItem.js +23 -0
- package/src/mappings/ActivityIndicator.js +58 -0
- package/src/mappings/AudioPlayer.js +57 -0
- package/src/mappings/AvatarEdit.js +38 -0
- package/src/mappings/Banner.js +32 -0
- package/src/mappings/BlurView.js +42 -0
- package/src/mappings/Button.js +116 -0
- package/src/mappings/Card.js +52 -0
- package/src/mappings/CardBlock.js +123 -0
- package/src/mappings/CardContainer.js +104 -0
- package/src/mappings/CardContainerRating.js +126 -0
- package/src/mappings/CardContainerShortImage.js +120 -0
- package/src/mappings/CardInline.js +52 -0
- package/src/mappings/Carousel.js +19 -0
- package/src/mappings/Checkbox.js +46 -0
- package/src/mappings/CheckboxGroup.js +26 -0
- package/src/mappings/CheckboxRow.js +61 -0
- package/src/mappings/CircleImage.js +25 -0
- package/src/mappings/Container.js +30 -0
- package/src/mappings/CustomCode.js +8 -0
- package/src/mappings/DatePicker.js +176 -0
- package/src/mappings/Divider.js +27 -0
- package/src/mappings/FAB.js +37 -0
- package/src/mappings/Fetch.js +13 -0
- package/src/mappings/FieldSearchBarFull.js +50 -0
- package/src/mappings/FlashList.js +79 -0
- package/src/mappings/FlatList.js +36 -0
- package/src/mappings/HeaderLarge.js +29 -0
- package/src/mappings/HeaderMedium.js +55 -0
- package/src/mappings/HeaderOverline.js +55 -0
- package/src/mappings/Icon.js +32 -0
- package/src/mappings/IconButton.js +35 -0
- package/src/mappings/Image.js +35 -0
- package/src/mappings/ImageBackground.js +29 -0
- package/src/mappings/KeyboardAvoidingView.js +41 -0
- package/src/mappings/KeyboardAwareScrollView.js +50 -0
- package/src/mappings/Layout.js +200 -0
- package/src/mappings/LinearGradient.js +77 -0
- package/src/mappings/MapCallout.js +21 -0
- package/src/mappings/MapMarker.js +47 -0
- package/src/mappings/MapView.js +139 -0
- package/src/mappings/Modal.js +42 -0
- package/src/mappings/NumberInput.js +254 -0
- package/src/mappings/Picker.js +148 -0
- package/src/mappings/ProgressBar.js +101 -0
- package/src/mappings/ProgressCircle.js +109 -0
- package/src/mappings/ProgressIndicator.js +181 -0
- package/src/mappings/RadioButton.js +51 -0
- package/src/mappings/RadioButtonGroup.js +17 -0
- package/src/mappings/RadioButtonRow.js +42 -0
- package/src/mappings/RowBodyIcon.js +75 -0
- package/src/mappings/RowHeadlineImageCaption.js +167 -0
- package/src/mappings/RowHeadlineImageIcon.js +99 -0
- package/src/mappings/SVG.js +20 -0
- package/src/mappings/SafeAreaView.js +33 -0
- package/src/mappings/ScrollView.js +31 -0
- package/src/mappings/Slider.js +60 -0
- package/src/mappings/StarRating.js +43 -0
- package/src/mappings/Stepper.js +32 -0
- package/src/mappings/Surface.js +14 -0
- package/src/mappings/Swiper.js +62 -0
- package/src/mappings/SwiperItem.js +8 -0
- package/src/mappings/Switch.js +81 -0
- package/src/mappings/Text.js +251 -0
- package/src/mappings/TextArea.js +274 -0
- package/src/mappings/TextField.js +391 -0
- package/src/mappings/TextInput.js +402 -0
- package/src/mappings/ToggleButton.js +50 -0
- package/src/mappings/Touchable.js +60 -0
- package/src/mappings/Video.js +81 -0
- package/src/mappings/View.js +207 -0
- package/src/mappings/WebView.js +88 -0
- package/src/styles/DarkTheme.js +26 -0
- package/src/styles/DefaultTheme.js +111 -0
- package/src/styles/fonts.js +62 -0
- package/src/styles/overlay.js +60 -0
- package/src/styles/shadow.js +51 -0
- package/src/theming.js +3 -0
- package/src/utilities.js +102 -0
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import { View } from "react-native";
|
|
4
|
+
// @ts-ignore
|
|
5
|
+
|
|
3
6
|
export function Center(_ref) {
|
|
4
7
|
let {
|
|
5
8
|
width = 240,
|
|
@@ -9,16 +12,15 @@ export function Center(_ref) {
|
|
|
9
12
|
style,
|
|
10
13
|
...rest
|
|
11
14
|
} = _ref;
|
|
12
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
15
|
+
return /*#__PURE__*/React.createElement(View, _extends({
|
|
13
16
|
style: [{
|
|
14
17
|
justifyContent: "center",
|
|
15
18
|
alignItems: "center",
|
|
16
19
|
width,
|
|
17
20
|
height,
|
|
18
21
|
backgroundColor: bgColor
|
|
19
|
-
}, style]
|
|
20
|
-
|
|
21
|
-
}, children);
|
|
22
|
+
}, style]
|
|
23
|
+
}, rest), children);
|
|
22
24
|
}
|
|
23
25
|
export function Circle(_ref2) {
|
|
24
26
|
let {
|
|
@@ -29,7 +31,7 @@ export function Circle(_ref2) {
|
|
|
29
31
|
...rest
|
|
30
32
|
} = _ref2;
|
|
31
33
|
const borderRadius = 1000;
|
|
32
|
-
return /*#__PURE__*/React.createElement(Center, {
|
|
34
|
+
return /*#__PURE__*/React.createElement(Center, _extends({
|
|
33
35
|
width: size,
|
|
34
36
|
height: size,
|
|
35
37
|
bgColor: bgColor,
|
|
@@ -37,9 +39,8 @@ export function Circle(_ref2) {
|
|
|
37
39
|
backgroundColor: bgColor,
|
|
38
40
|
borderRadius,
|
|
39
41
|
overflow: "hidden"
|
|
40
|
-
}]
|
|
41
|
-
|
|
42
|
-
}, children);
|
|
42
|
+
}]
|
|
43
|
+
}, rest), children);
|
|
43
44
|
}
|
|
44
45
|
export function Square(_ref3) {
|
|
45
46
|
let {
|
|
@@ -49,13 +50,12 @@ export function Square(_ref3) {
|
|
|
49
50
|
style,
|
|
50
51
|
...rest
|
|
51
52
|
} = _ref3;
|
|
52
|
-
return /*#__PURE__*/React.createElement(Center, {
|
|
53
|
+
return /*#__PURE__*/React.createElement(Center, _extends({
|
|
53
54
|
style: style,
|
|
54
55
|
width: size,
|
|
55
56
|
height: size,
|
|
56
|
-
bgColor: bgColor
|
|
57
|
-
|
|
58
|
-
}, children);
|
|
57
|
+
bgColor: bgColor
|
|
58
|
+
}, rest), children);
|
|
59
59
|
}
|
|
60
60
|
export function Row(_ref4) {
|
|
61
61
|
let {
|
|
@@ -65,14 +65,15 @@ export function Row(_ref4) {
|
|
|
65
65
|
style,
|
|
66
66
|
...rest
|
|
67
67
|
} = _ref4;
|
|
68
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
69
|
-
style: [style,
|
|
68
|
+
return /*#__PURE__*/React.createElement(View, _extends({
|
|
69
|
+
style: [style,
|
|
70
|
+
// style goes first b/c we can't override these
|
|
71
|
+
{
|
|
70
72
|
alignItems,
|
|
71
73
|
flexDirection: "row",
|
|
72
74
|
justifyContent: justifyContent
|
|
73
|
-
}]
|
|
74
|
-
|
|
75
|
-
}, children);
|
|
75
|
+
}]
|
|
76
|
+
}, rest), children);
|
|
76
77
|
}
|
|
77
78
|
export function Spacer(_ref5) {
|
|
78
79
|
let {
|
|
@@ -84,36 +85,14 @@ export function Spacer(_ref5) {
|
|
|
84
85
|
style,
|
|
85
86
|
...rest
|
|
86
87
|
} = _ref5;
|
|
87
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
88
|
+
return /*#__PURE__*/React.createElement(View, _extends({
|
|
88
89
|
style: [style, {
|
|
89
90
|
paddingRight: right,
|
|
90
91
|
paddingTop: top,
|
|
91
92
|
paddingLeft: left,
|
|
92
93
|
paddingBottom: bottom
|
|
93
|
-
}]
|
|
94
|
-
|
|
95
|
-
}, children);
|
|
96
|
-
}
|
|
97
|
-
export function Stack(_ref6) {
|
|
98
|
-
let {
|
|
99
|
-
children,
|
|
100
|
-
justifyContent = "flex-start",
|
|
101
|
-
alignItems = "flex-start",
|
|
102
|
-
style,
|
|
103
|
-
...rest
|
|
104
|
-
} = _ref6;
|
|
105
|
-
return (
|
|
106
|
-
/*#__PURE__*/
|
|
107
|
-
// style must go first since we don't want justifyContent, alignItems overridden
|
|
108
|
-
React.createElement(View, {
|
|
109
|
-
style: [style, {
|
|
110
|
-
justifyContent,
|
|
111
|
-
alignItems
|
|
112
|
-
}],
|
|
113
|
-
...rest
|
|
114
|
-
}, children)
|
|
115
|
-
);
|
|
116
|
-
}hildren);
|
|
94
|
+
}]
|
|
95
|
+
}, rest), children);
|
|
117
96
|
}
|
|
118
97
|
export function Stack(_ref6) {
|
|
119
98
|
let {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import React, { useEffect, useState } from "react";
|
|
2
3
|
import { TextInput } from "react-native";
|
|
3
4
|
import { isString, isNumber, isNaN } from "lodash";
|
|
@@ -25,6 +26,7 @@ const NumberInput = _ref => {
|
|
|
25
26
|
}
|
|
26
27
|
return "0";
|
|
27
28
|
};
|
|
29
|
+
|
|
28
30
|
// set currentStringNumberValue as defaultValue prop if there is a differnce on first render only
|
|
29
31
|
useEffect(() => {
|
|
30
32
|
const defaultStringNumberValue = formatValueToStringNumber(defaultValue);
|
|
@@ -39,6 +41,7 @@ const NumberInput = _ref => {
|
|
|
39
41
|
setCurrentStringNumberValue(newStringNumberValue);
|
|
40
42
|
onChangeText === null || onChangeText === void 0 ? void 0 : onChangeText(number);
|
|
41
43
|
};
|
|
44
|
+
|
|
42
45
|
// run handleChangeText with value prop only when value prop changes (and first render to reset currentStringNumberValue)
|
|
43
46
|
useEffect(() => {
|
|
44
47
|
const nextStringNumberValue = formatValueToStringNumber(value);
|
|
@@ -47,18 +50,6 @@ const NumberInput = _ref => {
|
|
|
47
50
|
}
|
|
48
51
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
49
52
|
}, [value]);
|
|
50
|
-
return /*#__PURE__*/React.createElement(TextInput, {
|
|
51
|
-
keyboardType: "numeric",
|
|
52
|
-
value: currentStringNumberValue,
|
|
53
|
-
onChangeText: handleChangeText,
|
|
54
|
-
...props
|
|
55
|
-
});
|
|
56
|
-
};
|
|
57
|
-
export default NumberInput;alue) {
|
|
58
|
-
handleChangeText(nextStringNumberValue);
|
|
59
|
-
}
|
|
60
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
61
|
-
}, [value]);
|
|
62
53
|
return /*#__PURE__*/React.createElement(TextInput, _extends({
|
|
63
54
|
keyboardType: "numeric",
|
|
64
55
|
value: currentStringNumberValue,
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
4
|
import * as React from "react";
|
|
2
5
|
import PortalConsumer from "./PortalConsumer";
|
|
3
6
|
import PortalHost, { PortalContext } from "./PortalHost";
|
|
@@ -23,34 +26,6 @@ import { ThemeProvider, withTheme } from "../../theming";
|
|
|
23
26
|
* }
|
|
24
27
|
* ```
|
|
25
28
|
*/
|
|
26
|
-
class Portal extends React.Component {
|
|
27
|
-
render() {
|
|
28
|
-
const {
|
|
29
|
-
children,
|
|
30
|
-
theme
|
|
31
|
-
} = this.props;
|
|
32
|
-
return /*#__PURE__*/React.createElement(PortalContext.Consumer, null, manager => /*#__PURE__*/React.createElement(PortalConsumer, {
|
|
33
|
-
manager: manager
|
|
34
|
-
}, /*#__PURE__*/React.createElement(ThemeProvider, {
|
|
35
|
-
theme: theme
|
|
36
|
-
}, children)));
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
// @component ./PortalHost.tsx
|
|
40
|
-
Portal.Host = PortalHost;
|
|
41
|
-
export default withTheme(Portal);rt { Portal, Text } from 'react-native-paper';
|
|
42
|
-
*
|
|
43
|
-
* export default class MyComponent extends React.Component {
|
|
44
|
-
* render() {
|
|
45
|
-
* return (
|
|
46
|
-
* <Portal>
|
|
47
|
-
* <Text>This is rendered at a different place</Text>
|
|
48
|
-
* </Portal>
|
|
49
|
-
* );
|
|
50
|
-
* }
|
|
51
|
-
* }
|
|
52
|
-
* ```
|
|
53
|
-
*/
|
|
54
29
|
class Portal extends React.Component {
|
|
55
30
|
// @component ./PortalHost.tsx
|
|
56
31
|
|
|
@@ -1,28 +1,13 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
4
|
import * as React from "react";
|
|
2
5
|
export default class PortalConsumer extends React.Component {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
await Promise.resolve();
|
|
7
|
-
this.key = this.props.manager.mount(this.props.children);
|
|
8
|
-
}
|
|
9
|
-
componentDidUpdate() {
|
|
10
|
-
this.checkManager();
|
|
11
|
-
this.props.manager.update(this.key, this.props.children);
|
|
12
|
-
}
|
|
13
|
-
componentWillUnmount() {
|
|
14
|
-
this.checkManager();
|
|
15
|
-
this.props.manager.unmount(this.key);
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
_defineProperty(this, "key", void 0);
|
|
16
9
|
}
|
|
17
|
-
|
|
18
|
-
if (!this.props.manager) {
|
|
19
|
-
throw new Error("Looks like you forgot to wrap your root component with `Provider` component from `react-native-paper`.\n\n" + "Please read our getting-started guide and make sure you've followed all the required steps.\n\n" + "https://callstack.github.io/react-native-paper/getting-started.html");
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
render() {
|
|
23
|
-
return null;
|
|
24
|
-
}
|
|
25
|
-
}sync componentDidMount() {
|
|
10
|
+
async componentDidMount() {
|
|
26
11
|
this.checkManager();
|
|
27
12
|
|
|
28
13
|
// Delay updating to prevent React from going to infinite loop
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
4
|
import * as React from "react";
|
|
2
5
|
import { View, StyleSheet } from "react-native";
|
|
3
6
|
import PortalManager from "./PortalManager";
|
|
4
7
|
export const PortalContext = /*#__PURE__*/React.createContext(null);
|
|
8
|
+
|
|
5
9
|
/**
|
|
6
10
|
* Portal host renders all of its children `Portal` elements.
|
|
7
11
|
* For example, you can wrap a screen in `Portal.Host` to render items above the screen.
|
|
@@ -29,10 +33,10 @@ export const PortalContext = /*#__PURE__*/React.createContext(null);
|
|
|
29
33
|
export default class PortalHost extends React.Component {
|
|
30
34
|
constructor() {
|
|
31
35
|
super(...arguments);
|
|
32
|
-
this
|
|
36
|
+
_defineProperty(this, "setManager", manager => {
|
|
33
37
|
this.manager = manager;
|
|
34
|
-
};
|
|
35
|
-
this
|
|
38
|
+
});
|
|
39
|
+
_defineProperty(this, "mount", children => {
|
|
36
40
|
const key = this.nextKey++;
|
|
37
41
|
if (this.manager) {
|
|
38
42
|
this.manager.mount(key, children);
|
|
@@ -44,8 +48,8 @@ export default class PortalHost extends React.Component {
|
|
|
44
48
|
});
|
|
45
49
|
}
|
|
46
50
|
return key;
|
|
47
|
-
};
|
|
48
|
-
this
|
|
51
|
+
});
|
|
52
|
+
_defineProperty(this, "update", (key, children) => {
|
|
49
53
|
if (this.manager) {
|
|
50
54
|
this.manager.update(key, children);
|
|
51
55
|
} else {
|
|
@@ -62,8 +66,8 @@ export default class PortalHost extends React.Component {
|
|
|
62
66
|
this.queue.push(op);
|
|
63
67
|
}
|
|
64
68
|
}
|
|
65
|
-
};
|
|
66
|
-
this
|
|
69
|
+
});
|
|
70
|
+
_defineProperty(this, "unmount", key => {
|
|
67
71
|
if (this.manager) {
|
|
68
72
|
this.manager.unmount(key);
|
|
69
73
|
} else {
|
|
@@ -72,9 +76,10 @@ export default class PortalHost extends React.Component {
|
|
|
72
76
|
key
|
|
73
77
|
});
|
|
74
78
|
}
|
|
75
|
-
};
|
|
76
|
-
this
|
|
77
|
-
this
|
|
79
|
+
});
|
|
80
|
+
_defineProperty(this, "nextKey", 0);
|
|
81
|
+
_defineProperty(this, "queue", []);
|
|
82
|
+
_defineProperty(this, "manager", void 0);
|
|
78
83
|
}
|
|
79
84
|
componentDidMount() {
|
|
80
85
|
const manager = this.manager;
|
|
@@ -112,41 +117,6 @@ export default class PortalHost extends React.Component {
|
|
|
112
117
|
}));
|
|
113
118
|
}
|
|
114
119
|
}
|
|
115
|
-
PortalHost.displayName = "Portal.Host";
|
|
116
|
-
const styles = StyleSheet.create({
|
|
117
|
-
container: {
|
|
118
|
-
flex: 1
|
|
119
|
-
}
|
|
120
|
-
}); switch (action.type) {
|
|
121
|
-
case "mount":
|
|
122
|
-
manager.mount(action.key, action.children);
|
|
123
|
-
break;
|
|
124
|
-
case "update":
|
|
125
|
-
manager.update(action.key, action.children);
|
|
126
|
-
break;
|
|
127
|
-
case "unmount":
|
|
128
|
-
manager.unmount(action.key);
|
|
129
|
-
break;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
render() {
|
|
135
|
-
return /*#__PURE__*/React.createElement(PortalContext.Provider, {
|
|
136
|
-
value: {
|
|
137
|
-
mount: this.mount,
|
|
138
|
-
update: this.update,
|
|
139
|
-
unmount: this.unmount
|
|
140
|
-
}
|
|
141
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
142
|
-
style: styles.container,
|
|
143
|
-
collapsable: false,
|
|
144
|
-
pointerEvents: "box-none"
|
|
145
|
-
}, this.props.children), /*#__PURE__*/React.createElement(PortalManager, {
|
|
146
|
-
ref: this.setManager
|
|
147
|
-
}));
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
120
|
_defineProperty(PortalHost, "displayName", "Portal.Host");
|
|
151
121
|
const styles = StyleSheet.create({
|
|
152
122
|
container: {
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
4
|
import * as React from "react";
|
|
2
5
|
import { View, StyleSheet } from "react-native";
|
|
3
6
|
/**
|
|
@@ -6,47 +9,18 @@ import { View, StyleSheet } from "react-native";
|
|
|
6
9
|
export default class PortalManager extends React.PureComponent {
|
|
7
10
|
constructor() {
|
|
8
11
|
super(...arguments);
|
|
9
|
-
this
|
|
12
|
+
_defineProperty(this, "state", {
|
|
10
13
|
portals: []
|
|
11
|
-
};
|
|
12
|
-
this
|
|
14
|
+
});
|
|
15
|
+
_defineProperty(this, "mount", (key, children) => {
|
|
13
16
|
this.setState(state => ({
|
|
14
17
|
portals: [...state.portals, {
|
|
15
18
|
key,
|
|
16
19
|
children
|
|
17
20
|
}]
|
|
18
21
|
}));
|
|
19
|
-
};
|
|
20
|
-
this.update = (key, children) => this.setState(state => ({
|
|
21
|
-
portals: state.portals.map(item => {
|
|
22
|
-
if (item.key === key) {
|
|
23
|
-
return {
|
|
24
|
-
...item,
|
|
25
|
-
children
|
|
26
|
-
};
|
|
27
|
-
}
|
|
28
|
-
return item;
|
|
29
|
-
})
|
|
30
|
-
}));
|
|
31
|
-
this.unmount = key => this.setState(state => ({
|
|
32
|
-
portals: state.portals.filter(item => item.key !== key)
|
|
33
|
-
}));
|
|
34
|
-
}
|
|
35
|
-
render() {
|
|
36
|
-
return this.state.portals.map(_ref => {
|
|
37
|
-
let {
|
|
38
|
-
key,
|
|
39
|
-
children
|
|
40
|
-
} = _ref;
|
|
41
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
42
|
-
key: key,
|
|
43
|
-
collapsable: false /* Need collapsable=false here to clip the elevations, otherwise they appear above sibling components */,
|
|
44
|
-
pointerEvents: "box-none",
|
|
45
|
-
style: StyleSheet.absoluteFill
|
|
46
|
-
}, children);
|
|
47
22
|
});
|
|
48
|
-
|
|
49
|
-
}ey, children) => this.setState(state => ({
|
|
23
|
+
_defineProperty(this, "update", (key, children) => this.setState(state => ({
|
|
50
24
|
portals: state.portals.map(item => {
|
|
51
25
|
if (item.key === key) {
|
|
52
26
|
return {
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
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); }
|
|
2
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
3
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
4
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
5
|
import React, { Component } from "react";
|
|
2
6
|
import { Animated, Easing, View, I18nManager } from "react-native";
|
|
3
7
|
const INDETERMINATE_WIDTH_FACTOR = 0.3;
|
|
@@ -5,7 +9,7 @@ const BAR_WIDTH_ZERO_POSITION = INDETERMINATE_WIDTH_FACTOR / (1 + INDETERMINATE_
|
|
|
5
9
|
export default class ProgressBar extends Component {
|
|
6
10
|
constructor(props) {
|
|
7
11
|
super(props);
|
|
8
|
-
this
|
|
12
|
+
_defineProperty(this, "handleLayout", event => {
|
|
9
13
|
const {
|
|
10
14
|
width = 150,
|
|
11
15
|
onLayout
|
|
@@ -18,7 +22,7 @@ export default class ProgressBar extends Component {
|
|
|
18
22
|
if (onLayout) {
|
|
19
23
|
onLayout(event);
|
|
20
24
|
}
|
|
21
|
-
};
|
|
25
|
+
});
|
|
22
26
|
const {
|
|
23
27
|
progress: progressP = 0,
|
|
24
28
|
indeterminate = false
|
|
@@ -66,6 +70,7 @@ export default class ProgressBar extends Component {
|
|
|
66
70
|
...animationConfig,
|
|
67
71
|
toValue: progress,
|
|
68
72
|
velocity: 0,
|
|
73
|
+
//adjust this value if animation fails - velocity is required
|
|
69
74
|
useNativeDriver
|
|
70
75
|
}).start();
|
|
71
76
|
} else {
|
|
@@ -134,43 +139,6 @@ export default class ProgressBar extends Component {
|
|
|
134
139
|
})
|
|
135
140
|
}]
|
|
136
141
|
};
|
|
137
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
138
|
-
style: [containerStyle, style],
|
|
139
|
-
onLayout: this.handleLayout,
|
|
140
|
-
...restProps
|
|
141
|
-
}, /*#__PURE__*/React.createElement(Animated.View, {
|
|
142
|
-
style: progressStyle
|
|
143
|
-
}), children);
|
|
144
|
-
}
|
|
145
|
-
} width,
|
|
146
|
-
borderWidth,
|
|
147
|
-
borderColor: borderColor || color,
|
|
148
|
-
borderRadius,
|
|
149
|
-
overflow: "hidden",
|
|
150
|
-
backgroundColor: unfilledColor
|
|
151
|
-
};
|
|
152
|
-
const progressStyle = {
|
|
153
|
-
backgroundColor: color,
|
|
154
|
-
// Always take up full height of container.
|
|
155
|
-
height: "100%",
|
|
156
|
-
transform: [{
|
|
157
|
-
translateX: this.state.animationValue.interpolate({
|
|
158
|
-
inputRange: [0, 1],
|
|
159
|
-
outputRange: [innerWidth * -INDETERMINATE_WIDTH_FACTOR, innerWidth]
|
|
160
|
-
})
|
|
161
|
-
}, {
|
|
162
|
-
translateX: this.state.progress.interpolate({
|
|
163
|
-
inputRange: [0, 1],
|
|
164
|
-
outputRange: [innerWidth / (I18nManager.isRTL ? 2 : -2), 0]
|
|
165
|
-
})
|
|
166
|
-
}, {
|
|
167
|
-
// Interpolation a temp workaround for https://github.com/facebook/react-native/issues/6278
|
|
168
|
-
scaleX: this.state.progress.interpolate({
|
|
169
|
-
inputRange: [0, 1],
|
|
170
|
-
outputRange: [0.0001, 1]
|
|
171
|
-
})
|
|
172
|
-
}]
|
|
173
|
-
};
|
|
174
142
|
return /*#__PURE__*/React.createElement(View, _extends({
|
|
175
143
|
style: [containerStyle, style],
|
|
176
144
|
onLayout: this.handleLayout
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import Config from "../Config";
|
|
3
4
|
import IconButton from "../IconButton";
|
|
@@ -29,19 +30,6 @@ const RadioButton = _ref => {
|
|
|
29
30
|
onPress === null || onPress === void 0 ? void 0 : onPress(realValue);
|
|
30
31
|
onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
|
|
31
32
|
};
|
|
32
|
-
return /*#__PURE__*/React.createElement(IconButton, {
|
|
33
|
-
Icon: Icon,
|
|
34
|
-
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
35
|
-
color: isSelected ? color : unselectedColor,
|
|
36
|
-
disabled: disabled,
|
|
37
|
-
onPress: handlePress,
|
|
38
|
-
size: size,
|
|
39
|
-
style: style,
|
|
40
|
-
...rest
|
|
41
|
-
});
|
|
42
|
-
};
|
|
43
|
-
export default RadioButton;: onValueChange(realValue);
|
|
44
|
-
};
|
|
45
33
|
return /*#__PURE__*/React.createElement(IconButton, _extends({
|
|
46
34
|
Icon: Icon,
|
|
47
35
|
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import { View } from "react-native";
|
|
3
4
|
import { getValueForRadioButton } from "../../utilities";
|
|
@@ -41,22 +42,7 @@ const RadioButtonGroup = _ref => {
|
|
|
41
42
|
alignItems: "center"
|
|
42
43
|
});
|
|
43
44
|
}
|
|
44
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
45
|
-
style: [{
|
|
46
|
-
minHeight: 40
|
|
47
|
-
}, style],
|
|
48
|
-
...rest
|
|
49
|
-
}, /*#__PURE__*/React.createElement(Provider, {
|
|
50
|
-
value: {
|
|
51
|
-
value: internalValue,
|
|
52
|
-
onValueChange: handleValueChange,
|
|
53
|
-
direction
|
|
54
|
-
}
|
|
55
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
56
|
-
style: _containerStyle
|
|
57
|
-
}, children)));
|
|
58
|
-
};
|
|
59
|
-
export default RadioButtonGroup;xtends({
|
|
45
|
+
return /*#__PURE__*/React.createElement(View, _extends({
|
|
60
46
|
style: [{
|
|
61
47
|
minHeight: 40
|
|
62
48
|
}, style]
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import { StyleSheet, View, Platform } from "react-native";
|
|
3
4
|
import RadioButton from "./RadioButton";
|
|
@@ -6,7 +7,7 @@ import { useRadioButtonGroupContext } from "./context";
|
|
|
6
7
|
import { Direction as GroupDirection } from "./context";
|
|
7
8
|
import Touchable from "../Touchable";
|
|
8
9
|
import { extractStyles, getValueForRadioButton } from "../../utilities";
|
|
9
|
-
export
|
|
10
|
+
export let Direction;
|
|
10
11
|
(function (Direction) {
|
|
11
12
|
Direction["Row"] = "row";
|
|
12
13
|
Direction["RowReverse"] = "row-reverse";
|
|
@@ -62,14 +63,13 @@ const RadioButtonRow = _ref => {
|
|
|
62
63
|
textStyles,
|
|
63
64
|
viewStyles
|
|
64
65
|
} = extractStyles(style);
|
|
65
|
-
return /*#__PURE__*/React.createElement(Touchable, {
|
|
66
|
+
return /*#__PURE__*/React.createElement(Touchable, _extends({
|
|
66
67
|
onPress: handlePress,
|
|
67
68
|
style: [styles.mainParent, {
|
|
68
69
|
flexDirection: direction
|
|
69
70
|
}, viewStyles],
|
|
70
|
-
disabled: disabled
|
|
71
|
-
|
|
72
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
71
|
+
disabled: disabled
|
|
72
|
+
}, rest), /*#__PURE__*/React.createElement(View, {
|
|
73
73
|
style: [styles.label, {
|
|
74
74
|
alignItems: direction === Direction.Row ? "flex-start" : "flex-end"
|
|
75
75
|
}, labelContainerStyle]
|
|
@@ -106,23 +106,4 @@ const styles = StyleSheet.create({
|
|
|
106
106
|
flex: 3
|
|
107
107
|
}
|
|
108
108
|
});
|
|
109
|
-
export default RadioButtonRow;.create({
|
|
110
|
-
mainParent: {
|
|
111
|
-
alignItems: "center",
|
|
112
|
-
justifyContent: "space-around",
|
|
113
|
-
paddingStart: 20,
|
|
114
|
-
minHeight: 50,
|
|
115
|
-
paddingEnd: 20,
|
|
116
|
-
display: "flex",
|
|
117
|
-
...Platform.select({
|
|
118
|
-
web: {
|
|
119
|
-
cursor: "pointer",
|
|
120
|
-
userSelect: "none"
|
|
121
|
-
}
|
|
122
|
-
})
|
|
123
|
-
},
|
|
124
|
-
label: {
|
|
125
|
-
flex: 3
|
|
126
|
-
}
|
|
127
|
-
});
|
|
128
109
|
export default RadioButtonRow;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
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); }
|
|
1
2
|
import * as React from "react";
|
|
2
3
|
import { View, StyleSheet } from "react-native";
|
|
3
4
|
import NativeSlider from "@react-native-community/slider";
|
|
@@ -63,10 +64,9 @@ function Slider(_ref) {
|
|
|
63
64
|
setInternalValue(newValue);
|
|
64
65
|
onValueChange(newValue);
|
|
65
66
|
};
|
|
66
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
67
|
-
style: [styles.container, style]
|
|
68
|
-
|
|
69
|
-
}, leftIcon ? /*#__PURE__*/React.createElement(Icon, {
|
|
67
|
+
return /*#__PURE__*/React.createElement(View, _extends({
|
|
68
|
+
style: [styles.container, style]
|
|
69
|
+
}, rest), leftIcon ? /*#__PURE__*/React.createElement(Icon, {
|
|
70
70
|
color: leftIconThemeColor,
|
|
71
71
|
name: leftIcon,
|
|
72
72
|
size: 24
|
|
@@ -98,21 +98,4 @@ const styles = StyleSheet.create({
|
|
|
98
98
|
marginHorizontal: 12
|
|
99
99
|
}
|
|
100
100
|
});
|
|
101
|
-
export default withTheme(Slider);Icon ? /*#__PURE__*/React.createElement(Icon, {
|
|
102
|
-
color: rightIconThemeColor,
|
|
103
|
-
name: rightIcon,
|
|
104
|
-
size: 24
|
|
105
|
-
}) : null);
|
|
106
|
-
}
|
|
107
|
-
const styles = StyleSheet.create({
|
|
108
|
-
container: {
|
|
109
|
-
height: 40,
|
|
110
|
-
flexDirection: "row",
|
|
111
|
-
alignItems: "center"
|
|
112
|
-
},
|
|
113
|
-
slider: {
|
|
114
|
-
flex: 1,
|
|
115
|
-
marginHorizontal: 12
|
|
116
|
-
}
|
|
117
|
-
});
|
|
118
101
|
export default withTheme(Slider);
|