Sha256: fb9501c72a8f2beae368ca29c16d6965813eda9252b59ec15260724facf1ce0c

Contents?: true

Size: 536 Bytes

Versions: 211

Compression:

Stored size: 536 Bytes

Contents

# frozen_string_literal: true

require_relative "base"

module ERBLint
  module Linters
    module ArgumentMappers
      # Maps attributes in the clipboard-copy element to arguments for the ClipboardCopy component.
      class ClipboardCopy < Base
        DEFAULT_TAG = "clipboard-copy"
        ATTRIBUTES = %w[role tabindex for value id style].freeze

        def attribute_to_args(attribute)
          attr_name = attribute.name

          { attr_name.to_sym => erb_helper.convert(attribute) }
        end
      end
    end
  end
end

Version data entries

211 entries across 211 versions & 3 rubygems

Version Path
primer_view_components-0.30.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.39.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.39.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.38.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
primer_view_components-0.29.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
primer_view_components-0.28.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.37.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.37.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.36.2 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.36.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.36.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
primer_view_components-0.27.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.35.2 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.35.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
primer_view_components-0.26.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.35.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
primer_view_components-0.26.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.34.0 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.33.2 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb
openproject-primer_view_components-0.33.1 lib/primer/view_components/linters/argument_mappers/clipboard_copy.rb