Tansy UI: a themeable React component kit

Tansy UI is a React component kit by OpenKhalix, named after the tansy
flower ("golden buttons"). It has two surfaces:

- A landing page built entirely from the kit's own components, with
  five featured parts, a palette-switching playground form, and links
  into Storybook
- A Storybook workshop with Tansy branding, a Welcome page, palette
  toolbar and accessibility checks

Includes 15 components with colocated tokens and stories, seven brand
palettes, a palette-aware logo, a Docker/nginx image, a scripted
cPanel deploy, and a generator that keeps the landing page catalogue
in sync with Storybook.
This commit is contained in:
thekhalidsha committed 2026-09-28 17:09:57 +05:30
commit 9d406d6d2a
81 files changed
+14240

No files matched your search

+45
View File
@@ -0,0 +1,45 @@
/**
* Alert style tokens.
*
* Kept in a separate module from the component so the file only exports
* components — mixing the two breaks Vite's fast refresh.
*/
export type AlertColor = 'success' | 'info' | 'warning' | 'error'
export type AlertVariant = 'default' | 'filled' | 'outlined' | 'gradient'
export type AlertTheme = {
bg: string
text: string
border: string
lightBg: string
}
export const ALERT_COLORS: Record<AlertColor, AlertTheme> = {
success: {
bg: 'bg-green-600',
text: 'text-green-700',
border: 'border-green-600',
lightBg: 'bg-green-100',
},
info: {
bg: 'bg-sky-600',
text: 'text-sky-700',
border: 'border-sky-600',
lightBg: 'bg-sky-100',
},
warning: {
bg: 'bg-orange-500',
text: 'text-orange-700',
border: 'border-orange-500',
lightBg: 'bg-orange-100',
},
error: {
bg: 'bg-red-600',
text: 'text-red-700',
border: 'border-red-600',
lightBg: 'bg-red-100',
},
}
export const ALERT_GRADIENT = 'bg-gradient-to-r from-green-400 to-primary-500 text-white'