From 0f779c49108bdf192bbb991a6439e172ed3701a0 Mon Sep 17 00:00:00 2001 From: sjschlapbach Date: Mon, 9 Sep 2024 19:46:46 +0200 Subject: [PATCH] enhance(Switch): show lock on switch thumb component when disabled --- packages/design-system/src/Switch.stories.tsx | 26 +++++++++++++++++++ packages/design-system/src/Switch.tsx | 10 ++++--- 2 files changed, 33 insertions(+), 3 deletions(-) diff --git a/packages/design-system/src/Switch.stories.tsx b/packages/design-system/src/Switch.stories.tsx index df0d8fbd..a3b374e7 100644 --- a/packages/design-system/src/Switch.stories.tsx +++ b/packages/design-system/src/Switch.stories.tsx @@ -124,8 +124,34 @@ export const Sizes = () => { onCheckedChange={(newValue) => setIsChecked2(newValue)} /> +
+ setIsChecked3(newValue)} + /> +
+
+ setIsChecked1(newValue)} + /> +
+
+ setIsChecked2(newValue)} + /> +
+ > + {disabled && ( + + )} + {!labelLeft && label && (