Class: Primer::SubheadComponent::Description

Inherits:
ViewComponent::Slot
  • Object
show all
Includes:
ClassNameHelper
Defined in:
app/components/primer/subhead_component.rb

Overview

:nodoc:

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from ClassNameHelper

#class_names

Constructor Details

#initialize(**system_arguments) ⇒ Description

Returns a new instance of Description.

Parameters:

  • system_arguments (Hash)

    <%= link_to_system_arguments_docs %>



110
111
112
113
114
# File 'app/components/primer/subhead_component.rb', line 110

def initialize(**system_arguments)
  @system_arguments = system_arguments
  @system_arguments[:tag] = :div
  @system_arguments[:classes] = class_names(@system_arguments[:classes], "Subhead-description")
end

Instance Attribute Details

#system_argumentsObject (readonly)

Returns the value of attribute system_arguments.



107
108
109
# File 'app/components/primer/subhead_component.rb', line 107

def system_arguments
  @system_arguments
end