@@ -91,7 +91,6 @@ const processDeploymentWindowStateAppGroup = importComponentFromFELibrary(
91
91
const ChangeImageSource = importComponentFromFELibrary ( 'ChangeImageSource' , null , 'function' )
92
92
const WebhookAddImageModal = importComponentFromFELibrary ( 'WebhookAddImageModal' , null , 'function' )
93
93
94
- // FIXME: IN CIMaterials we are sending isCDLoading while in CD materials we are sending isCILoading
95
94
let inprogressStatusTimer
96
95
const EnvTriggerView = ( { filteredAppIds, isVirtualEnv } : AppGroupDetailDefaultType ) => {
97
96
const { envId } = useParams < { envId : string } > ( )
@@ -100,11 +99,7 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
100
99
const match = useRouteMatch < CIMaterialRouterProps > ( )
101
100
const { url } = useRouteMatch ( )
102
101
103
- const abortControllerRef = useRef ( new AbortController ( ) )
104
-
105
102
const [ pageViewType , setPageViewType ] = useState < string > ( ViewType . LOADING )
106
- const [ isCILoading , setCILoading ] = useState ( false )
107
- const [ isCDLoading , setCDLoading ] = useState ( false )
108
103
const [ isBranchChangeLoading , setIsBranchChangeLoading ] = useState ( false )
109
104
const [ showPreDeployment , setShowPreDeployment ] = useState ( false )
110
105
const [ showPostDeployment , setShowPostDeployment ] = useState ( false )
@@ -417,8 +412,6 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
417
412
if ( ! appIds . length ) {
418
413
updateResponseListData ( skippedResources )
419
414
setIsBranchChangeLoading ( false )
420
- setCDLoading ( false )
421
- setCILoading ( false )
422
415
return
423
416
}
424
417
@@ -436,8 +429,6 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
436
429
} )
437
430
} )
438
431
updateResponseListData ( [ ..._responseList , ...skippedResources ] )
439
- setCDLoading ( false )
440
- setCILoading ( false )
441
432
} )
442
433
. catch ( ( error ) => {
443
434
showError ( error )
@@ -448,8 +439,6 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
448
439
}
449
440
450
441
const closeCDModal = ( ) : void => {
451
- abortControllerRef . current . abort ( )
452
- setCDLoading ( false )
453
442
history . push ( {
454
443
search : '' ,
455
444
} )
@@ -464,7 +453,6 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
464
453
}
465
454
466
455
const hideBulkCDModal = ( ) => {
467
- setCDLoading ( false )
468
456
setShowBulkCDModal ( false )
469
457
setResponseList ( [ ] )
470
458
@@ -479,16 +467,12 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
479
467
}
480
468
481
469
const hideBulkCIModal = ( ) => {
482
- setCILoading ( false )
483
470
setShowBulkCIModal ( false )
484
471
setResponseList ( [ ] )
485
472
}
486
473
487
474
const onShowBulkCIModal = ( ) => {
488
- setCILoading ( true )
489
- setTimeout ( ( ) => {
490
- setShowBulkCIModal ( true )
491
- } , 100 )
475
+ setShowBulkCIModal ( true )
492
476
}
493
477
494
478
const hideChangeSourceModal = ( ) => {
@@ -666,7 +650,7 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
666
650
667
651
return (
668
652
< ApprovalMaterialModal
669
- isLoading = { isCDLoading }
653
+ isLoading = { false }
670
654
node = { node ?? ( { } as CommonNodeAttr ) }
671
655
materialType = { MATERIAL_TYPE . inputMaterialList }
672
656
stageType = { DeploymentNodeType . CD }
@@ -751,23 +735,16 @@ const EnvTriggerView = ({ filteredAppIds, isVirtualEnv }: AppGroupDetailDefaultT
751
735
text = "Build image"
752
736
onClick = { onShowBulkCIModal }
753
737
size = { ComponentSizeType . medium }
754
- isLoading = { isCILoading }
755
738
/>
756
739
< div className = "flex" >
757
740
< button
758
- className = { `cta flex h-32 ${ _showPopupMenu ? 'dc__no-right-radius' : '' } ` }
741
+ className = { `cta flex h-32 dc__gap-8 ${ _showPopupMenu ? 'dc__no-right-radius' : '' } ` }
759
742
data-trigger-type = "CD"
760
743
data-testid = "bulk-deploy-button"
761
744
onClick = { onShowBulkCDModal }
762
745
>
763
- { isCDLoading ? (
764
- < Progressing />
765
- ) : (
766
- < >
767
- < DeployIcon className = "icon-dim-16 dc__no-svg-fill mr-8" />
768
- Deploy
769
- </ >
770
- ) }
746
+ < DeployIcon className = "icon-dim-16 dc__no-svg-fill" />
747
+ Deploy
771
748
</ button >
772
749
{ _showPopupMenu && renderDeployPopupMenu ( ) }
773
750
</ div >
0 commit comments