@ghub/ui

中文文档
0.19.0发布于 2026/11/08SEE LICENSE IN LICENSETypeScriptES Module构建来源已验证近 30 天下载 2419

The design system of the Gelhaus Solutions product family: hand-rolled accessible React components. No Radix, no shadcn, no headless component libraries.

原始使用文档
文档目录3 节
  1. Entry points
  2. Moving from @ghub/gctl-ui
  3. Licence

@ghub/ui

The design system of the Gelhaus Solutions product family. Direction: precision control room. Dark-first, dense, hairline borders, mono numerals, one accent reserved for live state and primary action.

Components are hand-rolled. No Radix, no shadcn, no headless component library: accessibility is implemented rather than inherited, and the bar is WCAG 2.2 AA with a contrast test that enforces the colour half of it.

Three of the components render an application's own manifest rather than anything this package knows about: GeneratedForm draws a settings schema, HealthPanel draws declared health values, MeterPanel draws declared usage. An application adding a setting or a metric costs no release of anything.

Tokens live in @ghub/tokens/theme.css, which you import alongside this.

import { Badge, HealthPanel, Panel } from "@ghub/ui";

Entry points

Entry pointWhat it holds
@ghub/uiConsole: the control room components
@ghub/ui/modernModern: the consumer-facing language, styled by modern.css
@ghub/ui/chartsThe two chart components, and the only place charts are drawn
@ghub/ui/behaviourWhat both languages share: the behaviour, with nothing drawn

ESM only.

Moving from @ghub/gctl-ui

Until 0.2.6 this package was published as @ghub/gctl-ui. 0.3.0 is the same code under the new name, with one removal: the panel bridge (@ghub/gctl-ui/panels) is GControl's protocol rather than part of a design system, so it stayed with GControl. Nothing in this package depends on a GControl package any more.

Part of GHub-Packages, the packages the Gelhaus Solutions products share. It is the family's design system rather than a general-purpose component library, and it changes when the family's design does.

Licence

Elastic License 2.0. Source-available: you may read, self-host and modify it for your own organisation. You may not offer it as a service, and you may not circumvent the licence-key functionality. See the LICENSE file in this package.

Copyright (c) 2026 Gelhaus Solutions (Enno Gelhaus). Built and maintained by Gelhaus Solutions.

版本与发布记录

@ghub/ui 共发布 22 个版本,首次发布于 2026/10/02;过去 12 个月发布了 22 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.19.0latest2026/11/087 天前
0.18.02026/11/0214 天前
0.17.02026/10/2621 天前
0.16.02026/10/2621 天前
0.15.12026/10/2621 天前
0.15.02026/10/2621 天前

关于 @ghub/ui 的常见问题

@ghub/ui 是什么?

The design system of the Gelhaus Solutions product family: hand-rolled accessible React components. No Radix, no shadcn, no headless component libraries.

如何安装 @ghub/ui?

在项目目录运行 npm install @ghub/ui,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:react(>=19)、react-dom(>=19)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@ghub/ui 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@ghub/ui 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@ghub/ui 可以商用吗?

@ghub/ui 使用 SEE LICENSE IN LICENSE 许可。许可条款写在包内的独立文件中,请阅读该文件确认可否商用。以上为概括,不构成法律意见,请以许可原文为准。

@ghub/ui 的下载量有多少?

根据 npm 官方下载统计,@ghub/ui 在 2026/10/17 – 2026/11/15 这 30 天内被下载 2,419 次,日均约 81 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@ghub/ui 还在维护吗?

最新版本 0.19.0 发布于 2026/11/08(7 天前);至今共发布 22 个版本,其中过去 12 个月发布了 22 个;首次发布于 2026/10/02。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。