2026-01-27 08:24:22 +00:00
|
|
|
/**
|
|
|
|
|
* Copyright (c) 2023-present Plane Software, Inc. and contributors
|
|
|
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
|
* See the LICENSE file for details.
|
|
|
|
|
*/
|
|
|
|
|
|
2025-11-06 08:38:48 +00:00
|
|
|
// plane imports
|
|
|
|
|
import { isRouteErrorResponse } from "react-router";
|
refactor: migrate Banner to @makeplane/propel across web app (#9737)
* chore: remove unused banner components from web application
Deleted the following banner components as they are no longer needed:
- AuthBanner
- BulkOperationsUpgradeBanner
- ContentLimitBanner
- IntegrationAndImportExportBanner
This cleanup helps streamline the codebase and remove redundant files.
* refactor: update banner imports and usage across multiple components
Replaced instances of the old banner component from @plane/propel with the new one from @makeplane/propel/components in various files. Adjusted properties and structure for consistency, including changes to the ArchivedIssueDetailsPage, DevErrorComponent, AuthRoot, and ResetPasswordForm. This update enhances the UI consistency and aligns with the recent component migration.
* refactor: update icon imports in ArchivedIssueDetailsPage and DevErrorComponent
Replaced the old icon components with new ones from @makeplane/propel/icons in the ArchivedIssueDetailsPage and DevErrorComponent. This change enhances visual consistency across the application by standardizing the icon usage in banner notifications.
* fix: enhance accessibility for Upgrade to One link in IssueBulkOperationsRoot
Updated the anchor element for the "Upgrade to One" button to include an aria-label for improved accessibility. This change ensures that screen readers can properly announce the purpose of the link, enhancing the user experience for individuals relying on assistive technologies.
* feat(i18n): integrate translation support in multiple components
Added translation functionality to the ArchivedIssueDetailsPage, WorkspaceIntegrationsPage, and PageRoot components. Updated banner titles and headings to utilize localized strings, enhancing the user experience for non-English speakers. This change improves accessibility and consistency across the application by leveraging the i18n framework.
* feat(i18n): add page content limit banners and archive messages across multiple languages
Introduced new localized messages for the "page content limit" banner and updated archive notifications in various language files. This enhancement improves user experience by providing clear guidance when content limits are reached and when work items are archived, ensuring consistency and accessibility across the application.
* refactor: update password strength banner implementation in AuthPasswordForm
Replaced the custom banner implementation with the new Banner component from @makeplane/propel/components. This change simplifies the code and enhances consistency in the user interface by utilizing the standardized Banner component for displaying password strength messages during sign-up.
* refactor: replace AnchorButton with Button in IssueBulkOperationsRoot
Updated the IssueBulkOperationsRoot component to replace the AnchorButton with the new Button component from @makeplane/propel/components. This change enhances the UI consistency and aligns with the recent component migration, while also adding a stretch property for improved layout flexibility.
* fix: enhance accessibility of Banner component in AuthRoot and ResetPasswordForm
Added role="alert" to the Banner component in both AuthRoot and ResetPasswordForm to improve accessibility for users relying on assistive technologies. This change ensures that error messages are announced appropriately, enhancing the overall user experience.
2026-09-07 12:21:06 +00:00
|
|
|
import { Banner } from "@makeplane/propel/components/banner";
|
|
|
|
|
import { InfoFilled } from "@makeplane/propel/icons";
|
2025-11-06 08:38:48 +00:00
|
|
|
import { Button } from "@plane/propel/button";
|
|
|
|
|
import { Card, ECardVariant } from "@plane/propel/card";
|
|
|
|
|
|
|
|
|
|
interface ErrorActionsProps {
|
|
|
|
|
onGoHome: () => void;
|
|
|
|
|
onReload?: () => void;
|
|
|
|
|
}
|
|
|
|
|
|
2025-11-20 12:09:40 +00:00
|
|
|
function ErrorActions({ onGoHome, onReload }: ErrorActionsProps) {
|
|
|
|
|
return (
|
|
|
|
|
<div className="flex gap-3 pt-2">
|
2025-12-12 15:20:14 +00:00
|
|
|
<Button variant="primary" size="lg" onClick={onGoHome}>
|
2025-11-20 12:09:40 +00:00
|
|
|
Go to home
|
2025-11-06 08:38:48 +00:00
|
|
|
</Button>
|
2025-11-20 12:09:40 +00:00
|
|
|
{onReload && (
|
2025-12-12 15:20:14 +00:00
|
|
|
<Button variant="secondary" size="lg" onClick={onReload}>
|
2025-11-20 12:09:40 +00:00
|
|
|
Reload page
|
|
|
|
|
</Button>
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
2025-11-06 08:38:48 +00:00
|
|
|
|
|
|
|
|
interface DevErrorComponentProps {
|
|
|
|
|
error: unknown;
|
|
|
|
|
onGoHome: () => void;
|
|
|
|
|
onReload: () => void;
|
|
|
|
|
}
|
|
|
|
|
|
2025-11-20 12:09:40 +00:00
|
|
|
export function DevErrorComponent({ error, onGoHome, onReload }: DevErrorComponentProps) {
|
2025-11-06 08:38:48 +00:00
|
|
|
if (isRouteErrorResponse(error)) {
|
|
|
|
|
return (
|
2026-03-02 15:10:50 +00:00
|
|
|
<div className="flex min-h-screen items-start justify-center bg-surface-2 p-6 transition-none">
|
|
|
|
|
<div className="mt-12 w-full max-w-4xl space-y-4 transition-none">
|
refactor: migrate Banner to @makeplane/propel across web app (#9737)
* chore: remove unused banner components from web application
Deleted the following banner components as they are no longer needed:
- AuthBanner
- BulkOperationsUpgradeBanner
- ContentLimitBanner
- IntegrationAndImportExportBanner
This cleanup helps streamline the codebase and remove redundant files.
* refactor: update banner imports and usage across multiple components
Replaced instances of the old banner component from @plane/propel with the new one from @makeplane/propel/components in various files. Adjusted properties and structure for consistency, including changes to the ArchivedIssueDetailsPage, DevErrorComponent, AuthRoot, and ResetPasswordForm. This update enhances the UI consistency and aligns with the recent component migration.
* refactor: update icon imports in ArchivedIssueDetailsPage and DevErrorComponent
Replaced the old icon components with new ones from @makeplane/propel/icons in the ArchivedIssueDetailsPage and DevErrorComponent. This change enhances visual consistency across the application by standardizing the icon usage in banner notifications.
* fix: enhance accessibility for Upgrade to One link in IssueBulkOperationsRoot
Updated the anchor element for the "Upgrade to One" button to include an aria-label for improved accessibility. This change ensures that screen readers can properly announce the purpose of the link, enhancing the user experience for individuals relying on assistive technologies.
* feat(i18n): integrate translation support in multiple components
Added translation functionality to the ArchivedIssueDetailsPage, WorkspaceIntegrationsPage, and PageRoot components. Updated banner titles and headings to utilize localized strings, enhancing the user experience for non-English speakers. This change improves accessibility and consistency across the application by leveraging the i18n framework.
* feat(i18n): add page content limit banners and archive messages across multiple languages
Introduced new localized messages for the "page content limit" banner and updated archive notifications in various language files. This enhancement improves user experience by providing clear guidance when content limits are reached and when work items are archived, ensuring consistency and accessibility across the application.
* refactor: update password strength banner implementation in AuthPasswordForm
Replaced the custom banner implementation with the new Banner component from @makeplane/propel/components. This change simplifies the code and enhances consistency in the user interface by utilizing the standardized Banner component for displaying password strength messages during sign-up.
* refactor: replace AnchorButton with Button in IssueBulkOperationsRoot
Updated the IssueBulkOperationsRoot component to replace the AnchorButton with the new Button component from @makeplane/propel/components. This change enhances the UI consistency and aligns with the recent component migration, while also adding a stretch property for improved layout flexibility.
* fix: enhance accessibility of Banner component in AuthRoot and ResetPasswordForm
Added role="alert" to the Banner component in both AuthRoot and ResetPasswordForm to improve accessibility for users relying on assistive technologies. This change ensures that error messages are announced appropriately, enhancing the overall user experience.
2026-09-07 12:21:06 +00:00
|
|
|
<Banner placement="page" variant="danger" icon={<InfoFilled />} title="Route Error Response" />
|
2025-11-06 08:38:48 +00:00
|
|
|
|
|
|
|
|
<Card variant={ECardVariant.WITH_SHADOW} className="!p-6 transition-none">
|
|
|
|
|
<div className="space-y-4">
|
|
|
|
|
<div>
|
2026-03-02 15:10:50 +00:00
|
|
|
<h2 className="mb-2 text-20 font-semibold text-danger-primary">
|
2025-11-06 08:38:48 +00:00
|
|
|
{error.status} {error.statusText}
|
|
|
|
|
</h2>
|
2026-03-02 15:10:50 +00:00
|
|
|
<div className="bg-subtle-1 h-px w-full" />
|
2025-11-06 08:38:48 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="space-y-2">
|
2026-03-02 15:10:50 +00:00
|
|
|
<h3 className="text-13 font-medium tracking-wide text-tertiary uppercase">Error Data</h3>
|
|
|
|
|
<div className="rounded-md bg-layer-1 p-4">
|
|
|
|
|
<p className="font-code text-13 text-secondary">{error.data}</p>
|
2025-11-06 08:38:48 +00:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<ErrorActions onGoHome={onGoHome} onReload={onReload} />
|
|
|
|
|
</div>
|
|
|
|
|
</Card>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (error instanceof Error) {
|
|
|
|
|
return (
|
2026-03-02 15:10:50 +00:00
|
|
|
<div className="flex min-h-screen items-start justify-center bg-surface-2 p-6 transition-none">
|
|
|
|
|
<div className="mt-12 w-full max-w-4xl space-y-4 transition-none">
|
refactor: migrate Banner to @makeplane/propel across web app (#9737)
* chore: remove unused banner components from web application
Deleted the following banner components as they are no longer needed:
- AuthBanner
- BulkOperationsUpgradeBanner
- ContentLimitBanner
- IntegrationAndImportExportBanner
This cleanup helps streamline the codebase and remove redundant files.
* refactor: update banner imports and usage across multiple components
Replaced instances of the old banner component from @plane/propel with the new one from @makeplane/propel/components in various files. Adjusted properties and structure for consistency, including changes to the ArchivedIssueDetailsPage, DevErrorComponent, AuthRoot, and ResetPasswordForm. This update enhances the UI consistency and aligns with the recent component migration.
* refactor: update icon imports in ArchivedIssueDetailsPage and DevErrorComponent
Replaced the old icon components with new ones from @makeplane/propel/icons in the ArchivedIssueDetailsPage and DevErrorComponent. This change enhances visual consistency across the application by standardizing the icon usage in banner notifications.
* fix: enhance accessibility for Upgrade to One link in IssueBulkOperationsRoot
Updated the anchor element for the "Upgrade to One" button to include an aria-label for improved accessibility. This change ensures that screen readers can properly announce the purpose of the link, enhancing the user experience for individuals relying on assistive technologies.
* feat(i18n): integrate translation support in multiple components
Added translation functionality to the ArchivedIssueDetailsPage, WorkspaceIntegrationsPage, and PageRoot components. Updated banner titles and headings to utilize localized strings, enhancing the user experience for non-English speakers. This change improves accessibility and consistency across the application by leveraging the i18n framework.
* feat(i18n): add page content limit banners and archive messages across multiple languages
Introduced new localized messages for the "page content limit" banner and updated archive notifications in various language files. This enhancement improves user experience by providing clear guidance when content limits are reached and when work items are archived, ensuring consistency and accessibility across the application.
* refactor: update password strength banner implementation in AuthPasswordForm
Replaced the custom banner implementation with the new Banner component from @makeplane/propel/components. This change simplifies the code and enhances consistency in the user interface by utilizing the standardized Banner component for displaying password strength messages during sign-up.
* refactor: replace AnchorButton with Button in IssueBulkOperationsRoot
Updated the IssueBulkOperationsRoot component to replace the AnchorButton with the new Button component from @makeplane/propel/components. This change enhances the UI consistency and aligns with the recent component migration, while also adding a stretch property for improved layout flexibility.
* fix: enhance accessibility of Banner component in AuthRoot and ResetPasswordForm
Added role="alert" to the Banner component in both AuthRoot and ResetPasswordForm to improve accessibility for users relying on assistive technologies. This change ensures that error messages are announced appropriately, enhancing the overall user experience.
2026-09-07 12:21:06 +00:00
|
|
|
<Banner placement="page" variant="danger" icon={<InfoFilled />} title="Runtime Error" />
|
2025-11-06 08:38:48 +00:00
|
|
|
<Card variant={ECardVariant.WITH_SHADOW} className="!p-6 transition-none">
|
|
|
|
|
<div className="space-y-4">
|
|
|
|
|
<div>
|
2026-03-02 15:10:50 +00:00
|
|
|
<h2 className="mb-2 text-20 font-semibold text-danger-primary">Error</h2>
|
|
|
|
|
<div className="bg-subtle-1 h-px w-full" />
|
2025-11-06 08:38:48 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="space-y-2">
|
2026-03-02 15:10:50 +00:00
|
|
|
<h3 className="text-13 font-medium tracking-wide text-tertiary uppercase">Message</h3>
|
|
|
|
|
<div className="rounded-md bg-layer-1 p-4">
|
|
|
|
|
<p className="text-13 font-medium text-primary">{error.message}</p>
|
2025-11-06 08:38:48 +00:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
{error.stack && (
|
|
|
|
|
<div className="space-y-2">
|
2026-03-02 15:10:50 +00:00
|
|
|
<h3 className="text-13 font-medium tracking-wide text-tertiary uppercase">Stack Trace</h3>
|
|
|
|
|
<div className="max-h-96 overflow-auto rounded-md border border-subtle bg-layer-1">
|
|
|
|
|
<pre className="p-4 font-code text-11 break-words whitespace-pre-wrap text-secondary">
|
2025-11-06 08:38:48 +00:00
|
|
|
{error.stack}
|
|
|
|
|
</pre>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
|
|
|
|
|
<ErrorActions onGoHome={onGoHome} onReload={onReload} />
|
|
|
|
|
</div>
|
|
|
|
|
</Card>
|
|
|
|
|
|
2026-03-02 15:10:50 +00:00
|
|
|
<Card variant={ECardVariant.WITHOUT_SHADOW} className="bg-layer-1 !p-4 transition-none">
|
2025-11-06 08:38:48 +00:00
|
|
|
<div className="flex items-start gap-3">
|
refactor: migrate web icons to @makeplane/propel (#9731)
* refactor: migrate web icons to @makeplane/propel
Replace confirmed icon symbols across apps/web with their audited
@makeplane/propel/icons targets. Unresolved symbols and the State,
Priority and Brand icons stay on their existing imports.
Lucide size props become explicit width/height, including the two
relation icons and the inbox status icon that forward a size variable.
Two aliased imports resolve to targets the file already imported, so
the aliases are dropped rather than importing the same symbol twice.
Widen the member dropdown chain and the AI menu from LucideIcon to
ComponentType<SVGProps<SVGSVGElement>> so both Lucide and Propel icons
satisfy them; both only ever render the icon with a className.
CycleGroupIcon is deliberately not migrated: it dispatches a different
glyph and color per cycle status, which CyclesOutline cannot express.
apps/web already declared @makeplane/propel, so no dependency change
was needed.
* fix: address icon migration review on web
Restore the six user-facing strings the identifier rename overwrote.
The migration replaced every occurrence of a source symbol name,
including ones inside string literals and JSX text, so the GitHub
empty state read "StarOutline us on GitHub", the exporter column key,
header and button label became "DownloadOutline", the project card
action title became "SettingsOutline" and a tooltip became "PinOutline".
Drop 122 strokeWidth props and 10 text-2 classes. Propel glyphs paint
with fill="currentColor", so strokeWidth never changed weight, and
text-2 was a bad conversion of stroke-2, which is a stroke width rather
than a colour and has no meaning on a fill path.
Use StarFilled for the two favorited sidebar stars. Lucide's Star with
fill-yellow-500 was a solid star, and StarOutline is a ring path, so
filling it does not reproduce that shape.
2026-09-02 15:06:43 +00:00
|
|
|
<InfoFilled className="mt-0.5 size-5 flex-shrink-0 text-tertiary" />
|
2025-11-06 08:38:48 +00:00
|
|
|
<div className="space-y-1">
|
2025-12-12 15:20:14 +00:00
|
|
|
<p className="text-13 font-medium text-secondary">Development Mode</p>
|
|
|
|
|
<p className="text-11 text-tertiary">
|
2025-11-06 08:38:48 +00:00
|
|
|
This detailed error view is only visible in development. In production, users will see a friendly
|
|
|
|
|
error page.
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</Card>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (
|
2026-03-02 15:10:50 +00:00
|
|
|
<div className="flex min-h-screen items-start justify-center bg-surface-2 p-6 transition-none">
|
|
|
|
|
<div className="mt-12 w-full max-w-4xl space-y-4 transition-none">
|
refactor: migrate Banner to @makeplane/propel across web app (#9737)
* chore: remove unused banner components from web application
Deleted the following banner components as they are no longer needed:
- AuthBanner
- BulkOperationsUpgradeBanner
- ContentLimitBanner
- IntegrationAndImportExportBanner
This cleanup helps streamline the codebase and remove redundant files.
* refactor: update banner imports and usage across multiple components
Replaced instances of the old banner component from @plane/propel with the new one from @makeplane/propel/components in various files. Adjusted properties and structure for consistency, including changes to the ArchivedIssueDetailsPage, DevErrorComponent, AuthRoot, and ResetPasswordForm. This update enhances the UI consistency and aligns with the recent component migration.
* refactor: update icon imports in ArchivedIssueDetailsPage and DevErrorComponent
Replaced the old icon components with new ones from @makeplane/propel/icons in the ArchivedIssueDetailsPage and DevErrorComponent. This change enhances visual consistency across the application by standardizing the icon usage in banner notifications.
* fix: enhance accessibility for Upgrade to One link in IssueBulkOperationsRoot
Updated the anchor element for the "Upgrade to One" button to include an aria-label for improved accessibility. This change ensures that screen readers can properly announce the purpose of the link, enhancing the user experience for individuals relying on assistive technologies.
* feat(i18n): integrate translation support in multiple components
Added translation functionality to the ArchivedIssueDetailsPage, WorkspaceIntegrationsPage, and PageRoot components. Updated banner titles and headings to utilize localized strings, enhancing the user experience for non-English speakers. This change improves accessibility and consistency across the application by leveraging the i18n framework.
* feat(i18n): add page content limit banners and archive messages across multiple languages
Introduced new localized messages for the "page content limit" banner and updated archive notifications in various language files. This enhancement improves user experience by providing clear guidance when content limits are reached and when work items are archived, ensuring consistency and accessibility across the application.
* refactor: update password strength banner implementation in AuthPasswordForm
Replaced the custom banner implementation with the new Banner component from @makeplane/propel/components. This change simplifies the code and enhances consistency in the user interface by utilizing the standardized Banner component for displaying password strength messages during sign-up.
* refactor: replace AnchorButton with Button in IssueBulkOperationsRoot
Updated the IssueBulkOperationsRoot component to replace the AnchorButton with the new Button component from @makeplane/propel/components. This change enhances the UI consistency and aligns with the recent component migration, while also adding a stretch property for improved layout flexibility.
* fix: enhance accessibility of Banner component in AuthRoot and ResetPasswordForm
Added role="alert" to the Banner component in both AuthRoot and ResetPasswordForm to improve accessibility for users relying on assistive technologies. This change ensures that error messages are announced appropriately, enhancing the overall user experience.
2026-09-07 12:21:06 +00:00
|
|
|
<Banner placement="page" variant="danger" icon={<InfoFilled />} title="Unknown Error" />
|
2025-11-06 08:38:48 +00:00
|
|
|
|
|
|
|
|
<Card variant={ECardVariant.WITH_SHADOW} className="!p-6">
|
|
|
|
|
<div className="space-y-4">
|
|
|
|
|
<div>
|
2026-03-02 15:10:50 +00:00
|
|
|
<h2 className="mb-2 text-20 font-semibold text-primary">Unknown Error</h2>
|
|
|
|
|
<div className="bg-subtle-1 h-px w-full" />
|
2025-11-06 08:38:48 +00:00
|
|
|
</div>
|
|
|
|
|
|
2026-03-02 15:10:50 +00:00
|
|
|
<div className="rounded-md bg-layer-1 p-4">
|
2025-12-12 15:20:14 +00:00
|
|
|
<p className="text-13 text-secondary">
|
2025-11-06 08:38:48 +00:00
|
|
|
An unknown error occurred. Please try refreshing the page or contact support if the problem persists.
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<ErrorActions onGoHome={onGoHome} onReload={onReload} />
|
|
|
|
|
</div>
|
|
|
|
|
</Card>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
);
|
2025-11-20 12:09:40 +00:00
|
|
|
}
|