@launchpad-ui/menu 0.6.5-alpha.1 → 0.6.6-alpha.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.
- package/package.json +6 -7
- package/dist/Menu.d.ts +0 -43
- package/dist/Menu.d.ts.map +0 -1
- package/dist/MenuBase.d.ts +0 -11
- package/dist/MenuBase.d.ts.map +0 -1
- package/dist/MenuDivider.d.ts +0 -11
- package/dist/MenuDivider.d.ts.map +0 -1
- package/dist/MenuItem.d.ts +0 -48
- package/dist/MenuItem.d.ts.map +0 -1
- package/dist/MenuItemList.d.ts +0 -7
- package/dist/MenuItemList.d.ts.map +0 -1
- package/dist/MenuSearch.d.ts +0 -13
- package/dist/MenuSearch.d.ts.map +0 -1
- package/dist/index.d.ts +0 -13
- package/dist/index.d.ts.map +0 -1
- package/dist/index.es.js +0 -452
- package/dist/index.es.js.map +0 -1
- package/dist/index.js +0 -452
- package/dist/index.js.map +0 -1
- package/dist/style.css +0 -222
- package/dist/utils.d.ts +0 -7
- package/dist/utils.d.ts.map +0 -1
package/dist/style.css
DELETED
@@ -1,222 +0,0 @@
|
|
1
|
-
.Menu-item {
|
2
|
-
display: block;
|
3
|
-
position: relative;
|
4
|
-
color: var(--color-text);
|
5
|
-
background: var(--color-background);
|
6
|
-
text-decoration: none;
|
7
|
-
cursor: pointer;
|
8
|
-
outline: none;
|
9
|
-
padding: 0.6rem 2.5rem;
|
10
|
-
text-align: left;
|
11
|
-
font-family: inherit;
|
12
|
-
font-size: 1.3rem;
|
13
|
-
overflow: hidden;
|
14
|
-
text-overflow: ellipsis;
|
15
|
-
white-space: nowrap;
|
16
|
-
-webkit-user-select: none;
|
17
|
-
-moz-user-select: none;
|
18
|
-
user-select: none;
|
19
|
-
line-height: inherit;
|
20
|
-
border-width: 0;
|
21
|
-
width: 100%;
|
22
|
-
}
|
23
|
-
|
24
|
-
.Menu-item:first-child {
|
25
|
-
border-top-left-radius: var(--border-radius);
|
26
|
-
border-top-right-radius: var(--border-radius);
|
27
|
-
}
|
28
|
-
|
29
|
-
.Menu-item:last-child {
|
30
|
-
border-bottom-left-radius: var(--border-radius);
|
31
|
-
border-bottom-right-radius: var(--border-radius);
|
32
|
-
}
|
33
|
-
|
34
|
-
.Menu-item-list {
|
35
|
-
min-width: 12rem;
|
36
|
-
overflow: auto;
|
37
|
-
max-height: 55vh;
|
38
|
-
}
|
39
|
-
|
40
|
-
.Menu-item-list > .Menu-item:last-child {
|
41
|
-
border-bottom-left-radius: var(--border-radius);
|
42
|
-
border-bottom-right-radius: var(--border-radius);
|
43
|
-
}
|
44
|
-
|
45
|
-
.Menu .Menu-item:not([disabled]):not([aria-disabled]):active {
|
46
|
-
text-decoration: none;
|
47
|
-
box-shadow: none;
|
48
|
-
background-color: var(--color-blue-200);
|
49
|
-
color: var(--color-blue-600);
|
50
|
-
}
|
51
|
-
|
52
|
-
.Menu .Menu-item:not([disabled]):not([aria-disabled]):hover:not(:active):not(.has-focus) {
|
53
|
-
background-color: var(--color-background-hover);
|
54
|
-
box-shadow: inset 0 0 0 1px var(--color-gray-600);
|
55
|
-
}
|
56
|
-
|
57
|
-
.Menu .Menu-item:not([disabled]):not([aria-disabled]).has-focus {
|
58
|
-
background-color: var(--color-background-hover);
|
59
|
-
box-shadow: inset 0 0 0 2px var(--color-focus);
|
60
|
-
}
|
61
|
-
|
62
|
-
/* stylelint-disable-next-line no-descending-specificity */
|
63
|
-
|
64
|
-
.Menu-item-list > .VirtualMenu-item-list .VirtualMenu-item:last-child .Menu-item {
|
65
|
-
border-bottom-left-radius: var(--border-radius);
|
66
|
-
border-bottom-right-radius: var(--border-radius);
|
67
|
-
}
|
68
|
-
|
69
|
-
.Menu {
|
70
|
-
font-family: var(--font-family-base);
|
71
|
-
}
|
72
|
-
|
73
|
-
.Menu:focus {
|
74
|
-
outline: none;
|
75
|
-
}
|
76
|
-
|
77
|
-
/* Override our link styles for MenuItemLink component */
|
78
|
-
|
79
|
-
.Menu a.Menu-item:focus:not(:hover):not(.has-focus) {
|
80
|
-
text-decoration: none;
|
81
|
-
box-shadow: none;
|
82
|
-
}
|
83
|
-
|
84
|
-
/* Ensures that links that are disabled don't show active styles */
|
85
|
-
|
86
|
-
.Menu a.Menu-item:active[disabled],
|
87
|
-
.Menu a.Menu-item:active[aria-disabled] {
|
88
|
-
text-decoration: none;
|
89
|
-
color: var(--color-text-subtle-primary);
|
90
|
-
}
|
91
|
-
|
92
|
-
/* stylelint-disable-next-line no-descending-specificity */
|
93
|
-
|
94
|
-
.Menu .Menu-item-list:first-child > .Menu-item:first-child, .Menu [hidden]:first-child + .Menu .Menu-item-list > .Menu-item:first-child {
|
95
|
-
border-top-left-radius: var(--border-radius);
|
96
|
-
border-top-right-radius: var(--border-radius);
|
97
|
-
}
|
98
|
-
|
99
|
-
.Menu .Menu-item-list:first-child > .VirtualMenu-item-list .VirtualMenu-item:first-child .Menu-item, .Menu [hidden]:first-child + .Menu .Menu-item-list > .VirtualMenu-item-list .VirtualMenu-item:first-child .Menu-item {
|
100
|
-
border-top-left-radius: var(--border-radius);
|
101
|
-
border-top-right-radius: var(--border-radius);
|
102
|
-
}
|
103
|
-
|
104
|
-
.Menu-item--nested {
|
105
|
-
padding-left: 4rem;
|
106
|
-
}
|
107
|
-
|
108
|
-
.Menu-item--header {
|
109
|
-
font-weight: var(--font-weight-medium);
|
110
|
-
}
|
111
|
-
|
112
|
-
.Menu-item .Gravatar {
|
113
|
-
margin-right: 0.5rem;
|
114
|
-
}
|
115
|
-
|
116
|
-
.Menu-item.is-highlighted {
|
117
|
-
background-color: var(--color-background-hover);
|
118
|
-
box-shadow: inset 0 0 0 1px var(--color-gray-600);
|
119
|
-
}
|
120
|
-
|
121
|
-
.Menu-item.is-highlighted:active {
|
122
|
-
background-color: var(--color-blue-200);
|
123
|
-
color: var(--color-blue-600);
|
124
|
-
box-shadow: none;
|
125
|
-
}
|
126
|
-
|
127
|
-
.Menu-item[aria-disabled],
|
128
|
-
.Menu-item[disabled] {
|
129
|
-
color: var(--color-text-subtle-primary);
|
130
|
-
cursor: default;
|
131
|
-
}
|
132
|
-
|
133
|
-
.Menu-item-icon {
|
134
|
-
position: absolute;
|
135
|
-
left: 0.5rem;
|
136
|
-
top: 50%;
|
137
|
-
transform: translateY(-50%);
|
138
|
-
}
|
139
|
-
|
140
|
-
.Menu-divider {
|
141
|
-
border-top: 1px solid var(--color-border);
|
142
|
-
}
|
143
|
-
|
144
|
-
.Menu-search {
|
145
|
-
padding: 1rem;
|
146
|
-
font-size: 1.3rem;
|
147
|
-
border-bottom: 1px solid var(--color-border);
|
148
|
-
}
|
149
|
-
|
150
|
-
.Menu-search:first-child {
|
151
|
-
border-top-left-radius: var(--border-radius);
|
152
|
-
border-top-right-radius: var(--border-radius);
|
153
|
-
}
|
154
|
-
|
155
|
-
.Menu-clear.Button {
|
156
|
-
text-decoration: none;
|
157
|
-
color: var(--color-system-red-600);
|
158
|
-
font-size: 1.3rem;
|
159
|
-
font-weight: var(--font-weight-medium);
|
160
|
-
padding: 1rem;
|
161
|
-
width: 100%;
|
162
|
-
border-bottom: 1px solid var(--color-border);
|
163
|
-
}
|
164
|
-
|
165
|
-
.Menu-clear.Button:active,
|
166
|
-
.Menu-clear.Button:focus,
|
167
|
-
.Menu-clear.Button:hover {
|
168
|
-
outline: none;
|
169
|
-
box-shadow: none;
|
170
|
-
box-shadow: initial;
|
171
|
-
color: var(--color-system-red-600);
|
172
|
-
border-bottom-color: var(--color-border);
|
173
|
-
background-color: var(--color-background-hover);
|
174
|
-
}
|
175
|
-
|
176
|
-
[class^='_Popover-content_'] .Menu-search {
|
177
|
-
width: 100%;
|
178
|
-
}
|
179
|
-
|
180
|
-
/* Removing anything that could give it some height */
|
181
|
-
|
182
|
-
[class^='_Popover-content_'] .Menu-search .Menu-search-hidden-placeholder {
|
183
|
-
padding-top: 0;
|
184
|
-
padding-bottom: 0;
|
185
|
-
height: 0;
|
186
|
-
border: none;
|
187
|
-
visibility: hidden;
|
188
|
-
}
|
189
|
-
|
190
|
-
.Menu--isVirtual {
|
191
|
-
display: flex;
|
192
|
-
align-items: stretch;
|
193
|
-
flex-direction: column;
|
194
|
-
}
|
195
|
-
|
196
|
-
.MenuSize--xl {
|
197
|
-
width: 32rem;
|
198
|
-
}
|
199
|
-
|
200
|
-
.MenuSize--lg {
|
201
|
-
width: 24rem;
|
202
|
-
}
|
203
|
-
|
204
|
-
.MenuSize--md {
|
205
|
-
width: 16rem;
|
206
|
-
}
|
207
|
-
|
208
|
-
.MenuSize--sm {
|
209
|
-
width: 12rem;
|
210
|
-
}
|
211
|
-
|
212
|
-
.VirtualMenu-item-list {
|
213
|
-
width: 100%;
|
214
|
-
position: relative;
|
215
|
-
}
|
216
|
-
|
217
|
-
.VirtualMenu-item {
|
218
|
-
position: absolute;
|
219
|
-
top: 0;
|
220
|
-
left: 0;
|
221
|
-
width: 100%;
|
222
|
-
}
|
package/dist/utils.d.ts
DELETED
@@ -1,7 +0,0 @@
|
|
1
|
-
import type { EventHandler, KeyboardEvent, SyntheticEvent } from 'react';
|
2
|
-
declare const createItemId: (index: number, id: string) => string;
|
3
|
-
declare const getNodeForIndex: (index: number | null, menuId: string) => HTMLElement | null;
|
4
|
-
declare const handleKeyboardInteractions: (event: KeyboardEvent, keyHandlers: Partial<Record<"handleUp" | "handleDown" | "handleEnter", (e: KeyboardEvent) => void>>) => void;
|
5
|
-
declare const chainEventHandlers: (...handlers: Array<EventHandler<SyntheticEvent> | undefined>) => (event: SyntheticEvent) => void;
|
6
|
-
export { createItemId, getNodeForIndex, handleKeyboardInteractions, chainEventHandlers };
|
7
|
-
//# sourceMappingURL=utils.d.ts.map
|
package/dist/utils.d.ts.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAEzE,QAAA,MAAM,YAAY,UAAW,MAAM,MAAM,MAAM,WAA0B,CAAC;AAE1E,QAAA,MAAM,eAAe,UAAW,MAAM,GAAG,IAAI,UAAU,MAAM,uBACkB,CAAC;AAEhF,QAAA,MAAM,0BAA0B,UACvB,aAAa,6EAEoC,aAAa,KAAK,IAAI,WAa/E,CAAC;AAEF,QAAA,MAAM,kBAAkB,gBACR,MAAM,aAAa,cAAc,CAAC,GAAG,SAAS,CAAC,aACrD,cAAc,SAErB,CAAC;AAEJ,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,0BAA0B,EAAE,kBAAkB,EAAE,CAAC"}
|