From 5e09a7abc6cc35f1319bd251bb2a103560c1b5f0 Mon Sep 17 00:00:00 2001 From: Rahulcheryala Date: Fri, 5 Jun 2026 16:39:54 +0530 Subject: [PATCH] refactor: migrate hooks (use-file-size) from web/app/ce to web/app/core --- .../core/components/issues/attachment/attachment-item-list.tsx | 2 +- .../web/core/components/issues/attachment/attachment-upload.tsx | 2 +- .../issue-detail-widgets/attachments/quick-action-button.tsx | 2 +- apps/web/core/hooks/editor/use-editor-config.ts | 2 +- apps/web/{ce => core}/hooks/use-file-size.ts | 0 5 files changed, 4 insertions(+), 4 deletions(-) rename apps/web/{ce => core}/hooks/use-file-size.ts (100%) diff --git a/apps/web/core/components/issues/attachment/attachment-item-list.tsx b/apps/web/core/components/issues/attachment/attachment-item-list.tsx index 0ac4db84f2..4341e5c951 100644 --- a/apps/web/core/components/issues/attachment/attachment-item-list.tsx +++ b/apps/web/core/components/issues/attachment/attachment-item-list.tsx @@ -16,7 +16,7 @@ import { EIssueServiceType } from "@plane/types"; // hooks import { useIssueDetail } from "@/hooks/store/use-issue-detail"; // plane web hooks -import { useFileSize } from "@/plane-web/hooks/use-file-size"; +import { useFileSize } from "@/hooks/use-file-size"; // types import type { TAttachmentHelpers } from "../issue-detail-widgets/attachments/helper"; // components diff --git a/apps/web/core/components/issues/attachment/attachment-upload.tsx b/apps/web/core/components/issues/attachment/attachment-upload.tsx index c537361ef9..2a37b3b985 100644 --- a/apps/web/core/components/issues/attachment/attachment-upload.tsx +++ b/apps/web/core/components/issues/attachment/attachment-upload.tsx @@ -8,7 +8,7 @@ import { useCallback, useState } from "react"; import { observer } from "mobx-react"; import { useDropzone } from "react-dropzone"; // plane web hooks -import { useFileSize } from "@/plane-web/hooks/use-file-size"; +import { useFileSize } from "@/hooks/use-file-size"; // types import type { TAttachmentOperations } from "../issue-detail-widgets/attachments/helper"; diff --git a/apps/web/core/components/issues/issue-detail-widgets/attachments/quick-action-button.tsx b/apps/web/core/components/issues/issue-detail-widgets/attachments/quick-action-button.tsx index 7853b3b4e4..dc6155550f 100644 --- a/apps/web/core/components/issues/issue-detail-widgets/attachments/quick-action-button.tsx +++ b/apps/web/core/components/issues/issue-detail-widgets/attachments/quick-action-button.tsx @@ -15,7 +15,7 @@ import type { TIssueServiceType } from "@plane/types"; // hooks import { useIssueDetail } from "@/hooks/store/use-issue-detail"; // plane web hooks -import { useFileSize } from "@/plane-web/hooks/use-file-size"; +import { useFileSize } from "@/hooks/use-file-size"; // local imports import { useAttachmentOperations } from "./helper"; diff --git a/apps/web/core/hooks/editor/use-editor-config.ts b/apps/web/core/hooks/editor/use-editor-config.ts index 98eb92c753..95493050be 100644 --- a/apps/web/core/hooks/editor/use-editor-config.ts +++ b/apps/web/core/hooks/editor/use-editor-config.ts @@ -12,7 +12,7 @@ import { getEditorAssetDownloadSrc, getEditorAssetSrc } from "@plane/utils"; import { useEditorAsset } from "@/hooks/store/use-editor-asset"; // plane web hooks import { useExtendedEditorConfig } from "@/plane-web/hooks/editor/use-extended-editor-config"; -import { useFileSize } from "@/plane-web/hooks/use-file-size"; +import { useFileSize } from "@/hooks/use-file-size"; // services import { FileService } from "@/services/file.service"; const fileService = new FileService(); diff --git a/apps/web/ce/hooks/use-file-size.ts b/apps/web/core/hooks/use-file-size.ts similarity index 100% rename from apps/web/ce/hooks/use-file-size.ts rename to apps/web/core/hooks/use-file-size.ts