Skip to content

Commit 2e72fdb

Browse files
committed
fix lint
1 parent 11bfd10 commit 2e72fdb

File tree

3 files changed

+15
-15
lines changed

3 files changed

+15
-15
lines changed

apps/web/components/demo.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,8 +290,8 @@ export function Demo({
290290
}
291291

292292
const components = Object.entries(raw.components ?? {})
293+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
293294
.map(([name, def]: [string, any]) => ({
294-
// eslint-disable-line @typescript-eslint/no-explicit-any
295295
name,
296296
description: (def.description as string) ?? "",
297297
props: extractFields(def.props),
@@ -301,8 +301,8 @@ export function Demo({
301301
.sort((a, b) => a.name.localeCompare(b.name));
302302

303303
const actions = Object.entries(raw.actions ?? {})
304+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
304305
.map(([name, def]: [string, any]) => ({
305-
// eslint-disable-line @typescript-eslint/no-explicit-any
306306
name,
307307
description: (def.description as string) ?? "",
308308
params: extractFields(def.params),

apps/web/components/playground.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -526,8 +526,8 @@ ${jsx}
526526
}
527527

528528
const components = Object.entries(raw.components ?? {})
529+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
529530
.map(([name, def]: [string, any]) => ({
530-
// eslint-disable-line @typescript-eslint/no-explicit-any
531531
name,
532532
description: (def.description as string) ?? "",
533533
props: extractFields(def.props),
@@ -537,8 +537,8 @@ ${jsx}
537537
.sort((a, b) => a.name.localeCompare(b.name));
538538

539539
const actions = Object.entries(raw.actions ?? {})
540+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
540541
.map(([name, def]: [string, any]) => ({
541-
// eslint-disable-line @typescript-eslint/no-explicit-any
542542
name,
543543
description: (def.description as string) ?? "",
544544
params: extractFields(def.params),

apps/web/lib/render/registry.tsx

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
213213
Tabs: ({ props, emit }) => {
214214
const tabs = props.tabs ?? [];
215215
const [boundValue, setBoundValue] = props.statePath
216-
? useStateBinding<string>(props.statePath)
216+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
217217
: [undefined, undefined];
218218
const [localValue, setLocalValue] = useState(
219219
props.defaultValue ?? tabs[0]?.value ?? "",
@@ -767,7 +767,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
767767

768768
Input: ({ props, emit }) => {
769769
const [boundValue, setBoundValue] = props.statePath
770-
? useStateBinding<string>(props.statePath)
770+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
771771
: [undefined, undefined];
772772
const [localValue, setLocalValue] = useState("");
773773
const value = props.statePath ? (boundValue ?? "") : localValue;
@@ -795,7 +795,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
795795

796796
Textarea: ({ props }) => {
797797
const [boundValue, setBoundValue] = props.statePath
798-
? useStateBinding<string>(props.statePath)
798+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
799799
: [undefined, undefined];
800800
const [localValue, setLocalValue] = useState("");
801801
const value = props.statePath ? (boundValue ?? "") : localValue;
@@ -818,7 +818,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
818818

819819
Select: ({ props, emit }) => {
820820
const [boundValue, setBoundValue] = props.statePath
821-
? useStateBinding<string>(props.statePath)
821+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
822822
: [undefined, undefined];
823823
const [localValue, setLocalValue] = useState<string>("");
824824
const value = props.statePath ? (boundValue ?? "") : localValue;
@@ -852,7 +852,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
852852

853853
Checkbox: ({ props, emit }) => {
854854
const [boundValue, setBoundValue] = props.statePath
855-
? useStateBinding<boolean>(props.statePath)
855+
? useStateBinding<boolean>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
856856
: [undefined, undefined];
857857
const [localChecked, setLocalChecked] = useState(!!props.checked);
858858
const checked = props.statePath ? (boundValue ?? false) : localChecked;
@@ -878,7 +878,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
878878
Radio: ({ props, emit }) => {
879879
const options = props.options ?? [];
880880
const [boundValue, setBoundValue] = props.statePath
881-
? useStateBinding<string>(props.statePath)
881+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
882882
: [undefined, undefined];
883883
const [localValue, setLocalValue] = useState(options[0] ?? "");
884884
const value = props.statePath ? (boundValue ?? "") : localValue;
@@ -912,7 +912,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
912912

913913
Switch: ({ props, emit }) => {
914914
const [boundValue, setBoundValue] = props.statePath
915-
? useStateBinding<boolean>(props.statePath)
915+
? useStateBinding<boolean>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
916916
: [undefined, undefined];
917917
const [localChecked, setLocalChecked] = useState(!!props.checked);
918918
const checked = props.statePath ? (boundValue ?? false) : localChecked;
@@ -937,7 +937,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
937937

938938
Slider: ({ props, emit }) => {
939939
const [boundValue, setBoundValue] = props.statePath
940-
? useStateBinding<number>(props.statePath)
940+
? useStateBinding<number>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
941941
: [undefined, undefined];
942942
const [localValue, setLocalValue] = useState(props.min ?? 0);
943943
const value = props.statePath
@@ -1021,7 +1021,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
10211021

10221022
Toggle: ({ props, emit }) => {
10231023
const [boundValue, setBoundValue] = props.statePath
1024-
? useStateBinding<boolean>(props.statePath)
1024+
? useStateBinding<boolean>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
10251025
: [undefined, undefined];
10261026
const [localPressed, setLocalPressed] = useState(props.pressed ?? false);
10271027
const pressed = props.statePath ? (boundValue ?? false) : localPressed;
@@ -1045,7 +1045,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
10451045
const type = props.type ?? "single";
10461046
const items = props.items ?? [];
10471047
const [boundValue, setBoundValue] = props.statePath
1048-
? useStateBinding<string>(props.statePath)
1048+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
10491049
: [undefined, undefined];
10501050
const [localValue, setLocalValue] = useState(items[0]?.value ?? "");
10511051
const value = props.statePath ? (boundValue ?? "") : localValue;
@@ -1086,7 +1086,7 @@ export const { registry, executeAction } = defineRegistry(playgroundCatalog, {
10861086
ButtonGroup: ({ props, emit }) => {
10871087
const buttons = props.buttons ?? [];
10881088
const [boundValue, setBoundValue] = props.statePath
1089-
? useStateBinding<string>(props.statePath)
1089+
? useStateBinding<string>(props.statePath) // eslint-disable-line react-hooks/rules-of-hooks
10901090
: [undefined, undefined];
10911091
const [localValue, setLocalValue] = useState(buttons[0]?.value ?? "");
10921092
const value = props.statePath ? (boundValue ?? "") : localValue;

0 commit comments

Comments
 (0)