-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add participating stores to Rewards screen (#129)
* Add participating stores * Add testing bypass back in dev mode * Fix child key warning * Wrap store names in TouchableOpacity * Update for design changes * Styling switches on guest mode
- Loading branch information
Showing
11 changed files
with
95 additions
and
27 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { useNavigation } from '@react-navigation/native'; | ||
import PropTypes from 'prop-types'; | ||
import React from 'react'; | ||
import { TouchableOpacity } from 'react-native'; | ||
import { ColumnContainer } from '../../styled/shared'; | ||
import { Overline, Subhead } from '../BaseComponents'; | ||
|
||
export default function ParticipatingStores({ participating, guest }) { | ||
const navigation = useNavigation(); | ||
return ( | ||
<ColumnContainer | ||
style={guest ? { marginLeft: 16, marginBottom: 24 } : { marginTop: 28 }}> | ||
<Overline style={{}}>Participating Stores</Overline> | ||
{participating.map((store) => { | ||
return ( | ||
<TouchableOpacity key={store.id}> | ||
<Subhead | ||
style={{ marginLeft: 12 }} | ||
onPress={() => | ||
navigation.navigate('Stores', { | ||
currentStore: store, | ||
}) | ||
}> | ||
{store.storeName} | ||
</Subhead> | ||
</TouchableOpacity> | ||
); | ||
})} | ||
<Subhead style={{ marginLeft: 12 }}>More stores coming soon!</Subhead> | ||
</ColumnContainer> | ||
); | ||
} | ||
|
||
ParticipatingStores.propTypes = { | ||
participating: PropTypes.array.isRequired, | ||
guest: PropTypes.bool.isRequired, | ||
}; |
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
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