Previews

No matching results.

x
1
2
3
4
5
6
7
8
9
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
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
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
<!-- With dynamic label -->
<select-panel data-interaction-subject="e985c4fa49cc96c3e5a94ce57caeaed0" data-select-variant="single" data-fetch-strategy="local" data-open-on-load="false" data-dynamic-label="true" data-dynamic-label-prefix="Item" id="with_avatar_items" anchor-align="start" anchor-side="outside-bottom" data-view-component="true">
<dialog-helper>
<button id="with_avatar_items-button" aria-controls="with_avatar_items-dialog" aria-haspopup="dialog" aria-expanded="false" type="button" data-view-component="true" class="Button--secondary Button--medium Button"> <span class="Button-content">
<span class="Button-label">Choose item</span>
</span>
</button>
<dialog id="with_avatar_items-dialog" aria-labelledby="with_avatar_items-dialog-title" data-target="select-panel.dialog" style="position: absolute;" data-view-component="true" class="Overlay Overlay-whenNarrow Overlay--size-small-portrait">
<div data-view-component="true" class="Overlay-header Overlay-header--divided">
<div class="Overlay-headerContentWrap">
<div class="Overlay-titleWrap">
<h1 class="Overlay-title " id="with_avatar_items-dialog-title">
Select users
</h1>
</div>
<div class="Overlay-actionWrap">
<button data-close-dialog-id="with_avatar_items-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x">
<path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path>
</svg></button>
</div>
</div>
<div data-view-component="true" class="Overlay-headerFilter">
<div data-target="select-panel.bannerErrorElement" hidden>
<x-banner data-dismiss-scheme="none" data-view-component="true">
<div data-view-component="true" class="Banner flash Banner--error flash-error mb-2">
<div class="Banner-visual">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-stop">
<path d="M4.47.22A.749.749 0 0 1 5 0h6c.199 0 .389.079.53.22l4.25 4.25c.141.14.22.331.22.53v6a.749.749 0 0 1-.22.53l-4.25 4.25A.749.749 0 0 1 11 16H5a.749.749 0 0 1-.53-.22L.22 11.53A.749.749 0 0 1 0 11V5c0-.199.079-.389.22-.53Zm.84 1.28L1.5 5.31v5.38l3.81 3.81h5.38l3.81-3.81V5.31L10.69 1.5ZM8 4a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 4Zm0 8a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z"></path>
</svg>
</div>
<div data-view-component="true" class="Banner-message">
<p class="Banner-title" data-target="x-banner.titleText">
<h2 class="f6 text-normal">Sorry, something went wrong.</h2>
</p>
</div>
</div>
</x-banner> </div>
<remote-input aria-owns="with_avatar_items-body" data-target="select-panel.remoteInput" data-view-component="true">
<primer-text-field class="FormControl width-full FormControl--fullWidth">
<label for="with_avatar_items-filter" class="sr-only FormControl-label position-absolute sr-only FormControl-label">
Filter
</label>
<div class="FormControl-input-wrap FormControl-input-wrap--leadingVisual">
<span class="FormControl-input-leadingVisualWrap">
<svg data-target="primer-text-field.leadingVisual" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search FormControl-input-leadingVisual">
<path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path>
</svg>
<span hidden="hidden" data-target="primer-text-field.leadingSpinner" data-view-component="true">
<svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true" data-view-component="true" class="anim-rotate">
<circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" fill="none" />
<path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" />
</svg> <span class="sr-only">Loading</span>
</span>
</span>
<input id="with_avatar_items-filter" type="search" autofocus="autofocus" data-target="primer-text-field.inputElement select-panel.filterInputTextField" aria-describedby="validation-d91739be-c462-4523-9d0e-ad764d81ef1e" class="FormControl-input FormControl-medium" name="filter" />
</div>
<div class="FormControl-inlineValidation" id="validation-d91739be-c462-4523-9d0e-ad764d81ef1e" hidden="hidden">
<span class="FormControl-inlineValidation--visual" data-target="primer-text-field.validationSuccessIcon" hidden><svg aria-hidden="true" height="12" viewBox="0 0 12 12" version="1.1" width="12" data-view-component="true" class="octicon octicon-check-circle-fill">
<path d="M6 0a6 6 0 1 1 0 12A6 6 0 0 1 6 0Zm-.705 8.737L9.63 4.403 8.392 3.166 5.295 6.263l-1.7-1.702L2.356 5.8l2.938 2.938Z"></path>
</svg></span>
<span class=" FormControl-inlineValidation--visual" data-target="primer-text-field.validationErrorIcon"><svg aria-hidden="true" height="12" viewBox="0 0 12 12" version="1.1" width="12" data-view-component="true" class="octicon octicon-alert-fill">
<path d="M4.855.708c.5-.896 1.79-.896 2.29 0l4.675 8.351a1.312 1.312 0 0 1-1.146 1.954H1.33A1.313 1.313 0 0 1 .183 9.058ZM7 7V3H5v4Zm-1 3a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z"></path>
</svg></span>
<span></span>
</div>
</primer-text-field>
</remote-input></div>
</div>
<div data-view-component="true" class="Overlay-body mt-0 p-0">
<focus-group direction="vertical" mnemonics retain>
<div class="sr-only" aria-live="polite" aria-atomic="true" data-target="select-panel.ariaLiveContainer"></div>
<div data-fetch-strategy="local" data-target="select-panel.list" data-view-component="true">
<div id="with_avatar_items-body">
<action-list>
<div data-view-component="true">
<ul aria-label="Select users options" id="with_avatar_items-list" role="listbox" data-view-component="true" class="ActionListWrap p-2">
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-73b04412-0f82-471f-9ba1-5f58eb0ad634" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 1
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-7f11746d-53d1-48e1-9de0-d8622d3fbfa5" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 2
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-7a6a4b32-0b65-485f-af63-9ba091c2ed5a" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 3
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-0e8e1591-6de6-4573-be16-e32c662509ac" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 4
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-59995a18-23bc-470d-958d-97f50bb1082a" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 5
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-be28c5a6-06f7-4fea-b966-d530f3a9a0be" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 6
</span>
</button>
</li>
</ul>
</div>
</action-list>
</div>
<div data-target="select-panel.noResults" class="pt-2 color-border-muted text-center d-flex flex-items-start flex-justify-center SelectPanel-emptyPanel" hidden>
<h2 class="v-align-middle m-3 f5">No results found</h2>
</div>
</div>
</focus-group>
</div>
</dialog> </dialog-helper>
</select-panel>
<script>
function ready(fn) {
if (document.readyState !== 'loading') {
fn()
} else {
document.addEventListener('DOMContentLoaded', fn)
}
}
ready(() => {
const subject = document.querySelector("[data-interaction-subject='e985c4fa49cc96c3e5a94ce57caeaed0']")
if (!subject) return
const fetchStrategy = subject.getAttribute('data-fetch-strategy')
if (fetchStrategy === 'local') {
subject.setAttribute('data-ready', 'true')
return
}
subject.addEventListener('loadend', (event) => {
event.target.setAttribute('data-ready', 'true')
})
})
</script>
<!-- With dynamic label and aria prefix -->
<select-panel data-interaction-subject="12425506cab3d7a98259b3b8a9d7905b" data-select-variant="single" data-fetch-strategy="local" data-open-on-load="false" data-dynamic-label="true" data-dynamic-label-prefix="Item" data-dynamic-aria-label-prefix="Your item" id="with_avatar_items" anchor-align="start" anchor-side="outside-bottom" data-view-component="true">
<dialog-helper>
<button id="with_avatar_items-button" aria-controls="with_avatar_items-dialog" aria-haspopup="dialog" aria-expanded="false" type="button" data-view-component="true" class="Button--secondary Button--medium Button"> <span class="Button-content">
<span class="Button-label">Choose item</span>
</span>
</button>
<dialog id="with_avatar_items-dialog" aria-labelledby="with_avatar_items-dialog-title" data-target="select-panel.dialog" style="position: absolute;" data-view-component="true" class="Overlay Overlay-whenNarrow Overlay--size-small-portrait">
<div data-view-component="true" class="Overlay-header Overlay-header--divided">
<div class="Overlay-headerContentWrap">
<div class="Overlay-titleWrap">
<h1 class="Overlay-title " id="with_avatar_items-dialog-title">
Select users
</h1>
</div>
<div class="Overlay-actionWrap">
<button data-close-dialog-id="with_avatar_items-dialog" aria-label="Close" type="button" data-view-component="true" class="close-button Overlay-closeButton"><svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-x">
<path d="M3.72 3.72a.75.75 0 0 1 1.06 0L8 6.94l3.22-3.22a.749.749 0 0 1 1.275.326.749.749 0 0 1-.215.734L9.06 8l3.22 3.22a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215L8 9.06l-3.22 3.22a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042L6.94 8 3.72 4.78a.75.75 0 0 1 0-1.06Z"></path>
</svg></button>
</div>
</div>
<div data-view-component="true" class="Overlay-headerFilter">
<div data-target="select-panel.bannerErrorElement" hidden>
<x-banner data-dismiss-scheme="none" data-view-component="true">
<div data-view-component="true" class="Banner flash Banner--error flash-error mb-2">
<div class="Banner-visual">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-stop">
<path d="M4.47.22A.749.749 0 0 1 5 0h6c.199 0 .389.079.53.22l4.25 4.25c.141.14.22.331.22.53v6a.749.749 0 0 1-.22.53l-4.25 4.25A.749.749 0 0 1 11 16H5a.749.749 0 0 1-.53-.22L.22 11.53A.749.749 0 0 1 0 11V5c0-.199.079-.389.22-.53Zm.84 1.28L1.5 5.31v5.38l3.81 3.81h5.38l3.81-3.81V5.31L10.69 1.5ZM8 4a.75.75 0 0 1 .75.75v3.5a.75.75 0 0 1-1.5 0v-3.5A.75.75 0 0 1 8 4Zm0 8a1 1 0 1 1 0-2 1 1 0 0 1 0 2Z"></path>
</svg>
</div>
<div data-view-component="true" class="Banner-message">
<p class="Banner-title" data-target="x-banner.titleText">
<h2 class="f6 text-normal">Sorry, something went wrong.</h2>
</p>
</div>
</div>
</x-banner> </div>
<remote-input aria-owns="with_avatar_items-body" data-target="select-panel.remoteInput" data-view-component="true">
<primer-text-field class="FormControl width-full FormControl--fullWidth">
<label for="with_avatar_items-filter" class="sr-only FormControl-label position-absolute sr-only FormControl-label">
Filter
</label>
<div class="FormControl-input-wrap FormControl-input-wrap--leadingVisual">
<span class="FormControl-input-leadingVisualWrap">
<svg data-target="primer-text-field.leadingVisual" aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-search FormControl-input-leadingVisual">
<path d="M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z"></path>
</svg>
<span hidden="hidden" data-target="primer-text-field.leadingSpinner" data-view-component="true">
<svg style="box-sizing: content-box; color: var(--color-icon-primary);" width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true" data-view-component="true" class="anim-rotate">
<circle cx="8" cy="8" r="7" stroke="currentColor" stroke-opacity="0.25" stroke-width="2" vector-effect="non-scaling-stroke" fill="none" />
<path d="M15 8a7.002 7.002 0 00-7-7" stroke="currentColor" stroke-width="2" stroke-linecap="round" vector-effect="non-scaling-stroke" />
</svg> <span class="sr-only">Loading</span>
</span>
</span>
<input id="with_avatar_items-filter" type="search" autofocus="autofocus" data-target="primer-text-field.inputElement select-panel.filterInputTextField" aria-describedby="validation-7f14370e-f5c7-40e4-8be7-ef838f17416e" class="FormControl-input FormControl-medium" name="filter" />
</div>
<div class="FormControl-inlineValidation" id="validation-7f14370e-f5c7-40e4-8be7-ef838f17416e" hidden="hidden">
<span class="FormControl-inlineValidation--visual" data-target="primer-text-field.validationSuccessIcon" hidden><svg aria-hidden="true" height="12" viewBox="0 0 12 12" version="1.1" width="12" data-view-component="true" class="octicon octicon-check-circle-fill">
<path d="M6 0a6 6 0 1 1 0 12A6 6 0 0 1 6 0Zm-.705 8.737L9.63 4.403 8.392 3.166 5.295 6.263l-1.7-1.702L2.356 5.8l2.938 2.938Z"></path>
</svg></span>
<span class=" FormControl-inlineValidation--visual" data-target="primer-text-field.validationErrorIcon"><svg aria-hidden="true" height="12" viewBox="0 0 12 12" version="1.1" width="12" data-view-component="true" class="octicon octicon-alert-fill">
<path d="M4.855.708c.5-.896 1.79-.896 2.29 0l4.675 8.351a1.312 1.312 0 0 1-1.146 1.954H1.33A1.313 1.313 0 0 1 .183 9.058ZM7 7V3H5v4Zm-1 3a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z"></path>
</svg></span>
<span></span>
</div>
</primer-text-field>
</remote-input></div>
</div>
<div data-view-component="true" class="Overlay-body mt-0 p-0">
<focus-group direction="vertical" mnemonics retain>
<div class="sr-only" aria-live="polite" aria-atomic="true" data-target="select-panel.ariaLiveContainer"></div>
<div data-fetch-strategy="local" data-target="select-panel.list" data-view-component="true">
<div id="with_avatar_items-body">
<action-list>
<div data-view-component="true">
<ul aria-label="Select users options" id="with_avatar_items-list" role="listbox" data-view-component="true" class="ActionListWrap p-2">
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-1eea30c5-786a-4bc6-a54e-9aa8d7c7a73c" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 1
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-3e0d07b2-121b-49a3-89e4-2c7930db8e9a" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 2
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-ec6cbddb-4e14-40c8-a5b4-8977fc012d04" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 3
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-8c13d06d-b083-459c-81e4-1fceea5125d7" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 4
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-503bfc60-7784-4312-86d1-d2255c329d5c" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 5
</span>
</button>
</li>
<li data-targets="action-list.items" role="none" data-view-component="true" class="ActionListItem">
<button id="item-a294e903-47c1-4dcc-9529-0ec98d8d2cf2" type="button" role="option" aria-selected="false" data-view-component="true" class="ActionListContent">
<span class="ActionListItem-visual ActionListItem-action--leading">
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-check ActionListItem-singleSelectCheckmark">
<path d="M13.78 4.22a.75.75 0 0 1 0 1.06l-7.25 7.25a.75.75 0 0 1-1.06 0L2.22 9.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018L6 10.94l6.72-6.72a.75.75 0 0 1 1.06 0Z"></path>
</svg>
</span>
<span data-view-component="true" class="ActionListItem-label">
Item 6
</span>
</button>
</li>
</ul>
</div>
</action-list>
</div>
<div data-target="select-panel.noResults" class="pt-2 color-border-muted text-center d-flex flex-items-start flex-justify-center SelectPanel-emptyPanel" hidden>
<h2 class="v-align-middle m-3 f5">No results found</h2>
</div>
</div>
</focus-group>
</div>
</dialog> </dialog-helper>
</select-panel>
<script>
function ready(fn) {
if (document.readyState !== 'loading') {
fn()
} else {
document.addEventListener('DOMContentLoaded', fn)
}
}
ready(() => {
const subject = document.querySelector("[data-interaction-subject='12425506cab3d7a98259b3b8a9d7905b']")
if (!subject) return
const fetchStrategy = subject.getAttribute('data-fetch-strategy')
if (fetchStrategy === 'local') {
subject.setAttribute('data-ready', 'true')
return
}
subject.addEventListener('loadend', (event) => {
event.target.setAttribute('data-ready', 'true')
})
})
</script>
1
2
3
4
5
6
7
8
9
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
45
46
47
48
49
50
51
<%# With dynamic label %>
<% subject_id = SecureRandom.hex %>
<%= render(Primer::Alpha::SelectPanel.new(
data: { interaction_subject: subject_id },
id: "with_avatar_items",
title: "Select users",
select_variant: :single,
fetch_strategy: :local,
dynamic_label: true,
dynamic_label_prefix: "Item",
open_on_load: open_on_load
)) do |panel| %>
<% panel.with_show_button { "Choose item" } %>
<% panel.with_item(label: "Item 1") %>
<% panel.with_item(label: "Item 2") %>
<% panel.with_item(label: "Item 3") %>
<% panel.with_item(label: "Item 4") %>
<% panel.with_item(label: "Item 5") %>
<% panel.with_item(label: "Item 6") %>
<% end %>
<%= render partial: "primer/alpha/select_panel_preview/interaction_subject_js", locals: { subject_id: subject_id } %>
<%# With dynamic label and aria prefix %>
<% subject_id = SecureRandom.hex %>
<%= render(Primer::Alpha::SelectPanel.new(
data: { interaction_subject: subject_id },
id: "with_avatar_items",
title: "Select users",
select_variant: :single,
fetch_strategy: :local,
dynamic_label: true,
dynamic_label_prefix: "Item",
dynamic_aria_label_prefix: "Your item",
open_on_load: open_on_load
)) do |panel| %>
<% panel.with_show_button { "Choose item" } %>
<% panel.with_item(label: "Item 1") %>
<% panel.with_item(label: "Item 2") %>
<% panel.with_item(label: "Item 3") %>
<% panel.with_item(label: "Item 4") %>
<% panel.with_item(label: "Item 5") %>
<% panel.with_item(label: "Item 6") %>
<% end %>
<%= render partial: "primer/alpha/select_panel_preview/interaction_subject_js", locals: { subject_id: subject_id } %>
Param Description Input

app/components/primer/alpha/select_panel.css

1
2
3
4
5
6
7
.SelectPanel-loadingPanel {
min-height: min(var(--overlay-height) - 10rem, 100vh - 2rem);
}
.SelectPanel-emptyPanel {
min-height: min(var(--overlay-height) - 10rem, 100vh - 2rem);
}