@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.web.js
CHANGED
|
@@ -757,7 +757,7 @@ var webAnimationOverlayEasing$2 = [0.42, 0, 1, 1];
|
|
|
757
757
|
var maxWidth = 540;
|
|
758
758
|
var overlayHorizontalPadding = 24;
|
|
759
759
|
var cardModal = {
|
|
760
|
-
borderRadius:
|
|
760
|
+
borderRadius: spacing * 2,
|
|
761
761
|
maxWidth: maxWidth,
|
|
762
762
|
maxWidthWithPadding: maxWidth + overlayHorizontalPadding * 2,
|
|
763
763
|
minHeight: 280,
|
|
@@ -849,7 +849,7 @@ var webAnimationContentEasing$1 = [0.77, 0, 0.175, 1];
|
|
|
849
849
|
var webAnimationOverlayDuration$1 = 250;
|
|
850
850
|
var webAnimationOverlayEasing$1 = [0.42, 0, 1, 1];
|
|
851
851
|
var dialogModal = {
|
|
852
|
-
borderRadius:
|
|
852
|
+
borderRadius: spacing * 2,
|
|
853
853
|
maxWidth: 540,
|
|
854
854
|
overlayPadding: {
|
|
855
855
|
horizontal: 24,
|
|
@@ -1818,10 +1818,10 @@ var highlight = {
|
|
|
1818
1818
|
},
|
|
1819
1819
|
primary: {
|
|
1820
1820
|
"default": {
|
|
1821
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1821
|
+
backgroundColor: deepPurpleColorPalette['blue.1']
|
|
1822
1822
|
},
|
|
1823
1823
|
hover: {
|
|
1824
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1824
|
+
backgroundColor: deepPurpleColorPalette['blue.2']
|
|
1825
1825
|
}
|
|
1826
1826
|
},
|
|
1827
1827
|
secondary: {
|
|
@@ -1842,10 +1842,14 @@ var highlight = {
|
|
|
1842
1842
|
},
|
|
1843
1843
|
dark: {
|
|
1844
1844
|
"default": {
|
|
1845
|
-
backgroundColor: deepPurpleColorPalette['
|
|
1845
|
+
backgroundColor: deepPurpleColorPalette['grey.0'],
|
|
1846
|
+
borderWidth: 1,
|
|
1847
|
+
borderColor: deepPurpleColorPalette['beige.3']
|
|
1846
1848
|
},
|
|
1847
1849
|
hover: {
|
|
1848
|
-
backgroundColor: deepPurpleColorPalette['beige.1']
|
|
1850
|
+
backgroundColor: deepPurpleColorPalette['beige.1'],
|
|
1851
|
+
borderWidth: 1,
|
|
1852
|
+
borderColor: deepPurpleColorPalette['beige.3']
|
|
1849
1853
|
}
|
|
1850
1854
|
},
|
|
1851
1855
|
success: {
|
|
@@ -2448,7 +2452,7 @@ var breakpoints = {
|
|
|
2448
2452
|
// TODO : seperate brand color usage definition from proper theme definition and add typings - https://ornikar.atlassian.net/browse/CME-156
|
|
2449
2453
|
var theme = {
|
|
2450
2454
|
spacing: spacing,
|
|
2451
|
-
getSpacing: function (multiplier) {
|
|
2455
|
+
getSpacing: function getSpacing(multiplier) {
|
|
2452
2456
|
return spacing * multiplier;
|
|
2453
2457
|
},
|
|
2454
2458
|
colors: colors,
|
|
@@ -2635,7 +2639,7 @@ var ActionCardPressable = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
2635
2639
|
onPress: onPress,
|
|
2636
2640
|
onHoverIn: onHoverIn,
|
|
2637
2641
|
onHoverOut: onHoverOut,
|
|
2638
|
-
children: function (_ref3) {
|
|
2642
|
+
children: function children(_ref3) {
|
|
2639
2643
|
var isHovered = _ref3.isHovered,
|
|
2640
2644
|
isPressed = _ref3.isPressed,
|
|
2641
2645
|
isFocused = _ref3.isFocused;
|
|
@@ -3476,7 +3480,7 @@ var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
3476
3480
|
onHoverOut: onHoverOut,
|
|
3477
3481
|
onFocus: onFocus,
|
|
3478
3482
|
onBlur: onBlur,
|
|
3479
|
-
children: function (_ref2) {
|
|
3483
|
+
children: function children(_ref2) {
|
|
3480
3484
|
var isHovered = _ref2.isHovered,
|
|
3481
3485
|
isPressed = _ref2.isPressed,
|
|
3482
3486
|
isFocused = _ref2.isFocused;
|
|
@@ -3573,7 +3577,7 @@ var ActionsItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
3573
3577
|
stretch: stretch,
|
|
3574
3578
|
disabled: isLoading ? true : disabled,
|
|
3575
3579
|
icon: isLoading ? /*#__PURE__*/jsx(LoaderIcon, {}) : icon,
|
|
3576
|
-
onPress: function (e) {
|
|
3580
|
+
onPress: function handlePress(e) {
|
|
3577
3581
|
var callPressAndUpdateLoadingState = /*#__PURE__*/function () {
|
|
3578
3582
|
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
3579
3583
|
return _regeneratorRuntime().wrap(function (_context) {
|
|
@@ -3902,7 +3906,7 @@ function CloseButton(_ref) {
|
|
|
3902
3906
|
onPress = _ref.onPress;
|
|
3903
3907
|
var onCloseContextCallback = useOnCloseModalBehaviour();
|
|
3904
3908
|
return /*#__PURE__*/cloneElement(children, {
|
|
3905
|
-
onPress: function () {
|
|
3909
|
+
onPress: function handleClose() {
|
|
3906
3910
|
if (onPress) onPress();
|
|
3907
3911
|
onCloseContextCallback();
|
|
3908
3912
|
}
|
|
@@ -4052,7 +4056,7 @@ function CardModalBehaviour(_ref) {
|
|
|
4052
4056
|
onClose: onClose,
|
|
4053
4057
|
children: /*#__PURE__*/jsx(CardModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
4054
4058
|
visible: visible,
|
|
4055
|
-
onExited: function () {
|
|
4059
|
+
onExited: function handleExitAnimationDone() {
|
|
4056
4060
|
if (onExited) onExited();
|
|
4057
4061
|
setIsModalBehaviourVisible(false);
|
|
4058
4062
|
},
|
|
@@ -4260,8 +4264,8 @@ function AnimatedChoiceItemView(_ref) {
|
|
|
4260
4264
|
|
|
4261
4265
|
var useNativeAnimation$3 = function () {
|
|
4262
4266
|
return {
|
|
4263
|
-
onPressIn: function () {},
|
|
4264
|
-
onPressOut: function () {},
|
|
4267
|
+
onPressIn: function onPressIn() {},
|
|
4268
|
+
onPressOut: function onPressOut() {},
|
|
4265
4269
|
backgroundStyles: undefined
|
|
4266
4270
|
};
|
|
4267
4271
|
};
|
|
@@ -4318,7 +4322,7 @@ function ChoiceItem(_ref) {
|
|
|
4318
4322
|
style: style,
|
|
4319
4323
|
onBlur: onBlur,
|
|
4320
4324
|
onFocus: onFocus,
|
|
4321
|
-
onPress: function (e) {
|
|
4325
|
+
onPress: function handlePress(e) {
|
|
4322
4326
|
if (onFocus) onFocus(e);
|
|
4323
4327
|
if (onPress) onPress();
|
|
4324
4328
|
handleChange();
|
|
@@ -4326,7 +4330,7 @@ function ChoiceItem(_ref) {
|
|
|
4326
4330
|
},
|
|
4327
4331
|
onPressIn: onPressIn,
|
|
4328
4332
|
onPressOut: onPressOut,
|
|
4329
|
-
children: function (_ref2) {
|
|
4333
|
+
children: function children(_ref2) {
|
|
4330
4334
|
var isHovered = _ref2.isHovered,
|
|
4331
4335
|
isPressed = _ref2.isPressed;
|
|
4332
4336
|
var textColor = getCurrentTextColor$1({
|
|
@@ -4430,7 +4434,7 @@ function Choices(_ref2) {
|
|
|
4430
4434
|
type: type,
|
|
4431
4435
|
disabled: disabled,
|
|
4432
4436
|
onPress: !isForm ? onPress : undefined,
|
|
4433
|
-
onChange: isForm ? function (newValue) {
|
|
4437
|
+
onChange: isForm ? function handleChange(newValue) {
|
|
4434
4438
|
setCurrentValue(newValue);
|
|
4435
4439
|
if (onChange) onChange(newValue);
|
|
4436
4440
|
} : undefined,
|
|
@@ -4567,7 +4571,7 @@ function DialogModalBehaviour(_ref) {
|
|
|
4567
4571
|
},
|
|
4568
4572
|
children: /*#__PURE__*/jsx(DialogModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
4569
4573
|
visible: visible,
|
|
4570
|
-
onExited: function () {
|
|
4574
|
+
onExited: function handleExitAnimationDone() {
|
|
4571
4575
|
if (onExited) onExited();
|
|
4572
4576
|
setIsModalBehaviourVisible(false);
|
|
4573
4577
|
},
|
|
@@ -5014,7 +5018,7 @@ function isReactElement(element) {
|
|
|
5014
5018
|
return _typeof(element) === 'object' && element !== null && 'type' in element && 'props' in element;
|
|
5015
5019
|
}
|
|
5016
5020
|
function Autocomplete(_ref) {
|
|
5017
|
-
var
|
|
5021
|
+
var _children = _ref.children,
|
|
5018
5022
|
name = _ref.name,
|
|
5019
5023
|
disabled = _ref.disabled,
|
|
5020
5024
|
placeholder = _ref.placeholder,
|
|
@@ -5041,7 +5045,7 @@ function Autocomplete(_ref) {
|
|
|
5041
5045
|
zIndex = _ref$zIndex === void 0 ? 1000 : _ref$zIndex,
|
|
5042
5046
|
maxItemContainerHeight = _ref.maxItemContainerHeight,
|
|
5043
5047
|
props = _objectWithoutProperties(_ref, _excluded$x);
|
|
5044
|
-
var childrenArray = Children.toArray(
|
|
5048
|
+
var childrenArray = Children.toArray(_children);
|
|
5045
5049
|
var items = childrenArray.filter(isReactElement).map(function (child) {
|
|
5046
5050
|
return {
|
|
5047
5051
|
child: child,
|
|
@@ -5052,12 +5056,12 @@ function Autocomplete(_ref) {
|
|
|
5052
5056
|
defaultIsOpen: isInitialOpen,
|
|
5053
5057
|
initialSelectedItem: initialValue,
|
|
5054
5058
|
initialInputValue: initialValue ? itemToString(initialValue) : undefined,
|
|
5055
|
-
itemToString: function (item) {
|
|
5059
|
+
itemToString: function handleItemToString(item) {
|
|
5056
5060
|
// Prevents returning null values
|
|
5057
5061
|
if (!itemToString) return '';
|
|
5058
5062
|
return itemToString(item || undefined);
|
|
5059
5063
|
},
|
|
5060
|
-
stateReducer: function (state, changes) {
|
|
5064
|
+
stateReducer: function stateReducer(state, changes) {
|
|
5061
5065
|
switch (changes.type) {
|
|
5062
5066
|
case Downshift.stateChangeTypes.changeInput:
|
|
5063
5067
|
return _objectSpread(_objectSpread({}, changes), {}, {
|
|
@@ -5067,7 +5071,7 @@ function Autocomplete(_ref) {
|
|
|
5067
5071
|
return changes;
|
|
5068
5072
|
}
|
|
5069
5073
|
},
|
|
5070
|
-
onChange: function (selectedItem, stateAndHelpers) {
|
|
5074
|
+
onChange: function onChange(selectedItem, stateAndHelpers) {
|
|
5071
5075
|
if (_onChange) {
|
|
5072
5076
|
_onChange(selectedItem, stateAndHelpers);
|
|
5073
5077
|
}
|
|
@@ -5075,7 +5079,7 @@ function Autocomplete(_ref) {
|
|
|
5075
5079
|
onSelect: onSelectItem,
|
|
5076
5080
|
onOuterClick: onOuterPress,
|
|
5077
5081
|
onInputValueChange: onInputChange,
|
|
5078
|
-
children: function (_ref2) {
|
|
5082
|
+
children: function children(_ref2) {
|
|
5079
5083
|
var getRootProps = _ref2.getRootProps,
|
|
5080
5084
|
getInputProps = _ref2.getInputProps,
|
|
5081
5085
|
getMenuProps = _ref2.getMenuProps,
|
|
@@ -5127,20 +5131,20 @@ function Autocomplete(_ref) {
|
|
|
5127
5131
|
right: right || (canDisplayCollapseButton ? /*#__PURE__*/jsx(InputPressable, _objectSpread(_objectSpread({}, toggleProps), {}, {
|
|
5128
5132
|
testID: "kitt.Autocomplete.listToggle",
|
|
5129
5133
|
hitSlop: 40,
|
|
5130
|
-
onPress: function (e) {
|
|
5134
|
+
onPress: function handleTogglePress(e) {
|
|
5131
5135
|
onClickToggle(e);
|
|
5132
5136
|
},
|
|
5133
5137
|
children: /*#__PURE__*/jsx(InputIcon, {
|
|
5134
5138
|
icon: isCurrentlyOpen ? /*#__PURE__*/jsx(CaretUpFillIcon, {}) : /*#__PURE__*/jsx(CaretDownFillIcon, {})
|
|
5135
5139
|
})
|
|
5136
5140
|
})) : null),
|
|
5137
|
-
onFocus: function (e) {
|
|
5141
|
+
onFocus: function onFocus(e) {
|
|
5138
5142
|
openMenu();
|
|
5139
5143
|
/** @ts-expect-error onFocus wants web events */
|
|
5140
5144
|
if (onSearchInputFocus) onSearchInputFocus(e);
|
|
5141
5145
|
if (_onFocus) _onFocus(e);
|
|
5142
5146
|
},
|
|
5143
|
-
onBlur: function (e) {
|
|
5147
|
+
onBlur: function onBlur(e) {
|
|
5144
5148
|
/** @ts-expect-error onBlur wants web events */
|
|
5145
5149
|
if (onSearchInputBlur) onSearchInputBlur(e);
|
|
5146
5150
|
|
|
@@ -5176,10 +5180,10 @@ function Autocomplete(_ref) {
|
|
|
5176
5180
|
selected: ariaSelected
|
|
5177
5181
|
},
|
|
5178
5182
|
disabled: disabled,
|
|
5179
|
-
onPress: function (e) {
|
|
5183
|
+
onPress: function onPress(e) {
|
|
5180
5184
|
if (onClick) onClick(e);
|
|
5181
5185
|
},
|
|
5182
|
-
children: function (_ref5) {
|
|
5186
|
+
children: function children(_ref5) {
|
|
5183
5187
|
var isHovered = _ref5.isHovered,
|
|
5184
5188
|
isFocused = _ref5.isFocused,
|
|
5185
5189
|
isPressed = _ref5.isPressed;
|
|
@@ -5269,12 +5273,12 @@ var Checkbox = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
5269
5273
|
disabled: disabled
|
|
5270
5274
|
},
|
|
5271
5275
|
disabled: disabled,
|
|
5272
|
-
onPress: function (e) {
|
|
5276
|
+
onPress: function handlePress(e) {
|
|
5273
5277
|
if (onFocus) onFocus();
|
|
5274
5278
|
if (onChange) onChange(!checked, e);
|
|
5275
5279
|
if (onBlur) onBlur();
|
|
5276
5280
|
},
|
|
5277
|
-
children: function (_ref2) {
|
|
5281
|
+
children: function children(_ref2) {
|
|
5278
5282
|
var isHovered = _ref2.isHovered,
|
|
5279
5283
|
isPressed = _ref2.isPressed,
|
|
5280
5284
|
isFocused = _ref2.isFocused;
|
|
@@ -6083,10 +6087,10 @@ var GoogleMapsAutocompleteContext = /*#__PURE__*/createContext({
|
|
|
6083
6087
|
isLoadingResultDetails: false,
|
|
6084
6088
|
shouldDisplayEmptyStateWhenNoResults: false
|
|
6085
6089
|
},
|
|
6086
|
-
onInputChange: function () {
|
|
6090
|
+
onInputChange: function onInputChange() {
|
|
6087
6091
|
return Promise.resolve();
|
|
6088
6092
|
},
|
|
6089
|
-
onSelectItem: function () {}
|
|
6093
|
+
onSelectItem: function onSelectItem() {}
|
|
6090
6094
|
});
|
|
6091
6095
|
function GoogleMapsAutocompleteProvider(_ref) {
|
|
6092
6096
|
var children = _ref.children,
|
|
@@ -6339,7 +6343,7 @@ function InputAddress(_ref) {
|
|
|
6339
6343
|
return /*#__PURE__*/jsx(Autocomplete, _objectSpread(_objectSpread({}, props), {}, {
|
|
6340
6344
|
itemToString: itemToString,
|
|
6341
6345
|
initialValue: formattedInitialValue,
|
|
6342
|
-
checkSelectedItem: function (selectedItem, item) {
|
|
6346
|
+
checkSelectedItem: function checkSelectedItem(selectedItem, item) {
|
|
6343
6347
|
return (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.place_id) === item.place_id;
|
|
6344
6348
|
},
|
|
6345
6349
|
right: state.isLoadingSearch || state.isLoadingResultDetails ? /*#__PURE__*/jsx(Icon, {
|
|
@@ -6348,10 +6352,10 @@ function InputAddress(_ref) {
|
|
|
6348
6352
|
}) : undefined,
|
|
6349
6353
|
errorElement: state.hasSearchError || state.hasSelectResultError ? errorElement : null,
|
|
6350
6354
|
emptyResultsElement: state.items.length === 0 ? emptyResultsElement : null,
|
|
6351
|
-
onInputChange: function (v) {
|
|
6355
|
+
onInputChange: function onInputChange(v) {
|
|
6352
6356
|
_onInputChange(v);
|
|
6353
6357
|
},
|
|
6354
|
-
onChange: function (v) {
|
|
6358
|
+
onChange: function onChange(v) {
|
|
6355
6359
|
onSelectItem(v, _onChange);
|
|
6356
6360
|
},
|
|
6357
6361
|
children: state.items.map(function (item) {
|
|
@@ -6433,7 +6437,7 @@ var InputNumber = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6433
6437
|
ref: ref
|
|
6434
6438
|
}, props), {}, {
|
|
6435
6439
|
inputMode: "numeric",
|
|
6436
|
-
onChange: function (event) {
|
|
6440
|
+
onChange: function handleChange(event) {
|
|
6437
6441
|
if (!onChange) return;
|
|
6438
6442
|
var value = parseFloat(event.nativeEvent.text);
|
|
6439
6443
|
|
|
@@ -6465,7 +6469,7 @@ var InputPassword = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6465
6469
|
testID: "kitt.InputPassword.passwordToggle",
|
|
6466
6470
|
hitSlop: 20,
|
|
6467
6471
|
accessibilityRole: "button",
|
|
6468
|
-
onPress: function () {
|
|
6472
|
+
onPress: function onPress() {
|
|
6469
6473
|
return setIsVisible(function (prev) {
|
|
6470
6474
|
return !prev;
|
|
6471
6475
|
});
|
|
@@ -6500,7 +6504,7 @@ var InputPhone = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
6500
6504
|
enterKeyHint: currentEnterKeyHint,
|
|
6501
6505
|
autoComplete: autoComplete,
|
|
6502
6506
|
textContentType: "telephoneNumber",
|
|
6503
|
-
onChange: function (event) {
|
|
6507
|
+
onChange: function handleChange(event) {
|
|
6504
6508
|
var number = parseNumber(event.nativeEvent.text);
|
|
6505
6509
|
|
|
6506
6510
|
// When intl phone number is valid :
|
|
@@ -6692,14 +6696,14 @@ function Radio(_ref, ref) {
|
|
|
6692
6696
|
focusable: checked && !disabled,
|
|
6693
6697
|
flexDirection: "row",
|
|
6694
6698
|
alignItems: "center",
|
|
6695
|
-
onPress: function (event) {
|
|
6699
|
+
onPress: function handlePress(event) {
|
|
6696
6700
|
if (onFocus) onFocus();
|
|
6697
6701
|
if (onChange) onChange(value, event);
|
|
6698
6702
|
if (onBlur) onBlur();
|
|
6699
6703
|
},
|
|
6700
6704
|
onFocus: onFocus,
|
|
6701
6705
|
onBlur: onBlur,
|
|
6702
|
-
children: function (_ref2) {
|
|
6706
|
+
children: function children(_ref2) {
|
|
6703
6707
|
var isHovered = _ref2.isHovered,
|
|
6704
6708
|
isPressed = _ref2.isPressed,
|
|
6705
6709
|
isFocused = _ref2.isFocused;
|
|
@@ -6875,7 +6879,7 @@ function RadioButton(_ref) {
|
|
|
6875
6879
|
flexShrink: createResponsiveStyleFromProp(stretch, 1, undefined),
|
|
6876
6880
|
flexBasis: createResponsiveStyleFromProp(stretch, 0),
|
|
6877
6881
|
disabled: disabled,
|
|
6878
|
-
onPress: function (e) {
|
|
6882
|
+
onPress: function handlePress(e) {
|
|
6879
6883
|
if (onFocus) onFocus(e);
|
|
6880
6884
|
if (onChange) onChange(value);
|
|
6881
6885
|
if (onBlur) onBlur(e);
|
|
@@ -6884,7 +6888,7 @@ function RadioButton(_ref) {
|
|
|
6884
6888
|
onPressOut: onPressOut,
|
|
6885
6889
|
onFocus: onFocus,
|
|
6886
6890
|
onBlur: onBlur,
|
|
6887
|
-
children: function (_ref2) {
|
|
6891
|
+
children: function children(_ref2) {
|
|
6888
6892
|
var isHovered = _ref2.isHovered,
|
|
6889
6893
|
isPressed = _ref2.isPressed,
|
|
6890
6894
|
isFocused = _ref2.isFocused;
|
|
@@ -7003,7 +7007,7 @@ var TextArea = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
7003
7007
|
textAlignVertical: "top",
|
|
7004
7008
|
minHeight: "kitt.forms.textArea.minHeight"
|
|
7005
7009
|
}, props), {}, {
|
|
7006
|
-
onChange: function (e) {
|
|
7010
|
+
onChange: function handleOnChange(e) {
|
|
7007
7011
|
if (!limit || e.nativeEvent.text.length <= limit) {
|
|
7008
7012
|
var _props$onChange;
|
|
7009
7013
|
(_props$onChange = props.onChange) === null || _props$onChange === void 0 || _props$onChange.call(props, e);
|
|
@@ -7166,10 +7170,10 @@ function Toggle(_ref) {
|
|
|
7166
7170
|
children: [/*#__PURE__*/jsx(Pressable, {
|
|
7167
7171
|
accessibilityRole: "togglebutton",
|
|
7168
7172
|
disabled: isDisabled,
|
|
7169
|
-
onPress: function () {
|
|
7173
|
+
onPress: function handlePress() {
|
|
7170
7174
|
onChange(!value);
|
|
7171
7175
|
},
|
|
7172
|
-
children: function (_ref2) {
|
|
7176
|
+
children: function children(_ref2) {
|
|
7173
7177
|
var isHovered = _ref2.isHovered,
|
|
7174
7178
|
isPressed = _ref2.isPressed,
|
|
7175
7179
|
isFocused = _ref2.isFocused;
|
|
@@ -7334,7 +7338,7 @@ function FullscreenModalBehaviour(_ref) {
|
|
|
7334
7338
|
onClose: onClose,
|
|
7335
7339
|
children: /*#__PURE__*/jsx(FullscreenModalAnimation, _objectSpread(_objectSpread({}, props), {}, {
|
|
7336
7340
|
visible: visible,
|
|
7337
|
-
onExited: function () {
|
|
7341
|
+
onExited: function handleExitAnimationDone() {
|
|
7338
7342
|
if (onExited) onExited();
|
|
7339
7343
|
setIsModalBehaviourVisible(false);
|
|
7340
7344
|
},
|
|
@@ -7518,6 +7522,8 @@ function AnimatedContainer(_ref) {
|
|
|
7518
7522
|
},
|
|
7519
7523
|
borderRadius: "kitt.highlight.borderRadius",
|
|
7520
7524
|
padding: theme.kitt.highlight.padding[size],
|
|
7525
|
+
borderWidth: theme.kitt.highlight[variant]["default"].borderWidth,
|
|
7526
|
+
borderColor: theme.kitt.highlight[variant]["default"].borderColor,
|
|
7521
7527
|
backgroundColor: isHovered ? theme.kitt.highlight[variant].hover.backgroundColor : theme.kitt.highlight[variant]["default"].backgroundColor,
|
|
7522
7528
|
children: children
|
|
7523
7529
|
});
|
|
@@ -7608,6 +7614,8 @@ function Highlight(_ref) {
|
|
|
7608
7614
|
borderRadius: "kitt.highlight.borderRadius",
|
|
7609
7615
|
padding: theme.kitt.highlight.padding[size],
|
|
7610
7616
|
backgroundColor: "kitt.highlight.".concat(variant, ".default.backgroundColor"),
|
|
7617
|
+
borderWidth: theme.kitt.highlight[variant]["default"].borderWidth,
|
|
7618
|
+
borderColor: theme.kitt.highlight[variant]["default"].borderColor,
|
|
7611
7619
|
children: /*#__PURE__*/jsxs(HStack, {
|
|
7612
7620
|
space: highlightStyle[size].spaceBetween,
|
|
7613
7621
|
children: [icon && /*#__PURE__*/jsx(View, {
|
|
@@ -7629,13 +7637,13 @@ function Highlight(_ref) {
|
|
|
7629
7637
|
});
|
|
7630
7638
|
}
|
|
7631
7639
|
return /*#__PURE__*/jsx(Pressable, {
|
|
7632
|
-
onPress: function () {
|
|
7640
|
+
onPress: function handlePress() {
|
|
7633
7641
|
setIsExpanded(!isExpanded);
|
|
7634
7642
|
setIsInitialRender(false);
|
|
7635
7643
|
},
|
|
7636
7644
|
onPressIn: onPressIn,
|
|
7637
7645
|
onPressOut: onPressOut,
|
|
7638
|
-
children: function (_ref2) {
|
|
7646
|
+
children: function children(_ref2) {
|
|
7639
7647
|
var isHovered = _ref2.isHovered;
|
|
7640
7648
|
return /*#__PURE__*/jsxs(AnimatedContainer, {
|
|
7641
7649
|
isHovered: isHovered,
|
|
@@ -8110,7 +8118,7 @@ function MapMarker(_ref2) {
|
|
|
8110
8118
|
return /*#__PURE__*/jsx(Pressable$1, {
|
|
8111
8119
|
testID: testID,
|
|
8112
8120
|
onPress: onPress,
|
|
8113
|
-
children: function (_ref3) {
|
|
8121
|
+
children: function children(_ref3) {
|
|
8114
8122
|
var isHovered = _ref3.isHovered;
|
|
8115
8123
|
return /*#__PURE__*/jsx(StaticMapMarker$1, _objectSpread(_objectSpread({}, props), {}, {
|
|
8116
8124
|
isHovered: isHovered
|
|
@@ -8146,6 +8154,8 @@ var getColorByType = function (type) {
|
|
|
8146
8154
|
switch (type) {
|
|
8147
8155
|
case 'success':
|
|
8148
8156
|
case 'danger':
|
|
8157
|
+
case 'info':
|
|
8158
|
+
return 'white';
|
|
8149
8159
|
case 'warning':
|
|
8150
8160
|
default:
|
|
8151
8161
|
return 'black';
|
|
@@ -8155,6 +8165,8 @@ var getIconButtonColor = function (messageType) {
|
|
|
8155
8165
|
switch (messageType) {
|
|
8156
8166
|
case 'success':
|
|
8157
8167
|
case 'danger':
|
|
8168
|
+
case 'info':
|
|
8169
|
+
return 'ghost';
|
|
8158
8170
|
case 'warning':
|
|
8159
8171
|
default:
|
|
8160
8172
|
return 'black';
|
|
@@ -8175,7 +8187,7 @@ function BaseMessage(_ref) {
|
|
|
8175
8187
|
justifyContent: "space-between",
|
|
8176
8188
|
minHeight: "kitt.feedbackMessage.minHeight",
|
|
8177
8189
|
paddingTop: insets === null || insets === void 0 ? void 0 : insets.top,
|
|
8178
|
-
borderRadius: hasNoRadius ? undefined : 'kitt.
|
|
8190
|
+
borderRadius: hasNoRadius ? undefined : 'kitt.2',
|
|
8179
8191
|
backgroundColor: "kitt.feedbackMessage.".concat(type, ".backgroundColor"),
|
|
8180
8192
|
children: [/*#__PURE__*/jsxs(HStack, {
|
|
8181
8193
|
flexGrow: 1,
|
|
@@ -8183,9 +8195,9 @@ function BaseMessage(_ref) {
|
|
|
8183
8195
|
alignSelf: "center",
|
|
8184
8196
|
alignItems: "flex-start",
|
|
8185
8197
|
paddingY: "kitt.4",
|
|
8186
|
-
paddingX: "kitt.
|
|
8198
|
+
paddingX: "kitt.4",
|
|
8187
8199
|
children: [centeredText ? null : /*#__PURE__*/jsx(View, {
|
|
8188
|
-
marginRight: "kitt.
|
|
8200
|
+
marginRight: "kitt.2",
|
|
8189
8201
|
children: /*#__PURE__*/jsx(Icon, {
|
|
8190
8202
|
color: color,
|
|
8191
8203
|
icon: /*#__PURE__*/jsx(IconContent, {
|
|
@@ -10674,19 +10686,19 @@ function NavigationModalBehaviour(_ref) {
|
|
|
10674
10686
|
children: /*#__PURE__*/jsx(AnimationComponent, _objectSpread(_objectSpread({}, props), {}, {
|
|
10675
10687
|
appear: shouldAppear,
|
|
10676
10688
|
visible: visible,
|
|
10677
|
-
onEnter: function () {
|
|
10689
|
+
onEnter: function handleEnter() {
|
|
10678
10690
|
if (onEnter) onEnter();
|
|
10679
10691
|
|
|
10680
10692
|
// Once a children as been displayed, we force appear to false in order to avoid replaying animation on breakpoint change
|
|
10681
10693
|
setShouldAppear(false);
|
|
10682
10694
|
},
|
|
10683
|
-
onExit: function () {
|
|
10695
|
+
onExit: function handleExit() {
|
|
10684
10696
|
if (onExit) onExit();
|
|
10685
10697
|
|
|
10686
10698
|
// Reset appear value to its original value for future modal display
|
|
10687
10699
|
setShouldAppear(appear);
|
|
10688
10700
|
},
|
|
10689
|
-
onExited: function () {
|
|
10701
|
+
onExited: function handleExitAnimationDone() {
|
|
10690
10702
|
if (onExited) onExited();
|
|
10691
10703
|
setIsModalBehaviourVisible(false);
|
|
10692
10704
|
},
|
|
@@ -10952,18 +10964,18 @@ function Picker(_ref) {
|
|
|
10952
10964
|
items: items,
|
|
10953
10965
|
initialSelectedItem: initialValueIndex > -1 ? items[initialValueIndex] : undefined,
|
|
10954
10966
|
initialIsOpen: isInitialOpen,
|
|
10955
|
-
stateReducer: function (state, actionAndChanges) {
|
|
10967
|
+
stateReducer: function stateReducer(state, actionAndChanges) {
|
|
10956
10968
|
return webUseSelectReducer(state, actionAndChanges, {
|
|
10957
10969
|
keepOpenOnChange: keepOpenOnChange
|
|
10958
10970
|
});
|
|
10959
10971
|
},
|
|
10960
10972
|
selectedItem: syncStateWithSourceValue ? sourceValue : undefined,
|
|
10961
|
-
onIsOpenChange: function (changes) {
|
|
10973
|
+
onIsOpenChange: function onIsOpenChange(changes) {
|
|
10962
10974
|
if (changes.isOpen === false) {
|
|
10963
10975
|
if (onClose) onClose();
|
|
10964
10976
|
}
|
|
10965
10977
|
},
|
|
10966
|
-
onSelectedItemChange: function (changes) {
|
|
10978
|
+
onSelectedItemChange: function onSelectedItemChange(changes) {
|
|
10967
10979
|
if (!onChange) return;
|
|
10968
10980
|
if (changes.selectedItem === null) {
|
|
10969
10981
|
onChange(undefined);
|
|
@@ -11182,7 +11194,7 @@ function Skeleton(_ref) {
|
|
|
11182
11194
|
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
11183
11195
|
overflow: "hidden",
|
|
11184
11196
|
style: style,
|
|
11185
|
-
onLayout: function (_ref2) {
|
|
11197
|
+
onLayout: function onLayout(_ref2) {
|
|
11186
11198
|
var nativeEvent = _ref2.nativeEvent;
|
|
11187
11199
|
return setWidth(nativeEvent.layout.width);
|
|
11188
11200
|
},
|
|
@@ -11408,7 +11420,7 @@ function StaticMap(_ref) {
|
|
|
11408
11420
|
position: "relative",
|
|
11409
11421
|
maxWidth: mapBoxMaxPictureWidth,
|
|
11410
11422
|
height: height,
|
|
11411
|
-
onLayout: function (event) {
|
|
11423
|
+
onLayout: function handleParentLayout(event) {
|
|
11412
11424
|
var nativeEvent = event.nativeEvent;
|
|
11413
11425
|
var rangedMapWidth = getPictureWidth(nativeEvent.layout.width);
|
|
11414
11426
|
setCurrentWidth(rangedMapWidth);
|
|
@@ -11420,11 +11432,11 @@ function StaticMap(_ref) {
|
|
|
11420
11432
|
width: currentWidth,
|
|
11421
11433
|
height: height,
|
|
11422
11434
|
alt: alt,
|
|
11423
|
-
onLoadEnd: function () {
|
|
11435
|
+
onLoadEnd: function handleImageLoadEnd() {
|
|
11424
11436
|
setIsLoading(false);
|
|
11425
11437
|
if (onLoaded) onLoaded();
|
|
11426
11438
|
},
|
|
11427
|
-
onError: function () {
|
|
11439
|
+
onError: function handleError() {
|
|
11428
11440
|
setHasError(true);
|
|
11429
11441
|
if (onError) onError();
|
|
11430
11442
|
}
|
|
@@ -11449,7 +11461,7 @@ function StaticMap(_ref) {
|
|
|
11449
11461
|
width: "100%",
|
|
11450
11462
|
height: "100%",
|
|
11451
11463
|
children: /*#__PURE__*/jsx(StaticMapError, {
|
|
11452
|
-
onReload: function () {
|
|
11464
|
+
onReload: function handleReload() {
|
|
11453
11465
|
setHasError(false);
|
|
11454
11466
|
setIsLoading(true);
|
|
11455
11467
|
setCurrentMapKey(function (prev) {
|
|
@@ -11691,7 +11703,7 @@ function StoryContainer(_ref) {
|
|
|
11691
11703
|
var StoryDecorator = makeDecorator({
|
|
11692
11704
|
name: 'StoryDecorator',
|
|
11693
11705
|
parameterName: 'storyDecorator',
|
|
11694
|
-
wrapper: function (storyFn, context) {
|
|
11706
|
+
wrapper: function wrapper(storyFn, context) {
|
|
11695
11707
|
var story = storyFn(context);
|
|
11696
11708
|
if (context.parameters.disableStoryContainer) {
|
|
11697
11709
|
return story;
|
|
@@ -11872,7 +11884,7 @@ function TabBar(_ref) {
|
|
|
11872
11884
|
return /*#__PURE__*/jsx(View, {
|
|
11873
11885
|
children: /*#__PURE__*/cloneElement(child, {
|
|
11874
11886
|
color: color,
|
|
11875
|
-
onPress: function (event) {
|
|
11887
|
+
onPress: function onPress(event) {
|
|
11876
11888
|
var _child$props$onPress, _child$props;
|
|
11877
11889
|
onChangeTab({
|
|
11878
11890
|
tab: tabs[index],
|
|
@@ -12050,7 +12062,7 @@ var TimePicker = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
12050
12062
|
isFocusedInternal: isFocusedInternal,
|
|
12051
12063
|
isPressedInternal: isPressedInternal
|
|
12052
12064
|
}),
|
|
12053
|
-
onChange: function (event) {
|
|
12065
|
+
onChange: function handleInputChange(event) {
|
|
12054
12066
|
var currentValue = event.nativeEvent.text;
|
|
12055
12067
|
if (currentValue.length === 0) {
|
|
12056
12068
|
setInputValue(currentValue);
|
|
@@ -12100,7 +12112,7 @@ var TimePicker = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
12100
12112
|
setInputValue(sanitizedValue);
|
|
12101
12113
|
handleChange(sanitizedValue);
|
|
12102
12114
|
},
|
|
12103
|
-
onBlur: function () {
|
|
12115
|
+
onBlur: function handleBlur() {
|
|
12104
12116
|
if (inputValue.indexOf(':') === 1) {
|
|
12105
12117
|
setInputValue("0".concat(inputValue));
|
|
12106
12118
|
}
|
|
@@ -12655,7 +12667,7 @@ function KittThemeProvider(_ref) {
|
|
|
12655
12667
|
var KittThemeDecorator = makeDecorator({
|
|
12656
12668
|
name: 'ThemeDecorator',
|
|
12657
12669
|
parameterName: 'theme',
|
|
12658
|
-
wrapper: function (storyFn, context, _ref2) {
|
|
12670
|
+
wrapper: function wrapper(storyFn, context, _ref2) {
|
|
12659
12671
|
var _parameters$isSSR;
|
|
12660
12672
|
var _ref2$options = _ref2.options,
|
|
12661
12673
|
options = _ref2$options === void 0 ? {} : _ref2$options,
|