From 0ccdcf30845dd1dfac3da33965090604e6307ba4 Mon Sep 17 00:00:00 2001 From: leon-morival Date: Thu, 2 Oct 2025 13:59:05 +0200 Subject: [PATCH] colors web --- src/screens/Profile/ChangeEmailAddress.js | 24 +++++++++++------------ src/screens/Profile/ChangePassword.js | 23 +++++++++++----------- src/screens/Profile/EditProfile.js | 13 ++++-------- src/screens/Profile/Language.js | 18 ++++++++--------- src/screens/Profile/Notifications.js | 15 +++++++------- src/screens/Profile/Profile.js | 5 ++--- src/screens/Profile/Settings.js | 15 +++++++------- 7 files changed, 55 insertions(+), 58 deletions(-) diff --git a/src/screens/Profile/ChangeEmailAddress.js b/src/screens/Profile/ChangeEmailAddress.js index d5d5708..0c4e953 100644 --- a/src/screens/Profile/ChangeEmailAddress.js +++ b/src/screens/Profile/ChangeEmailAddress.js @@ -1,18 +1,18 @@ -import { Platform, View } from "react-native"; -import React, { useEffect, useState } from "react"; -import Page from "../../layouts/Page"; -import { background } from "../../assets"; -import { gutters, Palette } from "../../styles"; -import { responsiveHeight } from "react-native-responsive-dimensions"; import { BlurView } from "expo-blur"; -import EditInput from "./components/EditInput"; -import GradientButton from "../../components/GradientButton"; +import React, { useEffect, useState } from "react"; +import { Platform, Text, View } from "react-native"; +import { responsiveHeight } from "react-native-responsive-dimensions"; import { useGlobal } from "reactn"; -import firebase, { usersRef } from "../../config/firebase"; -import { goBack } from "../../navigation/NavigationService"; import { checkIfEmailIsValid } from "../../actions/signupActions"; -import { Text } from "react-native"; +import { background } from "../../assets"; +import GradientButton from "../../components/GradientButton"; +import firebase, { usersRef } from "../../config/firebase"; +import { isWeb } from "../../hooks/useLayoutType"; +import Page from "../../layouts/Page"; +import { goBack } from "../../navigation/NavigationService"; +import { gutters, Palette } from "../../styles"; import { FONT_FAMILY } from "../../styles/Fonts"; +import EditInput from "./components/EditInput"; const ChangeEmailAddress = () => { const [email, setEmail] = useState(""); @@ -91,7 +91,7 @@ const ChangeEmailAddress = () => { paddingBottom: gutters * 4, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} > diff --git a/src/screens/Profile/ChangePassword.js b/src/screens/Profile/ChangePassword.js index 32bf314..f809991 100644 --- a/src/screens/Profile/ChangePassword.js +++ b/src/screens/Profile/ChangePassword.js @@ -1,17 +1,18 @@ -import { View, Text, Pressable, Platform } from "react-native"; -import React, { useState } from "react"; -import Page from "../../layouts/Page"; -import { background } from "../../assets"; -import { gutters, Palette } from "../../styles"; -import { responsiveHeight } from "react-native-responsive-dimensions"; import { BlurView } from "expo-blur"; -import EditInput from "./components/EditInput"; -import GradientButton from "../../components/GradientButton"; -import { FONT_FAMILY } from "../../styles/Fonts"; +import React, { useState } from "react"; +import { Platform, Pressable, Text, View } from "react-native"; +import { responsiveHeight } from "react-native-responsive-dimensions"; import { useGlobal } from "reactn"; +import { background } from "../../assets"; +import GradientButton from "../../components/GradientButton"; import firebase from "../../config/firebase"; -import { navigate } from "../../navigation/NavigationService"; +import { isWeb } from "../../hooks/useLayoutType"; +import Page from "../../layouts/Page"; import { Routes } from "../../navigation"; +import { navigate } from "../../navigation/NavigationService"; +import { gutters, Palette } from "../../styles"; +import { FONT_FAMILY } from "../../styles/Fonts"; +import EditInput from "./components/EditInput"; const ChangePassword = () => { const [oldPassword, setOldPassword] = useState(""); @@ -53,7 +54,7 @@ const ChangePassword = () => { paddingBottom: gutters * 4, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} > diff --git a/src/screens/Profile/EditProfile.js b/src/screens/Profile/EditProfile.js index 7705ddd..2cc4e3e 100644 --- a/src/screens/Profile/EditProfile.js +++ b/src/screens/Profile/EditProfile.js @@ -1,20 +1,15 @@ import { BlurView } from "expo-blur"; +import { Image as ExpoImage } from "expo-image"; import * as ImagePicker from "expo-image-picker"; import React, { useEffect, useState } from "react"; -import { - Platform, - Pressable, - Text, - View, - Image as RNImage, -} from "react-native"; -import { Image as ExpoImage } from "expo-image"; +import { Platform, Pressable, Text, View } from "react-native"; import { responsiveHeight } from "react-native-responsive-dimensions"; import { useGlobal } from "reactn"; import { background, img } from "../../assets"; import GradientButton from "../../components/GradientButton"; import firebase, { serverTimestamp, usersRef } from "../../config/firebase"; import { uploadFileToFirebase } from "../../helpers/uploadToFirebase"; +import { isWeb } from "../../hooks/useLayoutType"; import Page from "../../layouts/Page"; import { goBack } from "../../navigation/NavigationService"; import { useUser } from "../../providers/UserDataProvider"; @@ -133,7 +128,7 @@ const EditProfile = () => { paddingBottom: gutters * 2, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} > diff --git a/src/screens/Profile/Language.js b/src/screens/Profile/Language.js index 13d710f..03a2da5 100644 --- a/src/screens/Profile/Language.js +++ b/src/screens/Profile/Language.js @@ -1,13 +1,13 @@ -import { View, Text, Pressable, Platform } from "react-native"; -import React, { useState } from "react"; -import Page from "../../layouts/Page"; -import { background } from "../../assets"; -import { gutters, Palette } from "../../styles"; -import { responsiveHeight } from "react-native-responsive-dimensions"; import { BlurView } from "expo-blur"; -import { FONT_FAMILY } from "../../styles/Fonts"; -import Style, { size } from "../../styles/Style"; +import React, { useState } from "react"; +import { Platform, Text, View } from "react-native"; +import { responsiveHeight } from "react-native-responsive-dimensions"; +import { background } from "../../assets"; import AppCheckbox from "../../components/AppCheckbox"; +import { isWeb } from "../../hooks/useLayoutType"; +import Page from "../../layouts/Page"; +import { gutters, Palette } from "../../styles"; +import { FONT_FAMILY } from "../../styles/Fonts"; const LANGUAGE = ["Anglais", "Français", "Chinois", "Japonais", "Coreen"]; @@ -23,7 +23,7 @@ const Language = () => { paddingBottom: gutters * 4, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} > diff --git a/src/screens/Profile/Notifications.js b/src/screens/Profile/Notifications.js index 27ae288..06edf25 100644 --- a/src/screens/Profile/Notifications.js +++ b/src/screens/Profile/Notifications.js @@ -1,14 +1,15 @@ /* eslint-disable react/display-name */ -import React, { useEffect, useGlobal } from "reactn"; -import Page from "../../layouts/Page"; -import { gutters, Palette, Style } from "../../styles"; -import { background } from "../../assets"; +import { BlurView } from "expo-blur"; +import { useState } from "react"; import { Platform, Text, View } from "react-native"; import { responsiveHeight } from "react-native-responsive-dimensions"; -import { BlurView } from "expo-blur"; +import React, { useEffect, useGlobal } from "reactn"; +import { background } from "../../assets"; import Switch from "../../components/Switch"; -import { useState } from "react"; import firebase, { usersRef } from "../../config/firebase"; +import { isWeb } from "../../hooks/useLayoutType"; +import Page from "../../layouts/Page"; +import { gutters, Palette, Style } from "../../styles"; import { FONT_FAMILY } from "../../styles/Fonts"; export default (props) => { @@ -47,7 +48,7 @@ export default (props) => { paddingBottom: gutters * 4, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} > diff --git a/src/screens/Profile/Profile.js b/src/screens/Profile/Profile.js index 760a666..ddf2d3e 100644 --- a/src/screens/Profile/Profile.js +++ b/src/screens/Profile/Profile.js @@ -65,7 +65,7 @@ const Profile = () => { setFollowers( Array.isArray(currentUserData?.followedBy) ? currentUserData.followedBy.length - : 0, + : 0 ); return; } @@ -139,8 +139,7 @@ const Profile = () => { setSelectedProjectId(item.id); setMenuPosition(posTop); setShowMenu( - (prev) => - !prev || posTop?.top !== (menuPosition?.top ?? null), + (prev) => !prev || posTop?.top !== (menuPosition?.top ?? null) ); }} /> diff --git a/src/screens/Profile/Settings.js b/src/screens/Profile/Settings.js index 0b9f549..26773e7 100644 --- a/src/screens/Profile/Settings.js +++ b/src/screens/Profile/Settings.js @@ -1,15 +1,16 @@ -import { View } from "react-native"; import React from "react"; -import Page from "../../layouts/Page"; -import { background } from "../../assets"; -import { gutters, Palette } from "../../styles"; +import { View } from "react-native"; +import { SheetManager } from "react-native-actions-sheet"; import { responsiveHeight } from "react-native-responsive-dimensions"; +import { background } from "../../assets"; import BlurItemButton from "../../components/BlurItemButton"; import BorderGradientButton from "../../components/BorderGradientButton"; -import { SheetManager } from "react-native-actions-sheet"; -import { navigate } from "../../navigation/NavigationService"; +import { isWeb } from "../../hooks/useLayoutType"; +import Page from "../../layouts/Page"; import { Routes } from "../../navigation"; +import { navigate } from "../../navigation/NavigationService"; import { useUserData } from "../../providers/UserDataProvider"; +import { gutters, Palette } from "../../styles"; const SETTINGS = [ { @@ -63,7 +64,7 @@ const Settings = () => { paddingBottom: gutters * 2, }} containerStyle={{ - backgroundColor: "#0000004D", + backgroundColor: isWeb ? "transparent" : "#0000004D", }} >