Skip to content

Commit

Permalink
chores: improve the msg to user when deleteing the resource
Browse files Browse the repository at this point in the history
Signed-off-by: ashutosh16 <11219262+ashutosh16@users.noreply.github.com>
  • Loading branch information
ashutosh16 committed Apr 4, 2024
1 parent f3dde8b commit 4d6e66c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions ui/src/app/applications/components/utils.tsx
Expand Up @@ -70,6 +70,9 @@ export async function deleteApplication(appName: string, appNamespace: string, a
<div>
<p>
Are you sure you want to delete the application <kbd>{appName}</kbd>?
<span style={{display: 'block', marginBottom: '10px'}} />
Deleting the application in <kbd>foreground</kbd> or <kbd>background</kbd> mode will delete all the application's managed resources, which can be{' '}
<strong>dangerous</strong>. Be sure you understand the effects of deleting this resource before continuing. Consider asking someone to review the change first.
</p>
<div className='argo-form-row'>
<FormField
Expand Down Expand Up @@ -300,6 +303,9 @@ export const deletePodAction = async (pod: appModels.Pod, appContext: AppContext
<div>
<p>
Are you sure you want to delete Pod <kbd>{pod.name}</kbd>?
<span style={{display: 'block', marginBottom: '10px'}} />
Deleting resources can be <strong>dangerous</strong>. Be sure you understand the effects of deleting this resource before continuing. Consider asking someone to
review the change first.
</p>
<div className='argo-form-row' style={{paddingLeft: '30px'}}>
<CheckboxField id='force-delete-checkbox' field='force'>
Expand Down Expand Up @@ -343,7 +349,11 @@ export const deletePopup = async (ctx: ContextApis, resource: ResourceTreeNode,
<div>
<p>
Are you sure you want to delete {resource.kind} <kbd>{resource.name}</kbd>?
<span style={{display: 'block', marginBottom: '10px'}} />
Deleting resources can be <strong>dangerous</strong>. Be sure you understand the effects of deleting this resource before continuing. Consider asking someone to
review the change first.
</p>

{isManaged ? (
<div className='argo-form-row'>
<FormField label={`Please type '${resource.name}' to confirm the deletion of the resource`} formApi={api} field='resourceName' component={Text} />
Expand Down

0 comments on commit 4d6e66c

Please sign in to comment.