@k8o/arte-odyssey 10.1.1 → 10.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +63 -20
- package/dist/components/form/checkbox-group/index.d.mts +3 -3
- package/dist/components/form/slider/slider.mjs +1 -1
- package/dist/integrations/_shared/openui-defs.d.mts +19 -0
- package/dist/integrations/_shared/openui-defs.mjs +159 -0
- package/dist/integrations/_shared/schemas.d.mts +26 -26
- package/dist/integrations/json-render/catalog.d.mts +411 -335
- package/dist/integrations/json-render/catalog.mjs +75 -2
- package/dist/integrations/json-render/registry.d.mts +27 -1
- package/dist/integrations/json-render/registry.mjs +26 -2
- package/dist/integrations/openui/library.d.mts +205 -1
- package/dist/integrations/openui/library.mjs +60 -416
- package/dist/integrations/openui/prompt.d.mts +6 -0
- package/dist/integrations/openui/prompt.mjs +19 -0
- package/docs/GUIDE.md +1 -0
- package/docs/llms.txt +23 -0
- package/docs/references/generative-ui.md +112 -0
- package/package.json +20 -2
package/README.md
CHANGED
|
@@ -241,13 +241,15 @@ These integrations are exposed as optional subpath exports. Install the framewor
|
|
|
241
241
|
pnpm add @json-render/core @json-render/react zod
|
|
242
242
|
# OpenUI
|
|
243
243
|
pnpm add @openuidev/react-lang zod
|
|
244
|
+
# OpenUI server-safe prompt entry (@k8o/arte-odyssey/openui/prompt) additionally needs:
|
|
245
|
+
pnpm add @openuidev/lang-core
|
|
244
246
|
```
|
|
245
247
|
|
|
246
|
-
Supported components (**all
|
|
248
|
+
Supported components (**all 49**, both frameworks):
|
|
247
249
|
|
|
248
|
-
- **Layout / containers**: `Stack`, `Card`, `Form`
|
|
250
|
+
- **Layout / containers**: `Stack`, `Grid`, `Card`, `Form`
|
|
249
251
|
- **Buttons / nav**: `Button`, `IconButton`, `Anchor`, `Breadcrumb`, `Pagination`
|
|
250
|
-
- **Display**: `Badge`, `Heading`, `Avatar`, `Code`, `Icon`, `Alert`, `Spinner`, `Progress`, `Skeleton`, `Separator`, `Tabs`, `Accordion`, `Table`, `BaselineStatus`, `ScrollLinked`
|
|
252
|
+
- **Display**: `Badge`, `Heading`, `Avatar`, `Code`, `Icon`, `ChevronIcon`, `StatusIcon`, `Alert`, `Spinner`, `Progress`, `Skeleton`, `Separator`, `Tabs`, `Accordion`, `Table`, `BaselineStatus`, `ScrollLinked`
|
|
251
253
|
- **Overlays (self-contained widgets)**: `Modal`, `Dialog`, `Drawer`, `Popover`, `Tooltip`, `DropdownMenu`, `Toast`
|
|
252
254
|
- **Form**: `TextField`, `Textarea`, `PasswordInput`, `NumberField`, `Slider`, `Checkbox`, `Switch`, `Select`, `Radio`, `RadioCard`, `CheckboxCard`, `ListBox`, `CheckboxGroup`, `Autocomplete`, `FileField`, `FormControl`
|
|
253
255
|
|
|
@@ -255,34 +257,61 @@ Overlays are exposed as **self-contained widgets**: a `Modal`/`Dialog`/`Drawer`/
|
|
|
255
257
|
|
|
256
258
|
### json-render (RSC-ready)
|
|
257
259
|
|
|
258
|
-
The catalog (schemas / prompt) and the registry (rendering) are split so the catalog is **server-safe** —
|
|
260
|
+
The catalog (schemas / prompt) and the registry (rendering) are split so the catalog is **server-safe** — generate the system prompt in a React Server Component, and render on the client.
|
|
259
261
|
|
|
260
262
|
```tsx
|
|
261
263
|
// Server Component: prompt generation
|
|
262
|
-
import { catalog } from '@k8o/arte-odyssey/json-render';
|
|
264
|
+
import { catalog, arteOdysseyRules } from '@k8o/arte-odyssey/json-render';
|
|
263
265
|
|
|
264
|
-
|
|
266
|
+
// `customRules` injects cross-cutting constraints the model tends to break
|
|
267
|
+
// (Table cell counts match columns, href format, text-only Tabs/Accordion content).
|
|
268
|
+
const systemPrompt = catalog.prompt({ customRules: [...arteOdysseyRules] });
|
|
265
269
|
```
|
|
266
270
|
|
|
267
271
|
```tsx
|
|
268
|
-
// Client Component: rendering
|
|
272
|
+
// Client Component: rendering.
|
|
273
|
+
// `JsonRenderUI` wires JSONUIProvider + Renderer and the registry for you —
|
|
274
|
+
// just pass a spec. Pass `onStateChange` to collect form values.
|
|
269
275
|
'use client';
|
|
270
|
-
import {
|
|
271
|
-
import { JSONUIProvider, Renderer } from '@json-render/react';
|
|
276
|
+
import { JsonRenderUI } from '@k8o/arte-odyssey/json-render/registry';
|
|
272
277
|
|
|
273
278
|
export function GenUi({ spec }: { spec: unknown }) {
|
|
274
|
-
return
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
+
return <JsonRenderUI spec={spec} />;
|
|
280
|
+
}
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
Validate (and repair) LLM output before rendering. `validateGeneratedSpec` runs auto-fixes, structural checks, and per-component prop validation, returning a ready-to-resend repair prompt on failure:
|
|
284
|
+
|
|
285
|
+
```tsx
|
|
286
|
+
import { validateGeneratedSpec } from '@k8o/arte-odyssey/json-render';
|
|
287
|
+
|
|
288
|
+
const result = validateGeneratedSpec(JSON.parse(llmOutput));
|
|
289
|
+
if (result.ok) {
|
|
290
|
+
return <JsonRenderUI spec={result.spec} />; // result.fixes lists auto-applied fixes
|
|
279
291
|
}
|
|
292
|
+
const retried = await llm(result.repairPrompt); // ask the model to fix, then retry
|
|
280
293
|
```
|
|
281
294
|
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
295
|
+
Hand-written or LLM specs can be typed with `satisfies ArteSpec` so component names and props are checked at compile time (no `as unknown as Spec`):
|
|
296
|
+
|
|
297
|
+
```tsx
|
|
298
|
+
import type { ArteSpec } from '@k8o/arte-odyssey/json-render';
|
|
299
|
+
|
|
300
|
+
const spec = {
|
|
301
|
+
root: 'root',
|
|
302
|
+
elements: {
|
|
303
|
+
root: { type: 'Stack', props: { direction: 'column' }, children: ['ok'] },
|
|
304
|
+
ok: { type: 'Button', props: { label: 'OK' } }, // typo in `type`/props → compile error
|
|
305
|
+
},
|
|
306
|
+
} satisfies ArteSpec;
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
For advanced setups (custom `navigate` / `handlers` / `validationFunctions`), pass the lower-level `registry` to `JSONUIProvider` and `Renderer` from `@json-render/react` directly.
|
|
310
|
+
|
|
311
|
+
| Export | Side | Contents |
|
|
312
|
+
| ---------------------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
|
|
313
|
+
| `@k8o/arte-odyssey/json-render` | server-safe | `catalog` (schemas + `prompt()`), `validateGeneratedSpec`, `arteOdysseyRules`, types (`ArteSpec`, `ComponentName`, `ComponentProps`) |
|
|
314
|
+
| `@k8o/arte-odyssey/json-render/registry` | `'use client'` | `JsonRenderUI` (pre-wired), `registry` (low-level) |
|
|
286
315
|
|
|
287
316
|
### OpenUI
|
|
288
317
|
|
|
@@ -296,13 +325,27 @@ export function GenUi({ response }: { response: string }) {
|
|
|
296
325
|
}
|
|
297
326
|
```
|
|
298
327
|
|
|
299
|
-
Generate the system prompt
|
|
328
|
+
Generate the system prompt on the **server** with the dedicated server-safe entry (symmetric with json-render's `catalog.prompt()`):
|
|
329
|
+
|
|
330
|
+
```tsx
|
|
331
|
+
import { prompt } from '@k8o/arte-odyssey/openui/prompt';
|
|
332
|
+
|
|
333
|
+
const systemPrompt = prompt(); // server-safe, no React — call it from an RSC or API route
|
|
334
|
+
```
|
|
335
|
+
|
|
336
|
+
To generate the prompt inside the client bundle instead, `library.prompt()` still works.
|
|
337
|
+
|
|
338
|
+
| Export | Side | Contents |
|
|
339
|
+
| --------------------------------- | -------------- | ------------------------------------- |
|
|
340
|
+
| `@k8o/arte-odyssey/openui` | `'use client'` | `library` (rendering) |
|
|
341
|
+
| `@k8o/arte-odyssey/openui/prompt` | server-safe | `prompt()` (system prompt generation) |
|
|
300
342
|
|
|
301
343
|
> **Notes**
|
|
302
344
|
>
|
|
303
345
|
> - Make sure `@k8o/arte-odyssey/styles.css` is loaded and the app is wrapped in `ArteOdysseyProvider`.
|
|
346
|
+
> - `@k8o/arte-odyssey/openui/prompt` needs the optional peer `@openuidev/lang-core` (React-free).
|
|
304
347
|
> - `Tabs` panels are text content (`tabs: [{ label, content }]`); rich-component panels are a future enhancement.
|
|
305
|
-
> - In OpenUI, `Card` can contain a `Stack`, but `Stack` cannot nest
|
|
348
|
+
> - In OpenUI, `Card` can contain a `Stack` or `Grid`, but `Stack`/`Grid` cannot directly nest a `Stack`/`Grid`/`Card` (no self-referential schemas) — put nested layout inside a `Card`. json-render nests freely (slots-based).
|
|
306
349
|
|
|
307
350
|
## Custom Hooks
|
|
308
351
|
|
|
@@ -3,7 +3,7 @@ declare const CheckboxGroup: import("react").FC<{
|
|
|
3
3
|
invalid?: boolean;
|
|
4
4
|
required?: boolean;
|
|
5
5
|
name: string;
|
|
6
|
-
} & Omit<import("react").FieldsetHTMLAttributes<HTMLFieldSetElement>, "
|
|
6
|
+
} & Omit<import("react").FieldsetHTMLAttributes<HTMLFieldSetElement>, "defaultValue" | "onChange" | "className" | "style" | "name"> & {
|
|
7
7
|
children?: import("react").ReactNode | undefined;
|
|
8
8
|
} & ({
|
|
9
9
|
value: string[];
|
|
@@ -18,7 +18,7 @@ declare const CheckboxGroup: import("react").FC<{
|
|
|
18
18
|
invalid?: boolean;
|
|
19
19
|
required?: boolean;
|
|
20
20
|
name: string;
|
|
21
|
-
} & Omit<import("react").FieldsetHTMLAttributes<HTMLFieldSetElement>, "
|
|
21
|
+
} & Omit<import("react").FieldsetHTMLAttributes<HTMLFieldSetElement>, "defaultValue" | "onChange" | "className" | "style" | "name"> & {
|
|
22
22
|
children?: import("react").ReactNode | undefined;
|
|
23
23
|
} & ({
|
|
24
24
|
value: string[];
|
|
@@ -33,7 +33,7 @@ declare const CheckboxGroup: import("react").FC<{
|
|
|
33
33
|
Item: import("react").FC<{
|
|
34
34
|
itemValue?: string;
|
|
35
35
|
label: string;
|
|
36
|
-
} & Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "
|
|
36
|
+
} & Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "value" | "onChange" | "className" | "style" | "defaultChecked" | "children" | "type" | "checked"> & ({
|
|
37
37
|
value: boolean;
|
|
38
38
|
onChange: (checked: boolean, event: import("react").ChangeEvent<HTMLInputElement>) => void;
|
|
39
39
|
defaultChecked?: never;
|
|
@@ -12,7 +12,7 @@ const Slider = ({ invalid = false, disabled = false, required = false, value, de
|
|
|
12
12
|
});
|
|
13
13
|
const { pending } = useFormStatus();
|
|
14
14
|
const disabledResolved = disabled || pending;
|
|
15
|
-
const range =
|
|
15
|
+
const range = max > min ? max - min : 1;
|
|
16
16
|
const progress = (currentValue - min) / range * 100;
|
|
17
17
|
const clampedProgress = `${Math.min(Math.max(progress, 0), 100)}%`;
|
|
18
18
|
return /* @__PURE__ */ jsxs("div", {
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Library } from "@openuidev/lang-core";
|
|
2
|
+
|
|
3
|
+
//#region src/integrations/_shared/openui-defs.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* OpenUI ライブラリの「定義部分」(スキーマ・説明文・子要素の構成)を
|
|
6
|
+
* React 非依存で組み立てる共有ファクトリ。
|
|
7
|
+
*
|
|
8
|
+
* 描画関数(`component`)だけを外から差し込むことで、
|
|
9
|
+
* - クライアント(`openui/library.tsx`・'use client')= 実 React 描画関数を渡す
|
|
10
|
+
* - サーバー安全(`openui/prompt.ts`)= 何も渡さず `prompt()` だけ使う
|
|
11
|
+
* の 2 つを **スキーマを二重管理せずに** 生成できる。
|
|
12
|
+
*
|
|
13
|
+
* OpenUI は schema と描画関数を `defineComponent` で同居させる設計なので、
|
|
14
|
+
* このファクトリ自体は描画関数を opaque な `C` として受け取り中身を見ない。
|
|
15
|
+
*/
|
|
16
|
+
type ArteOdysseyRenderers<C> = Partial<Record<string, C>>;
|
|
17
|
+
declare const buildArteOdysseyLibrary: <C>(render: ArteOdysseyRenderers<C>) => Library<C>;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { ArteOdysseyRenderers, buildArteOdysseyLibrary };
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import { accordionProps, alertProps, anchorProps, autocompleteProps, avatarProps, badgeProps, baselineStatusProps, breadcrumbProps, buttonProps, cardProps, checkboxCardProps, checkboxGroupProps, checkboxProps, chevronIconProps, codeProps, dialogProps, drawerProps, dropdownMenuProps, fileFieldProps, formControlProps, formProps, gridProps, headingProps, iconButtonProps, iconProps, listBoxProps, modalProps, numberFieldProps, paginationProps, passwordInputProps, popoverProps, progressProps, radioCardProps, radioProps, scrollLinkedProps, selectProps, separatorProps, skeletonProps, sliderProps, spinnerProps, stackProps, statusIconProps, switchProps, tableProps, tabsProps, textFieldProps, textareaProps, toastProps, tooltipProps } from "./schemas.mjs";
|
|
2
|
+
import { createLibrary, defineComponent } from "@openuidev/lang-core";
|
|
3
|
+
import { z } from "zod";
|
|
4
|
+
//#region src/integrations/_shared/openui-defs.ts
|
|
5
|
+
const buildArteOdysseyLibrary = (render) => {
|
|
6
|
+
const def = (name, description, props) => defineComponent({
|
|
7
|
+
name,
|
|
8
|
+
description,
|
|
9
|
+
props,
|
|
10
|
+
component: render[name]
|
|
11
|
+
});
|
|
12
|
+
const Button = def("Button", "アクションボタン。href を指定するとリンク(<a>)になる。", buttonProps);
|
|
13
|
+
const IconButton = def("IconButton", "アイコンのみのボタン(label は必須)。", iconButtonProps);
|
|
14
|
+
const Badge = def("Badge", "ステータスやラベルのバッジ。", badgeProps);
|
|
15
|
+
const Heading = def("Heading", "見出し(h1〜h6)。", headingProps);
|
|
16
|
+
const Anchor = def("Anchor", "テキストリンク。", anchorProps);
|
|
17
|
+
const Avatar = def("Avatar", "アバター(画像 or イニシャル)。", avatarProps);
|
|
18
|
+
const Code = def("Code", "インラインのコード/値表示。", codeProps);
|
|
19
|
+
const Icon = def("Icon", "アイコン(name で指定)。", iconProps);
|
|
20
|
+
const ChevronIcon = def("ChevronIcon", "矢印アイコン。direction で向きを指定。", chevronIconProps);
|
|
21
|
+
const StatusIcon = def("StatusIcon", "ステータスを表すアイコン(success/info/warning/error)。装飾用途で、メッセージ表示なら Alert を使う。", statusIconProps);
|
|
22
|
+
const Alert = def("Alert", "状態を伝えるアラート。message は文字列または文字列配列。", alertProps);
|
|
23
|
+
const Spinner = def("Spinner", "ローディングスピナー。", spinnerProps);
|
|
24
|
+
const Progress = def("Progress", "進捗バー。", progressProps);
|
|
25
|
+
const Skeleton = def("Skeleton", "ローディングのプレースホルダ。", skeletonProps);
|
|
26
|
+
const Separator = def("Separator", "区切り線。", separatorProps);
|
|
27
|
+
const Tabs = def("Tabs", "タブ。各タブは label とテキスト content を持つ。content は文字列のみ。", tabsProps);
|
|
28
|
+
const Accordion = def("Accordion", "開閉できるアコーディオン。各項目は title とテキスト content。content は文字列のみ。", accordionProps);
|
|
29
|
+
const Breadcrumb = def("Breadcrumb", "パンくずリスト。", breadcrumbProps);
|
|
30
|
+
const Table = def("Table", "テーブル。columns と rows(行ごとのセル文字列)。各行のセル数は columns の数と一致させる。", tableProps);
|
|
31
|
+
const TextField = def("TextField", "1行テキスト入力。name でフォーム状態に束縛される。", textFieldProps);
|
|
32
|
+
const Textarea = def("Textarea", "複数行テキスト入力。name でフォーム状態に束縛される。", textareaProps);
|
|
33
|
+
const PasswordInput = def("PasswordInput", "パスワード入力。name でフォーム状態に束縛される。", passwordInputProps);
|
|
34
|
+
const NumberField = def("NumberField", "数値入力。name でフォーム状態に束縛される。", numberFieldProps);
|
|
35
|
+
const Slider = def("Slider", "スライダー。name でフォーム状態に束縛される。", sliderProps);
|
|
36
|
+
const Checkbox = def("Checkbox", "チェックボックス。name でフォーム状態に束縛される。", checkboxProps);
|
|
37
|
+
const Switch = def("Switch", "オン/オフスイッチ。name でフォーム状態に束縛される。", switchProps);
|
|
38
|
+
const Select = def("Select", "ドロップダウン選択。name でフォーム状態に束縛される。", selectProps);
|
|
39
|
+
const Radio = def("Radio", "単一選択ラジオ。name でフォーム状態に束縛される。", radioProps);
|
|
40
|
+
const RadioCard = def("RadioCard", "カード型の単一選択。name でフォーム状態に束縛される。", radioCardProps);
|
|
41
|
+
const CheckboxCard = def("CheckboxCard", "カード型の複数選択。name でフォーム状態に束縛される。", checkboxCardProps);
|
|
42
|
+
const Pagination = def("Pagination", "ページネーション。name でフォーム状態に束縛される。", paginationProps);
|
|
43
|
+
const Tooltip = def("Tooltip", "ツールチップ。ホバー/フォーカスで表示。", tooltipProps);
|
|
44
|
+
const DropdownMenu = def("DropdownMenu", "ドロップダウンメニュー。", dropdownMenuProps);
|
|
45
|
+
const Toast = def("Toast", "トースト通知。triggerLabel のボタンで発火。", toastProps);
|
|
46
|
+
const ScrollLinked = def("ScrollLinked", "ページスクロール進捗バー(fixed top)。", scrollLinkedProps);
|
|
47
|
+
const BaselineStatus = def("BaselineStatus", "Web feature の Baseline ステータス表示。", baselineStatusProps);
|
|
48
|
+
const ListBox = def("ListBox", "ポップアップ型の単一選択リスト。", listBoxProps);
|
|
49
|
+
const CheckboxGroup = def("CheckboxGroup", "チェックボックスグループ。name でフォーム状態に束縛。", checkboxGroupProps);
|
|
50
|
+
const Autocomplete = def("Autocomplete", "タグ風の複数選択オートコンプリート。", autocompleteProps);
|
|
51
|
+
const FileField = def("FileField", "ファイル選択フィールド(自己完結ウィジェット)。", fileFieldProps);
|
|
52
|
+
const FormControl = def("FormControl", "ラベル+ヘルプ/エラー付きフィールド(text/textarea/password)。", formControlProps);
|
|
53
|
+
const childRefs = [
|
|
54
|
+
Button.ref,
|
|
55
|
+
IconButton.ref,
|
|
56
|
+
Badge.ref,
|
|
57
|
+
Heading.ref,
|
|
58
|
+
Anchor.ref,
|
|
59
|
+
Avatar.ref,
|
|
60
|
+
Code.ref,
|
|
61
|
+
Icon.ref,
|
|
62
|
+
ChevronIcon.ref,
|
|
63
|
+
StatusIcon.ref,
|
|
64
|
+
Alert.ref,
|
|
65
|
+
Spinner.ref,
|
|
66
|
+
Progress.ref,
|
|
67
|
+
Skeleton.ref,
|
|
68
|
+
Separator.ref,
|
|
69
|
+
Tabs.ref,
|
|
70
|
+
Accordion.ref,
|
|
71
|
+
Breadcrumb.ref,
|
|
72
|
+
Table.ref,
|
|
73
|
+
TextField.ref,
|
|
74
|
+
Textarea.ref,
|
|
75
|
+
PasswordInput.ref,
|
|
76
|
+
NumberField.ref,
|
|
77
|
+
Slider.ref,
|
|
78
|
+
Checkbox.ref,
|
|
79
|
+
Switch.ref,
|
|
80
|
+
Select.ref,
|
|
81
|
+
Radio.ref,
|
|
82
|
+
RadioCard.ref,
|
|
83
|
+
CheckboxCard.ref,
|
|
84
|
+
Pagination.ref,
|
|
85
|
+
Tooltip.ref,
|
|
86
|
+
DropdownMenu.ref,
|
|
87
|
+
Toast.ref,
|
|
88
|
+
ScrollLinked.ref,
|
|
89
|
+
BaselineStatus.ref,
|
|
90
|
+
ListBox.ref,
|
|
91
|
+
CheckboxGroup.ref,
|
|
92
|
+
Autocomplete.ref,
|
|
93
|
+
FileField.ref,
|
|
94
|
+
FormControl.ref
|
|
95
|
+
];
|
|
96
|
+
const Stack = def("Stack", "子要素を縦/横に等間隔で並べるレイアウトコンテナ。Stack の直下に Stack/Grid/Card は置けない。入れ子レイアウトが必要なら Card の中に Stack や Grid を入れる。", stackProps.extend({ children: z.array(z.union(childRefs)).describe("並べる子要素") }));
|
|
97
|
+
const Grid = def("Grid", "子要素をグリッド状に並べる。cols(1〜6 / auto-fill / auto-fit)と gap、auto-fill/fit 時は minItemSize で各セルの最小サイズを制御。Grid の直下に Stack/Grid/Card は置けない。", gridProps.extend({ children: z.array(z.union(childRefs)).describe("グリッド内の子要素") }));
|
|
98
|
+
const containerChildRefs = [
|
|
99
|
+
...childRefs,
|
|
100
|
+
Stack.ref,
|
|
101
|
+
Grid.ref
|
|
102
|
+
];
|
|
103
|
+
return createLibrary({
|
|
104
|
+
components: [
|
|
105
|
+
Stack,
|
|
106
|
+
Grid,
|
|
107
|
+
def("Card", "コンテンツをまとめるカード(コンテナ)。Stack や Grid も入れられる。interactive を付けるとホバー時にスケールする。", cardProps.extend({ children: z.array(z.union(containerChildRefs)).describe("カード内の子要素") })),
|
|
108
|
+
def("Form", "フォーム要素のラッパー(縦並びレイアウト)。", formProps.extend({ children: z.array(z.union(containerChildRefs)).describe("フォーム内の要素") })),
|
|
109
|
+
def("Modal", "モーダルダイアログ。triggerLabel のボタンで開く。", modalProps.extend({ children: z.array(z.union(containerChildRefs)).describe("モーダル内の要素") })),
|
|
110
|
+
def("Dialog", "センターダイアログ。triggerLabel のボタンで開く。", dialogProps.extend({ children: z.array(z.union(containerChildRefs)).describe("ダイアログ内の要素") })),
|
|
111
|
+
def("Drawer", "サイドドロワー。triggerLabel のボタンで開く。", drawerProps.extend({ children: z.array(z.union(containerChildRefs)).describe("ドロワー内の要素") })),
|
|
112
|
+
def("Popover", "ポップオーバー。triggerLabel のボタンで開閉。", popoverProps.extend({ children: z.array(z.union(containerChildRefs)).describe("ポップオーバー内の要素") })),
|
|
113
|
+
Tooltip,
|
|
114
|
+
DropdownMenu,
|
|
115
|
+
Toast,
|
|
116
|
+
Button,
|
|
117
|
+
IconButton,
|
|
118
|
+
Badge,
|
|
119
|
+
Heading,
|
|
120
|
+
Anchor,
|
|
121
|
+
Avatar,
|
|
122
|
+
Code,
|
|
123
|
+
Icon,
|
|
124
|
+
ChevronIcon,
|
|
125
|
+
StatusIcon,
|
|
126
|
+
Alert,
|
|
127
|
+
Spinner,
|
|
128
|
+
Progress,
|
|
129
|
+
Skeleton,
|
|
130
|
+
Separator,
|
|
131
|
+
ScrollLinked,
|
|
132
|
+
BaselineStatus,
|
|
133
|
+
Tabs,
|
|
134
|
+
Accordion,
|
|
135
|
+
Breadcrumb,
|
|
136
|
+
Table,
|
|
137
|
+
TextField,
|
|
138
|
+
Textarea,
|
|
139
|
+
PasswordInput,
|
|
140
|
+
NumberField,
|
|
141
|
+
Slider,
|
|
142
|
+
Checkbox,
|
|
143
|
+
Switch,
|
|
144
|
+
Select,
|
|
145
|
+
Radio,
|
|
146
|
+
RadioCard,
|
|
147
|
+
CheckboxCard,
|
|
148
|
+
Pagination,
|
|
149
|
+
ListBox,
|
|
150
|
+
CheckboxGroup,
|
|
151
|
+
Autocomplete,
|
|
152
|
+
FileField,
|
|
153
|
+
FormControl
|
|
154
|
+
],
|
|
155
|
+
root: "Stack"
|
|
156
|
+
});
|
|
157
|
+
};
|
|
158
|
+
//#endregion
|
|
159
|
+
export { buildArteOdysseyLibrary };
|
|
@@ -40,16 +40,14 @@ declare const buttonProps: z.ZodObject<{
|
|
|
40
40
|
}, z.core.$strip>;
|
|
41
41
|
declare const iconName: z.ZodEnum<{
|
|
42
42
|
form: "form";
|
|
43
|
-
list: "list";
|
|
44
43
|
link: "link";
|
|
45
|
-
table: "table";
|
|
46
|
-
send: "send";
|
|
47
|
-
location: "location";
|
|
48
|
-
copy: "copy";
|
|
49
44
|
check: "check";
|
|
45
|
+
list: "list";
|
|
50
46
|
plus: "plus";
|
|
51
47
|
minus: "minus";
|
|
52
48
|
close: "close";
|
|
49
|
+
copy: "copy";
|
|
50
|
+
send: "send";
|
|
53
51
|
mail: "mail";
|
|
54
52
|
subscribe: "subscribe";
|
|
55
53
|
rss: "rss";
|
|
@@ -57,7 +55,9 @@ declare const iconName: z.ZodEnum<{
|
|
|
57
55
|
"update-date": "update-date";
|
|
58
56
|
"publish-date": "publish-date";
|
|
59
57
|
"external-link": "external-link";
|
|
58
|
+
location: "location";
|
|
60
59
|
"navigation-menu": "navigation-menu";
|
|
60
|
+
table: "table";
|
|
61
61
|
view: "view";
|
|
62
62
|
"view-off": "view-off";
|
|
63
63
|
"light-mode": "light-mode";
|
|
@@ -95,16 +95,14 @@ declare const iconName: z.ZodEnum<{
|
|
|
95
95
|
declare const iconProps: z.ZodObject<{
|
|
96
96
|
name: z.ZodEnum<{
|
|
97
97
|
form: "form";
|
|
98
|
-
list: "list";
|
|
99
98
|
link: "link";
|
|
100
|
-
table: "table";
|
|
101
|
-
send: "send";
|
|
102
|
-
location: "location";
|
|
103
|
-
copy: "copy";
|
|
104
99
|
check: "check";
|
|
100
|
+
list: "list";
|
|
105
101
|
plus: "plus";
|
|
106
102
|
minus: "minus";
|
|
107
103
|
close: "close";
|
|
104
|
+
copy: "copy";
|
|
105
|
+
send: "send";
|
|
108
106
|
mail: "mail";
|
|
109
107
|
subscribe: "subscribe";
|
|
110
108
|
rss: "rss";
|
|
@@ -112,7 +110,9 @@ declare const iconProps: z.ZodObject<{
|
|
|
112
110
|
"update-date": "update-date";
|
|
113
111
|
"publish-date": "publish-date";
|
|
114
112
|
"external-link": "external-link";
|
|
113
|
+
location: "location";
|
|
115
114
|
"navigation-menu": "navigation-menu";
|
|
115
|
+
table: "table";
|
|
116
116
|
view: "view";
|
|
117
117
|
"view-off": "view-off";
|
|
118
118
|
"light-mode": "light-mode";
|
|
@@ -156,16 +156,14 @@ declare const iconProps: z.ZodObject<{
|
|
|
156
156
|
declare const iconButtonProps: z.ZodObject<{
|
|
157
157
|
icon: z.ZodEnum<{
|
|
158
158
|
form: "form";
|
|
159
|
-
list: "list";
|
|
160
159
|
link: "link";
|
|
161
|
-
table: "table";
|
|
162
|
-
send: "send";
|
|
163
|
-
location: "location";
|
|
164
|
-
copy: "copy";
|
|
165
160
|
check: "check";
|
|
161
|
+
list: "list";
|
|
166
162
|
plus: "plus";
|
|
167
163
|
minus: "minus";
|
|
168
164
|
close: "close";
|
|
165
|
+
copy: "copy";
|
|
166
|
+
send: "send";
|
|
169
167
|
mail: "mail";
|
|
170
168
|
subscribe: "subscribe";
|
|
171
169
|
rss: "rss";
|
|
@@ -173,7 +171,9 @@ declare const iconButtonProps: z.ZodObject<{
|
|
|
173
171
|
"update-date": "update-date";
|
|
174
172
|
"publish-date": "publish-date";
|
|
175
173
|
"external-link": "external-link";
|
|
174
|
+
location: "location";
|
|
176
175
|
"navigation-menu": "navigation-menu";
|
|
176
|
+
table: "table";
|
|
177
177
|
view: "view";
|
|
178
178
|
"view-off": "view-off";
|
|
179
179
|
"light-mode": "light-mode";
|
|
@@ -215,9 +215,9 @@ declare const iconButtonProps: z.ZodObject<{
|
|
|
215
215
|
lg: "lg";
|
|
216
216
|
}>>;
|
|
217
217
|
color: z.ZodOptional<z.ZodEnum<{
|
|
218
|
+
transparent: "transparent";
|
|
218
219
|
primary: "primary";
|
|
219
220
|
secondary: "secondary";
|
|
220
|
-
transparent: "transparent";
|
|
221
221
|
base: "base";
|
|
222
222
|
}>>;
|
|
223
223
|
}, z.core.$strip>;
|
|
@@ -237,9 +237,9 @@ declare const chevronIconProps: z.ZodObject<{
|
|
|
237
237
|
declare const statusIconProps: z.ZodObject<{
|
|
238
238
|
status: z.ZodEnum<{
|
|
239
239
|
success: "success";
|
|
240
|
+
error: "error";
|
|
240
241
|
info: "info";
|
|
241
242
|
warning: "warning";
|
|
242
|
-
error: "error";
|
|
243
243
|
}>;
|
|
244
244
|
size: z.ZodOptional<z.ZodEnum<{
|
|
245
245
|
sm: "sm";
|
|
@@ -251,10 +251,10 @@ declare const badgeProps: z.ZodObject<{
|
|
|
251
251
|
text: z.ZodString;
|
|
252
252
|
tone: z.ZodOptional<z.ZodEnum<{
|
|
253
253
|
success: "success";
|
|
254
|
-
info: "info";
|
|
255
|
-
warning: "warning";
|
|
256
254
|
error: "error";
|
|
257
255
|
neutral: "neutral";
|
|
256
|
+
info: "info";
|
|
257
|
+
warning: "warning";
|
|
258
258
|
}>>;
|
|
259
259
|
variant: z.ZodOptional<z.ZodEnum<{
|
|
260
260
|
solid: "solid";
|
|
@@ -330,9 +330,9 @@ declare const cardProps: z.ZodObject<{
|
|
|
330
330
|
declare const alertProps: z.ZodObject<{
|
|
331
331
|
tone: z.ZodEnum<{
|
|
332
332
|
success: "success";
|
|
333
|
+
error: "error";
|
|
333
334
|
info: "info";
|
|
334
335
|
warning: "warning";
|
|
335
|
-
error: "error";
|
|
336
336
|
}>;
|
|
337
337
|
message: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>;
|
|
338
338
|
}, z.core.$strip>;
|
|
@@ -352,8 +352,8 @@ declare const progressProps: z.ZodObject<{
|
|
|
352
352
|
}, z.core.$strip>;
|
|
353
353
|
declare const skeletonProps: z.ZodObject<{
|
|
354
354
|
shape: z.ZodOptional<z.ZodEnum<{
|
|
355
|
-
circle: "circle";
|
|
356
355
|
rect: "rect";
|
|
356
|
+
circle: "circle";
|
|
357
357
|
}>>;
|
|
358
358
|
size: z.ZodOptional<z.ZodEnum<{
|
|
359
359
|
sm: "sm";
|
|
@@ -366,9 +366,9 @@ declare const toastProps: z.ZodObject<{
|
|
|
366
366
|
triggerLabel: z.ZodString;
|
|
367
367
|
tone: z.ZodEnum<{
|
|
368
368
|
success: "success";
|
|
369
|
+
error: "error";
|
|
369
370
|
info: "info";
|
|
370
371
|
warning: "warning";
|
|
371
|
-
error: "error";
|
|
372
372
|
}>;
|
|
373
373
|
message: z.ZodString;
|
|
374
374
|
}, z.core.$strip>;
|
|
@@ -392,21 +392,21 @@ declare const stackProps: z.ZodObject<{
|
|
|
392
392
|
sm: "sm";
|
|
393
393
|
md: "md";
|
|
394
394
|
lg: "lg";
|
|
395
|
-
none: "none";
|
|
396
395
|
xl: "xl";
|
|
396
|
+
none: "none";
|
|
397
397
|
}>>;
|
|
398
398
|
padding: z.ZodOptional<z.ZodEnum<{
|
|
399
399
|
sm: "sm";
|
|
400
400
|
md: "md";
|
|
401
401
|
lg: "lg";
|
|
402
|
-
none: "none";
|
|
403
402
|
xl: "xl";
|
|
403
|
+
none: "none";
|
|
404
404
|
}>>;
|
|
405
405
|
align: z.ZodOptional<z.ZodEnum<{
|
|
406
406
|
start: "start";
|
|
407
407
|
end: "end";
|
|
408
|
-
stretch: "stretch";
|
|
409
408
|
center: "center";
|
|
409
|
+
stretch: "stretch";
|
|
410
410
|
}>>;
|
|
411
411
|
justify: z.ZodOptional<z.ZodEnum<{
|
|
412
412
|
start: "start";
|
|
@@ -422,8 +422,8 @@ declare const gridProps: z.ZodObject<{
|
|
|
422
422
|
sm: "sm";
|
|
423
423
|
md: "md";
|
|
424
424
|
lg: "lg";
|
|
425
|
-
none: "none";
|
|
426
425
|
xl: "xl";
|
|
426
|
+
none: "none";
|
|
427
427
|
}>>;
|
|
428
428
|
}, z.core.$strip>;
|
|
429
429
|
declare const scrollLinkedProps: z.ZodObject<{}, z.core.$strip>;
|