Sha256: 10405162ad6c5eb8504664470a18da2968bf63abdcf44a366df5967712392ab5
Contents?: true
Size: 625 Bytes
Versions: 6
Compression:
Stored size: 625 Bytes
Contents
module Headmin module Form class BlocksView < ViewModel def repeater_options keys = %i[form attribute names label] options = to_h.slice(*keys) default_repeater_options.deep_merge(options) end def paths @paths || [] end def prefixes paths + ["admin/blocks", "blocks", ""] end private def default_repeater_options { attribute: "blocks", label: false, templates: names, row: { class: "repeater-row list-group-item pt-3" } } end end end end
Version data entries
6 entries across 6 versions & 1 rubygems