event types new dropdown misaligned (#4216)

* fixed event type creation dropdown

* nit
pull/4214/head
Peer Richelsen 2022-09-06 20:51:11 +02:00 committed by GitHub
parent dd9d7ab485
commit efc0bf6a5b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -156,20 +156,22 @@ export default function CreateEventTypeButton(props: CreateEventTypeBtnProps) {
<Button EndIcon={Icon.FiChevronDown}>{t("new")}</Button>
</DropdownMenuTrigger>
<DropdownMenuContent align="end">
<DropdownMenuLabel>{t("new_event_subtitle")}</DropdownMenuLabel>
<DropdownMenuLabel>
<div className="max-w-48 shadow-dropdown">{t("new_event_subtitle")}</div>
</DropdownMenuLabel>
<DropdownMenuSeparator className="h-px bg-gray-200" />
{props.options.map((option) => (
<DropdownMenuItem
key={option.slug}
className="cursor-pointer px-3 py-2 hover:bg-neutral-100 focus:outline-none"
className="flex cursor-pointer items-center px-3 py-2 hover:bg-neutral-100 focus:outline-none"
onSelect={() => openModal(option)}>
<Avatar
alt={option.name || ""}
imageSrc={option.image || `${WEBAPP_URL}/${option.slug}/avatar.png`} // if no image, use default avatar
size="sm"
className="inline ltr:mr-2 rtl:ml-2"
className="inline ltr:mr-4 rtl:ml-4"
/>
{option.name ? option.name : option.slug}
<span className="px-4">{option.name ? option.name : option.slug}</span>
</DropdownMenuItem>
))}
</DropdownMenuContent>