diff --git a/packages/client/ui-primitives/src/icons/index.tsx b/packages/client/ui-primitives/src/icons/index.tsx index 830ff4f642..74e3e757b2 100644 --- a/packages/client/ui-primitives/src/icons/index.tsx +++ b/packages/client/ui-primitives/src/icons/index.tsx @@ -728,3 +728,18 @@ export const IconQuestionOutline14 = ({ size = 14, className }: IconProps) => ( ) + +/** ic_ds_archive_outline_20 (figma extract): lidded box + label slot. The export's + * 0.11px stroke ring around the box contour is dropped — it restates the same + * contour in the same ink, which currentColor already carries. */ +export const IconArchiveOutline20 = ({ size = 20, className }: IconProps) => ( + + + + +) diff --git a/packages/client/ui-primitives/src/icons/props.ts b/packages/client/ui-primitives/src/icons/props.ts index 59b10c8492..27dde23e4d 100644 --- a/packages/client/ui-primitives/src/icons/props.ts +++ b/packages/client/ui-primitives/src/icons/props.ts @@ -1,6 +1,6 @@ /** Shared props for every ic_ds_* icon component. */ export interface IconProps { - /** Square edge in px; defaults to the glyph's native size (14 or 16). */ + /** Square edge in px; defaults to the glyph's own drawn size. */ size?: number | undefined /** Extra class for layout placement; color rides currentColor. * (`| undefined` for exactOptionalPropertyTypes: callers forward their own optional prop.) */ diff --git a/packages/client/ui-primitives/tests/icons.spec.tsx b/packages/client/ui-primitives/tests/icons.spec.tsx index 536d1b774f..cc5175cba4 100644 --- a/packages/client/ui-primitives/tests/icons.spec.tsx +++ b/packages/client/ui-primitives/tests/icons.spec.tsx @@ -2,7 +2,7 @@ import { cleanup, render } from '@testing-library/react' import { afterEach, describe, expect, it } from 'vitest' import * as primitives from '@deepseek-ai/dsh-client-ui-primitives' -import { IconApiOutline14, IconFolderClose16, IconSendOutline16 } from '@deepseek-ai/dsh-client-ui-primitives' +import { IconApiOutline14, IconArchiveOutline20, IconFolderClose16, IconSendOutline16 } from '@deepseek-ai/dsh-client-ui-primitives' afterEach(cleanup) @@ -14,8 +14,8 @@ const icons = Object.fromEntries( const iconNames = Object.keys(icons) describe('ic_ds_ icon set', () => { - it('exports the full P-I set (45 deepsuite + 14 figma extracts + the hand-authored sparkle)', () => { - expect(iconNames.length).toBe(60) + it('exports the full P-I set (45 deepsuite + 15 figma extracts + the hand-authored sparkle)', () => { + expect(iconNames.length).toBe(61) }) it.each(iconNames)('%s renders an svg with currentColor fills and no hardcoded palette', (name) => { @@ -36,11 +36,13 @@ describe('ic_ds_ icon set', () => { expect(svg.classList.contains('x')).toBe(true) }) - it('native defaults: 14-glyphs default 14, 16-glyphs default 16', () => { + it('each glyph defaults to its own drawn size, not one set-wide default', () => { const api = render() expect(api.container.querySelector('svg')!.getAttribute('width')).toBe('14') const folder = render() expect(folder.container.querySelector('svg')!.getAttribute('width')).toBe('16') + const archive = render() + expect(archive.container.querySelector('svg')!.getAttribute('width')).toBe('20') }) }) diff --git a/packages/client/ui-workspace/src/client/rows/Rows.tsx b/packages/client/ui-workspace/src/client/rows/Rows.tsx index 27a105df30..ab92e671ea 100644 --- a/packages/client/ui-workspace/src/client/rows/Rows.tsx +++ b/packages/client/ui-workspace/src/client/rows/Rows.tsx @@ -8,7 +8,7 @@ import { useState } from 'react' import clsx from 'clsx' import { - HoverCard, IconBranchOutline16, IconDownloadOutline16, IconEditOutline16, + HoverCard, IconArchiveOutline20, IconBranchOutline16, IconEditOutline16, IconEllipsisOutline16, IconFolderClose16, IconFolderOpen16, IconPlusOutline16, IconTrashOutline16, IconTriangleRightFill14, Menu, StateDot, } from '@deepseek-ai/dsh-client-ui-primitives' @@ -273,7 +273,8 @@ export function SessionNodeItem({ node, currentId, now, onOpen, onRename, onFork const sessionMenuItems = [ { id: 'rename', label: t('rename'), icon: }, { id: 'fork', label: t('menu.fork'), icon: }, - { id: 'archive', label: t('menu.archiveSession'), icon: }, + // 20-native glyph in the menu's 16px icon slot (Menu.module.css .itemIcon). + { id: 'archive', label: t('menu.archiveSession'), icon: }, ] // Figma session cell: pad 8, status slot 16, then a 4px title gap. const ownRow = (