Commit 959385be authored by Thomas Randolph's avatar Thomas Randolph Committed by Phil Hughes

Remove `autoExpandCollapsedDiffs` feature flag

parent 1e0ff62a
......@@ -94,11 +94,7 @@ export default {
},
'file.file_hash': {
handler: function watchFileHash() {
if (
this.glFeatures.autoExpandCollapsedDiffs &&
this.viewDiffsFileByFile &&
this.file.viewer.collapsed
) {
if (this.viewDiffsFileByFile && this.file.viewer.collapsed) {
this.isCollapsed = false;
this.handleLoadCollapsedDiff();
} else {
......@@ -108,7 +104,7 @@ export default {
immediate: true,
},
'file.viewer.collapsed': function setIsCollapsed(newVal) {
if (!this.viewDiffsFileByFile && !this.glFeatures.autoExpandCollapsedDiffs) {
if (!this.viewDiffsFileByFile) {
this.isCollapsed = newVal;
}
},
......
......@@ -34,7 +34,6 @@ class Projects::MergeRequestsController < Projects::MergeRequests::ApplicationCo
push_frontend_feature_flag(:multiline_comments, @project, default_enabled: true)
push_frontend_feature_flag(:file_identifier_hash)
push_frontend_feature_flag(:batch_suggestions, @project, default_enabled: true)
push_frontend_feature_flag(:auto_expand_collapsed_diffs, @project, default_enabled: true)
push_frontend_feature_flag(:approvals_commented_by, @project, default_enabled: true)
push_frontend_feature_flag(:hide_jump_to_next_unresolved_in_threads, default_enabled: true)
push_frontend_feature_flag(:merge_request_widget_graphql, @project)
......
---
title: Fix issue causing 'Expand All' button to not work in MR diffs view (Remove `autoExpandCollapsedDiffs` feature flag)
merge_request: 40960
author:
type: fixed
......@@ -128,26 +128,6 @@ describe('DiffFile', () => {
});
});
it('should auto-expand collapsed files when viewDiffsFileByFile is true', done => {
vm.$destroy();
window.gon = {
features: { autoExpandCollapsedDiffs: true },
};
vm = createComponentWithStore(Vue.extend(DiffFileComponent), createStore(), {
file: JSON.parse(JSON.stringify(diffFileMockDataUnreadable)),
canCurrentUserFork: false,
viewDiffsFileByFile: true,
}).$mount();
vm.$nextTick(() => {
expect(vm.$el.innerText).not.toContain('This diff is collapsed');
window.gon = {};
done();
});
});
it('should be collapsed for renamed files', done => {
vm.renderIt = true;
vm.isCollapsed = false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment