@oicl/openbridge-webcomponents 2.0.0-next.73 → 2.0.0-next.74
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/bundle/openbridge-webcomponents.bundle.js +41 -9
- package/bundle/openbridge-webcomponents.bundle.js.map +1 -1
- package/custom-elements.json +296 -1
- package/dist/automation/automation-button/abstract-automation-button-motorized.d.ts +7 -0
- package/dist/automation/automation-button/abstract-automation-button-motorized.d.ts.map +1 -1
- package/dist/automation/automation-button/abstract-automation-button-motorized.js +16 -4
- package/dist/automation/automation-button/abstract-automation-button-motorized.js.map +1 -1
- package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.d.ts +16 -0
- package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.d.ts.map +1 -1
- package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.js +11 -1
- package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.js.map +1 -1
- package/dist/components/toggle-button-vertical-group/toggle-button-vertical-group.d.ts +14 -0
- package/dist/components/toggle-button-vertical-group/toggle-button-vertical-group.d.ts.map +1 -1
- package/dist/components/toggle-button-vertical-group/toggle-button-vertical-group.js +25 -5
- package/dist/components/toggle-button-vertical-group/toggle-button-vertical-group.js.map +1 -1
- package/package.json +1 -1
|
@@ -18403,17 +18403,20 @@ class ObcAbstractAutomationButtonMotorized extends ObcAbstractAutomationButton {
|
|
|
18403
18403
|
super(...arguments);
|
|
18404
18404
|
this.on = false;
|
|
18405
18405
|
this.speedInPercent = 0;
|
|
18406
|
+
this.speedUnit = "%";
|
|
18407
|
+
this.speedMaxDigits = 3;
|
|
18406
18408
|
this.labelDirection = AutomationButtonLabelDirection.right;
|
|
18407
18409
|
this.variant = "regular";
|
|
18408
18410
|
}
|
|
18409
18411
|
get extraReadouts() {
|
|
18410
|
-
|
|
18412
|
+
const speed = this.speed ?? this.speedInPercent;
|
|
18413
|
+
if (speed !== void 0 && speed !== null && this.on) {
|
|
18411
18414
|
return [
|
|
18412
18415
|
{
|
|
18413
18416
|
type: "value",
|
|
18414
|
-
value:
|
|
18415
|
-
nDigits:
|
|
18416
|
-
unit:
|
|
18417
|
+
value: speed,
|
|
18418
|
+
nDigits: this.speedMaxDigits,
|
|
18419
|
+
unit: this.speedUnit,
|
|
18417
18420
|
direction: this.labelDirection,
|
|
18418
18421
|
icon: "chevron"
|
|
18419
18422
|
}
|
|
@@ -18439,6 +18442,15 @@ __decorateClass$zi([
|
|
|
18439
18442
|
__decorateClass$zi([
|
|
18440
18443
|
n$3({ type: Number })
|
|
18441
18444
|
], ObcAbstractAutomationButtonMotorized.prototype, "speedInPercent");
|
|
18445
|
+
__decorateClass$zi([
|
|
18446
|
+
n$3({ type: Number })
|
|
18447
|
+
], ObcAbstractAutomationButtonMotorized.prototype, "speed");
|
|
18448
|
+
__decorateClass$zi([
|
|
18449
|
+
n$3({ type: String })
|
|
18450
|
+
], ObcAbstractAutomationButtonMotorized.prototype, "speedUnit");
|
|
18451
|
+
__decorateClass$zi([
|
|
18452
|
+
n$3({ type: Number })
|
|
18453
|
+
], ObcAbstractAutomationButtonMotorized.prototype, "speedMaxDigits");
|
|
18442
18454
|
__decorateClass$zi([
|
|
18443
18455
|
n$3({ type: String })
|
|
18444
18456
|
], ObcAbstractAutomationButtonMotorized.prototype, "labelDirection");
|
|
@@ -107320,6 +107332,7 @@ let ObcToggleButtonVerticalGroup = class extends i$4 {
|
|
|
107320
107332
|
this.value = "";
|
|
107321
107333
|
this.type = ObcToggleButtonVerticalOptionType.regular;
|
|
107322
107334
|
this.hugWidth = false;
|
|
107335
|
+
this.allowEmptySelection = false;
|
|
107323
107336
|
this.disabled = false;
|
|
107324
107337
|
this._originalDisabledStates = /* @__PURE__ */ new Map();
|
|
107325
107338
|
}
|
|
@@ -107356,8 +107369,12 @@ let ObcToggleButtonVerticalGroup = class extends i$4 {
|
|
|
107356
107369
|
this.updateDividers();
|
|
107357
107370
|
return;
|
|
107358
107371
|
}
|
|
107359
|
-
|
|
107360
|
-
|
|
107372
|
+
if (this.allowEmptySelection) {
|
|
107373
|
+
newValue = "";
|
|
107374
|
+
} else {
|
|
107375
|
+
const fallback = this.getFirstSelectableOption();
|
|
107376
|
+
newValue = fallback?.value || "";
|
|
107377
|
+
}
|
|
107361
107378
|
}
|
|
107362
107379
|
this.value = newValue;
|
|
107363
107380
|
this.options.forEach((option) => {
|
|
@@ -107400,9 +107417,13 @@ let ObcToggleButtonVerticalGroup = class extends i$4 {
|
|
|
107400
107417
|
}
|
|
107401
107418
|
});
|
|
107402
107419
|
if (!this.value || !this.getOptionByValue(this.value)) {
|
|
107403
|
-
|
|
107404
|
-
|
|
107405
|
-
|
|
107420
|
+
if (this.allowEmptySelection) {
|
|
107421
|
+
this.updateSelection("", false);
|
|
107422
|
+
} else {
|
|
107423
|
+
const firstSelectable = this.getFirstSelectableOption();
|
|
107424
|
+
if (firstSelectable) {
|
|
107425
|
+
this.updateSelection(firstSelectable.value, false);
|
|
107426
|
+
}
|
|
107406
107427
|
}
|
|
107407
107428
|
} else {
|
|
107408
107429
|
this.updateSelection(this.value, false);
|
|
@@ -107411,6 +107432,10 @@ let ObcToggleButtonVerticalGroup = class extends i$4 {
|
|
|
107411
107432
|
handleOptionDisabledChange() {
|
|
107412
107433
|
const currentOption = this.getOptionByValue(this.value);
|
|
107413
107434
|
if (currentOption?.disabled && this.hasAnyEnabledOption()) {
|
|
107435
|
+
if (this.allowEmptySelection) {
|
|
107436
|
+
this.updateSelection("");
|
|
107437
|
+
return;
|
|
107438
|
+
}
|
|
107414
107439
|
const firstSelectable = this.getFirstSelectableOption();
|
|
107415
107440
|
if (firstSelectable) {
|
|
107416
107441
|
this.updateSelection(firstSelectable.value);
|
|
@@ -107443,6 +107468,10 @@ let ObcToggleButtonVerticalGroup = class extends i$4 {
|
|
|
107443
107468
|
super.updated(changedProperties);
|
|
107444
107469
|
const currentOption = this.getOptionByValue(this.value);
|
|
107445
107470
|
if (currentOption?.disabled && this.hasAnyEnabledOption()) {
|
|
107471
|
+
if (this.allowEmptySelection) {
|
|
107472
|
+
this.updateSelection("");
|
|
107473
|
+
return;
|
|
107474
|
+
}
|
|
107446
107475
|
const firstSelectable = this.getFirstSelectableOption();
|
|
107447
107476
|
if (firstSelectable) {
|
|
107448
107477
|
this.updateSelection(firstSelectable.value);
|
|
@@ -107485,6 +107514,9 @@ __decorateClass$sS([
|
|
|
107485
107514
|
__decorateClass$sS([
|
|
107486
107515
|
n$3({ type: Boolean })
|
|
107487
107516
|
], ObcToggleButtonVerticalGroup.prototype, "hugWidth", 2);
|
|
107517
|
+
__decorateClass$sS([
|
|
107518
|
+
n$3({ type: Boolean })
|
|
107519
|
+
], ObcToggleButtonVerticalGroup.prototype, "allowEmptySelection", 2);
|
|
107488
107520
|
__decorateClass$sS([
|
|
107489
107521
|
n$3({ type: Boolean, reflect: true })
|
|
107490
107522
|
], ObcToggleButtonVerticalGroup.prototype, "disabled", 2);
|