Skip to content

Commit 9f73d08

Browse files
refactor: migrate package icons to @makeplane/propel (#9732)
* refactor: migrate package icons to @makeplane/propel Replace confirmed icon symbols in packages/editor, packages/propel, packages/ui and packages/utils with their audited @makeplane/propel/icons targets, including the relative legacy icon imports inside packages/propel/src. Add the dependency to all four workspaces. Widen the icon component types that were pinned to LucideIcon so both Lucide and Propel icons satisfy them: the editor menu items, editor constants, custom image utils, alignment selector, the ui alert modal variants, and the link icon matchers in utils. Each only renders the icon as a component, and the matcher list still mixes both sources. Two files are deliberately left alone. The emoji-icon-picker directory is out of scope, and icons/priority-icon.tsx dispatches one shared size prop across four still-unresolved Lucide icons, so migrating only its urgent glyph would break that prop and mix fill with stroke. * fix: address icon migration review on packages Restore the 49 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 editor toolbar labels, slash-command titles, image download tooltips and aria-labels, and the Storybook example labels all displayed icon component names. Drop strokeWidth from Propel icons; the generated glyphs paint with fill="currentColor" so the prop never changed weight. Pick StarFilled for the selected FavoriteStar. Lucide's Star with a fill utility was a solid star, and StarOutline is a ring path, so filling it does not reproduce that shape. Also correct six toolbar story tooltips that already read "Bullet ListLayoutIcon" on preview, from an earlier migration with the same over-broad rename. * fix: restore context-menu story labels after icon rename The mechanical icon rename also replaced JSX text children that matched old lucide identifiers (Edit, Download, Share, Archive). Restore the 13 user-facing labels in the context-menu stories. * chore: align lockfile @makeplane/propel importers to 0.3.0 The preview merge left editor, propel, ui, and utils resolved to 0.2.0 while catalog is 0.3.0. Re-resolve those importers so the lockfile matches.
1 parent cb28b70 commit 9f73d08

64 files changed

Lines changed: 515 additions & 476 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

packages/editor/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
"@floating-ui/react": "catalog:",
3838
"@headlessui/react": "catalog:",
3939
"@hocuspocus/provider": "catalog:",
40+
"@makeplane/propel": "catalog:",
4041
"@plane/constants": "workspace:*",
4142
"@plane/hooks": "workspace:*",
4243
"@plane/propel": "workspace:*",

packages/editor/src/components/links/link-edit-view.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66

77
import type { Node } from "@tiptap/pm/model";
8-
import { Link2Off } from "lucide-react";
8+
import { UnlinkOutline } from "@makeplane/propel/icons";
99
import { useCallback, useEffect, useRef, useState } from "react";
1010
// components
1111
import type { LinkViewProps, LinkViews } from "@/components/links";
@@ -148,7 +148,7 @@ export function LinkEditView({ viewProps }: LinkEditViewProps) {
148148
<InputView label="Text" placeholder="Enter Text to display" value={localText} onChange={handleTextChange} />
149149
<div className="bg-strong mb-1 h-[1px] w-full gap-2" />
150150
<div className="flex items-center gap-2 text-13 text-secondary">
151-
<Link2Off size={14} className="inline-block" />
151+
<UnlinkOutline width={14} height={14} className="inline-block" />
152152
<button onClick={removeLink} className="cursor-pointer transition-colors hover:text-placeholder">
153153
Remove Link
154154
</button>

packages/editor/src/components/links/link-preview.tsx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
* See the LICENSE file for details.
55
*/
66

7-
import { Link2Off } from "lucide-react";
8-
import { CopyIcon, GlobeIcon, EditIcon } from "@plane/propel/icons";
7+
import { CopyOutline, EditOutline, GlobeOutline, UnlinkOutline } from "@makeplane/propel/icons";
98
// components
109
import type { LinkViewProps, LinkViews } from "@/components/links";
1110

@@ -36,22 +35,22 @@ export function LinkPreview({
3635
}}
3736
>
3837
<div className="shadow-md flex items-center gap-3 rounded-sm border-2 border-subtle bg-layer-1 p-2 text-11 text-tertiary">
39-
<GlobeIcon width={14} height={14} className="inline-block" />
38+
<GlobeOutline width={14} height={14} className="inline-block" />
4039
<p>{url?.length > 40 ? url.slice(0, 40) + "..." : url}</p>
4140
<div className="flex gap-2">
4241
<button onClick={copyLinkToClipboard} className="cursor-pointer transition-colors hover:text-primary">
43-
<CopyIcon width={14} height={14} className="inline-block" />
42+
<CopyOutline width={14} height={14} className="inline-block" />
4443
</button>
4544
{editor.isEditable && (
4645
<>
4746
<button
4847
onClick={() => switchView("LinkEditView")}
4948
className="cursor-pointer transition-colors hover:text-primary"
5049
>
51-
<EditIcon width={14} height={14} className="inline-block" />
50+
<EditOutline width={14} height={14} className="inline-block" />
5251
</button>
5352
<button onClick={removeLink} className="cursor-pointer transition-colors hover:text-primary">
54-
<Link2Off size={14} className="inline-block" />
53+
<UnlinkOutline width={14} height={14} className="inline-block" />
5554
</button>
5655
</>
5756
)}

packages/editor/src/components/menus/block-menu-options.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import type { Node as ProseMirrorNode } from "@tiptap/pm/model";
88
import { TableMap } from "@tiptap/pm/tables";
99
import type { Editor } from "@tiptap/react";
10-
import { MoveHorizontal } from "lucide-react";
10+
import { DragDropOutline } from "@makeplane/propel/icons";
1111
// constants
1212
import { CORE_EXTENSIONS } from "@/constants/extension";
1313
// types
@@ -84,7 +84,7 @@ const setTableToFullWidth = (editor: Editor): void => {
8484

8585
export const getNodeOptions = (editor: Editor): BlockMenuOption[] => [
8686
{
87-
icon: MoveHorizontal,
87+
icon: DragDropOutline,
8888
key: "table-full-width",
8989
label: "Fit to width",
9090
isDisabled: !editor.isActive(CORE_EXTENSIONS.TABLE),

packages/editor/src/components/menus/block-menu.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import {
1717
import type { Editor } from "@tiptap/react";
1818
import type { LucideIcon } from "lucide-react";
1919
import { useCallback, useEffect, useRef, useState } from "react";
20-
import { CopyIcon, TrashIcon } from "@plane/propel/icons";
20+
import { CopyOutline, DeleteOutline } from "@makeplane/propel/icons";
2121
import type { ISvgIcons } from "@plane/propel/icons";
2222
import { cn } from "@plane/utils";
2323
// constants
@@ -150,7 +150,7 @@ export function BlockMenu(props: Props) {
150150

151151
const MENU_ITEMS: BlockMenuOption[] = [
152152
{
153-
icon: TrashIcon,
153+
icon: DeleteOutline,
154154
key: "delete",
155155
label: "Delete",
156156
onClick: (_e) => {
@@ -159,7 +159,7 @@ export function BlockMenu(props: Props) {
159159
},
160160
},
161161
{
162-
icon: CopyIcon,
162+
icon: CopyOutline,
163163
key: "duplicate",
164164
label: "Duplicate",
165165
isDisabled:

packages/editor/src/components/menus/bubble-menu/alignment-selector.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
*/
66

77
import type { Editor } from "@tiptap/core";
8-
import type { LucideIcon } from "lucide-react";
9-
import { AlignCenter, AlignLeft, AlignRight } from "lucide-react";
8+
import type { ComponentType, SVGProps } from "react";
9+
import { AlignCenterOutline, AlignLeftOutline, AlignRightOutline } from "@makeplane/propel/icons";
1010
// plane utils
1111
import { cn } from "@plane/utils";
1212
// components
@@ -27,14 +27,14 @@ export function TextAlignmentSelector(props: Props) {
2727
const textAlignmentOptions: {
2828
itemKey: TEditorCommands;
2929
renderKey: string;
30-
icon: LucideIcon;
30+
icon: ComponentType<SVGProps<SVGSVGElement>>;
3131
command: () => void;
3232
isActive: () => boolean;
3333
}[] = [
3434
{
3535
itemKey: "text-align",
3636
renderKey: "text-align-left",
37-
icon: AlignLeft,
37+
icon: AlignLeftOutline,
3838
command: () =>
3939
menuItem.command({
4040
alignment: "left",
@@ -44,7 +44,7 @@ export function TextAlignmentSelector(props: Props) {
4444
{
4545
itemKey: "text-align",
4646
renderKey: "text-align-center",
47-
icon: AlignCenter,
47+
icon: AlignCenterOutline,
4848
command: () =>
4949
menuItem.command({
5050
alignment: "center",
@@ -54,7 +54,7 @@ export function TextAlignmentSelector(props: Props) {
5454
{
5555
itemKey: "text-align",
5656
renderKey: "text-align-right",
57-
icon: AlignRight,
57+
icon: AlignRightOutline,
5858
command: () =>
5959
menuItem.command({
6060
alignment: "right",

packages/editor/src/components/menus/bubble-menu/color-selector.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
*/
66

77
import type { Editor } from "@tiptap/react";
8-
import { ALargeSmall, Ban } from "lucide-react";
8+
import { Ban } from "lucide-react";
9+
import { TextOutline } from "@makeplane/propel/icons";
910
import { useMemo } from "react";
1011
// plane utils
1112
import { cn } from "@plane/utils";
@@ -48,7 +49,7 @@ export function BubbleMenuColorSelector(props: Props) {
4849
backgroundColor: activeBackgroundColor ? activeBackgroundColor.backgroundColor : "transparent",
4950
}}
5051
>
51-
<ALargeSmall
52+
<TextOutline
5253
className={cn("size-3.5", {
5354
"text-primary": !activeTextColor,
5455
})}

packages/editor/src/components/menus/bubble-menu/link-selector.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import type { Editor } from "@tiptap/core";
88

99
import { useCallback, useRef, useState } from "react";
10-
import { LinkIcon, TrashIcon, CheckIcon } from "@plane/propel/icons";
10+
import { DeleteOutline, LinkOutline, TickOutline } from "@makeplane/propel/icons";
1111
// plane imports
1212
import { cn } from "@plane/utils";
1313
// constants
@@ -64,7 +64,7 @@ export function BubbleMenuLinkSelector(props: Props) {
6464
menuButton={
6565
<>
6666
Link
67-
<LinkIcon className="size-3 shrink-0" />
67+
<LinkOutline className="size-3 shrink-0" />
6868
</>
6969
}
7070
options={options}
@@ -102,7 +102,7 @@ export function BubbleMenuLinkSelector(props: Props) {
102102
context.onOpenChange(false);
103103
}}
104104
>
105-
<TrashIcon className="size-4" />
105+
<DeleteOutline className="size-4" />
106106
</button>
107107
) : (
108108
<button
@@ -113,7 +113,7 @@ export function BubbleMenuLinkSelector(props: Props) {
113113
handleLinkSubmit();
114114
}}
115115
>
116-
<CheckIcon className="size-4" />
116+
<TickOutline className="size-4" />
117117
</button>
118118
)}
119119
</div>

packages/editor/src/components/menus/bubble-menu/node-selector.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import type { Editor } from "@tiptap/react";
88

9-
import { CheckIcon, ChevronDownIcon } from "@plane/propel/icons";
9+
import { ChevronDownOutline, TickOutline } from "@makeplane/propel/icons";
1010
// plane utils
1111
import { cn } from "@plane/utils";
1212
// components
@@ -73,7 +73,7 @@ export function BubbleMenuNodeSelector(props: Props) {
7373
menuButton={
7474
<>
7575
<span>{activeItem?.name}</span>
76-
<ChevronDownIcon className="size-3 shrink-0" />
76+
<ChevronDownOutline className="size-3 shrink-0" />
7777
</>
7878
}
7979
options={options}
@@ -101,7 +101,7 @@ export function BubbleMenuNodeSelector(props: Props) {
101101
<item.icon className="size-3 flex-shrink-0" />
102102
<span>{item.name}</span>
103103
</div>
104-
{activeItem.name === item.name && <CheckIcon className="size-3 flex-shrink-0 text-tertiary" />}
104+
{activeItem.name === item.name && <TickOutline className="size-3 flex-shrink-0 text-tertiary" />}
105105
</button>
106106
))}
107107
</section>

0 commit comments

Comments
 (0)