All checks were successful
		
		
	
	Add copyright notice / copyright_notice (pull_request) Successful in 29s
				
			Check usage of free licenses / build-static-assets (pull_request) Successful in 1m34s
				
			Build Nginx-based docker image / build-static-assets (push) Successful in 3m17s
				
			Playwright Tests / test (pull_request) Successful in 4m18s
				
			
		
			
				
	
	
		
			15 lines
		
	
	
		
			644 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			15 lines
		
	
	
		
			644 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
| /* Copyright (C) 2024-2025 LibreWeddingPlanner contributors*/
 | |
| 
 | |
| import clsx from "clsx";
 | |
| 
 | |
| type ButtonColor = 'primary' | 'blue' | 'green' | 'red' | 'yellow' | 'gray';
 | |
| 
 | |
| export function classNames(type: ButtonColor) {
 | |
|     return (clsx("text-white py-1 px-2 m-2 rounded disabled:opacity-50 disabled:cursor-not-allowed", {
 | |
|         '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',
 | |
|         'bg-gray-500 hover:bg-gray-700': type === 'gray'
 | |
|     }))
 | |
| } |