Skip to content

Conversation

@ZedLi
Copy link
Collaborator

@ZedLi ZedLi commented Dec 19, 2025

Description

Added grant templates which are suggestions that are currently completely static data and can be used as a base for writing grants for users.

Screenshots (if appropriate)

Screen.Recording.2025-12-19.at.3.24.46.PM.mov

How to Test

Go to the roles page and try using the add grant templates action.

Checklist

  • I have added before and after screenshots for UI changes
  • [ ] I have added JSON response output for API changes
  • [ ] I have added steps to reproduce and test for bug fixes in the description
  • I have commented on my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I have added a11y-tests label to run a11y audit tests if needed

PCI review checklist

  • I have documented a clear reason for, and description of, the change I am making.
  • If applicable, I've documented a plan to revert these changes if they require more than reverting the pull request.
  • If applicable, I've documented the impact of any changes to security controls.
    Examples of changes to security controls include using new access control methods, adding or removing logging pipelines, etc.

@ZedLi ZedLi self-assigned this Dec 19, 2025
@ZedLi ZedLi requested a review from a team as a code owner December 19, 2025 20:53
@vercel
Copy link

vercel bot commented Dec 19, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
boundary-ui Ready Ready Preview, Comment Jan 22, 2026 0:05am
boundary-ui-desktop Ready Ready Preview, Comment Jan 22, 2026 0:05am

Request Review

hashicc
hashicc previously approved these changes Jan 21, 2026
Copy link
Collaborator

@hashicc hashicc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀 Looks great, two small comments on the tests

/>
<form.actions
@submitText={{t
'resources.role.grant-templates.actions.add-grant-templates'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would it make sense to move these action buttons to the top? Add principals does this, so wanted to check if we want to have the same for this route.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I saw that, from the designs we didn't want that and I think historically we only had those buttons on top because the table could be infinite. Realistically I think we eventually want to paginate these pages properly and move the buttons back below the table rather than having them on top.

}
}

.role-manage-custom-scopes-form {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed these because it seemed like these styles for manage scopes were re-applying some of the search-filtering styles (namely some of them were because the class was a level higher in the dom so the > div wasn't applying margins).

Let me know if there's any concern or anything I missed about these styles

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice refactor to combine the pattern! The visual diff looks the exact same to me

Copy link
Collaborator

@DhariniJeeva DhariniJeeva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great!

Copy link
Collaborator

@hashicc hashicc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks for the style refactor, too!

Copy link
Collaborator

@priya-patel04 priya-patel04 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks great!

Quick question around when a user adds an existing grant template - do we want to filter it out and not display in the UI to avoid jump when user clicks on Save button ?

Screen.Recording.2026-01-26.at.11.08.35.AM.mov

@priya-patel04
Copy link
Collaborator

Overall looks great!

Quick question around when a user adds an existing grant template - do we want to filter it out and not display in the UI to avoid jump when user clicks on Save button ?

Screen.Recording.2026-01-26.at.11.08.35.AM.mov

Ahh unless letting users add the same template is intentional to create variations

@ZedLi
Copy link
Collaborator Author

ZedLi commented Jan 26, 2026

Quick question around when a user adds an existing grant template - do we want to filter it out and not display in the UI to avoid jump when user clicks on Save button ?
Ahh unless letting users add the same template is intentional to create variations

If I'm understanding correctly, the question is filtering out any grants that are the same if they end up with the same ones when adding? If so, we're just adding exactly as they are. Since these are templates, if there's any existing ones it's up to the user to decide how they want to change the grants if at all.

}

/**
* Redirect to role grants as if nothing ever happened.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😆

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a11y-tests Runs our a11y tests when label added to PR addons admin ui

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants