@ornikar/kitt-universal 29.4.1 → 29.4.2-canary.0e4f130cb45a177a7fdd9a15817918e986eb8cd4.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 +15 -0
- package/dist/definitions/BaseMessage/BaseMessage.d.ts +1 -1
- package/dist/definitions/BaseMessage/BaseMessage.d.ts.map +1 -1
- package/dist/definitions/CardModal/CardModalAnimation/CardModalAnimation.web.d.ts +1 -1
- package/dist/definitions/CardModal/CardModalAnimation/CardModalAnimation.web.d.ts.map +1 -1
- package/dist/definitions/CardModal/CardModalAnimation/CardModalRotationContainer.d.ts +2 -2
- package/dist/definitions/CardModal/CardModalAnimation/CardModalRotationContainer.d.ts.map +1 -1
- package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts +1 -1
- package/dist/definitions/DialogModal/DialogModalAnimation/DialogModalAnimation.web.d.ts.map +1 -1
- package/dist/definitions/FullscreenModal/FullscreenModalAnimation.web.d.ts +1 -1
- package/dist/definitions/FullscreenModal/FullscreenModalAnimation.web.d.ts.map +1 -1
- package/dist/definitions/Notification/Notification.d.ts +2 -2
- package/dist/definitions/Notification/Notification.d.ts.map +1 -1
- package/dist/definitions/Overlay/Overlay.d.ts +2 -2
- package/dist/definitions/Overlay/Overlay.d.ts.map +1 -1
- package/dist/definitions/Picker/Picker.web.d.ts.map +1 -1
- package/dist/index-metro.es.android.js +23 -18
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +23 -18
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-22.17.cjs.js +16 -12
- package/dist/index-node-22.17.cjs.js.map +1 -1
- package/dist/index-node-22.17.cjs.web.js +48 -13
- package/dist/index-node-22.17.cjs.web.js.map +1 -1
- package/dist/index-node-22.17.es.mjs +16 -12
- package/dist/index-node-22.17.es.mjs.map +1 -1
- package/dist/index-node-22.17.es.web.mjs +48 -13
- package/dist/index-node-22.17.es.web.mjs.map +1 -1
- package/dist/index.es.js +15 -10
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +47 -11
- package/dist/index.es.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +1 -1
- package/scripts/codemods/__testfixtures__/illustration-imports/illustration-imports.input.tsx +11 -0
- package/scripts/codemods/__testfixtures__/illustration-imports/illustration-imports.output.tsx +13 -0
- package/scripts/codemods/__tests__/illustration-imports.test.js +12 -0
- package/scripts/codemods/illustration-imports.js +184 -0
package/dist/index.es.web.js
CHANGED
|
@@ -4154,9 +4154,10 @@ function ModalBehaviour(_ref2) {
|
|
|
4154
4154
|
}
|
|
4155
4155
|
ModalBehaviour.CloseButton = CloseButton$1;
|
|
4156
4156
|
|
|
4157
|
-
|
|
4157
|
+
var Overlay = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
4158
4158
|
var onPress = _ref.onPress;
|
|
4159
4159
|
return /*#__PURE__*/jsx(Pressable, {
|
|
4160
|
+
ref: ref,
|
|
4160
4161
|
accessibilityRole: "none",
|
|
4161
4162
|
position: "absolute",
|
|
4162
4163
|
top: "0",
|
|
@@ -4166,10 +4167,10 @@ function Overlay(_ref) {
|
|
|
4166
4167
|
backgroundColor: "kitt.overlay.dark",
|
|
4167
4168
|
onPress: onPress
|
|
4168
4169
|
});
|
|
4169
|
-
}
|
|
4170
|
+
});
|
|
4170
4171
|
|
|
4171
|
-
|
|
4172
|
-
return /*#__PURE__*/jsx(View, _objectSpread({
|
|
4172
|
+
var CardModalRotationContainer = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
4173
|
+
return /*#__PURE__*/jsx(View, _objectSpread(_objectSpread({
|
|
4173
4174
|
paddingX: "kitt.cardModal.overlayPadding.horizontal",
|
|
4174
4175
|
paddingY: "kitt.cardModal.overlayPadding.vertical",
|
|
4175
4176
|
maxWidth: "kitt.cardModal.maxWidthWithPadding",
|
|
@@ -4178,8 +4179,10 @@ function CardModalRotationContainer(props) {
|
|
|
4178
4179
|
_web: {
|
|
4179
4180
|
maxHeight: '100svh'
|
|
4180
4181
|
}
|
|
4181
|
-
}, props)
|
|
4182
|
-
|
|
4182
|
+
}, props), {}, {
|
|
4183
|
+
ref: ref
|
|
4184
|
+
}));
|
|
4185
|
+
});
|
|
4183
4186
|
|
|
4184
4187
|
var _excluded$J = ["children", "appear", "visible", "unmountOnExit", "isAnimationEnabled", "onEnter", "onEntered", "onExit", "onExited", "onClose"];
|
|
4185
4188
|
var contentAnimationEnter$1 = "kitt-u_contentAnimationEnter_c11xxy4r";
|
|
@@ -4221,6 +4224,10 @@ function CardModalAnimation(_ref) {
|
|
|
4221
4224
|
onExited = _ref.onExited,
|
|
4222
4225
|
onClose = _ref.onClose,
|
|
4223
4226
|
props = _objectWithoutProperties(_ref, _excluded$J);
|
|
4227
|
+
// React 19 has removed the ReactDOM.findDOMNode method. We need to use refs to access DOM nodes in CSSTransition.
|
|
4228
|
+
// See https://github.com/reactjs/react-transition-group/issues/918
|
|
4229
|
+
var overlayRef = useRef(null);
|
|
4230
|
+
var contentRef = useRef(null);
|
|
4224
4231
|
var theme = useTheme();
|
|
4225
4232
|
var animation = theme.kitt.cardModal.animation;
|
|
4226
4233
|
var sharedProps = {
|
|
@@ -4232,12 +4239,15 @@ function CardModalAnimation(_ref) {
|
|
|
4232
4239
|
height: "100%",
|
|
4233
4240
|
justifyContent: "center",
|
|
4234
4241
|
children: [/*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
4242
|
+
nodeRef: overlayRef,
|
|
4235
4243
|
timeout: isAnimationEnabled ? animation.overlay.duration : 0,
|
|
4236
4244
|
classNames: opacityClassNames$2,
|
|
4237
4245
|
children: /*#__PURE__*/jsx(Overlay, {
|
|
4246
|
+
ref: overlayRef,
|
|
4238
4247
|
onPress: onClose
|
|
4239
4248
|
})
|
|
4240
4249
|
})), /*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
4250
|
+
nodeRef: contentRef,
|
|
4241
4251
|
timeout: isAnimationEnabled ? animation.content.duration : 0,
|
|
4242
4252
|
classNames: contentAnimationClassNames$1,
|
|
4243
4253
|
onEnter: onEnter,
|
|
@@ -4245,6 +4255,7 @@ function CardModalAnimation(_ref) {
|
|
|
4245
4255
|
onExit: onExit,
|
|
4246
4256
|
onExited: onExited,
|
|
4247
4257
|
children: /*#__PURE__*/jsx(CardModalRotationContainer, {
|
|
4258
|
+
ref: contentRef,
|
|
4248
4259
|
alignItems: "center",
|
|
4249
4260
|
margin: "auto",
|
|
4250
4261
|
children: children
|
|
@@ -4815,6 +4826,10 @@ function DialogModalAnimation(_ref) {
|
|
|
4815
4826
|
onExited = _ref.onExited,
|
|
4816
4827
|
onClose = _ref.onClose,
|
|
4817
4828
|
props = _objectWithoutProperties(_ref, _excluded$C);
|
|
4829
|
+
// React 19 has removed the ReactDOM.findDOMNode method. We need to use refs to access DOM nodes in CSSTransition.
|
|
4830
|
+
// See https://github.com/reactjs/react-transition-group/issues/918
|
|
4831
|
+
var overlayRef = useRef(null);
|
|
4832
|
+
var contentRef = useRef(null);
|
|
4818
4833
|
var theme = useTheme();
|
|
4819
4834
|
var animation = theme.kitt.dialogModal.animation;
|
|
4820
4835
|
var sharedProps = {
|
|
@@ -4826,12 +4841,15 @@ function DialogModalAnimation(_ref) {
|
|
|
4826
4841
|
height: "100%",
|
|
4827
4842
|
justifyContent: "center",
|
|
4828
4843
|
children: [/*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
4844
|
+
nodeRef: overlayRef,
|
|
4829
4845
|
timeout: isAnimationEnabled ? animation.overlay.duration : 0,
|
|
4830
4846
|
classNames: opacityClassNames$1,
|
|
4831
4847
|
children: /*#__PURE__*/jsx(Overlay, {
|
|
4848
|
+
ref: overlayRef,
|
|
4832
4849
|
onPress: onClose
|
|
4833
4850
|
})
|
|
4834
4851
|
})), /*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
4852
|
+
nodeRef: contentRef,
|
|
4835
4853
|
timeout: isAnimationEnabled ? animation.content.duration : 0,
|
|
4836
4854
|
classNames: contentAnimationClassNames,
|
|
4837
4855
|
onEnter: onEnter,
|
|
@@ -4839,6 +4857,7 @@ function DialogModalAnimation(_ref) {
|
|
|
4839
4857
|
onExit: onExit,
|
|
4840
4858
|
onExited: onExited,
|
|
4841
4859
|
children: /*#__PURE__*/jsx(View, {
|
|
4860
|
+
ref: contentRef,
|
|
4842
4861
|
alignItems: "center",
|
|
4843
4862
|
paddingX: "kitt.dialogModal.overlayPadding.horizontal",
|
|
4844
4863
|
paddingY: "kitt.dialogModal.overlayPadding.vertical",
|
|
@@ -7593,6 +7612,10 @@ function FullscreenModalAnimation(_ref) {
|
|
|
7593
7612
|
onExited = _ref.onExited,
|
|
7594
7613
|
onClose = _ref.onClose,
|
|
7595
7614
|
props = _objectWithoutProperties(_ref, _excluded$i);
|
|
7615
|
+
// React 19 has removed the ReactDOM.findDOMNode method. We need to use refs to access DOM nodes in CSSTransition.
|
|
7616
|
+
// See https://github.com/reactjs/react-transition-group/issues/918
|
|
7617
|
+
var overlayRef = useRef(null);
|
|
7618
|
+
var contentRef = useRef(null);
|
|
7596
7619
|
var theme = useTheme();
|
|
7597
7620
|
var animation = theme.kitt.fullscreenModal.animation;
|
|
7598
7621
|
var sharedProps = {
|
|
@@ -7602,19 +7625,25 @@ function FullscreenModalAnimation(_ref) {
|
|
|
7602
7625
|
};
|
|
7603
7626
|
return /*#__PURE__*/jsxs(View, _objectSpread(_objectSpread({}, props), {}, {
|
|
7604
7627
|
children: [/*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
7628
|
+
nodeRef: overlayRef,
|
|
7605
7629
|
timeout: isAnimationEnabled ? animation.overlay.duration : 0,
|
|
7606
7630
|
classNames: opacityClassNames,
|
|
7607
7631
|
children: /*#__PURE__*/jsx(Overlay, {
|
|
7632
|
+
ref: overlayRef,
|
|
7608
7633
|
onPress: onClose
|
|
7609
7634
|
})
|
|
7610
7635
|
})), /*#__PURE__*/jsx(CSSTransition, _objectSpread(_objectSpread({}, sharedProps), {}, {
|
|
7636
|
+
nodeRef: contentRef,
|
|
7611
7637
|
timeout: isAnimationEnabled ? animation.content.duration : 0,
|
|
7612
7638
|
classNames: slideInClassNames,
|
|
7613
7639
|
onEnter: onEnter,
|
|
7614
7640
|
onEntered: onEntered,
|
|
7615
7641
|
onExit: onExit,
|
|
7616
7642
|
onExited: onExited,
|
|
7617
|
-
children:
|
|
7643
|
+
children: /*#__PURE__*/jsx(View, {
|
|
7644
|
+
ref: contentRef,
|
|
7645
|
+
children: children
|
|
7646
|
+
})
|
|
7618
7647
|
}))]
|
|
7619
7648
|
}));
|
|
7620
7649
|
}
|
|
@@ -8374,7 +8403,7 @@ var getIconButtonColor = function (messageType) {
|
|
|
8374
8403
|
}
|
|
8375
8404
|
};
|
|
8376
8405
|
|
|
8377
|
-
|
|
8406
|
+
var BaseMessage = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
8378
8407
|
var _ref$type = _ref.type,
|
|
8379
8408
|
type = _ref$type === void 0 ? 'info' : _ref$type,
|
|
8380
8409
|
children = _ref.children,
|
|
@@ -8384,6 +8413,7 @@ function BaseMessage(_ref) {
|
|
|
8384
8413
|
onDismiss = _ref.onDismiss;
|
|
8385
8414
|
var color = getColorByType(type);
|
|
8386
8415
|
return /*#__PURE__*/jsxs(HStack, {
|
|
8416
|
+
ref: ref,
|
|
8387
8417
|
alignItems: "flex-start",
|
|
8388
8418
|
justifyContent: "space-between",
|
|
8389
8419
|
minHeight: "kitt.feedbackMessage.minHeight",
|
|
@@ -8425,7 +8455,7 @@ function BaseMessage(_ref) {
|
|
|
8425
8455
|
})
|
|
8426
8456
|
}) : null]
|
|
8427
8457
|
});
|
|
8428
|
-
}
|
|
8458
|
+
});
|
|
8429
8459
|
|
|
8430
8460
|
function Message(_ref) {
|
|
8431
8461
|
var _ref$type = _ref.type,
|
|
@@ -11168,13 +11198,14 @@ NavigationBottomSheet.Header = NavigationBottomSheetHeader;
|
|
|
11168
11198
|
NavigationBottomSheet.Body = NavigationBottomSheetBody;
|
|
11169
11199
|
NavigationBottomSheet.Footer = NavigationBottomSheetFooter;
|
|
11170
11200
|
|
|
11171
|
-
|
|
11201
|
+
var Notification = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
11172
11202
|
var type = _ref.type,
|
|
11173
11203
|
children = _ref.children,
|
|
11174
11204
|
centeredText = _ref.centeredText,
|
|
11175
11205
|
insets = _ref.insets,
|
|
11176
11206
|
onDismiss = _ref.onDismiss;
|
|
11177
11207
|
return /*#__PURE__*/jsx(BaseMessage, {
|
|
11208
|
+
ref: ref,
|
|
11178
11209
|
hasNoRadius: true,
|
|
11179
11210
|
type: type,
|
|
11180
11211
|
centeredText: centeredText,
|
|
@@ -11182,7 +11213,7 @@ function Notification(_ref) {
|
|
|
11182
11213
|
onDismiss: onDismiss,
|
|
11183
11214
|
children: children
|
|
11184
11215
|
});
|
|
11185
|
-
}
|
|
11216
|
+
});
|
|
11186
11217
|
|
|
11187
11218
|
var AnimatedCircle = Animated$1.createAnimatedComponent(Circle$1);
|
|
11188
11219
|
function AnimatedLoaderCircle(_ref) {
|
|
@@ -11438,6 +11469,9 @@ function Picker(_ref) {
|
|
|
11438
11469
|
isItemsWidthFixed = _ref.isItemsWidthFixed,
|
|
11439
11470
|
onChange = _ref.onChange,
|
|
11440
11471
|
onClose = _ref.onClose;
|
|
11472
|
+
// React 19 has removed the ReactDOM.findDOMNode method. We need to use refs to access DOM nodes in CSSTransition.
|
|
11473
|
+
// See https://github.com/reactjs/react-transition-group/issues/918
|
|
11474
|
+
var nodeRef = useRef(null);
|
|
11441
11475
|
if ((process.env.NODE_ENV !== "production") && sourceValue !== undefined && !syncStateWithSourceValue) {
|
|
11442
11476
|
throw new Error('Picker: sourceValue prop should only be used with syncStateWithSourceValue prop');
|
|
11443
11477
|
}
|
|
@@ -11546,6 +11580,7 @@ function Picker(_ref) {
|
|
|
11546
11580
|
},
|
|
11547
11581
|
children: /*#__PURE__*/jsx(CSSTransition, {
|
|
11548
11582
|
unmountOnExit: true,
|
|
11583
|
+
nodeRef: nodeRef,
|
|
11549
11584
|
timeout: 300,
|
|
11550
11585
|
"in": isOpen,
|
|
11551
11586
|
classNames: {
|
|
@@ -11555,6 +11590,7 @@ function Picker(_ref) {
|
|
|
11555
11590
|
exitActive: exitActive
|
|
11556
11591
|
},
|
|
11557
11592
|
children: /*#__PURE__*/jsx(View, {
|
|
11593
|
+
ref: nodeRef,
|
|
11558
11594
|
paddingY: "kitt.2",
|
|
11559
11595
|
children: childrenArray.map(function (child, index) {
|
|
11560
11596
|
var currentValue = items[index];
|