web-stylebook-mcp 0.17.0 → 0.18.1
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/README.ja.md +188 -0
- package/README.ko.md +4 -4
- package/README.md +1 -1
- package/dist/foundations/catalog.js +1 -1
- package/dist/foundations/interaction.js +2 -2
- package/dist/improvement/actions.js +2 -2
- package/dist/improvement/workflow.js +2 -2
- package/dist/server-info.d.ts +1 -1
- package/dist/server-info.js +1 -1
- package/dist/structure/guides/fusions.js +377 -352
- package/dist/structure/guides/styles.js +848 -831
- package/dist/visual-canonical/contrast.js +33 -9
- package/dist/visual-canonical/export.js +17 -5
- package/dist/visual-canonical/fontSources.d.ts +3 -0
- package/dist/visual-canonical/fontSources.js +227 -83
- package/dist/visual-canonical/hash.d.ts +6 -1
- package/dist/visual-canonical/hash.js +21 -6
- package/dist/visual-canonical/resolve.js +66 -17
- package/dist/visual-canonical/schema.js +154 -35
- package/dist/visual-canonical/types.d.ts +2 -2
- package/dist/visual-canonical/types.js +25 -1
- package/generated/catalog.v1.json +7802 -5582
- package/generated/manifest.v1.json +1 -1
- package/generated/visual-contract-source.v1.json +15 -8
- package/generated/visual-contracts.v1.json +4775 -4584
- package/package.json +3 -6
- package/skills/web-stylebook-design/references/example-result.json +2 -2
- package/dist/audit/check-scope.js.map +0 -1
- package/dist/audit/evaluator.js.map +0 -1
- package/dist/audit/planner.js.map +0 -1
- package/dist/audit/principle-verify.js.map +0 -1
- package/dist/audit/verdict.js.map +0 -1
- package/dist/catalog/repository.js.map +0 -1
- package/dist/catalog/stable-hash.js.map +0 -1
- package/dist/catalog/validate.js.map +0 -1
- package/dist/catalog/visual.js.map +0 -1
- package/dist/cli-tools.js.map +0 -1
- package/dist/cli.js.map +0 -1
- package/dist/design-principles/planner.js.map +0 -1
- package/dist/foundations/catalog.js.map +0 -1
- package/dist/foundations/color.js.map +0 -1
- package/dist/foundations/composition.js.map +0 -1
- package/dist/foundations/information.js.map +0 -1
- package/dist/foundations/interaction.js.map +0 -1
- package/dist/foundations/perception.js.map +0 -1
- package/dist/foundations/planner.js.map +0 -1
- package/dist/foundations/sources.js.map +0 -1
- package/dist/foundations/types.js.map +0 -1
- package/dist/foundations/typography.js.map +0 -1
- package/dist/improvement/actions.js.map +0 -1
- package/dist/improvement/evaluator.js.map +0 -1
- package/dist/improvement/render.js.map +0 -1
- package/dist/improvement/schema.js.map +0 -1
- package/dist/improvement/workflow.js.map +0 -1
- package/dist/localization.js.map +0 -1
- package/dist/principles/planner.js.map +0 -1
- package/dist/protocol/errors.js.map +0 -1
- package/dist/protocol/register-prompts.js.map +0 -1
- package/dist/protocol/register-resources.js.map +0 -1
- package/dist/protocol/register-tools.js.map +0 -1
- package/dist/protocol/result.js.map +0 -1
- package/dist/recommendation/compare.js.map +0 -1
- package/dist/recommendation/explain.js.map +0 -1
- package/dist/recommendation/index.js.map +0 -1
- package/dist/recommendation/lexicon.js.map +0 -1
- package/dist/recommendation/normalize-context.js.map +0 -1
- package/dist/recommendation/rank-reason.js.map +0 -1
- package/dist/recommendation/scoring.js.map +0 -1
- package/dist/recommendation/types.js.map +0 -1
- package/dist/references/search.js.map +0 -1
- package/dist/server-info.js.map +0 -1
- package/dist/server.js.map +0 -1
- package/dist/state-atlas/planner.js.map +0 -1
- package/dist/structure/audit.js.map +0 -1
- package/dist/structure/checks.js.map +0 -1
- package/dist/structure/detect.js.map +0 -1
- package/dist/structure/dom/cascade.js.map +0 -1
- package/dist/structure/dom/css.js.map +0 -1
- package/dist/structure/dom/html.js.map +0 -1
- package/dist/structure/dom/page.js.map +0 -1
- package/dist/structure/dom/selector.js.map +0 -1
- package/dist/structure/dom/tailwind.js.map +0 -1
- package/dist/structure/dom/values.js.map +0 -1
- package/dist/structure/guidance.js.map +0 -1
- package/dist/structure/guides/fusions.js.map +0 -1
- package/dist/structure/guides/index.js.map +0 -1
- package/dist/structure/guides/styles.js.map +0 -1
- package/dist/structure/must-have-detect.js.map +0 -1
- package/dist/structure/must-haves.js.map +0 -1
- package/dist/structure/patterns.js.map +0 -1
- package/dist/structure/revisions.js.map +0 -1
- package/dist/structure/rules.js.map +0 -1
- package/dist/structure/similarity.js.map +0 -1
- package/dist/structure/types.js.map +0 -1
- package/dist/structure/validate.js.map +0 -1
- package/dist/tokens/compile.js.map +0 -1
- package/dist/tokens/contrast.js.map +0 -1
- package/dist/tokens/design-md.js.map +0 -1
- package/dist/tokens/visual.js.map +0 -1
- package/dist/tokens/yaml.js.map +0 -1
- package/dist/types.js.map +0 -1
- package/dist/visual-canonical/contrast.js.map +0 -1
- package/dist/visual-canonical/export.js.map +0 -1
- package/dist/visual-canonical/fontSources.js.map +0 -1
- package/dist/visual-canonical/hash.js.map +0 -1
- package/dist/visual-canonical/resolve.js.map +0 -1
- package/dist/visual-canonical/schema.js.map +0 -1
- package/dist/visual-canonical/types.js.map +0 -1
- package/docs/reference.ko.md +0 -747
- package/docs/reference.md +0 -752
- package/docs/research/design-foundations.md +0 -126
package/README.ja.md
ADDED
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+
# web-stylebook-mcp
|
|
4
|
+
|
|
5
|
+
**コーディングエージェント向けのデザイン判断。今あるUIを改善し、その根拠を示します。**
|
|
6
|
+
|
|
7
|
+
[](https://www.npmjs.com/package/web-stylebook-mcp)
|
|
8
|
+
[](https://www.npmjs.com/package/web-stylebook-mcp)
|
|
9
|
+
[](./LICENSE)
|
|
10
|
+
[](https://nodejs.org)
|
|
11
|
+
[](https://modelcontextprotocol.io)
|
|
12
|
+
|
|
13
|
+
[English](./README.md) · [한국어](./README.ko.md) · **日本語**
|
|
14
|
+
|
|
15
|
+
</div>
|
|
16
|
+
|
|
17
|
+

|
|
18
|
+
|
|
19
|
+
<sub>左は一般的な生成スタイルで作成したサンプルのダッシュボードです。右は Claude Opus 5.5 が
|
|
20
|
+
`web-stylebook-design` スキルを1回実行し、人の手を加えずに改善した同じページです。データは架空のものです。
|
|
21
|
+
[作り方、計測した値、示していない内容 →](./docs/demo/README.ja.md)</sub>
|
|
22
|
+
|
|
23
|
+
- **デザインの知識を持っています。** 調査済みのデザイン原論 24 件(出典 30 件)、インターフェース原則 25 件、
|
|
24
|
+
UX 原則 23 件、ビジュアルの方向性 48 件、実在サイトの参考例 520 件を収録しています。各ルールには、いつ適用し、
|
|
25
|
+
いつ適用しないか、結果をどう確認するかが書かれています。
|
|
26
|
+
- **エージェントに最後までやり切らせます。** エージェントはページをキャプチャし、計画を立て、実際のソースを編集し、
|
|
27
|
+
再度キャプチャして比較します。`complete` になるのは、変更前後のキャプチャが揃い、リンクとテストフックが保たれ、
|
|
28
|
+
動作とアクセシビリティの確認が済んだ場合だけです。そうでなければ `needs-work` となり、不足している項目を一覧で示します。
|
|
29
|
+
- **ローカルで完結します。** API キーもモデル呼び出しもネットワークも不要で、プロジェクトのファイルは読みません。
|
|
30
|
+
同じ入力からは常に同じ出力が得られます。
|
|
31
|
+
|
|
32
|
+
## インストール
|
|
33
|
+
|
|
34
|
+
Node 20 以降が必要です。
|
|
35
|
+
|
|
36
|
+
### Cursor
|
|
37
|
+
|
|
38
|
+
ボタンを押してください。
|
|
39
|
+
|
|
40
|
+
[](https://cursor.com/install-mcp?name=web-stylebook&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIndlYi1zdHlsZWJvb2stbWNwQGxhdGVzdCJdfQ==)
|
|
41
|
+
|
|
42
|
+
ボタンを押すと Cursor のインストール用ディープリンクが開きます。Cursor が開かない場合は、次のディープリンクをブラウザに貼り付けてください。
|
|
43
|
+
|
|
44
|
+
```text
|
|
45
|
+
cursor://anysphere.cursor-deeplink/mcp/install?name=web-stylebook&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIndlYi1zdHlsZWJvb2stbWNwQGxhdGVzdCJdfQ==
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
または、プロジェクトの `.cursor/mcp.json` にサーバーを追加します(すべてのプロジェクトで使う場合は `~/.cursor/mcp.json`)。
|
|
49
|
+
|
|
50
|
+
```json
|
|
51
|
+
{
|
|
52
|
+
"mcpServers": {
|
|
53
|
+
"web-stylebook": {
|
|
54
|
+
"command": "npx",
|
|
55
|
+
"args": ["-y", "web-stylebook-mcp@latest"]
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### Claude Code
|
|
62
|
+
|
|
63
|
+
プラグインでスキルと MCP サーバーをまとめてインストールできます(Claude Code 2.1.275 以降)。
|
|
64
|
+
|
|
65
|
+
```text
|
|
66
|
+
/plugin install web-stylebook --marketplace seungdori/web-stylebook-mcp
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
MCP サーバーだけを使う場合は、次のコマンドを実行します。
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
claude mcp add web-stylebook -- npx -y web-stylebook-mcp@latest
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
このコマンドは、現在のプロジェクトで自分だけがサーバーを使えるようにします。すべてのプロジェクトで使うには `add` の後ろに `--scope user` を付けます。チームで共有するには `--scope project` を付けます。その場合、Claude Code がプロジェクトルートの `.mcp.json` に書き込みます。このファイルを直接書いてもかまいません。
|
|
76
|
+
|
|
77
|
+
```json
|
|
78
|
+
{
|
|
79
|
+
"mcpServers": {
|
|
80
|
+
"web-stylebook": {
|
|
81
|
+
"type": "stdio",
|
|
82
|
+
"command": "npx",
|
|
83
|
+
"args": ["-y", "web-stylebook-mcp@latest"]
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
Claude Code は `.mcp.json` のサーバーを使う前に、利用者ごとに一度承認を求めます。`claude mcp list` で、サーバーに接続できたかを確認できます。
|
|
90
|
+
|
|
91
|
+
### Codex
|
|
92
|
+
|
|
93
|
+
```bash
|
|
94
|
+
codex mcp add web-stylebook -- npx -y web-stylebook-mcp@latest
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
このコマンドは `~/.codex/config.toml` にサーバーを追加します。このファイルに次の行を直接書いてもかまいません。
|
|
98
|
+
|
|
99
|
+
```toml
|
|
100
|
+
[mcp_servers.web-stylebook]
|
|
101
|
+
command = "npx"
|
|
102
|
+
args = ["-y", "web-stylebook-mcp@latest"]
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### VS Code
|
|
106
|
+
|
|
107
|
+
VS Code の GitHub Copilot では、ボタンを押してください。
|
|
108
|
+
|
|
109
|
+
[](https://vscode.dev/redirect?url=vscode%3Amcp%2Finstall%3F%257B%2522name%2522%253A%2522web-stylebook%2522%252C%2522command%2522%253A%2522npx%2522%252C%2522args%2522%253A%255B%2522-y%2522%252C%2522web-stylebook-mcp%2540latest%2522%255D%257D)
|
|
110
|
+
|
|
111
|
+
VS Code がサーバーのページを開きます。インストールする前に、そのページでコマンドを確認してください。
|
|
112
|
+
|
|
113
|
+
または、ワークスペースのルートにある `.mcp.json` にサーバーを追加します。Claude Code が読むファイルと同じです。すべてのワークスペースで使うには `~/.copilot/mcp-config.json` に追加します。
|
|
114
|
+
|
|
115
|
+
```json
|
|
116
|
+
{
|
|
117
|
+
"mcpServers": {
|
|
118
|
+
"web-stylebook": {
|
|
119
|
+
"type": "stdio",
|
|
120
|
+
"command": "npx",
|
|
121
|
+
"args": ["-y", "web-stylebook-mcp@latest"]
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
信頼されたワークスペースでは、VS Code は `.mcp.json` のサーバーを追加の確認なしに起動します。コマンドパレットの **MCP: List Servers** で、サーバーを確認できます。古いガイドには `servers` キーを持つ `.vscode/mcp.json` が出てきますが、VS Code はこの形式を廃止予定として扱っています。
|
|
128
|
+
|
|
129
|
+
### スキルとその他のクライアント
|
|
130
|
+
|
|
131
|
+
スキルに対応したエージェント(Claude Code、Codex、Cursor など)は、スキルをインストールできます。`npx skills` には Node 22.20 以降が必要です。
|
|
132
|
+
|
|
133
|
+
```bash
|
|
134
|
+
npx skills add seungdori/web-stylebook-mcp
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
Windsurf と Claude Desktop の設定は[リファレンス](./docs/reference.ja.md#インストール)にあります。
|
|
138
|
+
|
|
139
|
+
## 使い方
|
|
140
|
+
|
|
141
|
+
既存の画面の改善を依頼します。
|
|
142
|
+
|
|
143
|
+
> ダッシュボードを改善して、オンコール担当者が問題のある箇所を真っ先に確認できるようにしてください。
|
|
144
|
+
|
|
145
|
+
エージェントはページをキャプチャして `get_design_improvement_plan` を呼び出します。次にコードを編集し、
|
|
146
|
+
`compare_page_revisions` で既存の要素が保たれたかを確認したうえで、`validate_design_improvement_result` で締めくくります。
|
|
147
|
+
変更前後のスクリーンショット、変更ごとの理由、実行した確認、未検証の項目が得られます。
|
|
148
|
+
|
|
149
|
+
新しいページの場合は、代わりに製品を説明してください。例えば *「決済 API のランディングページ」* のように書きます。
|
|
150
|
+
エージェントは `recommend_design_direction` から始め、順位を付けた候補と、除外した候補および除外の理由を示します。
|
|
151
|
+
|
|
152
|
+
レビューだけを依頼した場合、エージェントは点検して報告するだけで、何も編集しません。
|
|
153
|
+
|
|
154
|
+
## MCP なしで使う
|
|
155
|
+
|
|
156
|
+
スキルは MCP サーバーがなくても動作します。同じツールをシェルから実行すれば、同じ結果が得られます。
|
|
157
|
+
|
|
158
|
+
```bash
|
|
159
|
+
npx -y web-stylebook-mcp tools
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
npx -y web-stylebook-mcp call get_design_improvement_plan --input plan-args.json
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
## ツール
|
|
167
|
+
|
|
168
|
+
| 用途 | ツール |
|
|
169
|
+
|---|---|
|
|
170
|
+
| 既存 UI の改善 | `get_design_improvement_plan`, `compare_page_revisions`, `validate_design_improvement_result` |
|
|
171
|
+
| レビュー | `get_design_audit_plan`, `audit_page_structure`, `validate_design_audit_result` |
|
|
172
|
+
| 方向性の選択 | `recommend_design_direction`, `compare_design_directions`, `search_design_references`, `get_design_reference` |
|
|
173
|
+
| 原則と状態 | `get_design_principle_plan`, `get_ux_principle_plan`, `get_ui_state_plan` |
|
|
174
|
+
| 実装 | `compose_design_tokens`(JSON、CSS 変数、Tailwind、TypeScript、DESIGN.md) |
|
|
175
|
+
|
|
176
|
+
ツールごとの例、結果の契約、リソース、プロンプト、CLI は[リファレンス](./docs/reference.ja.md)にあります。
|
|
177
|
+
|
|
178
|
+
## 詳しく見る
|
|
179
|
+
|
|
180
|
+
- [リファレンス](./docs/reference.ja.md): ツールの例、契約、CLI、互換性
|
|
181
|
+
- [デモ](./docs/demo/README.ja.md): 上記の変更前後の比較と、すべての証拠ファイル
|
|
182
|
+
- [MCP あり・なしの比較](./showcase/README.ja.md): 10 組のペアによる作例、ブラインド比較、記録された結果
|
|
183
|
+
- [変更履歴](./CHANGELOG.md) · [セキュリティ](./SECURITY.md) · [リリース](./RELEASING.md)
|
|
184
|
+
|
|
185
|
+
## ライセンス
|
|
186
|
+
|
|
187
|
+
[MIT](./LICENSE)。コードと同梱のカタログスナップショットに適用されます。webstylebook.com のウェブサイト自体は
|
|
188
|
+
CC BY-NC です。帰属表示の詳細は[リファレンス](./docs/reference.ja.md#ライセンス)にあります。
|
package/README.ko.md
CHANGED
|
@@ -10,15 +10,15 @@
|
|
|
10
10
|
[](https://nodejs.org)
|
|
11
11
|
[](https://modelcontextprotocol.io)
|
|
12
12
|
|
|
13
|
-
[English](./README.md) · **한국어**
|
|
13
|
+
[English](./README.md) · **한국어** · [日本語](./README.ja.md)
|
|
14
14
|
|
|
15
15
|
</div>
|
|
16
16
|
|
|
17
|
-

|
|
18
18
|
|
|
19
19
|
<sub>왼쪽은 흔한 AI 생성 스타일로 작성한 예시 대시보드입니다. 오른쪽은 Claude Opus 5.5가
|
|
20
20
|
`web-stylebook-design` 스킬을 한 번 따라 고친 같은 페이지이며, 사람이 손대지 않았습니다. 데이터는
|
|
21
|
-
가상입니다. [만든 방법, 측정한 값, 보여 주지 않는 것 →](./docs/demo/README.md)</sub>
|
|
21
|
+
가상입니다. [만든 방법, 측정한 값, 보여 주지 않는 것 →](./docs/demo/README.ko.md)</sub>
|
|
22
22
|
|
|
23
23
|
- **디자인 지식이 들어 있습니다.** 조사된 디자인 원론 24개(출처 30개), 인터페이스 원칙 25개, UX
|
|
24
24
|
원칙 23개, 시각 방향 48개, 실제 사이트 레퍼런스 520개를 담고 있습니다. 규칙마다 언제 적용하고
|
|
@@ -187,7 +187,7 @@ npx -y web-stylebook-mcp call get_design_improvement_plan --input plan-args.json
|
|
|
187
187
|
## 더 보기
|
|
188
188
|
|
|
189
189
|
- [레퍼런스](./docs/reference.ko.md): 툴 예시, 계약, CLI, 호환성
|
|
190
|
-
- [데모](./docs/demo/README.md): 위 전후 비교와 모든 증거 파일(영문)
|
|
190
|
+
- [데모](./docs/demo/README.ko.md): 위 전후 비교와 모든 증거 파일(증거 파일은 영문)
|
|
191
191
|
- [MCP 사용·미사용 비교](./showcase/README.ko.md): 브리프 10개의 비교 화면과 실험 기록
|
|
192
192
|
- [변경 기록](./CHANGELOG.md) · [보안](./SECURITY.md) · [릴리스](./RELEASING.md)
|
|
193
193
|
|
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
[](https://nodejs.org)
|
|
11
11
|
[](https://modelcontextprotocol.io)
|
|
12
12
|
|
|
13
|
-
**English** · [한국어](./README.ko.md)
|
|
13
|
+
**English** · [한국어](./README.ko.md) · [日本語](./README.ja.md)
|
|
14
14
|
|
|
15
15
|
</div>
|
|
16
16
|
|
|
@@ -16,7 +16,7 @@ export const IMPROVEMENT_PROTOCOL = {
|
|
|
16
16
|
purpose: L('Use the knowledge to implement justified improvements, compare the result, and report completed changes. A retrieved plan is not an inspection or proof of improvement.', '이 지식으로 근거 있는 개선을 구현하고 결과를 비교한 뒤 완료한 변경을 보고하세요. 조회한 계획은 실제 점검이나 개선의 증거가 아닙니다.', 'この知識で根拠ある改善を実装し、結果を比較して完了した変更を報告します。取得した計画は実検査や改善の証拠ではありません。'),
|
|
17
17
|
evidenceBoundary: L('Sources support the stated concepts. Decision rules and examples are independently authored applications, not experimentally validated universal laws. W3C Understanding pages explain criteria; apply the normative criterion, level and exceptions when claiming conformance.', '출처는 명시한 개념을 뒷받침합니다. 판단 규칙과 예시는 독립 작성한 적용 지침이며 실험 검증된 보편 법칙이 아닙니다. W3C Understanding은 기준 해설이므로 준수를 주장할 때 규범적 기준·등급·예외를 적용하세요.', '出典は記載した概念を支えます。判断規則と例は独自の応用指針で、実験で検証された普遍法則ではありません。W3C Understandingは解説であり、適合主張には規範的基準、レベル、例外を適用します。'),
|
|
18
18
|
decisionOrder: [
|
|
19
|
-
L('Identify the user task, existing intent and observed obstacle before choosing a remedy. Preserve well-working design and product identity.', '수정법을 고르기 전에 사용자 과업·기존 의도·관찰된 문제를 정하고 잘 작동하는 디자인과 제품 정체성을 보존하세요.', '
|
|
19
|
+
L('Identify the user task, existing intent and observed obstacle before choosing a remedy. Preserve well-working design and product identity.', '수정법을 고르기 전에 사용자 과업·기존 의도·관찰된 문제를 정하고 잘 작동하는 디자인과 제품 정체성을 보존하세요.', '修正前に利用者の課題、既存意図、観察した問題を定め、機能するデザインと製品の個性を保ちます。'),
|
|
20
20
|
L('Check conditions and counterexamples; fix content/interaction/structure before polishing tokens where those are the cause. Address access, task failure and truthful consequences before aesthetic preferences.', '조건과 반례를 확인하고 내용·동작·구조가 원인이면 토큰 미화보다 먼저 고치세요. 접근성·과업 실패·정확한 결과 전달을 미적 취향보다 우선하세요.', '条件と反例を確認し、内容、動作、構造が原因ならトークンの装飾より先に直します。アクセス、課題失敗、正確な結果伝達を美的好みより優先します。'),
|
|
21
21
|
L('Make a coherent reversible change, verify it, then keep, revise or revert. Do not force a catalog style or diagnose an AI origin from appearance.', '일관되고 되돌릴 수 있는 변경을 만들고 검증한 뒤 유지·재수정·복구하세요. 카탈로그 스타일을 강제하거나 외형으로 AI 제작 여부를 판정하지 마세요.', '一貫した戻せる変更を作り検証後に維持、再修正、復元します。カタログ様式を強制したり外観からAI制作を判定しません。'),
|
|
22
22
|
],
|
|
@@ -38,7 +38,7 @@ export const INTERACTION_FOUNDATIONS = [
|
|
|
38
38
|
concerns: ['resilience', 'accessibility', 'readability'], surfaces: ['form', 'checkout', 'settings', 'chat', 'developer-console'], relatedPrincipleIds: ['recoverable-actions', 'complete-state-model'], sourceIds: ['validation', 'heuristics'],
|
|
39
39
|
observe: [L('Follow invalid input, failed submission, cancel and retry; note whether the original data or consequences become unclear.', '잘못된 입력·제출 실패·취소·재시도를 따라가며 원본 데이터나 결과가 불명확해지는지 보세요.', '無効入力、送信失敗、取消、再試行を追い、元データや結果が不明になるか確認します。')],
|
|
40
40
|
decisions: [
|
|
41
|
-
{ when: L('A failed form clears input or leaves errors far from their fields.', '폼 실패가 입력을 지우거나 오류를 필드에서 멀리 둡니다.', 'フォーム失敗で入力を消すか、エラーが欄から離れています。'), change: L('Retain answers, associate field errors, and provide a summary/navigation when needed.', '답을 유지하고 필드 오류를 연결하며 필요할 때 요약·이동 수단을 제공하세요.', '回答を保ち欄エラーを関連付け、必要に応じ概要や移動手段を提供します。'), instead: L('Do not blame invalid input for a service outage, permission failure or unknown submission result.', '서비스
|
|
41
|
+
{ when: L('A failed form clears input or leaves errors far from their fields.', '폼 실패가 입력을 지우거나 오류를 필드에서 멀리 둡니다.', 'フォーム失敗で入力を消すか、エラーが欄から離れています。'), change: L('Retain answers, associate field errors, and provide a summary/navigation when needed.', '답을 유지하고 필드 오류를 연결하며 필요할 때 요약·이동 수단을 제공하세요.', '回答を保ち欄エラーを関連付け、必要に応じ概要や移動手段を提供します。'), instead: L('Do not blame invalid input for a service outage, permission failure or unknown submission result.', '서비스 중단·권한 문제·불명확한 제출 결과를 잘못된 입력 탓으로 돌리지 마세요.', 'サービス停止、権限、送信結果不明を入力ミスのせいにしません。') },
|
|
42
42
|
{ when: L('A costly action is easy to trigger and hard to reverse.', '결과가 큰 행동을 쉽게 실행하고 되돌리기는 어렵습니다.', '重大な操作を簡単に実行でき、戻すのは困難です。'), change: L('Expose consequences and scope; use undo when real, or a proportionate confirmation before commitment.', '결과와 범위를 드러내고 실제 가능한 되돌리기나 실행 전 적절한 확인을 제공하세요.', '結果と範囲を示し、実際に可能な取消か実行前の相応な確認を提供します。'), instead: L('Do not add confirmations to every harmless action or blindly retry an uncertain transaction.', '무해한 모든 행동에 확인을 추가하거나 결과가 불명확한 거래를 무조건 재시도하지 마세요.', '無害な全操作に確認を追加したり、結果不明な取引を盲目的に再試行しません。') },
|
|
43
43
|
],
|
|
44
44
|
preserve: L('Retain input, user control and honest distinctions between failed, pending and completed work.', '입력·사용자 통제·실패와 대기와 완료의 정확한 구별을 보존하세요.', '入力、利用者の制御、失敗と保留と完了の正確な区別を保ちます。'),
|
|
@@ -84,7 +84,7 @@ export const INTERACTION_FOUNDATIONS = [
|
|
|
84
84
|
id: 'comparative-iteration', category: 'evaluation', name: L('Improve through comparable evidence', '비교 가능한 근거로 개선하기', '比較できる根拠で改善する'),
|
|
85
85
|
principle: L('A visual preference is a hypothesis; improvement needs a stated goal, matched observations and preserved functionality.', '시각적 선호는 가설입니다. 개선에는 명시한 목표·조건을 맞춘 관찰·기능 보존이 필요합니다.', '視覚的な好みは仮説です。改善には明示した目標、条件を揃えた観察、機能の保持が必要です。'),
|
|
86
86
|
concerns: ['resilience', 'consistency'], surfaces: ['global'], relatedPrincipleIds: ['fidelity-follows-certainty'], sourceIds: ['user-testing'],
|
|
87
|
-
observe: [L('Record the task, suspected obstacle, baseline state, data and uncertainty before choosing a change. Name the baseline strengths that must survive and the concrete gain expected from each edit. Include keeping the original as an alternative.', '변경을 고르기 전에 과업·의심 문제·기준 상태·데이터·불확실성을 기록하세요. 유지해야 할 원본의 장점과 각 수정으로 얻을 구체적 이득을 적고 원본 유지도 대안에 포함하세요.', '
|
|
87
|
+
observe: [L('Record the task, suspected obstacle, baseline state, data and uncertainty before choosing a change. Name the baseline strengths that must survive and the concrete gain expected from each edit. Include keeping the original as an alternative.', '변경을 고르기 전에 과업·의심 문제·기준 상태·데이터·불확실성을 기록하세요. 유지해야 할 원본의 장점과 각 수정으로 얻을 구체적 이득을 적고 원본 유지도 대안에 포함하세요.', '変更前に課題、疑わしい問題、基準状態、データ、不確実性を記録します。守るべき原本の長所と各編集の具体的な利点を挙げ、原本維持も選択肢に含めます。')],
|
|
88
88
|
decisions: [
|
|
89
89
|
{ when: L('The cause of awkwardness is uncertain.', '어색함의 원인이 불확실합니다.', '違和感の原因が不確かです。'), change: L('Change one coherent relationship and compare a small reversible alternative before widening scope.', '하나의 일관된 관계를 고치고 작은 되돌릴 수 있는 대안을 비교한 뒤 범위를 넓히세요.', '一つの一貫した関係を直し、小さな戻せる代案を比較してから範囲を広げます。'), instead: L('Do not replace the whole visual identity merely to create an obvious difference.', '눈에 띄는 차이를 만들려고 시각 정체성 전체를 바꾸지 마세요.', '目立つ差を作るためだけに視覚的な個性全体を変えません。') },
|
|
90
90
|
{ when: L('The revised screenshot looks cleaner but evidence is incomplete.', '수정 스크린샷은 깔끔하지만 근거가 부족합니다.', '修正画像は整っていますが根拠が不十分です。'), change: L('Repeat the real task and edge states; retain, revise or revert based on observed effects.', '실제 과업과 경계 상태를 반복하고 관찰된 효과에 따라 유지·재수정·복구하세요.', '実課題と境界状態を繰り返し、観察結果で維持、再修正、復元を選びます。'), instead: L('Do not claim measured user improvement, a design score or conformance without the corresponding evidence.', '해당 근거 없이 사용자 개선 측정값·디자인 점수·표준 준수를 주장하지 마세요.', '対応する根拠なしに利用改善の測定値、デザイン点数、規格適合を主張しません。') },
|
|
@@ -4,7 +4,7 @@ const actions = {
|
|
|
4
4
|
plan: ['원래 대상 범위를 보존하고 정확한 계획 입력의 workflow.planHash를 사용하세요.', '元の対象範囲を保ち、正確な計画入力のworkflow.planHashを使ってください。'],
|
|
5
5
|
identity: ['대상·캡처·변경·검사 ID와 참조를 확인하고 중복이나 다른 대상의 참조를 바로잡으세요.', '対象・画像・変更・検査のIDと参照を確認し、重複や別対象の参照を修正してください。'],
|
|
6
6
|
knowledge: ['실제 디자인 원론을 조회하고 관찰한 문제와 조건에 맞는 수정법을 연결하세요.', '実際のデザイン知識を取得し、観察した問題と条件に合う修正を結び付けてください。'],
|
|
7
|
-
implement: ['실제 소스를 수정하고 변경 파일과 diff를 저장하세요. 제안이나 가상 이미지는 구현 증거가 아닙니다. 접근할 수 없다면 구체적인
|
|
7
|
+
implement: ['실제 소스를 수정하고 변경 파일과 diff를 저장하세요. 제안이나 가상 이미지는 구현 증거가 아닙니다. 접근할 수 없다면 작업을 막는 구체적인 문제를 보고하세요.', '実ソースを修正し、変更ファイルと差分を保存してください。提案や仮画像は実装証拠ではありません。アクセス不可なら作業を妨げる具体的な問題を報告してください。'],
|
|
8
8
|
outcome: ['이 대상에 영향을 준 모든 변경과 실제 관찰 결과를 보고하세요. 확인하지 못한 항목은 미검증으로 남기세요.', 'この対象に影響する全変更と実際の観察結果を報告し、未確認事項は未検証として残してください。'],
|
|
9
9
|
repair: ['실패하거나 퇴행한 변경을 고치거나 되돌린 뒤 해당 대상을 다시 캡처하고 검증하세요.', '失敗・退行した変更を修復または戻してから、対象を再記録・再検証してください。'],
|
|
10
10
|
capture: ['불변의 수정 전 원본과 실제 수정 후 화면을 각각 확보하세요. 원본이 없다면 버전 관리에서 분리 복구하고, 수정 후 이미지를 원본처럼 꾸미지 마세요.', '変更前の不変原本と実際の変更後画面を別々に保存してください。原本がなければ版管理から分離復元し、変更後画像を原本と偽らないでください。'],
|
|
@@ -15,7 +15,7 @@ const actions = {
|
|
|
15
15
|
checks: ['계획 조건에 맞고 폰트 로딩이 끝난 수정 후 화면에서 검사를 수행하고 조작 단계·결과 증거를 저장하세요. 시각·보존 검사는 결과에 연결한 전후 캡처를 모두 참조해야 합니다. 근거 없는 통과 판정은 미검증입니다.', '計画条件と一致しフォント読込済みの変更後画面で検査し、操作手順と結果証拠を保存してください。視覚・保存検査は結果の前後両画像を参照します。根拠のない合格は未検証です。'],
|
|
16
16
|
applicable: ['정적 UI에서도 시각 비교·내용 보존·관련 접근성 검사는 수행하세요.', '静的UIでも視覚比較・内容保存・関連アクセシビリティ検査は実行してください。'],
|
|
17
17
|
method: ['동작과 접근성은 브라우저에서 조작하거나 참여자로 관찰하고, 시각은 캡처로 비교한 뒤 다시 기록하세요. 정적 검사나 검토만으로는 보여 주지 못합니다.', '操作とアクセシビリティはブラウザでの操作か参加者の観察で、視覚は画像比較で確認し直して記録してください。静的検査やレビューだけでは示せません。'],
|
|
18
|
-
claim: ['관찰한
|
|
18
|
+
claim: ['관찰한 과업의 문제를 밝히거나, 스타일 선호뿐인 변경은 변화 없음으로 보고하세요.', '観察したタスク上の問題を示すか、スタイルの好みだけの変更は変化なしとして報告してください。'],
|
|
19
19
|
criterion: ['어떤 조건에서 무엇이 바뀌면 개선인지 성공 기준을 적고 그 기준을 확인하세요.', 'どの条件で何が変われば改善かという成功条件を書き、その条件を確認してください。'],
|
|
20
20
|
reassess: ['수정법과 증거를 다시 판단하세요. 개선을 확인하지 못한 불필요한 변경은 고치거나 되돌리고 개선 효과를 꾸며내지 마세요.', '修正方法と証拠を再評価してください。改善を確認できない不要な変更は修復または戻し、効果を捏造しないでください。'],
|
|
21
21
|
};
|
|
@@ -12,7 +12,7 @@ const stages = [
|
|
|
12
12
|
},
|
|
13
13
|
{
|
|
14
14
|
id: 'decide',
|
|
15
|
-
instruction: L('Use the selected foundations to connect an observed task obstacle to a conditional remedy and an observable success check. Record baseline strengths in context.constraints and compare each gain against losses in group membership, useful visible information, continuity and reading comfort. Keep the original as a valid alternative. Consider counterexamples, working behavior and product identity. Prioritize task completion, information hierarchy and legibility before decoration. Do not force a new style, wider spacing, fewer cards or a font change without evidence. Retrieve omitted relevant foundations as needed.', '선택된 디자인 지식으로 관찰한
|
|
15
|
+
instruction: L('Use the selected foundations to connect an observed task obstacle to a conditional remedy and an observable success check. Record baseline strengths in context.constraints and compare each gain against losses in group membership, useful visible information, continuity and reading comfort. Keep the original as a valid alternative. Consider counterexamples, working behavior and product identity. Prioritize task completion, information hierarchy and legibility before decoration. Do not force a new style, wider spacing, fewer cards or a font change without evidence. Retrieve omitted relevant foundations as needed.', '선택된 디자인 지식으로 관찰한 과업의 문제, 조건에 맞는 수정, 확인할 성공 기준을 연결합니다. 원본의 장점을 context.constraints에 기록하고 이득과 그룹 구분·실제로 보이는 정보·연속성·읽기 편안함의 손실을 비교합니다. 원본 유지도 대안에 포함합니다. 반례·정상 동작·제품 정체성을 고려하고 장식보다 과업 완수·정보 위계·읽기를 우선합니다. 근거 없이 새 스타일·넓은 여백·카드 제거·폰트 교체를 강요하지 않습니다. 누락된 관련 지식은 추가 조회합니다.', '選んだ知識から観察した問題、条件に合う修正、確認可能な成功条件を結びます。原本の長所をcontext.constraintsに記録し、利点と所属、見える情報、連続性、読み心地の損失を比較します。原本維持も選択肢とします。反例、正常動作、製品らしさを考慮し、装飾よりタスク完了、情報階層、可読性を優先します。根拠なく新スタイル、余白拡大、カード削除、書体変更を強いません。必要な未取得知識を追加取得します。'),
|
|
16
16
|
tools: ['get_design_improvement_plan', 'get_design_principle_plan', 'get_ux_principle_plan', 'get_ui_state_plan'],
|
|
17
17
|
},
|
|
18
18
|
{
|
|
@@ -27,7 +27,7 @@ const stages = [
|
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
29
|
id: 'report',
|
|
30
|
-
instruction: L('Call validate_design_improvement_result with this plan query and workflow.planHash, actual captures, implemented changes, observed checks, per-target outcomes and limitations. Follow nextActions until in-scope work is done or a concrete blocker remains. Deliver the before/after artifact links, what changed and why, measured or expert-observed differences, verification, tradeoffs and remaining unverified work. A side-by-side or toggle viewer helps when many screenshots are involved. Never invent scores, time savings or user-study results. complete describes submitted evidence coverage, not an independent quality certification; no-change must never be marketed as an improvement.', '이 계획 입력과 workflow.planHash, 실제 캡처·구현된 변경·관찰한 검사·대상별 결과·한계를 validate_design_improvement_result에 제출합니다. 범위 안의 작업을 끝내거나 구체적인
|
|
30
|
+
instruction: L('Call validate_design_improvement_result with this plan query and workflow.planHash, actual captures, implemented changes, observed checks, per-target outcomes and limitations. Follow nextActions until in-scope work is done or a concrete blocker remains. Deliver the before/after artifact links, what changed and why, measured or expert-observed differences, verification, tradeoffs and remaining unverified work. A side-by-side or toggle viewer helps when many screenshots are involved. Never invent scores, time savings or user-study results. complete describes submitted evidence coverage, not an independent quality certification; no-change must never be marketed as an improvement.', '이 계획 입력과 workflow.planHash, 실제 캡처·구현된 변경·관찰한 검사·대상별 결과·한계를 validate_design_improvement_result에 제출합니다. 범위 안의 작업을 끝내거나 작업을 막는 구체적인 문제가 남을 때까지 nextActions를 수행합니다. 전후 이미지 링크, 무엇을 왜 고쳤는지, 측정 또는 전문가 관찰 차이, 검증·상충점·미검증 항목을 보고합니다. 이미지가 많으면 나란히 보기나 전환형 보고서가 유용합니다. 점수·시간 절감·사용자 조사 결과를 꾸며내지 않습니다. complete는 제출 증거의 충족 상태이며 독립적 품질 인증이 아닙니다. no-change를 개선했다고 표현하지 않습니다.', 'この計画入力とworkflow.planHash、実画像、実装変更、観察した検査、対象別結果、制約をvalidate_design_improvement_resultへ提出します。範囲内作業を完了するか作業を妨げる具体的な問題が残るまでnextActionsを実行します。前後画像、何をなぜ変更したか、測定または専門家観察による差、検証、トレードオフ、未検証事項を報告します。画像が多ければ並列・切替表示が便利です。点数、時間短縮、利用者調査を捏造しません。completeは提出証拠の充足であり独立品質認証ではなく、no-changeを改善と呼びません。'),
|
|
31
31
|
tools: ['validate_design_improvement_result'],
|
|
32
32
|
},
|
|
33
33
|
];
|
package/dist/server-info.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const SERVER_NAME = "web-stylebook";
|
|
2
|
-
export declare const SERVER_VERSION = "0.
|
|
2
|
+
export declare const SERVER_VERSION = "0.18.1";
|
|
3
3
|
export declare const SERVER_INSTRUCTIONS: string;
|
|
4
4
|
export declare const TOOL_NAMES: readonly ["recommend_design_direction", "compare_design_directions", "search_design_references", "get_design_reference", "get_design_principle_plan", "get_design_improvement_plan", "validate_design_improvement_result", "get_ux_principle_plan", "get_design_audit_plan", "validate_design_audit_result", "get_ui_state_plan", "compose_design_tokens", "audit_page_structure", "compare_page_revisions"];
|
|
5
5
|
export declare const PROMPT_NAMES: readonly ["improve-ui", "design-product", "design-screen", "complete-ui-states", "redesign-with-style", "audit-design-direction", "audit-design-principles", "audit-ux-principles"];
|
package/dist/server-info.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export const SERVER_NAME = 'web-stylebook';
|
|
2
|
-
export const SERVER_VERSION = '0.
|
|
2
|
+
export const SERVER_VERSION = '0.18.1';
|
|
3
3
|
export const SERVER_INSTRUCTIONS = [
|
|
4
4
|
'For an existing UI improvement request, default to implementation, verification and a before/after report. Use get_design_improvement_plan first, with context containing the actual user task and observed target conditions; its workflow is the default execution contract. Preserve an immutable before capture, decide with conditional design foundations and counterexamples, edit the real source using host tools, render matched after states and test affected behavior, accessibility and preservation. Call validate_design_improvement_result with the exact plan query, workflow.planHash and actual implementation/capture/check evidence. Follow nextActions for needs-work; proposals, missing evidence, mismatched conditions and regressions cannot complete an improvement. Report actual before/after artifacts, changes and reasons, verification, tradeoffs and unverified work. complete is submitted evidence coverage, not independent quality certification; no-change is never an improvement claim. A review or explanation alone is not completion unless the human explicitly requested review only. Honor explicit read-only or narrower scope. Infer a bounded scope from the task and inspect available source before asking; ask only for missing information that materially blocks execution, never for routine reapproval. Commit, push, release and deployment remain separate authorizations. Keep working behavior and product identity, and do not require a new catalog style or new-direction approval for existing-UI fixes. Record baseline strengths and compare gains against losses in grouping, visible information, continuity and reading comfort. Keep the original when benefits are unsupported; user feedback that identifies a regression reopens prior improvement claims and requires correcting the report. Familiar visual patterns are investigation cues, not automatic defects or proof of AI authorship. Source-supported concepts and authored remedies remain distinct. The host performs edits and captures; this offline MCP cannot access the project. These existing-UI instructions take precedence over the new-direction workflow below.',
|
|
5
5
|
'Use Web Stylebook before implementing or redesigning UI. Explicit audit-only requests remain read-only and use get_design_audit_plan and validate_design_audit_result. For a genuinely new visual direction, start with recommend_design_direction using product context, then read webstylebook://styles/{id}. Use search_design_references to find a small set of relevant real-world examples and get_design_reference for only the selected entries; treat their observations and tokens as attributed research evidence, not permission to copy or redistribute screenshots, brand assets, copy, typefaces, or visual identity. Then call get_design_principle_plan for the layout concerns/surface/phase, call get_ux_principle_plan for the task outcomes/surface/phase, call get_ui_state_plan for each surface, and compose_design_tokens for tokens. Prefer the pinned visual contract path: pass contract.schema from manifest.visualContract.contractSchema and optionally its contentHash plus the selected style revision; omit colorMode for the authored native mode and carry the website editor overrides. Keep the complete visualContract companion when delivering CSS or a theme. Calls without contract keep the legacy token shape: shadows follow the pinned visual contract, and editorial or monospace-led styles use authored font families. Other fields remain family-derived starting points. After implementation call get_design_audit_plan and inspect the actual rendered/code/interaction evidence for every included check; missing evidence is NOT_VERIFIED, never PASS. Submit the plan query, target matrix, evidence references, and one result per check/target to validate_design_audit_result before claiming completion; its valid field describes contract validity, not visual quality. A direction changes structure, not just tokens: build from candidate.structure (layout archetype and signature moves), then run audit_page_structure on the built page’s HTML and CSS with the chosen styleId, replace every finding with the move it names, and include the "structure" audit group when validating. Style never removes a product must-have: place every entry of the recommendation’s mustHaves in its zone (a first-screen item goes in the hero, whatever the archetype’s opening limits say), and pass the same productType to audit_page_structure, which lists the ones that are missing or off the first screen. When content is in scope, lack of internal jargon is not enough: test whether material claims, conclusions, and recommendations match their support and expressed certainty; whether prominent copy conveys concrete, context-specific information; and whether visual prominence matches information value, task relevance, and support. Do not invent evidence, facts, or next steps while rewriting. Use design principles as practical placement and visual-review guidance rather than a fixed recipe. Treat UX principles as evidence-labeled decision prompts, not universal laws; accessibility, safety, informed consent, and truthful feedback take priority.',
|