File tree Expand file tree Collapse file tree 8 files changed +77
-0
lines changed Expand file tree Collapse file tree 8 files changed +77
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ ' @qwik-ui/styled ' : patch
3
+ ---
4
+
5
+ feat(styled kit): add Skeleton component
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ export const statusByComponent: ComponentKitsStatuses = {
23
23
Pagination : ComponentStatus . Draft ,
24
24
Popover : ComponentStatus . Draft ,
25
25
Separator : ComponentStatus . Beta ,
26
+ Skeleton : ComponentStatus . Beta ,
26
27
Tabs : ComponentStatus . Beta ,
27
28
Textarea : ComponentStatus . Draft ,
28
29
} ,
Original file line number Diff line number Diff line change 19
19
- [ Modal] ( /docs/styled/modal )
20
20
- [ Popover] ( /docs/styled/popover )
21
21
- [ Separator] ( /docs/styled/separator )
22
+ - [ Skeleton] ( /docs/styled/skeleton )
22
23
- [ Tabs] ( /docs/styled/tabs )
23
24
- [ Textarea] ( /docs/styled/textarea )
Original file line number Diff line number Diff line change
1
+ import { component$ } from '@builder.io/qwik' ;
2
+ import { Skeleton } from '@qwik-ui/styled' ;
3
+
4
+ export default component$ ( ( ) => {
5
+ return (
6
+ < div class = "flex flex-col space-y-3" >
7
+ < Skeleton class = "h-32 w-64 rounded-3xl" />
8
+ < div class = "space-y-2" >
9
+ < Skeleton class = "h-4 w-64" />
10
+ < Skeleton class = "h-4 w-48" />
11
+ </ div >
12
+ </ div >
13
+ ) ;
14
+ } ) ;
Original file line number Diff line number Diff line change
1
+ import { component$ } from '@builder.io/qwik' ;
2
+ import { Skeleton } from '@qwik-ui/styled' ;
3
+
4
+ export default component$ ( ( ) => {
5
+ return (
6
+ < div class = "flex items-center space-x-4" >
7
+ < Skeleton class = "h-12 w-12 rounded-full" />
8
+ < div class = "space-y-2" >
9
+ < Skeleton class = "h-4 w-[250px]" />
10
+ < Skeleton class = "h-4 w-[200px]" />
11
+ </ div >
12
+ </ div >
13
+ ) ;
14
+ } ) ;
Original file line number Diff line number Diff line change
1
+ ---
2
+ title : Qwik UI | Styled Skeleton Component
3
+ ---
4
+
5
+ import { statusByComponent } from ' ~/_state/component-statuses' ;
6
+
7
+ <StatusBanner status = { statusByComponent .styled .Skeleton } />
8
+
9
+ # Popover
10
+
11
+ Visually or semantically separates content.
12
+
13
+ <Showcase name = " hero" />
14
+
15
+ ## Installation
16
+
17
+ ``` sh
18
+ qwik-ui add skeleton
19
+ ```
20
+
21
+ ## Usage
22
+
23
+ ``` tsx
24
+ import { Skeleton } from ' @qwik-ui/styled' ;
25
+ ```
26
+
27
+ ``` tsx
28
+ <Skeleton className = " h-6 w-24 rounded-full" />
29
+ ```
30
+
31
+ ## Examples
32
+
33
+ ### Card
34
+
35
+ <Showcase name = " card" />
Original file line number Diff line number Diff line change
1
+ import { QwikIntrinsicElements , component$ } from '@builder.io/qwik' ;
2
+ import { cn } from '@qwik-ui/utils' ;
3
+
4
+ export const Skeleton = component$ < QwikIntrinsicElements [ 'div' ] > ( ( { ...props } ) => {
5
+ return < div { ...props } class = { cn ( 'bg-accent animate-pulse rounded' , props . class ) } /> ;
6
+ } ) ;
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ export * from './components/label/label';
9
9
export * from './components/modal/modal' ;
10
10
export * from './components/popover/popover' ;
11
11
export * from './components/separator/separator' ;
12
+ export * from './components/skeleton/skeleton' ;
12
13
export * from './components/tabs/tabs' ;
13
14
export * from './components/textarea/textarea' ;
14
15
export * from './components/toggle/toggle' ;
You can’t perform that action at this time.
0 commit comments