@aurodesignsystem/auro-formkit 3.2.0 → 3.3.0-beta.1
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/CHANGELOG.md +12 -0
- package/components/checkbox/README.md +1 -1
- package/components/checkbox/demo/readme.md +1 -1
- package/components/combobox/README.md +1 -1
- package/components/combobox/demo/api.md +1 -1
- package/components/combobox/demo/api.min.js +26 -5
- package/components/combobox/demo/index.min.js +26 -5
- package/components/combobox/demo/readme.md +1 -1
- package/components/combobox/dist/auro-combobox.d.ts +5 -2
- package/components/combobox/dist/index.js +26 -5
- package/components/combobox/dist/registered.js +26 -5
- package/components/counter/README.md +1 -1
- package/components/counter/demo/api.md +1 -1
- package/components/counter/demo/api.min.js +26 -5
- package/components/counter/demo/index.min.js +26 -5
- package/components/counter/demo/readme.md +1 -1
- package/components/counter/dist/auro-counter-group.d.ts +5 -2
- package/components/counter/dist/index.js +26 -5
- package/components/counter/dist/registered.js +26 -5
- package/components/datepicker/README.md +1 -1
- package/components/datepicker/demo/api.md +1 -0
- package/components/datepicker/demo/api.min.js +36 -4
- package/components/datepicker/demo/index.min.js +36 -4
- package/components/datepicker/demo/readme.md +1 -1
- package/components/datepicker/dist/auro-datepicker.d.ts +13 -0
- package/components/datepicker/dist/index.js +36 -4
- package/components/datepicker/dist/registered.js +36 -4
- package/components/dropdown/README.md +1 -1
- package/components/dropdown/demo/api.md +1 -1
- package/components/dropdown/demo/api.min.js +21 -3
- package/components/dropdown/demo/index.md +83 -0
- package/components/dropdown/demo/index.min.js +21 -3
- package/components/dropdown/demo/readme.md +1 -1
- package/components/dropdown/dist/auro-dropdown.d.ts +12 -1
- package/components/dropdown/dist/index.js +21 -3
- package/components/dropdown/dist/registered.js +21 -3
- package/components/form/README.md +1 -1
- package/components/form/demo/autocomplete.html +15 -0
- package/components/form/demo/readme.md +1 -1
- package/components/input/README.md +1 -1
- package/components/input/demo/readme.md +1 -1
- package/components/menu/README.md +1 -1
- package/components/menu/demo/readme.md +1 -1
- package/components/radio/README.md +1 -1
- package/components/radio/demo/readme.md +1 -1
- package/components/select/README.md +1 -1
- package/components/select/demo/api.md +1 -1
- package/components/select/demo/api.min.js +26 -5
- package/components/select/demo/index.md +46 -1
- package/components/select/demo/index.min.js +26 -5
- package/components/select/demo/readme.md +1 -1
- package/components/select/dist/auro-select.d.ts +5 -2
- package/components/select/dist/index.js +26 -5
- package/components/select/dist/registered.js +26 -5
- package/package.json +1 -1
|
@@ -14887,6 +14887,7 @@ var tokensCss$1$1 = css`:host{--ds-auro-dropdown-label-text-color: var(--ds-basi
|
|
|
14887
14887
|
|
|
14888
14888
|
const DESIGN_TOKEN_BREAKPOINT_PREFIX = '--ds-grid-breakpoint-';
|
|
14889
14889
|
const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
14890
|
+
'xl',
|
|
14890
14891
|
'lg',
|
|
14891
14892
|
'md',
|
|
14892
14893
|
'sm',
|
|
@@ -14958,6 +14959,7 @@ class AuroDropdownBib extends LitElement {
|
|
|
14958
14959
|
|
|
14959
14960
|
set mobileFullscreenBreakpoint(value) {
|
|
14960
14961
|
// verify the defined breakpoint is valid and exit out if not
|
|
14962
|
+
// 'disabled' is a design token breakpoint so it acts as our "undefined" value
|
|
14961
14963
|
const validatedValue = DESIGN_TOKEN_BREAKPOINT_OPTIONS.includes(value) ? value : undefined;
|
|
14962
14964
|
if (!validatedValue) {
|
|
14963
14965
|
this._mobileBreakpointValue = undefined;
|
|
@@ -15483,7 +15485,12 @@ class AuroDropdown extends LitElement {
|
|
|
15483
15485
|
},
|
|
15484
15486
|
|
|
15485
15487
|
/**
|
|
15486
|
-
* Defines the screen size breakpoint (`
|
|
15488
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
15489
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
15490
|
+
*
|
|
15491
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
15492
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
15493
|
+
* @default sm
|
|
15487
15494
|
*/
|
|
15488
15495
|
fullscreenBreakpoint: {
|
|
15489
15496
|
type: String,
|
|
@@ -15623,6 +15630,15 @@ class AuroDropdown extends LitElement {
|
|
|
15623
15630
|
AuroLibraryRuntimeUtils$1$1.prototype.registerComponent(name, AuroDropdown);
|
|
15624
15631
|
}
|
|
15625
15632
|
|
|
15633
|
+
/**
|
|
15634
|
+
* Accessor for reusing the focusable entity query string.
|
|
15635
|
+
* @private
|
|
15636
|
+
* @returns {string}
|
|
15637
|
+
*/
|
|
15638
|
+
get focusableEntityQuery () {
|
|
15639
|
+
return 'auro-input, [auro-input], auro-button, [auro-button], button, input';
|
|
15640
|
+
}
|
|
15641
|
+
|
|
15626
15642
|
connectedCallback() {
|
|
15627
15643
|
super.connectedCallback();
|
|
15628
15644
|
}
|
|
@@ -15636,6 +15652,8 @@ class AuroDropdown extends LitElement {
|
|
|
15636
15652
|
updated(changedProperties) {
|
|
15637
15653
|
this.floater.handleUpdate(changedProperties);
|
|
15638
15654
|
|
|
15655
|
+
// Note: `disabled` is not a breakpoint (it is not a screen size),
|
|
15656
|
+
// so it looks like we never consume this - however, dropdownBib handles this in the setter as "undefined"
|
|
15639
15657
|
if (changedProperties.has('fullscreenBreakpoint')) {
|
|
15640
15658
|
this.bibContent.mobileFullscreenBreakpoint = this.fullscreenBreakpoint;
|
|
15641
15659
|
}
|
|
@@ -15786,7 +15804,7 @@ class AuroDropdown extends LitElement {
|
|
|
15786
15804
|
|
|
15787
15805
|
this.triggerContentSlot.forEach((node) => {
|
|
15788
15806
|
if (node.querySelectorAll) {
|
|
15789
|
-
const auroElements = node.querySelectorAll(
|
|
15807
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
15790
15808
|
auroElements.forEach((auroEl) => {
|
|
15791
15809
|
auroEl.addEventListener('focus', this.bindFocusEventToTrigger);
|
|
15792
15810
|
auroEl.addEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -15807,7 +15825,7 @@ class AuroDropdown extends LitElement {
|
|
|
15807
15825
|
|
|
15808
15826
|
this.triggerContentSlot.forEach((node) => {
|
|
15809
15827
|
if (node.querySelectorAll) {
|
|
15810
|
-
const auroElements = node.querySelectorAll(
|
|
15828
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
15811
15829
|
auroElements.forEach((auroEl) => {
|
|
15812
15830
|
auroEl.removeEventListener('focus', this.bindFocusEventToTrigger);
|
|
15813
15831
|
auroEl.removeEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -23101,6 +23119,7 @@ class AuroDatePicker extends LitElement {
|
|
|
23101
23119
|
this.calendarEndDate = undefined;
|
|
23102
23120
|
this.calendarFocusDate = this.value;
|
|
23103
23121
|
this.format = 'mm/dd/yyyy';
|
|
23122
|
+
this.fullscreenBreakpoint = 'sm';
|
|
23104
23123
|
this.monthNames = [
|
|
23105
23124
|
'January',
|
|
23106
23125
|
'February',
|
|
@@ -23238,6 +23257,19 @@ class AuroDatePicker extends LitElement {
|
|
|
23238
23257
|
reflect: true
|
|
23239
23258
|
},
|
|
23240
23259
|
|
|
23260
|
+
/**
|
|
23261
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
23262
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
23263
|
+
*
|
|
23264
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
23265
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
23266
|
+
* @default sm
|
|
23267
|
+
*/
|
|
23268
|
+
fullscreenBreakpoint: {
|
|
23269
|
+
type: String,
|
|
23270
|
+
reflect: true
|
|
23271
|
+
},
|
|
23272
|
+
|
|
23241
23273
|
/**
|
|
23242
23274
|
* If declared, make bib.fullscreen.headline in HeadingDisplay.
|
|
23243
23275
|
* Otherwise, Heading 600.
|
|
@@ -24064,7 +24096,7 @@ class AuroDatePicker extends LitElement {
|
|
|
24064
24096
|
?disabled="${this.disabled}"
|
|
24065
24097
|
?error="${this.validity !== undefined && this.validity !== 'valid'}"
|
|
24066
24098
|
disableEventShow
|
|
24067
|
-
fullscreenBreakpoint="
|
|
24099
|
+
.fullscreenBreakpoint="${this.fullscreenBreakpoint}"
|
|
24068
24100
|
.placement="${this.placement}"
|
|
24069
24101
|
.offset="${this.offset}"
|
|
24070
24102
|
?autoPlacement="${this.autoPlacement}"
|
|
@@ -107,7 +107,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
107
107
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
108
108
|
|
|
109
109
|
```html
|
|
110
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
110
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-dropdown/+esm"></script>
|
|
111
111
|
```
|
|
112
112
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
113
113
|
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
| [error](#error) | `error` | ` Boolean ` | | If declared in combination with `bordered` property or `helpText` slot content, will apply red color to both. |
|
|
24
24
|
| [fluid](#fluid) | `fluid` | `Boolean` | | Makes the trigger to be full width of its parent container. |
|
|
25
25
|
| [focusShow](#focusShow) | `focusShow` | ` Boolean ` | | If declared, the bib will display when focus is applied to the trigger. |
|
|
26
|
-
| [fullscreenBreakpoint](#fullscreenBreakpoint) | `fullscreenBreakpoint` | ` String ` |
|
|
26
|
+
| [fullscreenBreakpoint](#fullscreenBreakpoint) | `fullscreenBreakpoint` | ` String ` | "sm" | Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)<br />at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.<br /><br />When expanded, the dropdown will automatically display in fullscreen mode<br />if the screen size is equal to or smaller than the selected breakpoint. |
|
|
27
27
|
| [hoverToggle](#hoverToggle) | `hoverToggle` | ` Boolean ` | | If declared, the trigger will toggle the dropdown on mouseover/mouseout. |
|
|
28
28
|
| [inset](#inset) | `inset` | ` Boolean ` | | If declared, will apply padding around trigger slot content. |
|
|
29
29
|
| [isBibFullscreen](#isBibFullscreen) | `isBibFullscreen` | `boolean` | false | If true, the dropdown bib is taking the fullscreen when it's open. |
|
|
@@ -2653,6 +2653,7 @@ var tokensCss$1 = i$3`:host{--ds-auro-dropdown-label-text-color: var(--ds-basic-
|
|
|
2653
2653
|
|
|
2654
2654
|
const DESIGN_TOKEN_BREAKPOINT_PREFIX = '--ds-grid-breakpoint-';
|
|
2655
2655
|
const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
2656
|
+
'xl',
|
|
2656
2657
|
'lg',
|
|
2657
2658
|
'md',
|
|
2658
2659
|
'sm',
|
|
@@ -2724,6 +2725,7 @@ class AuroDropdownBib extends r {
|
|
|
2724
2725
|
|
|
2725
2726
|
set mobileFullscreenBreakpoint(value) {
|
|
2726
2727
|
// verify the defined breakpoint is valid and exit out if not
|
|
2728
|
+
// 'disabled' is a design token breakpoint so it acts as our "undefined" value
|
|
2727
2729
|
const validatedValue = DESIGN_TOKEN_BREAKPOINT_OPTIONS.includes(value) ? value : undefined;
|
|
2728
2730
|
if (!validatedValue) {
|
|
2729
2731
|
this._mobileBreakpointValue = undefined;
|
|
@@ -3249,7 +3251,12 @@ class AuroDropdown extends r {
|
|
|
3249
3251
|
},
|
|
3250
3252
|
|
|
3251
3253
|
/**
|
|
3252
|
-
* Defines the screen size breakpoint (`
|
|
3254
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
3255
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
3256
|
+
*
|
|
3257
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
3258
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
3259
|
+
* @default sm
|
|
3253
3260
|
*/
|
|
3254
3261
|
fullscreenBreakpoint: {
|
|
3255
3262
|
type: String,
|
|
@@ -3389,6 +3396,15 @@ class AuroDropdown extends r {
|
|
|
3389
3396
|
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroDropdown);
|
|
3390
3397
|
}
|
|
3391
3398
|
|
|
3399
|
+
/**
|
|
3400
|
+
* Accessor for reusing the focusable entity query string.
|
|
3401
|
+
* @private
|
|
3402
|
+
* @returns {string}
|
|
3403
|
+
*/
|
|
3404
|
+
get focusableEntityQuery () {
|
|
3405
|
+
return 'auro-input, [auro-input], auro-button, [auro-button], button, input';
|
|
3406
|
+
}
|
|
3407
|
+
|
|
3392
3408
|
connectedCallback() {
|
|
3393
3409
|
super.connectedCallback();
|
|
3394
3410
|
}
|
|
@@ -3402,6 +3418,8 @@ class AuroDropdown extends r {
|
|
|
3402
3418
|
updated(changedProperties) {
|
|
3403
3419
|
this.floater.handleUpdate(changedProperties);
|
|
3404
3420
|
|
|
3421
|
+
// Note: `disabled` is not a breakpoint (it is not a screen size),
|
|
3422
|
+
// so it looks like we never consume this - however, dropdownBib handles this in the setter as "undefined"
|
|
3405
3423
|
if (changedProperties.has('fullscreenBreakpoint')) {
|
|
3406
3424
|
this.bibContent.mobileFullscreenBreakpoint = this.fullscreenBreakpoint;
|
|
3407
3425
|
}
|
|
@@ -3552,7 +3570,7 @@ class AuroDropdown extends r {
|
|
|
3552
3570
|
|
|
3553
3571
|
this.triggerContentSlot.forEach((node) => {
|
|
3554
3572
|
if (node.querySelectorAll) {
|
|
3555
|
-
const auroElements = node.querySelectorAll(
|
|
3573
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3556
3574
|
auroElements.forEach((auroEl) => {
|
|
3557
3575
|
auroEl.addEventListener('focus', this.bindFocusEventToTrigger);
|
|
3558
3576
|
auroEl.addEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -3573,7 +3591,7 @@ class AuroDropdown extends r {
|
|
|
3573
3591
|
|
|
3574
3592
|
this.triggerContentSlot.forEach((node) => {
|
|
3575
3593
|
if (node.querySelectorAll) {
|
|
3576
|
-
const auroElements = node.querySelectorAll(
|
|
3594
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3577
3595
|
auroElements.forEach((auroEl) => {
|
|
3578
3596
|
auroEl.removeEventListener('focus', this.bindFocusEventToTrigger);
|
|
3579
3597
|
auroEl.removeEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -411,6 +411,89 @@ To make the dropdown to be just big as the trigger's content, style the `auro-dr
|
|
|
411
411
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
412
412
|
</auro-accordion>
|
|
413
413
|
|
|
414
|
+
## Triggering a fullscreen dropdown
|
|
415
|
+
This example shows how to set a dropdown fullscreen breakpoint attribute. Most consuming components use `sm` by default, but
|
|
416
|
+
dropdown supports `xs`, `sm`, `md`, `lg`, `xl` and `disabled`, with `disabled` ensuring that the dropdown will never be fullscreen.
|
|
417
|
+
|
|
418
|
+
<div class="exampleWrapper">
|
|
419
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/fullscreen.html) -->
|
|
420
|
+
<!-- The below content is automatically added from ./../apiExamples/fullscreen.html -->
|
|
421
|
+
<h3>Never fullscreen</h3>
|
|
422
|
+
<auro-dropdown id="common-never-fullscreen" common aria-label="Label content for screen reader" fullscreenBreakpoint="disabled">
|
|
423
|
+
<div style="padding: var(--ds-size-150);">
|
|
424
|
+
Lorem ipsum solar
|
|
425
|
+
<br />
|
|
426
|
+
<auro-button onclick="document.querySelector('#common-never-fullscreen').hide()">
|
|
427
|
+
Dismiss Dropdown
|
|
428
|
+
</auro-button>
|
|
429
|
+
</div>
|
|
430
|
+
<span slot="helpText">
|
|
431
|
+
Help text
|
|
432
|
+
</span>
|
|
433
|
+
<div slot="trigger">
|
|
434
|
+
Trigger
|
|
435
|
+
</div>
|
|
436
|
+
</auro-dropdown>
|
|
437
|
+
<h3>Always fullscreen</h3>
|
|
438
|
+
<auro-dropdown id="common-always-fullscreen" common aria-label="Label content for screen reader" fullscreenBreakpoint="xl">
|
|
439
|
+
<div style="padding: var(--ds-size-150);">
|
|
440
|
+
Lorem ipsum solar
|
|
441
|
+
<br />
|
|
442
|
+
<auro-button onclick="document.querySelector('#common-always-fullscreen').hide()">
|
|
443
|
+
Dismiss Dropdown
|
|
444
|
+
</auro-button>
|
|
445
|
+
</div>
|
|
446
|
+
<span slot="helpText">
|
|
447
|
+
Help text
|
|
448
|
+
</span>
|
|
449
|
+
<div slot="trigger">
|
|
450
|
+
Trigger
|
|
451
|
+
</div>
|
|
452
|
+
</auro-dropdown>
|
|
453
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
454
|
+
</div>
|
|
455
|
+
<auro-accordion alignRight>
|
|
456
|
+
<span slot="trigger">See code</span>
|
|
457
|
+
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/fullscreen.html) -->
|
|
458
|
+
<!-- The below code snippet is automatically added from ./../apiExamples/fullscreen.html -->
|
|
459
|
+
|
|
460
|
+
```html
|
|
461
|
+
<h3>Never fullscreen</h3>
|
|
462
|
+
<auro-dropdown id="common-never-fullscreen" common aria-label="Label content for screen reader" fullscreenBreakpoint="disabled">
|
|
463
|
+
<div style="padding: var(--ds-size-150);">
|
|
464
|
+
Lorem ipsum solar
|
|
465
|
+
<br />
|
|
466
|
+
<auro-button onclick="document.querySelector('#common-never-fullscreen').hide()">
|
|
467
|
+
Dismiss Dropdown
|
|
468
|
+
</auro-button>
|
|
469
|
+
</div>
|
|
470
|
+
<span slot="helpText">
|
|
471
|
+
Help text
|
|
472
|
+
</span>
|
|
473
|
+
<div slot="trigger">
|
|
474
|
+
Trigger
|
|
475
|
+
</div>
|
|
476
|
+
</auro-dropdown>
|
|
477
|
+
<h3>Always fullscreen</h3>
|
|
478
|
+
<auro-dropdown id="common-always-fullscreen" common aria-label="Label content for screen reader" fullscreenBreakpoint="xl">
|
|
479
|
+
<div style="padding: var(--ds-size-150);">
|
|
480
|
+
Lorem ipsum solar
|
|
481
|
+
<br />
|
|
482
|
+
<auro-button onclick="document.querySelector('#common-always-fullscreen').hide()">
|
|
483
|
+
Dismiss Dropdown
|
|
484
|
+
</auro-button>
|
|
485
|
+
</div>
|
|
486
|
+
<span slot="helpText">
|
|
487
|
+
Help text
|
|
488
|
+
</span>
|
|
489
|
+
<div slot="trigger">
|
|
490
|
+
Trigger
|
|
491
|
+
</div>
|
|
492
|
+
</auro-dropdown>
|
|
493
|
+
```
|
|
494
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
495
|
+
</auro-accordion>
|
|
496
|
+
|
|
414
497
|
## Supported standard and accessible interactions
|
|
415
498
|
|
|
416
499
|
The dropdown can be opened with the following actions:
|
|
@@ -2628,6 +2628,7 @@ var tokensCss$1 = i$3`:host{--ds-auro-dropdown-label-text-color: var(--ds-basic-
|
|
|
2628
2628
|
|
|
2629
2629
|
const DESIGN_TOKEN_BREAKPOINT_PREFIX = '--ds-grid-breakpoint-';
|
|
2630
2630
|
const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
2631
|
+
'xl',
|
|
2631
2632
|
'lg',
|
|
2632
2633
|
'md',
|
|
2633
2634
|
'sm',
|
|
@@ -2699,6 +2700,7 @@ class AuroDropdownBib extends r {
|
|
|
2699
2700
|
|
|
2700
2701
|
set mobileFullscreenBreakpoint(value) {
|
|
2701
2702
|
// verify the defined breakpoint is valid and exit out if not
|
|
2703
|
+
// 'disabled' is a design token breakpoint so it acts as our "undefined" value
|
|
2702
2704
|
const validatedValue = DESIGN_TOKEN_BREAKPOINT_OPTIONS.includes(value) ? value : undefined;
|
|
2703
2705
|
if (!validatedValue) {
|
|
2704
2706
|
this._mobileBreakpointValue = undefined;
|
|
@@ -3224,7 +3226,12 @@ class AuroDropdown extends r {
|
|
|
3224
3226
|
},
|
|
3225
3227
|
|
|
3226
3228
|
/**
|
|
3227
|
-
* Defines the screen size breakpoint (`
|
|
3229
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
3230
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
3231
|
+
*
|
|
3232
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
3233
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
3234
|
+
* @default sm
|
|
3228
3235
|
*/
|
|
3229
3236
|
fullscreenBreakpoint: {
|
|
3230
3237
|
type: String,
|
|
@@ -3364,6 +3371,15 @@ class AuroDropdown extends r {
|
|
|
3364
3371
|
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroDropdown);
|
|
3365
3372
|
}
|
|
3366
3373
|
|
|
3374
|
+
/**
|
|
3375
|
+
* Accessor for reusing the focusable entity query string.
|
|
3376
|
+
* @private
|
|
3377
|
+
* @returns {string}
|
|
3378
|
+
*/
|
|
3379
|
+
get focusableEntityQuery () {
|
|
3380
|
+
return 'auro-input, [auro-input], auro-button, [auro-button], button, input';
|
|
3381
|
+
}
|
|
3382
|
+
|
|
3367
3383
|
connectedCallback() {
|
|
3368
3384
|
super.connectedCallback();
|
|
3369
3385
|
}
|
|
@@ -3377,6 +3393,8 @@ class AuroDropdown extends r {
|
|
|
3377
3393
|
updated(changedProperties) {
|
|
3378
3394
|
this.floater.handleUpdate(changedProperties);
|
|
3379
3395
|
|
|
3396
|
+
// Note: `disabled` is not a breakpoint (it is not a screen size),
|
|
3397
|
+
// so it looks like we never consume this - however, dropdownBib handles this in the setter as "undefined"
|
|
3380
3398
|
if (changedProperties.has('fullscreenBreakpoint')) {
|
|
3381
3399
|
this.bibContent.mobileFullscreenBreakpoint = this.fullscreenBreakpoint;
|
|
3382
3400
|
}
|
|
@@ -3527,7 +3545,7 @@ class AuroDropdown extends r {
|
|
|
3527
3545
|
|
|
3528
3546
|
this.triggerContentSlot.forEach((node) => {
|
|
3529
3547
|
if (node.querySelectorAll) {
|
|
3530
|
-
const auroElements = node.querySelectorAll(
|
|
3548
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3531
3549
|
auroElements.forEach((auroEl) => {
|
|
3532
3550
|
auroEl.addEventListener('focus', this.bindFocusEventToTrigger);
|
|
3533
3551
|
auroEl.addEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -3548,7 +3566,7 @@ class AuroDropdown extends r {
|
|
|
3548
3566
|
|
|
3549
3567
|
this.triggerContentSlot.forEach((node) => {
|
|
3550
3568
|
if (node.querySelectorAll) {
|
|
3551
|
-
const auroElements = node.querySelectorAll(
|
|
3569
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3552
3570
|
auroElements.forEach((auroEl) => {
|
|
3553
3571
|
auroEl.removeEventListener('focus', this.bindFocusEventToTrigger);
|
|
3554
3572
|
auroEl.removeEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -107,7 +107,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
107
107
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
108
108
|
|
|
109
109
|
```html
|
|
110
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
110
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-dropdown/+esm"></script>
|
|
111
111
|
```
|
|
112
112
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
113
113
|
|
|
@@ -120,7 +120,12 @@ export class AuroDropdown extends LitElement {
|
|
|
120
120
|
type: BooleanConstructor;
|
|
121
121
|
};
|
|
122
122
|
/**
|
|
123
|
-
* Defines the screen size breakpoint (`
|
|
123
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
124
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
125
|
+
*
|
|
126
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
127
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
128
|
+
* @default sm
|
|
124
129
|
*/
|
|
125
130
|
fullscreenBreakpoint: {
|
|
126
131
|
type: StringConstructor;
|
|
@@ -320,6 +325,12 @@ export class AuroDropdown extends LitElement {
|
|
|
320
325
|
* @returns {void}
|
|
321
326
|
*/
|
|
322
327
|
show(): void;
|
|
328
|
+
/**
|
|
329
|
+
* Accessor for reusing the focusable entity query string.
|
|
330
|
+
* @private
|
|
331
|
+
* @returns {string}
|
|
332
|
+
*/
|
|
333
|
+
private get focusableEntityQuery();
|
|
323
334
|
updated(changedProperties: any): void;
|
|
324
335
|
firstUpdated(): void;
|
|
325
336
|
dropdownId: any;
|
|
@@ -2581,6 +2581,7 @@ var tokensCss$1 = css`:host{--ds-auro-dropdown-label-text-color: var(--ds-basic-
|
|
|
2581
2581
|
|
|
2582
2582
|
const DESIGN_TOKEN_BREAKPOINT_PREFIX = '--ds-grid-breakpoint-';
|
|
2583
2583
|
const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
2584
|
+
'xl',
|
|
2584
2585
|
'lg',
|
|
2585
2586
|
'md',
|
|
2586
2587
|
'sm',
|
|
@@ -2652,6 +2653,7 @@ class AuroDropdownBib extends LitElement {
|
|
|
2652
2653
|
|
|
2653
2654
|
set mobileFullscreenBreakpoint(value) {
|
|
2654
2655
|
// verify the defined breakpoint is valid and exit out if not
|
|
2656
|
+
// 'disabled' is a design token breakpoint so it acts as our "undefined" value
|
|
2655
2657
|
const validatedValue = DESIGN_TOKEN_BREAKPOINT_OPTIONS.includes(value) ? value : undefined;
|
|
2656
2658
|
if (!validatedValue) {
|
|
2657
2659
|
this._mobileBreakpointValue = undefined;
|
|
@@ -3177,7 +3179,12 @@ class AuroDropdown extends LitElement {
|
|
|
3177
3179
|
},
|
|
3178
3180
|
|
|
3179
3181
|
/**
|
|
3180
|
-
* Defines the screen size breakpoint (`
|
|
3182
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
3183
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
3184
|
+
*
|
|
3185
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
3186
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
3187
|
+
* @default sm
|
|
3181
3188
|
*/
|
|
3182
3189
|
fullscreenBreakpoint: {
|
|
3183
3190
|
type: String,
|
|
@@ -3317,6 +3324,15 @@ class AuroDropdown extends LitElement {
|
|
|
3317
3324
|
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroDropdown);
|
|
3318
3325
|
}
|
|
3319
3326
|
|
|
3327
|
+
/**
|
|
3328
|
+
* Accessor for reusing the focusable entity query string.
|
|
3329
|
+
* @private
|
|
3330
|
+
* @returns {string}
|
|
3331
|
+
*/
|
|
3332
|
+
get focusableEntityQuery () {
|
|
3333
|
+
return 'auro-input, [auro-input], auro-button, [auro-button], button, input';
|
|
3334
|
+
}
|
|
3335
|
+
|
|
3320
3336
|
connectedCallback() {
|
|
3321
3337
|
super.connectedCallback();
|
|
3322
3338
|
}
|
|
@@ -3330,6 +3346,8 @@ class AuroDropdown extends LitElement {
|
|
|
3330
3346
|
updated(changedProperties) {
|
|
3331
3347
|
this.floater.handleUpdate(changedProperties);
|
|
3332
3348
|
|
|
3349
|
+
// Note: `disabled` is not a breakpoint (it is not a screen size),
|
|
3350
|
+
// so it looks like we never consume this - however, dropdownBib handles this in the setter as "undefined"
|
|
3333
3351
|
if (changedProperties.has('fullscreenBreakpoint')) {
|
|
3334
3352
|
this.bibContent.mobileFullscreenBreakpoint = this.fullscreenBreakpoint;
|
|
3335
3353
|
}
|
|
@@ -3480,7 +3498,7 @@ class AuroDropdown extends LitElement {
|
|
|
3480
3498
|
|
|
3481
3499
|
this.triggerContentSlot.forEach((node) => {
|
|
3482
3500
|
if (node.querySelectorAll) {
|
|
3483
|
-
const auroElements = node.querySelectorAll(
|
|
3501
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3484
3502
|
auroElements.forEach((auroEl) => {
|
|
3485
3503
|
auroEl.addEventListener('focus', this.bindFocusEventToTrigger);
|
|
3486
3504
|
auroEl.addEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -3501,7 +3519,7 @@ class AuroDropdown extends LitElement {
|
|
|
3501
3519
|
|
|
3502
3520
|
this.triggerContentSlot.forEach((node) => {
|
|
3503
3521
|
if (node.querySelectorAll) {
|
|
3504
|
-
const auroElements = node.querySelectorAll(
|
|
3522
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3505
3523
|
auroElements.forEach((auroEl) => {
|
|
3506
3524
|
auroEl.removeEventListener('focus', this.bindFocusEventToTrigger);
|
|
3507
3525
|
auroEl.removeEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -2581,6 +2581,7 @@ var tokensCss$1 = css`:host{--ds-auro-dropdown-label-text-color: var(--ds-basic-
|
|
|
2581
2581
|
|
|
2582
2582
|
const DESIGN_TOKEN_BREAKPOINT_PREFIX = '--ds-grid-breakpoint-';
|
|
2583
2583
|
const DESIGN_TOKEN_BREAKPOINT_OPTIONS = [
|
|
2584
|
+
'xl',
|
|
2584
2585
|
'lg',
|
|
2585
2586
|
'md',
|
|
2586
2587
|
'sm',
|
|
@@ -2652,6 +2653,7 @@ class AuroDropdownBib extends LitElement {
|
|
|
2652
2653
|
|
|
2653
2654
|
set mobileFullscreenBreakpoint(value) {
|
|
2654
2655
|
// verify the defined breakpoint is valid and exit out if not
|
|
2656
|
+
// 'disabled' is a design token breakpoint so it acts as our "undefined" value
|
|
2655
2657
|
const validatedValue = DESIGN_TOKEN_BREAKPOINT_OPTIONS.includes(value) ? value : undefined;
|
|
2656
2658
|
if (!validatedValue) {
|
|
2657
2659
|
this._mobileBreakpointValue = undefined;
|
|
@@ -3177,7 +3179,12 @@ class AuroDropdown extends LitElement {
|
|
|
3177
3179
|
},
|
|
3178
3180
|
|
|
3179
3181
|
/**
|
|
3180
|
-
* Defines the screen size breakpoint (`
|
|
3182
|
+
* Defines the screen size breakpoint (`xs`, `sm`, `md`, `lg`, `xl`, `disabled`)
|
|
3183
|
+
* at which the dropdown switches to fullscreen mode on mobile. `disabled` indicates a dropdown should _never_ enter fullscreen.
|
|
3184
|
+
*
|
|
3185
|
+
* When expanded, the dropdown will automatically display in fullscreen mode
|
|
3186
|
+
* if the screen size is equal to or smaller than the selected breakpoint.
|
|
3187
|
+
* @default sm
|
|
3181
3188
|
*/
|
|
3182
3189
|
fullscreenBreakpoint: {
|
|
3183
3190
|
type: String,
|
|
@@ -3317,6 +3324,15 @@ class AuroDropdown extends LitElement {
|
|
|
3317
3324
|
AuroLibraryRuntimeUtils$1.prototype.registerComponent(name, AuroDropdown);
|
|
3318
3325
|
}
|
|
3319
3326
|
|
|
3327
|
+
/**
|
|
3328
|
+
* Accessor for reusing the focusable entity query string.
|
|
3329
|
+
* @private
|
|
3330
|
+
* @returns {string}
|
|
3331
|
+
*/
|
|
3332
|
+
get focusableEntityQuery () {
|
|
3333
|
+
return 'auro-input, [auro-input], auro-button, [auro-button], button, input';
|
|
3334
|
+
}
|
|
3335
|
+
|
|
3320
3336
|
connectedCallback() {
|
|
3321
3337
|
super.connectedCallback();
|
|
3322
3338
|
}
|
|
@@ -3330,6 +3346,8 @@ class AuroDropdown extends LitElement {
|
|
|
3330
3346
|
updated(changedProperties) {
|
|
3331
3347
|
this.floater.handleUpdate(changedProperties);
|
|
3332
3348
|
|
|
3349
|
+
// Note: `disabled` is not a breakpoint (it is not a screen size),
|
|
3350
|
+
// so it looks like we never consume this - however, dropdownBib handles this in the setter as "undefined"
|
|
3333
3351
|
if (changedProperties.has('fullscreenBreakpoint')) {
|
|
3334
3352
|
this.bibContent.mobileFullscreenBreakpoint = this.fullscreenBreakpoint;
|
|
3335
3353
|
}
|
|
@@ -3480,7 +3498,7 @@ class AuroDropdown extends LitElement {
|
|
|
3480
3498
|
|
|
3481
3499
|
this.triggerContentSlot.forEach((node) => {
|
|
3482
3500
|
if (node.querySelectorAll) {
|
|
3483
|
-
const auroElements = node.querySelectorAll(
|
|
3501
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3484
3502
|
auroElements.forEach((auroEl) => {
|
|
3485
3503
|
auroEl.addEventListener('focus', this.bindFocusEventToTrigger);
|
|
3486
3504
|
auroEl.addEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -3501,7 +3519,7 @@ class AuroDropdown extends LitElement {
|
|
|
3501
3519
|
|
|
3502
3520
|
this.triggerContentSlot.forEach((node) => {
|
|
3503
3521
|
if (node.querySelectorAll) {
|
|
3504
|
-
const auroElements = node.querySelectorAll(
|
|
3522
|
+
const auroElements = node.querySelectorAll(this.focusableEntityQuery);
|
|
3505
3523
|
auroElements.forEach((auroEl) => {
|
|
3506
3524
|
auroEl.removeEventListener('focus', this.bindFocusEventToTrigger);
|
|
3507
3525
|
auroEl.removeEventListener('blur', this.bindFocusEventToTrigger);
|
|
@@ -109,7 +109,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
109
109
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
110
110
|
|
|
111
111
|
```html
|
|
112
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
112
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-form/+esm"></script>
|
|
113
113
|
```
|
|
114
114
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
115
115
|
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
6
|
+
<title>Demo page for auto-complete</title>
|
|
7
|
+
</head>
|
|
8
|
+
<body>
|
|
9
|
+
<!-- EVERY AUTOCOMPLETE OPTION, auro inputs -->
|
|
10
|
+
|
|
11
|
+
<!-- EVERY AUTOCOMPLETE OPTION, auro combobox -->
|
|
12
|
+
|
|
13
|
+
<!-- LOGIN FORM -->
|
|
14
|
+
</body>
|
|
15
|
+
</html>
|
|
@@ -109,7 +109,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
109
109
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
110
110
|
|
|
111
111
|
```html
|
|
112
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
112
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-form/+esm"></script>
|
|
113
113
|
```
|
|
114
114
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
115
115
|
|
|
@@ -99,7 +99,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
99
99
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
100
100
|
|
|
101
101
|
```html
|
|
102
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
102
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-input/+esm"></script>
|
|
103
103
|
```
|
|
104
104
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
105
105
|
|
|
@@ -99,7 +99,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
99
99
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
100
100
|
|
|
101
101
|
```html
|
|
102
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
102
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-input/+esm"></script>
|
|
103
103
|
```
|
|
104
104
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
105
105
|
|
|
@@ -110,7 +110,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
110
110
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
111
111
|
|
|
112
112
|
```html
|
|
113
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
113
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-menu/+esm"></script>
|
|
114
114
|
```
|
|
115
115
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
116
116
|
|
|
@@ -110,7 +110,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
110
110
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
111
111
|
|
|
112
112
|
```html
|
|
113
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
113
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-menu/+esm"></script>
|
|
114
114
|
```
|
|
115
115
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
116
116
|
|
|
@@ -100,7 +100,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
100
100
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
101
101
|
|
|
102
102
|
```html
|
|
103
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
103
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-radio/+esm"></script>
|
|
104
104
|
```
|
|
105
105
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
106
106
|
|
|
@@ -100,7 +100,7 @@ The use of any Auro custom element has a dependency on the [Auro Design Tokens](
|
|
|
100
100
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
101
101
|
|
|
102
102
|
```html
|
|
103
|
-
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.
|
|
103
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@3.2.0/auro-radio/+esm"></script>
|
|
104
104
|
```
|
|
105
105
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
106
106
|
|