@dotnaos/ ui (英语)
@dotnaos/ui 是DotNaos组件系统的完整公共捆绑。 面向消费者的进口品使用斜拉式副道:
import { Stack, Button } from "@dotnaos/ui/base";
import { ListDetailPageLayout } from "@dotnaos/ui/layout";
import { FileExplorer } from "@dotnaos/ui/file-tree";
import { GitClient } from "@dotnaos/ui/source-control";
import { Coverage, List, Navigation, Status, Tree } from "@dotnaos/ui/source-control/changes/review";
import { PdfViewer } from "@dotnaos/ui/pdf-viewer";
内部工作空间包名称使用 npm-相容的连字符名, 如 @dotnaos/ui-base;这些名称是执行细节,没有定义公共导入样式或组件-树标签.
软件包
ui bundle
├── base generic primitives, controls, and surfaces
├── layout panels, shells, and responsive page layouts
├── tree generic flat or nested tree behavior
├── file-tree file navigation and actionable explorer
├── code editable and read-only code surfaces
├── markdown-editor Markdown rendering and editing
├── chat backend-agnostic chat presentation
├── ai assistant controls and composed AI surfaces
├── source-control changes, diffs, history, and complete Git client
├── canvas drawing surface and editor
├── calendar calendar parts and complete calendar
├── pdf-viewer PDF render parts and complete viewer surfaces
├── settings fields, groups, panels, and settings page
├── workspace-picker workspace rows, tree, picker, dialog, and page
├── devtools review and inspection tooling
├── web web runtime composition
└── native native primitives and native-owned components
每个组件域都是真实的包 components/ui。 。 。 . git-client 属于 source-control,以及前者 node-tree 软件包现在为通用 tree 软件包。 原始人直接生活在 base;没有单独的原始,共享,或适配软件包.
建筑规则
- 特性包依赖于下级包,绝不从中导入
@dotnaos/ui捆绑. - Web 组件组成主题意识
Container和语义表面,而不是重复地粘贴、半径和背景选择. - 原住民拥有其渲染器并只分享平台中性设计符和刻意签订合同.
- 公共特性包可以导出由嵌入式体验组成的小渲染单元,以及可选对话框或页面表面.
- 一个有意义的下划线前缀路径是私有的,永远不会从其软件包中导出.
- 每个导出的 React 组件都有一个合用的位置
*.design.tsx定义. - 软件包和文件夹只组织源头发现;运行时构成和严格UI身份仍然来自JSX并打入了分槽.
权威架构和重构合同是 ../../docs/ui-repository-refactor-plan.md。 。 。 .
样式和预览
网络消费者一次导入完整的共享样式表. 里面有设计 基金会和所有公共部门使用的公用事业:
import "@dotnaos/ui/styles.css";
设计 空格读取真实的软件包和源文件夹 .designspace.ts;库中并不需要自己的开发服务器只是被发现或编译.