Module: Blot::Helpers::Visibility

Included in:
Blot::Helpers
Defined in:
lib/blot/helpers/visibility.rb

Instance Method Summary collapse

Instance Method Details

#hide_for_smallObject



16
17
18
19
20
21
22
23
24
# File 'lib/blot/helpers/visibility.rb', line 16

def hide_for_small
   :table, class: 'hide-for-small' do
     :tr do
       :td do
        yield if block_given?
      end
    end
  end
end

#show_for_smallObject



4
5
6
7
8
9
10
11
12
13
14
# File 'lib/blot/helpers/visibility.rb', line 4

def show_for_small
  ('<!--[if !mso]><!-- -->' +
  (:table, class: 'show-for-small') do
     :tr do
       :td do
        yield if block_given?
      end
    end
  end +
  '<!--<![endif]-->').html_safe
end