@ornikar/kitt-universal 27.3.1-canary.2a1e1042a7d526c8c6b6197a77f84626e0e5d206.0 → 27.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -17
- package/dist/definitions/BaseMessage/helper.d.ts.map +1 -1
- package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.d.ts +1 -1
- package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.d.ts.map +1 -1
- package/dist/definitions/Highlight/AnimatedContainer/AnimatedContainer.web.d.ts.map +1 -1
- package/dist/definitions/Highlight/Highlight.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/cardModal.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/dialogModal.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/highlight.d.ts +4 -0
- package/dist/definitions/themes/late-ocean/highlight.d.ts.map +1 -1
- package/dist/definitions/typography/Typography.d.ts +6 -18
- package/dist/definitions/typography/Typography.d.ts.map +1 -1
- package/dist/index-metro.es.android.js +24 -11
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +24 -11
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +24 -11
- package/dist/index-node-22.17.cjs.js.map +1 -1
- package/dist/index-node-22.17.cjs.web.js +21 -9
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +24 -11
- package/dist/index-node-22.17.es.mjs.map +1 -1
- package/dist/index-node-22.17.es.web.mjs +21 -9
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +113 -100
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +81 -69
- package/dist/index.es.web.js.map +1 -1
- package/dist/linaria-themes-metro.es.android.js +10 -6
- package/dist/linaria-themes-metro.es.android.js.map +1 -1
- package/dist/linaria-themes-metro.es.ios.js +10 -6
- package/dist/linaria-themes-metro.es.ios.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.js +10 -6
- package/dist/linaria-themes-node-22.17.cjs.js.map +1 -1
- package/dist/linaria-themes-node-22.17.cjs.web.js +10 -6
- package/dist/linaria-themes-node-22.17.cjs.web.js.map +1 -1
- package/dist/linaria-themes-node-22.17.es.mjs +10 -6
- package/dist/linaria-themes-node-22.17.es.mjs.map +1 -1
- package/dist/linaria-themes-node-22.17.es.web.mjs +10 -6
- package/dist/linaria-themes-node-22.17.es.web.mjs.map +1 -1
- package/dist/linaria-themes.es.js +11 -7
- package/dist/linaria-themes.es.js.map +1 -1
- package/dist/linaria-themes.es.web.js +11 -7
- package/dist/linaria-themes.es.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +28 -28
package/dist/index.es.js
CHANGED
|
@@ -761,7 +761,7 @@ var webAnimationOverlayEasing$2 = [0.42, 0, 1, 1];
|
|
|
761
761
|
var maxWidth = 540;
|
|
762
762
|
var overlayHorizontalPadding = 24;
|
|
763
763
|
var cardModal = {
|
|
764
|
-
borderRadius:
|
|
764
|
+
borderRadius: spacing * 2,
|
|
765
765
|
maxWidth: maxWidth,
|
|
766
766
|
maxWidthWithPadding: maxWidth + overlayHorizontalPadding * 2,
|
|
767
767
|
minHeight: 280,
|
|
@@ -853,7 +853,7 @@ var webAnimationContentEasing$1 = [0.77, 0, 0.175, 1];
|
|
|
853
853
|
var webAnimationOverlayDuration$1 = 250;
|
|
854
854
|
var webAnimationOverlayEasing$1 = [0.42, 0, 1, 1];
|
|
855
855
|
var dialogModal = {
|
|
856
|
-
borderRadius:
|
|
856
|
+
borderRadius: spacing * 2,
|
|
857
857
|
maxWidth: 540,
|
|
858
858
|
overlayPadding: {
|
|
859
859
|
horizontal: 24,
|
|
@@ -1822,10 +1822,10 @@ var highlight = {
|
|
|
1822
1822
|
},
|
|
1823
1823
|
primary: {
|
|
1824
1824
|
"default": {
|
|
1825
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1825
|
+
backgroundColor: deepPurpleColorPalette['blue.1']
|
|
1826
1826
|
},
|
|
1827
1827
|
hover: {
|
|
1828
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1828
|
+
backgroundColor: deepPurpleColorPalette['blue.2']
|
|
1829
1829
|
}
|
|
1830
1830
|
},
|
|
1831
1831
|
secondary: {
|
|
@@ -1846,10 +1846,14 @@ var highlight = {
|
|
|
1846
1846
|
},
|
|
1847
1847
|
dark: {
|
|
1848
1848
|
"default": {
|
|
1849
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1849
|
+
backgroundColor: deepPurpleColorPalette['grey.0'],
|
|
1850
|
+
borderWidth: 1,
|
|
1851
|
+
borderColor: deepPurpleColorPalette['beige.3']
|
|
1850
1852
|
},
|
|
1851
1853
|
hover: {
|
|
1852
|
-
backgroundColor: deepPurpleColorPalette['beige.1']
|
|
1854
|
+
backgroundColor: deepPurpleColorPalette['beige.1'],
|
|
1855
|
+
borderWidth: 1,
|
|
1856
|
+
borderColor: deepPurpleColorPalette['beige.3']
|
|
1853
1857
|
}
|
|
1854
1858
|
},
|
|
1855
1859
|
success: {
|
|
@@ -2452,7 +2456,7 @@ var breakpoints = {
|
|
|
2452
2456
|
// TODO : seperate brand color usage definition from proper theme definition and add typings - https://ornikar.atlassian.net/browse/CME-156
|
|
2453
2457
|
var theme = {
|
|
2454
2458
|
spacing: spacing,
|
|
2455
|
-
getSpacing: function (multiplier) {
|
|
2459
|
+
getSpacing: function getSpacing(multiplier) {
|
|
2456
2460
|
return spacing * multiplier;
|
|
2457
2461
|
},
|
|
2458
2462
|
colors: colors,
|
|
@@ -2639,7 +2643,7 @@ var ActionCardPressable = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
2639
2643
|
onPress: onPress,
|
|
2640
2644
|
onHoverIn: onHoverIn,
|
|
2641
2645
|
onHoverOut: onHoverOut,
|
|
2642
|
-
children: function (_ref3) {
|
|
2646
|
+
children: function children(_ref3) {
|
|
2643
2647
|
var isHovered = _ref3.isHovered,
|
|
2644
2648
|
isPressed = _ref3.isPressed,
|
|
2645
2649
|
isFocused = _ref3.isFocused;
|
|
@@ -3419,11 +3423,11 @@ var useNativeAnimation$4 = function (_ref) {
|
|
|
3419
3423
|
};
|
|
3420
3424
|
});
|
|
3421
3425
|
return {
|
|
3422
|
-
onPressIn: function () {
|
|
3426
|
+
onPressIn: function handlePressIn() {
|
|
3423
3427
|
color.value = withSpring(1);
|
|
3424
3428
|
pressed.value = 1;
|
|
3425
3429
|
},
|
|
3426
|
-
onPressOut: function () {
|
|
3430
|
+
onPressOut: function handlePressOut() {
|
|
3427
3431
|
color.value = withSpring(0);
|
|
3428
3432
|
pressed.value = 0;
|
|
3429
3433
|
},
|
|
@@ -3492,7 +3496,7 @@ var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
3492
3496
|
onHoverOut: onHoverOut,
|
|
3493
3497
|
onFocus: onFocus,
|
|
3494
3498
|
onBlur: onBlur,
|
|
3495
|
-
children: function (_ref2) {
|
|
3499
|
+
children: function children(_ref2) {
|
|
3496
3500
|
var isHovered = _ref2.isHovered,
|
|
3497
3501
|
isPressed = _ref2.isPressed,
|
|
3498
3502
|
isFocused = _ref2.isFocused;
|
|
@@ -3615,7 +3619,7 @@ var ActionsItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
3615
3619
|
stretch: stretch,
|
|
3616
3620
|
disabled: isLoading ? true : disabled,
|
|
3617
3621
|
icon: isLoading ? /*#__PURE__*/jsx(LoaderIcon, {}) : icon,
|
|
3618
|
-
onPress: function (e) {
|
|
3622
|
+
onPress: function handlePress(e) {
|
|
3619
3623
|
var callPressAndUpdateLoadingState = /*#__PURE__*/function () {
|
|
3620
3624
|
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
3621
3625
|
return _regeneratorRuntime().wrap(function (_context) {
|
|
@@ -3887,10 +3891,10 @@ function BottomSheetComp(_ref, ref) {
|
|
|
3887
3891
|
borderRadius: 4,
|
|
3888
3892
|
backgroundColor: theme.kitt.bottomSheet.handle.backgroundColor
|
|
3889
3893
|
},
|
|
3890
|
-
handleComponent: function (props) {
|
|
3894
|
+
handleComponent: function handleComponent(props) {
|
|
3891
3895
|
return hasHandle ? /*#__PURE__*/jsx(BottomSheetHandle, _objectSpread({}, props)) : null;
|
|
3892
3896
|
},
|
|
3893
|
-
backdropComponent: function (props) {
|
|
3897
|
+
backdropComponent: function backdropComponent(props) {
|
|
3894
3898
|
return hasBackdrop ? /*#__PURE__*/jsx(BottomSheetBackdrop, _objectSpread(_objectSpread({}, props), {}, {
|
|
3895
3899
|
opacity: 0.25,
|
|
3896
3900
|
appearsOnIndex: 0,
|
|
@@ -3899,7 +3903,7 @@ function BottomSheetComp(_ref, ref) {
|
|
|
3899
3903
|
}
|
|
3900
3904
|
}, rest), {}, {
|
|
3901
3905
|
topInset: top,
|
|
3902
|
-
children: function (props) {
|
|
3906
|
+
children: function children(props) {
|
|
3903
3907
|
return /*#__PURE__*/jsx(Wrapper, {
|
|
3904
3908
|
children: typeof Content === 'function' ? /*#__PURE__*/jsx(Content, _objectSpread({}, props === null || props === void 0 ? void 0 : props.data)) : Content
|
|
3905
3909
|
});
|
|
@@ -3975,7 +3979,7 @@ function CloseButton(_ref) {
|
|
|
3975
3979
|
onPress = _ref.onPress;
|
|
3976
3980
|
var onCloseContextCallback = useOnCloseModalBehaviour();
|
|
3977
3981
|
return /*#__PURE__*/cloneElement(children, {
|
|
3978
|
-
onPress: function () {
|
|
3982
|
+
onPress: function handleClose() {
|
|
3979
3983
|
if (onPress) onPress();
|
|
3980
3984
|
onCloseContextCallback();
|
|
3981
3985
|
}
|
|
@@ -4153,11 +4157,11 @@ function CardModalAnimation(_ref) {
|
|
|
4153
4157
|
transparent: true,
|
|
4154
4158
|
supportedOrientations: ['landscape', 'portrait'],
|
|
4155
4159
|
visible: isModalVisible,
|
|
4156
|
-
onShow: function () {
|
|
4160
|
+
onShow: function onShow() {
|
|
4157
4161
|
if (onEnter) onEnter();
|
|
4158
4162
|
setIsContentVisible(true);
|
|
4159
4163
|
},
|
|
4160
|
-
onDismiss: function () {
|
|
4164
|
+
onDismiss: function onDismiss() {
|
|
4161
4165
|
if (onExited) onExited();
|
|
4162
4166
|
},
|
|
4163
4167
|
children: /*#__PURE__*/jsxs(View, {
|
|
@@ -4204,7 +4208,7 @@ function CardModalBehaviour(_ref) {
|
|
|
4204
4208
|
onClose: onClose,
|
|
4205
4209
|
children: /*#__PURE__*/jsx(CardModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
4206
4210
|
visible: visible,
|
|
4207
|
-
onExited: function () {
|
|
4211
|
+
onExited: function handleExitAnimationDone() {
|
|
4208
4212
|
if (onExited) onExited();
|
|
4209
4213
|
setIsModalBehaviourVisible(false);
|
|
4210
4214
|
},
|
|
@@ -4435,10 +4439,10 @@ var useNativeAnimation$3 = function (_ref) {
|
|
|
4435
4439
|
};
|
|
4436
4440
|
});
|
|
4437
4441
|
return {
|
|
4438
|
-
onPressIn: function () {
|
|
4442
|
+
onPressIn: function onPressIn() {
|
|
4439
4443
|
pressed.value = true;
|
|
4440
4444
|
},
|
|
4441
|
-
onPressOut: function () {
|
|
4445
|
+
onPressOut: function onPressOut() {
|
|
4442
4446
|
pressed.value = false;
|
|
4443
4447
|
},
|
|
4444
4448
|
backgroundStyles: backgroundStyles
|
|
@@ -4501,7 +4505,7 @@ function ChoiceItem(_ref) {
|
|
|
4501
4505
|
style: style,
|
|
4502
4506
|
onBlur: onBlur,
|
|
4503
4507
|
onFocus: onFocus,
|
|
4504
|
-
onPress: function (e) {
|
|
4508
|
+
onPress: function handlePress(e) {
|
|
4505
4509
|
if (onFocus) onFocus(e);
|
|
4506
4510
|
if (onPress) onPress();
|
|
4507
4511
|
handleChange();
|
|
@@ -4509,7 +4513,7 @@ function ChoiceItem(_ref) {
|
|
|
4509
4513
|
},
|
|
4510
4514
|
onPressIn: onPressIn,
|
|
4511
4515
|
onPressOut: onPressOut,
|
|
4512
|
-
children: function (_ref2) {
|
|
4516
|
+
children: function children(_ref2) {
|
|
4513
4517
|
var isHovered = _ref2.isHovered,
|
|
4514
4518
|
isPressed = _ref2.isPressed;
|
|
4515
4519
|
var textColor = getCurrentTextColor$1({
|
|
@@ -4613,7 +4617,7 @@ function Choices(_ref2) {
|
|
|
4613
4617
|
type: type,
|
|
4614
4618
|
disabled: disabled,
|
|
4615
4619
|
onPress: !isForm ? onPress : undefined,
|
|
4616
|
-
onChange: isForm ? function (newValue) {
|
|
4620
|
+
onChange: isForm ? function handleChange(newValue) {
|
|
4617
4621
|
setCurrentValue(newValue);
|
|
4618
4622
|
if (onChange) onChange(newValue);
|
|
4619
4623
|
} : undefined,
|
|
@@ -4771,11 +4775,11 @@ function DialogModalAnimation(_ref) {
|
|
|
4771
4775
|
transparent: true,
|
|
4772
4776
|
supportedOrientations: ['landscape', 'portrait'],
|
|
4773
4777
|
visible: isModalVisible,
|
|
4774
|
-
onShow: function () {
|
|
4778
|
+
onShow: function onShow() {
|
|
4775
4779
|
if (onEnter) onEnter();
|
|
4776
4780
|
setIsContentVisible(true);
|
|
4777
4781
|
},
|
|
4778
|
-
onDismiss: function () {
|
|
4782
|
+
onDismiss: function onDismiss() {
|
|
4779
4783
|
if (onExited) onExited();
|
|
4780
4784
|
},
|
|
4781
4785
|
children: /*#__PURE__*/jsxs(View, {
|
|
@@ -4829,7 +4833,7 @@ function DialogModalBehaviour(_ref) {
|
|
|
4829
4833
|
},
|
|
4830
4834
|
children: /*#__PURE__*/jsx(DialogModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
4831
4835
|
visible: visible,
|
|
4832
|
-
onExited: function () {
|
|
4836
|
+
onExited: function handleExitAnimationDone() {
|
|
4833
4837
|
if (onExited) onExited();
|
|
4834
4838
|
setIsModalBehaviourVisible(false);
|
|
4835
4839
|
},
|
|
@@ -5092,7 +5096,7 @@ function ExternalLink(_ref) {
|
|
|
5092
5096
|
var openExternalLink = useOpenExternalLink();
|
|
5093
5097
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
5094
5098
|
return /*#__PURE__*/jsx(Component, _objectSpread(_objectSpread({}, rest), {}, {
|
|
5095
|
-
onPress: function (e) {
|
|
5099
|
+
onPress: function handleOnPress(e) {
|
|
5096
5100
|
if (onPress) {
|
|
5097
5101
|
onPress(e);
|
|
5098
5102
|
if (e.defaultPrevented) return;
|
|
@@ -5316,14 +5320,14 @@ var _excluded$z = ["children", "name", "disabled", "placeholder", "isInitialOpen
|
|
|
5316
5320
|
function patchNativeEvent(event) {
|
|
5317
5321
|
return event || {
|
|
5318
5322
|
preventDownshiftDefault: false,
|
|
5319
|
-
preventDefault: function () {}
|
|
5323
|
+
preventDefault: function preventDefault() {}
|
|
5320
5324
|
};
|
|
5321
5325
|
}
|
|
5322
5326
|
function isReactElement(element) {
|
|
5323
5327
|
return _typeof(element) === 'object' && element !== null && 'type' in element && 'props' in element;
|
|
5324
5328
|
}
|
|
5325
5329
|
function Autocomplete(_ref) {
|
|
5326
|
-
var
|
|
5330
|
+
var _children = _ref.children,
|
|
5327
5331
|
name = _ref.name,
|
|
5328
5332
|
disabled = _ref.disabled,
|
|
5329
5333
|
placeholder = _ref.placeholder,
|
|
@@ -5350,7 +5354,7 @@ function Autocomplete(_ref) {
|
|
|
5350
5354
|
zIndex = _ref$zIndex === void 0 ? 1000 : _ref$zIndex,
|
|
5351
5355
|
maxItemContainerHeight = _ref.maxItemContainerHeight,
|
|
5352
5356
|
props = _objectWithoutProperties(_ref, _excluded$z);
|
|
5353
|
-
var childrenArray = Children.toArray(
|
|
5357
|
+
var childrenArray = Children.toArray(_children);
|
|
5354
5358
|
var items = childrenArray.filter(isReactElement).map(function (child) {
|
|
5355
5359
|
return {
|
|
5356
5360
|
child: child,
|
|
@@ -5361,12 +5365,12 @@ function Autocomplete(_ref) {
|
|
|
5361
5365
|
defaultIsOpen: isInitialOpen,
|
|
5362
5366
|
initialSelectedItem: initialValue,
|
|
5363
5367
|
initialInputValue: initialValue ? itemToString(initialValue) : undefined,
|
|
5364
|
-
itemToString: function (item) {
|
|
5368
|
+
itemToString: function handleItemToString(item) {
|
|
5365
5369
|
// Prevents returning null values
|
|
5366
5370
|
if (!itemToString) return '';
|
|
5367
5371
|
return itemToString(item || undefined);
|
|
5368
5372
|
},
|
|
5369
|
-
stateReducer: function (state, changes) {
|
|
5373
|
+
stateReducer: function stateReducer(state, changes) {
|
|
5370
5374
|
switch (changes.type) {
|
|
5371
5375
|
case Downshift.stateChangeTypes.changeInput:
|
|
5372
5376
|
return _objectSpread(_objectSpread({}, changes), {}, {
|
|
@@ -5376,7 +5380,7 @@ function Autocomplete(_ref) {
|
|
|
5376
5380
|
return changes;
|
|
5377
5381
|
}
|
|
5378
5382
|
},
|
|
5379
|
-
onChange: function (selectedItem, stateAndHelpers) {
|
|
5383
|
+
onChange: function onChange(selectedItem, stateAndHelpers) {
|
|
5380
5384
|
if (_onChange) {
|
|
5381
5385
|
_onChange(selectedItem, stateAndHelpers);
|
|
5382
5386
|
}
|
|
@@ -5384,7 +5388,7 @@ function Autocomplete(_ref) {
|
|
|
5384
5388
|
onSelect: onSelectItem,
|
|
5385
5389
|
onOuterClick: onOuterPress,
|
|
5386
5390
|
onInputValueChange: onInputChange,
|
|
5387
|
-
children: function (_ref2) {
|
|
5391
|
+
children: function children(_ref2) {
|
|
5388
5392
|
var getRootProps = _ref2.getRootProps,
|
|
5389
5393
|
getInputProps = _ref2.getInputProps,
|
|
5390
5394
|
getMenuProps = _ref2.getMenuProps,
|
|
@@ -5436,7 +5440,7 @@ function Autocomplete(_ref) {
|
|
|
5436
5440
|
right: right || (canDisplayCollapseButton ? /*#__PURE__*/jsx(InputPressable, _objectSpread(_objectSpread({}, toggleProps), {}, {
|
|
5437
5441
|
testID: "kitt.Autocomplete.listToggle",
|
|
5438
5442
|
hitSlop: 40,
|
|
5439
|
-
onPress: function (e) {
|
|
5443
|
+
onPress: function handleTogglePress(e) {
|
|
5440
5444
|
if (Platform.OS === 'web') {
|
|
5441
5445
|
onClickToggle(e);
|
|
5442
5446
|
return;
|
|
@@ -5447,13 +5451,13 @@ function Autocomplete(_ref) {
|
|
|
5447
5451
|
icon: isCurrentlyOpen ? /*#__PURE__*/jsx(CaretUpFillIcon, {}) : /*#__PURE__*/jsx(CaretDownFillIcon, {})
|
|
5448
5452
|
})
|
|
5449
5453
|
})) : null),
|
|
5450
|
-
onFocus: function (e) {
|
|
5454
|
+
onFocus: function onFocus(e) {
|
|
5451
5455
|
openMenu();
|
|
5452
5456
|
/** @ts-expect-error onFocus wants web events */
|
|
5453
5457
|
if (Platform.OS !== 'android' && onSearchInputFocus) onSearchInputFocus(e);
|
|
5454
5458
|
if (_onFocus) _onFocus(e);
|
|
5455
5459
|
},
|
|
5456
|
-
onBlur: function (e) {
|
|
5460
|
+
onBlur: function onBlur(e) {
|
|
5457
5461
|
/** @ts-expect-error onBlur wants web events */
|
|
5458
5462
|
if (Platform.OS === 'web' && onSearchInputBlur) onSearchInputBlur(e);
|
|
5459
5463
|
|
|
@@ -5489,14 +5493,14 @@ function Autocomplete(_ref) {
|
|
|
5489
5493
|
selected: ariaSelected
|
|
5490
5494
|
},
|
|
5491
5495
|
disabled: disabled,
|
|
5492
|
-
onPress: function (e) {
|
|
5496
|
+
onPress: function onPress(e) {
|
|
5493
5497
|
if (Platform.OS === 'web') {
|
|
5494
5498
|
if (onClick) onClick(e);
|
|
5495
5499
|
return;
|
|
5496
5500
|
}
|
|
5497
5501
|
if (_onPress) _onPress(patchNativeEvent(e));
|
|
5498
5502
|
},
|
|
5499
|
-
children: function (_ref5) {
|
|
5503
|
+
children: function children(_ref5) {
|
|
5500
5504
|
var isHovered = _ref5.isHovered,
|
|
5501
5505
|
isFocused = _ref5.isFocused,
|
|
5502
5506
|
isPressed = _ref5.isPressed;
|
|
@@ -5586,12 +5590,12 @@ var Checkbox = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
5586
5590
|
disabled: disabled
|
|
5587
5591
|
},
|
|
5588
5592
|
disabled: disabled,
|
|
5589
|
-
onPress: function (e) {
|
|
5593
|
+
onPress: function handlePress(e) {
|
|
5590
5594
|
if (onFocus) onFocus();
|
|
5591
5595
|
if (onChange) onChange(!checked, e);
|
|
5592
5596
|
if (onBlur) onBlur();
|
|
5593
5597
|
},
|
|
5594
|
-
children: function (_ref2) {
|
|
5598
|
+
children: function children(_ref2) {
|
|
5595
5599
|
var isHovered = _ref2.isHovered,
|
|
5596
5600
|
isPressed = _ref2.isPressed,
|
|
5597
5601
|
isFocused = _ref2.isFocused;
|
|
@@ -6146,7 +6150,7 @@ var DatePickerAndroid = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6146
6150
|
DateTimePickerAndroid.open({
|
|
6147
6151
|
testID: pickerUITestID,
|
|
6148
6152
|
value: currentValue || pickerDefaultDate || new Date(Date.now()),
|
|
6149
|
-
onChange: function (e) {
|
|
6153
|
+
onChange: function onChange(e) {
|
|
6150
6154
|
setIsFocused(false);
|
|
6151
6155
|
var timestamp = e.nativeEvent.timestamp;
|
|
6152
6156
|
if (timestamp) {
|
|
@@ -6198,7 +6202,7 @@ function PlatformDateTimePicker(_ref) {
|
|
|
6198
6202
|
minimumDate: minimuDate,
|
|
6199
6203
|
display: displayMode
|
|
6200
6204
|
}, iosProps), {}, {
|
|
6201
|
-
onChange: function (_event, date) {
|
|
6205
|
+
onChange: function onChange(_event, date) {
|
|
6202
6206
|
return _onChange(date);
|
|
6203
6207
|
}
|
|
6204
6208
|
}));
|
|
@@ -6232,7 +6236,7 @@ function ModalPlatformDateTimePicker(_ref2) {
|
|
|
6232
6236
|
|
|
6233
6237
|
return /*#__PURE__*/jsx(CardModal.ModalBehaviour, {
|
|
6234
6238
|
visible: Boolean(isVisible),
|
|
6235
|
-
onClose: function () {
|
|
6239
|
+
onClose: function handleClose() {
|
|
6236
6240
|
setCurrentValue(value);
|
|
6237
6241
|
onClose();
|
|
6238
6242
|
},
|
|
@@ -6243,7 +6247,7 @@ function ModalPlatformDateTimePicker(_ref2) {
|
|
|
6243
6247
|
}) : null, /*#__PURE__*/jsx(CardModal.Body, {
|
|
6244
6248
|
children: /*#__PURE__*/jsx(PlatformDateTimePicker, _objectSpread(_objectSpread({}, props), {}, {
|
|
6245
6249
|
value: currentValue,
|
|
6246
|
-
onChange: function (newDate) {
|
|
6250
|
+
onChange: function handleChange(newDate) {
|
|
6247
6251
|
setCurrentValue(function (prev) {
|
|
6248
6252
|
return newDate || prev;
|
|
6249
6253
|
});
|
|
@@ -6253,7 +6257,7 @@ function ModalPlatformDateTimePicker(_ref2) {
|
|
|
6253
6257
|
children: /*#__PURE__*/jsx(Button, {
|
|
6254
6258
|
stretch: true,
|
|
6255
6259
|
type: "primary",
|
|
6256
|
-
onPress: function () {
|
|
6260
|
+
onPress: function handleSubmit() {
|
|
6257
6261
|
onChange(currentValue);
|
|
6258
6262
|
},
|
|
6259
6263
|
children: validateButtonLabel ? /*#__PURE__*/jsx(Text$1, {
|
|
@@ -6307,7 +6311,7 @@ var DefaultNativeUIDatePicker = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6307
6311
|
isFocusedInternal: isFocused || isFocusedInternal,
|
|
6308
6312
|
isHoveredInternal: isHoveredInternal,
|
|
6309
6313
|
isPressedInternal: isPressedInternal,
|
|
6310
|
-
onPress: function () {
|
|
6314
|
+
onPress: function handleModalOpen() {
|
|
6311
6315
|
if (onFocus) onFocus();
|
|
6312
6316
|
setIsPickerUIVisible(true);
|
|
6313
6317
|
setIsFocused(true);
|
|
@@ -6320,7 +6324,7 @@ var DefaultNativeUIDatePicker = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6320
6324
|
validateButtonLabel: pickerUIValidateButtonLabel,
|
|
6321
6325
|
defaultDate: pickerDefaultDate,
|
|
6322
6326
|
onClose: handleModalClose,
|
|
6323
|
-
onChange: function (newDate) {
|
|
6327
|
+
onChange: function handleChange(newDate) {
|
|
6324
6328
|
setCurrentValue(newDate);
|
|
6325
6329
|
onChange(newDate);
|
|
6326
6330
|
handleModalClose();
|
|
@@ -6636,7 +6640,7 @@ function FilePicker(_ref) {
|
|
|
6636
6640
|
return /*#__PURE__*/jsxs(Fragment, {
|
|
6637
6641
|
children: [/*#__PURE__*/cloneElement(childElement, {
|
|
6638
6642
|
// ensure that the press event is not prevented by Button component
|
|
6639
|
-
onPress: function () {
|
|
6643
|
+
onPress: function onPress() {
|
|
6640
6644
|
var _childElement$props$o, _childElement$props, _bottomSheetRef$curre;
|
|
6641
6645
|
if (disabled) return;
|
|
6642
6646
|
(_childElement$props$o = (_childElement$props = childElement.props).onPress) === null || _childElement$props$o === void 0 || _childElement$props$o.call(_childElement$props);
|
|
@@ -6937,10 +6941,10 @@ var GoogleMapsAutocompleteContext = /*#__PURE__*/createContext({
|
|
|
6937
6941
|
isLoadingResultDetails: false,
|
|
6938
6942
|
shouldDisplayEmptyStateWhenNoResults: false
|
|
6939
6943
|
},
|
|
6940
|
-
onInputChange: function () {
|
|
6944
|
+
onInputChange: function onInputChange() {
|
|
6941
6945
|
return Promise.resolve();
|
|
6942
6946
|
},
|
|
6943
|
-
onSelectItem: function () {}
|
|
6947
|
+
onSelectItem: function onSelectItem() {}
|
|
6944
6948
|
});
|
|
6945
6949
|
function GoogleMapsAutocompleteProvider(_ref) {
|
|
6946
6950
|
var children = _ref.children,
|
|
@@ -7193,7 +7197,7 @@ function InputAddress(_ref) {
|
|
|
7193
7197
|
return /*#__PURE__*/jsx(Autocomplete, _objectSpread(_objectSpread({}, props), {}, {
|
|
7194
7198
|
itemToString: itemToString,
|
|
7195
7199
|
initialValue: formattedInitialValue,
|
|
7196
|
-
checkSelectedItem: function (selectedItem, item) {
|
|
7200
|
+
checkSelectedItem: function checkSelectedItem(selectedItem, item) {
|
|
7197
7201
|
return (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.place_id) === item.place_id;
|
|
7198
7202
|
},
|
|
7199
7203
|
right: state.isLoadingSearch || state.isLoadingResultDetails ? /*#__PURE__*/jsx(Icon, {
|
|
@@ -7202,10 +7206,10 @@ function InputAddress(_ref) {
|
|
|
7202
7206
|
}) : undefined,
|
|
7203
7207
|
errorElement: state.hasSearchError || state.hasSelectResultError ? errorElement : null,
|
|
7204
7208
|
emptyResultsElement: state.items.length === 0 ? emptyResultsElement : null,
|
|
7205
|
-
onInputChange: function (v) {
|
|
7209
|
+
onInputChange: function onInputChange(v) {
|
|
7206
7210
|
_onInputChange(v);
|
|
7207
7211
|
},
|
|
7208
|
-
onChange: function (v) {
|
|
7212
|
+
onChange: function onChange(v) {
|
|
7209
7213
|
onSelectItem(v, _onChange);
|
|
7210
7214
|
},
|
|
7211
7215
|
children: state.items.map(function (item) {
|
|
@@ -7287,7 +7291,7 @@ var InputNumber = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7287
7291
|
ref: ref
|
|
7288
7292
|
}, props), {}, {
|
|
7289
7293
|
inputMode: "numeric",
|
|
7290
|
-
onChange: function (event) {
|
|
7294
|
+
onChange: function handleChange(event) {
|
|
7291
7295
|
if (!onChange) return;
|
|
7292
7296
|
var value = parseFloat(event.nativeEvent.text);
|
|
7293
7297
|
|
|
@@ -7319,7 +7323,7 @@ var InputPassword = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7319
7323
|
testID: "kitt.InputPassword.passwordToggle",
|
|
7320
7324
|
hitSlop: 20,
|
|
7321
7325
|
accessibilityRole: "button",
|
|
7322
|
-
onPress: function () {
|
|
7326
|
+
onPress: function onPress() {
|
|
7323
7327
|
return setIsVisible(function (prev) {
|
|
7324
7328
|
return !prev;
|
|
7325
7329
|
});
|
|
@@ -7354,7 +7358,7 @@ var InputPhone = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7354
7358
|
enterKeyHint: currentEnterKeyHint,
|
|
7355
7359
|
autoComplete: autoComplete,
|
|
7356
7360
|
textContentType: "telephoneNumber",
|
|
7357
|
-
onChange: function (event) {
|
|
7361
|
+
onChange: function handleChange(event) {
|
|
7358
7362
|
var number = parseNumber(event.nativeEvent.text);
|
|
7359
7363
|
|
|
7360
7364
|
// When intl phone number is valid :
|
|
@@ -7547,14 +7551,14 @@ function Radio(_ref, ref) {
|
|
|
7547
7551
|
focusable: checked && !disabled,
|
|
7548
7552
|
flexDirection: "row",
|
|
7549
7553
|
alignItems: "center",
|
|
7550
|
-
onPress: function (event) {
|
|
7554
|
+
onPress: function handlePress(event) {
|
|
7551
7555
|
if (onFocus) onFocus();
|
|
7552
7556
|
if (onChange) onChange(value, event);
|
|
7553
7557
|
if (onBlur) onBlur();
|
|
7554
7558
|
},
|
|
7555
7559
|
onFocus: onFocus,
|
|
7556
7560
|
onBlur: onBlur,
|
|
7557
|
-
children: function (_ref2) {
|
|
7561
|
+
children: function children(_ref2) {
|
|
7558
7562
|
var isHovered = _ref2.isHovered,
|
|
7559
7563
|
isPressed = _ref2.isPressed,
|
|
7560
7564
|
isFocused = _ref2.isFocused;
|
|
@@ -7673,11 +7677,11 @@ var useNativeAnimation$2 = function (_ref) {
|
|
|
7673
7677
|
};
|
|
7674
7678
|
});
|
|
7675
7679
|
return {
|
|
7676
|
-
onPressIn: function () {
|
|
7680
|
+
onPressIn: function handlePressIn() {
|
|
7677
7681
|
color.value = withSpring(1);
|
|
7678
7682
|
pressed.value = 1;
|
|
7679
7683
|
},
|
|
7680
|
-
onPressOut: function () {
|
|
7684
|
+
onPressOut: function handlePressOut() {
|
|
7681
7685
|
color.value = withSpring(0);
|
|
7682
7686
|
pressed.value = 0;
|
|
7683
7687
|
},
|
|
@@ -7730,7 +7734,7 @@ function RadioButton(_ref) {
|
|
|
7730
7734
|
flexShrink: createResponsiveStyleFromProp(stretch, 1, undefined),
|
|
7731
7735
|
flexBasis: createResponsiveStyleFromProp(stretch, 0),
|
|
7732
7736
|
disabled: disabled,
|
|
7733
|
-
onPress: function (e) {
|
|
7737
|
+
onPress: function handlePress(e) {
|
|
7734
7738
|
if (onFocus) onFocus(e);
|
|
7735
7739
|
if (onChange) onChange(value);
|
|
7736
7740
|
if (onBlur) onBlur(e);
|
|
@@ -7739,7 +7743,7 @@ function RadioButton(_ref) {
|
|
|
7739
7743
|
onPressOut: onPressOut,
|
|
7740
7744
|
onFocus: onFocus,
|
|
7741
7745
|
onBlur: onBlur,
|
|
7742
|
-
children: function (_ref2) {
|
|
7746
|
+
children: function children(_ref2) {
|
|
7743
7747
|
var isHovered = _ref2.isHovered,
|
|
7744
7748
|
isPressed = _ref2.isPressed,
|
|
7745
7749
|
isFocused = _ref2.isFocused;
|
|
@@ -7858,7 +7862,7 @@ var TextArea = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7858
7862
|
textAlignVertical: "top",
|
|
7859
7863
|
minHeight: "kitt.forms.textArea.minHeight"
|
|
7860
7864
|
}, props), {}, {
|
|
7861
|
-
onChange: function (e) {
|
|
7865
|
+
onChange: function handleOnChange(e) {
|
|
7862
7866
|
if (!limit || e.nativeEvent.text.length <= limit) {
|
|
7863
7867
|
var _props$onChange;
|
|
7864
7868
|
(_props$onChange = props.onChange) === null || _props$onChange === void 0 || _props$onChange.call(props, e);
|
|
@@ -8021,10 +8025,10 @@ function Toggle(_ref) {
|
|
|
8021
8025
|
children: [/*#__PURE__*/jsx(Pressable, {
|
|
8022
8026
|
accessibilityRole: "togglebutton",
|
|
8023
8027
|
disabled: isDisabled,
|
|
8024
|
-
onPress: function () {
|
|
8028
|
+
onPress: function handlePress() {
|
|
8025
8029
|
onChange(!value);
|
|
8026
8030
|
},
|
|
8027
|
-
children: function (_ref2) {
|
|
8031
|
+
children: function children(_ref2) {
|
|
8028
8032
|
var isHovered = _ref2.isHovered,
|
|
8029
8033
|
isPressed = _ref2.isPressed,
|
|
8030
8034
|
isFocused = _ref2.isFocused;
|
|
@@ -8213,11 +8217,11 @@ function FullscreenModalAnimation(_ref) {
|
|
|
8213
8217
|
transparent: true,
|
|
8214
8218
|
supportedOrientations: ['landscape', 'portrait'],
|
|
8215
8219
|
visible: isModalVisible,
|
|
8216
|
-
onShow: function () {
|
|
8220
|
+
onShow: function onShow() {
|
|
8217
8221
|
if (onEnter) onEnter();
|
|
8218
8222
|
setIsContentVisible(true);
|
|
8219
8223
|
},
|
|
8220
|
-
onDismiss: function () {
|
|
8224
|
+
onDismiss: function onDismiss() {
|
|
8221
8225
|
if (onExited) onExited();
|
|
8222
8226
|
},
|
|
8223
8227
|
children: /*#__PURE__*/jsxs(View, {
|
|
@@ -8264,7 +8268,7 @@ function FullscreenModalBehaviour(_ref) {
|
|
|
8264
8268
|
onClose: onClose,
|
|
8265
8269
|
children: /*#__PURE__*/jsx(FullscreenModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
8266
8270
|
visible: visible,
|
|
8267
|
-
onExited: function () {
|
|
8271
|
+
onExited: function handleExitAnimationDone() {
|
|
8268
8272
|
if (onExited) onExited();
|
|
8269
8273
|
setIsModalBehaviourVisible(false);
|
|
8270
8274
|
},
|
|
@@ -8427,12 +8431,15 @@ function AnimatedCaret(_ref) {
|
|
|
8427
8431
|
function AnimatedContainer(_ref) {
|
|
8428
8432
|
var children = _ref.children,
|
|
8429
8433
|
size = _ref.size,
|
|
8430
|
-
animatedStyles = _ref.animatedStyles
|
|
8434
|
+
animatedStyles = _ref.animatedStyles,
|
|
8435
|
+
variant = _ref.variant;
|
|
8431
8436
|
var sx = useSx();
|
|
8432
8437
|
var theme = useTheme();
|
|
8433
8438
|
var styles = sx({
|
|
8434
8439
|
borderRadius: theme.kitt.highlight.borderRadius,
|
|
8435
|
-
padding: theme.kitt.highlight.padding[size]
|
|
8440
|
+
padding: theme.kitt.highlight.padding[size],
|
|
8441
|
+
borderWidth: theme.kitt.highlight[variant]["default"].borderWidth,
|
|
8442
|
+
borderColor: theme.kitt.highlight[variant]["default"].borderColor
|
|
8436
8443
|
});
|
|
8437
8444
|
return /*#__PURE__*/jsx(Animated.View, {
|
|
8438
8445
|
style: [styles, animatedStyles],
|
|
@@ -8491,11 +8498,11 @@ var useNativeAnimation$1 = function (_ref) {
|
|
|
8491
8498
|
};
|
|
8492
8499
|
});
|
|
8493
8500
|
return {
|
|
8494
|
-
onPressIn: function () {
|
|
8501
|
+
onPressIn: function handleHoverIn() {
|
|
8495
8502
|
color.value = withTiming(1, withTimingConfig);
|
|
8496
8503
|
translate.value = withTiming(2, withTimingConfig);
|
|
8497
8504
|
},
|
|
8498
|
-
onPressOut: function () {
|
|
8505
|
+
onPressOut: function handleHoverOut() {
|
|
8499
8506
|
color.value = withTiming(0, withTimingConfig);
|
|
8500
8507
|
translate.value = withTiming(0, withTimingConfig);
|
|
8501
8508
|
},
|
|
@@ -8566,6 +8573,8 @@ function Highlight(_ref) {
|
|
|
8566
8573
|
borderRadius: "kitt.highlight.borderRadius",
|
|
8567
8574
|
padding: theme.kitt.highlight.padding[size],
|
|
8568
8575
|
backgroundColor: "kitt.highlight.".concat(variant, ".default.backgroundColor"),
|
|
8576
|
+
borderWidth: theme.kitt.highlight[variant]["default"].borderWidth,
|
|
8577
|
+
borderColor: theme.kitt.highlight[variant]["default"].borderColor,
|
|
8569
8578
|
children: /*#__PURE__*/jsxs(HStack, {
|
|
8570
8579
|
space: highlightStyle[size].spaceBetween,
|
|
8571
8580
|
children: [icon && /*#__PURE__*/jsx(View, {
|
|
@@ -8587,13 +8596,13 @@ function Highlight(_ref) {
|
|
|
8587
8596
|
});
|
|
8588
8597
|
}
|
|
8589
8598
|
return /*#__PURE__*/jsx(Pressable, {
|
|
8590
|
-
onPress: function () {
|
|
8599
|
+
onPress: function handlePress() {
|
|
8591
8600
|
setIsExpanded(!isExpanded);
|
|
8592
8601
|
setIsInitialRender(false);
|
|
8593
8602
|
},
|
|
8594
8603
|
onPressIn: onPressIn,
|
|
8595
8604
|
onPressOut: onPressOut,
|
|
8596
|
-
children: function (_ref2) {
|
|
8605
|
+
children: function children(_ref2) {
|
|
8597
8606
|
var isHovered = _ref2.isHovered;
|
|
8598
8607
|
return /*#__PURE__*/jsxs(AnimatedContainer, {
|
|
8599
8608
|
isHovered: isHovered,
|
|
@@ -8985,7 +8994,7 @@ function MapMarker(_ref2) {
|
|
|
8985
8994
|
return /*#__PURE__*/jsx(Pressable$1, {
|
|
8986
8995
|
testID: testID,
|
|
8987
8996
|
onPress: onPress,
|
|
8988
|
-
children: function (_ref3) {
|
|
8997
|
+
children: function children(_ref3) {
|
|
8989
8998
|
var isHovered = _ref3.isHovered;
|
|
8990
8999
|
return /*#__PURE__*/jsx(StaticMapMarker$1, _objectSpread(_objectSpread({}, props), {}, {
|
|
8991
9000
|
isHovered: isHovered
|
|
@@ -9021,6 +9030,8 @@ var getColorByType = function (type) {
|
|
|
9021
9030
|
switch (type) {
|
|
9022
9031
|
case 'success':
|
|
9023
9032
|
case 'danger':
|
|
9033
|
+
case 'info':
|
|
9034
|
+
return 'white';
|
|
9024
9035
|
case 'warning':
|
|
9025
9036
|
default:
|
|
9026
9037
|
return 'black';
|
|
@@ -9030,6 +9041,8 @@ var getIconButtonColor = function (messageType) {
|
|
|
9030
9041
|
switch (messageType) {
|
|
9031
9042
|
case 'success':
|
|
9032
9043
|
case 'danger':
|
|
9044
|
+
case 'info':
|
|
9045
|
+
return 'ghost';
|
|
9033
9046
|
case 'warning':
|
|
9034
9047
|
default:
|
|
9035
9048
|
return 'black';
|
|
@@ -9050,7 +9063,7 @@ function BaseMessage(_ref) {
|
|
|
9050
9063
|
justifyContent: "space-between",
|
|
9051
9064
|
minHeight: "kitt.feedbackMessage.minHeight",
|
|
9052
9065
|
paddingTop: insets === null || insets === void 0 ? void 0 : insets.top,
|
|
9053
|
-
borderRadius: hasNoRadius ? undefined : 'kitt.
|
|
9066
|
+
borderRadius: hasNoRadius ? undefined : 'kitt.2',
|
|
9054
9067
|
backgroundColor: "kitt.feedbackMessage.".concat(type, ".backgroundColor"),
|
|
9055
9068
|
children: [/*#__PURE__*/jsxs(HStack, {
|
|
9056
9069
|
flexGrow: 1,
|
|
@@ -9058,9 +9071,9 @@ function BaseMessage(_ref) {
|
|
|
9058
9071
|
alignSelf: "center",
|
|
9059
9072
|
alignItems: "flex-start",
|
|
9060
9073
|
paddingY: "kitt.4",
|
|
9061
|
-
paddingX: "kitt.
|
|
9074
|
+
paddingX: "kitt.4",
|
|
9062
9075
|
children: [centeredText ? null : /*#__PURE__*/jsx(View, {
|
|
9063
|
-
marginRight: "kitt.
|
|
9076
|
+
marginRight: "kitt.2",
|
|
9064
9077
|
children: /*#__PURE__*/jsx(Icon, {
|
|
9065
9078
|
color: color,
|
|
9066
9079
|
icon: /*#__PURE__*/jsx(IconContent, {
|
|
@@ -11572,19 +11585,19 @@ function NavigationModalBehaviour(_ref) {
|
|
|
11572
11585
|
children: /*#__PURE__*/jsx(AnimationComponent, _objectSpread(_objectSpread({}, props), {}, {
|
|
11573
11586
|
appear: shouldAppear,
|
|
11574
11587
|
visible: visible,
|
|
11575
|
-
onEnter: function () {
|
|
11588
|
+
onEnter: function handleEnter() {
|
|
11576
11589
|
if (onEnter) onEnter();
|
|
11577
11590
|
|
|
11578
11591
|
// Once a children as been displayed, we force appear to false in order to avoid replaying animation on breakpoint change
|
|
11579
11592
|
setShouldAppear(false);
|
|
11580
11593
|
},
|
|
11581
|
-
onExit: function () {
|
|
11594
|
+
onExit: function handleExit() {
|
|
11582
11595
|
if (onExit) onExit();
|
|
11583
11596
|
|
|
11584
11597
|
// Reset appear value to its original value for future modal display
|
|
11585
11598
|
setShouldAppear(appear);
|
|
11586
11599
|
},
|
|
11587
|
-
onExited: function () {
|
|
11600
|
+
onExited: function handleExitAnimationDone() {
|
|
11588
11601
|
if (onExited) onExited();
|
|
11589
11602
|
setIsModalBehaviourVisible(false);
|
|
11590
11603
|
},
|
|
@@ -11945,7 +11958,7 @@ function Picker(_ref) {
|
|
|
11945
11958
|
isOpen: state.isOpen,
|
|
11946
11959
|
selectedItem: state.currentValue,
|
|
11947
11960
|
disabled: disabled,
|
|
11948
|
-
onPress: function () {
|
|
11961
|
+
onPress: function handlePressTrigger() {
|
|
11949
11962
|
if (syncStateWithSourceValue) {
|
|
11950
11963
|
dispatch({
|
|
11951
11964
|
type: 'open-modal-with-value',
|
|
@@ -11999,7 +12012,7 @@ function Picker(_ref) {
|
|
|
11999
12012
|
accessibilityState: {
|
|
12000
12013
|
selected: isSelected
|
|
12001
12014
|
},
|
|
12002
|
-
onPress: function () {
|
|
12015
|
+
onPress: function onPress() {
|
|
12003
12016
|
handleInternalChange(item.props.value);
|
|
12004
12017
|
},
|
|
12005
12018
|
children: function (_ref2) {
|
|
@@ -12020,7 +12033,7 @@ function Picker(_ref) {
|
|
|
12020
12033
|
children: /*#__PURE__*/jsx(Button, {
|
|
12021
12034
|
stretch: true,
|
|
12022
12035
|
type: "primary",
|
|
12023
|
-
onPress: function () {
|
|
12036
|
+
onPress: function handleChange() {
|
|
12024
12037
|
if (onChange) onChange(state.internalValue);
|
|
12025
12038
|
dispatch({
|
|
12026
12039
|
type: 'change-value'
|
|
@@ -12157,7 +12170,7 @@ function Skeleton(_ref) {
|
|
|
12157
12170
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
12158
12171
|
overflow: "hidden",
|
|
12159
12172
|
style: style,
|
|
12160
|
-
onLayout: function (_ref2) {
|
|
12173
|
+
onLayout: function onLayout(_ref2) {
|
|
12161
12174
|
var nativeEvent = _ref2.nativeEvent;
|
|
12162
12175
|
return setWidth(nativeEvent.layout.width);
|
|
12163
12176
|
},
|
|
@@ -12379,7 +12392,7 @@ function StaticMap(_ref) {
|
|
|
12379
12392
|
position: "relative",
|
|
12380
12393
|
maxWidth: mapBoxMaxPictureWidth,
|
|
12381
12394
|
height: height,
|
|
12382
|
-
onLayout: function (event) {
|
|
12395
|
+
onLayout: function handleParentLayout(event) {
|
|
12383
12396
|
var nativeEvent = event.nativeEvent;
|
|
12384
12397
|
var rangedMapWidth = getPictureWidth(nativeEvent.layout.width);
|
|
12385
12398
|
setCurrentWidth(rangedMapWidth);
|
|
@@ -12391,11 +12404,11 @@ function StaticMap(_ref) {
|
|
|
12391
12404
|
width: currentWidth,
|
|
12392
12405
|
height: height,
|
|
12393
12406
|
alt: alt,
|
|
12394
|
-
onLoadEnd: function () {
|
|
12407
|
+
onLoadEnd: function handleImageLoadEnd() {
|
|
12395
12408
|
setIsLoading(false);
|
|
12396
12409
|
if (onLoaded) onLoaded();
|
|
12397
12410
|
},
|
|
12398
|
-
onError: function () {
|
|
12411
|
+
onError: function handleError() {
|
|
12399
12412
|
setHasError(true);
|
|
12400
12413
|
if (onError) onError();
|
|
12401
12414
|
}
|
|
@@ -12420,7 +12433,7 @@ function StaticMap(_ref) {
|
|
|
12420
12433
|
width: "100%",
|
|
12421
12434
|
height: "100%",
|
|
12422
12435
|
children: /*#__PURE__*/jsx(StaticMapError, {
|
|
12423
|
-
onReload: function () {
|
|
12436
|
+
onReload: function handleReload() {
|
|
12424
12437
|
setHasError(false);
|
|
12425
12438
|
setIsLoading(true);
|
|
12426
12439
|
setCurrentMapKey(function (prev) {
|
|
@@ -12661,7 +12674,7 @@ function StoryContainer(_ref) {
|
|
|
12661
12674
|
var StoryDecorator = makeDecorator({
|
|
12662
12675
|
name: 'StoryDecorator',
|
|
12663
12676
|
parameterName: 'storyDecorator',
|
|
12664
|
-
wrapper: function (storyFn, context) {
|
|
12677
|
+
wrapper: function wrapper(storyFn, context) {
|
|
12665
12678
|
var story = storyFn(context);
|
|
12666
12679
|
if (context.parameters.disableStoryContainer) {
|
|
12667
12680
|
return story;
|
|
@@ -12846,7 +12859,7 @@ function TabBar(_ref) {
|
|
|
12846
12859
|
return /*#__PURE__*/jsx(View, {
|
|
12847
12860
|
children: /*#__PURE__*/cloneElement(child, {
|
|
12848
12861
|
color: color,
|
|
12849
|
-
onPress: function (event) {
|
|
12862
|
+
onPress: function onPress(event) {
|
|
12850
12863
|
var _child$props$onPress, _child$props;
|
|
12851
12864
|
onChangeTab({
|
|
12852
12865
|
tab: tabs[index],
|
|
@@ -12995,7 +13008,7 @@ function ModalDateTimePicker(_ref) {
|
|
|
12995
13008
|
stretch: true,
|
|
12996
13009
|
testID: "timePicker.ModalDateTimePicker.submitButton",
|
|
12997
13010
|
type: "primary",
|
|
12998
|
-
onPress: function () {
|
|
13011
|
+
onPress: function handleSubmit() {
|
|
12999
13012
|
onChange(currentValue);
|
|
13000
13013
|
},
|
|
13001
13014
|
children: buttonContent
|
|
@@ -13042,7 +13055,7 @@ var TimePickerPressable = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
13042
13055
|
width: createResponsiveStyleFromProp(stretch, '100%', 'kitt.forms.timePicker.minWidth'),
|
|
13043
13056
|
pointerEvents: "box-only",
|
|
13044
13057
|
onPress: onPress,
|
|
13045
|
-
children: function (_ref2) {
|
|
13058
|
+
children: function children(_ref2) {
|
|
13046
13059
|
var isHovered = _ref2.isHovered,
|
|
13047
13060
|
isFocused = _ref2.isFocused,
|
|
13048
13061
|
isPressed = _ref2.isPressed;
|
|
@@ -13119,7 +13132,7 @@ var TimePicker = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
13119
13132
|
isHoveredInternal: isHoveredInternal,
|
|
13120
13133
|
isFocusedInternal: isFocusedInternal,
|
|
13121
13134
|
isPressedInternal: isPressedInternal,
|
|
13122
|
-
onPress: function () {
|
|
13135
|
+
onPress: function handlePress() {
|
|
13123
13136
|
setIsPickerVisible(true);
|
|
13124
13137
|
}
|
|
13125
13138
|
}), Platform.OS === 'android' && isPickerVisible ? /*#__PURE__*/jsx(DateTimePicker, {
|
|
@@ -13143,7 +13156,7 @@ var TimePicker = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
13143
13156
|
value: pickerValue,
|
|
13144
13157
|
validateButtonLabel: validateButtonLabel,
|
|
13145
13158
|
onChange: handleChange,
|
|
13146
|
-
onClose: function () {
|
|
13159
|
+
onClose: function handleClose() {
|
|
13147
13160
|
setIsPickerVisible(false);
|
|
13148
13161
|
}
|
|
13149
13162
|
}) : null]
|
|
@@ -13506,7 +13519,7 @@ function Tooltip(_ref) {
|
|
|
13506
13519
|
ref: reference,
|
|
13507
13520
|
children: renderPressable({
|
|
13508
13521
|
ref: getPressableRect,
|
|
13509
|
-
onPress: function () {
|
|
13522
|
+
onPress: function handlePress() {
|
|
13510
13523
|
if (onToggle) onToggle(!!pressed.value);
|
|
13511
13524
|
pressed.value = !pressed.value;
|
|
13512
13525
|
},
|
|
@@ -13525,7 +13538,7 @@ function Tooltip(_ref) {
|
|
|
13525
13538
|
left: customShiftData.left,
|
|
13526
13539
|
right: customShiftData.right,
|
|
13527
13540
|
zIndex: zIndex,
|
|
13528
|
-
onLayout: function (_ref2) {
|
|
13541
|
+
onLayout: function onLayout(_ref2) {
|
|
13529
13542
|
var nativeEvent = _ref2.nativeEvent;
|
|
13530
13543
|
return setFloatingWidth(nativeEvent.layout.width);
|
|
13531
13544
|
},
|
|
@@ -13688,7 +13701,7 @@ function KittThemeProvider(_ref) {
|
|
|
13688
13701
|
var KittThemeDecorator = makeDecorator({
|
|
13689
13702
|
name: 'ThemeDecorator',
|
|
13690
13703
|
parameterName: 'theme',
|
|
13691
|
-
wrapper: function (storyFn, context, _ref2) {
|
|
13704
|
+
wrapper: function wrapper(storyFn, context, _ref2) {
|
|
13692
13705
|
var _parameters$isSSR;
|
|
13693
13706
|
var _ref2$options = _ref2.options,
|
|
13694
13707
|
options = _ref2$options === void 0 ? {} : _ref2$options,
|