@jxsuite/studio 2.2.2 → 2.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.
Files changed (182) hide show
  1. package/data/css-meta.json +1487 -0
  2. package/data/elements-meta.json +370 -0
  3. package/data/html-meta.json +366 -0
  4. package/data/stylebook-meta.json +200 -0
  5. package/data/webdata.json +1621 -0
  6. package/dist/chunks/{Overlay.dev-ymy3et3y.js → Overlay.dev-d2ajy6sj.js} +7 -7
  7. package/dist/chunks/{content-source-r2n7v682.js → content-source-56xpvx83.js} +13 -12
  8. package/dist/chunks/{convert-to-repeater-cnpyvj74.js → convert-to-repeater-0xh9wwek.js} +12 -11
  9. package/dist/chunks/{extension-sections-vpcm4jvx.js → extension-sections-g34239vm.js} +17 -16
  10. package/dist/chunks/{files-zeg88k2d.js → files-gkz202dp.js} +18 -19
  11. package/dist/chunks/{format-host-taymsw55.js → format-host-pej3srnw.js} +2 -2
  12. package/dist/chunks/{git-panel-qp4rrwr9.js → git-panel-4j6xbh8g.js} +12 -11
  13. package/dist/chunks/{layers-panel-kj93w2zg.js → layers-panel-8mvn8sgd.js} +15 -14
  14. package/dist/chunks/{monaco-setup-xy3bs05d.js → monaco-setup-a5wkmbgh.js} +6 -3
  15. package/dist/chunks/{publish-panel-6qz6kp41.js → publish-panel-ptddc3kg.js} +6 -6
  16. package/dist/chunks/{quick-search-9wwa09hh.js → quick-search-j88azfs2.js} +19 -18
  17. package/dist/chunks/right-panel-egkaxy89.js +38 -0
  18. package/dist/chunks/{sp-overlay.dev-h6kdx076.js → sp-overlay.dev-s18hymn9.js} +8 -8
  19. package/dist/chunks/sp-progress-circle.dev-0zxcyz3r.js +15 -0
  20. package/dist/chunks/sp-tooltip.dev-5c6d1kjz.js +15 -0
  21. package/dist/chunks/{studio-753znj4c.js → studio-0e4h32g6.js} +5 -5
  22. package/dist/chunks/{studio-yz9s88s0.js → studio-10s469da.js} +25 -9
  23. package/dist/chunks/{studio-6f0am8f2.js → studio-2w11grav.js} +2 -2
  24. package/dist/chunks/{studio-zqv3w24n.js → studio-3q65xvzv.js} +5 -5
  25. package/dist/chunks/{studio-qhh8r5fz.js → studio-4058pg09.js} +4 -4
  26. package/dist/chunks/{studio-hekaagev.js → studio-4enps87v.js} +17 -17
  27. package/dist/chunks/{studio-tqemhphj.js → studio-50eed4c9.js} +4 -4
  28. package/dist/chunks/studio-53n8bp04.js +16 -0
  29. package/dist/chunks/{studio-nqq8jk8f.js → studio-5amdrjm4.js} +14 -14
  30. package/dist/chunks/{studio-6zzbyx17.js → studio-5ne8mdx9.js} +2 -2
  31. package/dist/chunks/{studio-3z8jjm2p.js → studio-7ejemhej.js} +3 -3
  32. package/dist/chunks/{studio-1kgfcv7s.js → studio-a11d3a1b.js} +12 -11
  33. package/dist/chunks/{studio-rgwcpast.js → studio-ay8wcr2b.js} +2 -2
  34. package/dist/chunks/{studio-fys6z73y.js → studio-bak2cyjr.js} +7 -7
  35. package/dist/chunks/{studio-xmvbhg31.js → studio-c31yb4t6.js} +2 -2
  36. package/dist/chunks/{studio-8sdyjfd6.js → studio-cf4rk7kv.js} +2 -2
  37. package/dist/chunks/{studio-yphy4z9m.js → studio-cv606rs1.js} +5 -5
  38. package/dist/chunks/{studio-5kt960pk.js → studio-hk523hby.js} +133 -147
  39. package/dist/chunks/{studio-x0et2z9g.js → studio-hs8x23fv.js} +15 -15
  40. package/dist/chunks/{studio-p471gg5n.js → studio-kvfx9z2c.js} +7 -3
  41. package/dist/chunks/{studio-22xr4q8q.js → studio-ncnet0ba.js} +18 -29
  42. package/dist/chunks/{studio-ckwz4d3x.js → studio-twsafr1e.js} +2 -2
  43. package/dist/chunks/{studio-qrsfh1w7.js → studio-tzx3xmvx.js} +5 -5
  44. package/dist/chunks/{studio-g8t7g0gp.js → studio-vdpcpada.js} +3 -3
  45. package/dist/chunks/{studio-6a0h7sne.js → studio-vhk5fmfv.js} +2 -2
  46. package/dist/chunks/{studio-hrajjyt2.js → studio-wdt9y92a.js} +2 -2
  47. package/dist/chunks/{studio-r8vx7bkz.js → studio-x3etxs0s.js} +14 -13
  48. package/dist/chunks/{studio-pv8m0h4a.js → studio-yxzgjq8q.js} +28 -23
  49. package/dist/chunks/{studio-300zsz1k.js → studio-zdkgwhkv.js} +6 -6
  50. package/dist/codicon.ttf +0 -0
  51. package/dist/iframe-entry.js +8 -1
  52. package/dist/manifest.json +82 -0
  53. package/dist/studio.js +232 -103
  54. package/index.html +0 -50
  55. package/package.json +11 -4
  56. package/src/canvas/iframe-entry.ts +5 -0
  57. package/src/canvas/iframe-host.ts +45 -4
  58. package/src/content/entry-editor.ts +2 -1
  59. package/src/editor/context-menu.ts +13 -2
  60. package/src/editor/slash-menu.ts +26 -11
  61. package/src/files/files.ts +11 -23
  62. package/src/grid/grid-panel.ts +27 -6
  63. package/src/hosting/document.ts +109 -0
  64. package/src/hosting/layout.ts +211 -0
  65. package/src/hosting/stage.ts +166 -0
  66. package/src/hosting/tsconfig.json +18 -0
  67. package/src/panels/ai-chat/chat-view.ts +25 -14
  68. package/src/panels/git-panel.ts +17 -14
  69. package/src/panels/head-panel.ts +32 -14
  70. package/src/panels/imports-panel.ts +32 -13
  71. package/src/panels/layers-panel.ts +9 -1
  72. package/src/panels/panel-registry.ts +0 -1
  73. package/src/panels/properties-panel.ts +3 -3
  74. package/src/panels/settings-pane.ts +1 -1
  75. package/src/panels/style-panel.ts +3 -3
  76. package/src/panels/stylebook-panel.ts +10 -1
  77. package/src/panels/toolbar.ts +1 -1
  78. package/src/services/bundle-base.ts +69 -0
  79. package/src/services/monaco-setup.ts +19 -13
  80. package/src/shell/tree.ts +155 -0
  81. package/src/shell.ts +0 -2
  82. package/src/studio.ts +22 -2
  83. package/src/types.ts +15 -0
  84. package/src/ui/regions.ts +10 -45
  85. package/styles/overlays.css +35 -0
  86. package/dist/chunks/2020-xp8vnwma.js.map +0 -24
  87. package/dist/chunks/Overlay.dev-ymy3et3y.js.map +0 -9
  88. package/dist/chunks/adapter-jkcyhgtr.js.map +0 -9
  89. package/dist/chunks/cf-settings-g5fbf2zp.js.map +0 -9
  90. package/dist/chunks/components-z6cnkyy1.js.map +0 -9
  91. package/dist/chunks/content-source-r2n7v682.js.map +0 -9
  92. package/dist/chunks/convert-to-repeater-cnpyvj74.js.map +0 -10
  93. package/dist/chunks/editor-cptq5jp1.js.map +0 -9
  94. package/dist/chunks/extension-sections-vpcm4jvx.js.map +0 -11
  95. package/dist/chunks/files-zeg88k2d.js.map +0 -9
  96. package/dist/chunks/flow-qbfgrpeh.js.map +0 -12
  97. package/dist/chunks/focus-trap.esm-ggawf1hy.js.map +0 -11
  98. package/dist/chunks/focus-visible-6eg70z18.js.map +0 -10
  99. package/dist/chunks/format-host-taymsw55.js.map +0 -9
  100. package/dist/chunks/git-panel-qp4rrwr9.js.map +0 -9
  101. package/dist/chunks/index-nj44jpzj.js.map +0 -14
  102. package/dist/chunks/index-zqxmqxmh.js.map +0 -9
  103. package/dist/chunks/javascript-q8kpmfah.js.map +0 -11
  104. package/dist/chunks/jsonMode-dkr040ga.js.map +0 -18
  105. package/dist/chunks/jx-validate-jj9rnt4n.js.map +0 -9
  106. package/dist/chunks/layers-panel-kj93w2zg.js.map +0 -9
  107. package/dist/chunks/monaco-binding-rj6xpx9y.js.map +0 -10
  108. package/dist/chunks/monaco-setup-xy3bs05d.js.map +0 -15
  109. package/dist/chunks/publish-panel-6qz6kp41.js.map +0 -9
  110. package/dist/chunks/quick-search-9wwa09hh.js.map +0 -9
  111. package/dist/chunks/right-panel-faf816ch.js +0 -37
  112. package/dist/chunks/right-panel-faf816ch.js.map +0 -9
  113. package/dist/chunks/section-registry-sx1ykvkw.js.map +0 -9
  114. package/dist/chunks/sp-overlay.dev-h6kdx076.js.map +0 -9
  115. package/dist/chunks/sp-popover.dev-dj9x7e7a.js.map +0 -9
  116. package/dist/chunks/sp-progress-circle.dev-0fpvhm52.js +0 -15
  117. package/dist/chunks/sp-progress-circle.dev-0fpvhm52.js.map +0 -9
  118. package/dist/chunks/sp-tooltip.dev-rvepkw4r.js +0 -15
  119. package/dist/chunks/sp-tooltip.dev-rvepkw4r.js.map +0 -9
  120. package/dist/chunks/sp-tray.dev-64v4pxw8.js.map +0 -12
  121. package/dist/chunks/studio-0a5qrh01.js.map +0 -9
  122. package/dist/chunks/studio-0rqqhrdy.js.map +0 -12
  123. package/dist/chunks/studio-18j3bmcz.js.map +0 -10
  124. package/dist/chunks/studio-1kgfcv7s.js.map +0 -13
  125. package/dist/chunks/studio-22xr4q8q.js.map +0 -13
  126. package/dist/chunks/studio-300zsz1k.js.map +0 -39
  127. package/dist/chunks/studio-3fk1ac9z.js.map +0 -12
  128. package/dist/chunks/studio-3n4ndrzh.js.map +0 -41
  129. package/dist/chunks/studio-3z8jjm2p.js.map +0 -13
  130. package/dist/chunks/studio-4mqb9a0j.js.map +0 -14
  131. package/dist/chunks/studio-4q0wznzf.js.map +0 -73
  132. package/dist/chunks/studio-5ehhackm.js.map +0 -10
  133. package/dist/chunks/studio-5kt960pk.js.map +0 -38
  134. package/dist/chunks/studio-5x5774ak.js.map +0 -10
  135. package/dist/chunks/studio-685s0ytq.js.map +0 -76
  136. package/dist/chunks/studio-6a0h7sne.js.map +0 -15
  137. package/dist/chunks/studio-6f0am8f2.js.map +0 -10
  138. package/dist/chunks/studio-6kv3apa9.js.map +0 -10
  139. package/dist/chunks/studio-6zzbyx17.js.map +0 -12
  140. package/dist/chunks/studio-753znj4c.js.map +0 -16
  141. package/dist/chunks/studio-7afd21nw.js.map +0 -10
  142. package/dist/chunks/studio-8jpzqk5s.js.map +0 -10
  143. package/dist/chunks/studio-8q517dfr.js.map +0 -10
  144. package/dist/chunks/studio-8sdyjfd6.js.map +0 -10
  145. package/dist/chunks/studio-a0tswy0w.js.map +0 -9
  146. package/dist/chunks/studio-a7pzveq1.js.map +0 -11
  147. package/dist/chunks/studio-ahnzd9rg.js.map +0 -10
  148. package/dist/chunks/studio-b9b6t1dg.js.map +0 -651
  149. package/dist/chunks/studio-bw5dz6km.js.map +0 -21
  150. package/dist/chunks/studio-cjm7fdjf.js.map +0 -14
  151. package/dist/chunks/studio-ckwz4d3x.js.map +0 -12
  152. package/dist/chunks/studio-d1ks410h.js.map +0 -10
  153. package/dist/chunks/studio-dg7zyt5x.js.map +0 -10
  154. package/dist/chunks/studio-fys6z73y.js.map +0 -10
  155. package/dist/chunks/studio-g1wdche0.js.map +0 -56
  156. package/dist/chunks/studio-g8t7g0gp.js.map +0 -10
  157. package/dist/chunks/studio-h4rxscfc.js.map +0 -10
  158. package/dist/chunks/studio-hekaagev.js.map +0 -18
  159. package/dist/chunks/studio-hrajjyt2.js.map +0 -10
  160. package/dist/chunks/studio-nqq8jk8f.js.map +0 -14
  161. package/dist/chunks/studio-p471gg5n.js.map +0 -14
  162. package/dist/chunks/studio-pv8m0h4a.js.map +0 -98
  163. package/dist/chunks/studio-qhh8r5fz.js.map +0 -13
  164. package/dist/chunks/studio-qrsfh1w7.js.map +0 -41
  165. package/dist/chunks/studio-r8vx7bkz.js.map +0 -235
  166. package/dist/chunks/studio-rgwcpast.js.map +0 -12
  167. package/dist/chunks/studio-s519zc99.js.map +0 -10
  168. package/dist/chunks/studio-sas7mt3k.js.map +0 -10
  169. package/dist/chunks/studio-t5wqwzdh.js.map +0 -10
  170. package/dist/chunks/studio-tqemhphj.js.map +0 -11
  171. package/dist/chunks/studio-tr20m8g8.js.map +0 -9
  172. package/dist/chunks/studio-tvgyw9xw.js.map +0 -14
  173. package/dist/chunks/studio-x0et2z9g.js.map +0 -32
  174. package/dist/chunks/studio-xm3dbxvn.js.map +0 -19
  175. package/dist/chunks/studio-xmvbhg31.js.map +0 -10
  176. package/dist/chunks/studio-ynxwkrzd.js.map +0 -246
  177. package/dist/chunks/studio-yphy4z9m.js.map +0 -10
  178. package/dist/chunks/studio-yz9s88s0.js.map +0 -54
  179. package/dist/chunks/studio-z6nw2ek2.js.map +0 -10
  180. package/dist/chunks/studio-zqv3w24n.js.map +0 -11
  181. package/dist/chunks/tsMode-76kr53q0.js.map +0 -13
  182. package/dist/chunks/ws-client-6shc5rze.js.map +0 -12
@@ -1,24 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../node_modules/ajv/dist/vocabularies/dynamic/dynamicAnchor.js", "../../../node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.js", "../../../node_modules/ajv/dist/vocabularies/dynamic/recursiveAnchor.js", "../../../node_modules/ajv/dist/vocabularies/dynamic/recursiveRef.js", "../../../node_modules/ajv/dist/vocabularies/dynamic/index.js", "../../../node_modules/ajv/dist/vocabularies/validation/dependentRequired.js", "../../../node_modules/ajv/dist/vocabularies/applicator/dependentSchemas.js", "../../../node_modules/ajv/dist/vocabularies/validation/limitContains.js", "../../../node_modules/ajv/dist/vocabularies/next.js", "../../../node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.js", "../../../node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.js", "../../../node_modules/ajv/dist/vocabularies/unevaluated/index.js", "../../../node_modules/ajv/dist/vocabularies/draft2020.js", "../../../node_modules/ajv/dist/refs/json-schema-2020-12/index.js", "../../../node_modules/ajv/dist/2020.js"],
4
- "sourcesContent": [
5
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.dynamicAnchor = void 0;\nconst codegen_1 = require(\"../../compile/codegen\");\nconst names_1 = require(\"../../compile/names\");\nconst compile_1 = require(\"../../compile\");\nconst ref_1 = require(\"../core/ref\");\nconst def = {\n keyword: \"$dynamicAnchor\",\n schemaType: \"string\",\n code: (cxt) => dynamicAnchor(cxt, cxt.schema),\n};\nfunction dynamicAnchor(cxt, anchor) {\n const { gen, it } = cxt;\n it.schemaEnv.root.dynamicAnchors[anchor] = true;\n const v = (0, codegen_1._) `${names_1.default.dynamicAnchors}${(0, codegen_1.getProperty)(anchor)}`;\n const validate = it.errSchemaPath === \"#\" ? it.validateName : _getValidate(cxt);\n gen.if((0, codegen_1._) `!${v}`, () => gen.assign(v, validate));\n}\nexports.dynamicAnchor = dynamicAnchor;\nfunction _getValidate(cxt) {\n const { schemaEnv, schema, self } = cxt.it;\n const { root, baseId, localRefs, meta } = schemaEnv.root;\n const { schemaId } = self.opts;\n const sch = new compile_1.SchemaEnv({ schema, schemaId, root, baseId, localRefs, meta });\n compile_1.compileSchema.call(self, sch);\n return (0, ref_1.getValidate)(cxt, sch);\n}\nexports.default = def;\n//# sourceMappingURL=dynamicAnchor.js.map",
6
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.dynamicRef = void 0;\nconst codegen_1 = require(\"../../compile/codegen\");\nconst names_1 = require(\"../../compile/names\");\nconst ref_1 = require(\"../core/ref\");\nconst def = {\n keyword: \"$dynamicRef\",\n schemaType: \"string\",\n code: (cxt) => dynamicRef(cxt, cxt.schema),\n};\nfunction dynamicRef(cxt, ref) {\n const { gen, keyword, it } = cxt;\n if (ref[0] !== \"#\")\n throw new Error(`\"${keyword}\" only supports hash fragment reference`);\n const anchor = ref.slice(1);\n if (it.allErrors) {\n _dynamicRef();\n }\n else {\n const valid = gen.let(\"valid\", false);\n _dynamicRef(valid);\n cxt.ok(valid);\n }\n function _dynamicRef(valid) {\n // TODO the assumption here is that `recursiveRef: #` always points to the root\n // of the schema object, which is not correct, because there may be $id that\n // makes # point to it, and the target schema may not contain dynamic/recursiveAnchor.\n // Because of that 2 tests in recursiveRef.json fail.\n // This is a similar problem to #815 (`$id` doesn't alter resolution scope for `{ \"$ref\": \"#\" }`).\n // (This problem is not tested in JSON-Schema-Test-Suite)\n if (it.schemaEnv.root.dynamicAnchors[anchor]) {\n const v = gen.let(\"_v\", (0, codegen_1._) `${names_1.default.dynamicAnchors}${(0, codegen_1.getProperty)(anchor)}`);\n gen.if(v, _callRef(v, valid), _callRef(it.validateName, valid));\n }\n else {\n _callRef(it.validateName, valid)();\n }\n }\n function _callRef(validate, valid) {\n return valid\n ? () => gen.block(() => {\n (0, ref_1.callRef)(cxt, validate);\n gen.let(valid, true);\n })\n : () => (0, ref_1.callRef)(cxt, validate);\n }\n}\nexports.dynamicRef = dynamicRef;\nexports.default = def;\n//# sourceMappingURL=dynamicRef.js.map",
7
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dynamicAnchor_1 = require(\"./dynamicAnchor\");\nconst util_1 = require(\"../../compile/util\");\nconst def = {\n keyword: \"$recursiveAnchor\",\n schemaType: \"boolean\",\n code(cxt) {\n if (cxt.schema)\n (0, dynamicAnchor_1.dynamicAnchor)(cxt, \"\");\n else\n (0, util_1.checkStrictMode)(cxt.it, \"$recursiveAnchor: false is ignored\");\n },\n};\nexports.default = def;\n//# sourceMappingURL=recursiveAnchor.js.map",
8
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dynamicRef_1 = require(\"./dynamicRef\");\nconst def = {\n keyword: \"$recursiveRef\",\n schemaType: \"string\",\n code: (cxt) => (0, dynamicRef_1.dynamicRef)(cxt, cxt.schema),\n};\nexports.default = def;\n//# sourceMappingURL=recursiveRef.js.map",
9
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dynamicAnchor_1 = require(\"./dynamicAnchor\");\nconst dynamicRef_1 = require(\"./dynamicRef\");\nconst recursiveAnchor_1 = require(\"./recursiveAnchor\");\nconst recursiveRef_1 = require(\"./recursiveRef\");\nconst dynamic = [dynamicAnchor_1.default, dynamicRef_1.default, recursiveAnchor_1.default, recursiveRef_1.default];\nexports.default = dynamic;\n//# sourceMappingURL=index.js.map",
10
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dependencies_1 = require(\"../applicator/dependencies\");\nconst def = {\n keyword: \"dependentRequired\",\n type: \"object\",\n schemaType: \"object\",\n error: dependencies_1.error,\n code: (cxt) => (0, dependencies_1.validatePropertyDeps)(cxt),\n};\nexports.default = def;\n//# sourceMappingURL=dependentRequired.js.map",
11
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dependencies_1 = require(\"./dependencies\");\nconst def = {\n keyword: \"dependentSchemas\",\n type: \"object\",\n schemaType: \"object\",\n code: (cxt) => (0, dependencies_1.validateSchemaDeps)(cxt),\n};\nexports.default = def;\n//# sourceMappingURL=dependentSchemas.js.map",
12
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst util_1 = require(\"../../compile/util\");\nconst def = {\n keyword: [\"maxContains\", \"minContains\"],\n type: \"array\",\n schemaType: \"number\",\n code({ keyword, parentSchema, it }) {\n if (parentSchema.contains === undefined) {\n (0, util_1.checkStrictMode)(it, `\"${keyword}\" without \"contains\" is ignored`);\n }\n },\n};\nexports.default = def;\n//# sourceMappingURL=limitContains.js.map",
13
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst dependentRequired_1 = require(\"./validation/dependentRequired\");\nconst dependentSchemas_1 = require(\"./applicator/dependentSchemas\");\nconst limitContains_1 = require(\"./validation/limitContains\");\nconst next = [dependentRequired_1.default, dependentSchemas_1.default, limitContains_1.default];\nexports.default = next;\n//# sourceMappingURL=next.js.map",
14
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst codegen_1 = require(\"../../compile/codegen\");\nconst util_1 = require(\"../../compile/util\");\nconst names_1 = require(\"../../compile/names\");\nconst error = {\n message: \"must NOT have unevaluated properties\",\n params: ({ params }) => (0, codegen_1._) `{unevaluatedProperty: ${params.unevaluatedProperty}}`,\n};\nconst def = {\n keyword: \"unevaluatedProperties\",\n type: \"object\",\n schemaType: [\"boolean\", \"object\"],\n trackErrors: true,\n error,\n code(cxt) {\n const { gen, schema, data, errsCount, it } = cxt;\n /* istanbul ignore if */\n if (!errsCount)\n throw new Error(\"ajv implementation error\");\n const { allErrors, props } = it;\n if (props instanceof codegen_1.Name) {\n gen.if((0, codegen_1._) `${props} !== true`, () => gen.forIn(\"key\", data, (key) => gen.if(unevaluatedDynamic(props, key), () => unevaluatedPropCode(key))));\n }\n else if (props !== true) {\n gen.forIn(\"key\", data, (key) => props === undefined\n ? unevaluatedPropCode(key)\n : gen.if(unevaluatedStatic(props, key), () => unevaluatedPropCode(key)));\n }\n it.props = true;\n cxt.ok((0, codegen_1._) `${errsCount} === ${names_1.default.errors}`);\n function unevaluatedPropCode(key) {\n if (schema === false) {\n cxt.setParams({ unevaluatedProperty: key });\n cxt.error();\n if (!allErrors)\n gen.break();\n return;\n }\n if (!(0, util_1.alwaysValidSchema)(it, schema)) {\n const valid = gen.name(\"valid\");\n cxt.subschema({\n keyword: \"unevaluatedProperties\",\n dataProp: key,\n dataPropType: util_1.Type.Str,\n }, valid);\n if (!allErrors)\n gen.if((0, codegen_1.not)(valid), () => gen.break());\n }\n }\n function unevaluatedDynamic(evaluatedProps, key) {\n return (0, codegen_1._) `!${evaluatedProps} || !${evaluatedProps}[${key}]`;\n }\n function unevaluatedStatic(evaluatedProps, key) {\n const ps = [];\n for (const p in evaluatedProps) {\n if (evaluatedProps[p] === true)\n ps.push((0, codegen_1._) `${key} !== ${p}`);\n }\n return (0, codegen_1.and)(...ps);\n }\n },\n};\nexports.default = def;\n//# sourceMappingURL=unevaluatedProperties.js.map",
15
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst codegen_1 = require(\"../../compile/codegen\");\nconst util_1 = require(\"../../compile/util\");\nconst error = {\n message: ({ params: { len } }) => (0, codegen_1.str) `must NOT have more than ${len} items`,\n params: ({ params: { len } }) => (0, codegen_1._) `{limit: ${len}}`,\n};\nconst def = {\n keyword: \"unevaluatedItems\",\n type: \"array\",\n schemaType: [\"boolean\", \"object\"],\n error,\n code(cxt) {\n const { gen, schema, data, it } = cxt;\n const items = it.items || 0;\n if (items === true)\n return;\n const len = gen.const(\"len\", (0, codegen_1._) `${data}.length`);\n if (schema === false) {\n cxt.setParams({ len: items });\n cxt.fail((0, codegen_1._) `${len} > ${items}`);\n }\n else if (typeof schema == \"object\" && !(0, util_1.alwaysValidSchema)(it, schema)) {\n const valid = gen.var(\"valid\", (0, codegen_1._) `${len} <= ${items}`);\n gen.if((0, codegen_1.not)(valid), () => validateItems(valid, items));\n cxt.ok(valid);\n }\n it.items = true;\n function validateItems(valid, from) {\n gen.forRange(\"i\", from, len, (i) => {\n cxt.subschema({ keyword: \"unevaluatedItems\", dataProp: i, dataPropType: util_1.Type.Num }, valid);\n if (!it.allErrors)\n gen.if((0, codegen_1.not)(valid), () => gen.break());\n });\n }\n },\n};\nexports.default = def;\n//# sourceMappingURL=unevaluatedItems.js.map",
16
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst unevaluatedProperties_1 = require(\"./unevaluatedProperties\");\nconst unevaluatedItems_1 = require(\"./unevaluatedItems\");\nconst unevaluated = [unevaluatedProperties_1.default, unevaluatedItems_1.default];\nexports.default = unevaluated;\n//# sourceMappingURL=index.js.map",
17
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst core_1 = require(\"./core\");\nconst validation_1 = require(\"./validation\");\nconst applicator_1 = require(\"./applicator\");\nconst dynamic_1 = require(\"./dynamic\");\nconst next_1 = require(\"./next\");\nconst unevaluated_1 = require(\"./unevaluated\");\nconst format_1 = require(\"./format\");\nconst metadata_1 = require(\"./metadata\");\nconst draft2020Vocabularies = [\n dynamic_1.default,\n core_1.default,\n validation_1.default,\n (0, applicator_1.default)(true),\n format_1.default,\n metadata_1.metadataVocabulary,\n metadata_1.contentVocabulary,\n next_1.default,\n unevaluated_1.default,\n];\nexports.default = draft2020Vocabularies;\n//# sourceMappingURL=draft2020.js.map",
18
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nconst metaSchema = require(\"./schema.json\");\nconst applicator = require(\"./meta/applicator.json\");\nconst unevaluated = require(\"./meta/unevaluated.json\");\nconst content = require(\"./meta/content.json\");\nconst core = require(\"./meta/core.json\");\nconst format = require(\"./meta/format-annotation.json\");\nconst metadata = require(\"./meta/meta-data.json\");\nconst validation = require(\"./meta/validation.json\");\nconst META_SUPPORT_DATA = [\"/properties\"];\nfunction addMetaSchema2020($data) {\n ;\n [\n metaSchema,\n applicator,\n unevaluated,\n content,\n core,\n with$data(this, format),\n metadata,\n with$data(this, validation),\n ].forEach((sch) => this.addMetaSchema(sch, undefined, false));\n return this;\n function with$data(ajv, sch) {\n return $data ? ajv.$dataMetaSchema(sch, META_SUPPORT_DATA) : sch;\n }\n}\nexports.default = addMetaSchema2020;\n//# sourceMappingURL=index.js.map",
19
- "\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.MissingRefError = exports.ValidationError = exports.CodeGen = exports.Name = exports.nil = exports.stringify = exports.str = exports._ = exports.KeywordCxt = exports.Ajv2020 = void 0;\nconst core_1 = require(\"./core\");\nconst draft2020_1 = require(\"./vocabularies/draft2020\");\nconst discriminator_1 = require(\"./vocabularies/discriminator\");\nconst json_schema_2020_12_1 = require(\"./refs/json-schema-2020-12\");\nconst META_SCHEMA_ID = \"https://json-schema.org/draft/2020-12/schema\";\nclass Ajv2020 extends core_1.default {\n constructor(opts = {}) {\n super({\n ...opts,\n dynamicRef: true,\n next: true,\n unevaluated: true,\n });\n }\n _addVocabularies() {\n super._addVocabularies();\n draft2020_1.default.forEach((v) => this.addVocabulary(v));\n if (this.opts.discriminator)\n this.addKeyword(discriminator_1.default);\n }\n _addDefaultMetaSchema() {\n super._addDefaultMetaSchema();\n const { $data, meta } = this.opts;\n if (!meta)\n return;\n json_schema_2020_12_1.default.call(this, $data);\n this.refs[\"http://json-schema.org/schema\"] = META_SCHEMA_ID;\n }\n defaultMeta() {\n return (this.opts.defaultMeta =\n super.defaultMeta() || (this.getSchema(META_SCHEMA_ID) ? META_SCHEMA_ID : undefined));\n }\n}\nexports.Ajv2020 = Ajv2020;\nmodule.exports = exports = Ajv2020;\nmodule.exports.Ajv2020 = Ajv2020;\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.default = Ajv2020;\nvar validate_1 = require(\"./compile/validate\");\nObject.defineProperty(exports, \"KeywordCxt\", { enumerable: true, get: function () { return validate_1.KeywordCxt; } });\nvar codegen_1 = require(\"./compile/codegen\");\nObject.defineProperty(exports, \"_\", { enumerable: true, get: function () { return codegen_1._; } });\nObject.defineProperty(exports, \"str\", { enumerable: true, get: function () { return codegen_1.str; } });\nObject.defineProperty(exports, \"stringify\", { enumerable: true, get: function () { return codegen_1.stringify; } });\nObject.defineProperty(exports, \"nil\", { enumerable: true, get: function () { return codegen_1.nil; } });\nObject.defineProperty(exports, \"Name\", { enumerable: true, get: function () { return codegen_1.Name; } });\nObject.defineProperty(exports, \"CodeGen\", { enumerable: true, get: function () { return codegen_1.CodeGen; } });\nvar validation_error_1 = require(\"./runtime/validation_error\");\nObject.defineProperty(exports, \"ValidationError\", { enumerable: true, get: function () { return validation_error_1.default; } });\nvar ref_error_1 = require(\"./compile/ref_error\");\nObject.defineProperty(exports, \"MissingRefError\", { enumerable: true, get: function () { return ref_error_1.default; } });\n//# sourceMappingURL=2020.js.map"
20
- ],
21
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;EACA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;AAAA,EACpD,wBAAqB;AAAA,EAC7B,IAAM;AAAA,EACN,IAAM;AAAA,EACN,IAAM;AAAA,EACN,IAAM;AAAA,EACN,IAAM,MAAM;AAAA,IACR,SAAS;AAAA,IACT,YAAY;AAAA,IACZ,MAAM,CAAC,QAAQ,cAAc,KAAK,IAAI,MAAM;AAAA,EAChD;AAAA,EACA,SAAS,aAAa,CAAC,KAAK,QAAQ;AAAA,IAChC,QAAQ,KAAK,OAAO;AAAA,IACpB,GAAG,UAAU,KAAK,eAAe,UAAU;AAAA,IAC3C,MAAM,IAAK,IAAG,UAAU,KAAM,QAAQ,QAAQ,kBAAkB,GAAG,UAAU,aAAa,MAAM;AAAA,IAChG,MAAM,WAAW,GAAG,kBAAkB,MAAM,GAAG,eAAe,aAAa,GAAG;AAAA,IAC9E,IAAI,GAAI,IAAG,UAAU,MAAO,KAAK,MAAM,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"names": []
9
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "6DE59D29FDB7666E64756E2164756E21",
8
- "names": []
9
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "B652056CE853690D64756E2164756E21",
8
- "names": []
9
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "CEB563C982678AEA64756E2164756E21",
8
- "names": []
9
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "70324E5D75F6A46764756E2164756E21",
8
- "names": []
9
- }
@@ -1,10 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../src/editor/convert-to-repeater.ts"],
4
- "sourcesContent": [
5
- "/// <reference lib=\"dom\" />\n// ─── Convert to Repeater ──────────────────────────────────────────────────────\nimport { html, render as litRender, nothing } from \"lit-html\";\nimport { ref } from \"lit-html/directives/ref.js\";\nimport { childIndex, childList, getNodeAtPath, parentElementPath } from \"../store\";\nimport { primarySelection } from \"../tabs/selection\";\nimport { activeTab } from \"../workspace/workspace\";\nimport { transactDoc } from \"../tabs/transact\";\nimport { showDialog } from \"../ui/layers\";\nimport { defCategory } from \"../panels/signals-panel\";\nimport { fetchPluginSchema } from \"../services/code-services\";\n\nimport type { JxMutableNode } from \"@jxsuite/schema/types\";\n\ninterface RepeaterConfig {\n items: { $ref: string } | unknown[];\n filter?: { $ref: string };\n sort?: { $ref: string };\n newDef?: { name: string };\n}\n\n/** Convert the currently selected element into a repeater template. */\nexport async function convertToRepeater() {\n const tab = activeTab.value;\n const path = primarySelection(tab?.session.selection);\n if (!tab || !path || path.length < 2) {\n return;\n }\n\n const node = getNodeAtPath(tab.doc.document, path);\n if (!node) {\n return;\n }\n\n const defs = tab.doc.document.state || {};\n const config = await promptRepeaterConfig(defs);\n if (!config) {\n return;\n }\n\n transactDoc(tab, (t) => {\n const doc = t.doc.document;\n if (config.newDef) {\n if (!doc.state) {\n doc.state = {};\n }\n doc.state[config.newDef.name] = { default: [], type: \"array\" };\n }\n const pp = parentElementPath(path);\n if (!pp) {\n return;\n }\n const idx = childIndex(path) as number;\n const parent = getNodeAtPath(doc, pp);\n if (!parent?.children) {\n return;\n }\n const element = childList(parent)[idx];\n\n const repeater: Record<string, unknown> = {\n $prototype: \"Array\",\n items: config.items,\n map: element,\n };\n if (config.filter) {\n repeater.filter = config.filter;\n }\n if (config.sort) {\n repeater.sort = config.sort;\n }\n\n // Replace the selected element in place with the array pseudo-element — no wrapper div. The\n // Repeated items render directly among the original parent's children.\n (parent.children as (string | JxMutableNode)[])[idx] = repeater as unknown as JxMutableNode;\n });\n}\n\n/**\n * @param {Record<string, unknown>} defs\n * @returns {Promise<RepeaterConfig | null>}\n */\nasync function promptRepeaterConfig(defs: Record<string, unknown>) {\n const arrayDefs = Object.entries(defs).filter(\n ([, d]) =>\n (d as Record<string, unknown> | null)?.type === \"array\" ||\n Array.isArray((d as Record<string, unknown> | null)?.default) ||\n (d as Record<string, unknown> | null)?.$prototype === \"Array\",\n );\n\n const tab = activeTab.value;\n const docPath = tab?.documentPath;\n for (const [name, d] of Object.entries(defs)) {\n const def = d as Record<string, unknown> | null;\n if (!def?.$prototype || def.$prototype === \"Function\" || def.$prototype === \"Array\") {\n continue;\n }\n if (arrayDefs.some(([n]) => n === name)) {\n continue;\n }\n const schema = await fetchPluginSchema(\n {\n ...(def.$src != null && { $src: def.$src as string }),\n $prototype: def.$prototype as string,\n },\n { ...(docPath != null && { documentPath: docPath }) },\n );\n if (schema?.returns?.type === \"array\") {\n arrayDefs.push([name, d]);\n }\n }\n\n const fnDefs = Object.entries(defs).filter(([, d]) => defCategory(d) === \"function\");\n\n let source = arrayDefs.length > 0 ? arrayDefs[0]![0] : \"__new__\";\n let newDefName = \"\";\n let filterDef = \"\";\n let sortDef = \"\";\n let error = \"\";\n\n return showDialog<RepeaterConfig | null>((done) => {\n function confirm() {\n if (source === \"__new__\") {\n const name = newDefName.trim();\n if (!name) {\n error = \"Enter a name for the new state definition.\";\n rerender();\n return;\n }\n if (defs[name]) {\n error = `\"${name}\" already exists.`;\n rerender();\n return;\n }\n if (!/^[a-zA-Z_$][a-zA-Z0-9_$]*$/.test(name)) {\n error = \"Invalid identifier name.\";\n rerender();\n return;\n }\n done({\n items: { $ref: `#/state/${name}` },\n ...(filterDef && { filter: { $ref: `#/state/${filterDef}` } }),\n ...(sortDef && { sort: { $ref: `#/state/${sortDef}` } }),\n newDef: { name },\n });\n } else {\n done({\n items: { $ref: `#/state/${source}` },\n ...(filterDef && { filter: { $ref: `#/state/${filterDef}` } }),\n ...(sortDef && { sort: { $ref: `#/state/${sortDef}` } }),\n });\n }\n }\n\n function rerender() {\n const layer = document.querySelector(\"#layer-dialog\");\n const slot = layer?.lastElementChild;\n if (slot) {\n litRender(buildTpl(), slot as HTMLElement);\n }\n }\n\n function buildTpl() {\n return html`\n <sp-dialog-wrapper\n open\n underlay\n headline=\"Repeat...\"\n confirm-label=\"Create Repeater\"\n cancel-label=\"Cancel\"\n size=\"s\"\n @confirm=${confirm}\n @cancel=${() => done(null)}\n @close=${() => done(null)}\n >\n <div style=\"display:flex;flex-direction:column;gap:12px\">\n <label>\n <sp-field-label size=\"s\">Items source</sp-field-label>\n <sp-picker\n label=\"Items source\"\n size=\"s\"\n .value=${source}\n @change=${(e: Event) => {\n source = (e.target as HTMLInputElement).value;\n error = \"\";\n rerender();\n }}\n >\n ${arrayDefs.map(\n ([name]) => html`<sp-menu-item value=${name}>${name}</sp-menu-item>`,\n )}\n <sp-menu-divider></sp-menu-divider>\n <sp-menu-item value=\"__new__\">Create new...</sp-menu-item>\n </sp-picker>\n </label>\n\n ${\n source === \"__new__\"\n ? html`\n <label>\n <sp-field-label size=\"s\">New definition name</sp-field-label>\n <sp-textfield\n size=\"s\"\n placeholder=\"myItems\"\n .value=${newDefName}\n ?invalid=${Boolean(error)}\n @input=${(e: Event) => {\n newDefName = (e.target as HTMLInputElement).value || \"\";\n error = \"\";\n rerender();\n }}\n @keydown=${(e: KeyboardEvent) => {\n if (e.key === \"Enter\") {\n confirm();\n }\n }}\n ${ref((el) => {\n if (el && source === \"__new__\") {\n requestAnimationFrame(() => (el as HTMLElement).focus());\n }\n })}\n >\n <sp-help-text slot=\"negative-help-text\">${error}</sp-help-text>\n </sp-textfield>\n </label>\n `\n : nothing\n }\n ${\n fnDefs.length > 0\n ? html`\n <label>\n <sp-field-label size=\"s\">Filter (optional)</sp-field-label>\n <sp-picker\n label=\"Filter\"\n size=\"s\"\n .value=${filterDef}\n @change=${(e: Event) => {\n filterDef = (e.target as HTMLInputElement).value;\n rerender();\n }}\n >\n <sp-menu-item value=\"\">None</sp-menu-item>\n ${fnDefs.map(\n ([name]) => html`<sp-menu-item value=${name}>${name}</sp-menu-item>`,\n )}\n </sp-picker>\n </label>\n <label>\n <sp-field-label size=\"s\">Sort (optional)</sp-field-label>\n <sp-picker\n label=\"Sort\"\n size=\"s\"\n .value=${sortDef}\n @change=${(e: Event) => {\n sortDef = (e.target as HTMLInputElement).value;\n rerender();\n }}\n >\n <sp-menu-item value=\"\">None</sp-menu-item>\n ${fnDefs.map(\n ([name]) => html`<sp-menu-item value=${name}>${name}</sp-menu-item>`,\n )}\n </sp-picker>\n </label>\n `\n : nothing\n }\n </div>\n </sp-dialog-wrapper>\n `;\n }\n\n return buildTpl();\n });\n}\n"
6
- ],
7
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAsBA,eAAsB,iBAAiB,GAAG;AAAA,EACxC,MAAM,MAAM,UAAU;AAAA,EACtB,MAAM,OAAO,iBAAiB,KAAK,QAAQ,SAAS;AAAA,EACpD,IAAI,CAAC,OAAO,CAAC,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A;AAAA;AAAA,iCAMe;AAAA,mCACE,QAAQ,KAAK;AAAA,iCACf,CAAC,MAAa;AAAA,QACrB,aAAc,EAAE,OAA4B,SAAS;AAAA,QACrD,QAAQ;AAAA,QACR,SAAS;AAAA;AAAA,mCAEA,CAAC,MAAqB;AAAA,QAC/B,IAAI,EAAE,QAAQ,SAAS;AAAA,UACrB,QAAQ;AAAA,QACV;AAAA;AAAA,0BAEA,IAAI,CAAC,OAAO;AAAA,QACZ,IAAI,MAAM,WAAW,WAAW;AAAA,UAC9B,sBAAsB,MAAO,GAAmB,MAAM,CAAC;AAAA,QACzD;AAAA,OACD;AAAA;AAAA,kEAEyC;AAAA;AAAA;AAAA,sBAIhD;AAAA,cAGJ,OAAO,SAAS,IACZ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAMe;AAAA,kCACC,CAAC,MAAa;AAAA,QACtB,YAAa,EAAE,OAA4B;AAAA,QAC3C,SAAS;AAAA;AAAA;AAAA;AAAA,0BAIT,OAAO,IACP,EAAE,UAAU,2BAA2B,QAAQ,qBACjD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAQS;AAAA,kCACC,CAAC,MAAa;AAAA,QACtB,UAAW,EAAE,OAA4B;AAAA,QACzC,SAAS;AAAA;AAAA;AAAA;AAAA,0BAIT,OAAO,IACP,EAAE,UAAU,2BAA2B,QAAQ,qBACjD;AAAA;AAAA;AAAA,sBAIN;AAAA;AAAA;AAAA;AAAA;AAAA,IAOd,OAAO,SAAS;AAAA,GACjB;AAAA;",
8
- "debugId": "87EFEC12CDD8956F64756E2164756E21",
9
- "names": []
10
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "7813877B0A1FDE2264756E2164756E21",
8
- "names": []
9
- }
@@ -1,11 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../src/panels/data-grid.ts", "../src/settings/extension-sections.ts"],
4
- "sourcesContent": [
5
- "/// <reference lib=\"dom\" />\n/**\n * Data section actions — the owner console entry points over the platform's data surface.\n *\n * Integration: the settings modal's contributed sections stay fully generic — extension-sections\n * passes this module's {@link dataSectionActions} into the ContributedSectionOptions.actions slot\n * for the data-domain sections (\"connections\"/\"data\") whenever the platform implements the\n * protocol's data routes. Those actions surface Test Connection, Push Schema (dry-run plan\n * confirmation before apply), and Open Data Grid — which opens the grid-tab source picker; table\n * editing itself lives in the spreadsheet grid tabs (src/grid/), which replaced the old modal grid\n * at feature parity (paging, cell edit, add/delete row) and added batch save with undo.\n */\n\nimport { html, nothing } from \"lit-html\";\nimport { openModal } from \"../ui/layers\";\nimport { dataSurfaceAvailable, pushSchema, testConnection } from \"../services/data-service\";\nimport { openGridSourcePicker } from \"../grid/grid-open\";\nimport type { TemplateResult } from \"lit-html\";\nimport type { DataConnectionTestResult, DataPushResult } from \"../types\";\nimport type { SectionActionsContext } from \"../settings/contributed-section\";\n\n// ─── Grid opening (delegates to the grid-tab source picker) ──────────────────\n\n/** Reset all module UI state and close any open surfaces (test hook / project switch). */\nexport function resetDataGridState(): void {\n actionsState = { pushing: false, testResult: null, testing: null };\n closePushDialog();\n}\n\n/** True when the platform serves the data grid. */\nexport function isDataGridAvailable(): boolean {\n return dataSurfaceAvailable();\n}\n\n// ─── Push dialog (dry-run plan confirmation before apply) ─────────────────────\n\ninterface PushDialogState {\n handle: ReturnType<typeof openModal>;\n connection: string | undefined;\n phase: \"loading\" | \"confirm\" | \"applying\" | \"done\";\n plan: DataPushResult | null;\n result: DataPushResult | null;\n onDone: () => void;\n}\n\nlet pushDialog: PushDialogState | null = null;\n\n/** Close the push dialog (also part of resetDataGridState). */\nfunction closePushDialog(): void {\n pushDialog?.handle.close();\n pushDialog = null;\n}\n\n/** Start a push: dry-run first, then a confirmation dialog gates the apply. */\nexport async function startPush(connection: string | undefined, onDone: () => void) {\n if (pushDialog) {\n return;\n }\n const handle = openModal(html``, { label: \"Push Schema\", onDismiss: closePushDialog });\n pushDialog = { connection, handle, onDone, phase: \"loading\", plan: null, result: null };\n renderPushDialog();\n const plan = await pushSchema({\n dryRun: true,\n ...(connection === undefined ? {} : { connection }),\n });\n if (!pushDialog) {\n return;\n }\n pushDialog.plan = plan;\n pushDialog.phase = \"confirm\";\n renderPushDialog();\n}\n\nasync function applyPush(): Promise<void> {\n if (!pushDialog) {\n return;\n }\n pushDialog.phase = \"applying\";\n renderPushDialog();\n const result = await pushSchema(\n pushDialog.connection === undefined ? {} : { connection: pushDialog.connection },\n );\n if (!pushDialog) {\n return;\n }\n pushDialog.result = result;\n pushDialog.phase = \"done\";\n renderPushDialog();\n pushDialog.onDone();\n}\n\nfunction pushDialogBody(state: PushDialogState): TemplateResult {\n if (state.phase === \"loading\" || state.phase === \"applying\") {\n return html`<div class=\"push-dialog-status\">\n ${state.phase === \"loading\" ? \"Compiling plan…\" : \"Applying…\"}\n </div>`;\n }\n const shown = state.phase === \"done\" ? state.result : state.plan;\n const steps = shown?.plan ?? [];\n const warnings = shown?.warnings ?? [];\n const errors = shown?.errors ?? [];\n return html`\n <div class=\"push-dialog-plan\">\n ${\n state.phase === \"done\"\n ? html`<div class=\"push-dialog-status\">\n ${shown?.applied ? \"Schema applied.\" : \"Push failed.\"}\n </div>`\n : steps.length === 0 && errors.length === 0\n ? html`<div class=\"push-dialog-status\">\n Nothing to push — the schema is up to date.\n </div>`\n : nothing\n }\n <ul class=\"push-dialog-steps\">\n ${steps.map(\n (step) => html`<li class=\"push-step push-step-${step.kind}\">${step.summary}</li>`,\n )}\n </ul>\n ${warnings.map((w) => html`<div class=\"push-dialog-warning\">${w}</div>`)}\n ${errors.map((e) => html`<div class=\"push-dialog-error\">${e}</div>`)}\n </div>\n `;\n}\n\nfunction renderPushDialog(): void {\n if (!pushDialog) {\n return;\n }\n const state = pushDialog;\n const confirmable = state.phase === \"confirm\" && (state.plan?.plan.length ?? 0) > 0;\n const tpl = html`\n <sp-underlay open @close=${closePushDialog}></sp-underlay>\n <div class=\"settings-modal push-dialog\">\n <div class=\"settings-modal-header\">\n <h2 class=\"settings-modal-title\">\n Push Schema${state.connection ? html` — ${state.connection}` : nothing}\n </h2>\n </div>\n <div class=\"settings-modal-body\">${pushDialogBody(state)}</div>\n <div class=\"push-dialog-actions\">\n <sp-action-button size=\"s\" class=\"push-cancel\" @click=${closePushDialog}>\n ${state.phase === \"done\" ? \"Close\" : \"Cancel\"}\n </sp-action-button>\n ${\n confirmable\n ? html`<sp-action-button\n size=\"s\"\n emphasized\n class=\"push-apply\"\n @click=${() => {\n void applyPush();\n }}\n >Apply</sp-action-button\n >`\n : nothing\n }\n </div>\n </div>\n `;\n state.handle.update(tpl);\n}\n\n// ─── Contributed-section actions (Test / Push / Open grid) ────────────────────\n\ninterface ActionsState {\n /** Connection currently being tested, when any. */\n testing: string | null;\n testResult: (DataConnectionTestResult & { connection: string }) | null;\n pushing: boolean;\n}\n\nlet actionsState: ActionsState = { pushing: false, testResult: null, testing: null };\n\n/**\n * The actions renderer for a data-domain contributed section, or null when the section is not\n * data-domain or the platform lacks the data routes. Section keys \"connections\"/\"data\" are the\n * connector's host wire contract (the same literals the backend's data routes serve) — the generic\n * contributed-section renderer itself stays extension-agnostic.\n *\n * @param {string} sectionKey\n * @returns {((ctx: SectionActionsContext) => TemplateResult) | null}\n */\nexport function dataSectionActions(\n sectionKey: string,\n): ((ctx: SectionActionsContext) => TemplateResult) | null {\n if ((sectionKey !== \"connections\" && sectionKey !== \"data\") || !dataSurfaceAvailable()) {\n return null;\n }\n return (ctx) => renderSectionActions(sectionKey, ctx);\n}\n\nasync function runTest(connection: string, rerender: () => void): Promise<void> {\n actionsState.testing = connection;\n actionsState.testResult = null;\n rerender();\n const result = await testConnection(connection);\n actionsState.testing = null;\n actionsState.testResult = { ...result, connection };\n rerender();\n}\n\nfunction renderSectionActions(sectionKey: string, ctx: SectionActionsContext): TemplateResult {\n const { selected, rerender } = ctx;\n const { testResult } = actionsState;\n // On the connections section a selected entry scopes both Test and Push to that connection.\n const pushTarget = sectionKey === \"connections\" && selected ? selected : undefined;\n return html`\n <div class=\"data-section-actions\">\n ${\n sectionKey === \"connections\"\n ? html`<sp-action-button\n size=\"s\"\n class=\"data-action-test\"\n ?disabled=${!selected || actionsState.testing !== null}\n @click=${() => {\n if (selected) {\n void runTest(selected, rerender);\n }\n }}\n >\n ${actionsState.testing ? \"Testing…\" : \"Test Connection\"}\n </sp-action-button>`\n : nothing\n }\n <sp-action-button\n size=\"s\"\n class=\"data-action-push\"\n @click=${() => {\n void startPush(pushTarget, rerender);\n }}\n >\n Push Schema\n </sp-action-button>\n <sp-action-button\n size=\"s\"\n class=\"data-action-grid\"\n @click=${() => {\n void openGridSourcePicker();\n }}\n >\n Open Data Grid\n </sp-action-button>\n ${\n testResult\n ? html`<span\n class=\"data-test-result ${testResult.ok ? \"ok\" : \"failed\"}\"\n title=${testResult.error ?? \"\"}\n >\n ${testResult.connection}:\n ${testResult.ok ? \"connected\" : (testResult.error ?? \"failed\")}\n </span>`\n : nothing\n }\n </div>\n `;\n}\n",
6
- "/// <reference lib=\"dom\" />\n/**\n * Extension settings sections — bridges the extensions payload (platform `listExtensions`) into the\n * Project Settings section registry. Every project-section contribution whose class declares a\n * `$studio.settings` block (specs/extensions.md §9.1) gets a section rendered generically by\n * renderContributedSection; sections vanish again when their extension is disabled. The studio\n * hard-codes nothing per extension — parser's Content Types section arrives through this exact\n * path.\n */\n\nimport { getFormats, loadExtensions, loadFormats } from \"../format/format-host\";\nimport { registerSettingsSection, unregisterSettingsSection } from \"./section-registry\";\nimport { renderContributedSection } from \"./contributed-section\";\nimport { dataSectionActions } from \"../panels/data-grid\";\nimport type { ExtensionContributionInfo } from \"../types\";\nimport type { JsonSchema } from \"../ui/schema-form\";\nimport type { SettingsContribution } from \"./contributed-section\";\n\n/** The `$studio.settings` block shape consumed here (nav metadata + the renderer inputs). */\ninterface StudioSettingsBlock {\n icon?: string;\n label?: string;\n order?: number;\n layout?: \"map\" | \"form\";\n entry?: SettingsContribution[\"settings\"][\"entry\"];\n}\n\n/** A contribution resolved into section-registry registration inputs. */\nexport interface DerivedSettingsSection {\n key: string;\n label: string;\n icon?: string | undefined;\n order: number;\n contribution: SettingsContribution;\n}\n\n/** Default sort position for contributed sections without an explicit `order`. */\nconst DEFAULT_SECTION_ORDER = 100;\n\n/**\n * Derive the section registration for one contribution, or null when its class declares no\n * `$studio.settings` block. The wire `entrySchema` is the SECTION value schema (`properties[<key>]`\n * of the project fragment); map layouts edit one entry at a time, so their form schema is that\n * section schema's `additionalProperties`.\n *\n * @param {ExtensionContributionInfo} info\n * @returns {DerivedSettingsSection | null}\n */\nexport function deriveSettingsSection(\n info: ExtensionContributionInfo,\n): DerivedSettingsSection | null {\n const studio = info.studio as { settings?: StudioSettingsBlock } | null | undefined;\n const settings = studio?.settings;\n if (!settings) {\n return null;\n }\n const { key } = info.project;\n const layout = settings.layout ?? \"form\";\n const sectionSchema = (info.entrySchema ?? {}) as JsonSchema & {\n additionalProperties?: JsonSchema | boolean;\n };\n const entrySchema =\n layout === \"map\"\n ? typeof sectionSchema.additionalProperties === \"object\"\n ? sectionSchema.additionalProperties\n : {}\n : (sectionSchema as JsonSchema);\n const label = settings.label ?? info.project.title ?? key;\n return {\n contribution: {\n entrySchema,\n key,\n settings: {\n ...(settings.entry === undefined ? {} : { entry: settings.entry }),\n ...(settings.layout === undefined ? {} : { layout: settings.layout }),\n },\n title: label,\n },\n icon: settings.icon,\n key,\n label,\n order: settings.order ?? DEFAULT_SECTION_ORDER,\n };\n}\n\n/** Section keys this module registered, so stale ones unregister on project/extension change. */\nconst registeredKeys = new Set<string>();\n\n/**\n * The sync currently running, so concurrent callers join it instead of racing it.\n *\n * This is half of the deep-link fix (plan §12 P6.2). `refreshExtensionUi` (`format/format-host.ts`)\n * fires this function **fire-and-forget** on project activation and after every `project.json`\n * write, and the settings surface used to start a SECOND, interleaved run and await only its own.\n * The two runs share {@link registeredKeys} and both reach {@link unregisterSettingsSection}, so a\n * key one run had just registered could be seen as stale by the other and unregistered — after the\n * awaited promise had already resolved. Coalescing makes \"the sections are ready\" one fact about\n * the registry rather than one fact per caller.\n */\nlet _inFlight: Promise<void> | null = null;\n\n/**\n * Await whatever contribution sync is in flight. Resolves immediately when none is.\n *\n * @returns {Promise<void>}\n */\nexport function extensionSectionsReady(): Promise<void> {\n return _inFlight ?? Promise.resolve();\n}\n\n/**\n * Load the extensions payload and (re)register a settings section per `$studio.settings`\n * contribution, unregistering sections whose extension is no longer enabled. Formats load alongside\n * so the `$formats` context root has data at render time. Call on project activation and after\n * project.json `extensions` changes; loadExtensions caches, so repeat calls are cheap.\n *\n * Concurrent calls share one run — see {@link _inFlight}.\n */\nexport function syncExtensionSettingsSections(): Promise<void> {\n _inFlight ??= runSync().finally(() => {\n _inFlight = null;\n });\n return _inFlight;\n}\n\n/** One pass over the extensions payload. Never called concurrently with itself. */\nasync function runSync(): Promise<void> {\n const [extensions] = await Promise.all([loadExtensions(), loadFormats()]);\n const next = new Set<string>();\n for (const ext of extensions) {\n for (const info of ext.contributions) {\n const derived = deriveSettingsSection(info);\n if (!derived) {\n continue;\n }\n const { contribution } = derived;\n registerSettingsSection({\n icon: derived.icon,\n key: derived.key,\n label: derived.label,\n order: derived.order,\n render: (container) => {\n // Data-domain sections get the Test/Push/Data-grid actions slot when the platform\n // Implements the protocol's data routes; every other section renders actions-free.\n const actions = dataSectionActions(derived.key);\n renderContributedSection(container, contribution, {\n formats: getFormats(),\n ...(actions === null ? {} : { actions }),\n });\n },\n });\n next.add(derived.key);\n }\n }\n for (const key of registeredKeys) {\n if (!next.has(key)) {\n unregisterSettingsSection(key);\n }\n }\n registeredKeys.clear();\n for (const key of next) {\n registeredKeys.add(key);\n }\n}\n\n/** Unregister every section this module added and forget them (project close / tests). */\nexport function resetExtensionSettingsSections(): void {\n for (const key of registeredKeys) {\n unregisterSettingsSection(key);\n }\n registeredKeys.clear();\n}\n\n/** The section keys currently registered by this module (diagnostics/tests). */\nexport function ext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AwB;AAAA,QACtB,MAAM,QAAQ;AAAA,QACd,KAAK,QAAQ;AAAA,QACb,OAAO,QAAQ;AAAA,QACf,OAAO,QAAQ;AAAA,QACf,QAAQ,CAAC,cAAc;AAAA,UAGrB,MAAM,UAAU,mBAAmB,QAAQ,GAAG;AAAA,UAC9C,yBAAyB,WAAW,cAAc;AAAA,YAChD,SAAS,WAAW;AAAA,eAChB,YAAY,OAAO,CAAC,IAAI,EAAE,QAAQ;AAAA,UACxC,CAAC;AAAA;AAAA,MAEL,CAAC;AAAA,MACD,KAAK,IAAI,QAAQ,GAAG;AAAA,IACtB;AAAA,EACF;AAAA,EACA,WAAW,OAAO,gBAAgB;AAAA,IAChC,IAAI,CAAC,KAAK,IAAI,GAAG,GAAG;AAAA,MAClB,0BAA0B,GAAG;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,eAAe,MAAM;AAAA,EACrB,WAAW,OAAO,MAAM;AAAA,IACtB,eAAe,IAAI,GAAG;AAAA,EACxB;AAAA;AAIK,SAAS,8BAA8B,GAAS;AAAA,EACrD,WAAW,OAAO,gBAAgB;AAAA,IAChC,0BAA0B,GAAG;AAAA,EAC/B;AAAA,EACA,eAAe,MAAM;AAAA;AAIhB,SAAS,oBAAoB,GAAa;AAAA,EAC/C,OAAO,CAAC,GAAG,cAAc;AAAA;",
9
- "debugId": "DEA4AC156D36823264756E2164756E21",
10
- "names": []
11
- }
@@ -1,9 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": [],
4
- "sourcesContent": [
5
- ],
6
- "mappings": "",
7
- "debugId": "B63A56C9673056D864756E2164756E21",
8
- "names": []
9
- }
@@ -1,12 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../node_modules/@lit-labs/virtualizer/layouts/shared/SizeCache.js", "../../../node_modules/@lit-labs/virtualizer/layouts/shared/BaseLayout.js", "../../../node_modules/@lit-labs/virtualizer/layouts/flow.js"],
4
- "sourcesContent": [
5
- "/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nexport class SizeCache {\n constructor(config) {\n this._map = new Map();\n this._roundAverageSize = false;\n this.totalSize = 0;\n if (config?.roundAverageSize === true) {\n this._roundAverageSize = true;\n }\n }\n set(index, value) {\n const prev = this._map.get(index) || 0;\n this._map.set(index, value);\n this.totalSize += value - prev;\n }\n get averageSize() {\n if (this._map.size > 0) {\n const average = this.totalSize / this._map.size;\n return this._roundAverageSize ? Math.round(average) : average;\n }\n return 0;\n }\n getSize(index) {\n return this._map.get(index);\n }\n clear() {\n this._map.clear();\n this.totalSize = 0;\n }\n}\n//# sourceMappingURL=SizeCache.js.map",
6
- "/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nexport function dim1(direction) {\n return direction === 'horizontal' ? 'width' : 'height';\n}\nexport function dim2(direction) {\n return direction === 'horizontal' ? 'height' : 'width';\n}\nexport function pos1(direction) {\n return direction === 'horizontal' ? 'left' : 'top';\n}\nexport function pos2(direction) {\n return direction === 'horizontal' ? 'top' : 'left';\n}\nexport class BaseLayout {\n _getDefaultConfig() {\n return {\n direction: 'vertical',\n };\n }\n constructor(hostSink, config) {\n /**\n * The last set viewport scroll position.\n */\n this._latestCoords = { left: 0, top: 0 };\n /**\n * Scrolling direction.\n */\n this._direction = null;\n /**\n * Dimensions of the viewport.\n */\n this._viewportSize = { width: 0, height: 0 };\n this.totalScrollSize = { width: 0, height: 0 };\n this.offsetWithinScroller = { left: 0, top: 0 };\n /**\n * Flag for debouncing asynchronous reflow requests.\n */\n this._pendingReflow = false;\n this._pendingLayoutUpdate = false;\n this._pin = null;\n /**\n * The index of the first item intersecting the viewport.\n */\n this._firstVisible = 0;\n /**\n * The index of the last item intersecting the viewport.\n */\n this._lastVisible = 0;\n /**\n * Pixel offset in the scroll direction of the first child.\n */\n this._physicalMin = 0;\n /**\n * Pixel offset in the scroll direction of the last child.\n */\n this._physicalMax = 0;\n /**\n * Index of the first child.\n */\n this._first = -1;\n /**\n * Index of the last child.\n */\n this._last = -1;\n /**\n * Length in the scrolling direction.\n */\n this._sizeDim = 'height';\n /**\n * Length in the non-scrolling direction.\n */\n this._secondarySizeDim = 'width';\n /**\n * Position in the scrolling direction.\n */\n this._positionDim = 'top';\n /**\n * Position in the non-scrolling direction.\n */\n this._secondaryPositionDim = 'left';\n /**\n * Current scroll offset in pixels.\n */\n this._scrollPosition = 0;\n /**\n * Difference between current scroll offset and scroll offset calculated due\n * to a reflow.\n */\n this._scrollError = 0;\n /**\n * Total number of items that could possibly be displayed. Used to help\n * calculate the scroll size.\n */\n this._items = [];\n /**\n * The total (estimated) length of all items in the scrolling direction.\n */\n this._scrollSize = 1;\n /**\n * Number of pixels beyond the viewport to still include\n * in the active range of items.\n */\n // TODO (graynorton): Probably want to make this something we calculate based\n // on viewport size, item size, other factors, possibly still with a dial of some kind\n this._overhang = 1000;\n this._hostSink = hostSink;\n // Delay setting config so that subclasses do setup work first\n Promise.resolve().then(() => (this.config = config || this._getDefaultConfig()));\n }\n set config(config) {\n Object.assign(this, Object.assign({}, this._getDefaultConfig(), config));\n }\n get config() {\n return {\n direction: this.direction,\n };\n }\n /**\n * Maximum index of children + 1, to help estimate total height of the scroll\n * space.\n */\n get items() {\n return this._items;\n }\n set items(items) {\n this._setItems(items);\n }\n _setItems(items) {\n if (items !== this._items) {\n this._items = items;\n this._scheduleReflow();\n }\n }\n /**\n * Primary scrolling direction.\n */\n get direction() {\n return this._direction;\n }\n set direction(dir) {\n // Force it to be either horizontal or vertical.\n dir = dir === 'horizontal' ? dir : 'vertical';\n if (dir !== this._direction) {\n this._direction = dir;\n this._sizeDim = dir === 'horizontal' ? 'width' : 'height';\n this._secondarySizeDim = dir === 'horizontal' ? 'height' : 'width';\n this._positionDim = dir === 'horizontal' ? 'left' : 'top';\n this._secondaryPositionDim = dir === 'horizontal' ? 'top' : 'left';\n this._triggerReflow();\n }\n }\n /**\n * Height and width of the viewport.\n */\n get viewportSize() {\n return this._viewportSize;\n }\n set viewportSize(dims) {\n const { _viewDim1, _viewDim2 } = this;\n Object.assign(this._viewportSize, dims);\n if (_viewDim2 !== this._viewDim2) {\n // this._viewDim2Changed();\n this._scheduleLayoutUpdate();\n }\n else if (_viewDim1 !== this._viewDim1) {\n this._checkThresholds();\n }\n }\n /**\n * Scroll offset of the viewport.\n */\n get viewportScroll() {\n return this._latestCoords;\n }\n set viewportScroll(coords) {\n Object.assign(this._latestCoords, coords);\n const oldPos = this._scrollPosition;\n this._scrollPosition = this._latestCoords[this._positionDim];\n const change = Math.abs(oldPos - this._scrollPosition);\n if (change >= 1) {\n this._checkThresholds();\n }\n }\n /**\n * Perform a reflow if one has been scheduled.\n */\n reflowIfNeeded(force = false) {\n if (force || this._pendingReflow) {\n this._pendingReflow = false;\n this._reflow();\n }\n }\n set pin(options) {\n this._pin = options;\n this._triggerReflow();\n }\n get pin() {\n if (this._pin !== null) {\n const { index, block } = this._pin;\n return {\n index: Math.max(0, Math.min(index, this.items.length - 1)),\n block,\n };\n }\n return null;\n }\n _clampScrollPosition(val) {\n return Math.max(-this.offsetWithinScroller[this._positionDim], Math.min(val, this.totalScrollSize[dim1(this.direction)] - this._viewDim1));\n }\n unpin() {\n if (this._pin !== null) {\n this._sendUnpinnedMessage();\n this._pin = null;\n }\n }\n _updateLayout() {\n // Override\n }\n // protected _viewDim2Changed(): void {\n // this._scheduleLayoutUpdate();\n // }\n /**\n * The height or width of the viewport, whichever corresponds to the scrolling direction.\n */\n get _viewDim1() {\n return this._viewportSize[this._sizeDim];\n }\n /**\n * The height or width of the viewport, whichever does NOT correspond to the scrolling direction.\n */\n get _viewDim2() {\n return this._viewportSize[this._secondarySizeDim];\n }\n _scheduleReflow() {\n this._pendingReflow = true;\n }\n _scheduleLayoutUpdate() {\n this._pendingLayoutUpdate = true;\n this._scheduleReflow();\n }\n // For triggering a reflow based on incoming changes to\n // the layout config.\n _triggerReflow() {\n this._scheduleLayoutUpdate();\n // TODO graynorton@: reflowIfNeeded() isn't really supposed\n // to be called internally. Address in larger cleanup\n // of virtualizer / layout interaction pattern.\n // this.reflowIfNeeded(true);\n Promise.resolve().then(() => this.reflowIfNeeded());\n }\n _reflow() {\n if (this._pendingLayoutUpdate) {\n this._updateLayout();\n this._pendingLayoutUpdate = false;\n }\n this._updateScrollSize();\n this._setPositionFromPin();\n this._getActiveItems();\n this._updateVisibleIndices();\n this._sendStateChangedMessage();\n }\n /**\n * If we are supposed to be pinned to a particular\n * item or set of coordinates, we set `_scrollPosition`\n * accordingly and adjust `_scrollError` as needed\n * so that the virtualizer can keep the scroll\n * position in the DOM in sync\n */\n _setPositionFromPin() {\n if (this.pin !== null) {\n const lastScrollPosition = this._scrollPosition;\n const { index, block } = this.pin;\n this._scrollPosition =\n this._calculateScrollIntoViewPosition({\n index,\n block: block || 'start',\n }) - this.offsetWithinScroller[this._positionDim];\n this._scrollError = lastScrollPosition - this._scrollPosition;\n }\n }\n /**\n * Calculate the coordinates to scroll to, given\n * a request to scroll to the element at a specific\n * index.\n *\n * Supports the same positioning options (`start`,\n * `center`, `end`, `nearest`) as the standard\n * `Element.scrollIntoView()` method, but currently\n * only considers the provided value in the `block`\n * dimension, since we don't yet have any layouts\n * that support virtualization in two dimensions.\n */\n _calculateScrollIntoViewPosition(options) {\n const { block } = options;\n const index = Math.min(this.items.length, Math.max(0, options.index));\n const itemStartPosition = this._getItemPosition(index)[this._positionDim];\n let scrollPosition = itemStartPosition;\n if (block !== 'start') {\n const itemSize = this._getItemSize(index)[this._sizeDim];\n if (block === 'center') {\n scrollPosition =\n itemStartPosition - 0.5 * this._viewDim1 + 0.5 * itemSize;\n }\n else {\n const itemEndPosition = itemStartPosition - this._viewDim1 + itemSize;\n if (block === 'end') {\n scrollPosition = itemEndPosition;\n }\n else {\n // block === 'nearest'\n const currentScrollPosition = this._scrollPosition;\n scrollPosition =\n Math.abs(currentScrollPosition - itemStartPosition) <\n Math.abs(currentScrollPosition - itemEndPosition)\n ? itemStartPosition\n : itemEndPosition;\n }\n }\n }\n scrollPosition += this.offsetWithinScroller[this._positionDim];\n return this._clampScrollPosition(scrollPosition);\n }\n getScrollIntoViewCoordinates(options) {\n return {\n [this._positionDim]: this._calculateScrollIntoViewPosition(options),\n };\n }\n _sendUnpinnedMessage() {\n this._hostSink({\n type: 'unpinned',\n });\n }\n _sendVisibilityChangedMessage() {\n this._hostSink({\n type: 'visibilityChanged',\n firstVisible: this._firstVisible,\n lastVisible: this._lastVisible,\n });\n }\n _sendStateChangedMessage() {\n const childPositions = new Map();\n if (this._first !== -1 && this._last !== -1) {\n for (let idx = this._first; idx <= this._last; idx++) {\n childPositions.set(idx, this._getItemPosition(idx));\n }\n }\n const message = {\n type: 'stateChanged',\n scrollSize: {\n [this._sizeDim]: this._scrollSize,\n [this._secondarySizeDim]: null,\n },\n range: {\n first: this._first,\n last: this._last,\n firstVisible: this._firstVisible,\n lastVisible: this._lastVisible,\n },\n childPositions,\n };\n if (this._scrollError) {\n message.scrollError = {\n [this._positionDim]: this._scrollError,\n [this._secondaryPositionDim]: 0,\n };\n this._scrollError = 0;\n }\n this._hostSink(message);\n }\n /**\n * Number of items to display.\n */\n get _num() {\n if (this._first === -1 || this._last === -1) {\n return 0;\n }\n return this._last - this._first + 1;\n }\n _checkThresholds() {\n if ((this._viewDim1 === 0 && this._num > 0) || this._pin !== null) {\n this._scheduleReflow();\n }\n else {\n const min = Math.max(0, this._scrollPosition - this._overhang);\n const max = Math.min(this._scrollSize, this._scrollPosition + this._viewDim1 + this._overhang);\n if (this._physicalMin > min || this._physicalMax < max) {\n this._scheduleReflow();\n }\n else {\n this._updateVisibleIndices({ emit: true });\n }\n }\n }\n /**\n * Find the indices of the first and last items to intersect the viewport.\n * Emit a visibleindiceschange event when either index changes.\n */\n _updateVisibleIndices(options) {\n if (this._first === -1 || this._last === -1)\n return;\n let firstVisible = this._first;\n while (firstVisible < this._last &&\n Math.round(this._getItemPosition(firstVisible)[this._positionDim] +\n this._getItemSize(firstVisible)[this._sizeDim]) <= Math.round(this._scrollPosition)) {\n firstVisible++;\n }\n let lastVisible = this._last;\n while (lastVisible > this._first &&\n Math.round(this._getItemPosition(lastVisible)[this._positionDim]) >=\n Math.round(this._scrollPosition + this._viewDim1)) {\n lastVisible--;\n }\n if (firstVisible !== this._firstVisible ||\n lastVisible !== this._lastVisible) {\n this._firstVisible = firstVisible;\n this._lastVisible = lastVisible;\n if (options && options.emit) {\n this._sendVisibilityChangedMessage();\n }\n }\n }\n}\n//# sourceMappingURL=BaseLayout.js.map",
7
- "/**\n * @license\n * Copyright 2021 Google LLC\n * SPDX-License-Identifier: BSD-3-Clause\n */\nimport { SizeCache } from './shared/SizeCache.js';\nimport { BaseLayout, dim1 } from './shared/BaseLayout.js';\nexport const flow = (config) => Object.assign({\n type: FlowLayout,\n}, config);\nfunction leadingMargin(direction) {\n return direction === 'horizontal' ? 'marginLeft' : 'marginTop';\n}\nfunction trailingMargin(direction) {\n return direction === 'horizontal' ? 'marginRight' : 'marginBottom';\n}\nfunction offset(direction) {\n return direction === 'horizontal' ? 'xOffset' : 'yOffset';\n}\nfunction collapseMargins(a, b) {\n const m = [a, b].sort();\n return m[1] <= 0 ? Math.min(...m) : m[0] >= 0 ? Math.max(...m) : m[0] + m[1];\n}\nclass MetricsCache {\n constructor() {\n this._childSizeCache = new SizeCache();\n this._marginSizeCache = new SizeCache();\n this._metricsCache = new Map();\n }\n update(metrics, direction) {\n const marginsToUpdate = new Set();\n Object.keys(metrics).forEach((key) => {\n const k = Number(key);\n this._metricsCache.set(k, metrics[k]);\n this._childSizeCache.set(k, metrics[k][dim1(direction)]);\n marginsToUpdate.add(k);\n marginsToUpdate.add(k + 1);\n });\n for (const k of marginsToUpdate) {\n const a = this._metricsCache.get(k)?.[leadingMargin(direction)] || 0;\n const b = this._metricsCache.get(k - 1)?.[trailingMargin(direction)] || 0;\n this._marginSizeCache.set(k, collapseMargins(a, b));\n }\n }\n get averageChildSize() {\n return this._childSizeCache.averageSize;\n }\n get totalChildSize() {\n return this._childSizeCache.totalSize;\n }\n get averageMarginSize() {\n return this._marginSizeCache.averageSize;\n }\n get totalMarginSize() {\n return this._marginSizeCache.totalSize;\n }\n getLeadingMarginValue(index, direction) {\n return this._metricsCache.get(index)?.[leadingMargin(direction)] || 0;\n }\n getChildSize(index) {\n return this._childSizeCache.getSize(index);\n }\n getMarginSize(index) {\n return this._marginSizeCache.getSize(index);\n }\n clear() {\n this._childSizeCache.clear();\n this._marginSizeCache.clear();\n this._metricsCache.clear();\n }\n}\nexport class FlowLayout extends BaseLayout {\n constructor() {\n super(...arguments);\n /**\n * Initial estimate of item size\n */\n this._itemSize = { width: 100, height: 100 };\n /**\n * Indices of children mapped to their (position and length) in the scrolling\n * direction. Used to keep track of children that are in range.\n */\n this._physicalItems = new Map();\n /**\n * Used in tandem with _physicalItems to track children in range across\n * reflows.\n */\n this._newPhysicalItems = new Map();\n /**\n * Width and height of children by their index.\n */\n this._metricsCache = new MetricsCache();\n /**\n * anchorIdx is the anchor around which we reflow. It is designed to allow\n * jumping to any point of the scroll size. We choose it once and stick with\n * it until stable. _first and _last are deduced around it.\n */\n this._anchorIdx = null;\n /**\n * Position in the scrolling direction of the anchor child.\n */\n this._anchorPos = null;\n /**\n * Whether all children in range were in range during the previous reflow.\n */\n this._stable = true;\n this._measureChildren = true;\n this._estimate = true;\n }\n // protected _defaultConfig: BaseLayoutConfig = Object.assign({}, super._defaultConfig, {\n // })\n // constructor(config: Layout1dConfig) {\n // super(config);\n // }\n get measureChildren() {\n return this._measureChildren;\n }\n /**\n * Determine the average size of all children represented in the sizes\n * argument.\n */\n updateItemSizes(sizes) {\n this._metricsCache.update(sizes, this.direction);\n // if (this._nMeasured) {\n // this._updateItemSize();\n this._scheduleReflow();\n // }\n }\n /**\n * Set the average item size based on the total length and number of children\n * in range.\n */\n // _updateItemSize() {\n // // Keep integer values.\n // this._itemSize[this._sizeDim] = this._metricsCache.averageChildSize;\n // }\n _getPhysicalItem(idx) {\n return this._newPhysicalItems.get(idx) ?? this._physicalItems.get(idx);\n }\n _getSize(idx) {\n const item = this._getPhysicalItem(idx);\n return item && this._metricsCache.getChildSize(idx);\n }\n _getAverageSize() {\n return this._metricsCache.averageChildSize || this._itemSize[this._sizeDim];\n }\n _estimatePosition(idx) {\n const c = this._metricsCache;\n if (this._first === -1 || this._last === -1) {\n return (c.averageMarginSize +\n idx * (c.averageMarginSize + this._getAverageSize()));\n }\n else {\n if (idx < this._first) {\n const delta = this._first - idx;\n const refItem = this._getPhysicalItem(this._first);\n return (refItem.pos -\n (c.getMarginSize(this._first - 1) || c.averageMarginSize) -\n (delta * c.averageChildSize + (delta - 1) * c.averageMarginSize));\n }\n else {\n const delta = idx - this._last;\n const refItem = this._getPhysicalItem(this._last);\n return (refItem.pos +\n (c.getChildSize(this._last) || c.averageChildSize) +\n (c.getMarginSize(this._last) || c.averageMarginSize) +\n delta * (c.averageChildSize + c.averageMarginSize));\n }\n }\n }\n /**\n * Returns the position in the scrolling direction of the item at idx.\n * Estimates it if the item at idx is not in the DOM.\n */\n _getPosition(idx) {\n const item = this._getPhysicalItem(idx);\n const { averageMarginSize } = this._metricsCache;\n return idx === 0\n ? this._metricsCache.getMarginSize(0) ?? averageMarginSize\n : item\n ? item.pos\n : this._estimatePosition(idx);\n }\n _calculateAnchor(lower, upper) {\n if (lower <= 0) {\n return 0;\n }\n if (upper > this._scrollSize - this._viewDim1) {\n return this.items.length - 1;\n }\n return Math.max(0, Math.min(this.items.length - 1, Math.floor((lower + upper) / 2 / this._delta)));\n }\n _getAnchor(lower, upper) {\n if (this._physicalItems.size === 0) {\n return this._calculateAnchor(lower, upper);\n }\n if (this._first < 0) {\n return this._calculateAnchor(lower, upper);\n }\n if (this._last < 0) {\n return this._calculateAnchor(lower, upper);\n }\n const firstItem = this._getPhysicalItem(this._first), lastItem = this._getPhysicalItem(this._last), firstMin = firstItem.pos, lastMin = lastItem.pos, lastMax = lastMin + this._metricsCache.getChildSize(this._last);\n if (lastMax < lower) {\n // Window is entirely past physical items, calculate new anchor\n return this._calculateAnchor(lower, upper);\n }\n if (firstMin > upper) {\n // Window is entirely before physical items, calculate new anchor\n return this._calculateAnchor(lower, upper);\n }\n // Window contains a physical item\n // Find one, starting with the one that was previously first visible\n let candidateIdx = this._firstVisible - 1;\n let cMax = -Infinity;\n while (cMax < lower) {\n const candidate = this._getPhysicalItem(++candidateIdx);\n cMax = candidate.pos + this._metricsCache.getChildSize(candidateIdx);\n }\n return candidateIdx;\n }\n /**\n * Updates _first and _last based on items that should be in the current\n * viewed range.\n */\n _getActiveItems() {\n if (this._viewDim1 === 0 || this.items.length === 0) {\n this._clearItems();\n }\n else {\n this._getItems();\n }\n }\n /**\n * Sets the range to empty.\n */\n _clearItems() {\n this._first = -1;\n this._last = -1;\n this._physicalMin = 0;\n this._physicalMax = 0;\n const items = this._newPhysicalItems;\n this._newPhysicalItems = this._physicalItems;\n this._newPhysicalItems.clear();\n this._physicalItems = items;\n this._stable = true;\n }\n /*\n * Updates _first and _last based on items that should be in the given range.\n */\n _getItems() {\n const items = this._newPhysicalItems;\n this._stable = true;\n let lower, upper;\n // The anchorIdx is the anchor around which we reflow. It is designed to\n // allow jumping to any point of the scroll size. We choose it once and\n // stick with it until stable. first and last are deduced around it.\n // If we have a pinned item, we anchor on it\n if (this.pin !== null) {\n const { index } = this.pin;\n this._anchorIdx = index;\n this._anchorPos = this._getPosition(index);\n }\n // Determine the lower and upper bounds of the region to be\n // rendered, relative to the viewport\n lower = this._scrollPosition - this._overhang; //leadingOverhang;\n upper = this._scrollPosition + this._viewDim1 + this._overhang; // trailingOverhang;\n if (upper < 0 || lower > this._scrollSize) {\n this._clearItems();\n return;\n }\n // If we are scrolling to a specific index or if we are doing another\n // pass to stabilize a previously started reflow, we will already\n // have an anchor. If not, establish an anchor now.\n if (this._anchorIdx === null || this._anchorPos === null) {\n this._anchorIdx = this._getAnchor(lower, upper);\n this._anchorPos = this._getPosition(this._anchorIdx);\n }\n let anchorSize = this._getSize(this._anchorIdx);\n if (anchorSize === undefined) {\n this._stable = false;\n anchorSize = this._getAverageSize();\n }\n const anchorLeadingMargin = this._metricsCache.getMarginSize(this._anchorIdx) ??\n this._metricsCache.averageMarginSize;\n const anchorTrailingMargin = this._metricsCache.getMarginSize(this._anchorIdx + 1) ??\n this._metricsCache.averageMarginSize;\n if (this._anchorIdx === 0) {\n this._anchorPos = anchorLeadingMargin;\n }\n if (this._anchorIdx === this.items.length - 1) {\n this._anchorPos = this._scrollSize - anchorTrailingMargin - anchorSize;\n }\n // Anchor might be outside bounds, so prefer correcting the error and keep\n // that anchorIdx.\n let anchorErr = 0;\n if (this._anchorPos + anchorSize + anchorTrailingMargin < lower) {\n anchorErr = lower - (this._anchorPos + anchorSize + anchorTrailingMargin);\n }\n if (this._anchorPos - anchorLeadingMargin > upper) {\n anchorErr = upper - (this._anchorPos - anchorLeadingMargin);\n }\n if (anchorErr) {\n this._scrollPosition -= anchorErr;\n lower -= anchorErr;\n upper -= anchorErr;\n this._scrollError += anchorErr;\n }\n items.set(this._anchorIdx, { pos: this._anchorPos, size: anchorSize });\n this._first = this._last = this._anchorIdx;\n this._physicalMin = this._anchorPos - anchorLeadingMargin;\n this._physicalMax = this._anchorPos + anchorSize + anchorTrailingMargin;\n while (this._physicalMin > lower && this._first > 0) {\n let size = this._getSize(--this._first);\n if (size === undefined) {\n this._stable = false;\n size = this._getAverageSize();\n }\n let margin = this._metricsCache.getMarginSize(this._first);\n if (margin === undefined) {\n this._stable = false;\n margin = this._metricsCache.averageMarginSize;\n }\n this._physicalMin -= size;\n const pos = this._physicalMin;\n items.set(this._first, { pos, size });\n this._physicalMin -= margin;\n if (this._stable === false && this._estimate === false) {\n break;\n }\n }\n while (this._physicalMax < upper && this._last < this.items.length - 1) {\n let size = this._getSize(++this._last);\n if (size === undefined) {\n this._stable = false;\n size = this._getAverageSize();\n }\n let margin = this._metricsCache.getMarginSize(this._last);\n if (margin === undefined) {\n this._stable = false;\n margin = this._metricsCache.averageMarginSize;\n }\n const pos = this._physicalMax;\n items.set(this._last, { pos, size });\n this._physicalMax += size + margin;\n if (!this._stable && !this._estimate) {\n break;\n }\n }\n // This handles the cases where we were relying on estimated sizes.\n const extentErr = this._calculateError();\n if (extentErr) {\n this._physicalMin -= extentErr;\n this._physicalMax -= extentErr;\n this._anchorPos -= extentErr;\n this._scrollPosition -= extentErr;\n items.forEach((item) => (item.pos -= extentErr));\n this._scrollError += extentErr;\n }\n if (this._stable) {\n this._newPhysicalItems = this._physicalItems;\n this._newPhysicalItems.clear();\n this._physicalItems = items;\n }\n }\n _calculateError() {\n if (this._first === 0) {\n return this._physicalMin;\n }\n else if (this._physicalMin <= 0) {\n return this._physicalMin - this._first * this._delta;\n }\n else if (this._last === this.items.length - 1) {\n return this._physicalMax - this._scrollSize;\n }\n else if (this._physicalMax >= this._scrollSize) {\n return (this._physicalMax -\n this._scrollSize +\n (this.items.length - 1 - this._last) * this._delta);\n }\n return 0;\n }\n _reflow() {\n const { _first, _last } = this;\n super._reflow();\n if ((this._first === -1 && this._last == -1) ||\n (this._first === _first && this._last === _last)) {\n this._resetReflowState();\n }\n }\n _resetReflowState() {\n this._anchorIdx = null;\n this._anchorPos = null;\n this._stable = true;\n }\n _updateScrollSize() {\n const { averageMarginSize } = this._metricsCache;\n this._scrollSize = Math.max(1, this.items.length * (averageMarginSize + this._getAverageSize()) +\n averageMarginSize);\n }\n /**\n * Returns the average size (precise or estimated) of an item in the scrolling direction,\n * including any surrounding space.\n */\n get _delta() {\n const { averageMarginSize } = this._metricsCache;\n return this._getAverageSize() + averageMarginSize;\n }\n /**\n * Returns the top and left positioning of the item at idx.\n */\n _getItemPosition(idx) {\n return {\n [this._positionDim]: this._getPosition(idx),\n [this._secondaryPositionDim]: 0,\n [offset(this.direction)]: -(this._metricsCache.getLeadingMarginValue(idx, this.direction) ??\n this._metricsCache.averageMarginSize),\n };\n }\n /**\n * Returns the height and width of the item at idx.\n */\n _getItemSize(idx) {\n return {\n [this._sizeDim]: this._getSize(idx) || this._getAverageSize(),\n [this._secondarySizeDim]: this._itemSize[this._secondarySizeDim],\n };\n }\n _viewDim2Changed() {\n this._metricsCache.clear();\n this._scheduleReflow();\n }\n}\n//# sourceMappingURL=flow.js.map"
8
- ],
9
- "mappings": ";;;AAKO,MAAM,UAAU;AAAA,EACnB,WAAW,CAAC,QAAQ;AAAA,IAChB,KAAK,OAAO,IAAI;AAAA,IAChB,KAAK,oBAAoB;AAAA,IACzB,KAAK,YAAY;AAAA,IACjB,IAAI,QAAQ,qBAAqB,MAAM;AAAA,MACnC,KAAK,oBAAoB;AAAA,IAC7B;AAAA;AAAA,EAEJ,GAAG,CAAC,OAAO,OAAO;AAAA,IACd,MAAM,OAAO,KAAK,KAAK,IAAI,KAAK,KAAK;AAAA,IACrC,KAAK,KAAK,IAAI,OAAO,KAAK;AAAA,IAC1B,KAAK,aAAa,QAAQ;AAAA;AAAA,MAE1B,WAAW,GAAG;AAAA,IACd,IAAI,KAAK,KAAK,OAAO,GAAG;AAAA,MACpB,MAAM,UAAU,KAAK,YAAY,KAAK,KAAK;AAAA,MAC3C,OAAO,KAAK,oBAAoB,KAAK,MAAM,OAAO,IAAI;AAAA,IAC1D;AAAA,IACA,OAAO;AAAA;AAAA,EAEX,OAAO,CAAC,OAAO;AAAA,IACX,OAAO,KAAK,KAAK,IAAI,KAAK;AAAA;AAAA,EAE9B,KAAK,GAAG;AAAA,IACJ,KAAK,KAAK,MAAM;AAAA,IAChB,KAAK,YAAY;AAAA;AAEzB;;;AC5BO,SAAS,IAAI,CAAC,WAAW;AAAA,EAC5B,OAAO,cAAc,eAAe,UAAU;AAAA;AAW3C,MAAM,WAAW;AAAA,EACpB,iBAAiB,GAAG;AAAA,IAChB,OAAO;AAAA,MACH,WAAW;AAAA,IACf;AAAA;AAAA,EAEJ,WAAW,CAAC,UAAU,QAAQ;AAAA,IAI1B,KAAK,gBAAgB,EAAE,MAAM,GAAG,KAAK,EAAE;AAAA,IAIvC,KAAK,aAAa;AAAA,IAIlB,KAAK,gBAAgB,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