Class: InnerPlan::Groups::ShowMenuComponent
- Inherits:
-
Phlex::HTML
- Object
- Phlex::HTML
- InnerPlan::Groups::ShowMenuComponent
- Includes:
- Phlex::Rails::Helpers::LinkTo
- Defined in:
- app/components/inner_plan/groups/show_menu_component.rb
Instance Method Summary collapse
-
#initialize(group) ⇒ ShowMenuComponent
constructor
A new instance of ShowMenuComponent.
- #template ⇒ Object
Constructor Details
#initialize(group) ⇒ ShowMenuComponent
Returns a new instance of ShowMenuComponent.
5 6 7 |
# File 'app/components/inner_plan/groups/show_menu_component.rb', line 5 def initialize(group) @group = group end |
Instance Method Details
#template ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'app/components/inner_plan/groups/show_menu_component.rb', line 9 def template div(class: "dropdown") { (class: "btn btn-link text-reset p-0 opacity-50", data_bs_toggle: "dropdown") { render(Phlex::Icons::Tabler::DotsCircleHorizontal.new(width: 35, height: 35)) } ul(class: "dropdown-menu dropdown-menu-end") { li { link_to(helpers.edit_group_path(@group), class: 'dropdown-item d-flex align-items-center gap-2', data: { turbo_frame: :_top }) { render(Phlex::Icons::Tabler::Pencil.new(width: 18, height: 18, class: 'text-secondary')) span { "Edit group" } } } } } end |