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

chore: improve UPDATE_FEATURE_STATE permission in UI #2986

Merged

Conversation

novakzaballa
Copy link
Contributor

Thanks for submitting a PR! Please check the boxes below:

  • I have run pre-commit to check linting
  • I have filled in the "Changes" section below?
  • I have filled in the "How did you test this code" section below?
  • I have used a Conventional Commit title for this Pull Request

Changes

  • The "Update segment override" button is no longer affected by UPDATE_FEATURE_STATE permission

How did you test this code?

  • Give and remove UPDATE_FEATURE_STATE permission in the environment setting page
  • If you have permission you can modify the feature flag.
  • Having or not having permission does not affect the "segment" overrides tab

Copy link

vercel bot commented Nov 16, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 17, 2023 3:20pm
flagsmith-frontend-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 17, 2023 3:20pm
flagsmith-frontend-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 17, 2023 3:20pm

@novakzaballa novakzaballa requested review from a team and kyle-ssg and removed request for a team November 16, 2023 18:37
@github-actions github-actions bot added the front-end Issue related to the React Front End Dashboard label Nov 16, 2023
Copy link
Contributor

github-actions bot commented Nov 16, 2023

Uffizzi Preview deployment-40924 was deleted.

@matthewelwell
Copy link
Contributor

image

Looks like there's something on the API preventing it still @zachaysan

@matthewelwell
Copy link
Contributor

matthewelwell commented Nov 17, 2023

I've fixed the above in #2990.

There is one minor FE tweak that I've noticed which would be good to resolve which is that the tooltip which comes up on hover on the feature row is kind of misleading now.

image

I have a feeling this has been misleading since we allowed users to view the feature slide out, but it's a good time to resolve it here I think @novakzaballa.

I think we can just remove the tooltip altogether here.

@matthewelwell
Copy link
Contributor

I've removed the tooltip here

matthewelwell
matthewelwell previously approved these changes Nov 17, 2023
@matthewelwell matthewelwell dismissed their stale review November 17, 2023 13:37

Changes should be wrapped in the relevant feature flag.

Comment on lines +1218 to +1241
<Permission
level='environment'
permission={Utils.getManageFeaturePermission(
is4Eyes,
identity,
)}
id={this.props.environmentId}
>
{({
permission: savePermission,
}) => (
<Permission
level='environment'
permission={
'MANAGE_SEGMENT_OVERRIDES'
}
id={
this.props.environmentId
}
>
{({
permission:
manageSegmentsOverrides,
}) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't quite understand what this code is doing but I have tested it functionally and it seems to behave how I expect!

@novakzaballa novakzaballa added this pull request to the merge queue Nov 17, 2023
Merged via the queue into main with commit 13e57fa Nov 17, 2023
@novakzaballa novakzaballa deleted the chore/improve-update-feature-state-permission-in-ui branch November 17, 2023 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
front-end Issue related to the React Front End Dashboard
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants