mirror of
https://github.com/balzack/databag.git
synced 2025-03-13 00:50:03 +00:00
Merge branch 'main' of https://github.com/balzack/databag into main
This commit is contained in:
commit
3e37cde3f7
@ -3,7 +3,8 @@ import { FlatList, ScrollView, View, TextInput, TouchableOpacity, Text } from 'r
|
||||
import { styles } from './Cards.styled';
|
||||
import { useCards } from './useCards.hook';
|
||||
import { SafeAreaView } from 'react-native-safe-area-context';
|
||||
import Ionicons from '@expo/vector-icons/AntDesign';
|
||||
import AntIcons from '@expo/vector-icons/AntDesign';
|
||||
import MatIcons from '@expo/vector-icons/MaterialCommunityIcons';
|
||||
import { CardItem } from './cardItem/CardItem';
|
||||
import Colors from 'constants/Colors';
|
||||
import { useNavigation } from '@react-navigation/native';
|
||||
@ -15,22 +16,22 @@ export function CardsTitle({ state, actions, openRegistry }) {
|
||||
<View style={styles.title}>
|
||||
{ state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.unsort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.text} />
|
||||
<MatIcons style={styles.icon} name="sort-alphabetical-ascending" size={18} color={Colors.text} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
{ !state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.sort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.disabled} />
|
||||
<MatIcons style={styles.icon} name="sort-alphabetical-ascending" size={18} color={Colors.disabled} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
<View style={styles.inputwrapper}>
|
||||
<Ionicons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<AntIcons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<TextInput style={styles.inputfield} value={state.filter} onChangeText={actions.setFilter}
|
||||
autoCapitalize="none" placeholderTextColor={Colors.disabled} placeholder="Contacts" />
|
||||
<View style={styles.space} />
|
||||
</View>
|
||||
<TouchableOpacity style={styles.add} onPress={() => openRegistry(navigation)}>
|
||||
<Ionicons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
<AntIcons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
<Text style={styles.newtext}>New</Text>
|
||||
</TouchableOpacity>
|
||||
</View>
|
||||
@ -66,22 +67,22 @@ export function Cards({ openRegistry, openContact }) {
|
||||
<View style={styles.topbar}>
|
||||
{ state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.unsort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.text} />
|
||||
<AntIcons style={styles.icon} name="menufold" size={18} color={Colors.text} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
{ !state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.sort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.disabled} />
|
||||
<AntIcons style={styles.icon} name="menufold" size={18} color={Colors.disabled} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
<View style={styles.inputwrapper}>
|
||||
<Ionicons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<AntIcons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<TextInput style={styles.inputfield} value={state.filter} onChangeText={actions.setFilter}
|
||||
autoCapitalize="none" placeholderTextColor={Colors.disabled} placeholder="Contacts" />
|
||||
<View style={styles.space} />
|
||||
</View>
|
||||
<TouchableOpacity style={styles.add} onPress={openRegistry}>
|
||||
<Ionicons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
<AntIcons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
<Text style={styles.newtext}>New</Text>
|
||||
</TouchableOpacity>
|
||||
</View>
|
||||
@ -106,21 +107,21 @@ export function Cards({ openRegistry, openContact }) {
|
||||
<SafeAreaView edges={['top', 'right']} style={styles.searchbar}>
|
||||
{ state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.unsort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.text} />
|
||||
<AntIcons style={styles.icon} name="menufold" size={18} color={Colors.text} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
{ !state.sorting && (
|
||||
<TouchableOpacity style={styles.sort} onPress={actions.sort}>
|
||||
<Ionicons style={styles.icon} name="menufold" size={18} color={Colors.disabled} />
|
||||
<AntIcons style={styles.icon} name="menufold" size={18} color={Colors.disabled} />
|
||||
</TouchableOpacity>
|
||||
)}
|
||||
<View style={styles.inputwrapper}>
|
||||
<Ionicons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<AntIcons style={styles.icon} name="search1" size={16} color={Colors.disabled} />
|
||||
<TextInput style={styles.inputfield} value={state.filter} onChangeText={actions.setFilter}
|
||||
autoCapitalize="none" placeholderTextColor={Colors.disabled} placeholder="Contacts" />
|
||||
</View>
|
||||
<TouchableOpacity style={styles.add} onPress={openRegistry}>
|
||||
<Ionicons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
<AntIcons name={'adduser'} size={16} color={Colors.white} style={[styles.box, { transform: [ { rotateY: "180deg" }, ]} ]}/>
|
||||
</TouchableOpacity>
|
||||
</SafeAreaView>
|
||||
</View>
|
||||
|
@ -99,7 +99,6 @@ export const styles = StyleSheet.create({
|
||||
},
|
||||
sort: {
|
||||
paddingRight: 12,
|
||||
transform: [ { rotate: "270deg" }, ]
|
||||
},
|
||||
findarea: {
|
||||
borderTopWidth: 1,
|
||||
|
Loading…
Reference in New Issue
Block a user