Skip to content

pantoken / packages/core/src / collectIcons

Funkcija: collectIcons()

collectIcons(options?): IconLayer

Beta

Zberite združeno plast ikon InstUI. Po meri ustvarjeni glyfi imajo prednost pred glyfi Lucide z enakim imenom. Izhod je razporejen po imenu za deterministične rezultate.

Parametri

options?

CollectIconsOptions = {}

Vrne

IconLayer

Primeri

Zberi vsak glyf in posebne vrednosti barv ikon

ts
import { collectIcons } from "@pantoken/core";

const { glyphs, colors } = collectIcons();
// glyphs → IconToken[] (Custom + Lucide, name-sorted)
// colors → [["--instui-icon-color-ai", "…"], ["--instui-icon-color-inherit", "currentColor"]]

Omeji le na glyfe, ki jih je ustvaril Instructure

ts
import { collectIcons } from "@pantoken/core";

const { glyphs } = collectIcons({ includeLucide: false });
// → only the Custom (Instructure-authored) glyphs