sag_components 1.0.401 → 1.0.403
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.
|
@@ -34,7 +34,7 @@ const IconButton = props => {
|
|
|
34
34
|
const [progress, setProgress] = (0, _react.useState)(0);
|
|
35
35
|
const [showProcess, setShowProcess] = (0, _react.useState)(false);
|
|
36
36
|
const incrementProgress = () => {
|
|
37
|
-
if (downloadStatus
|
|
37
|
+
if (downloadStatus === 'in progress' && progress <= 90) {
|
|
38
38
|
const interval = setInterval(() => {
|
|
39
39
|
setProgress(prevProgress => {
|
|
40
40
|
const newProgress = prevProgress + 3;
|
|
@@ -45,7 +45,7 @@ const IconButton = props => {
|
|
|
45
45
|
});
|
|
46
46
|
setShowProcess(true);
|
|
47
47
|
}, 500);
|
|
48
|
-
} else
|
|
48
|
+
} else {
|
|
49
49
|
setProgress(0);
|
|
50
50
|
setShowProcess(false);
|
|
51
51
|
}
|
|
@@ -147,7 +147,7 @@ const IconButton = props => {
|
|
|
147
147
|
exports.IconButton = IconButton;
|
|
148
148
|
var _default = exports.default = IconButton;
|
|
149
149
|
IconButton.defaultProps = {
|
|
150
|
-
downloadStatus: '
|
|
150
|
+
downloadStatus: '',
|
|
151
151
|
buttonText: '',
|
|
152
152
|
iconName: 'eye',
|
|
153
153
|
contentColor: '#212121',
|