JustGenius-s/DSH-Plugs--packages-ui ↗★ 8
@just-genius/dsh-plugin-ui
提供DSH原生UI组件库与主题Token 适合开发DSH插件或独立应用,需要使用统一React基础组件和主题的用户。
安装
此插件尚未提供可验证的 bundle,或兼容性检查未通过。请先阅读仓库说明。 阅读完整 README ↗
说明文档
阅读完整 README ↗@just-genius/dsh-plugin-ui
DSH-native UI kit: --dsw-* theme tokens plus React primitives. Used by plugins in this monorepo (bundled at build time) and by standalone apps such as Vellum (runtime dependency).
What it exports
| Surface | Contents |
|---|---|
. | Components + installTheme / setThemePreference |
./official-primitives | DSH-only facade for the platform's content renderers |
./theme.css | Concatenated token sheets for Vite/CSS @import |
./css-modules | Build helper (dshCssModules) for plugin tsdown configs |
Atoms: Button, Input, Pill, Tooltip, Modal, Menu, StateDot, DisclosureRow, plus the ic_ds_* icon set.
Settings chrome: Switch, Field*, SettingsCard, ExpandableRow, Tree*, FilterChip*, Tag, …
Standalone app (e.g. Vellum)
// boot once
import { installTheme } from '@just-genius/dsh-plugin-ui'
installTheme('system') // 'light' | 'dark' | 'system'
@import '@just-genius/dsh-plugin-ui/theme.css';
import { Button, Input, Modal } from '@just-genius/dsh-plugin-ui'
Tokens live on body / body[data-ds-dark-theme]. Dark mode is toggled by installTheme / setThemePreference, not by a .dark class.
Sync theme from deepseek-harness
DSH_THEME_SRC=/path/to/ui-theme/src/styles pnpm --filter @just-genius/dsh-plugin-ui sync-theme
Normal builds use the committed snapshot under src/theme and never read another checkout.
Refreshing that snapshot is an explicit maintainer operation requiring DSH_THEME_SRC.
Local link (before npm publish)
"@just-genius/dsh-plugin-ui": "file:../DSH-Plugs/packages/ui"
Build this package first (pnpm --filter @just-genius/dsh-plugin-ui build) so lib/ exists.
Peer deps
react and react-dom >=18.2.0. The DSH-only
./official-primitives entry additionally expects the platform-materialized
@deepseek-ai/dsh-client-ui-primitives version declared in package.json.