@cxtms/cx-schema 1.9.66 → 1.9.241
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/dist/cli.js +43 -9
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
- package/schemas/actions/all.json +5 -1
- package/schemas/actions/reload.json +17 -0
- package/schemas/actions/setSessionStorage.json +38 -0
- package/schemas/actions/sound.json +39 -0
- package/schemas/actions/vibrate.json +48 -0
- package/schemas/components/avatar.json +1 -0
- package/schemas/components/badge.json +79 -0
- package/schemas/components/barcodeScanner.json +28 -0
- package/schemas/components/camera.json +177 -0
- package/schemas/components/card.json +78 -0
- package/schemas/components/dashboard-widget.json +39 -0
- package/schemas/components/dashboard.json +46 -0
- package/schemas/components/dataGrid.json +15 -0
- package/schemas/components/field-collection.json +86 -2
- package/schemas/components/field.json +39 -4
- package/schemas/components/form.json +4 -0
- package/schemas/components/index.json +17 -1
- package/schemas/components/infoLine.json +1 -0
- package/schemas/components/map.json +167 -0
- package/schemas/components/module.json +32 -0
- package/schemas/components/planner.json +1 -0
- package/schemas/components/progressBar.json +1 -0
- package/schemas/components/timeline.json +216 -74
- package/schemas/components/timelineGrid.json +5 -1
- package/schemas/fields/autocomplete-googleplaces.json +2 -2
- package/schemas/fields/datetime.json +2 -2
- package/schemas/fields/index.json +4 -0
- package/schemas/fields/number-select.json +88 -0
- package/schemas/fields/rangedatetime.json +10 -2
- package/schemas/fields/select-async.json +2 -2
- package/schemas/fields/toggle.json +91 -0
- package/schemas/schema.graphql +11016 -12171
- package/schemas/schemas.json +131 -4
- package/schemas/workflows/flow/entity.json +3 -1
- package/schemas/workflows/input.json +1 -1
- package/schemas/workflows/output.json +1 -1
- package/schemas/workflows/tasks/all.json +9 -0
- package/schemas/workflows/tasks/commodity.json +8 -0
- package/schemas/workflows/tasks/contact-address.json +25 -0
- package/schemas/workflows/tasks/dispatch-routes.json +64 -0
- package/schemas/workflows/tasks/edi.json +15 -0
- package/schemas/workflows/tasks/export.json +21 -0
- package/schemas/workflows/tasks/httpRequest.json +4 -0
- package/schemas/workflows/tasks/import.json +5 -0
- package/schemas/workflows/tasks/order-move.json +38 -0
- package/schemas/workflows/tasks/order.json +6 -0
- package/schemas/workflows/tasks/organization-config.json +101 -0
- package/schemas/workflows/tasks/tracking-event.json +11 -3
- package/schemas/workflows/tasks/workflow-execute.json +4 -0
- package/schemas/workflows/variable.json +2 -2
- package/schemas/workflows/workflow.json +39 -2
- package/skills/cxtms-developer/SKILL.md +5 -2
- package/skills/cxtms-developer/ref-cli-auth.md +2 -0
- package/skills/cxtms-developer/ref-entity-commodity.md +41 -5
- package/skills/cxtms-developer/ref-entity-contact.md +46 -0
- package/skills/cxtms-developer/ref-entity-dispatch-routing.md +195 -0
- package/skills/cxtms-developer/ref-entity-geography.md +26 -1
- package/skills/cxtms-developer/ref-entity-job.md +6 -2
- package/skills/cxtms-developer/ref-entity-order-sub.md +1 -1
- package/skills/cxtms-developer/ref-entity-order.md +36 -3
- package/skills/cxtms-developer/ref-entity-organization.md +4 -2
- package/skills/cxtms-developer/ref-entity-shared.md +79 -3
- package/skills/cxtms-developer/ref-graphql-query.md +246 -4
- package/skills/cxtms-module-builder/SKILL.md +33 -6
- package/skills/cxtms-module-builder/ref-components-data.md +85 -0
- package/skills/cxtms-module-builder/ref-components-display.md +282 -8
- package/skills/cxtms-module-builder/ref-components-forms.md +386 -21
- package/skills/cxtms-module-builder/ref-components-interactive.md +2 -0
- package/skills/cxtms-module-builder/ref-components-layout.md +288 -29
- package/skills/cxtms-module-builder/ref-components-specialized.md +168 -20
- package/skills/cxtms-workflow-builder/SKILL.md +45 -6
- package/skills/cxtms-workflow-builder/ref-entity.md +100 -4
- package/skills/cxtms-workflow-builder/ref-expressions-ncalc.md +35 -2
- package/skills/cxtms-workflow-builder/ref-expressions-template.md +15 -1
- package/skills/cxtms-workflow-builder/ref-flow.md +6 -1
- package/skills/cxtms-workflow-builder/ref-query.md +16 -0
- package/skills/cxtms-workflow-builder/ref-utilities.md +32 -2
- package/templates/workflow-public-api.yaml +1 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# Layout & Structure Components
|
|
2
2
|
|
|
3
3
|
## Contents
|
|
4
|
+
- Adaptive / Responsive Design (mobile, tablet, desktop)
|
|
4
5
|
- Layout component
|
|
5
6
|
- Row component
|
|
6
7
|
- Col component
|
|
@@ -11,6 +12,189 @@
|
|
|
11
12
|
- Line component
|
|
12
13
|
- Slot component
|
|
13
14
|
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## Adaptive / Responsive Design (Mobile, Tablet, Desktop)
|
|
18
|
+
|
|
19
|
+
CXTMS UI uses MUI Grid v2 breakpoints. **Design mobile-first**: define `xs` behavior, then progressively enhance for `sm`, `md`, `lg`, `xl`.
|
|
20
|
+
|
|
21
|
+
### Breakpoints
|
|
22
|
+
|
|
23
|
+
| Token | Min width | Target devices |
|
|
24
|
+
|-------|-----------|----------------|
|
|
25
|
+
| `xs` | 0px | Phone (portrait) |
|
|
26
|
+
| `sm` | 600px | Phone (landscape), small tablet |
|
|
27
|
+
| `md` | 900px | Tablet, small laptop |
|
|
28
|
+
| `lg` | 1200px | Desktop |
|
|
29
|
+
| `xl` | 1536px | Large desktop / wide monitor |
|
|
30
|
+
|
|
31
|
+
### Responsive props (modern MUI Grid v2)
|
|
32
|
+
|
|
33
|
+
These accept a number (treated as `xs`) **or** an object keyed by breakpoint:
|
|
34
|
+
|
|
35
|
+
| Prop | Where | Example |
|
|
36
|
+
|------|-------|---------|
|
|
37
|
+
| `size` | any layout child | `size: { xs: 12, sm: 6, md: 4, lg: 3 }` |
|
|
38
|
+
| `offset` | any layout child | `offset: { md: 2 }` |
|
|
39
|
+
| `order` | any layout child | `order: { xs: 2, md: 1 }` |
|
|
40
|
+
| `columns` | `layout` container | `columns: { xs: 4, md: 12 }` (total grid columns) |
|
|
41
|
+
| `spacing` | `layout` container | `spacing: { xs: 1, sm: 2, md: 3 }` (sets BOTH row + column gap) |
|
|
42
|
+
| `columnSpacing` | `layout` container | `columnSpacing: { xs: 1, md: 3 }` (horizontal gap only) |
|
|
43
|
+
| `rowSpacing` | `layout` container | `rowSpacing: { xs: 2, md: 4 }` (vertical gap only) |
|
|
44
|
+
| `itemDefaults.size` | `layout` container | `itemDefaults: { size: { xs: 12, md: 6 } }` |
|
|
45
|
+
|
|
46
|
+
> **Modern spacing pattern** (MUI Grid v2 `row-and-column-spacing`): use `rowSpacing` and `columnSpacing` independently when you need different gap values for stacked vs side-by-side, or to tighten the layout on phones. Use `spacing` when both axes should match. All three accept responsive breakpoint maps.
|
|
47
|
+
|
|
48
|
+
### Legacy props — DO NOT use in new code
|
|
49
|
+
|
|
50
|
+
| Legacy | Replace with |
|
|
51
|
+
|--------|-------------|
|
|
52
|
+
| `cols: N` (on `layout` or `form`) | `itemDefaults: { size: { xs: 12, md: <12/N> } }` on a `layout`. Non-responsive and ignored on mobile. |
|
|
53
|
+
| `row` component | `layout` component with responsive `columns` / `itemDefaults.size`. `row` has no breakpoint-aware `columns` and no `itemDefaults`. Existing `row` usages can stay; new code uses `layout`. |
|
|
54
|
+
| Bare `spacing: 3` (single number) | Still valid, but prefer `rowSpacing` / `columnSpacing` (or responsive `spacing: { xs, md }`) for adaptive layouts. |
|
|
55
|
+
|
|
56
|
+
### Mobile-first patterns
|
|
57
|
+
|
|
58
|
+
#### One column on mobile → two on tablet → three on desktop
|
|
59
|
+
```yaml
|
|
60
|
+
component: layout
|
|
61
|
+
name: detailFields
|
|
62
|
+
props:
|
|
63
|
+
rowSpacing: { xs: 2, md: 3 } # vertical gap grows on desktop
|
|
64
|
+
columnSpacing: { xs: 0, sm: 2, md: 3 } # horizontal gap only when columns appear
|
|
65
|
+
itemDefaults:
|
|
66
|
+
size: { xs: 12, sm: 6, md: 4 }
|
|
67
|
+
children:
|
|
68
|
+
- component: field
|
|
69
|
+
name: name
|
|
70
|
+
props: { type: text, label: { en-US: "Name" } }
|
|
71
|
+
- component: field
|
|
72
|
+
name: code
|
|
73
|
+
props: { type: text, label: { en-US: "Code" } }
|
|
74
|
+
- component: field
|
|
75
|
+
name: status
|
|
76
|
+
props: { type: select, label: { en-US: "Status" } }
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
#### Side-by-side on desktop, stacked on mobile (8/4 split)
|
|
80
|
+
```yaml
|
|
81
|
+
component: layout
|
|
82
|
+
props:
|
|
83
|
+
spacing: { xs: 2, md: 3 } # uniform gap, larger on desktop
|
|
84
|
+
children:
|
|
85
|
+
- component: card
|
|
86
|
+
name: mainPanel
|
|
87
|
+
props:
|
|
88
|
+
size: { xs: 12, md: 8 }
|
|
89
|
+
children: [ ... ]
|
|
90
|
+
- component: card
|
|
91
|
+
name: sidebar
|
|
92
|
+
props:
|
|
93
|
+
size: { xs: 12, md: 4 }
|
|
94
|
+
children: [ ... ]
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
#### Reorder on mobile (e.g., put summary first on phones)
|
|
98
|
+
```yaml
|
|
99
|
+
component: layout
|
|
100
|
+
props:
|
|
101
|
+
rowSpacing: { xs: 2, md: 0 } # spacing only when stacked
|
|
102
|
+
columnSpacing: { md: 3 }
|
|
103
|
+
children:
|
|
104
|
+
- component: card
|
|
105
|
+
name: details
|
|
106
|
+
props:
|
|
107
|
+
size: { xs: 12, md: 8 }
|
|
108
|
+
order: { xs: 2, md: 1 }
|
|
109
|
+
children: [ ... ]
|
|
110
|
+
- component: card
|
|
111
|
+
name: summary
|
|
112
|
+
props:
|
|
113
|
+
size: { xs: 12, md: 4 }
|
|
114
|
+
order: { xs: 1, md: 2 }
|
|
115
|
+
children: [ ... ]
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
#### Responsive total columns (12-grid on desktop, 4-grid on mobile)
|
|
119
|
+
```yaml
|
|
120
|
+
component: layout
|
|
121
|
+
props:
|
|
122
|
+
columns: { xs: 4, md: 12 }
|
|
123
|
+
spacing: { xs: 1, md: 2 }
|
|
124
|
+
children:
|
|
125
|
+
- component: field
|
|
126
|
+
name: a
|
|
127
|
+
props: { type: text, size: { xs: 4, md: 3 } }
|
|
128
|
+
- component: field
|
|
129
|
+
name: b
|
|
130
|
+
props: { type: text, size: { xs: 4, md: 3 } }
|
|
131
|
+
- component: field
|
|
132
|
+
name: c
|
|
133
|
+
props: { type: text, size: { xs: 4, md: 6 } }
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
#### Different row vs column gaps (modern row-and-column-spacing pattern)
|
|
137
|
+
```yaml
|
|
138
|
+
# Form fields: tight column gap, comfortable row gap, both grow on desktop
|
|
139
|
+
component: layout
|
|
140
|
+
props:
|
|
141
|
+
columnSpacing: { xs: 1, md: 2 }
|
|
142
|
+
rowSpacing: { xs: 2, md: 4 }
|
|
143
|
+
itemDefaults:
|
|
144
|
+
size: { xs: 12, md: 6 }
|
|
145
|
+
children:
|
|
146
|
+
- component: field
|
|
147
|
+
name: firstName
|
|
148
|
+
props: { type: text, label: { en-US: "First Name" } }
|
|
149
|
+
- component: field
|
|
150
|
+
name: lastName
|
|
151
|
+
props: { type: text, label: { en-US: "Last Name" } }
|
|
152
|
+
- component: field
|
|
153
|
+
name: email
|
|
154
|
+
props: { type: email, label: { en-US: "Email" }, size: { xs: 12 } }
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
#### Flex-wrapping toolbar / chip set (no grid math)
|
|
158
|
+
```yaml
|
|
159
|
+
component: layout
|
|
160
|
+
name: actions
|
|
161
|
+
props:
|
|
162
|
+
containerTag: box # flex-wrap container, not Grid
|
|
163
|
+
spacing: { xs: 1, md: 2 }
|
|
164
|
+
alignItems: center
|
|
165
|
+
children:
|
|
166
|
+
- component: button
|
|
167
|
+
name: refresh
|
|
168
|
+
props: { label: { en-US: "Refresh" }, icon: refresh-cw }
|
|
169
|
+
- component: button
|
|
170
|
+
name: export
|
|
171
|
+
props: { label: { en-US: "Export" }, icon: download }
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
### Mobile sanity checklist
|
|
175
|
+
|
|
176
|
+
- Default to single column (`size: 12`) on `xs`. Never assume horizontal space on phones.
|
|
177
|
+
- Don't exceed **2 columns on `sm`**, **3 columns on `md`**, **4 columns on `lg`**. Avoid 5+ across.
|
|
178
|
+
- Long fields (`textarea`, `quill`, `attachment`, multiline notes) should always be `size: { xs: 12 }` regardless of viewport.
|
|
179
|
+
- Tap targets ≥ 44px — use default `button` size for primary actions on mobile, not `size: small`.
|
|
180
|
+
- `tabs` are horizontally scrollable; verify labels are short or use `icon` only on `xs`.
|
|
181
|
+
- Avoid horizontal scroll inside a card on `xs`. Use `dataGrid` filter collapse or stack columns into a card-list view.
|
|
182
|
+
- Pair fields that belong together (firstName/lastName, qty/uom, from/to) — give them the same breakpoints so they always wrap together.
|
|
183
|
+
- Use `containerTag: box` for **non-grid** flex-wrap layouts (icon toolbars, chip sets, tag rows) — saves you from grid math.
|
|
184
|
+
|
|
185
|
+
### Style rules — do not use for layouts
|
|
186
|
+
|
|
187
|
+
- **Do NOT use CSS class names (`className`) for layout** on `layout`, `row`, or `col`. Use:
|
|
188
|
+
- `size` / `columns` / `offset` for sizing
|
|
189
|
+
- `spacing` / `rowSpacing` / `columnSpacing` for gaps
|
|
190
|
+
- `sx` / `containerSx` / `itemDefaults.sx` for any visual tweaks (colors, borders, custom margins)
|
|
191
|
+
- `containerTag: box` for flex-wrap layouts
|
|
192
|
+
- **Do NOT use `cols: N`** on `layout` or `form`. Use `itemDefaults: { size: { xs: 12, md: <12/N> } }`.
|
|
193
|
+
- **Do NOT use the `row` component** in new code. Use `layout` with responsive `columns` and `itemDefaults.size`.
|
|
194
|
+
- **Do NOT mix `spacing` with both `rowSpacing` and `columnSpacing`** — when both axes are set explicitly, omit `spacing`.
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
14
198
|
## layout
|
|
15
199
|
|
|
16
200
|
General-purpose container. Renders MUI Grid or Box with flexbox.
|
|
@@ -18,35 +202,42 @@ General-purpose container. Renders MUI Grid or Box with flexbox.
|
|
|
18
202
|
**Props:**
|
|
19
203
|
| Prop | Type | Default | Description |
|
|
20
204
|
|------|------|---------|-------------|
|
|
21
|
-
| `
|
|
22
|
-
| `
|
|
23
|
-
| `
|
|
24
|
-
| `
|
|
25
|
-
| `
|
|
205
|
+
| `columns` | `number \| {xs,sm,md,lg,xl}` | `12` | Total grid columns. Use a breakpoint map for responsive grid resolution (e.g. `{ xs: 4, md: 12 }`). |
|
|
206
|
+
| `spacing` | `number \| string \| {xs,sm,md,lg,xl}` | `3` | Grid gap (BOTH row and column). Accepts a breakpoint map per modern MUI Grid v2. Set `rowSpacing` / `columnSpacing` to override one axis. |
|
|
207
|
+
| `columnSpacing` | `number \| string \| {xs,sm,md,lg,xl}` | — | Horizontal gap only. Overrides `spacing` on the column axis. |
|
|
208
|
+
| `rowSpacing` | `number \| string \| {xs,sm,md,lg,xl}` | — | Vertical gap only. Overrides `spacing` on the row axis. |
|
|
209
|
+
| `itemDefaults` | `{size?,offset?,order?,sx?,alignSelf?}` | — | Default Grid item props applied to every child (overridable per-child). **Primary lever for responsive child sizing.** |
|
|
210
|
+
| `containerTag` | `grid \| box` | `grid` | `grid` = MUI Grid (12-col math); `box` = flex-wrap container (no grid math). For `box`, only `spacing` is used (as the `gap` value). |
|
|
26
211
|
| `containerSx` | `SxProps` | — | MUI sx styles on container |
|
|
27
|
-
| `className` | `string` | — | CSS class (template-parsed) |
|
|
28
212
|
| `id` | `string` | — | Element ID (template-parsed) |
|
|
29
|
-
| `direction` | `row \| column` |
|
|
30
|
-
| `
|
|
31
|
-
| `
|
|
213
|
+
| `direction` | `row \| column` | `row` | Explicit flex direction (overrides `orientation`) |
|
|
214
|
+
| `orientation` | `horizontal \| vertical \| flex` | `horizontal` | Convenience wrapper that sets `direction` |
|
|
215
|
+
| `justifyContent` | `flex-start \| flex-end \| center \| space-between \| space-around \| space-evenly` | — | Flexbox main-axis alignment |
|
|
216
|
+
| `alignItems` | `flex-start \| flex-end \| center \| stretch \| baseline` | — | Flexbox cross-axis alignment |
|
|
217
|
+
| `margin` / `marginTop` / `marginBottom` / `marginLeft` / `marginRight` | `number \| string` | — | Container margin (MUI spacing units or CSS values) |
|
|
218
|
+
| `padding` / `paddingTop` / `paddingBottom` / `paddingLeft` / `paddingRight` | `number \| string` | — | Container padding |
|
|
32
219
|
| `refreshHandler` | `string` | — | Remounts on refresh event |
|
|
33
220
|
| `permission` | `string` | — | Permission gate |
|
|
34
221
|
| `title` | `ILocalizeString` | — | Layout title |
|
|
35
222
|
| `icon` | `string` | — | Layout icon |
|
|
36
223
|
| `toolbar` | `component[]` | — | Toolbar components |
|
|
37
|
-
|
|
|
224
|
+
| ~~`cols: number`~~ | _legacy_ | — | **Deprecated.** Non-responsive equal-width columns. Replace with `itemDefaults: { size: { xs: 12, md: <12/N> } }`. |
|
|
225
|
+
| ~~`className`~~ | _legacy_ | — | **Do not use for layout styling.** Layouts must use `size`, `columns`, `spacing`/`columnSpacing`/`rowSpacing`, and `sx` / `containerSx` / `itemDefaults.sx` for visual control — not CSS class names. |
|
|
38
226
|
|
|
39
227
|
**Events:** `onClick`
|
|
40
228
|
|
|
41
229
|
**Children:** Yes — each child rendered via ComponentRender, wrapped in Grid item.
|
|
42
230
|
|
|
43
231
|
```yaml
|
|
44
|
-
#
|
|
232
|
+
# Adaptive 2-column layout (1 col on mobile, 2 on tablet+)
|
|
233
|
+
# Modern MUI Grid v2 spacing: tighter columns + comfortable rows, both grow on desktop.
|
|
45
234
|
component: layout
|
|
46
235
|
name: detailLayout
|
|
47
236
|
props:
|
|
48
|
-
|
|
49
|
-
|
|
237
|
+
columnSpacing: { xs: 1, md: 2 }
|
|
238
|
+
rowSpacing: { xs: 2, md: 3 }
|
|
239
|
+
itemDefaults:
|
|
240
|
+
size: { xs: 12, md: 6 }
|
|
50
241
|
title:
|
|
51
242
|
en-US: "Detail View"
|
|
52
243
|
icon: file-text
|
|
@@ -58,8 +249,18 @@ children:
|
|
|
58
249
|
- component: field
|
|
59
250
|
name: lastName
|
|
60
251
|
props: { type: text, label: { en-US: "Last Name" } }
|
|
252
|
+
- component: field
|
|
253
|
+
name: notes
|
|
254
|
+
props:
|
|
255
|
+
type: textarea
|
|
256
|
+
label: { en-US: "Notes" }
|
|
257
|
+
rows: 3
|
|
258
|
+
size: { xs: 12 } # always full width — overrides itemDefaults
|
|
61
259
|
```
|
|
62
260
|
|
|
261
|
+
> **Do NOT use `cols: 2`** — non-responsive and forces the same column count on every viewport. Use `itemDefaults: { size: { xs: 12, md: 6 } }` instead.
|
|
262
|
+
> **Do NOT use CSS class names for layout styling.** Use breakpoint props (`size`, `columns`), spacing props (`spacing`, `rowSpacing`, `columnSpacing`), and `sx` / `containerSx` / `itemDefaults.sx` for visual control. The `className` prop is reserved for non-layout styling concerns (theming hooks, animations, etc.) and should generally be omitted.
|
|
263
|
+
|
|
63
264
|
```yaml
|
|
64
265
|
# Horizontal flex layout with toolbar
|
|
65
266
|
component: layout
|
|
@@ -81,40 +282,66 @@ children:
|
|
|
81
282
|
|
|
82
283
|
---
|
|
83
284
|
|
|
84
|
-
## row
|
|
285
|
+
## row — LEGACY (use `layout` instead)
|
|
85
286
|
|
|
86
|
-
|
|
287
|
+
> **For new code, use `layout` instead of `row`.** The `layout` component supports `itemDefaults`, breakpoint-mapped `columns`, and the modern `rowSpacing`/`columnSpacing` pattern. The `row` component is kept for backwards compatibility with existing modules.
|
|
288
|
+
|
|
289
|
+
Horizontal MUI Grid row. Existing usages can stay; do not introduce new `row` blocks.
|
|
87
290
|
|
|
88
291
|
**Props:**
|
|
89
292
|
| Prop | Type | Default | Description |
|
|
90
293
|
|------|------|---------|-------------|
|
|
91
|
-
| `spacing` | `number` | `3` | Grid
|
|
92
|
-
| `
|
|
294
|
+
| `spacing` | `number \| string \| {xs,sm,md,lg,xl}` | `3` | Grid gap (both axes). Accepts breakpoint maps. |
|
|
295
|
+
| `columnSpacing` | `number \| string \| {xs,sm,md,lg,xl}` | — | Horizontal gap only |
|
|
296
|
+
| `rowSpacing` | `number \| string \| {xs,sm,md,lg,xl}` | — | Vertical gap only |
|
|
297
|
+
| `columns` | `number \| {xs,sm,md,lg,xl}` | `12` | Grid total columns |
|
|
93
298
|
| `direction` | `row \| column` | `row` | Grid direction |
|
|
94
299
|
| `sx` | `SxProps` | — | MUI sx styles |
|
|
95
|
-
| `className` | `string` | — | CSS class |
|
|
96
300
|
| `alignItems` | `string` | — | Cross-axis alignment |
|
|
97
301
|
| `justifyContent` | `string` | — | Main-axis alignment |
|
|
302
|
+
| ~~`className`~~ | _legacy_ | — | **Do not use for layout styling.** Use `sx` instead. |
|
|
98
303
|
|
|
99
|
-
**Children:** Yes — rendered without Grid item wrapper (use `
|
|
304
|
+
**Children:** Yes — rendered without Grid item wrapper (use children with responsive `size`).
|
|
100
305
|
|
|
101
306
|
```yaml
|
|
307
|
+
# PREFERRED — equivalent adaptive header using `layout` (modern, with row/column spacing)
|
|
308
|
+
component: layout
|
|
309
|
+
name: headerLayout
|
|
310
|
+
props:
|
|
311
|
+
rowSpacing: { xs: 1, sm: 0 }
|
|
312
|
+
columnSpacing: { sm: 2 }
|
|
313
|
+
alignItems: center
|
|
314
|
+
children:
|
|
315
|
+
- component: text
|
|
316
|
+
name: title
|
|
317
|
+
props:
|
|
318
|
+
value: "Header"
|
|
319
|
+
type: h3
|
|
320
|
+
size: { xs: 12, sm: 8 }
|
|
321
|
+
- component: button
|
|
322
|
+
name: actionBtn
|
|
323
|
+
props:
|
|
324
|
+
label: { en-US: "Action" }
|
|
325
|
+
size: { xs: 12, sm: 4 }
|
|
326
|
+
sx: { textAlign: { xs: 'left', sm: 'right' } }
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
```yaml
|
|
330
|
+
# LEGACY (existing modules only — do not use in new code)
|
|
102
331
|
component: row
|
|
103
332
|
name: headerRow
|
|
104
333
|
props:
|
|
105
|
-
spacing: 2
|
|
334
|
+
spacing: { xs: 1, sm: 2 }
|
|
106
335
|
alignItems: center
|
|
107
336
|
children:
|
|
108
337
|
- component: col
|
|
109
|
-
|
|
110
|
-
props: { size: 6 }
|
|
338
|
+
props: { size: { xs: 12, sm: 8 } }
|
|
111
339
|
children:
|
|
112
340
|
- component: text
|
|
113
341
|
name: title
|
|
114
342
|
props: { value: "Header", type: h3 }
|
|
115
343
|
- component: col
|
|
116
|
-
|
|
117
|
-
props: { size: 6 }
|
|
344
|
+
props: { size: { xs: 12, sm: 4 } }
|
|
118
345
|
children:
|
|
119
346
|
- component: button
|
|
120
347
|
name: actionBtn
|
|
@@ -125,26 +352,49 @@ children:
|
|
|
125
352
|
|
|
126
353
|
## col
|
|
127
354
|
|
|
128
|
-
Grid column item. Child of `row` or `layout`.
|
|
355
|
+
Grid column item. Child of `row` or `layout`. The primary primitive for **per-child responsive sizing**.
|
|
129
356
|
|
|
130
357
|
**Props:**
|
|
131
358
|
| Prop | Type | Description |
|
|
132
359
|
|------|------|-------------|
|
|
133
|
-
| `size` | `number \| {xs,sm,md,lg,xl}` |
|
|
134
|
-
| `offset` | `number \| {xs,sm,md,lg,xl}` |
|
|
135
|
-
| `order` | `number \| {xs,sm,md,lg,xl}` | CSS order
|
|
360
|
+
| `size` | `number \| {xs,sm,md,lg,xl}` | Column width in 12-grid (or parent's `columns` total). Plain number = `xs` only. Object = per-breakpoint width. |
|
|
361
|
+
| `offset` | `number \| {xs,sm,md,lg,xl}` | Leading offset (push column right) |
|
|
362
|
+
| `order` | `number \| {xs,sm,md,lg,xl}` | CSS `order` — change visual order per breakpoint |
|
|
136
363
|
| `sx` | `SxProps` | MUI sx styles |
|
|
137
|
-
| `className` | `string` | CSS class |
|
|
138
364
|
| `alignSelf` | `string` | CSS align-self |
|
|
365
|
+
| ~~`className`~~ | _legacy_ | **Do not use for layout styling.** Use `sx` instead. |
|
|
139
366
|
|
|
140
367
|
**Children:** Yes.
|
|
141
368
|
|
|
142
369
|
```yaml
|
|
370
|
+
# Centered content column — full-width on mobile, 8 of 12 on desktop with 2-col offset
|
|
143
371
|
component: col
|
|
144
372
|
name: mainContent
|
|
145
373
|
props:
|
|
146
374
|
size: { xs: 12, md: 8 }
|
|
147
375
|
offset: { md: 2 }
|
|
376
|
+
children:
|
|
377
|
+
- component: text
|
|
378
|
+
name: body
|
|
379
|
+
props: { value: "Content...", type: p }
|
|
380
|
+
```
|
|
381
|
+
|
|
382
|
+
```yaml
|
|
383
|
+
# Reorder on mobile — show summary above details on phones, beside on desktop
|
|
384
|
+
component: row
|
|
385
|
+
children:
|
|
386
|
+
- component: col
|
|
387
|
+
name: details
|
|
388
|
+
props:
|
|
389
|
+
size: { xs: 12, md: 8 }
|
|
390
|
+
order: { xs: 2, md: 1 }
|
|
391
|
+
children: [ ... ]
|
|
392
|
+
- component: col
|
|
393
|
+
name: summary
|
|
394
|
+
props:
|
|
395
|
+
size: { xs: 12, md: 4 }
|
|
396
|
+
order: { xs: 1, md: 2 }
|
|
397
|
+
children: [ ... ]
|
|
148
398
|
```
|
|
149
399
|
|
|
150
400
|
---
|
|
@@ -259,6 +509,7 @@ MUI Card container with optional header, content, and actions.
|
|
|
259
509
|
| `variant` | `elevation \| outlined` | — | MUI Card variant |
|
|
260
510
|
| `elevation` | `number` | — | Shadow depth |
|
|
261
511
|
| `sx` | `SxProps` | — | Card sx styles |
|
|
512
|
+
| `style` | `{light?,dark?}` | — | Theme-aware root CSSProperties applied after `sx`; use `style.light` for light mode and `style.dark` for dark mode |
|
|
262
513
|
| `className` | `string` | — | Additional CSS class |
|
|
263
514
|
| `bgcolor` | `string` | — | Background color |
|
|
264
515
|
| `color` | `string` | — | Text color |
|
|
@@ -275,6 +526,9 @@ name: summaryCard
|
|
|
275
526
|
props:
|
|
276
527
|
options:
|
|
277
528
|
variant: outlined
|
|
529
|
+
style:
|
|
530
|
+
light: { backgroundColor: "#ffffff", borderColor: "#d7dee8" }
|
|
531
|
+
dark: { backgroundColor: "#121826", borderColor: "#344054", color: "#f8fafc" }
|
|
278
532
|
header:
|
|
279
533
|
title: "Summary"
|
|
280
534
|
subheader: "Last updated today"
|
|
@@ -388,3 +642,8 @@ props:
|
|
|
388
642
|
```
|
|
389
643
|
|
|
390
644
|
**How extensions target slots:** Other modules register extension components using `appComponent` with `targetSlot` and optional `order` to control rendering position within the slot. See `appComponent.json` schema for details.
|
|
645
|
+
|
|
646
|
+
|
|
647
|
+
## dashboard persistence
|
|
648
|
+
|
|
649
|
+
Editable dashboard layout persistence is scoped by dashboard name, organization, and current user. Reads, resets, and cancel-edit restores must include the current user so one user never loads or deletes another user's saved layout.
|