Sha256: 927e311d87399347e4a9728ed0818dc310f2eca5e3a638afd2e87faaa43b506e

Contents?: true

Size: 776 Bytes

Versions: 20

Compression:

Stored size: 776 Bytes

Contents

# frozen_string_literal: true

module Primer
  module Alpha
    class Dialog
      # A `Dialog::Body` is a compositional component, used to render the
      # Body of a dialog. See <%= link_to_component(Primer::Alpha::Dialog) %>.
      class Body < Primer::Component
        # @param system_arguments [Hash] <%= link_to_system_arguments_docs %>
        def initialize(**system_arguments)
          @system_arguments = deny_tag_argument(**system_arguments)
          @system_arguments[:tag] = :div
          @system_arguments[:classes] = class_names(
            "Overlay-body",
            system_arguments[:classes]
          )
        end

        def call
          render(Primer::BaseComponent.new(**@system_arguments)) { content }
        end
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
primer_view_components-0.0.112 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.111 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.110 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.109 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.108 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.107 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.106 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.105 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.104 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.103 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.102 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.101 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.100 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.99 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.98 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.97 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.96 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.95 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.94 app/components/primer/alpha/dialog/body.rb
primer_view_components-0.0.93 app/components/primer/alpha/dialog/body.rb