Method: PublishMyData::StripesHelper#section_title

Defined in:
app/helpers/publish_my_data/stripes_helper.rb

#section_title(text, show_icon = true) ⇒ Object



80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
# File 'app/helpers/publish_my_data/stripes_helper.rb', line 80

def section_title(text, show_icon = true)
  if (show_icon)
    linkname = to_css_name(text)
     :h2 do
      str = link_to ("#" + linkname).to_s, {id: linkname, class: 'pmd_bookmarkable', title: 'permalink to this section'} do
         :i, class: 'icon-bookmark' do
        end
      end
      str += text
      str
    end
  else
     :h2 do
      text
    end

  end
end