Commit 789faf30 authored by Marvin Karegyeya's avatar Marvin Karegyeya Committed by Ezekiel Kigbo

Resolve Migrate '.fa-spinner' to '.spinner' for 'app/helpers'

parent 8a152be0
...@@ -129,8 +129,7 @@ module DropdownsHelper ...@@ -129,8 +129,7 @@ module DropdownsHelper
end end
def dropdown_loading def dropdown_loading
content_tag :div, class: "dropdown-loading" do spinner = loading_icon(container: true, size: "md", css_class: "gl-mt-7")
icon('spinner spin') content_tag(:div, spinner, class: "dropdown-loading")
end
end end
end end
...@@ -89,15 +89,6 @@ module IconsHelper ...@@ -89,15 +89,6 @@ module IconsHelper
sprite_icon(name, css_class: css_class) sprite_icon(name, css_class: css_class)
end end
def spinner(text = nil, visible = false)
css_class = ['loading']
css_class << 'hide' unless visible
content_tag :div, class: css_class.join(' ') do
icon('spinner spin') + text
end
end
def boolean_to_icon(value) def boolean_to_icon(value)
if value if value
sprite_icon('check', css_class: 'cgreen') sprite_icon('check', css_class: 'cgreen')
......
...@@ -35,13 +35,6 @@ module ServicesHelper ...@@ -35,13 +35,6 @@ module ServicesHelper
"#{event}_events" "#{event}_events"
end end
def service_save_button(disabled: false)
button_tag(class: 'btn btn-success', type: 'submit', disabled: disabled, data: { qa_selector: 'save_changes_button' }) do
icon('spinner spin', class: 'hidden js-btn-spinner') +
content_tag(:span, 'Save changes', class: 'js-btn-label')
end
end
def scoped_integrations_path def scoped_integrations_path
if @project.present? if @project.present?
project_settings_integrations_path(@project) project_settings_integrations_path(@project)
......
...@@ -34,4 +34,5 @@ ...@@ -34,4 +34,5 @@
%div{ id: dom_id(@project) } %div{ id: dom_id(@project) }
%ol#commits-list.list-unstyled.content_list %ol#commits-list.list-unstyled.content_list
= render 'commits', project: @project, ref: @ref = render 'commits', project: @project, ref: @ref
= spinner .loading.hide
= loading_icon(size: "lg")
---
title: Migrate .fa-spinner to .spinner for app/helpers
merge_request: 25033
author: nuwe1
type: other
...@@ -246,8 +246,8 @@ RSpec.describe DropdownsHelper do ...@@ -246,8 +246,8 @@ RSpec.describe DropdownsHelper do
expect(content).to include('dropdown-loading') expect(content).to include('dropdown-loading')
end end
it 'returns an icon in the content' do it 'returns a gl-spinner in the content' do
expect(content.scan('icon').count).to eq(1) expect(content).to include('gl-spinner')
end end
end end
end end
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