Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 7 additions & 0 deletions .changeset/agent-reference-corrections.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@inkcre/ui-web": patch
---

修正 Agent 组件选型和表单示例说明,按实际版本整理迁移要求;API 参考从签名补出组件本地类型结构,明确与包根导出类型的区别,并移除重复的组件误用汇总及消费者入口中的维护指令。

迁移指南增加统一的下一版本区,由现有版本准备命令自动归档,并在发布前检查待定内容已处理。
5 changes: 5 additions & 0 deletions .changeset/logo-pack-delivery.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@inkcre/ui-web": minor
---

纳入 InKCre Logo Pack,随包交付 SVG、PNG、消费说明和清单,通过 `@inkcre/ui-web/logo/*` 提供公开静态资源入口,新增 SwiftPM 资源 product;版本 ZIP 作为 GitHub Release 附件,App Icon 由消费者制作。
5 changes: 5 additions & 0 deletions .github/workflows/release-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,8 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Complete SwiftPM tag and Logo release attachment
if: steps.changesets.outputs.hasChangesets == 'false'
run: python3 scripts/logo-release.py publish
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@ coverage/
# Published design examples are maintained documentation assets.
!/docs/design/examples/*
!/packages/web/docs/design/examples/*
!/assets/logo/**/*.png
!/assets/logo/*.png

# Logo delivery is copied from the root asset owner during the package build.
/packages/web/assets/
/.build/
/.swiftpm/
__pycache__/

# svc:begin local-config sha256=0cb2591848c4e5675766aa516f16dfb9981fc52e1dcbadd8cec89b6982db927d
svc.local.json
Expand Down
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Design tokens are the single source for names, types, values, and references. Fi

- Design stance, visual language, composition, and rationale: `DESIGN.md` and `docs/design/`
- Design-token source: `tokens/inkcre.tokens.json` (see `tokens/tokens.md` for format and maintenance)
- Brand assets: `assets/logo/`; two original-transparent SVG masters own geometry and original colors. PNG/SVG exports and versioned release ZIPs are generated; npm and SwiftPM deliver the same resources. Other repositories recorded in its provenance are historical sources, not future asset owners.
- Public package API: `packages/web/` exports, component manifest, TypeScript sources, generated declarations, styles
- Component usage evidence: `packages/web/stories/`
- UI consumer Agent guidance: `packages/web/skill.seed.json` and the generated `packages/web/skills/ui-web/`
Expand Down
22 changes: 22 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,28 @@ For interaction or visual behavior changes, also review the affected Story or re
consuming page — build and coverage checks do not prove those behaviors correct.
Check selection follows the [organization verification policy](https://github.com/InKCre/.github/blob/main/TESTING.md).

## 包版本与迁移说明

需要消费者调整调用或特别复核的变化写入 `packages/web/MIGRATION.md` 的 `## 下一版本` 区,并为 Web 包添加 Changeset。正文中的小节使用三级标题;CHANGELOG 记录版本变化,MIGRATION 只说明升级动作和兼容边界,不重复完整变更列表。

运行 `pnpm changeset:version` 推进版本。它先恢复未完成的迁移归档,再执行 Changesets,将待定正文归入新的正式版本,最后同步包元数据。`migration-base` 标记记录待定内容开始积累时的包版本,由命令维护,不手改;版本发生变化但没有迁移内容时也会更新标记。版本标题表示该版本包含这些变化,不表示 registry 已发布成功。

归档通过一次文件替换同时更新正文与基准,已有历史不改写。Changesets 成功后若归档或元数据生成失败,修复报错后重跑同一命令;先完成恢复,再添加下一批 Changeset。Changesets 自身失败时可能留下部分版本文件,需要先检查其输出与工作树,不将部分结果直接发布。目标版本已存在迁移历史时,命令报错并保留原文,交由维护者核对。

`pnpm check:release` 校验迁移结构并在临时工作区验证版本推进、失败恢复与重复执行;普通 PR 可以保留待定内容。`pnpm changeset:publish` 在发布前要求基准与包版本一致、待定区为空,不能用裸 `changeset publish` 绕过检查。当前归档入口只支持正式版本;引入预发布流程时需同步定义迁移归属和恢复规则。

组件用途、交互和示例变化的文档责任见[Agent 文档生成说明](scripts/build-agent-skills.md#内容责任)。作者核对受影响的选型与限制,审阅者通过相关 Story 或实际消费者动作确认;结构、类型和构建检查只承担各自能观察到的事实。

## Logo 资产维护

`assets/logo/masters/inkcre-original-transparent-optical-32.svg` 与 `inkcre-original-transparent-standard-256.svg` 是人工维护源,`data-inkcre-color` 区分主体与灰块以生成配色。其余 SVG、PNG 和 manifest 是产物。更新源或生成规则后,按[资产说明](assets/logo/README.zh-CN.md)重建;App Icon 由消费应用维护。原日期 ZIP、PROVENANCE 和原始 sources 是历史证据,不能约束未来 Logo 必须等于旧包。

普通包构建只检查输入摘要和产物清单,复制消费资源,不运行渲染器。`pnpm check:logo` 检查源关系、逐文件 ZIP 校验和冲突拒绝;`check:package` 继续验证真实 npm tarball 的公开 SVG/PNG 子路径。图形未变时复用已有显示证据,不重做全部渲染和多仓测试。

所有渠道沿用 `packages/web/package.json` 的 UI 发行号与 Changeset。Swift 资源公开入口的破坏性变更同样计入 SemVer 和 MIGRATION。发布成功的 `@inkcre/ui-web@V` tag 锚定提交 C;Release workflow 在 C 上补裸版本 tag `V` 与 `InKCre-logo-pack-V.zip` 附件。缺失内容可重跑补齐,已存在但内容不同则失败,不移动 tag 或覆盖附件。没有 Swift manifest 的旧版本不补发。PNG 已提交,发布只打包,禁止在重试时重新渲染。

`pnpm logo:pack` 可本地检查版本 ZIP;尚未发行的 checkout 产物不是正式下载入口。`python3 scripts/logo-release.py publish` 会写 GitHub,只用于已有发布授权的发行流程;它不批准 npm 发行或合并 PR。

## Token pipeline

`tokens/inkcre.tokens.json` is the Token specification source. Figma proposes value
Expand Down
1 change: 1 addition & 0 deletions DESIGN.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ InKCre 的界面应让内容的关系和可执行的操作容易理解,让阅
| 选择文字、颜色、形状和层次,或审视整体视觉是否协调 | [视觉语言](docs/design/visual-language.md) |
| 把内容和操作组织成页面、列表、表单或浮层 | [页面组合](docs/design/composition.md) |
| 比较方案、解释取舍,或用已有例子校准判断 | [判断依据](docs/design/reference.md) |
| 选择 Logo 配色、逻辑尺寸和高 DPI 资产 | [Logo Pack](assets/logo/README.zh-CN.md) |

设计立场说明理由,视觉语言说明表达,页面组合说明关系如何落到场景,判断依据说明能从实例得出什么结论。它们共享设计方向,各自只拥有相应的知识;一个技术问题不要求加载整套正文。

Expand Down
20 changes: 20 additions & 0 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// swift-tools-version: 5.9
import PackageDescription

let package = Package(
name: "InKCreUI",
products: [.library(name: "InKCreLogoAssets", targets: ["InKCreLogoAssets"])],
targets: [
.target(
name: "InKCreLogoAssets",
path: "assets/logo",
exclude: [
"masters", "svg", "sources", "build_pack.py", "manifest.json",
"PROVENANCE.json", "QA-report.json", "README.zh-CN.md",
"InKCre-logo-pack-preview.png",
],
sources: ["InKCreLogoAssets.swift"],
resources: [.copy("png")]
)
]
)
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,23 @@

The InKCre design system and the `@inkcre/ui-web` web renderer — design tokens, Vue components, and an interactive component catalog.

`ui` 是 InKCre 的设计系统仓库——维护 Token 源、Vue 组件和交互式组件目录,并通过 `@inkcre/ui-web` 发布给 Web 消费方。
`ui` 是 InKCre 的设计系统仓库——维护品牌资产、Token 源、Vue 组件和交互式组件目录,通过 `@inkcre/ui-web`、SwiftPM 与 GitHub Release 的 Logo ZIP 交付给消费方。

## Repository shape

- [`DESIGN.md`](DESIGN.md) — design principles and the per-task reading path
- `docs/design/` — design stance, visual language, page composition, and rationale
- `tokens/inkcre.tokens.json` — the Token specification source (Figma proposes value updates; the generator owns outputs)
- `packages/web/` — the `@inkcre/ui-web` Vue component package
- [`assets/logo/`](assets/logo/README.zh-CN.md) — 跨平台 Logo 资产、来源、清单和重建脚本
- `scripts/build-tokens.ts` — the Token generator (Style Dictionary)

## Quickstart

### 获取 Logo

Web 消费者从 `@inkcre/ui-web/logo/*` 导入,Swift 消费者依赖本仓库的 `InKCreLogoAssets` product;用法见 [Logo 说明](assets/logo/README.zh-CN.md)。正式发行的 ZIP 位于[对应 GitHub Release](https://github.com/InKCre/ui/releases),供人工和设计工具使用。SVG 为源,PNG 与 ZIP 为产物;App Icon 的画布、尺寸和平台绑定由消费者制作和维护。原日期 ZIP 仅保留为历史输入。

### Use the package

```bash
Expand Down
Binary file added assets/InKCre-logo-pack-20261021.zip
Binary file not shown.
Binary file added assets/logo/InKCre-logo-pack-preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions assets/logo/InKCreLogoAssets.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import Foundation

/// PNG resources retain the documented `png/<variant>/…` and Retina paths.
public enum InKCreLogoAssets {
public static let bundle: Bundle = .module
}
65 changes: 65 additions & 0 deletions assets/logo/PROVENANCE.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"checked_on": "2026-10-21",
"purpose": "Preserve current InKCre mark and package native vector assets; no redesign.",
"sources": [
{
"local_path": "sources/web-logo-256.svg",
"repository": "InKCre/impl-ts",
"path": "apps/client-web/public/logo/256.svg",
"commit": "2d260e3f194ba34858243d41d19afa889a2d4060",
"git_blob_sha": "8ebc4f5bea14cbd550a32fe6ec7e0c8bbbd17837",
"url": "https://github.com/InKCre/impl-ts/blob/2d260e3f194ba34858243d41d19afa889a2d4060/apps/client-web/public/logo/256.svg",
"role": "Standard geometry master, 256 viewBox. Used at logical sizes 48 and above in this pack."
},
{
"local_path": "sources/ui-logo-32.svg",
"repository": "InKCre/ui",
"path": "packages/web/src/logo.svg",
"commit": "cd434bf11eaeae0fe59e230008cb15c8a9f950f6",
"git_blob_sha": "2727331578969757f6ac17c069e2793f908a3f6f",
"url": "https://github.com/InKCre/ui/blob/cd434bf11eaeae0fe59e230008cb15c8a9f950f6/packages/web/src/logo.svg",
"same_blob_url": "https://github.com/InKCre/impl-ts/blob/2d260e3f194ba34858243d41d19afa889a2d4060/apps/client-web/public/logo/32.svg",
"role": "Existing 32-viewBox small-size geometry, shared by design system and current web app. Used at logical sizes up to 32 in this pack."
},
{
"local_path": "sources/website-mark-32.svg",
"repository": "InKCre/docs",
"path": "website/content/public/images/inkcre-mark.svg",
"commit": "7449135fefdd6056fecba387e59e3005aed5eafd",
"git_blob_sha": "51b8c832f4708c10e612f9c8702e51346e4cf248",
"url": "https://github.com/InKCre/docs/blob/7449135fefdd6056fecba387e59e3005aed5eafd/website/content/public/images/inkcre-mark.svg",
"role": "Corroborating current website logo; not the rendering master because its connector path differs from UI source line encoding."
}
],
"additional_evidence": [
{
"url": "https://github.com/InKCre/impl-ts/blob/2d260e3f194ba34858243d41d19afa889a2d4060/apps/client-web/src/App.vue",
"finding": "Current app header references /logo/32.svg."
},
{
"url": "https://github.com/InKCre/ui/blob/cd434bf11eaeae0fe59e230008cb15c8a9f950f6/packages/web/histoire.config.ts",
"finding": "Current UI design-system logo points to src/logo.svg."
},
{
"url": "https://github.com/InKCre/ui/blob/cd434bf11eaeae0fe59e230008cb15c8a9f950f6/docs/design/visual-language.md",
"finding": "Current visual language describes a neutral black/white/gray framework, rectilinear shapes and a flat appearance."
},
{
"url": "https://github.com/InKCre/impl-swift/blob/main/D3LibMin/Assets.xcassets/AppIcon.appiconset/Contents.json",
"finding": "Swift app includes light and dark/tinted raster versions of the same mark. Inspected for corroboration only, not traced or used as source."
}
],
"excluded_reference": {
"url": "https://github.com/InKCre/impl-ts/blob/2d260e3f194ba34858243d41d19afa889a2d4060/apps/client-webext/assets/inkcre.svg",
"git_blob_sha": "70ec5a6c03584be8317dbb4bf3fd23e1ff8be2e8",
"reason": "Current extension still contains a traced-looking 200px asset with near-white rounded background, off-black tones and a detached gray speck; also identical to asset in archived client-webext. Excluded in favor of clean native web/UI sources. Not a claim that the extension stopped using it."
},
"derived_changes": [
"Preserve all source foreground coordinates, connector strokes and viewBox proportions.",
"Replace white nested-square knockout with a true even-odd transparent counter.",
"Provide original black/gray, reverse white/gray, solid black and solid white colorways.",
"Provide transparent canvases plus four contrasting white/black background combinations.",
"Select existing 32 geometry for logical sizes <=32 and existing 256 geometry for >=48. This threshold is a pack convention, not an independently verified official brand rule.",
"Retina exports select geometry by logical display size, not physical raster size."
]
}
30 changes: 30 additions & 0 deletions assets/logo/QA-report.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"status": "pass",
"checks": [
{
"test": "Three untouched source files match recorded Git blob SHA values",
"result": "pass"
},
{
"test": "All exported SVGs are native vector with even-odd counter; all PNG dimensions, alpha, margins and counter probes correct",
"result": "pass",
"assets_checked": 264
},
{
"test": "Original on white 32px pixel-identical to unmodified native source",
"result": "pass",
"max_channel_difference": 0
},
{
"test": "Original on white 256px pixel-identical to unmodified native source",
"result": "pass",
"max_channel_difference": 0
},
{
"test": "Geometry selected by logical display size, never by physical 2x/3x raster size",
"result": "pass"
}
],
"source_of_truth": "Original repository SVGs; no bitmap tracing or AI redrawing",
"manual_review": "Preview inspected separately before delivery"
}
Loading
Loading