Skip to content

pantoken / packages/core/src / collectIcons

फंक्शन: collectIcons()

collectIcons(options?): IconLayer

बीटा

एकीकृत InstUI आइकन लेयर एकत्र करें। कस्टम ग्लिफ़ समान नाम वाले Lucide\nglyphs की तुलना में प्राथमिकता रखते हैं। आउटपुट को नाम के अनुसार सॉर्ट किया जाता है ताकि परिणाम निर्धारक हों।

पैरामीटर

options?

CollectIconsOptions = {}

वापसी

IconLayer

उदाहरण

हर ग्लिफ़ और icon-colour विशेष मान एकत्र करें

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"]]

केवल Instructure-authored ग्लिफ़ तक सीमित करें

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

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