diff --git a/app/generators/uuid/page.tsx b/app/generators/uuid/page.tsx index 5251745..0a4b00b 100644 --- a/app/generators/uuid/page.tsx +++ b/app/generators/uuid/page.tsx @@ -5,7 +5,7 @@ import { range } from "fp-ts/NonEmptyArray"; import { toolGroups } from "@/config/tools"; import { uuid } from "@/lib/uuid"; -import { useScrollFollow } from "@/hooks/useScrollFollow"; +import { useAutoScroll } from "@/hooks/useAutoScroll"; import { Button } from "@/components/ui/button"; import { Input, InputProps } from "@/components/ui/input"; import * as Select from "@/components/ui/select"; @@ -37,7 +37,7 @@ export default function Page() { const [uuidVersion, setUuidVersion] = useState("4"); const [generates, setGenerates] = useState(1); const [uuids, setUuids] = useState([]); - const ref = useScrollFollow([uuids]); + const ref = useAutoScroll([uuids]); const uuidsString = uuids.join("\n"); diff --git a/app/settings/page.tsx b/app/settings/page.tsx index 71afcf0..67e6a88 100644 --- a/app/settings/page.tsx +++ b/app/settings/page.tsx @@ -8,7 +8,6 @@ import { Configuration } from "@/components/configuration"; import { Configurations } from "@/components/configurations"; import { icons } from "@/components/icons"; import { PageRootSection } from "@/components/page-root-section"; -import { PageSection } from "@/components/page-section"; export default function Page() { const { theme = "system", setTheme } = useTheme(); @@ -38,9 +37,7 @@ export default function Page() { return ( - - - + ); } diff --git a/components/buttons/base.tsx b/components/buttons/base.tsx index a1fb85d..5b01384 100644 --- a/components/buttons/base.tsx +++ b/components/buttons/base.tsx @@ -9,7 +9,7 @@ export type BaseProps = ButtonProps & { export function Base({ icon, iconOnly, labelText, ...props }: BaseProps) { const button = ( - diff --git a/components/page-section.tsx b/components/page-section.tsx index 1d57b60..56f5ed7 100644 --- a/components/page-section.tsx +++ b/components/page-section.tsx @@ -3,22 +3,21 @@ import { cn } from "@/lib/style"; type Props = { className?: string; children: React.ReactNode; - title?: string; + title: string; control?: React.ReactNode; }; export function PageSection({ className, children, title, control }: Props) { return (
- {title && - (control ? ( -
-

{title}

-
{control}
-
- ) : ( -

{title}

- ))} + {control ? ( +
+

{title}

+
{control}
+
+ ) : ( +

{title}

+ )} {children}
); diff --git a/components/sidebar/search-bar.tsx b/components/sidebar/search-bar.tsx index ea26bb7..5bae650 100644 --- a/components/sidebar/search-bar.tsx +++ b/components/sidebar/search-bar.tsx @@ -41,10 +41,10 @@ export function SearchBar() { }; return ( -
+
(null); @@ -25,18 +24,19 @@ export function ToolGroup({ Icon, title, href, tools, isOpend }: Props) {
- +
+ +
(
  • ))} diff --git a/components/sidebar/tool-link.tsx b/components/sidebar/tool-link.tsx index 4a54c57..727f02c 100644 --- a/components/sidebar/tool-link.tsx +++ b/components/sidebar/tool-link.tsx @@ -8,22 +8,24 @@ import { cn } from "@/lib/style"; import { Indicator } from "@/components/indicator"; type Props = Pick & - Pick, "className" | "href" | "onClick"> & { + Pick, "href" | "onClick"> & { highlight: "both" | "indicatorOnly" | "none"; + grouped?: true; }; -function RawToolLink({ Icon, shortTitle: title, href, onClick, className, highlight }: Props) { +// FIXME: css outline messed up +function RawToolLink({ Icon, shortTitle: title, href, onClick, highlight, grouped }: Props) { return ( - + diff --git a/components/ui/input.tsx b/components/ui/input.tsx index a13e4d2..a9307a6 100644 --- a/components/ui/input.tsx +++ b/components/ui/input.tsx @@ -9,7 +9,7 @@ const RawInput = React.forwardRef(({ className, .. (