@protobase/cli 0.99.5 → 0.99.7
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/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@protobase/cli",
|
|
3
|
-
"version": "0.99.
|
|
3
|
+
"version": "0.99.7",
|
|
4
4
|
"description": "The protobase command: scaffold, doctor, dev, build and serve a Protobase project.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -43,13 +43,13 @@
|
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@better-auth/core": "^1.7.12",
|
|
45
45
|
"@hono/node-server": "^2.1.3",
|
|
46
|
-
"@protobase/config": "0.99.
|
|
47
|
-
"@protobase/layout": "0.99.
|
|
48
|
-
"@protobase/query": "0.99.
|
|
49
|
-
"@protobase/schema": "0.99.
|
|
50
|
-
"@protobase/server": "0.99.
|
|
51
|
-
"@protobase/ui": "0.99.
|
|
52
|
-
"@protobase/workflows": "0.99.
|
|
46
|
+
"@protobase/config": "0.99.7",
|
|
47
|
+
"@protobase/layout": "0.99.7",
|
|
48
|
+
"@protobase/query": "0.99.7",
|
|
49
|
+
"@protobase/schema": "0.99.7",
|
|
50
|
+
"@protobase/server": "0.99.7",
|
|
51
|
+
"@protobase/ui": "0.99.7",
|
|
52
|
+
"@protobase/workflows": "0.99.7",
|
|
53
53
|
"@react-email/render": "^2.1.0",
|
|
54
54
|
"@scalar/hono-api-reference": "^0.12.10",
|
|
55
55
|
"@sentry/vite-plugin": "^11.10.0",
|
|
@@ -19,11 +19,12 @@ Pages of your own, built from blocks in a JSX layout.
|
|
|
19
19
|
- [Full-width pages](../reference/blocks.md#page): A page fills the whole area beside the sidebar instead of a centred column, for a dashboard with many blocks.
|
|
20
20
|
- [Data blocks](../reference/blocks.md#data): Counts, tables, single records, rows of cards, field values and progress bars.
|
|
21
21
|
- [Related records](../reference/layouts.md#related-records) (beta): Layouts repeat over a record's related records, the records a JSON list of keys points at and the items of a JSON list with `ReferenceManyField`, `ReferenceArrayField`, `ArrayField`, `RecordsIterator` and `ReferenceField`, nested as deep as needed, and a table draws such a list.
|
|
22
|
-
- [Read plans](../reference/layouts.md#how-a-page-reads-its-data) (beta): The build plans one read per data block ahead of time, derives the fields each read needs, and checks every nested read's indexes; custom components that fetch their own data
|
|
22
|
+
- [Read plans](../reference/layouts.md#how-a-page-reads-its-data) (beta): The build plans one read per data block ahead of time, derives the fields each read needs, and checks every nested read's indexes. Every read of a page's records, card rows, counts and related lists starts at once when it opens, and a data block's [text form](../reference/layouts.md#a-pages-text-with-its-records) lists its records; tables, threads, charts and custom components that fetch their own data still load on their own.
|
|
23
23
|
- [Table columns on a phone](../reference/blocks.md#columns-on-a-phone): Table blocks choose which columns show at mobile width by priority, with a sensible default, and fall back to a Markdown table.
|
|
24
24
|
- [Row buttons](../reference/blocks.md#row-buttons) (experimental): A table's rows carry a button labelled by a field of the row, such as its next step; the row decides where it goes: a record tab a field names, a list with a filter built from its fields, or an outside https link a field holds. On mobile width the button sits under the row's first cell.
|
|
25
25
|
- [Record rows](../reference/blocks.md#recordrow): A sideways row of cards for a filter, favorites or saved searches, with a count and new-record marks.
|
|
26
26
|
- [Record cards](../reference/blocks.md#recordcards): Full-width cards with fields and buttons, stacked or in a carousel.
|
|
27
|
+
- [Diff block](../reference/blocks.md#diff) (beta): A `Diff` block shows a unified patch the record holds, side by side on wide screens and in one column on a phone; it shows stored patches and does not compute them.
|
|
27
28
|
- [Image block](../reference/blocks.md#image): A picture one of the app's API functions draws for the reader, such as a system map, at the size and theme the client asks, refreshed on a timer; a client that draws no images shows its alt text, or nothing.
|
|
28
29
|
- [Chart block](../reference/blocks.md#chart): Counts, sums or averages by value or by date, as bars, lines or a donut, and over time split by a second field.
|
|
29
30
|
- [Conversations](../reference/blocks.md#conversation): A chat declared in the layout: a thread of a resource's messages under each sender's name and time, following new ones as they arrive, and a box that sends one as the signed-in user.
|
|
@@ -441,6 +441,29 @@ A bar for `value` out of `max`, with both numbers. It turns amber from 90%.
|
|
|
441
441
|
<Progress label="Seats" value="seats_used" max="plan.seats" />
|
|
442
442
|
```
|
|
443
443
|
|
|
444
|
+
### Diff
|
|
445
|
+
|
|
446
|
+
:::caution[Beta]
|
|
447
|
+
`Diff` may still change.
|
|
448
|
+
:::
|
|
449
|
+
|
|
450
|
+
A unified patch the record holds in a text field, as `diff -u` and `git diff` write it: each file under its name with the counts of added and removed lines, then its changes, numbered by the patch's `@@` lines. From the `md` breakpoint (768px) up, the old lines stand on the left and the new ones beside them; below it, both run in one column. Text that is not a unified patch shows as it is, in a code font, and text before the first file, such as a mailed patch's message, is left out.
|
|
451
|
+
|
|
452
|
+
| Prop | |
|
|
453
|
+
| --- | --- |
|
|
454
|
+
| `source` | The text field holding the patch, a [path](layouts.md#paths-and-scopes) as a [field component](#field-components)'s `source` is. Required. |
|
|
455
|
+
| `emptyText` | Shown when the field is empty; nothing is shown without it. |
|
|
456
|
+
|
|
457
|
+
```tsx
|
|
458
|
+
<RecordCard resource="changes" recordKey="42" title="Proposed change">
|
|
459
|
+
<Diff source="patch" emptyText="No changes yet" />
|
|
460
|
+
</RecordCard>
|
|
461
|
+
```
|
|
462
|
+
|
|
463
|
+
In the [text form](layouts.md#text-form) it reads as the patch in a fenced `diff` code block, its fence longer than any run of backticks the patch holds, so a patch of a Markdown file cannot end it early.
|
|
464
|
+
|
|
465
|
+
<gap>A Diff block cannot compare two versions of a field because computing a diff is not implemented; it shows a patch the record already holds.</gap>
|
|
466
|
+
|
|
444
467
|
### Image
|
|
445
468
|
|
|
446
469
|
A fixed picture at `src`, or one an [API function](../guides/api-functions.md) draws.
|
|
@@ -71,11 +71,11 @@ renderText(<Page title="Order"><Field source="status" /></Page>, {
|
|
|
71
71
|
|
|
72
72
|
| Option | |
|
|
73
73
|
| --- | --- |
|
|
74
|
-
| `record` | The record around the tree. `Field`, the [field components](#field-values), `Stat field`, `Progress`, `Show` conditions and the `{{field}}`s of addresses read it, through relations as nested objects (`plan.name`); a count a condition names, such as `billing_profiles.count`, is a key of its own. The `{{path}}`s of props read it too. Without it, a field reads as its label alone, a condition as holding (a `Show` reads as its children, a `Switch` as its first `Match`), a prop's `{{path}}`s as empty, and addresses keep their `{{field}}`s. |
|
|
74
|
+
| `record` | The record around the tree. `Field`, the [field components](#field-values), `Diff`, `Stat field`, `Progress`, `Show` conditions and the `{{field}}`s of addresses read it, through relations as nested objects (`plan.name`); a count a condition names, such as `billing_profiles.count`, is a key of its own. The `{{path}}`s of props read it too. Without it, a field reads as its label alone, a condition as holding (a `Show` reads as its children, a `Switch` as its first `Match`), a prop's `{{path}}`s as empty, and addresses keep their `{{field}}`s. |
|
|
75
75
|
| `fields` | Per field path, its `label` and the `valueLabels` its enum values read as; a field without a label reads under its path. |
|
|
76
|
-
| `records` | Per `ReferenceManyField`, `ReferenceArrayField` or `ReferenceField` element and the record around it, the records it holds, which you loaded; its `RecordsIterator` then reads as its children once per record, in that record, and an empty list as its `empty`. Without it, the block reads as a link to its records. An `ArrayField` reads its items from the record around it. For a `Table` with `select`, the row chosen, whose record its children read; without it they read as nothing. |
|
|
76
|
+
| `records` | Per `ReferenceManyField`, `ReferenceArrayField` or `ReferenceField` element and the record around it, the records it holds, which you loaded; its `RecordsIterator` then reads as its children once per record, in that record, and an empty list as its `empty`. Without it, the block reads as a link to its records. An `ArrayField` reads its items from the record around it. For a `RecordCard`, its record, which its children read; for a `CardRow`, its records, its children once per record. For a `Table` with `select`, the row chosen, whose record its children read; without it they read as nothing. It gets the element, the record around it and the element's place in the tree, the pointer the [read plan](#how-a-page-reads-its-data) names its block by. |
|
|
77
77
|
| `params` | The [page parameters](#page-parameters) the page's address holds, such as `{ window: '30d' }`, which `@params` and the `SelectInput`s read, each held to its choices. |
|
|
78
|
-
| `tables` | Per `Table` element, the records it shows and its columns (`{ columns: [{ name, label, title?, badge?, valueLabels? }], rows }`), which you loaded; the table then reads as its heading and a Markdown table. Without it, a table reads as its heading. |
|
|
78
|
+
| `tables` | Per `Table` element, its place in the tree, the record around it and the records of the list around it (which a table without `resource` shows), the records it shows and its columns (`{ columns: [{ name, label, title?, badge?, valueLabels? }], rows }`), which you loaded; the table then reads as its heading and a Markdown table. Without it, a table reads as its heading. |
|
|
79
79
|
| `locale` | The reader's locale, such as `nl-NL`, in which [field components](#field-values) without `locales` format numbers and dates; the runtime's default when omitted. |
|
|
80
80
|
| `basePath` | What links start with, such as `https://example.com/admin`. |
|
|
81
81
|
| `forms` | Text forms by block type, over the built-in ones. |
|
|
@@ -95,7 +95,23 @@ renderText(tree, { forms: { Grid: ruled, Card: noted, SeatChart: childrenText }
|
|
|
95
95
|
|
|
96
96
|
A custom component reads as its [fallback](custom-components.md#fallbacks) when it declares one, and otherwise as what it holds, unless `forms` names it.
|
|
97
97
|
|
|
98
|
-
|
|
98
|
+
### A page's text with its records
|
|
99
|
+
|
|
100
|
+
`pageText` reads a page's records itself: it starts every read of the page's [read plan](#how-a-page-reads-its-data) at once through the `read` you give it, which makes one read as the reader, such as a list or an `:aggregate` of the API, and once they are all back renders the text form with them. A `RecordCard` reads as its record, its header `actions` too, a `CardRow` as its records, a `Table` as a Markdown table of its rows, one without `resource` of the list around it, and a related list as its records, each nested list under its own record. The record you pass as `record` is the page's own, whose key fills `{{@root.…}}`. A read that fails leaves its block as it reads without records, a link to them.
|
|
101
|
+
|
|
102
|
+
```ts
|
|
103
|
+
import { pageText } from '@protobase/layout'
|
|
104
|
+
|
|
105
|
+
const text = await pageText(page.tree, page.reads, {
|
|
106
|
+
read: async (read) => ({ rows: (await client.list(read.resource, { filter: read.filter, orderBy: read.orderBy, pageSize: read.pageSize, fields: read.fields, limitPer: read.limitPer })).items }),
|
|
107
|
+
labels: { workers: { name: { label: 'Name' } } },
|
|
108
|
+
params: { window: '30d' },
|
|
109
|
+
})
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
It takes the options of `renderText` but `records` and `tables`, and `labels`: per resource, its fields' labels and value labels, which its tables' headers and cells read. A count's `read` gives `{ rows: [], total }`, and a count per record around it, an `:aggregate`, its groups as rows `{ value, count }`.
|
|
113
|
+
|
|
114
|
+
<gap>A `Stat` count, a `Chart`, a `RecordCards`, a `RecordRow` or a `Thread` cannot read its records in `pageText` because their text forms for planned records are not implemented.</gap> <gap>A path in the text form cannot read a record further out than the nearest, such as `../id`, because a stack of records in the text form is not implemented.</gap> A `Thread` holding the elements of [`threadItemNodes`](blocks.md#tool-calls) reads as its messages and calls. <gap>A data block other than a `Table`, a `RecordCard`, a `CardRow`, a `Thread` or a list block cannot list records you pass because its text form for records is not implemented.</gap> <gap>A field's text form cannot apply its `format`, such as a relative time, because formatting in the text form is not implemented.</gap> <gap>MCP clients cannot read a page's text form because a tool that serves it is not implemented.</gap>
|
|
99
115
|
|
|
100
116
|
## What a layout may hold
|
|
101
117
|
|
|
@@ -110,12 +126,12 @@ Behaviour comes from [named actions](#named-actions); React code from [custom co
|
|
|
110
126
|
|
|
111
127
|
`Stat`, `RecordCard`, `Table`, `CardRow`, `RecordRow`, `RecordCards` and `Thread` read records of a `resource`. `filter` is AIP-160 and `sort` AIP-132, exactly as the list API's `filter` and `order_by`, so a filter that works in the list's URL works here. `Thread` takes no `sort`: it orders its messages by its `time` field, newest first. `ReferenceManyField`, `ReferenceArrayField` and `ReferenceField` read records of their `reference` that the record around them points to or is pointed at by: see [related records](#related-records).
|
|
112
128
|
|
|
113
|
-
A `RecordCard` (its first match), a `ReferenceField`, each card of a `CardRow` and each entry of a `RecordsIterator` hold a **record**. Inside one, `Field`, `Progress`, `Stat field`, `Show`, `Action` and `ModalForm mode="edit"` work on that record, and a `RecordCard`'s header `actions` do too. A field name may follow relations: `company_id.city` is the city of the record's company, fetched like the record page fetches it and cached.
|
|
129
|
+
A `RecordCard` (its first match), a `ReferenceField`, each card of a `CardRow` and each entry of a `RecordsIterator` hold a **record**. Inside one, `Field`, `Diff`, `Progress`, `Stat field`, `Show`, `Action` and `ModalForm mode="edit"` work on that record, and a `RecordCard`'s header `actions` do too. A field name may follow relations: `company_id.city` is the city of the record's company, fetched like the record page fetches it and cached.
|
|
114
130
|
|
|
115
131
|
## Related records
|
|
116
132
|
|
|
117
133
|
:::caution[Beta]
|
|
118
|
-
|
|
134
|
+
A list's next pages, with `pagination="more"`, are a read of the list's own. A `Table` inside a list's records still reads once it draws, as [how a page reads its data](#how-a-page-reads-its-data) says.
|
|
119
135
|
:::
|
|
120
136
|
|
|
121
137
|
A record's related records repeat under it as a list: a `ReferenceManyField` holds the records of another resource that point at it, a `ReferenceArrayField` the records whose keys a JSON field of it lists, and an `ArrayField` the items of a JSON list it holds. A `RecordsIterator` inside one draws its children once for each entry, with nothing around them, and a `Table` without `resource` draws the list as a table. A `ReferenceField` draws the one record a field points at. They take the names, props and defaults of the [react-admin](../features/compatibility.md#react-admin) components of the same names.
|
|
@@ -143,10 +159,10 @@ Each entry is a record of the stack while its children draw, so `Field`, `Show`,
|
|
|
143
159
|
## How a page reads its data
|
|
144
160
|
|
|
145
161
|
:::caution[Beta]
|
|
146
|
-
|
|
162
|
+
On the web, a `Table`, `Thread`, `Chart`, `RecordCards` and `RecordRow` still read once they draw, as the marked limits below say.
|
|
147
163
|
:::
|
|
148
164
|
|
|
149
|
-
The build compiles each page into a read plan: one ordinary API read per data block, each known before any record is read, so all of them
|
|
165
|
+
The build compiles each page into a read plan: one ordinary API read per data block, each known before any record is read, so all of them start together when the page opens and none waits for another's rows. There is no combined page query: each read is a request of its own. `/api/meta` sends each user the plan of the page as they see it, so it holds no read of a resource they cannot read and no field they cannot read.
|
|
150
166
|
|
|
151
167
|
- **One read per block.** `Stat`, `RecordCard`, `Table`, `CardRow`, `RecordRow`, `RecordCards`, `Thread`, `Chart`, `ReferenceManyField`, `ReferenceArrayField` and `ReferenceField` each make one list, count or `:aggregate` read. A `Thread`'s tool calls, the row a `Table`'s `select` chose and each `<resource>.count` a condition names are reads of their own. A block under `Show` or `Match` is read anyway: the condition decides only what is drawn.
|
|
152
168
|
- **Fields are derived.** You never write `fields`. Each read asks for its key and every field drawn in its scope: by `Field`s, [field components](#field-values), `{{path}}`s, conditions and table columns, and the fields a nested list ties itself by. A block whose view decides what it draws, such as a `Table` without `columns` or a `RecordRow`, reads every field. So does a read whose records an `Action` or an edit form changes, since it asks for each record's ETag and an ETag covers the whole record. The other reads ask for no ETag.
|
|
@@ -155,11 +171,13 @@ The build compiles each page into a read plan: one ordinary API read per data bl
|
|
|
155
171
|
- **The page's own record.** A field of it that the address does not hold, `{{@root.project_id}}`, becomes `related()` on that record by its key, so the page's record is not read first. Page parameters and the page record's key stay `{{…}}` slots in the plan, which the address fills.
|
|
156
172
|
- **Indexes.** [`protobase doctor`](cli.md#doctor) judges every planned read with the scan guard's rule, the outer reads its `related()` terms carry included, so it reports a nested read's missing index before the API refuses the read.
|
|
157
173
|
|
|
158
|
-
|
|
174
|
+
When a page opens, the web starts every read of its plan at once, with the page's parameters filled in, whatever a condition says and however deep a block sits. A `RecordCard`, `CardRow`, `Stat`, `ReferenceManyField`, `ReferenceArrayField` and `ReferenceField` then draw from their read and read nothing themselves; one inside the records of another takes the rows of its own record out of its read, by the field it ties itself by. Inside a record the plan did not read, such as one of a list's later pages, it reads its rows itself. A `Show` or `Match` decides only what is drawn: switching what it shows starts no new read. A change to a resource, live or the page's own, reads again exactly the reads of that resource, and a nested read also when the records around it change.
|
|
175
|
+
|
|
176
|
+
Each read in the plan (`page.reads.reads`) names its block by a JSON Pointer into the page's tree, such as `/children/0/children/2`, which `elementAt(tree, pointer)` finds. It gives the read's `resource`, its `kind` (`list`, `count` or `aggregate`), `filter`, `orderBy`, `pageSize`, `limitPer`, `groupBy`, `fields` (absent for every field), `etag`, and for a read inside the records of another its `split`: the `field` its rows hold the value `source`, a path, reads where the block draws, and the `parent` read, by `planReadId(read)`. `compileReadPlan(tree, { models })` makes the same plan from a tree of your own. `runReadPlan(plan, read, { params })` starts every read at once through `read` and gives each outcome by `planReadId`, and `plannedRows(read, rows, scope)` the rows of one record around a block.
|
|
159
177
|
|
|
160
178
|
A [custom component](custom-components.md#reads) is planned when it declares its reads. One that declares none is outside the plan (`page.reads.outside`): whatever it reads, it reads by itself once it draws, and `protobase doctor` lists it.
|
|
161
179
|
|
|
162
|
-
<gap>A
|
|
180
|
+
<gap>A `Table`, `Thread`, `Chart`, `RecordCards` or `RecordRow` cannot start its read when the page opens because drawing those blocks from their planned read is not implemented; each still reads once it draws, under a `Show` or `Match` once its condition holds.</gap> <gap>A read without an ETag cannot read only its fields from the database because skipping ETags in the list API is not implemented; it still sends only its fields.</gap> <gap>A `Chart` cannot sit inside a repeated record because grouping a chart per record is not implemented.</gap>
|
|
163
181
|
|
|
164
182
|
## Field values
|
|
165
183
|
|
|
@@ -205,7 +223,7 @@ In the [text form](#text-form) each one reads as its formatted value, a `UrlFiel
|
|
|
205
223
|
## Paths and scopes
|
|
206
224
|
|
|
207
225
|
:::caution[Beta]
|
|
208
|
-
A path cannot read `@root` yet,
|
|
226
|
+
A path cannot read `@root` yet, as the marked limit below says.
|
|
209
227
|
:::
|
|
210
228
|
|
|
211
229
|
A `RecordCard`, a `ReferenceField`, each card of a `CardRow` and each entry of a [`RecordsIterator`](#related-records) put their record on a stack of records: an element inside both a task's `RecordCard` and a `CardRow` of its claims sits in a claim, inside the task. A bare name is looked up in the innermost record, then in each record further out, then in the page's own record; the [compatibility page](../features/compatibility.md#template-paths) says which template syntax this follows:
|
|
@@ -220,7 +238,7 @@ A `RecordCard`, a `ReferenceField`, each card of a `CardRow` and each entry of a
|
|
|
220
238
|
| `@root.id` | The page's own record. <gap>A path cannot read `@root` because pages with a record of their own are not implemented.</gap> |
|
|
221
239
|
| `@params.window` | The [page parameter](#page-parameters) `window`, which a `SelectInput source="window"` on the page sets. |
|
|
222
240
|
|
|
223
|
-
`Field source`, a field component's `source`, `Stat field`, `Progress`, and the names in a [condition](#conditions) take a path. A string prop takes `{{path}}` placeholders in double braces, filled with the path's value where the element draws, and empty when it has none:
|
|
241
|
+
`Field source`, a field component's `source`, `Diff source`, `Stat field`, `Progress`, and the names in a [condition](#conditions) take a path. A string prop takes `{{path}}` placeholders in double braces, filled with the path's value where the element draws, and empty when it has none:
|
|
224
242
|
|
|
225
243
|
- `title`, `description`, `empty`, `label`, and a field component's `emptyText`, `content`, `valueLabelTrue` and `valueLabelFalse` read any path: `<Table resource="claim_steps" title="Steps of {{title}}" />`.
|
|
226
244
|
- `filter`, `recordKey` and `values` read a field of a record around them. A filter takes one only as a top-level `AND` equality, `claim_id = {{id}} AND done = false`, the shape a read can take for every row at once with a [`related()`](api.md#filtering-through-related-records) filter. A filter takes a page parameter anywhere.
|
|
@@ -236,8 +254,6 @@ The build checks every path where it sits:
|
|
|
236
254
|
- **Reads that would wait.** A per-row value in a filter in any other place than a top-level `AND` equality (with `>=`, inside `OR` or `NOT`, a second one), `@index`, `@first`, `@last` or `this` in a filter, key or values, and any placeholder in `resource`, `sort`, `columns` or `limit` fail with "this would wait for the parent's rows": each block's records are one read of their own, and none may wait for another's rows.
|
|
237
255
|
- **Shadowing.** A bare name that more than one record around it has reads the nearest, and the build warns which it read and how to write the others: `"id" resolves to task_claims; write ../id for the one of tasks`. `protobase build --strict` fails on it instead. `this.`, `./`, `../` and `@` paths never warn.
|
|
238
256
|
|
|
239
|
-
<gap>A block inside a `CardRow` or `RecordCard` cannot read its records at page load, beside the records around it, because running the [read plan](#how-a-page-reads-its-data) on the web is not implemented; it reads once the card around it draws.</gap> <gap>A block under a `Show` or `Match` cannot read its records before its condition holds because running the read plan on the web is not implemented.</gap>
|
|
240
|
-
|
|
241
257
|
## Page parameters
|
|
242
258
|
|
|
243
259
|
:::caution[Beta]
|
|
@@ -262,7 +278,7 @@ A `Table` with `select` chooses one of its rows: each row links to the page with
|
|
|
262
278
|
|
|
263
279
|
In the [text form](#text-form), a `SelectInput` reads as its label and its choice's name, `**Window**: Last 30 days`, from the `params` you pass, and a `select` table's children as the row `records` gives for it.
|
|
264
280
|
|
|
265
|
-
<gap>A
|
|
281
|
+
<gap>A data block other than a `Table`, or a list display such as a map, cannot take `select` because choosing a row there is not implemented.</gap>
|
|
266
282
|
|
|
267
283
|
## Conditions
|
|
268
284
|
|
|
@@ -362,7 +378,7 @@ Every block reads the regular API with the user's token, so the access rules app
|
|
|
362
378
|
|
|
363
379
|
- a page whose `roles` leave the user out is not sent;
|
|
364
380
|
- an element whose resource they cannot see, or whose filter or sort names a field they cannot read, is left out with everything inside it, and so is a `Tab` left with nothing in it;
|
|
365
|
-
- `Field`, `Progress` and `Stat field` on a field they cannot read are left out, and table columns are narrowed;
|
|
381
|
+
- `Field`, `Diff`, `Progress` and `Stat field` on a field they cannot read are left out, and table columns are narrowed;
|
|
366
382
|
- `ModalForm` needs create or update permission and keeps only the fields they may write;
|
|
367
383
|
- an `Action` missing from their view of the resource is left out, and so is a `Show` that names something they cannot see.
|
|
368
384
|
- an `Image` whose function they may not call is left out; a fixed one (`src`) is kept.
|