Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upcoming: [M3-7530] - Restrict proxy users from updating username/email #10103

Merged
merged 8 commits into from
Jan 29, 2024

Conversation

jaalah-akamai
Copy link
Contributor

Description 📝

As a parent user logged into a proxy account, I should not be able to change the email address or username set by the provisioning API.

Changes 🔄

  • Fixed alignment of input fields and buttons at /profile/display page.
  • Added unit tests for disabling Username and Email
  • As proxy user: added tooltip text to buttons to disabled buttons for context

Preview 📷

Before After
Screenshot 2024-01-23 at 10 41 23 PM Screenshot 2024-01-23 at 10 51 06 PM

How to test 🧪

Prerequisites

  • Turn on MSW and Parent/Child feature flag
  • Set user_type to proxy in serverHandlers

Reproduction steps

Verification steps

  • Observe disabled fields
  • Change user_type to something else, observe fields are editable

As an Author I have considered 🤔

Check all that apply

  • 👀 Doing a self review
  • ❔ Our contribution guidelines
  • 🤏 Splitting feature into small PRs
  • ➕ Adding a changeset
  • 🧪 Providing/Improving test coverage
  • 🔐 Removing all sensitive information from the code and PR description
  • 🚩 Using a feature flag to protect the release
  • 👣 Providing comprehensive reproduction steps
  • 📑 Providing or updating our documentation
  • 🕛 Scheduling a pair reviewing session
  • 📱 Providing mobile support
  • ♿ Providing accessibility support

@jaalah-akamai jaalah-akamai self-assigned this Jan 24, 2024
@jaalah-akamai jaalah-akamai requested a review from a team as a code owner January 24, 2024 03:58
@jaalah-akamai jaalah-akamai requested review from mjac0bs and carrillo-erik and removed request for a team January 24, 2024 03:58
Copy link

github-actions bot commented Jan 24, 2024

Coverage Report:
Base Coverage: 80.33%
Current Coverage: 80.33%

Copy link
Contributor

@jdamore-linode jdamore-linode left a comment

Choose a reason for hiding this comment

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

Looks good @jaalah-akamai! Confirmed fields/buttons are disabled when user_type is proxy, and that the field/buttons behave as expected for other user_types.

Copy link
Contributor

@mjac0bs mjac0bs left a comment

Choose a reason for hiding this comment

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

Confirmed that the only a proxy user does see disabled text fields and buttons with a tooltip for username and email. Approving pending a styling regression fix and some small unit test additions.

Thanks for aligning the buttons with the textfields too. When I checked for any styling regressions at various screen sizes, the only thing I found was the smaller width of the textfields, which I don't think was an intended change.

We could improve test coverage just slightly with the suggestions Joe and I left there.

@mjac0bs mjac0bs added the Approved Multiple approvals and ready to merge! label Jan 24, 2024
@jaalah-akamai jaalah-akamai merged commit 61f95ba into linode:develop Jan 29, 2024
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Approved Multiple approvals and ready to merge! Parent / Child Account
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants