ngx-json-render 0.5.0 → 0.5.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ngx-json-render",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "Angular renderer for json-render — stream AI-generated JSON specs into real Angular components with signals.",
5
5
  "keywords": [
6
6
  "angular",
@@ -604,7 +604,22 @@ declare class JrElement {
604
604
  /** Prop/visibility resolution context (state + repeat scope + extensions). */
605
605
  private readonly resolutionCtx;
606
606
  protected readonly visible: Signal<boolean>;
607
- /** The element with all prop expressions resolved. */
607
+ /**
608
+ * The element with all prop expressions resolved.
609
+ *
610
+ * Resolving builds a new props object on every state write, whatever the
611
+ * write touched. Handing that on as a change would re-run every catalog
612
+ * template in the tree for one keystroke, so a result that holds the same
613
+ * values as the last one counts as unchanged and keeps the old object.
614
+ *
615
+ * Two-way bound elements are the exception, and keep treating every
616
+ * resolution as a change. Their component writes the user's input into the
617
+ * DOM before it reaches state, so the DOM can differ from a prop whose
618
+ * value never did: typing and a `clearStatePath` in the same turn take
619
+ * the prop from '' through 'milk' back to '' with nobody reading 'milk'.
620
+ * The README tells catalog authors to sync such inputs with an effect on
621
+ * props, and that effect only gets to put the DOM right if it runs.
622
+ */
608
623
  readonly resolvedElement: Signal<UIElement<string, Record<string, unknown>> | undefined>;
609
624
  /** Two-way binding paths ($bindState / $bindItem) by prop name. */
610
625
  readonly bindings: Signal<Record<string, string> | undefined>;