mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Change button labels and color in delete confirmation dialog for all objects to improve UX. #6513
This commit is contained in:
@@ -525,7 +525,7 @@ define('pgadmin.browser.node', [
|
||||
title = gettext('Delete FORCE %s?', obj.label);
|
||||
|
||||
} else if (input.url == 'delete') {
|
||||
msg = gettext('Are you sure you want to delete %s <b>"%s"</b> and all the objects that depend on it?',
|
||||
msg = gettext('Are you sure you want to delete the %s <b>"%s"</b> and all the objects that depend on it?',
|
||||
obj.label.toLowerCase(), d.label);
|
||||
title = gettext('Delete CASCADE %s?', obj.label);
|
||||
|
||||
@@ -539,10 +539,10 @@ define('pgadmin.browser.node', [
|
||||
}
|
||||
} else {
|
||||
if (obj.dropAsRemove) {
|
||||
msg = gettext('Are you sure you want to remove %s "%s"?', obj.label.toLowerCase(), d.label);
|
||||
msg = gettext('Are you sure you want to remove the %s <b>"%s"</b>?', obj.label.toLowerCase(), d.label);
|
||||
title = gettext('Remove %s?', obj.label);
|
||||
} else {
|
||||
msg = gettext('Are you sure you want to delete %s <b>"%s"</b>?', obj.label.toLowerCase(), d.label);
|
||||
msg = gettext('Are you sure you want to delete the %s <b>"%s"</b>?', obj.label.toLowerCase(), d.label);
|
||||
title = gettext('Delete %s?', obj.label);
|
||||
}
|
||||
|
||||
@@ -555,7 +555,7 @@ define('pgadmin.browser.node', [
|
||||
return;
|
||||
}
|
||||
}
|
||||
pgAdmin.Browser.notifier.confirm(title, msg,
|
||||
pgAdmin.Browser.notifier.confirmDelete(title, msg,
|
||||
function() {
|
||||
getApiInstance().delete(
|
||||
obj.generate_url(i, input.url, d, true),
|
||||
@@ -592,7 +592,10 @@ define('pgadmin.browser.node', [
|
||||
}
|
||||
pgAdmin.Browser.notifier.alert(gettext('Error dropping/removing %s: "%s"', obj.label, objName), errmsg);
|
||||
});
|
||||
}
|
||||
},
|
||||
() => {},
|
||||
gettext('Delete'),
|
||||
gettext('Cancel'),
|
||||
);
|
||||
},
|
||||
// Callback for creating script(s) & opening them in Query editor
|
||||
|
||||
Reference in New Issue
Block a user