@fluidframework/tree 2.42.0 → 2.43.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 (542) hide show
  1. package/CHANGELOG.md +189 -0
  2. package/api-report/tree.alpha.api.md +72 -25
  3. package/api-report/tree.beta.api.md +34 -0
  4. package/api-report/tree.legacy.alpha.api.md +1 -0
  5. package/api-report/tree.legacy.public.api.md +1 -0
  6. package/api-report/tree.public.api.md +1 -0
  7. package/dist/alpha.d.ts +12 -6
  8. package/dist/beta.d.ts +6 -1
  9. package/dist/core/index.d.ts +1 -1
  10. package/dist/core/index.d.ts.map +1 -1
  11. package/dist/core/index.js +5 -2
  12. package/dist/core/index.js.map +1 -1
  13. package/dist/core/schema-stored/formatV2.d.ts +80 -0
  14. package/dist/core/schema-stored/formatV2.d.ts.map +1 -0
  15. package/dist/core/schema-stored/formatV2.js +55 -0
  16. package/dist/core/schema-stored/formatV2.js.map +1 -0
  17. package/dist/core/schema-stored/index.d.ts +3 -1
  18. package/dist/core/schema-stored/index.d.ts.map +1 -1
  19. package/dist/core/schema-stored/index.js +5 -2
  20. package/dist/core/schema-stored/index.js.map +1 -1
  21. package/dist/core/schema-stored/schema.d.ts +49 -17
  22. package/dist/core/schema-stored/schema.d.ts.map +1 -1
  23. package/dist/core/schema-stored/schema.js +65 -22
  24. package/dist/core/schema-stored/schema.js.map +1 -1
  25. package/dist/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.d.ts +9 -7
  26. package/dist/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.d.ts.map +1 -1
  27. package/dist/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.js +13 -9
  28. package/dist/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.js.map +1 -1
  29. package/dist/feature-libraries/chunked-forest/codec/compressedEncode.d.ts +3 -3
  30. package/dist/feature-libraries/chunked-forest/codec/compressedEncode.d.ts.map +1 -1
  31. package/dist/feature-libraries/chunked-forest/codec/compressedEncode.js +6 -6
  32. package/dist/feature-libraries/chunked-forest/codec/compressedEncode.js.map +1 -1
  33. package/dist/feature-libraries/chunked-forest/codec/nodeShape.d.ts +1 -1
  34. package/dist/feature-libraries/chunked-forest/codec/nodeShape.d.ts.map +1 -1
  35. package/dist/feature-libraries/chunked-forest/codec/nodeShape.js +3 -3
  36. package/dist/feature-libraries/chunked-forest/codec/nodeShape.js.map +1 -1
  37. package/dist/feature-libraries/detachedFieldIndexSummarizer.d.ts +8 -3
  38. package/dist/feature-libraries/detachedFieldIndexSummarizer.d.ts.map +1 -1
  39. package/dist/feature-libraries/detachedFieldIndexSummarizer.js +2 -5
  40. package/dist/feature-libraries/detachedFieldIndexSummarizer.js.map +1 -1
  41. package/dist/feature-libraries/flex-tree/flexTreeTypes.d.ts +24 -25
  42. package/dist/feature-libraries/flex-tree/flexTreeTypes.d.ts.map +1 -1
  43. package/dist/feature-libraries/flex-tree/flexTreeTypes.js.map +1 -1
  44. package/dist/feature-libraries/flex-tree/index.d.ts +0 -1
  45. package/dist/feature-libraries/flex-tree/index.d.ts.map +1 -1
  46. package/dist/feature-libraries/flex-tree/index.js +1 -7
  47. package/dist/feature-libraries/flex-tree/index.js.map +1 -1
  48. package/dist/feature-libraries/flex-tree/lazyEntity.d.ts +2 -2
  49. package/dist/feature-libraries/flex-tree/lazyEntity.d.ts.map +1 -1
  50. package/dist/feature-libraries/flex-tree/lazyEntity.js +3 -0
  51. package/dist/feature-libraries/flex-tree/lazyEntity.js.map +1 -1
  52. package/dist/feature-libraries/flex-tree/lazyField.d.ts +1 -2
  53. package/dist/feature-libraries/flex-tree/lazyField.d.ts.map +1 -1
  54. package/dist/feature-libraries/flex-tree/lazyField.js +2 -5
  55. package/dist/feature-libraries/flex-tree/lazyField.js.map +1 -1
  56. package/dist/feature-libraries/flex-tree/lazyNode.d.ts +5 -5
  57. package/dist/feature-libraries/flex-tree/lazyNode.d.ts.map +1 -1
  58. package/dist/feature-libraries/flex-tree/lazyNode.js +15 -7
  59. package/dist/feature-libraries/flex-tree/lazyNode.js.map +1 -1
  60. package/dist/feature-libraries/forest-summary/forestSummarizer.d.ts +8 -3
  61. package/dist/feature-libraries/forest-summary/forestSummarizer.d.ts.map +1 -1
  62. package/dist/feature-libraries/forest-summary/forestSummarizer.js +2 -5
  63. package/dist/feature-libraries/forest-summary/forestSummarizer.js.map +1 -1
  64. package/dist/feature-libraries/index.d.ts +2 -2
  65. package/dist/feature-libraries/index.d.ts.map +1 -1
  66. package/dist/feature-libraries/index.js +1 -2
  67. package/dist/feature-libraries/index.js.map +1 -1
  68. package/dist/feature-libraries/mapTreeCursor.d.ts +16 -2
  69. package/dist/feature-libraries/mapTreeCursor.d.ts.map +1 -1
  70. package/dist/feature-libraries/mapTreeCursor.js.map +1 -1
  71. package/dist/feature-libraries/modular-schema/fieldKindWithEditor.d.ts.map +1 -1
  72. package/dist/feature-libraries/modular-schema/fieldKindWithEditor.js +2 -0
  73. package/dist/feature-libraries/modular-schema/fieldKindWithEditor.js.map +1 -1
  74. package/dist/feature-libraries/object-forest/objectForest.d.ts.map +1 -1
  75. package/dist/feature-libraries/object-forest/objectForest.js +2 -0
  76. package/dist/feature-libraries/object-forest/objectForest.js.map +1 -1
  77. package/dist/feature-libraries/schema-edits/schemaChangeCodecs.d.ts.map +1 -1
  78. package/dist/feature-libraries/schema-edits/schemaChangeCodecs.js +8 -4
  79. package/dist/feature-libraries/schema-edits/schemaChangeCodecs.js.map +1 -1
  80. package/dist/feature-libraries/schema-edits/schemaChangeFormat.d.ts +2 -36
  81. package/dist/feature-libraries/schema-edits/schemaChangeFormat.d.ts.map +1 -1
  82. package/dist/feature-libraries/schema-edits/schemaChangeFormat.js +3 -3
  83. package/dist/feature-libraries/schema-edits/schemaChangeFormat.js.map +1 -1
  84. package/dist/feature-libraries/schema-index/codec.d.ts.map +1 -1
  85. package/dist/feature-libraries/schema-index/codec.js +59 -9
  86. package/dist/feature-libraries/schema-index/codec.js.map +1 -1
  87. package/dist/feature-libraries/schema-index/formatV1.d.ts +1 -1
  88. package/dist/feature-libraries/schema-index/formatV2.d.ts +42 -0
  89. package/dist/feature-libraries/schema-index/formatV2.d.ts.map +1 -0
  90. package/dist/feature-libraries/schema-index/formatV2.js +26 -0
  91. package/dist/feature-libraries/schema-index/formatV2.js.map +1 -0
  92. package/dist/feature-libraries/schema-index/index.d.ts +2 -1
  93. package/dist/feature-libraries/schema-index/index.d.ts.map +1 -1
  94. package/dist/feature-libraries/schema-index/index.js +4 -2
  95. package/dist/feature-libraries/schema-index/index.js.map +1 -1
  96. package/dist/feature-libraries/schema-index/schemaSummarizer.d.ts +7 -2
  97. package/dist/feature-libraries/schema-index/schemaSummarizer.d.ts.map +1 -1
  98. package/dist/feature-libraries/schema-index/schemaSummarizer.js +6 -6
  99. package/dist/feature-libraries/schema-index/schemaSummarizer.js.map +1 -1
  100. package/dist/index.d.ts +2 -2
  101. package/dist/index.d.ts.map +1 -1
  102. package/dist/index.js.map +1 -1
  103. package/dist/packageVersion.d.ts +1 -1
  104. package/dist/packageVersion.js +1 -1
  105. package/dist/packageVersion.js.map +1 -1
  106. package/dist/shared-tree/schematizeTree.d.ts.map +1 -1
  107. package/dist/shared-tree/schematizeTree.js +1 -0
  108. package/dist/shared-tree/schematizeTree.js.map +1 -1
  109. package/dist/shared-tree/schematizingTreeView.d.ts.map +1 -1
  110. package/dist/shared-tree/schematizingTreeView.js +3 -3
  111. package/dist/shared-tree/schematizingTreeView.js.map +1 -1
  112. package/dist/shared-tree/sharedTree.d.ts +5 -1
  113. package/dist/shared-tree/sharedTree.d.ts.map +1 -1
  114. package/dist/shared-tree/sharedTree.js +34 -5
  115. package/dist/shared-tree/sharedTree.js.map +1 -1
  116. package/dist/shared-tree/treeAlpha.d.ts +39 -1
  117. package/dist/shared-tree/treeAlpha.d.ts.map +1 -1
  118. package/dist/shared-tree/treeAlpha.js +117 -11
  119. package/dist/shared-tree/treeAlpha.js.map +1 -1
  120. package/dist/shared-tree-core/editManagerSummarizer.d.ts +8 -3
  121. package/dist/shared-tree-core/editManagerSummarizer.d.ts.map +1 -1
  122. package/dist/shared-tree-core/editManagerSummarizer.js +2 -5
  123. package/dist/shared-tree-core/editManagerSummarizer.js.map +1 -1
  124. package/dist/shared-tree-core/sharedTreeCore.d.ts +18 -7
  125. package/dist/shared-tree-core/sharedTreeCore.d.ts.map +1 -1
  126. package/dist/shared-tree-core/sharedTreeCore.js +15 -2
  127. package/dist/shared-tree-core/sharedTreeCore.js.map +1 -1
  128. package/dist/simple-tree/api/configuration.d.ts +15 -3
  129. package/dist/simple-tree/api/configuration.d.ts.map +1 -1
  130. package/dist/simple-tree/api/configuration.js +40 -22
  131. package/dist/simple-tree/api/configuration.js.map +1 -1
  132. package/dist/simple-tree/api/index.d.ts +1 -1
  133. package/dist/simple-tree/api/index.d.ts.map +1 -1
  134. package/dist/simple-tree/api/index.js +4 -4
  135. package/dist/simple-tree/api/index.js.map +1 -1
  136. package/dist/simple-tree/api/schemaCompatibilityTester.js +1 -1
  137. package/dist/simple-tree/api/schemaCompatibilityTester.js.map +1 -1
  138. package/dist/simple-tree/api/schemaCreationUtilities.d.ts +3 -3
  139. package/dist/simple-tree/api/schemaCreationUtilities.js +3 -3
  140. package/dist/simple-tree/api/schemaCreationUtilities.js.map +1 -1
  141. package/dist/simple-tree/api/schemaFactory.d.ts +15 -11
  142. package/dist/simple-tree/api/schemaFactory.d.ts.map +1 -1
  143. package/dist/simple-tree/api/schemaFactory.js +4 -0
  144. package/dist/simple-tree/api/schemaFactory.js.map +1 -1
  145. package/dist/simple-tree/api/schemaFactoryAlpha.d.ts +41 -11
  146. package/dist/simple-tree/api/schemaFactoryAlpha.d.ts.map +1 -1
  147. package/dist/simple-tree/api/schemaFactoryAlpha.js +31 -4
  148. package/dist/simple-tree/api/schemaFactoryAlpha.js.map +1 -1
  149. package/dist/simple-tree/api/storedSchema.js +2 -2
  150. package/dist/simple-tree/api/storedSchema.js.map +1 -1
  151. package/dist/simple-tree/api/treeChangeEvents.d.ts +8 -3
  152. package/dist/simple-tree/api/treeChangeEvents.d.ts.map +1 -1
  153. package/dist/simple-tree/api/treeChangeEvents.js.map +1 -1
  154. package/dist/simple-tree/api/treeNodeApi.d.ts +3 -0
  155. package/dist/simple-tree/api/treeNodeApi.d.ts.map +1 -1
  156. package/dist/simple-tree/api/treeNodeApi.js +1 -1
  157. package/dist/simple-tree/api/treeNodeApi.js.map +1 -1
  158. package/dist/simple-tree/api/viewSchemaToSimpleSchema.d.ts.map +1 -1
  159. package/dist/simple-tree/api/viewSchemaToSimpleSchema.js +5 -0
  160. package/dist/simple-tree/api/viewSchemaToSimpleSchema.js.map +1 -1
  161. package/dist/simple-tree/core/context.d.ts +3 -3
  162. package/dist/simple-tree/core/context.d.ts.map +1 -1
  163. package/dist/simple-tree/core/context.js.map +1 -1
  164. package/dist/simple-tree/core/getOrCreateNode.d.ts +9 -0
  165. package/dist/simple-tree/core/getOrCreateNode.d.ts.map +1 -1
  166. package/dist/simple-tree/core/getOrCreateNode.js +12 -1
  167. package/dist/simple-tree/core/getOrCreateNode.js.map +1 -1
  168. package/dist/simple-tree/core/index.d.ts +2 -2
  169. package/dist/simple-tree/core/index.d.ts.map +1 -1
  170. package/dist/simple-tree/core/index.js +3 -1
  171. package/dist/simple-tree/core/index.js.map +1 -1
  172. package/dist/simple-tree/core/treeNodeKernel.js +2 -2
  173. package/dist/simple-tree/core/treeNodeKernel.js.map +1 -1
  174. package/dist/simple-tree/core/treeNodeSchema.d.ts +68 -1
  175. package/dist/simple-tree/core/treeNodeSchema.d.ts.map +1 -1
  176. package/dist/simple-tree/core/treeNodeSchema.js +24 -1
  177. package/dist/simple-tree/core/treeNodeSchema.js.map +1 -1
  178. package/dist/simple-tree/core/unhydratedFlexTree.d.ts +5 -9
  179. package/dist/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  180. package/dist/simple-tree/core/unhydratedFlexTree.js +12 -31
  181. package/dist/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  182. package/dist/simple-tree/core/walkSchema.d.ts +3 -3
  183. package/dist/simple-tree/core/walkSchema.d.ts.map +1 -1
  184. package/dist/simple-tree/core/walkSchema.js +9 -5
  185. package/dist/simple-tree/core/walkSchema.js.map +1 -1
  186. package/dist/simple-tree/createContext.js +1 -1
  187. package/dist/simple-tree/createContext.js.map +1 -1
  188. package/dist/simple-tree/getTreeNodeForField.d.ts +1 -1
  189. package/dist/simple-tree/getTreeNodeForField.d.ts.map +1 -1
  190. package/dist/simple-tree/getTreeNodeForField.js +3 -3
  191. package/dist/simple-tree/getTreeNodeForField.js.map +1 -1
  192. package/dist/simple-tree/index.d.ts +6 -6
  193. package/dist/simple-tree/index.d.ts.map +1 -1
  194. package/dist/simple-tree/index.js +8 -5
  195. package/dist/simple-tree/index.js.map +1 -1
  196. package/dist/simple-tree/leafNodeSchema.d.ts +4 -1
  197. package/dist/simple-tree/leafNodeSchema.d.ts.map +1 -1
  198. package/dist/simple-tree/leafNodeSchema.js +1 -0
  199. package/dist/simple-tree/leafNodeSchema.js.map +1 -1
  200. package/dist/simple-tree/node-kinds/array/arrayNode.d.ts +3 -1
  201. package/dist/simple-tree/node-kinds/array/arrayNode.d.ts.map +1 -1
  202. package/dist/simple-tree/node-kinds/array/arrayNode.js +21 -16
  203. package/dist/simple-tree/node-kinds/array/arrayNode.js.map +1 -1
  204. package/dist/simple-tree/node-kinds/map/mapNode.d.ts +3 -2
  205. package/dist/simple-tree/node-kinds/map/mapNode.d.ts.map +1 -1
  206. package/dist/simple-tree/node-kinds/map/mapNode.js +11 -5
  207. package/dist/simple-tree/node-kinds/map/mapNode.js.map +1 -1
  208. package/dist/simple-tree/node-kinds/object/objectNode.d.ts +3 -2
  209. package/dist/simple-tree/node-kinds/object/objectNode.d.ts.map +1 -1
  210. package/dist/simple-tree/node-kinds/object/objectNode.js +12 -7
  211. package/dist/simple-tree/node-kinds/object/objectNode.js.map +1 -1
  212. package/dist/simple-tree/prepareForInsertion.d.ts.map +1 -1
  213. package/dist/simple-tree/prepareForInsertion.js +5 -1
  214. package/dist/simple-tree/prepareForInsertion.js.map +1 -1
  215. package/dist/simple-tree/schemaTypes.d.ts +63 -30
  216. package/dist/simple-tree/schemaTypes.d.ts.map +1 -1
  217. package/dist/simple-tree/schemaTypes.js +73 -40
  218. package/dist/simple-tree/schemaTypes.js.map +1 -1
  219. package/dist/simple-tree/simpleSchema.d.ts +22 -4
  220. package/dist/simple-tree/simpleSchema.d.ts.map +1 -1
  221. package/dist/simple-tree/simpleSchema.js.map +1 -1
  222. package/dist/simple-tree/toStoredSchema.d.ts +4 -0
  223. package/dist/simple-tree/toStoredSchema.d.ts.map +1 -1
  224. package/dist/simple-tree/toStoredSchema.js +15 -4
  225. package/dist/simple-tree/toStoredSchema.js.map +1 -1
  226. package/dist/simple-tree/treeNodeValid.d.ts.map +1 -1
  227. package/dist/simple-tree/treeNodeValid.js +1 -2
  228. package/dist/simple-tree/treeNodeValid.js.map +1 -1
  229. package/dist/simple-tree/walkFieldSchema.d.ts.map +1 -1
  230. package/dist/simple-tree/walkFieldSchema.js +1 -1
  231. package/dist/simple-tree/walkFieldSchema.js.map +1 -1
  232. package/dist/tableSchema.d.ts +1 -1
  233. package/dist/util/typeUtils.d.ts +2 -2
  234. package/dist/util/typeUtils.js.map +1 -1
  235. package/dist/util/utils.d.ts +2 -0
  236. package/dist/util/utils.d.ts.map +1 -1
  237. package/dist/util/utils.js.map +1 -1
  238. package/lib/alpha.d.ts +12 -6
  239. package/lib/beta.d.ts +6 -1
  240. package/lib/core/index.d.ts +1 -1
  241. package/lib/core/index.d.ts.map +1 -1
  242. package/lib/core/index.js +1 -1
  243. package/lib/core/index.js.map +1 -1
  244. package/lib/core/schema-stored/formatV2.d.ts +80 -0
  245. package/lib/core/schema-stored/formatV2.d.ts.map +1 -0
  246. package/lib/core/schema-stored/formatV2.js +52 -0
  247. package/lib/core/schema-stored/formatV2.js.map +1 -0
  248. package/lib/core/schema-stored/index.d.ts +3 -1
  249. package/lib/core/schema-stored/index.d.ts.map +1 -1
  250. package/lib/core/schema-stored/index.js +3 -1
  251. package/lib/core/schema-stored/index.js.map +1 -1
  252. package/lib/core/schema-stored/schema.d.ts +49 -17
  253. package/lib/core/schema-stored/schema.d.ts.map +1 -1
  254. package/lib/core/schema-stored/schema.js +63 -21
  255. package/lib/core/schema-stored/schema.js.map +1 -1
  256. package/lib/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.d.ts +9 -7
  257. package/lib/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.d.ts.map +1 -1
  258. package/lib/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.js +11 -7
  259. package/lib/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.js.map +1 -1
  260. package/lib/feature-libraries/chunked-forest/codec/compressedEncode.d.ts +3 -3
  261. package/lib/feature-libraries/chunked-forest/codec/compressedEncode.d.ts.map +1 -1
  262. package/lib/feature-libraries/chunked-forest/codec/compressedEncode.js +7 -7
  263. package/lib/feature-libraries/chunked-forest/codec/compressedEncode.js.map +1 -1
  264. package/lib/feature-libraries/chunked-forest/codec/nodeShape.d.ts +1 -1
  265. package/lib/feature-libraries/chunked-forest/codec/nodeShape.d.ts.map +1 -1
  266. package/lib/feature-libraries/chunked-forest/codec/nodeShape.js +3 -3
  267. package/lib/feature-libraries/chunked-forest/codec/nodeShape.js.map +1 -1
  268. package/lib/feature-libraries/detachedFieldIndexSummarizer.d.ts +8 -3
  269. package/lib/feature-libraries/detachedFieldIndexSummarizer.d.ts.map +1 -1
  270. package/lib/feature-libraries/detachedFieldIndexSummarizer.js +2 -5
  271. package/lib/feature-libraries/detachedFieldIndexSummarizer.js.map +1 -1
  272. package/lib/feature-libraries/flex-tree/flexTreeTypes.d.ts +24 -25
  273. package/lib/feature-libraries/flex-tree/flexTreeTypes.d.ts.map +1 -1
  274. package/lib/feature-libraries/flex-tree/flexTreeTypes.js.map +1 -1
  275. package/lib/feature-libraries/flex-tree/index.d.ts +0 -1
  276. package/lib/feature-libraries/flex-tree/index.d.ts.map +1 -1
  277. package/lib/feature-libraries/flex-tree/index.js +0 -1
  278. package/lib/feature-libraries/flex-tree/index.js.map +1 -1
  279. package/lib/feature-libraries/flex-tree/lazyEntity.d.ts +2 -2
  280. package/lib/feature-libraries/flex-tree/lazyEntity.d.ts.map +1 -1
  281. package/lib/feature-libraries/flex-tree/lazyEntity.js +3 -0
  282. package/lib/feature-libraries/flex-tree/lazyEntity.js.map +1 -1
  283. package/lib/feature-libraries/flex-tree/lazyField.d.ts +1 -2
  284. package/lib/feature-libraries/flex-tree/lazyField.d.ts.map +1 -1
  285. package/lib/feature-libraries/flex-tree/lazyField.js +3 -6
  286. package/lib/feature-libraries/flex-tree/lazyField.js.map +1 -1
  287. package/lib/feature-libraries/flex-tree/lazyNode.d.ts +5 -5
  288. package/lib/feature-libraries/flex-tree/lazyNode.d.ts.map +1 -1
  289. package/lib/feature-libraries/flex-tree/lazyNode.js +15 -7
  290. package/lib/feature-libraries/flex-tree/lazyNode.js.map +1 -1
  291. package/lib/feature-libraries/forest-summary/forestSummarizer.d.ts +8 -3
  292. package/lib/feature-libraries/forest-summary/forestSummarizer.d.ts.map +1 -1
  293. package/lib/feature-libraries/forest-summary/forestSummarizer.js +2 -5
  294. package/lib/feature-libraries/forest-summary/forestSummarizer.js.map +1 -1
  295. package/lib/feature-libraries/index.d.ts +2 -2
  296. package/lib/feature-libraries/index.d.ts.map +1 -1
  297. package/lib/feature-libraries/index.js +1 -1
  298. package/lib/feature-libraries/index.js.map +1 -1
  299. package/lib/feature-libraries/mapTreeCursor.d.ts +16 -2
  300. package/lib/feature-libraries/mapTreeCursor.d.ts.map +1 -1
  301. package/lib/feature-libraries/mapTreeCursor.js.map +1 -1
  302. package/lib/feature-libraries/modular-schema/fieldKindWithEditor.d.ts.map +1 -1
  303. package/lib/feature-libraries/modular-schema/fieldKindWithEditor.js +2 -0
  304. package/lib/feature-libraries/modular-schema/fieldKindWithEditor.js.map +1 -1
  305. package/lib/feature-libraries/object-forest/objectForest.d.ts.map +1 -1
  306. package/lib/feature-libraries/object-forest/objectForest.js +2 -0
  307. package/lib/feature-libraries/object-forest/objectForest.js.map +1 -1
  308. package/lib/feature-libraries/schema-edits/schemaChangeCodecs.d.ts.map +1 -1
  309. package/lib/feature-libraries/schema-edits/schemaChangeCodecs.js +8 -4
  310. package/lib/feature-libraries/schema-edits/schemaChangeCodecs.js.map +1 -1
  311. package/lib/feature-libraries/schema-edits/schemaChangeFormat.d.ts +2 -36
  312. package/lib/feature-libraries/schema-edits/schemaChangeFormat.d.ts.map +1 -1
  313. package/lib/feature-libraries/schema-edits/schemaChangeFormat.js +3 -3
  314. package/lib/feature-libraries/schema-edits/schemaChangeFormat.js.map +1 -1
  315. package/lib/feature-libraries/schema-index/codec.d.ts.map +1 -1
  316. package/lib/feature-libraries/schema-index/codec.js +60 -10
  317. package/lib/feature-libraries/schema-index/codec.js.map +1 -1
  318. package/lib/feature-libraries/schema-index/formatV1.d.ts +1 -1
  319. package/lib/feature-libraries/schema-index/formatV2.d.ts +42 -0
  320. package/lib/feature-libraries/schema-index/formatV2.d.ts.map +1 -0
  321. package/lib/feature-libraries/schema-index/formatV2.js +23 -0
  322. package/lib/feature-libraries/schema-index/formatV2.js.map +1 -0
  323. package/lib/feature-libraries/schema-index/index.d.ts +2 -1
  324. package/lib/feature-libraries/schema-index/index.d.ts.map +1 -1
  325. package/lib/feature-libraries/schema-index/index.js +2 -1
  326. package/lib/feature-libraries/schema-index/index.js.map +1 -1
  327. package/lib/feature-libraries/schema-index/schemaSummarizer.d.ts +7 -2
  328. package/lib/feature-libraries/schema-index/schemaSummarizer.d.ts.map +1 -1
  329. package/lib/feature-libraries/schema-index/schemaSummarizer.js +6 -6
  330. package/lib/feature-libraries/schema-index/schemaSummarizer.js.map +1 -1
  331. package/lib/index.d.ts +2 -2
  332. package/lib/index.d.ts.map +1 -1
  333. package/lib/index.js.map +1 -1
  334. package/lib/packageVersion.d.ts +1 -1
  335. package/lib/packageVersion.js +1 -1
  336. package/lib/packageVersion.js.map +1 -1
  337. package/lib/shared-tree/schematizeTree.d.ts.map +1 -1
  338. package/lib/shared-tree/schematizeTree.js +1 -0
  339. package/lib/shared-tree/schematizeTree.js.map +1 -1
  340. package/lib/shared-tree/schematizingTreeView.d.ts.map +1 -1
  341. package/lib/shared-tree/schematizingTreeView.js +4 -4
  342. package/lib/shared-tree/schematizingTreeView.js.map +1 -1
  343. package/lib/shared-tree/sharedTree.d.ts +5 -1
  344. package/lib/shared-tree/sharedTree.d.ts.map +1 -1
  345. package/lib/shared-tree/sharedTree.js +34 -5
  346. package/lib/shared-tree/sharedTree.js.map +1 -1
  347. package/lib/shared-tree/treeAlpha.d.ts +39 -1
  348. package/lib/shared-tree/treeAlpha.d.ts.map +1 -1
  349. package/lib/shared-tree/treeAlpha.js +111 -5
  350. package/lib/shared-tree/treeAlpha.js.map +1 -1
  351. package/lib/shared-tree-core/editManagerSummarizer.d.ts +8 -3
  352. package/lib/shared-tree-core/editManagerSummarizer.d.ts.map +1 -1
  353. package/lib/shared-tree-core/editManagerSummarizer.js +2 -5
  354. package/lib/shared-tree-core/editManagerSummarizer.js.map +1 -1
  355. package/lib/shared-tree-core/sharedTreeCore.d.ts +18 -7
  356. package/lib/shared-tree-core/sharedTreeCore.d.ts.map +1 -1
  357. package/lib/shared-tree-core/sharedTreeCore.js +15 -2
  358. package/lib/shared-tree-core/sharedTreeCore.js.map +1 -1
  359. package/lib/simple-tree/api/configuration.d.ts +15 -3
  360. package/lib/simple-tree/api/configuration.d.ts.map +1 -1
  361. package/lib/simple-tree/api/configuration.js +42 -24
  362. package/lib/simple-tree/api/configuration.js.map +1 -1
  363. package/lib/simple-tree/api/index.d.ts +1 -1
  364. package/lib/simple-tree/api/index.d.ts.map +1 -1
  365. package/lib/simple-tree/api/index.js +1 -1
  366. package/lib/simple-tree/api/index.js.map +1 -1
  367. package/lib/simple-tree/api/schemaCompatibilityTester.js +1 -1
  368. package/lib/simple-tree/api/schemaCompatibilityTester.js.map +1 -1
  369. package/lib/simple-tree/api/schemaCreationUtilities.d.ts +3 -3
  370. package/lib/simple-tree/api/schemaCreationUtilities.js +3 -3
  371. package/lib/simple-tree/api/schemaCreationUtilities.js.map +1 -1
  372. package/lib/simple-tree/api/schemaFactory.d.ts +15 -11
  373. package/lib/simple-tree/api/schemaFactory.d.ts.map +1 -1
  374. package/lib/simple-tree/api/schemaFactory.js +4 -0
  375. package/lib/simple-tree/api/schemaFactory.js.map +1 -1
  376. package/lib/simple-tree/api/schemaFactoryAlpha.d.ts +41 -11
  377. package/lib/simple-tree/api/schemaFactoryAlpha.d.ts.map +1 -1
  378. package/lib/simple-tree/api/schemaFactoryAlpha.js +31 -4
  379. package/lib/simple-tree/api/schemaFactoryAlpha.js.map +1 -1
  380. package/lib/simple-tree/api/storedSchema.js +2 -2
  381. package/lib/simple-tree/api/storedSchema.js.map +1 -1
  382. package/lib/simple-tree/api/treeChangeEvents.d.ts +8 -3
  383. package/lib/simple-tree/api/treeChangeEvents.d.ts.map +1 -1
  384. package/lib/simple-tree/api/treeChangeEvents.js.map +1 -1
  385. package/lib/simple-tree/api/treeNodeApi.d.ts +3 -0
  386. package/lib/simple-tree/api/treeNodeApi.d.ts.map +1 -1
  387. package/lib/simple-tree/api/treeNodeApi.js +2 -2
  388. package/lib/simple-tree/api/treeNodeApi.js.map +1 -1
  389. package/lib/simple-tree/api/viewSchemaToSimpleSchema.d.ts.map +1 -1
  390. package/lib/simple-tree/api/viewSchemaToSimpleSchema.js +5 -0
  391. package/lib/simple-tree/api/viewSchemaToSimpleSchema.js.map +1 -1
  392. package/lib/simple-tree/core/context.d.ts +3 -3
  393. package/lib/simple-tree/core/context.d.ts.map +1 -1
  394. package/lib/simple-tree/core/context.js.map +1 -1
  395. package/lib/simple-tree/core/getOrCreateNode.d.ts +9 -0
  396. package/lib/simple-tree/core/getOrCreateNode.d.ts.map +1 -1
  397. package/lib/simple-tree/core/getOrCreateNode.js +10 -0
  398. package/lib/simple-tree/core/getOrCreateNode.js.map +1 -1
  399. package/lib/simple-tree/core/index.d.ts +2 -2
  400. package/lib/simple-tree/core/index.d.ts.map +1 -1
  401. package/lib/simple-tree/core/index.js +2 -2
  402. package/lib/simple-tree/core/index.js.map +1 -1
  403. package/lib/simple-tree/core/treeNodeKernel.js +2 -2
  404. package/lib/simple-tree/core/treeNodeKernel.js.map +1 -1
  405. package/lib/simple-tree/core/treeNodeSchema.d.ts +68 -1
  406. package/lib/simple-tree/core/treeNodeSchema.d.ts.map +1 -1
  407. package/lib/simple-tree/core/treeNodeSchema.js +21 -0
  408. package/lib/simple-tree/core/treeNodeSchema.js.map +1 -1
  409. package/lib/simple-tree/core/unhydratedFlexTree.d.ts +5 -9
  410. package/lib/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  411. package/lib/simple-tree/core/unhydratedFlexTree.js +15 -34
  412. package/lib/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  413. package/lib/simple-tree/core/walkSchema.d.ts +3 -3
  414. package/lib/simple-tree/core/walkSchema.d.ts.map +1 -1
  415. package/lib/simple-tree/core/walkSchema.js +9 -5
  416. package/lib/simple-tree/core/walkSchema.js.map +1 -1
  417. package/lib/simple-tree/createContext.js +1 -1
  418. package/lib/simple-tree/createContext.js.map +1 -1
  419. package/lib/simple-tree/getTreeNodeForField.d.ts +1 -1
  420. package/lib/simple-tree/getTreeNodeForField.d.ts.map +1 -1
  421. package/lib/simple-tree/getTreeNodeForField.js +1 -1
  422. package/lib/simple-tree/getTreeNodeForField.js.map +1 -1
  423. package/lib/simple-tree/index.d.ts +6 -6
  424. package/lib/simple-tree/index.d.ts.map +1 -1
  425. package/lib/simple-tree/index.js +4 -4
  426. package/lib/simple-tree/index.js.map +1 -1
  427. package/lib/simple-tree/leafNodeSchema.d.ts +4 -1
  428. package/lib/simple-tree/leafNodeSchema.d.ts.map +1 -1
  429. package/lib/simple-tree/leafNodeSchema.js +2 -1
  430. package/lib/simple-tree/leafNodeSchema.js.map +1 -1
  431. package/lib/simple-tree/node-kinds/array/arrayNode.d.ts +3 -1
  432. package/lib/simple-tree/node-kinds/array/arrayNode.d.ts.map +1 -1
  433. package/lib/simple-tree/node-kinds/array/arrayNode.js +13 -8
  434. package/lib/simple-tree/node-kinds/array/arrayNode.js.map +1 -1
  435. package/lib/simple-tree/node-kinds/map/mapNode.d.ts +3 -2
  436. package/lib/simple-tree/node-kinds/map/mapNode.d.ts.map +1 -1
  437. package/lib/simple-tree/node-kinds/map/mapNode.js +14 -8
  438. package/lib/simple-tree/node-kinds/map/mapNode.js.map +1 -1
  439. package/lib/simple-tree/node-kinds/object/objectNode.d.ts +3 -2
  440. package/lib/simple-tree/node-kinds/object/objectNode.d.ts.map +1 -1
  441. package/lib/simple-tree/node-kinds/object/objectNode.js +14 -9
  442. package/lib/simple-tree/node-kinds/object/objectNode.js.map +1 -1
  443. package/lib/simple-tree/prepareForInsertion.d.ts.map +1 -1
  444. package/lib/simple-tree/prepareForInsertion.js +5 -1
  445. package/lib/simple-tree/prepareForInsertion.js.map +1 -1
  446. package/lib/simple-tree/schemaTypes.d.ts +63 -30
  447. package/lib/simple-tree/schemaTypes.d.ts.map +1 -1
  448. package/lib/simple-tree/schemaTypes.js +70 -36
  449. package/lib/simple-tree/schemaTypes.js.map +1 -1
  450. package/lib/simple-tree/simpleSchema.d.ts +22 -4
  451. package/lib/simple-tree/simpleSchema.d.ts.map +1 -1
  452. package/lib/simple-tree/simpleSchema.js.map +1 -1
  453. package/lib/simple-tree/toStoredSchema.d.ts +4 -0
  454. package/lib/simple-tree/toStoredSchema.d.ts.map +1 -1
  455. package/lib/simple-tree/toStoredSchema.js +15 -4
  456. package/lib/simple-tree/toStoredSchema.js.map +1 -1
  457. package/lib/simple-tree/treeNodeValid.d.ts.map +1 -1
  458. package/lib/simple-tree/treeNodeValid.js +1 -2
  459. package/lib/simple-tree/treeNodeValid.js.map +1 -1
  460. package/lib/simple-tree/walkFieldSchema.d.ts.map +1 -1
  461. package/lib/simple-tree/walkFieldSchema.js +1 -1
  462. package/lib/simple-tree/walkFieldSchema.js.map +1 -1
  463. package/lib/tableSchema.d.ts +1 -1
  464. package/lib/util/typeUtils.d.ts +2 -2
  465. package/lib/util/typeUtils.js.map +1 -1
  466. package/lib/util/utils.d.ts +2 -0
  467. package/lib/util/utils.d.ts.map +1 -1
  468. package/lib/util/utils.js.map +1 -1
  469. package/package.json +23 -23
  470. package/src/core/index.ts +3 -1
  471. package/src/core/schema-stored/formatV2.ts +78 -0
  472. package/src/core/schema-stored/index.ts +4 -1
  473. package/src/core/schema-stored/schema.ts +123 -33
  474. package/src/feature-libraries/chunked-forest/codec/chunkEncodingGeneric.ts +16 -11
  475. package/src/feature-libraries/chunked-forest/codec/compressedEncode.ts +16 -7
  476. package/src/feature-libraries/chunked-forest/codec/nodeShape.ts +4 -4
  477. package/src/feature-libraries/detachedFieldIndexSummarizer.ts +9 -16
  478. package/src/feature-libraries/flex-tree/flexTreeTypes.ts +33 -30
  479. package/src/feature-libraries/flex-tree/index.ts +0 -8
  480. package/src/feature-libraries/flex-tree/lazyEntity.ts +5 -1
  481. package/src/feature-libraries/flex-tree/lazyField.ts +5 -8
  482. package/src/feature-libraries/flex-tree/lazyNode.ts +17 -8
  483. package/src/feature-libraries/forest-summary/forestSummarizer.ts +9 -16
  484. package/src/feature-libraries/index.ts +1 -1
  485. package/src/feature-libraries/mapTreeCursor.ts +17 -8
  486. package/src/feature-libraries/modular-schema/fieldKindWithEditor.ts +2 -0
  487. package/src/feature-libraries/object-forest/objectForest.ts +3 -0
  488. package/src/feature-libraries/schema-edits/schemaChangeCodecs.ts +11 -6
  489. package/src/feature-libraries/schema-edits/schemaChangeFormat.ts +3 -3
  490. package/src/feature-libraries/schema-index/codec.ts +73 -14
  491. package/src/feature-libraries/schema-index/formatV2.ts +30 -0
  492. package/src/feature-libraries/schema-index/index.ts +2 -1
  493. package/src/feature-libraries/schema-index/schemaSummarizer.ts +11 -18
  494. package/src/index.ts +6 -0
  495. package/src/packageVersion.ts +1 -1
  496. package/src/shared-tree/schematizeTree.ts +1 -0
  497. package/src/shared-tree/schematizingTreeView.ts +8 -5
  498. package/src/shared-tree/sharedTree.ts +42 -12
  499. package/src/shared-tree/treeAlpha.ts +196 -6
  500. package/src/shared-tree-core/editManagerSummarizer.ts +9 -16
  501. package/src/shared-tree-core/sharedTreeCore.ts +33 -24
  502. package/src/simple-tree/api/configuration.ts +59 -27
  503. package/src/simple-tree/api/index.ts +3 -3
  504. package/src/simple-tree/api/schemaCompatibilityTester.ts +1 -1
  505. package/src/simple-tree/api/schemaCreationUtilities.ts +3 -3
  506. package/src/simple-tree/api/schemaFactory.ts +16 -11
  507. package/src/simple-tree/api/schemaFactoryAlpha.ts +53 -8
  508. package/src/simple-tree/api/storedSchema.ts +4 -4
  509. package/src/simple-tree/api/treeChangeEvents.ts +8 -3
  510. package/src/simple-tree/api/treeNodeApi.ts +5 -2
  511. package/src/simple-tree/api/viewSchemaToSimpleSchema.ts +5 -0
  512. package/src/simple-tree/core/context.ts +3 -3
  513. package/src/simple-tree/core/getOrCreateNode.ts +14 -0
  514. package/src/simple-tree/core/index.ts +7 -1
  515. package/src/simple-tree/core/treeNodeKernel.ts +2 -2
  516. package/src/simple-tree/core/treeNodeSchema.ts +113 -1
  517. package/src/simple-tree/core/unhydratedFlexTree.ts +22 -44
  518. package/src/simple-tree/core/walkSchema.ts +16 -7
  519. package/src/simple-tree/createContext.ts +1 -1
  520. package/src/simple-tree/getTreeNodeForField.ts +3 -1
  521. package/src/simple-tree/index.ts +12 -5
  522. package/src/simple-tree/leafNodeSchema.ts +9 -1
  523. package/src/simple-tree/node-kinds/array/arrayNode.ts +20 -9
  524. package/src/simple-tree/node-kinds/map/mapNode.ts +21 -6
  525. package/src/simple-tree/node-kinds/object/objectNode.ts +29 -12
  526. package/src/simple-tree/prepareForInsertion.ts +5 -1
  527. package/src/simple-tree/schemaTypes.ts +151 -71
  528. package/src/simple-tree/simpleSchema.ts +27 -5
  529. package/src/simple-tree/toStoredSchema.ts +17 -4
  530. package/src/simple-tree/treeNodeValid.ts +1 -1
  531. package/src/simple-tree/walkFieldSchema.ts +5 -1
  532. package/src/util/typeUtils.ts +2 -2
  533. package/src/util/utils.ts +2 -0
  534. package/dist/feature-libraries/flex-tree/navigation.d.ts +0 -46
  535. package/dist/feature-libraries/flex-tree/navigation.d.ts.map +0 -1
  536. package/dist/feature-libraries/flex-tree/navigation.js +0 -104
  537. package/dist/feature-libraries/flex-tree/navigation.js.map +0 -1
  538. package/lib/feature-libraries/flex-tree/navigation.d.ts +0 -46
  539. package/lib/feature-libraries/flex-tree/navigation.d.ts.map +0 -1
  540. package/lib/feature-libraries/flex-tree/navigation.js +0 -97
  541. package/lib/feature-libraries/flex-tree/navigation.js.map +0 -1
  542. package/src/feature-libraries/flex-tree/navigation.ts +0 -121
@@ -2,12 +2,12 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- export { typeNameSymbol, typeSchemaSymbol, type WithType, type TreeNodeSchema, NodeKind, type TreeNodeSchemaClass, type TreeNodeSchemaNonClass, type TreeNodeSchemaCore, type TreeNode, type Unhydrated, type InternalTreeNode, isTreeNode, tryDisposeTreeNode, HydratedContext, SimpleContextSlot, getOrCreateInnerNode, getOrCreateNodeFromInnerNode, getKernel, } from "./core/index.js";
6
- export { type ITree, type TreeView, type ViewableTree, type TreeViewEvents, TreeViewConfiguration, TreeViewConfigurationAlpha, type ITreeViewConfiguration, type SchemaCompatibilityStatus, type ITreeConfigurationOptions, SchemaFactory, SchemaFactoryAlpha, type SchemaFactoryObjectOptions, type ScopedSchemaName, type ValidateRecursiveSchema, type FixRecursiveArraySchema, adaptEnum, enumFromStrings, singletonSchema, treeNodeApi, type TreeNodeApi, type NodeChangedData, TreeBeta, type TreeChangeEventsBeta, type SimpleTreeIndex, type IdentifierIndex, createSimpleTreeIndex, createIdentifierIndex, type JsonSchemaId, type JsonSchemaType, type JsonObjectNodeSchema, type JsonArrayNodeSchema, type JsonMapNodeSchema, type JsonLeafNodeSchema, type JsonSchemaRef, type JsonRefPath, type JsonNodeSchema, type JsonNodeSchemaBase, type JsonTreeSchema, type JsonFieldSchema, type JsonLeafSchemaType, type TreeSchemaEncodingOptions, getJsonSchema, getSimpleSchema, type VerboseTreeNode, type TreeEncodingOptions, type VerboseTree, extractPersistedSchema, comparePersistedSchema, type ConciseTree, SchemaCompatibilityTester, type Unenforced, type System_Unsafe, type ArrayNodeCustomizableSchemaUnsafe, type MapNodeCustomizableSchemaUnsafe, type TreeViewAlpha, type TreeBranch, type TreeBranchEvents, tryGetSchema, getStoredKey, getPropertyKeyFromStoredKey, applySchemaToParserOptions, cursorFromVerbose, verboseFromCursor, conciseFromCursor, createFromCursor, asTreeViewAlpha, customFromCursorStored, type CustomTreeNode, type CustomTreeValue, tryStoredSchemaAsArray, type SchemaStatics, type ITreeAlpha, type TransactionConstraint, type NodeInDocumentConstraint, type RunTransactionParams, type VoidTransactionCallbackStatus, type TransactionCallbackStatus, type TransactionResult, type TransactionResultExt, type TransactionResultSuccess, type TransactionResultFailed, rollback, generateSchemaFromSimpleSchema, replaceConciseTreeHandles, replaceHandles, replaceVerboseTreeHandles, type HandleConverter, allowUnused, type FieldSchemaAlphaUnsafe, getIdentifierFromNode, type TreeSchema, type ValidateRecursiveSchemaTemplate, type FixRecursiveRecursionLimit, schemaStatics, type TreeChangeEvents, } from "./api/index.js";
7
- export type { SimpleTreeSchema, SimpleNodeSchema, SimpleFieldSchema, SimpleLeafNodeSchema, SimpleMapNodeSchema, SimpleArrayNodeSchema, SimpleObjectNodeSchema, SimpleNodeSchemaBase, SimpleObjectFieldSchema, } from "./simpleSchema.js";
8
- export { type NodeFromSchema, isTreeNodeSchemaClass, type AnnotatedAllowedType, type AnnotatedAllowedTypes, type ImplicitFieldSchema, type ImplicitAnnotatedFieldSchema, type TreeFieldFromImplicitField, type ImplicitAllowedTypes, type ImplicitAnnotatedAllowedTypes, type UnannotateImplicitAllowedTypes, type UnannotateAllowedTypes, type UnannotateAllowedType, type UnannotateAllowedTypesList, type UnannotateAllowedTypeOrLazyItem, type UnannotateImplicitFieldSchema, type UnannotateSchemaRecord, type TreeNodeFromImplicitAllowedTypes, type InsertableTreeNodeFromImplicitAllowedTypes, type TreeLeafValue, type AllowedTypes, type AllowedTypeMetadata, type AllowedTypesMetadata, FieldKind, FieldSchema, type FieldSchemaAlpha, type InsertableTreeFieldFromImplicitField, type InsertableTypedNode, type NodeBuilderData, type DefaultProvider, type FieldProps, normalizeFieldSchema, areFieldSchemaEqual, areImplicitFieldSchemaEqual, type ApplyKind, type FieldSchemaMetadata, type InsertableField, type Insertable, type UnsafeUnknownSchema, normalizeAllowedTypes, type ApplyKindInput, type InsertableTreeNodeFromAllowedTypes, type Input, type ReadableField, type ReadSchema, type NodeSchemaOptions, type NodeSchemaMetadata, evaluateLazySchema, } from "./schemaTypes.js";
9
- export { getTreeNodeForField } from "./getTreeNodeForField.js";
10
- export { type ArrayNodeCustomizableSchema, type ArrayNodePojoEmulationSchema, ArrayNodeSchema, isArrayNodeSchema, IterableTreeArrayContent, type ReadonlyArrayNode, TreeArrayNode, type MapNodeCustomizableSchema, type MapNodePojoEmulationSchema, MapNodeSchema, isMapNodeSchema, type TreeMapNode, type MapNodeInsertableData, type FieldHasDefault, type InsertableObjectFromSchemaRecord, type ObjectFromSchemaRecord, ObjectNodeSchema, type InsertableObjectFromAnnotatedSchemaRecord, type TreeObjectNode, setField, createUnknownOptionalFieldPolicy, } from "./node-kinds/index.js";
5
+ export { typeNameSymbol, typeSchemaSymbol, type WithType, type TreeNodeSchema, type AnnotatedAllowedType, type NormalizedAnnotatedAllowedTypes, NodeKind, type TreeNodeSchemaClass, type TreeNodeSchemaNonClass, type TreeNodeSchemaCore, type TreeNode, type Unhydrated, type InternalTreeNode, isTreeNode, tryDisposeTreeNode, HydratedContext, SimpleContextSlot, getOrCreateInnerNode, getOrCreateNodeFromInnerNode, getOrCreateNodeFromInnerUnboxedNode, getKernel, } from "./core/index.js";
6
+ export { type ITree, type TreeView, type ViewableTree, type TreeViewEvents, TreeViewConfiguration, TreeViewConfigurationAlpha, type ITreeViewConfiguration, type SchemaCompatibilityStatus, type ITreeConfigurationOptions, SchemaFactory, SchemaFactoryAlpha, type SchemaFactoryObjectOptions, type ScopedSchemaName, type ValidateRecursiveSchema, type FixRecursiveArraySchema, adaptEnum, enumFromStrings, singletonSchema, treeNodeApi, type TreeNodeApi, type NodeChangedData, TreeBeta, type TreeChangeEventsBeta, type SimpleTreeIndex, type IdentifierIndex, createSimpleTreeIndex, createIdentifierIndex, type JsonSchemaId, type JsonSchemaType, type JsonObjectNodeSchema, type JsonArrayNodeSchema, type JsonMapNodeSchema, type JsonLeafNodeSchema, type JsonSchemaRef, type JsonRefPath, type JsonNodeSchema, type JsonNodeSchemaBase, type JsonTreeSchema, type JsonFieldSchema, type JsonLeafSchemaType, type TreeSchemaEncodingOptions, getJsonSchema, getSimpleSchema, type VerboseTreeNode, type TreeEncodingOptions, type VerboseTree, extractPersistedSchema, comparePersistedSchema, type ConciseTree, SchemaCompatibilityTester, type Unenforced, type System_Unsafe, type ArrayNodeCustomizableSchemaUnsafe, type MapNodeCustomizableSchemaUnsafe, type TreeViewAlpha, type TreeBranch, type TreeBranchEvents, getPropertyKeyFromStoredKey, getStoredKey, tryGetSchema, applySchemaToParserOptions, cursorFromVerbose, verboseFromCursor, conciseFromCursor, createFromCursor, asTreeViewAlpha, customFromCursorStored, type CustomTreeNode, type CustomTreeValue, tryStoredSchemaAsArray, type SchemaStatics, type ITreeAlpha, type TransactionConstraint, type NodeInDocumentConstraint, type RunTransactionParams, type VoidTransactionCallbackStatus, type TransactionCallbackStatus, type TransactionResult, type TransactionResultExt, type TransactionResultSuccess, type TransactionResultFailed, rollback, generateSchemaFromSimpleSchema, replaceConciseTreeHandles, replaceHandles, replaceVerboseTreeHandles, type HandleConverter, allowUnused, type FieldSchemaAlphaUnsafe, getIdentifierFromNode, type TreeSchema, type ValidateRecursiveSchemaTemplate, type FixRecursiveRecursionLimit, schemaStatics, type TreeChangeEvents, } from "./api/index.js";
7
+ export type { SimpleTreeSchema, SimpleNodeSchema, SimpleFieldSchema, SimpleLeafNodeSchema, SimpleMapNodeSchema, SimpleArrayNodeSchema, SimpleObjectNodeSchema, SimpleNodeSchemaBase, SimpleNodeSchemaBaseAlpha, SimpleObjectFieldSchema, } from "./simpleSchema.js";
8
+ export { type NodeFromSchema, isTreeNodeSchemaClass, type ImplicitFieldSchema, type ImplicitAnnotatedFieldSchema, type TreeFieldFromImplicitField, type ImplicitAllowedTypes, type ImplicitAnnotatedAllowedTypes, type UnannotateImplicitAllowedTypes, type UnannotateAllowedTypes, type UnannotateAllowedType, type UnannotateAllowedTypesList, type UnannotateAllowedTypeOrLazyItem, type UnannotateImplicitFieldSchema, type UnannotateSchemaRecord, type TreeNodeFromImplicitAllowedTypes, type InsertableTreeNodeFromImplicitAllowedTypes, type TreeLeafValue, type AllowedTypes, type AllowedTypeMetadata, type AllowedTypesMetadata, type AnnotatedAllowedTypes, FieldKind, FieldSchema, type FieldSchemaAlpha, type InsertableTreeFieldFromImplicitField, type InsertableTypedNode, type NodeBuilderData, type DefaultProvider, type FieldProps, type FieldPropsAlpha, normalizeFieldSchema, areFieldSchemaEqual, areImplicitFieldSchemaEqual, type ApplyKind, type FieldSchemaMetadata, type InsertableField, type Insertable, type UnsafeUnknownSchema, normalizeAllowedTypes, type ApplyKindInput, type InsertableTreeNodeFromAllowedTypes, type Input, type ReadableField, type ReadSchema, type NodeSchemaOptions, type NodeSchemaOptionsAlpha, type NodeSchemaMetadata, evaluateLazySchema, } from "./schemaTypes.js";
9
+ export { tryGetTreeNodeForField } from "./getTreeNodeForField.js";
10
+ export { type ArrayNodeCustomizableSchema, type ArrayNodePojoEmulationSchema, ArrayNodeSchema, asIndex, isArrayNodeSchema, IterableTreeArrayContent, type ReadonlyArrayNode, TreeArrayNode, type MapNodeCustomizableSchema, type MapNodePojoEmulationSchema, MapNodeSchema, isMapNodeSchema, type TreeMapNode, type MapNodeInsertableData, type FieldHasDefault, type InsertableObjectFromSchemaRecord, type ObjectFromSchemaRecord, ObjectNodeSchema, isObjectNodeSchema, type InsertableObjectFromAnnotatedSchemaRecord, type TreeObjectNode, setField, createUnknownOptionalFieldPolicy, } from "./node-kinds/index.js";
11
11
  export { unhydratedFlexTreeFromInsertable, type InsertableContent, type FactoryContent, type FactoryContentObject, } from "./unhydratedFlexTreeFromInsertable.js";
12
12
  export { prepareForInsertion, prepareForInsertionContextless, } from "./prepareForInsertion.js";
13
13
  export { toStoredSchema, getStoredSchema } from "./toStoredSchema.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/simple-tree/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,cAAc,EACd,gBAAgB,EAChB,KAAK,QAAQ,EACb,KAAK,cAAc,EACnB,QAAQ,EACR,KAAK,mBAAmB,EACxB,KAAK,sBAAsB,EAC3B,KAAK,kBAAkB,EAGvB,KAAK,QAAQ,EACb,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,UAAU,EACV,kBAAkB,EAClB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,SAAS,GACT,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACN,KAAK,KAAK,EACV,KAAK,QAAQ,EACb,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,qBAAqB,EACrB,0BAA0B,EAC1B,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EAC9B,aAAa,EACb,kBAAkB,EAClB,KAAK,0BAA0B,EAC/B,KAAK,gBAAgB,EACrB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,SAAS,EACT,eAAe,EACf,eAAe,EACf,WAAW,EACX,KAAK,WAAW,EAChB,KAAK,eAAe,EACpB,QAAQ,EACR,KAAK,oBAAoB,EACzB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AACtD,YAAY,EAAE,QAAQ,EAAE,QAAQ,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC"}
@@ -4,8 +4,8 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.areFieldSchemaEqual = exports.normalizeFieldSchema = exports.FieldSchema = exports.FieldKind = exports.isTreeNodeSchemaClass = exports.schemaStatics = exports.getIdentifierFromNode = exports.allowUnused = exports.replaceVerboseTreeHandles = exports.replaceHandles = exports.replaceConciseTreeHandles = exports.generateSchemaFromSimpleSchema = exports.rollback = exports.tryStoredSchemaAsArray = exports.customFromCursorStored = exports.asTreeViewAlpha = exports.createFromCursor = exports.conciseFromCursor = exports.verboseFromCursor = exports.cursorFromVerbose = exports.applySchemaToParserOptions = exports.getPropertyKeyFromStoredKey = exports.getStoredKey = exports.tryGetSchema = exports.SchemaCompatibilityTester = exports.comparePersistedSchema = exports.extractPersistedSchema = exports.getSimpleSchema = exports.getJsonSchema = exports.createIdentifierIndex = exports.createSimpleTreeIndex = exports.TreeBeta = exports.treeNodeApi = exports.singletonSchema = exports.enumFromStrings = exports.adaptEnum = exports.SchemaFactoryAlpha = exports.SchemaFactory = exports.TreeViewConfigurationAlpha = exports.TreeViewConfiguration = exports.getKernel = exports.getOrCreateNodeFromInnerNode = exports.getOrCreateInnerNode = exports.SimpleContextSlot = exports.HydratedContext = exports.tryDisposeTreeNode = exports.isTreeNode = exports.NodeKind = exports.typeSchemaSymbol = exports.typeNameSymbol = void 0;
8
- exports.nullSchema = exports.handleSchema = exports.booleanSchema = exports.stringSchema = exports.numberSchema = exports.getStoredSchema = exports.toStoredSchema = exports.prepareForInsertionContextless = exports.prepareForInsertion = exports.unhydratedFlexTreeFromInsertable = exports.createUnknownOptionalFieldPolicy = exports.setField = exports.ObjectNodeSchema = exports.isMapNodeSchema = exports.MapNodeSchema = exports.TreeArrayNode = exports.IterableTreeArrayContent = exports.isArrayNodeSchema = exports.ArrayNodeSchema = exports.getTreeNodeForField = exports.evaluateLazySchema = exports.normalizeAllowedTypes = exports.areImplicitFieldSchemaEqual = void 0;
7
+ exports.normalizeFieldSchema = exports.FieldSchema = exports.FieldKind = exports.isTreeNodeSchemaClass = exports.schemaStatics = exports.getIdentifierFromNode = exports.allowUnused = exports.replaceVerboseTreeHandles = exports.replaceHandles = exports.replaceConciseTreeHandles = exports.generateSchemaFromSimpleSchema = exports.rollback = exports.tryStoredSchemaAsArray = exports.customFromCursorStored = exports.asTreeViewAlpha = exports.createFromCursor = exports.conciseFromCursor = exports.verboseFromCursor = exports.cursorFromVerbose = exports.applySchemaToParserOptions = exports.tryGetSchema = exports.getStoredKey = exports.getPropertyKeyFromStoredKey = exports.SchemaCompatibilityTester = exports.comparePersistedSchema = exports.extractPersistedSchema = exports.getSimpleSchema = exports.getJsonSchema = exports.createIdentifierIndex = exports.createSimpleTreeIndex = exports.TreeBeta = exports.treeNodeApi = exports.singletonSchema = exports.enumFromStrings = exports.adaptEnum = exports.SchemaFactoryAlpha = exports.SchemaFactory = exports.TreeViewConfigurationAlpha = exports.TreeViewConfiguration = exports.getKernel = exports.getOrCreateNodeFromInnerUnboxedNode = exports.getOrCreateNodeFromInnerNode = exports.getOrCreateInnerNode = exports.SimpleContextSlot = exports.HydratedContext = exports.tryDisposeTreeNode = exports.isTreeNode = exports.NodeKind = exports.typeSchemaSymbol = exports.typeNameSymbol = void 0;
8
+ exports.nullSchema = exports.handleSchema = exports.booleanSchema = exports.stringSchema = exports.numberSchema = exports.getStoredSchema = exports.toStoredSchema = exports.prepareForInsertionContextless = exports.prepareForInsertion = exports.unhydratedFlexTreeFromInsertable = exports.createUnknownOptionalFieldPolicy = exports.setField = exports.isObjectNodeSchema = exports.ObjectNodeSchema = exports.isMapNodeSchema = exports.MapNodeSchema = exports.TreeArrayNode = exports.IterableTreeArrayContent = exports.isArrayNodeSchema = exports.asIndex = exports.ArrayNodeSchema = exports.tryGetTreeNodeForField = exports.evaluateLazySchema = exports.normalizeAllowedTypes = exports.areImplicitFieldSchemaEqual = exports.areFieldSchemaEqual = void 0;
9
9
  var index_js_1 = require("./core/index.js");
10
10
  Object.defineProperty(exports, "typeNameSymbol", { enumerable: true, get: function () { return index_js_1.typeNameSymbol; } });
11
11
  Object.defineProperty(exports, "typeSchemaSymbol", { enumerable: true, get: function () { return index_js_1.typeSchemaSymbol; } });
@@ -16,6 +16,7 @@ Object.defineProperty(exports, "HydratedContext", { enumerable: true, get: funct
16
16
  Object.defineProperty(exports, "SimpleContextSlot", { enumerable: true, get: function () { return index_js_1.SimpleContextSlot; } });
17
17
  Object.defineProperty(exports, "getOrCreateInnerNode", { enumerable: true, get: function () { return index_js_1.getOrCreateInnerNode; } });
18
18
  Object.defineProperty(exports, "getOrCreateNodeFromInnerNode", { enumerable: true, get: function () { return index_js_1.getOrCreateNodeFromInnerNode; } });
19
+ Object.defineProperty(exports, "getOrCreateNodeFromInnerUnboxedNode", { enumerable: true, get: function () { return index_js_1.getOrCreateNodeFromInnerUnboxedNode; } });
19
20
  Object.defineProperty(exports, "getKernel", { enumerable: true, get: function () { return index_js_1.getKernel; } });
20
21
  var index_js_2 = require("./api/index.js");
21
22
  Object.defineProperty(exports, "TreeViewConfiguration", { enumerable: true, get: function () { return index_js_2.TreeViewConfiguration; } });
@@ -34,9 +35,9 @@ Object.defineProperty(exports, "getSimpleSchema", { enumerable: true, get: funct
34
35
  Object.defineProperty(exports, "extractPersistedSchema", { enumerable: true, get: function () { return index_js_2.extractPersistedSchema; } });
35
36
  Object.defineProperty(exports, "comparePersistedSchema", { enumerable: true, get: function () { return index_js_2.comparePersistedSchema; } });
36
37
  Object.defineProperty(exports, "SchemaCompatibilityTester", { enumerable: true, get: function () { return index_js_2.SchemaCompatibilityTester; } });
37
- Object.defineProperty(exports, "tryGetSchema", { enumerable: true, get: function () { return index_js_2.tryGetSchema; } });
38
- Object.defineProperty(exports, "getStoredKey", { enumerable: true, get: function () { return index_js_2.getStoredKey; } });
39
38
  Object.defineProperty(exports, "getPropertyKeyFromStoredKey", { enumerable: true, get: function () { return index_js_2.getPropertyKeyFromStoredKey; } });
39
+ Object.defineProperty(exports, "getStoredKey", { enumerable: true, get: function () { return index_js_2.getStoredKey; } });
40
+ Object.defineProperty(exports, "tryGetSchema", { enumerable: true, get: function () { return index_js_2.tryGetSchema; } });
40
41
  Object.defineProperty(exports, "applySchemaToParserOptions", { enumerable: true, get: function () { return index_js_2.applySchemaToParserOptions; } });
41
42
  Object.defineProperty(exports, "cursorFromVerbose", { enumerable: true, get: function () { return index_js_2.cursorFromVerbose; } });
42
43
  Object.defineProperty(exports, "verboseFromCursor", { enumerable: true, get: function () { return index_js_2.verboseFromCursor; } });
@@ -63,15 +64,17 @@ Object.defineProperty(exports, "areImplicitFieldSchemaEqual", { enumerable: true
63
64
  Object.defineProperty(exports, "normalizeAllowedTypes", { enumerable: true, get: function () { return schemaTypes_js_1.normalizeAllowedTypes; } });
64
65
  Object.defineProperty(exports, "evaluateLazySchema", { enumerable: true, get: function () { return schemaTypes_js_1.evaluateLazySchema; } });
65
66
  var getTreeNodeForField_js_1 = require("./getTreeNodeForField.js");
66
- Object.defineProperty(exports, "getTreeNodeForField", { enumerable: true, get: function () { return getTreeNodeForField_js_1.getTreeNodeForField; } });
67
+ Object.defineProperty(exports, "tryGetTreeNodeForField", { enumerable: true, get: function () { return getTreeNodeForField_js_1.tryGetTreeNodeForField; } });
67
68
  var index_js_3 = require("./node-kinds/index.js");
68
69
  Object.defineProperty(exports, "ArrayNodeSchema", { enumerable: true, get: function () { return index_js_3.ArrayNodeSchema; } });
70
+ Object.defineProperty(exports, "asIndex", { enumerable: true, get: function () { return index_js_3.asIndex; } });
69
71
  Object.defineProperty(exports, "isArrayNodeSchema", { enumerable: true, get: function () { return index_js_3.isArrayNodeSchema; } });
70
72
  Object.defineProperty(exports, "IterableTreeArrayContent", { enumerable: true, get: function () { return index_js_3.IterableTreeArrayContent; } });
71
73
  Object.defineProperty(exports, "TreeArrayNode", { enumerable: true, get: function () { return index_js_3.TreeArrayNode; } });
72
74
  Object.defineProperty(exports, "MapNodeSchema", { enumerable: true, get: function () { return index_js_3.MapNodeSchema; } });
73
75
  Object.defineProperty(exports, "isMapNodeSchema", { enumerable: true, get: function () { return index_js_3.isMapNodeSchema; } });
74
76
  Object.defineProperty(exports, "ObjectNodeSchema", { enumerable: true, get: function () { return index_js_3.ObjectNodeSchema; } });
77
+ Object.defineProperty(exports, "isObjectNodeSchema", { enumerable: true, get: function () { return index_js_3.isObjectNodeSchema; } });
75
78
  Object.defineProperty(exports, "setField", { enumerable: true, get: function () { return index_js_3.setField; } });
76
79
  Object.defineProperty(exports, "createUnknownOptionalFieldPolicy", { enumerable: true, get: function () { return index_js_3.createUnknownOptionalFieldPolicy; } });
77
80
  var unhydratedFlexTreeFromInsertable_js_1 = require("./unhydratedFlexTreeFromInsertable.js");
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/simple-tree/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;AAEH,4CAqByB;AApBxB,0GAAA,cAAc,OAAA;AACd,4GAAA,gBAAgB,OAAA;AAGhB,oGAAA,QAAQ,OAAA;AASR,sGAAA,UAAU,OAAA;AACV,8GAAA,kBAAkB,OAAA;AAClB,2GAAA,eAAe,OAAA;AACf,6GAAA,iBAAiB,OAAA;AACjB,gHAAA,oBAAoB,OAAA;AACpB,wHAAA,4BAA4B,OAAA;AAC5B,qGAAA,SAAS,OAAA;AAEV,2CAgGwB;AA3FvB,iHAAA,qBAAqB,OAAA;AACrB,sHAAA,0BAA0B,OAAA;AAI1B,yGAAA,aAAa,OAAA;AACb,8GAAA,kBAAkB,OAAA;AAKlB,qGAAA,SAAS,OAAA;AACT,2GAAA,eAAe,OAAA;AACf,2GAAA,eAAe,OAAA;AACf,uGAAA,WAAW,OAAA;AAGX,oGAAA,QAAQ,OAAA;AAIR,iHAAA,qBAAqB,OAAA;AACrB,iHAAA,qBAAqB,OAAA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A;AAKjC,mEAGkC;AAFjC,6HAAA,mBAAmB,OAAA;AACnB,wIAAA,8BAA8B,OAAA;AAE/B,yDAAsE;AAA7D,mHAAA,cAAc,OAAA;AAAE,oHAAA,eAAe,OAAA;AACxC,yDAM6B;AAL5B,iHAAA,YAAY,OAAA;AACZ,iHAAA,YAAY,OAAA;AACZ,kHAAA,aAAa,OAAA;AACb,iHAAA,YAAY,OAAA;AACZ,+GAAA,UAAU,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport {\n\ttypeNameSymbol,\n\ttypeSchemaSymbol,\n\ttype WithType,\n\ttype TreeNodeSchema,\n\tNodeKind,\n\ttype TreeNodeSchemaClass,\n\ttype TreeNodeSchemaNonClass,\n\ttype TreeNodeSchemaCore,\n\t// TreeNode is only type exported, which prevents use of the class object for unsupported use-cases like direct sub-classing and instanceof.\n\t// See docs on TreeNode for more details.\n\ttype TreeNode,\n\ttype Unhydrated,\n\ttype InternalTreeNode,\n\tisTreeNode,\n\ttryDisposeTreeNode,\n\tHydratedContext,\n\tSimpleContextSlot,\n\tgetOrCreateInnerNode,\n\tgetOrCreateNodeFromInnerNode,\n\tgetKernel,\n} from \"./core/index.js\";\nexport {\n\ttype ITree,\n\ttype TreeView,\n\ttype ViewableTree,\n\ttype TreeViewEvents,\n\tTreeViewConfiguration,\n\tTreeViewConfigurationAlpha,\n\ttype ITreeViewConfiguration,\n\ttype SchemaCompatibilityStatus,\n\ttype ITreeConfigurationOptions,\n\tSchemaFactory,\n\tSchemaFactoryAlpha,\n\ttype SchemaFactoryObjectOptions,\n\ttype ScopedSchemaName,\n\ttype ValidateRecursiveSchema,\n\ttype FixRecursiveArraySchema,\n\tadaptEnum,\n\tenumFromStrings,\n\tsingletonSchema,\n\ttreeNodeApi,\n\ttype TreeNodeApi,\n\ttype NodeChangedData,\n\tTreeBeta,\n\ttype TreeChangeEventsBeta,\n\ttype SimpleTreeIndex,\n\ttype IdentifierIndex,\n\tcreateSimpleTreeIndex,\n\tcreateIdentifierIndex,\n\ttype JsonSchemaId,\n\ttype JsonSchemaType,\n\ttype JsonObjectNodeSchema,\n\ttype JsonArrayNodeSchema,\n\ttype JsonMapNodeSchema,\n\ttype JsonLeafNodeSchema,\n\ttype JsonSchemaRef,\n\ttype JsonRefPath,\n\ttype JsonNodeSchema,\n\ttype JsonNodeSchemaBase,\n\ttype JsonTreeSchema,\n\ttype JsonFieldSchema,\n\ttype JsonLeafSchemaType,\n\ttype TreeSchemaEncodingOptions,\n\tgetJsonSchema,\n\tgetSimpleSchema,\n\ttype VerboseTreeNode,\n\ttype TreeEncodingOptions,\n\ttype VerboseTree,\n\textractPersistedSchema,\n\tcomparePersistedSchema,\n\ttype ConciseTree,\n\tSchemaCompatibilityTester,\n\ttype Unenforced,\n\ttype System_Unsafe,\n\ttype ArrayNodeCustomizableSchemaUnsafe,\n\ttype MapNodeCustomizableSchemaUnsafe,\n\ttype TreeViewAlpha,\n\ttype TreeBranch,\n\ttype TreeBranchEvents,\n\ttryGetSchema,\n\tgetStoredKey,\n\tgetPropertyKeyFromStoredKey,\n\tapplySchemaToParserOptions,\n\tcursorFromVerbose,\n\tverboseFromCursor,\n\tconciseFromCursor,\n\tcreateFromCursor,\n\tasTreeViewAlpha,\n\tcustomFromCursorStored,\n\ttype CustomTreeNode,\n\ttype CustomTreeValue,\n\ttryStoredSchemaAsArray,\n\ttype SchemaStatics,\n\ttype ITreeAlpha,\n\ttype TransactionConstraint,\n\ttype NodeInDocumentConstraint,\n\ttype RunTransactionParams,\n\ttype VoidTransactionCallbackStatus,\n\ttype TransactionCallbackStatus,\n\ttype TransactionResult,\n\ttype TransactionResultExt,\n\ttype TransactionResultSuccess,\n\ttype TransactionResultFailed,\n\trollback,\n\tgenerateSchemaFromSimpleSchema,\n\treplaceConciseTreeHandles,\n\treplaceHandles,\n\treplaceVerboseTreeHandles,\n\ttype HandleConverter,\n\tallowUnused,\n\ttype FieldSchemaAlphaUnsafe,\n\tgetIdentifierFromNode,\n\ttype TreeSchema,\n\ttype ValidateRecursiveSchemaTemplate,\n\ttype FixRecursiveRecursionLimit,\n\tschemaStatics,\n\ttype TreeChangeEvents,\n} from \"./api/index.js\";\nexport type {\n\tSimpleTreeSchema,\n\tSimpleNodeSchema,\n\tSimpleFieldSchema,\n\tSimpleLeafNodeSchema,\n\tSimpleMapNodeSchema,\n\tSimpleArrayNodeSchema,\n\tSimpleObjectNodeSchema,\n\tSimpleNodeSchemaBase,\n\tSimpleObjectFieldSchema,\n} from \"./simpleSchema.js\";\nexport {\n\ttype NodeFromSchema,\n\tisTreeNodeSchemaClass,\n\ttype AnnotatedAllowedType,\n\ttype AnnotatedAllowedTypes,\n\ttype ImplicitFieldSchema,\n\ttype ImplicitAnnotatedFieldSchema,\n\ttype TreeFieldFromImplicitField,\n\ttype ImplicitAllowedTypes,\n\ttype ImplicitAnnotatedAllowedTypes,\n\ttype UnannotateImplicitAllowedTypes,\n\ttype UnannotateAllowedTypes,\n\ttype UnannotateAllowedType,\n\ttype UnannotateAllowedTypesList,\n\ttype UnannotateAllowedTypeOrLazyItem,\n\ttype UnannotateImplicitFieldSchema,\n\ttype UnannotateSchemaRecord,\n\ttype TreeNodeFromImplicitAllowedTypes,\n\ttype InsertableTreeNodeFromImplicitAllowedTypes,\n\ttype TreeLeafValue,\n\ttype AllowedTypes,\n\ttype AllowedTypeMetadata,\n\ttype AllowedTypesMetadata,\n\tFieldKind,\n\tFieldSchema,\n\ttype FieldSchemaAlpha,\n\ttype InsertableTreeFieldFromImplicitField,\n\ttype InsertableTypedNode,\n\ttype NodeBuilderData,\n\ttype DefaultProvider,\n\ttype FieldProps,\n\tnormalizeFieldSchema,\n\tareFieldSchemaEqual,\n\tareImplicitFieldSchemaEqual,\n\ttype ApplyKind,\n\ttype FieldSchemaMetadata,\n\ttype InsertableField,\n\ttype Insertable,\n\ttype UnsafeUnknownSchema,\n\tnormalizeAllowedTypes,\n\ttype ApplyKindInput,\n\ttype InsertableTreeNodeFromAllowedTypes,\n\ttype Input,\n\ttype ReadableField,\n\ttype ReadSchema,\n\ttype NodeSchemaOptions,\n\ttype NodeSchemaMetadata,\n\tevaluateLazySchema,\n} from \"./schemaTypes.js\";\nexport { getTreeNodeForField } from \"./getTreeNodeForField.js\";\nexport {\n\ttype ArrayNodeCustomizableSchema,\n\ttype ArrayNodePojoEmulationSchema,\n\tArrayNodeSchema,\n\tisArrayNodeSchema,\n\tIterableTreeArrayContent,\n\ttype ReadonlyArrayNode,\n\tTreeArrayNode,\n\ttype MapNodeCustomizableSchema,\n\ttype MapNodePojoEmulationSchema,\n\tMapNodeSchema,\n\tisMapNodeSchema,\n\ttype TreeMapNode,\n\ttype MapNodeInsertableData,\n\ttype FieldHasDefault,\n\ttype InsertableObjectFromSchemaRecord,\n\ttype ObjectFromSchemaRecord,\n\tObjectNodeSchema,\n\ttype InsertableObjectFromAnnotatedSchemaRecord,\n\ttype TreeObjectNode,\n\tsetField,\n\tcreateUnknownOptionalFieldPolicy,\n} from \"./node-kinds/index.js\";\nexport {\n\tunhydratedFlexTreeFromInsertable,\n\ttype InsertableContent,\n\ttype FactoryContent,\n\ttype FactoryContentObject,\n} from \"./unhydratedFlexTreeFromInsertable.js\";\nexport {\n\tprepareForInsertion,\n\tprepareForInsertionContextless,\n} from \"./prepareForInsertion.js\";\nexport { toStoredSchema, getStoredSchema } from \"./toStoredSchema.js\";\nexport {\n\tnumberSchema,\n\tstringSchema,\n\tbooleanSchema,\n\thandleSchema,\n\tnullSchema,\n} from \"./leafNodeSchema.js\";\nexport type { LeafSchema } from \"./leafNodeSchema.js\";\nexport type { LazyItem, FlexList, FlexListToUnion, ExtractItemType } from \"./flexList.js\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/simple-tree/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;AAEH,4CAwByB;AAvBxB,0GAAA,cAAc,OAAA;AACd,4GAAA,gBAAgB,OAAA;AA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OAAA;AAoBrB,2GAAA,SAAS,OAAA;AACT,6GAAA,WAAW,OAAA;AAQX,sHAAA,oBAAoB,OAAA;AACpB,qHAAA,mBAAmB,OAAA;AACnB,6HAAA,2BAA2B,OAAA;AAM3B,uHAAA,qBAAqB,OAAA;AASrB,oHAAA,kBAAkB,OAAA;AAEnB,mEAAkE;AAAzD,gIAAA,sBAAsB,OAAA;AAC/B,kDAwB+B;AArB9B,2GAAA,eAAe,OAAA;AACf,mGAAA,OAAO,OAAA;AACP,6GAAA,iBAAiB,OAAA;AACjB,oHAAA,wBAAwB,OAAA;AAExB,yGAAA,aAAa,OAAA;AAGb,yGAAA,aAAa,OAAA;AACb,2GAAA,eAAe,OAAA;AAMf,4GAAA,gBAAgB,OAAA;AAChB,8GAAA,kBAAkB,OAAA;AAGlB,oGAAA,QAAQ,OAAA;AACR,4HAAA,gCAAgC,OAAA;AAEjC,6FAK+C;AAJ9C,uJAAA,gCAAgC,OAAA;AAKjC,mEAGkC;AAFjC,6HAAA,mBAAmB,OAAA;AACnB,wIAAA,8BAA8B,OAAA;AAE/B,yDAAsE;AAA7D,mHAAA,cAAc,OAAA;AAAE,oHAAA,eAAe,OAAA;AACxC,yDAM6B;AAL5B,iHAAA,YAAY,OAAA;AACZ,iHAAA,YAAY,OAAA;AACZ,kHAAA,aAAa,OAAA;AACb,iHAAA,YAAY,OAAA;AACZ,+GAAA,UAAU,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport {\n\ttypeNameSymbol,\n\ttypeSchemaSymbol,\n\ttype WithType,\n\ttype TreeNodeSchema,\n\ttype AnnotatedAllowedType,\n\ttype NormalizedAnnotatedAllowedTypes,\n\tNodeKind,\n\ttype TreeNodeSchemaClass,\n\ttype TreeNodeSchemaNonClass,\n\ttype TreeNodeSchemaCore,\n\t// TreeNode is only type exported, which prevents use of the class object for unsupported use-cases like direct sub-classing and instanceof.\n\t// See docs on TreeNode for more details.\n\ttype TreeNode,\n\ttype Unhydrated,\n\ttype InternalTreeNode,\n\tisTreeNode,\n\ttryDisposeTreeNode,\n\tHydratedContext,\n\tSimpleContextSlot,\n\tgetOrCreateInnerNode,\n\tgetOrCreateNodeFromInnerNode,\n\tgetOrCreateNodeFromInnerUnboxedNode,\n\tgetKernel,\n} from \"./core/index.js\";\nexport {\n\ttype ITree,\n\ttype TreeView,\n\ttype ViewableTree,\n\ttype TreeViewEvents,\n\tTreeViewConfiguration,\n\tTreeViewConfigurationAlpha,\n\ttype ITreeViewConfiguration,\n\ttype SchemaCompatibilityStatus,\n\ttype ITreeConfigurationOptions,\n\tSchemaFactory,\n\tSchemaFactoryAlpha,\n\ttype SchemaFactoryObjectOptions,\n\ttype ScopedSchemaName,\n\ttype ValidateRecursiveSchema,\n\ttype FixRecursiveArraySchema,\n\tadaptEnum,\n\tenumFromStrings,\n\tsingletonSchema,\n\ttreeNodeApi,\n\ttype TreeNodeApi,\n\ttype NodeChangedData,\n\tTreeBeta,\n\ttype TreeChangeEventsBeta,\n\ttype SimpleTreeIndex,\n\ttype IdentifierIndex,\n\tcreateSimpleTreeIndex,\n\tcreateIdentifierIndex,\n\ttype JsonSchemaId,\n\ttype JsonSchemaType,\n\ttype JsonObjectNodeSchema,\n\ttype JsonArrayNodeSchema,\n\ttype JsonMapNodeSchema,\n\ttype JsonLeafNodeSchema,\n\ttype JsonSchemaRef,\n\ttype JsonRefPath,\n\ttype JsonNodeSchema,\n\ttype JsonNodeSchemaBase,\n\ttype JsonTreeSchema,\n\ttype JsonFieldSchema,\n\ttype JsonLeafSchemaType,\n\ttype TreeSchemaEncodingOptions,\n\tgetJsonSchema,\n\tgetSimpleSchema,\n\ttype VerboseTreeNode,\n\ttype TreeEncodingOptions,\n\ttype VerboseTree,\n\textractPersistedSchema,\n\tcomparePersistedSchema,\n\ttype ConciseTree,\n\tSchemaCompatibilityTester,\n\ttype Unenforced,\n\ttype System_Unsafe,\n\ttype ArrayNodeCustomizableSchemaUnsafe,\n\ttype MapNodeCustomizableSchemaUnsafe,\n\ttype TreeViewAlpha,\n\ttype TreeBranch,\n\ttype TreeBranchEvents,\n\tgetPropertyKeyFromStoredKey,\n\tgetStoredKey,\n\ttryGetSchema,\n\tapplySchemaToParserOptions,\n\tcursorFromVerbose,\n\tverboseFromCursor,\n\tconciseFromCursor,\n\tcreateFromCursor,\n\tasTreeViewAlpha,\n\tcustomFromCursorStored,\n\ttype CustomTreeNode,\n\ttype CustomTreeValue,\n\ttryStoredSchemaAsArray,\n\ttype SchemaStatics,\n\ttype ITreeAlpha,\n\ttype TransactionConstraint,\n\ttype NodeInDocumentConstraint,\n\ttype RunTransactionParams,\n\ttype VoidTransactionCallbackStatus,\n\ttype TransactionCallbackStatus,\n\ttype TransactionResult,\n\ttype TransactionResultExt,\n\ttype TransactionResultSuccess,\n\ttype TransactionResultFailed,\n\trollback,\n\tgenerateSchemaFromSimpleSchema,\n\treplaceConciseTreeHandles,\n\treplaceHandles,\n\treplaceVerboseTreeHandles,\n\ttype HandleConverter,\n\tallowUnused,\n\ttype FieldSchemaAlphaUnsafe,\n\tgetIdentifierFromNode,\n\ttype TreeSchema,\n\ttype ValidateRecursiveSchemaTemplate,\n\ttype FixRecursiveRecursionLimit,\n\tschemaStatics,\n\ttype TreeChangeEvents,\n} from \"./api/index.js\";\nexport type {\n\tSimpleTreeSchema,\n\tSimpleNodeSchema,\n\tSimpleFieldSchema,\n\tSimpleLeafNodeSchema,\n\tSimpleMapNodeSchema,\n\tSimpleArrayNodeSchema,\n\tSimpleObjectNodeSchema,\n\tSimpleNodeSchemaBase,\n\tSimpleNodeSchemaBaseAlpha,\n\tSimpleObjectFieldSchema,\n} from \"./simpleSchema.js\";\nexport {\n\ttype NodeFromSchema,\n\tisTreeNodeSchemaClass,\n\ttype ImplicitFieldSchema,\n\ttype ImplicitAnnotatedFieldSchema,\n\ttype TreeFieldFromImplicitField,\n\ttype ImplicitAllowedTypes,\n\ttype ImplicitAnnotatedAllowedTypes,\n\ttype UnannotateImplicitAllowedTypes,\n\ttype UnannotateAllowedTypes,\n\ttype UnannotateAllowedType,\n\ttype UnannotateAllowedTypesList,\n\ttype UnannotateAllowedTypeOrLazyItem,\n\ttype UnannotateImplicitFieldSchema,\n\ttype UnannotateSchemaRecord,\n\ttype TreeNodeFromImplicitAllowedTypes,\n\ttype InsertableTreeNodeFromImplicitAllowedTypes,\n\ttype TreeLeafValue,\n\ttype AllowedTypes,\n\ttype AllowedTypeMetadata,\n\ttype AllowedTypesMetadata,\n\ttype AnnotatedAllowedTypes,\n\tFieldKind,\n\tFieldSchema,\n\ttype FieldSchemaAlpha,\n\ttype InsertableTreeFieldFromImplicitField,\n\ttype InsertableTypedNode,\n\ttype NodeBuilderData,\n\ttype DefaultProvider,\n\ttype FieldProps,\n\ttype FieldPropsAlpha,\n\tnormalizeFieldSchema,\n\tareFieldSchemaEqual,\n\tareImplicitFieldSchemaEqual,\n\ttype ApplyKind,\n\ttype FieldSchemaMetadata,\n\ttype InsertableField,\n\ttype Insertable,\n\ttype UnsafeUnknownSchema,\n\tnormalizeAllowedTypes,\n\ttype ApplyKindInput,\n\ttype InsertableTreeNodeFromAllowedTypes,\n\ttype Input,\n\ttype ReadableField,\n\ttype ReadSchema,\n\ttype NodeSchemaOptions,\n\ttype NodeSchemaOptionsAlpha,\n\ttype NodeSchemaMetadata,\n\tevaluateLazySchema,\n} from \"./schemaTypes.js\";\nexport { tryGetTreeNodeForField } from \"./getTreeNodeForField.js\";\nexport {\n\ttype ArrayNodeCustomizableSchema,\n\ttype ArrayNodePojoEmulationSchema,\n\tArrayNodeSchema,\n\tasIndex,\n\tisArrayNodeSchema,\n\tIterableTreeArrayContent,\n\ttype ReadonlyArrayNode,\n\tTreeArrayNode,\n\ttype MapNodeCustomizableSchema,\n\ttype MapNodePojoEmulationSchema,\n\tMapNodeSchema,\n\tisMapNodeSchema,\n\ttype TreeMapNode,\n\ttype MapNodeInsertableData,\n\ttype FieldHasDefault,\n\ttype InsertableObjectFromSchemaRecord,\n\ttype ObjectFromSchemaRecord,\n\tObjectNodeSchema,\n\tisObjectNodeSchema,\n\ttype InsertableObjectFromAnnotatedSchemaRecord,\n\ttype TreeObjectNode,\n\tsetField,\n\tcreateUnknownOptionalFieldPolicy,\n} from \"./node-kinds/index.js\";\nexport {\n\tunhydratedFlexTreeFromInsertable,\n\ttype InsertableContent,\n\ttype FactoryContent,\n\ttype FactoryContentObject,\n} from \"./unhydratedFlexTreeFromInsertable.js\";\nexport {\n\tprepareForInsertion,\n\tprepareForInsertionContextless,\n} from \"./prepareForInsertion.js\";\nexport { toStoredSchema, getStoredSchema } from \"./toStoredSchema.js\";\nexport {\n\tnumberSchema,\n\tstringSchema,\n\tbooleanSchema,\n\thandleSchema,\n\tnullSchema,\n} from \"./leafNodeSchema.js\";\nexport type { LeafSchema } from \"./leafNodeSchema.js\";\nexport type { LazyItem, FlexList, FlexListToUnion, ExtractItemType } from \"./flexList.js\";\n"]}
@@ -4,9 +4,10 @@
4
4
  */
5
5
  import { type TreeValue, ValueSchema } from "../core/index.js";
6
6
  import { type FlexTreeNode } from "../feature-libraries/index.js";
7
- import { NodeKind, type TreeNodeSchema, type TreeNodeSchemaNonClass } from "./core/index.js";
7
+ import { NodeKind, type NormalizedAnnotatedAllowedTypes, type TreeNodeSchema, type TreeNodeSchemaNonClass } from "./core/index.js";
8
8
  import type { NodeSchemaMetadata, TreeLeafValue } from "./schemaTypes.js";
9
9
  import type { SimpleLeafNodeSchema } from "./simpleSchema.js";
10
+ import type { JsonCompatibleReadOnlyObject } from "../util/index.js";
10
11
  /**
11
12
  * Instances of this class are schema for leaf nodes.
12
13
  * @remarks
@@ -22,10 +23,12 @@ export declare class LeafNodeSchema<Name extends string, const T extends ValueSc
22
23
  readonly info: T;
23
24
  readonly implicitlyConstructable: true;
24
25
  readonly childTypes: ReadonlySet<TreeNodeSchema>;
26
+ readonly childAnnotatedAllowedTypes: readonly NormalizedAnnotatedAllowedTypes[];
25
27
  create(data: TreeValue<T> | FlexTreeNode): TreeValue<T>;
26
28
  createFromInsertable(data: TreeValue<T>): TreeValue<T>;
27
29
  readonly leafKind: ValueSchema;
28
30
  readonly metadata: NodeSchemaMetadata;
31
+ readonly persistedMetadata: JsonCompatibleReadOnlyObject | undefined;
29
32
  constructor(name: Name, t: T);
30
33
  }
31
34
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"leafNodeSchema.d.ts","sourceRoot":"","sources":["../../src/simple-tree/leafNodeSchema.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,EAAE,KAAK,SAAS,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EACN,KAAK,YAAY,EAGjB,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EAAE,QAAQ,EAAE,KAAK,cAAc,EAAE,KAAK,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAC7F,OAAO,KAAK,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAC1E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAE9D;;;;;;;;GAQG;AACH,qBAAa,cAAc,CAAC,IAAI,SAAS,MAAM,EAAE,KAAK,CAAC,CAAC,SAAS,WAAW,CAC3E,YAAW,sBAAsB,CAAC,IAAI,EAAE,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC;IAElF,SAAgB,UAAU,EAAE,IAAI,CAAC;IACjC,SAAgB,IAAI,iBAAiB;IACrC,SAAgB,IAAI,EAAE,CAAC,CAAC;IACxB,SAAgB,uBAAuB,OAAiB;IACxD,SAAgB,UAAU,EAAE,WAAW,CAAC,cAAc,CAAC,CAAa;IAE7D,MAAM,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,YAAY,GAAG,SAAS,CAAC,CAAC,CAAC;IASvD,oBAAoB,CAAC,IAAI,EAAE,SAAS,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ructable = true;
36
36
  this.childTypes = new Set();
37
+ this.childAnnotatedAllowedTypes = [];
37
38
  this.metadata = {};
38
39
  this.identifier = name;
39
40
  this.info = t;
@@ -1 +1 @@
1
- {"version":3,"file":"leafNodeSchema.js","sourceRoot":"","sources":["../../src/simple-tree/leafNodeSchema.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,kEAA6D;AAE7D,+CAA+D;AAC/D,4DAIuC;AAEvC,8CAA6F;AAI7F;;;;;;;;GAQG;AACH,MAAa,cAAc;IASnB,MAAM,CAAC,IAAiC;QAC9C,IAAI,IAAA,yBAAc,EAAC,IAAI,CAAC,EAAE,CAAC;YAC1B,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACzB,IAAA,iBAAM,EAAC,IAAA,4BAAiB,EAAC,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,KAAK,CAAC,mBAAmB,CAAC,CAAC;YACvE,OAAO,KAAK,CAAC;QACd,CAAC;QACD,OAAO,IAAI,CAAC;IACb,CAAC;IAEM,oBAAoB,CAAC,IAAkB;QAC7C,OAAO,IAAI,CAAC;IACb,CAAC;IAMD,YAAmB,IAAU,EAAE,CAAI;QAtBnB,SAAI,GAAG,mBAAQ,CAAC,IAAI,CAAC;QAErB,4BAAuB,GAAG,IAAa,CAAC;QACxC,eAAU,GAAgC,IAAI,GAAG,EAAE,CAAC;QAiBpD,aAAQ,GAAuB,EAAE,CAAC;QAGjD,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;QACvB,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QACd,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAC;IACnB,CAAC;CACD;AA/BD,wCA+BC;AAED;;GAEG;AACH,SAAS,QAAQ,CAChB,IAAU,EACV,CAAI;IAEJ,yFAAyF;IACzF,OAAO,IAAI,cAAc,CAAC,2BAA2B,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC;AACjE,CAAC;AAsBD,0DAA0D;AAC7C,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,MAAM,CAAC,CAAC;AACtD,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,MAAM,CAAC,CAAC;AACtD,QAAA,aAAa,GAAG,QAAQ,CAAC,SAAS,EAAE,sBAAW,CAAC,OAAO,CAAC,CAAC;AACzD,QAAA,UAAU,GAAG,QAAQ,CAAC,MAAM,EAAE,sBAAW,CAAC,IAAI,CAAC,CAAC;AAChD,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,WAAW,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { assert } from \"@fluidframework/core-utils/internal\";\n\nimport { type TreeValue, ValueSchema } from \"../core/index.js\";\nimport {\n\ttype FlexTreeNode,\n\tisFlexTreeNode,\n\tvalueSchemaAllows,\n} from \"../feature-libraries/index.js\";\n\nimport { NodeKind, type TreeNodeSchema, type TreeNodeSchemaNonClass } from \"./core/index.js\";\nimport type { NodeSchemaMetadata, TreeLeafValue } from \"./schemaTypes.js\";\nimport type { SimpleLeafNodeSchema } from \"./simpleSchema.js\";\n\n/**\n * Instances of this class are schema for leaf nodes.\n * @remarks\n * Unlike other schema, leaf schema are class instances instead of classes themselves.\n * This is because the instance type (the tree node type) for leaves are not objects,\n * so those instances can't be instances of a schema based class.\n * @privateRemarks\n * This class refers to the underlying flex tree schema in its constructor, so this class can't be included in the package API.\n */\nexport class LeafNodeSchema<Name extends string, const T extends ValueSchema>\n\timplements TreeNodeSchemaNonClass<Name, NodeKind.Leaf, TreeValue<T>, TreeValue<T>>\n{\n\tpublic readonly identifier: Name;\n\tpublic readonly kind = NodeKind.Leaf;\n\tpublic readonly info: T;\n\tpublic readonly implicitlyConstructable = true as const;\n\tpublic readonly childTypes: ReadonlySet<TreeNodeSchema> = new Set();\n\n\tpublic create(data: TreeValue<T> | FlexTreeNode): TreeValue<T> {\n\t\tif (isFlexTreeNode(data)) {\n\t\t\tconst value = data.value;\n\t\t\tassert(valueSchemaAllows(this.info, value), 0x916 /* invalid value */);\n\t\t\treturn value;\n\t\t}\n\t\treturn data;\n\t}\n\n\tpublic createFromInsertable(data: TreeValue<T>): TreeValue<T> {\n\t\treturn data;\n\t}\n\n\tpublic readonly leafKind: ValueSchema;\n\n\tpublic readonly metadata: NodeSchemaMetadata = {};\n\n\tpublic constructor(name: Name, t: T) {\n\t\tthis.identifier = name;\n\t\tthis.info = t;\n\t\tthis.leafKind = t;\n\t}\n}\n\n/**\n * Wrapper around LeafNodeSchema's constructor that provides the return type that is desired in the package public API.\n */\nfunction makeLeaf<Name extends string, const T extends ValueSchema>(\n\tname: Name,\n\tt: T,\n): LeafSchema<Name, TreeValue<T>> & SimpleLeafNodeSchema {\n\t// Names in this domain follow https://en.wikipedia.org/wiki/Reverse_domain_name_notation\n\treturn new LeafNodeSchema(`com.fluidframework.leaf.${name}`, t);\n}\n\n/**\n * A {@link TreeNodeSchema} for a {@link TreeLeafValue}.\n * @remarks\n * This is just a more specific alias for a particular {@link TreeNodeSchemaNonClass}.\n * It only exists to make the API (particularly errors, IntelliSense, and generated .d.ts files) more readable.\n *\n * See {@link SchemaFactory} and its various properties for actual leaf schema objects.\n * @privateRemarks\n * This is an interface so its name will show up in things like type errors instead of the fully expanded TreeNodeSchemaNonClass.\n * @system @sealed @public\n */\nexport interface LeafSchema<Name extends string, T extends TreeLeafValue>\n\textends TreeNodeSchemaNonClass<\n\t\t`com.fluidframework.leaf.${Name}`,\n\t\tNodeKind.Leaf,\n\t\t/* TNode */ T,\n\t\t/* TInsertable */ T,\n\t\t/* ImplicitlyConstructable */ true\n\t> {}\n\n// Leaf schema shared between all SchemaFactory instances.\nexport const stringSchema = makeLeaf(\"string\", ValueSchema.String);\nexport const numberSchema = makeLeaf(\"number\", ValueSchema.Number);\nexport const booleanSchema = makeLeaf(\"boolean\", ValueSchema.Boolean);\nexport const nullSchema = makeLeaf(\"null\", ValueSchema.Null);\nexport const handleSchema = makeLeaf(\"handle\", ValueSchema.FluidHandle);\n"]}
1
+ {"version":3,"file":"leafNodeSchema.js","sourceRoot":"","sources":["../../src/simple-tree/leafNodeSchema.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,kEAA6D;AAE7D,+CAA+D;AAC/D,4DAIuC;AAEvC,8CAKyB;AAKzB;;;;;;;;GAQG;AACH,MAAa,cAAc;IAUnB,MAAM,CAAC,IAAiC;QAC9C,IAAI,IAAA,yBAAc,EAAC,IAAI,CAAC,EAAE,CAAC;YAC1B,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;YACzB,IAAA,iBAAM,EAAC,IAAA,4BAAiB,EAAC,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,KAAK,CAAC,mBAAmB,CAAC,CAAC;YACvE,OAAO,KAAK,CAAC;QACd,CAAC;QACD,OAAO,IAAI,CAAC;IACb,CAAC;IAEM,oBAAoB,CAAC,IAAkB;QAC7C,OAAO,IAAI,CAAC;IACb,CAAC;IAOD,YAAmB,IAAU,EAAE,CAAI;QAxBnB,SAAI,GAAG,mBAAQ,CAAC,IAAI,CAAC;QAErB,4BAAuB,GAAG,IAAa,CAAC;QACxC,eAAU,GAAgC,IAAI,GAAG,EAAE,CAAC;QACpD,+BAA0B,GAA+C,EAAE,CAAC;QAiB5E,aAAQ,GAAuB,EAAE,CAAC;QAIjD,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;QACvB,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QACd,IAAI,CAAC,QAAQ,GAAG,CAAC,CAAC;IACnB,CAAC;CACD;AAjCD,wCAiCC;AAED;;GAEG;AACH,SAAS,QAAQ,CAChB,IAAU,EACV,CAAI;IAEJ,yFAAyF;IACzF,OAAO,IAAI,cAAc,CAAC,2BAA2B,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC;AACjE,CAAC;AAsBD,0DAA0D;AAC7C,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,MAAM,CAAC,CAAC;AACtD,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,MAAM,CAAC,CAAC;AACtD,QAAA,aAAa,GAAG,QAAQ,CAAC,SAAS,EAAE,sBAAW,CAAC,OAAO,CAAC,CAAC;AACzD,QAAA,UAAU,GAAG,QAAQ,CAAC,MAAM,EAAE,sBAAW,CAAC,IAAI,CAAC,CAAC;AAChD,QAAA,YAAY,GAAG,QAAQ,CAAC,QAAQ,EAAE,sBAAW,CAAC,WAAW,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { assert } from \"@fluidframework/core-utils/internal\";\n\nimport { type TreeValue, ValueSchema } from \"../core/index.js\";\nimport {\n\ttype FlexTreeNode,\n\tisFlexTreeNode,\n\tvalueSchemaAllows,\n} from \"../feature-libraries/index.js\";\n\nimport {\n\tNodeKind,\n\ttype NormalizedAnnotatedAllowedTypes,\n\ttype TreeNodeSchema,\n\ttype TreeNodeSchemaNonClass,\n} from \"./core/index.js\";\nimport type { NodeSchemaMetadata, TreeLeafValue } from \"./schemaTypes.js\";\nimport type { SimpleLeafNodeSchema } from \"./simpleSchema.js\";\nimport type { JsonCompatibleReadOnlyObject } from \"../util/index.js\";\n\n/**\n * Instances of this class are schema for leaf nodes.\n * @remarks\n * Unlike other schema, leaf schema are class instances instead of classes themselves.\n * This is because the instance type (the tree node type) for leaves are not objects,\n * so those instances can't be instances of a schema based class.\n * @privateRemarks\n * This class refers to the underlying flex tree schema in its constructor, so this class can't be included in the package API.\n */\nexport class LeafNodeSchema<Name extends string, const T extends ValueSchema>\n\timplements TreeNodeSchemaNonClass<Name, NodeKind.Leaf, TreeValue<T>, TreeValue<T>>\n{\n\tpublic readonly identifier: Name;\n\tpublic readonly kind = NodeKind.Leaf;\n\tpublic readonly info: T;\n\tpublic readonly implicitlyConstructable = true as const;\n\tpublic readonly childTypes: ReadonlySet<TreeNodeSchema> = new Set();\n\tpublic readonly childAnnotatedAllowedTypes: readonly NormalizedAnnotatedAllowedTypes[] = [];\n\n\tpublic create(data: TreeValue<T> | FlexTreeNode): TreeValue<T> {\n\t\tif (isFlexTreeNode(data)) {\n\t\t\tconst value = data.value;\n\t\t\tassert(valueSchemaAllows(this.info, value), 0x916 /* invalid value */);\n\t\t\treturn value;\n\t\t}\n\t\treturn data;\n\t}\n\n\tpublic createFromInsertable(data: TreeValue<T>): TreeValue<T> {\n\t\treturn data;\n\t}\n\n\tpublic readonly leafKind: ValueSchema;\n\n\tpublic readonly metadata: NodeSchemaMetadata = {};\n\tpublic readonly persistedMetadata: JsonCompatibleReadOnlyObject | undefined;\n\n\tpublic constructor(name: Name, t: T) {\n\t\tthis.identifier = name;\n\t\tthis.info = t;\n\t\tthis.leafKind = t;\n\t}\n}\n\n/**\n * Wrapper around LeafNodeSchema's constructor that provides the return type that is desired in the package public API.\n */\nfunction makeLeaf<Name extends string, const T extends ValueSchema>(\n\tname: Name,\n\tt: T,\n): LeafSchema<Name, TreeValue<T>> & SimpleLeafNodeSchema {\n\t// Names in this domain follow https://en.wikipedia.org/wiki/Reverse_domain_name_notation\n\treturn new LeafNodeSchema(`com.fluidframework.leaf.${name}`, t);\n}\n\n/**\n * A {@link TreeNodeSchema} for a {@link TreeLeafValue}.\n * @remarks\n * This is just a more specific alias for a particular {@link TreeNodeSchemaNonClass}.\n * It only exists to make the API (particularly errors, IntelliSense, and generated .d.ts files) more readable.\n *\n * See {@link SchemaFactory} and its various properties for actual leaf schema objects.\n * @privateRemarks\n * This is an interface so its name will show up in things like type errors instead of the fully expanded TreeNodeSchemaNonClass.\n * @system @sealed @public\n */\nexport interface LeafSchema<Name extends string, T extends TreeLeafValue>\n\textends TreeNodeSchemaNonClass<\n\t\t`com.fluidframework.leaf.${Name}`,\n\t\tNodeKind.Leaf,\n\t\t/* TNode */ T,\n\t\t/* TInsertable */ T,\n\t\t/* ImplicitlyConstructable */ true\n\t> {}\n\n// Leaf schema shared between all SchemaFactory instances.\nexport const stringSchema = makeLeaf(\"string\", ValueSchema.String);\nexport const numberSchema = makeLeaf(\"number\", ValueSchema.Number);\nexport const booleanSchema = makeLeaf(\"boolean\", ValueSchema.Boolean);\nexport const nullSchema = makeLeaf(\"null\", ValueSchema.Null);\nexport const handleSchema = makeLeaf(\"handle\", ValueSchema.FluidHandle);\n"]}
@@ -6,6 +6,7 @@ import { type ImplicitAllowedTypes, type ImplicitAnnotatedAllowedTypes, type Ins
6
6
  import { type WithType, NodeKind, type TreeNode } from "../../core/index.js";
7
7
  import type { System_Unsafe } from "../../api/index.js";
8
8
  import type { ArrayNodeCustomizableSchema, ArrayNodePojoEmulationSchema } from "./arrayNodeTypes.js";
9
+ import type { JsonCompatibleReadOnlyObject } from "../../../util/index.js";
9
10
  /**
10
11
  * A covariant base type for {@link (TreeArrayNode:interface)}.
11
12
  *
@@ -374,6 +375,7 @@ export declare function asIndex(key: string | symbol, exclusiveMax: number): num
374
375
  * Define a {@link TreeNodeSchema} for a {@link (TreeArrayNode:interface)}.
375
376
  *
376
377
  * @param name - Unique identifier for this schema including the factory's scope.
378
+ * @param persistedMetadata - Optional persisted metadata for the object node schema.
377
379
  */
378
- export declare function arraySchema<TName extends string, const T extends ImplicitAnnotatedAllowedTypes, const ImplicitlyConstructable extends boolean, const TCustomMetadata = unknown>(identifier: TName, info: T, implicitlyConstructable: ImplicitlyConstructable, customizable: boolean, metadata?: NodeSchemaMetadata<TCustomMetadata>): ArrayNodeCustomizableSchema<TName, T, ImplicitlyConstructable, TCustomMetadata> & ArrayNodePojoEmulationSchema<TName, T, ImplicitlyConstructable, TCustomMetadata>;
380
+ export declare function arraySchema<TName extends string, const T extends ImplicitAnnotatedAllowedTypes, const ImplicitlyConstructable extends boolean, const TCustomMetadata = unknown>(identifier: TName, info: T, implicitlyConstructable: ImplicitlyConstructable, customizable: boolean, metadata?: NodeSchemaMetadata<TCustomMetadata>, persistedMetadata?: JsonCompatibleReadOnlyObject | undefined): ArrayNodeCustomizableSchema<TName, T, ImplicitlyConstructable, TCustomMetadata> & ArrayNodePojoEmulationSchema<TName, T, ImplicitlyConstructable, TCustomMetadata>;
379
381
  //# sourceMappingURL=arrayNode.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"arrayNode.d.ts","sourceRoot":"","sources":["../../../../src/simple-tree/node-kinds/array/arrayNode.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAYH,OAAO,EAGN,KAAK,oBAAoB,EACzB,KAAK,6BAA6B,EAClC,KAAK,0CAA0C,EAC/C,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,gCAAgC,EAErC,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACN,KAAK,QAAQ,EAGb,QAAQ,EACR,KAAK,QAAQ,EAYb,MAAM,qBAAqB,CAAC;AAQ7B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACxD,OAAO,KAAK,EACX,2BAA2B,EAC3B,4BAA4B,EAC5B,MAAM,qBAAqB,CAAC;AAE7B;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAiB,CAAC,GAAG,CAAC,CAAC,GAAG,QAAQ,GAAG,aAAa,CAClE,SAAQ,aAAa,CAAC,CAAC,CAAC,EACvB,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC,KAAK,CAAC,CAAC;CAAG;AAEzD;;;;;;;;;GASG;AACH,MAAM,WAAW,aAAa,CAC7B,aAAa,SAAS,aAAa,CAAC,0BAA0B,GAAG,oBAAoB,EACrF,GAAG,CAAC,CAAC,GAAG,CAAC,aAAa,CAAC,SAAS,CAAC,oBAAoB,CAAC,GACnD,gCAAgC,CAAC,aAAa,CAAC,GAC/C,gCAAgC,CAAC,oBAAoB,CAAC,EACzD,EAAE,CAAC,IAAI,GAAG,C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
14
14
  const internal_1 = require("@fluidframework/core-utils/internal");
15
15
  const internal_2 = require("@fluidframework/telemetry-utils/internal");
16
16
  const index_js_1 = require("../../../core/index.js");
17
- const index_js_2 = require("../../../feature-libraries/index.js");
18
17
  const schemaTypes_js_1 = require("../../schemaTypes.js");
19
- const index_js_3 = require("../../core/index.js");
18
+ const index_js_2 = require("../../core/index.js");
20
19
  const unhydratedFlexTreeFromInsertable_js_1 = require("../../unhydratedFlexTreeFromInsertable.js");
21
20
  const prepareForInsertion_js_1 = require("../../prepareForInsertion.js");
22
21
  const treeNodeValid_js_1 = require("../../treeNodeValid.js");
@@ -67,7 +66,7 @@ exports.IterableTreeArrayContent = IterableTreeArrayContent;
67
66
  * Given a array node proxy, returns its underlying LazySequence field.
68
67
  */
69
68
  function getSequenceField(arrayNode) {
70
- return (0, index_js_3.getOrCreateInnerNode)(arrayNode).getBoxed(index_js_1.EmptyKey);
69
+ return (0, index_js_2.getOrCreateInnerNode)(arrayNode).getBoxed(index_js_1.EmptyKey);
71
70
  }
72
71
  // For compatibility, we are initially implement 'readonly T[]' by applying the Array.prototype methods
73
72
  // to the array node proxy. Over time, we should replace these with efficient implementations on LazySequence
@@ -183,9 +182,9 @@ function createArrayNodeProxy(allowAdditionalProperties, proxyTarget, dispatchTa
183
182
  return Reflect.get(dispatchTarget, key, receiver);
184
183
  }
185
184
  const maybeContent = field.at(maybeIndex);
186
- return (0, index_js_2.isFlexTreeNode)(maybeContent)
187
- ? (0, index_js_3.getOrCreateNodeFromInnerNode)(maybeContent)
188
- : maybeContent;
185
+ return maybeContent === undefined
186
+ ? undefined
187
+ : (0, index_js_2.getOrCreateNodeFromInnerUnboxedNode)(maybeContent);
189
188
  },
190
189
  set: (target, key, newValue, receiver) => {
191
190
  if (key === "length") {
@@ -236,7 +235,7 @@ function createArrayNodeProxy(allowAdditionalProperties, proxyTarget, dispatchTa
236
235
  // To satisfy 'deepEquals' level scrutiny, the property descriptor for indexed properties must
237
236
  // be a simple value property (as opposed to using getter) and declared writable/enumerable/configurable.
238
237
  return {
239
- value: (0, index_js_2.isFlexTreeNode)(val) ? (0, index_js_3.getOrCreateNodeFromInnerNode)(val) : val,
238
+ value: val === undefined ? undefined : (0, index_js_2.getOrCreateNodeFromInnerUnboxedNode)(val),
240
239
  writable: true, // For MVP, setting indexed properties is reported as allowed here (for deep equals compatibility noted above), but not actually supported.
241
240
  enumerable: true,
242
241
  configurable: true,
@@ -301,7 +300,7 @@ class CustomArrayNodeBase extends TreeNodeWithArrayFeatures {
301
300
  if (val === undefined) {
302
301
  return val;
303
302
  }
304
- return (0, index_js_3.getOrCreateNodeFromInnerNode)(val);
303
+ return (0, index_js_2.getOrCreateNodeFromInnerNode)(val);
305
304
  }
306
305
  insertAt(index, ...value) {
307
306
  const field = getSequenceField(this);
@@ -371,7 +370,7 @@ class CustomArrayNodeBase extends TreeNodeWithArrayFeatures {
371
370
  if (sourceField !== destinationField) {
372
371
  for (let i = sourceStart; i < sourceEnd; i++) {
373
372
  const sourceNode = sourceField.boxedAt(i) ?? (0, internal_1.oob)();
374
- const sourceSchema = (0, index_js_3.getSimpleNodeSchemaFromInnerNode)(sourceNode);
373
+ const sourceSchema = (0, index_js_2.getSimpleNodeSchemaFromInnerNode)(sourceNode);
375
374
  if (!destinationSchema.has(sourceSchema)) {
376
375
  throw new internal_2.UsageError("Type in source sequence is not allowed in destination.");
377
376
  }
@@ -379,7 +378,7 @@ class CustomArrayNodeBase extends TreeNodeWithArrayFeatures {
379
378
  }
380
379
  const movedCount = sourceEnd - sourceStart;
381
380
  if (!destinationField.context.isHydrated()) {
382
- if (!(sourceField instanceof index_js_3.UnhydratedSequenceField)) {
381
+ if (!(sourceField instanceof index_js_2.UnhydratedSequenceField)) {
383
382
  throw new internal_2.UsageError("Cannot move elements from a hydrated array to an unhydrated array.");
384
383
  }
385
384
  if (sourceField.context.isHydrated()) {
@@ -403,10 +402,10 @@ class CustomArrayNodeBase extends TreeNodeWithArrayFeatures {
403
402
  }
404
403
  }
405
404
  values() {
406
- return this.generateValues((0, index_js_3.getKernel)(this).generationNumber);
405
+ return this.generateValues((0, index_js_2.getKernel)(this).generationNumber);
407
406
  }
408
407
  *generateValues(initialLastUpdatedStamp) {
409
- const kernel = (0, index_js_3.getKernel)(this);
408
+ const kernel = (0, index_js_2.getKernel)(this);
410
409
  if (initialLastUpdatedStamp !== kernel.generationNumber) {
411
410
  throw new internal_2.UsageError(`Concurrent editing and iteration is not allowed.`);
412
411
  }
@@ -418,16 +417,18 @@ class CustomArrayNodeBase extends TreeNodeWithArrayFeatures {
418
417
  }
419
418
  }
420
419
  }
421
- CustomArrayNodeBase.kind = index_js_3.NodeKind.Array;
420
+ CustomArrayNodeBase.kind = index_js_2.NodeKind.Array;
422
421
  /**
423
422
  * Define a {@link TreeNodeSchema} for a {@link (TreeArrayNode:interface)}.
424
423
  *
425
424
  * @param name - Unique identifier for this schema including the factory's scope.
425
+ * @param persistedMetadata - Optional persisted metadata for the object node schema.
426
426
  */
427
427
  // eslint-disable-next-line @typescript-eslint/explicit-function-return-type
428
- function arraySchema(identifier, info, implicitlyConstructable, customizable, metadata) {
428
+ function arraySchema(identifier, info, implicitlyConstructable, customizable, metadata, persistedMetadata) {
429
429
  const unannotatedTypes = (0, schemaTypes_js_1.unannotateImplicitAllowedTypes)(info);
430
430
  const lazyChildTypes = new internal_1.Lazy(() => (0, schemaTypes_js_1.normalizeAllowedTypes)(unannotatedTypes));
431
+ const lazyAnnotatedTypes = new internal_1.Lazy(() => [(0, schemaTypes_js_1.normalizeAnnotatedAllowedTypes)(info)]);
431
432
  const lazyAllowedTypesIdentifiers = new internal_1.Lazy(() => new Set([...lazyChildTypes.value].map((type) => type.identifier)));
432
433
  let unhydratedContext;
433
434
  // This class returns a proxy from its constructor to handle numeric indexing.
@@ -482,11 +483,14 @@ function arraySchema(identifier, info, implicitlyConstructable, customizable, me
482
483
  static get childTypes() {
483
484
  return lazyChildTypes.value;
484
485
  }
486
+ static get childAnnotatedAllowedTypes() {
487
+ return lazyAnnotatedTypes.value;
488
+ }
485
489
  // eslint-disable-next-line import/no-deprecated
486
- get [index_js_3.typeNameSymbol]() {
490
+ get [index_js_2.typeNameSymbol]() {
487
491
  return identifier;
488
492
  }
489
- get [index_js_3.typeSchemaSymbol]() {
493
+ get [index_js_2.typeSchemaSymbol]() {
490
494
  return Schema.constructorCached?.constructor;
491
495
  }
492
496
  get simpleSchema() {
@@ -501,6 +505,7 @@ function arraySchema(identifier, info, implicitlyConstructable, customizable, me
501
505
  Schema.info = info;
502
506
  Schema.implicitlyConstructable = implicitlyConstructable;
503
507
  Schema.metadata = metadata ?? {};
508
+ Schema.persistedMetadata = persistedMetadata;
504
509
  const output = Schema;
505
510
  return output;
506
511
  }