Spartans get ready! v1 is coming!
We are very close to our first stable release. Expect more announcements in the coming weeks. v1 was made possible by our partner Zerops.
Getting Started
Stack
Components
- Accordion
- Alert
- Alert Dialog
- Aspect Ratio
- Autocomplete
- Avatar
- Badge
- Breadcrumb
- Button
- Button Group
- Calendar
- Card
- Carousel
- Checkbox
- Collapsible
- Combobox
- Command
- Context Menu
- Data Table
- Date Picker
- Dialog
- Dropdown Menu
- Empty
- Form Field
- Hover Card
- Icon
- Input Group
- Input OTP
- Input
- Item
- Kbd
- Label
- Menubar
- Pagination
- Popover
- Progress
- Radio Group
- Resizable
- Scroll Area
- Select
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Sonner (Toast)
- Spinner
- Switch
- Table
- Tabs
- Textarea
- Toggle
- Toggle Group
- Tooltip
Skeleton
Use to show a placeholder while content is loading.
import { Component } from '@angular/core';
import { HlmSkeletonImports } from '@spartan-ng/helm/skeleton';
@Component({
selector: 'spartan-skeleton-preview',
imports: [HlmSkeletonImports],
template: `
<div class="flex items-center space-x-4">
<hlm-skeleton class="size-12 rounded-full" />
<div class="space-y-2">
<hlm-skeleton class="h-4 w-[250px]" />
<hlm-skeleton class="h-4 w-[200px]" />
</div>
</div>
`,
})
export class SkeletonPreview {}Installation
npx nx g @spartan-ng/cli:ui skeleton
ng g @spartan-ng/cli:ui skeleton
Usage
import { HlmSkeletonImports } from '@spartan-ng/helm/skeleton';<hlm-skeleton class="h-[20px] w-[100px] rounded-full" />Examples
Card
import { Component } from '@angular/core';
import { HlmSkeletonImports } from '@spartan-ng/helm/skeleton';
@Component({
selector: 'spartan-skeleton-card',
imports: [HlmSkeletonImports],
template: `
<div class="flex flex-col space-y-3">
<hlm-skeleton class="h-[125px] w-[250px] rounded-xl" />
<div class="space-y-2">
<hlm-skeleton class="h-4 w-[250px]" />
<hlm-skeleton class="h-4 w-[200px]" />
</div>
</div>
`,
})
export class SkeletonCard {}Helm API
HlmSkeleton
Selector: hlm-skeleton
Inputs
| Prop | Type | Default | Description |
|---|---|---|---|
| class | ClassValue | - | - |