@zendeskgarden/react-loaders 8.49.0 → 8.49.3
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/dist/index.cjs.js +17 -15
- package/dist/index.esm.js +17 -15
- package/dist/typings/elements/Dots.d.ts +2 -11
- package/dist/typings/elements/Inline.d.ts +2 -7
- package/dist/typings/elements/Progress.d.ts +2 -12
- package/dist/typings/elements/Skeleton.d.ts +2 -9
- package/dist/typings/elements/Spinner.d.ts +2 -19
- package/dist/typings/index.d.ts +1 -5
- package/dist/typings/styled/{StyledInlineTypingIndicator.d.ts → StyledInline.d.ts} +2 -3
- package/dist/typings/styled/StyledLoadingPlaceholder.d.ts +7 -5
- package/dist/typings/styled/StyledProgress.d.ts +3 -3
- package/dist/typings/styled/index.d.ts +1 -1
- package/dist/typings/types/index.d.ts +62 -0
- package/package.json +3 -3
package/dist/index.cjs.js
CHANGED
|
@@ -193,7 +193,7 @@ StyledDotsCircleThree.defaultProps = {
|
|
|
193
193
|
var COMPONENT_ID$5 = 'loaders.loading_placeholder';
|
|
194
194
|
var StyledLoadingPlaceholder = styled__default["default"].div.attrs({
|
|
195
195
|
'data-garden-id': COMPONENT_ID$5,
|
|
196
|
-
'data-garden-version': '8.49.
|
|
196
|
+
'data-garden-version': '8.49.3',
|
|
197
197
|
role: 'progressbar'
|
|
198
198
|
}).withConfig({
|
|
199
199
|
displayName: "StyledLoadingPlaceholder",
|
|
@@ -228,7 +228,7 @@ var PROGRESS_BACKGROUND_COMPONENT_ID = 'loaders.progress_background';
|
|
|
228
228
|
var StyledProgressBackground = styled__default["default"].div.attrs(function (props) {
|
|
229
229
|
return {
|
|
230
230
|
'data-garden-id': PROGRESS_BACKGROUND_COMPONENT_ID,
|
|
231
|
-
'data-garden-version': '8.49.
|
|
231
|
+
'data-garden-version': '8.49.3',
|
|
232
232
|
borderRadius: props.borderRadius || sizeToBorderRadius(props.size, props.theme)
|
|
233
233
|
};
|
|
234
234
|
}).withConfig({
|
|
@@ -252,7 +252,7 @@ var PROGESS_INDICATOR_COMPONENT_ID = 'loaders.progress_indicator';
|
|
|
252
252
|
var StyledProgressIndicator = styled__default["default"].div.attrs(function (props) {
|
|
253
253
|
return {
|
|
254
254
|
'data-garden-id': PROGESS_INDICATOR_COMPONENT_ID,
|
|
255
|
-
'data-garden-version': '8.49.
|
|
255
|
+
'data-garden-version': '8.49.3',
|
|
256
256
|
height: props.height || sizeToHeight(props.size, props.theme),
|
|
257
257
|
borderRadius: props.borderRadius || sizeToBorderRadius(props.size, props.theme)
|
|
258
258
|
};
|
|
@@ -298,7 +298,7 @@ var retrieveSkeletonGradient = function retrieveSkeletonGradient(_ref3) {
|
|
|
298
298
|
};
|
|
299
299
|
var StyledSkeleton = styled__default["default"].div.attrs({
|
|
300
300
|
'data-garden-id': COMPONENT_ID$4,
|
|
301
|
-
'data-garden-version': '8.49.
|
|
301
|
+
'data-garden-version': '8.49.3'
|
|
302
302
|
}).withConfig({
|
|
303
303
|
displayName: "StyledSkeleton",
|
|
304
304
|
componentId: "sc-1raozze-0"
|
|
@@ -339,7 +339,7 @@ StyledSpinnerCircle.defaultProps = {
|
|
|
339
339
|
|
|
340
340
|
var StyledSVG = styled__default["default"].svg.attrs(function (props) {
|
|
341
341
|
return {
|
|
342
|
-
'data-garden-version': '8.49.
|
|
342
|
+
'data-garden-version': '8.49.3',
|
|
343
343
|
xmlns: 'http://www.w3.org/2000/svg',
|
|
344
344
|
width: props.width,
|
|
345
345
|
height: props.height,
|
|
@@ -372,23 +372,23 @@ var StyledCircle = styled__default["default"].circle.attrs({
|
|
|
372
372
|
cy: 2,
|
|
373
373
|
r: 2
|
|
374
374
|
}).withConfig({
|
|
375
|
-
displayName: "
|
|
376
|
-
componentId: "sc-
|
|
375
|
+
displayName: "StyledInline__StyledCircle",
|
|
376
|
+
componentId: "sc-fxsb9l-0"
|
|
377
377
|
})([""]);
|
|
378
378
|
StyledCircle.defaultProps = {
|
|
379
379
|
theme: reactTheming.DEFAULT_THEME
|
|
380
380
|
};
|
|
381
|
-
var
|
|
381
|
+
var StyledInline = styled__default["default"].svg.attrs(function (props) {
|
|
382
382
|
return {
|
|
383
383
|
'data-garden-id': COMPONENT_ID$3,
|
|
384
|
-
'data-garden-version': '8.49.
|
|
384
|
+
'data-garden-version': '8.49.3',
|
|
385
385
|
viewBox: '0 0 16 4',
|
|
386
386
|
width: props.size,
|
|
387
387
|
height: props.size * 0.25
|
|
388
388
|
};
|
|
389
389
|
}).withConfig({
|
|
390
|
-
displayName: "
|
|
391
|
-
componentId: "sc-
|
|
390
|
+
displayName: "StyledInline",
|
|
391
|
+
componentId: "sc-fxsb9l-1"
|
|
392
392
|
})(["color:", ";", "{opacity:0.2;&:nth-child(1){animation:", " 1s infinite;animation-delay:", ";}&:nth-child(2){animation:", " 1s infinite;animation-delay:0.2s;}&:nth-child(3){animation:", " 1s infinite;animation-delay:", ";}}", ""], function (props) {
|
|
393
393
|
return props.color;
|
|
394
394
|
}, StyledCircle, PULSE_ANIMATION, function (props) {
|
|
@@ -398,7 +398,7 @@ var StyledInlineTypingSVG = styled__default["default"].svg.attrs(function (props
|
|
|
398
398
|
}, function (props) {
|
|
399
399
|
return reactTheming.retrieveComponentStyles(COMPONENT_ID$3, props);
|
|
400
400
|
});
|
|
401
|
-
|
|
401
|
+
StyledInline.defaultProps = {
|
|
402
402
|
theme: reactTheming.DEFAULT_THEME
|
|
403
403
|
};
|
|
404
404
|
|
|
@@ -473,6 +473,8 @@ Dots.defaultProps = {
|
|
|
473
473
|
delayMS: 750
|
|
474
474
|
};
|
|
475
475
|
|
|
476
|
+
var SIZE = ['small', 'medium', 'large'];
|
|
477
|
+
|
|
476
478
|
var _excluded$3 = ["value", "size"];
|
|
477
479
|
var COMPONENT_ID$1 = 'loaders.progress';
|
|
478
480
|
var Progress = React__default["default"].forwardRef(function (_ref, ref) {
|
|
@@ -482,7 +484,7 @@ var Progress = React__default["default"].forwardRef(function (_ref, ref) {
|
|
|
482
484
|
var percentage = Math.max(0, Math.min(100, value));
|
|
483
485
|
return React__default["default"].createElement(StyledProgressBackground, _extends({
|
|
484
486
|
"data-garden-id": COMPONENT_ID$1,
|
|
485
|
-
"data-garden-version": '8.49.
|
|
487
|
+
"data-garden-version": '8.49.3',
|
|
486
488
|
"aria-valuemax": 100,
|
|
487
489
|
"aria-valuemin": 0,
|
|
488
490
|
"aria-valuenow": percentage,
|
|
@@ -498,7 +500,7 @@ Progress.displayName = 'Progress';
|
|
|
498
500
|
Progress.propTypes = {
|
|
499
501
|
color: PropTypes__default["default"].string,
|
|
500
502
|
value: PropTypes__default["default"].number.isRequired,
|
|
501
|
-
size: PropTypes__default["default"].oneOf(
|
|
503
|
+
size: PropTypes__default["default"].oneOf(SIZE)
|
|
502
504
|
};
|
|
503
505
|
Progress.defaultProps = {
|
|
504
506
|
value: 0,
|
|
@@ -681,7 +683,7 @@ var Inline = React.forwardRef(function (_ref, ref) {
|
|
|
681
683
|
var size = _ref.size,
|
|
682
684
|
color = _ref.color,
|
|
683
685
|
other = _objectWithoutProperties(_ref, _excluded);
|
|
684
|
-
return React__default["default"].createElement(
|
|
686
|
+
return React__default["default"].createElement(StyledInline, _extends({
|
|
685
687
|
ref: ref,
|
|
686
688
|
size: size,
|
|
687
689
|
color: color
|
package/dist/index.esm.js
CHANGED
|
@@ -183,7 +183,7 @@ StyledDotsCircleThree.defaultProps = {
|
|
|
183
183
|
var COMPONENT_ID$5 = 'loaders.loading_placeholder';
|
|
184
184
|
var StyledLoadingPlaceholder = styled.div.attrs({
|
|
185
185
|
'data-garden-id': COMPONENT_ID$5,
|
|
186
|
-
'data-garden-version': '8.49.
|
|
186
|
+
'data-garden-version': '8.49.3',
|
|
187
187
|
role: 'progressbar'
|
|
188
188
|
}).withConfig({
|
|
189
189
|
displayName: "StyledLoadingPlaceholder",
|
|
@@ -218,7 +218,7 @@ var PROGRESS_BACKGROUND_COMPONENT_ID = 'loaders.progress_background';
|
|
|
218
218
|
var StyledProgressBackground = styled.div.attrs(function (props) {
|
|
219
219
|
return {
|
|
220
220
|
'data-garden-id': PROGRESS_BACKGROUND_COMPONENT_ID,
|
|
221
|
-
'data-garden-version': '8.49.
|
|
221
|
+
'data-garden-version': '8.49.3',
|
|
222
222
|
borderRadius: props.borderRadius || sizeToBorderRadius(props.size, props.theme)
|
|
223
223
|
};
|
|
224
224
|
}).withConfig({
|
|
@@ -242,7 +242,7 @@ var PROGESS_INDICATOR_COMPONENT_ID = 'loaders.progress_indicator';
|
|
|
242
242
|
var StyledProgressIndicator = styled.div.attrs(function (props) {
|
|
243
243
|
return {
|
|
244
244
|
'data-garden-id': PROGESS_INDICATOR_COMPONENT_ID,
|
|
245
|
-
'data-garden-version': '8.49.
|
|
245
|
+
'data-garden-version': '8.49.3',
|
|
246
246
|
height: props.height || sizeToHeight(props.size, props.theme),
|
|
247
247
|
borderRadius: props.borderRadius || sizeToBorderRadius(props.size, props.theme)
|
|
248
248
|
};
|
|
@@ -288,7 +288,7 @@ var retrieveSkeletonGradient = function retrieveSkeletonGradient(_ref3) {
|
|
|
288
288
|
};
|
|
289
289
|
var StyledSkeleton = styled.div.attrs({
|
|
290
290
|
'data-garden-id': COMPONENT_ID$4,
|
|
291
|
-
'data-garden-version': '8.49.
|
|
291
|
+
'data-garden-version': '8.49.3'
|
|
292
292
|
}).withConfig({
|
|
293
293
|
displayName: "StyledSkeleton",
|
|
294
294
|
componentId: "sc-1raozze-0"
|
|
@@ -329,7 +329,7 @@ StyledSpinnerCircle.defaultProps = {
|
|
|
329
329
|
|
|
330
330
|
var StyledSVG = styled.svg.attrs(function (props) {
|
|
331
331
|
return {
|
|
332
|
-
'data-garden-version': '8.49.
|
|
332
|
+
'data-garden-version': '8.49.3',
|
|
333
333
|
xmlns: 'http://www.w3.org/2000/svg',
|
|
334
334
|
width: props.width,
|
|
335
335
|
height: props.height,
|
|
@@ -362,23 +362,23 @@ var StyledCircle = styled.circle.attrs({
|
|
|
362
362
|
cy: 2,
|
|
363
363
|
r: 2
|
|
364
364
|
}).withConfig({
|
|
365
|
-
displayName: "
|
|
366
|
-
componentId: "sc-
|
|
365
|
+
displayName: "StyledInline__StyledCircle",
|
|
366
|
+
componentId: "sc-fxsb9l-0"
|
|
367
367
|
})([""]);
|
|
368
368
|
StyledCircle.defaultProps = {
|
|
369
369
|
theme: DEFAULT_THEME
|
|
370
370
|
};
|
|
371
|
-
var
|
|
371
|
+
var StyledInline = styled.svg.attrs(function (props) {
|
|
372
372
|
return {
|
|
373
373
|
'data-garden-id': COMPONENT_ID$3,
|
|
374
|
-
'data-garden-version': '8.49.
|
|
374
|
+
'data-garden-version': '8.49.3',
|
|
375
375
|
viewBox: '0 0 16 4',
|
|
376
376
|
width: props.size,
|
|
377
377
|
height: props.size * 0.25
|
|
378
378
|
};
|
|
379
379
|
}).withConfig({
|
|
380
|
-
displayName: "
|
|
381
|
-
componentId: "sc-
|
|
380
|
+
displayName: "StyledInline",
|
|
381
|
+
componentId: "sc-fxsb9l-1"
|
|
382
382
|
})(["color:", ";", "{opacity:0.2;&:nth-child(1){animation:", " 1s infinite;animation-delay:", ";}&:nth-child(2){animation:", " 1s infinite;animation-delay:0.2s;}&:nth-child(3){animation:", " 1s infinite;animation-delay:", ";}}", ""], function (props) {
|
|
383
383
|
return props.color;
|
|
384
384
|
}, StyledCircle, PULSE_ANIMATION, function (props) {
|
|
@@ -388,7 +388,7 @@ var StyledInlineTypingSVG = styled.svg.attrs(function (props) {
|
|
|
388
388
|
}, function (props) {
|
|
389
389
|
return retrieveComponentStyles(COMPONENT_ID$3, props);
|
|
390
390
|
});
|
|
391
|
-
|
|
391
|
+
StyledInline.defaultProps = {
|
|
392
392
|
theme: DEFAULT_THEME
|
|
393
393
|
};
|
|
394
394
|
|
|
@@ -463,6 +463,8 @@ Dots.defaultProps = {
|
|
|
463
463
|
delayMS: 750
|
|
464
464
|
};
|
|
465
465
|
|
|
466
|
+
var SIZE = ['small', 'medium', 'large'];
|
|
467
|
+
|
|
466
468
|
var _excluded$3 = ["value", "size"];
|
|
467
469
|
var COMPONENT_ID$1 = 'loaders.progress';
|
|
468
470
|
var Progress = React.forwardRef(function (_ref, ref) {
|
|
@@ -472,7 +474,7 @@ var Progress = React.forwardRef(function (_ref, ref) {
|
|
|
472
474
|
var percentage = Math.max(0, Math.min(100, value));
|
|
473
475
|
return React.createElement(StyledProgressBackground, _extends({
|
|
474
476
|
"data-garden-id": COMPONENT_ID$1,
|
|
475
|
-
"data-garden-version": '8.49.
|
|
477
|
+
"data-garden-version": '8.49.3',
|
|
476
478
|
"aria-valuemax": 100,
|
|
477
479
|
"aria-valuemin": 0,
|
|
478
480
|
"aria-valuenow": percentage,
|
|
@@ -488,7 +490,7 @@ Progress.displayName = 'Progress';
|
|
|
488
490
|
Progress.propTypes = {
|
|
489
491
|
color: PropTypes.string,
|
|
490
492
|
value: PropTypes.number.isRequired,
|
|
491
|
-
size: PropTypes.oneOf(
|
|
493
|
+
size: PropTypes.oneOf(SIZE)
|
|
492
494
|
};
|
|
493
495
|
Progress.defaultProps = {
|
|
494
496
|
value: 0,
|
|
@@ -671,7 +673,7 @@ var Inline = forwardRef(function (_ref, ref) {
|
|
|
671
673
|
var size = _ref.size,
|
|
672
674
|
color = _ref.color,
|
|
673
675
|
other = _objectWithoutProperties(_ref, _excluded);
|
|
674
|
-
return React.createElement(
|
|
676
|
+
return React.createElement(StyledInline, _extends({
|
|
675
677
|
ref: ref,
|
|
676
678
|
size: size,
|
|
677
679
|
color: color
|
|
@@ -4,17 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React
|
|
8
|
-
|
|
9
|
-
/** Sets the height and width in pixels. Inherits the parent's font size by default. */
|
|
10
|
-
size?: string | number;
|
|
11
|
-
/** Sets the fill color. Inherits the parent's `color` by default. */
|
|
12
|
-
color?: string;
|
|
13
|
-
/** Sets the length of the animation cycle in milliseconds **/
|
|
14
|
-
duration?: number;
|
|
15
|
-
/** Delays displaying the loader to prevent a render flash during normal loading times **/
|
|
16
|
-
delayMS?: number;
|
|
17
|
-
}
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { IDotsProps } from '../types';
|
|
18
9
|
/**
|
|
19
10
|
* @extends SVGAttributes<SVGSVGElement>
|
|
20
11
|
*/
|
|
@@ -4,13 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React
|
|
8
|
-
|
|
9
|
-
/** Sets the width in pixels and scales the loader proportionally */
|
|
10
|
-
size?: number;
|
|
11
|
-
/** Sets the fill color. Inherits the parent's `color` by default. */
|
|
12
|
-
color?: string;
|
|
13
|
-
}
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { IInlineProps } from '../types';
|
|
14
9
|
/**
|
|
15
10
|
* @extends SVGAttributes<SVGSVGElement>
|
|
16
11
|
*/
|
|
@@ -4,18 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React
|
|
8
|
-
|
|
9
|
-
/** Sets the progress as a value between 0 and 100 */
|
|
10
|
-
value?: number;
|
|
11
|
-
/**
|
|
12
|
-
* Sets the foreground bar's fill color.
|
|
13
|
-
* Defaults to the `successHue` [theme](/components/theme-object#colors) value.
|
|
14
|
-
*/
|
|
15
|
-
color?: string;
|
|
16
|
-
/** Adjusts the height */
|
|
17
|
-
size?: 'small' | 'medium' | 'large';
|
|
18
|
-
}
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { IProgressProps } from '../types';
|
|
19
9
|
/**
|
|
20
10
|
* @extends HTMLAttributes<HTMLDivElement>
|
|
21
11
|
*/
|
|
@@ -4,15 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React
|
|
8
|
-
|
|
9
|
-
/** Sets the width as a percentage of the the parent element's width */
|
|
10
|
-
width?: string;
|
|
11
|
-
/** Sets the height as a percentage of parent element's height if the height is not already inherited by `line-height` */
|
|
12
|
-
height?: string;
|
|
13
|
-
/** Inverts the color for use on dark backgrounds */
|
|
14
|
-
isLight?: boolean;
|
|
15
|
-
}
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { ISkeletonProps } from '../types';
|
|
16
9
|
/**
|
|
17
10
|
* @extends HTMLAttributes<HTMLDivElement>
|
|
18
11
|
*/
|
|
@@ -4,25 +4,8 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Sets the height and width in pixels. Inherits the parent's font size by default.
|
|
11
|
-
**/
|
|
12
|
-
size?: string;
|
|
13
|
-
/**
|
|
14
|
-
* Sets the length of the animation cycle in milliseconds
|
|
15
|
-
**/
|
|
16
|
-
duration?: number;
|
|
17
|
-
/**
|
|
18
|
-
* Sets the fill color. Inherits the parent's `color` by default.
|
|
19
|
-
**/
|
|
20
|
-
color?: string;
|
|
21
|
-
/**
|
|
22
|
-
* Delays displaying the loader to prevent a render flash during normal loading times
|
|
23
|
-
**/
|
|
24
|
-
delayMS?: number;
|
|
25
|
-
}
|
|
7
|
+
import React from 'react';
|
|
8
|
+
import { ISpinnerProps } from '../types';
|
|
26
9
|
/**
|
|
27
10
|
* @extends SVGAttributes<SVGSVGElement>
|
|
28
11
|
*/
|
package/dist/typings/index.d.ts
CHANGED
|
@@ -5,12 +5,8 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
export { Dots } from './elements/Dots';
|
|
8
|
-
export type { IDotsProps } from './elements/Dots';
|
|
9
8
|
export { Progress } from './elements/Progress';
|
|
10
|
-
export type { IProgressProps } from './elements/Progress';
|
|
11
9
|
export { Skeleton } from './elements/Skeleton';
|
|
12
|
-
export type { ISkeletonProps } from './elements/Skeleton';
|
|
13
10
|
export { Spinner } from './elements/Spinner';
|
|
14
|
-
export type { ISpinnerProps } from './elements/Spinner';
|
|
15
11
|
export { Inline } from './elements/Inline';
|
|
16
|
-
export type { IInlineProps } from './
|
|
12
|
+
export type { IDotsProps, IInlineProps, IProgressProps, ISkeletonProps, ISpinnerProps } from './types';
|
|
@@ -4,15 +4,14 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
8
7
|
export declare const StyledCircle: import("styled-components").StyledComponent<"circle", import("styled-components").DefaultTheme, {
|
|
9
8
|
fill: "currentColor";
|
|
10
9
|
cy: 2;
|
|
11
10
|
r: 2;
|
|
12
11
|
}, "cy" | "fill" | "r">;
|
|
13
|
-
interface
|
|
12
|
+
interface IStyledInlineProps {
|
|
14
13
|
size: number;
|
|
15
14
|
color: string;
|
|
16
15
|
}
|
|
17
|
-
export declare const
|
|
16
|
+
export declare const StyledInline: import("styled-components").StyledComponent<"svg", import("styled-components").DefaultTheme, IStyledInlineProps, never>;
|
|
18
17
|
export {};
|
|
@@ -4,12 +4,14 @@
|
|
|
4
4
|
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
|
+
interface IStyledLoadingPlaceholderProps {
|
|
8
|
+
fontSize: string | number;
|
|
9
|
+
width?: string;
|
|
10
|
+
height?: string;
|
|
11
|
+
}
|
|
7
12
|
export declare const StyledLoadingPlaceholder: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
8
13
|
'data-garden-id': string;
|
|
9
14
|
'data-garden-version': string;
|
|
10
15
|
role: "progressbar";
|
|
11
|
-
} &
|
|
12
|
-
|
|
13
|
-
width?: string | undefined;
|
|
14
|
-
height?: string | undefined;
|
|
15
|
-
}, "role" | "data-garden-id" | "data-garden-version">;
|
|
16
|
+
} & IStyledLoadingPlaceholderProps, "role" | "data-garden-id" | "data-garden-version">;
|
|
17
|
+
export {};
|
|
@@ -5,15 +5,15 @@
|
|
|
5
5
|
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
6
|
*/
|
|
7
7
|
import { DefaultTheme } from 'styled-components';
|
|
8
|
-
|
|
8
|
+
import { Size } from '../types';
|
|
9
9
|
interface IStyledProgressBackgroundProps {
|
|
10
|
-
size:
|
|
10
|
+
size: Size;
|
|
11
11
|
borderRadius?: number;
|
|
12
12
|
color?: string;
|
|
13
13
|
}
|
|
14
14
|
export declare const StyledProgressBackground: import("styled-components").StyledComponent<"div", DefaultTheme, IStyledProgressBackgroundProps, never>;
|
|
15
15
|
interface IStyledProgressIndicatorProps {
|
|
16
|
-
size:
|
|
16
|
+
size: Size;
|
|
17
17
|
borderRadius?: number;
|
|
18
18
|
value: number;
|
|
19
19
|
height?: number;
|
|
@@ -10,4 +10,4 @@ export { StyledProgressBackground, StyledProgressIndicator } from './StyledProgr
|
|
|
10
10
|
export { StyledSkeleton } from './StyledSkeleton';
|
|
11
11
|
export { StyledSpinnerCircle } from './StyledSpinnerCircle';
|
|
12
12
|
export { StyledSVG } from './StyledSVG';
|
|
13
|
-
export { StyledCircle,
|
|
13
|
+
export { StyledCircle, StyledInline } from './StyledInline';
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright Zendesk, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
|
+
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
+
*/
|
|
7
|
+
import { HTMLAttributes, SVGAttributes } from 'react';
|
|
8
|
+
export declare const SIZE: readonly ["small", "medium", "large"];
|
|
9
|
+
export declare type Size = typeof SIZE[number];
|
|
10
|
+
export interface IDotsProps extends SVGAttributes<SVGSVGElement> {
|
|
11
|
+
/** Sets the height and width in pixels. Inherits the parent's font size by default. */
|
|
12
|
+
size?: string | number;
|
|
13
|
+
/** Sets the fill color. Inherits the parent's `color` by default. */
|
|
14
|
+
color?: string;
|
|
15
|
+
/** Sets the length of the animation cycle in milliseconds **/
|
|
16
|
+
duration?: number;
|
|
17
|
+
/** Delays displaying the loader to prevent a render flash during normal loading times **/
|
|
18
|
+
delayMS?: number;
|
|
19
|
+
}
|
|
20
|
+
export interface IInlineProps extends SVGAttributes<SVGSVGElement> {
|
|
21
|
+
/** Sets the width in pixels and scales the loader proportionally */
|
|
22
|
+
size?: number;
|
|
23
|
+
/** Sets the fill color. Inherits the parent's `color` by default. */
|
|
24
|
+
color?: string;
|
|
25
|
+
}
|
|
26
|
+
export interface IProgressProps extends HTMLAttributes<HTMLDivElement> {
|
|
27
|
+
/** Sets the progress as a value between 0 and 100 */
|
|
28
|
+
value?: number;
|
|
29
|
+
/**
|
|
30
|
+
* Sets the foreground bar's fill color.
|
|
31
|
+
* Defaults to the `successHue` [theme](/components/theme-object#colors) value.
|
|
32
|
+
*/
|
|
33
|
+
color?: string;
|
|
34
|
+
/** Adjusts the height */
|
|
35
|
+
size?: Size;
|
|
36
|
+
}
|
|
37
|
+
export interface ISkeletonProps extends HTMLAttributes<HTMLDivElement> {
|
|
38
|
+
/** Sets the width as a percentage of the the parent element's width */
|
|
39
|
+
width?: string;
|
|
40
|
+
/** Sets the height as a percentage of parent element's height if the height is not already inherited by `line-height` */
|
|
41
|
+
height?: string;
|
|
42
|
+
/** Inverts the color for use on dark backgrounds */
|
|
43
|
+
isLight?: boolean;
|
|
44
|
+
}
|
|
45
|
+
export interface ISpinnerProps extends SVGAttributes<SVGSVGElement> {
|
|
46
|
+
/**
|
|
47
|
+
* Sets the height and width in pixels. Inherits the parent's font size by default.
|
|
48
|
+
**/
|
|
49
|
+
size?: string;
|
|
50
|
+
/**
|
|
51
|
+
* Sets the length of the animation cycle in milliseconds
|
|
52
|
+
**/
|
|
53
|
+
duration?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Sets the fill color. Inherits the parent's `color` by default.
|
|
56
|
+
**/
|
|
57
|
+
color?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Delays displaying the loader to prevent a render flash during normal loading times
|
|
60
|
+
**/
|
|
61
|
+
delayMS?: number;
|
|
62
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zendeskgarden/react-loaders",
|
|
3
|
-
"version": "8.49.
|
|
3
|
+
"version": "8.49.3",
|
|
4
4
|
"description": "Components relating to loaders in the Garden Design System",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Zendesk Garden <garden@zendesk.com>",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"styled-components": "^4.2.0 || ^5.0.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@zendeskgarden/react-theming": "^8.49.
|
|
35
|
+
"@zendeskgarden/react-theming": "^8.49.3"
|
|
36
36
|
},
|
|
37
37
|
"keywords": [
|
|
38
38
|
"components",
|
|
@@ -44,5 +44,5 @@
|
|
|
44
44
|
"access": "public"
|
|
45
45
|
},
|
|
46
46
|
"zendeskgarden:src": "src/index.ts",
|
|
47
|
-
"gitHead": "
|
|
47
|
+
"gitHead": "983322364971c051ca6ce478770edfc3310e4c4b"
|
|
48
48
|
}
|