Skip to content

Commit 36df07a

Browse files
committed
fix(checkbox): changes checkBoxSig to checkboxSig
1 parent 0f4895c commit 36df07a

File tree

11 files changed

+19
-126
lines changed

11 files changed

+19
-126
lines changed

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list-false.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export default component$(() => {
1111
<Checkbox.Root
1212
class="flex items-center gap-3 bg-slate-900 text-white"
1313
checklist={true}
14-
checkBoxSig={checklistSig}
14+
checkboxSig={checklistSig}
1515
id="checklist"
1616
>
1717
<Checklist.Indicator class="w-fit">

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list-falses.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ export default component$(() => {
1717
<p>Controlls all</p>
1818
</Checkbox.Root>
1919
<Checkbox.Root
20-
checkBoxSig={firstUserSig}
20+
checkboxSig={firstUserSig}
2121
class="flex items-center gap-3 bg-slate-900 pr-2 text-white"
2222
>
2323
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
2424
<p>No other stuff is needed here</p>
2525
</Checkbox.Root>
2626

27-
<Checkbox.Root checkBoxSig={secondUserSig} class="bg-slate-900 text-white">
27+
<Checkbox.Root checkboxSig={secondUserSig} class="bg-slate-900 text-white">
2828
<div class="flex items-center gap-3">
2929
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
3030
<p>No other stuff is needed here</p>

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list-mixed.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,14 @@ export default component$(() => {
2222
<p>Controlls all</p>
2323
</Checkbox.Root>
2424
<Checkbox.Root
25-
checkBoxSig={firstUserSig}
25+
checkboxSig={firstUserSig}
2626
class="flex items-center gap-3 bg-slate-900 pr-2 text-white"
2727
>
2828
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
2929
<p>No other stuff is needed here</p>
3030
</Checkbox.Root>
3131

32-
<Checkbox.Root checkBoxSig={secondUserSig} class="bg-slate-900 text-white">
32+
<Checkbox.Root checkboxSig={secondUserSig} class="bg-slate-900 text-white">
3333
<div class="flex items-center gap-3">
3434
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
3535
<p>No other stuff is needed here</p>

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list-true.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export default component$(() => {
1010
<Checkbox.Root
1111
class="flex items-center gap-3 bg-slate-900 text-white"
1212
checklist={true}
13-
checkBoxSig={checklistSig}
13+
checkboxSig={checklistSig}
1414
id="checklist"
1515
>
1616
<Checklist.Indicator class="w-fit">

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list-trues.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ export default component$(() => {
1717
<p>Controlls all</p>
1818
</Checkbox.Root>
1919
<Checkbox.Root
20-
checkBoxSig={firstUserSig}
20+
checkboxSig={firstUserSig}
2121
class="flex items-center gap-3 bg-slate-900 pr-2 text-white"
2222
>
2323
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
2424
<p>No other stuff is needed here</p>
2525
</Checkbox.Root>
2626

27-
<Checkbox.Root checkBoxSig={secondUserSig} class="bg-slate-900 text-white">
27+
<Checkbox.Root checkboxSig={secondUserSig} class="bg-slate-900 text-white">
2828
<div class="flex items-center gap-3">
2929
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>
3030
<p>No other stuff is needed here</p>

apps/website/src/routes/docs/headless/checkbox/examples/test-controlled-list.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default component$(() => {
1717
<p>Controlls all</p>
1818
</Checkbox.Root>
1919
<Checkbox.Root
20-
checkBoxSig={firstUserSig}
20+
checkboxSig={firstUserSig}
2121
class="flex items-center gap-3 bg-slate-900 pr-2 text-white"
2222
>
2323
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>

apps/website/src/routes/docs/headless/checkbox/examples/test-hero.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ export default component$(() => {
55
const userSig = useSignal(true);
66
return (
77
<>
8-
<Checkbox.Root class="bg-slate-900 text-white" checkBoxSig={userSig}>
8+
<Checkbox.Root class="bg-slate-900 text-white" checkboxSig={userSig}>
99
<div class="flex items-center gap-3">
1010
<Checkbox.Indicator class="w-fit bg-slate-600">
1111
<p id="indicator"></p>

apps/website/src/routes/docs/headless/checkbox/examples/test-props-ids-list.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export default component$(() => {
1919
</Checkbox.Root>
2020
<Checkbox.Root
2121
id="child-1"
22-
checkBoxSig={firstUserSig}
22+
checkboxSig={firstUserSig}
2323
class="flex items-center gap-3 bg-slate-900 pr-2 text-white"
2424
>
2525
<Checkbox.Indicator class="w-fit bg-slate-600"></Checkbox.Indicator>

packages/kit-headless/src/components/checkbox/checkbox.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export type MixedStateCheckboxProps = {
1919
_overWriteCheckbox?: boolean;
2020
} & PropsOf<'div'>;
2121
export type TwoStateCheckboxProps = {
22-
checkBoxSig?: Signal<boolean>;
22+
checkboxSig?: Signal<boolean>;
2323
_useCheckListContext?: boolean;
2424
_overWriteCheckbox?: boolean;
2525
} & PropsOf<'div'>;
@@ -28,7 +28,7 @@ type TwoStateCheckboxBehaviorProps = {
2828
checkboxSig: Signal<boolean>;
2929
} & PropsOf<'div'>;
3030
export type ChecklistTwoStateCheckboxProps = {
31-
checkBoxSig?: Signal<boolean>;
31+
checkboxSig?: Signal<boolean>;
3232
_useCheckListContext?: boolean;
3333
_overWriteCheckbox?: boolean;
3434
} & PropsOf<'div'>;
@@ -65,7 +65,7 @@ function getAriaChecked(triBool: TriBool): 'mixed' | 'true' | 'false' {
6565
export const TwoStateCheckbox = component$<TwoStateCheckboxProps>((props) => {
6666
// all the sig stuff should be refactored into a fancy hook
6767
const defaultSig = useSignal(false);
68-
const appliedSig = props.checkBoxSig ?? defaultSig;
68+
const appliedSig = props.checkboxSig ?? defaultSig;
6969
const checklistID = useSignal<string | undefined>(props.id);
7070
useContextProvider(CheckboxContext, appliedSig);
7171
return (
@@ -89,7 +89,7 @@ export const ChecklistTwoStateCheckbox = component$<ChecklistTwoStateCheckboxPro
8989
// making this a wrapper over the simpler component or using hooks
9090
const checklistContext = useContext(CheckListContext);
9191
const defaultSig = useSignal(false);
92-
const appliedSig = props.checkBoxSig ?? defaultSig;
92+
const appliedSig = props.checkboxSig ?? defaultSig;
9393
const checklistID = useSignal<string | undefined>(props.id);
9494
// makes sure that the checklist's value is the same as its child
9595
const syncToChecklist = useSignal<undefined | boolean>(props._overWriteCheckbox);

packages/kit-headless/src/components/checkbox/checklist.tsx

Lines changed: 0 additions & 107 deletions
This file was deleted.

0 commit comments

Comments
 (0)