@brightspace-ui/labs 2.55.1 → 2.56.2
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/demo/components/ou-filter/ouFilterDemoPage.js +14 -16
- package/package.json +4 -3
- package/src/components/accessibility-disability-simulator/accessibility-disability-simulator.js +70 -74
- package/src/components/accordion/accordion-collapse.js +161 -164
- package/src/components/accordion/accordion.js +14 -17
- package/src/components/attribute-picker/attribute-picker-item.js +63 -66
- package/src/components/attribute-picker/attribute-picker.js +118 -121
- package/src/components/card-overlay/card-overlay.js +53 -55
- package/src/components/checkbox-drawer/checkbox-drawer.js +32 -36
- package/src/components/community/community-base.js +3 -5
- package/src/components/community/community-button.js +3 -5
- package/src/components/community/community-link.js +4 -6
- package/src/components/file-uploader/file-uploader.js +148 -151
- package/src/components/grade-result/grade-result-icon-button.js +5 -6
- package/src/components/grade-result/grade-result-letter-score.js +18 -22
- package/src/components/grade-result/grade-result-numeric-score.js +25 -28
- package/src/components/grade-result/grade-result-presentational.js +133 -136
- package/src/components/grade-result/grade-result-student-grade-preview.js +38 -42
- package/src/components/media-player/media-player-audio-bars.js +28 -31
- package/src/components/media-player/media-player.js +471 -475
- package/src/components/media-player/slider-bar.js +119 -122
- package/src/components/navigation/navigation-band.js +69 -71
- package/src/components/navigation/navigation-button-icon.js +51 -55
- package/src/components/navigation/navigation-dropdown-button-custom.js +13 -17
- package/src/components/navigation/navigation-dropdown-button-icon.js +21 -25
- package/src/components/navigation/navigation-immersive.js +128 -132
- package/src/components/navigation/navigation-iterator.js +24 -24
- package/src/components/navigation/navigation-link-back.js +13 -17
- package/src/components/navigation/navigation-link-icon.js +36 -40
- package/src/components/navigation/navigation-link-image.js +31 -35
- package/src/components/navigation/navigation-link.js +34 -38
- package/src/components/navigation/navigation-main-footer.js +7 -9
- package/src/components/navigation/navigation-main-header.js +34 -36
- package/src/components/navigation/navigation-notification-icon.js +30 -34
- package/src/components/navigation/navigation.js +19 -23
- package/src/components/opt-in-flyout/flyout-impl.js +138 -146
- package/src/components/opt-in-flyout/opt-in-flyout.js +14 -18
- package/src/components/opt-in-flyout/opt-out-dialog.js +63 -67
- package/src/components/opt-in-flyout/opt-out-flyout.js +15 -19
- package/src/components/opt-in-flyout/opt-out-reason-selector.js +38 -45
- package/src/components/opt-in-flyout/opt-out-reason.js +9 -13
- package/src/components/ou-filter/ou-filter.js +14 -18
- package/src/components/ou-filter/tree-filter.js +22 -26
- package/src/components/ou-filter/tree-selector-node.js +62 -66
- package/src/components/ou-filter/tree-selector.js +55 -62
- package/src/components/pagination/pager-numeric.js +35 -39
- package/src/components/view-toggle/view-toggle.js +79 -81
- package/src/components/wizard/single-step-header.js +106 -110
- package/src/components/wizard/wizard-step.js +65 -68
- package/src/components/wizard/wizard.js +30 -33
- package/src/utilities/reactive-store/README.md +10 -15
|
@@ -6,141 +6,138 @@ import { RtlMixin } from '@brightspace-ui/core/mixins/rtl-mixin.js';
|
|
|
6
6
|
|
|
7
7
|
class SliderBar extends PropertyRequiredMixin(LocalizeLabsElement(RtlMixin(LitElement))) {
|
|
8
8
|
|
|
9
|
-
static
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
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
|
-
--d2l-calculated-progress-background-color: var(--d2l-progress-background-color, var(--d2l-color-corundum-65-opacity));
|
|
45
|
-
display: block;
|
|
46
|
-
}
|
|
9
|
+
static properties = {
|
|
10
|
+
value: { type: Number },
|
|
11
|
+
immediateValue: { type: Number, reflect: true },
|
|
12
|
+
hoverValue: { type: Number, reflect: true },
|
|
13
|
+
dragging: { type: Boolean, reflect: true },
|
|
14
|
+
hovering: { type: Boolean, reflect: true },
|
|
15
|
+
vertical: { type: Boolean },
|
|
16
|
+
fullWidth: { type: Boolean },
|
|
17
|
+
min: { type: Number },
|
|
18
|
+
max: { type: Number },
|
|
19
|
+
label: { type: String, required: true },
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
static styles = css`
|
|
23
|
+
:host {
|
|
24
|
+
--d2l-color-corundum-65-opacity: rgba(177, 185, 190, 0.65);
|
|
25
|
+
--d2l-color-galena-88-opacity: rgba(110, 116, 119, 0.88);
|
|
26
|
+
--d2l-calculated-seek-bar-height: var(--d2l-seek-bar-height, 6px);
|
|
27
|
+
--d2l-calculated-knob-size: var(--d2l-knob-size, 32px);
|
|
28
|
+
--d2l-half-knob-size: calc(var(--d2l-calculated-knob-size)/2);
|
|
29
|
+
--d2l-half-knob-size-overflow: calc((var(--d2l-calculated-knob-size) - var(--d2l-calculated-seek-bar-height)) / 2 - 1px);
|
|
30
|
+
--d2l-calculated-inner-knob-margin: var(--d2l-inner-knob-margin, 8px);
|
|
31
|
+
--d2l-calculated-knob-box-shadow: var(--d2l-knob-box-shadow, 0 2px 4px 0 rgba(0, 0, 0, 0.52));
|
|
32
|
+
--d2l-calculated-outer-knob-color: var(--d2l-outer-knob-color, var(--d2l-color-regolith));
|
|
33
|
+
--d2l-calculated-outer-knob-border-color: var(--d2l-outer-knob-border-color, var(--d2l-color-pressicus));
|
|
34
|
+
--d2l-inner-knob-color: var(--d2l-inner-knob-color, var(--d2l-color-celestine-plus-1));
|
|
35
|
+
--d2l-calculated-knob-focus-color: var(--d2l-knob-focus-color, var(--d2l-color-celestine));
|
|
36
|
+
--d2l-calculated-knob-focus-size: var(--d2l-knob-focus-size, 2px);
|
|
37
|
+
--d2l-calculated-progress-border-color: var(--d2l-progress-border-color, var(--d2l-color-pressicus));
|
|
38
|
+
--d2l-calculated-progress-border-radius: var(--d2l-progress-border-radius, 6px);
|
|
39
|
+
--d2l-calculated-progress-shadow-color: var(--d2l-progress-shadow-color, var(--d2l-color-galena-88-opacity));
|
|
40
|
+
--d2l-calculated-progress-active-color: var(--d2l-progress-active-color, var(--d2l-color-celestine-plus-1));
|
|
41
|
+
--d2l-calculated-progress-background-color: var(--d2l-progress-background-color, var(--d2l-color-corundum-65-opacity));
|
|
42
|
+
display: block;
|
|
43
|
+
}
|
|
47
44
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
45
|
+
:host(:focus-within) {
|
|
46
|
+
outline: none;
|
|
47
|
+
}
|
|
51
48
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
49
|
+
:host(:focus-within) .slider-knob::after {
|
|
50
|
+
border-radius: 50%;
|
|
51
|
+
bottom: 0;
|
|
52
|
+
box-shadow: 0 0 0 var(--d2l-calculated-knob-focus-size) var(--d2l-calculated-knob-focus-color);
|
|
53
|
+
content: "";
|
|
54
|
+
left: 0;
|
|
55
|
+
position: absolute;
|
|
56
|
+
right: 0;
|
|
57
|
+
top: 0;
|
|
58
|
+
}
|
|
62
59
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
60
|
+
:host([solid]) .slider-knob-inner {
|
|
61
|
+
display: none;
|
|
62
|
+
}
|
|
66
63
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
64
|
+
#sliderContainer {
|
|
65
|
+
height: var(--d2l-calculated-knob-size);
|
|
66
|
+
margin-left: var(--d2l-half-knob-size);
|
|
67
|
+
margin-right: var(--d2l-half-knob-size);
|
|
68
|
+
position: relative;
|
|
69
|
+
}
|
|
73
70
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
71
|
+
#knobContainer {
|
|
72
|
+
bottom: 0;
|
|
73
|
+
left: 0;
|
|
74
|
+
pointer-events: none;
|
|
75
|
+
position: absolute;
|
|
76
|
+
right: 0;
|
|
77
|
+
top: 0;
|
|
78
|
+
}
|
|
82
79
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
80
|
+
:host([fullWidth]) #sliderContainer {
|
|
81
|
+
margin-left: 0;
|
|
82
|
+
margin-right: 0;
|
|
83
|
+
}
|
|
87
84
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
85
|
+
:host([fullWidth]) #knobContainer {
|
|
86
|
+
left: var(--d2l-half-knob-size);
|
|
87
|
+
right: var(--d2l-half-knob-size);
|
|
88
|
+
}
|
|
92
89
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
90
|
+
.bar-container {
|
|
91
|
+
cursor: pointer;
|
|
92
|
+
overflow: hidden;
|
|
93
|
+
}
|
|
97
94
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
95
|
+
#sliderBar {
|
|
96
|
+
padding: var(--d2l-half-knob-size-overflow) 0;
|
|
97
|
+
width: 100%;
|
|
98
|
+
}
|
|
102
99
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
100
|
+
#progressContainer {
|
|
101
|
+
--d2l-progress-container-color: var(--d2l-calculated-progress-background-color);
|
|
102
|
+
background: var(--d2l-progress-container-color, var(--d2l-color-gypsum));
|
|
103
|
+
border-radius: var(--d2l-calculated-progress-border-radius);
|
|
104
|
+
box-shadow: inset 0 1px 0 0 var(--d2l-calculated-progress-shadow-color);
|
|
105
|
+
height: var(--d2l-progress-height, 6px);
|
|
106
|
+
position: relative;
|
|
107
|
+
}
|
|
111
108
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
109
|
+
#primaryProgress {
|
|
110
|
+
--d2l-progress-active-color: var(--d2l-calculated-progress-active-color);
|
|
111
|
+
background: var(--d2l-progress-active-color, var(--d2l-color-celestine));
|
|
112
|
+
border-radius: var(--d2l-calculated-progress-border-radius);
|
|
113
|
+
box-shadow: inset 0 1px 0 0 rgba(0, 0, 0, 0.07);
|
|
114
|
+
height: 100%;
|
|
115
|
+
}
|
|
119
116
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
117
|
+
.slider-knob {
|
|
118
|
+
background-color: var(--d2l-calculated-outer-knob-color);
|
|
119
|
+
border-radius: 50%;
|
|
120
|
+
box-shadow: var(--d2l-calculated-knob-box-shadow);
|
|
121
|
+
cursor: pointer;
|
|
122
|
+
height: calc((((var(--d2l-calculated-knob-size) / 2) - var(--d2l-calculated-seek-bar-height) / 2) * 2) + var(--d2l-calculated-seek-bar-height) - 2px);
|
|
123
|
+
left: 0;
|
|
124
|
+
margin-left: calc(-1 * ((var(--d2l-calculated-knob-size) / 2) - var(--d2l-calculated-seek-bar-height) / 2) - var(--d2l-calculated-seek-bar-height) / 2);
|
|
125
|
+
position: absolute;
|
|
126
|
+
top: 0;
|
|
127
|
+
width: calc((((var(--d2l-calculated-knob-size) / 2) - var(--d2l-calculated-seek-bar-height) / 2) * 2) + var(--d2l-calculated-seek-bar-height) - 2px);
|
|
128
|
+
z-index: 1;
|
|
129
|
+
}
|
|
133
130
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
131
|
+
.slider-knob-inner {
|
|
132
|
+
background-color: var(--d2l-inner-knob-color);
|
|
133
|
+
border-radius: 50%;
|
|
134
|
+
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.07);
|
|
135
|
+
box-sizing: border-box;
|
|
136
|
+
height: calc(100% - var(--d2l-calculated-inner-knob-margin) *2);
|
|
137
|
+
margin: var(--d2l-calculated-inner-knob-margin);
|
|
138
|
+
width: calc(100% - var(--d2l-calculated-inner-knob-margin) *2);
|
|
139
|
+
}
|
|
140
|
+
`;
|
|
144
141
|
|
|
145
142
|
constructor() {
|
|
146
143
|
super();
|
|
@@ -9,84 +9,82 @@ function useCustomScroll() {
|
|
|
9
9
|
|
|
10
10
|
class NavigationBand extends LitElement {
|
|
11
11
|
|
|
12
|
-
static
|
|
13
|
-
|
|
14
|
-
:
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
:
|
|
21
|
-
|
|
22
|
-
}
|
|
12
|
+
static styles = [centererStyles, guttersStyles, css`
|
|
13
|
+
:host {
|
|
14
|
+
background: linear-gradient(180deg, var(--d2l-branding-primary-color, var(--d2l-color-celestine)) 1.5rem, #ffffff 0%);
|
|
15
|
+
display: block;
|
|
16
|
+
min-height: 4px;
|
|
17
|
+
position: relative; /* Needed for Firefox */
|
|
18
|
+
}
|
|
19
|
+
:host([hidden]) {
|
|
20
|
+
display: none;
|
|
21
|
+
}
|
|
23
22
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
23
|
+
.d2l-labs-navigation-scroll {
|
|
24
|
+
overflow-x: auto;
|
|
25
|
+
overflow-y: hidden;
|
|
26
|
+
scroll-behavior: smooth;
|
|
27
|
+
}
|
|
29
28
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
29
|
+
.d2l-labs-navigation-scroll[data-custom-scroll] {
|
|
30
|
+
/* Firefox Styles */
|
|
31
|
+
scrollbar-color: var(--d2l-color-galena) var(--d2l-color-sylvite);
|
|
32
|
+
scrollbar-width: thin;
|
|
33
|
+
}
|
|
34
|
+
/* Webkit Styles */
|
|
35
|
+
.d2l-labs-navigation-scroll[data-custom-scroll]::-webkit-scrollbar {
|
|
36
|
+
background-color: var(--d2l-color-sylvite);
|
|
37
|
+
border-radius: 8px;
|
|
38
|
+
height: 9px;
|
|
39
|
+
}
|
|
40
|
+
.d2l-labs-navigation-scroll[data-custom-scroll]::-webkit-scrollbar-thumb {
|
|
41
|
+
background-color: var(--d2l-color-galena);
|
|
42
|
+
border-bottom: 1px solid var(--d2l-color-sylvite);
|
|
43
|
+
border-radius: 8px;
|
|
44
|
+
border-top: 1px solid var(--d2l-color-sylvite);
|
|
45
|
+
}
|
|
46
|
+
/* Faded edges styles */
|
|
47
|
+
.d2l-labs-navigation-scroll-before,
|
|
48
|
+
.d2l-labs-navigation-scroll-after {
|
|
49
|
+
height: 100%;
|
|
50
|
+
max-height: 1.5rem; /* should match linear-background height */
|
|
51
|
+
pointer-events: none;
|
|
52
|
+
position: absolute;
|
|
53
|
+
top: 0;
|
|
54
|
+
width: 2.439%; /* should match gutter width */
|
|
55
|
+
z-index: 2;
|
|
56
|
+
}
|
|
57
|
+
.d2l-labs-navigation-scroll-before {
|
|
58
|
+
background: linear-gradient(to right, var(--d2l-branding-primary-color, var(--d2l-color-celestine)), transparent);
|
|
59
|
+
left: 0;
|
|
60
|
+
}
|
|
61
|
+
.d2l-labs-navigation-scroll-after {
|
|
62
|
+
background: linear-gradient(to left, var(--d2l-branding-primary-color, var(--d2l-color-celestine)), transparent);
|
|
63
|
+
right: 0;
|
|
64
|
+
}
|
|
65
|
+
/* Styles to ensure the right padding is respected when scrolling */
|
|
66
|
+
.d2l-labs-navigation-centerer {
|
|
67
|
+
line-height: 0;
|
|
68
|
+
position: relative;
|
|
69
|
+
}
|
|
70
|
+
.d2l-labs-navigation-gutters {
|
|
71
|
+
display: inline-block;
|
|
72
|
+
position: unset;
|
|
73
|
+
vertical-align: top;
|
|
74
|
+
}
|
|
75
|
+
@media (max-width: 615px) {
|
|
48
76
|
.d2l-labs-navigation-scroll-before,
|
|
49
77
|
.d2l-labs-navigation-scroll-after {
|
|
50
|
-
|
|
51
|
-
max-height: 1.5rem; /* should match linear-background height */
|
|
52
|
-
pointer-events: none;
|
|
53
|
-
position: absolute;
|
|
54
|
-
top: 0;
|
|
55
|
-
width: 2.439%; /* should match gutter width */
|
|
56
|
-
z-index: 2;
|
|
57
|
-
}
|
|
58
|
-
.d2l-labs-navigation-scroll-before {
|
|
59
|
-
background: linear-gradient(to right, var(--d2l-branding-primary-color, var(--d2l-color-celestine)), transparent);
|
|
60
|
-
left: 0;
|
|
78
|
+
width: 15px;
|
|
61
79
|
}
|
|
80
|
+
}
|
|
81
|
+
@media (min-width: 1230px) {
|
|
82
|
+
.d2l-labs-navigation-scroll-before,
|
|
62
83
|
.d2l-labs-navigation-scroll-after {
|
|
63
|
-
|
|
64
|
-
right: 0;
|
|
84
|
+
width: 30px;
|
|
65
85
|
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
line-height: 0;
|
|
69
|
-
position: relative;
|
|
70
|
-
}
|
|
71
|
-
.d2l-labs-navigation-gutters {
|
|
72
|
-
display: inline-block;
|
|
73
|
-
position: unset;
|
|
74
|
-
vertical-align: top;
|
|
75
|
-
}
|
|
76
|
-
@media (max-width: 615px) {
|
|
77
|
-
.d2l-labs-navigation-scroll-before,
|
|
78
|
-
.d2l-labs-navigation-scroll-after {
|
|
79
|
-
width: 15px;
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
@media (min-width: 1230px) {
|
|
83
|
-
.d2l-labs-navigation-scroll-before,
|
|
84
|
-
.d2l-labs-navigation-scroll-after {
|
|
85
|
-
width: 30px;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
`];
|
|
89
|
-
}
|
|
86
|
+
}
|
|
87
|
+
`];
|
|
90
88
|
|
|
91
89
|
constructor() {
|
|
92
90
|
super();
|
|
@@ -12,62 +12,58 @@ import { ifDefined } from 'lit/directives/if-defined.js';
|
|
|
12
12
|
*/
|
|
13
13
|
class NavigationButtonIcon extends FocusMixin(LitElement) {
|
|
14
14
|
|
|
15
|
-
static
|
|
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
|
-
}
|
|
15
|
+
static properties = {
|
|
16
|
+
/**
|
|
17
|
+
* Disables the button
|
|
18
|
+
* @type {boolean}
|
|
19
|
+
*/
|
|
20
|
+
disabled: { reflect: true, type: Boolean },
|
|
21
|
+
/**
|
|
22
|
+
* REQUIRED: Preset icon key (e.g. "tier1:gear")
|
|
23
|
+
* @type {string}
|
|
24
|
+
*/
|
|
25
|
+
icon: { type: String },
|
|
26
|
+
/**
|
|
27
|
+
* Position of the icon.
|
|
28
|
+
* @type {'start'|'end'}
|
|
29
|
+
*/
|
|
30
|
+
iconPosition: { attribute: 'icon-position', type: String },
|
|
31
|
+
/**
|
|
32
|
+
* Visually hides the highlight border when hovered/focused
|
|
33
|
+
* @type {boolean}
|
|
34
|
+
*/
|
|
35
|
+
noHighlightBorder: { attribute: 'no-highlight-border', type: Boolean },
|
|
36
|
+
/**
|
|
37
|
+
* REQUIRED: Text for the button
|
|
38
|
+
* @type {string}
|
|
39
|
+
*/
|
|
40
|
+
text: { type: String },
|
|
41
|
+
/**
|
|
42
|
+
* Visually hides the text but still accessible
|
|
43
|
+
* @type {boolean}
|
|
44
|
+
*/
|
|
45
|
+
textHidden: { attribute: 'text-hidden', type: Boolean },
|
|
46
|
+
/**
|
|
47
|
+
* Offset of the tooltip
|
|
48
|
+
* @type {Number}
|
|
49
|
+
*/
|
|
50
|
+
tooltipOffset: { attribute: 'tooltip-offset', type: Number },
|
|
51
|
+
/**
|
|
52
|
+
* Position of the tooltip
|
|
53
|
+
* @type {'top'|'bottom'|'left'|'right'}
|
|
54
|
+
*/
|
|
55
|
+
tooltipPosition: { attribute: 'tooltip-position', type: String }
|
|
56
|
+
};
|
|
59
57
|
|
|
60
|
-
static
|
|
61
|
-
|
|
62
|
-
:
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
:
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
`];
|
|
70
|
-
}
|
|
58
|
+
static styles = [highlightBorderStyles, highlightButtonStyles, css`
|
|
59
|
+
:host {
|
|
60
|
+
display: inline-block;
|
|
61
|
+
height: 100%;
|
|
62
|
+
}
|
|
63
|
+
:host([hidden]) {
|
|
64
|
+
display: none;
|
|
65
|
+
}
|
|
66
|
+
`];
|
|
71
67
|
|
|
72
68
|
constructor() {
|
|
73
69
|
super();
|
|
@@ -5,24 +5,20 @@ import { ifDefined } from 'lit/directives/if-defined.js';
|
|
|
5
5
|
|
|
6
6
|
class NavigationDropdownButtonCustom extends DropdownOpenerMixin(LitElement) {
|
|
7
7
|
|
|
8
|
-
static
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
};
|
|
12
|
-
}
|
|
8
|
+
static properties = {
|
|
9
|
+
openerLabel: { type: String, attribute: 'opener-label' }
|
|
10
|
+
};
|
|
13
11
|
|
|
14
|
-
static
|
|
15
|
-
|
|
16
|
-
:
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
:
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
`];
|
|
25
|
-
}
|
|
12
|
+
static styles = [highlightBorderStyles, highlightButtonStyles, css`
|
|
13
|
+
:host {
|
|
14
|
+
display: inline-block;
|
|
15
|
+
height: 100%;
|
|
16
|
+
position: relative;
|
|
17
|
+
}
|
|
18
|
+
:host([hidden]) {
|
|
19
|
+
display: none;
|
|
20
|
+
}
|
|
21
|
+
`];
|
|
26
22
|
|
|
27
23
|
render() {
|
|
28
24
|
return html`
|
|
@@ -10,32 +10,28 @@ import { offscreenStyles } from '@brightspace-ui/core/components/offscreen/offsc
|
|
|
10
10
|
|
|
11
11
|
class NavigationDropdownButtonIcon extends DropdownOpenerMixin(LitElement) {
|
|
12
12
|
|
|
13
|
-
static
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
};
|
|
21
|
-
}
|
|
13
|
+
static properties = {
|
|
14
|
+
icon: { type: String },
|
|
15
|
+
hasNotification: { attribute: 'has-notification', reflect: true, type: Boolean },
|
|
16
|
+
text: { type: String },
|
|
17
|
+
notificationText: { attribute: 'notification-text', type: String },
|
|
18
|
+
tooltipOffset: { attribute: 'tooltip-offset', type: Number }
|
|
19
|
+
};
|
|
22
20
|
|
|
23
|
-
static
|
|
24
|
-
|
|
25
|
-
:
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
:
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
`];
|
|
38
|
-
}
|
|
21
|
+
static styles = [highlightBorderStyles, highlightButtonStyles, offscreenStyles, css`
|
|
22
|
+
:host {
|
|
23
|
+
display: inline-block;
|
|
24
|
+
height: 100%;
|
|
25
|
+
position: relative;
|
|
26
|
+
}
|
|
27
|
+
:host([hidden]) {
|
|
28
|
+
display: none;
|
|
29
|
+
}
|
|
30
|
+
.icon-container {
|
|
31
|
+
display: inline-block;
|
|
32
|
+
position: relative;
|
|
33
|
+
}
|
|
34
|
+
`];
|
|
39
35
|
|
|
40
36
|
constructor() {
|
|
41
37
|
super();
|