@brightspace-ui/core 2.112.8 → 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.
|
@@ -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
|
@@ -7992,6 +7992,11 @@
|
|
|
7992
7992
|
"path": "./components/list/list-controls.js",
|
|
7993
7993
|
"description": "Controls for list components containing select-all, etc.",
|
|
7994
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
|
+
},
|
|
7995
8000
|
{
|
|
7996
8001
|
"name": "no-selection",
|
|
7997
8002
|
"description": "Whether to render select-all and selection summary",
|
|
@@ -8022,6 +8027,12 @@
|
|
|
8022
8027
|
}
|
|
8023
8028
|
],
|
|
8024
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
|
+
},
|
|
8025
8036
|
{
|
|
8026
8037
|
"name": "noSelection",
|
|
8027
8038
|
"attribute": "no-selection",
|
|
@@ -10621,6 +10632,11 @@
|
|
|
10621
10632
|
"path": "./components/selection/selection-controls.js",
|
|
10622
10633
|
"description": "Controls for selection components (e.g. list, table-wrapper) containing select-all, etc.",
|
|
10623
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
|
+
},
|
|
10624
10640
|
{
|
|
10625
10641
|
"name": "no-selection",
|
|
10626
10642
|
"description": "Whether to render select-all and selection summary",
|
|
@@ -10651,6 +10667,12 @@
|
|
|
10651
10667
|
}
|
|
10652
10668
|
],
|
|
10653
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
|
+
},
|
|
10654
10676
|
{
|
|
10655
10677
|
"name": "noSelection",
|
|
10656
10678
|
"attribute": "no-selection",
|
|
@@ -11647,6 +11669,11 @@
|
|
|
11647
11669
|
"path": "./components/table/table-controls.js",
|
|
11648
11670
|
"description": "Controls for table components containing a selection summary and selection actions.",
|
|
11649
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
|
+
},
|
|
11650
11677
|
{
|
|
11651
11678
|
"name": "no-selection",
|
|
11652
11679
|
"description": "Whether to render the selection summary",
|
|
@@ -11677,6 +11704,12 @@
|
|
|
11677
11704
|
}
|
|
11678
11705
|
],
|
|
11679
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
|
+
},
|
|
11680
11713
|
{
|
|
11681
11714
|
"name": "noSelection",
|
|
11682
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",
|