mirror of
https://github.com/balzack/databag.git
synced 2025-02-12 03:29:16 +00:00
updating style for light mode
This commit is contained in:
parent
65564c808a
commit
ffb44c1f5d
@ -47,8 +47,8 @@ const LightColors = {
|
|||||||
confirmedIndicator: '#88bb00',
|
confirmedIndicator: '#88bb00',
|
||||||
unknownIndicator: '#dddddd',
|
unknownIndicator: '#dddddd',
|
||||||
errorIndicator: '#ffaaaa',
|
errorIndicator: '#ffaaaa',
|
||||||
horizontalDivider: '#bbbbbb',
|
horizontalDivider: '#dddddd',
|
||||||
verticalDivider: '#aaaaaa',
|
verticalDivider: '#dddddd',
|
||||||
itemDivider: '#cccccc',
|
itemDivider: '#cccccc',
|
||||||
unreadIndicator: '#00aa00',
|
unreadIndicator: '#00aa00',
|
||||||
enabledIndicator: '#8fbea7',
|
enabledIndicator: '#8fbea7',
|
||||||
|
@ -183,6 +183,8 @@ const Strings = [
|
|||||||
agree: 'I agree to Terms of Service',
|
agree: 'I agree to Terms of Service',
|
||||||
terms: 'View Terms of Service',
|
terms: 'View Terms of Service',
|
||||||
policy: 'Terms of Use and User Policy',
|
policy: 'Terms of Use and User Policy',
|
||||||
|
|
||||||
|
editMessage: 'Edit Message Text',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
languageCode: 'fr',
|
languageCode: 'fr',
|
||||||
@ -362,6 +364,8 @@ const Strings = [
|
|||||||
agree: 'J\'accepte les Conditions d\'Utilisation',
|
agree: 'J\'accepte les Conditions d\'Utilisation',
|
||||||
terms: 'Afficher les Conditions d\'Utilisation',
|
terms: 'Afficher les Conditions d\'Utilisation',
|
||||||
policy: 'Conditions d\'Utilisation et Politique d\'Utilisation',
|
policy: 'Conditions d\'Utilisation et Politique d\'Utilisation',
|
||||||
|
|
||||||
|
editMessage: 'Modifier le Texte du Message',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
languageCode: 'es',
|
languageCode: 'es',
|
||||||
@ -541,6 +545,8 @@ const Strings = [
|
|||||||
agree: 'Acepto los Términos de Servicio',
|
agree: 'Acepto los Términos de Servicio',
|
||||||
terms: 'Ver Términos de Servicio',
|
terms: 'Ver Términos de Servicio',
|
||||||
policy: 'Términos de Uso y Política de Usuario',
|
policy: 'Términos de Uso y Política de Usuario',
|
||||||
|
|
||||||
|
editMessage: 'Editar Texto del Mensaje',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
languageCode: 'de',
|
languageCode: 'de',
|
||||||
@ -720,6 +726,8 @@ const Strings = [
|
|||||||
agree: 'Ich akzeptiere die Nutzungsbedingungen',
|
agree: 'Ich akzeptiere die Nutzungsbedingungen',
|
||||||
terms: 'Nutzungsbedingungen anzeigen',
|
terms: 'Nutzungsbedingungen anzeigen',
|
||||||
policy: 'Nutzungsbedingungen und Benutzerrichtlinien',
|
policy: 'Nutzungsbedingungen und Benutzerrichtlinien',
|
||||||
|
|
||||||
|
editMessage: 'Nachrichtentext Bearbeiten',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
languageCode: 'pt',
|
languageCode: 'pt',
|
||||||
@ -885,6 +893,7 @@ const Strings = [
|
|||||||
agree: 'Eu concordo com os Termos de Serviço',
|
agree: 'Eu concordo com os Termos de Serviço',
|
||||||
terms: 'Ver Termos de Serviço',
|
terms: 'Ver Termos de Serviço',
|
||||||
policy: 'Termos de Uso e Política do Usuário',
|
policy: 'Termos de Uso e Política do Usuário',
|
||||||
|
editMessage: 'Editar Texto da Mensagem',
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -8,6 +8,7 @@ import Ionicons from 'react-native-vector-icons/AntDesign';
|
|||||||
import { Logo } from 'utils/Logo';
|
import { Logo } from 'utils/Logo';
|
||||||
import { AddTopic } from './addTopic/AddTopic';
|
import { AddTopic } from './addTopic/AddTopic';
|
||||||
import { TopicItem } from './topicItem/TopicItem';
|
import { TopicItem } from './topicItem/TopicItem';
|
||||||
|
import { BlurView } from "@react-native-community/blur";
|
||||||
|
|
||||||
export function Conversation({ navigation, cardId, channelId, closeConversation, openDetails, shareIntent, setShareIntent }) {
|
export function Conversation({ navigation, cardId, channelId, closeConversation, openDetails, shareIntent, setShareIntent }) {
|
||||||
|
|
||||||
@ -66,7 +67,6 @@ export function Conversation({ navigation, cardId, channelId, closeConversation,
|
|||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
||||||
<KeyboardAvoidingView behavior={Platform.OS === 'ios' ? 'padding' : 'height'} keyboardVerticalOffset={navigation ? 72 : 0}>
|
<KeyboardAvoidingView behavior={Platform.OS === 'ios' ? 'padding' : 'height'} keyboardVerticalOffset={navigation ? 72 : 0}>
|
||||||
<View style={styles.container}>
|
<View style={styles.container}>
|
||||||
{ !navigation && (
|
{ !navigation && (
|
||||||
@ -122,28 +122,31 @@ export function Conversation({ navigation, cardId, channelId, closeConversation,
|
|||||||
supportedOrientations={['portrait', 'landscape']}
|
supportedOrientations={['portrait', 'landscape']}
|
||||||
onRequestClose={actions.hideEdit}
|
onRequestClose={actions.hideEdit}
|
||||||
>
|
>
|
||||||
<KeyboardAvoidingView behavior="height" style={styles.modal}>
|
<View style={styles.modalOverlay}>
|
||||||
<View style={styles.editContainer}>
|
<BlurView style={styles.modalOverlay} blurType={Colors.overlay} blurAmount={2} reducedTransparencyFallbackColor="black" />
|
||||||
<Text style={styles.editHeader}>Edit Message Text:</Text>
|
<KeyboardAvoidingView style={styles.modalBase} behavior={Platform.OS === 'ios' ? 'padding' : 'height'}>
|
||||||
|
<View style={styles.modalContainer}>
|
||||||
|
<Text style={styles.editHeader}>{ state.strings.editMessage }</Text>
|
||||||
<View style={styles.inputField}>
|
<View style={styles.inputField}>
|
||||||
<TextInput style={styles.input} value={state.editMessage} onChangeText={actions.setEditMessage}
|
<TextInput style={styles.input} value={state.editMessage} onChangeText={actions.setEditMessage}
|
||||||
autoCapitalize="sentences" placeholder="Message Text" multiline={true} placeholderTextColor={Colors.grey} />
|
autoCapitalize="sentences" placeholder="Message Text" multiline={true} placeholderTextColor={Colors.grey} />
|
||||||
</View>
|
</View>
|
||||||
<View style={styles.editControls}>
|
<View style={styles.editControls}>
|
||||||
<TouchableOpacity style={styles.cancel} onPress={actions.hideEdit}>
|
<TouchableOpacity style={styles.cancel} onPress={actions.hideEdit}>
|
||||||
<Text style={styles.canceltext}>Cancel</Text>
|
<Text style={styles.canceltext}>{ state.strings.cancel }</Text>
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
<TouchableOpacity style={styles.save} onPress={updateTopic}>
|
<TouchableOpacity style={styles.save} onPress={updateTopic}>
|
||||||
{ state.updateBusy && (
|
{ state.updateBusy && (
|
||||||
<ActivityIndicator size="small" color={Colors.white} />
|
<ActivityIndicator size="small" color={Colors.white} />
|
||||||
)}
|
)}
|
||||||
{ !state.updateBusy && (
|
{ !state.updateBusy && (
|
||||||
<Text style={styles.saveText}>Save</Text>
|
<Text style={styles.saveText}>{ state.strings.save }</Text>
|
||||||
)}
|
)}
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
</View>
|
</View>
|
||||||
</View>
|
</View>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
|
</View>
|
||||||
</Modal>
|
</Modal>
|
||||||
</View>
|
</View>
|
||||||
</KeyboardAvoidingView>
|
</KeyboardAvoidingView>
|
||||||
|
@ -105,11 +105,10 @@ export const styles = StyleSheet.create({
|
|||||||
color: Colors.white,
|
color: Colors.white,
|
||||||
},
|
},
|
||||||
canceltext: {
|
canceltext: {
|
||||||
color: Colors.text,
|
color: Colors.cancelButtonText,
|
||||||
},
|
},
|
||||||
cancel: {
|
cancel: {
|
||||||
borderWidth: 1,
|
backgroundColor: Colors.cancelButton,
|
||||||
borderColor: Colors.lightgrey,
|
|
||||||
borderRadius: 4,
|
borderRadius: 4,
|
||||||
padding: 8,
|
padding: 8,
|
||||||
marginRight: 8,
|
marginRight: 8,
|
||||||
@ -167,5 +166,30 @@ export const styles = StyleSheet.create({
|
|||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
},
|
},
|
||||||
|
modalOverlay: {
|
||||||
|
width: '100%',
|
||||||
|
height: '100%',
|
||||||
|
},
|
||||||
|
modalBase: {
|
||||||
|
position: 'absolute',
|
||||||
|
top: 0,
|
||||||
|
left: 0,
|
||||||
|
width: '100%',
|
||||||
|
height: '100%',
|
||||||
|
display: 'flex',
|
||||||
|
alignItems: 'center',
|
||||||
|
justifyContent: 'center'
|
||||||
|
},
|
||||||
|
modalContainer: {
|
||||||
|
backgroundColor: Colors.modalBase,
|
||||||
|
borderColor: Colors.modalBorder,
|
||||||
|
borderWidth: 1,
|
||||||
|
width: '80%',
|
||||||
|
maxWidth: 400,
|
||||||
|
display: 'flex',
|
||||||
|
alignItems: 'center',
|
||||||
|
borderRadius: 8,
|
||||||
|
padding: 16,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -5,9 +5,11 @@ import { AccountContext } from 'context/AccountContext';
|
|||||||
import { ConversationContext } from 'context/ConversationContext';
|
import { ConversationContext } from 'context/ConversationContext';
|
||||||
import { getChannelSubjectLogo } from 'context/channelUtil';
|
import { getChannelSubjectLogo } from 'context/channelUtil';
|
||||||
import { getChannelSeals, isUnsealed, getContentKey, encryptTopicSubject, decryptTopicSubject } from 'context/sealUtil';
|
import { getChannelSeals, isUnsealed, getContentKey, encryptTopicSubject, decryptTopicSubject } from 'context/sealUtil';
|
||||||
|
import { getLanguageStrings } from 'constants/Strings';
|
||||||
|
|
||||||
export function useConversation() {
|
export function useConversation() {
|
||||||
const [state, setState] = useState({
|
const [state, setState] = useState({
|
||||||
|
strings: getLanguageStrings(),
|
||||||
hosted: null,
|
hosted: null,
|
||||||
subject: null,
|
subject: null,
|
||||||
logo: null,
|
logo: null,
|
||||||
|
Loading…
Reference in New Issue
Block a user