File tree Expand file tree Collapse file tree 1 file changed +21
-25
lines changed Expand file tree Collapse file tree 1 file changed +21
-25
lines changed Original file line number Diff line number Diff line change 1- import { StyleSheet , Text } from 'react-native'
2- import React from 'react'
1+ import { StyleSheet , Text } from 'react-native' ;
2+ import React from 'react' ;
33
44const icons = {
5- copy : "📋" ,
6- done : "✅" ,
7- close : "✕" ,
8- chevronDown : "▼" ,
9- chevronUp : "▲" ,
10- error : "❌"
11- } ;
5+ copy : '📋' ,
6+ done : '✅' ,
7+ close : '✕' ,
8+ chevronDown : '▼' ,
9+ chevronUp : '▲' ,
10+ error : '❌' ,
11+ } ;
1212
13-
14- interface IconProps {
15- type :'copy' | 'done' | 'close' | 'chevronDown' | 'chevronUp' | 'error'
16- }
17-
18- const Icon :React . FunctionComponent < IconProps > = ( { type} ) => {
19- return (
20- < Text style = { styles . closeButton } > { icons [ type ] } </ Text >
21- )
13+ interface IconProps {
14+ type : 'copy' | 'done' | 'close' | 'chevronDown' | 'chevronUp' | 'error' ;
2215}
2316
24- export default Icon
17+ const Icon : React . FunctionComponent < IconProps > = ( { type } ) => {
18+ return < Text style = { styles . closeButton } > { icons [ type ] } </ Text > ;
19+ } ;
2520
21+ export default Icon ;
2622
2723const styles = StyleSheet . create ( {
28- closeButton : {
29- fontSize : 18 ,
30- color : '#666' ,
31- fontWeight : 'bold' ,
32- } ,
33- } ) ;
24+ closeButton : {
25+ fontSize : 18 ,
26+ color : '#666' ,
27+ fontWeight : 'bold' ,
28+ } ,
29+ } ) ;
You can’t perform that action at this time.
0 commit comments