@brightspace-ui/core 3.267.1 → 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-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
|
@@ -34,168 +34,164 @@ export const moveActions = Object.freeze({
|
|
|
34
34
|
*/
|
|
35
35
|
class ButtonMove extends ThemeMixin(FocusMixin(LitElement)) {
|
|
36
36
|
|
|
37
|
-
static
|
|
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
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
};
|
|
90
|
-
}
|
|
37
|
+
static properties = {
|
|
38
|
+
/**
|
|
39
|
+
* @ignore
|
|
40
|
+
*/
|
|
41
|
+
// eslint-disable-next-line lit/no-native-attributes
|
|
42
|
+
autofocus: { type: Boolean, reflect: true },
|
|
43
|
+
/**
|
|
44
|
+
* ACCESSIBILITY: A description to be added to the button for accessibility when text on button does not provide enough context
|
|
45
|
+
* @type {string}
|
|
46
|
+
*/
|
|
47
|
+
description: { type: String },
|
|
48
|
+
/**
|
|
49
|
+
* Disables the down interaction
|
|
50
|
+
* @type {boolean}
|
|
51
|
+
*/
|
|
52
|
+
disabledDown: { type: Boolean, attribute: 'disabled-down', reflect: true },
|
|
53
|
+
/**
|
|
54
|
+
* Disables the end interaction
|
|
55
|
+
* @type {boolean}
|
|
56
|
+
*/
|
|
57
|
+
disabledEnd: { type: Boolean, attribute: 'disabled-end', reflect: true },
|
|
58
|
+
/**
|
|
59
|
+
* Disables the home interaction
|
|
60
|
+
* @type {boolean}
|
|
61
|
+
*/
|
|
62
|
+
disabledHome: { type: Boolean, attribute: 'disabled-home', reflect: true },
|
|
63
|
+
/**
|
|
64
|
+
* Disables the left interaction
|
|
65
|
+
* @type {boolean}
|
|
66
|
+
*/
|
|
67
|
+
disabledLeft: { type: Boolean, attribute: 'disabled-left', reflect: true },
|
|
68
|
+
/**
|
|
69
|
+
* Disables the right interaction
|
|
70
|
+
* @type {boolean}
|
|
71
|
+
*/
|
|
72
|
+
disabledRight: { type: Boolean, attribute: 'disabled-right', reflect: true },
|
|
73
|
+
/**
|
|
74
|
+
* Disables the up interaction
|
|
75
|
+
* @type {boolean}
|
|
76
|
+
*/
|
|
77
|
+
disabledUp: { type: Boolean, attribute: 'disabled-up', reflect: true },
|
|
78
|
+
/**
|
|
79
|
+
* ACCESSIBILITY: REQUIRED: Accessible text for the button
|
|
80
|
+
* @type {string}
|
|
81
|
+
*/
|
|
82
|
+
text: { type: String, reflect: true },
|
|
83
|
+
/**
|
|
84
|
+
* Renders the buttons in a side by side orientation
|
|
85
|
+
* @type {boolean}
|
|
86
|
+
*/
|
|
87
|
+
sideToSide: { type: Boolean, attribute: 'side-to-side', reflect: true }
|
|
88
|
+
};
|
|
91
89
|
|
|
92
|
-
static
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
:
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
:
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
:
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
button
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
.
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
}
|
|
90
|
+
static styles = [ buttonStyles,
|
|
91
|
+
css`
|
|
92
|
+
:host {
|
|
93
|
+
--d2l-button-move-background-color-focus: #ffffff;
|
|
94
|
+
--d2l-button-move-icon-background-color-hover: var(--d2l-color-mica);
|
|
95
|
+
--d2l-icon-fill-color: var(--d2l-color-tungsten);
|
|
96
|
+
display: inline-block;
|
|
97
|
+
line-height: 0;
|
|
98
|
+
}
|
|
99
|
+
:host([hidden]) {
|
|
100
|
+
display: none;
|
|
101
|
+
}
|
|
102
|
+
:host([theme="dark"]) {
|
|
103
|
+
--d2l-button-move-background-color-focus: #000000;
|
|
104
|
+
--d2l-button-move-icon-background-color-hover: rgba(51, 53, 54, 0.9); /* tungsten @70% @90% */
|
|
105
|
+
--d2l-icon-fill-color: var(--d2l-color-sylvite);
|
|
106
|
+
--d2l-focus-ring-color: var(--d2l-color-celestine-plus-1);
|
|
107
|
+
}
|
|
108
|
+
button {
|
|
109
|
+
background-color: transparent;
|
|
110
|
+
display: flex;
|
|
111
|
+
flex-direction: column;
|
|
112
|
+
gap: 2px;
|
|
113
|
+
margin: 0;
|
|
114
|
+
min-height: auto;
|
|
115
|
+
padding: 0;
|
|
116
|
+
position: relative;
|
|
117
|
+
width: 0.9rem;
|
|
118
|
+
}
|
|
119
|
+
d2l-icon {
|
|
120
|
+
border-radius: 0.1rem;
|
|
121
|
+
height: 0.85rem;
|
|
122
|
+
width: 0.9rem;
|
|
123
|
+
}
|
|
124
|
+
button:focus {
|
|
125
|
+
background-color: var(--d2l-button-move-background-color-focus);
|
|
126
|
+
}
|
|
127
|
+
button:hover > d2l-icon,
|
|
128
|
+
button:focus > d2l-icon {
|
|
129
|
+
background-color: var(--d2l-button-move-icon-background-color-hover);
|
|
130
|
+
}
|
|
131
|
+
.up-icon {
|
|
132
|
+
border-top-left-radius: 0.3rem;
|
|
133
|
+
border-top-right-radius: 0.3rem;
|
|
134
|
+
}
|
|
135
|
+
.down-icon {
|
|
136
|
+
border-bottom-left-radius: 0.3rem;
|
|
137
|
+
border-bottom-right-radius: 0.3rem;
|
|
138
|
+
}
|
|
139
|
+
.layer {
|
|
140
|
+
display: flex;
|
|
141
|
+
flex-direction: column;
|
|
142
|
+
height: calc(1.2rem * 2);
|
|
143
|
+
inset-inline-start: -0.2rem;
|
|
144
|
+
position: absolute;
|
|
145
|
+
top: -0.35rem;
|
|
146
|
+
width: 1.3rem;
|
|
147
|
+
}
|
|
148
|
+
.up-layer,
|
|
149
|
+
.down-layer {
|
|
150
|
+
height: 1.2rem;
|
|
151
|
+
position: relative;
|
|
152
|
+
width: 1.25rem;
|
|
153
|
+
}
|
|
157
154
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
155
|
+
/* Firefox includes a hidden border which messes up button dimensions */
|
|
156
|
+
button::-moz-focus-inner {
|
|
157
|
+
border: 0;
|
|
158
|
+
}
|
|
159
|
+
button[disabled]:hover > d2l-icon {
|
|
160
|
+
background-color: transparent;
|
|
161
|
+
}
|
|
162
|
+
:host([disabled-up]) .up-icon,
|
|
163
|
+
:host([disabled-down]) .down-icon {
|
|
164
|
+
opacity: 0.5;
|
|
165
|
+
}
|
|
166
|
+
:host([disabled-up]) .up-layer,
|
|
167
|
+
:host([disabled-down]) .down-layer {
|
|
168
|
+
cursor: default;
|
|
169
|
+
}
|
|
173
170
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
171
|
+
:host([side-to-side]) button {
|
|
172
|
+
align-items: center;
|
|
173
|
+
flex-direction: row;
|
|
174
|
+
height: 1.2rem;
|
|
175
|
+
width: calc(calc(1.2rem + 1px) * 2);
|
|
176
|
+
}
|
|
180
177
|
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
178
|
+
:host([side-to-side]) .layer {
|
|
179
|
+
flex-direction: row;
|
|
180
|
+
gap: 2px;
|
|
181
|
+
height: 1.2rem;
|
|
182
|
+
inset-inline-start: 0;
|
|
183
|
+
top: 0;
|
|
184
|
+
width: calc(calc(1.2rem + 1px) * 2);
|
|
185
|
+
}
|
|
189
186
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
}
|
|
187
|
+
:host([side-to-side]) d2l-icon {
|
|
188
|
+
height: 1.2rem;
|
|
189
|
+
/* Arrows need to be rotated in opposite direction for RTL */
|
|
190
|
+
transform: rotate(calc(-90deg * var(--d2l-length-factor)));
|
|
191
|
+
width: 1.2rem;
|
|
192
|
+
}
|
|
193
|
+
`
|
|
194
|
+
];
|
|
199
195
|
|
|
200
196
|
constructor() {
|
|
201
197
|
super();
|
|
@@ -8,27 +8,23 @@ import { PropertyRequiredMixin } from '../../mixins/property-required/property-r
|
|
|
8
8
|
*/
|
|
9
9
|
class ButtonSplitItem extends PropertyRequiredMixin(MenuItemMixin(LitElement)) {
|
|
10
10
|
|
|
11
|
-
static
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
};
|
|
19
|
-
}
|
|
11
|
+
static properties = {
|
|
12
|
+
/**
|
|
13
|
+
* REQUIRED: Key of the action
|
|
14
|
+
* @type {string}
|
|
15
|
+
*/
|
|
16
|
+
key: { type: String, required: true }
|
|
17
|
+
};
|
|
20
18
|
|
|
21
|
-
static
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
:
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
];
|
|
31
|
-
}
|
|
19
|
+
static styles = [ menuItemStyles,
|
|
20
|
+
css`
|
|
21
|
+
:host {
|
|
22
|
+
align-items: center;
|
|
23
|
+
display: flex;
|
|
24
|
+
padding: 0.75rem 1rem;
|
|
25
|
+
}
|
|
26
|
+
`
|
|
27
|
+
];
|
|
32
28
|
|
|
33
29
|
render() {
|
|
34
30
|
return html`
|
|
@@ -16,80 +16,76 @@ import { PropertyRequiredMixin } from '../../mixins/property-required/property-r
|
|
|
16
16
|
*/
|
|
17
17
|
class ButtonSplit extends FocusMixin(PropertyRequiredMixin(LocalizeCoreElement(LitElement))) {
|
|
18
18
|
|
|
19
|
-
static
|
|
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
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
margin-inline-end: 4px;
|
|
90
|
-
}
|
|
91
|
-
`;
|
|
92
|
-
}
|
|
19
|
+
static properties = {
|
|
20
|
+
/**
|
|
21
|
+
* ACCESSIBILITY: A description to be added to the main action button for accessibility when text does not provide enough context
|
|
22
|
+
* @type {string}
|
|
23
|
+
*/
|
|
24
|
+
description: { type: String },
|
|
25
|
+
/**
|
|
26
|
+
* Disables the main action and dropdown opener buttons
|
|
27
|
+
* @type {boolean}
|
|
28
|
+
*/
|
|
29
|
+
disabled: { type: Boolean, reflect: true },
|
|
30
|
+
/**
|
|
31
|
+
* Tooltip text when disabled
|
|
32
|
+
* @type {string}
|
|
33
|
+
*/
|
|
34
|
+
disabledTooltip: { type: String, attribute: 'disabled-tooltip' },
|
|
35
|
+
/**
|
|
36
|
+
* REQUIRED: Key of the main action
|
|
37
|
+
* @type {string}
|
|
38
|
+
*/
|
|
39
|
+
key: { type: String, required: true },
|
|
40
|
+
/**
|
|
41
|
+
* Styles the buttons as a primary buttons
|
|
42
|
+
* @type {boolean}
|
|
43
|
+
*/
|
|
44
|
+
primary: { type: Boolean, reflect: true },
|
|
45
|
+
/**
|
|
46
|
+
* ACCESSIBILITY: REQUIRED: Accessible text for the main action button
|
|
47
|
+
* @type {string}
|
|
48
|
+
*/
|
|
49
|
+
text: { type: String, reflect: true, required: true },
|
|
50
|
+
_focusVisibleElem: { state: true }
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
static styles = css`
|
|
54
|
+
:host {
|
|
55
|
+
display: inline-block;
|
|
56
|
+
}
|
|
57
|
+
:host([hidden]) {
|
|
58
|
+
display: none;
|
|
59
|
+
}
|
|
60
|
+
.container {
|
|
61
|
+
display: flex;
|
|
62
|
+
gap: 2px;
|
|
63
|
+
}
|
|
64
|
+
.main-action {
|
|
65
|
+
--d2l-button-start-end-radius: 0;
|
|
66
|
+
--d2l-button-end-end-radius: 0;
|
|
67
|
+
}
|
|
68
|
+
.d2l-dropdown-opener {
|
|
69
|
+
--d2l-button-start-start-radius: 0;
|
|
70
|
+
--d2l-button-end-start-radius: 0;
|
|
71
|
+
--d2l-button-padding-inline-end: 0.6rem;
|
|
72
|
+
--d2l-button-padding-inline-start: 0.6rem;
|
|
73
|
+
}
|
|
74
|
+
.d2l-dropdown-opener[primary] > d2l-icon {
|
|
75
|
+
color: #ffffff;
|
|
76
|
+
}
|
|
77
|
+
::slotted(:not(d2l-button-split-item)) {
|
|
78
|
+
display: none;
|
|
79
|
+
}
|
|
80
|
+
.main-action-focus-visible .d2l-dropdown-opener {
|
|
81
|
+
--d2l-button-padding-inline-start: calc(0.6rem - 4px);
|
|
82
|
+
margin-inline-start: 4px;
|
|
83
|
+
}
|
|
84
|
+
.menu-opener-focus-visible .main-action {
|
|
85
|
+
--d2l-button-padding-inline-end: calc(1.5rem - 4px);
|
|
86
|
+
margin-inline-end: 4px;
|
|
87
|
+
}
|
|
88
|
+
`;
|
|
93
89
|
|
|
94
90
|
constructor() {
|
|
95
91
|
super();
|
|
@@ -7,25 +7,23 @@ import { FocusMixin } from '../../mixins/focus/focus-mixin.js';
|
|
|
7
7
|
* A button component that copies to the clipboard, using the "subtle" button style.
|
|
8
8
|
*/
|
|
9
9
|
class ButtonSubtleCopy extends FocusMixin(ButtonCopyMixin(LitElement)) {
|
|
10
|
-
static
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
};
|
|
28
|
-
}
|
|
10
|
+
static properties = {
|
|
11
|
+
/**
|
|
12
|
+
* ACCESSIBILITY: A description to be added to the button for accessibility when text on button does not provide enough context
|
|
13
|
+
* @type {string}
|
|
14
|
+
*/
|
|
15
|
+
description: { type: String },
|
|
16
|
+
/**
|
|
17
|
+
* ACCESSIBILITY: REQUIRED: Text for the button
|
|
18
|
+
* @type {string}
|
|
19
|
+
*/
|
|
20
|
+
text: { type: String, reflect: true },
|
|
21
|
+
/**
|
|
22
|
+
* Whether to render the slimmer version of the button
|
|
23
|
+
* @type {boolean}
|
|
24
|
+
*/
|
|
25
|
+
slim: { type: Boolean, reflect: true },
|
|
26
|
+
};
|
|
29
27
|
|
|
30
28
|
static get focusElementSelector() {
|
|
31
29
|
return 'd2l-button-subtle';
|