Manuel Bustillo 1b71bc9d79
All checks were successful
Check usage of free licenses / build-static-assets (pull_request) Successful in 1m21s
Add copyright notice / copyright_notice (pull_request) Successful in 1m53s
Playwright Tests / test (pull_request) Successful in 8m19s
Build Nginx-based docker image / build-static-assets (pull_request) Successful in 10m37s
Display the table arrangements returned by the API
2024-11-02 12:52:18 +01:00

12 lines
466 B
TypeScript

import clsx from "clsx";
type ButtonColor = 'primary' | 'blue' | 'green' | 'red' | 'yellow';
export function classNames(type: ButtonColor) {
return(clsx("text-white py-1 px-2 mx-1 rounded", {
'bg-blue-400 hover:bg-blue-600': type === 'primary' || type === 'blue',
'bg-green-500 hover:bg-green-600': type === 'green',
'bg-red-500 hover:bg-red-600': type === 'red',
'bg-yellow-500 hover:bg-yellow-700': type === 'yellow'
}))
}