Sha256: d7d7c28a69dfbc10dcd6890ac5b9d20e3f0fdc6f56858a53952161baf571368c

Contents?: true

Size: 360 Bytes

Versions: 20

Compression:

Stored size: 360 Bytes

Contents

module Coco
  module Concerns
    module ActsAsFieldWithOptions
      extend ActiveSupport::Concern
      include Concerns::HasName

      def combine_options!
        @options[:data] ||= {}
        @options[:data][:coco] = "✔"
        @options[:data][:component] = "form-#{component_name.delete_prefix("fields-")}"
        super
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
coveragebook_components-0.19.8 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.7 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.6 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.5 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.4 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.3 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.2 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.1 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.19.0 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.18.8 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.18.7 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.18.0 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.7 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.6 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.5 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.4 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.3 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.2 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.1 app/components/coco/concerns/acts_as_field_with_options.rb
coveragebook_components-0.17.0 app/components/coco/concerns/acts_as_field_with_options.rb