Module: Card::Set::Abstract::AccountDropdown::HtmlFormat

Extended by:
Card::Set::AbstractFormat
Defined in:
platypus/tmp/set/gem-defaults/mod031-layout/abstract/account_dropdown.rb

Instance Method Summary collapse

Instance Method Details

#account_dropdown(&render_role_item) ⇒ Object



14
15
16
17
18
19
20
21
22
# File 'platypus/tmp/set/gem-defaults/mod031-layout/abstract/account_dropdown.rb', line 14

def  &render_role_item
  class_up "dropdown-toggle-split", "nav-link"
  split_dropdown_button link_to_mycard do
    [
      [[Auth.current, :account_settings], "Account"],
      [:signin, t("account_sign_out"), { path: { action: :delete } }]
    ] + (&render_role_item)
  end
end


9
10
11
12
# File 'platypus/tmp/set/gem-defaults/mod031-layout/abstract/account_dropdown.rb', line 9

def link_to_mycard
  link_to_card Auth.current.name, nil,
               id: "my-card-link", class: "nav-link #{classy('my-card')}"
end