Class: Trestle::Toolbar::Dropdown
Instance Attribute Summary
Attributes inherited from Item
#menu
Instance Method Summary
collapse
Methods inherited from Button
#render
Methods inherited from Item
#==, #button_classes, #button_label, #button_style, #initialize, #render, #to_s
Instance Method Details
109
110
111
|
# File 'lib/trestle/toolbar/item.rb', line 109
def button_style_classes
super + ["dropdown-toggle"]
end
|
#label ⇒ Object
103
104
105
106
107
|
# File 'lib/trestle/toolbar/item.rb', line 103
def label
safe_join([
super, content_tag(:span, "", class: "caret")
], " ")
end
|
#options ⇒ Object
99
100
101
|
# File 'lib/trestle/toolbar/item.rb', line 99
def options
super.merge(type: "button", data: { bs_toggle: "dropdown" })
end
|
113
114
115
|
# File 'lib/trestle/toolbar/item.rb', line 113
def
[.render_items]
end
|