@dhis2-ui/button 8.16.0-alpha.1 → 8.16.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +6 -6
- package/types/index.d.ts +10 -32
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dhis2-ui/button",
|
|
3
|
-
"version": "8.16.0-alpha.
|
|
3
|
+
"version": "8.16.0-alpha.2",
|
|
4
4
|
"description": "UI Button",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -33,11 +33,11 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@dhis2/prop-types": "^3.1.2",
|
|
36
|
-
"@dhis2-ui/layer": "8.16.0-alpha.
|
|
37
|
-
"@dhis2-ui/loader": "8.16.0-alpha.
|
|
38
|
-
"@dhis2-ui/popper": "8.16.0-alpha.
|
|
39
|
-
"@dhis2/ui-constants": "8.16.0-alpha.
|
|
40
|
-
"@dhis2/ui-icons": "8.16.0-alpha.
|
|
36
|
+
"@dhis2-ui/layer": "8.16.0-alpha.2",
|
|
37
|
+
"@dhis2-ui/loader": "8.16.0-alpha.2",
|
|
38
|
+
"@dhis2-ui/popper": "8.16.0-alpha.2",
|
|
39
|
+
"@dhis2/ui-constants": "8.16.0-alpha.2",
|
|
40
|
+
"@dhis2/ui-icons": "8.16.0-alpha.2",
|
|
41
41
|
"classnames": "^2.3.1",
|
|
42
42
|
"prop-types": "^15.7.2"
|
|
43
43
|
},
|
package/types/index.d.ts
CHANGED
|
@@ -30,11 +30,7 @@ export interface ButtonProps {
|
|
|
30
30
|
* for identification during testing
|
|
31
31
|
*/
|
|
32
32
|
dataTest?: string
|
|
33
|
-
/**
|
|
34
|
-
* Indicates that the button makes potentially dangerous
|
|
35
|
-
* deletions or data changes.
|
|
36
|
-
* Mutually exclusive with `primary` and `secondary` props
|
|
37
|
-
*/
|
|
33
|
+
/** Applies 'destructive' button appearance, implying a dangerous action */
|
|
38
34
|
destructive?: boolean
|
|
39
35
|
/**
|
|
40
36
|
* Applies a greyed-out appearance and makes the button non-interactive
|
|
@@ -61,15 +57,9 @@ export interface ButtonProps {
|
|
|
61
57
|
* Gets passed as part of the first argument to callbacks (see `onClick`).
|
|
62
58
|
*/
|
|
63
59
|
name?: string
|
|
64
|
-
/**
|
|
65
|
-
* Applies 'primary' button appearance.
|
|
66
|
-
* Mutually exclusive with `destructive` and `secondary` props
|
|
67
|
-
*/
|
|
60
|
+
/** Applies 'primary' button appearance, implying the most important action */
|
|
68
61
|
primary?: boolean
|
|
69
|
-
/**
|
|
70
|
-
* Applies 'secondary' button appearance.
|
|
71
|
-
* Mutually exclusive with `primary` and `destructive` props
|
|
72
|
-
*/
|
|
62
|
+
/** Applies 'secondary' button appearance */
|
|
73
63
|
secondary?: boolean
|
|
74
64
|
/**
|
|
75
65
|
* Makes the button small. Mutually exclusive with `large` prop
|
|
@@ -143,9 +133,7 @@ export interface DropdownButtonProps {
|
|
|
143
133
|
*/
|
|
144
134
|
component?: React.ReactElement<any>
|
|
145
135
|
dataTest?: string
|
|
146
|
-
/**
|
|
147
|
-
* Button variant. Mutually exclusive with `primary` and `secondary` props
|
|
148
|
-
*/
|
|
136
|
+
/** Applies 'destructive' button appearance, implying a dangerous action. */
|
|
149
137
|
destructive?: boolean
|
|
150
138
|
/**
|
|
151
139
|
* Make the button non-interactive
|
|
@@ -165,16 +153,12 @@ export interface DropdownButtonProps {
|
|
|
165
153
|
* Controls popper visibility. When implementing this prop the component becomes a controlled component
|
|
166
154
|
*/
|
|
167
155
|
open?: boolean
|
|
168
|
-
/**
|
|
169
|
-
* Button variant. Mutually exclusive with `destructive` and `secondary` props
|
|
170
|
-
*/
|
|
156
|
+
/** Applies 'primary' button appearance, implying the most important action */
|
|
171
157
|
primary?: boolean
|
|
172
|
-
/**
|
|
173
|
-
* Button variant. Mutually exclusive with `primary` and `destructive` props
|
|
174
|
-
*/
|
|
158
|
+
/** Applies 'secondary' button appearance */
|
|
175
159
|
secondary?: boolean
|
|
176
160
|
/**
|
|
177
|
-
*
|
|
161
|
+
* Changes button size. Mutually exclusive with `large` prop
|
|
178
162
|
*/
|
|
179
163
|
small?: boolean
|
|
180
164
|
tabIndex?: string
|
|
@@ -206,9 +190,7 @@ export interface SplitButtonProps {
|
|
|
206
190
|
*/
|
|
207
191
|
component?: React.ReactElement<any>
|
|
208
192
|
dataTest?: string
|
|
209
|
-
/**
|
|
210
|
-
* Applies 'destructive' appearance to indicate purpose. Mutually exclusive with `primary` and `secondary` props
|
|
211
|
-
*/
|
|
193
|
+
/** Applies 'destructive' button appearance, implying a dangerous action. */
|
|
212
194
|
destructive?: boolean
|
|
213
195
|
/**
|
|
214
196
|
* Disables the button and makes it uninteractive
|
|
@@ -227,13 +209,9 @@ export interface SplitButtonProps {
|
|
|
227
209
|
*/
|
|
228
210
|
large?: boolean
|
|
229
211
|
name?: string
|
|
230
|
-
/**
|
|
231
|
-
* Applies 'primary' appearance to indicate purpose. Mutually exclusive with `destructive` and `secondary` props
|
|
232
|
-
*/
|
|
212
|
+
/** Applies 'primary' button appearance, implying the most important action */
|
|
233
213
|
primary?: boolean
|
|
234
|
-
/**
|
|
235
|
-
* Applies 'secondary' appearance to indicate purpose. Mutually exclusive with `primary` and `destructive` props
|
|
236
|
-
*/
|
|
214
|
+
/** Applies 'secondary' button appearance */
|
|
237
215
|
secondary?: boolean
|
|
238
216
|
/**
|
|
239
217
|
* Changes button size. Mutually exclusive with `large` prop
|