Sha256: 0f388e454b3ce4616b6820de26fd1aadb4a75dbb5b01bd4a1eaaa0f46bce820e

Contents?: true

Size: 483 Bytes

Versions: 225

Compression:

Stored size: 483 Bytes

Contents

# frozen_string_literal: true

class Avo::Index::GridItemComponent < ViewComponent::Base
  include Avo::ResourcesHelper

  def initialize(resource: nil, reflection: nil, parent_model: nil)
    @resource = resource
    @reflection = reflection
    @grid_fields = resource.get_grid_fields
    @parent_model = parent_model
  end

  private

  def cover
    @grid_fields.cover_field
  end

  def title
    @grid_fields.title_field
  end

  def body
    @grid_fields.body_field
  end
end

Version data entries

225 entries across 225 versions & 1 rubygems

Version Path
avo-2.2.2 app/components/avo/index/grid_item_component.rb
avo-2.2.1 app/components/avo/index/grid_item_component.rb
avo-2.2.0 app/components/avo/index/grid_item_component.rb
avo-2.1.2.pre2 app/components/avo/index/grid_item_component.rb
avo-2.1.2.pre1 app/components/avo/index/grid_item_component.rb
avo-1.25.1 app/components/avo/index/grid_item_component.rb
avo-2.1.1 app/components/avo/index/grid_item_component.rb
avo-2.1.0 app/components/avo/index/grid_item_component.rb
avo-2.0.0 app/components/avo/index/grid_item_component.rb
avo-1.25.0 app/components/avo/index/grid_item_component.rb
avo-1.24.2 app/components/avo/index/grid_item_component.rb
avo-1.24.1 app/components/avo/index/grid_item_component.rb
avo-1.24.0 app/components/avo/index/grid_item_component.rb
avo-1.23.0 app/components/avo/index/grid_item_component.rb
avo-1.22.4 app/components/avo/index/grid_item_component.rb
avo-1.22.3 app/components/avo/index/grid_item_component.rb
avo-1.22.2 app/components/avo/index/grid_item_component.rb
avo-1.22.1 app/components/avo/index/grid_item_component.rb
avo-1.22.1.pre.2 app/components/avo/index/grid_item_component.rb
avo-1.22.1.pre.1 app/components/avo/index/grid_item_component.rb