@praxisui/crud 9.0.0-beta.7 → 9.0.0-beta.71
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 +26 -9
- package/ai/component-registry.json +10741 -0
- package/fesm2022/praxisui-crud.mjs +569 -73
- package/package.json +12 -8
- package/types/praxisui-crud.d.ts +39 -1
package/README.md
CHANGED
|
@@ -26,7 +26,7 @@ npm i @praxisui/crud@latest
|
|
|
26
26
|
Peer dependencies:
|
|
27
27
|
|
|
28
28
|
- `@angular/common`, `@angular/core`, `@angular/forms`, `@angular/cdk`, `@angular/material`, `@angular/router` `^21.0.0`
|
|
29
|
-
- `@praxisui/core`, `@praxisui/table`, `@praxisui/dynamic-form`, `@praxisui/dynamic-fields`, `@praxisui/settings-panel`, `@praxisui/ai` `^9.0.0-beta.
|
|
29
|
+
- `@praxisui/core`, `@praxisui/table`, `@praxisui/dynamic-form`, `@praxisui/dynamic-fields`, `@praxisui/settings-panel`, `@praxisui/ai` `^9.0.0-beta.12`
|
|
30
30
|
- `rxjs` `~7.8.0`
|
|
31
31
|
|
|
32
32
|
## Quick Start
|
|
@@ -127,22 +127,39 @@ Child component semantics stay with their owners:
|
|
|
127
127
|
CRUD actions can open by route, modal, or drawer. `CrudLauncherService` resolves the final mode from persisted overrides, action metadata, and global/default configuration.
|
|
128
128
|
|
|
129
129
|
```ts
|
|
130
|
-
const editAction = {
|
|
130
|
+
const editAction: CrudAction = {
|
|
131
131
|
id: 'edit',
|
|
132
|
-
|
|
132
|
+
action: 'edit',
|
|
133
|
+
label: 'Edit employee',
|
|
133
134
|
openMode: 'drawer',
|
|
134
|
-
|
|
135
|
+
};
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
For canonical `create`, `view`, `edit`, and `delete` operations, prefer inferred
|
|
139
|
+
contracts. The runtime resolves the stable form id, request schema, submit URL,
|
|
140
|
+
and HTTP method from the resource path, capabilities, surfaces, and HATEOAS
|
|
141
|
+
links. Use an explicit form contract only when the operation deliberately
|
|
142
|
+
overrides that baseline:
|
|
143
|
+
|
|
144
|
+
```ts
|
|
145
|
+
const explicitEditAction: CrudAction = {
|
|
146
|
+
id: 'edit',
|
|
147
|
+
action: 'edit',
|
|
148
|
+
label: 'Edit employee',
|
|
149
|
+
openMode: 'drawer',
|
|
150
|
+
formId: 'employee-edit',
|
|
151
|
+
mode: 'explicit',
|
|
135
152
|
form: {
|
|
136
|
-
formId: 'employee-edit',
|
|
137
153
|
schemaUrl: '/api/employees/schemas/edit',
|
|
138
|
-
submitUrl: '/api/employees
|
|
139
|
-
submitMethod: '
|
|
154
|
+
submitUrl: '/api/employees/{id}',
|
|
155
|
+
submitMethod: 'put',
|
|
140
156
|
},
|
|
141
|
-
params: [{ from: 'row.id', to: 'path.id', name: 'id' }],
|
|
142
157
|
};
|
|
143
158
|
```
|
|
144
159
|
|
|
145
|
-
|
|
160
|
+
Drawer mode works without a host adapter: the package opens its standard form
|
|
161
|
+
dialog host with drawer presentation. Provide `CRUD_DRAWER_ADAPTER` only when a
|
|
162
|
+
host must replace that standard shell with a real corporate drawer implementation.
|
|
146
163
|
|
|
147
164
|
## Visual Authoring
|
|
148
165
|
|