-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dev: Adding additional features and components
- Loading branch information
1 parent
6a95a88
commit 84ba1e3
Showing
7 changed files
with
111 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { Input } from '@nextui-org/react'; | ||
import { MagnifyingGlassIcon } from '@heroicons/react/24/solid'; | ||
|
||
/** | ||
* SearchInput properties | ||
*/ | ||
export interface SearchInputProps { | ||
/** | ||
* The placeholder text to display. | ||
*/ | ||
placeholder?: string; | ||
} | ||
|
||
/** | ||
* SearchInput component | ||
*/ | ||
export function SearchInput({ | ||
placeholder = 'Type to search...', | ||
}: SearchInputProps) { | ||
return ( | ||
<Input | ||
classNames={{ | ||
base: 'max-w-full sm:max-w-[10rem] h-10', | ||
mainWrapper: 'h-full', | ||
input: 'text-small', | ||
inputWrapper: 'h-full font-normal text-default-500 bg-default-400/20 dark:bg-default-500/20', | ||
}} | ||
placeholder={placeholder} | ||
size="sm" | ||
startContent={<MagnifyingGlassIcon className="size-6" />} | ||
type="search" | ||
/> | ||
); | ||
} |