diff --git a/packages/frontend/core/src/modules/template-doc/view/styles.css.ts b/packages/frontend/core/src/modules/template-doc/view/styles.css.ts index 640f94f0a6..cc9ecc63f6 100644 --- a/packages/frontend/core/src/modules/template-doc/view/styles.css.ts +++ b/packages/frontend/core/src/modules/template-doc/view/styles.css.ts @@ -16,5 +16,28 @@ export const scrollableViewport = style({ maxHeight: 360, }); export const emptyIcon = style({ + fontSize: 20, color: cssVarV2.icon.primary, }); +export const empty = style({ + pointerEvents: 'none', + display: 'flex', + gap: 8, + justifyContent: 'space-between', + alignItems: 'center', + lineHeight: '20px', + padding: 4, +}); +export const emptyText = style({ + color: cssVarV2.text.secondary, +}); +export const link = style({ + lineHeight: 0, + pointerEvents: 'auto', + fontSize: 20, + color: cssVarV2.icon.primary, +}); +export const space = style({ + width: 0, + flex: 1, +}); diff --git a/packages/frontend/core/src/modules/template-doc/view/template-list-menu.tsx b/packages/frontend/core/src/modules/template-doc/view/template-list-menu.tsx index 8187b77827..b85ed0e034 100644 --- a/packages/frontend/core/src/modules/template-doc/view/template-list-menu.tsx +++ b/packages/frontend/core/src/modules/template-doc/view/template-list-menu.tsx @@ -1,7 +1,13 @@ -import { Menu, MenuItem, type MenuProps, Scrollable } from '@affine/component'; +import { + IconButton, + Menu, + MenuItem, + type MenuProps, + Scrollable, +} from '@affine/component'; import { useAsyncCallback } from '@affine/core/components/hooks/affine-async-hooks'; import { useI18n } from '@affine/i18n'; -import { InformationIcon } from '@blocksuite/icons/rc'; +import { DualLinkIcon, InformationIcon } from '@blocksuite/icons/rc'; import { useLiveData, useService } from '@toeverything/infra'; import { useState } from 'react'; @@ -47,12 +53,21 @@ const DocItem = ({ doc, onSelect, asLink }: DocItemProps) => { const Empty = () => { const t = useI18n(); return ( - } - > - {t['com.affine.template-list.empty']()} - +
); };