#1 PDF Application on GitHub that lets you edit PDFs on any device anywhere
TypeScript dockerhacktoberfestjavapdfpdf-converterpdf-editorpdf-manipulationpdf-mergerpdf-ocrpdf-toolspdf-web-appspdfmergerself-hosted
Render the app chrome through <Icon> (#7895)
EthanHealy0153e85105fa84
diff --git a/.github/workflows/PR-Auto-Deploy-V2.yml b/.github/workflows/PR-Auto-Deploy-V2.ymlindex b4bbd111e1..aa5e4ca03d 100644--- a/.github/workflows/PR-Auto-Deploy-V2.yml+++ b/.github/workflows/PR-Auto-Deploy-V2.yml@@ -409,7 +409,7 @@ jobs:VPS_USER: ${{ secrets.NEW_VPS_USERNAME }}run: |set -euo pipefail- # `prepare` generates the icon set stories import (not committed).+ # `prepare` runs the env, icon-registry and OG-metadata generators the stories rely on.task frontend:preparetask frontend:storybook:buildPR=${{ needs.check-pr.outputs.pr_number }}diff --git a/frontend/editor/scripts/generate-og-image.mjs b/frontend/editor/scripts/generate-og-image.mjsindex cf617bf7e8..e9e9d36f90 100644--- a/frontend/editor/scripts/generate-og-image.mjs+++ b/frontend/editor/scripts/generate-og-image.mjs@@ -2,23 +2,25 @@// public/og_images tool cards. Renders an HTML template with Puppeteer.//// Usage:-// node scripts/generate-og-image.mjs --missing # generate cards for every tool with no art-// node scripts/generate-og-image.mjs --name "Add Text" --desc "Add custom text anywhere" \+// npx tsx scripts/generate-og-image.mjs --missing # generate cards for every tool with no art+// npx tsx scripts/generate-og-image.mjs --name "Add Text" --desc "Add custom text anywhere" \// --icon text-fields --out public/og_images/add-text.png// # theme overrides, e.g. a different accent:-// node scripts/generate-og-image.mjs --name "Sign" --icon draw --bg-top "#1e3a5f" \+// npx tsx scripts/generate-og-image.mjs --name "Sign" --icon draw --bg-top "#1e3a5f" \// --bg-bottom "#3b6ea5" --rotate -3 --out /path/sign.png//-// --icon is a material-symbols name (https://fonts.google.com/icons) resolved via iconify,+// --icon is a registry icon name (a lucide icon, or one of src/core/icons/svg/stirling),// or a raw "<svg…>" string. Theme is fully customizable (see THEME / the CLI flags below).// After adding images, run `node scripts/generate-og-metadata.mjs` so they get picked up./* global document, getComputedStyle */ // used inside page.evaluate (browser context)import fs from "node:fs/promises";-import { readFileSync } from "node:fs";+import { existsSync, readFileSync } from "node:fs";import path from "node:path";import { fileURLToPath } from "node:url";+// oxlint-disable-next-line no-restricted-imports -- build script; no alias covers scripts/+import { STROKE_WIDTH } from "../src/core/icons/icons.config.ts";const HERE = path.dirname(fileURLToPath(import.meta.url));const ROOT = path.resolve(HERE, "..");@@ -67,19 +69,36 @@ export const THEME = {"https://fonts.googleapis.com/css2?family=Nunito:wght@600;700;900&display=swap",};-// ---- icon resolution (material-symbols via iconify) -------------------------async function resolveIcon(icon) {+// The same sources the registry generator bundles, so a card shows the glyph+// the tool actually uses in the app.+const ICON_DIRS = [+ path.join(ROOT, "../node_modules/lucide-static/icons"),+ path.join(ROOT, "src/core/icons/svg/stirling"),+];++function iconFile(name) {+ if (!name || !/^[a-z0-9]+(-[a-z0-9]+)*$/.test(name)) return null;+ for (const dir of ICON_DIRS) {+ const file = path.join(dir, `${name}.svg`);+ if (existsSync(file)) return file;+ }+ return null;+}++export async function resolveIcon(icon) {if (!icon) return "";if (icon.trim().startsWith("<svg")) return icon; // raw svg passed through- const { getIconData, iconToSVG } = await import("@iconify/utils");- const { default: set } = await import(- "@iconify-json/material-symbols/icons.json",- { with: { type: "json" } }- );- const data = getIconData(set, icon);- if (!data) throw new Error(`icon not found in material-symbols: "${icon}"`);- const { attributes, body } = iconToSVG(data);- return `<svg xmlns="http://www.w3.org/2000/svg" viewBox="${attributes.viewBox}" style="color:#fff">${body}</svg>`;+ const file = iconFile(icon);+ if (!file)+ throw new Error(+ `icon not found in the registry (lucide or src/core/icons/svg/stirling): "${icon}"`,+ );+ const raw = await fs.readFile(file, "utf8");+ const open = raw.indexOf("<svg");+ const body = raw.slice(raw.indexOf(">", open) + 1, raw.lastIndexOf("</svg>"));+ // Root attributes are replaced: the source files carry lucide's default+ // weight, and the card wants the app's stroke in white.+ return `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="#fff" stroke-width="${STROKE_WIDTH}" stroke-linecap="round" stroke-linejoin="round">${body}</svg>`;}// ---- html template ---------------------------------------------------------@@ -214,18 +233,18 @@ export async function closeBrowser() {}// ---- batch: generate cards for tools that currently have no bespoke art -----// material-symbols icon per tool (the white glyph shown in the card).+// Registry icon per tool (the white glyph shown in the card).const MISSING_TOOL_ICONS = {- addText: "title",- annotate: "draw",- timestampPdf: "schedule",- bookletImposition: "menu-book-outline",- pdfTextEditor: "edit-document-outline",- formFill: "ballot-outline",+ addText: "type",+ annotate: "pen-tool",+ timestampPdf: "clock",+ bookletImposition: "book-open",+ pdfTextEditor: "file-pen",+ formFill: "list-checks",devApi: "api",- devFolderScanning: "folder-open-outline",- devSsoGuide: "key-outline",- devAirgapped: "cloud-off-outline",+ devFolderScanning: "folder-open",+ devSsoGuide: "key",+ devAirgapped: "cloud-off",};const kebab = (id) => id.replace(/([A-Z])/g, "-$1").toLowerCase();@@ -267,14 +286,14 @@ export async function generateMissing(theme = THEME) {return results;}-// Each tool's app icon lives as `icon="<material-symbol>"` just before its+// Each tool's app icon lives as `<Icon name="…"` just before its// `name: t("home.<id>.title", …)`. Pair each title with the closest preceding icon.-function readRegistryIcons() {+export function readRegistryIcons() {const src = readFileSync(path.join(ROOT, "src/core/data/useTranslatedToolRegistry.tsx"),"utf8",);- const icons = [...src.matchAll(/icon="([^"]+)"/g)].map((m) => ({+ const icons = [...src.matchAll(/<Icon\s+name="([^"]+)"/g)].map((m) => ({pos: m.index,name: m[1],}));@@ -290,28 +309,8 @@ function readRegistryIcons() {return byId;}-async function iconExists(name) {- if (!name) return false;- try {- const { getIconData } = await import("@iconify/utils");- const { default: set } = await import(- "@iconify-json/material-symbols/icons.json",- { with: { type: "json" } }- );- return !!getIconData(set, name);- } catch {- return false;- }-}--// First candidate that resolves; also tries dropping a "-rounded" suffix.-async function firstResolvableIcon(candidates) {- for (const c of candidates) {- if (await iconExists(c)) return c;- const alt = c && c.replace(/-rounded$/, "");- if (alt && alt !== c && (await iconExists(alt))) return alt;- }- return "description-outline";+function firstResolvableIcon(candidates) {+ return candidates.find((c) => iconFile(c)) ?? "file-text";}const humanizeId = (id) =>@@ -331,10 +330,7 @@ export async function generateAll(theme = THEME) {);const results = [];for (const [id, basename] of Object.entries(ogMap)) {- const icon = await firstResolvableIcon([- regIcons[id],- MISSING_TOOL_ICONS[id],- ]);+ const icon = firstResolvableIcon([regIcons[id], MISSING_TOOL_ICONS[id]]);await renderOgCard({name: titles[id] || humanizeId(id),description: descs[id] || "",diff --git a/frontend/editor/src/assets/3rdPartyLicenses.json b/frontend/editor/src/assets/3rdPartyLicenses.jsonindex b2ec99d368..72760bab59 100644--- a/frontend/editor/src/assets/3rdPartyLicenses.json+++ b/frontend/editor/src/assets/3rdPartyLicenses.json@@ -196,6 +196,13 @@"moduleLicense": "MIT","moduleLicenseUrl": "https://opensource.org/licenses/MIT"},+ {+ "moduleName": "@iconify-json/material-symbols",+ "moduleUrl": "https://icon-sets.iconify.design/material-symbols/",+ "moduleVersion": "1.2.90",+ "moduleLicense": "Apache-2.0",+ "moduleLicenseUrl": "https://www.apache.org/licenses/LICENSE-2.0"+ },{"moduleName": "@mantine/core","moduleUrl": "https://github.com/mantinedev/mantine",@@ -227,14 +234,14 @@{"moduleName": "@mui/icons-material","moduleUrl": "https://github.com/mui/material-ui",- "moduleVersion": "9.3.1",+ "moduleVersion": "9.4.0","moduleLicense": "MIT","moduleLicenseUrl": "https://opensource.org/licenses/MIT"},{"moduleName": "@mui/material","moduleUrl": "https://github.com/mui/material-ui",- "moduleVersion": "9.3.1",+ "moduleVersion": "9.4.0","moduleLicense": "MIT","moduleLicenseUrl": "https://opensource.org/licenses/MIT"},@@ -283,7 +290,7 @@{"moduleName": "@tanstack/react-query","moduleUrl": "https://github.com/TanStack/query",- "moduleVersion": "5.101.4",+ "moduleVersion": "5.102.0","moduleLicense": "MIT","moduleLicenseUrl": "https://opensource.org/licenses/MIT"},@@ -399,6 +406,13 @@"moduleLicense": "MIT","moduleLicenseUrl": "https://opensource.org/licenses/MIT"},+ {+ "moduleName": "lucide-static",+ "moduleUrl": "https://github.com/lucide-icons/lucide",+ "moduleVersion": "1.41.0",+ "moduleLicense": "ISC",+ "moduleLicenseUrl": "https://opensource.org/licenses/ISC"+ },{"moduleName": "pdfjs-dist","moduleUrl": "https://github.com/mozilla/pdf.js",diff --git a/frontend/editor/src/core/components/AppLayout.stories.tsx b/frontend/editor/src/core/components/AppLayout.stories.tsxindex 69aceef9d7..4db2da9c72 100644--- a/frontend/editor/src/core/components/AppLayout.stories.tsx+++ b/frontend/editor/src/core/components/AppLayout.stories.tsx@@ -50,7 +50,7 @@ function BannerSetter() {useEffect(() => {setBanner(<AppBanner- icon="info-rounded"+ icon="info"title="Heads up"message="This workspace is running in offline mode."/>,diff --git a/frontend/editor/src/core/components/layout/Workbench.tsx b/frontend/editor/src/core/components/layout/Workbench.tsxindex 4350569999..69ee06d3c4 100644--- a/frontend/editor/src/core/components/layout/Workbench.tsx+++ b/frontend/editor/src/core/components/layout/Workbench.tsx@@ -1,6 +1,6 @@import { useState, useEffect, useRef, Suspense, lazy } from "react";import { useTranslation } from "react-i18next";-import KeyboardArrowDownIcon from "@mui/icons-material/KeyboardArrowDown";+import { Icon } from "@app/ui/Icon";import { Box, Loader, Center, Stack, Text } from "@mantine/core";import { Button } from "@app/ui/Button";import { useToolWorkflow } from "@app/contexts/ToolWorkflowContext";@@ -305,7 +305,7 @@ export default function Workbench() {aria-expanded={false}aria-label={t("workbenchBar.showToolbar", "Show toolbar")}title={t("workbenchBar.showToolbar", "Show toolbar")}- leftSection={<KeyboardArrowDownIcon sx={{ fontSize: "1rem" }} />}+ leftSection={<Icon name="chevron-down" size={"1rem"} />}/>)}</div>diff --git a/frontend/editor/src/core/components/notifications/NotificationItem.tsx b/frontend/editor/src/core/components/notifications/NotificationItem.tsxindex 62402f65ff..634252d220 100644--- a/frontend/editor/src/core/components/notifications/NotificationItem.tsx+++ b/frontend/editor/src/core/components/notifications/NotificationItem.tsx@@ -3,7 +3,7 @@ import type { TFunction } from "i18next";import { useTranslation } from "react-i18next";import { Menu, Tooltip } from "@mantine/core";import { ActionIcon, Button } from "@app/ui";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import {isResolvableHere,refreshNotificationsNow,@@ -217,7 +217,7 @@ export function NotificationItem({className="notification-bell__more"aria-label={`${t("notifications.action.more", "More options")}: ${title}`}>- <LocalIcon icon="more-horiz" width={14} height={14} />+ <Icon name="ellipsis" size={14} /></ActionIcon></Tooltip></Menu.Target>diff --git a/frontend/editor/src/core/components/shared/AllToolsNavButton.tsx b/frontend/editor/src/core/components/shared/AllToolsNavButton.tsxindex 40e6f5641b..2804963b7e 100644--- a/frontend/editor/src/core/components/shared/AllToolsNavButton.tsx+++ b/frontend/editor/src/core/components/shared/AllToolsNavButton.tsx@@ -1,6 +1,6 @@import React from "react";import { useTranslation } from "react-i18next";-import AppsIcon from "@mui/icons-material/AppsRounded";+import { Icon } from "@app/ui/Icon";import { useToolWorkflow } from "@app/contexts/ToolWorkflowContext";import {useNavigationState,@@ -65,7 +65,9 @@ const AllToolsNavButton: React.FC<AllToolsNavButtonProps> = ({return (<div className="mt-4 mb-2"><QuickAccessButton- icon={<AppsIcon sx={{ fontSize: isActive ? "1.875rem" : "1.5rem" }} />}+ icon={+ <Icon name="layout-grid" size={isActive ? "1.875rem" : "1.5rem"} />+ }label={t("quickAccess.allTools", "Tools")}isActive={isActive}onClick={handleNavClick}diff --git a/frontend/editor/src/core/components/shared/BulkShareModal.tsx b/frontend/editor/src/core/components/shared/BulkShareModal.tsxindex f68a154e89..9602d5daef 100644--- a/frontend/editor/src/core/components/shared/BulkShareModal.tsx+++ b/frontend/editor/src/core/components/shared/BulkShareModal.tsx@@ -10,8 +10,7 @@ import {Select,} from "@mantine/core";import { Button } from "@app/ui/Button";-import LinkIcon from "@mui/icons-material/Link";-import ContentCopyRoundedIcon from "@mui/icons-material/ContentCopyRounded";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";import apiClient from "@app/services/apiClient";@@ -245,9 +244,7 @@ const BulkShareModal: React.FC<BulkShareModalProps> = ({<Buttonvariant="tertiary"size="sm"- leftSection={- <ContentCopyRoundedIcon style={{ fontSize: 16 }} />- }+ leftSection={<Icon name="copy" size={16} />}onClick={handleCopyLink}>{t("storageShare.copy", "Copy")}@@ -301,7 +298,7 @@ const BulkShareModal: React.FC<BulkShareModalProps> = ({{t("cancel", "Cancel")}</Button><Button- leftSection={<LinkIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="link" size={18} />}onClick={handleGenerateLink}loading={isWorking}disabled={!shareLinksEnabled}diff --git a/frontend/editor/src/core/components/shared/BulkUploadToServerModal.tsx b/frontend/editor/src/core/components/shared/BulkUploadToServerModal.tsxindex df594c4eac..0688b4b5ef 100644--- a/frontend/editor/src/core/components/shared/BulkUploadToServerModal.tsx+++ b/frontend/editor/src/core/components/shared/BulkUploadToServerModal.tsx@@ -1,7 +1,7 @@import React, { useCallback, useEffect, useMemo, useState } from "react";import { Modal, Stack, Text, Group, Alert } from "@mantine/core";import { Button } from "@app/ui/Button";-import CloudUploadIcon from "@mui/icons-material/CloudUpload";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";import { alert } from "@app/components/toast";@@ -156,7 +156,7 @@ const BulkUploadToServerModal: React.FC<BulkUploadToServerModalProps> = ({{t("cancel", "Cancel")}</Button><Button- leftSection={<CloudUploadIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="cloud-upload" size={18} />}onClick={handleUpload}loading={isUploading}>diff --git a/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx b/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsxindex 4def62470d..71b3922930 100644--- a/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx+++ b/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx@@ -9,8 +9,7 @@ import {TextInput,} from "@mantine/core";import { useTranslation } from "react-i18next";-import UnfoldMoreIcon from "@mui/icons-material/UnfoldMore";-import SearchIcon from "@mui/icons-material/Search";+import { Icon } from "@app/ui/Icon";import { Z_INDEX_AUTOMATE_DROPDOWN } from "@app/styles/zIndex";export interface DropdownItem {@@ -161,9 +160,10 @@ const DropdownListWithFooter: React.FC<DropdownListWithFooterProps> = ({<Text size="sm" style={{ flex: 1 }}>{getDisplayText()}</Text>- <UnfoldMoreIcon+ <Icon+ name="chevrons-up-down"+ size={"1rem"}style={{- fontSize: "1rem",color:"light-dark(var(--mantine-color-gray-5), var(--mantine-color-dark-2))",}}@@ -197,7 +197,7 @@ const DropdownListWithFooter: React.FC<DropdownListWithFooterProps> = ({placeholder={t("dropdownList.searchPlaceholder", "Search...")}value={searchTerm}onChange={handleSearchChange}- leftSection={<SearchIcon style={{ fontSize: "1rem" }} />}+ leftSection={<Icon name="search" size={"1rem"} />}size="sm"style={{ width: "100%" }}/>diff --git a/frontend/editor/src/core/components/shared/EditableSecretField.tsx b/frontend/editor/src/core/components/shared/EditableSecretField.tsxindex a340b2e554..b28ea3a416 100644--- a/frontend/editor/src/core/components/shared/EditableSecretField.tsx+++ b/frontend/editor/src/core/components/shared/EditableSecretField.tsx@@ -3,8 +3,7 @@ import { PasswordInput, Group, Tooltip, TextInput } from "@mantine/core";import { useTranslation } from "react-i18next";import { ActionIcon } from "@app/ui/ActionIcon";import { InfoTooltip } from "@app/ui/InfoTooltip";-import LocalIcon from "@app/components/shared/LocalIcon";-+import { Icon } from "@app/ui/Icon";interface EditableSecretFieldProps {label?: string;description?: string;@@ -102,7 +101,7 @@ export default function EditableSecretField({"Edit secret value",)}>- <LocalIcon icon="edit" width="1rem" height="1rem" />+ <Icon name="pencil" size="1rem" /></ActionIcon></Tooltip></Group>diff --git a/frontend/editor/src/core/components/shared/HoverActionMenu.stories.tsx b/frontend/editor/src/core/components/shared/HoverActionMenu.stories.tsxindex dc391d0e9a..2e18486ed2 100644--- a/frontend/editor/src/core/components/shared/HoverActionMenu.stories.tsx+++ b/frontend/editor/src/core/components/shared/HoverActionMenu.stories.tsx@@ -2,26 +2,24 @@ import type { Meta, StoryObj } from "@storybook/react-vite";import HoverActionMenu, {type HoverAction,} from "@app/components/shared/HoverActionMenu";-import { iconMap } from "@app/components/tools/automate/iconMap";--const { EditIcon, DeleteIcon, DownloadIcon } = iconMap;+import { Icon } from "@app/ui/Icon";const actions: HoverAction[] = [{id: "edit",- icon: <EditIcon style={{ fontSize: 16 }} />,+ icon: <Icon name="pencil" size={16} />,label: "Edit",onClick: () => {},},{id: "download",- icon: <DownloadIcon style={{ fontSize: 16 }} />,+ icon: <Icon name="download" size={16} />,label: "Download",onClick: () => {},},{id: "delete",- icon: <DeleteIcon style={{ fontSize: 16 }} />,+ icon: <Icon name="trash" size={16} />,label: "Delete",onClick: () => {},color: "var(--text-error)",diff --git a/frontend/editor/src/core/components/shared/LanguageSelector.tsx b/frontend/editor/src/core/components/shared/LanguageSelector.tsxindex 1adb0fc0bb..e9810e6d06 100644--- a/frontend/editor/src/core/components/shared/LanguageSelector.tsx+++ b/frontend/editor/src/core/components/shared/LanguageSelector.tsx@@ -5,7 +5,7 @@ import { ActionIcon } from "@app/ui/ActionIcon";import { Tooltip } from "@app/components/shared/Tooltip";import { useTranslation } from "react-i18next";import { supportedLanguages, setUserLanguage } from "@app/i18n";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import styles from "@app/components/shared/LanguageSelector.module.css";import { Z_INDEX_CONFIG_MODAL } from "@app/styles/zIndex";@@ -257,7 +257,7 @@ const LanguageSelector: React.FC<LanguageSelectorProps> = ({title={!opened && tooltip ? tooltip : undefined}aria-label={tooltip ?? currentLanguage}>- <LocalIcon icon="language" width="1.5rem" height="1.5rem" />+ <Icon name="globe" size="1.5rem" /></ActionIcon>) : (<Button@@ -265,9 +265,7 @@ const LanguageSelector: React.FC<LanguageSelectorProps> = ({accent="neutral"size="sm"data-testid="language-selector-button"- leftSection={- <LocalIcon icon="language" width="1.5rem" height="1.5rem" />- }+ leftSection={<Icon name="globe" size="1.5rem" />}><span className={styles.languageText}>{currentLanguage}</span></Button>diff --git a/frontend/editor/src/core/components/shared/MobileTransferModal.tsx b/frontend/editor/src/core/components/shared/MobileTransferModal.tsxindex 08e55b98bf..bcaba698d2 100644--- a/frontend/editor/src/core/components/shared/MobileTransferModal.tsx+++ b/frontend/editor/src/core/components/shared/MobileTransferModal.tsx@@ -2,9 +2,7 @@ import { ReactNode } from "react";import { Modal, Stack, Text, Box, Alert } from "@mantine/core";import { QRCodeSVG } from "qrcode.react";import { useAppConfig } from "@app/contexts/AppConfigContext";-import InfoRoundedIcon from "@mui/icons-material/InfoRounded";-import ErrorRoundedIcon from "@mui/icons-material/ErrorRounded";-import WarningRoundedIcon from "@mui/icons-material/WarningRounded";+import { Icon } from "@app/ui/Icon";import { Z_INDEX_OVER_FILE_MANAGER_MODAL } from "@app/styles/zIndex";import { useMobileTransferSession } from "@app/hooks/useMobileTransferSession";@@ -88,7 +86,7 @@ export default function MobileTransferModal({><Stack gap="md"><Alert- icon={<InfoRoundedIcon style={{ fontSize: "1rem" }} />}+ icon={<Icon name="info" size={"1rem"} />}color="blue"variant="light">@@ -97,7 +95,7 @@ export default function MobileTransferModal({{showExpiryWarning && timeRemaining !== null && (<Alert- icon={<WarningRoundedIcon style={{ fontSize: "1rem" }} />}+ icon={<Icon name="triangle-alert" size={"1rem"} />}title={expiryWarningTitle}color="orange">@@ -109,7 +107,7 @@ export default function MobileTransferModal({{error && (<Alert- icon={<ErrorRoundedIcon style={{ fontSize: "1rem" }} />}+ icon={<Icon name="circle-alert" size={"1rem"} />}title={errorTitle}color="red">diff --git a/frontend/editor/src/core/components/shared/MobileUploadModal.tsx b/frontend/editor/src/core/components/shared/MobileUploadModal.tsxindex 64ff82cb9f..745d6638e8 100644--- a/frontend/editor/src/core/components/shared/MobileUploadModal.tsx+++ b/frontend/editor/src/core/components/shared/MobileUploadModal.tsx@@ -2,7 +2,7 @@ import { useCallback } from "react";import { Badge } from "@mantine/core";import { useTranslation } from "react-i18next";import { useAppConfig } from "@app/contexts/AppConfigContext";-import CheckRoundedIcon from "@mui/icons-material/CheckRounded";+import { Icon } from "@app/ui/Icon";import MobileTransferModal from "@app/components/shared/MobileTransferModal";import { convertImageToPdf, isImageFile } from "@app/utils/imageToPdfUtils";@@ -115,7 +115,7 @@ export default function MobileUploadModal({variant="filled"color="green"size="lg"- leftSection={<CheckRoundedIcon style={{ fontSize: "1rem" }} />}+ leftSection={<Icon name="check" size={"1rem"} />}>{t("mobileUpload.filesReceived", "{{count}} file(s) received", {count,diff --git a/frontend/editor/src/core/components/shared/RenameFileDialog.tsx b/frontend/editor/src/core/components/shared/RenameFileDialog.tsxindex 83e00f6ba3..cb364bc4af 100644--- a/frontend/editor/src/core/components/shared/RenameFileDialog.tsx+++ b/frontend/editor/src/core/components/shared/RenameFileDialog.tsx@@ -1,8 +1,7 @@import { useEffect, useState } from "react";import { useTranslation } from "react-i18next";import { Alert, Group, Modal, Stack, TextInput } from "@mantine/core";-import ErrorOutlineIcon from "@mui/icons-material/ErrorOutlined";-+import { Icon } from "@app/ui/Icon";import { Button } from "@app/ui/Button";import { splitFileName } from "@app/utils/fileUtils";@@ -115,7 +114,7 @@ export function RenameFileDialog({{error && (<Alertcolor="red"- icon={<ErrorOutlineIcon fontSize="small" />}+ icon={<Icon name="circle-alert" size={20} />}variant="light"role="alert">diff --git a/frontend/editor/src/core/components/shared/ShareFileModal.tsx b/frontend/editor/src/core/components/shared/ShareFileModal.tsxindex 009345c274..4bbd134d75 100644--- a/frontend/editor/src/core/components/shared/ShareFileModal.tsx+++ b/frontend/editor/src/core/components/shared/ShareFileModal.tsx@@ -10,8 +10,7 @@ import {Select,} from "@mantine/core";import { Button } from "@app/ui/Button";-import LinkIcon from "@mui/icons-material/Link";-import ContentCopyRoundedIcon from "@mui/icons-material/ContentCopyRounded";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";import apiClient from "@app/services/apiClient";@@ -255,9 +254,7 @@ const ShareFileModal: React.FC<ShareFileModalProps> = ({<Buttonvariant="tertiary"size="sm"- leftSection={- <ContentCopyRoundedIcon style={{ fontSize: 16 }} />- }+ leftSection={<Icon name="copy" size={16} />}onClick={handleCopyLink}>{t("storageShare.copy", "Copy")}@@ -311,7 +308,7 @@ const ShareFileModal: React.FC<ShareFileModalProps> = ({{t("cancel", "Cancel")}</Button><Button- leftSection={<LinkIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="link" size={18} />}onClick={handleGenerateLink}loading={isWorking}disabled={!shareLinksEnabled}diff --git a/frontend/editor/src/core/components/shared/ShareManagementModal.tsx b/frontend/editor/src/core/components/shared/ShareManagementModal.tsxindex 64760da8d7..2a46dfff95 100644--- a/frontend/editor/src/core/components/shared/ShareManagementModal.tsx+++ b/frontend/editor/src/core/components/shared/ShareManagementModal.tsx@@ -13,11 +13,7 @@ import {Select,} from "@mantine/core";import { Button } from "@app/ui/Button";-import ContentCopyRoundedIcon from "@mui/icons-material/ContentCopyRounded";-import DeleteIcon from "@mui/icons-material/Delete";-import HistoryIcon from "@mui/icons-material/History";-import LinkIcon from "@mui/icons-material/Link";-import ShareIcon from "@mui/icons-material/Share";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";import apiClient from "@app/services/apiClient";@@ -484,7 +480,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({centeredtitle={<Group gap="xs" wrap="nowrap">- <ShareIcon style={{ fontSize: 20 }} />+ <Icon name="share-2" size={20} /><Text fw={600} size="lg">{t("storageShare.manageTitle", "Manage Sharing")}</Text>@@ -583,7 +579,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({)}<Group justify="flex-end" gap="sm"><Button- leftSection={<LinkIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="link" size={18} />}onClick={() => createShareLink()}loading={isLoading}>@@ -753,9 +749,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({variant="secondary"accent="danger"size="sm"- leftSection={- <DeleteIcon style={{ fontSize: 16 }} />- }+ leftSection={<Icon name="trash" size={16} />}onClick={() =>setConfirmRemoveUser(user.username)}@@ -814,11 +808,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({<Buttonvariant="tertiary"size="sm"- leftSection={- <ContentCopyRoundedIcon- style={{ fontSize: 16 }}- />- }+ leftSection={<Icon name="copy" size={16} />}onClick={() => handleCopyLink(link.token)}>{t("storageShare.copy", "Copy")}@@ -876,7 +866,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({variant={isSelected ? "secondary" : "primary"}size="sm"leftSection={- <HistoryIcon style={{ fontSize: 16 }} />+ <Icon name="rotate-ccw-clock" size={16} />}onClick={() =>setSelectedActivityToken((prev) =>@@ -919,9 +909,7 @@ const ShareManagementModal: React.FC<ShareManagementModalProps> = ({variant="secondary"accent="danger"size="sm"- leftSection={- <DeleteIcon style={{ fontSize: 16 }} />- }+ leftSection={<Icon name="trash" size={16} />}onClick={() =>setConfirmRevokeToken(link.token)}diff --git a/frontend/editor/src/core/components/shared/TextInput.tsx b/frontend/editor/src/core/components/shared/TextInput.tsxindex 41a4223a4c..1acbbe8852 100644--- a/frontend/editor/src/core/components/shared/TextInput.tsx+++ b/frontend/editor/src/core/components/shared/TextInput.tsx@@ -1,7 +1,7 @@import React, { forwardRef } from "react";import { useTranslation } from "react-i18next";import { ActionIcon } from "@app/ui/ActionIcon";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import styles from "@app/components/shared/textInput/TextInput.module.css";/**@@ -133,11 +133,7 @@ export const TextInput = forwardRef<HTMLInputElement, TextInputProps>(onClick={handleClear}aria-label={t("textInput.clear", "Clear input")}>- <LocalIcon- icon="close-rounded"- width="0.875rem"- height="0.875rem"- />+ <Icon name="x" size="0.875rem" /></ActionIcon>)}</div>diff --git a/frontend/editor/src/core/components/shared/ToolPanelHeader.stories.tsx b/frontend/editor/src/core/components/shared/ToolPanelHeader.stories.tsxindex bfcaedba4f..65a9a87dff 100644--- a/frontend/editor/src/core/components/shared/ToolPanelHeader.stories.tsx+++ b/frontend/editor/src/core/components/shared/ToolPanelHeader.stories.tsx@@ -1,5 +1,5 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import SettingsIcon from "@mui/icons-material/Settings";+import { Icon } from "@app/ui/Icon";import { ToolPanelHeader } from "@app/components/shared/ToolPanelHeader";const meta: Meta<typeof ToolPanelHeader> = {@@ -12,7 +12,7 @@ type Story = StoryObj<typeof meta>;export const Default: Story = {args: {- icon: <SettingsIcon sx={{ fontSize: 18 }} />,+ icon: <Icon name="settings" size={18} />,title: "Split",},};@@ -20,7 +20,7 @@ export const Default: Story = {/** Trailing close button only renders when `onClose` is supplied. */export const WithCloseButton: Story = {args: {- icon: <SettingsIcon sx={{ fontSize: 18 }} />,+ icon: <Icon name="settings" size={18} />,title: "Split",onClose: () => {},closeLabel: "Close tool panel",diff --git a/frontend/editor/src/core/components/shared/ToolPanelHeader.tsx b/frontend/editor/src/core/components/shared/ToolPanelHeader.tsxindex 9d5f921bec..554e9bef9d 100644--- a/frontend/editor/src/core/components/shared/ToolPanelHeader.tsx+++ b/frontend/editor/src/core/components/shared/ToolPanelHeader.tsx@@ -1,6 +1,6 @@import type { ReactNode } from "react";import { ActionIcon } from "@app/ui/ActionIcon";-import CloseIcon from "@mui/icons-material/Close";+import { Icon } from "@app/ui/Icon";import "@app/components/shared/ToolPanelHeader.css";export interface ToolPanelHeaderProps {@@ -45,7 +45,7 @@ export function ToolPanelHeader({onClick={onClose}aria-label={closeLabel ?? ""}>- <CloseIcon sx={{ fontSize: 18 }} />+ <Icon name="x" size={18} /></ActionIcon>)}</div>diff --git a/frontend/editor/src/core/components/shared/Tooltip.tsx b/frontend/editor/src/core/components/shared/Tooltip.tsxindex b8128bf637..d8829556eb 100644--- a/frontend/editor/src/core/components/shared/Tooltip.tsx+++ b/frontend/editor/src/core/components/shared/Tooltip.tsx@@ -8,7 +8,7 @@ import React, {import { createPortal } from "react-dom";import { useTranslation } from "react-i18next";import { ActionIcon } from "@app/ui/ActionIcon";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import { addEventListenerWithCleanup } from "@app/utils/genericUtils";import { useTooltipPosition } from "@app/hooks/useTooltipPosition";import { TooltipTip } from "@app/types/tips";@@ -448,7 +448,7 @@ export const Tooltip: React.FC<TooltipProps> = ({title={t("tooltip.close", "Close tooltip")}aria-label={t("tooltip.close", "Close tooltip")}>- <LocalIcon icon="close-rounded" width="1.25rem" height="1.25rem" />+ <Icon name="x" size="1.25rem" /></ActionIcon>)}{arrow && !sidebarTooltip && (diff --git a/frontend/editor/src/core/components/shared/TopControls.tsx b/frontend/editor/src/core/components/shared/TopControls.tsxindex de0b4766d4..a93a3a34f4 100644--- a/frontend/editor/src/core/components/shared/TopControls.tsx+++ b/frontend/editor/src/core/components/shared/TopControls.tsx@@ -1,10 +1,7 @@import React, { useState, useCallback, useMemo } from "react";import { Loader } from "@mantine/core";import { SegmentedControl } from "@app/ui/SegmentedControl";-import InsertDriveFileIcon from "@mui/icons-material/InsertDriveFile";-import GridViewIcon from "@mui/icons-material/GridView";-import FolderIcon from "@mui/icons-material/Folder";-import PictureAsPdfIcon from "@mui/icons-material/PictureAsPdf";+import { Icon } from "@app/ui/Icon";import { WorkbenchType, isValidWorkbench } from "@app/types/workbench";import { PageEditorFileDropdown } from "@app/components/shared/PageEditorFileDropdown";import type { CustomWorkbenchViewInstance } from "@app/contexts/ToolWorkflowContext";@@ -55,11 +52,7 @@ const createViewOptions = (/>) : (<div style={viewOptionStyle}>- {switchingTo === "viewer" ? (- <Loader size="sm" />- ) : (- <InsertDriveFileIcon fontSize="medium" />- )}+ {switchingTo === "viewer" ? <Loader size="sm" /> : <Icon name="file" />}</div>),value: "viewer",@@ -87,7 +80,7 @@ const createViewOptions = ({switchingTo === "pageEditor" ? (<Loader size="sm" />) : (- <GridViewIcon fontSize="medium" />+ <Icon name="layout-grid" />)}</div>),@@ -100,7 +93,7 @@ const createViewOptions = ({switchingTo === "fileEditor" ? (<Loader size="sm" />) : (- <FolderIcon fontSize="medium" />+ <Icon name="folder" />)}</div>),@@ -117,7 +110,7 @@ const createViewOptions = ({switchingTo === view.workbenchId ? (<Loader size="sm" />) : (- view.icon || <PictureAsPdfIcon fontSize="medium" />+ view.icon || <Icon name="file-pdf" />)}<span>{view.label}</span></div>diff --git a/frontend/editor/src/core/components/shared/UnsavedChangesDialog.tsx b/frontend/editor/src/core/components/shared/UnsavedChangesDialog.tsxindex 9ed8c270dc..dea864db69 100644--- a/frontend/editor/src/core/components/shared/UnsavedChangesDialog.tsx+++ b/frontend/editor/src/core/components/shared/UnsavedChangesDialog.tsx@@ -4,8 +4,7 @@*/import { Modal, Text, Group, Stack, rem } from "@mantine/core";import { useTranslation } from "react-i18next";-import WarningAmberRoundedIcon from "@mui/icons-material/WarningAmberRounded";-+import { Icon } from "@app/ui/Icon";import { Button } from "@app/ui/Button";import { IconBadge } from "@app/ui/IconBadge";import { Z_INDEX_TOAST } from "@app/styles/zIndex";@@ -49,7 +48,7 @@ export function UnsavedChangesDialog({<Modal.Title className="sr-only">{heading}</Modal.Title><Stack align="center" gap="md"><IconBadge accent="amber" size="md">- <WarningAmberRoundedIcon style={{ fontSize: 22 }} />+ <Icon name="triangle-alert" size={22} /></IconBadge><Stack gap={4} ta="center">diff --git a/frontend/editor/src/core/components/shared/UploadToServerModal.tsx b/frontend/editor/src/core/components/shared/UploadToServerModal.tsxindex 55c4b61c4f..fa6ca017db 100644--- a/frontend/editor/src/core/components/shared/UploadToServerModal.tsx+++ b/frontend/editor/src/core/components/shared/UploadToServerModal.tsx@@ -1,7 +1,7 @@import React, { useCallback, useEffect, useState } from "react";import { Modal, Stack, Text, Group, Alert } from "@mantine/core";import { Button } from "@app/ui/Button";-import CloudUploadIcon from "@mui/icons-material/CloudUpload";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";import { alert } from "@app/components/toast";@@ -125,7 +125,7 @@ const UploadToServerModal: React.FC<UploadToServerModalProps> = ({{t("cancel", "Cancel")}</Button><Button- leftSection={<CloudUploadIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="cloud-upload" size={18} />}onClick={handleUpload}loading={isUploading}>diff --git a/frontend/editor/src/core/components/shared/ViewerInlineControls.tsx b/frontend/editor/src/core/components/shared/ViewerInlineControls.tsxindex bdaf4c6ade..29eb4d1419 100644--- a/frontend/editor/src/core/components/shared/ViewerInlineControls.tsx+++ b/frontend/editor/src/core/components/shared/ViewerInlineControls.tsx@@ -4,9 +4,7 @@ import { ActionIcon } from "@app/ui/ActionIcon";import { useTranslation } from "react-i18next";import { useViewer } from "@app/contexts/ViewerContext";import { useNavigationState } from "@app/contexts/NavigationContext";-import ZoomInIcon from "@mui/icons-material/ZoomIn";-import ZoomOutIcon from "@mui/icons-material/ZoomOut";-+import { Icon } from "@app/ui/Icon";/*** Compact zoom controls rendered inline in the WorkbenchBar when the current workbench is "viewer".*/@@ -43,7 +41,7 @@ export function ViewerInlineControls() {onClick={() => viewer.zoomActions.zoomOut()}aria-label={t("viewer.zoomOut", "Zoom out")}>- <ZoomOutIcon sx={{ fontSize: "1rem" }} />+ <Icon name="zoom-out" size={"1rem"} /></ActionIcon><div className="viewer-inline-controls__slider-wrap">@@ -71,7 +69,7 @@ export function ViewerInlineControls() {onClick={() => viewer.zoomActions.zoomIn()}aria-label={t("viewer.zoomIn", "Zoom in")}>- <ZoomInIcon sx={{ fontSize: "1rem" }} />+ <Icon name="zoom-in" size={"1rem"} /></ActionIcon><span className="viewer-inline-controls__zoom-pct">diff --git a/frontend/editor/src/core/components/shared/ZipWarningModal.tsx b/frontend/editor/src/core/components/shared/ZipWarningModal.tsxindex 3a5c993ba5..da86846049 100644--- a/frontend/editor/src/core/components/shared/ZipWarningModal.tsx+++ b/frontend/editor/src/core/components/shared/ZipWarningModal.tsx@@ -1,9 +1,7 @@import { Modal, Text, Group, Stack } from "@mantine/core";import { Button } from "@app/ui/Button";import { useTranslation } from "react-i18next";-import WarningAmberIcon from "@mui/icons-material/WarningAmber";-import CheckCircleOutlineIcon from "@mui/icons-material/CheckCircleOutlined";-import CancelIcon from "@mui/icons-material/Cancel";+import { Icon } from "@app/ui/Icon";import { CSSProperties } from "react";interface ZipWarningModalProps {@@ -14,8 +12,9 @@ interface ZipWarningModalProps {zipFileName: string;}+const WARNING_ICON_SIZE = 36;+const WARNING_ICON_STYLE: CSSProperties = {- fontSize: 36,display: "block",margin: "0 auto 8px",color: "var(--c-accent-text)",@@ -41,7 +40,11 @@ const ZipWarningModal = ({closeOnEscape={true}><Stack ta="center" p="md" gap="sm">- <WarningAmberIcon style={WARNING_ICON_STYLE} />+ <Icon+ name="triangle-alert"+ size={WARNING_ICON_SIZE}+ style={WARNING_ICON_STYLE}+ /><Text size="md" fw={300}>{zipFileName}</Text>@@ -59,7 +62,7 @@ const ZipWarningModal = ({variant="secondary"accent="neutral"onClick={onCancel}- leftSection={<CancelIcon fontSize="small" />}+ leftSection={<Icon name="circle-x" size={20} />}style={{width: "10rem",}}@@ -68,7 +71,7 @@ const ZipWarningModal = ({</Button><ButtononClick={onConfirm}- leftSection={<CheckCircleOutlineIcon fontSize="small" />}+ leftSection={<Icon name="circle-check" size={20} />}style={{width: "10rem",}}@@ -83,7 +86,7 @@ const ZipWarningModal = ({variant="secondary"accent="neutral"onClick={onCancel}- leftSection={<CancelIcon fontSize="small" />}+ leftSection={<Icon name="circle-x" size={20} />}style={{width: "10rem",}}@@ -92,7 +95,7 @@ const ZipWarningModal = ({</Button><ButtononClick={onConfirm}- leftSection={<CheckCircleOutlineIcon fontSize="small" />}+ leftSection={<Icon name="circle-check" size={20} />}style={{width: "10rem",}}diff --git a/frontend/editor/src/core/components/shared/quickAccessBar/QuickAccessButton.stories.tsx b/frontend/editor/src/core/components/shared/quickAccessBar/QuickAccessButton.stories.tsxindex cc984b007f..3ca3d728a4 100644--- a/frontend/editor/src/core/components/shared/quickAccessBar/QuickAccessButton.stories.tsx+++ b/frontend/editor/src/core/components/shared/quickAccessBar/QuickAccessButton.stories.tsx@@ -1,5 +1,5 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import HomeIcon from "@mui/icons-material/HomeRounded";+import { Icon } from "@app/ui/Icon";import QuickAccessButton from "@app/components/shared/quickAccessBar/QuickAccessButton";const meta = {@@ -19,7 +19,7 @@ type Story = StoryObj<typeof meta>;export const Default: Story = {args: {- icon: <HomeIcon sx={{ fontSize: "1.5rem" }} />,+ icon: <Icon name="house" size={"1.5rem"} />,label: "Home",isActive: false,ariaLabel: "Home",@@ -28,7 +28,7 @@ export const Default: Story = {export const Active: Story = {args: {- icon: <HomeIcon sx={{ fontSize: "1.875rem" }} />,+ icon: <Icon name="house" size={"1.875rem"} />,label: "Home",isActive: true,ariaLabel: "Home",@@ -37,7 +37,7 @@ export const Active: Story = {export const Disabled: Story = {args: {- icon: <HomeIcon sx={{ fontSize: "1.5rem" }} />,+ icon: <Icon name="house" size={"1.5rem"} />,label: "Home",isActive: false,ariaLabel: "Home",diff --git a/frontend/editor/src/core/components/shared/quickNav/QuickNavRail.css b/frontend/editor/src/core/components/shared/quickNav/QuickNavRail.cssindex 8ef18e7ec8..f49552d667 100644--- a/frontend/editor/src/core/components/shared/quickNav/QuickNavRail.css+++ b/frontend/editor/src/core/components/shared/quickNav/QuickNavRail.css@@ -41,7 +41,6 @@width: 1.125rem;height: 1.125rem;color: inherit;- fill: currentColor;}/* Taller than wide (71x79), so height drives the width. */diff --git a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailContainer.tsx b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailContainer.tsxindex bcbd12b0e1..eba63d876d 100644--- a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailContainer.tsx+++ b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailContainer.tsx@@ -1,6 +1,6 @@import { useTranslation } from "react-i18next";import { NavSurface } from "@app/ui/NavSurface";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import { QuickNavBrand } from "@app/components/shared/quickNav/QuickNavBrand";import type { QuickNavIdentity } from "@app/contexts/QuickNavHostContext";import {@@ -66,34 +66,16 @@ export function QuickNavRailContainer({{onInvite && (<RailButtonlabel={t("quickNav.invite", "Invite")}- icon={- <LocalIcon- icon="person-add-outline-rounded"- width="1.125rem"- height="1.125rem"- />- }+ icon={<Icon name="user-plus" size="1.125rem" />}onClick={onInvite}/>)}{onOpenDocs && (<RailButtonlabel={t("quickNav.docs", "Documentation")}- icon={- docsActive ? (- <LocalIcon- icon="help-rounded"- width="1.125rem"- height="1.125rem"- />- ) : (- <LocalIcon- icon="help-outline-rounded"- width="1.125rem"- height="1.125rem"- />- )- }+ // No `filled`: the mark is a ring around a stroked glyph, so a+ // fill swallows the question mark and leaves a blank disc.+ icon={<Icon name="circle-question-mark" size="1.125rem" />}current={docsActive}testId="docs-button"onClick={onOpenDocs}diff --git a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailHost.tsx b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailHost.tsxindex c62e8ddb08..ffc49827fb 100644--- a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailHost.tsx+++ b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailHost.tsx@@ -1,6 +1,5 @@import { useTranslation } from "react-i18next";import { useLocation, useNavigate } from "react-router-dom";-import LocalIcon from "@app/components/shared/LocalIcon";import { QuickNavRailContainer } from "@app/components/shared/quickNav/QuickNavRailContainer";import type { QuickNavEntry } from "@app/components/shared/quickNav/QuickNavRailBase";import type { ToolId } from "@app/types/toolId";@@ -17,6 +16,7 @@ import { DOCS_PATH, HAS_DOCS } from "@app/routes/docsRoute";import { stripBasePath } from "@app/constants/app";import { rememberSettingsOrigin } from "@app/utils/settingsNavigation";+import { Icon } from "@app/ui/Icon";const SIZE = "1.125rem";/** Entries come from the URL, not either app's context, so the rail survives a switch. */@@ -75,9 +75,7 @@ export function QuickNavRailHost() {const reader: QuickNavEntry = {id: "reader",label: t("quickNav.reader", "Reader"),- icon: (- <LocalIcon icon="menu-book-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="book-open" size={SIZE} />,pressed: Boolean(host?.readerMode),// From the processor there is no editor to toggle - see pendingReaderMode.onClick: () => {@@ -94,11 +92,7 @@ export function QuickNavRailHost() {const editor: QuickNavEntry = {id: "editor",label: t("quickNav.editor", "Editor"),- icon: inEditor ? (- <LocalIcon icon="edit-rounded" width={SIZE} height={SIZE} />- ) : (- <LocalIcon icon="edit-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="pencil" size={SIZE} filled={inEditor} />,// The library is a place of its own, not the editor with a different centre.current: inEditor && !host?.fileLibrary,onClick: () => {@@ -114,12 +108,7 @@ export function QuickNavRailHost() {const processor: QuickNavEntry = {id: "processor",label: t("quickNav.processor", "Processor"),- // Two literals, not a computed name: the offline icon bundle scans for `icon="..."`.- icon: inPortal ? (- <LocalIcon icon="memory-rounded" width={SIZE} height={SIZE} />- ) : (- <LocalIcon icon="memory-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="cpu" size={SIZE} filled={inPortal} />,current: inPortal,disabled: HAS_PORTAL && !inPortal && !host?.portalAccess,reason:@@ -145,9 +134,7 @@ export function QuickNavRailHost() {{id: "files",label: t("fileSidebar.myFiles", "File library"),- icon: (- <LocalIcon icon="folder-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="folder" size={SIZE} />,current: Boolean(host?.fileLibrary),// Through the app where possible: the library is a view, not a route. From the// processor there is no editor to ask, so the path carries it and HomePage seeds@@ -165,9 +152,7 @@ export function QuickNavRailHost() {{id: "automate",label: t("quickAccess.automate", "Automate"),- icon: (- <LocalIcon icon="rebase-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="git-branch" size={SIZE} />,...openingTool("automate"),...unusable("automate"),onClick: () => openTool("automate", "/automate"),@@ -175,9 +160,7 @@ export function QuickNavRailHost() {{id: "sharedSign",label: t("home.sharedSign.title", "Shared Signing"),- icon: (- <LocalIcon icon="draw-outline-rounded" width={SIZE} height={SIZE} />- ),+ icon: <Icon name="pen-tool" size={SIZE} />,badge: host?.signingBadge,badgeTone: "warning",...openingTool("sharedSign"),diff --git a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailNotifications.tsx b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailNotifications.tsxindex aee294de1c..350fc50a06 100644--- a/frontend/editor/src/core/components/shared/quickNav/QuickNavRailNotifications.tsx+++ b/frontend/editor/src/core/components/shared/quickNav/QuickNavRailNotifications.tsx@@ -1,5 +1,5 @@import { useTranslation } from "react-i18next";-import LocalIcon from "@app/components/shared/LocalIcon";+import { Icon } from "@app/ui/Icon";import { RailButton } from "@app/components/shared/quickNav/QuickNavRailBase";import { useNotifications } from "@app/hooks/useNotifications";import { useNotificationsAvailable } from "@app/components/notifications/useNotificationsAvailable";@@ -34,13 +34,7 @@ function MountedRailNotifications({<span data-notifications-trigger><RailButtonlabel={t("quickNav.notifications", "Notifications")}- icon={- <LocalIcon- icon="notifications-outline-rounded"- width="1.125rem"- height="1.125rem"- />- }+ icon={<Icon name="bell" size="1.125rem" />}badge={unreadCount}expanded={Boolean(open)}controls={NOTIFICATIONS_PANEL_ID}diff --git a/frontend/editor/src/core/components/toast/Toast.README.md b/frontend/editor/src/core/components/toast/Toast.README.mdindex fe8d15485d..fa0efbbecd 100644--- a/frontend/editor/src/core/components/toast/Toast.README.md+++ b/frontend/editor/src/core/components/toast/Toast.README.md@@ -274,7 +274,7 @@ alert({alertType: 'neutral',title: 'New feature available',body: 'Check out the latest updates.',- icon: <LocalIcon icon="star" />+ icon: <Icon name="star" />});```diff --git a/frontend/editor/src/core/components/toast/ToastRenderer.tsx b/frontend/editor/src/core/components/toast/ToastRenderer.tsxindex df2a871a5a..8a289e7c76 100644--- a/frontend/editor/src/core/components/toast/ToastRenderer.tsx+++ b/frontend/editor/src/core/components/toast/ToastRenderer.tsx@@ -2,11 +2,11 @@ import type { CSSProperties } from "react";import { useTranslation } from "react-i18next";import { useToast } from "@app/components/toast/ToastContext";import { ToastInstance, ToastLocation } from "@app/components/toast/types";-import { LocalIcon } from "@app/components/shared/LocalIcon";import { ActionIcon } from "@app/ui/ActionIcon";import { Button } from "@app/ui/Button";import "@app/components/toast/ToastRenderer.css";+import { Icon, type IconName } from "@app/ui/Icon";const locationToClass: Record<ToastLocation, string> = {"top-left": "toast-container--top-left","top-right": "toast-container--top-right",@@ -27,14 +27,14 @@ function getActionButtonClass(t: ToastInstance): string {return `toast-action-button toast-action-button--${t.alertType}`;}-function getDefaultIconName(t: ToastInstance): string {+function getDefaultIconName(t: ToastInstance): IconName {switch (t.alertType) {case "success":- return "check-circle-rounded";+ return "circle-check";case "error":- return "cancel";+ return "circle-x";case "warning":- return "warning";+ return "triangle-alert";case "neutral":default:return "info";@@ -81,13 +81,7 @@ export default function ToastRenderer() {<div className="toast-header">{/* Icon */}<div className="toast-icon">- {t.icon ?? (- <LocalIcon- icon={getDefaultIconName(t)}- width={20}- height={20}- />- )}+ {t.icon ?? <Icon name={getDefaultIconName(t)} size={20} />}</div>{/* Title + count badge */}@@ -115,7 +109,7 @@ export default function ToastRenderer() {}}className={`toast-button toast-expand-button ${t.isExpanded ? "toast-expand-button--expanded" : ""}`}>- <LocalIcon icon="expand-more-rounded" />+ <Icon name="chevron-down" size="1em" /></ActionIcon>)}<ActionIcondiff --git a/frontend/editor/src/core/pages/HomePage.tsx b/frontend/editor/src/core/pages/HomePage.tsxindex 47fbe57cd2..3fbb8b45e4 100644--- a/frontend/editor/src/core/pages/HomePage.tsx+++ b/frontend/editor/src/core/pages/HomePage.tsx@@ -26,14 +26,11 @@ import {import { isApplyingRestoredView } from "@app/services/workbenchSession";import { useViewer } from "@app/contexts/ViewerContext";import { useLocation, useNavigate } from "react-router-dom";-import AppsIcon from "@mui/icons-material/AppsRounded";-import CreateNewFolderIcon from "@mui/icons-material/CreateNewFolder";-+import { Icon } from "@app/ui/Icon";import RightSidebar from "@app/components/tools/RightSidebar";import Workbench from "@app/components/layout/Workbench";import FileSidebar from "@app/components/shared/FileSidebar";import FileManager from "@app/components/FileManager";-import LocalIcon from "@app/components/shared/LocalIcon";import {getStartupNavigationAction,getDefaultWorkbenchForFileCount,@@ -61,8 +58,6 @@ import { NewFolderButton } from "@app/components/filesPage/NewFolderButton";import MobileUploadModal from "@app/components/shared/MobileUploadModal";import { useLibraryRefresh } from "@app/hooks/useLibraryRefresh";import { useAuth } from "@app/auth/UseSession";-import RefreshIcon from "@mui/icons-material/Refresh";-import QrCode2Icon from "@mui/icons-material/QrCode2";import { canPickDirectory } from "@app/services/directoryPicker";import { useFileHandler } from "@app/hooks/useFileHandler";import type { FileSidebarProps } from "@app/components/shared/FileSidebar";@@ -596,7 +591,7 @@ export default function HomePage() {}}}>- <AppsIcon sx={{ fontSize: "1.5rem" }} />+ <Icon name="layout-grid" size={"1.5rem"} /><span className="mobile-bottom-button-label">{t("quickAccess.allTools", "Tools")}</span>@@ -614,11 +609,7 @@ export default function HomePage() {}}}>- <LocalIcon- icon="automation-outline"- width="1.5rem"- height="1.5rem"- />+ <Icon name="workflow" size="1.5rem" /><span className="mobile-bottom-button-label">{t("quickAccess.automate", "Automate")}</span>@@ -630,11 +621,7 @@ export default function HomePage() {aria-label={t("home.mobile.openFiles", "Open files")}onClick={() => navigate("/files")}>- <LocalIcon- icon="folder-rounded"- width="1.5rem"- height="1.5rem"- />+ <Icon name="folder" size="1.5rem" /><span className="mobile-bottom-button-label">{t("quickAccess.files", "Files")}</span>@@ -645,11 +632,7 @@ export default function HomePage() {aria-label={t("quickAccess.config", "Config")}onClick={openSettings}>- <LocalIcon- icon="settings-rounded"- width="1.5rem"- height="1.5rem"- />+ <Icon name="settings" size="1.5rem" /><span className="mobile-bottom-button-label">{t("quickAccess.config", "Config")}</span>@@ -760,7 +743,7 @@ const MyFilesSidebarOverrides = forwardRef<HTMLDivElement, FileSidebarProps>(onPickGoogleDriveFiles={handleUpload}extraActions={[{- icon: <CreateNewFolderIcon />,+ icon: <Icon name="folder-plus" />,label: t("filesPage.newFolder", "New folder"),onClick: createFolderHere,disabled: newFolderDisabledReason !== null,@@ -786,7 +769,8 @@ const MyFilesSidebarOverrides = forwardRef<HTMLDivElement, FileSidebarProps>(},{icon: (- <RefreshIcon+ <Icon+ name="refresh-cw"className={refreshing ? "file-sidebar-spin" : undefined}/>),@@ -799,7 +783,7 @@ const MyFilesSidebarOverrides = forwardRef<HTMLDivElement, FileSidebarProps>(...(mobileUploadAvailable? [{- icon: <QrCode2Icon />,+ icon: <Icon name="qr-code" />,label: t("filesPage.uploadFromMobile","Upload from Mobile",diff --git a/frontend/editor/src/core/ui/ActionIcon.stories.tsx b/frontend/editor/src/core/ui/ActionIcon.stories.tsxindex 43130cb9d0..38a342a3e3 100644--- a/frontend/editor/src/core/ui/ActionIcon.stories.tsx+++ b/frontend/editor/src/core/ui/ActionIcon.stories.tsx@@ -1,27 +1,9 @@import type { Meta, StoryObj } from "@storybook/react-vite";+import { Icon } from "@app/ui/Icon";import { ActionIcon } from "@app/ui/ActionIcon";-const Plus = () => (- <svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="M12 5v14M5 12h14"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- />- </svg>-);-const Trash = () => (- <svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="M5 7h14M10 7V5h4v2m-8 0 1 13h6l1-13"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- strokeLinejoin="round"- />- </svg>-);+const Plus = () => <Icon name="plus" size="1em" />;+const Trash = () => <Icon name="trash" size="1em" />;const ACCENTS = ["default",diff --git a/frontend/editor/src/core/ui/Button.stories.tsx b/frontend/editor/src/core/ui/Button.stories.tsxindex 22e6c9464e..82bd5769cb 100644--- a/frontend/editor/src/core/ui/Button.stories.tsx+++ b/frontend/editor/src/core/ui/Button.stories.tsx@@ -1,40 +1,12 @@import type { ReactNode } from "react";+import { Icon } from "@app/ui/Icon";import type { Meta, StoryObj } from "@storybook/react-vite";import { Button } from "@app/ui/Button";-/* tiny inline icons for the demos */-const Plus = () => (- <svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="M12 5v14M5 12h14"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- />- </svg>-);-const Arrow = () => (- <svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="M5 12h14m0 0-5-5m5 5-5 5"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- strokeLinejoin="round"- />- </svg>-);-const Trash = () => (- <svg width="1em" height="1em" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="M5 7h14M10 7V5h4v2m-8 0 1 13h6l1-13"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- strokeLinejoin="round"- />- </svg>-);+/* icons for the demos */+const Plus = () => <Icon name="plus" size="1em" />;+const Arrow = () => <Icon name="arrow-right" size="1em" />;+const Trash = () => <Icon name="trash" size="1em" />;const Sparkle = () => (<svgwidth="1em"diff --git a/frontend/editor/src/core/ui/CardRail.stories.tsx b/frontend/editor/src/core/ui/CardRail.stories.tsxindex 79ce5597a7..cfc738ad1d 100644--- a/frontend/editor/src/core/ui/CardRail.stories.tsx+++ b/frontend/editor/src/core/ui/CardRail.stories.tsx@@ -1,41 +1,36 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import ShieldOutlinedIcon from "@mui/icons-material/ShieldOutlined";-import CategoryOutlinedIcon from "@mui/icons-material/CategoryOutlined";-import GavelOutlinedIcon from "@mui/icons-material/GavelOutlined";-import LayersOutlinedIcon from "@mui/icons-material/LayersOutlined";-import AltRouteOutlinedIcon from "@mui/icons-material/AltRouteOutlined";-import ScheduleOutlinedIcon from "@mui/icons-material/ScheduleOutlined";+import { Icon } from "@app/ui/Icon";import { CardRail } from "@app/ui/CardRail";import { OptionCard } from "@app/ui/OptionCard";const items = [{- icon: <ShieldOutlinedIcon />,+ icon: <Icon name="shield" />,title: "Security",desc: "Redact, sanitize, and watermark every document.",},{- icon: <CategoryOutlinedIcon />,+ icon: <Icon name="shapes" />,title: "Classification",desc: "Tag each document against your team's labels.",},{- icon: <GavelOutlinedIcon />,+ icon: <Icon name="gavel" />,title: "Compliance",desc: "Enforce frameworks and keep an audit trail.",},{- icon: <LayersOutlinedIcon />,+ icon: <Icon name="layers" />,title: "Ingestion",desc: "OCR and flatten documents as they arrive.",},{- icon: <AltRouteOutlinedIcon />,+ icon: <Icon name="git-fork" />,title: "Routing",desc: "Send finished documents where they belong.",},{- icon: <ScheduleOutlinedIcon />,+ icon: <Icon name="clock" />,title: "Retention",desc: "Archive and expire on your schedule.",},diff --git a/frontend/editor/src/core/ui/DataTable.tsx b/frontend/editor/src/core/ui/DataTable.tsxindex ccb5578016..84dba6ef41 100644--- a/frontend/editor/src/core/ui/DataTable.tsx+++ b/frontend/editor/src/core/ui/DataTable.tsx@@ -1,4 +1,5 @@import { type KeyboardEvent, type ReactNode, useMemo, useState } from "react";+import { Icon } from "@app/ui/Icon";import {type ColumnDef,createColumnHelper,@@ -109,20 +110,6 @@ export interface DataTableProps<T> {collapseLabels?: { showAll: (total: number) => string; showLess: string };}-function ChevronGlyph() {- return (- <svg width="16" height="16" viewBox="0 0 24 24" fill="none" aria-hidden>- <path- d="m9 6 6 6-6 6"- stroke="currentColor"- strokeWidth="2"- strokeLinecap="round"- strokeLinejoin="round"- />- </svg>- );-}-function SortGlyph() {return (<svg@@ -210,7 +197,7 @@ export function DataTable<T extends RowData>({renderCell: (row) =>(isRowInteractive?.(row) ?? true) ? (<span className="sui-datatable__chevron" aria-hidden>- <ChevronGlyph />+ <Icon name="chevron-right" size={16} /></span>) : null,},diff --git a/frontend/editor/src/core/ui/IconBadge.stories.tsx b/frontend/editor/src/core/ui/IconBadge.stories.tsxindex 538208f14a..d831cdc101 100644--- a/frontend/editor/src/core/ui/IconBadge.stories.tsx+++ b/frontend/editor/src/core/ui/IconBadge.stories.tsx@@ -1,14 +1,9 @@import type { Meta, StoryObj } from "@storybook/react-vite";+import { Icon } from "@app/ui/Icon";import { IconBadge } from "@app/ui/IconBadge";function Glyph() {- return (- <svg viewBox="0 0 24 24" width={16} height={16} fill="currentColor">- <rect x="3" y="4" width="18" height="4" rx="1" />- <rect x="3" y="10" width="18" height="4" rx="1" />- <rect x="3" y="16" width="18" height="4" rx="1" />- </svg>- );+ return <Icon name="star" size={16} />;}const meta: Meta<typeof IconBadge> = {diff --git a/frontend/editor/src/core/ui/IconPicker.stories.tsx b/frontend/editor/src/core/ui/IconPicker.stories.tsxindex 8fe0534867..4276579cc6 100644--- a/frontend/editor/src/core/ui/IconPicker.stories.tsx+++ b/frontend/editor/src/core/ui/IconPicker.stories.tsx@@ -1,32 +1,36 @@import { useState } from "react";+import { Icon } from "@app/ui/Icon";import type { Meta, StoryObj } from "@storybook/react-vite";-import ShieldOutlinedIcon from "@mui/icons-material/ShieldOutlined";-import LockOutlinedIcon from "@mui/icons-material/LockOutlined";-import LabelOutlinedIcon from "@mui/icons-material/LabelOutlined";-import LayersOutlinedIcon from "@mui/icons-material/LayersOutlined";-import FolderOutlinedIcon from "@mui/icons-material/FolderOutlined";-import BoltOutlinedIcon from "@mui/icons-material/BoltOutlined";-import ScheduleOutlinedIcon from "@mui/icons-material/ScheduleOutlined";-import AutoAwesomeOutlinedIcon from "@mui/icons-material/AutoAwesomeOutlined";import { IconPicker, type IconPickerOption } from "@app/ui/IconPicker";-const sx = { fontSize: "1.25rem" } as const;const OPTIONS: IconPickerOption[] = [- { key: "shield", label: "Shield", node: <ShieldOutlinedIcon sx={sx} /> },- { key: "lock", label: "Lock", node: <LockOutlinedIcon sx={sx} /> },- { key: "label", label: "Label", node: <LabelOutlinedIcon sx={sx} /> },- { key: "layers", label: "Layers", node: <LayersOutlinedIcon sx={sx} /> },- { key: "folder", label: "Folder", node: <FolderOutlinedIcon sx={sx} /> },- { key: "bolt", label: "Bolt", node: <BoltOutlinedIcon sx={sx} /> },+ {+ key: "shield",+ label: "Shield",+ node: <Icon name="shield" size="1.25rem" />,+ },+ { key: "lock", label: "Lock", node: <Icon name="lock" size="1.25rem" /> },+ { key: "label", label: "Label", node: <Icon name="tag" size="1.25rem" /> },+ {+ key: "layers",+ label: "Layers",+ node: <Icon name="layers" size="1.25rem" />,+ },+ {+ key: "folder",+ label: "Folder",+ node: <Icon name="folder" size="1.25rem" />,+ },+ { key: "bolt", label: "Bolt", node: <Icon name="zap" size="1.25rem" /> },{key: "schedule",label: "Schedule",- node: <ScheduleOutlinedIcon sx={sx} />,+ node: <Icon name="clock" size="1.25rem" />,},{key: "sparkle",label: "Sparkle",- node: <AutoAwesomeOutlinedIcon sx={sx} />,+ node: <Icon name="sparkles" size="1.25rem" />,},];diff --git a/frontend/editor/src/core/ui/NodeCard.css b/frontend/editor/src/core/ui/NodeCard.cssindex a7a6d8e781..7223a38779 100644--- a/frontend/editor/src/core/ui/NodeCard.css+++ b/frontend/editor/src/core/ui/NodeCard.css@@ -42,6 +42,13 @@overflow: visible;}+/* Callers pass glyphs of mixed provenance (kind icons, registry tool icons, brand marks); the badge+ draws them all at one size so a chain of cards reads as one set. */+.sui-node-card .sui-iconbadge svg {+ width: 1.125rem;+ height: 1.125rem;+}+.sui-node-card__text {display: flex;flex-direction: column;diff --git a/frontend/editor/src/core/ui/NodeCard.stories.tsx b/frontend/editor/src/core/ui/NodeCard.stories.tsxindex acfe28f71d..2521e6d012 100644--- a/frontend/editor/src/core/ui/NodeCard.stories.tsx+++ b/frontend/editor/src/core/ui/NodeCard.stories.tsx@@ -1,6 +1,5 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import TuneRoundedIcon from "@mui/icons-material/TuneRounded";-import CloseRoundedIcon from "@mui/icons-material/CloseRounded";+import { Icon } from "@app/ui/Icon";import { NodeCard } from "@app/ui/NodeCard";import { ActionIcon } from "@app/ui/ActionIcon";@@ -9,7 +8,7 @@ const meta = {component: NodeCard,parameters: { layout: "padded" },args: {- icon: <TuneRoundedIcon style={{ fontSize: "1.125rem" }} />,+ icon: <Icon name="sliders-horizontal" size={"1.125rem"} />,title: "Compress",detail: "level 7",onSelect: () => {},@@ -46,7 +45,7 @@ export const WithTrailing: Story = {shape="circle"aria-label="Remove">- <CloseRoundedIcon style={{ fontSize: "0.875rem" }} />+ <Icon name="x" size={"0.875rem"} /></ActionIcon>),},diff --git a/frontend/editor/src/core/ui/OptionCard.stories.tsx b/frontend/editor/src/core/ui/OptionCard.stories.tsxindex f7b6ce93eb..1f36540a11 100644--- a/frontend/editor/src/core/ui/OptionCard.stories.tsx+++ b/frontend/editor/src/core/ui/OptionCard.stories.tsx@@ -1,21 +1,17 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import ShieldOutlinedIcon from "@mui/icons-material/ShieldOutlined";-import CategoryOutlinedIcon from "@mui/icons-material/CategoryOutlined";-import GavelOutlinedIcon from "@mui/icons-material/GavelOutlined";-import ArrowForwardRoundedIcon from "@mui/icons-material/ArrowForwardRounded";-import LockOutlinedIcon from "@mui/icons-material/LockOutlined";+import { Icon } from "@app/ui/Icon";import { OptionCard } from "@app/ui/OptionCard";const setUp = (<>Set up- <ArrowForwardRoundedIcon style={{ fontSize: "1rem" }} />+ <Icon name="arrow-right" size={"1rem"} /></>);const comingSoon = (<>- <LockOutlinedIcon style={{ fontSize: "0.95rem" }} />+ <Icon name="lock" size={"0.95rem"} />Coming soon</>);@@ -26,7 +22,7 @@ const meta: Meta<typeof OptionCard> = {tags: ["autodocs"],parameters: { layout: "padded" },args: {- icon: <ShieldOutlinedIcon />,+ icon: <Icon name="shield" />,title: "Security",description:"Redact sensitive information, strip active content, and watermark every document.",@@ -73,7 +69,7 @@ export const Gallery: Story = {<div style={{ display: "flex", gap: "0.75rem", height: "12rem" }}><div style={{ flex: "0 0 16rem" }}><OptionCard- icon={<ShieldOutlinedIcon />}+ icon={<Icon name="shield" />}title="Security"description="Redact sensitive information, strip active content, and watermark every document."cta={setUp}@@ -82,7 +78,7 @@ export const Gallery: Story = {</div><div style={{ flex: "0 0 16rem" }}><OptionCard- icon={<CategoryOutlinedIcon />}+ icon={<Icon name="shapes" />}title="Classification"description="Identify each document's type against your team's labels and tag it automatically."cta={setUp}@@ -91,7 +87,7 @@ export const Gallery: Story = {</div><div style={{ flex: "0 0 16rem" }}><OptionCard- icon={<GavelOutlinedIcon />}+ icon={<Icon name="gavel" />}title="Compliance"description="Enforce your regulatory frameworks and keep an audit trail of every change."disableddiff --git a/frontend/editor/src/core/ui/PanelHeader.stories.tsx b/frontend/editor/src/core/ui/PanelHeader.stories.tsxindex 261d98be2e..f6d3a0b3cb 100644--- a/frontend/editor/src/core/ui/PanelHeader.stories.tsx+++ b/frontend/editor/src/core/ui/PanelHeader.stories.tsx@@ -1,5 +1,5 @@import type { Meta, StoryObj } from "@storybook/react-vite";-import ShieldOutlinedIcon from "@mui/icons-material/ShieldOutlined";+import { Icon } from "@app/ui/Icon";import { PanelHeader } from "@app/ui/PanelHeader";import { StatusBadge } from "@app/ui/StatusBadge";import { Button } from "@app/ui/Button";@@ -10,7 +10,7 @@ const meta: Meta<typeof PanelHeader> = {tags: ["autodocs"],parameters: { layout: "padded" },args: {- icon: <ShieldOutlinedIcon sx={{ fontSize: "1rem" }} />,+ icon: <Icon name="shield" size={"1rem"} />,title: "Security",closeLabel: "Close",},diff --git a/frontend/editor/src/core/ui/PanelHeader.tsx b/frontend/editor/src/core/ui/PanelHeader.tsxindex 3d9a0383ba..869834089a 100644--- a/frontend/editor/src/core/ui/PanelHeader.tsx+++ b/frontend/editor/src/core/ui/PanelHeader.tsx@@ -1,7 +1,6 @@import type { CSSProperties, ReactNode } from "react";import { ActionIcon, Menu } from "@mantine/core";-import CloseIcon from "@mui/icons-material/Close";-import KeyboardArrowDownIcon from "@mui/icons-material/KeyboardArrowDown";+import { Icon } from "@app/ui/Icon";import type { IconBadgeAccent } from "@app/ui/IconBadge";import "@app/ui/PanelHeader.css";@@ -95,10 +94,7 @@ export function PanelHeader({<span className="sui-panelhdr__actions">{actions}</span>)}{hasMenu && (- <KeyboardArrowDownIcon- className="sui-panelhdr__chevron"- sx={{ fontSize: 18 }}- />+ <Icon name="chevron-down" size={18} className="sui-panelhdr__chevron" />)}</>);@@ -141,7 +137,7 @@ export function PanelHeader({onClick={onClose}aria-label={closeLabel}>- <CloseIcon sx={{ fontSize: 18 }} />+ <Icon name="x" size={18} /></ActionIcon>)}</div>diff --git a/frontend/editor/src/core/ui/SegmentedControl.stories.tsx b/frontend/editor/src/core/ui/SegmentedControl.stories.tsxindex 06b1c71978..9a536111e4 100644--- a/frontend/editor/src/core/ui/SegmentedControl.stories.tsx+++ b/frontend/editor/src/core/ui/SegmentedControl.stories.tsx@@ -1,7 +1,6 @@import { useState } from "react";import type { Meta, StoryObj } from "@storybook/react-vite";-import InsertDriveFileOutlinedIcon from "@mui/icons-material/InsertDriveFileOutlined";-import FolderOutlinedIcon from "@mui/icons-material/FolderOutlined";+import { Icon } from "@app/ui/Icon";import { SegmentedControl } from "@app/ui/SegmentedControl";const meta: Meta<typeof SegmentedControl> = {@@ -114,7 +113,7 @@ export const WithIcons: Story = {value: "viewer",label: (<>- <InsertDriveFileOutlinedIcon fontSize="small" />+ <Icon name="file" size={20} /><span>Viewer</span></>),@@ -123,7 +122,7 @@ export const WithIcons: Story = {value: "files",label: (<>- <FolderOutlinedIcon fontSize="small" />+ <Icon name="folder" size={20} /><span>Active Files</span></>),diff --git a/frontend/editor/src/desktop/components/WindowTitleBar.tsx b/frontend/editor/src/desktop/components/WindowTitleBar.tsxindex 7c7407426d..c8faf630d2 100644--- a/frontend/editor/src/desktop/components/WindowTitleBar.tsx+++ b/frontend/editor/src/desktop/components/WindowTitleBar.tsx@@ -2,10 +2,7 @@ import { useEffect, useState } from "react";import { useIsomorphicEffect } from "@mantine/hooks";import { getCurrentWindow } from "@tauri-apps/api/window";import { isTauri } from "@tauri-apps/api/core";-import MinimizeIcon from "@mui/icons-material/Minimize";-import CropSquareIcon from "@mui/icons-material/CropSquare";-import FilterNoneIcon from "@mui/icons-material/FilterNone";-import CloseIcon from "@mui/icons-material/Close";+import { Icon } from "@app/ui/Icon";import { getDesktopOs, DesktopOs } from "@app/services/platformService";import styles from "@app/components/WindowTitleBar.module.css";// Desktop-only skin that reserves the controls' corner across core layout@@ -157,7 +154,7 @@ export function WindowTitleBar() {aria-label="Minimize"tabIndex={-1}>- <MinimizeIcon fontSize="inherit" />+ <Icon name="minus" size="1em" /></button><buttontype="button"@@ -167,9 +164,9 @@ export function WindowTitleBar() {tabIndex={-1}>{maximized ? (- <FilterNoneIcon fontSize="inherit" className={styles.restoreIcon} />+ <Icon name="copy" size="1em" className={styles.restoreIcon} />) : (- <CropSquareIcon fontSize="inherit" />+ <Icon name="square" size="1em" />)}</button><button@@ -179,7 +176,7 @@ export function WindowTitleBar() {aria-label="Close"tabIndex={-1}>- <CloseIcon fontSize="inherit" />+ <Icon name="x" size="1em" /></button></div></div>diff --git a/frontend/editor/src/desktop/components/shared/CloudBadge.tsx b/frontend/editor/src/desktop/components/shared/CloudBadge.tsxindex e0d13d2935..ae64b75d62 100644--- a/frontend/editor/src/desktop/components/shared/CloudBadge.tsx+++ b/frontend/editor/src/desktop/components/shared/CloudBadge.tsx@@ -1,5 +1,5 @@import { Badge, Tooltip } from "@mantine/core";-import CloudOutlinedIcon from "@mui/icons-material/CloudOutlined";+import { Icon } from "@app/ui/Icon";import { useTranslation } from "react-i18next";interface CloudBadgeProps {@@ -25,7 +25,7 @@ export function CloudBadge({ className }: CloudBadgeProps) {><BadgeclassName={className}- leftSection={<CloudOutlinedIcon sx={{ fontSize: 12 }} />}+ leftSection={<Icon name="cloud" size={12} />}variant="light"color="blue"size="xs"diff --git a/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx b/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsxindex 4387c36a11..6c3ee988a5 100644--- a/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx+++ b/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx@@ -14,11 +14,7 @@ import {} from "@mantine/core";import { Button } from "@app/ui/Button";import { useParticipantSession } from "@app/hooks/workflow/useParticipantSession";-import InfoIcon from "@mui/icons-material/Info";-import DownloadIcon from "@mui/icons-material/Download";-import CheckCircleIcon from "@mui/icons-material/CheckCircle";-import CancelIcon from "@mui/icons-material/Cancel";-+import { Icon } from "@app/ui/Icon";interface ParticipantViewProps {token: string;}@@ -195,7 +191,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {if (error) {return (<Alert- icon={<InfoIcon fontSize="small" />}+ icon={<Icon name="info" size={20} />}color="red"title={t("workflow.participant.errorTitle", "Error")}>@@ -206,7 +202,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {if (!session || !participant) {return (- <Alert icon={<InfoIcon fontSize="small" />} color="orange">+ <Alert icon={<Icon name="info" size={20} />} color="orange">{t("workflow.participant.sessionNotFound","Session not found or access denied.",@@ -263,9 +259,9 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {<Alerticon={notification.type === "success" ? (- <CheckCircleIcon fontSize="small" />+ <Icon name="circle-check" size={20} />) : (- <InfoIcon fontSize="small" />+ <Icon name="info" size={20} />)}color={notification.type === "success" ? "green" : "red"}@@ -293,7 +289,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {{session.message && (<Alert- icon={<InfoIcon fontSize="small" />}+ icon={<Icon name="info" size={20} />}color="blue"variant="light">@@ -312,7 +308,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {<Group gap="xs" mt="sm"><Buttonsize="sm"- leftSection={<DownloadIcon fontSize="small" />}+ leftSection={<Icon name="download" size={20} />}onClick={() => downloadDocument(token)}variant="secondary">@@ -483,7 +479,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {<Group gap="xs"><Button- leftSection={<CheckCircleIcon fontSize="small" />}+ leftSection={<Icon name="circle-check" size={20} />}onClick={handleSubmitSignature}loading={isSubmitting}disabled={@@ -496,7 +492,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {</Button><Button- leftSection={<CancelIcon fontSize="small" />}+ leftSection={<Icon name="circle-x" size={20} />}onClick={handleDecline}variant="secondary"accent="danger"@@ -510,7 +506,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {)}{participant.hasCompleted && (- <Alert icon={<CheckCircleIcon fontSize="small" />} color="green">+ <Alert icon={<Icon name="circle-check" size={20} />} color="green">{participant.status === "SIGNED"? t("workflow.participant.completedSigned",@@ -524,7 +520,7 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {)}{participant.isExpired && (- <Alert icon={<InfoIcon fontSize="small" />} color="orange">+ <Alert icon={<Icon name="info" size={20} />} color="orange">{t("workflow.participant.accessExpired","Your access to this document has expired.",diff --git a/frontend/editor/src/proprietary/routes/ShareLinkPage.tsx b/frontend/editor/src/proprietary/routes/ShareLinkPage.tsxindex 4cf09ea27c..5da1a10daa 100644--- a/frontend/editor/src/proprietary/routes/ShareLinkPage.tsx+++ b/frontend/editor/src/proprietary/routes/ShareLinkPage.tsx@@ -13,10 +13,7 @@ import {} from "@mantine/core";import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";-import DownloadIcon from "@mui/icons-material/Download";-import LoginIcon from "@mui/icons-material/Login";-import OpenInNewIcon from "@mui/icons-material/OpenInNew";-+import { Icon } from "@app/ui/Icon";import { useFileActions } from "@app/contexts/FileContext";import { useNavigationActions } from "@app/contexts/NavigationContext";import { alert } from "@app/components/toast";@@ -225,7 +222,7 @@ export default function ShareLinkPage() {)}<Group justify="flex-start" gap="sm" pt="sm"><Button- leftSection={<OpenInNewIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="external-link" size={18} />}onClick={handleOpen}loading={isWorking}disabled={!canOpen}@@ -234,7 +231,7 @@ export default function ShareLinkPage() {</Button><Buttonvariant="secondary"- leftSection={<DownloadIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="download" size={18} />}onClick={handleDownload}loading={isWorking}disabled={!canDownload}@@ -275,7 +272,7 @@ export default function ShareLinkPage() {</Text><Group mt="md"><Button- leftSection={<LoginIcon style={{ fontSize: 18 }} />}+ leftSection={<Icon name="log-in" size={18} />}onClick={handleLogin}>{t("storageShare.goToLogin", "Go to login")}