-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add seperator field and confs for menu item
- Loading branch information
1 parent
1f5c32c
commit ce2e099
Showing
8 changed files
with
101 additions
and
43 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
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import isEqual from 'lodash.isequal'; | ||
import React, { memo, useMemo } from 'react'; | ||
import { View } from 'react-native'; | ||
|
||
import { BORDER_LIGHT_COLOR, BORDER_DARK_COLOR } from './constants'; | ||
|
||
type SeperatorProps = { | ||
theme: 'light' | 'dark'; | ||
}; | ||
|
||
const Seperator = ({ theme }: SeperatorProps) => { | ||
const styles = useMemo(() => { | ||
return { | ||
width: '100%', | ||
height: 8, | ||
backgroundColor: | ||
theme === 'dark' ? BORDER_DARK_COLOR : BORDER_LIGHT_COLOR, | ||
}; | ||
}, [theme]); | ||
|
||
return <View style={styles} />; | ||
}; | ||
|
||
export default memo(Seperator, isEqual); |
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