From 5661675fb24f367ab51b595fc109998bb7c1ed4f Mon Sep 17 00:00:00 2001 From: Benjamin Guedj Date: Mon, 18 Mar 2024 11:14:42 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20Politique=20de=20confiden?= =?UTF-8?q?tialit=C3=A9=202024?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/package.json | 2 +- front/src/components/html/a.component.tsx | 10 +- .../menu/conditionsOfUse.component.tsx | 436 ++++++------------ front/yarn.lock | 203 ++++---- 4 files changed, 242 insertions(+), 409 deletions(-) diff --git a/front/package.json b/front/package.json index fd66ba08a..b54a48b3f 100644 --- a/front/package.json +++ b/front/package.json @@ -88,7 +88,7 @@ "postinstall-postinstall": "^2.1.0", "react": "18.2.0", "react-dom": "18.2.0", - "react-native": "0.72.6", + "react-native": "0.72.10", "react-native-animatable": "^1.3.3", "react-native-calendars": "^1.1268.0", "react-native-confetti": "^0.1.0", diff --git a/front/src/components/html/a.component.tsx b/front/src/components/html/a.component.tsx index 812cf7335..c55f20f0a 100644 --- a/front/src/components/html/a.component.tsx +++ b/front/src/components/html/a.component.tsx @@ -1,7 +1,7 @@ import type { FC } from "react"; import * as React from "react"; import { useCallback } from "react"; -import { StyleSheet } from "react-native"; +import { Linking, StyleSheet } from "react-native"; import { Colors } from "../../styles"; import { LinkingUtils } from "../../utils"; @@ -15,10 +15,10 @@ interface AProps { export type Props = AProps & TextProps; const A: FC = (props) => { - const onTextPressed = useCallback( - async () => LinkingUtils.openWebsite(props.url), - [props.url] - ); + const onTextPressed = useCallback(() => { + if (props.url.startsWith("mailto:")) void Linking.openURL(props.url); + else void LinkingUtils.openWebsite(props.url); + }, [props.url]); return ( { + const iframeMatomo = ` +