@startinblox/core 0.19.0-beta.3 → 0.19.0-beta.4

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.
package/dist/index.js CHANGED
@@ -10979,7 +10979,7 @@ class CustomGetter {
10979
10979
  this.getExpandedPredicate("ldp:BasicContainer"),
10980
10980
  this.getExpandedPredicate("ldp:DirectContainer"),
10981
10981
  this.getExpandedPredicate("ldp:IndirectContainer"),
10982
- "sib:federatedContainer"
10982
+ this.getExpandedPredicate("sib:federatedContainer")
10983
10983
  ];
10984
10984
  }
10985
10985
  /**
@@ -11261,18 +11261,27 @@ function appendServerPaginationToIri(iri, options) {
11261
11261
  const ContextParser2 = JSONLDContextParser.ContextParser;
11262
11262
  const myParser = new ContextParser2();
11263
11263
  const base_context = {
11264
- "@vocab": "http://happy-dev.fr/owl/#",
11265
- rdf: "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
11266
- rdfs: "http://www.w3.org/2000/01/rdf-schema#",
11267
- ldp: "http://www.w3.org/ns/ldp#",
11264
+ "@vocab": "https://cdn.startinblox.com/owl#",
11268
11265
  foaf: "http://xmlns.com/foaf/0.1/",
11269
- name: "rdfs:label",
11266
+ doap: "http://usefulinc.com/ns/doap#",
11267
+ ldp: "http://www.w3.org/ns/ldp#",
11268
+ rdfs: "http://www.w3.org/2000/01/rdf-schema#",
11269
+ rdf: "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
11270
+ xsd: "http://www.w3.org/2001/XMLSchema#",
11271
+ geo: "http://www.w3.org/2003/01/geo/wgs84_pos#",
11270
11272
  acl: "http://www.w3.org/ns/auth/acl#",
11273
+ name: "rdfs:label",
11274
+ deadline: "xsd:dateTime",
11275
+ lat: "geo:lat",
11276
+ lng: "geo:long",
11277
+ jabberID: "foaf:jabberID",
11271
11278
  permissions: "acl:accessControl",
11272
11279
  mode: "acl:mode",
11273
- geo: "http://www.w3.org/2003/01/geo/wgs84_pos#",
11274
- lat: "geo:lat",
11275
- lng: "geo:long"
11280
+ view: "acl:Read",
11281
+ change: "acl:Write",
11282
+ add: "acl:Append",
11283
+ delete: "acl:Delete",
11284
+ control: "acl:Control"
11276
11285
  };
11277
11286
  class Store {
11278
11287
  constructor(storeOptions) {
@@ -12691,12 +12700,15 @@ const MultipleselectFormMixin = {
12691
12700
  setDataSrc(value, listValueTransformations) {
12692
12701
  if (value && value !== this.dataSrc) {
12693
12702
  try {
12694
- if (Array.isArray(JSON.parse(value))) {
12695
- this.setValue(JSON.parse(value));
12703
+ let values = JSON.parse(value);
12704
+ if (values && Array.isArray(values)) {
12705
+ this.setValue(values);
12706
+ } else {
12707
+ this.setValue([value]);
12696
12708
  }
12697
12709
  } catch (ex) {
12698
12710
  this.dataSrc = value;
12699
- console.log("Not an array", ex);
12711
+ this.setValue([{ "@id": value }]);
12700
12712
  }
12701
12713
  }
12702
12714
  const nextProcessor = listValueTransformations.shift();
@@ -12874,7 +12886,7 @@ const FederationMixin = {
12874
12886
  return [];
12875
12887
  const newResources = [];
12876
12888
  const getChildResources = async (res) => {
12877
- var _a, _b;
12889
+ var _a;
12878
12890
  if (!res)
12879
12891
  return;
12880
12892
  if ((_a = res.isContainer) == null ? void 0 : _a.call(res)) {
@@ -12885,10 +12897,6 @@ const FederationMixin = {
12885
12897
  if (resourcesFetched)
12886
12898
  newResources.push(...await this.getResources(resourcesFetched));
12887
12899
  }
12888
- } else if (!((_b = res.isArray) == null ? void 0 : _b.call(res))) {
12889
- const resource = await store.getData(res["@id"], this.context);
12890
- if (resource)
12891
- newResources.push(resource);
12892
12900
  } else {
12893
12901
  newResources.push(res);
12894
12902
  }
@@ -51134,6 +51142,10 @@ const WidgetMixin = {
51134
51142
  var _a, _b;
51135
51143
  if (resource && !((_a = resource.isContainer) == null ? void 0 : _a.call(resource))) {
51136
51144
  let fieldValue = await resource[field];
51145
+ if (fieldValue === null || fieldValue === void 0 || fieldValue === "") {
51146
+ let expandedPredicate = sibStore.getExpandedPredicate(field, this.context);
51147
+ fieldValue = await resource[expandedPredicate];
51148
+ }
51137
51149
  if (fieldValue === null || fieldValue === void 0 || fieldValue === "")
51138
51150
  return void 0;
51139
51151
  if (Array.isArray(fieldValue) && !fieldValue["ldp:contains"]) {