Class: UI::CommandShortcut
- Inherits:
-
Phlex::HTML
- Object
- Phlex::HTML
- UI::CommandShortcut
- Includes:
- CommandShortcutBehavior
- Defined in:
- app/components/ui/command_shortcut.rb
Instance Method Summary collapse
-
#initialize(classes: "", **attributes) ⇒ CommandShortcut
constructor
A new instance of CommandShortcut.
- #view_template ⇒ Object
Methods included from CommandShortcutBehavior
#command_shortcut_classes, #command_shortcut_html_attributes
Constructor Details
#initialize(classes: "", **attributes) ⇒ CommandShortcut
Returns a new instance of CommandShortcut.
6 7 8 9 |
# File 'app/components/ui/command_shortcut.rb', line 6 def initialize(classes: "", **attributes) @classes = classes @attributes = attributes end |
Instance Method Details
#view_template ⇒ Object
11 12 13 |
# File 'app/components/ui/command_shortcut.rb', line 11 def view_template(&) span(**command_shortcut_html_attributes.deep_merge(@attributes), &) end |