@brightspace-ui/core 2.112.7 → 2.113.0
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/components/inputs/input-date.js +0 -2
- package/components/inputs/input-text.js +1 -14
- package/components/selection/README.md +1 -0
- package/components/selection/selection-controls.js +10 -2
- package/components/selection/selection-summary.js +1 -1
- package/custom-elements.json +33 -22
- package/package.json +1 -1
|
@@ -278,7 +278,6 @@ class InputDate extends FocusMixin(LabelledMixin(SkeletonMixin(FormElementMixin(
|
|
|
278
278
|
<d2l-input-text
|
|
279
279
|
?novalidate="${this.noValidate}"
|
|
280
280
|
aria-invalid="${this.invalid ? 'true' : 'false'}"
|
|
281
|
-
atomic="true"
|
|
282
281
|
@blur="${this._handleInputTextBlur}"
|
|
283
282
|
@change="${this._handleChange}"
|
|
284
283
|
class="d2l-dropdown-opener"
|
|
@@ -291,7 +290,6 @@ class InputDate extends FocusMixin(LabelledMixin(SkeletonMixin(FormElementMixin(
|
|
|
291
290
|
label="${ifDefined(this.label)}"
|
|
292
291
|
?label-hidden="${this.labelHidden || this.labelledBy}"
|
|
293
292
|
.labelRequired="${false}"
|
|
294
|
-
live="assertive"
|
|
295
293
|
@mouseup="${this._handleMouseup}"
|
|
296
294
|
placeholder="${shortDateFormat}"
|
|
297
295
|
?required="${this.required}"
|
|
@@ -38,12 +38,6 @@ class InputText extends FocusMixin(LabelledMixin(FormElementMixin(SkeletonMixin(
|
|
|
38
38
|
* @type {string}
|
|
39
39
|
*/
|
|
40
40
|
ariaInvalid: { type: String, attribute: 'aria-invalid' },
|
|
41
|
-
/**
|
|
42
|
-
* ADVANCED: Specifies whether or not the screen reader should always present changes to the live region as a whole.
|
|
43
|
-
* This only applies if live is set to polite or assertive.
|
|
44
|
-
* @type {string}
|
|
45
|
-
*/
|
|
46
|
-
atomic: { type: String },
|
|
47
41
|
/**
|
|
48
42
|
* Specifies which types of values can be autofilled by the browser
|
|
49
43
|
* @type {string}
|
|
@@ -79,11 +73,6 @@ class InputText extends FocusMixin(LabelledMixin(FormElementMixin(SkeletonMixin(
|
|
|
79
73
|
* @type {boolean}
|
|
80
74
|
*/
|
|
81
75
|
labelHidden: { type: Boolean, attribute: 'label-hidden' },
|
|
82
|
-
/**
|
|
83
|
-
* ADVANCED: Set the priority with which screen readers should treat updates to the input's live text region
|
|
84
|
-
* @type {string}
|
|
85
|
-
*/
|
|
86
|
-
live: { type: String },
|
|
87
76
|
/**
|
|
88
77
|
* For number inputs, maximum value
|
|
89
78
|
* @type {string}
|
|
@@ -426,12 +415,10 @@ class InputText extends FocusMixin(LabelledMixin(FormElementMixin(SkeletonMixin(
|
|
|
426
415
|
const input = html`
|
|
427
416
|
<div class="d2l-input-container">
|
|
428
417
|
<div class="d2l-input-text-container d2l-skeletize" style="${styleMap(inputContainerStyles)}">
|
|
429
|
-
<input aria-
|
|
430
|
-
aria-describedby="${ifDefined(this.description ? this._descriptionId : undefined)}"
|
|
418
|
+
<input aria-describedby="${ifDefined(this.description ? this._descriptionId : undefined)}"
|
|
431
419
|
aria-haspopup="${ifDefined(this.ariaHaspopup)}"
|
|
432
420
|
aria-invalid="${ifDefined(ariaInvalid)}"
|
|
433
421
|
aria-label="${ifDefined(this._getAriaLabel())}"
|
|
434
|
-
aria-live="${ifDefined(this.live)}"
|
|
435
422
|
aria-required="${ifDefined(ariaRequired)}"
|
|
436
423
|
?required="${this.required}"
|
|
437
424
|
autocomplete="${ifDefined(this.autocomplete)}"
|
|
@@ -486,6 +486,7 @@ When using lists, use the list-specific `d2l-list-controls` instead, which exten
|
|
|
486
486
|
| Property | Type | Description |
|
|
487
487
|
|---|---|---|
|
|
488
488
|
| `no-selection` | Boolean | Whether to render select-all and selection summary |
|
|
489
|
+
| `no-selection-text` | String | Text to display if no items are selected (overrides pageable counts) |
|
|
489
490
|
| `no-sticky` | Boolean | Disables sticky positioning for the controls |
|
|
490
491
|
| `select-all-pages-allowed` | Boolean | Whether all pages can be selected |
|
|
491
492
|
<!-- docs: end hidden content -->
|
|
@@ -24,6 +24,11 @@ export class SelectionControls extends PageableSubscriberMixin(SelectionObserver
|
|
|
24
24
|
* @type {boolean}
|
|
25
25
|
*/
|
|
26
26
|
noSelection: { type: Boolean, attribute: 'no-selection' },
|
|
27
|
+
/**
|
|
28
|
+
* ADVANCED: Text to display if no items are selected (overrides pageable counts)
|
|
29
|
+
* @type {string}
|
|
30
|
+
*/
|
|
31
|
+
noSelectionText: { type: String, attribute: 'no-selection-text' },
|
|
27
32
|
/**
|
|
28
33
|
* Disables sticky positioning for the controls
|
|
29
34
|
* @type {boolean}
|
|
@@ -150,8 +155,11 @@ export class SelectionControls extends PageableSubscriberMixin(SelectionObserver
|
|
|
150
155
|
if (changedProperties.has('noSticky')) {
|
|
151
156
|
this._stickyObserverUpdate();
|
|
152
157
|
}
|
|
153
|
-
|
|
154
|
-
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
willUpdate(changedProperties) {
|
|
161
|
+
if (changedProperties.has('noSelectionText') || changedProperties.has('_pageableInfo')) {
|
|
162
|
+
this._noSelectionText = this.noSelectionText || this._getNoSelectionText();
|
|
155
163
|
}
|
|
156
164
|
}
|
|
157
165
|
|
|
@@ -44,7 +44,7 @@ class Summary extends LocalizeCoreElement(SelectionObserverMixin(LitElement)) {
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
willUpdate(changedProperties) {
|
|
47
|
-
if (changedProperties.has('_provider') || changedProperties.has('selectionInfo')) {
|
|
47
|
+
if (changedProperties.has('_provider') || changedProperties.has('selectionInfo') || changedProperties.has('noSelectionText')) {
|
|
48
48
|
this._updateSelectSummary();
|
|
49
49
|
}
|
|
50
50
|
}
|
package/custom-elements.json
CHANGED
|
@@ -6445,11 +6445,6 @@
|
|
|
6445
6445
|
"description": "ADVANCED: Indicates that the input value is invalid",
|
|
6446
6446
|
"type": "string"
|
|
6447
6447
|
},
|
|
6448
|
-
{
|
|
6449
|
-
"name": "atomic",
|
|
6450
|
-
"description": "ADVANCED: Specifies whether or not the screen reader should always present changes to the live region as a whole.\nThis only applies if live is set to polite or assertive.",
|
|
6451
|
-
"type": "string"
|
|
6452
|
-
},
|
|
6453
6448
|
{
|
|
6454
6449
|
"name": "autocomplete",
|
|
6455
6450
|
"description": "Specifies which types of values can be autofilled by the browser",
|
|
@@ -6465,11 +6460,6 @@
|
|
|
6465
6460
|
"description": "Restricts the maximum width of the input box without impacting the width of the label.",
|
|
6466
6461
|
"type": "string"
|
|
6467
6462
|
},
|
|
6468
|
-
{
|
|
6469
|
-
"name": "live",
|
|
6470
|
-
"description": "ADVANCED: Set the priority with which screen readers should treat updates to the input's live text region",
|
|
6471
|
-
"type": "string"
|
|
6472
|
-
},
|
|
6473
6463
|
{
|
|
6474
6464
|
"name": "max",
|
|
6475
6465
|
"description": "For number inputs, maximum value",
|
|
@@ -6619,12 +6609,6 @@
|
|
|
6619
6609
|
"description": "ADVANCED: Indicates that the input value is invalid",
|
|
6620
6610
|
"type": "string"
|
|
6621
6611
|
},
|
|
6622
|
-
{
|
|
6623
|
-
"name": "atomic",
|
|
6624
|
-
"attribute": "atomic",
|
|
6625
|
-
"description": "ADVANCED: Specifies whether or not the screen reader should always present changes to the live region as a whole.\nThis only applies if live is set to polite or assertive.",
|
|
6626
|
-
"type": "string"
|
|
6627
|
-
},
|
|
6628
6612
|
{
|
|
6629
6613
|
"name": "autocomplete",
|
|
6630
6614
|
"attribute": "autocomplete",
|
|
@@ -6643,12 +6627,6 @@
|
|
|
6643
6627
|
"description": "Restricts the maximum width of the input box without impacting the width of the label.",
|
|
6644
6628
|
"type": "string"
|
|
6645
6629
|
},
|
|
6646
|
-
{
|
|
6647
|
-
"name": "live",
|
|
6648
|
-
"attribute": "live",
|
|
6649
|
-
"description": "ADVANCED: Set the priority with which screen readers should treat updates to the input's live text region",
|
|
6650
|
-
"type": "string"
|
|
6651
|
-
},
|
|
6652
6630
|
{
|
|
6653
6631
|
"name": "max",
|
|
6654
6632
|
"attribute": "max",
|
|
@@ -8014,6 +7992,11 @@
|
|
|
8014
7992
|
"path": "./components/list/list-controls.js",
|
|
8015
7993
|
"description": "Controls for list components containing select-all, etc.",
|
|
8016
7994
|
"attributes": [
|
|
7995
|
+
{
|
|
7996
|
+
"name": "no-selection-text",
|
|
7997
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
7998
|
+
"type": "string"
|
|
7999
|
+
},
|
|
8017
8000
|
{
|
|
8018
8001
|
"name": "no-selection",
|
|
8019
8002
|
"description": "Whether to render select-all and selection summary",
|
|
@@ -8044,6 +8027,12 @@
|
|
|
8044
8027
|
}
|
|
8045
8028
|
],
|
|
8046
8029
|
"properties": [
|
|
8030
|
+
{
|
|
8031
|
+
"name": "noSelectionText",
|
|
8032
|
+
"attribute": "no-selection-text",
|
|
8033
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
8034
|
+
"type": "string"
|
|
8035
|
+
},
|
|
8047
8036
|
{
|
|
8048
8037
|
"name": "noSelection",
|
|
8049
8038
|
"attribute": "no-selection",
|
|
@@ -10643,6 +10632,11 @@
|
|
|
10643
10632
|
"path": "./components/selection/selection-controls.js",
|
|
10644
10633
|
"description": "Controls for selection components (e.g. list, table-wrapper) containing select-all, etc.",
|
|
10645
10634
|
"attributes": [
|
|
10635
|
+
{
|
|
10636
|
+
"name": "no-selection-text",
|
|
10637
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
10638
|
+
"type": "string"
|
|
10639
|
+
},
|
|
10646
10640
|
{
|
|
10647
10641
|
"name": "no-selection",
|
|
10648
10642
|
"description": "Whether to render select-all and selection summary",
|
|
@@ -10673,6 +10667,12 @@
|
|
|
10673
10667
|
}
|
|
10674
10668
|
],
|
|
10675
10669
|
"properties": [
|
|
10670
|
+
{
|
|
10671
|
+
"name": "noSelectionText",
|
|
10672
|
+
"attribute": "no-selection-text",
|
|
10673
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
10674
|
+
"type": "string"
|
|
10675
|
+
},
|
|
10676
10676
|
{
|
|
10677
10677
|
"name": "noSelection",
|
|
10678
10678
|
"attribute": "no-selection",
|
|
@@ -11669,6 +11669,11 @@
|
|
|
11669
11669
|
"path": "./components/table/table-controls.js",
|
|
11670
11670
|
"description": "Controls for table components containing a selection summary and selection actions.",
|
|
11671
11671
|
"attributes": [
|
|
11672
|
+
{
|
|
11673
|
+
"name": "no-selection-text",
|
|
11674
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
11675
|
+
"type": "string"
|
|
11676
|
+
},
|
|
11672
11677
|
{
|
|
11673
11678
|
"name": "no-selection",
|
|
11674
11679
|
"description": "Whether to render the selection summary",
|
|
@@ -11699,6 +11704,12 @@
|
|
|
11699
11704
|
}
|
|
11700
11705
|
],
|
|
11701
11706
|
"properties": [
|
|
11707
|
+
{
|
|
11708
|
+
"name": "noSelectionText",
|
|
11709
|
+
"attribute": "no-selection-text",
|
|
11710
|
+
"description": "ADVANCED: Text to display if no items are selected (overrides pageable counts)",
|
|
11711
|
+
"type": "string"
|
|
11712
|
+
},
|
|
11702
11713
|
{
|
|
11703
11714
|
"name": "noSelection",
|
|
11704
11715
|
"attribute": "no-selection",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brightspace-ui/core",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.113.0",
|
|
4
4
|
"description": "A collection of accessible, free, open-source web components for building Brightspace applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": "https://github.com/BrightspaceUI/core.git",
|