Skip to content
代码片段 群组 项目
提交 c2b836e7 编辑于 作者: Jacques's avatar Jacques
浏览文件

Remove unused feature flag

Removes the unused source editor FF + associated code

Changelog: removed
上级 1e062bac
No related branches found
No related tags found
2 合并请求!3031Merge per-main-jh to main-jh by luzhiyuan,!3030Merge per-main-jh to main-jh
......@@ -19,21 +19,17 @@
- input_options = { label: _('File name'), id: 'file_name', name: 'file_name', value: params[:file_name] || '', required: true, placeholder: "Filename", testid: 'file-name-field', class: 'new-file-name js-file-path-name-input' }
= render 'filepath_form', input_options: input_options
- if Feature.enabled?(:source_editor_toolbar, current_user)
#editor-toolbar
- else
.file-buttons.gl-flex.gl-items-center.gl-justify-end
- if is_markdown
.md-header.gl-flex.gl-px-2.gl-rounded-base.gl-mx-2.gl-mt-2
.gl-flex.gl-items-center.gl-flex-wrap.gl-justify-between
.md-header-toolbar.gl-flex.gl-py-2.gl-flex-wrap{ class: "!gl-m-0" }
= render 'shared/blob/markdown_buttons', supports_file_upload: false
%span.soft-wrap-toggle
= render Pajamas::ButtonComponent.new(icon: 'soft-unwrap', button_options: { class: 'no-wrap' }) do
= _("No wrap")
= render Pajamas::ButtonComponent.new(icon: 'soft-wrap', button_options: { class: 'soft-wrap' }) do
= _("Soft wrap")
.file-buttons.gl-flex.gl-items-center.gl-justify-end
- if is_markdown
.md-header.gl-flex.gl-px-2.gl-rounded-base.gl-mx-2.gl-mt-2
.gl-flex.gl-items-center.gl-flex-wrap.gl-justify-between
.md-header-toolbar.gl-flex.gl-py-2.gl-flex-wrap{ class: "!gl-m-0" }
= render 'shared/blob/markdown_buttons', supports_file_upload: false
%span.soft-wrap-toggle
= render Pajamas::ButtonComponent.new(icon: 'soft-unwrap', button_options: { class: 'no-wrap' }) do
= _("No wrap")
= render Pajamas::ButtonComponent.new(icon: 'soft-wrap', button_options: { class: 'soft-wrap' }) do
= _("Soft wrap")
.file-editor.code
.js-edit-mode-pane#editor{ data: { 'editor-loading': true, testid: 'source-editor-preview-container', ref: ref} }<
......
---
name: source_editor_toolbar
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/82304
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/354748
milestone: '14.9'
type: development
group: group::source code
default_enabled: false
......@@ -81,7 +81,6 @@ def add_gon_variables
# Initialize gon.features with any flags that should be
# made globally available to the frontend
push_frontend_feature_flag(:source_editor_toolbar)
push_frontend_feature_flag(:vscode_web_ide, current_user)
push_frontend_feature_flag(:ui_for_organizations, current_user)
push_frontend_feature_flag(:organization_switching, current_user)
......
......@@ -107,13 +107,7 @@ def has_toolbar_buttons
end
end
it "has defined set of toolbar buttons when the flag is on" do
stub_feature_flags(source_editor_toolbar: true)
has_toolbar_buttons
end
it "has defined set of toolbar buttons when the flag is off" do
stub_feature_flags(source_editor_toolbar: false)
it "has defined set of toolbar buttons" do
has_toolbar_buttons
end
end
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册