diff --git a/app/assets/javascripts/diffs/components/diff_file.vue b/app/assets/javascripts/diffs/components/diff_file.vue index 933891d698cc7f9202223d97fb66f199d1816df5..d09cc064b2c292446fa8ac8f2125296f1911c3c0 100644 --- a/app/assets/javascripts/diffs/components/diff_file.vue +++ b/app/assets/javascripts/diffs/components/diff_file.vue @@ -170,10 +170,7 @@ export default { return !this.isCollapsed && !this.isFileTooLarge; }, showLocalFileReviews() { - const loggedIn = Boolean(gon.current_user_id); - const featureOn = this.glFeatures.localFileReviews; - - return loggedIn && featureOn; + return Boolean(gon.current_user_id); }, codequalityDiffForFile() { return this.codequalityDiff?.files?.[this.file.file_path] || []; diff --git a/app/controllers/projects/merge_requests_controller.rb b/app/controllers/projects/merge_requests_controller.rb index 9dac240f2817c789ef7f8213d62435e316706fb2..ef2c5bda940ef7dfa2ff5543bb6e4c12ad06177f 100644 --- a/app/controllers/projects/merge_requests_controller.rb +++ b/app/controllers/projects/merge_requests_controller.rb @@ -35,7 +35,6 @@ class Projects::MergeRequestsController < Projects::MergeRequests::ApplicationCo push_frontend_feature_flag(:merge_request_widget_graphql, @project, default_enabled: :yaml) push_frontend_feature_flag(:default_merge_ref_for_diffs, @project, default_enabled: :yaml) push_frontend_feature_flag(:core_security_mr_widget_counts, @project) - push_frontend_feature_flag(:local_file_reviews, default_enabled: :yaml) push_frontend_feature_flag(:paginated_notes, @project, default_enabled: :yaml) push_frontend_feature_flag(:confidential_notes, @project, default_enabled: :yaml) push_frontend_feature_flag(:usage_data_i_testing_summary_widget_total, @project, default_enabled: :yaml) diff --git a/config/feature_flags/development/local_file_reviews.yml b/config/feature_flags/development/local_file_reviews.yml deleted file mode 100644 index 4001f6ade729ceb8cc6b3a284e52d0f064dc3d88..0000000000000000000000000000000000000000 --- a/config/feature_flags/development/local_file_reviews.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -name: local_file_reviews -introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/51513 -rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/296674 -milestone: '13.9' -type: development -group: group::code review -default_enabled: true diff --git a/doc/user/project/merge_requests/changes.md b/doc/user/project/merge_requests/changes.md index c59d5973e21a75f3e7fe798163ed8528b0891f55..d348c00bdc2202c95446d4c75725ebb23a858a9c 100644 --- a/doc/user/project/merge_requests/changes.md +++ b/doc/user/project/merge_requests/changes.md @@ -97,11 +97,8 @@ a merge request. You can choose to hide or show whitespace changes: ## Mark files as viewed -> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/51513) in GitLab 13.9. -> - Deployed behind a feature flag, enabled by default. -> - Enabled on GitLab.com. -> - Recommended for production use. -> - For GitLab self-managed instances, GitLab administrators can opt to [disable it](#enable-or-disable-file-views). **(FREE SELF)** +> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/51513) in GitLab 13.9 behind a feature flag, enabled by default. +> - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/296674) in GitLab 14.3. When reviewing a merge request with many files multiple times, it may be useful to the reviewer to focus on new changes and ignore the files that they have already reviewed and don't want to @@ -116,25 +113,6 @@ To mark a file as viewed: Once checked, the file remains marked for that reviewer unless there are newly introduced changes to its content or the checkbox is unchecked. -### Enable or disable file views **(FREE SELF)** - -The file view feature is under development but ready for production use. -It is deployed behind a feature flag that is **enabled by default**. -[GitLab administrators with access to the GitLab Rails console](../../../administration/feature_flags.md) -can opt to enable it for your instance. - -To enable it: - -```ruby -Feature.enable(:local_file_reviews) -``` - -To disable it: - -```ruby -Feature.disable(:local_file_reviews) -``` - ## Show merge request conflicts in diff > - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/232484) in GitLab 13.5. diff --git a/spec/frontend/diffs/components/diff_file_spec.js b/spec/frontend/diffs/components/diff_file_spec.js index 3dec56f2fe3e358394389abcc5c6a41ac2c79bbd..feb7118744b1d60b9ef2f0bab3b42f034d352d9c 100644 --- a/spec/frontend/diffs/components/diff_file_spec.js +++ b/spec/frontend/diffs/components/diff_file_spec.js @@ -242,32 +242,20 @@ describe('DiffFile', () => { }); it.each` - loggedIn | featureOn | bool - ${true} | ${true} | ${true} - ${false} | ${true} | ${false} - ${true} | ${false} | ${false} - ${false} | ${false} | ${false} - `( - 'should be $bool when { userIsLoggedIn: $loggedIn, featureEnabled: $featureOn }', - ({ loggedIn, featureOn, bool }) => { - setLoggedIn(loggedIn); - - ({ wrapper } = createComponent({ - options: { - provide: { - glFeatures: { - localFileReviews: featureOn, - }, - }, - }, - props: { - file: store.state.diffs.diffFiles[0], - }, - })); + loggedIn | bool + ${true} | ${true} + ${false} | ${false} + `('should be $bool when { userIsLoggedIn: $loggedIn }', ({ loggedIn, bool }) => { + setLoggedIn(loggedIn); + + ({ wrapper } = createComponent({ + props: { + file: store.state.diffs.diffFiles[0], + }, + })); - expect(wrapper.vm.showLocalFileReviews).toBe(bool); - }, - ); + expect(wrapper.vm.showLocalFileReviews).toBe(bool); + }); }); });