Sha256: 9fd6f421f544ac610cfe264bbbef673cf62faf361bfb48f53f70b7e85474f820
Contents?: true
Size: 582 Bytes
Versions: 13
Compression:
Stored size: 582 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 return [] unless defined?(AvoDashboards) AvoDashboards.dashboard_manager.dashboards_for_navigation end def resources Avo::Current.app.resource_manager.resources_for_navigation helpers._current_user end def tools Avo::App.tools.tools_for_navigation end def stimulus_target @for_mobile ? "mobileSidebar" : "sidebar" end end
Version data entries
13 entries across 13 versions & 1 rubygems