Sha256: 9f84782563a3fb98a4894ea699f639a5f18382bcb9a4f129172bbc7e504dc5af
Contents?: true
Size: 612 Bytes
Versions: 55
Compression:
Stored size: 612 Bytes
Contents
# frozen_string_literal: true class Avo::Edit::FieldWrapperComponent < ViewComponent::Base def initialize(field: nil, dash_if_blank: true, full_width: false, displayed_in_modal: false, form: nil, resource: {}, **args) @field = field @dash_if_blank = dash_if_blank @classes = args[:class].present? ? args[:class] : "" @args = args @displayed_in_modal = displayed_in_modal @form = form @resource = resource @model = resource.present? ? resource.model : nil @full_width = full_width if (@index != 0) || @displayed_in_modal @classes += " border-t" end end end
Version data entries
55 entries across 55 versions & 1 rubygems