File tree Expand file tree Collapse file tree 5 files changed +3105
-2629
lines changed
components/optionalThemeButton Expand file tree Collapse file tree 5 files changed +3105
-2629
lines changed Original file line number Diff line number Diff line change
1
+ import { component$ } from '@builder.io/qwik' ;
2
+
3
+ export interface ThemeButton {
4
+ theme ?: 'Headless' | 'Daisy' ;
5
+ }
6
+ export default component$ ( ( { theme } : ThemeButton ) => {
7
+ return (
8
+ < a href = "/docs" >
9
+ < button
10
+ type = "button"
11
+ class = { ` shadow-md hover:shadow-lg w-96 h-72 w text-slate-100 ease-in duration-500 bg-slate-600 transition-transform rounded-xl active:rounded-3xl ${
12
+ theme === 'Headless' ? ' hover:bg-yellow-600 ' : ' hover:bg-green-600'
13
+ } `}
14
+ >
15
+ < div class = "bg-slate-900" >
16
+ < img
17
+ src = { `${
18
+ theme === 'Headless' ? '/qwik-headless.png' : '/qwik-daisy.png'
19
+ } `}
20
+ class = "w-72 h-48 self-center mx-auto"
21
+ />
22
+ </ div >
23
+ < div >
24
+ < h2 > { theme } </ h2 >
25
+ < p >
26
+ Yooo { theme } is the best option 4 u! don't listen to the other box
27
+ next to me
28
+ </ p >
29
+ </ div >
30
+ </ button >
31
+ </ a >
32
+ ) ;
33
+ } ) ;
Original file line number Diff line number Diff line change 1
1
import { component$ } from '@builder.io/qwik' ;
2
2
import type { DocumentHead } from '@builder.io/qwik-city' ;
3
+ import OptionalThemeButton from '../components/optionalThemeButton/optionalThemeButton' ;
3
4
4
5
export default component$ ( ( ) => {
5
6
return (
6
7
< div class = "flex flex-col items-center" >
7
8
< h1 class = "text-5xl" > Qwik UI</ h1 >
8
9
< p class = "mt-6 text-lg" > The components library for Qwik</ p >
9
- < a href = "/docs" >
10
- < button class = "link" type = "button" >
11
- All components
12
- </ button >
13
- </ a >
10
+ < div class = " gap-6 flex flex-col lg:flex-row w-full justify-center justify-items-center" >
11
+ < OptionalThemeButton theme = "Headless" />
12
+ < OptionalThemeButton theme = "Daisy" />
13
+ </ div >
14
14
</ div >
15
15
) ;
16
16
} ) ;
You can’t perform that action at this time.
0 commit comments