Compare commits
37
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b8d9efe5b6 | ||
|
|
50cf8f8bbf | ||
|
|
754630fd16 | ||
|
|
c0c06599c9 | ||
|
|
9a6667e07c | ||
|
|
7cdf150bdf | ||
|
|
bffa52c974 | ||
|
|
f266e80556 | ||
|
|
7f40365aae | ||
|
|
30c0bca0b1 | ||
|
|
1dd0ccd901 | ||
|
|
ecaac0dcbc | ||
|
|
1c3880e977 | ||
|
|
c4abc24578 | ||
|
|
338a650935 | ||
|
|
7f90ed2e83 | ||
|
|
ea1eabac9e | ||
|
|
384fef9f30 | ||
|
|
7543413947 | ||
|
|
b053e10961 | ||
|
|
cae8617f3e | ||
|
|
42f582acae | ||
|
|
8c88af8057 | ||
|
|
378b49b27a | ||
|
|
033ea1262d | ||
|
|
813de842e9 | ||
|
|
0f0104fcac | ||
|
|
9ae465178c | ||
|
|
5cebdab9c8 | ||
|
|
0c9abc14ec | ||
|
|
47606db169 | ||
|
|
4f0f05fd0c | ||
|
|
d7d016d350 | ||
|
|
c024d37dd2 | ||
|
|
1b9e67fd82 | ||
|
|
f6286cc403 | ||
|
|
5303ce2a2f |
+2
-2
@@ -115,5 +115,5 @@ scripts/
|
||||
# i18n auto-generated types (regenerated on every build)
|
||||
packages/i18n/src/types/keys.generated.ts
|
||||
|
||||
# Local security notes (not for version control)
|
||||
/security/
|
||||
# Local security advisory notes (not for version control)
|
||||
/advisories.md
|
||||
|
||||
@@ -19,7 +19,6 @@ from plane.bgtasks.storage_metadata_task import get_asset_object_metadata
|
||||
from plane.settings.storage import S3Storage
|
||||
from plane.utils.path_validator import sanitize_filename
|
||||
from plane.db.models import FileAsset, User, Workspace
|
||||
from plane.app.permissions import WorkspaceUserPermission
|
||||
from plane.api.views.base import BaseAPIView
|
||||
from plane.api.serializers import (
|
||||
UserAssetUploadSerializer,
|
||||
@@ -405,12 +404,6 @@ class UserServerAssetEndpoint(BaseAPIView):
|
||||
class GenericAssetEndpoint(BaseAPIView):
|
||||
"""This endpoint is used to upload generic assets that can be later bound to entities."""
|
||||
|
||||
# The workspace is taken straight from the URL slug, so every method must
|
||||
# verify the caller is an active member of that workspace. Without this the
|
||||
# endpoint is a cross-workspace IDOR (the public-API sibling of the
|
||||
# CVE-2026-46558 dashboard fix).
|
||||
permission_classes = [WorkspaceUserPermission]
|
||||
|
||||
use_read_replica = True
|
||||
|
||||
@asset_docs(
|
||||
|
||||
@@ -1,143 +0,0 @@
|
||||
# Copyright (c) 2023-present Plane Software, Inc. and contributors
|
||||
# SPDX-License-Identifier: AGPL-3.0-only
|
||||
# See the LICENSE file for details.
|
||||
|
||||
"""Contract tests for the public REST API ``GenericAssetEndpoint``.
|
||||
|
||||
Regression coverage for the cross-workspace asset IDOR (the unfixed
|
||||
external-API sibling of CVE-2026-46558 / GHSA-qw87-v5w3-6vxx). The endpoint
|
||||
must reject any caller that is not an active member of the workspace named in
|
||||
the URL slug, regardless of the workspace their Personal Access Token came
|
||||
from.
|
||||
"""
|
||||
|
||||
from unittest import mock
|
||||
from uuid import uuid4
|
||||
|
||||
import pytest
|
||||
from rest_framework import status
|
||||
|
||||
from plane.db.models import FileAsset, User, Workspace, WorkspaceMember
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def victim_user(db):
|
||||
"""A user that owns a separate workspace the attacker is not part of."""
|
||||
unique_id = uuid4().hex[:8]
|
||||
user = User.objects.create(
|
||||
email=f"victim-{unique_id}@plane.so",
|
||||
username=f"victim_{unique_id}",
|
||||
first_name="Victim",
|
||||
last_name="User",
|
||||
)
|
||||
user.set_password("test-password")
|
||||
user.save()
|
||||
return user
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def victim_workspace(db, victim_user):
|
||||
"""A workspace whose only active member is ``victim_user``.
|
||||
|
||||
The attacker (``create_user``, who authenticates ``api_key_client``) is
|
||||
deliberately NOT a member here.
|
||||
"""
|
||||
workspace = Workspace.objects.create(
|
||||
name="Victim Workspace",
|
||||
owner=victim_user,
|
||||
slug="victim-workspace",
|
||||
)
|
||||
WorkspaceMember.objects.create(workspace=workspace, member=victim_user, role=20)
|
||||
return workspace
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def victim_asset(db, victim_workspace, victim_user):
|
||||
"""An uploaded attachment that lives inside the victim workspace.
|
||||
|
||||
``storage_metadata`` is pre-populated so the PATCH handler does not enqueue
|
||||
the metadata Celery task during the test.
|
||||
"""
|
||||
return FileAsset.objects.create(
|
||||
attributes={"name": "secret.pdf", "type": "application/pdf", "size": 1024},
|
||||
asset=f"{victim_workspace.id}/secret.pdf",
|
||||
size=1024,
|
||||
workspace=victim_workspace,
|
||||
created_by=victim_user,
|
||||
entity_type=FileAsset.EntityTypeContext.ISSUE_ATTACHMENT,
|
||||
is_uploaded=True,
|
||||
storage_metadata={"size": 1024},
|
||||
)
|
||||
|
||||
|
||||
@pytest.mark.contract
|
||||
class TestGenericAssetCrossWorkspaceIDOR:
|
||||
"""A PAT holder must not reach assets in a workspace they don't belong to."""
|
||||
|
||||
def detail_url(self, slug, asset_id):
|
||||
return f"/api/v1/workspaces/{slug}/assets/{asset_id}/"
|
||||
|
||||
def list_url(self, slug):
|
||||
return f"/api/v1/workspaces/{slug}/assets/"
|
||||
|
||||
@pytest.mark.django_db
|
||||
def test_get_cross_workspace_asset_returns_403(self, api_key_client, victim_workspace, victim_asset):
|
||||
"""GET on another workspace's asset must be forbidden, not return a
|
||||
presigned download URL."""
|
||||
url = self.detail_url(victim_workspace.slug, victim_asset.id)
|
||||
|
||||
with mock.patch("plane.api.views.asset.S3Storage") as mock_storage:
|
||||
mock_storage.return_value.generate_presigned_url.return_value = "https://signed.example/download"
|
||||
response = api_key_client.get(url)
|
||||
|
||||
assert response.status_code == status.HTTP_403_FORBIDDEN, f"Got {response.status_code}: {response.data!r}"
|
||||
# The S3 download URL must never be minted for a non-member.
|
||||
mock_storage.return_value.generate_presigned_url.assert_not_called()
|
||||
|
||||
@pytest.mark.django_db
|
||||
def test_post_cross_workspace_asset_returns_403(self, api_key_client, victim_workspace):
|
||||
"""POST (upload) into another workspace must be forbidden and must not
|
||||
plant an asset row in the victim workspace."""
|
||||
url = self.list_url(victim_workspace.slug)
|
||||
payload = {"name": "evil.pdf", "type": "application/pdf", "size": 1024}
|
||||
|
||||
with mock.patch("plane.api.views.asset.S3Storage") as mock_storage:
|
||||
mock_storage.return_value.generate_presigned_post.return_value = {"url": "x", "fields": {}}
|
||||
response = api_key_client.post(url, payload, format="json")
|
||||
|
||||
assert response.status_code == status.HTTP_403_FORBIDDEN, f"Got {response.status_code}: {response.data!r}"
|
||||
assert FileAsset.objects.filter(workspace=victim_workspace).count() == 0
|
||||
|
||||
@pytest.mark.django_db
|
||||
def test_patch_cross_workspace_asset_returns_403(self, api_key_client, victim_workspace, victim_asset):
|
||||
"""PATCH on another workspace's asset must be forbidden and must leave
|
||||
the asset untouched."""
|
||||
url = self.detail_url(victim_workspace.slug, victim_asset.id)
|
||||
|
||||
response = api_key_client.patch(url, {"is_uploaded": False}, format="json")
|
||||
|
||||
assert response.status_code == status.HTTP_403_FORBIDDEN, f"Got {response.status_code}: {response.data!r}"
|
||||
victim_asset.refresh_from_db()
|
||||
assert victim_asset.is_uploaded is True
|
||||
|
||||
@pytest.mark.django_db
|
||||
def test_member_can_patch_own_workspace_asset(self, api_key_client, workspace, create_user):
|
||||
"""Positive control: an active member of the workspace can still update
|
||||
their own asset, so the fix does not over-block legitimate callers."""
|
||||
asset = FileAsset.objects.create(
|
||||
attributes={"name": "mine.pdf", "type": "application/pdf", "size": 10},
|
||||
asset=f"{workspace.id}/mine.pdf",
|
||||
size=10,
|
||||
workspace=workspace,
|
||||
created_by=create_user,
|
||||
entity_type=FileAsset.EntityTypeContext.ISSUE_ATTACHMENT,
|
||||
is_uploaded=False,
|
||||
storage_metadata={"size": 10},
|
||||
)
|
||||
url = self.detail_url(workspace.slug, asset.id)
|
||||
|
||||
response = api_key_client.patch(url, {"is_uploaded": True}, format="json")
|
||||
|
||||
assert response.status_code == status.HTTP_204_NO_CONTENT, f"Got {response.status_code}: {response.data!r}"
|
||||
asset.refresh_from_db()
|
||||
assert asset.is_uploaded is True
|
||||
@@ -27,7 +27,7 @@ import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// layouts
|
||||
import { ProjectAuthWrapper } from "@/layouts/auth-layout/project-wrapper";
|
||||
// plane web imports
|
||||
import { useWorkItemProperties } from "@/hooks/use-issue-properties";
|
||||
import { useWorkItemProperties } from "@/plane-web/hooks/use-issue-properties";
|
||||
import { WorkItemDetailRoot } from "@/plane-web/components/browse/workItem-detail";
|
||||
|
||||
import type { Route } from "./+types/page";
|
||||
|
||||
+1
-1
@@ -20,7 +20,7 @@ import { useProject } from "@/hooks/store/use-project";
|
||||
// plane web
|
||||
import { ProjectBreadcrumb } from "@/plane-web/components/breadcrumbs/project";
|
||||
// services
|
||||
import { IssueService } from "@/services/issue";
|
||||
import { IssueService } from "@plane/services";
|
||||
|
||||
const issueService = new IssueService();
|
||||
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@ import { LogoSpinner } from "@/components/common/logo-spinner";
|
||||
// hooks
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// services
|
||||
import { IssueService } from "@/services/issue/issue.service";
|
||||
import { IssueService } from "@plane/services";
|
||||
// types
|
||||
import type { Route } from "./+types/page";
|
||||
|
||||
|
||||
+2
-2
@@ -27,11 +27,11 @@ import { useEditorAsset } from "@/hooks/store/use-editor-asset";
|
||||
import { useWorkspace } from "@/hooks/store/use-workspace";
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// plane web hooks
|
||||
import { EPageStoreType, usePage, usePageStore } from "@/hooks/store";
|
||||
import { EPageStoreType, usePage, usePageStore } from "@/plane-web/hooks/store";
|
||||
// plane web services
|
||||
import { WorkspaceService } from "@/services/workspace.service";
|
||||
// services
|
||||
import { ProjectPageService, ProjectPageVersionService } from "@/services/page";
|
||||
import { ProjectPageService, ProjectPageVersionService } from "@plane/services";
|
||||
import type { Route } from "./+types/page";
|
||||
const workspaceService = new WorkspaceService();
|
||||
const projectPageService = new ProjectPageService();
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@ import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// plane web imports
|
||||
import { CommonProjectBreadcrumbs } from "@/plane-web/components/breadcrumbs/common";
|
||||
import { PageDetailsHeaderExtraActions } from "@/plane-web/components/pages";
|
||||
import { EPageStoreType, usePage, usePageStore } from "@/hooks/store";
|
||||
import { EPageStoreType, usePage, usePageStore } from "@/plane-web/hooks/store";
|
||||
|
||||
export interface IPagesHeaderProps {
|
||||
showButton?: boolean;
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@ import useSWR from "swr";
|
||||
import { AppHeader } from "@/components/core/app-header";
|
||||
import { ContentWrapper } from "@/components/core/content-wrapper";
|
||||
// plane web hooks
|
||||
import { EPageStoreType, usePageStore } from "@/hooks/store";
|
||||
import { EPageStoreType, usePageStore } from "@/plane-web/hooks/store";
|
||||
// local components
|
||||
import type { Route } from "./+types/layout";
|
||||
import { PageDetailsHeader } from "./header";
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ import { BreadcrumbLink } from "@/components/common/breadcrumb-link";
|
||||
import { useProject } from "@/hooks/store/use-project";
|
||||
// plane web imports
|
||||
import { CommonProjectBreadcrumbs } from "@/plane-web/components/breadcrumbs/common";
|
||||
import { EPageStoreType, usePageStore } from "@/hooks/store";
|
||||
import { EPageStoreType, usePageStore } from "@/plane-web/hooks/store";
|
||||
|
||||
export const PagesListHeader = observer(function PagesListHeader() {
|
||||
// states
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@ import { useProject } from "@/hooks/store/use-project";
|
||||
import { useUserPermissions } from "@/hooks/store/user";
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// plane web hooks
|
||||
import { EPageStoreType } from "@/hooks/store";
|
||||
import { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import type { Route } from "./+types/page";
|
||||
|
||||
const getPageType = (pageType?: string | null): TPageNavigationTabs => {
|
||||
|
||||
+1
-1
@@ -19,7 +19,7 @@ import { APP_INTEGRATIONS } from "@plane/constants";
|
||||
import { useWorkspace } from "@/hooks/store/use-workspace";
|
||||
import { useUserPermissions } from "@/hooks/store/user";
|
||||
// services
|
||||
import { IntegrationService } from "@/services/integrations";
|
||||
import { IntegrationService } from "@plane/services";
|
||||
|
||||
const integrationService = new IntegrationService();
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
import { Outlet } from "react-router";
|
||||
import { AuthenticationWrapper } from "@/lib/wrappers/authentication-wrapper";
|
||||
import { WorkspaceContentWrapper } from "@/plane-web/components/workspace/content-wrapper";
|
||||
import { AppRailVisibilityProvider } from "@/lib/app-rail";
|
||||
import { AppRailVisibilityProvider } from "@/plane-web/hooks/app-rail";
|
||||
import { GlobalModals } from "@/plane-web/components/common/modal/global";
|
||||
import { WorkspaceAuthWrapper } from "@/layouts/auth-layout/workspace-wrapper";
|
||||
import type { Route } from "./+types/layout";
|
||||
|
||||
@@ -13,7 +13,7 @@ import { CreateUpdateProjectViewModal } from "@/components/views/modal";
|
||||
// hooks
|
||||
import { useCommandPalette } from "@/hooks/store/use-command-palette";
|
||||
// plane web hooks
|
||||
import { EPageStoreType } from "@/hooks/store";
|
||||
import { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
|
||||
export type TProjectLevelModalsProps = {
|
||||
workspaceSlug: string;
|
||||
|
||||
@@ -18,8 +18,8 @@ import { RichTextEditor } from "@/components/editor/rich-text";
|
||||
// plane web constants
|
||||
import { AI_EDITOR_TASKS, LOADING_TEXTS } from "@plane/constants";
|
||||
// plane web services
|
||||
import type { TTaskPayload } from "@/services/ai.service";
|
||||
import { AIService } from "@/services/ai.service";
|
||||
import type { TTaskPayload } from "@plane/services";
|
||||
import { AIService } from "@plane/services";
|
||||
import { AskPiMenu } from "./ask-pi-menu";
|
||||
const aiService = new AIService();
|
||||
|
||||
@@ -75,7 +75,7 @@ export function EditorAIMenu(props: Props) {
|
||||
// params
|
||||
const handleGenerateResponse = async (payload: TTaskPayload) => {
|
||||
if (!workspaceSlug) return;
|
||||
await aiService.performEditorTask(workspaceSlug.toString(), payload).then((res) => setResponse(res.response));
|
||||
await aiService.rephraseGrammar(workspaceSlug.toString(), payload).then((res) => setResponse(res.response));
|
||||
};
|
||||
// handle task click
|
||||
const handleClick = async (key: AI_EDITOR_TASKS) => {
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*/
|
||||
|
||||
// store
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
|
||||
export type TPageHeaderExtraActionsProps = {
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
import { observer } from "mobx-react";
|
||||
// components
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
|
||||
|
||||
@@ -110,7 +110,7 @@ export const CreateProjectForm = observer(function CreateProjectForm(props: TCre
|
||||
if (setToFavorite) {
|
||||
handleAddToFavorites(res.id);
|
||||
}
|
||||
return handleNextStep(res.id);
|
||||
handleNextStep(res.id);
|
||||
})
|
||||
.catch((err) => {
|
||||
try {
|
||||
@@ -119,9 +119,8 @@ export const CreateProjectForm = observer(function CreateProjectForm(props: TCre
|
||||
|
||||
const nameError = errorData.name?.includes("PROJECT_NAME_ALREADY_EXIST");
|
||||
const identifierError = errorData?.identifier?.includes("PROJECT_IDENTIFIER_ALREADY_EXIST");
|
||||
const nameSpecialCharError = errorData?.name?.includes("PROJECT_NAME_CANNOT_CONTAIN_SPECIAL_CHARACTERS");
|
||||
|
||||
if (nameError || identifierError || nameSpecialCharError) {
|
||||
if (nameError || identifierError) {
|
||||
if (nameError) {
|
||||
setToast({
|
||||
type: TOAST_TYPE.ERROR,
|
||||
@@ -137,14 +136,6 @@ export const CreateProjectForm = observer(function CreateProjectForm(props: TCre
|
||||
message: t("project_identifier_already_taken"),
|
||||
});
|
||||
}
|
||||
|
||||
if (nameSpecialCharError) {
|
||||
setToast({
|
||||
type: TOAST_TYPE.ERROR,
|
||||
title: t("toast.error"),
|
||||
message: t("project_name_cannot_contain_special_characters"),
|
||||
});
|
||||
}
|
||||
} else {
|
||||
setToast({
|
||||
type: TOAST_TYPE.ERROR,
|
||||
|
||||
@@ -4,4 +4,4 @@
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
export * from "./favorite.service";
|
||||
export * from "./provider";
|
||||
@@ -0,0 +1,23 @@
|
||||
/**
|
||||
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
import React from "react";
|
||||
import { observer } from "mobx-react";
|
||||
import { AppRailVisibilityProvider as CoreProvider } from "@/lib/app-rail";
|
||||
|
||||
interface AppRailVisibilityProviderProps {
|
||||
children: React.ReactNode;
|
||||
}
|
||||
|
||||
/**
|
||||
* CE AppRailVisibilityProvider
|
||||
* Wraps core provider with isEnabled hardcoded to false
|
||||
*/
|
||||
export const AppRailVisibilityProvider = observer(function AppRailVisibilityProvider({
|
||||
children,
|
||||
}: AppRailVisibilityProviderProps) {
|
||||
return <CoreProvider isEnabled={false}>{children}</CoreProvider>;
|
||||
});
|
||||
@@ -4,5 +4,5 @@
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
export * from "./use-extended-editor-extensions";
|
||||
export * from "./use-pages-pane-extensions";
|
||||
export * from "./use-extended-editor-extensions";
|
||||
+1
-1
@@ -7,7 +7,7 @@
|
||||
import type { IEditorPropsExtended } from "@plane/editor";
|
||||
import type { TSearchEntityRequestPayload, TSearchResponse } from "@plane/types";
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "../store";
|
||||
|
||||
export type TExtendedEditorExtensionsHookParams = {
|
||||
workspaceSlug: string;
|
||||
@@ -8,8 +8,8 @@ import { useContext } from "react";
|
||||
// mobx store
|
||||
import { StoreContext } from "@/lib/store-context";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "./use-page-store";
|
||||
import { usePageStore } from "./use-page-store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageStore } from "@/plane-web/hooks/store";
|
||||
|
||||
export type TArgs = {
|
||||
pageId: string;
|
||||
+1
-1
@@ -6,7 +6,7 @@
|
||||
|
||||
// editor
|
||||
import type { TExtensions } from "@plane/editor";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
|
||||
export type TEditorFlaggingHookReturnType = {
|
||||
document: {
|
||||
@@ -0,0 +1,31 @@
|
||||
/**
|
||||
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
// editor
|
||||
import type { TEmbedConfig } from "@plane/editor";
|
||||
// plane types
|
||||
import type { TSearchEntityRequestPayload, TSearchResponse } from "@plane/types";
|
||||
// plane web components
|
||||
import { IssueEmbedUpgradeCard } from "@/plane-web/components/pages";
|
||||
|
||||
export type TIssueEmbedHookProps = {
|
||||
fetchEmbedSuggestions?: (payload: TSearchEntityRequestPayload) => Promise<TSearchResponse>;
|
||||
projectId?: string;
|
||||
workspaceSlug?: string;
|
||||
};
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
export const useIssueEmbed = (props: TIssueEmbedHookProps) => {
|
||||
const widgetCallback = () => <IssueEmbedUpgradeCard />;
|
||||
|
||||
const issueEmbedProps: TEmbedConfig["issue"] = {
|
||||
widgetCallback,
|
||||
};
|
||||
|
||||
return {
|
||||
issueEmbedProps,
|
||||
};
|
||||
};
|
||||
@@ -0,0 +1,32 @@
|
||||
/**
|
||||
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
* See the LICENSE file for details.
|
||||
*/
|
||||
|
||||
// types
|
||||
import type { TTimelineTypeCore } from "@plane/types";
|
||||
import { GANTT_TIMELINE_TYPE } from "@plane/types";
|
||||
// Plane-web
|
||||
|
||||
import type { IBaseTimelineStore } from "@/plane-web/store/timeline/base-timeline.store";
|
||||
import type { ITimelineStore } from "../store/timeline";
|
||||
|
||||
export const getTimelineStore = (
|
||||
timelineStore: ITimelineStore,
|
||||
timelineType: TTimelineTypeCore
|
||||
): IBaseTimelineStore => {
|
||||
if (timelineType === GANTT_TIMELINE_TYPE.ISSUE) {
|
||||
return timelineStore.issuesTimeLineStore as IBaseTimelineStore;
|
||||
}
|
||||
if (timelineType === GANTT_TIMELINE_TYPE.MODULE) {
|
||||
return timelineStore.modulesTimeLineStore as IBaseTimelineStore;
|
||||
}
|
||||
if (timelineType === GANTT_TIMELINE_TYPE.PROJECT) {
|
||||
return timelineStore.projectTimeLineStore;
|
||||
}
|
||||
if (timelineType === GANTT_TIMELINE_TYPE.GROUPED) {
|
||||
return timelineStore.groupedTimeLineStore;
|
||||
}
|
||||
throw new Error(`Unknown timeline type: ${timelineType}`);
|
||||
};
|
||||
+1
-1
@@ -61,7 +61,7 @@ import { useModule } from "@/hooks/store/use-module";
|
||||
import { useProject } from "@/hooks/store/use-project";
|
||||
import { useProjectState } from "@/hooks/store/use-project-state";
|
||||
// plane web imports
|
||||
import { useFiltersOperatorConfigs } from "@/hooks/rich-filters/use-filters-operator-configs";
|
||||
import { useFiltersOperatorConfigs } from "@/plane-web/hooks/rich-filters/use-filters-operator-configs";
|
||||
|
||||
export type TWorkItemFiltersEntityProps = {
|
||||
workspaceSlug: string;
|
||||
@@ -14,7 +14,7 @@ import type {
|
||||
TEstimateSystemKeys,
|
||||
} from "@plane/types";
|
||||
// plane web services
|
||||
import estimateService from "@/services/estimate.service";
|
||||
import { EstimateService } from "@plane/services";
|
||||
// store
|
||||
import type { IEstimatePoint } from "@/store/estimates/estimate-point";
|
||||
import { EstimatePoint } from "@/store/estimates/estimate-point";
|
||||
@@ -41,6 +41,8 @@ export interface IEstimate extends Omit<IEstimateType, "points"> {
|
||||
) => Promise<IEstimatePointType | undefined>;
|
||||
}
|
||||
|
||||
const estimateService = new EstimateService();
|
||||
|
||||
export class Estimate implements IEstimate {
|
||||
// data model observables
|
||||
id: string | undefined = undefined;
|
||||
|
||||
@@ -20,7 +20,7 @@ import type {
|
||||
import { EIssueServiceType } from "@plane/types";
|
||||
// plane web constants
|
||||
// services
|
||||
import { IssueActivityService } from "@/services/issue";
|
||||
import { IssueActivityService } from "@plane/services";
|
||||
// store
|
||||
import type { CoreRootStore } from "@/store/root.store";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import { cn, checkEmailValidity } from "@plane/utils";
|
||||
// hooks
|
||||
import useTimer from "@/hooks/use-timer";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
// local components
|
||||
import { FormContainer } from "./common/container";
|
||||
import { AuthFormHeader } from "./common/header";
|
||||
|
||||
@@ -16,7 +16,7 @@ import { authErrorHandler } from "@/helpers/authentication.helper";
|
||||
import { useInstance } from "@/hooks/store/use-instance";
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
// local components
|
||||
import { AuthEmailForm } from "./email";
|
||||
import { AuthPasswordForm } from "./password";
|
||||
|
||||
@@ -22,7 +22,7 @@ import { ForgotPasswordPopover } from "@/components/account/auth-forms/forgot-pa
|
||||
// helpers
|
||||
import { EAuthModes, EAuthSteps } from "@/helpers/authentication.helper";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
email: string;
|
||||
|
||||
@@ -20,7 +20,7 @@ import { getPasswordStrength } from "@plane/utils";
|
||||
import type { EAuthenticationErrorCodes, TAuthErrorInfo } from "@/helpers/authentication.helper";
|
||||
import { EErrorAlertType, authErrorHandler } from "@/helpers/authentication.helper";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
// local imports
|
||||
import { AuthBanner } from "./auth-banner";
|
||||
import { FormContainer } from "./common/container";
|
||||
|
||||
@@ -22,7 +22,7 @@ import { getPasswordStrength } from "@plane/utils";
|
||||
import { useUser } from "@/hooks/store/user";
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
// local components
|
||||
import { FormContainer } from "./common/container";
|
||||
import { AuthFormHeader } from "./common/header";
|
||||
|
||||
@@ -16,7 +16,7 @@ import { EAuthModes } from "@/helpers/authentication.helper";
|
||||
// hooks
|
||||
import useTimer from "@/hooks/use-timer";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
|
||||
// services
|
||||
const authService = new AuthService();
|
||||
|
||||
@@ -15,7 +15,7 @@ import type { TChartData } from "@plane/types";
|
||||
// hooks
|
||||
import { useAnalytics } from "@/hooks/store/use-analytics";
|
||||
// services
|
||||
import { AnalyticsService } from "@/services/analytics.service";
|
||||
import { AnalyticsService } from "@plane/services";
|
||||
// plane web components
|
||||
import AnalyticsSectionWrapper from "../analytics-section-wrapper";
|
||||
import { ProjectInsightsLoader } from "../loaders";
|
||||
|
||||
@@ -16,7 +16,7 @@ import { cn } from "@plane/utils";
|
||||
// hooks
|
||||
import { useAnalytics } from "@/hooks/store/use-analytics";
|
||||
// services
|
||||
import { AnalyticsService } from "@/services/analytics.service";
|
||||
import { AnalyticsService } from "@plane/services";
|
||||
// local imports
|
||||
import InsightCard from "./insight-card";
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ import { renderFormattedDate } from "@plane/utils";
|
||||
// hooks
|
||||
import { useAnalytics } from "@/hooks/store/use-analytics";
|
||||
// services
|
||||
import { AnalyticsService } from "@/services/analytics.service";
|
||||
import { AnalyticsService } from "@plane/services";
|
||||
// plane web components
|
||||
import AnalyticsSectionWrapper from "../analytics-section-wrapper";
|
||||
import { ChartLoader } from "../loaders";
|
||||
|
||||
@@ -24,7 +24,7 @@ import { generateExtendedColors, parseChartData } from "@/components/chart/utils
|
||||
// hooks
|
||||
import { useAnalytics } from "@/hooks/store/use-analytics";
|
||||
import { useProjectState } from "@/hooks/store/use-project-state";
|
||||
import { AnalyticsService } from "@/services/analytics.service";
|
||||
import { AnalyticsService } from "@plane/services";
|
||||
import { exportCSV } from "../export";
|
||||
import { DataTable } from "../insight-table/data-table";
|
||||
import { ChartLoader } from "../loaders";
|
||||
|
||||
@@ -21,7 +21,7 @@ import { getFileURL } from "@plane/utils";
|
||||
// hooks
|
||||
import { useAnalytics } from "@/hooks/store/use-analytics";
|
||||
import { useProject } from "@/hooks/store/use-project";
|
||||
import { AnalyticsService } from "@/services/analytics.service";
|
||||
import { AnalyticsService } from "@plane/services";
|
||||
// plane web components
|
||||
import { exportCSV } from "../export";
|
||||
import { InsightTable } from "../insight-table";
|
||||
|
||||
@@ -30,7 +30,7 @@ import { SimpleEmptyState } from "@/components/empty-state/simple-empty-state-ro
|
||||
import { useIssues } from "@/hooks/store/use-issues";
|
||||
import useDebounce from "@/hooks/use-debounce";
|
||||
// services
|
||||
import { ProjectService } from "@/services/project";
|
||||
import { ProjectService } from "@plane/services";
|
||||
// local components
|
||||
import { BulkDeleteIssuesModalItem } from "./bulk-delete-issues-modal-item";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import type { EAuthenticationErrorCodes } from "@/helpers/authentication.helper"
|
||||
// hooks
|
||||
import { useUser } from "@/hooks/store/user";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
import userService from "@/services/user.service";
|
||||
|
||||
type Props = { isOpen: boolean; onClose: () => void };
|
||||
|
||||
@@ -25,7 +25,7 @@ import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// plane web components
|
||||
import { IssueIdentifier } from "@/plane-web/components/issues/issue-details/issue-identifier";
|
||||
// services
|
||||
import { ProjectService } from "@/services/project";
|
||||
import { ProjectService } from "@plane/services";
|
||||
// components
|
||||
import { IssueSearchModalEmptyState } from "./issue-search-modal-empty-state";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import { Input } from "@plane/ui";
|
||||
// components
|
||||
import { RichTextEditor } from "@/components/editor/rich-text";
|
||||
// services
|
||||
import { AIService } from "@/services/ai.service";
|
||||
import { AIService } from "@plane/services";
|
||||
const aiService = new AIService();
|
||||
|
||||
type Props = {
|
||||
@@ -106,7 +106,7 @@ export function GptAssistantPopover(props: Props) {
|
||||
|
||||
const callAIService = async (formData: FormData) => {
|
||||
try {
|
||||
const res = await aiService.createGptTask(workspaceSlug.toString(), {
|
||||
const res = await aiService.prompt(workspaceSlug.toString(), {
|
||||
prompt: prompt || "",
|
||||
task: formData.task,
|
||||
});
|
||||
|
||||
@@ -22,7 +22,7 @@ import { useCycle } from "@/hooks/store/use-cycle";
|
||||
import { useUserPermissions } from "@/hooks/store/user";
|
||||
import { useTimeZoneConverter } from "@/hooks/use-timezone-converter";
|
||||
// services
|
||||
import { CycleService } from "@/services/cycle.service";
|
||||
import { CycleService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
workspaceSlug: string;
|
||||
@@ -74,7 +74,7 @@ export const CycleSidebarHeader = observer(function CycleSidebarHeader(props: Pr
|
||||
|
||||
const dateChecker = async (payload: any) => {
|
||||
try {
|
||||
const res = await cycleService.cycleDateCheck(workspaceSlug, projectId, payload);
|
||||
const res = await cycleService.validateDates(workspaceSlug, projectId, payload);
|
||||
return res.status;
|
||||
} catch (_err) {
|
||||
return false;
|
||||
|
||||
@@ -19,7 +19,7 @@ import useKeypress from "@/hooks/use-keypress";
|
||||
import useLocalStorage from "@/hooks/use-local-storage";
|
||||
import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// services
|
||||
import { CycleService } from "@/services/cycle.service";
|
||||
import { CycleService } from "@plane/services";
|
||||
// local imports
|
||||
import { CycleForm } from "./form";
|
||||
|
||||
@@ -100,7 +100,7 @@ export function CycleCreateUpdateModal(props: CycleModalProps) {
|
||||
const dateChecker = async (projectId: string, payload: CycleDateCheckData) => {
|
||||
let status = false;
|
||||
|
||||
await cycleService.cycleDateCheck(workspaceSlug, projectId, payload).then((res) => {
|
||||
await cycleService.validateDates(workspaceSlug, projectId, payload).then((res) => {
|
||||
status = res.status;
|
||||
});
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ import { useEditorConfig, useEditorMention } from "@/hooks/editor";
|
||||
import { useMember } from "@/hooks/store/use-member";
|
||||
import { useParseEditorContent } from "@/hooks/use-parse-editor-content";
|
||||
// plane web hooks
|
||||
import { useEditorFlagging } from "@/hooks/use-editor-flagging";
|
||||
import { useEditorFlagging } from "@/plane-web/hooks/use-editor-flagging";
|
||||
// local imports
|
||||
import { EditorMentionsRoot } from "../embeds/mentions";
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ import { useEditorConfig, useEditorMention } from "@/hooks/editor";
|
||||
import { useMember } from "@/hooks/store/use-member";
|
||||
import { useParseEditorContent } from "@/hooks/use-parse-editor-content";
|
||||
// plane web hooks
|
||||
import { useEditorFlagging } from "@/hooks/use-editor-flagging";
|
||||
import { useEditorFlagging } from "@/plane-web/hooks/use-editor-flagging";
|
||||
// plane web service
|
||||
import { WorkspaceService } from "@/services/workspace.service";
|
||||
import { LiteToolbar } from "./lite-toolbar";
|
||||
|
||||
@@ -17,7 +17,7 @@ import { useEditorConfig, useEditorMention } from "@/hooks/editor";
|
||||
import { useMember } from "@/hooks/store/use-member";
|
||||
import { useParseEditorContent } from "@/hooks/use-parse-editor-content";
|
||||
// plane web hooks
|
||||
import { useEditorFlagging } from "@/hooks/use-editor-flagging";
|
||||
import { useEditorFlagging } from "@/plane-web/hooks/use-editor-flagging";
|
||||
|
||||
type RichTextEditorWrapperProps = MakeOptional<
|
||||
Omit<IRichTextEditorProps, "fileHandler" | "mentionHandler" | "extendedEditorProps">,
|
||||
|
||||
@@ -18,7 +18,7 @@ import { cn } from "@plane/utils";
|
||||
import { useEditorConfig } from "@/hooks/editor";
|
||||
import { useParseEditorContent } from "@/hooks/use-parse-editor-content";
|
||||
// plane web hooks
|
||||
import { useEditorFlagging } from "@/hooks/use-editor-flagging";
|
||||
import { useEditorFlagging } from "@/plane-web/hooks/use-editor-flagging";
|
||||
import { StickyEditorToolbar } from "./toolbar";
|
||||
|
||||
interface StickyEditorWrapperProps extends Omit<
|
||||
|
||||
@@ -26,7 +26,7 @@ import { CustomSearchSelect, CustomSelect } from "@plane/ui";
|
||||
// import { WorkItemFiltersRow } from "@/components/work-item-filters/filters-row";
|
||||
import { useProject } from "@/hooks/store/use-project";
|
||||
import { useUser, useUserPermissions } from "@/hooks/store/user";
|
||||
import { ProjectExportService } from "@/services/project/project-export.service";
|
||||
import { ProjectExportService } from "@plane/services";
|
||||
// local imports
|
||||
import { SettingsBoxedControlItem } from "../settings/boxed-control-item";
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { useProject } from "@/hooks/store/use-project";
|
||||
import { useUser } from "@/hooks/store/user";
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// services
|
||||
import { ProjectExportService } from "@/services/project";
|
||||
import { ProjectExportService } from "@plane/services";
|
||||
type Props = {
|
||||
isOpen: boolean;
|
||||
handleClose: () => void;
|
||||
|
||||
@@ -19,7 +19,7 @@ import { ImportExportSettingsLoader } from "@/components/ui/loader/settings/impo
|
||||
// constants
|
||||
import { EXPORT_SERVICES_LIST } from "@plane/constants";
|
||||
// services
|
||||
import { IntegrationService } from "@/services/integrations";
|
||||
import { IntegrationService } from "@plane/services";
|
||||
// local imports
|
||||
import { useExportColumns } from "./column";
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ import { GanttChartRowList } from "@/plane-web/components/gantt-chart/blocks/blo
|
||||
import { GanttChartBlocksList } from "@/plane-web/components/gantt-chart/blocks/blocks-list";
|
||||
import { IssueBulkOperationsRoot } from "@/plane-web/components/issues/bulk-operations";
|
||||
// plane web hooks
|
||||
import { useBulkOperationStatus } from "@/hooks/use-bulk-operation-status";
|
||||
import { useBulkOperationStatus } from "@/plane-web/hooks/use-bulk-operation-status";
|
||||
//
|
||||
import { DEFAULT_BLOCK_WIDTH, GANTT_SELECT_GROUP, HEADER_HEIGHT } from "../constants";
|
||||
import { getItemPositionWidth } from "../views";
|
||||
|
||||
@@ -31,9 +31,9 @@ import { useUser } from "@/hooks/store/user";
|
||||
import useReloadConfirmations from "@/hooks/use-reload-confirmation";
|
||||
// store types
|
||||
import { DeDupeIssuePopoverRoot } from "@/plane-web/components/de-dupe/duplicate-popover";
|
||||
import { useDebouncedDuplicateIssues } from "@/hooks/use-debounced-duplicate-issues";
|
||||
import { useDebouncedDuplicateIssues } from "@/plane-web/hooks/use-debounced-duplicate-issues";
|
||||
// services
|
||||
import { IntakeWorkItemVersionService } from "@/services/inbox";
|
||||
import { IntakeWorkItemVersionService } from "@plane/services";
|
||||
// stores
|
||||
import type { IInboxIssueStore } from "@/store/inbox/inbox-issue.store";
|
||||
// local imports
|
||||
|
||||
@@ -26,7 +26,7 @@ import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// plane web imports
|
||||
import { DeDupeButtonRoot } from "@/plane-web/components/de-dupe/de-dupe-button";
|
||||
import { DuplicateModalRoot } from "@/plane-web/components/de-dupe/duplicate-modal";
|
||||
import { useDebouncedDuplicateIssues } from "@/hooks/use-debounced-duplicate-issues";
|
||||
import { useDebouncedDuplicateIssues } from "@/plane-web/hooks/use-debounced-duplicate-issues";
|
||||
// services
|
||||
import { FileService } from "@/services/file.service";
|
||||
// local imports
|
||||
|
||||
@@ -25,7 +25,7 @@ import { SimpleEmptyState } from "@/components/empty-state/simple-empty-state-ro
|
||||
import { useProject } from "@/hooks/store/use-project";
|
||||
import useDebounce from "@/hooks/use-debounce";
|
||||
// services
|
||||
import { ProjectService } from "@/services/project";
|
||||
import { ProjectService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean;
|
||||
|
||||
@@ -13,7 +13,7 @@ import type { IWorkspaceIntegration } from "@plane/types";
|
||||
import { CustomSearchSelect } from "@plane/ui";
|
||||
// helpers
|
||||
import { truncateText } from "@plane/utils";
|
||||
import { ProjectService } from "@/services/project";
|
||||
import { ProjectService } from "@plane/services";
|
||||
// types
|
||||
|
||||
type Props = {
|
||||
|
||||
@@ -27,7 +27,7 @@ import { useUserPermissions } from "@/hooks/store/user";
|
||||
import useIntegrationPopup from "@/hooks/use-integration-popup";
|
||||
import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// services
|
||||
import { IntegrationService } from "@/services/integrations";
|
||||
import { IntegrationService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
integration: IAppIntegration;
|
||||
|
||||
@@ -18,7 +18,7 @@ import { SLACK_CHANNEL_INFO } from "@plane/constants";
|
||||
import { useInstance } from "@/hooks/store/use-instance";
|
||||
import useIntegrationPopup from "@/hooks/use-integration-popup";
|
||||
// services
|
||||
import { AppInstallationService } from "@/services/app_installation.service";
|
||||
import { AppInstallationService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
integration: IWorkspaceIntegration;
|
||||
|
||||
@@ -16,7 +16,7 @@ import { EIssueServiceType } from "@plane/types";
|
||||
// hooks
|
||||
import { useIssueDetail } from "@/hooks/store/use-issue-detail";
|
||||
// plane web hooks
|
||||
import { useFileSize } from "@/hooks/use-file-size";
|
||||
import { useFileSize } from "@/plane-web/hooks/use-file-size";
|
||||
// types
|
||||
import type { TAttachmentHelpers } from "../issue-detail-widgets/attachments/helper";
|
||||
// components
|
||||
|
||||
@@ -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 "@/hooks/use-file-size";
|
||||
import { useFileSize } from "@/plane-web/hooks/use-file-size";
|
||||
// types
|
||||
import type { TAttachmentOperations } from "../issue-detail-widgets/attachments/helper";
|
||||
|
||||
|
||||
+1
-1
@@ -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 "@/hooks/use-file-size";
|
||||
import { useFileSize } from "@/plane-web/hooks/use-file-size";
|
||||
// local imports
|
||||
import { useAttachmentOperations } from "./helper";
|
||||
|
||||
|
||||
@@ -24,9 +24,9 @@ import useSize from "@/hooks/use-window-size";
|
||||
// plane web components
|
||||
import { DeDupeIssuePopoverRoot } from "@/plane-web/components/de-dupe/duplicate-popover";
|
||||
import { IssueTypeSwitcher } from "@/plane-web/components/issues/issue-details/issue-type-switcher";
|
||||
import { useDebouncedDuplicateIssues } from "@/hooks/use-debounced-duplicate-issues";
|
||||
import { useDebouncedDuplicateIssues } from "@/plane-web/hooks/use-debounced-duplicate-issues";
|
||||
// services
|
||||
import { WorkItemVersionService } from "@/services/issue";
|
||||
import { WorkItemVersionService } from "@plane/services";
|
||||
// local imports
|
||||
import { IssueDetailWidgets } from "../issue-detail-widgets";
|
||||
import { NameDescriptionUpdateStatus } from "../issue-update-status";
|
||||
|
||||
@@ -25,7 +25,7 @@ import { useIssueStoreType } from "@/hooks/use-issue-layout-store";
|
||||
import { useIssuesActions } from "@/hooks/use-issues-actions";
|
||||
import { useTimeLineChart } from "@/hooks/use-timeline-chart";
|
||||
// plane web hooks
|
||||
import { useBulkOperationStatus } from "@/hooks/use-bulk-operation-status";
|
||||
import { useBulkOperationStatus } from "@/plane-web/hooks/use-bulk-operation-status";
|
||||
|
||||
import { IssueLayoutHOC } from "../issue-layout-HOC";
|
||||
import { GanttQuickAddIssueButton, QuickAddIssueRoot } from "../quick-add";
|
||||
|
||||
@@ -29,7 +29,7 @@ import { useIssueStoreType } from "@/hooks/use-issue-layout-store";
|
||||
// plane web components
|
||||
import { IssueBulkOperationsRoot } from "@/plane-web/components/issues/bulk-operations";
|
||||
// plane web hooks
|
||||
import { useBulkOperationStatus } from "@/hooks/use-bulk-operation-status";
|
||||
import { useBulkOperationStatus } from "@/plane-web/hooks/use-bulk-operation-status";
|
||||
// utils
|
||||
import type { GroupDropLocation } from "../utils";
|
||||
import { getGroupByColumns, isWorkspaceLevel, isSubGrouped } from "../utils";
|
||||
|
||||
@@ -18,7 +18,7 @@ import { useProject } from "@/hooks/store/use-project";
|
||||
// plane web components
|
||||
import { IssueBulkOperationsRoot } from "@/plane-web/components/issues/bulk-operations";
|
||||
// plane web hooks
|
||||
import { useBulkOperationStatus } from "@/hooks/use-bulk-operation-status";
|
||||
import { useBulkOperationStatus } from "@/plane-web/hooks/use-bulk-operation-status";
|
||||
// local imports
|
||||
import type { TRenderQuickActions } from "../list/list-view-types";
|
||||
import { QuickAddIssueRoot, SpreadsheetAddIssueButton } from "../quick-add";
|
||||
|
||||
@@ -31,7 +31,7 @@ import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// plane web services
|
||||
import { WorkspaceService } from "@/services/workspace.service";
|
||||
// services
|
||||
import { AIService } from "@/services/ai.service";
|
||||
import { AIService } from "@plane/services";
|
||||
const workspaceService = new WorkspaceService();
|
||||
const aiService = new AIService();
|
||||
|
||||
@@ -120,7 +120,7 @@ export const IssueDescriptionEditor = observer(function IssueDescriptionEditor(p
|
||||
setIAmFeelingLucky(true);
|
||||
|
||||
aiService
|
||||
.createGptTask(workspaceSlug.toString(), {
|
||||
.prompt(workspaceSlug.toString(), {
|
||||
prompt: issueName,
|
||||
task: "Generate a proper description for this work item.",
|
||||
})
|
||||
|
||||
@@ -48,7 +48,7 @@ import { DeDupeButtonRoot } from "@/plane-web/components/de-dupe/de-dupe-button"
|
||||
import { DuplicateModalRoot } from "@/plane-web/components/de-dupe/duplicate-modal";
|
||||
import { IssueTypeSelect, WorkItemTemplateSelect } from "@/plane-web/components/issues/issue-modal";
|
||||
import { WorkItemModalAdditionalProperties } from "@/plane-web/components/issues/issue-modal/modal-additional-properties";
|
||||
import { useDebouncedDuplicateIssues } from "@/hooks/use-debounced-duplicate-issues";
|
||||
import { useDebouncedDuplicateIssues } from "@/plane-web/hooks/use-debounced-duplicate-issues";
|
||||
|
||||
export interface IssueFormProps {
|
||||
data?: Partial<TIssue>;
|
||||
|
||||
@@ -27,7 +27,7 @@ import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// plane web components
|
||||
import { IssueIdentifier } from "@/plane-web/components/issues/issue-details/issue-identifier";
|
||||
// services
|
||||
import { ProjectService } from "@/services/project";
|
||||
import { ProjectService } from "@plane/services";
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean;
|
||||
|
||||
@@ -25,9 +25,9 @@ import useReloadConfirmations from "@/hooks/use-reload-confirmation";
|
||||
import { DeDupeIssuePopoverRoot } from "@/plane-web/components/de-dupe/duplicate-popover";
|
||||
import { IssueTypeSwitcher } from "@/plane-web/components/issues/issue-details/issue-type-switcher";
|
||||
// plane web hooks
|
||||
import { useDebouncedDuplicateIssues } from "@/hooks/use-debounced-duplicate-issues";
|
||||
import { useDebouncedDuplicateIssues } from "@/plane-web/hooks/use-debounced-duplicate-issues";
|
||||
// services
|
||||
import { WorkItemVersionService } from "@/services/issue";
|
||||
import { WorkItemVersionService } from "@plane/services";
|
||||
// local components
|
||||
import type { TIssueOperations } from "../issue-detail";
|
||||
import { IssueParentDetail } from "../issue-detail/parent";
|
||||
|
||||
@@ -19,7 +19,7 @@ import { useIssueDetail } from "@/hooks/store/use-issue-detail";
|
||||
import { useIssues } from "@/hooks/store/use-issues";
|
||||
import { useUserPermissions } from "@/hooks/store/user";
|
||||
import { useIssueStoreType } from "@/hooks/use-issue-layout-store";
|
||||
import { useWorkItemProperties } from "@/hooks/use-issue-properties";
|
||||
import { useWorkItemProperties } from "@/plane-web/hooks/use-issue-properties";
|
||||
// local imports
|
||||
import type { TIssueOperations } from "../issue-detail";
|
||||
import { IssueView } from "./view";
|
||||
|
||||
@@ -22,7 +22,7 @@ import { UserImageUploadModal } from "@/components/core/modals/user-image-upload
|
||||
// hooks
|
||||
import { useUser, useUserProfile } from "@/hooks/store/user";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
|
||||
type TProfileSetupFormValues = {
|
||||
first_name: string;
|
||||
|
||||
@@ -21,7 +21,7 @@ import { UserImageUploadModal } from "@/components/core/modals/user-image-upload
|
||||
import { useInstance } from "@/hooks/store/use-instance";
|
||||
import { useUser, useUserProfile } from "@/hooks/store/user";
|
||||
// services
|
||||
import { AuthService } from "@/services/auth.service";
|
||||
import { AuthService } from "@plane/services";
|
||||
// local components
|
||||
import { CommonOnboardingHeader } from "../common";
|
||||
import { MarketingConsent } from "./consent";
|
||||
|
||||
@@ -23,8 +23,8 @@ import { usePageOperations } from "@/hooks/use-page-operations";
|
||||
// plane web components
|
||||
import { MovePageModal } from "@/plane-web/components/pages";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePageFlag } from "@/hooks/use-page-flag";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageFlag } from "@/plane-web/hooks/use-page-flag";
|
||||
// store types
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
|
||||
|
||||
@@ -36,9 +36,9 @@ import { useParseEditorContent } from "@/hooks/use-parse-editor-content";
|
||||
import type { TCustomEventHandlers } from "@/hooks/use-realtime-page-events";
|
||||
import { useRealtimePageEvents } from "@/hooks/use-realtime-page-events";
|
||||
import { EditorAIMenu } from "@/plane-web/components/pages";
|
||||
import type { TExtendedEditorExtensionsConfig } from "@/hooks/pages";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { useEditorFlagging } from "@/hooks/use-editor-flagging";
|
||||
import type { TExtendedEditorExtensionsConfig } from "@/plane-web/hooks/pages";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { useEditorFlagging } from "@/plane-web/hooks/use-editor-flagging";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
// local imports
|
||||
|
||||
@@ -14,8 +14,8 @@ import { usePageFallback } from "@/hooks/use-page-fallback";
|
||||
// plane web import
|
||||
import type { PageUpdateHandler, TCustomEventHandlers } from "@/hooks/use-realtime-page-events";
|
||||
import { PageModals } from "@/plane-web/components/pages";
|
||||
import { usePagesPaneExtensions, useExtendedEditorProps } from "@/hooks/pages";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePagesPaneExtensions, useExtendedEditorProps } from "@/plane-web/hooks/pages";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
// local imports
|
||||
|
||||
@@ -16,7 +16,7 @@ import { usePageFilters } from "@/hooks/use-page-filters";
|
||||
import { useQueryParams } from "@/hooks/use-query-params";
|
||||
// plane web imports
|
||||
import type { TPageNavigationPaneTab } from "@/plane-web/components/pages/navigation-pane";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
// local imports
|
||||
|
||||
@@ -10,7 +10,7 @@ import { PageLockControl } from "@/plane-web/components/pages/header/lock-contro
|
||||
import { PageMoveControl } from "@/plane-web/components/pages/header/move-control";
|
||||
import { PageShareControl } from "@/plane-web/components/pages/header/share-control";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
// local imports
|
||||
|
||||
@@ -17,8 +17,8 @@ import { FiltersDropdown } from "@/components/issues/issue-layouts/filters";
|
||||
// hooks
|
||||
import { useMember } from "@/hooks/store/use-member";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePageStore } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageStore } from "@/plane-web/hooks/store";
|
||||
// local imports
|
||||
import { PageAppliedFiltersList } from "../list/applied-filters";
|
||||
import { PageFiltersSelection } from "../list/filters";
|
||||
|
||||
@@ -15,7 +15,7 @@ import { renderFormattedDate, getFileURL } from "@plane/utils";
|
||||
import { useMember } from "@/hooks/store/use-member";
|
||||
import { usePageOperations } from "@/hooks/use-page-operations";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
// local imports
|
||||
|
||||
@@ -16,8 +16,8 @@ import { BlockItemAction } from "@/components/pages/list/block-item-action";
|
||||
// hooks
|
||||
import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePage } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePage } from "@/plane-web/hooks/store";
|
||||
|
||||
type TPageListBlock = {
|
||||
pageId: string;
|
||||
|
||||
@@ -10,8 +10,8 @@ import type { TPageNavigationTabs } from "@plane/types";
|
||||
// components
|
||||
import { ListLayout } from "@/components/core/list";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePageStore } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageStore } from "@/plane-web/hooks/store";
|
||||
// local imports
|
||||
import { PageListBlock } from "./block";
|
||||
|
||||
|
||||
@@ -13,8 +13,8 @@ import { EModalPosition, EModalWidth, ModalCore } from "@plane/ui";
|
||||
// hooks
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
// plane web hooks
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePageStore } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageStore } from "@/plane-web/hooks/store";
|
||||
// local imports
|
||||
import { PageForm } from "./page-form";
|
||||
|
||||
|
||||
@@ -14,8 +14,8 @@ import { getPageName } from "@plane/utils";
|
||||
// constants
|
||||
// plane web hooks
|
||||
import { useAppRouter } from "@/hooks/use-app-router";
|
||||
import type { EPageStoreType } from "@/hooks/store";
|
||||
import { usePageStore } from "@/hooks/store";
|
||||
import type { EPageStoreType } from "@/plane-web/hooks/store";
|
||||
import { usePageStore } from "@/plane-web/hooks/store";
|
||||
// store
|
||||
import type { TPageInstance } from "@/store/pages/base-page";
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user