mirror of
https://github.com/Sonny93/my-links.git
synced 2025-12-10 15:35:35 +00:00
feat: create settings modal
This commit is contained in:
6
inertia/lib/color.ts
Normal file
6
inertia/lib/color.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import hexRgb from 'hex-rgb';
|
||||
|
||||
export const rgba = (hex: string, alpha: number) => {
|
||||
const rgb = hexRgb(hex, { format: 'array' }).slice(0, -1).join(',');
|
||||
return `rgba(${rgb},${alpha})`;
|
||||
};
|
||||
Reference in New Issue
Block a user