N8N-DASHBOARD/dashboard/tailwind.config.js
David cd1a922976 Redesign dashboard as command center + capture error_message in poller
Dashboard:
- Dark theme by default (zinc-950 background, high-contrast status colors)
- Layout: sticky header with live status, hero HealthBanner, FailuresPanel,
  AnomaliesPanel, 2-col grid (Workflows + Activity), StatsStrip footer
- Auto-detected anomalies: stale active workflows, 100% fail rate, stuck running
- Click any failure/activity row → links to n8n execution view (VITE_N8N_URL)
- VITE_N8N_URL env var threaded through Dockerfile + compose

Poller (poller.n8n.json):
- Fetch n8n Executions: includeData false → true (now includes execution data)
- Create/Update Execution Record: extract error_message from data.resultData.error
  using a safe IIFE that JSON.parses the data field

Also:
- Added vite-env.d.ts so VITE_* env vars are typed
- docker-compose.yml: VITE_N8N_URL added to build args
- .env.example: documented VITE_N8N_URL at root and dashboard level
2026-08-23 19:11:29 +02:00

53 lines
1.7 KiB
JavaScript

/** @type {import('tailwindcss').Config} */
export default {
darkMode: 'class',
content: ['./index.html', './src/**/*.{ts,tsx}'],
theme: {
extend: {
colors: {
// Surfaces (dark by default — command center look)
border: '#27272a', // zinc-800
background: '#09090b', // zinc-950
foreground: '#fafafa', // zinc-50
muted: {
DEFAULT: '#18181b', // zinc-900 (panels)
foreground: '#a1a1aa', // zinc-400 (secondary text)
},
card: {
DEFAULT: '#0f0f12', // slight lift from background
foreground: '#fafafa',
},
popover: {
DEFAULT: '#18181b',
foreground: '#fafafa',
},
// Status — high contrast on dark
success: '#22c55e', // green-500
'success-fg': '#052e16', // for badges
error: '#ef4444', // red-500
'error-fg': '#450a0a',
warning: '#f59e0b', // amber-500
'warning-fg': '#451a03',
pending: '#eab308', // yellow-500
'pending-fg': '#422006',
info: '#3b82f6', // blue-500
'info-fg': '#172554',
// Accent (active states, links)
accent: '#60a5fa', // blue-400
},
borderRadius: {
lg: '0.5rem',
md: '0.375rem',
sm: '0.25rem',
},
fontFamily: {
mono: ['ui-monospace', 'SFMono-Regular', 'Menlo', 'monospace'],
sans: ['ui-sans-serif', 'system-ui', '-apple-system', 'sans-serif'],
},
animation: {
'pulse-slow': 'pulse 3s cubic-bezier(0.4, 0, 0.6, 1) infinite',
},
},
},
plugins: [],
};