mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-16 19:57:52 +01:00
mobile: ui updates
This commit is contained in:
committed by
Abdullah Atta
parent
7f05043e03
commit
8f1545916f
@@ -21,10 +21,10 @@ import { strings } from "@notesnook/intl";
|
||||
import { useThemeColors } from "@notesnook/theme";
|
||||
import { useNetInfo } from "@react-native-community/netinfo";
|
||||
import React from "react";
|
||||
import { ActivityIndicator, Image, View } from "react-native";
|
||||
import { ActivityIndicator, Image, Linking, View } from "react-native";
|
||||
import { useSheetRef } from "react-native-actions-sheet";
|
||||
import useSyncProgress from "../../../hooks/use-sync-progress";
|
||||
import { presentSheet } from "../../../services/event-manager";
|
||||
import { presentSheet, ToastManager } from "../../../services/event-manager";
|
||||
import Navigation from "../../../services/navigation";
|
||||
import { SyncStatus, useUserStore } from "../../../stores/use-user-store";
|
||||
import { getObfuscatedEmail } from "../../../utils/functions";
|
||||
@@ -38,6 +38,7 @@ import { TimeSince } from "../../ui/time-since";
|
||||
import Paragraph from "../../ui/typography/paragraph";
|
||||
import Sync from "../../../services/sync";
|
||||
|
||||
import Clipboard from "@react-native-clipboard/clipboard";
|
||||
export const UserSheet = () => {
|
||||
const ref = useSheetRef();
|
||||
const { colors } = useThemeColors();
|
||||
@@ -286,6 +287,28 @@ export const UserSheet = () => {
|
||||
Navigation.navigate("Settings");
|
||||
}
|
||||
},
|
||||
{
|
||||
title: strings.emailSupport(),
|
||||
icon: "email",
|
||||
onPress: () => {
|
||||
Clipboard.setString("support@streetwriters.co");
|
||||
ToastManager.show({
|
||||
heading: strings.emailCopied(),
|
||||
type: "success",
|
||||
icon: "content-copy"
|
||||
});
|
||||
setTimeout(() => {
|
||||
Linking.openURL("mailto:support@streetwriters.co");
|
||||
}, 1000);
|
||||
}
|
||||
},
|
||||
{
|
||||
title: strings.documentation(),
|
||||
onPress: async () => {
|
||||
Linking.openURL("https://docs.notesnook.com");
|
||||
},
|
||||
icon: "file-document"
|
||||
},
|
||||
{
|
||||
icon: "logout",
|
||||
title: strings.logout(),
|
||||
|
||||
@@ -715,6 +715,7 @@ export const settingsGroups: SettingSection[] = [
|
||||
{
|
||||
id: "behaviour",
|
||||
type: "screen",
|
||||
icon: "brain",
|
||||
name: strings.behavior(),
|
||||
description: strings.behaviorDesc(),
|
||||
sections: [
|
||||
@@ -1299,6 +1300,7 @@ export const settingsGroups: SettingSection[] = [
|
||||
id: "restore-backup",
|
||||
name: strings.restoreBackup(),
|
||||
description: strings.restoreBackupDesc(),
|
||||
icon: "restore",
|
||||
type: "screen",
|
||||
component: "backuprestore"
|
||||
},
|
||||
@@ -1425,7 +1427,7 @@ export const settingsGroups: SettingSection[] = [
|
||||
{
|
||||
id: "email-support",
|
||||
name: strings.emailSupport(),
|
||||
icon: "mail",
|
||||
icon: "email",
|
||||
modifer: () => {
|
||||
Clipboard.setString("support@streetwriters.co");
|
||||
ToastManager.show({
|
||||
@@ -1522,6 +1524,7 @@ export const settingsGroups: SettingSection[] = [
|
||||
{
|
||||
id: "tos",
|
||||
name: strings.tos(),
|
||||
icon: "briefcase-outline",
|
||||
modifer: async () => {
|
||||
try {
|
||||
await Linking.openURL("https://notesnook.com/tos");
|
||||
@@ -1534,6 +1537,7 @@ export const settingsGroups: SettingSection[] = [
|
||||
{
|
||||
id: "privacy-policy",
|
||||
name: strings.privacyPolicy(),
|
||||
icon: "shield-outline",
|
||||
modifer: async () => {
|
||||
try {
|
||||
await Linking.openURL("https://notesnook.com/privacy");
|
||||
|
||||
Binary file not shown.
@@ -93,7 +93,10 @@ const EXTRA_ICON_NAMES = [
|
||||
"checkbox-blank-outline",
|
||||
"checkbox-outline",
|
||||
"checkbox-intermediate",
|
||||
"dots-vertical"
|
||||
"dots-vertical",
|
||||
"briefcase-outline",
|
||||
"shield-outline",
|
||||
"brain"
|
||||
];
|
||||
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
|
||||
Reference in New Issue
Block a user