Module: Card::Set::Type::LinkList::HtmlFormat

Extended by:
AbstractFormat
Defined in:
platypus/tmp/set/gem-defaults/mod005-list/type/link_list.rb

Instance Method Summary collapse

Instance Method Details

#input_typeObject



30
31
32
# File 'platypus/tmp/set/gem-defaults/mod005-list/type/link_list.rb', line 30

def input_type
  :link_list
end

#items_for_input(items = nil) ⇒ Object



38
39
40
41
# File 'platypus/tmp/set/gem-defaults/mod005-list/type/link_list.rb', line 38

def items_for_input items=nil
  items ||= card.item_names context: :raw
  items.empty? ? [["", ""]] : items.zip(card.item_titles(false))
end


43
44
45
46
47
48
49
50
# File 'platypus/tmp/set/gem-defaults/mod005-list/type/link_list.rb', line 43

def link_list_input args={}
  items = items_for_input args[:item_list]
  extra_class = "pointer-link-list-ul"
  ul_classes = classy "pointer-list-editor", extra_class
  haml :link_list_input,
       items: items, ul_classes: ul_classes,
       options_card: :all.card # options_card_name
end

#view: inputObject



34
35
36
# File 'platypus/tmp/set/gem-defaults/mod005-list/type/link_list.rb', line 34

view :input, cache: :never do
  _render_hidden_content_field + super()
end