@@ -18,73 +18,87 @@ export default component$(() => {
18
18
< h2 > Basic Example</ h2 >
19
19
< div class = "panel" >
20
20
< Button > default</ Button >
21
- < Button primary > primary</ Button >
22
- < Button secondary > secondary</ Button >
23
- < Button accent > accent</ Button >
24
- < Button info > info</ Button >
25
- < Button success > success</ Button >
26
- < Button warning > warning</ Button >
27
- < Button error > error</ Button >
28
- < Button ghost > ghost</ Button >
29
- < Button link > link</ Button >
30
- < Button primary active > primary active</ Button >
31
- < Button accent active > accent active</ Button >
32
- < Button disabled > disabled</ Button >
33
- < Button disabled = { true } > disabled</ Button >
21
+ < Button variant = "primary" > primary</ Button >
22
+ < Button variant = "secondary" > secondary</ Button >
23
+ < Button variant = "accent" > accent</ Button >
24
+ < Button variant = "info" > info</ Button >
25
+ < Button variant = "success" > success</ Button >
26
+ < Button variant = "warning" > warning</ Button >
27
+ < Button variant = "error" > error</ Button >
28
+ < Button variant = "ghost" > ghost</ Button >
29
+ < Button variant = "link" > link</ Button >
30
+ < Button variant = "primary" disabled > primary disabled</ Button >
31
+ < Button variant = "secondary" disabled > secondary disabled</ Button >
34
32
</ div >
35
33
34
+ < h2 > Active Example</ h2 >
35
+ < div className = "panel" >
36
+ < Button active > default</ Button >
37
+ < Button variant = "primary" active > primary</ Button >
38
+ < Button variant = "secondary" active > secondary</ Button >
39
+ < Button variant = "accent" active > accent</ Button >
40
+ < Button variant = "info" active > info</ Button >
41
+ < Button variant = "success" active > success</ Button >
42
+ < Button variant = "warning" active > warning</ Button >
43
+ < Button variant = "error" active > error</ Button >
44
+ < Button variant = "ghost" active > ghost</ Button >
45
+ < Button variant = "link" active > link</ Button >
46
+ < Button variant = "primary" active disabled > primary | active | disabled</ Button >
47
+ < Button variant = "secondary" active disabled > secondary | active | disabled</ Button >
48
+ </ div >
49
+
50
+
36
51
< h2 > Outline Example</ h2 >
37
52
< div class = "panel" >
38
- < Button outline primary > primary</ Button >
39
- < Button outline secondary > secondary</ Button >
40
- < Button outline accent > accent</ Button >
41
- < Button outline info > info</ Button >
42
- < Button outline success > success</ Button >
43
- < Button outline warning > warning</ Button >
44
- < Button outline error > error</ Button >
45
- < Button outline ghost > ghost</ Button >
46
- < Button outline link > link</ Button >
47
- < Button outline active > active</ Button >
48
- < Button outline disabled > disabled</ Button >
53
+ < Button outline variant = "primary" > primary</ Button >
54
+ < Button outline variant = "secondary" > secondary</ Button >
55
+ < Button outline variant = "accent" > accent</ Button >
56
+ < Button outline variant = "info" > info</ Button >
57
+ < Button outline variant = "success" > success</ Button >
58
+ < Button outline variant = "warning" > warning</ Button >
59
+ < Button outline variant = "error" > error</ Button >
60
+ < Button outline variant = "ghost" > ghost</ Button >
61
+ < Button outline variant = "link" > link</ Button >
62
+ < Button outline variant = "disabled" > disabled</ Button >
49
63
</ div >
50
64
51
65
< h2 > size</ h2 >
52
66
< div class = "panel" >
53
- < Button primary size = "xs" > xs</ Button >
54
- < Button primary size = "sm" > sm</ Button >
55
- < Button primary size = "md" > md</ Button >
56
- < Button primary size = "lg" > lg</ Button >
67
+ < Button variant = " primary" size = "xs" > xs</ Button >
68
+ < Button variant = "secondary" size = "sm" > sm</ Button >
69
+ < Button variant = "accent" size = "md" > md</ Button >
70
+ < Button variant = "warning" size = "lg" > lg</ Button >
57
71
</ div >
58
72
59
73
< h2 > loading</ h2 >
60
74
< div class = "panel" >
61
- < Button primary loading > loading</ Button >
75
+ < Button variant = " primary" loading > loading</ Button >
62
76
< Button loading square > </ Button >
63
77
</ div >
64
78
65
79
< h2 > no click animation</ h2 >
66
80
< div class = "panel" >
67
- < Button primary noAnimation > click me</ Button >
68
- < Button secondary noAnimation > click me</ Button >
81
+ < Button variant = " primary" noAnimation > click me</ Button >
82
+ < Button variant = " secondary" noAnimation > click me</ Button >
69
83
</ div >
70
84
71
85
< h2 > Square and Circle</ h2 >
72
86
< div class = "panel" >
73
- < Button secondary square > A</ Button >
74
- < Button accent circle > B</ Button >
87
+ < Button variant = " secondary" square > A</ Button >
88
+ < Button variant = " accent" circle > B</ Button >
75
89
</ div >
76
90
77
91
< h2 > Custom class</ h2 >
78
92
79
93
< div class = "panel" >
80
- < Button type = "button" primary class = "px-32 border-4 border-black" >
94
+ < Button type = "button" variant = " primary" class = "px-32 border-4 border-black" >
81
95
CUSTOM CLASS
82
96
</ Button >
83
97
</ div >
84
98
85
99
< div >
86
100
< h2 > Qwik Events</ h2 >
87
- < Button primary onClick$ = { $ ( ( ) => window . alert ( 'hello' ) ) } > SHOW ALERT</ Button >
101
+ < Button variant = " primary" onClick$ = { $ ( ( ) => window . alert ( 'hello' ) ) } > SHOW ALERT</ Button >
88
102
</ div >
89
103
</ div >
90
104
</ >
0 commit comments