From 8116d69b6cd4d8c9f249bc7e25c234ca9815fffe Mon Sep 17 00:00:00 2001 From: patak <583075+patak-dev@users.noreply.github.com> Date: Sat, 1 Feb 2025 07:25:06 +0100 Subject: [PATCH] chore: remove welcome screen (#3168) --- composables/dialog.ts | 11 +---------- constants/index.ts | 1 - 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/composables/dialog.ts b/composables/dialog.ts index ba02eca1..463abbac 100644 --- a/composables/dialog.ts +++ b/composables/dialog.ts @@ -1,6 +1,5 @@ import type { mastodon } from 'masto' import type { ConfirmDialogChoice, ConfirmDialogOptions, DraftItem, ErrorDialogData } from '~/types' -import { STORAGE_KEY_FIRST_VISIT } from '~/constants' export const confirmDialogChoice = ref() export const confirmDialogLabel = ref() @@ -17,14 +16,12 @@ export const reportStatus = ref() export const commandPanelInput = ref('') -export const isFirstVisit = useLocalStorage(STORAGE_KEY_FIRST_VISIT, !process.mock) - export const isSigninDialogOpen = ref(false) export const isPublishDialogOpen = ref(false) export const isKeyboardShortcutsDialogOpen = ref(false) export const isMediaPreviewOpen = ref(false) export const isEditHistoryDialogOpen = ref(false) -export const isPreviewHelpOpen = ref(isFirstVisit.value) +export const isPreviewHelpOpen = ref(false) export const isCommandPanelOpen = ref(false) export const isConfirmDialogOpen = ref(false) export const isErrorDialogOpen = ref(false) @@ -77,12 +74,6 @@ export async function openFavoridedBoostedByDialog(statusId: string) { favouritedBoostedByStatusId.value = statusId } -if (isPreviewHelpOpen.value) { - watch(isPreviewHelpOpen, () => { - isFirstVisit.value = false - }) -} - function restoreMediaPreviewFromState() { mediaPreviewList.value = JSON.parse(history.state?.mediaPreviewList ?? '[]') mediaPreviewIndex.value = history.state?.mediaPreviewIndex ?? 0 diff --git a/constants/index.ts b/constants/index.ts index 2ded6500..9a82b5e3 100644 --- a/constants/index.ts +++ b/constants/index.ts @@ -13,7 +13,6 @@ export const STORAGE_KEY_SERVERS = 'elk-servers' export const STORAGE_KEY_NODES = 'elk-nodes' export const STORAGE_KEY_CURRENT_USER_HANDLE = 'elk-current-user-handle' export const STORAGE_KEY_NOTIFY_TAB = 'elk-notify-tab' -export const STORAGE_KEY_FIRST_VISIT = 'elk-first-visit' export const STORAGE_KEY_SETTINGS = 'elk-settings' export const STORAGE_KEY_CUSTOM_EMOJIS = 'elk-custom-emojis' export const STORAGE_KEY_HIDE_EXPLORE_POSTS_TIPS = 'elk-hide-explore-posts-tips'