Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: export checkboxes as parts #600

Merged
merged 1 commit into from
Nov 28, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions lib/use-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
<input
class="checkbox"
type="checkbox"
part="checkbox"
.checked=${selected}
.dataItem=${item}
@input=${onCheckboxChange}
Expand Down Expand Up @@ -157,7 +158,7 @@
item: e.currentTarget.dataItem,
index: e.currentTarget.dataIndex,
},
})
}),

Check warning on line 161 in lib/use-list.js

View check run for this annotation

Codecov / codecov/patch

lib/use-list.js#L161

Added line #L161 was not covered by tests
);
}, []);

Expand All @@ -169,7 +170,7 @@
const { groupOnColumn } = sortAndGroupOptions,
onItemChange = useCallback(
(column, item) => (value) => _onItemChange(host, column, item, value),
[]
[],
);

return {
Expand Down Expand Up @@ -201,7 +202,7 @@
dataIsValid,
groupOnColumn,
onItemChange,
]
],
),
renderGroup: useMemo(
() =>
Expand All @@ -210,7 +211,7 @@
dataIsValid,
groupOnColumn,
}),
[onCheckboxChange, dataIsValid, groupOnColumn]
[onCheckboxChange, dataIsValid, groupOnColumn],
),
};
};
Loading