forked from vergnet/application-amicale
Removed map screen
This commit is contained in:
parent
e43577c8cb
commit
f321888bc3
3 changed files with 0 additions and 121 deletions
|
@ -30,7 +30,6 @@ import ClubAboutScreen from "../screens/Amicale/Clubs/ClubAboutScreen";
|
|||
import ClubDisplayScreen from "../screens/Amicale/Clubs/ClubDisplayScreen";
|
||||
import {createScreenCollapsibleStack, getWebsiteStack} from "../utils/CollapsibleUtils";
|
||||
import BugReportScreen from "../screens/Other/FeedbackScreen";
|
||||
import MapScreen from "../screens/Services/MapScreen";
|
||||
|
||||
const modalTransition = Platform.OS === 'ios' ? TransitionPresets.ModalPresentationIOS : TransitionPresets.ModalSlideFromBottomIOS;
|
||||
|
||||
|
@ -107,13 +106,6 @@ function MainStackComponent(props: { createTabNavigator: () => React.Node }) {
|
|||
{getWebsiteStack("available-rooms", MainStack, AvailableRoomScreen, i18n.t('screens.availableRooms'))}
|
||||
{getWebsiteStack("bib", MainStack, BibScreen, i18n.t('screens.bib'))}
|
||||
{createScreenCollapsibleStack("self-menu", MainStack, SelfMenuScreen, i18n.t('screens.menuSelf'))}
|
||||
<MainStack.Screen
|
||||
name="map"
|
||||
component={MapScreen}
|
||||
options={{
|
||||
title: i18n.t('screens.map'),
|
||||
}}
|
||||
/>
|
||||
|
||||
{/* STUDENTS */}
|
||||
{createScreenCollapsibleStack("proximo", MainStack, ProximoMainScreen, i18n.t('screens.proximo'))}
|
||||
|
|
|
@ -1,104 +0,0 @@
|
|||
// @flow
|
||||
|
||||
import * as React from 'react';
|
||||
import {View} from 'react-native';
|
||||
import {withTheme} from 'react-native-paper';
|
||||
import {StackNavigationProp} from "@react-navigation/stack";
|
||||
import type {CustomTheme} from "../../managers/ThemeManager";
|
||||
import MapboxGL from "@react-native-mapbox-gl/maps";
|
||||
|
||||
type Props = {
|
||||
navigation: StackNavigationProp,
|
||||
theme: CustomTheme,
|
||||
}
|
||||
|
||||
type State = {
|
||||
featureCollection: Array<Object>,
|
||||
}
|
||||
|
||||
MapboxGL.setAccessToken("pk.eyJ1IjoiYW1pY2FsZS1pbnNhdCIsImEiOiJja2JpM2d5OHYwYmdiMndxdnV4bmh6bGFwIn0.qiOwbs2_HRaQGUOpBDjbsQ");
|
||||
|
||||
// const styles = {
|
||||
// icon: {
|
||||
// iconImage: exampleIcon,
|
||||
// iconAllowOverlap: true,
|
||||
// },
|
||||
// };
|
||||
|
||||
// const FEATURES = [{
|
||||
// type: 'Feature',
|
||||
// geometry: {
|
||||
// type: 'Point',
|
||||
// coordinates: [1.4669608, 43.5698867],
|
||||
// }
|
||||
// }]
|
||||
|
||||
/**
|
||||
* Class defining the app's map screen.
|
||||
*/
|
||||
class MapScreen extends React.Component<Props, State> {
|
||||
|
||||
map: { current: null | MapboxGL.MapView };
|
||||
|
||||
constructor() {
|
||||
super();
|
||||
this.map = React.createRef();
|
||||
|
||||
this.state = {
|
||||
featureCollection: [],
|
||||
};
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
MapboxGL.setTelemetryEnabled(false);
|
||||
|
||||
}
|
||||
|
||||
// onSymbolPress = (feature) => {
|
||||
// console.log("coucou");
|
||||
// }
|
||||
//
|
||||
//
|
||||
// onSourceLayerPress = ({features, coordinates, point}) => {
|
||||
// console.log(
|
||||
// 'You pressed a layer here are your features:',
|
||||
// features,
|
||||
// coordinates,
|
||||
// point,
|
||||
// );
|
||||
// }
|
||||
|
||||
render() {
|
||||
return (
|
||||
<View style={{flex: 1}}>
|
||||
<MapboxGL.MapView
|
||||
style={{flex: 1}}
|
||||
ref={this.map}
|
||||
styleURL={MapboxGL.StyleURL.Outdoors}
|
||||
surfaceView={true}
|
||||
onPress={(e) => {
|
||||
console.log(e)
|
||||
}}
|
||||
>
|
||||
<MapboxGL.Camera
|
||||
zoomLevel={15}
|
||||
centerCoordinate={[1.4669608, 43.5698867]}
|
||||
pitch={30}
|
||||
/>
|
||||
{/*<MapboxGL.ShapeSource*/}
|
||||
{/* id="symbolLocationSource"*/}
|
||||
{/* shape={{ type: 'FeatureCollection', features: FEATURES }}*/}
|
||||
{/*>*/}
|
||||
{/* <MapboxGL.SymbolLayer*/}
|
||||
{/* id="symbolLocationSymbols"*/}
|
||||
{/* minZoomLevel={15}*/}
|
||||
{/* style={styles.icon}*/}
|
||||
{/* />*/}
|
||||
{/*</MapboxGL.ShapeSource>*/}
|
||||
</MapboxGL.MapView>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default withTheme(MapScreen);
|
|
@ -31,7 +31,6 @@ const WIKETUD_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/Wiketud
|
|||
const EE_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/EEC.png";
|
||||
const TUTORINSA_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/TutorINSA.png";
|
||||
|
||||
const MAP_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/Map.png";
|
||||
const BIB_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/Bib.png";
|
||||
const RU_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/RU.png";
|
||||
const ROOM_IMAGE = "https://etud.insa-toulouse.fr/~amicale_app/images/Salles.png";
|
||||
|
@ -50,8 +49,6 @@ type State = {
|
|||
isLoggedIn: boolean,
|
||||
}
|
||||
|
||||
// TODO translate subtitles
|
||||
|
||||
class ServicesScreen extends React.Component<Props, State> {
|
||||
|
||||
amicaleDataset: cardList;
|
||||
|
@ -122,12 +119,6 @@ class ServicesScreen extends React.Component<Props, State> {
|
|||
},
|
||||
];
|
||||
this.insaDataset = [
|
||||
{
|
||||
title: i18n.t('screens.map'),
|
||||
subtitle: i18n.t('servicesScreen.descriptions.map'),
|
||||
image: MAP_IMAGE,
|
||||
onPress: () => nav.navigate("map"),
|
||||
},
|
||||
{
|
||||
title: i18n.t('screens.menuSelf'),
|
||||
subtitle: i18n.t('servicesScreen.descriptions.self'),
|
||||
|
|
Loading…
Reference in a new issue