Class: RUI::Navigation::Top

Inherits:
Base
  • Object
show all
Defined in:
lib/rui/navigation/top.rb

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from RUI::Base

Instance Method Details

#groupObject



16
17
18
# File 'lib/rui/navigation/top.rb', line 16

def group(&)
  section(class: "flex flex-row items-center gap-3", &)
end

#view_templateObject



4
5
6
7
8
9
10
11
12
13
14
# File 'lib/rui/navigation/top.rb', line 4

def view_template(&)
  nav(id: "top-nav", class: "fixed top-0 left-0 right-0 bg-white flex flex-col z-30") do
    section(class: "flex flex-row items-center justify-between gap-3 border-b border-zinc-300 p-3 lg:px-10 min-h-16", &)
    section(class: "lg:hidden p-3 border-b border-zinc-300") do
      render RUI::Buttons::Ghost.new(
        icon: "menu",
        data: { action: "navigation#toggle" }
      )
    end
  end
end