@startinblox/core 0.19.1-beta.4 → 0.19.1-beta.6

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 (2) hide show
  1. package/dist/index.js +26 -6
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -25411,6 +25411,13 @@ const ActionMixin = {
25411
25411
  callback: function(newValue) {
25412
25412
  this.addToAttributes(newValue, "src");
25413
25413
  }
25414
+ },
25415
+ targetSrc: {
25416
+ type: String,
25417
+ default: "",
25418
+ callback: function(newValue) {
25419
+ this.addToAttributes(newValue, "target-src");
25420
+ }
25414
25421
  }
25415
25422
  }
25416
25423
  };
@@ -51280,7 +51287,9 @@ const WidgetMixin = {
51280
51287
  "minlength",
51281
51288
  "search-text",
51282
51289
  "search-placeholder",
51283
- "link-text"
51290
+ "link-text",
51291
+ "target-src",
51292
+ "data-label"
51284
51293
  ];
51285
51294
  for (let attr of defaultAttributes)
51286
51295
  this.addToAttributes(`${attr}-${escapedField}`, attr, attrs2);
@@ -52276,7 +52285,7 @@ const SolidDisplay = {
52276
52285
  getChildAttributes() {
52277
52286
  const attributes = {};
52278
52287
  for (let attr of this.element.attributes) {
52279
- if (attr.name.startsWith("value-") || attr.name.startsWith("label-") || attr.name.startsWith("placeholder-") || attr.name.startsWith("widget-") || attr.name.startsWith("class-") || attr.name.startsWith("multiple-") || attr.name.startsWith("editable-") || attr.name.startsWith("action-") || attr.name.startsWith("default-") || attr.name.startsWith("link-text-") || attr.name == "extra-context")
52288
+ if (attr.name.startsWith("value-") || attr.name.startsWith("label-") || attr.name.startsWith("placeholder-") || attr.name.startsWith("widget-") || attr.name.startsWith("class-") || attr.name.startsWith("multiple-") || attr.name.startsWith("editable-") || attr.name.startsWith("action-") || attr.name.startsWith("default-") || attr.name.startsWith("link-text-") || attr.name.startsWith("target-src-") || attr.name.startsWith("data-label-") || attr.name == "extra-context")
52280
52289
  attributes[attr.name] = attr.value;
52281
52290
  if (attr.name.startsWith("child-"))
52282
52291
  attributes[attr.name.replace(/^child-/, "")] = attr.value;
@@ -53479,7 +53488,8 @@ const SolidWidget = {
53479
53488
  name: this.name,
53480
53489
  value: this.value || this.resource || "",
53481
53490
  src: this.src,
53482
- label: this.label
53491
+ label: this.label,
53492
+ targetSrc: this.targetSrc || ""
53483
53493
  });
53484
53494
  return tpl;
53485
53495
  },
@@ -54272,8 +54282,9 @@ const SolidMemberDelete = {
54272
54282
  type: String,
54273
54283
  default: null,
54274
54284
  callback: function(newValue, oldValue) {
54275
- if (newValue !== oldValue)
54285
+ if (newValue !== oldValue) {
54276
54286
  this.planRender();
54287
+ }
54277
54288
  }
54278
54289
  },
54279
54290
  dataUnknownMember: {
@@ -54283,6 +54294,10 @@ const SolidMemberDelete = {
54283
54294
  if (newValue !== oldValue)
54284
54295
  this.planRender();
54285
54296
  }
54297
+ },
54298
+ classSubmitButton: {
54299
+ type: String,
54300
+ default: void 0
54286
54301
  }
54287
54302
  },
54288
54303
  initialState: {
@@ -54292,6 +54307,8 @@ const SolidMemberDelete = {
54292
54307
  this.planRender();
54293
54308
  },
54294
54309
  async populate() {
54310
+ if (!this.resourceId)
54311
+ return;
54295
54312
  this.resource = await store.getData(this.resourceId);
54296
54313
  if (!this.resource)
54297
54314
  return;
@@ -54301,7 +54318,6 @@ const SolidMemberDelete = {
54301
54318
  this.currentMembers = [this.currentMembers];
54302
54319
  }
54303
54320
  this.isMember = this.currentMembers ? this.currentMembers.some((member) => member["@id"] === this.dataTargetSrc) : false;
54304
- console.log("populate", this.dataSrc, this.dataTargetSrc, this.currentMembers, this.isMember);
54305
54321
  },
54306
54322
  planRender() {
54307
54323
  if (!this.renderPlanned) {
@@ -54356,8 +54372,12 @@ const SolidMemberDelete = {
54356
54372
  button = html$1`
54357
54373
  <solid-ac-checker data-src="${this.dataSrc}"
54358
54374
  permission="acl:Write"
54375
+ class=${ifDefined(this.classSubmitButton)}
54359
54376
  >
54360
- <button @click=${this.removeMember.bind(this)}>${this.dataLabel || this.t("solid-delete-member.button")}</button>
54377
+ <button
54378
+ @click=${this.removeMember.bind(this)}>
54379
+ ${this.dataLabel || this.t("solid-delete-member.button")}
54380
+ </button>
54361
54381
  ${this.getModalDialog()}
54362
54382
  </solid-ac-checker>
54363
54383
  `;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@startinblox/core",
3
- "version": "0.19.1-beta.4",
3
+ "version": "0.19.1-beta.6",
4
4
  "description": "This is a series of web component respecting both the web components standards and the Linked Data Platform convention.",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",