perf(bundle): replace broad storage and utils imports
This commit is contained in:
@@ -2,7 +2,7 @@ import { describe, expect, it, vi } from "vitest";
|
||||
|
||||
import type { IAuthStorage } from "@/data/storage/auth";
|
||||
import { LoginStatus } from "@/data/dto/auth";
|
||||
import { Result } from "@/utils";
|
||||
import { Result } from "@/utils/result";
|
||||
|
||||
import { hasCompleteBusinessAuthSession } from "../auth_session";
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
"use client";
|
||||
|
||||
import { Logger } from "@/utils";
|
||||
import { Logger } from "@/utils/logger";
|
||||
|
||||
const log = new Logger("LibBrowserPersistentStorage");
|
||||
let storagePersistenceRequested = false;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { beforeEach, describe, expect, it, vi } from "vitest";
|
||||
|
||||
import { Result } from "@/utils";
|
||||
import { Result } from "@/utils/result";
|
||||
|
||||
const getHistoryMock = vi.hoisted(() => vi.fn());
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
import { AuthStorage } from "@/data/storage/auth/auth_storage";
|
||||
import { UserStorage } from "@/data/storage/user/user_storage";
|
||||
import { ROUTES } from "@/router/routes";
|
||||
import { UrlLauncherUtil } from "@/utils";
|
||||
import { UrlLauncherUtil } from "@/utils/url-launcher-util";
|
||||
|
||||
export async function openChatInExternalBrowser(): Promise<void> {
|
||||
const authStorage = AuthStorage.getInstance();
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
import type { ChatMediaKind } from "@/data/dto/chat";
|
||||
import { getChatRepository } from "@/data/repositories/chat_repository";
|
||||
import { Result, type Result as ResultT } from "@/utils";
|
||||
import { Result, type Result as ResultT } from "@/utils/result";
|
||||
|
||||
import { localChatMediaRowToBlob } from "./chat_media_blob";
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
resolveChatCacheOwnerKey,
|
||||
type ChatCacheIdentityResolver,
|
||||
} from "@/data/repositories/chat_cache_identity";
|
||||
import { Result, type Result as ResultT } from "@/utils";
|
||||
import { Result, type Result as ResultT } from "@/utils/result";
|
||||
|
||||
import type { SplashLatestMessageCache } from "./splash_latest_message_cache";
|
||||
import { getLatestSplashMessagePreview } from "./splash_latest_message_preview";
|
||||
|
||||
@@ -3,7 +3,10 @@
|
||||
import { useEffect, useRef, useState } from "react";
|
||||
|
||||
import type { ChatMediaKind } from "@/data/dto/chat";
|
||||
import { BrowserDetector, Logger, PlatformDetector, Result } from "@/utils";
|
||||
import { BrowserDetector } from "@/utils/browser-detect";
|
||||
import { Logger } from "@/utils/logger";
|
||||
import { PlatformDetector } from "@/utils/platform-detect";
|
||||
import { Result } from "@/utils/result";
|
||||
|
||||
import {
|
||||
cacheRemoteChatMediaBlob,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { Logger, Result } from "@/utils";
|
||||
import { Logger } from "@/utils/logger";
|
||||
import { Result } from "@/utils/result";
|
||||
|
||||
import {
|
||||
savePendingEzpayOrder,
|
||||
|
||||
@@ -3,13 +3,13 @@
|
||||
import {
|
||||
PendingPaymentOrderStorage,
|
||||
type PendingPaymentOrder,
|
||||
} from "@/data/storage";
|
||||
} from "@/data/storage/payment/pending_payment_order_storage";
|
||||
import { ROUTES } from "@/router/routes";
|
||||
import {
|
||||
DEFAULT_TIP_COFFEE_TYPE,
|
||||
TIP_COFFEE_TYPE_PARAM,
|
||||
} from "@/lib/tip/tip_coffee";
|
||||
import type { Result } from "@/utils";
|
||||
import type { Result } from "@/utils/result";
|
||||
|
||||
export type PendingPaymentSubscriptionType =
|
||||
PendingPaymentOrder["subscriptionType"];
|
||||
|
||||
Reference in New Issue
Block a user