@texaryn/react 0.5.2 → 0.5.3

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 CHANGED
@@ -1,5 +1,16 @@
1
1
  # @texaryn/react
2
2
 
3
+ ## 0.5.3
4
+
5
+ ### Patch Changes
6
+
7
+ - eae5f41: Object children are keyed by property name, with `objectChildKey` from
8
+ `@texaryn/core`, so a field keeps its element and its focus when the form grows
9
+ ahead of it, for example when typing into a recursive object exposes the next
10
+ level.
11
+ - Updated dependencies [eae5f41]
12
+ - @texaryn/core@0.13.0
13
+
3
14
  ## 0.5.2
4
15
 
5
16
  ### Patch Changes
@@ -1 +1 @@
1
- {"version":3,"file":"ObjectLayout.d.ts","sourceRoot":"","sources":["../../src/widgets/ObjectLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAK3C,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAA;CACb;AAED,iBAAS,gBAAgB,CAAC,EAAE,IAAI,EAAE,EAAE,WAAW,qBAsB9C;AAED,eAAO,MAAM,YAAY,oDAGxB,CAAA"}
1
+ {"version":3,"file":"ObjectLayout.d.ts","sourceRoot":"","sources":["../../src/widgets/ObjectLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAK3C,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAA;CACb;AAED,iBAAS,gBAAgB,CAAC,EAAE,IAAI,EAAE,EAAE,WAAW,qBAsB9C;AAED,eAAO,MAAM,YAAY,oDAGxB,CAAA"}
@@ -1,12 +1,13 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import React from 'react';
3
+ import { objectChildKey } from '@texaryn/core';
3
4
  import { NodeRenderer } from '../components/NodeRenderer.js';
4
5
  import { useRendererContext } from '../components/renderer-context.js';
5
6
  import { useObjectGroup } from '../hooks/use-object-group.js';
6
7
  function ObjectLayoutImpl({ node }) {
7
8
  const { document, registry } = useRendererContext();
8
9
  const { nested, title, children } = useObjectGroup(node);
9
- const rendered = children.map((child) => (_jsx(NodeRenderer, { node: child, document: document, registry: registry }, child.id)));
10
+ const rendered = children.map((child) => (_jsx(NodeRenderer, { node: child, document: document, registry: registry }, objectChildKey(child))));
10
11
  if (!nested) {
11
12
  return _jsx("div", { children: rendered });
12
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ObjectLayout.js","sourceRoot":"","sources":["../../src/widgets/ObjectLayout.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAA;AAC5D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAA;AACtE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAA;AAM7D,SAAS,gBAAgB,CAAC,EAAE,IAAI,EAAe;IAC7C,MAAM,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,kBAAkB,EAAE,CAAA;IACnD,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,cAAc,CAAC,IAAI,CAAC,CAAA;IAExD,MAAM,QAAQ,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CACvC,KAAC,YAAY,IAAgB,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,IAA7D,KAAK,CAAC,EAAE,CAAyD,CACrF,CAAC,CAAA;IAEF,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,OAAO,wBAAM,QAAQ,GAAO,CAAA;IAC9B,CAAC;IAED,6EAA6E;IAC7E,2EAA2E;IAC3E,6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EF,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,OAAO,wBAAM,QAAQ,GAAO,CAAA;IAC9B,CAAC;IAED,6EAA6E;IAC7E,2EAA2E;IAC3E,6EAA6E;IAC7E,yBAAyB;IACzB,OAAO,CACL,oBAAU,IAAI,EAAE,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS,aACrD,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,2BAAS,KAAK,GAAU,EACtD,wBAAM,QAAQ,GAAO,IACZ,CACZ,CAAA;AACH,CAAC;AAED,MAAM,CAAC,MAAM,YAAY,GAAG,KAAK,CAAC,IAAI,CACpC,gBAAgB,EAChB,CAAC,IAAI,EAAE,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,EAAE,CAC9C,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@texaryn/react",
3
- "version": "0.5.2",
3
+ "version": "0.5.3",
4
4
  "description": "React bindings, hooks, prop getters, and default widgets for Texaryn",
5
5
  "keywords": [
6
6
  "react",
@@ -44,7 +44,7 @@
44
44
  "CHANGELOG.md"
45
45
  ],
46
46
  "dependencies": {
47
- "@texaryn/core": "^0.12.1"
47
+ "@texaryn/core": "^0.13.0"
48
48
  },
49
49
  "peerDependencies": {
50
50
  "react": ">=18.0.0"
@@ -56,7 +56,7 @@
56
56
  "jsdom": "^25.0.0",
57
57
  "react": "^19.0.0",
58
58
  "react-dom": "^19.0.0",
59
- "@texaryn/schema-json": "0.6.3"
59
+ "@texaryn/schema-json": "0.7.0"
60
60
  },
61
61
  "scripts": {
62
62
  "build": "tsc --build"