Skip to content

Commit 0a44da5

Browse files
authored
Merge pull request #4904 from GeekyAnts/fix/3.4-example-changes
Fix/3.4 example changes
2 parents dbc6406 + b161f03 commit 0a44da5

File tree

8 files changed

+57
-59
lines changed

8 files changed

+57
-59
lines changed

example/storybook/stories/components/basic/FlatList/Basic.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,9 @@ export const Example = () => {
6262
<Box
6363
borderBottomWidth="1"
6464
_dark={{
65-
borderColor: 'gray.600',
65+
borderColor: 'muted.50',
6666
}}
67-
borderColor="coolGray.200"
67+
borderColor="muted.800"
6868
pl="4"
6969
pr="5"
7070
py="2"

example/storybook/stories/components/basic/ScrollView/Basic.tsx

Lines changed: 49 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -3,56 +3,54 @@ import { ScrollView, VStack, Center, useTheme, Heading } from 'native-base';
33
export const Example = () => {
44
const { colors } = useTheme();
55
return (
6-
<Center>
7-
<ScrollView
8-
maxW="300"
9-
h="80"
10-
_contentContainerStyle={{
11-
px: '20px',
12-
mb: '4',
13-
minW: '72',
14-
}}
15-
>
16-
<Center mt="3" mb="4">
17-
<Heading fontSize="xl">Cyan</Heading>
18-
</Center>
19-
<VStack flex="1">
20-
{Object.keys(colors.cyan).map((key, index) => {
21-
if (index >= 1 && index <= 5)
22-
return (
23-
<Center py="4" bg={`cyan.${key}`}>
24-
{key}
25-
</Center>
26-
);
27-
})}
28-
</VStack>
29-
<Center mt="8" mb="4">
30-
<Heading fontSize="xl">Yellow</Heading>
31-
</Center>
32-
<VStack flex="1">
33-
{Object.keys(colors.cyan).map((key, index) => {
34-
if (index >= 1 && index <= 5)
35-
return (
36-
<Center py="4" bg={`yellow.${key}`}>
37-
{key}
38-
</Center>
39-
);
40-
})}
41-
</VStack>
42-
<Center mt="8" mb="4">
43-
<Heading fontSize="xl"> Violet</Heading>
44-
</Center>
45-
<VStack flex="1">
46-
{Object.keys(colors.violet).map((key, index) => {
47-
if (index >= 1 && index <= 5)
48-
return (
49-
<Center py="4" bg={`violet.${key}`}>
50-
{key}
51-
</Center>
52-
);
53-
})}
54-
</VStack>
55-
</ScrollView>
56-
</Center>
6+
<ScrollView
7+
maxW="300"
8+
h="80"
9+
_contentContainerStyle={{
10+
px: '20px',
11+
mb: '4',
12+
minW: '72',
13+
}}
14+
>
15+
<Center mt="3" mb="4">
16+
<Heading fontSize="xl">Cyan</Heading>
17+
</Center>
18+
<VStack flex="1">
19+
{Object.keys(colors.cyan).map((key, index) => {
20+
if (index >= 1 && index <= 5)
21+
return (
22+
<Center py="4" bg={`cyan.${key}`}>
23+
{key}
24+
</Center>
25+
);
26+
})}
27+
</VStack>
28+
<Center mt="8" mb="4">
29+
<Heading fontSize="xl">Yellow</Heading>
30+
</Center>
31+
<VStack flex="1">
32+
{Object.keys(colors.cyan).map((key, index) => {
33+
if (index >= 1 && index <= 5)
34+
return (
35+
<Center py="4" bg={`yellow.${key}`}>
36+
{key}
37+
</Center>
38+
);
39+
})}
40+
</VStack>
41+
<Center mt="8" mb="4">
42+
<Heading fontSize="xl"> Violet</Heading>
43+
</Center>
44+
<VStack flex="1">
45+
{Object.keys(colors.violet).map((key, index) => {
46+
if (index >= 1 && index <= 5)
47+
return (
48+
<Center py="4" bg={`violet.${key}`}>
49+
{key}
50+
</Center>
51+
);
52+
})}
53+
</VStack>
54+
</ScrollView>
5755
);
5856
};

example/storybook/stories/components/composites/Menu/Basic.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Menu, HamburgerIcon, Box, Pressable } from 'native-base';
33

44
export function Example() {
55
return (
6-
<Box h="80%" w="90%" alignItems="flex-start">
6+
<Box w="90%" alignItems="center">
77
<Menu
88
w="190"
99
trigger={(triggerProps) => {

example/storybook/stories/components/composites/Menu/Group.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Menu, Divider, HamburgerIcon, Box, Pressable } from 'native-base';
33

44
export function Example() {
55
return (
6-
<Box h="80%" w="90%" alignItems="flex-start">
6+
<Box w="90%" alignItems="center">
77
<Menu
88
w="190"
99
trigger={(triggerProps) => {

example/storybook/stories/components/composites/Menu/MenuOptionsGroup.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Menu, Divider, HamburgerIcon, Box, Pressable } from 'native-base';
33

44
export function Example() {
55
return (
6-
<Box h="80%" w="90%" alignItems="flex-start">
6+
<Box w="90%" alignItems="center">
77
<Menu
88
closeOnSelect={false}
99
w="190"

example/storybook/stories/components/composites/Popover/Basic.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Popover, Button, Box } from 'native-base';
33

44
export function Example() {
55
return (
6-
<Box h="60%" w="100%" alignItems="center">
6+
<Box w="100%" alignItems="center">
77
<Popover
88
trigger={(triggerProps) => {
99
return (

example/storybook/stories/components/composites/Popover/PopoverPositions.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export function Example() {
66
const [isOpen, setIsOpen] = useState(false);
77

88
return (
9-
<Box h="60%" w="100%" alignItems="center">
9+
<Box w="100%" alignItems="center">
1010
<VStack space={6} alignSelf="flex-start" w="100%">
1111
<Popover
1212
// @ts-ignore

example/storybook/stories/components/composites/Popover/RefEg.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Popover, Button, Input, FormControl, Box } from 'native-base';
44
export function Example() {
55
const initialFocusRef = React.useRef(null);
66
return (
7-
<Box h="60%" w="100%" alignItems="center">
7+
<Box w="100%" alignItems="center">
88
<Popover
99
initialFocusRef={initialFocusRef}
1010
trigger={(triggerProps) => {

0 commit comments

Comments
 (0)