Sha256: 6329de84c9e7d0f4951a90f3f9882c9c79e67cfc1d25a4a2c5036de57618576e

Contents?: true

Size: 374 Bytes

Versions: 130

Compression:

Stored size: 374 Bytes

Contents

# frozen_string_literal: true

module NfgUi
  module Components
    module Utilities
      # Allows NFG design system components to utilize the :title option
      module Titleable
        def title
          options.fetch(:title, nil)
        end

        private

        def non_html_attribute_options
          super.push(:title)
        end
      end
    end
  end
end

Version data entries

130 entries across 130 versions & 1 rubygems

Version Path
nfg_ui-0.12.12 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.11 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.10 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.9 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.8 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.7 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.6 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.5 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.4 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.3 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.2 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.1 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0.5 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0.4 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0.3 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0.2 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0.1 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.12.0 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.11.18 lib/nfg_ui/components/utilities/titleable.rb
nfg_ui-0.11.17 lib/nfg_ui/components/utilities/titleable.rb