Files
clj-ui-framework/src/ui/skeleton.css
Florian Schroedl 18043cb150 feat: add 13 components adapted from Oat UI
Components (.cljc + .css + tests):
- Alert (success/warning/danger/info variants)
- Badge (primary/secondary/outline/success/warning/danger)
- Card (card/card-header/card-body/card-footer)
- Accordion (collapsible with open/closed state)
- Table (headers/rows, striped/bordered variants)
- Dialog (modal with header/body/footer sections)
- Breadcrumb (nav with active item)
- Pagination (current/total with prev/next)
- Progress (value bar with color variants)
- Spinner (sm/md/lg sizes)
- Skeleton (line/box/circle/heading placeholders)
- Switch (toggle with checked/disabled states)
- Tooltip (hover text via data-tooltip attr)

CSS-only additions:
- Form elements (inputs, selects, checkboxes, radios, range, groups)
- Grid (12-column system with offsets, responsive)
- Utilities (flex, spacing, alignment, sr-only)

Also adds warning/fg-on-warning tokens to light and dark themes.
All 3 dev targets updated with full component showcase.
40 tests, 213 assertions, all passing.
2026-03-03 11:37:05 +01:00

43 lines
666 B
CSS

.skeleton {
background: var(--bg-2);
border-radius: var(--radius-md);
animation: skeleton-pulse 2s infinite;
background-size: 200% 100%;
background-image: linear-gradient(
90deg,
var(--bg-2) 0%,
var(--bg-1) 50%,
var(--bg-2) 100%
);
}
.skeleton + .skeleton {
margin-top: var(--size-3);
}
.skeleton--line {
height: 1rem;
width: 100%;
}
.skeleton--box {
width: 4rem;
height: 4rem;
}
.skeleton--circle {
width: 3rem;
height: 3rem;
border-radius: 9999px;
}
.skeleton--heading {
height: 1.5rem;
width: 60%;
}
@keyframes skeleton-pulse {
from { background-position: 200% 0; }
to { background-position: -200% 0; }
}