swarm-ui: add CheckboxField and use it for the issue report toggle and the account delete option
This commit is contained in:
parent
a1a70e257c
commit
acf82beba3
1 changed files with 105 additions and 30 deletions
|
|
@ -33,6 +33,7 @@ import { readApiError, type ProblemDetails } from "@hive/shared/api-error.js";
|
|||
import { Badge } from "@hive/shared/badge.js";
|
||||
import { useLocalSetting } from "@hive/shared/settings-storage.js";
|
||||
import { Panel } from "../ui/panel/Panel.js";
|
||||
import { CheckboxField } from "../ui/checkbox-field/CheckboxField.js";
|
||||
import { SelectField } from "../ui/select-field/SelectField.js";
|
||||
import { Table, type TableColumn } from "../ui/table/Table.js";
|
||||
import { ALL_REPOS, reportUrl, repoOptions } from "./issue-report-repo.js";
|
||||
|
|
@ -378,16 +379,12 @@ export function IssueReportPage() {
|
|||
onChange={setRepoFilter}
|
||||
options={repoOptions(repos, repoFilter)}
|
||||
/>
|
||||
<label class="issue-report-toggle">
|
||||
<input
|
||||
type="checkbox"
|
||||
checked={hideBlocked}
|
||||
onChange={(e) =>
|
||||
setHideBlocked((e.target as HTMLInputElement).checked)
|
||||
}
|
||||
/>
|
||||
hide blocked (open dependency)
|
||||
</label>
|
||||
<CheckboxField
|
||||
id="issue-report-hide-blocked"
|
||||
label="hide blocked (open dependency)"
|
||||
checked={hideBlocked}
|
||||
onChange={setHideBlocked}
|
||||
/>
|
||||
</div>
|
||||
{reposError ? (
|
||||
<ApiErrorPanel
|
||||
|
|
|
|||
Loading…
Reference in a new issue