@juspay/svelte-ui-components 2.84.0 → 2.84.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -37,7 +37,19 @@
|
|
|
37
37
|
|
|
38
38
|
<!-- svelte-ignore a11y_click_events_have_key_events -->
|
|
39
39
|
<!-- svelte-ignore a11y_no_noninteractive_element_interactions -->
|
|
40
|
-
|
|
40
|
+
<!-- preventDefault stops the label's default activation from firing a synthesized
|
|
41
|
+
click that re-toggles the native input AFTER handleClick has flipped the state,
|
|
42
|
+
which left input.checked out of sync with the rendered box (and with
|
|
43
|
+
:checked-based selectors/testing probes). State has one owner: handleClick. -->
|
|
44
|
+
<label
|
|
45
|
+
class="container {classes ?? ''}"
|
|
46
|
+
class:disabled
|
|
47
|
+
onclick={(e: MouseEvent) => {
|
|
48
|
+
e.preventDefault();
|
|
49
|
+
handleClick();
|
|
50
|
+
}}
|
|
51
|
+
data-pw={testId}
|
|
52
|
+
>
|
|
41
53
|
<input
|
|
42
54
|
type="checkbox"
|
|
43
55
|
class="native-checkbox"
|