Fix TS errors
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { Tab, TabGroup, TabList, TabPanel, TabPanels } from "$lib";
|
import { Tab, TabGroup, TabList, TabPanel, TabPanels } from "$lib";
|
||||||
|
|
||||||
function classNames(...classes) {
|
function classNames(...classes: (string | false | null | undefined)[]) {
|
||||||
return classes.filter(Boolean).join(" ");
|
return classes.filter(Boolean).join(" ");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,13 @@
|
|||||||
function classNames(...classes: (string | false | null | undefined)[]) {
|
function classNames(...classes: (string | false | null | undefined)[]) {
|
||||||
return classes.filter(Boolean).join(" ");
|
return classes.filter(Boolean).join(" ");
|
||||||
}
|
}
|
||||||
function resolveClass({ active, disabled }) {
|
function resolveClass({
|
||||||
|
active,
|
||||||
|
disabled,
|
||||||
|
}: {
|
||||||
|
active: boolean;
|
||||||
|
disabled: boolean;
|
||||||
|
}) {
|
||||||
return classNames(
|
return classNames(
|
||||||
"flex justify-between w-full px-4 py-2 text-sm leading-5 text-left",
|
"flex justify-between w-full px-4 py-2 text-sm leading-5 text-left",
|
||||||
active ? "bg-gray-100 text-gray-900" : "text-gray-700",
|
active ? "bg-gray-100 text-gray-900" : "text-gray-700",
|
||||||
|
|||||||
Reference in New Issue
Block a user