From ea1954f27e30f51ff9e8765c9cf19beb8e963230 Mon Sep 17 00:00:00 2001 From: atty57 <99388680+atty57@users.noreply.github.com> Date: Mon, 28 Sep 2026 11:43:11 -0400 Subject: [PATCH] Show remove-duplicate button to non-admins as disabled The button that removes a testcase's duplicate status was wrapped in a dom-if on info.is_admin, so non-admins saw nothing at all and had no way to tell the functionality existed. Render it unconditionally and disable it for non-admins instead, using the existing disabled$ idiom. The tooltip moves onto a wrapping span so it describes the action as admin-only for admins and non-admins alike: paper-icon-button sets pointer-events: none while disabled, so a title on the button itself would never surface for the readers who most need it. Server-side enforcement is unchanged; remove_duplicate.Handler.post still requires check_admin_access. Addresses #5452. --- .../private/components/testcase-detail/testcase-detail.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/appengine/private/components/testcase-detail/testcase-detail.html b/src/appengine/private/components/testcase-detail/testcase-detail.html index e2c7d4a995e..e2ed6331ff4 100644 --- a/src/appengine/private/components/testcase-detail/testcase-detail.html +++ b/src/appengine/private/components/testcase-detail/testcase-detail.html @@ -435,9 +435,9 @@ Duplicate of testcase [[info.testcase.duplicate_of]] - + + +