Skip to content

pantoken / foundation

foundation

实验性

@pantoken/foundation — 为 Foundation for Sites 使用 Instructure 令牌的主题。

Foundation 以 Sass 为先,因此该包提供两层。toFoundationSettings 会生成一个 _settings 风格的 Sass 局部文件,将 Foundation 的设置变量指向 var(--instui-*),从而在保留通过相同自定义属性的运行时主题化的同时,由 Sass 构建编译出 Instructure 的外观。toFoundationCss 会生成一个薄的 CSS 覆盖层,以相同方式为常见的已编译类(.button, .callout, 链接)着色——当你使用现成的 Foundation CSS 并且只想在不重新编译的情况下叠加 Instructure 颜色时非常有用。

示例

ts
import { foundationSettings, foundationCss } from "@pantoken/foundation";
// foundationSettings → a Sass partial; foundationCss → a runtime overlay.

接口

变量

函数

引用

default

重命名并重新导出 foundationCss