Skip to content

Commit 3503247

Browse files
vnbaaijCopilot
andauthored
Update src/Core.Scripts/src/Components/SortableList/FluentSortableList.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 90c5ce7 commit 3503247

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Core.Scripts/src/Components/SortableList/FluentSortableList.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,11 @@ export namespace Microsoft.FluentUI.Blazor.Components.SortableList {
8181
switch (event.key) {
8282
case 'Enter':
8383
case ' ':
84-
if (typeof (sortable.options.filter) === 'string' && !item.classList.contains(sortable.options.filter.slice(1)) || !sortable.options.filter) {
84+
if (
85+
!sortable.options.filter ||
86+
(typeof sortable.options.filter === 'string' &&
87+
!item.classList.contains(sortable.options.filter.slice(1)))
88+
) {
8589
item.setAttribute('aria-grabbed', (!isGrabbed).toString());
8690
}
8791
event.preventDefault();

0 commit comments

Comments
 (0)