import React from 'react'; import 'twin.macro'; import ButtonAction from '../../../types/UserInterface/ButtonAction'; import ButtonPrimary from '../Styled/ButtonPrimary'; import ButtonSecondary from '../Styled/ButtonSecondary'; export interface PopupButtonsProps { actions: ButtonAction[], } export default function PopupButtons({ actions, }: PopupButtonsProps) { return (
{actions.map((action) => ( action.theme === 'primary' ? ( action.onClick?.()} tw="ml-2 py-1 px-4 rounded" > {action.label} ) : ( action.onClick?.()} tw="ml-2 py-1 px-4 rounded" > {action.label} ) ))}
); }