@pagopa/io-app-design-system 4.2.0 → 4.3.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/lib/commonjs/components/alert/Alert.js +10 -31
- package/lib/commonjs/components/alert/Alert.js.map +1 -1
- package/lib/commonjs/components/alert/AlertEdgeToEdge.js +9 -29
- package/lib/commonjs/components/alert/AlertEdgeToEdge.js.map +1 -1
- package/lib/commonjs/components/banner/Banner.js +10 -34
- package/lib/commonjs/components/banner/Banner.js.map +1 -1
- package/lib/commonjs/components/banner/__test__/__snapshots__/banner.test.tsx.snap +1 -1
- package/lib/commonjs/components/buttons/ButtonLink.js +20 -53
- package/lib/commonjs/components/buttons/ButtonLink.js.map +1 -1
- package/lib/commonjs/components/buttons/ButtonOutline.js +24 -44
- package/lib/commonjs/components/buttons/ButtonOutline.js.map +1 -1
- package/lib/commonjs/components/buttons/ButtonSolid.js +14 -39
- package/lib/commonjs/components/buttons/ButtonSolid.js.map +1 -1
- package/lib/commonjs/components/buttons/IconButton.js +13 -32
- package/lib/commonjs/components/buttons/IconButton.js.map +1 -1
- package/lib/commonjs/components/buttons/IconButtonContained.js +19 -42
- package/lib/commonjs/components/buttons/IconButtonContained.js.map +1 -1
- package/lib/commonjs/components/buttons/IconButtonSolid.js +15 -31
- package/lib/commonjs/components/buttons/IconButtonSolid.js.map +1 -1
- package/lib/commonjs/components/buttons/__test__/__snapshots__/button.test.tsx.snap +34 -10
- package/lib/commonjs/components/layout/index.js +0 -11
- package/lib/commonjs/components/layout/index.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemAction.js +16 -41
- package/lib/commonjs/components/listitems/ListItemAction.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemCheckbox.js +13 -41
- package/lib/commonjs/components/listitems/ListItemCheckbox.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemHeader.js +2 -2
- package/lib/commonjs/components/listitems/ListItemHeader.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemInfoCopy.js +15 -43
- package/lib/commonjs/components/listitems/ListItemInfoCopy.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemNav.js +17 -48
- package/lib/commonjs/components/listitems/ListItemNav.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemNavAlert.js +19 -50
- package/lib/commonjs/components/listitems/ListItemNavAlert.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemRadio.js +20 -50
- package/lib/commonjs/components/listitems/ListItemRadio.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemRadioWithAmount.js +13 -25
- package/lib/commonjs/components/listitems/ListItemRadioWithAmount.js.map +1 -1
- package/lib/commonjs/components/listitems/ListItemTransaction.js +4 -5
- package/lib/commonjs/components/listitems/ListItemTransaction.js.map +1 -1
- package/lib/commonjs/components/listitems/{PressableListItemsBase.js → PressableListItemBase.js} +7 -7
- package/lib/commonjs/components/listitems/PressableListItemBase.js.map +1 -0
- package/lib/commonjs/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +45 -81
- package/lib/commonjs/components/listitems/__test__/listitem.test.js +3 -3
- package/lib/commonjs/components/listitems/__test__/listitem.test.js.map +1 -1
- package/lib/commonjs/components/listitems/index.js +11 -11
- package/lib/commonjs/components/listitems/index.js.map +1 -1
- package/lib/commonjs/components/modules/ModuleCredential.js +35 -28
- package/lib/commonjs/components/modules/ModuleCredential.js.map +1 -1
- package/lib/commonjs/components/modules/PressableModuleBase.js +17 -11
- package/lib/commonjs/components/modules/PressableModuleBase.js.map +1 -1
- package/lib/commonjs/components/modules/index.js +8 -8
- package/lib/commonjs/components/modules/index.js.map +1 -1
- package/lib/commonjs/components/numberpad/NumberButton.js +12 -28
- package/lib/commonjs/components/numberpad/NumberButton.js.map +1 -1
- package/lib/commonjs/components/numberpad/__test__/__snapshots__/NumberPad.test.tsx.snap +20 -0
- package/lib/commonjs/components/stack/Stack.js +4 -3
- package/lib/commonjs/components/stack/Stack.js.map +1 -1
- package/lib/commonjs/components/tabs/TabItem.js +15 -21
- package/lib/commonjs/components/tabs/TabItem.js.map +1 -1
- package/lib/commonjs/components/typography/H6.js +1 -1
- package/lib/commonjs/components/typography/__test__/__snapshots__/typography.test.tsx.snap +1 -1
- package/lib/commonjs/core/IOAnimations.js +6 -12
- package/lib/commonjs/core/IOAnimations.js.map +1 -1
- package/lib/commonjs/hooks/index.js +28 -0
- package/lib/commonjs/hooks/index.js.map +1 -0
- package/lib/commonjs/hooks/useListItemAnimation.js +40 -0
- package/lib/commonjs/hooks/useListItemAnimation.js.map +1 -0
- package/lib/commonjs/hooks/useScaleAnimation.js +36 -0
- package/lib/commonjs/hooks/useScaleAnimation.js.map +1 -0
- package/lib/commonjs/index.js +11 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/utils/fonts.js +1 -1
- package/lib/commonjs/utils/hooks/index.js +28 -0
- package/lib/commonjs/utils/hooks/index.js.map +1 -0
- package/lib/commonjs/utils/hooks/useSpringPressProgressValue.js +5 -7
- package/lib/commonjs/utils/hooks/useSpringPressProgressValue.js.map +1 -1
- package/lib/module/components/alert/Alert.js +10 -32
- package/lib/module/components/alert/Alert.js.map +1 -1
- package/lib/module/components/alert/AlertEdgeToEdge.js +10 -31
- package/lib/module/components/alert/AlertEdgeToEdge.js.map +1 -1
- package/lib/module/components/banner/Banner.js +10 -33
- package/lib/module/components/banner/Banner.js.map +1 -1
- package/lib/module/components/banner/__test__/__snapshots__/banner.test.tsx.snap +1 -1
- package/lib/module/components/buttons/ButtonLink.js +23 -56
- package/lib/module/components/buttons/ButtonLink.js.map +1 -1
- package/lib/module/components/buttons/ButtonOutline.js +27 -47
- package/lib/module/components/buttons/ButtonOutline.js.map +1 -1
- package/lib/module/components/buttons/ButtonSolid.js +17 -42
- package/lib/module/components/buttons/ButtonSolid.js.map +1 -1
- package/lib/module/components/buttons/IconButton.js +16 -35
- package/lib/module/components/buttons/IconButton.js.map +1 -1
- package/lib/module/components/buttons/IconButtonContained.js +21 -45
- package/lib/module/components/buttons/IconButtonContained.js.map +1 -1
- package/lib/module/components/buttons/IconButtonSolid.js +17 -34
- package/lib/module/components/buttons/IconButtonSolid.js.map +1 -1
- package/lib/module/components/buttons/__test__/__snapshots__/button.test.tsx.snap +34 -10
- package/lib/module/components/layout/index.js +0 -1
- package/lib/module/components/layout/index.js.map +1 -1
- package/lib/module/components/listitems/ListItemAction.js +17 -43
- package/lib/module/components/listitems/ListItemAction.js.map +1 -1
- package/lib/module/components/listitems/ListItemCheckbox.js +15 -43
- package/lib/module/components/listitems/ListItemCheckbox.js.map +1 -1
- package/lib/module/components/listitems/ListItemHeader.js +2 -2
- package/lib/module/components/listitems/ListItemHeader.js.map +1 -1
- package/lib/module/components/listitems/ListItemInfoCopy.js +16 -45
- package/lib/module/components/listitems/ListItemInfoCopy.js.map +1 -1
- package/lib/module/components/listitems/ListItemNav.js +17 -47
- package/lib/module/components/listitems/ListItemNav.js.map +1 -1
- package/lib/module/components/listitems/ListItemNavAlert.js +19 -49
- package/lib/module/components/listitems/ListItemNavAlert.js.map +1 -1
- package/lib/module/components/listitems/ListItemRadio.js +22 -52
- package/lib/module/components/listitems/ListItemRadio.js.map +1 -1
- package/lib/module/components/listitems/ListItemRadioWithAmount.js +14 -26
- package/lib/module/components/listitems/ListItemRadioWithAmount.js.map +1 -1
- package/lib/module/components/listitems/ListItemTransaction.js +3 -4
- package/lib/module/components/listitems/ListItemTransaction.js.map +1 -1
- package/lib/module/components/listitems/{PressableListItemsBase.js → PressableListItemBase.js} +7 -7
- package/lib/module/components/listitems/PressableListItemBase.js.map +1 -0
- package/lib/module/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +45 -81
- package/lib/module/components/listitems/__test__/listitem.test.js +1 -1
- package/lib/module/components/listitems/__test__/listitem.test.js.map +1 -1
- package/lib/module/components/listitems/index.js +1 -1
- package/lib/module/components/listitems/index.js.map +1 -1
- package/lib/module/components/modules/ModuleCredential.js +36 -29
- package/lib/module/components/modules/ModuleCredential.js.map +1 -1
- package/lib/module/components/modules/PressableModuleBase.js +17 -10
- package/lib/module/components/modules/PressableModuleBase.js.map +1 -1
- package/lib/module/components/modules/index.js +1 -1
- package/lib/module/components/modules/index.js.map +1 -1
- package/lib/module/components/numberpad/NumberButton.js +14 -30
- package/lib/module/components/numberpad/NumberButton.js.map +1 -1
- package/lib/module/components/numberpad/__test__/__snapshots__/NumberPad.test.tsx.snap +20 -0
- package/lib/module/components/stack/Stack.js +4 -3
- package/lib/module/components/stack/Stack.js.map +1 -1
- package/lib/module/components/tabs/TabItem.js +18 -24
- package/lib/module/components/tabs/TabItem.js.map +1 -1
- package/lib/module/components/typography/H6.js +1 -1
- package/lib/module/components/typography/__test__/__snapshots__/typography.test.tsx.snap +1 -1
- package/lib/module/core/IOAnimations.js +4 -10
- package/lib/module/core/IOAnimations.js.map +1 -1
- package/lib/module/hooks/index.js +3 -0
- package/lib/module/hooks/index.js.map +1 -0
- package/lib/module/hooks/useListItemAnimation.js +33 -0
- package/lib/module/hooks/useListItemAnimation.js.map +1 -0
- package/lib/module/hooks/useScaleAnimation.js +29 -0
- package/lib/module/hooks/useScaleAnimation.js.map +1 -0
- package/lib/module/index.js +1 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/utils/fonts.js +1 -1
- package/lib/module/utils/hooks/index.js +3 -0
- package/lib/module/utils/hooks/index.js.map +1 -0
- package/lib/module/utils/hooks/useSpringPressProgressValue.js +5 -5
- package/lib/module/utils/hooks/useSpringPressProgressValue.js.map +1 -1
- package/lib/typescript/components/alert/Alert.d.ts.map +1 -1
- package/lib/typescript/components/alert/AlertEdgeToEdge.d.ts.map +1 -1
- package/lib/typescript/components/banner/Banner.d.ts.map +1 -1
- package/lib/typescript/components/buttons/ButtonLink.d.ts.map +1 -1
- package/lib/typescript/components/buttons/ButtonOutline.d.ts.map +1 -1
- package/lib/typescript/components/buttons/ButtonSolid.d.ts.map +1 -1
- package/lib/typescript/components/buttons/IconButton.d.ts.map +1 -1
- package/lib/typescript/components/buttons/IconButtonContained.d.ts.map +1 -1
- package/lib/typescript/components/buttons/IconButtonSolid.d.ts.map +1 -1
- package/lib/typescript/components/layout/index.d.ts +0 -1
- package/lib/typescript/components/layout/index.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemAction.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemCheckbox.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemInfoCopy.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemNav.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemNavAlert.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemRadio.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemRadioWithAmount.d.ts.map +1 -1
- package/lib/typescript/components/listitems/ListItemTransaction.d.ts +1 -1
- package/lib/typescript/components/listitems/ListItemTransaction.d.ts.map +1 -1
- package/lib/typescript/components/listitems/{PressableListItemsBase.d.ts → PressableListItemBase.d.ts} +3 -2
- package/lib/typescript/components/listitems/PressableListItemBase.d.ts.map +1 -0
- package/lib/typescript/components/listitems/index.d.ts +1 -1
- package/lib/typescript/components/listitems/index.d.ts.map +1 -1
- package/lib/typescript/components/modules/ModuleCredential.d.ts +2 -2
- package/lib/typescript/components/modules/ModuleCredential.d.ts.map +1 -1
- package/lib/typescript/components/modules/PressableModuleBase.d.ts.map +1 -1
- package/lib/typescript/components/modules/index.d.ts +1 -1
- package/lib/typescript/components/modules/index.d.ts.map +1 -1
- package/lib/typescript/components/numberpad/NumberButton.d.ts.map +1 -1
- package/lib/typescript/components/stack/Stack.d.ts +4 -3
- package/lib/typescript/components/stack/Stack.d.ts.map +1 -1
- package/lib/typescript/components/tabs/TabItem.d.ts.map +1 -1
- package/lib/typescript/core/IOAnimations.d.ts +6 -10
- package/lib/typescript/core/IOAnimations.d.ts.map +1 -1
- package/lib/typescript/hooks/index.d.ts +3 -0
- package/lib/typescript/hooks/index.d.ts.map +1 -0
- package/lib/typescript/hooks/useListItemAnimation.d.ts +10 -0
- package/lib/typescript/hooks/useListItemAnimation.d.ts.map +1 -0
- package/lib/typescript/hooks/useScaleAnimation.d.ts +10 -0
- package/lib/typescript/hooks/useScaleAnimation.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +1 -0
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/utils/fonts.d.ts +1 -1
- package/lib/typescript/utils/hooks/index.d.ts +3 -0
- package/lib/typescript/utils/hooks/index.d.ts.map +1 -0
- package/lib/typescript/utils/hooks/useSpringPressProgressValue.d.ts +7 -8
- package/lib/typescript/utils/hooks/useSpringPressProgressValue.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/alert/Alert.tsx +7 -46
- package/src/components/alert/AlertEdgeToEdge.tsx +6 -46
- package/src/components/banner/Banner.tsx +6 -52
- package/src/components/banner/__test__/__snapshots__/banner.test.tsx.snap +1 -1
- package/src/components/buttons/ButtonLink.tsx +32 -89
- package/src/components/buttons/ButtonOutline.tsx +26 -60
- package/src/components/buttons/ButtonSolid.tsx +11 -58
- package/src/components/buttons/IconButton.tsx +10 -47
- package/src/components/buttons/IconButtonContained.tsx +21 -57
- package/src/components/buttons/IconButtonSolid.tsx +15 -46
- package/src/components/buttons/__test__/__snapshots__/button.test.tsx.snap +34 -10
- package/src/components/layout/index.tsx +0 -1
- package/src/components/listitems/ListItemAction.tsx +11 -67
- package/src/components/listitems/ListItemCheckbox.tsx +10 -68
- package/src/components/listitems/ListItemHeader.tsx +2 -2
- package/src/components/listitems/ListItemInfoCopy.tsx +11 -71
- package/src/components/listitems/ListItemNav.tsx +13 -74
- package/src/components/listitems/ListItemNavAlert.tsx +18 -92
- package/src/components/listitems/ListItemRadio.tsx +14 -75
- package/src/components/listitems/ListItemRadioWithAmount.tsx +16 -31
- package/src/components/listitems/ListItemTransaction.tsx +3 -7
- package/src/components/listitems/{PressableListItemsBase.tsx → PressableListItemBase.tsx} +7 -6
- package/src/components/listitems/__test__/__snapshots__/listitem.test.tsx.snap +45 -81
- package/src/components/listitems/__test__/listitem.test.tsx +1 -1
- package/src/components/listitems/index.tsx +1 -1
- package/src/components/modules/ModuleCredential.tsx +49 -39
- package/src/components/modules/PressableModuleBase.tsx +15 -8
- package/src/components/modules/index.tsx +1 -1
- package/src/components/numberpad/NumberButton.tsx +12 -43
- package/src/components/numberpad/__test__/__snapshots__/NumberPad.test.tsx.snap +20 -0
- package/src/components/stack/Stack.tsx +11 -3
- package/src/components/tabs/TabItem.tsx +15 -29
- package/src/components/typography/H6.tsx +1 -1
- package/src/components/typography/__test__/__snapshots__/typography.test.tsx.snap +1 -1
- package/src/core/IOAnimations.ts +8 -10
- package/src/hooks/index.tsx +2 -0
- package/src/hooks/useListItemAnimation.tsx +59 -0
- package/src/hooks/useScaleAnimation.tsx +41 -0
- package/src/index.tsx +1 -0
- package/src/utils/fonts.ts +1 -1
- package/src/utils/hooks/index.tsx +2 -0
- package/src/utils/hooks/useSpringPressProgressValue.ts +14 -8
- package/lib/commonjs/components/layout/FooterWithButtons.js +0 -84
- package/lib/commonjs/components/layout/FooterWithButtons.js.map +0 -1
- package/lib/commonjs/components/listitems/PressableListItemsBase.js.map +0 -1
- package/lib/commonjs/components/listitems/hooks/useListItemSpringAnimation.js +0 -56
- package/lib/commonjs/components/listitems/hooks/useListItemSpringAnimation.js.map +0 -1
- package/lib/commonjs/components/modules/hooks/useModuleSpringAnimation.js +0 -41
- package/lib/commonjs/components/modules/hooks/useModuleSpringAnimation.js.map +0 -1
- package/lib/module/components/layout/FooterWithButtons.js +0 -75
- package/lib/module/components/layout/FooterWithButtons.js.map +0 -1
- package/lib/module/components/listitems/PressableListItemsBase.js.map +0 -1
- package/lib/module/components/listitems/hooks/useListItemSpringAnimation.js +0 -47
- package/lib/module/components/listitems/hooks/useListItemSpringAnimation.js.map +0 -1
- package/lib/module/components/modules/hooks/useModuleSpringAnimation.js +0 -34
- package/lib/module/components/modules/hooks/useModuleSpringAnimation.js.map +0 -1
- package/lib/typescript/components/layout/FooterWithButtons.d.ts +0 -16
- package/lib/typescript/components/layout/FooterWithButtons.d.ts.map +0 -1
- package/lib/typescript/components/listitems/PressableListItemsBase.d.ts.map +0 -1
- package/lib/typescript/components/listitems/hooks/useListItemSpringAnimation.d.ts +0 -13
- package/lib/typescript/components/listitems/hooks/useListItemSpringAnimation.d.ts.map +0 -1
- package/lib/typescript/components/modules/hooks/useModuleSpringAnimation.d.ts +0 -10
- package/lib/typescript/components/modules/hooks/useModuleSpringAnimation.d.ts.map +0 -1
- package/src/components/layout/FooterWithButtons.tsx +0 -90
- package/src/components/listitems/hooks/useListItemSpringAnimation.ts +0 -72
- package/src/components/modules/hooks/useModuleSpringAnimation.ts +0 -49
|
@@ -1,26 +1,15 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import {
|
|
2
|
+
import { useState } from "react";
|
|
3
3
|
import { Pressable, View } from "react-native";
|
|
4
4
|
import ReactNativeHapticFeedback from "react-native-haptic-feedback";
|
|
5
|
-
import Animated
|
|
6
|
-
Extrapolate,
|
|
7
|
-
interpolate,
|
|
8
|
-
interpolateColor,
|
|
9
|
-
useAnimatedStyle,
|
|
10
|
-
useDerivedValue,
|
|
11
|
-
useSharedValue,
|
|
12
|
-
withSpring
|
|
13
|
-
} from "react-native-reanimated";
|
|
5
|
+
import Animated from "react-native-reanimated";
|
|
14
6
|
import {
|
|
15
|
-
IOColors,
|
|
16
|
-
IOScaleValues,
|
|
17
7
|
IOSelectionListItemStyles,
|
|
18
8
|
IOSelectionListItemVisualParams,
|
|
19
|
-
IOSpringValues,
|
|
20
9
|
IOStyles,
|
|
21
|
-
hexToRgba,
|
|
22
10
|
useIOTheme
|
|
23
11
|
} from "../../core";
|
|
12
|
+
import { useListItemAnimation } from "../../hooks";
|
|
24
13
|
import { AnimatedCheckbox } from "../checkbox/AnimatedCheckbox";
|
|
25
14
|
import { IOIcons, Icon } from "../icons";
|
|
26
15
|
import { HSpacer, VSpacer } from "../spacer";
|
|
@@ -60,15 +49,8 @@ export const ListItemCheckbox = ({
|
|
|
60
49
|
onValueChange
|
|
61
50
|
}: ListItemCheckboxProps) => {
|
|
62
51
|
const [toggleValue, setToggleValue] = useState(selected ?? false);
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
// Scaling transformation applied when the button is pressed
|
|
67
|
-
const animationScaleValue = IOScaleValues?.basicButton?.pressedState;
|
|
68
|
-
|
|
69
|
-
const progressPressed = useDerivedValue(() =>
|
|
70
|
-
withSpring(isPressed.value, IOSpringValues.button)
|
|
71
|
-
);
|
|
52
|
+
const { onPressIn, onPressOut, scaleAnimatedStyle, backgroundAnimatedStyle } =
|
|
53
|
+
useListItemAnimation();
|
|
72
54
|
|
|
73
55
|
// Theme
|
|
74
56
|
const theme = useIOTheme();
|
|
@@ -79,46 +61,6 @@ export const ListItemCheckbox = ({
|
|
|
79
61
|
? `${value}, ${description}`
|
|
80
62
|
: value;
|
|
81
63
|
|
|
82
|
-
const mapBackgroundStates: Record<string, string> = {
|
|
83
|
-
default: hexToRgba(IOColors[theme["listItem-pressed"]], 0),
|
|
84
|
-
pressed: IOColors[theme["listItem-pressed"]]
|
|
85
|
-
};
|
|
86
|
-
|
|
87
|
-
// Interpolate animation values from `isPressed` values
|
|
88
|
-
const animatedScaleStyle = useAnimatedStyle(() => {
|
|
89
|
-
const scale = interpolate(
|
|
90
|
-
progressPressed.value,
|
|
91
|
-
[0, 1],
|
|
92
|
-
[1, animationScaleValue],
|
|
93
|
-
Extrapolate.CLAMP
|
|
94
|
-
);
|
|
95
|
-
|
|
96
|
-
return {
|
|
97
|
-
transform: [{ scale }]
|
|
98
|
-
};
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
const handlePressIn = useCallback(() => {
|
|
102
|
-
// eslint-disable-next-line functional/immutable-data
|
|
103
|
-
isPressed.value = 1;
|
|
104
|
-
}, [isPressed]);
|
|
105
|
-
const handlePressOut = useCallback(() => {
|
|
106
|
-
// eslint-disable-next-line functional/immutable-data
|
|
107
|
-
isPressed.value = 0;
|
|
108
|
-
}, [isPressed]);
|
|
109
|
-
|
|
110
|
-
const animatedBackgroundStyle = useAnimatedStyle(() => {
|
|
111
|
-
const backgroundColor = interpolateColor(
|
|
112
|
-
progressPressed.value,
|
|
113
|
-
[0, 1],
|
|
114
|
-
[mapBackgroundStates.default, mapBackgroundStates.pressed]
|
|
115
|
-
);
|
|
116
|
-
|
|
117
|
-
return {
|
|
118
|
-
backgroundColor
|
|
119
|
-
};
|
|
120
|
-
});
|
|
121
|
-
|
|
122
64
|
const toggleCheckbox = () => {
|
|
123
65
|
ReactNativeHapticFeedback.trigger("impactLight");
|
|
124
66
|
setToggleValue(!toggleValue);
|
|
@@ -130,9 +72,9 @@ export const ListItemCheckbox = ({
|
|
|
130
72
|
return (
|
|
131
73
|
<Pressable
|
|
132
74
|
onPress={toggleCheckbox}
|
|
133
|
-
onPressIn={
|
|
134
|
-
onPressOut={
|
|
135
|
-
onTouchEnd={
|
|
75
|
+
onPressIn={onPressIn}
|
|
76
|
+
onPressOut={onPressOut}
|
|
77
|
+
onTouchEnd={onPressOut}
|
|
136
78
|
testID="ListItemCheckbox"
|
|
137
79
|
accessible={true}
|
|
138
80
|
accessibilityLabel={accessibilityLabel || fallbackAccessibilityLabel}
|
|
@@ -147,14 +89,14 @@ export const ListItemCheckbox = ({
|
|
|
147
89
|
<Animated.View
|
|
148
90
|
style={[
|
|
149
91
|
IOSelectionListItemStyles.listItem,
|
|
150
|
-
|
|
92
|
+
backgroundAnimatedStyle,
|
|
151
93
|
{ opacity: disabled ? DISABLED_OPACITY : 1 }
|
|
152
94
|
]}
|
|
153
95
|
// This is required to avoid opacity
|
|
154
96
|
// inheritance on Android
|
|
155
97
|
needsOffscreenAlphaCompositing={true}
|
|
156
98
|
>
|
|
157
|
-
<Animated.View style={
|
|
99
|
+
<Animated.View style={scaleAnimatedStyle}>
|
|
158
100
|
<View style={IOSelectionListItemStyles.listItemInner}>
|
|
159
101
|
<View style={[IOStyles.row, { flexShrink: 1 }]}>
|
|
160
102
|
{icon && (
|
|
@@ -87,7 +87,7 @@ export const ListItemHeader = ({
|
|
|
87
87
|
[label, theme, endElement]
|
|
88
88
|
);
|
|
89
89
|
|
|
90
|
-
const
|
|
90
|
+
const listItemAction = useCallback(() => {
|
|
91
91
|
if (endElement) {
|
|
92
92
|
const { type, componentProps } = endElement;
|
|
93
93
|
|
|
@@ -141,7 +141,7 @@ export const ListItemHeader = ({
|
|
|
141
141
|
<View style={IOStyles.flex}>{itemInfoTextComponent}</View>
|
|
142
142
|
{endElement && (
|
|
143
143
|
<View style={{ marginLeft: IOListItemVisualParams.actionMargin }}>
|
|
144
|
-
{
|
|
144
|
+
{listItemAction()}
|
|
145
145
|
</View>
|
|
146
146
|
)}
|
|
147
147
|
</View>
|
|
@@ -1,25 +1,13 @@
|
|
|
1
|
-
import React, { ComponentProps,
|
|
1
|
+
import React, { ComponentProps, useMemo } from "react";
|
|
2
2
|
import { GestureResponderEvent, Pressable, View } from "react-native";
|
|
3
|
-
import Animated
|
|
4
|
-
Extrapolate,
|
|
5
|
-
interpolate,
|
|
6
|
-
interpolateColor,
|
|
7
|
-
useAnimatedStyle,
|
|
8
|
-
useDerivedValue,
|
|
9
|
-
useSharedValue,
|
|
10
|
-
withSpring
|
|
11
|
-
} from "react-native-reanimated";
|
|
3
|
+
import Animated from "react-native-reanimated";
|
|
12
4
|
import {
|
|
13
|
-
IOColors,
|
|
14
5
|
IOListItemStyles,
|
|
15
6
|
IOListItemVisualParams,
|
|
16
|
-
IOScaleValues,
|
|
17
|
-
IOSpringValues,
|
|
18
7
|
IOStyles,
|
|
19
|
-
hexToRgba,
|
|
20
|
-
useIOExperimentalDesign,
|
|
21
8
|
useIOTheme
|
|
22
9
|
} from "../../core";
|
|
10
|
+
import { useListItemAnimation } from "../../hooks";
|
|
23
11
|
import { WithTestID } from "../../utils/types";
|
|
24
12
|
import { IOIcons, Icon } from "../icons";
|
|
25
13
|
import { BodySmall, H6 } from "../typography";
|
|
@@ -46,9 +34,9 @@ export const ListItemInfoCopy = ({
|
|
|
46
34
|
accessibilityHint,
|
|
47
35
|
testID
|
|
48
36
|
}: ListItemInfoCopy) => {
|
|
49
|
-
const isPressed = useSharedValue(0);
|
|
50
|
-
const { isExperimental } = useIOExperimentalDesign();
|
|
51
37
|
const theme = useIOTheme();
|
|
38
|
+
const { onPressIn, onPressOut, scaleAnimatedStyle, backgroundAnimatedStyle } =
|
|
39
|
+
useListItemAnimation();
|
|
52
40
|
|
|
53
41
|
const componentValueToAccessibility = useMemo(
|
|
54
42
|
() => (typeof value === "string" ? value : ""),
|
|
@@ -63,9 +51,7 @@ export const ListItemInfoCopy = ({
|
|
|
63
51
|
[label, componentValueToAccessibility, accessibilityLabel]
|
|
64
52
|
);
|
|
65
53
|
|
|
66
|
-
const foregroundColor =
|
|
67
|
-
? theme["interactiveElem-default"]
|
|
68
|
-
: "blue";
|
|
54
|
+
const foregroundColor = theme["interactiveElem-default"];
|
|
69
55
|
|
|
70
56
|
const listItemInfoCopyContent = (
|
|
71
57
|
<>
|
|
@@ -83,58 +69,12 @@ export const ListItemInfoCopy = ({
|
|
|
83
69
|
</>
|
|
84
70
|
);
|
|
85
71
|
|
|
86
|
-
const mapBackgroundStates: Record<string, string> = {
|
|
87
|
-
default: hexToRgba(IOColors[theme["listItem-pressed"]], 0),
|
|
88
|
-
pressed: IOColors[theme["listItem-pressed"]]
|
|
89
|
-
};
|
|
90
|
-
|
|
91
|
-
// Scaling transformation applied when the button is pressed
|
|
92
|
-
const animationScaleValue = IOScaleValues?.basicButton?.pressedState;
|
|
93
|
-
|
|
94
|
-
const progressPressed = useDerivedValue(() =>
|
|
95
|
-
withSpring(isPressed.value, IOSpringValues.button)
|
|
96
|
-
);
|
|
97
|
-
|
|
98
|
-
// Interpolate animation values from `isPressed` values
|
|
99
|
-
const animatedScaleStyle = useAnimatedStyle(() => {
|
|
100
|
-
const scale = interpolate(
|
|
101
|
-
progressPressed.value,
|
|
102
|
-
[0, 1],
|
|
103
|
-
[1, animationScaleValue],
|
|
104
|
-
Extrapolate.CLAMP
|
|
105
|
-
);
|
|
106
|
-
|
|
107
|
-
return {
|
|
108
|
-
transform: [{ scale }]
|
|
109
|
-
};
|
|
110
|
-
});
|
|
111
|
-
|
|
112
|
-
const animatedBackgroundStyle = useAnimatedStyle(() => {
|
|
113
|
-
const backgroundColor = interpolateColor(
|
|
114
|
-
progressPressed.value,
|
|
115
|
-
[0, 1],
|
|
116
|
-
[mapBackgroundStates.default, mapBackgroundStates.pressed]
|
|
117
|
-
);
|
|
118
|
-
|
|
119
|
-
return {
|
|
120
|
-
backgroundColor
|
|
121
|
-
};
|
|
122
|
-
});
|
|
123
|
-
|
|
124
|
-
const handlePressIn = useCallback(() => {
|
|
125
|
-
// eslint-disable-next-line functional/immutable-data
|
|
126
|
-
isPressed.value = 1;
|
|
127
|
-
}, [isPressed]);
|
|
128
|
-
const handlePressOut = useCallback(() => {
|
|
129
|
-
// eslint-disable-next-line functional/immutable-data
|
|
130
|
-
isPressed.value = 0;
|
|
131
|
-
}, [isPressed]);
|
|
132
|
-
|
|
133
72
|
return (
|
|
134
73
|
<Pressable
|
|
135
74
|
onPress={onPress}
|
|
136
|
-
onPressIn={
|
|
137
|
-
onPressOut={
|
|
75
|
+
onPressIn={onPressIn}
|
|
76
|
+
onPressOut={onPressOut}
|
|
77
|
+
onTouchEnd={onPressOut}
|
|
138
78
|
accessible={true}
|
|
139
79
|
accessibilityLabel={listItemAccessibilityLabel}
|
|
140
80
|
accessibilityHint={accessibilityHint}
|
|
@@ -144,10 +84,10 @@ export const ListItemInfoCopy = ({
|
|
|
144
84
|
<Animated.View
|
|
145
85
|
importantForAccessibility="no-hide-descendants"
|
|
146
86
|
accessibilityElementsHidden
|
|
147
|
-
style={[IOListItemStyles.listItem,
|
|
87
|
+
style={[IOListItemStyles.listItem, backgroundAnimatedStyle]}
|
|
148
88
|
>
|
|
149
89
|
<Animated.View
|
|
150
|
-
style={[IOListItemStyles.listItemInner,
|
|
90
|
+
style={[IOListItemStyles.listItemInner, scaleAnimatedStyle]}
|
|
151
91
|
>
|
|
152
92
|
{icon && (
|
|
153
93
|
<View style={{ marginRight: IOListItemVisualParams.iconMargin }}>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { ComponentProps, ReactNode
|
|
1
|
+
import React, { ComponentProps, ReactNode } from "react";
|
|
2
2
|
import {
|
|
3
3
|
GestureResponderEvent,
|
|
4
4
|
Image,
|
|
@@ -6,27 +6,16 @@ import {
|
|
|
6
6
|
StyleSheet,
|
|
7
7
|
View
|
|
8
8
|
} from "react-native";
|
|
9
|
-
import Animated
|
|
10
|
-
Extrapolate,
|
|
11
|
-
interpolate,
|
|
12
|
-
interpolateColor,
|
|
13
|
-
useAnimatedStyle,
|
|
14
|
-
useDerivedValue,
|
|
15
|
-
useSharedValue,
|
|
16
|
-
withSpring
|
|
17
|
-
} from "react-native-reanimated";
|
|
9
|
+
import Animated from "react-native-reanimated";
|
|
18
10
|
import {
|
|
19
11
|
IOColors,
|
|
20
12
|
IOListItemStyles,
|
|
21
13
|
IOListItemVisualParams,
|
|
22
|
-
IOScaleValues,
|
|
23
14
|
IOSelectionListItemVisualParams,
|
|
24
|
-
IOSpringValues,
|
|
25
15
|
IOStyles,
|
|
26
|
-
hexToRgba,
|
|
27
|
-
useIOExperimentalDesign,
|
|
28
16
|
useIOTheme
|
|
29
17
|
} from "../../core";
|
|
18
|
+
import { useListItemAnimation } from "../../hooks";
|
|
30
19
|
import { WithTestID } from "../../utils/types";
|
|
31
20
|
import { Avatar } from "../avatar";
|
|
32
21
|
import { Badge } from "../badge";
|
|
@@ -114,8 +103,8 @@ export const ListItemNav = ({
|
|
|
114
103
|
loading,
|
|
115
104
|
numberOfLines
|
|
116
105
|
}: ListItemNav) => {
|
|
117
|
-
const
|
|
118
|
-
|
|
106
|
+
const { onPressIn, onPressOut, scaleAnimatedStyle, backgroundAnimatedStyle } =
|
|
107
|
+
useListItemAnimation();
|
|
119
108
|
const theme = useIOTheme();
|
|
120
109
|
|
|
121
110
|
const withMargin = (GraphicalAsset: ReactNode) => (
|
|
@@ -172,56 +161,7 @@ export const ListItemNav = ({
|
|
|
172
161
|
</>
|
|
173
162
|
);
|
|
174
163
|
|
|
175
|
-
const
|
|
176
|
-
default: hexToRgba(IOColors[theme["listItem-pressed"]], 0),
|
|
177
|
-
pressed: IOColors[theme["listItem-pressed"]]
|
|
178
|
-
};
|
|
179
|
-
|
|
180
|
-
const navIconColor = isExperimental
|
|
181
|
-
? theme["interactiveElem-default"]
|
|
182
|
-
: "blue";
|
|
183
|
-
|
|
184
|
-
// Scaling transformation applied when the button is pressed
|
|
185
|
-
const animationScaleValue = IOScaleValues?.basicButton?.pressedState;
|
|
186
|
-
|
|
187
|
-
const progressPressed = useDerivedValue(() =>
|
|
188
|
-
withSpring(isPressed.value, IOSpringValues.button)
|
|
189
|
-
);
|
|
190
|
-
|
|
191
|
-
// Interpolate animation values from `isPressed` values
|
|
192
|
-
const animatedScaleStyle = useAnimatedStyle(() => {
|
|
193
|
-
const scale = interpolate(
|
|
194
|
-
progressPressed.value,
|
|
195
|
-
[0, 1],
|
|
196
|
-
[1, animationScaleValue],
|
|
197
|
-
Extrapolate.CLAMP
|
|
198
|
-
);
|
|
199
|
-
|
|
200
|
-
return {
|
|
201
|
-
transform: [{ scale }]
|
|
202
|
-
};
|
|
203
|
-
});
|
|
204
|
-
|
|
205
|
-
const animatedBackgroundStyle = useAnimatedStyle(() => {
|
|
206
|
-
const backgroundColor = interpolateColor(
|
|
207
|
-
progressPressed.value,
|
|
208
|
-
[0, 1],
|
|
209
|
-
[mapBackgroundStates.default, mapBackgroundStates.pressed]
|
|
210
|
-
);
|
|
211
|
-
|
|
212
|
-
return {
|
|
213
|
-
backgroundColor
|
|
214
|
-
};
|
|
215
|
-
});
|
|
216
|
-
|
|
217
|
-
const handlePressIn = useCallback(() => {
|
|
218
|
-
// eslint-disable-next-line functional/immutable-data
|
|
219
|
-
isPressed.value = 1;
|
|
220
|
-
}, [isPressed]);
|
|
221
|
-
const handlePressOut = useCallback(() => {
|
|
222
|
-
// eslint-disable-next-line functional/immutable-data
|
|
223
|
-
isPressed.value = 0;
|
|
224
|
-
}, [isPressed]);
|
|
164
|
+
const interactiveColor = theme["interactiveElem-default"];
|
|
225
165
|
|
|
226
166
|
const handleOnPress = (event: GestureResponderEvent) => {
|
|
227
167
|
if (!loading) {
|
|
@@ -229,13 +169,12 @@ export const ListItemNav = ({
|
|
|
229
169
|
}
|
|
230
170
|
};
|
|
231
171
|
|
|
232
|
-
const primaryColor: IOColors = isExperimental ? "blueIO-500" : "blue";
|
|
233
|
-
|
|
234
172
|
return (
|
|
235
173
|
<Pressable
|
|
236
174
|
onPress={handleOnPress}
|
|
237
|
-
onPressIn={
|
|
238
|
-
onPressOut={
|
|
175
|
+
onPressIn={onPressIn}
|
|
176
|
+
onPressOut={onPressOut}
|
|
177
|
+
onTouchEnd={onPressOut}
|
|
239
178
|
accessible={true}
|
|
240
179
|
accessibilityState={{ busy: loading }}
|
|
241
180
|
accessibilityLabel={accessibilityLabel}
|
|
@@ -244,10 +183,10 @@ export const ListItemNav = ({
|
|
|
244
183
|
testID={testID}
|
|
245
184
|
>
|
|
246
185
|
<Animated.View
|
|
247
|
-
style={[IOListItemStyles.listItem,
|
|
186
|
+
style={[IOListItemStyles.listItem, backgroundAnimatedStyle]}
|
|
248
187
|
>
|
|
249
188
|
<Animated.View
|
|
250
|
-
style={[IOListItemStyles.listItemInner,
|
|
189
|
+
style={[IOListItemStyles.listItemInner, scaleAnimatedStyle]}
|
|
251
190
|
>
|
|
252
191
|
{/* Possibile graphical assets
|
|
253
192
|
- Icon
|
|
@@ -273,11 +212,11 @@ export const ListItemNav = ({
|
|
|
273
212
|
{avatar && withMargin(<Avatar size="small" {...avatar} />)}
|
|
274
213
|
|
|
275
214
|
<View style={IOStyles.flex}>{listItemNavContent}</View>
|
|
276
|
-
{loading && <LoadingSpinner color={
|
|
215
|
+
{loading && <LoadingSpinner color={interactiveColor} />}
|
|
277
216
|
{!loading && !hideChevron && (
|
|
278
217
|
<Icon
|
|
279
218
|
name="chevronRightListItem"
|
|
280
|
-
color={
|
|
219
|
+
color={interactiveColor}
|
|
281
220
|
size={IOListItemVisualParams.chevronSize}
|
|
282
221
|
/>
|
|
283
222
|
)}
|
|
@@ -1,25 +1,13 @@
|
|
|
1
|
-
import React, { ComponentProps
|
|
1
|
+
import React, { ComponentProps } from "react";
|
|
2
2
|
import { GestureResponderEvent, Pressable, View } from "react-native";
|
|
3
|
-
import Animated
|
|
4
|
-
Extrapolate,
|
|
5
|
-
interpolate,
|
|
6
|
-
interpolateColor,
|
|
7
|
-
useAnimatedStyle,
|
|
8
|
-
useDerivedValue,
|
|
9
|
-
useSharedValue,
|
|
10
|
-
withSpring
|
|
11
|
-
} from "react-native-reanimated";
|
|
3
|
+
import Animated from "react-native-reanimated";
|
|
12
4
|
import {
|
|
13
|
-
IOColors,
|
|
14
5
|
IOListItemStyles,
|
|
15
6
|
IOListItemVisualParams,
|
|
16
|
-
IOScaleValues,
|
|
17
|
-
IOSpringValues,
|
|
18
7
|
IOStyles,
|
|
19
|
-
hexToRgba,
|
|
20
|
-
useIOExperimentalDesign,
|
|
21
8
|
useIOTheme
|
|
22
9
|
} from "../../core";
|
|
10
|
+
import { useListItemAnimation } from "../../hooks";
|
|
23
11
|
import { WithTestID } from "../../utils/types";
|
|
24
12
|
import { Icon } from "../icons";
|
|
25
13
|
import { H6, BodySmall } from "../typography";
|
|
@@ -44,31 +32,17 @@ export const ListItemNavAlert = ({
|
|
|
44
32
|
accessibilityHint,
|
|
45
33
|
testID
|
|
46
34
|
}: ListItemNavAlert) => {
|
|
47
|
-
const
|
|
48
|
-
const {
|
|
49
|
-
|
|
50
|
-
const componentValueToAccessibility = useMemo(
|
|
51
|
-
() => (typeof value === "string" ? value : ""),
|
|
52
|
-
[value]
|
|
53
|
-
);
|
|
35
|
+
const theme = useIOTheme();
|
|
36
|
+
const { onPressIn, onPressOut, scaleAnimatedStyle, backgroundAnimatedStyle } =
|
|
37
|
+
useListItemAnimation();
|
|
54
38
|
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
);
|
|
39
|
+
const componentValueToAccessibility = typeof value === "string" ? value : "";
|
|
40
|
+
const componentDescriptionToAccessibility =
|
|
41
|
+
typeof description === "string" ? description : "";
|
|
59
42
|
|
|
60
|
-
const listItemAccessibilityLabel =
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
? accessibilityLabel
|
|
64
|
-
: `${componentValueToAccessibility}; ${componentDescriptionToAccessibility}`,
|
|
65
|
-
[
|
|
66
|
-
componentDescriptionToAccessibility,
|
|
67
|
-
componentValueToAccessibility,
|
|
68
|
-
accessibilityLabel
|
|
69
|
-
]
|
|
70
|
-
);
|
|
71
|
-
const theme = useIOTheme();
|
|
43
|
+
const listItemAccessibilityLabel =
|
|
44
|
+
accessibilityLabel ??
|
|
45
|
+
`${componentValueToAccessibility}; ${componentDescriptionToAccessibility}`;
|
|
72
46
|
|
|
73
47
|
// TODO: Remove this when legacy look is deprecated https://pagopa.atlassian.net/browse/IOPLT-153
|
|
74
48
|
const listItemNavAlertContent = (
|
|
@@ -93,60 +67,12 @@ export const ListItemNavAlert = ({
|
|
|
93
67
|
</>
|
|
94
68
|
);
|
|
95
69
|
|
|
96
|
-
const iconColor = isExperimental ? theme["interactiveElem-default"] : "blue";
|
|
97
|
-
|
|
98
|
-
const mapBackgroundStates: Record<string, string> = {
|
|
99
|
-
default: hexToRgba(IOColors[theme["listItem-pressed"]], 0),
|
|
100
|
-
pressed: IOColors[theme["listItem-pressed"]]
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
// Scaling transformation applied when the button is pressed
|
|
104
|
-
const animationScaleValue = IOScaleValues?.basicButton?.pressedState;
|
|
105
|
-
|
|
106
|
-
const progressPressed = useDerivedValue(() =>
|
|
107
|
-
withSpring(isPressed.value, IOSpringValues.button)
|
|
108
|
-
);
|
|
109
|
-
|
|
110
|
-
// Interpolate animation values from `isPressed` values
|
|
111
|
-
const animatedScaleStyle = useAnimatedStyle(() => {
|
|
112
|
-
const scale = interpolate(
|
|
113
|
-
progressPressed.value,
|
|
114
|
-
[0, 1],
|
|
115
|
-
[1, animationScaleValue],
|
|
116
|
-
Extrapolate.CLAMP
|
|
117
|
-
);
|
|
118
|
-
|
|
119
|
-
return {
|
|
120
|
-
transform: [{ scale }]
|
|
121
|
-
};
|
|
122
|
-
});
|
|
123
|
-
|
|
124
|
-
const animatedBackgroundStyle = useAnimatedStyle(() => {
|
|
125
|
-
const backgroundColor = interpolateColor(
|
|
126
|
-
progressPressed.value,
|
|
127
|
-
[0, 1],
|
|
128
|
-
[mapBackgroundStates.default, mapBackgroundStates.pressed]
|
|
129
|
-
);
|
|
130
|
-
|
|
131
|
-
return {
|
|
132
|
-
backgroundColor
|
|
133
|
-
};
|
|
134
|
-
});
|
|
135
|
-
|
|
136
|
-
const handlePressIn = useCallback(() => {
|
|
137
|
-
// eslint-disable-next-line functional/immutable-data
|
|
138
|
-
isPressed.value = 1;
|
|
139
|
-
}, [isPressed]);
|
|
140
|
-
const handlePressOut = useCallback(() => {
|
|
141
|
-
// eslint-disable-next-line functional/immutable-data
|
|
142
|
-
isPressed.value = 0;
|
|
143
|
-
}, [isPressed]);
|
|
144
|
-
|
|
145
70
|
return (
|
|
146
71
|
<Pressable
|
|
147
72
|
onPress={onPress}
|
|
148
|
-
onPressIn={
|
|
149
|
-
onPressOut={
|
|
73
|
+
onPressIn={onPressIn}
|
|
74
|
+
onPressOut={onPressOut}
|
|
75
|
+
onTouchEnd={onPressOut}
|
|
150
76
|
accessible={true}
|
|
151
77
|
accessibilityLabel={listItemAccessibilityLabel}
|
|
152
78
|
accessibilityHint={accessibilityHint}
|
|
@@ -154,12 +80,12 @@ export const ListItemNavAlert = ({
|
|
|
154
80
|
testID={testID}
|
|
155
81
|
>
|
|
156
82
|
<Animated.View
|
|
157
|
-
style={[IOListItemStyles.listItem,
|
|
83
|
+
style={[IOListItemStyles.listItem, backgroundAnimatedStyle]}
|
|
158
84
|
importantForAccessibility="no-hide-descendants"
|
|
159
85
|
accessibilityElementsHidden
|
|
160
86
|
>
|
|
161
87
|
<Animated.View
|
|
162
|
-
style={[IOListItemStyles.listItemInner,
|
|
88
|
+
style={[IOListItemStyles.listItemInner, scaleAnimatedStyle]}
|
|
163
89
|
>
|
|
164
90
|
{!withoutIcon && (
|
|
165
91
|
<View style={{ marginRight: IOListItemVisualParams.iconMargin }}>
|
|
@@ -174,7 +100,7 @@ export const ListItemNavAlert = ({
|
|
|
174
100
|
<View style={{ marginLeft: IOListItemVisualParams.iconMargin }}>
|
|
175
101
|
<Icon
|
|
176
102
|
name="chevronRightListItem"
|
|
177
|
-
color={
|
|
103
|
+
color={theme["interactiveElem-default"]}
|
|
178
104
|
size={IOListItemVisualParams.chevronSize}
|
|
179
105
|
/>
|
|
180
106
|
</View>
|