@cakejp/design-system 0.20.1 → 0.21.0

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.
Files changed (161) hide show
  1. package/CHANGELOG.md +172 -0
  2. package/CLAUDE.md +5 -3
  3. package/MIGRATION.md +3 -3
  4. package/README.md +31 -11
  5. package/contracts/components.json +420 -63
  6. package/contracts/composition.json +38 -4
  7. package/contracts/rules.json +27 -5
  8. package/contracts/screen-patterns.json +6 -4
  9. package/dist/components/ec/admin-shell.js +62 -60
  10. package/dist/components/ec/anniversary-card.js +13 -12
  11. package/dist/components/ec/coupon-card.js +11 -11
  12. package/dist/components/ec/delivery-calendar.js +51 -45
  13. package/dist/components/ec/mypage-shell.js +80 -69
  14. package/dist/components/ec/product-card.js +93 -76
  15. package/dist/components/ec/product-carousel.js +65 -60
  16. package/dist/components/ec/product-detail-bar.js +13 -11
  17. package/dist/components/ec/product-detail-sidebar.js +60 -58
  18. package/dist/components/ec/product-list-item.js +64 -63
  19. package/dist/components/ec/product-option.js +30 -26
  20. package/dist/components/ec/rating-stars.js +27 -27
  21. package/dist/components/ec/review-card.js +32 -32
  22. package/dist/components/ec/review-form.js +37 -37
  23. package/dist/components/ec/shop-card.js +21 -19
  24. package/dist/components/foundations/accordion.js +33 -31
  25. package/dist/components/foundations/alert-dialog.js +4 -5
  26. package/dist/components/foundations/badge.js +5 -5
  27. package/dist/components/foundations/breadcrumb.js +27 -26
  28. package/dist/components/foundations/button.js +144 -25
  29. package/dist/components/foundations/calendar.js +28 -26
  30. package/dist/components/foundations/checkbox-card.js +71 -47
  31. package/dist/components/foundations/checkbox-group.js +30 -27
  32. package/dist/components/foundations/checkbox.js +69 -52
  33. package/dist/components/foundations/chip-variants.js +13 -0
  34. package/dist/components/foundations/command.js +81 -79
  35. package/dist/components/foundations/confirm-dialog.js +136 -0
  36. package/dist/components/foundations/context-menu.js +43 -38
  37. package/dist/components/foundations/data-table.js +87 -84
  38. package/dist/components/foundations/dialog.js +45 -36
  39. package/dist/components/foundations/dropdown-menu.js +47 -42
  40. package/dist/components/foundations/file-input.js +97 -67
  41. package/dist/components/foundations/hover-card.js +21 -21
  42. package/dist/components/foundations/menubar.js +75 -69
  43. package/dist/components/foundations/navigation-menu.js +31 -26
  44. package/dist/components/foundations/pagination.js +54 -50
  45. package/dist/components/foundations/popover.js +7 -7
  46. package/dist/components/foundations/progress.js +10 -6
  47. package/dist/components/foundations/radio-group.js +6 -3
  48. package/dist/components/foundations/responsive-dialog.js +73 -55
  49. package/dist/components/foundations/scroll-area.js +18 -14
  50. package/dist/components/foundations/select.js +44 -39
  51. package/dist/components/foundations/sheet.js +45 -37
  52. package/dist/components/foundations/skeleton.js +6 -6
  53. package/dist/components/foundations/skip-link.js +10 -8
  54. package/dist/components/foundations/slider.js +73 -48
  55. package/dist/components/foundations/sonner.js +5 -4
  56. package/dist/components/foundations/spinner.js +7 -5
  57. package/dist/components/foundations/switch.js +11 -10
  58. package/dist/components/foundations/tabs.js +54 -39
  59. package/dist/components/foundations/toggle-group.js +29 -21
  60. package/dist/components/foundations/toggle.js +20 -16
  61. package/dist/components/primitives/admin-side-nav.js +65 -62
  62. package/dist/components/primitives/banner-carousel.js +32 -29
  63. package/dist/components/primitives/bottom-tab-bar.js +16 -15
  64. package/dist/components/primitives/category-scroll.js +39 -29
  65. package/dist/components/primitives/category-shortcuts.js +9 -9
  66. package/dist/components/primitives/chat-composer.js +77 -74
  67. package/dist/components/primitives/chip.js +84 -61
  68. package/dist/components/primitives/combobox.js +63 -47
  69. package/dist/components/primitives/container.js +9 -9
  70. package/dist/components/primitives/content-card.js +15 -17
  71. package/dist/components/primitives/content-carousel.js +79 -68
  72. package/dist/components/primitives/date-picker.js +137 -99
  73. package/dist/components/primitives/footer.js +36 -37
  74. package/dist/components/primitives/header.js +175 -168
  75. package/dist/components/primitives/image-carousel.js +107 -87
  76. package/dist/components/primitives/image-gallery.js +32 -27
  77. package/dist/components/primitives/image-uploader.js +6 -6
  78. package/dist/components/primitives/list-item.js +59 -51
  79. package/dist/components/primitives/menu-drawer.js +36 -38
  80. package/dist/components/primitives/multi-select.js +89 -58
  81. package/dist/components/primitives/notification-list.js +10 -9
  82. package/dist/components/primitives/number-input.js +116 -105
  83. package/dist/components/primitives/scroll-row.js +21 -0
  84. package/dist/components/primitives/search-bar.js +31 -28
  85. package/dist/components/primitives/section-header.js +54 -53
  86. package/dist/components/primitives/side-nav.js +57 -56
  87. package/dist/components/primitives/sub-nav.js +13 -14
  88. package/dist/components/primitives/tag.js +4 -2
  89. package/dist/index.css +1 -1
  90. package/dist/index.js +3051 -924
  91. package/dist/lib/field-labelling.js +31 -21
  92. package/dist/lib/focus-ring.js +22 -4
  93. package/dist/lib/high-contrast.js +4 -0
  94. package/dist/lib/image-index.js +8 -0
  95. package/dist/lib/use-prefers-reduced-motion.js +21 -0
  96. package/dist/types/components/ec/admin-shell.d.ts +11 -1
  97. package/dist/types/components/ec/anniversary-card.d.ts +9 -1
  98. package/dist/types/components/ec/mypage-shell.d.ts +12 -1
  99. package/dist/types/components/ec/product-card.d.ts +13 -1
  100. package/dist/types/components/ec/product-carousel.d.ts +13 -1
  101. package/dist/types/components/ec/product-detail-bar.d.ts +12 -1
  102. package/dist/types/components/ec/product-detail-sidebar.d.ts +11 -1
  103. package/dist/types/components/ec/product-list-item.d.ts +9 -1
  104. package/dist/types/components/ec/rating-stars.d.ts +2 -0
  105. package/dist/types/components/ec/review-card.d.ts +1 -1
  106. package/dist/types/components/ec/shop-card.d.ts +8 -1
  107. package/dist/types/components/foundations/badge.d.ts +1 -1
  108. package/dist/types/components/foundations/breadcrumb.d.ts +8 -1
  109. package/dist/types/components/foundations/button.d.ts +38 -3
  110. package/dist/types/components/foundations/checkbox-card.d.ts +7 -1
  111. package/dist/types/components/foundations/checkbox.d.ts +1 -1
  112. package/dist/types/components/foundations/chip-variants.d.ts +2 -2
  113. package/dist/types/components/foundations/confirm-dialog.d.ts +61 -0
  114. package/dist/types/components/foundations/data-table.d.ts +9 -2
  115. package/dist/types/components/foundations/dialog.d.ts +16 -1
  116. package/dist/types/components/foundations/pagination.d.ts +1 -1
  117. package/dist/types/components/foundations/responsive-dialog.d.ts +2 -1
  118. package/dist/types/components/foundations/sheet.d.ts +12 -1
  119. package/dist/types/components/foundations/skeleton.d.ts +6 -0
  120. package/dist/types/components/foundations/slider.d.ts +15 -1
  121. package/dist/types/components/foundations/tabs.d.ts +7 -0
  122. package/dist/types/components/primitives/admin-side-nav.d.ts +22 -2
  123. package/dist/types/components/primitives/banner-carousel.d.ts +9 -1
  124. package/dist/types/components/primitives/bottom-tab-bar.d.ts +13 -2
  125. package/dist/types/components/primitives/category-scroll.d.ts +10 -1
  126. package/dist/types/components/primitives/category-shortcuts.d.ts +11 -2
  127. package/dist/types/components/primitives/chip.d.ts +22 -3
  128. package/dist/types/components/primitives/combobox.d.ts +7 -2
  129. package/dist/types/components/primitives/container.d.ts +3 -0
  130. package/dist/types/components/primitives/content-card.d.ts +1 -1
  131. package/dist/types/components/primitives/content-carousel.d.ts +12 -4
  132. package/dist/types/components/primitives/date-picker.d.ts +10 -3
  133. package/dist/types/components/primitives/footer.d.ts +1 -1
  134. package/dist/types/components/primitives/header.d.ts +14 -2
  135. package/dist/types/components/primitives/image-carousel.d.ts +23 -5
  136. package/dist/types/components/primitives/list-item.d.ts +10 -1
  137. package/dist/types/components/primitives/menu-drawer.d.ts +1 -1
  138. package/dist/types/components/primitives/multi-select.d.ts +7 -2
  139. package/dist/types/components/primitives/notification-list.d.ts +10 -1
  140. package/dist/types/components/primitives/number-input.d.ts +18 -5
  141. package/dist/types/components/primitives/scroll-row.d.ts +43 -0
  142. package/dist/types/components/primitives/section-header.d.ts +9 -2
  143. package/dist/types/components/primitives/side-nav.d.ts +13 -1
  144. package/dist/types/components/primitives/sub-nav.d.ts +1 -1
  145. package/dist/types/components/primitives/tag.d.ts +1 -1
  146. package/dist/types/index.d.ts +7 -1
  147. package/dist/types/lib/field-labelling.d.ts +23 -8
  148. package/dist/types/lib/focus-ring.d.ts +70 -3
  149. package/dist/types/lib/high-contrast.d.ts +25 -0
  150. package/dist/types/lib/image-index.d.ts +2 -0
  151. package/dist/types/lib/link-component.d.ts +26 -21
  152. package/dist/types/lib/use-prefers-reduced-motion.d.ts +9 -0
  153. package/package.json +11 -3
  154. package/src/components/COMPONENT_LOOKUP.md +18 -16
  155. package/src/preset-standalone.css +42 -0
  156. package/src/preset.css +20 -1
  157. package/src/styles/semantic.css +57 -0
  158. package/templates/AGENTS.md +5 -1
  159. package/templates/CLAUDE.md +3 -1
  160. package/tokens.json +49 -0
  161. package/dist/lib/link-component.js +0 -6
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "meta": {
3
3
  "name": "Cake.jp Design System — Composition Contracts",
4
- "version": "0.20.1",
4
+ "version": "0.21.0",
5
5
  "description": "ページ骨格・視覚階層・余白リズムの機械可読な正本。画面パターンを選んだ後の「実際の組み方」を規定する。ページの外枠(モバイル/デスクトップ/管理)、商品グリッドの列数、余白の4段リズム、Surface のネスト階層、テキスト階層、CTA の優先順位を構造化する。人間向けの解説は guidelines/composition/layout.md・guidelines/composition/hierarchy.md・guidelines/overview.md。",
6
6
  "source": "guidelines/composition/layout.md, guidelines/composition/hierarchy.md, guidelines/overview.md, guidelines/components/button.md(CTA 密度ルール)を正本化",
7
7
  "roleSeparation": "screen-patterns.json はページ種別(Standard Page / Focused Workspace / ResponsiveDialog / Dialog)を選ぶための契約。composition.json は選んだ後、その骨格をどう組むか(外枠構造・余白リズム・階層)の契約。前者=何を使うか、後者=どう並べるか。",
@@ -24,7 +24,8 @@
24
24
  "スクロール本文は flex-1 で伸縮させる。高さをハードコードしない",
25
25
  "下部に StickyActionBar(固定 CTA)がある場合、main に pb-20 を付けて本文が隠れないようにする",
26
26
  "モバイルの全ページは原則 Header を上端・BottomTabBar を下端に持つ(下部 CTA ページでは BottomTabBar の代わりに StickyActionBar)",
27
- "横スクロールリストは flex.overflow-x-auto.gap-3.[-webkit-overflow-scrolling:touch](カテゴリ横スクロールは CategoryScroll を使う)"
27
+ "横スクロールリストは ScrollRow を使う(flex.overflow-x-auto.gap-3.[-webkit-overflow-scrolling:touch] の手組みをしない。カテゴリ横スクロールは CategoryScroll、自動再生・ドット付きは ContentCarousel)",
28
+ "横スクロールの行の端の余白は Container の gutter にそろえる: Container の直下で gutter 分だけ外へはみ出し(SP では画面端までスクロール)、同じ幅の padding と scroll-padding を付ける。1 枚目の左端が見出しとそろい、スナップ後・最後の要素の右にも余白が残る。ScrollRow と ContentCarousel・ImageCarousel の peek はこれを内蔵しているので、外側に -mx-4 等を足さない。Card など余白を持つ親の中では ScrollRow に bleed={false} を渡す(変数は Container の子孫すべてに届く)。手組みが避けられないときは -mx-4 px-4 を直書きせず -mx-[var(--Container-Gutter)] px-[var(--Container-Gutter)] scroll-px-[var(--Container-Gutter)] を使う(md 以上の 24px・gutter=tight にも追従する)"
28
29
  ]
29
30
  },
30
31
  "desktop": {
@@ -149,15 +150,48 @@
149
150
  { "variant": "default", "role": "Primary CTA(前進・確定)", "appearance": "ブランドオレンジのベタ塗り", "note": "1ビューポートに1つまで(唯一の主 CTA)" },
150
151
  { "variant": "secondary", "role": "Secondary action(前進系の副 CTA。例: 「サンプルを見る」「詳細を見る」)", "appearance": "⚠️ ブランドアクセント(Surface-Accent-Primary-Light 地 + Brand-Cake-Orange 文字)。Material / Bootstrap / shadcn の secondary(グレー・控えめ)とは別物", "note": "アクセント色が付くため、戻る・キャンセル・閉じる等の後退/中立アクションには使わない(→ tertiary)" },
151
152
  { "variant": "tertiary", "role": "Tertiary action / 後退・中立アクション(戻る・キャンセル・閉じる・スキップ・あとで)", "appearance": "ニュートラルなグレー(Surface-Tertiary 地 + Text-High-Emphasis 文字)", "note": "他 DS の secondary に相当する見た目。主 CTA の隣に置く「戻る」「キャンセル」はこれを使う" },
153
+ { "variant": "outline", "role": "準主役の前進アクション(ブランド色を使わない)。「一覧を見る」等の移動ボタン、一覧・カードで1件ごとに繰り返す操作(商品カードの「カートに追加」等)、ブックマーク等の保存トグルのボタン本体", "appearance": "白地(Surface-Primary)+ 1px の黒系の枠(Border-High-Emphasis)+ Text-High-Emphasis 文字。hover / active は薄い下地(Hover-Text-Button / Active-Text-Button)", "note": "ブランド色を使わないので何個並んでもよい。ただし繰り返す操作は見た目が増えるので、ボタンに頼らずカード全体のリンクで足りるときは置かない" },
152
154
  { "variant": "ghost", "role": "Minimal action(メニュー・ツールバー内)", "appearance": "下地なし・hover で薄い下地" },
153
- { "variant": "link", "role": "Inline link", "appearance": "テキストリンク意匠" }
155
+ { "variant": "link", "role": "補助リンク(「もっと見る」「利用規約を見る」等のインラインの移動)", "appearance": "ブランド色を使わない。Text-Medium-Emphasis(グレー)+ 常時下線。hover で Text-High-Emphasis", "note": "セクション見出し横の「もっと見る」は SectionHeader が同じ意匠で描く" }
154
156
  ],
155
157
  "rules": [
156
158
  "default(オレンジ)の CTA は1ビューポートに1つまで。主アクションを1つに絞る",
157
159
  "複数アクションを並べる時は default を tertiary / ghost と組み合わせる",
158
160
  "「戻る」「キャンセル」「閉じる」「スキップ」「あとで」は tertiary(グレー)。secondary はアクセント色なので後退アクションに使わない",
161
+ "ブランド色を使わずに「押せるボタン」の存在感がほしい前進アクション(「一覧を見る」、1件ごとに繰り返す操作、保存トグルのボタン本体)は outline。黒ベタ塗りにしない",
162
+ "「もっと見る」等の補助リンクは link(グレー + 下線)。ブランド色の文字リンクにしない",
159
163
  "secondary を使うのは、主 CTA と別方向の“前進”を促す副 CTA のとき(例: 主=「購入する」に対し副=「サンプルを見る」)",
160
- "モバイルの全幅下部 CTA は size=\"xl\" + w-full(StickyActionBar 内)"
164
+ "モバイルの全幅下部 CTA は size=\"xl\" + w-full(StickyActionBar 内)",
165
+ "ブランド色を使ってよい場所・使わない場所の正本は brandColorUsage"
166
+ ]
167
+ },
168
+ "brandColorUsage": {
169
+ "description": "ブランド色を使ってよい場所と使わない場所。ブランド色が付いた部品が画面に多いと、どれが主役か分からなくなり目立ちすぎる。そのため「1つの主 CTA」「価格の最強調」「入力部品のオン状態」など、色そのものが意味を持つ場所にだけ使う。色相に依存しない書き方にしてあり、ブランド色が別の色相に変わってもこのルールは同じ(トークン名や hex ではなく役割で判断する)。",
170
+ "brandTokens": ["--Brand-Cake-Orange", "--Brand-Cake-Orange-Light", "--Brand-Cake-Orange-Ultra-Light", "--Text-Accent-Primary", "--Surface-Accent-Primary-Light", "--Object-Accent-Primary", "--Border-Accent-Primary"],
171
+ "principle": "強調は色の量ではなく、サイズ・余白・配置・文字の太さで作る。ブランド色の部品が1ビューポートに複数あるなら、主役以外は黒系(Text-High-Emphasis / Border-High-Emphasis)かグレー(Text-Medium-Emphasis / Surface-Tertiary)に落とす。",
172
+ "allowed": [
173
+ { "place": "1ビューポートに1つの主 CTA", "use": "Button variant=\"default\"(暗背景の上は inverse)", "note": "ctaHierarchy の default。副 CTA の secondary もアクセント色なので、主 CTA と合わせて画面の「前進アクション」を2つ程度に絞る" },
174
+ { "place": "価格の最強調", "use": "typo-label-lg + --Text-Accent-Primary(PriceDisplay 等)", "note": "textHierarchy.accentNote と同じ。font-bold は足さない" },
175
+ { "place": "ロゴ・ブランドの印", "use": "ブランド色のロゴ素材そのもの", "note": "UI 部品の色としては使わない" },
176
+ { "place": "入力部品のオン状態", "use": "Checkbox / CheckboxGroup / CheckboxCard / RadioGroup / Switch / Slider のチェック・選択・つまみ(--Object-Accent-Primary / --Brand-Cake-Orange)", "note": "状態そのものを示す色なので、ボタンや文字リンクには広げない" },
177
+ { "place": "進捗・処理中の表示", "use": "ProgressSteps / FunnelShell のステップの完了・現在、Progress の帯、Spinner の回る円弧", "note": "完了と現在地を示す表示に限る。装飾には使わない" },
178
+ { "place": "未読・件数などの小さな状態の印", "use": "NotificationList の未読ドット、FilterBar・MenuDrawer の件数バッジ、ImageGallery の現在位置ドット", "note": "面積が小さい印に限る。バッジを並べて画面を埋めない" },
179
+ { "place": "ヘッダーの「会員登録・ログイン」(未ログイン時の入会・ログイン導線)", "use": "Button variant=\"default\" size=\"sm\"(ブランド色の塗り)", "note": "会員になることは事業上の主導線なので、全ページに出てもブランド色の塗りを維持する。ヘッダーの中でブランド色の塗りにしてよいのはこの1つだけ(カート・ナビ項目・ログイン後のアカウント操作は notAllowed のとおり)" }
180
+ ],
181
+ "notAllowed": [
182
+ { "place": "ヘッダー・グローバルナビの操作(カート、ナビ項目、ログイン後のアカウント操作など。会員登録・ログインだけは allowed の例外)", "instead": "Button variant=\"outline\"(強調したいとき)/ ghost(通常)/ tertiary", "note": "毎ページに出るので、ブランド色を置くとページごとの主 CTA と競合する" },
183
+ { "place": "一覧・カードで1件ごとに繰り返す操作(商品カードの「カートに追加」、クーポンの「獲得する」等)", "instead": "Button variant=\"outline\"(ProductCard のカートボタンは対応済み)", "note": "件数分だけブランド色のベタ塗りが並び、一覧全体がブランド色に染まって見える" },
184
+ { "place": "ブックマーク・お気に入り等の保存トグルのボタン本体(「ブックマークを追加」「保存」)", "instead": "Button variant=\"outline\"(保存済みは文言とアイコンの形で示す。ブランド色のベタ塗りにしない)", "note": "保存は主 CTA ではなく補助の操作" },
185
+ { "place": "「もっと見る」「すべて見る」「一覧を見る」等の移動", "instead": "文字リンクは Button variant=\"link\"(SectionHeader の moreHref も同じ意匠)。ボタンにするときは variant=\"outline\"(黒ベタ塗りにしない)", "note": "色ではなく下線で「押せる」ことを示す" },
186
+ { "place": "ナビの選択中表示(チップ・タブ・サイドナビ・ボトムタブ)", "instead": "Text-High-Emphasis の文字・下線・左ライン(Tabs の underbar が見本)。チップは Chip の selected(グレー地 + 黒系の枠)", "note": "選択中を色の薄い地で塗らない。Chip の selected は対応済み(Surface-Tertiary 地 + Text-High-Emphasis 文字 + 内側 1px の Border-High-Emphasis の枠)。今の SideNav / BottomTabBar / SectionNav / SubNav はブランド色のままで、変更は別途(未対応)" },
187
+ { "place": "評価の星・評価の数値", "instead": "RatingStars は --Text-High-Emphasis(黒系)。入力用の星(ReviewForm の選択済み)はブランド色のまま", "note": "表示用の評価はブランド色の目立つ要素にしない" },
188
+ { "place": "装飾目的の成功色・アクセント色の情報ラベル(「最短 〇月〇日お届け」等)", "instead": "--Text-Medium-Emphasis(Text-Success は成功メッセージ・結果の状態だけに使う)", "note": "情報ラベルを色で目立たせない" }
189
+ ],
190
+ "rules": [
191
+ "新しい部品や画面でブランド色を使うときは、allowed のどれに当たるかを説明できること。当たらないなら黒系・グレー系(Text-High-Emphasis / Text-Medium-Emphasis / Border-High-Emphasis / Surface-Tertiary)か、Button の outline / link を使う",
192
+ "ブランド色のベタ塗り・薄い地は、1ビューポートに主 CTA 1つと、状態を示す小さな印を除いて置かない",
193
+ "文字リンクにブランド色(--Text-Accent-Primary)を使わない。リンクは下線で示す。価格の最強調だけがアクセント色の文字",
194
+ "DS 内に notAllowed に当たる既存部品が残っているときは、新規実装にそれを真似しない(部品の追従は個別に行う)"
161
195
  ]
162
196
  }
163
197
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "meta": {
3
3
  "name": "Cake.jp Design System — Rules Contracts",
4
- "version": "0.20.1",
4
+ "version": "0.21.0",
5
5
  "description": "禁止パターン・アクセシビリティ要件・ライティングルールの構造化定義。lint-scratch.sh と check-drift.sh で自動検証。"
6
6
  },
7
7
  "prohibited": [
@@ -515,7 +515,7 @@
515
515
  "components/ec/"
516
516
  ],
517
517
  "message": "outline-none でフォーカスリングを消す禁止",
518
- "fix": "focus-visible:ring-[3px] focus-visible:ring-[var(--Focus-High-Emphasis)]/50"
518
+ "fix": "FOCUS_RING / FOCUS_RING_ONLY(src/lib/focus-ring.ts)を使う。focus-visible:ring-[3px] に続けるリング色は ring-[color:var(--Focus-Ring-Control,color-mix(in_oklab,var(--Focus-High-Emphasis)_50%,transparent))]"
519
519
  },
520
520
  {
521
521
  "id": "R42",
@@ -614,6 +614,13 @@
614
614
  ],
615
615
  "message": "Input type='number' を直接使わない",
616
616
  "fix": "数値入力はカート数量・価格・在庫すべて <NumberInput /> を使う(size=\"sm\" コンパクト型 / size=\"md\" サークル型)"
617
+ },
618
+ {
619
+ "id": "R57",
620
+ "severity": "warning",
621
+ "category": "component",
622
+ "message": "ブランド色(--Brand-Cake-Orange / --Text-Accent-Primary / --Surface-Accent-Primary-Light 等)を、主 CTA・価格の最強調・入力部品のオン状態・進捗や件数の小さな印以外に使わない。特に、ヘッダー・グローバルナビの操作、一覧やカードで1件ごとに繰り返す操作、ブックマーク等の保存トグルのボタン本体、「もっと見る」等の移動リンク、ナビの選択中表示、評価の星、情報ラベルをブランド色にしない(正規表現では検出できないため、レビューで見る)",
623
+ "fix": "使ってよい場所と代わりの部品は contracts/composition.json の brandColorUsage を見る。繰り返す操作・移動ボタン・保存トグルは <Button variant=\"outline\">、「もっと見る」等の文字リンクは <Button variant=\"link\">(グレー + 下線)、評価の星は --Text-High-Emphasis、情報ラベルは --Text-Medium-Emphasis"
617
624
  }
618
625
  ],
619
626
  "accessibility": {
@@ -629,7 +636,7 @@
629
636
  },
630
637
  {
631
638
  "id": "A003",
632
- "rule": "UIコンポーネント境界・アイコンのコントラスト比 3:1 以上"
639
+ "rule": "UIコンポーネント境界・アイコンのコントラスト比 3:1 以上。既定で届かない枠・溝・輪郭・リングだけのフォーカスは、見た目の既定を変えずに、高コントラスト(OS の prefers-contrast: more か data-contrast=\"more\")のときだけ新ロール(--Border-Control / --Surface-Control-Track / --Focus-Ring-Control)で 3:1 以上にする。入力・選択の操作部品の枠は border-[var(--Border-Control,var(--Border-Medium-Emphasis))] の形(フォールバック付き)で書く。新ロールはフォールバックなしで参照せず、:root / .dark では宣言しない(semantic.css の High Contrast 節だけ)。検査は npm run lint:contrast(既定 + 高コントラスト 2 モード)"
633
640
  },
634
641
  {
635
642
  "id": "A004",
@@ -637,7 +644,7 @@
637
644
  },
638
645
  {
639
646
  "id": "A005",
640
- "rule": "フォーカスリング必須: focus-visible:border-[var(--Focus-High-Emphasis)] focus-visible:ring-[3px] focus-visible:ring-[var(--Focus-High-Emphasis)]/50(DS の FOCUS_RING 定数。入力系・操作系はすべてこれを使い、独自の ring 幅・色を作らない)"
647
+ "rule": "フォーカスリング必須: focus-visible:border-[var(--Focus-High-Emphasis)] focus-visible:ring-[3px] focus-visible:ring-[color:var(--Focus-Ring-Control,color-mix(in_oklab,var(--Focus-High-Emphasis)_50%,transparent))](DS の FOCUS_RING 定数。リングの色は既定では緑の 50% 透過で、高コントラストのときだけ不透明な --Focus-Ring-Control に切り替わる。入力系・操作系はすべてこれを使い、独自の ring 幅・色を作らない)。枠を変えずリングだけで示す部品(Switch / ListItem / カルーセル等)は FOCUS_RING_ONLY(内側に描くなら FOCUS_RING_INSET)を使う。ring-[var(--Focus-High-Emphasis)]/50 や ring-ring/50 の直書きは、高コントラストで不透明なリング(--Focus-Ring-Control)に切り替わらないため禁止。リングは box-shadow なので forced-colors(Windows のハイコントラスト)では描かれない。forced-colors では outline(実線 2px・Highlight)で示す: FOCUS_RING / FOCUS_RING_WITHIN / FOCUS_RING_INSET / FOCUS_RING_ONLY は含んでいる。ring を自前で書く場合は FORCED_COLORS_FOCUS(外側)/ FORCED_COLORS_FOCUS_INSET / FORCED_COLORS_FOCUS_WITHIN を足す。メニュー項目の選択位置は forced-colors で Highlight / HighlightText の塗りにする(FORCED_COLORS_MENU_ITEM / cmdk は FORCED_COLORS_COMMAND_ITEM。項目は outline-none。outline-hidden は forced-colors で常時 2px の輪郭線が出る)"
641
648
  },
642
649
  {
643
650
  "id": "A011",
@@ -661,7 +668,7 @@
661
668
  },
662
669
  {
663
670
  "id": "A013",
664
- "rule": "Radix ベースのコントロール(Select / Switch / Checkbox / Combobox / Slider 等)は <button> や <span role=\"slider\"> として描画されるため、<Label htmlFor> や外側の <label> ラップでは名前が付かない。FormField でラップして aria-labelledby を自動付与させるか、単体利用なら日本語の aria-label をコントロール自身に書く(issue #202)"
671
+ "rule": "Radix ベースのコントロール(Select / Switch / Checkbox / Combobox / Slider 等)は、単一フィールドでは FormField の aria-labelledby で名前を付ける。複数選択肢では各コントロールを native label に関連付けるか、日本語の aria-label / aria-labelledby を明示する。明示ARIAは自動のフィールド名より優先し、description / error は aria-describedby で関連付ける(issue #202)"
665
672
  },
666
673
  {
667
674
  "id": "A008",
@@ -839,6 +846,7 @@
839
846
  }
840
847
  ],
841
848
  "usage": "Tailwind では duration-[var(--Motion-Duration-Base)] / ease-[var(--Motion-Easing-Standard)]。素の CSS では var() を直接参照する。",
849
+ "reducedMotion": "prefers-reduced-motion: reduce では、--Motion-Duration-* を参照する動きと tw-animate-css の animate-in / animate-out(preset が再生時間を 0.01ms に落とす)は自動で止まる。Tailwind の animate-spin / animate-pulse など無限に繰り返すアニメーションは止まらないため motion-reduce:animate-none を必ず併記する。JS で動かすもの(カルーセルの自動再生・scrollTo の smooth 等)は matchMedia で prefers-reduced-motion を判定して止める",
842
850
  "note": "Tailwind の ease-out / ease-in-out クラス(別曲線)を使っている既存箇所は体感が変わるため Standard に寄せていない。曲線を何本に整理するかは視覚が変わる設計判断として別途扱う。"
843
851
  },
844
852
  "zIndex": {
@@ -984,6 +992,20 @@
984
992
  "excludes": [
985
993
  ".stories."
986
994
  ]
995
+ },
996
+ {
997
+ "id": "AI8",
998
+ "name": "window.confirm",
999
+ "pattern": "",
1000
+ "description": "AI生成パターン: window.confirm() で確認する(ブラウザ標準の意匠で、文言・ボタン・フォーカスを DS の規約に合わせられない)",
1001
+ "fix": "useConfirm を使う(アプリのルートに ConfirmDialogProvider を 1 つ置き、const ok = await confirm({ title, description, confirmLabel, tone }) で受け取る)"
1002
+ },
1003
+ {
1004
+ "id": "AI9",
1005
+ "name": "処理中ボタンの自作",
1006
+ "pattern": "",
1007
+ "description": "AI生成パターン: 処理中のボタンを disabled + 自作スピナーで組む(disabled でフォーカスが外れ、ラベルの差し替えで幅も変わる)。例: <Button disabled><Spinner /> 送信中...</Button> / <Button disabled={busy}>{busy ? <Loader2 className=\"animate-spin\" /> : \"保存\"}</Button> / <Button disabled={busy}>{busy && <Spinner />}保存</Button>",
1008
+ "fix": "Button の loading を使う(<Button loading>保存</Button>。幅を保ち、フォーカスを保ったまま click 系を止める。読み上げ文言は loadingLabel、既定「処理中」)"
987
1009
  }
988
1010
  ]
989
1011
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "meta": {
3
3
  "name": "Cake.jp Design System — Screen Patterns Contracts",
4
- "version": "0.20.1",
4
+ "version": "0.21.0",
5
5
  "description": "CRUD 機能でどの画面パターンを使うかの機械可読な判断基準。5パターンの定義・CRUD 対応・決定木・編集UIの観点比較を構造化する。人間向けの解説は guidelines/foundations/screen-patterns.md。",
6
6
  "source": "GitHub issue #37 CRUDの画面設計の型化と基本パターンの整備",
7
7
  "relatedContract": "本契約はページ種別の選択(何を使うか)を担う。選んだ後の骨格の組み方(外枠構造・余白リズム・視覚階層)は contracts/composition.json を参照する。",
@@ -113,7 +113,7 @@
113
113
  "aliases": ["Semi Modal"],
114
114
  "purpose": "軽〜中程度の作成・編集。一覧のコンテキストを維持したまま素早く終える。",
115
115
  "dsComponents": ["ResponsiveDialog"],
116
- "dsComponentsNote": "PC=Dialog / SP=Sheet を自動切替。素の Dialog / Sheet を手組みで出し分けない。",
116
+ "dsComponentsNote": "PC=Dialog / SP=Drawer(下部のボトムシート)を自動切替。素の Dialog / Sheet を手組みで出し分けない。",
117
117
  "navigation": {
118
118
  "globalNav": "元画面のまま(オーバーレイ表示)",
119
119
  "breadcrumb": "元画面のまま",
@@ -148,11 +148,13 @@
148
148
  "削除確認・実行確認・警告",
149
149
  "操作を一度止めて明示的な確認を取りたい",
150
150
  "選択肢を提示して分岐させたい",
151
- "破壊的操作(削除・取り消し)の確認は AlertDialog"
151
+ "破壊的操作(削除・取り消し)の確認は AlertDialog",
152
+ "はい / いいえを 1 回聞くだけの確認(window.confirm() の置き換え)は useConfirm。アプリのルートに ConfirmDialogProvider を 1 つ置き、const ok = await confirm({ title, description }) で受け取る(中身は AlertDialog)"
152
153
  ],
153
154
  "whenNotToUse": [
154
155
  "フォーム入力(→ ResponsiveDialog)",
155
- "破壊的確認なのに素の Dialog で組む(→ AlertDialog)"
156
+ "破壊的確認なのに素の Dialog で組む(→ AlertDialog)",
157
+ "window.confirm() で確認する(→ useConfirm)"
156
158
  ]
157
159
  }
158
160
  ],
@@ -1,24 +1,24 @@
1
1
  "use client";
2
- import { jsxs as r, jsx as e, Fragment as N } from "react/jsx-runtime";
3
- import * as d from "react";
4
- import { cn as k } from "../../lib/utils.js";
5
- import M from "iconsax-reactjs/dist/esm/Home2.js";
6
- import z from "iconsax-reactjs/dist/esm/ShoppingCart.js";
7
- import C from "iconsax-reactjs/dist/esm/Cake.js";
8
- import A from "iconsax-reactjs/dist/esm/Shop.js";
9
- import T from "iconsax-reactjs/dist/esm/Chart2.js";
10
- import H from "iconsax-reactjs/dist/esm/Box.js";
11
- import P from "iconsax-reactjs/dist/esm/Setting2.js";
12
- import E from "iconsax-reactjs/dist/esm/InfoCircle.js";
13
- import j from "iconsax-reactjs/dist/esm/Notification.js";
14
- import w from "iconsax-reactjs/dist/esm/User.js";
15
- import F from "iconsax-reactjs/dist/esm/ArrowRight2.js";
16
- import I from "iconsax-reactjs/dist/esm/ArrowLeft.js";
17
- import { AdminSideNav as O } from "../primitives/admin-side-nav.js";
18
- import { AdminHeader as L } from "../primitives/admin-header.js";
19
- import { Button as R } from "../foundations/button.js";
20
- import { SkipLink as B } from "../foundations/skip-link.js";
21
- function te({
2
+ import { jsxs as r, jsx as e, Fragment as M } from "react/jsx-runtime";
3
+ import * as b from "react";
4
+ import { cn as z } from "../../lib/utils.js";
5
+ import C from "iconsax-reactjs/dist/esm/Home2.js";
6
+ import A from "iconsax-reactjs/dist/esm/ShoppingCart.js";
7
+ import T from "iconsax-reactjs/dist/esm/Cake.js";
8
+ import H from "iconsax-reactjs/dist/esm/Shop.js";
9
+ import E from "iconsax-reactjs/dist/esm/Chart2.js";
10
+ import P from "iconsax-reactjs/dist/esm/Box.js";
11
+ import j from "iconsax-reactjs/dist/esm/Setting2.js";
12
+ import w from "iconsax-reactjs/dist/esm/InfoCircle.js";
13
+ import F from "iconsax-reactjs/dist/esm/Notification.js";
14
+ import I from "iconsax-reactjs/dist/esm/User.js";
15
+ import L from "iconsax-reactjs/dist/esm/ArrowRight2.js";
16
+ import O from "iconsax-reactjs/dist/esm/ArrowLeft.js";
17
+ import { AdminSideNav as B } from "../primitives/admin-side-nav.js";
18
+ import { AdminHeader as D } from "../primitives/admin-header.js";
19
+ import { Button as K } from "../foundations/button.js";
20
+ import { SkipLink as R } from "../foundations/skip-link.js";
21
+ function oe({
22
22
  name: i,
23
23
  children: t,
24
24
  className: l
@@ -26,12 +26,12 @@ function te({
26
26
  return /* @__PURE__ */ r(
27
27
  "div",
28
28
  {
29
- className: k(
29
+ className: z(
30
30
  "relative border-2 border-dashed border-red-500 rounded-lg",
31
31
  l
32
32
  ),
33
33
  children: [
34
- /* @__PURE__ */ r("span", { className: "absolute -top-3 left-2 bg-[var(--Primitive-Red-500)] text-[var(--Primitive-White-alpha-1000)] typo-label-xs px-1.5 py-0.5 rounded z-10", children: [
34
+ /* @__PURE__ */ r("span", { className: "absolute -top-3 left-2 bg-[var(--Surface-Caution)] text-[var(--Primitive-White-alpha-1000)] typo-label-xs px-1.5 py-0.5 rounded z-10", children: [
35
35
  "DS未実装: ",
36
36
  i
37
37
  ] }),
@@ -49,12 +49,12 @@ function a(i) {
49
49
  }
50
50
  );
51
51
  }
52
- const D = [
53
- { key: "home", label: "ホーム", icon: a(M) },
52
+ const $ = [
53
+ { key: "home", label: "ホーム", icon: a(C) },
54
54
  {
55
55
  key: "orders",
56
56
  label: "注文管理",
57
- icon: a(z),
57
+ icon: a(A),
58
58
  subMenus: [
59
59
  { label: "注文一覧", href: "#" },
60
60
  { label: "注文CSV出力", href: "#" },
@@ -66,7 +66,7 @@ const D = [
66
66
  {
67
67
  key: "items",
68
68
  label: "商品管理",
69
- icon: a(C),
69
+ icon: a(T),
70
70
  subMenus: [
71
71
  { label: "商品一覧", href: "#" },
72
72
  { label: "商品登録", href: "#" },
@@ -79,7 +79,7 @@ const D = [
79
79
  {
80
80
  key: "shop",
81
81
  label: "ショップ管理",
82
- icon: a(A),
82
+ icon: a(H),
83
83
  subMenus: [
84
84
  { label: "ショップ情報", href: "#" },
85
85
  { label: "休業日設定", href: "#" },
@@ -93,7 +93,7 @@ const D = [
93
93
  {
94
94
  key: "sales",
95
95
  label: "売上管理",
96
- icon: a(T),
96
+ icon: a(E),
97
97
  subMenus: [
98
98
  { label: "売上詳細", href: "#" },
99
99
  { label: "振込一覧", href: "#" },
@@ -101,11 +101,11 @@ const D = [
101
101
  { label: "広告管理", href: "#" }
102
102
  ]
103
103
  },
104
- { key: "services", label: "サービス", icon: a(H) },
104
+ { key: "services", label: "サービス", icon: a(P) },
105
105
  {
106
106
  key: "settings",
107
107
  label: "設定",
108
- icon: a(P),
108
+ icon: a(j),
109
109
  subMenus: [
110
110
  { label: "アカウント設定", href: "#" },
111
111
  { label: "銀行口座", href: "#" },
@@ -114,29 +114,30 @@ const D = [
114
114
  { label: "メールテンプレート", href: "#" }
115
115
  ]
116
116
  },
117
- { key: "faq", label: "FAQ", icon: a(E) }
117
+ { key: "faq", label: "FAQ", icon: a(w) }
118
118
  ];
119
- function ne({
119
+ function se({
120
120
  children: i,
121
121
  activeNav: t = "home",
122
122
  title: l = "",
123
123
  breadcrumbs: n,
124
124
  shopName: s = "Sample Shop",
125
- brand: b,
126
- sidebarHeader: p,
127
- navItems: u = D,
128
- headerActions: v,
125
+ brand: p,
126
+ sidebarHeader: u,
127
+ navItems: v = $,
128
+ headerActions: x,
129
129
  onBack: m,
130
- backLabel: x = "戻る",
130
+ backLabel: g = "戻る",
131
131
  mainId: f = "main-content",
132
- skipLink: g
132
+ skipLink: y,
133
+ linkComponent: c
133
134
  }) {
134
- const [y, c] = d.useState(!1), S = /* @__PURE__ */ r(N, { children: [
135
+ const S = c ?? "a", [N, h] = b.useState(!1), k = /* @__PURE__ */ r(M, { children: [
135
136
  /* @__PURE__ */ r("button", { className: "relative flex items-center justify-center size-10 shrink-0 rounded-lg hover:bg-[var(--Surface-Secondary)]", "aria-label": "通知", children: [
136
- /* @__PURE__ */ e(j, { size: 20, className: "text-[var(--Text-High-Emphasis)]" }),
137
+ /* @__PURE__ */ e(F, { size: 20, className: "text-[var(--Text-High-Emphasis)]" }),
137
138
  /* @__PURE__ */ e("span", { className: "absolute top-1.5 right-1.5 size-2 rounded-full bg-[var(--Surface-Caution)]" })
138
139
  ] }),
139
- /* @__PURE__ */ e("button", { className: "flex items-center justify-center size-10 shrink-0 rounded-full bg-[var(--Surface-Tertiary)]", "aria-label": "プロフィール", children: /* @__PURE__ */ e(w, { size: 20, className: "text-[var(--Text-Medium-Emphasis)]" }) })
140
+ /* @__PURE__ */ e("button", { className: "flex items-center justify-center size-10 shrink-0 rounded-full bg-[var(--Surface-Tertiary)]", "aria-label": "プロフィール", children: /* @__PURE__ */ e(I, { size: 20, className: "text-[var(--Text-Medium-Emphasis)]" }) })
140
141
  ] });
141
142
  return (
142
143
  // 地が Surface-Secondary なので、配下 Card の既定サーフェスを白に切り替える文脈を宣言する
@@ -147,46 +148,47 @@ function ne({
147
148
  className: "@container flex min-h-screen bg-[var(--Surface-Secondary)] [--card-surface:var(--Surface-Primary)] dark:[--card-surface:var(--Surface-Secondary)]",
148
149
  "data-slot": "admin-shell",
149
150
  children: [
150
- g !== !1 && /* @__PURE__ */ e(B, { href: `#${f}` }),
151
+ y !== !1 && /* @__PURE__ */ e(R, { href: `#${f}` }),
151
152
  /* @__PURE__ */ e(
152
- O,
153
+ B,
153
154
  {
154
- items: u,
155
+ items: v,
155
156
  activeKey: t,
156
- drawerTitle: p ?? s,
157
- open: y,
158
- onOpenChange: c
157
+ drawerTitle: u ?? s,
158
+ open: N,
159
+ onOpenChange: h,
160
+ linkComponent: c
159
161
  }
160
162
  ),
161
163
  /* @__PURE__ */ r("div", { className: "@container/main flex flex-1 flex-col @md:pl-18", children: [
162
164
  /* @__PURE__ */ e(
163
- L,
165
+ D,
164
166
  {
165
- brand: b ?? `${s}管理`,
166
- onMenuClick: () => c(!0),
167
- actions: v ?? S
167
+ brand: p ?? `${s}管理`,
168
+ onMenuClick: () => h(!0),
169
+ actions: x ?? k
168
170
  }
169
171
  ),
170
172
  /* @__PURE__ */ r("main", { id: f, className: "mt-14 @md:mt-16 flex-1 p-4 @md:p-6", children: [
171
173
  m && /* @__PURE__ */ r(
172
- R,
174
+ K,
173
175
  {
174
176
  variant: "ghost",
175
177
  size: "sm",
176
178
  className: "mb-2 gap-1",
177
179
  onClick: m,
178
180
  children: [
179
- /* @__PURE__ */ e(I, { size: 16 }),
181
+ /* @__PURE__ */ e(O, { size: 16 }),
180
182
  " ",
181
- x
183
+ g
182
184
  ]
183
185
  }
184
186
  ),
185
187
  (n || l) && /* @__PURE__ */ r("div", { className: "mb-4 space-y-1", children: [
186
- n && n.length > 0 && /* @__PURE__ */ e("nav", { className: "flex items-center gap-1 typo-body-sm text-[var(--Text-Low-Emphasis)]", "aria-label": "パンくず", children: n.map((o, h) => /* @__PURE__ */ r(d.Fragment, { children: [
187
- h > 0 && /* @__PURE__ */ e(F, { size: 12 }),
188
- o.href ? /* @__PURE__ */ e("a", { href: o.href, className: "hover:text-[var(--Text-Accent-Primary)] transition-colors", children: o.label }) : /* @__PURE__ */ e("span", { className: "text-[var(--Text-High-Emphasis)]", children: o.label })
189
- ] }, h)) }),
188
+ n && n.length > 0 && /* @__PURE__ */ e("nav", { className: "flex items-center gap-1 typo-body-sm text-[var(--Text-Low-Emphasis)]", "aria-label": "パンくず", children: n.map((o, d) => /* @__PURE__ */ r(b.Fragment, { children: [
189
+ d > 0 && /* @__PURE__ */ e(L, { size: 12 }),
190
+ o.href ? /* @__PURE__ */ e(S, { href: o.href, className: "hover:text-[var(--Text-Accent-Primary)] transition-colors", children: o.label }) : /* @__PURE__ */ e("span", { className: "text-[var(--Text-High-Emphasis)]", children: o.label })
191
+ ] }, d)) }),
190
192
  l && /* @__PURE__ */ e("h1", { className: "typo-heading-2xl text-[var(--Text-High-Emphasis)]", children: l })
191
193
  ] }),
192
194
  i
@@ -198,6 +200,6 @@ function ne({
198
200
  );
199
201
  }
200
202
  export {
201
- ne as AdminShell,
202
- te as MissingComponent
203
+ se as AdminShell,
204
+ oe as MissingComponent
203
205
  };
@@ -1,9 +1,9 @@
1
1
  import { jsxs as a, jsx as e } from "react/jsx-runtime";
2
2
  import "react";
3
- import h from "iconsax-reactjs/dist/esm/Calendar.js";
4
- import { cn as u } from "../../lib/utils.js";
3
+ import u from "iconsax-reactjs/dist/esm/Calendar.js";
4
+ import { cn as v } from "../../lib/utils.js";
5
5
  import { Button as i } from "../foundations/button.js";
6
- function N({
6
+ function T({
7
7
  name: n,
8
8
  relation: d,
9
9
  type: l,
@@ -12,26 +12,27 @@ function N({
12
12
  memo: r,
13
13
  editHref: s,
14
14
  onEdit: t,
15
- className: p,
16
- ...o
15
+ linkComponent: p,
16
+ className: o,
17
+ ...x
17
18
  }) {
18
- const x = s ? /* @__PURE__ */ e(i, { variant: "tertiary", size: "xs", asChild: !0, children: /* @__PURE__ */ e("a", { href: s, children: "編集" }) }) : t ? /* @__PURE__ */ e(i, { variant: "tertiary", size: "xs", onClick: t, children: "編集" }) : null;
19
+ const h = s ? /* @__PURE__ */ e(i, { variant: "tertiary", size: "xs", asChild: !0, children: /* @__PURE__ */ e(p ?? "a", { href: s, children: "編集" }) }) : t ? /* @__PURE__ */ e(i, { variant: "tertiary", size: "xs", onClick: t, children: "編集" }) : null;
19
20
  return /* @__PURE__ */ a(
20
21
  "div",
21
22
  {
22
23
  "data-slot": "anniversary-card",
23
- className: u(
24
+ className: v(
24
25
  "min-w-[200px] rounded-xl border border-[var(--Border-Medium-Emphasis)] bg-[var(--Surface-Primary)] p-4 space-y-2",
25
- p
26
+ o
26
27
  ),
27
- ...o,
28
+ ...x,
28
29
  children: [
29
30
  /* @__PURE__ */ a("div", { className: "flex items-center justify-between gap-2", children: [
30
31
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
31
32
  /* @__PURE__ */ e("p", { className: "typo-label-md text-[var(--Text-High-Emphasis)]", children: n }),
32
33
  /* @__PURE__ */ e("span", { className: "typo-label-xs text-[var(--Text-Medium-Emphasis)] bg-[var(--Surface-Secondary)] px-2 py-0.5 rounded-full", children: d })
33
34
  ] }),
34
- x
35
+ h
35
36
  ] }),
36
37
  /* @__PURE__ */ a("p", { className: "typo-body-sm text-[var(--Text-Medium-Emphasis)]", children: [
37
38
  l,
@@ -40,7 +41,7 @@ function N({
40
41
  ] }),
41
42
  /* @__PURE__ */ a("div", { className: "flex items-center gap-2 bg-[var(--Surface-Accent-Primary-Light)] rounded-lg px-3 py-2", children: [
42
43
  /* @__PURE__ */ e(
43
- h,
44
+ u,
44
45
  {
45
46
  size: 16,
46
47
  className: "text-[var(--Brand-Cake-Orange)]",
@@ -59,5 +60,5 @@ function N({
59
60
  );
60
61
  }
61
62
  export {
62
- N as AnniversaryCard
63
+ T as AnniversaryCard
63
64
  };
@@ -10,8 +10,8 @@ function P({
10
10
  imageAlt: o,
11
11
  shopThumbnailUrl: s,
12
12
  shopName: a,
13
- status: c = "available",
14
- onAcquire: n,
13
+ status: n = "available",
14
+ onAcquire: c,
15
15
  acquireLabel: u = "クーポンを獲得する",
16
16
  layout: p = "vertical",
17
17
  limitLabel: f,
@@ -27,8 +27,8 @@ function P({
27
27
  limitLabel: f,
28
28
  conditionText: b,
29
29
  expiryText: x,
30
- status: c,
31
- onAcquire: n,
30
+ status: n,
31
+ onAcquire: c,
32
32
  className: m,
33
33
  ...v
34
34
  }
@@ -38,7 +38,7 @@ function P({
38
38
  "data-slot": "coupon-card",
39
39
  className: d(
40
40
  "min-w-[200px] overflow-hidden rounded-xl border border-[var(--Border-Medium-Emphasis)] bg-[var(--Surface-Primary)]",
41
- c === "unavailable" && "opacity-50",
41
+ n === "unavailable" && "opacity-50",
42
42
  m
43
43
  ),
44
44
  ...v,
@@ -68,7 +68,7 @@ function P({
68
68
  t && /* @__PURE__ */ e("p", { className: "mt-1 break-words typo-body-md text-[var(--Text-Medium-Emphasis)]", children: t })
69
69
  ] }),
70
70
  /* @__PURE__ */ e("div", { className: "px-4 py-3", children: /* @__PURE__ */ e("div", { className: "border-t border-dashed border-[var(--Border-Medium-Emphasis)]" }) }),
71
- /* @__PURE__ */ e("div", { className: "px-4 pb-4", children: /* @__PURE__ */ e(h, { status: c, onAcquire: n, label: u, size: "lg" }) })
71
+ /* @__PURE__ */ e("div", { className: "px-4 pb-4", children: /* @__PURE__ */ e(h, { status: n, onAcquire: c, label: u, size: "lg" }) })
72
72
  ]
73
73
  }
74
74
  );
@@ -80,16 +80,16 @@ function w({
80
80
  expiryText: o,
81
81
  status: s = "available",
82
82
  onAcquire: a,
83
- className: c,
84
- ...n
83
+ className: n,
84
+ ...c
85
85
  }) {
86
86
  return /* @__PURE__ */ i(
87
87
  "div",
88
88
  {
89
89
  "data-slot": "coupon-card",
90
90
  "data-layout": "horizontal",
91
- className: d("flex items-stretch min-w-0 overflow-hidden", c),
92
- ...n,
91
+ className: d("flex items-stretch min-w-0 overflow-hidden", n),
92
+ ...c,
93
93
  children: [
94
94
  /* @__PURE__ */ i("div", { className: "flex min-w-0 flex-1 flex-col items-start justify-center gap-1 rounded-l-lg border-b border-l border-t border-[var(--Border-Medium-Emphasis)] bg-[var(--Surface-Primary)] px-3 py-2", children: [
95
95
  t && /* @__PURE__ */ e("span", { className: "shrink-0 rounded-full bg-[var(--Surface-Accent-Primary-Light)] px-2 py-0.5 typo-body-sm text-[var(--Text-Accent-Primary)]", children: t }),
@@ -126,7 +126,7 @@ function h({
126
126
  l
127
127
  ]
128
128
  }
129
- ) : r === "acquiring" ? /* @__PURE__ */ e("div", { className: d(a, "bg-[var(--Brand-Cake-Orange)] text-[var(--Text-on-Inverse)]"), children: /* @__PURE__ */ e(g, { className: "size-5 animate-spin" }) }) : r === "acquired" ? /* @__PURE__ */ i("div", { className: d(a, "bg-[var(--Surface-Secondary)] text-[var(--Text-Medium-Emphasis)] animate-in fade-in duration-[var(--Motion-Duration-Slow)] gap-1.5"), children: [
129
+ ) : r === "acquiring" ? /* @__PURE__ */ e("div", { className: d(a, "bg-[var(--Brand-Cake-Orange)] text-[var(--Text-on-Inverse)]"), children: /* @__PURE__ */ e(g, { className: "size-5 animate-spin motion-reduce:animate-none" }) }) : r === "acquired" ? /* @__PURE__ */ i("div", { className: d(a, "bg-[var(--Surface-Secondary)] text-[var(--Text-Medium-Emphasis)] animate-in fade-in duration-[var(--Motion-Duration-Slow)] gap-1.5"), children: [
130
130
  /* @__PURE__ */ e(N, { className: "size-4" }),
131
131
  "獲得済み"
132
132
  ] }) : /* @__PURE__ */ e("div", { className: d(a, "bg-[var(--Surface-Secondary)] text-[var(--Text-Low-Emphasis)]"), children: "獲得不可" });