From ce248dc3831a494bf70625d3f4b0b6ca895a2d97 Mon Sep 17 00:00:00 2001 From: Elizabeth Mitchell Date: Tue, 1 Aug 2023 14:00:41 -0700 Subject: [PATCH] fix(checkbox)!: remove error property BREAKING CHANGE: Design is still exploring error-state checkboxes. If needed, theme with an error color and set aria-invalid. PiperOrigin-RevId: 552914338 --- checkbox/demo/demo.ts | 1 - checkbox/demo/stories.ts | 9 +---- checkbox/internal/_checkbox.scss | 61 ------------------------------ checkbox/internal/checkbox.ts | 27 +------------ checkbox/internal/checkbox_test.ts | 23 ----------- tokens/_md-comp-checkbox.scss | 32 ++++++++-------- 6 files changed, 20 insertions(+), 133 deletions(-) diff --git a/checkbox/demo/demo.ts b/checkbox/demo/demo.ts index 9bc5c4c6bc..c520af9d7f 100644 --- a/checkbox/demo/demo.ts +++ b/checkbox/demo/demo.ts @@ -16,7 +16,6 @@ const collection = new MaterialCollection>('Checkbox', [ new Knob('checked', {defaultValue: false, ui: boolInput()}), new Knob('indeterminate', {defaultValue: false, ui: boolInput()}), - new Knob('error', {defaultValue: false, ui: boolInput()}), new Knob('disabled', {defaultValue: false, ui: boolInput()}), ]); diff --git a/checkbox/demo/stories.ts b/checkbox/demo/stories.ts index 1c9b2b261b..dab76724a8 100644 --- a/checkbox/demo/stories.ts +++ b/checkbox/demo/stories.ts @@ -13,19 +13,17 @@ import {css, html} from 'lit'; export interface StoryKnobs { checked: boolean; disabled: boolean; - error: boolean; indeterminate: boolean; } const checkbox: MaterialStoryInit = { name: 'Checkbox', - render({checked, disabled, error, indeterminate}) { + render({checked, disabled, indeterminate}) { return html` `; @@ -47,13 +45,12 @@ const withLabels: MaterialStoryInit = { } `, ], - render({disabled, error}) { + render({disabled}) { return html`