From 43182cdfa426dc98c326c248a15a95f91dced033 Mon Sep 17 00:00:00 2001 From: Halvor Haugan Date: Wed, 23 Oct 2024 13:05:15 +0200 Subject: [PATCH] Checkbox: Remove redundant attribute aria-checked --- .changeset/tiny-jobs-arrive.md | 5 +++++ @navikt/core/react/src/form/checkbox/Checkbox.tsx | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 .changeset/tiny-jobs-arrive.md diff --git a/.changeset/tiny-jobs-arrive.md b/.changeset/tiny-jobs-arrive.md new file mode 100644 index 00000000000..5c3481345e5 --- /dev/null +++ b/.changeset/tiny-jobs-arrive.md @@ -0,0 +1,5 @@ +--- +"@navikt/ds-react": patch +--- + +Checkbox: Remove redundant attribute aria-checked diff --git a/@navikt/core/react/src/form/checkbox/Checkbox.tsx b/@navikt/core/react/src/form/checkbox/Checkbox.tsx index 7379ead0822..45d1f09e35a 100644 --- a/@navikt/core/react/src/form/checkbox/Checkbox.tsx +++ b/@navikt/core/react/src/form/checkbox/Checkbox.tsx @@ -41,7 +41,6 @@ export const Checkbox = forwardRef( {...omit(inputProps, ["aria-invalid"])} type="checkbox" className="navds-checkbox__input" - aria-checked={props.indeterminate ? "mixed" : inputProps.checked} ref={(el) => { if (el) { el.indeterminate = props.indeterminate ?? false;