File: header_component.rb

package info (click to toggle)
ruby-view-component 2.74.1-1
  • links: PTS, VCS
  • area: contrib
  • in suites: bookworm
  • size: 3,156 kB
  • sloc: ruby: 6,731; sh: 163; javascript: 10; makefile: 4
file content (13 lines) | stat: -rw-r--r-- 361 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
# frozen_string_literal: true

module NestedSharedState
  class HeaderComponent < ViewComponent::Base
    renders_many :cells, NestedSharedState::CellComponent

    def initialize(selectable: false, class_names: "table__header", **kwargs)
      @selectable = selectable
      @tag_arguments = kwargs
      @tag_arguments[:class] = class_names
    end
  end
end