Skip to content

Commit

Permalink
fix(Picker): 增加弹开 & 联动
Browse files Browse the repository at this point in the history
  • Loading branch information
ChenlingasMx authored and hy committed Apr 8, 2023
1 parent a2d09e5 commit 5ec6f9b
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions example/examples/src/routes/Picker/index.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import React from 'react';
import {SafeAreaView} from 'react-native';
import {Picker, Button, Spacing} from '@uiw/react-native';
import {ComProps} from '../../routes';
import Layout, {Container} from '../../Layout';
import { SafeAreaView } from 'react-native';
import { Picker, Button, Spacing } from '@uiw/react-native';
import { ComProps } from '../../routes';
import Layout, { Container } from '../../Layout';

const {Header, Body, Card, Footer} = Layout;
const { Header, Body, Card, Footer } = Layout;

export interface PickerViewProps extends ComProps {}
export interface PickerViewProps extends ComProps { }

export default function (props: PickerViewProps) {
const {route} = props;
const { route } = props;
const description = route.params.description;
const title = route.params.title;
const [value, setValue] = React.useState(['2', '22', '221']);
Expand All @@ -24,24 +24,24 @@ export default function (props: PickerViewProps) {
label: '南京市',
value: '11',
children: [
{label: '宣武区', value: '111'},
{label: '雨花台区', value: '112'},
{ label: '宣武区', value: '111' },
{ label: '雨花台区', value: '112' },
],
},
{
label: '苏州市',
value: '12',
children: [{label: '苏州区', value: '121'}],
children: [{ label: '苏州区', value: '121' }],
},
],
},
{label: '北京市', value: '2', children: [{label: '北京市', value: '22', children: [{label: '朝阳区', value: '221'}]}]},
{ label: '北京市', value: '2', children: [{ label: '北京市', value: '22', children: [{ label: '朝阳区', value: '221' }] }] },
];

const arr2 = [
{label: '3', value: '3'},
{label: '4', value: '4'},
{label: '5', value: '5'},
{ label: '3', value: '3' },
{ label: '4', value: '4' },
{ label: '5', value: '5' },
];

return (
Expand Down

0 comments on commit 5ec6f9b

Please sign in to comment.