@brightspace-ui/core 3.267.0 → 3.267.3
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/alert/alert-toast.js +98 -102
- package/components/alert/alert.js +109 -113
- package/components/backdrop/backdrop-dirty-overlay.js +13 -17
- package/components/backdrop/backdrop-loading.js +105 -109
- package/components/backdrop/backdrop.js +50 -54
- package/components/breadcrumbs/breadcrumb-current-page.js +19 -23
- package/components/breadcrumbs/breadcrumb.js +50 -54
- package/components/breadcrumbs/breadcrumbs.js +34 -38
- package/components/button/button-add.js +156 -164
- package/components/button/button-copy-mixin.js +9 -11
- package/components/button/button-copy.js +15 -19
- package/components/button/button-icon.js +110 -114
- package/components/button/button-move.js +153 -157
- package/components/button/button-split-item.js +16 -20
- package/components/button/button-split.js +70 -74
- package/components/button/button-subtle-copy.js +17 -19
- package/components/button/button-subtle.js +145 -149
- package/components/button/button-toggle.js +25 -29
- package/components/button/button.js +70 -74
- package/components/button/floating-buttons.js +63 -67
- package/components/calendar/calendar.js +244 -248
- package/components/card/card-content-meta.js +13 -15
- package/components/card/card-content-title.js +9 -11
- package/components/card/card-footer-link.js +76 -80
- package/components/card/card-loading-shimmer.js +35 -39
- package/components/card/card.js +188 -192
- package/components/collapsible-panel/collapsible-panel-group.js +17 -21
- package/components/collapsible-panel/collapsible-panel-summary-item.js +27 -31
- package/components/collapsible-panel/collapsible-panel.js +258 -262
- package/components/count-badge/count-badge-icon.js +12 -16
- package/components/count-badge/count-badge-mixin.js +124 -128
- package/components/count-badge/count-badge.js +2 -4
- package/components/description-list/description-list-wrapper.js +27 -31
- package/components/dialog/dialog-confirm.js +55 -59
- package/components/dialog/dialog-fullscreen.js +128 -132
- package/components/dialog/dialog-mixin.js +39 -41
- package/components/dialog/dialog.js +61 -65
- package/components/dropdown/dropdown-button-subtle.js +21 -25
- package/components/dropdown/dropdown-button.js +31 -35
- package/components/dropdown/dropdown-context-menu.js +28 -31
- package/components/dropdown/dropdown-menu.js +27 -31
- package/components/dropdown/dropdown-more.js +23 -26
- package/components/dropdown/dropdown-opener-mixin.js +44 -46
- package/components/dropdown/dropdown-popover-mixin.js +155 -159
- package/components/dropdown/dropdown-tabs.js +5 -7
- package/components/dropdown/dropdown.js +1 -3
- package/components/empty-state/empty-state-action-button.js +18 -22
- package/components/empty-state/empty-state-action-link.js +14 -18
- package/components/empty-state/empty-state-illustrated.js +21 -25
- package/components/empty-state/empty-state-simple.js +8 -12
- package/components/expand-collapse/expand-collapse-content.js +48 -52
- package/components/filter/filter-dimension-set-date-text-value.js +34 -36
- package/components/filter/filter-dimension-set-date-time-range-value.js +45 -47
- package/components/filter/filter-dimension-set-empty-state.js +17 -19
- package/components/filter/filter-dimension-set-value.js +27 -29
- package/components/filter/filter-dimension-set.js +65 -67
- package/components/filter/filter-overflow-group.js +15 -19
- package/components/filter/filter-tags.js +16 -19
- package/components/filter/filter.js +115 -119
- package/components/focus-trap/focus-trap.js +17 -21
- package/components/form/form-element-mixin.js +33 -35
- package/components/form/form-error-summary.js +37 -42
- package/components/form/form.js +33 -37
- package/components/hierarchical-view/hierarchical-view-mixin.js +76 -80
- package/components/hierarchical-view/hierarchical-view.js +5 -7
- package/components/html-block/html-block.js +45 -49
- package/components/icons/icon-custom.js +20 -24
- package/components/icons/icon.js +20 -24
- package/components/icons/slotted-icon-mixin.js +16 -18
- package/components/inputs/input-checkbox-group.js +34 -38
- package/components/inputs/input-checkbox.js +106 -110
- package/components/inputs/input-color.js +142 -148
- package/components/inputs/input-date-range.js +90 -94
- package/components/inputs/input-date-time-range-to.js +70 -74
- package/components/inputs/input-date-time-range.js +110 -115
- package/components/inputs/input-date-time.js +75 -79
- package/components/inputs/input-date.js +101 -105
- package/components/inputs/input-fieldset.js +37 -43
- package/components/inputs/input-group.js +10 -12
- package/components/inputs/input-inline-help.js +4 -6
- package/components/inputs/input-number.js +112 -118
- package/components/inputs/input-percent.js +52 -58
- package/components/inputs/input-radio-group.js +45 -49
- package/components/inputs/input-radio-spacer.js +11 -13
- package/components/inputs/input-radio.js +62 -66
- package/components/inputs/input-search.js +63 -68
- package/components/inputs/input-styles.js +140 -3
- package/components/inputs/input-text.js +245 -251
- package/components/inputs/input-textarea.js +128 -132
- package/components/inputs/input-time-range.js +100 -104
- package/components/inputs/input-time.js +107 -113
- package/components/link/link-mixin.js +37 -41
- package/components/link/link.js +113 -119
- package/components/list/list-controls.js +25 -29
- package/components/list/list-item-button-mixin.js +10 -12
- package/components/list/list-item-checkbox-mixin.js +35 -37
- package/components/list/list-item-content.js +33 -35
- package/components/list/list-item-drag-drop-mixin.js +45 -47
- package/components/list/list-item-drag-handle.js +80 -84
- package/components/list/list-item-drag-image.js +77 -81
- package/components/list/list-item-expand-collapse-mixin.js +17 -19
- package/components/list/list-item-generic-layout.js +222 -226
- package/components/list/list-item-link-mixin.js +10 -12
- package/components/list/list-item-mixin.js +68 -70
- package/components/list/list-item-nav-mixin.js +17 -19
- package/components/list/list-item-placement-marker.js +65 -67
- package/components/list/list-item-role-mixin.js +9 -11
- package/components/list/list-item.js +7 -9
- package/components/list/list.js +121 -125
- package/components/loading-spinner/loading-spinner.js +93 -97
- package/custom-elements.json +1920 -6694
- package/package.json +3 -2
|
@@ -9,73 +9,71 @@ import { html, LitElement } from 'lit';
|
|
|
9
9
|
*/
|
|
10
10
|
class FilterDimensionSet extends LitElement {
|
|
11
11
|
|
|
12
|
-
static
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
};
|
|
78
|
-
}
|
|
12
|
+
static properties = {
|
|
13
|
+
/**
|
|
14
|
+
* Whether the dimension has more values to load. Manual search and selected first should be set if has more is being used
|
|
15
|
+
* @type {boolean}
|
|
16
|
+
*/
|
|
17
|
+
hasMore: { type: Boolean, attribute: 'has-more' },
|
|
18
|
+
/**
|
|
19
|
+
* A heading displayed above the list items. This is usually unnecessary, but can be used to emphasize or promote something specific about the list of items to help orient users.
|
|
20
|
+
* @type {string}
|
|
21
|
+
*/
|
|
22
|
+
headerText: { type: String, attribute: 'header-text' },
|
|
23
|
+
/**
|
|
24
|
+
* The introductory text to display at the top of the filter dropdown
|
|
25
|
+
* @type {string}
|
|
26
|
+
*/
|
|
27
|
+
introductoryText: { type: String, attribute: 'introductory-text' },
|
|
28
|
+
/**
|
|
29
|
+
* REQUIRED: Unique key to represent this dimension in the filter
|
|
30
|
+
* @type {string}
|
|
31
|
+
*/
|
|
32
|
+
key: { type: String },
|
|
33
|
+
/**
|
|
34
|
+
* Whether the values for this dimension are still loading and a loading spinner should be displayed
|
|
35
|
+
* @type {boolean}
|
|
36
|
+
*/
|
|
37
|
+
loading: { type: Boolean },
|
|
38
|
+
/**
|
|
39
|
+
* @ignore
|
|
40
|
+
*/
|
|
41
|
+
minWidth: { type: Number },
|
|
42
|
+
/**
|
|
43
|
+
* ADVANCED: Whether to ignore the enforce single selection setting for this dimension.
|
|
44
|
+
*/
|
|
45
|
+
ignoreEnforceSelectionSingle: { type: Boolean, attribute: 'ignore-enforce-selection-single' },
|
|
46
|
+
/**
|
|
47
|
+
* Whether to hide the search input, perform a simple text search, or fire an event on search
|
|
48
|
+
* @type {'none'|'automatic'|'manual'}
|
|
49
|
+
*/
|
|
50
|
+
searchType: { type: String, attribute: 'search-type' },
|
|
51
|
+
/**
|
|
52
|
+
* Adds a select all checkbox and summary for this dimension
|
|
53
|
+
* @type {boolean}
|
|
54
|
+
*/
|
|
55
|
+
selectAll: { type: Boolean, attribute: 'select-all' },
|
|
56
|
+
/**
|
|
57
|
+
* Whether to render the selected items at the top of the filter. Forced on if load more paging is being used
|
|
58
|
+
* @type {boolean}
|
|
59
|
+
*/
|
|
60
|
+
selectedFirst: { type: Boolean, attribute: 'selected-first' },
|
|
61
|
+
/**
|
|
62
|
+
* Whether only one value can be selected at a time for this dimension
|
|
63
|
+
* @type {boolean}
|
|
64
|
+
*/
|
|
65
|
+
selectionSingle: { type: Boolean, attribute: 'selection-single' },
|
|
66
|
+
/**
|
|
67
|
+
* REQUIRED: The text that is displayed for the dimension title
|
|
68
|
+
* @type {string}
|
|
69
|
+
*/
|
|
70
|
+
text: { type: String },
|
|
71
|
+
/**
|
|
72
|
+
* Whether to hide the dimension in the text sent to active filter subscribers
|
|
73
|
+
* @type {boolean}
|
|
74
|
+
*/
|
|
75
|
+
valueOnlyActiveFilterText: { type: Boolean, attribute: 'value-only-active-filter-text' }
|
|
76
|
+
};
|
|
79
77
|
|
|
80
78
|
constructor() {
|
|
81
79
|
super();
|
|
@@ -12,25 +12,21 @@ const updateEvents = ['d2l-filter-dimension-load-more', 'd2l-filter-dimension-se
|
|
|
12
12
|
*/
|
|
13
13
|
class FilterOverflowGroup extends OverflowGroupMixin(LitElement) {
|
|
14
14
|
|
|
15
|
-
static
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
margin-inline-end: 0.3rem;
|
|
31
|
-
}
|
|
32
|
-
`];
|
|
33
|
-
}
|
|
15
|
+
static properties = {
|
|
16
|
+
/**
|
|
17
|
+
* Show `d2l-filter-tags` beneath the filters. Tags will be shown for all filters in the group.
|
|
18
|
+
* @type {boolean}
|
|
19
|
+
*/
|
|
20
|
+
tags: { type: Boolean },
|
|
21
|
+
_openedDimensions: { state: true },
|
|
22
|
+
_filterIds: { state: true }
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
static styles = [super.styles, css`
|
|
26
|
+
::slotted(d2l-filter) {
|
|
27
|
+
margin-inline-end: 0.3rem;
|
|
28
|
+
}
|
|
29
|
+
`];
|
|
34
30
|
|
|
35
31
|
constructor() {
|
|
36
32
|
super();
|
|
@@ -11,26 +11,23 @@ import { LocalizeCoreElement } from '../../helpers/localize-core-element.js';
|
|
|
11
11
|
const CLEAR_TIMEOUT = 310; /** Corresponds to timeout in _dispatchChangeEvent in filter + 10 ms */
|
|
12
12
|
|
|
13
13
|
class FilterTags extends LocalizeCoreElement(LitElement) {
|
|
14
|
-
static get properties() {
|
|
15
|
-
return {
|
|
16
|
-
/**
|
|
17
|
-
* REQUIRED: Id(s) (space-delimited) of the filter component(s) to subscribe to
|
|
18
|
-
* @type {string}
|
|
19
|
-
*/
|
|
20
|
-
filterIds: { type: String, attribute: 'filter-ids' }
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
14
|
|
|
24
|
-
static
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
15
|
+
static properties = {
|
|
16
|
+
/**
|
|
17
|
+
* REQUIRED: Id(s) (space-delimited) of the filter component(s) to subscribe to
|
|
18
|
+
* @type {string}
|
|
19
|
+
*/
|
|
20
|
+
filterIds: { type: String, attribute: 'filter-ids' }
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
static styles = css`
|
|
24
|
+
:host {
|
|
25
|
+
display: inline-block;
|
|
26
|
+
}
|
|
27
|
+
:host([hidden]) {
|
|
28
|
+
display: none;
|
|
29
|
+
}
|
|
30
|
+
`;
|
|
34
31
|
|
|
35
32
|
constructor() {
|
|
36
33
|
super();
|
|
@@ -72,143 +72,139 @@ function addSpaceListener() {
|
|
|
72
72
|
*/
|
|
73
73
|
class Filter extends FocusMixin(LocalizeCoreElement(LitElement)) {
|
|
74
74
|
|
|
75
|
-
static
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
[slot="header"] {
|
|
104
|
-
padding: 0.9rem 0.3rem;
|
|
105
|
-
}
|
|
75
|
+
static properties = {
|
|
76
|
+
/**
|
|
77
|
+
* Disables the dropdown opener for the filter
|
|
78
|
+
* @type {boolean}
|
|
79
|
+
*/
|
|
80
|
+
disabled: { type: Boolean, reflect: true },
|
|
81
|
+
/**
|
|
82
|
+
* Indicates if the filter is open
|
|
83
|
+
* @type {boolean}
|
|
84
|
+
*/
|
|
85
|
+
opened: { type: Boolean, reflect: true },
|
|
86
|
+
/**
|
|
87
|
+
* Optional override for the button text used for a multi-dimensional filter
|
|
88
|
+
* @type {string}
|
|
89
|
+
*/
|
|
90
|
+
text: { type: String },
|
|
91
|
+
_activeDimensionKey: { type: String, attribute: false },
|
|
92
|
+
_dimensions: { type: Array, attribute: false },
|
|
93
|
+
_displayKeyboardTooltip: { state: true },
|
|
94
|
+
_ignoreSlotChanges: { type: Boolean },
|
|
95
|
+
_minWidth: { type: Number, attribute: false },
|
|
96
|
+
_totalAppliedCount: { type: Number, attribute: false }
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
static styles = [bodyCompactStyles, bodySmallStyles, bodyStandardStyles, heading4Styles, offscreenStyles, css`
|
|
100
|
+
[slot="header"] {
|
|
101
|
+
padding: 0.9rem 0.3rem;
|
|
102
|
+
}
|
|
106
103
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
104
|
+
.d2l-filter-dimension-header {
|
|
105
|
+
padding-bottom: 0.9rem;
|
|
106
|
+
}
|
|
110
107
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
108
|
+
.d2l-filter-dimension-header.with-intro {
|
|
109
|
+
padding-bottom: 0.6rem;
|
|
110
|
+
}
|
|
114
111
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
112
|
+
.d2l-filter-dimension-header,
|
|
113
|
+
.d2l-filter-dimension-header-actions {
|
|
114
|
+
align-items: center;
|
|
115
|
+
display: flex;
|
|
116
|
+
}
|
|
120
117
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
118
|
+
.d2l-filter-dimension-header-actions {
|
|
119
|
+
flex-flow: row wrap;
|
|
120
|
+
}
|
|
124
121
|
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
122
|
+
d2l-input-search {
|
|
123
|
+
flex: 1 0;
|
|
124
|
+
margin-inline: 0.3rem 0.6rem;
|
|
125
|
+
}
|
|
129
126
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
127
|
+
.d2l-filter-dimension-select-all {
|
|
128
|
+
flex-basis: 100%;
|
|
129
|
+
margin-top: 0.9rem;
|
|
130
|
+
}
|
|
134
131
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
132
|
+
d2l-selection-select-all {
|
|
133
|
+
padding: 0 0.6rem;
|
|
134
|
+
}
|
|
138
135
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
136
|
+
.d2l-filter-dimension-header-text {
|
|
137
|
+
flex-grow: 1;
|
|
138
|
+
padding-inline-end: calc(2rem + 2px);
|
|
139
|
+
text-align: center;
|
|
140
|
+
${overflowEllipsisDeclarations}
|
|
141
|
+
}
|
|
145
142
|
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
143
|
+
.d2l-filter-dimension-set-value {
|
|
144
|
+
align-items: center;
|
|
145
|
+
color: var(--d2l-color-ferrite);
|
|
146
|
+
display: flex;
|
|
147
|
+
gap: 0.45rem;
|
|
148
|
+
line-height: unset;
|
|
149
|
+
}
|
|
150
|
+
.d2l-filter-dimension-set-value d2l-icon {
|
|
151
|
+
flex-shrink: 0;
|
|
152
|
+
}
|
|
153
|
+
d2l-expand-collapse-content[expanded] {
|
|
154
|
+
margin-inline-start: -2.1rem;
|
|
155
|
+
padding-block: 0.8rem 0.4rem;
|
|
156
|
+
}
|
|
157
|
+
d2l-list-item.expanding-content {
|
|
158
|
+
overflow-y: hidden;
|
|
159
|
+
}
|
|
163
160
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
161
|
+
.d2l-filter-dimension-set-value-text {
|
|
162
|
+
hyphens: auto;
|
|
163
|
+
${getOverflowDeclarations({ lines: 2 })}
|
|
164
|
+
}
|
|
168
165
|
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
166
|
+
d2l-list-item[selection-disabled] .d2l-filter-dimension-set-value,
|
|
167
|
+
d2l-list-item[selection-disabled] .d2l-body-small {
|
|
168
|
+
color: var(--d2l-color-chromite);
|
|
169
|
+
}
|
|
173
170
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
171
|
+
.d2l-filter-dimension-intro-text {
|
|
172
|
+
margin: 0;
|
|
173
|
+
padding: 0.6rem 1.5rem 1.5rem;
|
|
174
|
+
text-align: center;
|
|
175
|
+
}
|
|
179
176
|
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
177
|
+
.d2l-filter-dimension-intro-text.multi-dimension {
|
|
178
|
+
padding: 0 1.5rem 1.5rem;
|
|
179
|
+
}
|
|
183
180
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
181
|
+
.d2l-empty-state-container {
|
|
182
|
+
padding: 0.9rem 0.9rem calc(0.9rem - 5px);
|
|
183
|
+
}
|
|
187
184
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
185
|
+
.list-header-text {
|
|
186
|
+
color: var(--d2l-color-ferrite);
|
|
187
|
+
margin: 0;
|
|
188
|
+
padding-bottom: 0.05rem;
|
|
189
|
+
padding-top: 0.65rem;
|
|
190
|
+
}
|
|
194
191
|
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
192
|
+
.d2l-filter-dimension-info-message {
|
|
193
|
+
color: var(--d2l-color-ferrite);
|
|
194
|
+
display: flex;
|
|
195
|
+
justify-content: center;
|
|
196
|
+
}
|
|
200
197
|
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
198
|
+
/* Needed to "undo" the menu-item style for multiple dimensions */
|
|
199
|
+
d2l-hierarchical-view {
|
|
200
|
+
cursor: auto;
|
|
201
|
+
}
|
|
205
202
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
}
|
|
203
|
+
d2l-loading-spinner {
|
|
204
|
+
padding-top: 0.6rem;
|
|
205
|
+
width: 100%;
|
|
206
|
+
}
|
|
207
|
+
`];
|
|
212
208
|
|
|
213
209
|
constructor() {
|
|
214
210
|
super();
|
|
@@ -12,27 +12,23 @@ const traps = [];
|
|
|
12
12
|
*/
|
|
13
13
|
class FocusTrap extends FocusMixin(LitElement) {
|
|
14
14
|
|
|
15
|
-
static
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
display: none;
|
|
33
|
-
}
|
|
34
|
-
`;
|
|
35
|
-
}
|
|
15
|
+
static properties = {
|
|
16
|
+
/**
|
|
17
|
+
* Whether the component should trap user focus.
|
|
18
|
+
* @type {boolean}
|
|
19
|
+
*/
|
|
20
|
+
trap: { type: Boolean },
|
|
21
|
+
_legacyPromptIds: { state: true }
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
static styles = css`
|
|
25
|
+
:host {
|
|
26
|
+
display: inline-block;
|
|
27
|
+
}
|
|
28
|
+
:host([hidden]) {
|
|
29
|
+
display: none;
|
|
30
|
+
}
|
|
31
|
+
`;
|
|
36
32
|
|
|
37
33
|
constructor() {
|
|
38
34
|
super();
|
|
@@ -77,41 +77,39 @@ export class FormElementValidityState {
|
|
|
77
77
|
|
|
78
78
|
export const FormElementMixin = superclass => class extends LocalizeCoreElement(superclass) {
|
|
79
79
|
|
|
80
|
-
static
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
};
|
|
114
|
-
}
|
|
80
|
+
static properties = {
|
|
81
|
+
/**
|
|
82
|
+
* @ignore
|
|
83
|
+
*/
|
|
84
|
+
forceInvalid: { type: Boolean, attribute: false },
|
|
85
|
+
/**
|
|
86
|
+
* @ignore
|
|
87
|
+
*/
|
|
88
|
+
invalid: { type: Boolean, reflect: true },
|
|
89
|
+
/**
|
|
90
|
+
* Name of the form control. Submitted with the form as part of a name/value pair.
|
|
91
|
+
* @type {string}
|
|
92
|
+
*/
|
|
93
|
+
name: { type: String },
|
|
94
|
+
/**
|
|
95
|
+
* @ignore
|
|
96
|
+
*/
|
|
97
|
+
noValidate: { type: Boolean, attribute: 'novalidate' },
|
|
98
|
+
/**
|
|
99
|
+
* @ignore
|
|
100
|
+
* Perform validation immediately instead of waiting for the user to make changes.
|
|
101
|
+
*/
|
|
102
|
+
validateOnInit: { type: Boolean, attribute: 'validate-on-init' },
|
|
103
|
+
/**
|
|
104
|
+
* @ignore
|
|
105
|
+
*/
|
|
106
|
+
validationError: { type: String, attribute: false },
|
|
107
|
+
/**
|
|
108
|
+
* @ignore
|
|
109
|
+
*/
|
|
110
|
+
childErrors: { type: Object, attribute: false },
|
|
111
|
+
_errors: { type: Array, attribute: false }
|
|
112
|
+
};
|
|
115
113
|
|
|
116
114
|
constructor() {
|
|
117
115
|
super();
|