@ornikar/kitt-universal 22.1.0 → 22.2.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 +23 -0
- package/dist/definitions/CardModal/CardModal.d.ts.map +1 -1
- package/dist/definitions/CardModal/CardModalAnimation/CardModalRotationContainer.d.ts.map +1 -1
- package/dist/definitions/CardModal/CardModalBehaviour.d.ts +0 -5
- package/dist/definitions/CardModal/CardModalBehaviour.d.ts.map +1 -1
- package/dist/definitions/CardModal/CardModalBody.d.ts +2 -2
- package/dist/definitions/CardModal/CardModalBody.d.ts.map +1 -1
- package/dist/definitions/NavigationModal/NavigationModalBehaviour.d.ts.map +1 -1
- package/dist/definitions/forms/InputEmail/InputEmail.d.ts +1 -1
- package/dist/definitions/forms/InputEmail/InputEmail.d.ts.map +1 -1
- package/dist/definitions/forms/InputNumber/InputNumber.d.ts +2 -1
- package/dist/definitions/forms/InputNumber/InputNumber.d.ts.map +1 -1
- package/dist/definitions/forms/InputPhone/InputPhone.d.ts +1 -1
- package/dist/definitions/forms/InputPhone/InputPhone.d.ts.map +1 -1
- package/dist/definitions/native-base/KittNativeBaseProvider.d.ts +5 -17
- package/dist/definitions/native-base/KittNativeBaseProvider.d.ts.map +1 -1
- package/dist/definitions/themes/late-ocean/cardModal.d.ts +1 -0
- package/dist/definitions/themes/late-ocean/cardModal.d.ts.map +1 -1
- package/dist/index-metro.es.android.js +53 -82
- package/dist/index-metro.es.android.js.map +1 -1
- package/dist/index-metro.es.ios.js +53 -82
- package/dist/index-metro.es.ios.js.map +1 -1
- package/dist/index-node-18.18.cjs.js +43 -71
- package/dist/index-node-18.18.cjs.js.map +1 -1
- package/dist/index-node-18.18.cjs.web.js +43 -66
- package/dist/index-node-18.18.cjs.web.js.map +1 -1
- package/dist/index-node-18.18.es.mjs +44 -72
- package/dist/index-node-18.18.es.mjs.map +1 -1
- package/dist/index-node-18.18.es.web.mjs +44 -67
- package/dist/index-node-18.18.es.web.mjs.map +1 -1
- package/dist/index.es.js +63 -90
- package/dist/index.es.js.map +1 -1
- package/dist/index.es.web.js +63 -85
- package/dist/index.es.web.js.map +1 -1
- package/dist/linaria-themes-metro.es.android.js +2 -1
- package/dist/linaria-themes-metro.es.android.js.map +1 -1
- package/dist/linaria-themes-metro.es.ios.js +2 -1
- package/dist/linaria-themes-metro.es.ios.js.map +1 -1
- package/dist/linaria-themes-node-18.18.cjs.js +2 -1
- package/dist/linaria-themes-node-18.18.cjs.js.map +1 -1
- package/dist/linaria-themes-node-18.18.cjs.web.js +2 -1
- package/dist/linaria-themes-node-18.18.cjs.web.js.map +1 -1
- package/dist/linaria-themes-node-18.18.es.mjs +2 -1
- package/dist/linaria-themes-node-18.18.es.mjs.map +1 -1
- package/dist/linaria-themes-node-18.18.es.web.mjs +2 -1
- package/dist/linaria-themes-node-18.18.es.web.mjs.map +1 -1
- package/dist/linaria-themes.es.js +2 -1
- package/dist/linaria-themes.es.js.map +1 -1
- package/dist/linaria-themes.es.web.js +2 -1
- package/dist/linaria-themes.es.web.js.map +1 -1
- package/dist/tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -790,6 +790,7 @@ const cardModal = {
|
|
|
790
790
|
borderRadius: 20,
|
|
791
791
|
maxWidth,
|
|
792
792
|
maxWidthWithPadding: maxWidth + overlayHorizontalPadding * 2,
|
|
793
|
+
minHeight: 280,
|
|
793
794
|
shadow: {
|
|
794
795
|
color: colors.black,
|
|
795
796
|
offsetX: 0,
|
|
@@ -808,7 +809,7 @@ const cardModal = {
|
|
|
808
809
|
},
|
|
809
810
|
overlayPadding: {
|
|
810
811
|
horizontal: 24,
|
|
811
|
-
vertical:
|
|
812
|
+
vertical: 80
|
|
812
813
|
},
|
|
813
814
|
animation: {
|
|
814
815
|
overlay: {
|
|
@@ -3088,6 +3089,10 @@ function CardModalRotationContainer(props) {
|
|
|
3088
3089
|
paddingY: "kitt.cardModal.overlayPadding.vertical",
|
|
3089
3090
|
maxWidth: "kitt.cardModal.maxWidthWithPadding",
|
|
3090
3091
|
width: "100%",
|
|
3092
|
+
maxHeight: "100%",
|
|
3093
|
+
_web: {
|
|
3094
|
+
maxHeight: '100svh'
|
|
3095
|
+
},
|
|
3091
3096
|
...props
|
|
3092
3097
|
});
|
|
3093
3098
|
}
|
|
@@ -3234,20 +3239,6 @@ function CardModalAnimation({
|
|
|
3234
3239
|
});
|
|
3235
3240
|
}
|
|
3236
3241
|
|
|
3237
|
-
function CardModalScrollContainer({
|
|
3238
|
-
children,
|
|
3239
|
-
...props
|
|
3240
|
-
}) {
|
|
3241
|
-
if (reactNative.Platform.OS !== 'web') {
|
|
3242
|
-
return /*#__PURE__*/jsxRuntime.jsx(View, {
|
|
3243
|
-
children: children
|
|
3244
|
-
});
|
|
3245
|
-
}
|
|
3246
|
-
return /*#__PURE__*/jsxRuntime.jsx(ScrollView, {
|
|
3247
|
-
...props,
|
|
3248
|
-
children: children
|
|
3249
|
-
});
|
|
3250
|
-
}
|
|
3251
3242
|
function CardModalBehaviour({
|
|
3252
3243
|
children,
|
|
3253
3244
|
visible,
|
|
@@ -3264,21 +3255,15 @@ function CardModalBehaviour({
|
|
|
3264
3255
|
return /*#__PURE__*/jsxRuntime.jsx(ModalBehaviour, {
|
|
3265
3256
|
visible: isModalBehaviourVisible,
|
|
3266
3257
|
onClose: onClose,
|
|
3267
|
-
children: /*#__PURE__*/jsxRuntime.jsx(
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3258
|
+
children: /*#__PURE__*/jsxRuntime.jsx(CardModalAnimation, {
|
|
3259
|
+
...props,
|
|
3260
|
+
visible: visible,
|
|
3261
|
+
onExited: () => {
|
|
3262
|
+
if (onExited) onExited();
|
|
3263
|
+
setIsModalBehaviourVisible(false);
|
|
3271
3264
|
},
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
visible: visible,
|
|
3275
|
-
onExited: () => {
|
|
3276
|
-
if (onExited) onExited();
|
|
3277
|
-
setIsModalBehaviourVisible(false);
|
|
3278
|
-
},
|
|
3279
|
-
onClose: onClose,
|
|
3280
|
-
children: children
|
|
3281
|
-
})
|
|
3265
|
+
onClose: onClose,
|
|
3266
|
+
children: children
|
|
3282
3267
|
})
|
|
3283
3268
|
});
|
|
3284
3269
|
}
|
|
@@ -3292,7 +3277,8 @@ function CardModalBody({
|
|
|
3292
3277
|
paddingY = 'kitt.4',
|
|
3293
3278
|
...props
|
|
3294
3279
|
}) {
|
|
3295
|
-
return /*#__PURE__*/jsxRuntime.jsx(
|
|
3280
|
+
return /*#__PURE__*/jsxRuntime.jsx(ScrollView, {
|
|
3281
|
+
showsVerticalScrollIndicator: false,
|
|
3296
3282
|
paddingX: paddingX,
|
|
3297
3283
|
paddingY: paddingY,
|
|
3298
3284
|
...props,
|
|
@@ -3392,6 +3378,7 @@ function CardModal({
|
|
|
3392
3378
|
width: "100%",
|
|
3393
3379
|
maxHeight: "100%",
|
|
3394
3380
|
maxWidth: maxWidth,
|
|
3381
|
+
minHeight: "kitt.cardModal.minHeight",
|
|
3395
3382
|
children: children || /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
3396
3383
|
children: [header || null, body || null, footer || null]
|
|
3397
3384
|
})
|
|
@@ -4104,7 +4091,7 @@ const InputText = /*#__PURE__*/React.forwardRef(({
|
|
|
4104
4091
|
autoCorrect = true,
|
|
4105
4092
|
textContentType = 'none',
|
|
4106
4093
|
autoComplete = 'off',
|
|
4107
|
-
inputMode = '
|
|
4094
|
+
inputMode = 'text',
|
|
4108
4095
|
multiline,
|
|
4109
4096
|
onSubmitEditing,
|
|
4110
4097
|
...props
|
|
@@ -5767,13 +5754,12 @@ function InputField({
|
|
|
5767
5754
|
|
|
5768
5755
|
const InputNumber = /*#__PURE__*/React.forwardRef(({
|
|
5769
5756
|
onChange,
|
|
5770
|
-
keyboardType = 'numeric',
|
|
5771
5757
|
...props
|
|
5772
5758
|
}, ref) => {
|
|
5773
5759
|
return /*#__PURE__*/jsxRuntime.jsx(InputText, {
|
|
5774
5760
|
ref: ref,
|
|
5775
5761
|
...props,
|
|
5776
|
-
|
|
5762
|
+
inputMode: "numeric",
|
|
5777
5763
|
onChange: event => {
|
|
5778
5764
|
if (!onChange) return;
|
|
5779
5765
|
const value = parseFloat(event.nativeEvent.text);
|
|
@@ -5805,7 +5791,7 @@ const InputPassword = /*#__PURE__*/React.forwardRef(({
|
|
|
5805
5791
|
accessibilityRole: "button",
|
|
5806
5792
|
onPress: () => setIsVisible(prev => !prev),
|
|
5807
5793
|
children: /*#__PURE__*/jsxRuntime.jsx(InputIcon, {
|
|
5808
|
-
icon: isVisible ? /*#__PURE__*/jsxRuntime.jsx(phosphor.
|
|
5794
|
+
icon: isVisible ? /*#__PURE__*/jsxRuntime.jsx(phosphor.EyeClosedRegularIcon, {}) : /*#__PURE__*/jsxRuntime.jsx(phosphor.EyeRegularIcon, {})
|
|
5809
5795
|
})
|
|
5810
5796
|
})
|
|
5811
5797
|
});
|
|
@@ -8059,7 +8045,8 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
8059
8045
|
height: theme.cardModal.header.height
|
|
8060
8046
|
},
|
|
8061
8047
|
maxWidth: theme.cardModal.maxWidth,
|
|
8062
|
-
maxWidthWithPadding: theme.cardModal.maxWidthWithPadding
|
|
8048
|
+
maxWidthWithPadding: theme.cardModal.maxWidthWithPadding,
|
|
8049
|
+
minHeight: theme.cardModal.minHeight
|
|
8063
8050
|
},
|
|
8064
8051
|
dialogModal: {
|
|
8065
8052
|
maxWidth: theme.dialogModal.maxWidth,
|
|
@@ -8173,7 +8160,7 @@ function createKittNativeBaseCustomTheme(theme, appTheme) {
|
|
|
8173
8160
|
padding: theme.button.padding
|
|
8174
8161
|
},
|
|
8175
8162
|
cardModal: {
|
|
8176
|
-
overlayPadding: theme.
|
|
8163
|
+
overlayPadding: theme.cardModal.overlayPadding
|
|
8177
8164
|
},
|
|
8178
8165
|
dialogModal: {
|
|
8179
8166
|
overlayPadding: theme.dialogModal.overlayPadding
|
|
@@ -8958,11 +8945,6 @@ function KittNativeBaseProvider({
|
|
|
8958
8945
|
});
|
|
8959
8946
|
}
|
|
8960
8947
|
|
|
8961
|
-
function SimpleContainer({
|
|
8962
|
-
children
|
|
8963
|
-
}) {
|
|
8964
|
-
return children;
|
|
8965
|
-
}
|
|
8966
8948
|
function NavigationModalBehaviour({
|
|
8967
8949
|
children,
|
|
8968
8950
|
visible,
|
|
@@ -8977,10 +8959,6 @@ function NavigationModalBehaviour({
|
|
|
8977
8959
|
base: FullscreenModalAnimation,
|
|
8978
8960
|
small: CardModalAnimation
|
|
8979
8961
|
});
|
|
8980
|
-
const CurrentContainerComponent = useBreakpointValue({
|
|
8981
|
-
base: SimpleContainer,
|
|
8982
|
-
small: CardModalScrollContainer
|
|
8983
|
-
});
|
|
8984
8962
|
const [isModalBehaviourVisible, setIsModalBehaviourVisible] = React.useState(visible);
|
|
8985
8963
|
const [shouldAppear, setShouldAppear] = React.useState(appear);
|
|
8986
8964
|
React.useEffect(() => {
|
|
@@ -8991,34 +8969,28 @@ function NavigationModalBehaviour({
|
|
|
8991
8969
|
return /*#__PURE__*/jsxRuntime.jsx(ModalBehaviour, {
|
|
8992
8970
|
visible: isModalBehaviourVisible,
|
|
8993
8971
|
onClose: onClose,
|
|
8994
|
-
children: /*#__PURE__*/jsxRuntime.jsx(
|
|
8995
|
-
|
|
8996
|
-
|
|
8997
|
-
|
|
8998
|
-
|
|
8999
|
-
|
|
9000
|
-
...props,
|
|
9001
|
-
appear: shouldAppear,
|
|
9002
|
-
visible: visible,
|
|
9003
|
-
onEnter: () => {
|
|
9004
|
-
if (onEnter) onEnter();
|
|
8972
|
+
children: /*#__PURE__*/jsxRuntime.jsx(AnimationComponent, {
|
|
8973
|
+
...props,
|
|
8974
|
+
appear: shouldAppear,
|
|
8975
|
+
visible: visible,
|
|
8976
|
+
onEnter: () => {
|
|
8977
|
+
if (onEnter) onEnter();
|
|
9005
8978
|
|
|
9006
|
-
|
|
9007
|
-
|
|
9008
|
-
|
|
9009
|
-
|
|
9010
|
-
|
|
8979
|
+
// Once a children as been displayed, we force appear to false in order to avoid replaying animation on breakpoint change
|
|
8980
|
+
setShouldAppear(false);
|
|
8981
|
+
},
|
|
8982
|
+
onExit: () => {
|
|
8983
|
+
if (onExit) onExit();
|
|
9011
8984
|
|
|
9012
|
-
|
|
9013
|
-
|
|
9014
|
-
|
|
9015
|
-
|
|
9016
|
-
|
|
9017
|
-
|
|
9018
|
-
|
|
9019
|
-
|
|
9020
|
-
|
|
9021
|
-
})
|
|
8985
|
+
// Reset appear value to its original value for future modal display
|
|
8986
|
+
setShouldAppear(appear);
|
|
8987
|
+
},
|
|
8988
|
+
onExited: () => {
|
|
8989
|
+
if (onExited) onExited();
|
|
8990
|
+
setIsModalBehaviourVisible(false);
|
|
8991
|
+
},
|
|
8992
|
+
onClose: onClose,
|
|
8993
|
+
children: children
|
|
9022
8994
|
})
|
|
9023
8995
|
});
|
|
9024
8996
|
}
|