Skip to content

Commit 34065fb

Browse files
authored
fixes AMA example error on useReanimatedTiming screen (#242)
1 parent d87b469 commit 34065fb

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

examples/shared/src/screens/UseReanimatedTimingScreen.tsx

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { useReanimatedTiming } from '@react-native-ama/animations';
22
import { Text } from '@react-native-ama/react-native';
33
import * as React from 'react';
4-
import { Dimensions, StyleSheet, View } from 'react-native';
4+
import { Dimensions, Linking, StyleSheet, View } from 'react-native';
55
import Animated, {
66
useAnimatedStyle,
77
useSharedValue,
@@ -42,8 +42,17 @@ export const UseReanimatedTimingScreen = () => {
4242
<Spacer height="big" />
4343
<Text style={styles.intro}>
4444
This example shows how to use the{' '}
45-
<Text onPress={() => {}}>getAnimationDuration</Text> with Reanimated for
46-
a more accessible animations.
45+
<Text
46+
accessibilityRole="link"
47+
style={styles.underline}
48+
onPress={() =>
49+
Linking.openURL(
50+
'https://commerce.nearform.com/open-source/react-native-ama/docs/hooks/useAnimationDuration#getanimationduration',
51+
)
52+
}>
53+
getAnimationDuration
54+
</Text>{' '}
55+
with Reanimated for a more accessible animations.
4756
</Text>
4857
<Spacer height="big" />
4958
<Animated.View style={[styles.box, animatedStyles]} />
@@ -69,4 +78,7 @@ const styles = StyleSheet.create({
6978
intro: {
7079
lineHeight: theme.lineHeight.medium,
7180
},
81+
underline: {
82+
textDecorationLine: 'underline',
83+
},
7284
});

0 commit comments

Comments
 (0)