-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a4593c7
commit b71b67d
Showing
10 changed files
with
114 additions
and
413 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,50 @@ | ||
import React from 'react'; | ||
import {Text, View} from 'react-native'; | ||
import {Divider} from '@uiw/react-native'; | ||
import {Divider, Theme} from '@uiw/react-native'; | ||
import {ComProps} from '../../routes'; | ||
import Layout, {Container} from '../../Layout'; | ||
import {useTheme} from '@shopify/restyle'; | ||
|
||
const {Header, Body, Card, Footer} = Layout; | ||
|
||
export interface DividerViewProps extends ComProps {} | ||
|
||
export default class DividerView extends React.Component<DividerViewProps> { | ||
render() { | ||
const {route} = this.props; | ||
const description = route.params.description; | ||
const title = route.params.title; | ||
return ( | ||
<Container> | ||
<Layout> | ||
<Header title={title} description={description} /> | ||
<Body> | ||
<Card title="横向分割线" style={{backgroundColor: '#ffffff'}}> | ||
<Text>分割线</Text> | ||
<Divider label="OR" /> | ||
<Text>分割线</Text> | ||
<Divider label="暂无数据" /> | ||
<Text>分割线</Text> | ||
<Divider label="调整间隔" gutter={30} /> | ||
<Text>分割线</Text> | ||
</Card> | ||
export default function DividerView(props: DividerViewProps) { | ||
const {route} = props; | ||
const description = route.params.description; | ||
const title = route.params.title; | ||
const theme = useTheme<Theme>(); | ||
return ( | ||
<Container> | ||
<Layout style={{backgroundColor: theme.colors.background}}> | ||
<Header title={title} description={description} /> | ||
<Body> | ||
<Card title="横向分割线" style={{backgroundColor: theme.colors.background}}> | ||
<Divider label="OR" /> | ||
<Text /> | ||
<Divider label="暂无数据" /> | ||
<Text /> | ||
<Divider label="调整间隔" gutter={30} /> | ||
<Text /> | ||
</Card> | ||
|
||
<Card title="分割线标题位置" style={{backgroundColor: '#ffffff'}}> | ||
<Text>分割线</Text> | ||
<Divider label="left" orientation="left" labelStyle={{fontWeight: 'bold'}} /> | ||
<Text>分割线</Text> | ||
<Divider label="center" labelStyle={{fontWeight: 'bold'}} /> | ||
<Text>分割线</Text> | ||
<Divider label="right" orientation="right" labelStyle={{fontWeight: 'bold'}} /> | ||
</Card> | ||
<Card title="分割线标题位置" style={{backgroundColor: theme.colors.background}}> | ||
<Text /> | ||
<Divider label="left" orientation="left" labelStyle={{fontWeight: 'bold'}} /> | ||
<Text /> | ||
<Divider label="center" labelStyle={{fontWeight: 'bold'}} /> | ||
<Text /> | ||
<Divider label="right" orientation="right" labelStyle={{fontWeight: 'bold'}} /> | ||
</Card> | ||
|
||
<Card title="纵向分割线" style={{backgroundColor: '#ffffff'}}> | ||
<View style={{height: 200}}> | ||
<Divider type="vertical" label="OR" /> | ||
</View> | ||
</Card> | ||
</Body> | ||
<Footer /> | ||
</Layout> | ||
</Container> | ||
); | ||
} | ||
<Card title="纵向分割线" style={{backgroundColor: theme.colors.background}}> | ||
<View style={{height: 200}}> | ||
<Divider type="vertical" label="OR" /> | ||
</View> | ||
</Card> | ||
</Body> | ||
<Footer /> | ||
</Layout> | ||
</Container> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.