refactor: docs (#10126)

This commit is contained in:
Noel
2024-02-29 04:37:52 +01:00
committed by GitHub
parent 0f9017ef95
commit 18cce83d80
192 changed files with 8116 additions and 6321 deletions

View File

@@ -0,0 +1,26 @@
'use client';
import { useSetAtom } from 'jotai';
import { Command, Search } from 'lucide-react';
import { isCmdKOpenAtom } from '~/stores/cmdk';
export function SearchButton() {
const setIsOpen = useSetAtom(isCmdKOpenAtom);
return (
<button
aria-label="Open search"
className="flex place-content-between place-items-center rounded-md bg-neutral-200 p-2 dark:bg-neutral-800"
type="button"
onClick={() => setIsOpen(true)}
>
<span className="flex place-items-center gap-2">
<Search aria-hidden size={20} />
Search...
</span>
<span className="hidden place-items-center gap-1 md:flex">
<Command aria-hidden size={20} /> K
</span>
</button>
);
}