@rljson/rljson 0.0.30 → 0.0.31

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.
@@ -26,7 +26,7 @@ export interface Cake extends Json {
26
26
  /**
27
27
  * The table containing the item collections defining the layers
28
28
  */
29
- collections: TableKey;
29
+ collectionsTable: TableKey;
30
30
  /**
31
31
  * Assigns a collection to each layer of the cake.
32
32
  */
@@ -28,7 +28,7 @@ export interface Collection extends Json {
28
28
  * The table containing the properties that are assigned to the items
29
29
  * with the assign property below
30
30
  */
31
- properties: TableKey;
31
+ propertiesTable: TableKey;
32
32
  /**
33
33
  * Assign properties to each item of the collection.
34
34
  */
package/dist/rljson.js CHANGED
@@ -45,7 +45,7 @@ const bakeryExample = () => {
45
45
  _type: "collections",
46
46
  _data: [
47
47
  {
48
- properties: "recipeIngredients",
48
+ propertiesTable: "recipeIngredients",
49
49
  assign: {
50
50
  flour: recipeIngredients._data[0]._hash
51
51
  },
@@ -57,7 +57,7 @@ const bakeryExample = () => {
57
57
  _type: "collections",
58
58
  _data: [
59
59
  {
60
- properties: "recipes",
60
+ propertiesTable: "recipes",
61
61
  assign: {
62
62
  slice0: recipes._data[0]._hash,
63
63
  slice1: recipes._data[0]._hash
@@ -82,7 +82,7 @@ const bakeryExample = () => {
82
82
  {
83
83
  idSetsTable: "slices",
84
84
  idSet: slices._data[0]._hash,
85
- collections: "layers",
85
+ collectionsTable: "layers",
86
86
  layers: {
87
87
  flour: layers._data[0]._hash
88
88
  },
@@ -275,14 +275,14 @@ __publicField(_Example, "ok", {
275
275
  const collection0 = hip({
276
276
  idSetsTable: "idSets",
277
277
  idSet: "MgHRBYSrhpyl4rvsOmAWcQ",
278
- properties: "properties",
278
+ propertiesTable: "properties",
279
279
  assign: {}
280
280
  });
281
281
  const collection1 = hip({
282
282
  base: collection0._hash,
283
283
  idSetsTable: "idSets",
284
284
  idSet: "MgHRBYSrhpyl4rvsOmAWcQ",
285
- properties: "properties",
285
+ propertiesTable: "properties",
286
286
  assign: {
287
287
  id0: property0._hash,
288
288
  id1: property1._hash
@@ -295,7 +295,7 @@ __publicField(_Example, "ok", {
295
295
  const cake = hip({
296
296
  idSetsTable: "idSets",
297
297
  idSet: idSets._data[0]._hash,
298
- collections: "collections",
298
+ collectionsTable: "collections",
299
299
  layers: {
300
300
  layer0: collection0._hash,
301
301
  layer1: collection1._hash
@@ -435,7 +435,7 @@ __publicField(_Example, "broken", {
435
435
  },
436
436
  missingCollectionsTable: () => {
437
437
  const result = _Example.ok.complete();
438
- result.cakes._data[0].collections = "MISSING";
438
+ result.cakes._data[0].collectionsTable = "MISSING";
439
439
  hip(result.cakes, true, false);
440
440
  return result;
441
441
  },
@@ -1075,7 +1075,7 @@ class _BaseValidator {
1075
1075
  }
1076
1076
  const collectionsTable = table;
1077
1077
  for (const collection of collectionsTable._data) {
1078
- const propertyTableKey = collection.properties;
1078
+ const propertyTableKey = collection.propertiesTable;
1079
1079
  const propertiesTable = this.rljsonIndexed[propertyTableKey];
1080
1080
  if (!propertiesTable) {
1081
1081
  missingPropertyTables.push({
@@ -1185,7 +1185,7 @@ class _BaseValidator {
1185
1185
  }
1186
1186
  const cakesTable = table;
1187
1187
  for (const cake of cakesTable._data) {
1188
- const collectionsTableKey = cake.collections;
1188
+ const collectionsTableKey = cake.collectionsTable;
1189
1189
  const collectionsTable = this.rljsonIndexed[collectionsTableKey];
1190
1190
  if (!collectionsTable) {
1191
1191
  missingCollectionTables.push({
@@ -175,7 +175,7 @@ export class Example {
175
175
  const collection0: Collection = hip({
176
176
  idSetsTable: 'idSets',
177
177
  idSet: 'MgHRBYSrhpyl4rvsOmAWcQ',
178
- properties: 'properties',
178
+ propertiesTable: 'properties',
179
179
  assign: {},
180
180
  });
181
181
 
@@ -183,7 +183,7 @@ export class Example {
183
183
  base: collection0._hash as string,
184
184
  idSetsTable: 'idSets',
185
185
  idSet: 'MgHRBYSrhpyl4rvsOmAWcQ',
186
- properties: 'properties',
186
+ propertiesTable: 'properties',
187
187
  assign: {
188
188
  id0: property0._hash,
189
189
  id1: property1._hash,
@@ -198,7 +198,7 @@ export class Example {
198
198
  const cake: Cake = hip({
199
199
  idSetsTable: 'idSets',
200
200
  idSet: idSets._data[0]._hash as string,
201
- collections: 'collections',
201
+ collectionsTable: 'collections',
202
202
  layers: {
203
203
  layer0: collection0._hash as string,
204
204
  layer1: collection1._hash as string,
@@ -356,7 +356,7 @@ export class Example {
356
356
 
357
357
  missingCollectionsTable: (): Rljson => {
358
358
  const result = Example.ok.complete();
359
- result.cakes._data[0].collections = 'MISSING'; // Missing collections table
359
+ result.cakes._data[0].collectionsTable = 'MISSING'; // Missing collections table
360
360
  hip(result.cakes, true, false);
361
361
  return result;
362
362
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rljson/rljson",
3
- "version": "0.0.30",
3
+ "version": "0.0.31",
4
4
  "packageManager": "pnpm@10.6.3",
5
5
  "description": "The RLJSON data format specification",
6
6
  "homepage": "https://github.com/rljson/rljson",