Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions apps/mobile/app/screens/settings/settings-data.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "remove-profile-picture",
name: strings.removeProfilePicture(),
icon: "face-man",
description: strings.removeProfilePictureDesc(),
useHook: () =>
useUserStore((state) => state.profile?.profilePicture),
Expand All @@ -198,6 +199,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "remove-name",
name: strings.removeFullName(),
icon: "rename-box",
description: strings.removeFullNameDesc(),
useHook: () => useUserStore((state) => state.profile?.fullName),
hidden: () => !useUserStore.getState().profile?.fullName,
Expand All @@ -223,6 +225,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "recovery-key",
name: strings.saveDataRecoveryKey(),
icon: "account-key",
modifer: async () => {
verifyUser(null, async () => {
await sleep(300);
Expand All @@ -243,6 +246,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "change-password",
name: strings.changePassword(),
icon: "form-textbox-password",
modifer: async () => {
ChangePassword.present();
},
Expand All @@ -251,6 +255,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "change-email",
name: strings.changeEmail(),
icon: "email",
modifer: async () => {
ChangeEmail.present();
},
Expand Down Expand Up @@ -589,6 +594,7 @@ export const settingsGroups: SettingSection[] = [
id: "theme-picker",
type: "screen",
name: strings.themes(),
icon: "palette",
description: strings.themesDesc(),
component: "theme-selector"
},
Expand Down Expand Up @@ -630,6 +636,7 @@ export const settingsGroups: SettingSection[] = [
type: "screen",
icon: "brain",
name: strings.behavior(),
icon: "cog",
description: strings.behaviorDesc(),
sections: [
{
Expand Down Expand Up @@ -694,12 +701,14 @@ export const settingsGroups: SettingSection[] = [
type: "screen",
name: strings.customizeToolbar(),
description: strings.customizeToolbarDesc(),
icon: "format-text",
component: "configuretoolbar"
},
{
id: "reset-toolbar",
name: strings.resetToolbar(),
description: strings.resetToolbarDesc(),
icon: "reload",
modifer: () => {
useDragState.getState().setPreset("default");
ToastManager.show({
Expand Down Expand Up @@ -745,6 +754,7 @@ export const settingsGroups: SettingSection[] = [
id: "title-format",
name: strings.titleFormat(),
component: "title-format",
icon: "format-title",
description: strings.titleFormatDesc(),
type: "component"
},
Expand All @@ -753,6 +763,7 @@ export const settingsGroups: SettingSection[] = [
name: strings.mardownShortcuts(),
property: "markdownShortcuts",
description: strings.mardownShortcutsDesc(),
icon: "language-markdown",
type: "switch"
}
]
Expand All @@ -775,6 +786,7 @@ export const settingsGroups: SettingSection[] = [
id: "marketing-emails",
type: "switch",
name: strings.marketingEmails(),
icon: "email-fast",
description: strings.marketingEmailsDesc(),
modifer: async () => {
try {
Expand Down Expand Up @@ -832,6 +844,7 @@ export const settingsGroups: SettingSection[] = [
id: "change-vault-password",
useHook: useVaultStatus,
name: strings.changeVaultPassword(),
icon: "key-change",
description: strings.changeVaultPasswordDesc(),
hidden: (current) => !(current as VaultStatusType)?.exists,
modifer: () =>
Expand All @@ -845,6 +858,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "clear-vault",
useHook: useVaultStatus,
icon: "key-remove",
description: strings.clearVaultDesc(),
name: strings.clearVault(),
hidden: (current) => !(current as VaultStatusType)?.exists,
Expand All @@ -860,6 +874,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "delete-vault",
name: strings.deleteVault(),
icon: "delete-forever",
description: strings.deleteVaultDesc(),
useHook: useVaultStatus,
hidden: (current) => !(current as VaultStatusType)?.exists,
Expand Down Expand Up @@ -975,6 +990,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "app-lock-timer",
name: strings.appLockTimeout(),
icon: "timer",
description: strings.appLockTimeoutDesc(),
type: "component",
component: "applock-timer"
Expand Down Expand Up @@ -1084,6 +1100,7 @@ export const settingsGroups: SettingSection[] = [
id: "backup-now",
name: strings.backupNow(),
description: strings.backupNowDesc(),
icon: "content-save",
modifer: async () => {
const user = useUserStore.getState().user;
if (!user || SettingsService.getProperty("encryptedBackup")) {
Expand All @@ -1098,6 +1115,7 @@ export const settingsGroups: SettingSection[] = [
id: "backup-now",
name: strings.backupNowWithAttachments(),
description: strings.backupNowWithAttachmentsDesc(),
icon: "content-save-all",
hidden: () => !useUserStore.getState().user,
modifer: async () => {
const user = useUserStore.getState().user;
Expand All @@ -1115,6 +1133,7 @@ export const settingsGroups: SettingSection[] = [
id: "auto-backups",
type: "component",
name: strings.automaticBackups(),
icon: "clock",
description: strings.automaticBackupsDesc(),
component: "autobackups"
},
Expand All @@ -1126,6 +1145,7 @@ export const settingsGroups: SettingSection[] = [
description: [
...strings.automaticBackupsWithAttachmentsDesc()
].join("\n"),
icon: "clock",
component: "autobackupsattachments"
},
{
Expand Down Expand Up @@ -1288,6 +1308,7 @@ export const settingsGroups: SettingSection[] = [
property: "defaultSnoozeTime",
type: "input",
name: strings.defaultSnoozeTime(),
icon: "alarm-snooze",
description: strings.defaultSnoozeTimeDesc(),
inputProperties: {
keyboardType: "decimal-pad",
Expand Down Expand Up @@ -1395,6 +1416,7 @@ export const settingsGroups: SettingSection[] = [
{
id: "join-telegram",
name: strings.joinTelegram(),
icon: "message-text",
description: strings.joinTelegramDesc(),
modifer: () => {
Linking.openURL("https://t.me/notesnook").catch(() => {
Expand Down Expand Up @@ -1452,6 +1474,7 @@ export const settingsGroups: SettingSection[] = [
console.error(e);
}
},
icon: "file-document",
description: strings.tosDesc()
},
{
Expand Down
Binary file modified apps/mobile/native/fonts/MaterialCommunityIcons.ttf
Binary file not shown.