ksk-design-system 1.49.0 → 1.49.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +1 -0
- package/CLAUDE.md +1 -0
- package/NATIVE_RECIPES.md +7 -0
- package/contracts/components.json +1 -1
- package/contracts/token-hex-cache.json +1 -1
- package/dist/index.js +4 -4
- package/dist/native/ui.js +435 -398
- package/dist/types/native/components/CardHeader.d.ts +13 -0
- package/dist/types/native/components/index.d.ts +1 -0
- package/package.json +3 -3
- package/src/components/COMPONENT_LOOKUP.md +1 -1
- package/src/native/COMPONENT_LOOKUP.md +2 -1
- package/src/styles/source-safelist.css +2 -0
package/AGENTS.md
CHANGED
|
@@ -35,6 +35,7 @@ UI を書く前に必ず確認すること:
|
|
|
35
35
|
- [ ] アイコンは `iconsax-reactjs` か(`lucide-react` / `heroicons` は使わない)
|
|
36
36
|
- [ ] 生タグ(`<button>` / `<input>` / `<a href>`)でなく DS コンポーネントを使ったか
|
|
37
37
|
- [ ] CSS でベンダープレフィックス併記する場合、**`-webkit-` を先・標準形を後**に書いたか(消費側の minifier が同一プロパティとして dedupe し後勝ちのみ残すため。逆順だと Firefox で静かに無効化。`node scripts/check-prefix-order.mjs` が CI で検出)
|
|
38
|
+
- [ ] flex 行(flex-col でない flex)で shrink-0 の兄弟と可変テキストを並べるとき、テキスト側に `flex-1`(+ 必要なら `min-w-[...]` 下限)を付けたか(`min-w-0` だけだと 1 文字ずつ折り返すまで潰れる。issue #293。`node scripts/check-flex-shrink.mjs` が CI で検出、例外は `ksk-lint-ignore KFX001 -- 理由`)
|
|
38
39
|
- [ ] クラス名は**完全な文字列**で書いたか(`` `bg-${color}` `` のような動的合成は静的抽出できず消費側で CSS が生成されない。分岐は三項演算子か cva variant で。`scripts/generate-source-safelist.mjs` が検出)
|
|
39
40
|
- [ ] `.tsx` 編集後に `bash scripts/lint-scratch.sh`、コンポーネント増減時は `npm run check` を実行したか
|
|
40
41
|
- [ ] `FormField` を import する前にどちらか確認したか(react-hook-form の Controller と統合するなら `RhfFormField`=`ui/form` の `FormField` を index.ts で別名 export したもの。単純な label+error 表示は `patterns/form-field` の `FormField`。迷ったら後者)
|
package/CLAUDE.md
CHANGED
|
@@ -35,6 +35,7 @@ UI を書く前に必ず確認すること:
|
|
|
35
35
|
- [ ] アイコンは `iconsax-reactjs` か(`lucide-react` / `heroicons` は使わない)
|
|
36
36
|
- [ ] 生タグ(`<button>` / `<input>` / `<a href>`)でなく DS コンポーネントを使ったか
|
|
37
37
|
- [ ] CSS でベンダープレフィックス併記する場合、**`-webkit-` を先・標準形を後**に書いたか(消費側の minifier が同一プロパティとして dedupe し後勝ちのみ残すため。逆順だと Firefox で静かに無効化。`node scripts/check-prefix-order.mjs` が CI で検出)
|
|
38
|
+
- [ ] flex 行(flex-col でない flex)で shrink-0 の兄弟と可変テキストを並べるとき、テキスト側に `flex-1`(+ 必要なら `min-w-[...]` 下限)を付けたか(`min-w-0` だけだと 1 文字ずつ折り返すまで潰れる。issue #293。`node scripts/check-flex-shrink.mjs` が CI で検出、例外は `ksk-lint-ignore KFX001 -- 理由`)
|
|
38
39
|
- [ ] クラス名は**完全な文字列**で書いたか(`` `bg-${color}` `` のような動的合成は静的抽出できず消費側で CSS が生成されない。分岐は三項演算子か cva variant で。`scripts/generate-source-safelist.mjs` が検出)
|
|
39
40
|
- [ ] `.tsx` 編集後に `bash scripts/lint-scratch.sh`、コンポーネント増減時は `npm run check` を実行したか
|
|
40
41
|
- [ ] `FormField` を import する前にどちらか確認したか(react-hook-form の Controller と統合するなら `RhfFormField`=`ui/form` の `FormField` を index.ts で別名 export したもの。単純な label+error 表示は `patterns/form-field` の `FormField`。迷ったら後者)
|
package/NATIVE_RECIPES.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
Native / Expo consumer は、新規 UI を作る前に `ksk-design-system/native/ui` の既存コンポーネントを確認してください。ローカル `ds/` に独自 wrapper を増やす前に、`src/native/COMPONENT_LOOKUP.md` とこのファイルの recipe を使います。
|
|
4
4
|
|
|
5
|
+
## Tailwind バージョンの前提
|
|
6
|
+
|
|
7
|
+
`tailwindcss` の peer 範囲は `^3.4.17 || ^4.1.0` です(issue #296)。
|
|
8
|
+
|
|
9
|
+
- **Web consumer**: `preset.css` が Tailwind v4 構文(`@import "tailwindcss"`)前提のため **v4 系が必須**。3 系はインストールできても preset が機能しません。
|
|
10
|
+
- **Expo / NativeWind consumer**: NativeWind のコンパイラ都合で `^3.4.x` に固定して構いません。`native/ui` entrypoint は Tailwind 4 の機能を要求しないため、この組み合わせが公式サポート範囲です。peer 範囲から 3 系を落とすと consumer の `npm install` が壊れるので、範囲は `__tests__/native-package-contract.test.ts` で契約として固定しています。
|
|
11
|
+
|
|
5
12
|
## Component lookup
|
|
6
13
|
|
|
7
14
|
RN 側の公開 export 一覧は `src/native/COMPONENT_LOOKUP.md` で確認できます。Web 側の `src/components/COMPONENT_LOOKUP.md` と同じく、consumer 実装前の DS-first チェックに使います。
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"meta": {
|
|
3
3
|
"name": "KSK Design System — Semantic Token Hex Cache",
|
|
4
|
-
"version": "1.49.
|
|
4
|
+
"version": "1.49.2",
|
|
5
5
|
"description": "semantic / semanticDark トークン(var(--Primitive-*) 参照)を実 hex に解決したサイドカー生成物。hex はデフォルト(Blue)テーマでの解決値であり、Brand 系(meta.themeDependentKeys に列挙)はテーマ差し替え(orange/green/violet 等)で実色が変わる。テーマ別の完全解決値は `ksk-design-system/native` エクスポート(バンドル済み native トークンモジュール)の themes を参照。tokens.json 本体のスキーマは変更せず、AI がこのファイルだけで実色を把握できるようにし、primitive 値の変更による semantic 実色のドリフトを --check で機械検出する。",
|
|
6
6
|
"generatedBy": "scripts/generate-token-hex-cache.mjs",
|
|
7
7
|
"theme": "default",
|
package/dist/index.js
CHANGED
|
@@ -14937,7 +14937,7 @@ function cp({ selectedCount: e, onClear: t, children: n, className: r, ...i }) {
|
|
|
14937
14937
|
}),
|
|
14938
14938
|
/* @__PURE__ */ V("div", { className: "h-5 w-px bg-[var(--Text-on-Inverse)]/20 shrink-0" }),
|
|
14939
14939
|
/* @__PURE__ */ V("div", {
|
|
14940
|
-
className: "flex items-center gap-2 min-w-0 overflow-x-auto [&>*]:shrink-0",
|
|
14940
|
+
className: "flex items-center gap-2 min-w-0 flex-1 overflow-x-auto [&>*]:shrink-0",
|
|
14941
14941
|
children: n
|
|
14942
14942
|
}),
|
|
14943
14943
|
t && /* @__PURE__ */ H(B, { children: [/* @__PURE__ */ V("div", { className: "h-5 w-px bg-[var(--Text-on-Inverse)]/20 shrink-0" }), /* @__PURE__ */ V("button", {
|
|
@@ -15391,12 +15391,12 @@ function yp({ className: e, icon: t, emoji: n, label: r, description: i, meta: a
|
|
|
15391
15391
|
label: "処理中"
|
|
15392
15392
|
})]
|
|
15393
15393
|
}), (i || a) && /* @__PURE__ */ H("span", {
|
|
15394
|
-
className: "flex w-full items-end justify-between gap-2",
|
|
15394
|
+
className: "flex w-full flex-wrap items-end justify-between gap-x-2 gap-y-1",
|
|
15395
15395
|
children: [i && /* @__PURE__ */ V("span", {
|
|
15396
|
-
className: "typo-body-sm min-w-
|
|
15396
|
+
className: "typo-body-sm min-w-[60%] flex-1 text-[var(--Text-Medium-Emphasis)]",
|
|
15397
15397
|
children: i
|
|
15398
15398
|
}), a && /* @__PURE__ */ V("span", {
|
|
15399
|
-
className: "typo-label-sm shrink-0 text-[var(--Text-Low-Emphasis)]",
|
|
15399
|
+
className: "typo-label-sm ml-auto shrink-0 text-[var(--Text-Low-Emphasis)]",
|
|
15400
15400
|
children: a
|
|
15401
15401
|
})]
|
|
15402
15402
|
})]
|