Replace close icon by icon font equivalent

pull/6827/head
Hagen Schink 11 years ago committed by Christian Ratz
parent d26de8b654
commit ad48672375
  1. 18
      lib/assets/stylesheets/reporting_engine/reporting.css.erb
  2. 3
      lib/widget/filters/remove_button.rb

@ -172,23 +172,23 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
margin-right: -2px; margin-right: -2px;
} }
.filter_rem { .filter_rem { }
color: transparent;
.icon-reporting-filter-rem {
background: #E6E6E6;
overflow: hidden; overflow: hidden;
cursor: pointer; cursor: pointer;
background: no-repeat center center transparent;
height: 18px; height: 18px;
width: 18px; width: 18px;
border-style: none;
display: block; display: block;
margin: 0 0 0 2px; margin: 0 0 0 2px;
} }
.icon-filter-rem { .icon-reporting-filter-rem:before {
background-image: url(<%= asset_path 'reporting_engine/close.gif' %>); padding: inherit;
position: relative; font-size: 12px;
float: right; vertical-align: text-top;
padding: 0px; margin-left: 3px;
} }
/***** icons *****/ /***** icons *****/

@ -25,8 +25,7 @@ class Widget::Filters::RemoveButton < Widget::Filters::Base
write(content_tag(:td, :width => "25px") do write(content_tag(:td, :width => "25px") do
hidden_field = tag :input, :id => "rm_#{filter_class.underscore_name}", hidden_field = tag :input, :id => "rm_#{filter_class.underscore_name}",
:name => "fields[]", :type => "hidden", :value => "" :name => "fields[]", :type => "hidden", :value => ""
button = tag :input, :type => "button", :value => "", button = icon_wrapper('icon icon-close icon-reporting-filter-rem filter_rem', l(:description_remove_filter))
:class => "icon filter_rem icon-filter-rem", :title => l(:description_remove_filter)
content_tag(:div, hidden_field + button, :id => "rm_box_#{filter_class.underscore_name}", :class => "remove-box") content_tag(:div, hidden_field + button, :id => "rm_box_#{filter_class.underscore_name}", :class => "remove-box")
end) end)
end end

Loading…
Cancel
Save