@arqel-dev/ui 0.8.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.
- package/LICENSE +21 -0
- package/README.md +62 -0
- package/SKILL.md +116 -0
- package/dist/FormRenderer-BJBRIkfH.d.ts +70 -0
- package/dist/TableToolbar-POLdlSgC.d.ts +54 -0
- package/dist/WidgetWrapper-DUQy381N.d.ts +54 -0
- package/dist/action.d.ts +73 -0
- package/dist/action.js +1092 -0
- package/dist/action.js.map +1 -0
- package/dist/auth.d.ts +12 -0
- package/dist/auth.js +12 -0
- package/dist/auth.js.map +1 -0
- package/dist/flash.d.ts +37 -0
- package/dist/flash.js +106 -0
- package/dist/flash.js.map +1 -0
- package/dist/form.d.ts +61 -0
- package/dist/form.js +675 -0
- package/dist/form.js.map +1 -0
- package/dist/index.d.ts +24 -0
- package/dist/index.js +3708 -0
- package/dist/index.js.map +1 -0
- package/dist/pages.d.ts +73 -0
- package/dist/pages.js +1648 -0
- package/dist/pages.js.map +1 -0
- package/dist/palette.d.ts +28 -0
- package/dist/palette.js +285 -0
- package/dist/palette.js.map +1 -0
- package/dist/primitives.d.ts +76 -0
- package/dist/primitives.js +660 -0
- package/dist/primitives.js.map +1 -0
- package/dist/resource.d.ts +27 -0
- package/dist/resource.js +722 -0
- package/dist/resource.js.map +1 -0
- package/dist/shell.d.ts +50 -0
- package/dist/shell.js +1048 -0
- package/dist/shell.js.map +1 -0
- package/dist/table.d.ts +13 -0
- package/dist/table.js +620 -0
- package/dist/table.js.map +1 -0
- package/dist/utility.d.ts +62 -0
- package/dist/utility.js +106 -0
- package/dist/utility.js.map +1 -0
- package/dist/utils.d.ts +12 -0
- package/dist/utils.js +11 -0
- package/dist/utils.js.map +1 -0
- package/dist/widgets.d.ts +163 -0
- package/dist/widgets.js +677 -0
- package/dist/widgets.js.map +1 -0
- package/package.json +145 -0
- package/src/styles/globals.css +137 -0
package/dist/pages.d.ts
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { JSX, ComponentType } from 'react';
|
|
2
|
+
import { RecordType } from '@arqel-dev/types/resources';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Default Inertia page for `arqel::create`.
|
|
6
|
+
*
|
|
7
|
+
* Renders a `<FormRenderer>` over the schema/fields the server
|
|
8
|
+
* emits (with `record: null`). Submission goes through Inertia's
|
|
9
|
+
* `useForm` via `useArqelForm` from `@arqel-dev/hooks` — this page is
|
|
10
|
+
* just the layout shell.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
declare function ArqelCreatePage(): JSX.Element;
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Default Inertia page for `arqel::edit`.
|
|
17
|
+
*
|
|
18
|
+
* Same shape as `ArqelCreatePage` but seeds the form with the
|
|
19
|
+
* server-emitted `record`. Submission posts to PUT `/{slug}/{id}`.
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
declare function ArqelEditPage<TRecord extends RecordType = RecordType>(): JSX.Element;
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Default Inertia page for `arqel::index`.
|
|
26
|
+
*
|
|
27
|
+
* Pulls every prop the server emits via `InertiaDataBuilder::
|
|
28
|
+
* buildIndexData` / `buildTableIndexData` and forwards them to
|
|
29
|
+
* `<ResourceIndex>`. Apps can override per-resource by registering
|
|
30
|
+
* their own page component at `Pages/Arqel/{Slug}/Index.tsx` (the
|
|
31
|
+
* lookup falls through to user pages first inside `createArqelApp`).
|
|
32
|
+
*/
|
|
33
|
+
|
|
34
|
+
declare function ArqelIndexPage<TRecord extends RecordType = RecordType>(): JSX.Element;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Default Inertia page for `arqel::show`.
|
|
38
|
+
*
|
|
39
|
+
* Read-only render of the record. Re-uses `<FormRenderer>` with
|
|
40
|
+
* every field forced to disabled — keeps a single rendering path
|
|
41
|
+
* for create/edit/show without a parallel "DetailRenderer" stack.
|
|
42
|
+
*/
|
|
43
|
+
|
|
44
|
+
declare function ArqelShowPage<TRecord extends RecordType = RecordType>(): JSX.Element;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Built-in Inertia page registry for `arqel::*`.
|
|
48
|
+
*
|
|
49
|
+
* `createArqelApp({ pages })` from `@arqel-dev/react/inertia` accepts
|
|
50
|
+
* one or more `PageRegistry` records — merge `arqelPages` first so
|
|
51
|
+
* user-defined pages can override per-resource:
|
|
52
|
+
*
|
|
53
|
+
* ```ts
|
|
54
|
+
* import { arqelPages } from '@arqel-dev/ui/pages';
|
|
55
|
+
* import { createArqelApp } from '@arqel-dev/react/inertia';
|
|
56
|
+
*
|
|
57
|
+
* const userPages = import.meta.glob('./Pages/**\/*.tsx');
|
|
58
|
+
*
|
|
59
|
+
* createArqelApp({
|
|
60
|
+
* pages: { ...arqelPages, ...userPages },
|
|
61
|
+
* });
|
|
62
|
+
* ```
|
|
63
|
+
*
|
|
64
|
+
* Names match what `ResourceController` emits via
|
|
65
|
+
* `Inertia::render('arqel::index', ...)`.
|
|
66
|
+
*/
|
|
67
|
+
|
|
68
|
+
type LazyPage = () => Promise<{
|
|
69
|
+
default: ComponentType<unknown>;
|
|
70
|
+
}>;
|
|
71
|
+
declare const arqelPages: Record<string, LazyPage>;
|
|
72
|
+
|
|
73
|
+
export { ArqelCreatePage, ArqelEditPage, ArqelIndexPage, ArqelShowPage, arqelPages };
|