refactor(web): replace remixicon components with css icons

This commit is contained in:
yyh
2026-02-13 10:28:23 +08:00
parent 5e9f3eab8b
commit e45d4d8d90
2 changed files with 4 additions and 9 deletions

View File

@@ -1,6 +1,5 @@
'use client'
import { RiCloseLine, RiExternalLinkLine } from '@remixicon/react'
import { useDebounceFn, useKeyPress } from 'ahooks'
import { noop } from 'es-toolkit/function'
import { useRouter } from 'next/navigation'
@@ -261,7 +260,7 @@ const CreateFromDSLModal = ({ show, onSuccess, onClose, activeTab = CreateFromDS
className="flex h-8 w-8 cursor-pointer items-center justify-center"
onClick={() => onClose()}
>
<RiCloseLine className="h-[18px] w-[18px] text-text-tertiary" />
<span className="i-ri-close-line h-[18px] w-[18px] text-text-tertiary" aria-hidden="true" />
</div>
</div>
<div className="border-b border-divider-subtle px-6">
@@ -319,7 +318,7 @@ const CreateFromDSLModal = ({ show, onSuccess, onClose, activeTab = CreateFromDS
rel="noopener noreferrer"
>
{learnMoreLabel}
<RiExternalLinkLine className="h-[12px] w-[12px]" />
<span className="i-ri-external-link-line h-[12px] w-[12px]" aria-hidden="true" />
</a>
<div className="flex items-center gap-3">
<Button variant="secondary" onClick={onClose}>

View File

@@ -1,10 +1,6 @@
import type { InspectHeaderProps } from './inspect-layout'
import type { DocPathWithoutLang } from '@/types/doc-paths'
import type { SandboxFileTreeNode } from '@/types/sandbox-file'
import {
RiCloseLine,
RiMenuLine,
} from '@remixicon/react'
import { useCallback, useMemo, useState } from 'react'
import { useTranslation } from 'react-i18next'
import ActionButton from '@/app/components/base/action-button'
@@ -156,7 +152,7 @@ const ArtifactsTab = (headerProps: InspectHeaderProps) => {
<div className="flex min-w-0 flex-1 items-center gap-1">
{isNarrow && (
<ActionButton className="shrink-0" onClick={onOpenMenu} aria-label="Open menu">
<RiMenuLine className="h-4 w-4" />
<span className="i-ri-menu-line h-4 w-4" aria-hidden="true" />
</ActionButton>
)}
{file && (
@@ -194,7 +190,7 @@ const ArtifactsTab = (headerProps: InspectHeaderProps) => {
)}
</div>
<ActionButton className="shrink-0" onClick={handleClose} aria-label="Close">
<RiCloseLine className="h-4 w-4" />
<span className="i-ri-close-line h-4 w-4" aria-hidden="true" />
</ActionButton>
</div>
<div className="flex min-h-0 flex-1 flex-col">