@fluidframework/tree 2.40.0 → 2.41.0-338186

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 (198) hide show
  1. package/api-report/tree.alpha.api.md +1 -1
  2. package/dist/feature-libraries/default-schema/schemaChecker.d.ts.map +1 -1
  3. package/dist/feature-libraries/default-schema/schemaChecker.js +0 -7
  4. package/dist/feature-libraries/default-schema/schemaChecker.js.map +1 -1
  5. package/dist/feature-libraries/flex-tree/context.d.ts +16 -14
  6. package/dist/feature-libraries/flex-tree/context.d.ts.map +1 -1
  7. package/dist/feature-libraries/flex-tree/context.js +12 -18
  8. package/dist/feature-libraries/flex-tree/context.js.map +1 -1
  9. package/dist/feature-libraries/flex-tree/index.d.ts +1 -1
  10. package/dist/feature-libraries/flex-tree/index.d.ts.map +1 -1
  11. package/dist/feature-libraries/flex-tree/index.js +1 -2
  12. package/dist/feature-libraries/flex-tree/index.js.map +1 -1
  13. package/dist/feature-libraries/flex-tree/lazyField.d.ts +1 -5
  14. package/dist/feature-libraries/flex-tree/lazyField.d.ts.map +1 -1
  15. package/dist/feature-libraries/flex-tree/lazyField.js +2 -16
  16. package/dist/feature-libraries/flex-tree/lazyField.js.map +1 -1
  17. package/dist/feature-libraries/flex-tree/utilities.d.ts +6 -6
  18. package/dist/feature-libraries/flex-tree/utilities.d.ts.map +1 -1
  19. package/dist/feature-libraries/flex-tree/utilities.js +6 -7
  20. package/dist/feature-libraries/flex-tree/utilities.js.map +1 -1
  21. package/dist/feature-libraries/index.d.ts +1 -1
  22. package/dist/feature-libraries/index.d.ts.map +1 -1
  23. package/dist/feature-libraries/index.js +1 -2
  24. package/dist/feature-libraries/index.js.map +1 -1
  25. package/dist/packageVersion.d.ts +1 -1
  26. package/dist/packageVersion.d.ts.map +1 -1
  27. package/dist/packageVersion.js +1 -1
  28. package/dist/packageVersion.js.map +1 -1
  29. package/dist/shared-tree/checkoutFlexTreeView.d.ts +7 -3
  30. package/dist/shared-tree/checkoutFlexTreeView.d.ts.map +1 -1
  31. package/dist/shared-tree/checkoutFlexTreeView.js +11 -2
  32. package/dist/shared-tree/checkoutFlexTreeView.js.map +1 -1
  33. package/dist/shared-tree/schematizeTree.d.ts +1 -1
  34. package/dist/shared-tree/schematizeTree.js +1 -1
  35. package/dist/shared-tree/schematizeTree.js.map +1 -1
  36. package/dist/shared-tree/schematizingTreeView.d.ts +3 -0
  37. package/dist/shared-tree/schematizingTreeView.d.ts.map +1 -1
  38. package/dist/shared-tree/schematizingTreeView.js +13 -7
  39. package/dist/shared-tree/schematizingTreeView.js.map +1 -1
  40. package/dist/shared-tree/treeAlpha.d.ts +1 -4
  41. package/dist/shared-tree/treeAlpha.d.ts.map +1 -1
  42. package/dist/shared-tree/treeAlpha.js +6 -1
  43. package/dist/shared-tree/treeAlpha.js.map +1 -1
  44. package/dist/simple-tree/api/create.d.ts +5 -1
  45. package/dist/simple-tree/api/create.d.ts.map +1 -1
  46. package/dist/simple-tree/api/create.js +10 -11
  47. package/dist/simple-tree/api/create.js.map +1 -1
  48. package/dist/simple-tree/api/index.d.ts +2 -2
  49. package/dist/simple-tree/api/index.d.ts.map +1 -1
  50. package/dist/simple-tree/api/index.js +2 -2
  51. package/dist/simple-tree/api/index.js.map +1 -1
  52. package/dist/simple-tree/api/storedSchema.d.ts +1 -8
  53. package/dist/simple-tree/api/storedSchema.d.ts.map +1 -1
  54. package/dist/simple-tree/api/storedSchema.js +3 -14
  55. package/dist/simple-tree/api/storedSchema.js.map +1 -1
  56. package/dist/simple-tree/arrayNode.d.ts.map +1 -1
  57. package/dist/simple-tree/arrayNode.js +3 -9
  58. package/dist/simple-tree/arrayNode.js.map +1 -1
  59. package/dist/simple-tree/core/unhydratedFlexTree.d.ts +4 -4
  60. package/dist/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  61. package/dist/simple-tree/core/unhydratedFlexTree.js +9 -5
  62. package/dist/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  63. package/dist/simple-tree/index.d.ts +3 -2
  64. package/dist/simple-tree/index.d.ts.map +1 -1
  65. package/dist/simple-tree/index.js +6 -4
  66. package/dist/simple-tree/index.js.map +1 -1
  67. package/dist/simple-tree/mapNode.d.ts.map +1 -1
  68. package/dist/simple-tree/mapNode.js +17 -20
  69. package/dist/simple-tree/mapNode.js.map +1 -1
  70. package/dist/simple-tree/objectNode.d.ts.map +1 -1
  71. package/dist/simple-tree/objectNode.js +2 -4
  72. package/dist/simple-tree/objectNode.js.map +1 -1
  73. package/dist/simple-tree/prepareForInsertion.d.ts +30 -0
  74. package/dist/simple-tree/prepareForInsertion.d.ts.map +1 -0
  75. package/dist/simple-tree/prepareForInsertion.js +137 -0
  76. package/dist/simple-tree/prepareForInsertion.js.map +1 -0
  77. package/dist/simple-tree/proxies.d.ts +1 -12
  78. package/dist/simple-tree/proxies.d.ts.map +1 -1
  79. package/dist/simple-tree/proxies.js +10 -106
  80. package/dist/simple-tree/proxies.js.map +1 -1
  81. package/dist/simple-tree/toMapTree.d.ts +1 -1
  82. package/dist/simple-tree/toMapTree.js +1 -1
  83. package/dist/simple-tree/toMapTree.js.map +1 -1
  84. package/dist/tableSchema.d.ts +108 -59
  85. package/dist/tableSchema.d.ts.map +1 -1
  86. package/dist/tableSchema.js +93 -44
  87. package/dist/tableSchema.js.map +1 -1
  88. package/lib/feature-libraries/default-schema/schemaChecker.d.ts.map +1 -1
  89. package/lib/feature-libraries/default-schema/schemaChecker.js +0 -7
  90. package/lib/feature-libraries/default-schema/schemaChecker.js.map +1 -1
  91. package/lib/feature-libraries/flex-tree/context.d.ts +16 -14
  92. package/lib/feature-libraries/flex-tree/context.d.ts.map +1 -1
  93. package/lib/feature-libraries/flex-tree/context.js +11 -16
  94. package/lib/feature-libraries/flex-tree/context.js.map +1 -1
  95. package/lib/feature-libraries/flex-tree/index.d.ts +1 -1
  96. package/lib/feature-libraries/flex-tree/index.d.ts.map +1 -1
  97. package/lib/feature-libraries/flex-tree/index.js +1 -1
  98. package/lib/feature-libraries/flex-tree/index.js.map +1 -1
  99. package/lib/feature-libraries/flex-tree/lazyField.d.ts +1 -5
  100. package/lib/feature-libraries/flex-tree/lazyField.d.ts.map +1 -1
  101. package/lib/feature-libraries/flex-tree/lazyField.js +1 -14
  102. package/lib/feature-libraries/flex-tree/lazyField.js.map +1 -1
  103. package/lib/feature-libraries/flex-tree/utilities.d.ts +6 -6
  104. package/lib/feature-libraries/flex-tree/utilities.d.ts.map +1 -1
  105. package/lib/feature-libraries/flex-tree/utilities.js +6 -7
  106. package/lib/feature-libraries/flex-tree/utilities.js.map +1 -1
  107. package/lib/feature-libraries/index.d.ts +1 -1
  108. package/lib/feature-libraries/index.d.ts.map +1 -1
  109. package/lib/feature-libraries/index.js +1 -1
  110. package/lib/feature-libraries/index.js.map +1 -1
  111. package/lib/packageVersion.d.ts +1 -1
  112. package/lib/packageVersion.d.ts.map +1 -1
  113. package/lib/packageVersion.js +1 -1
  114. package/lib/packageVersion.js.map +1 -1
  115. package/lib/shared-tree/checkoutFlexTreeView.d.ts +7 -3
  116. package/lib/shared-tree/checkoutFlexTreeView.d.ts.map +1 -1
  117. package/lib/shared-tree/checkoutFlexTreeView.js +12 -3
  118. package/lib/shared-tree/checkoutFlexTreeView.js.map +1 -1
  119. package/lib/shared-tree/schematizeTree.d.ts +1 -1
  120. package/lib/shared-tree/schematizeTree.js +1 -1
  121. package/lib/shared-tree/schematizeTree.js.map +1 -1
  122. package/lib/shared-tree/schematizingTreeView.d.ts +3 -0
  123. package/lib/shared-tree/schematizingTreeView.d.ts.map +1 -1
  124. package/lib/shared-tree/schematizingTreeView.js +14 -8
  125. package/lib/shared-tree/schematizingTreeView.js.map +1 -1
  126. package/lib/shared-tree/treeAlpha.d.ts +1 -4
  127. package/lib/shared-tree/treeAlpha.d.ts.map +1 -1
  128. package/lib/shared-tree/treeAlpha.js +7 -2
  129. package/lib/shared-tree/treeAlpha.js.map +1 -1
  130. package/lib/simple-tree/api/create.d.ts +5 -1
  131. package/lib/simple-tree/api/create.d.ts.map +1 -1
  132. package/lib/simple-tree/api/create.js +8 -10
  133. package/lib/simple-tree/api/create.js.map +1 -1
  134. package/lib/simple-tree/api/index.d.ts +2 -2
  135. package/lib/simple-tree/api/index.d.ts.map +1 -1
  136. package/lib/simple-tree/api/index.js +2 -2
  137. package/lib/simple-tree/api/index.js.map +1 -1
  138. package/lib/simple-tree/api/storedSchema.d.ts +1 -8
  139. package/lib/simple-tree/api/storedSchema.d.ts.map +1 -1
  140. package/lib/simple-tree/api/storedSchema.js +2 -12
  141. package/lib/simple-tree/api/storedSchema.js.map +1 -1
  142. package/lib/simple-tree/arrayNode.d.ts.map +1 -1
  143. package/lib/simple-tree/arrayNode.js +4 -10
  144. package/lib/simple-tree/arrayNode.js.map +1 -1
  145. package/lib/simple-tree/core/unhydratedFlexTree.d.ts +4 -4
  146. package/lib/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  147. package/lib/simple-tree/core/unhydratedFlexTree.js +9 -5
  148. package/lib/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  149. package/lib/simple-tree/index.d.ts +3 -2
  150. package/lib/simple-tree/index.d.ts.map +1 -1
  151. package/lib/simple-tree/index.js +3 -2
  152. package/lib/simple-tree/index.js.map +1 -1
  153. package/lib/simple-tree/mapNode.d.ts.map +1 -1
  154. package/lib/simple-tree/mapNode.js +3 -6
  155. package/lib/simple-tree/mapNode.js.map +1 -1
  156. package/lib/simple-tree/objectNode.d.ts.map +1 -1
  157. package/lib/simple-tree/objectNode.js +4 -6
  158. package/lib/simple-tree/objectNode.js.map +1 -1
  159. package/lib/simple-tree/prepareForInsertion.d.ts +30 -0
  160. package/lib/simple-tree/prepareForInsertion.d.ts.map +1 -0
  161. package/lib/simple-tree/prepareForInsertion.js +131 -0
  162. package/lib/simple-tree/prepareForInsertion.js.map +1 -0
  163. package/lib/simple-tree/proxies.d.ts +1 -12
  164. package/lib/simple-tree/proxies.d.ts.map +1 -1
  165. package/lib/simple-tree/proxies.js +1 -96
  166. package/lib/simple-tree/proxies.js.map +1 -1
  167. package/lib/simple-tree/toMapTree.d.ts +1 -1
  168. package/lib/simple-tree/toMapTree.js +1 -1
  169. package/lib/simple-tree/toMapTree.js.map +1 -1
  170. package/lib/tableSchema.d.ts +108 -59
  171. package/lib/tableSchema.d.ts.map +1 -1
  172. package/lib/tableSchema.js +94 -45
  173. package/lib/tableSchema.js.map +1 -1
  174. package/lib/tsdoc-metadata.json +1 -1
  175. package/package.json +25 -25
  176. package/src/feature-libraries/default-schema/schemaChecker.ts +0 -8
  177. package/src/feature-libraries/flex-tree/context.ts +18 -20
  178. package/src/feature-libraries/flex-tree/index.ts +0 -1
  179. package/src/feature-libraries/flex-tree/lazyField.ts +2 -14
  180. package/src/feature-libraries/flex-tree/utilities.ts +8 -8
  181. package/src/feature-libraries/index.ts +0 -1
  182. package/src/packageVersion.ts +1 -1
  183. package/src/shared-tree/checkoutFlexTreeView.ts +10 -6
  184. package/src/shared-tree/schematizeTree.ts +1 -1
  185. package/src/shared-tree/schematizingTreeView.ts +14 -14
  186. package/src/shared-tree/treeAlpha.ts +21 -5
  187. package/src/simple-tree/api/create.ts +15 -15
  188. package/src/simple-tree/api/index.ts +6 -2
  189. package/src/simple-tree/api/storedSchema.ts +2 -19
  190. package/src/simple-tree/arrayNode.ts +9 -20
  191. package/src/simple-tree/core/unhydratedFlexTree.ts +10 -5
  192. package/src/simple-tree/index.ts +6 -5
  193. package/src/simple-tree/mapNode.ts +8 -12
  194. package/src/simple-tree/objectNode.ts +3 -12
  195. package/src/simple-tree/prepareForInsertion.ts +236 -0
  196. package/src/simple-tree/proxies.ts +2 -147
  197. package/src/simple-tree/toMapTree.ts +1 -1
  198. package/src/tableSchema.ts +310 -158
@@ -19,6 +19,32 @@ const index_js_2 = require("./simple-tree/index.js");
19
19
  * The sub-scope applied to user-provided {@link SchemaFactory}s by table schema factories.
20
20
  */
21
21
  const tableSchemaFactorySubScope = "table";
22
+ /**
23
+ * Gets the table containing the provided row/column node, if the node is part of a table.
24
+ * @remarks Assumes that the table is the grandparent of the row/column node.
25
+ */
26
+ function getParentTable(rowOrColumnNode) {
27
+ const rowListNode = index_js_1.Tree.parent(rowOrColumnNode);
28
+ if (rowListNode === undefined || !(0, index_js_2.isArrayNodeSchema)(index_js_1.Tree.schema(rowListNode))) {
29
+ return undefined;
30
+ }
31
+ const tableNode = index_js_1.Tree.parent(rowListNode);
32
+ if (tableNode === undefined || !isTableNode(tableNode)) {
33
+ return undefined;
34
+ }
35
+ return tableNode;
36
+ }
37
+ /**
38
+ * A private symbol put on table schema to help identify them.
39
+ */
40
+ const tableSchemaSymbol = Symbol("tableNode");
41
+ /**
42
+ * Type-guard to determine if a node is a table node.
43
+ * @remarks Uses {@link tableSchemaSymbol} to identify table nodes.
44
+ */
45
+ function isTableNode(node) {
46
+ return tableSchemaSymbol in index_js_1.Tree.schema(node);
47
+ }
22
48
  /**
23
49
  * Not intended for use outside of this package.
24
50
  *
@@ -32,11 +58,11 @@ const tableSchemaFactorySubScope = "table";
32
58
  var System_TableSchema;
33
59
  (function (System_TableSchema) {
34
60
  /**
35
- * Factory for creating new table column schema.
61
+ * Factory for creating column schema.
36
62
  * @system @internal
37
63
  */
38
64
  // eslint-disable-next-line @typescript-eslint/explicit-function-return-type -- Return type is too complex to be reasonable to specify
39
- function createColumnInternal(inputSchemaFactory, propsSchema) {
65
+ function createColumnSchema(inputSchemaFactory, cellSchema, propsSchema) {
40
66
  const schemaFactory = inputSchemaFactory.scopedFactory(tableSchemaFactorySubScope);
41
67
  // Note: `columnFields` is broken into two parts to work around a TypeScript bug
42
68
  // that results in broken `.d.ts` output.
@@ -69,6 +95,23 @@ var System_TableSchema;
69
95
  // Will make it easier to evolve this schema in the future.
70
96
  allowUnknownOptionalFields: true,
71
97
  }) {
98
+ getCells() {
99
+ const tableNode = getParentTable(this);
100
+ if (tableNode === undefined) {
101
+ throw new internal_2.UsageError(`Column with ID "${this.id}" is not contained in a table.`);
102
+ }
103
+ const result = [];
104
+ for (const row of tableNode.rows) {
105
+ const cell = row.getCell(this.id);
106
+ if (cell !== undefined) {
107
+ if (!index_js_1.Tree.is(cell, cellSchema)) {
108
+ throw new internal_2.UsageError("Parent table contains a cell with incompatible with this column.");
109
+ }
110
+ result.push({ rowId: row.id, cell: cell });
111
+ }
112
+ }
113
+ return result;
114
+ }
72
115
  }
73
116
  // Returning SingletonSchema without a type conversion results in TypeScript generating something like `readonly "__#124291@#brand": unknown;`
74
117
  // for the private brand field of TreeNode.
@@ -78,14 +121,13 @@ var System_TableSchema;
78
121
  const ColumnSchemaType = Column;
79
122
  return ColumnSchemaType;
80
123
  }
81
- System_TableSchema.createColumnInternal = createColumnInternal;
124
+ System_TableSchema.createColumnSchema = createColumnSchema;
82
125
  /**
83
- * Factory for creating new table row schema.
84
- *
126
+ * Factory for creating row schema.
85
127
  * @sealed @internal
86
128
  */
87
129
  // eslint-disable-next-line @typescript-eslint/explicit-function-return-type -- Return type is too complex to be reasonable to specify
88
- function createRowInternal(inputSchemaFactory, cellSchema, propsSchema) {
130
+ function createRowSchema(inputSchemaFactory, cellSchema, propsSchema) {
89
131
  const schemaFactory = inputSchemaFactory.scopedFactory(tableSchemaFactorySubScope);
90
132
  // Note: `rowFields` is broken into two parts to work around a TypeScript bug
91
133
  // that results in broken `.d.ts` output.
@@ -139,6 +181,18 @@ var System_TableSchema;
139
181
  this.cells.delete(columnId);
140
182
  return cell;
141
183
  }
184
+ getCells() {
185
+ const result = [];
186
+ for (const [columnId, cell] of this.cells.entries()) {
187
+ if (cell !== undefined) {
188
+ result.push({
189
+ columnId,
190
+ cell,
191
+ });
192
+ }
193
+ }
194
+ return result;
195
+ }
142
196
  }
143
197
  // Returning SingletonSchema without a type conversion results in TypeScript generating something like `readonly "__#124291@#brand": unknown;`
144
198
  // for the private brand field of TreeNode.
@@ -148,13 +202,13 @@ var System_TableSchema;
148
202
  const RowSchemaType = Row;
149
203
  return RowSchemaType;
150
204
  }
151
- System_TableSchema.createRowInternal = createRowInternal;
205
+ System_TableSchema.createRowSchema = createRowSchema;
152
206
  /**
153
- * Factory for creating new table schema.
207
+ * Factory for creating table schema.
154
208
  * @system @internal
155
209
  */
156
210
  // eslint-disable-next-line @typescript-eslint/explicit-function-return-type -- Return type is too complex to be reasonable to specify
157
- function createTableInternal(inputSchemaFactory, _cellSchema, columnSchema, rowSchema) {
211
+ function createTableSchema(inputSchemaFactory, _cellSchema, columnSchema, rowSchema) {
158
212
  const schemaFactory = inputSchemaFactory.scopedFactory(tableSchemaFactorySubScope);
159
213
  /**
160
214
  * {@link Table} fields.
@@ -172,6 +226,9 @@ var System_TableSchema;
172
226
  // Will make it easier to evolve this schema in the future.
173
227
  allowUnknownOptionalFields: true,
174
228
  }) {
229
+ static empty() {
230
+ return new this({ columns: [], rows: [] });
231
+ }
175
232
  getColumn(id) {
176
233
  // TypeScript is unable to narrow the types correctly here, hence the casts.
177
234
  // See: https://github.com/microsoft/TypeScript/issues/52144
@@ -202,21 +259,10 @@ var System_TableSchema;
202
259
  return inserted[0] ?? (0, internal_1.oob)();
203
260
  }
204
261
  insertColumns({ columns, index, }) {
205
- // #region Input validation
206
262
  // Ensure index is valid
207
263
  if (index !== undefined) {
208
264
  Table.validateInsertionIndex(index, this.columns);
209
265
  }
210
- // Check all of the columns being inserted an ensure the table does not already contain any with the same ID.
211
- for (const column of columns) {
212
- // TypeScript is unable to narrow the type of the column type correctly here, hence the casts below.
213
- // See: https://github.com/microsoft/TypeScript/issues/52144
214
- const maybeId = column.id;
215
- if (maybeId !== undefined && this.containsColumnWithId(maybeId)) {
216
- throw new internal_2.UsageError(`A column with ID "${column.id}" already exists in the table.`);
217
- }
218
- }
219
- // #endregion
220
266
  // TypeScript is unable to narrow the column type correctly here, hence the casts below.
221
267
  // See: https://github.com/microsoft/TypeScript/issues/52144
222
268
  if (index === undefined) {
@@ -246,11 +292,6 @@ var System_TableSchema;
246
292
  // Note: TypeScript is unable to narrow the type of the row type correctly here, hence the casts below.
247
293
  // See: https://github.com/microsoft/TypeScript/issues/52144
248
294
  for (const newRow of rows) {
249
- // Check all of the rows being inserted an ensure the table does not already contain any with the same ID.
250
- const maybeId = newRow.id;
251
- if (maybeId !== undefined && this.containsRowWithId(maybeId)) {
252
- throw new internal_2.UsageError(`A row with ID "${newRow.id}" already exists in the table.`);
253
- }
254
295
  // If the row contains cells, verify that the table contains the columns for those cells.
255
296
  // Note: we intentionally hide `cells` on `IRow` to avoid leaking the internal data representation as much as possible, so we have to cast here.
256
297
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
@@ -401,13 +442,13 @@ var System_TableSchema;
401
442
  containsColumnWithId(columnId) {
402
443
  // TypeScript is unable to narrow the types correctly here, hence the cast.
403
444
  // See: https://github.com/microsoft/TypeScript/issues/52144
404
- return (this.columns.find((column) => column.id === columnId) !==
405
- undefined);
445
+ return (this.columns.find((column) => column.id === columnId) !== undefined);
406
446
  }
407
447
  containsRowWithId(rowId) {
408
448
  // TypeScript is unable to narrow the types correctly here, hence the cast.
409
449
  // See: https://github.com/microsoft/TypeScript/issues/52144
410
- return this.rows.find((row) => row.id === rowId) !== undefined;
450
+ return (this.rows.find((row) => row.id === rowId) !==
451
+ undefined);
411
452
  }
412
453
  /**
413
454
  * Ensure that the specified index is a valid location for item insertion in the destination list.
@@ -425,6 +466,12 @@ var System_TableSchema;
425
466
  }
426
467
  }
427
468
  }
469
+ // Set a private symbol on the schema class that marks it as having been generated by this factory.
470
+ // Column / Row functionality use this to validate that they are being used in a table.
471
+ // This is effectively a work-around that allows columns and rows to invoke table methods
472
+ // without having to pass the table as a parameter to their construction, which isn't possible.
473
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
474
+ Table[tableSchemaSymbol] = true;
428
475
  // Returning SingletonSchema without a type conversion results in TypeScript generating something like `readonly "__#124291@#brand": unknown;`
429
476
  // for the private brand field of TreeNode.
430
477
  // This numeric id doesn't seem to be stable over incremental builds, and thus causes diffs in the API extractor reports.
@@ -434,7 +481,7 @@ var System_TableSchema;
434
481
  // Return the table schema
435
482
  return TableSchemaType;
436
483
  }
437
- System_TableSchema.createTableInternal = createTableInternal;
484
+ System_TableSchema.createTableSchema = createTableSchema;
438
485
  // #endregion
439
486
  })(System_TableSchema || (exports.System_TableSchema = System_TableSchema = {}));
440
487
  /**
@@ -468,7 +515,7 @@ var System_TableSchema;
468
515
  * value: schemaFactory.string,
469
516
  * }) {}
470
517
  *
471
- * class Table extends TableSchema.createTable({
518
+ * class Table extends TableSchema.table({
472
519
  * schemaFactory,
473
520
  * cell: Cell,
474
521
  * }) {}
@@ -493,17 +540,18 @@ var System_TableSchema;
493
540
  * dataType: schemaFactory.optional(schemaFactory.string),
494
541
  * }) {}
495
542
  *
496
- * class Column extends TableSchema.createColumn({
543
+ * class Column extends TableSchema.column({
497
544
  * schemaFactory,
545
+ * cell: Cell,
498
546
  * props: ColumnProps,
499
547
  * }) {}
500
548
  *
501
- * class Row extends TableSchema.createRow({
549
+ * class Row extends TableSchema.row({
502
550
  * schemaFactory,
503
551
  * cell: Cell,
504
552
  * }) {}
505
553
  *
506
- * class Table extends TableSchema.createTable({
554
+ * class Table extends TableSchema.table({
507
555
  * schemaFactory,
508
556
  * cell: Cell,
509
557
  * column: Column,
@@ -532,29 +580,30 @@ var TableSchema;
532
580
  /**
533
581
  * Overload implementation
534
582
  */
535
- function createColumn({ schemaFactory, props = index_js_2.SchemaFactory.optional(index_js_2.SchemaFactory.null), }) {
536
- return System_TableSchema.createColumnInternal(schemaFactory, props);
583
+ function column({ schemaFactory, cell, props = index_js_2.SchemaFactory.optional(index_js_2.SchemaFactory.null), }) {
584
+ return System_TableSchema.createColumnSchema(schemaFactory, cell, props);
537
585
  }
538
- TableSchema.createColumn = createColumn;
586
+ TableSchema.column = column;
539
587
  /**
540
588
  * Overload implementation
541
589
  */
542
- function createRow({ schemaFactory, cell, props = index_js_2.SchemaFactory.optional(index_js_2.SchemaFactory.null), }) {
543
- return System_TableSchema.createRowInternal(schemaFactory, cell, props);
590
+ function row({ schemaFactory, cell, props = index_js_2.SchemaFactory.optional(index_js_2.SchemaFactory.null), }) {
591
+ return System_TableSchema.createRowSchema(schemaFactory, cell, props);
544
592
  }
545
- TableSchema.createRow = createRow;
593
+ TableSchema.row = row;
546
594
  /**
547
595
  * Overload implementation
548
596
  */
549
- function createTable({ schemaFactory, cell, column = createColumn({
597
+ function table({ schemaFactory, cell: cellSchema, column: columnSchema = column({
550
598
  schemaFactory,
551
- }), row = createRow({
599
+ cell: cellSchema,
600
+ }), row: rowSchema = row({
552
601
  schemaFactory,
553
- cell,
602
+ cell: cellSchema,
554
603
  }), }) {
555
- return System_TableSchema.createTableInternal(schemaFactory, cell, column, row);
604
+ return System_TableSchema.createTableSchema(schemaFactory, cellSchema, columnSchema, rowSchema);
556
605
  }
557
- TableSchema.createTable = createTable;
606
+ TableSchema.table = table;
558
607
  // #endregion
559
608
  })(TableSchema || (exports.TableSchema = TableSchema = {}));
560
609
  //# sourceMappingURL=tableSchema.js.map