Class: Shadcn::MenubarLabelComponent
- Inherits:
-
BaseComponent
- Object
- ViewComponent::Base
- BaseComponent
- Shadcn::MenubarLabelComponent
- Defined in:
- app/components/shadcn/menubar_label_component.rb
Overview
Menubar Label component Label for grouping menu items
Constant Summary collapse
- BASE_CLASSES =
"px-2 py-1.5 text-sm font-semibold"
Instance Attribute Summary
Attributes inherited from BaseComponent
#class_name, #data, #html_options
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(inset: false, **options, &block) ⇒ MenubarLabelComponent
constructor
A new instance of MenubarLabelComponent.
Methods inherited from BaseComponent
Methods included from Rails::Helpers::ClassNameHelper
Constructor Details
#initialize(inset: false, **options, &block) ⇒ MenubarLabelComponent
Returns a new instance of MenubarLabelComponent.
10 11 12 13 |
# File 'app/components/shadcn/menubar_label_component.rb', line 10 def initialize(inset: false, **, &block) super(**, &block) @inset = inset end |
Instance Method Details
#call ⇒ Object
15 16 17 |
# File 'app/components/shadcn/menubar_label_component.rb', line 15 def call content_tag(:div, content, label_attributes) end |