lib/phlex/icons/base.rb in phlex-icons-remix-0.17.0 vs lib/phlex/icons/base.rb in phlex-icons-remix-1.0.0
- old
+ new
@@ -1,13 +1,14 @@
# frozen_string_literal: true
module Phlex
module Icons
class Base < Phlex::SVG
- attr_reader :classes
+ attr_reader :attrs
- def initialize(classes: Phlex::Icons.configuration.default_classes)
- @classes = classes
+ def initialize(**attrs)
+ @attrs = attrs
+ attrs[:class] ||= Phlex::Icons.configuration.default_classes
super()
end
def view_template