Files
libredesk/frontend/tailwind.config.cjs
T
Abhinav Raut d8b73c5877 retheme UI to the green palette and fix form and search bugs
Colors: the brand color moves from indigo to green in both themes, and the
sidebar, tooltip, card and link styles follow it. Three new tokens replace
hardcoded values: foreground-lighter for idle sidebar items, warning-600 for
warning text that needs 4.5:1 contrast on light backgrounds, and link for
anchors inside rendered email content. DESIGN_SYSTEM.md now lists the real
values from main.scss instead of the old indigo ones.

Forms: every button inside a form that is not the submit button now has an
explicit type. Without it the browser treats it as a submit button, so
clicking Cancel on a contact note posted an empty note, "New holiday" saved
the whole business-hours form, and pressing Enter in an SLA field deleted the
first alert row. The login page also highlights an empty password field on a
failed submit, which a broken condition prevented before, and the two
password fields on the set-password page get their own show and hide toggles.

Search: conversation and contact search now drop responses from an older
query, so clearing the box no longer repopulates the list with stale results.

Permissions: /api/v1/ai/summarize now needs messages:write, since it writes a
private note, and the menu item is hidden for agents without it.
2026-07-25 00:49:26 +05:30

223 lines
6.2 KiB
JavaScript

const animate = require("tailwindcss-animate")
const typography = require("@tailwindcss/typography")
/** @type {import('tailwindcss').Config} */
module.exports = {
mode: 'jit',
darkMode: "class",
safelist: ["dark"],
prefix: "",
content: [
'./apps/main/src/**/*.{js,ts,vue}',
'./apps/widget/src/**/*.{js,ts,vue}',
'./shared-ui/**/*.{js,ts,vue}',
],
theme: {
container: {
center: true,
padding: '2rem',
screens: {
'2xl': '1400px'
}
},
extend: {
height: {
screen: '100dvh'
},
minHeight: {
screen: '100dvh'
},
colors: {
border: 'hsl(var(--border))',
input: 'hsl(var(--input))',
ring: 'hsl(var(--ring))',
background: 'hsl(var(--background))',
foreground: 'hsl(var(--foreground))',
'foreground-lighter': 'hsl(var(--foreground-lighter))',
sidebar: {
DEFAULT: 'hsl(var(--sidebar-background))',
foreground: 'hsl(var(--sidebar-foreground))',
primary: 'hsl(var(--sidebar-primary))',
'primary-foreground': 'hsl(var(--sidebar-primary-foreground))',
accent: 'hsl(var(--sidebar-accent))',
'accent-foreground': 'hsl(var(--sidebar-accent-foreground))',
border: 'hsl(var(--sidebar-border))',
ring: 'hsl(var(--sidebar-ring))'
},
primary: {
DEFAULT: 'hsl(var(--primary))',
foreground: 'hsl(var(--primary-foreground))'
},
secondary: {
DEFAULT: 'hsl(var(--secondary))',
foreground: 'hsl(var(--secondary-foreground))'
},
destructive: {
DEFAULT: 'hsl(var(--destructive))',
foreground: 'hsl(var(--destructive-foreground))'
},
success: {
DEFAULT: 'hsl(var(--success))',
foreground: 'hsl(var(--success-foreground))'
},
warning: {
DEFAULT: 'hsl(var(--warning))',
foreground: 'hsl(var(--warning-foreground))',
600: 'hsl(var(--warning-600))'
},
link: 'hsl(var(--link))',
muted: {
DEFAULT: 'hsl(var(--muted))',
foreground: 'hsl(var(--muted-foreground))'
},
accent: {
DEFAULT: 'hsl(var(--accent))',
foreground: 'hsl(var(--accent-foreground))'
},
popover: {
DEFAULT: 'hsl(var(--popover))',
foreground: 'hsl(var(--popover-foreground))'
},
card: {
DEFAULT: 'hsl(var(--card))',
foreground: 'hsl(var(--card-foreground))'
},
private: 'hsl(var(--private))',
canvas: 'hsl(var(--canvas))'
},
borderRadius: {
xl: 'calc(var(--radius) + 4px)',
lg: 'var(--radius)',
md: 'calc(var(--radius) - 2px)',
sm: 'calc(var(--radius) - 4px)'
},
keyframes: {
'dot-flashing': {
'0%': { opacity: '0.2' },
'100%': { opacity: '1' },
},
'accordion-down': {
from: {
height: 0
},
to: {
height: 'var(--radix-accordion-content-height)'
}
},
shake: {
'0%': { transform: 'translateX(0)' },
'15%': { transform: 'translateX(-5px)' },
'25%': { transform: 'translateX(5px)' },
'35%': { transform: 'translateX(-5px)' },
'45%': { transform: 'translateX(5px)' },
'55%': { transform: 'translateX(-5px)' },
'65%': { transform: 'translateX(5px)' },
'75%': { transform: 'translateX(-5px)' },
'85%': { transform: 'translateX(5px)' },
'95%': { transform: 'translateX(-5px)' },
'100%': { transform: 'translateX(0)' },
},
'accordion-up': {
from: {
height: 'var(--radix-accordion-content-height)'
},
to: {
height: 0
}
},
'collapsible-down': {
from: {
height: 0
},
to: {
height: 'var(--radix-collapsible-content-height)'
}
},
'collapsible-up': {
from: {
height: 'var(--radix-collapsible-content-height)'
},
to: {
height: 0
}
},
'fade-in-down': {
'0%': {
opacity: '0',
transform: 'translateY(-3px)'
},
'100%': {
opacity: '1',
transform: 'translateY(0)'
}
},
'bounce-in': {
'0%': {
transform: 'scale(0)'
},
'50%': {
transform: 'scale(1.2)'
},
'100%': {
transform: 'scale(1)'
}
},
'fade-in': {
'0%': {
opacity: '0'
},
'100%': {
opacity: '1'
}
},
'fade-out': {
'0%': {
opacity: '1'
},
'100%': {
opacity: '0'
}
},
'slide-in': {
'0%': {
transform: 'translateY(10px)',
opacity: '0'
},
'100%': {
transform: 'translateY(0)',
opacity: '1'
}
},
'slide-out': {
'0%': {
transform: 'translateY(0)',
opacity: '1'
},
'100%': {
transform: 'translateY(10px)',
opacity: '0'
}
}
},
animation: {
'accordion-down': 'accordion-down 0.2s ease-out',
'accordion-up': 'accordion-up 0.2s ease-out',
'collapsible-down': 'collapsible-down 0.2s ease-in-out',
'collapsible-up': 'collapsible-up 0.2s ease-in-out',
'fade-in-down': 'fade-in-down 0.3s ease-out',
'bounce-in': 'bounce-in 0.3s',
'bounce-out': 'bounce-in 0.3s reverse',
'fade-in': 'fade-in 0.3s ease-out',
'fade-out': 'fade-out 0.3s ease-in',
'slide-in': 'slide-in 0.3s cubic-bezier(0.4, 0, 0.2, 1)',
'slide-out': 'slide-out 0.3s cubic-bezier(0.4, 0, 0.2, 1)',
'shake': 'shake 0.5s ease-in-out',
'dot-flashing': 'dot-flashing 1s infinite linear alternate',
}
}
},
plugins: [animate, typography],
}