Sha256: 198aee7956ca2be8f667f002636be6f7723bb299cd27dcdc53a2a5e0c0c15bc9
Contents?: true
Size: 595 Bytes
Versions: 2
Compression:
Stored size: 595 Bytes
Contents
# frozen_string_literal: true require "yattho/classify" module Yattho module Forms # :nodoc: class Group < BaseComponent VERTICAL = :vertical HORIZONTAL = :horizontal DEFAULT_LAYOUT = VERTICAL LAYOUTS = [VERTICAL, HORIZONTAL].freeze def initialize(inputs:, builder:, form:, layout: DEFAULT_LAYOUT, **system_arguments) @inputs = inputs @builder = builder @form = form @layout = layout @system_arguments = system_arguments end def horizontal? @layout == HORIZONTAL end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
yattho_view_components-0.1.1 | lib/yattho/forms/group.rb |
yattho_view_components-0.0.1 | lib/yattho/forms/group.rb |