Class: PhlexKit::BreadcrumbSeparator

Inherits:
BaseComponent show all
Defined in:
app/components/phlex_kit/breadcrumb/breadcrumb_separator.rb

Instance Method Summary collapse

Methods inherited from BaseComponent

#on

Constructor Details

#initialize(**attrs) ⇒ BreadcrumbSeparator

Returns a new instance of BreadcrumbSeparator.



3
# File 'app/components/phlex_kit/breadcrumb/breadcrumb_separator.rb', line 3

def initialize(**attrs) = (@attrs = attrs)

Instance Method Details

#view_template(&block) ⇒ Object



4
5
6
7
8
# File 'app/components/phlex_kit/breadcrumb/breadcrumb_separator.rb', line 4

def view_template(&block)
  li(**mix({ class: "pk-breadcrumb-separator", role: "presentation", aria: { hidden: true } }, @attrs)) do
    if block then yield else svg(xmlns: "http://www.w3.org/2000/svg", viewbox: "0 0 24 24", fill: "none", stroke: "currentColor", stroke_width: "2", stroke_linecap: "round", stroke_linejoin: "round") { |s| s.path(d: "m9 18 6-6-6-6") } end
  end
end