@codeleap/mobile 4.2.9 → 4.2.10
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/dist/Registry.js +28 -53
- package/dist/Registry.js.map +1 -1
- package/dist/components/ActionIcon/index.js +27 -67
- package/dist/components/ActionIcon/index.js.map +1 -1
- package/dist/components/ActionIcon/styles.js +1 -2
- package/dist/components/ActionIcon/types.js +1 -2
- package/dist/components/ActivityIndicator/index.js +22 -62
- package/dist/components/ActivityIndicator/index.js.map +1 -1
- package/dist/components/ActivityIndicator/styles.js +1 -2
- package/dist/components/ActivityIndicator/types.js +1 -2
- package/dist/components/Autocomplete/index.js +73 -121
- package/dist/components/Autocomplete/index.js.map +1 -1
- package/dist/components/Autocomplete/styles.js +1 -2
- package/dist/components/Autocomplete/types.js +1 -2
- package/dist/components/Avatar/index.js +49 -90
- package/dist/components/Avatar/index.js.map +1 -1
- package/dist/components/Avatar/styles.js +1 -2
- package/dist/components/Avatar/types.js +1 -2
- package/dist/components/AvatarGroup/index.js +30 -75
- package/dist/components/AvatarGroup/index.js.map +1 -1
- package/dist/components/AvatarGroup/styles.js +1 -2
- package/dist/components/AvatarGroup/types.js +1 -2
- package/dist/components/Backdrop/index.js +26 -66
- package/dist/components/Backdrop/index.js.map +1 -1
- package/dist/components/Backdrop/styles.js +1 -2
- package/dist/components/Backdrop/types.js +1 -2
- package/dist/components/Badge/index.js +44 -85
- package/dist/components/Badge/index.js.map +1 -1
- package/dist/components/Badge/styles.js +1 -2
- package/dist/components/Badge/types.js +1 -2
- package/dist/components/Button/index.js +49 -98
- package/dist/components/Button/index.js.map +1 -1
- package/dist/components/Button/styles.js +1 -2
- package/dist/components/Button/types.js +1 -2
- package/dist/components/Calendar/index.js +27 -68
- package/dist/components/Calendar/index.js.map +1 -1
- package/dist/components/Calendar/types.d.ts +1 -2
- package/dist/components/Calendar/types.js +1 -2
- package/dist/components/Checkbox/index.js +52 -85
- package/dist/components/Checkbox/index.js.map +1 -1
- package/dist/components/Checkbox/styles.js +1 -2
- package/dist/components/Checkbox/types.js +1 -2
- package/dist/components/DatePickerModal/index.js +61 -113
- package/dist/components/DatePickerModal/index.js.map +1 -1
- package/dist/components/DatePickerModal/styles.js +1 -2
- package/dist/components/DatePickerModal/types.js +1 -2
- package/dist/components/EmptyPlaceholder/index.js +40 -69
- package/dist/components/EmptyPlaceholder/index.js.map +1 -1
- package/dist/components/EmptyPlaceholder/styles.js +1 -2
- package/dist/components/EmptyPlaceholder/types.js +1 -2
- package/dist/components/FileInput/index.js +112 -178
- package/dist/components/FileInput/index.js.map +1 -1
- package/dist/components/FileInput/types.js +1 -2
- package/dist/components/Grid/index.js +47 -97
- package/dist/components/Grid/index.js.map +1 -1
- package/dist/components/Grid/styles.js +1 -2
- package/dist/components/Grid/types.js +1 -2
- package/dist/components/Icon/index.js +34 -75
- package/dist/components/Icon/index.js.map +1 -1
- package/dist/components/Icon/styles.js +1 -2
- package/dist/components/Icon/types.js +1 -2
- package/dist/components/Image/index.js +53 -96
- package/dist/components/Image/index.js.map +1 -1
- package/dist/components/Image/styles.js +1 -2
- package/dist/components/Image/types.js +1 -2
- package/dist/components/ImageView/Spotlight.js +75 -131
- package/dist/components/ImageView/Spotlight.js.map +1 -1
- package/dist/components/ImageView/component.js +8 -15
- package/dist/components/ImageView/component.js.map +1 -1
- package/dist/components/ImageView/index.js +2 -18
- package/dist/components/ImageView/index.js.map +1 -1
- package/dist/components/InputBase/index.js +35 -75
- package/dist/components/InputBase/index.js.map +1 -1
- package/dist/components/InputBase/styles.d.ts +3 -3
- package/dist/components/InputBase/styles.js +49 -50
- package/dist/components/InputBase/styles.js.map +1 -1
- package/dist/components/InputBase/types.d.ts +1 -0
- package/dist/components/InputBase/types.js +1 -2
- package/dist/components/InputBase/utils.js +4 -19
- package/dist/components/InputBase/utils.js.map +1 -1
- package/dist/components/List/index.js +46 -86
- package/dist/components/List/index.js.map +1 -1
- package/dist/components/List/styles.js +1 -2
- package/dist/components/List/types.js +1 -2
- package/dist/components/LoadingOverlay/index.js +28 -66
- package/dist/components/LoadingOverlay/index.js.map +1 -1
- package/dist/components/LoadingOverlay/styles.js +1 -2
- package/dist/components/LoadingOverlay/types.js +1 -2
- package/dist/components/Modal/index.js +77 -113
- package/dist/components/Modal/index.js.map +1 -1
- package/dist/components/Modal/styles.js +1 -2
- package/dist/components/Modal/types.js +1 -2
- package/dist/components/Navigation/Navigation.js +23 -66
- package/dist/components/Navigation/Navigation.js.map +1 -1
- package/dist/components/Navigation/constants.js +7 -10
- package/dist/components/Navigation/constants.js.map +1 -1
- package/dist/components/Navigation/index.js +3 -19
- package/dist/components/Navigation/index.js.map +1 -1
- package/dist/components/Navigation/types.js +1 -2
- package/dist/components/Navigation/utils.js +24 -59
- package/dist/components/Navigation/utils.js.map +1 -1
- package/dist/components/NumberIncrement/index.js +132 -165
- package/dist/components/NumberIncrement/index.js.map +1 -1
- package/dist/components/NumberIncrement/styles.js +1 -2
- package/dist/components/NumberIncrement/types.d.ts +2 -2
- package/dist/components/NumberIncrement/types.js +1 -2
- package/dist/components/NumberIncrement/utils.js +8 -12
- package/dist/components/NumberIncrement/utils.js.map +1 -1
- package/dist/components/Pager/PagerDots.js +17 -54
- package/dist/components/Pager/PagerDots.js.map +1 -1
- package/dist/components/Pager/index.js +43 -97
- package/dist/components/Pager/index.js.map +1 -1
- package/dist/components/Pager/styles.js +1 -2
- package/dist/components/Pager/types.js +1 -2
- package/dist/components/PaginationIndicator/index.js +23 -38
- package/dist/components/PaginationIndicator/index.js.map +1 -1
- package/dist/components/PaginationIndicator/styles.js +1 -2
- package/dist/components/PaginationIndicator/types.js +1 -2
- package/dist/components/PlacesAutocomplete/index.js +55 -106
- package/dist/components/PlacesAutocomplete/index.js.map +1 -1
- package/dist/components/PlacesAutocomplete/styles.js +1 -2
- package/dist/components/PlacesAutocomplete/types.js +1 -2
- package/dist/components/RadioInput/index.js +46 -84
- package/dist/components/RadioInput/index.js.map +1 -1
- package/dist/components/RadioInput/styles.js +1 -2
- package/dist/components/RadioInput/types.js +1 -2
- package/dist/components/RefreshControl/index.js +22 -63
- package/dist/components/RefreshControl/index.js.map +1 -1
- package/dist/components/RefreshControl/styles.js +1 -2
- package/dist/components/RefreshControl/types.js +1 -2
- package/dist/components/Scroll/index.js +33 -81
- package/dist/components/Scroll/index.js.map +1 -1
- package/dist/components/Scroll/styles.js +1 -2
- package/dist/components/Scroll/types.js +1 -2
- package/dist/components/SearchInput/index.js +22 -69
- package/dist/components/SearchInput/index.js.map +1 -1
- package/dist/components/SectionFilters/context.d.ts +6 -0
- package/dist/components/SectionFilters/context.js +4 -8
- package/dist/components/SectionFilters/context.js.map +1 -1
- package/dist/components/SectionFilters/index.js +33 -76
- package/dist/components/SectionFilters/index.js.map +1 -1
- package/dist/components/SectionFilters/types.js +1 -2
- package/dist/components/SectionFilters/useSectionFilters.d.ts +3 -0
- package/dist/components/SectionFilters/useSectionFilters.js +71 -73
- package/dist/components/SectionFilters/useSectionFilters.js.map +1 -1
- package/dist/components/Sections/index.d.ts +8 -8
- package/dist/components/Sections/index.js +61 -106
- package/dist/components/Sections/index.js.map +1 -1
- package/dist/components/Sections/styles.d.ts +1 -1
- package/dist/components/Sections/styles.js +1 -2
- package/dist/components/Sections/types.js +1 -2
- package/dist/components/SegmentedControl/Option.js +13 -31
- package/dist/components/SegmentedControl/Option.js.map +1 -1
- package/dist/components/SegmentedControl/index.js +71 -114
- package/dist/components/SegmentedControl/index.js.map +1 -1
- package/dist/components/SegmentedControl/styles.js +1 -2
- package/dist/components/SegmentedControl/types.js +1 -2
- package/dist/components/Select/index.js +94 -157
- package/dist/components/Select/index.js.map +1 -1
- package/dist/components/Select/styles.js +1 -2
- package/dist/components/Select/types.js +1 -2
- package/dist/components/Slider/index.js +89 -129
- package/dist/components/Slider/index.js.map +1 -1
- package/dist/components/Slider/styles.d.ts +0 -6
- package/dist/components/Slider/styles.js +1 -2
- package/dist/components/Slider/types.js +1 -2
- package/dist/components/SortablePhotos/index.js +58 -91
- package/dist/components/SortablePhotos/index.js.map +1 -1
- package/dist/components/SortablePhotos/styles.js +1 -2
- package/dist/components/SortablePhotos/types.js +1 -2
- package/dist/components/SortablePhotos/useSortablePhotos.js +93 -157
- package/dist/components/SortablePhotos/useSortablePhotos.js.map +1 -1
- package/dist/components/Switch/index.js +51 -84
- package/dist/components/Switch/index.js.map +1 -1
- package/dist/components/Switch/styles.js +1 -2
- package/dist/components/Switch/types.js +1 -2
- package/dist/components/Text/index.js +40 -88
- package/dist/components/Text/index.js.map +1 -1
- package/dist/components/Text/styles.js +1 -2
- package/dist/components/Text/types.js +1 -2
- package/dist/components/TextInput/index.js +83 -131
- package/dist/components/TextInput/index.js.map +1 -1
- package/dist/components/TextInput/styles.js +1 -2
- package/dist/components/TextInput/types.js +1 -2
- package/dist/components/Touchable/index.js +69 -122
- package/dist/components/Touchable/index.js.map +1 -1
- package/dist/components/Touchable/styles.js +1 -2
- package/dist/components/Touchable/types.js +1 -2
- package/dist/components/View/index.js +19 -51
- package/dist/components/View/index.js.map +1 -1
- package/dist/components/View/styles.js +1 -2
- package/dist/components/View/types.js +1 -2
- package/dist/components/components.js +43 -59
- package/dist/components/components.js.map +1 -1
- package/dist/hooks/index.js +7 -11
- package/dist/hooks/index.js.map +1 -1
- package/dist/index.js +8 -43
- package/dist/index.js.map +1 -1
- package/dist/modules/PressableRipple/index.js +2 -8
- package/dist/modules/PressableRipple/index.js.map +1 -1
- package/dist/modules/PressableRipple/ripple.js +125 -163
- package/dist/modules/PressableRipple/ripple.js.map +1 -1
- package/dist/modules/PressableRipple/styles.js +9 -20
- package/dist/modules/PressableRipple/styles.js.map +1 -1
- package/dist/modules/PressableRipple/type.js +1 -2
- package/dist/modules/reactNavigation.js +10 -21
- package/dist/modules/reactNavigation.js.map +1 -1
- package/dist/modules/textInputMask.js +3 -20
- package/dist/modules/textInputMask.js.map +1 -1
- package/dist/modules/types/textInputMask.js +1 -2
- package/dist/types/index.js +1 -17
- package/dist/types/index.js.map +1 -1
- package/dist/types/utility.js +1 -2
- package/dist/utils/KeyboardAware/context.js +5 -14
- package/dist/utils/KeyboardAware/context.js.map +1 -1
- package/dist/utils/KeyboardAware/index.js +3 -19
- package/dist/utils/KeyboardAware/index.js.map +1 -1
- package/dist/utils/KeyboardAware/keyboardHooks.js +36 -41
- package/dist/utils/KeyboardAware/keyboardHooks.js.map +1 -1
- package/dist/utils/KeyboardAware/types.js +1 -2
- package/dist/utils/KeyboardAware/types.js.map +1 -1
- package/dist/utils/ModalManager/components.js +24 -54
- package/dist/utils/ModalManager/components.js.map +1 -1
- package/dist/utils/ModalManager/context.js +94 -89
- package/dist/utils/ModalManager/context.js.map +1 -1
- package/dist/utils/ModalManager/index.js +7 -10
- package/dist/utils/ModalManager/index.js.map +1 -1
- package/dist/utils/NotificationManager/index.js +115 -245
- package/dist/utils/NotificationManager/index.js.map +1 -1
- package/dist/utils/NotificationManager/types.js +1 -2
- package/dist/utils/OSAlert.js +32 -48
- package/dist/utils/OSAlert.js.map +1 -1
- package/dist/utils/PermissionManager/context.js +138 -255
- package/dist/utils/PermissionManager/context.js.map +1 -1
- package/dist/utils/PermissionManager/index.js +2 -8
- package/dist/utils/PermissionManager/index.js.map +1 -1
- package/dist/utils/PermissionManager/types.js +1 -2
- package/dist/utils/StorageManager.js +39 -46
- package/dist/utils/StorageManager.js.map +1 -1
- package/dist/utils/Subscription.js +30 -54
- package/dist/utils/Subscription.js.map +1 -1
- package/dist/utils/deprecated/notifications.js +143 -250
- package/dist/utils/deprecated/notifications.js.map +1 -1
- package/dist/utils/hooks.js +101 -120
- package/dist/utils/hooks.js.map +1 -1
- package/dist/utils/index.js +14 -43
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/input.js +15 -19
- package/dist/utils/input.js.map +1 -1
- package/dist/utils/locale.js +5 -9
- package/dist/utils/locale.js.map +1 -1
- package/dist/utils/misc.js +25 -40
- package/dist/utils/misc.js.map +1 -1
- package/dist/utils/theme.js +24 -33
- package/dist/utils/theme.js.map +1 -1
- package/dist/utils/useQueryListRefresh.js +16 -26
- package/dist/utils/useQueryListRefresh.js.map +1 -1
- package/package.json +6 -6
- package/package.json.bak +2 -2
- package/src/components/Calendar/types.ts +3 -3
- package/src/components/InputBase/styles.ts +35 -23
- package/src/components/InputBase/types.ts +1 -0
- package/src/components/NumberIncrement/index.tsx +8 -2
- package/src/components/NumberIncrement/types.ts +3 -3
- package/src/components/RadioInput/index.tsx +4 -0
- package/src/components/SectionFilters/useSectionFilters.tsx +31 -1
- package/src/components/Sections/index.tsx +3 -2
- package/src/components/Sections/styles.ts +2 -2
- package/src/components/Slider/index.tsx +9 -1
- package/src/components/Slider/styles.ts +0 -6
- package/src/components/TextInput/index.tsx +5 -0
|
@@ -1,173 +1,112 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __assign = (this && this.__assign) || function () {
|
|
3
|
-
__assign = Object.assign || function(t) {
|
|
4
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
-
s = arguments[i];
|
|
6
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
-
t[p] = s[p];
|
|
8
|
-
}
|
|
9
|
-
return t;
|
|
10
|
-
};
|
|
11
|
-
return __assign.apply(this, arguments);
|
|
12
|
-
};
|
|
13
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
14
|
-
if (k2 === undefined) k2 = k;
|
|
15
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
16
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
17
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
18
|
-
}
|
|
19
|
-
Object.defineProperty(o, k2, desc);
|
|
20
|
-
}) : (function(o, m, k, k2) {
|
|
21
|
-
if (k2 === undefined) k2 = k;
|
|
22
|
-
o[k2] = m[k];
|
|
23
|
-
}));
|
|
24
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
25
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
26
|
-
}) : function(o, v) {
|
|
27
|
-
o["default"] = v;
|
|
28
|
-
});
|
|
29
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
30
|
-
if (mod && mod.__esModule) return mod;
|
|
31
|
-
var result = {};
|
|
32
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
33
|
-
__setModuleDefault(result, mod);
|
|
34
|
-
return result;
|
|
35
|
-
};
|
|
36
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
37
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
38
|
-
};
|
|
39
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
40
|
-
var t = {};
|
|
41
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
42
|
-
t[p] = s[p];
|
|
43
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
44
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
45
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
46
|
-
t[p[i]] = s[p[i]];
|
|
47
|
-
}
|
|
48
|
-
return t;
|
|
49
|
-
};
|
|
50
|
-
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
51
|
-
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
52
|
-
if (ar || !(i in from)) {
|
|
53
|
-
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
54
|
-
ar[i] = from[i];
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
return to.concat(ar || Array.prototype.slice.call(from));
|
|
58
|
-
};
|
|
59
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
60
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
61
|
-
};
|
|
62
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
63
|
-
exports.Select = void 0;
|
|
64
1
|
/* eslint-disable max-lines */
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
return options.filter(
|
|
80
|
-
if (
|
|
2
|
+
import { TypeGuards, onMount, onUpdate, usePrevious, useSearch, useConditionalState, } from '@codeleap/common';
|
|
3
|
+
import React, { useCallback, useMemo } from 'react';
|
|
4
|
+
import { List } from '../List';
|
|
5
|
+
import { TextInput } from '../TextInput';
|
|
6
|
+
import { ModalManager } from '../../utils';
|
|
7
|
+
import { Button } from '../Button';
|
|
8
|
+
import { useCompositionStyles } from '@codeleap/styles';
|
|
9
|
+
import Modal from '../Modal';
|
|
10
|
+
import { MobileStyleRegistry } from '../../Registry';
|
|
11
|
+
import { SearchInput } from '../SearchInput';
|
|
12
|
+
import { useStylesFor } from '../../hooks';
|
|
13
|
+
export * from './styles';
|
|
14
|
+
export * from './types';
|
|
15
|
+
const defaultFilterFunction = (search, options) => {
|
|
16
|
+
return options.filter((option) => {
|
|
17
|
+
if (TypeGuards.isString(option.label)) {
|
|
81
18
|
return option.label.toLowerCase().includes(search.toLowerCase());
|
|
82
19
|
}
|
|
83
20
|
return option.label === search;
|
|
84
21
|
});
|
|
85
22
|
};
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
if ((option === null || option === void 0 ? void 0 : option.length) === 0)
|
|
23
|
+
const defaultGetLabel = (option) => {
|
|
24
|
+
if (TypeGuards.isArray(option)) {
|
|
25
|
+
if (option?.length === 0)
|
|
90
26
|
return null;
|
|
91
|
-
|
|
92
|
-
return labels
|
|
27
|
+
const labels = option?.map(option => option?.label)?.filter(value => !!value);
|
|
28
|
+
return labels?.join(', ');
|
|
93
29
|
}
|
|
94
30
|
else {
|
|
95
31
|
if (!option)
|
|
96
32
|
return null;
|
|
97
|
-
return option
|
|
33
|
+
return option?.label;
|
|
98
34
|
}
|
|
99
35
|
};
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
return <
|
|
36
|
+
const OuterInput = (props) => {
|
|
37
|
+
const { currentValueLabel, debugName, clearIcon, label, toggle, style, placeholder, disabled = false, inputProps = {}, } = props;
|
|
38
|
+
return <TextInput value={TypeGuards.isString(currentValueLabel) ? currentValueLabel : null} rightIcon={clearIcon} onPress={disabled ? null : () => toggle()} disabled={disabled} label={label} debugName={debugName} style={style} innerWrapperProps={{
|
|
103
39
|
rippleDisabled: true,
|
|
104
40
|
}} placeholder={placeholder} {...inputProps}/>;
|
|
105
41
|
};
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
42
|
+
export const Select = (selectProps) => {
|
|
43
|
+
const allProps = {
|
|
44
|
+
...Select.defaultProps,
|
|
45
|
+
...selectProps,
|
|
46
|
+
};
|
|
47
|
+
const { value, onValueChange, label, options = [], style, description, renderItem: Item, listProps, debugName, placeholder, arrowIconName, clearIconName, clearable, selectedIcon, inputProps = {}, hideInput, itemProps = {}, searchable, loadOptions, multiple, closeOnSelect = !multiple, limit = null, defaultOptions = options, visible: _visible, toggle: _toggle, ListHeaderComponent, ListComponent, onLoadOptionsError, loadOptionsOnMount = defaultOptions.length === 0, loadOptionsOnOpen, filterItems, getLabel, searchInputProps, outerInputComponent, disabled, ...modalProps } = allProps;
|
|
48
|
+
const isValueArray = TypeGuards.isArray(value) && multiple;
|
|
49
|
+
const { loading, setLoading, labelOptions, setLabelOptions, filteredOptions, load, onChangeSearch, } = useSearch({
|
|
50
|
+
value,
|
|
51
|
+
multiple,
|
|
52
|
+
options,
|
|
53
|
+
filterItems,
|
|
54
|
+
debugName,
|
|
55
|
+
defaultOptions,
|
|
56
|
+
loadOptions,
|
|
57
|
+
onLoadOptionsError,
|
|
58
|
+
});
|
|
59
|
+
const [visible, toggle] = useConditionalState(_visible, _toggle, { initialValue: false, isBooleanToggle: true });
|
|
60
|
+
const currentValueLabel = useMemo(() => {
|
|
61
|
+
const _options = (multiple ? labelOptions : labelOptions?.[0]);
|
|
62
|
+
const label = getLabel(_options);
|
|
124
63
|
return label;
|
|
125
64
|
}, [labelOptions]);
|
|
126
|
-
|
|
65
|
+
onMount(() => {
|
|
127
66
|
if (loadOptionsOnMount && !!loadOptions) {
|
|
128
67
|
load();
|
|
129
68
|
}
|
|
130
69
|
});
|
|
131
|
-
|
|
132
|
-
|
|
70
|
+
const prevVisible = usePrevious(visible);
|
|
71
|
+
onUpdate(() => {
|
|
133
72
|
if (visible && !prevVisible && loadOptionsOnOpen && !!loadOptions) {
|
|
134
73
|
load();
|
|
135
74
|
}
|
|
136
75
|
}, [visible, prevVisible]);
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
76
|
+
const styles = useStylesFor(Select.styleRegistryName, style);
|
|
77
|
+
const compositionStyles = useCompositionStyles(['item', 'list', 'input', 'searchInput'], styles);
|
|
78
|
+
const currentOptions = searchable ? filteredOptions : defaultOptions;
|
|
79
|
+
const close = () => toggle?.();
|
|
80
|
+
const select = useCallback((selectedValue) => {
|
|
81
|
+
let newValue = null;
|
|
82
|
+
let newOption = null;
|
|
83
|
+
let removedIndex = null;
|
|
145
84
|
if (multiple && isValueArray) {
|
|
146
85
|
if (value.includes(selectedValue)) {
|
|
147
|
-
removedIndex = value.findIndex(
|
|
148
|
-
newValue = value.filter(
|
|
86
|
+
removedIndex = value.findIndex(v => v === selectedValue);
|
|
87
|
+
newValue = value.filter((v, i) => i !== removedIndex);
|
|
149
88
|
}
|
|
150
89
|
else {
|
|
151
|
-
if (
|
|
90
|
+
if (TypeGuards.isNumber(limit) && value.length >= limit) {
|
|
152
91
|
return;
|
|
153
92
|
}
|
|
154
|
-
newOption = currentOptions.find(
|
|
155
|
-
newValue =
|
|
93
|
+
newOption = currentOptions.find(o => o.value === selectedValue);
|
|
94
|
+
newValue = [...value, selectedValue];
|
|
156
95
|
}
|
|
157
96
|
}
|
|
158
97
|
else {
|
|
159
98
|
newValue = selectedValue;
|
|
160
|
-
newOption = currentOptions.find(
|
|
99
|
+
newOption = currentOptions.find(o => o.value === selectedValue);
|
|
161
100
|
}
|
|
162
101
|
onValueChange(newValue);
|
|
163
102
|
if (isValueArray) {
|
|
164
103
|
if (removedIndex !== null) {
|
|
165
|
-
|
|
104
|
+
const newOptions = [...labelOptions];
|
|
166
105
|
newOptions.splice(removedIndex, 1);
|
|
167
106
|
setLabelOptions(newOptions);
|
|
168
107
|
}
|
|
169
108
|
else {
|
|
170
|
-
|
|
109
|
+
const newLabels = [...labelOptions, newOption];
|
|
171
110
|
setLabelOptions(newLabels);
|
|
172
111
|
}
|
|
173
112
|
}
|
|
@@ -175,70 +114,68 @@ var Select = function (selectProps) {
|
|
|
175
114
|
setLabelOptions([newOption]);
|
|
176
115
|
}
|
|
177
116
|
if (closeOnSelect) {
|
|
178
|
-
close
|
|
117
|
+
close?.();
|
|
179
118
|
}
|
|
180
119
|
}, [isValueArray, (isValueArray ? value : [value]), limit, multiple, labelOptions, currentOptions]);
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
var selected = false;
|
|
120
|
+
const renderListItem = useCallback(({ item, index }) => {
|
|
121
|
+
let selected = false;
|
|
184
122
|
if (multiple && isValueArray) {
|
|
185
|
-
selected = value
|
|
123
|
+
selected = value?.includes(item.value);
|
|
186
124
|
}
|
|
187
125
|
else {
|
|
188
126
|
selected = value === item.value;
|
|
189
127
|
}
|
|
190
|
-
return <Item debugName={
|
|
128
|
+
return <Item debugName={`${debugName} item ${item.value}`} selected={selected} text={item.label} item={item} onPress={() => select(item.value)}
|
|
191
129
|
// @ts-ignore
|
|
192
130
|
icon={selectedIcon}
|
|
193
131
|
// @ts-ignore
|
|
194
|
-
rightIcon={selectedIcon} style={compositionStyles
|
|
132
|
+
rightIcon={selectedIcon} style={compositionStyles?.item} index={index} {...itemProps}/>;
|
|
195
133
|
}, [value, select, multiple]);
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
134
|
+
const isEmpty = TypeGuards.isNil(value);
|
|
135
|
+
const showClearIcon = !isEmpty && clearable;
|
|
136
|
+
const inputIcon = showClearIcon ? clearIconName : arrowIconName;
|
|
137
|
+
const onPressInputIcon = () => {
|
|
200
138
|
if (showClearIcon) {
|
|
201
139
|
onValueChange(null);
|
|
202
140
|
}
|
|
203
141
|
else {
|
|
204
|
-
close
|
|
142
|
+
close?.();
|
|
205
143
|
}
|
|
206
144
|
};
|
|
207
|
-
|
|
145
|
+
const searchHeader = searchable ? <SearchInput debugName={debugName} onTypingChange={(isTyping) => {
|
|
208
146
|
if (searchable && !!loadOptions) {
|
|
209
147
|
setLoading(isTyping);
|
|
210
148
|
}
|
|
211
|
-
}} debounce={!!loadOptions ? 800 : null} onSearchChange={onChangeSearch} style={compositionStyles
|
|
212
|
-
|
|
149
|
+
}} debounce={!!loadOptions ? 800 : null} onSearchChange={onChangeSearch} style={compositionStyles?.searchInput} {...searchInputProps}/> : null;
|
|
150
|
+
const _ListHeaderComponent = useMemo(() => {
|
|
213
151
|
if (ListHeaderComponent) {
|
|
214
152
|
return <ListHeaderComponent searchComponent={searchHeader}/>;
|
|
215
153
|
}
|
|
216
154
|
return searchHeader;
|
|
217
155
|
}, [searchable, ListHeaderComponent]);
|
|
218
|
-
|
|
156
|
+
const Input = outerInputComponent;
|
|
219
157
|
return <>
|
|
220
158
|
{!hideInput ? (
|
|
221
159
|
// @ts-ignore
|
|
222
160
|
<Input clearIcon={{
|
|
223
161
|
icon: inputIcon,
|
|
224
162
|
onPress: disabled ? null : onPressInputIcon,
|
|
225
|
-
}} currentValueLabel={currentValueLabel} debugName={
|
|
163
|
+
}} currentValueLabel={currentValueLabel} debugName={`${debugName} select input`} style={compositionStyles?.input} {...allProps} {...inputProps} visible={visible} toggle={toggle}/>) : null}
|
|
226
164
|
|
|
227
|
-
<
|
|
228
|
-
<ListComponent data={searchable ? filteredOptions : options} scrollEnabled={false} showsHorizontalScrollIndicator={false} style={compositionStyles
|
|
229
|
-
loading
|
|
165
|
+
<ModalManager.Modal title={label} description={description} {...modalProps} debugName={`${debugName} modal`} style={styles} id={null} visible={visible} toggle={toggle}>
|
|
166
|
+
<ListComponent data={searchable ? filteredOptions : options} scrollEnabled={false} showsHorizontalScrollIndicator={false} style={compositionStyles?.list} keyExtractor={(i) => i.value} renderItem={renderListItem} fakeEmpty={loading} separators keyboardAware={false} {...listProps} ListHeaderComponent={_ListHeaderComponent} placeholder={{
|
|
167
|
+
loading,
|
|
230
168
|
}}/>
|
|
231
|
-
</
|
|
169
|
+
</ModalManager.Modal>
|
|
232
170
|
</>;
|
|
233
171
|
};
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
return exports.Select;
|
|
172
|
+
Select.styleRegistryName = 'Select';
|
|
173
|
+
Select.elements = [...Modal.elements, 'input', 'list', 'item', 'searchInput'];
|
|
174
|
+
Select.rootElement = 'inputWrapper';
|
|
175
|
+
Select.withVariantTypes = (styles) => {
|
|
176
|
+
return Select;
|
|
240
177
|
};
|
|
241
|
-
|
|
178
|
+
Select.defaultProps = {
|
|
242
179
|
getLabel: defaultGetLabel,
|
|
243
180
|
outerInputComponent: OuterInput,
|
|
244
181
|
searchInputProps: {},
|
|
@@ -252,8 +189,8 @@ exports.Select.defaultProps = {
|
|
|
252
189
|
loadOptionsOnOpen: false,
|
|
253
190
|
disabled: false,
|
|
254
191
|
filterItems: defaultFilterFunction,
|
|
255
|
-
renderItem:
|
|
256
|
-
ListComponent:
|
|
192
|
+
renderItem: Button,
|
|
193
|
+
ListComponent: List,
|
|
257
194
|
};
|
|
258
|
-
|
|
195
|
+
MobileStyleRegistry.registerComponent(Select);
|
|
259
196
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Select/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Select/index.tsx"],"names":[],"mappings":"AAAA,8BAA8B;AAC9B,OAAO,EACL,UAAU,EAEV,OAAO,EACP,QAAQ,EACR,WAAW,EACX,SAAS,EACT,mBAAmB,GACpB,MAAM,kBAAkB,CAAA;AACzB,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,OAAO,CAAA;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC1C,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAkD,oBAAoB,EAAE,MAAM,kBAAkB,CAAA;AACvG,OAAO,KAAK,MAAM,UAAU,CAAA;AAC5B,OAAO,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAE1C,cAAc,UAAU,CAAA;AACxB,cAAc,SAAS,CAAA;AAEvB,MAAM,qBAAqB,GAAG,CAAC,MAAc,EAAE,OAA+B,EAAE,EAAE;IAChF,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,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