"use client";

import { useState } from "react";
import PrimaryButton from "./buttons/PrimaryButton";
import ThemeToggle from "./UI/ThemeToggle";
import { Home } from "lucide-react";

export default function ComponentsConteiner() {
    const [isLoading, setIsloading] = useState(false);
    function dummyLoading() {
        setIsloading(true);
        setTimeout(() => {
            setIsloading(false);
        }, 1500);
    }
    return (
        <div className="flex flex-col items-start gap-2 p-4">
            <ThemeToggle />
            <div className="w-36">
                <PrimaryButton onClick={() => dummyLoading()} loading={isLoading}>
                    <Home size={20} />
                    <p>test icon</p>
                </PrimaryButton>
            </div>
        </div>
    );
}
