@ldo/solid-type-index 1.0.0-alpha.2 → 1.0.0-alpha.21

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 (136) hide show
  1. package/dist/{.ldo → cjs/.ldo}/profile.context.js +5 -0
  2. package/dist/cjs/.ldo/profile.context.js.map +1 -0
  3. package/dist/{.ldo → cjs/.ldo}/profile.schema.js +5 -0
  4. package/dist/cjs/.ldo/profile.schema.js.map +1 -0
  5. package/dist/cjs/.ldo/profile.shapeTypes.js +19 -0
  6. package/dist/cjs/.ldo/profile.shapeTypes.js.map +1 -0
  7. package/dist/cjs/.ldo/profile.typings.js.map +1 -0
  8. package/dist/{.ldo → cjs/.ldo}/typeIndex.context.js +5 -0
  9. package/dist/cjs/.ldo/typeIndex.context.js.map +1 -0
  10. package/dist/{.ldo → cjs/.ldo}/typeIndex.schema.js +5 -0
  11. package/dist/cjs/.ldo/typeIndex.schema.js.map +1 -0
  12. package/dist/cjs/.ldo/typeIndex.shapeTypes.js +27 -0
  13. package/dist/cjs/.ldo/typeIndex.shapeTypes.js.map +1 -0
  14. package/dist/cjs/.ldo/typeIndex.typings.js.map +1 -0
  15. package/dist/cjs/constants.js.map +1 -0
  16. package/dist/{getTypeIndex.js → cjs/getTypeIndex.js} +20 -15
  17. package/dist/cjs/getTypeIndex.js.map +1 -0
  18. package/dist/{index.js → cjs/index.js} +4 -4
  19. package/dist/cjs/index.js.map +1 -0
  20. package/dist/cjs/react/useInstanceUris.js +33 -0
  21. package/dist/cjs/react/useInstanceUris.js.map +1 -0
  22. package/dist/{react → cjs/react}/useTypeIndexProfile.js +3 -4
  23. package/dist/cjs/react/useTypeIndexProfile.js.map +1 -0
  24. package/dist/{react → cjs/react}/util/useSubscribeToUris.js +4 -2
  25. package/dist/cjs/react/util/useSubscribeToUris.js.map +1 -0
  26. package/dist/{setTypeIndex.js → cjs/setTypeIndex.js} +60 -21
  27. package/dist/cjs/setTypeIndex.js.map +1 -0
  28. package/dist/{util → cjs/util}/Options.js +1 -2
  29. package/dist/cjs/util/Options.js.map +1 -0
  30. package/dist/esm/.ldo/profile.context.js +18 -0
  31. package/dist/esm/.ldo/profile.context.js.map +1 -0
  32. package/dist/esm/.ldo/profile.schema.js +61 -0
  33. package/dist/esm/.ldo/profile.schema.js.map +1 -0
  34. package/dist/esm/.ldo/profile.shapeTypes.js +16 -0
  35. package/dist/esm/.ldo/profile.shapeTypes.js.map +1 -0
  36. package/dist/esm/.ldo/profile.typings.js +2 -0
  37. package/dist/esm/.ldo/profile.typings.js.map +1 -0
  38. package/dist/esm/.ldo/typeIndex.context.js +63 -0
  39. package/dist/esm/.ldo/typeIndex.context.js.map +1 -0
  40. package/dist/esm/.ldo/typeIndex.schema.js +143 -0
  41. package/dist/esm/.ldo/typeIndex.schema.js.map +1 -0
  42. package/dist/esm/.ldo/typeIndex.shapeTypes.js +24 -0
  43. package/dist/esm/.ldo/typeIndex.shapeTypes.js.map +1 -0
  44. package/dist/esm/.ldo/typeIndex.typings.js +2 -0
  45. package/dist/esm/.ldo/typeIndex.typings.js.map +1 -0
  46. package/dist/esm/constants.js +6 -0
  47. package/dist/esm/constants.js.map +1 -0
  48. package/dist/esm/getTypeIndex.js +61 -0
  49. package/dist/esm/getTypeIndex.js.map +1 -0
  50. package/dist/esm/index.js +5 -0
  51. package/dist/esm/index.js.map +1 -0
  52. package/dist/esm/react/useInstanceUris.js +30 -0
  53. package/dist/esm/react/useInstanceUris.js.map +1 -0
  54. package/dist/esm/react/useTypeIndexProfile.js +9 -0
  55. package/dist/esm/react/useTypeIndexProfile.js.map +1 -0
  56. package/dist/esm/react/util/useSubscribeToUris.js +30 -0
  57. package/dist/esm/react/util/useSubscribeToUris.js.map +1 -0
  58. package/dist/esm/setTypeIndex.js +156 -0
  59. package/dist/esm/setTypeIndex.js.map +1 -0
  60. package/dist/esm/util/Options.js +9 -0
  61. package/dist/esm/util/Options.js.map +1 -0
  62. package/dist/types/.ldo/profile.context.d.ts +8 -0
  63. package/dist/types/.ldo/profile.context.d.ts.map +1 -0
  64. package/dist/types/.ldo/profile.schema.d.ts +8 -0
  65. package/dist/types/.ldo/profile.schema.d.ts.map +1 -0
  66. package/dist/types/.ldo/profile.shapeTypes.d.ts +12 -0
  67. package/dist/types/.ldo/profile.shapeTypes.d.ts.map +1 -0
  68. package/dist/types/.ldo/profile.typings.d.ts +26 -0
  69. package/dist/types/.ldo/profile.typings.d.ts.map +1 -0
  70. package/dist/types/.ldo/typeIndex.context.d.ts +8 -0
  71. package/dist/types/.ldo/typeIndex.context.d.ts.map +1 -0
  72. package/dist/types/.ldo/typeIndex.schema.d.ts +8 -0
  73. package/dist/types/.ldo/typeIndex.schema.d.ts.map +1 -0
  74. package/dist/types/.ldo/typeIndex.shapeTypes.d.ts +16 -0
  75. package/dist/types/.ldo/typeIndex.shapeTypes.d.ts.map +1 -0
  76. package/dist/types/.ldo/typeIndex.typings.d.ts +53 -0
  77. package/dist/types/.ldo/typeIndex.typings.d.ts.map +1 -0
  78. package/dist/{constants.d.ts → types/constants.d.ts} +1 -0
  79. package/dist/types/constants.d.ts.map +1 -0
  80. package/dist/{getTypeIndex.d.ts → types/getTypeIndex.d.ts} +4 -3
  81. package/dist/types/getTypeIndex.d.ts.map +1 -0
  82. package/dist/types/index.d.ts +5 -0
  83. package/dist/types/index.d.ts.map +1 -0
  84. package/dist/types/react/useInstanceUris.d.ts +9 -0
  85. package/dist/types/react/useInstanceUris.d.ts.map +1 -0
  86. package/dist/types/react/useTypeIndexProfile.d.ts +3 -0
  87. package/dist/types/react/useTypeIndexProfile.d.ts.map +1 -0
  88. package/dist/{react → types/react}/util/useSubscribeToUris.d.ts +1 -0
  89. package/dist/types/react/util/useSubscribeToUris.d.ts.map +1 -0
  90. package/dist/types/setTypeIndex.d.ts +53 -0
  91. package/dist/types/setTypeIndex.d.ts.map +1 -0
  92. package/dist/{util → types/util}/Options.d.ts +1 -0
  93. package/dist/types/util/Options.d.ts.map +1 -0
  94. package/package.json +27 -18
  95. package/src/.ldo/profile.shapeTypes.ts +3 -3
  96. package/src/.ldo/typeIndex.shapeTypes.ts +3 -3
  97. package/src/getTypeIndex.ts +7 -7
  98. package/src/index.ts +4 -4
  99. package/src/react/useInstanceUris.ts +7 -5
  100. package/src/react/useTypeIndexProfile.ts +2 -2
  101. package/src/setTypeIndex.ts +10 -10
  102. package/src/util/Options.ts +0 -2
  103. package/dist/.ldo/profile.context.d.ts +0 -2
  104. package/dist/.ldo/profile.context.js.map +0 -1
  105. package/dist/.ldo/profile.schema.d.ts +0 -2
  106. package/dist/.ldo/profile.schema.js.map +0 -1
  107. package/dist/.ldo/profile.shapeTypes.d.ts +0 -3
  108. package/dist/.ldo/profile.shapeTypes.js +0 -11
  109. package/dist/.ldo/profile.shapeTypes.js.map +0 -1
  110. package/dist/.ldo/profile.typings.d.ts +0 -11
  111. package/dist/.ldo/profile.typings.js.map +0 -1
  112. package/dist/.ldo/typeIndex.context.d.ts +0 -2
  113. package/dist/.ldo/typeIndex.context.js.map +0 -1
  114. package/dist/.ldo/typeIndex.schema.d.ts +0 -2
  115. package/dist/.ldo/typeIndex.schema.js.map +0 -1
  116. package/dist/.ldo/typeIndex.shapeTypes.d.ts +0 -4
  117. package/dist/.ldo/typeIndex.shapeTypes.js +0 -16
  118. package/dist/.ldo/typeIndex.shapeTypes.js.map +0 -1
  119. package/dist/.ldo/typeIndex.typings.d.ts +0 -26
  120. package/dist/.ldo/typeIndex.typings.js.map +0 -1
  121. package/dist/constants.js.map +0 -1
  122. package/dist/getTypeIndex.js.map +0 -1
  123. package/dist/index.d.ts +0 -4
  124. package/dist/index.js.map +0 -1
  125. package/dist/react/useInstanceUris.d.ts +0 -2
  126. package/dist/react/useInstanceUris.js +0 -26
  127. package/dist/react/useInstanceUris.js.map +0 -1
  128. package/dist/react/useTypeIndexProfile.d.ts +0 -2
  129. package/dist/react/useTypeIndexProfile.js.map +0 -1
  130. package/dist/react/util/useSubscribeToUris.js.map +0 -1
  131. package/dist/setTypeIndex.d.ts +0 -14
  132. package/dist/setTypeIndex.js.map +0 -1
  133. package/dist/util/Options.js.map +0 -1
  134. /package/dist/{.ldo → cjs/.ldo}/profile.typings.js +0 -0
  135. /package/dist/{.ldo → cjs/.ldo}/typeIndex.typings.js +0 -0
  136. /package/dist/{constants.js → cjs/constants.js} +0 -0
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.profileContext = void 0;
4
+ /**
5
+ * =============================================================================
6
+ * profileContext: JSONLD Context for profile
7
+ * =============================================================================
8
+ */
4
9
  exports.profileContext = {
5
10
  privateTypeIndex: {
6
11
  "@id": "http://www.w3.org/ns/solid/terms#privateTypeIndex",
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.context.js","sourceRoot":"","sources":["../../../src/.ldo/profile.context.ts"],"names":[],"mappings":";;;AAEA;;;;GAIG;AACU,QAAA,cAAc,GAAqB;IAC9C,gBAAgB,EAAE;QAChB,KAAK,EAAE,mDAAmD;QAC1D,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;IACD,eAAe,EAAE;QACf,KAAK,EAAE,kDAAkD;QACzD,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;CACF,CAAC"}
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.profileSchema = void 0;
4
+ /**
5
+ * =============================================================================
6
+ * profileSchema: ShexJ Schema for profile
7
+ * =============================================================================
8
+ */
4
9
  exports.profileSchema = {
5
10
  type: "Schema",
6
11
  shapes: [
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.schema.js","sourceRoot":"","sources":["../../../src/.ldo/profile.schema.ts"],"names":[],"mappings":";;;AAEA;;;;GAIG;AACU,QAAA,aAAa,GAAW;IACnC,IAAI,EAAE,QAAQ;IACd,MAAM,EAAE;QACN;YACE,EAAE,EAAE,6DAA6D;YACjE,IAAI,EAAE,WAAW;YACjB,SAAS,EAAE;gBACT,IAAI,EAAE,OAAO;gBACb,UAAU,EAAE;oBACV,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE;wBACX;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,mDAAmD;4BAC9D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EACH,0EAA0E;qCAC7E;iCACF;6BACF;yBACF;wBACD;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,kDAAkD;4BAC7D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EACH,oEAAoE;qCACvE;iCACF;6BACF;yBACF;qBACF;iBACF;aACF;SACF;KACF;CACF,CAAC"}
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TypeIndexProfileShapeType = void 0;
4
+ const profile_schema_js_1 = require("./profile.schema.js");
5
+ const profile_context_js_1 = require("./profile.context.js");
6
+ /**
7
+ * =============================================================================
8
+ * LDO ShapeTypes profile
9
+ * =============================================================================
10
+ */
11
+ /**
12
+ * TypeIndexProfile ShapeType
13
+ */
14
+ exports.TypeIndexProfileShapeType = {
15
+ schema: profile_schema_js_1.profileSchema,
16
+ shape: "https://shaperepo.com/schemas/solidProfile#TypeIndexProfile",
17
+ context: profile_context_js_1.profileContext,
18
+ };
19
+ //# sourceMappingURL=profile.shapeTypes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.shapeTypes.js","sourceRoot":"","sources":["../../../src/.ldo/profile.shapeTypes.ts"],"names":[],"mappings":";;;AACA,2DAAoD;AACpD,6DAAsD;AAGtD;;;;GAIG;AAEH;;GAEG;AACU,QAAA,yBAAyB,GAAgC;IACpE,MAAM,EAAE,iCAAa;IACrB,KAAK,EAAE,6DAA6D;IACpE,OAAO,EAAE,mCAAc;CACxB,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.typings.js","sourceRoot":"","sources":["../../../src/.ldo/profile.typings.ts"],"names":[],"mappings":""}
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.typeIndexContext = void 0;
4
+ /**
5
+ * =============================================================================
6
+ * typeIndexContext: JSONLD Context for typeIndex
7
+ * =============================================================================
8
+ */
4
9
  exports.typeIndexContext = {
5
10
  type: {
6
11
  "@id": "@type",
@@ -0,0 +1 @@
1
+ {"version":3,"file":"typeIndex.context.js","sourceRoot":"","sources":["../../../src/.ldo/typeIndex.context.ts"],"names":[],"mappings":";;;AAEA;;;;GAIG;AACU,QAAA,gBAAgB,GAAqB;IAChD,IAAI,EAAE;QACJ,KAAK,EAAE,OAAO;KACf;IACD,SAAS,EAAE;QACT,KAAK,EAAE,4CAA4C;QACnD,UAAU,EAAE;YACV,IAAI,EAAE;gBACJ,KAAK,EAAE,OAAO;aACf;SACF;KACF;IACD,cAAc,EAAE;QACd,KAAK,EAAE,iDAAiD;QACxD,UAAU,EAAE;YACV,IAAI,EAAE;gBACJ,KAAK,EAAE,OAAO;aACf;SACF;KACF;IACD,gBAAgB,EAAE;QAChB,KAAK,EAAE,mDAAmD;QAC1D,UAAU,EAAE;YACV,IAAI,EAAE;gBACJ,KAAK,EAAE,OAAO;aACf;YACD,QAAQ,EAAE;gBACR,KAAK,EAAE,2CAA2C;gBAClD,OAAO,EAAE,KAAK;aACf;YACD,QAAQ,EAAE;gBACR,KAAK,EAAE,2CAA2C;gBAClD,OAAO,EAAE,KAAK;gBACd,eAAe,EAAE,IAAI;aACtB;YACD,iBAAiB,EAAE;gBACjB,KAAK,EAAE,oDAAoD;gBAC3D,OAAO,EAAE,KAAK;gBACd,eAAe,EAAE,IAAI;aACtB;SACF;KACF;IACD,QAAQ,EAAE;QACR,KAAK,EAAE,2CAA2C;QAClD,OAAO,EAAE,KAAK;KACf;IACD,QAAQ,EAAE;QACR,KAAK,EAAE,2CAA2C;QAClD,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;IACD,iBAAiB,EAAE;QACjB,KAAK,EAAE,oDAAoD;QAC3D,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;CACF,CAAC"}
@@ -1,6 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.typeIndexSchema = void 0;
4
+ /**
5
+ * =============================================================================
6
+ * typeIndexSchema: ShexJ Schema for typeIndex
7
+ * =============================================================================
8
+ */
4
9
  exports.typeIndexSchema = {
5
10
  type: "Schema",
6
11
  shapes: [
@@ -0,0 +1 @@
1
+ {"version":3,"file":"typeIndex.schema.js","sourceRoot":"","sources":["../../../src/.ldo/typeIndex.schema.ts"],"names":[],"mappings":";;;AAEA;;;;GAIG;AACU,QAAA,eAAe,GAAW;IACrC,IAAI,EAAE,QAAQ;IACd,MAAM,EAAE;QACN;YACE,EAAE,EAAE,8DAA8D;YAClE,IAAI,EAAE,WAAW;YACjB,SAAS,EAAE;gBACT,IAAI,EAAE,OAAO;gBACb,UAAU,EAAE;oBACV,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE;wBACX;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,iDAAiD;4BAC5D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,MAAM,EAAE,CAAC,4CAA4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K,EAAE,mCAAmC;qCAC3C;iCACF;6BACF;yBACF;wBACD;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,2CAA2C;4BACtD,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EAAE,8CAA8C;qCACtD;iCACF;6BACF;yBACF;wBACD;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,oDAAoD;4BAC/D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EAAE,mDAAmD;qCAC3D;iCACF;6BACF;yBACF;qBACF;iBACF;gBACD,KAAK,EAAE,CAAC,iDAAiD,CAAC;aAC3D;SACF;KACF;CACF,CAAC"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TypeRegistrationShapeType = exports.TypeIndexDocumentShapeType = void 0;
4
+ const typeIndex_schema_js_1 = require("./typeIndex.schema.js");
5
+ const typeIndex_context_js_1 = require("./typeIndex.context.js");
6
+ /**
7
+ * =============================================================================
8
+ * LDO ShapeTypes typeIndex
9
+ * =============================================================================
10
+ */
11
+ /**
12
+ * TypeIndexDocument ShapeType
13
+ */
14
+ exports.TypeIndexDocumentShapeType = {
15
+ schema: typeIndex_schema_js_1.typeIndexSchema,
16
+ shape: "https://shaperepo.com/schemas/solidProfile#TypeIndexDocument",
17
+ context: typeIndex_context_js_1.typeIndexContext,
18
+ };
19
+ /**
20
+ * TypeRegistration ShapeType
21
+ */
22
+ exports.TypeRegistrationShapeType = {
23
+ schema: typeIndex_schema_js_1.typeIndexSchema,
24
+ shape: "https://shaperepo.com/schemas/solidProfile#TypeRegistration",
25
+ context: typeIndex_context_js_1.typeIndexContext,
26
+ };
27
+ //# sourceMappingURL=typeIndex.shapeTypes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"typeIndex.shapeTypes.js","sourceRoot":"","sources":["../../../src/.ldo/typeIndex.shapeTypes.ts"],"names":[],"mappings":";;;AACA,+DAAwD;AACxD,iEAA0D;AAG1D;;;;GAIG;AAEH;;GAEG;AACU,QAAA,0BAA0B,GAAiC;IACtE,MAAM,EAAE,qCAAe;IACvB,KAAK,EAAE,8DAA8D;IACrE,OAAO,EAAE,uCAAgB;CAC1B,CAAC;AAEF;;GAEG;AACU,QAAA,yBAAyB,GAAgC;IACpE,MAAM,EAAE,qCAAe;IACvB,KAAK,EAAE,6DAA6D;IACpE,OAAO,EAAE,uCAAgB;CAC1B,CAAC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"typeIndex.typings.js","sourceRoot":"","sources":["../../../src/.ldo/typeIndex.typings.ts"],"names":[],"mappings":""}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,QAAQ,GAAG,iDAAiD,CAAC;AAC7D,QAAA,iBAAiB,GAC5B,mDAAmD,CAAC;AACzC,QAAA,SAAS,GAAG,2CAA2C,CAAC;AACxD,QAAA,QAAQ,GAAG,2CAA2C,CAAC;AACvD,QAAA,kBAAkB,GAC7B,oDAAoD,CAAC"}
@@ -1,34 +1,39 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getInstanceUris = exports.getTypeIndexesUrisFromProfile = exports.getProfile = exports.getTypeRegistrations = void 0;
4
- const profile_shapeTypes_1 = require("./.ldo/profile.shapeTypes");
5
- const typeIndex_shapeTypes_1 = require("./.ldo/typeIndex.shapeTypes");
6
- const constants_1 = require("./constants");
7
- const Options_1 = require("./util/Options");
3
+ exports.getTypeRegistrations = getTypeRegistrations;
4
+ exports.getProfile = getProfile;
5
+ exports.getTypeIndexesUrisFromProfile = getTypeIndexesUrisFromProfile;
6
+ exports.getInstanceUris = getInstanceUris;
7
+ const profile_shapeTypes_js_1 = require("./.ldo/profile.shapeTypes.js");
8
+ const typeIndex_shapeTypes_js_1 = require("./.ldo/typeIndex.shapeTypes.js");
9
+ const constants_js_1 = require("./constants.js");
10
+ const Options_js_1 = require("./util/Options.js");
8
11
  async function getTypeRegistrations(webId, options) {
9
- const { dataset } = (0, Options_1.guaranteeOptions)(options);
12
+ const { dataset } = (0, Options_js_1.guaranteeOptions)(options);
13
+ // Get Profile
10
14
  const profile = await getProfile(webId, options);
15
+ // Get Type Indexes
11
16
  const typeIndexUris = getTypeIndexesUrisFromProfile(profile);
17
+ // Fetch the type Indexes
12
18
  await Promise.all(typeIndexUris.map(async (typeIndexUri) => {
13
19
  const typeIndexResource = dataset.getResource(typeIndexUri);
14
20
  const readResult = await typeIndexResource.readIfUnfetched();
15
21
  if (readResult.isError)
16
22
  throw readResult;
17
23
  }));
24
+ // Get Type Registrations
18
25
  return dataset
19
- .usingType(typeIndex_shapeTypes_1.TypeRegistrationShapeType)
20
- .matchSubject(constants_1.RDF_TYPE, constants_1.TYPE_REGISTRATION);
26
+ .usingType(typeIndex_shapeTypes_js_1.TypeRegistrationShapeType)
27
+ .matchSubject(constants_js_1.RDF_TYPE, constants_js_1.TYPE_REGISTRATION);
21
28
  }
22
- exports.getTypeRegistrations = getTypeRegistrations;
23
29
  async function getProfile(webId, options) {
24
- const { dataset } = (0, Options_1.guaranteeOptions)(options);
30
+ const { dataset } = (0, Options_js_1.guaranteeOptions)(options);
25
31
  const profileResource = dataset.getResource(webId);
26
32
  const readResult = await profileResource.readIfUnfetched();
27
33
  if (readResult.isError)
28
34
  throw readResult;
29
- return dataset.usingType(profile_shapeTypes_1.TypeIndexProfileShapeType).fromSubject(webId);
35
+ return dataset.usingType(profile_shapeTypes_js_1.TypeIndexProfileShapeType).fromSubject(webId);
30
36
  }
31
- exports.getProfile = getProfile;
32
37
  function getTypeIndexesUrisFromProfile(profile) {
33
38
  const uris = [];
34
39
  profile.privateTypeIndex?.forEach((indexNode) => {
@@ -39,13 +44,14 @@ function getTypeIndexesUrisFromProfile(profile) {
39
44
  });
40
45
  return uris;
41
46
  }
42
- exports.getTypeIndexesUrisFromProfile = getTypeIndexesUrisFromProfile;
43
47
  async function getInstanceUris(classUri, typeRegistrations, options) {
44
- const { dataset } = (0, Options_1.guaranteeOptions)(options);
48
+ const { dataset } = (0, Options_js_1.guaranteeOptions)(options);
45
49
  const leafUris = new Set();
46
50
  await Promise.all(typeRegistrations.map(async (registration) => {
47
51
  if (registration.forClass["@id"] === classUri) {
52
+ // Individual registrations
48
53
  registration.instance?.forEach((instance) => leafUris.add(instance["@id"]));
54
+ // Container registrations
49
55
  await Promise.all(registration.instanceContainer?.map(async (instanceContainer) => {
50
56
  const containerResource = dataset.getResource(instanceContainer["@id"]);
51
57
  await containerResource.readIfUnfetched();
@@ -58,5 +64,4 @@ async function getInstanceUris(classUri, typeRegistrations, options) {
58
64
  }));
59
65
  return Array.from(leafUris);
60
66
  }
61
- exports.getInstanceUris = getInstanceUris;
62
67
  //# sourceMappingURL=getTypeIndex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getTypeIndex.js","sourceRoot":"","sources":["../../src/getTypeIndex.ts"],"names":[],"mappings":";;AAUA,oDAyBC;AAED,gCASC;AAED,sEAWC;AAED,0CA+BC;AA1FD,wEAAyE;AACzE,4EAA2E;AAC3E,iDAA6D;AAE7D,kDAAqD;AAI9C,KAAK,UAAU,oBAAoB,CACxC,KAAa,EACb,OAAiB;IAEjB,MAAM,EAAE,OAAO,EAAE,GAAG,IAAA,6BAAgB,EAAC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AAC,CAAC,IAAI,EAAE,CACT,CAAC;QACJ,CAAC;IACH,CAAC,CAAC,CACH,CAAC;IACF,OAAO,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;AAC9B,CAAC"}
@@ -14,8 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./getTypeIndex"), exports);
18
- __exportStar(require("./setTypeIndex"), exports);
19
- __exportStar(require("./react/useInstanceUris"), exports);
20
- __exportStar(require("./react/useTypeIndexProfile"), exports);
17
+ __exportStar(require("./getTypeIndex.js"), exports);
18
+ __exportStar(require("./setTypeIndex.js"), exports);
19
+ __exportStar(require("./react/useInstanceUris.js"), exports);
20
+ __exportStar(require("./react/useTypeIndexProfile.js"), exports);
21
21
  //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,oDAAkC;AAClC,6DAA2C;AAC3C,iEAA+C"}
@@ -0,0 +1,33 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.useInstanceUris = useInstanceUris;
4
+ const useTypeIndexProfile_js_1 = require("./useTypeIndexProfile.js");
5
+ const react_1 = require("react");
6
+ const useSubscribeToUris_js_1 = require("./util/useSubscribeToUris.js");
7
+ const solid_react_1 = require("@ldo/solid-react");
8
+ const typeIndex_shapeTypes_js_1 = require("../.ldo/typeIndex.shapeTypes.js");
9
+ const constants_js_1 = require("../constants.js");
10
+ const getTypeIndex_js_1 = require("../getTypeIndex.js");
11
+ /**
12
+ * Provides the LeafUris of everything in a type node for a specific class uri
13
+ *
14
+ * @param classUri - the class uri
15
+ * @returns - URIs of all resources registered with this node
16
+ */
17
+ function useInstanceUris(classUri) {
18
+ const { dataset } = (0, solid_react_1.useLdo)();
19
+ const profile = (0, useTypeIndexProfile_js_1.useTypeIndexProfile)();
20
+ const typeIndexUris = (0, react_1.useMemo)(() => (profile ? (0, getTypeIndex_js_1.getTypeIndexesUrisFromProfile)(profile) : []), [profile]);
21
+ (0, useSubscribeToUris_js_1.useSubscribeToUris)(typeIndexUris);
22
+ const [leafUris, setLeafUris] = (0, react_1.useState)([]);
23
+ const typeRegistrations = (0, solid_react_1.useMatchSubject)(typeIndex_shapeTypes_js_1.TypeRegistrationShapeType, constants_js_1.RDF_TYPE, constants_js_1.TYPE_REGISTRATION);
24
+ (0, react_1.useEffect)(() => {
25
+ (0, getTypeIndex_js_1.getInstanceUris)(classUri, typeRegistrations.toArray(), {
26
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
27
+ // @ts-ignore TODO: come back and see if we can fix this
28
+ solidLdoDataset: dataset,
29
+ }).then(setLeafUris);
30
+ }, [typeRegistrations]);
31
+ return leafUris;
32
+ }
33
+ //# sourceMappingURL=useInstanceUris.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useInstanceUris.js","sourceRoot":"","sources":["../../../src/react/useInstanceUris.ts"],"names":[],"mappings":";;AAkBA,0CA4BC;AA9CD,qEAA+D;AAC/D,iCAAqD;AACrD,wEAAkE;AAClE,kDAA2D;AAC3D,6EAA4E;AAC5E,kDAA8D;AAC9D,wDAG4B;AAG5B;;;;;GAKG;AACH,SAAgB,eAAe,CAAC,QAAgB;IAC9C,MAAM,EAAE,OAAO,EAAE,GAAG,IAAA,oBAAM,GAAE,CAAC;IAC7B,MAAM,OAAO,GAAG,IAAA,4CAAmB,GAAE,CAAC;IAEtC,MAAM,aAAa,GAAa,IAAA,eAAO,EACrC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,IAAA,+CAA6B,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAC7D,CAAC,OAAO,CAAC,CACV,CAAC;IAEF,IAAA,0CAAkB,EAAC,aAAa,CAAC,CAAC;IAElC,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,IAAA,gBAAQ,EAAiB,EAAE,CAAC,CAAC;IAE7D,MAAM,iBAAiB,GAAG,IAAA,6BAAe,EACvC,mDAAyB,EACzB,uBAAQ,EACR,gCAAiB,CAClB,CAAC;IAEF,IAAA,iBAAS,EAAC,GAAG,EAAE;QACb,IAAA,iCAAe,EAAC,QAAQ,EAAE,iBAAiB,CAAC,OAAO,EAAE,EAAE;YACrD,6DAA6D;YAC7D,wDAAwD;YACxD,eAAe,EAAE,OAAO;SACzB,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IACvB,CAAC,EAAE,CAAC,iBAAiB,CAAC,CAAC,CAAC;IAExB,OAAO,QAAQ,CAAC;AAClB,CAAC"}
@@ -1,13 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useTypeIndexProfile = void 0;
3
+ exports.useTypeIndexProfile = useTypeIndexProfile;
4
4
  const solid_react_1 = require("@ldo/solid-react");
5
- const profile_shapeTypes_1 = require("../.ldo/profile.shapeTypes");
5
+ const profile_shapeTypes_js_1 = require("../.ldo/profile.shapeTypes.js");
6
6
  function useTypeIndexProfile() {
7
7
  const { session } = (0, solid_react_1.useSolidAuth)();
8
8
  (0, solid_react_1.useResource)(session.webId, { subscribe: true });
9
- const profile = (0, solid_react_1.useSubject)(profile_shapeTypes_1.TypeIndexProfileShapeType, session.webId);
9
+ const profile = (0, solid_react_1.useSubject)(profile_shapeTypes_js_1.TypeIndexProfileShapeType, session.webId);
10
10
  return profile;
11
11
  }
12
- exports.useTypeIndexProfile = useTypeIndexProfile;
13
12
  //# sourceMappingURL=useTypeIndexProfile.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useTypeIndexProfile.js","sourceRoot":"","sources":["../../../src/react/useTypeIndexProfile.ts"],"names":[],"mappings":";;AAIA,kDAKC;AATD,kDAAyE;AAEzE,yEAA0E;AAE1E,SAAgB,mBAAmB;IACjC,MAAM,EAAE,OAAO,EAAE,GAAG,IAAA,0BAAY,GAAE,CAAC;IACnC,IAAA,yBAAW,EAAC,OAAO,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IAChD,MAAM,OAAO,GAAG,IAAA,wBAAU,EAAC,iDAAyB,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;IACrE,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useSubscribeToUris = void 0;
3
+ exports.useSubscribeToUris = useSubscribeToUris;
4
4
  const solid_react_1 = require("@ldo/solid-react");
5
5
  const react_1 = require("react");
6
6
  function useSubscribeToUris(uris) {
@@ -11,6 +11,7 @@ function useSubscribeToUris(uris) {
11
11
  const previousSubscriptions = { ...currentlySubscribed.current };
12
12
  Promise.all(resources.map(async (resource) => {
13
13
  if (!previousSubscriptions[resource.uri]) {
14
+ // Read and subscribe
14
15
  await resource.readIfUnfetched();
15
16
  currentlySubscribed.current[resource.uri] =
16
17
  await resource.subscribeToNotifications();
@@ -19,7 +20,9 @@ function useSubscribeToUris(uris) {
19
20
  delete previousSubscriptions[resource.uri];
20
21
  }
21
22
  })).then(async () => {
23
+ // Unsubscribe from all remaining previous subscriptions
22
24
  await Promise.all(Object.entries(previousSubscriptions).map(async ([resourceUri, subscriptionId]) => {
25
+ // Unsubscribe
23
26
  delete currentlySubscribed.current[resourceUri];
24
27
  const resource = dataset.getResource(resourceUri);
25
28
  await resource.unsubscribeFromNotifications(subscriptionId);
@@ -27,5 +30,4 @@ function useSubscribeToUris(uris) {
27
30
  });
28
31
  }, [uris]);
29
32
  }
30
- exports.useSubscribeToUris = useSubscribeToUris;
31
33
  //# sourceMappingURL=useSubscribeToUris.js.map
@@ -0,0 +1 @@
1
+ {"version":3,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ChD,MAAM,QAAQ,GAAG,OAAO,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC;gBAClD,MAAM,QAAQ,CAAC,4BAA4B,CAAC,cAAc,CAAC,CAAC;YAC9D,CAAC,CACF,CACF,CAAC;QACJ,CAAC,CAAC,CAAC;IACL,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;AACb,CAAC"}
@@ -1,17 +1,27 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.findAppropriateTypeRegistration = exports.removeRegistration = exports.addRegistration = exports.createIndex = exports.initTypeIndex = void 0;
3
+ exports.initTypeIndex = initTypeIndex;
4
+ exports.createIndex = createIndex;
5
+ exports.addRegistration = addRegistration;
6
+ exports.removeRegistration = removeRegistration;
7
+ exports.findAppropriateTypeRegistration = findAppropriateTypeRegistration;
8
+ /* eslint-disable @typescript-eslint/no-explicit-any */
4
9
  const uuid_1 = require("uuid");
5
- const typeIndex_shapeTypes_1 = require("./.ldo/typeIndex.shapeTypes");
6
- const constants_1 = require("./constants");
7
- const Options_1 = require("./util/Options");
8
- const data_model_1 = require("@rdfjs/data-model");
9
- const getTypeIndex_1 = require("./getTypeIndex");
10
- const profile_shapeTypes_1 = require("./.ldo/profile.shapeTypes");
10
+ const constants_js_1 = require("./constants.js");
11
+ const Options_js_1 = require("./util/Options.js");
12
+ const rdf_utils_1 = require("@ldo/rdf-utils");
13
+ const getTypeIndex_js_1 = require("./getTypeIndex.js");
14
+ const profile_shapeTypes_js_1 = require("./.ldo/profile.shapeTypes.js");
11
15
  const ldo_1 = require("@ldo/ldo");
16
+ const typeIndex_shapeTypes_js_1 = require("./.ldo/typeIndex.shapeTypes.js");
17
+ /**
18
+ * =============================================================================
19
+ * INITIALIZERS
20
+ * =============================================================================
21
+ */
12
22
  async function initTypeIndex(webId, options) {
13
- const { dataset } = (0, Options_1.guaranteeOptions)(options);
14
- const profile = await (0, getTypeIndex_1.getProfile)(webId, options);
23
+ const { dataset } = (0, Options_js_1.guaranteeOptions)(options);
24
+ const profile = await (0, getTypeIndex_js_1.getProfile)(webId, options);
15
25
  if (!profile.privateTypeIndex?.size || !profile.publicTypeIndex?.size) {
16
26
  const profileFolder = await dataset
17
27
  .getResource(webId)
@@ -28,8 +38,14 @@ async function initTypeIndex(webId, options) {
28
38
  }
29
39
  }
30
40
  }
31
- exports.initTypeIndex = initTypeIndex;
41
+ /**
42
+ * @internal
43
+ * @param webId
44
+ * @param profileFolder
45
+ * @param dataset
46
+ */
32
47
  async function createIndex(webId, profileFolder, dataset, isPrivate) {
48
+ // Create a private type index
33
49
  const createResult = await profileFolder.createChildAndOverwrite(`${isPrivate ? "private" : "public"}_index_${(0, uuid_1.v4)()}`);
34
50
  if (createResult.isError)
35
51
  throw createResult;
@@ -55,7 +71,7 @@ async function createIndex(webId, profileFolder, dataset, isPrivate) {
55
71
  throw wacResult;
56
72
  const transaction = dataset.startTransaction();
57
73
  const cProfile = transaction
58
- .usingType(profile_shapeTypes_1.TypeIndexProfileShapeType)
74
+ .usingType(profile_shapeTypes_js_1.TypeIndexProfileShapeType)
59
75
  .write(dataset.getResource(webId).uri)
60
76
  .fromSubject(webId);
61
77
  if (isPrivate) {
@@ -65,7 +81,7 @@ async function createIndex(webId, profileFolder, dataset, isPrivate) {
65
81
  cProfile.publicTypeIndex?.add({ "@id": indexResource.uri });
66
82
  }
67
83
  const cTypeIndex = transaction
68
- .usingType(typeIndex_shapeTypes_1.TypeIndexDocumentShapeType)
84
+ .usingType(typeIndex_shapeTypes_js_1.TypeIndexDocumentShapeType)
69
85
  .write(indexResource.uri)
70
86
  .fromSubject(indexResource.uri);
71
87
  cTypeIndex.type = (0, ldo_1.set)({ "@id": "ListedDocument" }, { "@id": "TypeIndex" });
@@ -73,9 +89,17 @@ async function createIndex(webId, profileFolder, dataset, isPrivate) {
73
89
  if (commitResult.isError)
74
90
  throw commitResult;
75
91
  }
76
- exports.createIndex = createIndex;
92
+ /**
93
+ * Adds an instance to a TypeRegistration
94
+ * @param indexUri The URI of the TypeIndex
95
+ * @param classUri The URI for the class the instance should be added to
96
+ * @param instances Objects representing the instances to add
97
+ * @param options Options
98
+ */
77
99
  function addRegistration(indexUri, classUri, instances, options) {
100
+ // Check to see if its already in the index
78
101
  const typeRegistration = findAppropriateTypeRegistration(indexUri, classUri, options);
102
+ // Add instances to type registration
79
103
  instances.instance?.forEach((instance) => {
80
104
  typeRegistration.instance?.add({ "@id": instance });
81
105
  });
@@ -83,9 +107,17 @@ function addRegistration(indexUri, classUri, instances, options) {
83
107
  typeRegistration.instanceContainer?.add({ "@id": instanceContainer });
84
108
  });
85
109
  }
86
- exports.addRegistration = addRegistration;
110
+ /**
111
+ * Removes instances from a TypeRegistration
112
+ * @param indexUri The URI of the TypeIndex
113
+ * @param classUri The URI for the class the instance should be removed from
114
+ * @param instances Objects representing the instances to remove
115
+ * @param options Options
116
+ */
87
117
  async function removeRegistration(indexUri, classUri, instances, options) {
118
+ // Check to see if its already in the index
88
119
  const typeRegistration = findAppropriateTypeRegistration(indexUri, classUri, options);
120
+ // Add instances to type registration
89
121
  instances.instance?.forEach((instanceUri) => {
90
122
  typeRegistration.instance?.delete({ "@id": instanceUri });
91
123
  });
@@ -93,26 +125,34 @@ async function removeRegistration(indexUri, classUri, instances, options) {
93
125
  typeRegistration.instanceContainer?.delete({ "@id": instanceContainerUri });
94
126
  });
95
127
  }
96
- exports.removeRegistration = removeRegistration;
128
+ /**
129
+ * Finds a TypeRegistration inside of a type index. If it doesn't exist, it
130
+ * creates one.
131
+ * @param indexUri The URI of the typeIndex
132
+ * @param classUri The URI of the class in question for the TypeRegistration
133
+ * @param options
134
+ * @returns The Type Index
135
+ */
97
136
  function findAppropriateTypeRegistration(indexUri, classUri, options) {
98
- const { dataset } = (0, Options_1.guaranteeOptions)(options);
137
+ const { dataset } = (0, Options_js_1.guaranteeOptions)(options);
138
+ // Check to see if its already in the index
99
139
  const existingRegistrationsUris = dataset
100
- .match(null, (0, data_model_1.namedNode)(constants_1.RDF_TYPE), (0, data_model_1.namedNode)(constants_1.TYPE_REGISTRATION), (0, data_model_1.namedNode)(indexUri))
140
+ .match(null, (0, rdf_utils_1.namedNode)(constants_js_1.RDF_TYPE), (0, rdf_utils_1.namedNode)(constants_js_1.TYPE_REGISTRATION), (0, rdf_utils_1.namedNode)(indexUri))
101
141
  .toArray()
102
142
  .map((quad) => quad.subject);
103
143
  const existingRegistrationForClassUri = existingRegistrationsUris.find((registrationUri) => {
104
- return dataset.has((0, data_model_1.quad)(registrationUri, (0, data_model_1.namedNode)(constants_1.FOR_CLASS), (0, data_model_1.namedNode)(classUri), (0, data_model_1.namedNode)(indexUri)));
144
+ return dataset.has((0, rdf_utils_1.quad)(registrationUri, (0, rdf_utils_1.namedNode)(constants_js_1.FOR_CLASS), (0, rdf_utils_1.namedNode)(classUri), (0, rdf_utils_1.namedNode)(indexUri)));
105
145
  })?.value;
106
146
  let typeRegistration;
107
147
  if (existingRegistrationForClassUri) {
108
148
  typeRegistration = dataset
109
- .usingType(typeIndex_shapeTypes_1.TypeRegistrationShapeType)
149
+ .usingType(typeIndex_shapeTypes_js_1.TypeRegistrationShapeType)
110
150
  .write(indexUri)
111
151
  .fromSubject(existingRegistrationForClassUri);
112
152
  }
113
153
  else {
114
154
  typeRegistration = dataset
115
- .usingType(typeIndex_shapeTypes_1.TypeRegistrationShapeType)
155
+ .usingType(typeIndex_shapeTypes_js_1.TypeRegistrationShapeType)
116
156
  .write(indexUri)
117
157
  .fromSubject(`${indexUri}#${(0, uuid_1.v4)()}`);
118
158
  typeRegistration.type = { "@id": "TypeRegistration" };
@@ -120,5 +160,4 @@ function findAppropriateTypeRegistration(indexUri, classUri, options) {
120
160
  }
121
161
  return typeRegistration;
122
162
  }
123
- exports.findAppropriateTypeRegistration = findAppropriateTypeRegistration;
124
163
  //# sourceMappingURL=setTypeIndex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setTypeIndex.js","sourceRoot":"","sources":["../../src/setTypeIndex.ts"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AC;IACvC,IAAI,+BAA+B,EAAE,CAAC;QACpC,gBAAgB,GAAG,OAAO;aACvB,SAAS,CAAC,mDAAyB,CAAC;aACpC,KAAK,CAAC,QAAQ,CAAC;aACf,WAAW,CAAC,+BAA+B,CAAC,CAAC;IAClD,CAAC;SAAM,CAAC;QACN,gBAAgB,GAAG,OAAO;aACvB,SAAS,CAAC,mDAAyB,CAAC;aACpC,KAAK,CAAC,QAAQ,CAAC;aACf,WAAW,CAAC,GAAG,QAAQ,IAAI,IAAA,SAAE,GAAE,EAAE,CAAC,CAAC;QACtC,gBAAgB,CAAC,IAAI,GAAG,EAAE,KAAK,EAAE,kBAAkB,EAAE,CAAC;QACtD,gBAAgB,CAAC,QAAQ,GAAG,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;IAClD,CAAC;IACD,OAAO,gBAAgB,CAAC;AAC1B,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.guaranteeOptions = void 0;
3
+ exports.guaranteeOptions = guaranteeOptions;
4
4
  const connected_solid_1 = require("@ldo/connected-solid");
5
5
  function guaranteeOptions(options) {
6
6
  const fetch = (0, connected_solid_1.guaranteeFetch)(options?.fetch);
@@ -9,5 +9,4 @@ function guaranteeOptions(options) {
9
9
  dataset.setContext("solid", { fetch });
10
10
  return { fetch, dataset };
11
11
  }
12
- exports.guaranteeOptions = guaranteeOptions;
13
12
  //# sourceMappingURL=Options.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Options.js","sourceRoot":"","sources":["../../../src/util/Options.ts"],"names":[],"mappings":";;AAUA,4CAMC;AAbD,0DAA6E;AAO7E,SAAgB,gBAAgB,CAAC,OAAiB;IAChD,MAAM,KAAK,GAAG,IAAA,gCAAc,EAAC,OAAO,EAAE,KAAK,CAAC,CAAC;IAC7C,MAAM,OAAO,GAAG,CAAC,OAAO,EAAE,eAAe;QACvC,IAAA,uCAAqB,GAAE,CAAgD,CAAC;IAC1E,OAAO,CAAC,UAAU,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IACvC,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC;AAC5B,CAAC"}
@@ -0,0 +1,18 @@
1
+ /**
2
+ * =============================================================================
3
+ * profileContext: JSONLD Context for profile
4
+ * =============================================================================
5
+ */
6
+ export const profileContext = {
7
+ privateTypeIndex: {
8
+ "@id": "http://www.w3.org/ns/solid/terms#privateTypeIndex",
9
+ "@type": "@id",
10
+ "@isCollection": true,
11
+ },
12
+ publicTypeIndex: {
13
+ "@id": "http://www.w3.org/ns/solid/terms#publicTypeIndex",
14
+ "@type": "@id",
15
+ "@isCollection": true,
16
+ },
17
+ };
18
+ //# sourceMappingURL=profile.context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.context.js","sourceRoot":"","sources":["../../../src/.ldo/profile.context.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,MAAM,CAAC,MAAM,cAAc,GAAqB;IAC9C,gBAAgB,EAAE;QAChB,KAAK,EAAE,mDAAmD;QAC1D,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;IACD,eAAe,EAAE;QACf,KAAK,EAAE,kDAAkD;QACzD,OAAO,EAAE,KAAK;QACd,eAAe,EAAE,IAAI;KACtB;CACF,CAAC"}
@@ -0,0 +1,61 @@
1
+ /**
2
+ * =============================================================================
3
+ * profileSchema: ShexJ Schema for profile
4
+ * =============================================================================
5
+ */
6
+ export const profileSchema = {
7
+ type: "Schema",
8
+ shapes: [
9
+ {
10
+ id: "https://shaperepo.com/schemas/solidProfile#TypeIndexProfile",
11
+ type: "ShapeDecl",
12
+ shapeExpr: {
13
+ type: "Shape",
14
+ expression: {
15
+ type: "EachOf",
16
+ expressions: [
17
+ {
18
+ type: "TripleConstraint",
19
+ predicate: "http://www.w3.org/ns/solid/terms#privateTypeIndex",
20
+ valueExpr: {
21
+ type: "NodeConstraint",
22
+ nodeKind: "iri",
23
+ },
24
+ min: 0,
25
+ max: -1,
26
+ annotations: [
27
+ {
28
+ type: "Annotation",
29
+ predicate: "http://www.w3.org/2000/01/rdf-schema#comment",
30
+ object: {
31
+ value: "A registry of all types used on the user's Pod (for private access only)",
32
+ },
33
+ },
34
+ ],
35
+ },
36
+ {
37
+ type: "TripleConstraint",
38
+ predicate: "http://www.w3.org/ns/solid/terms#publicTypeIndex",
39
+ valueExpr: {
40
+ type: "NodeConstraint",
41
+ nodeKind: "iri",
42
+ },
43
+ min: 0,
44
+ max: -1,
45
+ annotations: [
46
+ {
47
+ type: "Annotation",
48
+ predicate: "http://www.w3.org/2000/01/rdf-schema#comment",
49
+ object: {
50
+ value: "A registry of all types used on the user's Pod (for public access)",
51
+ },
52
+ },
53
+ ],
54
+ },
55
+ ],
56
+ },
57
+ },
58
+ },
59
+ ],
60
+ };
61
+ //# sourceMappingURL=profile.schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profile.schema.js","sourceRoot":"","sources":["../../../src/.ldo/profile.schema.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,MAAM,CAAC,MAAM,aAAa,GAAW;IACnC,IAAI,EAAE,QAAQ;IACd,MAAM,EAAE;QACN;YACE,EAAE,EAAE,6DAA6D;YACjE,IAAI,EAAE,WAAW;YACjB,SAAS,EAAE;gBACT,IAAI,EAAE,OAAO;gBACb,UAAU,EAAE;oBACV,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE;wBACX;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,mDAAmD;4BAC9D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EACH,0EAA0E;qCAC7E;iCACF;6BACF;yBACF;wBACD;4BACE,IAAI,EAAE,kBAAkB;4BACxB,SAAS,EAAE,kDAAkD;4BAC7D,SAAS,EAAE;gCACT,IAAI,EAAE,gBAAgB;gCACtB,QAAQ,EAAE,KAAK;6BAChB;4BACD,GAAG,EAAE,CAAC;4BACN,GAAG,EAAE,CAAC,CAAC;4BACP,WAAW,EAAE;gCACX;oCACE,IAAI,EAAE,YAAY;oCAClB,SAAS,EAAE,8CAA8C;oCACzD,MAAM,EAAE;wCACN,KAAK,EACH,oEAAoE;qCACvE;iCACF;6BACF;yBACF;qBACF;iBACF;aACF;SACF;KACF;CACF,CAAC"}