Sha256: b9f7628d737b7f38a6a0eb96eb0e10e4d0e0455c12a67c097210e7bf35e548c2

Contents?: true

Size: 460 Bytes

Versions: 136

Compression:

Stored size: 460 Bytes

Contents

# frozen_string_literal: true

class Avo::SidebarComponent < ViewComponent::Base
  def initialize(sidebar_open: nil, for_mobile: false)
    @sidebar_open = sidebar_open
    @for_mobile = for_mobile
  end

  def dashboards
    Avo::App.dashboards_for_navigation
  end

  def resources
    Avo::App.resources_for_navigation
  end

  def tools
    Avo::App.tools_for_navigation
  end

  def stimulus_target
    @for_mobile ? "mobileSidebar" : "sidebar"
  end
end

Version data entries

136 entries across 136 versions & 1 rubygems

Version Path
avo-2.53.0 app/components/avo/sidebar_component.rb
avo-2.52.0 app/components/avo/sidebar_component.rb
avo-2.49.0 app/components/avo/sidebar_component.rb
avo-2.48.0 app/components/avo/sidebar_component.rb
avo-2.47.0 app/components/avo/sidebar_component.rb
avo-2.46.0 app/components/avo/sidebar_component.rb
avo-2.45.0 app/components/avo/sidebar_component.rb
avo-2.44.0 app/components/avo/sidebar_component.rb
avo-2.43.0 app/components/avo/sidebar_component.rb
avo-2.42.2 app/components/avo/sidebar_component.rb
avo-2.42.1 app/components/avo/sidebar_component.rb
avo-2.42.0 app/components/avo/sidebar_component.rb
avo-2.41.0 app/components/avo/sidebar_component.rb
avo-2.40.0 app/components/avo/sidebar_component.rb
avo-2.39.0 app/components/avo/sidebar_component.rb
avo-2.38.0 app/components/avo/sidebar_component.rb
avo-2.37.2 app/components/avo/sidebar_component.rb
avo-2.37.1 app/components/avo/sidebar_component.rb
avo-2.37.0 app/components/avo/sidebar_component.rb
avo-2.36.3 app/components/avo/sidebar_component.rb