Compare commits

..

No commits in common. "3d482753edca632b45bf3f497daf37ed7b7ecd45" and "a4c602c098627a51cb182258965d2336e0dcc3e5" have entirely different histories.

4 changed files with 76 additions and 131 deletions

View file

@ -346,21 +346,11 @@
"license": "License",
"debug": "Debug",
"team": "Team",
"authorMail": "Send an email",
"technologies": "Technologies",
"reactNative": "Made with React Native",
"libs": "Libraries used",
"thanks": "Thanks",
"user": {
"youName": "You",
"you": "[NON TRADUIT] Toi aussi devient le prochaint dévelopeur à rejoindre la team, passe voir le git de l'application y'a tout plein d'info",
"arnaud": "[NON TRADUIT] Étudiant en IR (2020). C'est le créateur de cette magnifique application que t'utilise tout les jour. Et il est vraiment BG aussi.",
"yohan": "[NON TRADUIT] Étudiant en [Je sais pas quoi] (2020). Il nous aide à corriger les bug. Et j'imagine aussi qu'il est BG mais je le connait pas.",
"beranger": "[NON TRADUIT] Étudiant en AE (2020) et Président de lAmicale au moment de la création et du lancement du projet. Lapplication, cétait son idée. Il a beaucoup aidé pour trouver des bugs, de nouvelles fonctionnalités et faire de la com.",
"celine": "[NON TRADUIT] Étudiante en GPE (2020). Sans elle, tout serait moins mignon. Elle a aidé pour écrire le texte, faire de la com, et aussi à créer la mascotte 🦊.",
"damien": "[NON TRADUIT] Étudiant en IR (2020) et créateur de la dernière version du site de lAmicale. Grâce à son aide, intégrer les services de lAmicale à lapplication a été très simple.",
"titouan": "[NON TRADUIT] Étudiant en IR (2020). Il a beaucoup aidé pour trouver des bugs et proposer des nouvelles fonctionnalités.",
"theo": "[NON TRADUIT] Étudiant en AE (2020). Si lapplication marche sur iOS, cest grâce à son aide lors de ses nombreux tests."
}
"thanks": "Thanks"
},
"feedback": {
"title": "Feedback",

View file

@ -345,21 +345,11 @@
"license": "Licence",
"debug": "Debug",
"team": "Équipe",
"authorMail": "Envoyer un mail",
"technologies": "Technologies",
"reactNative": "Créé avec React Native",
"libs": "Librairies utilisées",
"thanks": "Remerciements",
"user": {
"youName": "Toi",
"you": "Toi aussi devient le prochaint dévelopeur à rejoindre la team, passe voir le git de l'application y'a tout plein d'info",
"arnaud": "Étudiant en IR (2020). C'est le créateur de cette magnifique application que t'utilise tout les jour. Et il est vraiment BG aussi.",
"yohan": "Étudiant en [Je sais pas quoi] (2020). Il nous aide à corriger les bug. Et j'imagine aussi qu'il est BG mais je le connait pas.",
"beranger": "Étudiant en AE (2020) et Président de lAmicale au moment de la création et du lancement du projet. Lapplication, cétait son idée. Il a beaucoup aidé pour trouver des bugs, de nouvelles fonctionnalités et faire de la com.",
"celine": "Étudiante en GPE (2020). Sans elle, tout serait moins mignon. Elle a aidé pour écrire le texte, faire de la com, et aussi à créer la mascotte 🦊.",
"damien": "Étudiant en IR (2020) et créateur de la dernière version du site de lAmicale. Grâce à son aide, intégrer les services de lAmicale à lapplication a été très simple.",
"titouan": "Étudiant en IR (2020). Il a beaucoup aidé pour trouver des bugs et proposer des nouvelles fonctionnalités.",
"theo": "Étudiant en AE (2020). Si lapplication marche sur iOS, cest grâce à son aide lors de ses nombreux tests."
}
"thanks": "Remerciements"
},
"feedback": {
"title": "Feedback",

View file

@ -6,7 +6,6 @@ import {FlatList} from 'react-native';
export type OptionsDialogButtonType = {
title: string,
icon?: string,
onPress: () => void,
};
@ -20,19 +19,10 @@ type PropsType = {
class OptionsDialog extends React.PureComponent<PropsType> {
getButtonRender = ({item}: {item: OptionsDialogButtonType}): React.Node => {
return (
<Button onPress={item.onPress} icon={item.icon}>
{item.title}
</Button>
);
return <Button onPress={item.onPress}>{item.title}</Button>;
};
keyExtractor = (item: OptionsDialogButtonType): string => {
if (item.icon != null) {
return item.title + item.icon;
}
return item.title;
};
keyExtractor = (item: OptionsDialogButtonType): string => item.title;
render(): React.Node {
const {props} = this;

View file

@ -5,7 +5,7 @@ import {FlatList, Linking, Platform, Image, View} from 'react-native';
import i18n from 'i18n-js';
import {Avatar, Card, List, withTheme} from 'react-native-paper';
import {StackNavigationProp} from '@react-navigation/stack';
import {Modalize} from 'react-native-modalize';
import {Modalize} from "react-native-modalize";
import packageJson from '../../../package.json';
import CollapsibleFlatList from '../../components/Collapsible/CollapsibleFlatList';
import APP_LOGO from '../../../assets/android.icon.round.png';
@ -13,7 +13,8 @@ import type {
CardTitleIconPropsType,
ListIconPropsType,
} from '../../constants/PaperStyles';
import OptionsDialog from '../../components/Dialogs/OptionsDialog';
import OptionsDialog from "../../components/Dialogs/OptionsDialog";
import type {OptionsDialogButtonType} from "../../components/Dialogs/OptionsDialog";
type ListItemType = {
onPressCallback: () => void,
@ -81,25 +82,23 @@ class AboutScreen extends React.Component<PropsType> {
*/
teamUsers = {
arnaud: {
name: 'Arnaud Vergnrt',
message: i18n.t('screens.about.user.arnaud'),
icon: 'crown',
name: 'Arnaud VERGNET',
message: 'C vrément tro 1 bg !!',
icon: 'account-circle',
btnTrool: {
title: 'SWAG',
onPress: () => {
openWebLink(links.meme);
title: 'SWAG',
onPress: () => {
openWebLink(links.meme);
},
},
},
btnLinkedin: {
title: '',
icon: 'linkedin',
title: 'Linkedin',
onPress: () => {
openWebLink(links.arnaudMail);
},
},
btnMail: {
title: '',
icon: 'email-edit',
title: i18n.t('screens.about.authorMail'),
onPress: () => {
openWebLink(links.arnaudLinkedin);
},
@ -107,38 +106,22 @@ class AboutScreen extends React.Component<PropsType> {
},
yohan: {
name: 'Yohan Simard',
message: i18n.t('screens.about.user.yohan'),
icon: 'xml',
message: 'Correction de quelques bugs',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: {
title: '',
icon: 'linkedin',
title: 'Linkedin',
onPress: () => {
openWebLink(links.yohanLinkedin);
},
},
btnMail: {
title: '',
icon: 'email-edit',
title: i18n.t('screens.about.authorMail'),
onPress: () => {
openWebLink(links.yohanMail);
},
},
},
you: {
name: i18n.t('screens.about.user.youName'),
message: i18n.t('screens.about.user.you'),
icon: 'hand-pointing-right',
btnTrool: {
title: '',
icon: 'git',
onPress: () => {
openWebLink(links.git);
},
},
btnLinkedin: null,
btnMail: null,
},
};
/**
@ -147,40 +130,40 @@ class AboutScreen extends React.Component<PropsType> {
thanksUsers = {
beranger: {
name: 'Béranger Quintana Y Arciosana',
message: i18n.t('screens.about.user.beranger'),
icon: 'account-heart',
message: 'Étudiant en AE (2020) et Président de lAmicale au moment de la création et du lancement du projet. Lapplication, cétait son idée. Il a beaucoup aidé pour trouver des bugs, de nouvelles fonctionnalités et faire de la com.',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: null,
btnMail: null,
},
celine: {
name: 'Céline Tassin',
message: i18n.t('screens.about.user.celine'),
icon: 'brush',
message: 'Étudiante en GPE (2020). Sans elle, tout serait moins mignon. Elle a aidé pour écrire le texte, faire de la com, et aussi à créer la mascotte 🦊.',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: null,
btnMail: null,
},
damien: {
name: 'Damien Molina',
message: i18n.t('screens.about.user.damien'),
icon: 'web',
message: 'Étudiant en IR (2020) et créateur de la dernière version du site de lAmicale. Grâce à son aide, intégrer les services de lAmicale à lapplication a été très simple.',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: null,
btnMail: null,
},
titouan: {
name: 'Titouan Labourdette',
message: i18n.t('screens.about.user.titouan'),
icon: 'shield-bug',
message: 'Étudiant en AE (2020) et Président de lAmicale au moment de la création et du lancement du projet. Lapplication, cétait son idée. Il a beaucoup aidé pour trouver des bugs, de nouvelles fonctionnalités et faire de la com.',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: null,
btnMail: null,
},
theo: {
name: 'Théo Tami',
message: i18n.t('screens.about.user.theo'),
icon: 'food-apple',
message: 'Étudiant en IR (2020). Il a beaucoup aidé pour trouver des bugs et proposer des nouvelles fonctionnalités.',
icon: 'account-circle',
btnTrool: null,
btnLinkedin: null,
btnMail: null,
@ -257,14 +240,6 @@ class AboutScreen extends React.Component<PropsType> {
text: this.teamUsers.yohan.name,
showChevron: false,
},
{
onPressCallback: () => {
this.onListItemPress(this.teamUsers.you);
},
icon: this.teamUsers.you.icon,
text: this.teamUsers.you.name,
showChevron: false,
},
];
/**
@ -371,24 +346,24 @@ class AboutScreen extends React.Component<PropsType> {
* Callback used when clicking an article in the list.
* It opens the modal to show detailed information about the article
*
* @param user A user key
* @param user TODO
*/
onListItemPress(user: AthorsItemType) {
const dialogBtn: Array<IconOptionsDialogButtonType> = [
const dialogBtn: Array<OptionsDialogButtonType> = [
{
title: 'OK',
onPress: () => {
this.setState({dialogVisible: false});
this.onDialogDismiss();
},
},
}
];
if (user.btnMail != null) {
if(user.btnMail != null) {
dialogBtn.push(user.btnMail);
}
if (user.btnLinkedin != null) {
if(user.btnLinkedin != null) {
dialogBtn.push(user.btnLinkedin);
}
if (user.btnTrool != null) {
if(user.btnTrool != null) {
dialogBtn.push(user.btnTrool);
}
this.setState({
@ -455,27 +430,27 @@ class AboutScreen extends React.Component<PropsType> {
}
/**
* Get the thank you card showing support information and links
* Gets the thanks card showing information and links about the team TODO
*
* @return {*}
*/
getThanksCard(): React.Node {
return (
<Card style={{marginBottom: 10}}>
<Card.Title
title={i18n.t('screens.about.thanks')}
left={(iconProps: CardTitleIconPropsType): React.Node => (
<Avatar.Icon size={iconProps.size} icon="hand-heart" />
)}
/>
<Card.Content>
<FlatList
data={this.thanksData}
keyExtractor={this.keyExtractor}
renderItem={this.getCardItem}
<Card style={{marginBottom: 10}}>
<Card.Title
title={i18n.t('screens.about.thanks')}
left={(iconProps: CardTitleIconPropsType): React.Node => (
<Avatar.Icon size={iconProps.size} icon="hand-heart" />
)}
/>
</Card.Content>
</Card>
<Card.Content>
<FlatList
data={this.thanksData}
keyExtractor={this.keyExtractor}
renderItem={this.getCardItem}
/>
</Card.Content>
</Card>
);
}
@ -486,21 +461,21 @@ class AboutScreen extends React.Component<PropsType> {
*/
getTechnoCard(): React.Node {
return (
<Card style={{marginBottom: 10}}>
<Card.Title
title={i18n.t('screens.about.technologies')}
left={(iconProps: CardTitleIconPropsType): React.Node => (
<Avatar.Icon size={iconProps.size} icon="wrench" />
)}
/>
<Card.Content>
<FlatList
data={this.technoData}
keyExtractor={this.keyExtractor}
renderItem={this.getCardItem}
<Card style={{marginBottom: 10}}>
<Card.Title
title={i18n.t('screens.about.technologies')}
left={(iconProps: CardTitleIconPropsType): React.Node => (
<Avatar.Icon size={iconProps.size} icon="build" />
)}
/>
</Card.Content>
</Card>
<Card.Content>
<FlatList
data={this.technoData}
keyExtractor={this.keyExtractor}
renderItem={this.getCardItem}
/>
</Card.Content>
</Card>
);
}
@ -589,20 +564,20 @@ class AboutScreen extends React.Component<PropsType> {
const {state} = this;
return (
<View
style={{
height: '100%',
}}>
style={{
height: '100%',
}}>
<CollapsibleFlatList
style={{padding: 5}}
data={this.dataOrder}
renderItem={this.getMainCard}
/>
<OptionsDialog
visible={state.dialogVisible}
title={state.dialogTitle}
message={state.dialogMessage}
buttons={state.dialogButtons}
onDismiss={state.onDialogDismiss}
visible={state.dialogVisible}
title={state.dialogTitle}
message={state.dialogMessage}
buttons={state.dialogButtons}
onDismiss={state.onDialogDismiss}
/>
</View>
);