Created
March 23, 2020 17:03
-
-
Save t1amat9409/362ad490c0a523d0d2d75b02d0c6e1dc to your computer and use it in GitHub Desktop.
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
return ( | |
<$Frame ref={forwardedRef}> | |
<$Page androidStatusBarBackground={nsRed} ref={this.pageRef} actionBarHidden={true}> | |
<$GridLayout background={'#eee'} rows={[ | |
new ItemSpec(1, 'auto'), //Header | |
new ItemSpec(1, 'star'), //Body | |
new ItemSpec(40, 'pixel') //Bottom Red Strip | |
]}> | |
<$GridLayout rows={[ | |
new ItemSpec(1, 'star'), //Background | |
new ItemSpec(1, 'auto') //Search | |
]} row={0}> | |
{this.renderHeaderContent()} | |
{this.renderSearchBox()} | |
</$GridLayout> | |
<$ScrollView row={1} background={"#eee"}> | |
<$StackLayout padding={`15 0`}> | |
{ | |
users.map((item, i) => { | |
return ( | |
<$GridLayout onTap={(args:any) => { | |
alert(`Hey, my username is ${item.username}!`) | |
}} columns={[ | |
new ItemSpec(50, 'pixel'), | |
new ItemSpec(1, 'star'), | |
new ItemSpec(1, 'auto') | |
]} key={i} style={{ | |
height: 80, | |
margin: `5 20`, | |
padding: `0 15`, | |
background: '#fff', | |
borderRadius: 10 | |
}}> | |
<$StackLayout col={0} style={{ | |
height: 50, | |
width: 50, | |
borderRadius: 25, | |
background: normalRed | |
}} /> | |
<$StackLayout verticalAlignment={'middle'} padding={`5 10`} col={1}> | |
<$Label fontSize={16} textWrap text={item.username} /> | |
<$Label textWrap text={item.company} /> | |
</$StackLayout> | |
<$Label col={2} verticalAlignment={'middle'} className={`Ionicons size20`} text={IconSet.Ionicons['ios-arrow-forward']} /> | |
</$GridLayout> | |
) | |
}) | |
} | |
</$StackLayout> | |
</$ScrollView> | |
<$StackLayout row={2} background={normalRed} /> | |
</$GridLayout> | |
</$Page> | |
</$Frame> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment