✨ feat(vscode): 代码阅读卡片横排多个概念图标

This commit is contained in:
cruldra committed 2026-10-03 03:11:47 +08:00
1 parent 11fcbef225
commit 394cd2fc1c
19 files changed
+328 -99

No files matched your search

@@ -3,7 +3,7 @@ import type { CSSProperties, ReactElement } from 'react'
import type { GroupStyle, Inline, SegmentGroup } from './types'
import { useContext, useState } from 'react'
import { DisplayNameContext, shownName } from './displayNames'
import { KIND_ICON_COMPONENTS, KIND_ICONS } from './kindIcons'
import { KIND_ICON_COMPONENTS } from './kindIcons'
import { isCurrent, segmentOccurrence, sourceOf } from './occurrences'
import { HighlightContext } from './useOccurrences'
@@ -47,10 +47,10 @@ export function SegmentText({ segments }: { segments: Inline[] }): ReactElement
* 颜色在 codeReader.css 的 .cr-group[data-style] 里,框自己给了颜色(color)时用它。
*/
const GROUP_ICONS: Record<GroupStyle, LucideIcon | undefined> = {
iteration: KIND_ICON_COMPONENTS[KIND_ICONS.loop],
condition: KIND_ICON_COMPONENTS[KIND_ICONS.if],
iteration: KIND_ICON_COMPONENTS.repeat,
condition: KIND_ICON_COMPONENTS.split,
branch: undefined,
skip: KIND_ICON_COMPONENTS[KIND_ICONS.return],
skip: KIND_ICON_COMPONENTS['corner-down-left'],
tag: undefined,
classes: undefined,
}