Module: Practical::Helpers::IconHelper

Includes:
Views::ElementHelper
Defined in:
lib/practical/helpers/icon_helper.rb

Instance Method Summary collapse

Methods included from Views::ElementHelper

#grab, #mix

Instance Method Details

#icon_setObject



6
7
8
# File 'lib/practical/helpers/icon_helper.rb', line 6

def icon_set
  ApplicationIconSet
end

#icon_text(icon:, text:, options: {}) ⇒ Object



10
11
12
13
14
15
16
17
# File 'lib/practical/helpers/icon_helper.rb', line 10

def icon_text(icon:, text:, options: {})
  tag.span(**mix({class: "wa-flank wa-gap-xs icon-text"}, options)) {
    safe_join([
      (render icon),
      tag.span(text)
    ])
  }
end