Organized custom components

This commit is contained in:
Arnaud Vergnet 2020-04-02 10:07:20 +02:00
parent 2010170e8b
commit 3f576c2287
37 changed files with 43 additions and 43 deletions

2
App.js
View file

@ -4,7 +4,7 @@ import * as React from 'react';
import {Platform, StatusBar} from 'react-native';
import LocaleManager from './managers/LocaleManager';
import AsyncStorageManager from "./managers/AsyncStorageManager";
import CustomIntroSlider from "./components/CustomIntroSlider";
import CustomIntroSlider from "./components/Custom/CustomIntroSlider";
import {SplashScreen} from 'expo';
import ThemeManager from './managers/ThemeManager';
import {NavigationContainer} from '@react-navigation/native';

View file

@ -3,8 +3,8 @@
import * as React from 'react';
import {View} from "react-native";
import {ActivityIndicator, withTheme} from 'react-native-paper';
import ConnectionManager, {ERROR_TYPE} from "../managers/ConnectionManager";
import NetworkErrorComponent from "./NetworkErrorComponent";
import ConnectionManager, {ERROR_TYPE} from "../../managers/ConnectionManager";
import NetworkErrorComponent from "../Custom/NetworkErrorComponent";
import i18n from 'i18n-js';
type Props = {

View file

@ -2,7 +2,7 @@
import * as React from 'react';
import {ActivityIndicator, Button, Dialog, Paragraph, Portal, withTheme} from 'react-native-paper';
import ConnectionManager from "../managers/ConnectionManager";
import ConnectionManager from "../../managers/ConnectionManager";
import i18n from 'i18n-js';
type Props = {

View file

@ -7,7 +7,7 @@ import {MaterialCommunityIcons} from "@expo/vector-icons";
import {Text} from "react-native-paper";
import i18n from 'i18n-js';
import AppIntroSlider from "react-native-app-intro-slider";
import Update from "../constants/Update";
import Update from "../../constants/Update";
type Props = {
onDone: Function,
@ -34,7 +34,7 @@ export default class CustomIntroSlider extends React.Component<Props> {
key: '1',
title: i18n.t('intro.slide1.title'),
text: i18n.t('intro.slide1.text'),
image: require('../assets/splash.png'),
image: require('../../assets/splash.png'),
colors: ['#e01928', '#be1522'],
},
{

View file

@ -4,7 +4,7 @@ import {TouchableOpacity, View} from "react-native";
import Autolink from "react-native-autolink";
import i18n from "i18n-js";
const ICON_AMICALE = require('../assets/amicale.png');
const ICON_AMICALE = require('../../assets/amicale.png');
/**
* Gets the amicale INSAT logo

View file

@ -5,7 +5,7 @@ import {StyleSheet, View} from "react-native";
import HTML from "react-native-render-html";
import i18n from "i18n-js";
import {Avatar, Button, Card, withTheme} from 'react-native-paper';
import {getFormattedEventTime, isDescriptionEmpty} from "../utils/Planning";
import {getFormattedEventTime, isDescriptionEmpty} from "../../utils/Planning";
/**
* Component used to display an event preview if an event is available

View file

@ -1,7 +1,7 @@
import * as React from 'react';
import {Avatar, Card, Text, withTheme} from 'react-native-paper';
import {StyleSheet, View} from "react-native";
import ProxiwashConstants from "../constants/ProxiwashConstants";
import ProxiwashConstants from "../../constants/ProxiwashConstants";
/**
* Component used to display a proxiwash item, showing machine progression and state

View file

@ -1,7 +1,7 @@
// @flow
import * as React from 'react';
import {readData} from "../utils/WebData";
import {readData} from "../../utils/WebData";
import i18n from "i18n-js";
import {Snackbar} from 'react-native-paper';
import {RefreshControl, SectionList, View} from "react-native";

View file

@ -4,7 +4,7 @@ import * as React from 'react';
import {View} from 'react-native';
import WebView from "react-native-webview";
import {ActivityIndicator, withTheme} from 'react-native-paper';
import HeaderButton from "./HeaderButton";
import HeaderButton from "../Custom/HeaderButton";
type Props = {
navigation: Object,

View file

@ -3,12 +3,12 @@
import * as React from 'react';
import {Dimensions, FlatList, Image, Platform, StyleSheet, View,} from 'react-native';
import i18n from "i18n-js";
import {openBrowser} from "../utils/WebBrowser";
import {openBrowser} from "../../utils/WebBrowser";
import SidebarDivider from "./SidebarDivider";
import SidebarItem from "./SidebarItem";
import {TouchableRipple, withTheme} from "react-native-paper";
import ConnectionManager from "../managers/ConnectionManager";
import LogoutDialog from "./LogoutDialog";
import ConnectionManager from "../../managers/ConnectionManager";
import LogoutDialog from "../Amicale/LogoutDialog";
const deviceWidth = Dimensions.get("window").width;
@ -226,7 +226,7 @@ class SideBar extends React.PureComponent<Props, State> {
onPress={onPress}
>
<Image
source={require("../assets/drawer-cover.png")}
source={require("../../assets/drawer-cover.png")}
style={styles.drawerCover}
/>
</TouchableRipple>

View file

@ -11,9 +11,9 @@ import AvailableRoomScreen from "../screens/Websites/AvailableRoomScreen";
import BibScreen from "../screens/Websites/BibScreen";
import TetrisScreen from "../screens/Tetris/TetrisScreen";
import DebugScreen from '../screens/About/DebugScreen';
import Sidebar from "../components/Sidebar";
import Sidebar from "../components/Sidebar/Sidebar";
import {createStackNavigator, TransitionPresets} from "@react-navigation/stack";
import HeaderButton from "../components/HeaderButton";
import HeaderButton from "../components/Custom/HeaderButton";
import i18n from "i18n-js";
import LoginScreen from "../screens/Amicale/LoginScreen";
import ProfileScreen from "../screens/Amicale/ProfileScreen";

View file

@ -13,7 +13,7 @@ import ProximoAboutScreen from "../screens/Proximo/ProximoAboutScreen";
import PlanexScreen from '../screens/Websites/PlanexScreen';
import {MaterialCommunityIcons} from "@expo/vector-icons";
import AsyncStorageManager from "../managers/AsyncStorageManager";
import HeaderButton from "../components/HeaderButton";
import HeaderButton from "../components/Custom/HeaderButton";
import {withTheme} from 'react-native-paper';
import i18n from "i18n-js";

View file

@ -5,7 +5,7 @@ import {FlatList, Linking, Platform, View} from 'react-native';
import i18n from "i18n-js";
import appJson from '../../app';
import AsyncStorageManager from "../../managers/AsyncStorageManager";
import CustomModal from "../../components/CustomModal";
import CustomModal from "../../components/Custom/CustomModal";
import {Avatar, Button, Card, List, Text, Title, withTheme} from 'react-native-paper';
const links = {

View file

@ -3,7 +3,7 @@
import * as React from 'react';
import {ScrollView, View} from "react-native";
import AsyncStorageManager from "../../managers/AsyncStorageManager";
import CustomModal from "../../components/CustomModal";
import CustomModal from "../../components/Custom/CustomModal";
import {Button, Card, List, Subheading, TextInput, Title, withTheme} from 'react-native-paper';
type Props = {

View file

@ -6,7 +6,7 @@ import {Avatar, Button, Card, HelperText, Text, TextInput, withTheme} from 'reac
import ConnectionManager, {ERROR_TYPE} from "../../managers/ConnectionManager";
import {openBrowser} from "../../utils/WebBrowser";
import i18n from 'i18n-js';
import AlertDialog from "../../components/AlertDialog";
import AlertDialog from "../../components/Custom/AlertDialog";
type Props = {
navigation: Object,

View file

@ -3,11 +3,11 @@
import * as React from 'react';
import {FlatList, StyleSheet, View} from "react-native";
import {Avatar, Button, Card, Divider, List, withTheme} from 'react-native-paper';
import AuthenticatedScreen from "../../components/AuthenticatedScreen";
import AuthenticatedScreen from "../../components/Amicale/AuthenticatedScreen";
import {openBrowser} from "../../utils/WebBrowser";
import HeaderButton from "../../components/HeaderButton";
import HeaderButton from "../../components/Custom/HeaderButton";
import i18n from 'i18n-js';
import LogoutDialog from "../../components/LogoutDialog";
import LogoutDialog from "../../components/Amicale/LogoutDialog";
type Props = {
navigation: Object,

View file

@ -3,12 +3,12 @@
import * as React from 'react';
import {View} from 'react-native';
import i18n from "i18n-js";
import DashboardItem from "../components/EventDashboardItem";
import WebSectionList from "../components/WebSectionList";
import DashboardItem from "../components/Home/EventDashboardItem";
import WebSectionList from "../components/Lists/WebSectionList";
import {Text, withTheme} from 'react-native-paper';
import FeedItem from "../components/FeedItem";
import SquareDashboardItem from "../components/SquareDashboardItem";
import PreviewEventDashboardItem from "../components/PreviewEventDashboardItem";
import FeedItem from "../components/Home/FeedItem";
import SquareDashboardItem from "../components/Home/SquareDashboardItem";
import PreviewEventDashboardItem from "../components/Home/PreviewEventDashboardItem";
import {stringToDate} from "../utils/Planning";
import {openBrowser} from "../utils/WebBrowser";
// import DATA from "../dashboard_data.json";

View file

@ -13,7 +13,7 @@ import {
getFormattedEventTime,
} from '../../utils/Planning';
import {Avatar, Divider, List} from 'react-native-paper';
import CustomAgenda from "../../components/CustomAgenda";
import CustomAgenda from "../../components/Custom/CustomAgenda";
LocaleConfig.locales['fr'] = {
monthNames: ['Janvier', 'Février', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Août', 'Septembre', 'Octobre', 'Novembre', 'Décembre'],

View file

@ -3,9 +3,9 @@
import * as React from 'react';
import {Image, Platform, ScrollView, View} from "react-native";
import i18n from "i18n-js";
import CustomModal from "../../components/CustomModal";
import CustomModal from "../../components/Custom/CustomModal";
import {Avatar, IconButton, List, RadioButton, Searchbar, Subheading, Text, Title, withTheme} from "react-native-paper";
import PureFlatList from "../../components/PureFlatList";
import PureFlatList from "../../components/Lists/PureFlatList";
function sortPrice(a, b) {
return a.price - b.price;

View file

@ -3,9 +3,9 @@
import * as React from 'react';
import {View} from 'react-native'
import i18n from "i18n-js";
import WebSectionList from "../../components/WebSectionList";
import WebSectionList from "../../components/Lists/WebSectionList";
import {List, withTheme} from 'react-native-paper';
import HeaderButton from "../../components/HeaderButton";
import HeaderButton from "../../components/Custom/HeaderButton";
const DATA_URL = "https://etud.insa-toulouse.fr/~proximo/data/stock-v2.json";

View file

@ -3,15 +3,15 @@
import * as React from 'react';
import {Alert, Platform, View} from 'react-native';
import i18n from "i18n-js";
import WebSectionList from "../../components/WebSectionList";
import WebSectionList from "../../components/Lists/WebSectionList";
import * as Notifications from "../../utils/Notifications";
import AsyncStorageManager from "../../managers/AsyncStorageManager";
import * as Expo from "expo";
import {Avatar, Banner, Button, Card, Text, withTheme} from 'react-native-paper';
import HeaderButton from "../../components/HeaderButton";
import ProxiwashListItem from "../../components/ProxiwashListItem";
import HeaderButton from "../../components/Custom/HeaderButton";
import ProxiwashListItem from "../../components/Lists/ProxiwashListItem";
import ProxiwashConstants from "../../constants/ProxiwashConstants";
import CustomModal from "../../components/CustomModal";
import CustomModal from "../../components/Custom/CustomModal";
import AprilFoolsManager from "../../managers/AprilFoolsManager";
const DATA_URL = "https://etud.insa-toulouse.fr/~amicale_app/washinsa/washinsa.json";

View file

@ -3,7 +3,7 @@
import * as React from 'react';
import {View} from 'react-native';
import DateManager from "../managers/DateManager";
import WebSectionList from "../components/WebSectionList";
import WebSectionList from "../components/Lists/WebSectionList";
import {Card, Text, withTheme} from 'react-native-paper';
import AprilFoolsManager from "../managers/AprilFoolsManager";

View file

@ -6,7 +6,7 @@ import {IconButton, Text, withTheme} from 'react-native-paper';
import {MaterialCommunityIcons} from "@expo/vector-icons";
import GameLogic from "./GameLogic";
import Grid from "./components/Grid";
import HeaderButton from "../../components/HeaderButton";
import HeaderButton from "../../components/Custom/HeaderButton";
import Preview from "./components/Preview";
import i18n from "i18n-js";

View file

@ -1,7 +1,7 @@
// @flow
import * as React from 'react';
import WebViewScreen from "../../components/WebViewScreen";
import WebViewScreen from "../../components/Screens/WebViewScreen";
import i18n from "i18n-js";
type Props = {

View file

@ -1,7 +1,7 @@
// @flow
import * as React from 'react';
import WebViewScreen from "../../components/WebViewScreen";
import WebViewScreen from "../../components/Screens/WebViewScreen";
import i18n from "i18n-js";
type Props = {

View file

@ -2,7 +2,7 @@
import * as React from 'react';
import ThemeManager from "../../managers/ThemeManager";
import WebViewScreen from "../../components/WebViewScreen";
import WebViewScreen from "../../components/Screens/WebViewScreen";
import {Avatar, Banner} from "react-native-paper";
import i18n from "i18n-js";
import {View} from "react-native";