Follow-up from "Edit Branch Rules: UI for Branch protection toggles"
<!--IssueSummary start-->
<details>
<summary>
Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards.
</summary>
- [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=463506)
</details>
<!--IssueSummary end-->
The following discussion from !153281 should be addressed:
- [ ] @psjakubowska started a [discussion](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/153281#note_1918809144): (+1 comment)
> @jerasmus I've realised we've guarded delete and edit actions behind a feature flag, but haven't introduced `canEdit` yet. I injected it for toggle, but I am right that I should follow-up with the MR that uses it for other editing option, right?
>
> I mean:
> - [deleting a rule](https://gitlab.com/gitlab-org/gitlab/-/blob/39c81cf20aa8b0decb415f46561555f78bb5804e/app/assets/javascripts/projects/settings/branch_rules/components/view/index.vue#L279)
> - [editing a custom rule pattern](https://gitlab.com/gitlab-org/gitlab/-/blob/39c81cf20aa8b0decb415f46561555f78bb5804e/app/assets/javascripts/projects/settings/branch_rules/components/view/index.vue#L300)
> - [is-edit-available on protection component](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/assets/javascripts/projects/settings/branch_rules/components/view/index.vue?ref_type=heads#L334)
> @psjakubowska if I remember correctly, `can_edit` is used for checking if a user can edit approval rules. It comes from [this helper](https://gitlab.com/gitlab-org/gitlab/-/blob/master/ee/app/helpers/ee/projects/settings/branch_rules_helper.rb#L25), so I don't think we should use it for the other edit actions.
> But now that you've bought it up, I can definitely see how the name of this property can be confusing :smile: Perhaps we should rename it to something more descriptive like `can_edit_approval_rules` :thinking: We can do this in a follow-up though.
issue