@lt-three/love3 0.1.0 → 0.1.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.
Files changed (271) hide show
  1. package/README.md +40 -40
  2. package/dist/native/analytics/animation.d.ts +1 -1
  3. package/dist/native/analytics/animation.js +1 -1
  4. package/dist/native/analytics/chart.types.d.ts +3 -3
  5. package/dist/native/analytics/metric-card.d.ts +3 -3
  6. package/dist/native/analytics/metric-card.js +3 -3
  7. package/dist/native/analytics/multi-line-chart.d.ts +9 -8
  8. package/dist/native/analytics/multi-line-chart.js +14 -13
  9. package/dist/native/analytics/pie-chart.d.ts +7 -7
  10. package/dist/native/analytics/pie-chart.js +8 -8
  11. package/dist/native/analytics/single-number.d.ts +4 -4
  12. package/dist/native/analytics/single-number.js +2 -2
  13. package/dist/native/atom/avatar.d.ts +6 -6
  14. package/dist/native/atom/avatar.js +2 -2
  15. package/dist/native/atom/badge.d.ts +5 -5
  16. package/dist/native/atom/button.d.ts +12 -12
  17. package/dist/native/atom/button.js +8 -8
  18. package/dist/native/atom/checkbox.d.ts +4 -4
  19. package/dist/native/atom/checkbox.js +2 -2
  20. package/dist/native/atom/colored-value.d.ts +4 -4
  21. package/dist/native/atom/colored-value.js +4 -4
  22. package/dist/native/atom/image.d.ts +7 -7
  23. package/dist/native/atom/image.js +2 -2
  24. package/dist/native/atom/label.d.ts +5 -5
  25. package/dist/native/atom/label.js +2 -2
  26. package/dist/native/atom/link.d.ts +5 -5
  27. package/dist/native/atom/link.js +5 -5
  28. package/dist/native/atom/readout.d.ts +7 -7
  29. package/dist/native/atom/readout.js +3 -3
  30. package/dist/native/atom/search-input.d.ts +2 -2
  31. package/dist/native/atom/search-input.js +2 -2
  32. package/dist/native/atom/select.d.ts +14 -14
  33. package/dist/native/atom/select.js +8 -8
  34. package/dist/native/atom/separator.d.ts +2 -3
  35. package/dist/native/atom/separator.js +2 -3
  36. package/dist/native/atom/skeleton.d.ts +3 -3
  37. package/dist/native/atom/skeleton.js +3 -3
  38. package/dist/native/atom/slider.d.ts +6 -6
  39. package/dist/native/atom/slider.js +3 -3
  40. package/dist/native/atom/spinner.d.ts +4 -4
  41. package/dist/native/atom/spinner.js +2 -2
  42. package/dist/native/atom/switch.d.ts +4 -4
  43. package/dist/native/atom/switch.js +3 -3
  44. package/dist/native/atom/symbol.d.ts +7 -7
  45. package/dist/native/atom/symbol.js +7 -7
  46. package/dist/native/atom/symbol.types.d.ts +8 -8
  47. package/dist/native/atom/symbol.types.js +7 -7
  48. package/dist/native/atom/text-field.d.ts +15 -15
  49. package/dist/native/atom/text-field.js +5 -5
  50. package/dist/native/atom/theme-toggle.d.ts +7 -7
  51. package/dist/native/atom/theme-toggle.js +4 -4
  52. package/dist/native/atom/timezone-select.d.ts +5 -5
  53. package/dist/native/atom/timezone-select.js +4 -4
  54. package/dist/native/atom/typography.d.ts +2 -2
  55. package/dist/native/atom/typography.js +2 -2
  56. package/dist/native/base/button.d.ts +13 -13
  57. package/dist/native/base/button.js +4 -4
  58. package/dist/native/base/form.d.ts +15 -15
  59. package/dist/native/base/form.js +11 -11
  60. package/dist/native/base/glass-card.d.ts +3 -3
  61. package/dist/native/base/glass-card.js +3 -3
  62. package/dist/native/base/input.d.ts +8 -8
  63. package/dist/native/base/input.js +7 -7
  64. package/dist/native/base/sheet.d.ts +27 -27
  65. package/dist/native/base/sheet.js +15 -15
  66. package/dist/native/form/checkbox.d.ts +3 -3
  67. package/dist/native/form/checkbox.js +2 -2
  68. package/dist/native/form/date-picker.d.ts +9 -9
  69. package/dist/native/form/date-picker.js +9 -9
  70. package/dist/native/form/form.d.ts +5 -6
  71. package/dist/native/form/form.js +4 -5
  72. package/dist/native/form/radio-group.d.ts +5 -5
  73. package/dist/native/form/radio-group.js +4 -4
  74. package/dist/native/form/select.d.ts +2 -2
  75. package/dist/native/form/select.js +2 -2
  76. package/dist/native/form/slider.d.ts +2 -2
  77. package/dist/native/form/slider.js +2 -2
  78. package/dist/native/form/switch.d.ts +2 -2
  79. package/dist/native/form/switch.js +2 -2
  80. package/dist/native/form/text-area.d.ts +2 -2
  81. package/dist/native/form/text-area.js +1 -1
  82. package/dist/native/form/text-input.d.ts +5 -5
  83. package/dist/native/form/text-input.js +8 -8
  84. package/dist/native/layout/accordion.d.ts +5 -5
  85. package/dist/native/layout/accordion.js +2 -2
  86. package/dist/native/layout/card.d.ts +8 -8
  87. package/dist/native/layout/card.js +3 -3
  88. package/dist/native/layout/description.d.ts +2 -2
  89. package/dist/native/layout/description.js +2 -2
  90. package/dist/native/layout/error.d.ts +5 -5
  91. package/dist/native/layout/error.js +2 -2
  92. package/dist/native/layout/information.d.ts +4 -4
  93. package/dist/native/layout/information.js +3 -3
  94. package/dist/native/layout/locked.d.ts +15 -15
  95. package/dist/native/layout/locked.js +7 -7
  96. package/dist/native/layout/modal.d.ts +8 -8
  97. package/dist/native/layout/modal.js +5 -5
  98. package/dist/native/layout/not-found.d.ts +4 -4
  99. package/dist/native/layout/not-found.js +3 -3
  100. package/dist/native/layout/page-frame.d.ts +8 -8
  101. package/dist/native/layout/page-frame.js +3 -3
  102. package/dist/native/layout/panel.d.ts +5 -5
  103. package/dist/native/layout/panel.js +5 -5
  104. package/dist/native/layout/reorderable-list.d.ts +14 -14
  105. package/dist/native/layout/reorderable-list.js +10 -10
  106. package/dist/native/layout/sheet.d.ts +10 -10
  107. package/dist/native/layout/sheet.js +4 -4
  108. package/dist/native/layout/simple-dialog.d.ts +3 -3
  109. package/dist/native/layout/simple-dialog.js +2 -2
  110. package/dist/native/layout/simple-table.d.ts +18 -18
  111. package/dist/native/layout/simple-table.js +1 -1
  112. package/dist/native/layout/tab-bar.d.ts +10 -10
  113. package/dist/native/layout/tab-bar.js +4 -4
  114. package/dist/native/layout/tabs.d.ts +6 -6
  115. package/dist/native/layout/tabs.js +4 -4
  116. package/dist/native/layout/tuning-panel.d.ts +10 -10
  117. package/dist/native/layout/tuning-panel.js +15 -15
  118. package/dist/native/lib/autocomplete.d.ts +1 -1
  119. package/dist/native/lib/autocomplete.js +1 -1
  120. package/dist/native/lib/breakpoints.d.ts +3 -3
  121. package/dist/native/lib/breakpoints.js +3 -3
  122. package/dist/native/lib/chart-palette.d.ts +2 -2
  123. package/dist/native/lib/chart-palette.js +2 -2
  124. package/dist/native/lib/confirm.d.ts +15 -16
  125. package/dist/native/lib/confirm.js +9 -10
  126. package/dist/native/lib/control.d.ts +9 -9
  127. package/dist/native/lib/external-store.d.ts +4 -5
  128. package/dist/native/lib/keyboard.d.ts +7 -7
  129. package/dist/native/lib/keyboard.js +7 -7
  130. package/dist/native/lib/labels.d.ts +6 -6
  131. package/dist/native/lib/labels.js +6 -6
  132. package/dist/native/lib/loading.d.ts +3 -3
  133. package/dist/native/lib/loading.js +3 -3
  134. package/dist/native/lib/network.d.ts +5 -6
  135. package/dist/native/lib/network.js +5 -6
  136. package/dist/native/lib/scheme.d.ts +7 -7
  137. package/dist/native/lib/scheme.js +3 -3
  138. package/dist/native/lib/snackbar.d.ts +12 -13
  139. package/dist/native/lib/snackbar.js +7 -8
  140. package/dist/native/lib/theme.d.ts +15 -15
  141. package/dist/native/lib/theme.js +15 -15
  142. package/dist/native/lib/timezone.d.ts +13 -13
  143. package/dist/native/lib/timezone.js +13 -13
  144. package/dist/native/lib/token-color.d.ts +1 -1
  145. package/dist/native/lib/token-color.js +1 -1
  146. package/dist/native/lib/tuning-context.d.ts +2 -2
  147. package/dist/native/lib/tuning.d.ts +10 -10
  148. package/dist/native/lib/tuning.js +8 -8
  149. package/dist/native/lib/typography.d.ts +3 -3
  150. package/dist/native/lib/typography.js +3 -3
  151. package/dist/native/lib/utils.d.ts +3 -3
  152. package/dist/native/lib/utils.js +3 -3
  153. package/dist/native/once/confirm.d.ts +2 -2
  154. package/dist/native/once/confirm.js +2 -2
  155. package/dist/native/once/error-boundary.d.ts +3 -3
  156. package/dist/native/once/error-boundary.js +2 -2
  157. package/dist/native/once/loading-lock.d.ts +3 -3
  158. package/dist/native/once/loading-lock.js +3 -3
  159. package/dist/native/once/offline-banner.d.ts +6 -6
  160. package/dist/native/once/offline-banner.js +5 -5
  161. package/dist/native/once/snackbar.d.ts +7 -7
  162. package/dist/native/once/snackbar.js +5 -5
  163. package/dist/native/styles.css +21 -21
  164. package/dist/shared/analytics.d.ts +23 -23
  165. package/dist/shared/button.d.ts +1 -1
  166. package/dist/shared/form.d.ts +7 -7
  167. package/dist/shared/form.js +2 -2
  168. package/dist/tokens/contrast-pairs.d.ts +9 -9
  169. package/dist/tokens/contrast-pairs.js +10 -10
  170. package/dist/tokens/index.d.ts +1 -1
  171. package/dist/tokens/index.js +1 -1
  172. package/dist/tokens/styles.gen.css +87 -87
  173. package/dist/tokens/tokens.gen.d.ts +2 -2
  174. package/dist/tokens/tokens.gen.js +2 -2
  175. package/dist/tuning/catalog.d.ts +8 -8
  176. package/dist/tuning/catalog.js +9 -9
  177. package/dist/tuning/color.d.ts +4 -4
  178. package/dist/tuning/color.js +5 -5
  179. package/dist/tuning/css.d.ts +13 -13
  180. package/dist/tuning/css.js +17 -17
  181. package/dist/tuning/model.d.ts +11 -11
  182. package/dist/tuning/model.js +11 -11
  183. package/dist/tuning/native.d.ts +18 -18
  184. package/dist/tuning/native.js +18 -18
  185. package/dist/tuning/schema.d.ts +15 -15
  186. package/dist/tuning/schema.js +22 -22
  187. package/dist/tuning/types.d.ts +25 -25
  188. package/dist/tuning/types.js +6 -6
  189. package/dist/web/analytics/line-chart.d.ts +6 -6
  190. package/dist/web/analytics/line-chart.js +3 -3
  191. package/dist/web/analytics/metric-card.d.ts +6 -6
  192. package/dist/web/analytics/metric-card.js +5 -5
  193. package/dist/web/analytics/multi-line-chart.d.ts +23 -23
  194. package/dist/web/analytics/multi-line-chart.js +33 -33
  195. package/dist/web/atom/avatar.d.ts +1 -1
  196. package/dist/web/atom/checkbox.d.ts +6 -6
  197. package/dist/web/atom/checkbox.js +2 -2
  198. package/dist/web/atom/colored-value.d.ts +4 -4
  199. package/dist/web/atom/colored-value.js +4 -4
  200. package/dist/web/atom/help.d.ts +1 -1
  201. package/dist/web/atom/segmented-control.d.ts +13 -14
  202. package/dist/web/atom/segmented-control.js +6 -7
  203. package/dist/web/atom/select.d.ts +7 -7
  204. package/dist/web/atom/select.js +5 -5
  205. package/dist/web/atom/slider.d.ts +3 -3
  206. package/dist/web/atom/slider.js +2 -2
  207. package/dist/web/atom/switch.d.ts +3 -3
  208. package/dist/web/atom/text-area.d.ts +9 -8
  209. package/dist/web/atom/text-area.js +9 -8
  210. package/dist/web/atom/text-field.d.ts +5 -4
  211. package/dist/web/atom/text-field.js +5 -4
  212. package/dist/web/atom/toggle-chip.d.ts +6 -6
  213. package/dist/web/atom/toggle-chip.js +4 -4
  214. package/dist/web/atom/tooltip.d.ts +6 -6
  215. package/dist/web/atom/tooltip.js +2 -2
  216. package/dist/web/base/accordion.js +1 -1
  217. package/dist/web/base/breadcrumb.d.ts +1 -1
  218. package/dist/web/base/breadcrumb.js +1 -1
  219. package/dist/web/base/card.d.ts +3 -3
  220. package/dist/web/base/card.js +2 -2
  221. package/dist/web/base/dialog.d.ts +1 -1
  222. package/dist/web/base/dialog.js +1 -1
  223. package/dist/web/base/form.d.ts +7 -7
  224. package/dist/web/base/form.js +5 -5
  225. package/dist/web/base/pagination.d.ts +5 -5
  226. package/dist/web/base/pagination.js +1 -1
  227. package/dist/web/base/sheet.d.ts +1 -1
  228. package/dist/web/base/sheet.js +1 -1
  229. package/dist/web/base/slider.d.ts +1 -1
  230. package/dist/web/base/sonner.d.ts +2 -2
  231. package/dist/web/base/sonner.js +2 -2
  232. package/dist/web/base/spinner.js +1 -1
  233. package/dist/web/form/checkbox.d.ts +8 -8
  234. package/dist/web/form/checkbox.js +3 -3
  235. package/dist/web/form/radio-group.js +3 -3
  236. package/dist/web/form/select.js +1 -1
  237. package/dist/web/form/slider.d.ts +3 -3
  238. package/dist/web/form/slider.js +3 -3
  239. package/dist/web/form/switch.d.ts +3 -3
  240. package/dist/web/form/switch.js +4 -4
  241. package/dist/web/form/text-area.js +1 -1
  242. package/dist/web/form/text-input.d.ts +1 -1
  243. package/dist/web/form/text-input.js +1 -1
  244. package/dist/web/layout/accordion.d.ts +5 -5
  245. package/dist/web/layout/accordion.js +2 -2
  246. package/dist/web/layout/alert-modal.d.ts +11 -11
  247. package/dist/web/layout/alert-modal.js +7 -7
  248. package/dist/web/layout/card.d.ts +1 -1
  249. package/dist/web/layout/information.d.ts +9 -9
  250. package/dist/web/layout/information.js +7 -7
  251. package/dist/web/layout/modal.d.ts +1 -1
  252. package/dist/web/layout/page-frame.d.ts +14 -14
  253. package/dist/web/layout/page-frame.js +7 -7
  254. package/dist/web/layout/scroll-area.d.ts +1 -1
  255. package/dist/web/layout/sheet.d.ts +4 -4
  256. package/dist/web/layout/simple-table.d.ts +18 -18
  257. package/dist/web/layout/simple-table.js +2 -2
  258. package/dist/web/layout/tabs.d.ts +4 -4
  259. package/dist/web/layout/titled-modal.d.ts +10 -11
  260. package/dist/web/layout/titled-modal.js +7 -8
  261. package/dist/web/lib/css-vars.d.ts +6 -6
  262. package/dist/web/lib/css-vars.js +5 -5
  263. package/dist/web/lib/dialog.d.ts +4 -4
  264. package/dist/web/lib/labels.d.ts +8 -8
  265. package/dist/web/lib/labels.js +8 -8
  266. package/dist/web/lib/modal-open-focus.d.ts +7 -7
  267. package/dist/web/lib/modal-open-focus.js +9 -9
  268. package/dist/web/lib/restore-focus.d.ts +4 -4
  269. package/dist/web/lib/restore-focus.js +4 -4
  270. package/dist/web/styles.css +33 -33
  271. package/package.json +2 -2
@@ -10,19 +10,19 @@ export type TabType = {
10
10
  export type TabsProps = {
11
11
  tabs: TabType;
12
12
  defaultValue?: string;
13
- /** 制御モード: 外部から選択値を管理する場合に指定する。 */
13
+ /** Controlled mode: specify it to manage the selected value from outside. */
14
14
  value?: string;
15
15
  onValueChange?: (value: string) => void;
16
- /** タブ列と同じ行の右端に置くスロット(ツールバー的に使う)。 */
16
+ /** Slot placed at the right end of the same row as the tab strip (used like a toolbar). */
17
17
  trailing?: ReactNode;
18
18
  className?: string;
19
19
  };
20
20
  /**
21
- * `@lt-three/web` の layout/tabs と同じレコード駆動の API を持つタブ。
22
- * 見た目は web の base/tabs に揃えたフラッシュレフトの下線タブで、
23
- * 共有の薄い罫線の上にアクティブの 2px インディゴ下線が乗る。
21
+ * Tabs with the same record-driven API as the web `layout/tabs`.
22
+ * Visually they are flush-left underlined tabs matching the web base/tabs:
23
+ * a 2px indigo underline for the active tab sits on a shared faint rule.
24
24
  *
25
- * タブ数が増えても折り返さないよう横スクロールする(web の `flex-wrap` の代わり)。
25
+ * They scroll horizontally so they never wrap as the tab count grows (instead of web's `flex-wrap`).
26
26
  */
27
27
  export declare function Tabs({ tabs, defaultValue, value, onValueChange, trailing, className }: TabsProps): import("react").JSX.Element;
28
28
  //#endregion
@@ -6,11 +6,11 @@ import { jsx, jsxs } from "react/jsx-runtime";
6
6
 
7
7
  //#region src/native/layout/tabs.tsx
8
8
  /**
9
- * `@lt-three/web` の layout/tabs と同じレコード駆動の API を持つタブ。
10
- * 見た目は web の base/tabs に揃えたフラッシュレフトの下線タブで、
11
- * 共有の薄い罫線の上にアクティブの 2px インディゴ下線が乗る。
9
+ * Tabs with the same record-driven API as the web `layout/tabs`.
10
+ * Visually they are flush-left underlined tabs matching the web base/tabs:
11
+ * a 2px indigo underline for the active tab sits on a shared faint rule.
12
12
  *
13
- * タブ数が増えても折り返さないよう横スクロールする(web の `flex-wrap` の代わり)。
13
+ * They scroll horizontally so they never wrap as the tab count grows (instead of web's `flex-wrap`).
14
14
  */
15
15
  function Tabs({ tabs, defaultValue, value, onValueChange, trailing, className }) {
16
16
  const keys = Object.keys(tabs);
@@ -1,24 +1,24 @@
1
1
  import { Tuning, TuningCatalog } from "../../tuning/types.js";
2
2
  //#region src/native/layout/tuning-panel.d.ts
3
3
  export type TuningPanelProps = {
4
- /** 調整の内容(既定との差分)。保存先はアプリが持つ。 */
4
+ /** The tuning content (the difference from the defaults). Where it is stored is up to the app. */
5
5
  tuning: Tuning;
6
6
  onChange: (next: Tuning) => void;
7
- /** 調整の対象。既定は love3 の生成物。 */
7
+ /** What is tuned. Defaults to love3's generated output. */
8
8
  catalog?: TuningCatalog;
9
- /** 書き出したとき(コピー・共有などはアプリが決める)。JSON の文字列が渡る。 */
9
+ /** Called on export (copying, sharing, etc. is up to the app). Receives the JSON string. */
10
10
  onExport?: (json: string) => void;
11
11
  };
12
12
  /**
13
- * native の調整の画面(最小限)。トークンを動かし、`love3-tuning` の JSON で書き出し・読み込みする。web の `/tuning` と同じ形式。
13
+ * The native tuning screen (minimal). Moves tokens and exports/imports them as `love3-tuning` JSON, the same format as web's `/tuning`.
14
14
  *
15
- * - 色: 今のテーマ(ライト・ダーク)の値を 16 進で編集する。読めない値は赤い枠のままで、適用しない
16
- * - 角丸: 役割ごとに px(実機ではビルド時に固定されるので効かない。JSON には残る)
17
- * - JSON: 「書き出す」で今の調整を欄に出し(`onExport` にも渡す)、「読み込む」で欄の JSON を検証して適用する。
18
- * 1 つでも不正なら全体を断り、理由を出す(部分適用しない)
19
- * - 実機で効かない項目は、`nativeLimits` の説明を出す
15
+ * - Colors: edits the current theme's (light or dark) values in hex. An unreadable value keeps a red border and is not applied
16
+ * - Radius: px per role (fixed at build time on real devices, so it has no effect there; it remains in the JSON)
17
+ * - JSON: "書き出す" (Export) puts the current tuning in the field (and also passes it to `onExport`); "読み込む" (Import) validates the JSON in the field and applies it.
18
+ * If even one entry is invalid, the whole input is rejected and the reasons are shown (no partial application)
19
+ * - For items that have no effect on real devices, the `nativeLimits` explanation is shown
20
20
  *
21
- * 作り込みはしない(love3 の native 部品だけで組んだ検証用)。
21
+ * It is not polished (a verification screen built only from love3's native components).
22
22
  */
23
23
  export declare function TuningPanel({ tuning, onChange, catalog, onExport }: TuningPanelProps): import("react").JSX.Element;
24
24
  //#endregion
@@ -15,7 +15,7 @@ import { View } from "react-native";
15
15
  import { jsx, jsxs } from "react/jsx-runtime";
16
16
 
17
17
  //#region src/native/layout/tuning-panel.tsx
18
- /** 色の編集に出すトークンの区分(ランプ・主操作・状態・チャート。ブランド色は共通なので別)。 */
18
+ /** Token groups shown in the color editor (ramp, primary action, state, chart; brand colors are shared, so they are separate). */
19
19
  const EDITABLE_GROUPS = /* @__PURE__ */ new Set([
20
20
  "ramp",
21
21
  "action",
@@ -23,15 +23,15 @@ const EDITABLE_GROUPS = /* @__PURE__ */ new Set([
23
23
  "chart"
24
24
  ]);
25
25
  /**
26
- * native の調整の画面(最小限)。トークンを動かし、`love3-tuning` の JSON で書き出し・読み込みする。web の `/tuning` と同じ形式。
26
+ * The native tuning screen (minimal). Moves tokens and exports/imports them as `love3-tuning` JSON, the same format as web's `/tuning`.
27
27
  *
28
- * - 色: 今のテーマ(ライト・ダーク)の値を 16 進で編集する。読めない値は赤い枠のままで、適用しない
29
- * - 角丸: 役割ごとに px(実機ではビルド時に固定されるので効かない。JSON には残る)
30
- * - JSON: 「書き出す」で今の調整を欄に出し(`onExport` にも渡す)、「読み込む」で欄の JSON を検証して適用する。
31
- * 1 つでも不正なら全体を断り、理由を出す(部分適用しない)
32
- * - 実機で効かない項目は、`nativeLimits` の説明を出す
28
+ * - Colors: edits the current theme's (light or dark) values in hex. An unreadable value keeps a red border and is not applied
29
+ * - Radius: px per role (fixed at build time on real devices, so it has no effect there; it remains in the JSON)
30
+ * - JSON: "書き出す" (Export) puts the current tuning in the field (and also passes it to `onExport`); "読み込む" (Import) validates the JSON in the field and applies it.
31
+ * If even one entry is invalid, the whole input is rejected and the reasons are shown (no partial application)
32
+ * - For items that have no effect on real devices, the `nativeLimits` explanation is shown
33
33
  *
34
- * 作り込みはしない(love3 の native 部品だけで組んだ検証用)。
34
+ * It is not polished (a verification screen built only from love3's native components).
35
35
  */
36
36
  function TuningPanel({ tuning, onChange, catalog: catalog$1 = catalog, onExport }) {
37
37
  const scheme = useActiveScheme();
@@ -152,7 +152,7 @@ function TuningPanel({ tuning, onChange, catalog: catalog$1 = catalog, onExport
152
152
  ]
153
153
  });
154
154
  }
155
- /** 入力が読めないときの理由。行の下に `role="alert"` で出し、入力欄から `aria-describedby` で結ぶ。 */
155
+ /** The reason shown when the input is unreadable. Rendered under the row with `role="alert"` and linked from the input via `aria-describedby`. */
156
156
  function Reason({ id, text }) {
157
157
  return /* @__PURE__ */ jsx(Text$1, {
158
158
  id,
@@ -162,10 +162,10 @@ function Reason({ id, text }) {
162
162
  });
163
163
  }
164
164
  /**
165
- * 色 1 件。**入力中の文字(draft)を自分で持ち、フォーカスが外れるまで欄に出し続ける**(`#abc` は有効な 3 桁の形だが、
166
- * 6 桁の途中でもある。反映した値で欄を置き換えると、6 桁を打ち切れない)。読める値になったら、打つたびに反映する
167
- * (反映した値は正規の形 `#aabbcc` になるが、欄には打った文字のまま)。外れたら、反映した値(正規の形)を欄に出す。
168
- * 読めない値は理由を出し、反映しない。
165
+ * One color. **Keeps its own in-progress text (draft) and keeps showing it in the field until focus leaves** (`#abc` is a valid 3-digit form
166
+ * but may also be partway through a 6-digit one; replacing the field with the applied value would make it impossible to finish typing 6 digits). Once the value is readable, it is applied on every keystroke
167
+ * (the applied value takes the canonical form `#aabbcc`, but the field keeps the text as typed). On blur, the applied value (canonical form) is shown in the field.
168
+ * An unreadable value shows a reason and is not applied.
169
169
  */
170
170
  function ColorRow({ name, value, alpha, onCommit }) {
171
171
  const reasonId = useId();
@@ -202,13 +202,13 @@ function ColorRow({ name, value, alpha, onCommit }) {
202
202
  })]
203
203
  });
204
204
  }
205
- /** 角丸の入力の問題(読めて、範囲内なら undefined)。 */
205
+ /** The problem with a radius input (undefined if it is readable and within range). */
206
206
  function radiusProblem(text) {
207
207
  const number = Number(text);
208
208
  if (text.trim() === "" || !Number.isFinite(number)) return `角丸は数で入力してください(0〜${64})`;
209
209
  if (number < 0 || number > 64) return `角丸は 0〜${64} の数で入力してください(実際: ${text})`;
210
210
  }
211
- /** 角丸 1 件。色と同じく、入力中の文字(`6.` など)は外れるまで欄に出し続ける。 */
211
+ /** One radius. As with colors, in-progress text (such as `6.`) keeps showing in the field until focus leaves. */
212
212
  function RadiusRow({ role, value, onCommit }) {
213
213
  const reasonId = useId();
214
214
  const [draft, setDraft] = useState(null);
@@ -2,6 +2,6 @@ import { TextInputProps } from "react-native";
2
2
  //#region src/native/lib/autocomplete.d.ts
3
3
  export type AutoComplete = NonNullable<TextInputProps["autoComplete"]>;
4
4
  export type TextContentType = NonNullable<TextInputProps["textContentType"]>;
5
- /** iOS の `textContentType`。対応する語が無ければ `undefined`(iOS の既定に任せる)。 */
5
+ /** iOS `textContentType`. `undefined` if there is no corresponding word (leave it to the iOS default). */
6
6
  export declare function textContentTypeOf(autoComplete: AutoComplete | undefined): TextContentType | undefined;
7
7
  //#endregion
@@ -25,7 +25,7 @@ const CONTENT_TYPE = {
25
25
  "cc-number": "creditCardNumber",
26
26
  off: "none"
27
27
  };
28
- /** iOS の `textContentType`。対応する語が無ければ `undefined`(iOS の既定に任せる)。 */
28
+ /** iOS `textContentType`. `undefined` if there is no corresponding word (leave it to the iOS default). */
29
29
  function textContentTypeOf(autoComplete) {
30
30
  return autoComplete === void 0 ? void 0 : CONTENT_TYPE[autoComplete];
31
31
  }
@@ -1,5 +1,5 @@
1
1
  //#region src/native/lib/breakpoints.d.ts
2
- /** web(Tailwind)と同じブレークポイント(px)。 */
2
+ /** Same breakpoints (px) as web (Tailwind). */
3
3
  export declare const BREAKPOINT: {
4
4
  readonly sm: 640;
5
5
  readonly md: 768;
@@ -7,8 +7,8 @@ export declare const BREAKPOINT: {
7
7
  };
8
8
  export type Breakpoint = keyof typeof BREAKPOINT;
9
9
  /**
10
- * `hideBelow` の列を、この画面の幅で出すか。ブレークポイントちょうどの幅は**出す**(Tailwind の `sm:` は 640px 以上)。
11
- * 指定が無ければ常に出す。
10
+ * Whether to show a `hideBelow` column at this screen width. A width exactly at the breakpoint **shows** it (Tailwind's `sm:` is 640px and up).
11
+ * If unspecified, always shown.
12
12
  */
13
13
  export declare function isShownAtWidth(hideBelow: Breakpoint | undefined, width: number): boolean;
14
14
  //#endregion
@@ -1,13 +1,13 @@
1
1
  //#region src/native/lib/breakpoints.ts
2
- /** web(Tailwind)と同じブレークポイント(px)。 */
2
+ /** Same breakpoints (px) as web (Tailwind). */
3
3
  const BREAKPOINT = {
4
4
  sm: 640,
5
5
  md: 768,
6
6
  lg: 1024
7
7
  };
8
8
  /**
9
- * `hideBelow` の列を、この画面の幅で出すか。ブレークポイントちょうどの幅は**出す**(Tailwind の `sm:` は 640px 以上)。
10
- * 指定が無ければ常に出す。
9
+ * Whether to show a `hideBelow` column at this screen width. A width exactly at the breakpoint **shows** it (Tailwind's `sm:` is 640px and up).
10
+ * If unspecified, always shown.
11
11
  */
12
12
  function isShownAtWidth(hideBelow, width) {
13
13
  return hideBelow === void 0 || width >= BREAKPOINT[hideBelow];
@@ -1,8 +1,8 @@
1
1
  //#region src/native/lib/chart-palette.d.ts
2
2
  /**
3
- * チャートの既定配色。web の `--chart-1` 〜 `--chart-5`(色で系列を分ける 5 色。ダークでも読める別の値を持つ)と同じ順序で返す。
3
+ * Default chart colors, returned in the same order as the web `--chart-1` to `--chart-5` (five colors that separate series by hue; each has a distinct value that stays readable in dark mode).
4
4
  *
5
- * `--chart-*` は、ライト・ダークで別の値を持つ生の色のトークンなので、そのまま実値を引ける。`.dark` にも追従する。
5
+ * `--chart-*` are raw color tokens with separate light and dark values, so the actual values can be looked up directly. They also follow `.dark`.
6
6
  */
7
7
  export declare function useChartPalette(): string[];
8
8
  //#endregion
@@ -2,9 +2,9 @@ import { useTokenColor } from "./token-color.js";
2
2
 
3
3
  //#region src/native/lib/chart-palette.ts
4
4
  /**
5
- * チャートの既定配色。web の `--chart-1` 〜 `--chart-5`(色で系列を分ける 5 色。ダークでも読める別の値を持つ)と同じ順序で返す。
5
+ * Default chart colors, returned in the same order as the web `--chart-1` to `--chart-5` (five colors that separate series by hue; each has a distinct value that stays readable in dark mode).
6
6
  *
7
- * `--chart-*` は、ライト・ダークで別の値を持つ生の色のトークンなので、そのまま実値を引ける。`.dark` にも追従する。
7
+ * `--chart-*` are raw color tokens with separate light and dark values, so the actual values can be looked up directly. They also follow `.dark`.
8
8
  */
9
9
  function useChartPalette() {
10
10
  return [
@@ -11,39 +11,38 @@ export type ConfirmDialogValue = {
11
11
  title?: string;
12
12
  description?: string;
13
13
  buttons?: ConfirmDialogButton[];
14
- /** 外側を押したとき。未指定なら閉じない。`close` を呼ぶと閉じる。 */
14
+ /** When the outside is pressed. If unspecified, it does not close. Calling `close` closes it. */
15
15
  onOutsideClick?: (close: () => void) => void;
16
16
  /**
17
- * ボタンを押さずに閉じられたとき(Escape・Android の戻る操作など)に描画側が呼ぶ。
18
- * `confirm()` はこれで false を解決し、待っている呼び出し側が固まらないようにする。
17
+ * Called by the renderer when it is dismissed without a button press (Escape, the Android back action, etc.).
18
+ * `confirm()` resolves false with it so that the waiting caller does not hang.
19
19
  */
20
20
  onDismiss?: () => void;
21
21
  };
22
- /** `ConfirmDialog` が読む状態。命令的な API(`confirm()`)がここへ書く。 */
22
+ /** State read by `ConfirmDialog`. The imperative API (`confirm()`) writes here. */
23
23
  export declare const confirmDialogStore: ExternalStore<ConfirmDialogValue>;
24
- /** 開いている確認ダイアログを閉じる(内容は残す。閉じるアニメーションの間、文字が消えないように)。 */
24
+ /** Closes the open confirm dialog (keeps its content, so the text does not vanish during the closing animation). */
25
25
  export declare function closeConfirmDialog(): void;
26
26
  /**
27
- * `ConfirmDialog` がマウントされている間だけ呼ぶ(`once/confirm` が effect で呼ぶ)。戻り値は解除。
28
- * **最後の 1 つが外れたとき、開いたままの確認は false で解決して閉じる**(開いたまま unmount すると、待っている呼び出し側が
29
- * 固まり、次にマウントしたときに古い確認が出てしまう)。
27
+ * Call only while a `ConfirmDialog` is mounted (`once/confirm` calls it in an effect). Returns an unsubscribe function.
28
+ * **When the last one detaches, a confirm left open is resolved with false and closed** (if it unmounted while open, the waiting caller would
29
+ * hang, and an old confirm would appear the next time one mounts).
30
30
  */
31
31
  export declare function registerConfirmDialog(): () => void;
32
32
  export type ConfirmOptions = {
33
33
  description?: string;
34
- /** 「はい」側のボタンの文言(既定「はい」)。 */
34
+ /** Label of the "yes" button (default "はい"). */
35
35
  yes?: string;
36
- /** 「いいえ」側のボタンの文言(既定「いいえ」)。 */
36
+ /** Label of the "no" button (default "いいえ"). */
37
37
  no?: string;
38
- /** 取り消せない操作の確認では `destructive` を渡し、見た目でも危険だと分かるようにする。 */
38
+ /** Pass `destructive` for confirming irreversible actions, so it also looks dangerous. */
39
39
  yesVariant?: ButtonProps["variant"];
40
40
  };
41
41
  /**
42
- * 確認ダイアログを開き、押されたボタンで解決する(はい = true、いいえ・外側・戻る操作 = false)。
43
- * アプリのルートに `once/confirm` の `ConfirmDialog` を 1 つ置いておく(**置いていないと、開かず、解決もしない**。開発時は警告を出す。
44
- * 後から置くと、その時点で開く)。
45
- * 移植元の `@lt-three/core` の `confirm(i18n, message, options)` から、i18n の引数を外した
46
- * (love3 は i18n に依存しない。文言は `yes` / `no` で渡し、既定は日本語)。
42
+ * Opens a confirm dialog and resolves with the pressed button (yes = true; no, outside press, back action = false).
43
+ * Place one `ConfirmDialog` from `once/confirm` at the app root (**without it, it neither opens nor resolves**; a warning is logged in development.
44
+ * If placed later, it opens at that point).
45
+ * Takes no i18n argument: love3 does not depend on i18n, text is passed as `yes` / `no`, and the defaults are Japanese.
47
46
  */
48
47
  export declare function confirm(message: string, options?: ConfirmOptions): Promise<boolean>;
49
48
  //#endregion
@@ -2,9 +2,9 @@ import { NO_LABEL, YES_LABEL } from "./labels.js";
2
2
  import { createExternalStore } from "./external-store.js";
3
3
 
4
4
  //#region src/native/lib/confirm.ts
5
- /** `ConfirmDialog` が読む状態。命令的な API(`confirm()`)がここへ書く。 */
5
+ /** State read by `ConfirmDialog`. The imperative API (`confirm()`) writes here. */
6
6
  const confirmDialogStore = createExternalStore({ isOpen: false });
7
- /** 開いている確認ダイアログを閉じる(内容は残す。閉じるアニメーションの間、文字が消えないように)。 */
7
+ /** Closes the open confirm dialog (keeps its content, so the text does not vanish during the closing animation). */
8
8
  function closeConfirmDialog() {
9
9
  confirmDialogStore.update((prev) => ({
10
10
  ...prev,
@@ -13,9 +13,9 @@ function closeConfirmDialog() {
13
13
  }
14
14
  let mountedDialogs = 0;
15
15
  /**
16
- * `ConfirmDialog` がマウントされている間だけ呼ぶ(`once/confirm` が effect で呼ぶ)。戻り値は解除。
17
- * **最後の 1 つが外れたとき、開いたままの確認は false で解決して閉じる**(開いたまま unmount すると、待っている呼び出し側が
18
- * 固まり、次にマウントしたときに古い確認が出てしまう)。
16
+ * Call only while a `ConfirmDialog` is mounted (`once/confirm` calls it in an effect). Returns an unsubscribe function.
17
+ * **When the last one detaches, a confirm left open is resolved with false and closed** (if it unmounted while open, the waiting caller would
18
+ * hang, and an old confirm would appear the next time one mounts).
19
19
  */
20
20
  function registerConfirmDialog() {
21
21
  mountedDialogs += 1;
@@ -28,11 +28,10 @@ function registerConfirmDialog() {
28
28
  }
29
29
  let pendingResolve = null;
30
30
  /**
31
- * 確認ダイアログを開き、押されたボタンで解決する(はい = true、いいえ・外側・戻る操作 = false)。
32
- * アプリのルートに `once/confirm` の `ConfirmDialog` を 1 つ置いておく(**置いていないと、開かず、解決もしない**。開発時は警告を出す。
33
- * 後から置くと、その時点で開く)。
34
- * 移植元の `@lt-three/core` の `confirm(i18n, message, options)` から、i18n の引数を外した
35
- * (love3 は i18n に依存しない。文言は `yes` / `no` で渡し、既定は日本語)。
31
+ * Opens a confirm dialog and resolves with the pressed button (yes = true; no, outside press, back action = false).
32
+ * Place one `ConfirmDialog` from `once/confirm` at the app root (**without it, it neither opens nor resolves**; a warning is logged in development.
33
+ * If placed later, it opens at that point).
34
+ * Takes no i18n argument: love3 does not depend on i18n, text is passed as `yes` / `no`, and the defaults are Japanese.
36
35
  */
37
36
  function confirm(message, options) {
38
37
  const { description, yes, no, yesVariant } = options ?? {};
@@ -1,12 +1,12 @@
1
1
  //#region src/native/lib/control.d.ts
2
2
  /**
3
- * 入力の部品(`atom/text-field` `checkbox` `switch` `slider`)が、フォームの外装(`base/form` の `FormControl`)から受け取る
4
- * アクセシビリティの props。web の `FormControl`(Radix の Slot が直下の入力に `id` / `aria-*` を渡す)に対応する。
3
+ * The accessibility props that input components (`atom/text-field`, `checkbox`, `switch`, `slider`) receive from the form wrapper (`FormControl` in `base/form`).
4
+ * Corresponds to the web `FormControl` (Radix's Slot passes `id` / `aria-*` to the direct child input).
5
5
  *
6
- * - `id` / `aria-labelledby` / `aria-describedby` / `aria-invalid`: react-native-web は DOM に出す(ラベルや説明との紐付けが効く)。
7
- * 実機の React Native は `aria-labelledby` を Android だけ、`aria-describedby` は読まないので、
8
- * 実機の読み上げには `accessibilityLabel` と `accessibilityHint` を渡す(フォームの部品が文字列のときに渡す)
9
- * - `accessibilityHint`: 補足(`description`)。実機の VoiceOver / TalkBack が名前のあとに読む
6
+ * - `id` / `aria-labelledby` / `aria-describedby` / `aria-invalid`: react-native-web emits them to the DOM (association with the label and description works).
7
+ * Real-device React Native honors `aria-labelledby` on Android only and does not read `aria-describedby`,
8
+ * so for real-device screen readers, pass `accessibilityLabel` and `accessibilityHint` (passed when the form's parts are strings)
9
+ * - `accessibilityHint`: supplementary text (`description`). Real-device VoiceOver / TalkBack reads it after the name
10
10
  */
11
11
  export type ControlA11yProps = {
12
12
  id?: string;
@@ -16,9 +16,9 @@ export type ControlA11yProps = {
16
16
  accessibilityHint?: string;
17
17
  };
18
18
  /**
19
- * 名前を自分で持つ入力(`atom/checkbox`=右のラベル、`atom/slider`=自分の `label`)が受ける props。
20
- * `aria-labelledby` は**型に含めない**(受け口が無いのに受けて黙って捨てない)。フォームの外装のラベルを名前にしたい入力
21
- * (`text-field`・`switch`)だけが `ControlA11yProps` の全部を受ける。
19
+ * Props received by inputs that carry their own name (`atom/checkbox` = the label on the right, `atom/slider` = its own `label`).
20
+ * `aria-labelledby` is **not included in the type** (no silently dropping what has nowhere to go). Only inputs that want the form wrapper's label as their name
21
+ * (`text-field`, `switch`) accept all of `ControlA11yProps`.
22
22
  */
23
23
  export type NamedControlA11yProps = Omit<ControlA11yProps, "aria-labelledby">;
24
24
  //#endregion
@@ -1,16 +1,15 @@
1
1
  //#region src/native/lib/external-store.d.ts
2
2
  /**
3
- * 命令的な API(`confirm()`・`globalLoading()`)と、ルートに置く部品(`ConfirmDialog`・`LoadingLock`)の橋渡しをする、
4
- * 小さな外部ストア。`@lt-three/core` は jotai の atom と共有のストアでこれをやっていたが、love3 は jotai に依存しない
5
- * ので、React の `useSyncExternalStore` で読む。値は不変で扱う(`set` は新しい値を渡す)。
3
+ * A small external store that bridges the imperative APIs (`confirm()`, `globalLoading()`) and the components placed at the root (`ConfirmDialog`, `LoadingLock`).
4
+ * love3 does not depend on jotai, so it is read with React's `useSyncExternalStore`. Treat values as immutable (`set` takes a new value).
6
5
  */
7
6
  export type ExternalStore<T> = {
8
7
  get: () => T;
9
8
  set: (next: T) => void;
10
- /** 前の値から次の値を作る。 */
9
+ /** Builds the next value from the previous one. */
11
10
  update: (updater: (prev: T) => T) => void;
12
11
  subscribe: (listener: () => void) => () => void;
13
- /** 部品から読む。値が変わると描き直す。 */
12
+ /** Read from components. Re-renders when the value changes. */
14
13
  use: () => T;
15
14
  };
16
15
  export declare function createExternalStore<T>(initial: T): ExternalStore<T>;
@@ -1,15 +1,15 @@
1
1
  import { KeyDownEvent } from "react-native";
2
2
  //#region src/native/lib/keyboard.d.ts
3
3
  /**
4
- * Space で `activate` を呼ぶ `onKeyDown`(`Pressable` に渡す)。
4
+ * An `onKeyDown` that calls `activate` on Space (pass it to `Pressable`).
5
5
  *
6
- * react-native-web の `Pressable` は、Enter では押したことになるが、Space は **`<button>` か `role="button"` のときだけ**
7
- * 押したことになる(`PressResponder` の `isValidKeyPress`)。`role="radio"` / `"checkbox"` / `"switch"` は Space で動かない。
8
- * WAI-ARIA の APG は、この 3 つを Space で決定する(キーボードだけの人が選べない = WCAG 2.1.1)。
9
- * **Enter は react-native-web が押したことにする**ので、ここでは Space だけを扱う(Enter まで扱うと二重に呼ばれる)。
6
+ * react-native-web's `Pressable` treats Enter as a press, but treats Space as a press **only for `<button>` or `role="button"`**
7
+ * (`isValidKeyPress` in `PressResponder`). `role="radio"` / `"checkbox"` / `"switch"` do not respond to Space.
8
+ * The WAI-ARIA APG decides these three with Space (without it, people using only a keyboard cannot select them; WCAG 2.1.1).
9
+ * **Enter is already handled as a press by react-native-web**, so only Space is handled here (handling Enter too would call it twice).
10
10
  *
11
- * 実機の React Native は、`onKeyDown` を受けるキーを `keyDownEvents` で挙げたものだけにするので、何も渡さないこの使い方では
12
- * 呼ばれない(実機の挙動は変わらない)。修飾キー(Ctrl・Alt・Meta・Shift)つきと、押しっぱなしの繰り返しは無視する。
11
+ * Real-device React Native only delivers keys listed in `keyDownEvents` to `onKeyDown`, so with this usage, which passes none, it is
12
+ * never called (behavior on device does not change). Presses with modifier keys (Ctrl, Alt, Meta, Shift) and held-key repeats are ignored.
13
13
  */
14
14
  export declare function activateOnSpace(activate: () => void, disabled?: boolean | null): (event: KeyDownEvent) => void;
15
15
  //#endregion
@@ -1,14 +1,14 @@
1
1
  //#region src/native/lib/keyboard.ts
2
2
  /**
3
- * Space で `activate` を呼ぶ `onKeyDown`(`Pressable` に渡す)。
3
+ * An `onKeyDown` that calls `activate` on Space (pass it to `Pressable`).
4
4
  *
5
- * react-native-web の `Pressable` は、Enter では押したことになるが、Space は **`<button>` か `role="button"` のときだけ**
6
- * 押したことになる(`PressResponder` の `isValidKeyPress`)。`role="radio"` / `"checkbox"` / `"switch"` は Space で動かない。
7
- * WAI-ARIA の APG は、この 3 つを Space で決定する(キーボードだけの人が選べない = WCAG 2.1.1)。
8
- * **Enter は react-native-web が押したことにする**ので、ここでは Space だけを扱う(Enter まで扱うと二重に呼ばれる)。
5
+ * react-native-web's `Pressable` treats Enter as a press, but treats Space as a press **only for `<button>` or `role="button"`**
6
+ * (`isValidKeyPress` in `PressResponder`). `role="radio"` / `"checkbox"` / `"switch"` do not respond to Space.
7
+ * The WAI-ARIA APG decides these three with Space (without it, people using only a keyboard cannot select them; WCAG 2.1.1).
8
+ * **Enter is already handled as a press by react-native-web**, so only Space is handled here (handling Enter too would call it twice).
9
9
  *
10
- * 実機の React Native は、`onKeyDown` を受けるキーを `keyDownEvents` で挙げたものだけにするので、何も渡さないこの使い方では
11
- * 呼ばれない(実機の挙動は変わらない)。修飾キー(Ctrl・Alt・Meta・Shift)つきと、押しっぱなしの繰り返しは無視する。
10
+ * Real-device React Native only delivers keys listed in `keyDownEvents` to `onKeyDown`, so with this usage, which passes none, it is
11
+ * never called (behavior on device does not change). Presses with modifier keys (Ctrl, Alt, Meta, Shift) and held-key repeats are ignored.
12
12
  */
13
13
  function activateOnSpace(activate, disabled) {
14
14
  return (event) => {
@@ -1,15 +1,15 @@
1
1
  //#region src/native/lib/labels.d.ts
2
- /** 読み込み中の表示(Spinner) */
2
+ /** Loading indicator (Spinner) */
3
3
  export declare const LOADING_LABEL = "読み込み中";
4
- /** 確認ダイアログ(`confirm()`)の既定のボタン。使う側は `yes` / `no` で上書きする */
4
+ /** Default buttons of the confirm dialog (`confirm()`). Callers override them with `yes` / `no` */
5
5
  export declare const YES_LABEL = "はい";
6
6
  export declare const NO_LABEL = "いいえ";
7
- /** 数値欄(`form/text-input` の `type="number"`)の入力が数として読めないとき */
7
+ /** When the input of a number field (`type="number"` of `form/text-input`) cannot be read as a number */
8
8
  export declare const NUMBER_INVALID_LABEL = "数値で入力してください";
9
- /** 閉じるボタン(Sheet・Modal・Snackbar)。使う側は `closeLabel` で上書きする */
9
+ /** Close button (Sheet, Modal, Snackbar). Callers override it with `closeLabel` */
10
10
  export declare const CLOSE_LABEL = "閉じる";
11
- /** `atom/select` の選択肢の見出し・名前が何も渡されなかったときの、最後の砦(無名のダイアログにしない) */
11
+ /** Last resort for when no heading or name was passed for the options of `atom/select` (so it never becomes an unnamed dialog) */
12
12
  export declare const SELECT_LABEL = "選択肢";
13
- /** `form/select` の placeholder の既定(web の `form/select` と同じ文言) */
13
+ /** Default placeholder of `form/select` (same wording as the web `form/select`) */
14
14
  export declare const SELECT_PLACEHOLDER_LABEL = "選択してください";
15
15
  //#endregion
@@ -1,16 +1,16 @@
1
1
  //#region src/native/lib/labels.ts
2
- /** 読み込み中の表示(Spinner) */
2
+ /** Loading indicator (Spinner) */
3
3
  const LOADING_LABEL = "読み込み中";
4
- /** 確認ダイアログ(`confirm()`)の既定のボタン。使う側は `yes` / `no` で上書きする */
4
+ /** Default buttons of the confirm dialog (`confirm()`). Callers override them with `yes` / `no` */
5
5
  const YES_LABEL = "はい";
6
6
  const NO_LABEL = "いいえ";
7
- /** 数値欄(`form/text-input` の `type="number"`)の入力が数として読めないとき */
7
+ /** When the input of a number field (`type="number"` of `form/text-input`) cannot be read as a number */
8
8
  const NUMBER_INVALID_LABEL = "数値で入力してください";
9
- /** 閉じるボタン(Sheet・Modal・Snackbar)。使う側は `closeLabel` で上書きする */
9
+ /** Close button (Sheet, Modal, Snackbar). Callers override it with `closeLabel` */
10
10
  const CLOSE_LABEL = "閉じる";
11
- /** `atom/select` の選択肢の見出し・名前が何も渡されなかったときの、最後の砦(無名のダイアログにしない) */
11
+ /** Last resort for when no heading or name was passed for the options of `atom/select` (so it never becomes an unnamed dialog) */
12
12
  const SELECT_LABEL = "選択肢";
13
- /** `form/select` の placeholder の既定(web の `form/select` と同じ文言) */
13
+ /** Default placeholder of `form/select` (same wording as the web `form/select`) */
14
14
  const SELECT_PLACEHOLDER_LABEL = "選択してください";
15
15
 
16
16
  //#endregion
@@ -1,10 +1,10 @@
1
1
  import { ExternalStore } from "./external-store.js";
2
2
  //#region src/native/lib/loading.d.ts
3
- /** `LoadingLock` が読む状態。命令的な API(`globalLoading()`)がここへ書く。 */
3
+ /** State read by `LoadingLock`. The imperative API (`globalLoading()`) writes here. */
4
4
  export declare const loadingStore: ExternalStore<boolean>;
5
5
  /**
6
- * アプリ全体の操作を塞ぐローディングを出す・消す。アプリのルートに `once/loading-lock` の `LoadingLock` を 1 つ置いておく。
7
- * 真偽の 1 つだけを持つ(重ねて呼んでも数えない。最後に `false` を渡した時点で消える。移植元と同じ)。
6
+ * Shows or hides a loading overlay that blocks interaction across the whole app. Place one `LoadingLock` from `once/loading-lock` at the app root.
7
+ * Holds a single boolean (repeated calls are not counted; the overlay goes away as soon as `false` is passed).
8
8
  */
9
9
  export declare function globalLoading(loading: boolean): void;
10
10
  //#endregion
@@ -1,11 +1,11 @@
1
1
  import { createExternalStore } from "./external-store.js";
2
2
 
3
3
  //#region src/native/lib/loading.ts
4
- /** `LoadingLock` が読む状態。命令的な API(`globalLoading()`)がここへ書く。 */
4
+ /** State read by `LoadingLock`. The imperative API (`globalLoading()`) writes here. */
5
5
  const loadingStore = createExternalStore(false);
6
6
  /**
7
- * アプリ全体の操作を塞ぐローディングを出す・消す。アプリのルートに `once/loading-lock` の `LoadingLock` を 1 つ置いておく。
8
- * 真偽の 1 つだけを持つ(重ねて呼んでも数えない。最後に `false` を渡した時点で消える。移植元と同じ)。
7
+ * Shows or hides a loading overlay that blocks interaction across the whole app. Place one `LoadingLock` from `once/loading-lock` at the app root.
8
+ * Holds a single boolean (repeated calls are not counted; the overlay goes away as soon as `false` is passed).
9
9
  */
10
10
  function globalLoading(loading) {
11
11
  loadingStore.set(loading);
@@ -1,12 +1,11 @@
1
1
  //#region src/native/lib/network.d.ts
2
2
  /**
3
- * 現在オンラインかどうかを購読する。`once/offline-banner` の表示制御に使う。
4
- * 移植元(`@lt-three/native` の `hooks/network.ts`)は TanStack Query の `onlineManager` を NetInfo に委譲していたが、
5
- * love3 は TanStack Query に依存しないので、ここは NetInfo だけを見る(fetch の保留・復帰時の再取得を NetInfo に連動させたいアプリは、
6
- * 自分で `onlineManager.setEventListener` を NetInfo に繋ぐ)。
3
+ * Subscribes to whether the device is currently online. Used to control the display of `once/offline-banner`.
4
+ * It watches NetInfo only and does not depend on TanStack Query (an app that wants to tie fetch pausing and refetch on reconnect to NetInfo
5
+ * wires `onlineManager.setEventListener` to NetInfo itself).
7
6
  *
8
- * 実機は NetInfo の `isConnected`(判定中の `null` はオンライン扱いにして誤検知を避ける)。
9
- * web(react-native-web)でも NetInfo は動き、`navigator.onLine` と `online` / `offline` イベントを見る。
7
+ * On device it uses NetInfo's `isConnected` (a `null` while determining is treated as online to avoid false positives).
8
+ * On web (react-native-web) NetInfo also works, watching `navigator.onLine` and the `online` / `offline` events.
10
9
  */
11
10
  export declare function useIsOnline(): boolean;
12
11
  //#endregion
@@ -3,13 +3,12 @@ import { addEventListener } from "@react-native-community/netinfo";
3
3
 
4
4
  //#region src/native/lib/network.ts
5
5
  /**
6
- * 現在オンラインかどうかを購読する。`once/offline-banner` の表示制御に使う。
7
- * 移植元(`@lt-three/native` の `hooks/network.ts`)は TanStack Query の `onlineManager` を NetInfo に委譲していたが、
8
- * love3 は TanStack Query に依存しないので、ここは NetInfo だけを見る(fetch の保留・復帰時の再取得を NetInfo に連動させたいアプリは、
9
- * 自分で `onlineManager.setEventListener` を NetInfo に繋ぐ)。
6
+ * Subscribes to whether the device is currently online. Used to control the display of `once/offline-banner`.
7
+ * It watches NetInfo only and does not depend on TanStack Query (an app that wants to tie fetch pausing and refetch on reconnect to NetInfo
8
+ * wires `onlineManager.setEventListener` to NetInfo itself).
10
9
  *
11
- * 実機は NetInfo の `isConnected`(判定中の `null` はオンライン扱いにして誤検知を避ける)。
12
- * web(react-native-web)でも NetInfo は動き、`navigator.onLine` と `online` / `offline` イベントを見る。
10
+ * On device it uses NetInfo's `isConnected` (a `null` while determining is treated as online to avoid false positives).
11
+ * On web (react-native-web) NetInfo also works, watching `navigator.onLine` and the `online` / `offline` events.
13
12
  */
14
13
  function useIsOnline() {
15
14
  const [online, setOnline] = useState(true);
@@ -1,18 +1,18 @@
1
1
  import { TokenName } from "../../tokens/tokens.gen.js";
2
2
  //#region src/native/lib/scheme.d.ts
3
- /** テーマ選択。`system` は端末設定に追従する。保存先(AsyncStorage・設定画面)はアプリの責務で、ここでは持たない。 */
3
+ /** Theme selection. `system` follows the device setting. Where it is stored (AsyncStorage, a settings screen) is the app's responsibility and is not handled here. */
4
4
  export type ThemePreference = "system" | "light" | "dark";
5
- /** 実際に描画に使われるテーマ。 */
5
+ /** The theme actually used for rendering. */
6
6
  export type ActiveScheme = "light" | "dark";
7
- /** 選択と端末のカラースキームから、実際に使うテーマを決める。 */
7
+ /** Decides the theme to actually use from the selection and the device color scheme. */
8
8
  export declare function resolveScheme(preference: ThemePreference, system: "light" | "dark" | "unspecified" | null | undefined): ActiveScheme;
9
- /** 色のトークンの名前(書体 `font-*` と角丸 `radius` を除く)。`useTokenColor` が受けるのはこれだけ。 */
9
+ /** Names of color tokens (excluding the `font-*` typefaces and `radius`). These are the only ones `useTokenColor` accepts. */
10
10
  export type ColorTokenName = Exclude<TokenName, `font-${string}` | "radius">;
11
11
  /**
12
- * トークンの色の実値。DS が値を持ち(`@lt-three/love3/tokens`)、部品はここを通して引く。
13
- * 名前は CSS 変数の形(`--ink-500`)でも、トークン名(`ink-500`)でもよい。色でないトークン(書体・角丸)は受けない。
12
+ * The actual value of a color token. The DS owns the values (`@lt-three/love3/tokens`), and components look them up through here.
13
+ * The name may be in CSS variable form (`--ink-500`) or token name form (`ink-500`). Non-color tokens (typefaces, radius) are not accepted.
14
14
  */
15
15
  export declare function tokenColor(scheme: ActiveScheme, name: `--${ColorTokenName}` | ColorTokenName,
16
- /** 調整(`TuningRoot`)が配る実効値。あれば、その値を優先する(実行時の上書きに追従する)。 */
16
+ /** Effective values distributed by tuning (`TuningRoot`). If present, they take priority (following runtime overrides). */
17
17
  overlay?: Readonly<Record<ActiveScheme, Readonly<Record<string, string>>>> | null): string;
18
18
  //#endregion