fix: suggestions

idk why break all not working
This commit is contained in:
Artemy Egorov 2023-08-25 18:34:12 +03:00
parent 5b2300cd79
commit 84ea50339d
2 changed files with 4 additions and 10 deletions

View file

@ -36,7 +36,7 @@ export function NavbarComponent() {
<NavbarContent className="sm:flex gap-4" justify="start"> <NavbarContent className="sm:flex gap-4" justify="start">
<NavbarItem> <NavbarItem>
<div className="relative block"> <div className="relative inline-block text-left">
<Input <Input
isClearable isClearable
radius="lg" radius="lg"
@ -61,18 +61,14 @@ export function NavbarComponent() {
} }
/> />
<div <div
className="absolute right-1/2 md:right-1 mt-1 flex flex-col justify-center backdrop-blur-3xl rounded-xl p-2 bg-gray-50 dark:bg-transparent" className="absolute right-0 z-10 mt-2 flex flex-col backdrop-blur-3xl rounded-xl bg-gray-50 dark:bg-transparent"
style={{
backfaceVisibility: "hidden",
transform: "translateZ(0)",
}}
> >
{suggestions.length > 0 && {suggestions.length > 0 &&
suggestions.map((suggestion) => ( suggestions.map((suggestion) => (
<Button <Button
key={suggestion} key={suggestion}
onClick={() => navigate(`/search?q=${suggestion}`)} onClick={() => navigate(`/search?q=${suggestion}`)}
className="m-1" className="m-1 break-all"
> >
{suggestion} {suggestion}
</Button> </Button>

View file

@ -38,9 +38,7 @@ export function VideoComponent({ video, uploaderAvatar }: VideoComponentProps) {
<div className="flex flex-row items-center"> <div className="flex flex-row items-center">
<EyeIcon className="w-6 h-6 p-1" /> <EyeIcon className="w-6 h-6 p-1" />
<p className="flex-none text-md"> <p className="flex-none text-md">
{`${shortenNumber(video.views)}${ {`${shortenNumber(video.views)}${video.uploadedDate ? `${video.uploadedDate}` : ""}`}
video.uploadedDate ? `${video.uploadedDate}` : ""
}`}
</p> </p>
</div> </div>
</div> </div>