Module: Klods::Utilities

Included in:
Builders
Defined in:
lib/klods/utilities.rb

Instance Method Summary collapse

Instance Method Details

#fill(a = nil, b = nil, &block) ⇒ Object



9
10
11
12
13
# File 'lib/klods/utilities.rb', line 9

def fill(a = nil, b = nil, &block)
  props, children = Core.normalize_args(a, b)
  children = klods_capture(&block) if block
  Core.build(tag: "div", base: "klods-fill", props: props, children: children)
end

#push(a = nil, b = nil, &block) ⇒ Object



3
4
5
6
7
# File 'lib/klods/utilities.rb', line 3

def push(a = nil, b = nil, &block)
  props, children = Core.normalize_args(a, b)
  children = klods_capture(&block) if block
  Core.build(tag: "span", base: "klods-push", props: props, children: children)
end