cedar-embeddable-editor 2.0.3 → 2.0.5
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/CHANGELOG.md +79 -4
- package/bundle-manifest.json +2 -2
- package/cedar-embeddable-editor.d.ts +35 -10
- package/cedar-embeddable-editor.js +131 -131
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,81 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.0.5] - 2026-09-03
|
|
11
|
+
|
|
12
|
+
This release aligns CEE's build-time model dependency with the public
|
|
13
|
+
`cedar-model-typescript-library@1.0.6` package. It also completes a pass over
|
|
14
|
+
the editor's read/write interaction states and the presentation of supplied
|
|
15
|
+
read-only instances.
|
|
16
|
+
|
|
17
|
+
### Changed
|
|
18
|
+
|
|
19
|
+
- Compact YAML downloads retain the artifact ID for templates, elements, fields, and instances.
|
|
20
|
+
|
|
21
|
+
- Read-only instances present recorded values as values rather than editable controls. Multiple
|
|
22
|
+
selections read as a list, temporal values respect their declared granularity, authority and
|
|
23
|
+
controlled-term identifiers remain available as links, and multi-instance fields keep their
|
|
24
|
+
occurrence controls alongside the field heading.
|
|
25
|
+
|
|
26
|
+
- Field specification text, numeric bounds, field and element identity markers, and the spacing of
|
|
27
|
+
editable forms are more compact and consistent.
|
|
28
|
+
|
|
29
|
+
### Fixed
|
|
30
|
+
|
|
31
|
+
- Loading, clearing, and rejecting an over-limit edit in a multi-select no longer leaves stale
|
|
32
|
+
selection or validation state, erases an existing answer, or writes while the form is read-only.
|
|
33
|
+
|
|
34
|
+
- Required checkbox and multi-select fields now report an unanswered value correctly, and checkbox
|
|
35
|
+
view synchronization no longer mutates the instance.
|
|
36
|
+
|
|
37
|
+
- Paging, copying, adding, deleting, and emptying repeated fields and attribute-value fields keep
|
|
38
|
+
the displayed occurrence, cursor, and serialized instance in agreement.
|
|
39
|
+
|
|
40
|
+
- Temporal fields now preserve the selected year in month pickers, ignore an untouched AM/PM
|
|
41
|
+
control, restore invalid typed segments on blur, and display unreadable stored values explicitly.
|
|
42
|
+
|
|
43
|
+
- Controlled-term searches honor value arrangements, distinguish empty and failed result states,
|
|
44
|
+
recover after an aborted suggestion click, and retain a labelless loaded term by its IRI.
|
|
45
|
+
|
|
46
|
+
- Authority inputs no longer issue duplicate searches per keystroke and consistently reconcile
|
|
47
|
+
unselected free text on blur.
|
|
48
|
+
|
|
49
|
+
## [2.0.4] - 2026-09-01
|
|
50
|
+
|
|
51
|
+
This release aligns CEE's build-time model dependency with the public
|
|
52
|
+
`cedar-model-typescript-library@1.0.5` package. The model library remains compiled into CEE's
|
|
53
|
+
browser bundle and is not a runtime dependency for embedding applications.
|
|
54
|
+
|
|
55
|
+
### Changed
|
|
56
|
+
|
|
57
|
+
- The application and visual-test dependency graphs now pin the same public
|
|
58
|
+
`cedar-model-typescript-library@1.0.5` tarball from npmjs.
|
|
59
|
+
|
|
60
|
+
- A template may be replaced while no instance has been supplied. Set-once exists
|
|
61
|
+
to refuse one question — what becomes of the answers someone has been typing when
|
|
62
|
+
the template under them is swapped — and where there are no answers, there is
|
|
63
|
+
nothing to lose. Each replacement builds a fresh context, so nothing of the
|
|
64
|
+
previous template survives into the new form; once an instance is loaded the
|
|
65
|
+
template is fixed again and a second assignment is reported and ignored, as
|
|
66
|
+
before. A host showing a live view of a template that is itself being edited no
|
|
67
|
+
longer has to discard the element and start a whole editor per change, which cost
|
|
68
|
+
about a second of bootstrapping regardless of the size of the template.
|
|
69
|
+
|
|
70
|
+
### Added
|
|
71
|
+
|
|
72
|
+
- The editor says it is the editor. `CEE` is stamped under the mark in the form's
|
|
73
|
+
header, above the version, which on its own read `2.0.4-dev.20260827.…` and named
|
|
74
|
+
a build without naming what was built. It matters where CEE is one of several
|
|
75
|
+
CEDAR components on a page: the embeddable designer's preview panel puts CEE's
|
|
76
|
+
header a few inches from the designer's own.
|
|
77
|
+
|
|
78
|
+
- `showExpandCollapseAll`, a config key hiding the Expand All and Collapse All
|
|
79
|
+
buttons above the form. On by default, so nothing changes for a host that does
|
|
80
|
+
not set it. A host rendering its own view of the same artifact beside the form
|
|
81
|
+
— the CEDAR Embeddable Designer previewing the template it is editing — can turn
|
|
82
|
+
them off rather than offering two contradictory sets of controls over one thing.
|
|
83
|
+
Each section still opens and closes on its own header.
|
|
84
|
+
|
|
10
85
|
## [2.0.3] - 2026-08-27
|
|
11
86
|
|
|
12
87
|
This release aligns CEE's build-time model dependency with the public
|
|
@@ -207,12 +282,12 @@ null` for a literal and `{}` for an IRI — and the compact serialization, the o
|
|
|
207
282
|
value to show.
|
|
208
283
|
|
|
209
284
|
- `Compact YAML - Instance` in the download menu writes the model library's
|
|
210
|
-
compact instance form to `<name>-instance-compact.yaml`,
|
|
211
|
-
and
|
|
285
|
+
compact instance form to `<name>-instance-compact.yaml`, retaining root identity
|
|
286
|
+
and instance data while omitting provenance metadata.
|
|
212
287
|
|
|
213
288
|
- `Compact YAML - Template` in the download menu writes the model library's
|
|
214
|
-
compact template form to `<name>-template-compact.yaml`, alongside
|
|
215
|
-
YAML document rather than replacing it.
|
|
289
|
+
identified compact template form to `<name>-template-compact.yaml`, alongside
|
|
290
|
+
the full YAML document rather than replacing it.
|
|
216
291
|
|
|
217
292
|
- `CeeValidationProblem` declares `field` and `inputType`. Every problem has carried both and the
|
|
218
293
|
validation guide documents both, so the one kind of consumer the declarations exist for was the
|
package/bundle-manifest.json
CHANGED
|
@@ -6,12 +6,15 @@
|
|
|
6
6
|
* `tsc --emitDeclarationOnly` turn this one file into the `.d.ts` the npm package
|
|
7
7
|
* ships, without dragging in paths that exist only inside this repository.
|
|
8
8
|
*
|
|
9
|
-
* Configuration
|
|
10
|
-
* and
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
9
|
+
* Configuration is set-once: the first assignment stands, and a later one is reported
|
|
10
|
+
* and ignored. So is the instance, and so is the template once an instance is loaded
|
|
11
|
+
* against it. That replaces three behaviours which had no answer — a second `config`
|
|
12
|
+
* that patched some keys and replaced others, a read-only mode that could be turned on
|
|
13
|
+
* and not off, and three artifact inputs with no stated precedence.
|
|
14
|
+
*
|
|
15
|
+
* A template with no instance behind it may be replaced, because the question set-once
|
|
16
|
+
* exists to refuse is what becomes of the answers someone has been typing. Where there
|
|
17
|
+
* are none, a host may drive a live view of a template that is itself changing. `eventHandler` is deliberately outside it and may be
|
|
15
18
|
* replaced, for the reasons given where it is declared.
|
|
16
19
|
*
|
|
17
20
|
* Types only, with no runtime values, and that is a constraint rather than a
|
|
@@ -67,6 +70,19 @@ export interface CeeConfig {
|
|
|
67
70
|
* asks. Nothing is rendered under the form either way.
|
|
68
71
|
*/
|
|
69
72
|
showDownloadMenu?: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Offers the Expand All and Collapse All buttons above the form.
|
|
75
|
+
*
|
|
76
|
+
* On by default, which is how CEE has always rendered. A host with its own view
|
|
77
|
+
* of the same artifact beside the form — a designer previewing the template it
|
|
78
|
+
* is editing, say — can turn them off so the two are not offered contradictory
|
|
79
|
+
* controls over one thing.
|
|
80
|
+
*
|
|
81
|
+
* The buttons act on the form's own sections and nothing else, so turning them
|
|
82
|
+
* off removes a control rather than fixing the sections open or shut: each
|
|
83
|
+
* still opens and closes on its own header.
|
|
84
|
+
*/
|
|
85
|
+
showExpandCollapseAll?: boolean;
|
|
70
86
|
/**
|
|
71
87
|
* Base for controlled-term search. Must end in a slash.
|
|
72
88
|
*
|
|
@@ -234,9 +250,10 @@ export interface CeeEventHandler {
|
|
|
234
250
|
/**
|
|
235
251
|
* The custom element, as a host sees it.
|
|
236
252
|
*
|
|
237
|
-
* Registered as `cedar-embeddable-editor`. Configuration
|
|
238
|
-
*
|
|
239
|
-
* ignored, and the first accepted value stands.
|
|
253
|
+
* Registered as `cedar-embeddable-editor`. Configuration takes one assignment, as does
|
|
254
|
+
* the instance, and so does the template once an instance is loaded against it; a second
|
|
255
|
+
* is reported through the event handler and ignored, and the first accepted value stands.
|
|
256
|
+
* A template with no instance behind it may be replaced. An unreadable instance is reported
|
|
240
257
|
* and does not spend its assignment, so the host may correct it. An artifact is a
|
|
241
258
|
* template and optionally an instance, so `templateAndInstanceObject` supplies
|
|
242
259
|
* between them what the two separate inputs do and cannot be combined with either.
|
|
@@ -256,7 +273,15 @@ export interface CedarEmbeddableEditorElement extends HTMLElement {
|
|
|
256
273
|
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
257
274
|
/** Configuration. Assign once, before or after the artifact. */
|
|
258
275
|
config: CeeConfig;
|
|
259
|
-
/**
|
|
276
|
+
/**
|
|
277
|
+
* The template to render, as a parsed CEDAR artifact.
|
|
278
|
+
*
|
|
279
|
+
* Assignable more than once while no instance has been supplied: each one replaces the
|
|
280
|
+
* form, building a fresh context, so nothing of the previous template survives. Once an
|
|
281
|
+
* instance is loaded the template is fixed, and a further assignment is reported and
|
|
282
|
+
* ignored — the answers in front of a person were recorded against the template that
|
|
283
|
+
* would be taken away.
|
|
284
|
+
*/
|
|
260
285
|
templateObject: CeeJsonObject;
|
|
261
286
|
/**
|
|
262
287
|
* An existing instance to load into the form.
|