@simai-studio/view 1.1.0 → 1.3.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/README.md +5 -5
- package/dist/package-receipt.json +322 -81
- package/dist/set.json +35 -2
- package/dist/smart/rule.js +94 -0
- package/dist/smart/rule.js.gz +0 -0
- package/dist/smart/view/component.json +1 -1
- package/dist/smart/view/component.json.gz +0 -0
- package/dist/smart/view/js/view.js +1 -1
- package/dist/smart/view/js/view.js.gz +0 -0
- package/dist/smart/view/js/view.min.js +1 -1
- package/dist/smart/view/js/view.min.js.gz +0 -0
- package/dist/smart/view/smart.manifest.json +1 -1
- package/dist/smart/view/smart.manifest.json.gz +0 -0
- package/dist/smart/view/static/default/open-record.html +1 -1
- package/dist/smart/view/static/default/open-record.html.gz +0 -0
- package/dist/smart/view/static/default/reference.html +1 -1
- package/dist/smart/view/static/default/reference.html.gz +0 -0
- package/dist/smart/view-flow/component.json +620 -0
- package/dist/smart/view-flow/component.json.gz +0 -0
- package/dist/smart/view-flow/css/view-flow.css +570 -0
- package/dist/smart/view-flow/css/view-flow.css.gz +0 -0
- package/dist/smart/view-flow/css/view-flow.min.css +3 -0
- package/dist/smart/view-flow/css/view-flow.min.css.gz +0 -0
- package/dist/smart/view-flow/examples.json +452 -0
- package/dist/smart/view-flow/examples.json.gz +0 -0
- package/dist/smart/view-flow/js/view-flow.js +7406 -0
- package/dist/smart/view-flow/js/view-flow.js.gz +0 -0
- package/dist/smart/view-flow/js/view-flow.min.js +749 -0
- package/dist/smart/view-flow/js/view-flow.min.js.gz +0 -0
- package/dist/smart/view-flow/lang/en.json +24 -0
- package/dist/smart/view-flow/lang/en.json.gz +0 -0
- package/dist/smart/view-flow/lang/ru.json +24 -0
- package/dist/smart/view-flow/lang/ru.json.gz +0 -0
- package/dist/smart/view-flow/probe.json +149 -0
- package/dist/smart/view-flow/probe.json.gz +0 -0
- package/dist/smart/view-flow/smart.manifest.json +486 -0
- package/dist/smart/view-flow/smart.manifest.json.gz +0 -0
- package/dist/smart/view-flow/static/default/answered.html +57 -0
- package/dist/smart/view-flow/static/default/answered.html.gz +0 -0
- package/dist/smart/view-flow/static/default/ask.html +146 -0
- package/dist/smart/view-flow/static/default/ask.html.gz +0 -0
- package/dist/smart/view-flow/static/default/expired.html +16 -0
- package/dist/smart/view-flow/static/default/expired.html.gz +0 -0
- package/dist/smart/view-flow/static/default/groups.html +44 -0
- package/dist/smart/view-flow/static/default/groups.html.gz +0 -0
- package/dist/smart/view-flow/static/default/reference.html +72 -0
- package/dist/smart/view-flow/static/default/reference.html.gz +0 -0
- package/dist/smart/view-flow/static/default/untitled.html +41 -0
- package/dist/smart/view-flow/static/default/untitled.html.gz +0 -0
- package/dist/smart/view-flow/static/sheets.json +443 -0
- package/dist/smart/view-flow/static/sheets.json.gz +0 -0
- package/dist/smart/view-flow/template/default.css +180 -0
- package/dist/smart/view-flow/template/default.css.gz +0 -0
- package/dist/smart/view-flow/template/default.js +136 -0
- package/dist/smart/view-flow/template/default.js.gz +0 -0
- package/dist/smart/view-properties/component.json +8 -1
- package/dist/smart/view-properties/component.json.gz +0 -0
- package/dist/smart/view-properties/css/view-properties.css +367 -0
- package/dist/smart/view-properties/css/view-properties.css.gz +0 -0
- package/dist/smart/view-properties/css/view-properties.min.css +1 -0
- package/dist/smart/view-properties/css/view-properties.min.css.gz +0 -0
- package/dist/smart/view-properties/js/view-properties.js +1755 -169
- package/dist/smart/view-properties/js/view-properties.js.gz +0 -0
- package/dist/smart/view-properties/js/view-properties.min.js +491 -378
- package/dist/smart/view-properties/js/view-properties.min.js.gz +0 -0
- package/dist/smart/view-properties/smart.manifest.json +38 -3
- package/dist/smart/view-properties/smart.manifest.json.gz +0 -0
- package/dist/smart/view-properties/template/default.js +1 -77
- package/dist/smart/view-properties/template/default.js.gz +0 -0
- package/dist/smart/view-table/js/view-table.js +2 -0
- package/dist/smart/view-table/js/view-table.js.gz +0 -0
- package/dist/smart/view-table/js/view-table.min.js +2 -0
- package/dist/smart/view-table/js/view-table.min.js.gz +0 -0
- package/package.json +1 -1
|
@@ -0,0 +1,486 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema_version": 2,
|
|
3
|
+
"id": "smart.view-flow",
|
|
4
|
+
"version": "1.1.0",
|
|
5
|
+
"title": "Flow block",
|
|
6
|
+
"summary": "A few properties as a block in a flow (a chat message, a feed, any stream): shows a record's fields, or asks for a few and sends them, then keeps the answer read-only. Fields are sf-view-properties' descriptors drawn by the Framework field renderers; a press is an event, the host answers with settle.",
|
|
7
|
+
"kind": "smart",
|
|
8
|
+
"reuse_mode": "whole",
|
|
9
|
+
"lifecycle": "experimental",
|
|
10
|
+
"tags": [
|
|
11
|
+
"record",
|
|
12
|
+
"properties",
|
|
13
|
+
"form",
|
|
14
|
+
"chat",
|
|
15
|
+
"feed"
|
|
16
|
+
],
|
|
17
|
+
"capabilities": [
|
|
18
|
+
"field-renderers",
|
|
19
|
+
"confirmation",
|
|
20
|
+
"expiry",
|
|
21
|
+
"live-announcement"
|
|
22
|
+
],
|
|
23
|
+
"custom_element": "sf-view-flow",
|
|
24
|
+
"templates": [
|
|
25
|
+
"default"
|
|
26
|
+
],
|
|
27
|
+
"exported_parts": [],
|
|
28
|
+
"composition": {
|
|
29
|
+
"uses": [
|
|
30
|
+
"component.icons",
|
|
31
|
+
"smart.avatar",
|
|
32
|
+
"smart.badge",
|
|
33
|
+
"smart.button",
|
|
34
|
+
"smart.button-group",
|
|
35
|
+
"smart.button-icon",
|
|
36
|
+
"smart.checkbox",
|
|
37
|
+
"smart.dropdown",
|
|
38
|
+
"smart.file-preview",
|
|
39
|
+
"smart.help-mark",
|
|
40
|
+
"smart.icon",
|
|
41
|
+
"smart.input",
|
|
42
|
+
"smart.input-color",
|
|
43
|
+
"smart.input-country",
|
|
44
|
+
"smart.input-date",
|
|
45
|
+
"smart.input-image",
|
|
46
|
+
"smart.input-quantity",
|
|
47
|
+
"smart.input-rich",
|
|
48
|
+
"smart.input-textarea",
|
|
49
|
+
"smart.list-item",
|
|
50
|
+
"smart.progress-scale",
|
|
51
|
+
"smart.reference-link",
|
|
52
|
+
"smart.slider-range",
|
|
53
|
+
"smart.spinner",
|
|
54
|
+
"smart.switch",
|
|
55
|
+
"smart.tag"
|
|
56
|
+
],
|
|
57
|
+
"public_parts": []
|
|
58
|
+
},
|
|
59
|
+
"inputs": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {
|
|
62
|
+
"template": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"default": "default",
|
|
65
|
+
"description": "Template variant name for SfBaseElement external templates.",
|
|
66
|
+
"const": "default"
|
|
67
|
+
},
|
|
68
|
+
"root-class": {
|
|
69
|
+
"type": "string",
|
|
70
|
+
"default": "",
|
|
71
|
+
"description": "Classes added to the root element the component draws."
|
|
72
|
+
},
|
|
73
|
+
"root-style": {
|
|
74
|
+
"type": "string",
|
|
75
|
+
"default": "",
|
|
76
|
+
"description": "Inline style declarations set on the root element the component draws, custom properties included."
|
|
77
|
+
},
|
|
78
|
+
"mode": {
|
|
79
|
+
"type": "string",
|
|
80
|
+
"default": "view",
|
|
81
|
+
"description": "view: the fields shown, read-only, with no foot. edit: the fields as controls and the answers at the foot (Send, Cancel); after the answer they are shown again, read-only.",
|
|
82
|
+
"enum": [
|
|
83
|
+
"view",
|
|
84
|
+
"edit"
|
|
85
|
+
]
|
|
86
|
+
},
|
|
87
|
+
"heading": {
|
|
88
|
+
"type": "string",
|
|
89
|
+
"default": "",
|
|
90
|
+
"description": "The header line; also the block's accessible name. Without one the block is named «Properties»."
|
|
91
|
+
},
|
|
92
|
+
"heading-level": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"default": "3",
|
|
95
|
+
"description": "The heading's level where the block is placed.",
|
|
96
|
+
"enum": [
|
|
97
|
+
"2",
|
|
98
|
+
"3",
|
|
99
|
+
"4",
|
|
100
|
+
"5",
|
|
101
|
+
"6"
|
|
102
|
+
]
|
|
103
|
+
},
|
|
104
|
+
"state": {
|
|
105
|
+
"type": "string",
|
|
106
|
+
"default": "open",
|
|
107
|
+
"description": "Where the answer is (edit mode). open: the controls and the answers. pending: an answer is on its way (set by a press). accepted: the values sent, read-only. declined, expired: only the outcome.",
|
|
108
|
+
"enum": [
|
|
109
|
+
"open",
|
|
110
|
+
"pending",
|
|
111
|
+
"accepted",
|
|
112
|
+
"declined",
|
|
113
|
+
"expired"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
"expires-at": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"default": "",
|
|
119
|
+
"description": "ISO 8601. Past it an open block reads as expired and says so once with sf-view-flow-expired."
|
|
120
|
+
},
|
|
121
|
+
"block-id": {
|
|
122
|
+
"type": "string",
|
|
123
|
+
"default": "",
|
|
124
|
+
"description": "The host's name for the block, carried back in every event."
|
|
125
|
+
},
|
|
126
|
+
"disabled": {
|
|
127
|
+
"type": "boolean",
|
|
128
|
+
"default": false,
|
|
129
|
+
"description": "The controls and the answers are shown and cannot be used (an answer is on its way elsewhere in the flow)."
|
|
130
|
+
},
|
|
131
|
+
"size": {
|
|
132
|
+
"type": "string",
|
|
133
|
+
"default": "1/2",
|
|
134
|
+
"description": "The block's size: its text, labels and controls. 1/2 sits in a message.",
|
|
135
|
+
"enum": [
|
|
136
|
+
"1",
|
|
137
|
+
"1/2"
|
|
138
|
+
]
|
|
139
|
+
},
|
|
140
|
+
"cancelable": {
|
|
141
|
+
"type": "boolean",
|
|
142
|
+
"default": true,
|
|
143
|
+
"description": "Whether Cancel is offered beside Send."
|
|
144
|
+
},
|
|
145
|
+
"submit-text": {
|
|
146
|
+
"type": "string",
|
|
147
|
+
"description": "The sending answer; empty is Send in the page's language."
|
|
148
|
+
},
|
|
149
|
+
"cancel-text": {
|
|
150
|
+
"type": "string",
|
|
151
|
+
"description": "The cancelling answer; empty is Cancel in the page's language."
|
|
152
|
+
},
|
|
153
|
+
"empty-text": {
|
|
154
|
+
"type": "string",
|
|
155
|
+
"description": "What an empty value reads as."
|
|
156
|
+
},
|
|
157
|
+
"required-text": {
|
|
158
|
+
"type": "string",
|
|
159
|
+
"description": "Said under a required field left empty when Send is pressed."
|
|
160
|
+
},
|
|
161
|
+
"invalid-text": {
|
|
162
|
+
"type": "string",
|
|
163
|
+
"description": "The status line when Send was stopped by the fields."
|
|
164
|
+
},
|
|
165
|
+
"fields": {
|
|
166
|
+
"type": "array",
|
|
167
|
+
"default": [],
|
|
168
|
+
"description": "The field descriptors, sf-view-properties' shape (key, label, propertyType, value, required, readonly, width, hint, options, when ...). JSON in markup; a property set from script wins."
|
|
169
|
+
},
|
|
170
|
+
"groups": {
|
|
171
|
+
"type": "array",
|
|
172
|
+
"default": [],
|
|
173
|
+
"description": "Named groups of field descriptors, each optionally collapsible (collapsible, collapsed). Wins over fields when both are given."
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
"additionalProperties": false
|
|
177
|
+
},
|
|
178
|
+
"item_contract": {},
|
|
179
|
+
"contracts": {
|
|
180
|
+
"field": {
|
|
181
|
+
"const": "The field descriptor of simai.property-view-port (sf-view-properties): key, label, propertyType, value, required, readonly, width (half|full), hint, placeholder, options, min, max, step, unit, variant, multiple, mask, when."
|
|
182
|
+
},
|
|
183
|
+
"answers": {
|
|
184
|
+
"const": "Send checks the required fields and the controls' own entries, moves the block to pending and dispatches sf-view-flow-answer {id, accepted: true, values} (cancelable; a cancelled event reopens it). Cancel dispatches {id, accepted: false}. The host answers with settle({answer: applied|refused, errors, message, values}) or sets state."
|
|
185
|
+
},
|
|
186
|
+
"slots": {
|
|
187
|
+
"type": "object",
|
|
188
|
+
"properties": {
|
|
189
|
+
"description": {
|
|
190
|
+
"type": "string",
|
|
191
|
+
"description": "A line under the heading."
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
"methods": {
|
|
197
|
+
"open": {
|
|
198
|
+
"summary": "Puts the question again (state open); asked by an assembly it answers {accepted, reason, value} when the person answers or the time runs out.",
|
|
199
|
+
"arguments": [],
|
|
200
|
+
"returns": {
|
|
201
|
+
"type": "object",
|
|
202
|
+
"description": "{outcome: applied} or {outcome: refused, reason}"
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
"answer": {
|
|
206
|
+
"summary": "Answer as the person would: accepted true sends (after the block's own check of the fields), false cancels. Refused invalid, closed, disabled or prevented.",
|
|
207
|
+
"arguments": [
|
|
208
|
+
{
|
|
209
|
+
"name": "accepted",
|
|
210
|
+
"schema": {
|
|
211
|
+
"type": "boolean"
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
],
|
|
215
|
+
"returns": {
|
|
216
|
+
"type": "object",
|
|
217
|
+
"description": "{outcome: applied} or {outcome: refused, reason}"
|
|
218
|
+
}
|
|
219
|
+
},
|
|
220
|
+
"confirm": {
|
|
221
|
+
"summary": "Send; data-sf-action=\"<id>.confirm\".",
|
|
222
|
+
"arguments": [],
|
|
223
|
+
"returns": {
|
|
224
|
+
"type": "object",
|
|
225
|
+
"description": "{outcome: applied} or {outcome: refused, reason}"
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
"cancel": {
|
|
229
|
+
"summary": "Cancel; data-sf-action=\"<id>.cancel\".",
|
|
230
|
+
"arguments": [],
|
|
231
|
+
"returns": {
|
|
232
|
+
"type": "object",
|
|
233
|
+
"description": "{outcome: applied} or {outcome: refused, reason}"
|
|
234
|
+
}
|
|
235
|
+
},
|
|
236
|
+
"settle": {
|
|
237
|
+
"summary": "The host's answer to an answer, in the record port's words: {answer: applied, values?} shows the values sent, read-only; {answer: refused, errors?, message?} reopens the block with each error under its field; reason closed or expired closes it.",
|
|
238
|
+
"arguments": [
|
|
239
|
+
{
|
|
240
|
+
"name": "result",
|
|
241
|
+
"schema": {
|
|
242
|
+
"type": "object"
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
],
|
|
246
|
+
"returns": {
|
|
247
|
+
"type": "object",
|
|
248
|
+
"description": "{outcome: applied} or {outcome: refused, reason}"
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
"events": {
|
|
253
|
+
"sf-view-flow-answer": {
|
|
254
|
+
"summary": "The person answered (vocabulary answer): Send with the values, or Cancel. Cancel the event to keep the block open.",
|
|
255
|
+
"payload": {
|
|
256
|
+
"type": "object",
|
|
257
|
+
"required": [
|
|
258
|
+
"id",
|
|
259
|
+
"accepted"
|
|
260
|
+
],
|
|
261
|
+
"properties": {
|
|
262
|
+
"id": {
|
|
263
|
+
"description": "block-id"
|
|
264
|
+
},
|
|
265
|
+
"accepted": {
|
|
266
|
+
"type": "boolean"
|
|
267
|
+
},
|
|
268
|
+
"values": {
|
|
269
|
+
"type": "object",
|
|
270
|
+
"description": "With accepted true: every shown, editable field's value by key."
|
|
271
|
+
}
|
|
272
|
+
},
|
|
273
|
+
"additionalProperties": true
|
|
274
|
+
}
|
|
275
|
+
},
|
|
276
|
+
"sf-view-flow-expired": {
|
|
277
|
+
"summary": "An open block passed expires-at; said once per time.",
|
|
278
|
+
"payload": {
|
|
279
|
+
"type": "object",
|
|
280
|
+
"required": [
|
|
281
|
+
"id"
|
|
282
|
+
],
|
|
283
|
+
"properties": {
|
|
284
|
+
"id": {
|
|
285
|
+
"description": "block-id"
|
|
286
|
+
}
|
|
287
|
+
},
|
|
288
|
+
"additionalProperties": true
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
"sf-view-flow-open": {
|
|
292
|
+
"summary": "A reference value (a record, a user) was pressed, vocabulary open: {id, field, value}. Following it is the host's.",
|
|
293
|
+
"payload": {
|
|
294
|
+
"type": "object",
|
|
295
|
+
"required": [
|
|
296
|
+
"id",
|
|
297
|
+
"field",
|
|
298
|
+
"value"
|
|
299
|
+
],
|
|
300
|
+
"properties": {
|
|
301
|
+
"id": {
|
|
302
|
+
"description": "block-id"
|
|
303
|
+
},
|
|
304
|
+
"field": {
|
|
305
|
+
"type": "string"
|
|
306
|
+
},
|
|
307
|
+
"value": {
|
|
308
|
+
"type": "object"
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
"additionalProperties": true
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
"state": {
|
|
316
|
+
"machines": {
|
|
317
|
+
"answer": [
|
|
318
|
+
"open",
|
|
319
|
+
"pending",
|
|
320
|
+
"accepted",
|
|
321
|
+
"declined",
|
|
322
|
+
"expired"
|
|
323
|
+
]
|
|
324
|
+
},
|
|
325
|
+
"visual_states": [
|
|
326
|
+
"default",
|
|
327
|
+
"loading",
|
|
328
|
+
"success",
|
|
329
|
+
"error",
|
|
330
|
+
"disabled"
|
|
331
|
+
]
|
|
332
|
+
},
|
|
333
|
+
"persistence": {
|
|
334
|
+
"mode": "none",
|
|
335
|
+
"source_of_truth": "host",
|
|
336
|
+
"network_owner": "host",
|
|
337
|
+
"revision_field": null
|
|
338
|
+
},
|
|
339
|
+
"ownership": {
|
|
340
|
+
"source": "simai/ui-view",
|
|
341
|
+
"data": "host",
|
|
342
|
+
"effects": "host",
|
|
343
|
+
"forbidden_client_responsibilities": [
|
|
344
|
+
"saving the values",
|
|
345
|
+
"validating beyond required fields and the controls' own entries",
|
|
346
|
+
"access decisions"
|
|
347
|
+
]
|
|
348
|
+
},
|
|
349
|
+
"security": {
|
|
350
|
+
"permissions_owner": "host",
|
|
351
|
+
"untrusted_inputs": [
|
|
352
|
+
"heading, labels and values (drawn by the field renderers as text)"
|
|
353
|
+
],
|
|
354
|
+
"network_policy": "deny"
|
|
355
|
+
},
|
|
356
|
+
"accessibility": {
|
|
357
|
+
"role": "region",
|
|
358
|
+
"accessible_name": "internal",
|
|
359
|
+
"keyboard": [
|
|
360
|
+
"Tab",
|
|
361
|
+
"Enter",
|
|
362
|
+
"Space"
|
|
363
|
+
],
|
|
364
|
+
"focus": "A section named by its heading (role=heading at heading-level). The status line is a polite live region, present before it speaks; when the answers go, focus moves to it; when Send is stopped or refused, to the first field in error."
|
|
365
|
+
},
|
|
366
|
+
"presentation": {
|
|
367
|
+
"themes": [
|
|
368
|
+
"light",
|
|
369
|
+
"dark"
|
|
370
|
+
],
|
|
371
|
+
"locales": [
|
|
372
|
+
"en",
|
|
373
|
+
"ru"
|
|
374
|
+
],
|
|
375
|
+
"responsive": [
|
|
376
|
+
"desktop",
|
|
377
|
+
"mobile"
|
|
378
|
+
],
|
|
379
|
+
"skeleton": {
|
|
380
|
+
"shape": "none",
|
|
381
|
+
"while_loading": "none"
|
|
382
|
+
}
|
|
383
|
+
},
|
|
384
|
+
"adapter": {
|
|
385
|
+
"kind": "generic",
|
|
386
|
+
"protocol": "simai.smart-studio-adapter.v1",
|
|
387
|
+
"module": null
|
|
388
|
+
},
|
|
389
|
+
"artifacts": {
|
|
390
|
+
"fixtures": [],
|
|
391
|
+
"scenarios": []
|
|
392
|
+
},
|
|
393
|
+
"readiness": {
|
|
394
|
+
"level": "host-required",
|
|
395
|
+
"required_checks": [
|
|
396
|
+
"manifest",
|
|
397
|
+
"loader-rule",
|
|
398
|
+
"view-flow-contract",
|
|
399
|
+
"view-flow-browser"
|
|
400
|
+
]
|
|
401
|
+
},
|
|
402
|
+
"compatibility": {
|
|
403
|
+
"contract_schema": {
|
|
404
|
+
"id": "https://simai.io/contracts/smart-component-manifest.v2.schema.json",
|
|
405
|
+
"version": 2
|
|
406
|
+
},
|
|
407
|
+
"runtime_pair": {
|
|
408
|
+
"ui_revision": "62b1d9b6dc8d390837b7daa7c28a4543297521ad",
|
|
409
|
+
"ui_smart_revision": "62b1d9b6dc8d390837b7daa7c28a4543297521ad"
|
|
410
|
+
},
|
|
411
|
+
"aliases": [],
|
|
412
|
+
"deprecations": [],
|
|
413
|
+
"replacement": null,
|
|
414
|
+
"migrations": [
|
|
415
|
+
{
|
|
416
|
+
"from": "1.0.0",
|
|
417
|
+
"to": "1.1.0",
|
|
418
|
+
"changes": [
|
|
419
|
+
"The block draws the property types money, percent, items, compound and ru.requisites with the record card's controls (view-properties js/set-fields.js, through the shared field value). Nothing changes for a host that sends none of them."
|
|
420
|
+
]
|
|
421
|
+
}
|
|
422
|
+
]
|
|
423
|
+
},
|
|
424
|
+
"provenance": {
|
|
425
|
+
"source_repository": "simai/ui-view",
|
|
426
|
+
"source_revision": "94a63c638f63c0cae50623b2f911a3120e4c5a6b",
|
|
427
|
+
"source_artifacts": [
|
|
428
|
+
{
|
|
429
|
+
"path": "src/smart/view-flow/index.js",
|
|
430
|
+
"sha256": "8a519d3bb7a6bda52339aa2a74ad905bce8d898022bc5c9c6d819e2b4663366b"
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
"path": "src/smart/view-flow/js/answer.js",
|
|
434
|
+
"sha256": "7ade765807ce11ef2ebeb813f8d91e6e742a8cf94ea147e01738e928d6a348fc"
|
|
435
|
+
},
|
|
436
|
+
{
|
|
437
|
+
"path": "src/smart/view-flow/js/templates/default.js",
|
|
438
|
+
"sha256": "dff4ddc80b56d3fb07b1481441ca6ec0248678e9513b95319e05f0f471c8d504"
|
|
439
|
+
},
|
|
440
|
+
{
|
|
441
|
+
"path": "src/smart/view-flow/js/templates/default.css",
|
|
442
|
+
"sha256": "1950e47fd8609d263df3d15745cb190d377fbd9a1f59d4e1705e9aa6a4f8f18d"
|
|
443
|
+
},
|
|
444
|
+
{
|
|
445
|
+
"path": "src/smart/view-properties/js/field-value.js",
|
|
446
|
+
"sha256": "aa04dbf2f3f8a979966af613c82e2bcffa13020371a5884f88728f50c1145b8e"
|
|
447
|
+
},
|
|
448
|
+
{
|
|
449
|
+
"path": "src/smart/view-properties/js/conditions.js",
|
|
450
|
+
"sha256": "bf48b0bf4d2affb43433d1142b1a0ca57e22dc26088c5bd0b28e3212fba7134b"
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
"path": "src/smart/helpers/confirm-surface.js",
|
|
454
|
+
"sha256": "d46e8651582d9fcba73394af057fed4d8dc79c3ee5b8b525abb689d41a0613c4"
|
|
455
|
+
},
|
|
456
|
+
{
|
|
457
|
+
"path": "src/smart/view-flow/rule.js",
|
|
458
|
+
"sha256": "e91d2c9ebaa697679a5911af4a884beeedc9e6eab09667277599e52b7fa6369c"
|
|
459
|
+
},
|
|
460
|
+
{
|
|
461
|
+
"path": "src/smart/view-flow/docs.md",
|
|
462
|
+
"sha256": "6c9e6914dadee80e973c8e4171f7b1aac3895e5a8dc9dc75b8e8edf49b24c9bb"
|
|
463
|
+
}
|
|
464
|
+
],
|
|
465
|
+
"generated_runtime": []
|
|
466
|
+
},
|
|
467
|
+
"ai_guidance": {
|
|
468
|
+
"use_when": "Use sf-view-flow for a few properties inside a flow: an assistant's answer showing a record, or asking the person to fill in a few fields and send them. For a record on a page or in a panel use sf-view-properties.",
|
|
469
|
+
"do_not": [
|
|
470
|
+
"Do not save in the element; answer the answer event and call settle",
|
|
471
|
+
"Do not leave the block pending: settle it, or set state",
|
|
472
|
+
"Do not send markup in labels or values"
|
|
473
|
+
],
|
|
474
|
+
"required_reads": [
|
|
475
|
+
"inputs",
|
|
476
|
+
"contracts",
|
|
477
|
+
"events",
|
|
478
|
+
"accessibility"
|
|
479
|
+
],
|
|
480
|
+
"minimal_example": "<sf-view-flow mode=\"edit\" heading=\"Командировка\" block-id=\"b1\" fields='[{\"key\":\"city\",\"label\":\"Город\",\"propertyType\":\"string\",\"required\":true}]'></sf-view-flow>",
|
|
481
|
+
"owner_commands": [
|
|
482
|
+
"node scripts/test.mjs",
|
|
483
|
+
"node scripts/run-browser-probes.mjs <free> <set build>"
|
|
484
|
+
]
|
|
485
|
+
}
|
|
486
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<!-- sf-view-flow, example «answered»: the static markup (standard simai.smart-component 1.3.8 §5.4). Generated by scripts/snapshot-first-paint.mjs from the built output; do not edit, run it again. -->
|
|
2
|
+
<sf-view-flow mode="edit" state="accepted" heading="Новая командировка" block-id="b1" style="display: contents;"><script type="application/json" data-sf-settings>{"fields":[{"key":"city","label":"Город","propertyType":"string","width":"half","required":true,"placeholder":"Куда","value":"Казань"},{"key":"from","label":"Выезд","propertyType":"date","width":"half","required":true,"value":"2026-11-20"},{"key":"nights","label":"Ночей","propertyType":"integer","width":"half","value":3},{"key":"goal","label":"Цель поездки","propertyType":"text","width":"full","placeholder":"Например, встреча с заказчиком","value":"Встреча с заказчиком"}]}</script>
|
|
3
|
+
<section class="sf-view-flow sf-view-flow--edit sf-view-flow--accepted sf-view-flow--size-1-2" aria-labelledby="sf-view-flow-answered-1" data-state="accepted" data-sf-static>
|
|
4
|
+
<div class="sf-view-flow__heading" role="heading" id="sf-view-flow-answered-1" aria-level="3">Новая командировка</div>
|
|
5
|
+
|
|
6
|
+
<div class="sf-view-flow__groups">
|
|
7
|
+
<div class="sf-view-flow__group" data-group="group-1">
|
|
8
|
+
<div class="sf-view-flow__fields" id="sf-view-flow-answered-2">
|
|
9
|
+
|
|
10
|
+
<div class="sf-view-flow__field sf-view-flow__field--half flex flex-col gap-1/4 min-w-0" data-field="city">
|
|
11
|
+
<div class="sf-view-flow__label flex items-cross-center gap-1/3 color-on-surface-variant">
|
|
12
|
+
<span>Город</span>
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
</div>
|
|
16
|
+
<div class="sf-view-flow__value min-w-0 flex items-cross-center gap-1 flex-wrap"><span class="sf-field-view">Казань</span></div>
|
|
17
|
+
|
|
18
|
+
</div>
|
|
19
|
+
<div class="sf-view-flow__field sf-view-flow__field--half flex flex-col gap-1/4 min-w-0" data-field="from">
|
|
20
|
+
<div class="sf-view-flow__label flex items-cross-center gap-1/3 color-on-surface-variant">
|
|
21
|
+
<span>Выезд</span>
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
</div>
|
|
25
|
+
<div class="sf-view-flow__value min-w-0 flex items-cross-center gap-1 flex-wrap"><span class="sf-field-view">20 нояб. 2026 г.</span></div>
|
|
26
|
+
|
|
27
|
+
</div>
|
|
28
|
+
<div class="sf-view-flow__field sf-view-flow__field--half flex flex-col gap-1/4 min-w-0" data-field="nights">
|
|
29
|
+
<div class="sf-view-flow__label flex items-cross-center gap-1/3 color-on-surface-variant">
|
|
30
|
+
<span>Ночей</span>
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
</div>
|
|
34
|
+
<div class="sf-view-flow__value min-w-0 flex items-cross-center gap-1 flex-wrap"><span class="sf-field-view">3</span></div>
|
|
35
|
+
|
|
36
|
+
</div>
|
|
37
|
+
<div class="sf-view-flow__field sf-view-flow__field--full flex flex-col gap-1/4 min-w-0" data-field="goal">
|
|
38
|
+
<div class="sf-view-flow__label flex items-cross-center gap-1/3 color-on-surface-variant">
|
|
39
|
+
<span>Цель поездки</span>
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
</div>
|
|
43
|
+
<div class="sf-view-flow__value min-w-0 flex items-cross-center gap-1 flex-wrap"><span class="sf-field-view">Встреча с заказчиком</span></div>
|
|
44
|
+
|
|
45
|
+
</div>
|
|
46
|
+
</div></div>
|
|
47
|
+
</div>
|
|
48
|
+
|
|
49
|
+
<footer class="sf-view-flow__footer">
|
|
50
|
+
|
|
51
|
+
<p role="status" tabindex="-1" class="sf-view-flow__status">
|
|
52
|
+
<sf-icon size="1/2" aria-hidden="true" icon="check_circle" style="display: contents;"><i class="sf-icon sf-icon--size-1/2 sf-icon--weight-regular" style="--sf-icon--grade:0;--sf-icon--optical-size:24" aria-hidden="true" data-sf-static>check_circle</i></sf-icon><span>Отправлено</span>
|
|
53
|
+
</p>
|
|
54
|
+
<div class="sf-view-flow__actions" hidden></div>
|
|
55
|
+
</footer>
|
|
56
|
+
</section>
|
|
57
|
+
</sf-view-flow>
|
|
Binary file
|