@illinois-toolkit/ilw-header-megamenu 0.0.1 → 1.0.1
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/LICENSE +20 -20
- package/README.md +229 -261
- package/builder/ilw-header-megamenu.json +12 -12
- package/builder/versions/ilw-header-megamenu.1.0-alpha.json +70 -70
- package/builder/versions/ilw-header-megamenu.1.0.1.json +70 -0
- package/builder/versions/ilw-header-megamenu.1.0.json +70 -0
- package/builder/versions/ilw-header-megamenu.2.0-alpha.json +76 -0
- package/dist/MegaMenu.d.ts.map +1 -1
- package/dist/MegaMenuSection.d.ts +2 -8
- package/dist/MegaMenuSection.d.ts.map +1 -1
- package/dist/cdn/ilw-header-megamenu.css +1 -1
- package/dist/cdn/ilw-header-megamenu.js +317 -329
- package/dist/ilw-header-megamenu.css +1 -1
- package/dist/ilw-header-megamenu.js +111 -123
- package/package.json +49 -49
- package/src/MegaMenu.css +82 -79
- package/src/MegaMenu.styles.css +37 -36
- package/src/MegaMenu.ts +169 -144
- package/src/MegaMenuSection.css +231 -347
- package/src/MegaMenuSection.styles.css +242 -162
- package/src/MegaMenuSection.ts +220 -284
- package/src/ilw-header-megamenu.ts +1 -1
|
@@ -1,163 +1,243 @@
|
|
|
1
|
-
#items {
|
|
2
|
-
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
#items.expanded {
|
|
6
|
-
all: initial;
|
|
7
|
-
box-sizing: border-box;
|
|
8
|
-
flex-direction: column;
|
|
9
|
-
border: var(--ilw-header-megamenu--items--border);
|
|
10
|
-
box-shadow: var(--ilw-header-megamenu--items--box-shadow);
|
|
11
|
-
width: var(--ilw-header-megamenu--items--width);
|
|
12
|
-
max-width: 100vw + 39px;
|
|
13
|
-
position: var(--ilw-header-megamenu--items--position);
|
|
14
|
-
display: grid;
|
|
15
|
-
left: var(--ilw-header-megamenu--items--left);
|
|
16
|
-
top: var(--ilw-header-megamenu--items--top);
|
|
17
|
-
z-index: 100;
|
|
18
|
-
background: white;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.parent {
|
|
22
|
-
height: 100%;
|
|
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
|
-
|
|
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
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
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
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
1
|
+
#items {
|
|
2
|
+
display: none;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
#items.expanded {
|
|
6
|
+
all: initial;
|
|
7
|
+
box-sizing: border-box;
|
|
8
|
+
flex-direction: column;
|
|
9
|
+
border: var(--ilw-header-megamenu--items--border);
|
|
10
|
+
box-shadow: var(--ilw-header-megamenu--items--box-shadow);
|
|
11
|
+
width: var(--ilw-header-megamenu--items--width);
|
|
12
|
+
max-width: 100vw + 39px;
|
|
13
|
+
position: var(--ilw-header-megamenu--items--position);
|
|
14
|
+
display: grid;
|
|
15
|
+
left: var(--ilw-header-megamenu--items--left);
|
|
16
|
+
top: var(--ilw-header-megamenu--items--top);
|
|
17
|
+
z-index: 100;
|
|
18
|
+
background: white;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.parent {
|
|
22
|
+
height: 100%;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
button,
|
|
26
|
+
.link {
|
|
27
|
+
all: initial;
|
|
28
|
+
box-sizing: border-box;
|
|
29
|
+
display: block;
|
|
30
|
+
position: relative;
|
|
31
|
+
padding: var(--ilw-header-megamenu-section--anchor--padding);
|
|
32
|
+
font: var(--ilw-header-megamenu--font);
|
|
33
|
+
background: var(--ilw-header-megamenu--link-background);
|
|
34
|
+
color: var(--ilw-header-megamenu--link-color);
|
|
35
|
+
fill: var(--ilw-header-megamenu--link-color);
|
|
36
|
+
border-width: 0 0 3px 0;
|
|
37
|
+
border-style: solid;
|
|
38
|
+
border-color: transparent;
|
|
39
|
+
outline: 0;
|
|
40
|
+
cursor: pointer;
|
|
41
|
+
height: 100%;
|
|
42
|
+
width: 100%;
|
|
43
|
+
border-bottom: var(--ilw-header-megamenu--link-border-bottom-highlight);
|
|
44
|
+
border-left: var(--ilw-header-megamenu--link-border-left-highlight);
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
svg {
|
|
48
|
+
padding: 2px;
|
|
49
|
+
transform: var(--ilw-header-megamenu-section--transform);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
&.current {
|
|
53
|
+
border-color: var(--il-blue);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&:hover {
|
|
57
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
58
|
+
border-bottom: var(--ilw-header-megamenu--link-border-bottom-highlight--hover);
|
|
59
|
+
color: var(--ilw-header-megamenu--link-color--hover);
|
|
60
|
+
fill: var(--ilw-header-megamenu--link-color--hover);
|
|
61
|
+
text-decoration: underline;
|
|
62
|
+
|
|
63
|
+
svg {
|
|
64
|
+
outline: 2px dotted var(--il-altgeld);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
&:focus {
|
|
69
|
+
background: var(--ilw-header-megamenu--link-background--focus);
|
|
70
|
+
border-bottom: var(--ilw-header-megamenu--link-border-bottom-highlight--focus);
|
|
71
|
+
border-left: var(--ilw-header-megamenu--link-border-left-highlight--focus);
|
|
72
|
+
color: var(--ilw-header-megamenu--link-color--focus);
|
|
73
|
+
fill: var(--ilw-header-megamenu--link-color--focus);
|
|
74
|
+
outline: 0;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&:focus:hover {
|
|
78
|
+
svg {
|
|
79
|
+
outline: 2px dotted var(--il-blue);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
button[aria-expanded="true"] {
|
|
85
|
+
text-decoration: underline;
|
|
86
|
+
color: var(--ilw-header-megamenu--link-color--hover);
|
|
87
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
88
|
+
|
|
89
|
+
&:focus {
|
|
90
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
91
|
+
border-bottom: var(--ilw-header-megamenu--link-border-bottom-highlight--hover);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
svg {
|
|
95
|
+
fill: var(--ilw-header-megamenu--link-color--hover);
|
|
96
|
+
transform: var(--ilw-header-megamenu-section--transform--selected);
|
|
97
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
98
|
+
|
|
99
|
+
&:focus {
|
|
100
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
101
|
+
color: var(--il-blue);
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.header {
|
|
107
|
+
position: relative;
|
|
108
|
+
display: grid;
|
|
109
|
+
grid-template-columns: var(--ilw-header-megamenu-section--grid-template-columns--header);
|
|
110
|
+
grid-template-areas: "label icon";
|
|
111
|
+
grid-gap: 4px;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.header-link.current button {
|
|
115
|
+
border-color: var(--il-blue);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.header-link {
|
|
119
|
+
position: relative;
|
|
120
|
+
display: grid;
|
|
121
|
+
grid-template-columns: var(--ilw-header-megamenu--grid-template-columns);
|
|
122
|
+
grid-template-areas: "label icon";
|
|
123
|
+
align-items: center;
|
|
124
|
+
height: 100%;
|
|
125
|
+
|
|
126
|
+
&.highlighted {
|
|
127
|
+
background: var(--ilw-header-megamenu--link-background--hover);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
& .link {
|
|
131
|
+
padding: 6px 0px 6px 20px;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
& button {
|
|
135
|
+
padding: 6px 20px 6px 6px;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.label,
|
|
140
|
+
.link {
|
|
141
|
+
box-sizing: border-box;
|
|
142
|
+
display: block;
|
|
143
|
+
position: relative;
|
|
144
|
+
grid-area: label;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.icon,
|
|
148
|
+
.header-link button {
|
|
149
|
+
align-self: center;
|
|
150
|
+
align-items: center;
|
|
151
|
+
justify-content: center;
|
|
152
|
+
grid-area: icon;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.icon {
|
|
156
|
+
display: flex;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.arrow {
|
|
160
|
+
display: block;
|
|
161
|
+
height: 14px;
|
|
162
|
+
width: 14px;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.submenu.parent button:hover .label ::slotted(span[slot="label"]),
|
|
166
|
+
.submenu.parent button:focus .label ::slotted(span[slot="label"]) {
|
|
167
|
+
text-decoration: underline;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.menu.parent .header-link.highlighted button,
|
|
171
|
+
.menu.parent .header-link.highlighted ::slotted(a[slot="link"]) {
|
|
172
|
+
border-bottom: var(--ilw-header-megamenu--link-border-bottom-highlight--focus) !important;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.submenu.parent button.arrow-only:hover,
|
|
176
|
+
.submenu.parent button.arrow-only:focus {
|
|
177
|
+
border-left: 4px solid transparent !important;
|
|
178
|
+
color: var(--il-blue);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.menu.parent .compact button.arrow-only:hover,
|
|
182
|
+
.menu.parent .compact button.arrow-only:focus {
|
|
183
|
+
border-left: 4px solid var(--il-blue) !important;
|
|
184
|
+
color: var(--il-blue);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
/* make single ul list */
|
|
189
|
+
|
|
190
|
+
:host(.solo-list) ::slotted(ul) {
|
|
191
|
+
display: grid;
|
|
192
|
+
grid-template-columns: repeat(4, minmax(0, 320px));
|
|
193
|
+
grid-template-rows: repeat(5, 34px);
|
|
194
|
+
grid-auto-flow: column;
|
|
195
|
+
max-width: 100vw;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
/* make distinct lists */
|
|
200
|
+
div.list-wrapper {
|
|
201
|
+
display: grid;
|
|
202
|
+
grid-template-columns: repeat(4, minmax(0, 320px));
|
|
203
|
+
max-width: 100vw;
|
|
204
|
+
overflow: hidden;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
:host-context(ilw-header-megamenu[compact]) .list-wrapper {
|
|
208
|
+
all: unset;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
::slotted(ul:last-of-type) {
|
|
212
|
+
border: none !important;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
::slotted([slot="action-right"]) {
|
|
216
|
+
grid-column: 4;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
::slotted([slot="action-right"].span-2) {
|
|
220
|
+
grid-column: 3 / span 2;
|
|
221
|
+
justify-self: auto;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
::slotted([slot="action-right"].span-3) {
|
|
225
|
+
grid-column: 2 / span 3;
|
|
226
|
+
justify-self: auto;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
::slotted([slot="action-left"]) {
|
|
230
|
+
grid-column: 1;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
::slotted([slot="action-left"].span-2) {
|
|
234
|
+
grid-column: 1 / span 2;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
::slotted([slot="action-left"].span-3) {
|
|
238
|
+
grid-column: 1 / span 3;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
.hidden {
|
|
242
|
+
display: none;
|
|
163
243
|
}
|