@@ -54,7 +54,7 @@ import AppEnvSelector from './AppDetails.components'
54
54
import { HibernationModalTypes } from './appDetails.type'
55
55
import AppDetailsCDButton from './AppDetailsCDButton'
56
56
import AppStatusCard from './AppStatusCard'
57
- import { AG_APP_DETAILS_GA_EVENTS , DA_APP_DETAILS_GA_EVENTS } from './constants'
57
+ import { ACTION_DISABLED_TEXT , AG_APP_DETAILS_GA_EVENTS , DA_APP_DETAILS_GA_EVENTS } from './constants'
58
58
import DeployedCommitCard from './DeployedCommitCard'
59
59
import DeploymentStatusCard from './DeploymentStatusCard'
60
60
import IssuesCard from './IssuesCard'
@@ -196,20 +196,23 @@ export const SourceInfo = ({
196
196
const renderAppDetailsCDButton = ( ) => {
197
197
const { buttonStyle, iconName } = getDeployButtonConfig ( deploymentUserActionState )
198
198
return (
199
- < AppDetailsCDButton
200
- { ...appDetailsCDButtonProps }
201
- gaEvent = {
202
- isAppView ? DA_APP_DETAILS_GA_EVENTS . DeployButtonClicked : AG_APP_DETAILS_GA_EVENTS . DeployButtonClicked
203
- }
204
- buttonProps = { {
205
- dataTestId : 'deploy-button' ,
206
- size : ComponentSizeType . medium ,
207
- text : 'Deploy' ,
208
- startIcon : < Icon name = { iconName } color = { null } /> ,
209
- style : buttonStyle ,
210
- } }
211
- />
212
- ) }
199
+ < AppDetailsCDButton
200
+ { ...appDetailsCDButtonProps }
201
+ gaEvent = {
202
+ isAppView
203
+ ? DA_APP_DETAILS_GA_EVENTS . DeployButtonClicked
204
+ : AG_APP_DETAILS_GA_EVENTS . DeployButtonClicked
205
+ }
206
+ buttonProps = { {
207
+ dataTestId : 'deploy-button' ,
208
+ size : ComponentSizeType . medium ,
209
+ text : 'Deploy' ,
210
+ startIcon : < Icon name = { iconName } color = { null } /> ,
211
+ style : buttonStyle ,
212
+ } }
213
+ />
214
+ )
215
+ }
213
216
214
217
const renderRollbackButton = ( isIcon ?: boolean ) => (
215
218
< AppDetailsCDButton
@@ -243,7 +246,7 @@ export const SourceInfo = ({
243
246
: ''
244
247
245
248
return (
246
- < div className = "flex left w-100" >
249
+ < div className = "flex left w-100 h-40 " >
247
250
< AppEnvSelector { ...( isAppView ? { isAppView, environments } : { isAppView : false , applications } ) } />
248
251
{ appDetails ?. deploymentAppType && (
249
252
< Tooltip
@@ -338,8 +341,16 @@ export const SourceInfo = ({
338
341
style = { ButtonStyleType . neutral }
339
342
showTooltip = { isApprovalConfigured }
340
343
tooltipProps = { {
341
- content :
342
- 'Application deployment requiring approval cannot be hibernated.' ,
344
+ content : (
345
+ < div className = "flexbox-col" >
346
+ < span className = "fw-6" >
347
+ Cannot { isHibernated ? 'unhibernate' : 'hibernate' }
348
+ </ span >
349
+ < span className = "fw-4 dc__word-break" >
350
+ { ACTION_DISABLED_TEXT }
351
+ </ span >
352
+ </ div >
353
+ ) ,
343
354
placement : 'bottom' ,
344
355
} }
345
356
ariaLabel = { isHibernated ? 'Unhibernate' : 'Hibernate' }
@@ -361,12 +372,19 @@ export const SourceInfo = ({
361
372
style = { ButtonStyleType . neutral }
362
373
showTooltip
363
374
tooltipProps = { {
364
- content : isApprovalConfigured
365
- ? 'Application deployment requiring approval cannot be hibernated.'
366
- : 'Restart workloads' ,
375
+ content : isApprovalConfigured ? (
376
+ < div className = "flexbox-col" >
377
+ < span className = "fw-6" > Cannot restart workloads</ span >
378
+ < span className = "fw-4 dc__word-break" >
379
+ { ACTION_DISABLED_TEXT }
380
+ </ span >
381
+ </ div >
382
+ ) : (
383
+ 'Restart workloads'
384
+ ) ,
367
385
placement : 'top' ,
368
386
} }
369
- ariaLabel = "rotate workloads"
387
+ ariaLabel = "restart workloads"
370
388
/>
371
389
) }
372
390
0 commit comments