Sha256: b9b7acad11a9e2eb3e07df04436f1855e177c613f980fdfaf59ed2e35ccaa2aa
Contents?: true
Size: 533 Bytes
Versions: 18
Compression:
Stored size: 533 Bytes
Contents
module Avo module Fields class HeadingField < Field def initialize(name, **args, &block) @defaults = { updatable: false, component: 'heading-field', id: 'heading_' + name.to_s.parameterize.underscore, } super(name, **args, &block) hide_on :index @as_html = args[:as_html].present? ? args[:as_html] : false end def hydrate_field(fields, model, resource, view) { as_html: @as_html } end end end end
Version data entries
18 entries across 18 versions & 1 rubygems