@oicl/openbridge-webcomponents 2.1.0 → 2.2.0-next.2
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 +59 -16
- package/bundle/openbridge-webcomponents.bundle.js.map +1 -1
- package/custom-elements.json +152 -9
- package/dist/components/icon-button/icon-button.d.ts +2 -0
- package/dist/components/icon-button/icon-button.d.ts.map +1 -1
- package/dist/components/icon-button/icon-button.js +4 -0
- package/dist/components/icon-button/icon-button.js.map +1 -1
- package/dist/components/split-button/split-button.css.js +5 -0
- package/dist/components/split-button/split-button.css.js.map +1 -1
- package/dist/components/split-button/split-button.d.ts +43 -5
- package/dist/components/split-button/split-button.d.ts.map +1 -1
- package/dist/components/split-button/split-button.js +23 -5
- package/dist/components/split-button/split-button.js.map +1 -1
- package/dist/components/top-bar/top-bar.css.js +2 -2
- package/dist/components/top-bar/top-bar.css.js.map +1 -1
- package/dist/components/top-bar/top-bar.d.ts +23 -8
- package/dist/components/top-bar/top-bar.d.ts.map +1 -1
- package/dist/components/top-bar/top-bar.js +25 -9
- package/dist/components/top-bar/top-bar.js.map +1 -1
- package/package.json +1 -1
|
@@ -7674,6 +7674,10 @@ var ObcIconButton = class ObcIconButton extends i$4 {
|
|
|
7674
7674
|
this.focusable = true;
|
|
7675
7675
|
this.ariaLabel = null;
|
|
7676
7676
|
}
|
|
7677
|
+
/** Focus lands on the button inside, not on the host. */
|
|
7678
|
+
focus(options) {
|
|
7679
|
+
this.shadowRoot?.querySelector("button")?.focus(options);
|
|
7680
|
+
}
|
|
7677
7681
|
get progressSpinner() {
|
|
7678
7682
|
if (this.progress === void 0) return A;
|
|
7679
7683
|
if (this.progress === 100) return b`<div class="progress-spinner">
|
|
@@ -107950,6 +107954,11 @@ var split_button_default = i$7`* {
|
|
|
107950
107954
|
top: unset;
|
|
107951
107955
|
}
|
|
107952
107956
|
|
|
107957
|
+
.wrapper.open-left .positioned-menu {
|
|
107958
|
+
right: anchor(right);
|
|
107959
|
+
left: unset;
|
|
107960
|
+
}
|
|
107961
|
+
|
|
107953
107962
|
.dropdown-button::part(visible-wrapper) {
|
|
107954
107963
|
box-sizing: border-box;
|
|
107955
107964
|
}
|
|
@@ -107970,7 +107979,10 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
107970
107979
|
this.dropdownLabel = "More options";
|
|
107971
107980
|
this.fullWidth = false;
|
|
107972
107981
|
this.disabled = false;
|
|
107982
|
+
this.primaryDisabled = false;
|
|
107983
|
+
this.dropdownDisabled = false;
|
|
107973
107984
|
this.openTop = false;
|
|
107985
|
+
this.openLeft = false;
|
|
107974
107986
|
this.columnGroups = [];
|
|
107975
107987
|
this.isDropdownOpen = false;
|
|
107976
107988
|
this.restoreFocusOnClose = false;
|
|
@@ -107989,7 +108001,7 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
107989
108001
|
} else window.removeEventListener("pointerdown", this.closeOnOutside);
|
|
107990
108002
|
};
|
|
107991
108003
|
this.handleDropdownKeydown = (event) => {
|
|
107992
|
-
if (this.
|
|
108004
|
+
if (this.isDropdownDisabled) return;
|
|
107993
108005
|
switch (event.key) {
|
|
107994
108006
|
case "ArrowDown":
|
|
107995
108007
|
event.preventDefault();
|
|
@@ -108051,8 +108063,15 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
108051
108063
|
});
|
|
108052
108064
|
};
|
|
108053
108065
|
}
|
|
108066
|
+
get isPrimaryDisabled() {
|
|
108067
|
+
return this.disabled || this.primaryDisabled;
|
|
108068
|
+
}
|
|
108069
|
+
get isDropdownDisabled() {
|
|
108070
|
+
return this.disabled || this.dropdownDisabled;
|
|
108071
|
+
}
|
|
108054
108072
|
async focusMenuAfterOpen() {
|
|
108055
108073
|
await this.updateComplete;
|
|
108074
|
+
await this.menu?.updateComplete;
|
|
108056
108075
|
if (!this.isDropdownOpen) return;
|
|
108057
108076
|
if (this.menuFocusStrategy === "last") this.menu?.focusLastItem();
|
|
108058
108077
|
else if (this.menuFocusStrategy === "first") this.menu?.focusFirstItem();
|
|
@@ -108084,7 +108103,8 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
108084
108103
|
wrapper: true,
|
|
108085
108104
|
"full-width": this.fullWidth,
|
|
108086
108105
|
"is-open": this.isDropdownOpen,
|
|
108087
|
-
"open-top": this.openTop
|
|
108106
|
+
"open-top": this.openTop,
|
|
108107
|
+
"open-left": this.openLeft
|
|
108088
108108
|
})}
|
|
108089
108109
|
>
|
|
108090
108110
|
<obc-button
|
|
@@ -108092,7 +108112,7 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
108092
108112
|
.variant=${"normal"}
|
|
108093
108113
|
.segmentPosition=${segmentPosition.start}
|
|
108094
108114
|
.showLeadingIcon=${this.hasIcon}
|
|
108095
|
-
.disabled=${this.
|
|
108115
|
+
.disabled=${this.isPrimaryDisabled}
|
|
108096
108116
|
@click=${this.handlePrimaryClick}
|
|
108097
108117
|
.fullWidth=${this.fullWidth}
|
|
108098
108118
|
>
|
|
@@ -108104,7 +108124,7 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
108104
108124
|
class="dropdown-button"
|
|
108105
108125
|
.variant=${"normal"}
|
|
108106
108126
|
.cornerRight=${true}
|
|
108107
|
-
.disabled=${this.
|
|
108127
|
+
.disabled=${this.isDropdownDisabled}
|
|
108108
108128
|
.activated=${this.isDropdownOpen}
|
|
108109
108129
|
aria-label=${this.dropdownLabel}
|
|
108110
108130
|
@click=${this.handleDropdownClick}
|
|
@@ -108112,7 +108132,11 @@ var ObcSplitButton = class ObcSplitButton extends i$4 {
|
|
|
108112
108132
|
aria-expanded=${this.isDropdownOpen}
|
|
108113
108133
|
aria-haspopup="menu"
|
|
108114
108134
|
>
|
|
108115
|
-
<
|
|
108135
|
+
<slot name="dropdown-icon">
|
|
108136
|
+
<obi-arrow-flyout-google
|
|
108137
|
+
aria-hidden="true"
|
|
108138
|
+
></obi-arrow-flyout-google>
|
|
108139
|
+
</slot>
|
|
108116
108140
|
</obc-icon-button>
|
|
108117
108141
|
|
|
108118
108142
|
<!-- Context Menu -->
|
|
@@ -108153,7 +108177,10 @@ __decorate([n$4({ type: String })], ObcSplitButton.prototype, "menuTitle", void
|
|
|
108153
108177
|
__decorate([n$4({ type: String })], ObcSplitButton.prototype, "dropdownLabel", void 0);
|
|
108154
108178
|
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "fullWidth", void 0);
|
|
108155
108179
|
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "disabled", void 0);
|
|
108180
|
+
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "primaryDisabled", void 0);
|
|
108181
|
+
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "dropdownDisabled", void 0);
|
|
108156
108182
|
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "openTop", void 0);
|
|
108183
|
+
__decorate([n$4({ type: Boolean })], ObcSplitButton.prototype, "openLeft", void 0);
|
|
108157
108184
|
__decorate([n$4({ type: Array })], ObcSplitButton.prototype, "columnGroups", void 0);
|
|
108158
108185
|
__decorate([r$3()], ObcSplitButton.prototype, "isDropdownOpen", void 0);
|
|
108159
108186
|
__decorate([e$4("obc-context-menu-input")], ObcSplitButton.prototype, "menu", void 0);
|
|
@@ -113930,7 +113957,7 @@ var top_bar_default = i$7`* {
|
|
|
113930
113957
|
/* Controls never shrink: a squeeze reaches the texts, then overflows the end */
|
|
113931
113958
|
.menu-button,
|
|
113932
113959
|
.app-icon,
|
|
113933
|
-
.
|
|
113960
|
+
.more-button,
|
|
113934
113961
|
.dimming-button,
|
|
113935
113962
|
.user-button,
|
|
113936
113963
|
.apps-button,
|
|
@@ -113986,7 +114013,7 @@ var top_bar_default = i$7`* {
|
|
|
113986
114013
|
"ss04" on;
|
|
113987
114014
|
}
|
|
113988
114015
|
|
|
113989
|
-
.
|
|
114016
|
+
.more-button {
|
|
113990
114017
|
display: none;
|
|
113991
114018
|
}
|
|
113992
114019
|
|
|
@@ -114159,7 +114186,7 @@ var ObcTopBar = class ObcTopBar extends i$4 {
|
|
|
114159
114186
|
this.menuButtonActivated = false;
|
|
114160
114187
|
this.dimmingButtonActivated = false;
|
|
114161
114188
|
this.appsButtonActivated = false;
|
|
114162
|
-
this.
|
|
114189
|
+
this.moreButtonActivated = false;
|
|
114163
114190
|
this.userButtonActivated = false;
|
|
114164
114191
|
this.userButtonDisabled = false;
|
|
114165
114192
|
this.tall = false;
|
|
@@ -114197,9 +114224,24 @@ var ObcTopBar = class ObcTopBar extends i$4 {
|
|
|
114197
114224
|
*/
|
|
114198
114225
|
this.dispatchEvent(new CustomEvent("apps-button-clicked"));
|
|
114199
114226
|
}
|
|
114200
|
-
|
|
114227
|
+
/**
|
|
114228
|
+
* Copies the deprecated `leftMoreButtonActivated` into
|
|
114229
|
+
* `moreButtonActivated`. A plain field rather than a getter/setter alias:
|
|
114230
|
+
* the Vue wrapper writes every prop back on its second render, and a getter
|
|
114231
|
+
* would then write `false` over the new property.
|
|
114232
|
+
*/
|
|
114233
|
+
willUpdate(changed) {
|
|
114234
|
+
super.willUpdate(changed);
|
|
114235
|
+
if (changed.has("leftMoreButtonActivated") && this.leftMoreButtonActivated !== void 0) this.moreButtonActivated = this.leftMoreButtonActivated;
|
|
114236
|
+
}
|
|
114237
|
+
moreButtonClicked() {
|
|
114238
|
+
/**
|
|
114239
|
+
* Fired when the more button is clicked.
|
|
114240
|
+
* @event more-button-clicked
|
|
114241
|
+
*/
|
|
114242
|
+
this.dispatchEvent(new CustomEvent("more-button-clicked"));
|
|
114201
114243
|
/**
|
|
114202
|
-
*
|
|
114244
|
+
* Deprecated alias of `more-button-clicked`; removed in 4.0.0.
|
|
114203
114245
|
* @event left-more-button-clicked
|
|
114204
114246
|
*/
|
|
114205
114247
|
this.dispatchEvent(new CustomEvent("left-more-button-clicked"));
|
|
@@ -114315,8 +114357,8 @@ var ObcTopBar = class ObcTopBar extends i$4 {
|
|
|
114315
114357
|
}
|
|
114316
114358
|
return b`
|
|
114317
114359
|
<style>
|
|
114318
|
-
@media (max-width: ${Math.max(this.appButtonBreakpointPx, this.dimmingButtonBreakpointPx)}px) {
|
|
114319
|
-
.
|
|
114360
|
+
@media (max-width: ${Math.max(this.appButtonBreakpointPx, this.dimmingButtonBreakpointPx, this.userButtonBreakpointPx, this.appIconBreakpointPx)}px) {
|
|
114361
|
+
.more-button {
|
|
114320
114362
|
display: revert !important;
|
|
114321
114363
|
}
|
|
114322
114364
|
|
|
@@ -114402,12 +114444,12 @@ var ObcTopBar = class ObcTopBar extends i$4 {
|
|
|
114402
114444
|
</obc-icon-button>` : null}
|
|
114403
114445
|
${this.showClock ? b`<slot name="clock"></slot>` : null}
|
|
114404
114446
|
${!this.inactive ? b`<obc-icon-button
|
|
114405
|
-
class="
|
|
114406
|
-
part="left-more-button"
|
|
114447
|
+
class="more-button"
|
|
114448
|
+
part="more-button left-more-button"
|
|
114407
114449
|
variant="flat"
|
|
114408
114450
|
aria-label=${msg("More")}
|
|
114409
|
-
@click=${this.
|
|
114410
|
-
?activated=${this.
|
|
114451
|
+
@click=${this.moreButtonClicked}
|
|
114452
|
+
?activated=${this.moreButtonActivated}
|
|
114411
114453
|
>
|
|
114412
114454
|
<obi-more-vertical-google></obi-more-vertical-google>
|
|
114413
114455
|
</obc-icon-button>` : null}
|
|
@@ -114425,6 +114467,7 @@ __decorate([n$4({ type: String })], ObcTopBar.prototype, "menuButtonIcon", void
|
|
|
114425
114467
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "menuButtonActivated", void 0);
|
|
114426
114468
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "dimmingButtonActivated", void 0);
|
|
114427
114469
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "appsButtonActivated", void 0);
|
|
114470
|
+
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "moreButtonActivated", void 0);
|
|
114428
114471
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "leftMoreButtonActivated", void 0);
|
|
114429
114472
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "userButtonActivated", void 0);
|
|
114430
114473
|
__decorate([n$4({ type: Boolean })], ObcTopBar.prototype, "userButtonDisabled", void 0);
|