Sha256: 635f4f9c7beeae94c523876b6272520572d8c6440afda7887b7f31ef31c9a1ed

Contents?: true

Size: 361 Bytes

Versions: 56

Compression:

Stored size: 361 Bytes

Contents

# frozen_string_literal: true

module Phlex
  module Icons
    class Base < Phlex::SVG
      attr_reader :attrs

      def initialize(**attrs)
        @attrs = attrs
        attrs[:class] ||= Phlex::Icons.configuration.default_classes

        super()
      end

      def view_template
        send(variant) if respond_to?(variant)
      end
    end
  end
end

Version data entries

56 entries across 56 versions & 8 rubygems

Version Path
phlex-icons-hero-1.6.0 lib/phlex/icons/base.rb
phlex-icons-bootstrap-1.6.0 lib/phlex/icons/base.rb
phlex-icons-tabler-1.6.0 lib/phlex/icons/base.rb
phlex-icons-lucide-1.5.0 lib/phlex/icons/base.rb
phlex-icons-remix-1.6.0 lib/phlex/icons/base.rb
phlex-icons-flag-1.6.0 lib/phlex/icons/base.rb
phlex-icons-radix-1.6.0 lib/phlex/icons/base.rb
phlex-icons-1.6.0 lib/phlex/icons/base.rb
phlex-icons-lucide-1.6.0 lib/phlex/icons/base.rb
phlex-icons-radix-1.5.0 lib/phlex/icons/base.rb
phlex-icons-tabler-1.5.0 lib/phlex/icons/base.rb
phlex-icons-remix-1.5.0 lib/phlex/icons/base.rb
phlex-icons-flag-1.5.0 lib/phlex/icons/base.rb
phlex-icons-1.5.0 lib/phlex/icons/base.rb
phlex-icons-hero-1.5.0 lib/phlex/icons/base.rb
phlex-icons-bootstrap-1.5.0 lib/phlex/icons/base.rb
phlex-icons-hero-1.4.0 lib/phlex/icons/base.rb
phlex-icons-lucide-1.4.0 lib/phlex/icons/base.rb
phlex-icons-tabler-1.4.0 lib/phlex/icons/base.rb
phlex-icons-radix-1.4.0 lib/phlex/icons/base.rb