app/helpers/dry_crud/form/control.rb in dry_crud-5.0.0 vs app/helpers/dry_crud/form/control.rb in dry_crud-5.2.0
- old
+ new
@@ -1,16 +1,14 @@
-# encoding: UTF-8
-
module DryCrud
module Form
# Internal class to handle the rendering of a single form control,
# consisting of a label, input field, addon, help text or
# required mark.
class Control
- attr_reader :builder, :attr, :args, :options, :span, :addon, :help
+ attr_reader :builder, :attr, :args, :options, :addon, :help
delegate :content_tag, :object,
to: :builder
# Html displayed to mark an input as required.
@@ -30,11 +28,11 @@
# Takes the form builder, the attribute to build the control for
# as well as any additional arguments for the field method.
# This includes an options hash as the last argument, that
# may contain the following special options:
#
- # * <tt>:addon</tt> - Addon content displayd just after the input field.
- # * <tt>:help</tt> - A help text displayd below the input field.
+ # * <tt>:addon</tt> - Addon content displayed just after the input field.
+ # * <tt>:help</tt> - A help text displayed below the input field.
# * <tt>:span</tt> - Number of columns the input field should span.
# * <tt>:caption</tt> - Different caption for the label.
# * <tt>:field_method</tt> - Different method to create the input field.
# * <tt>:required</tt> - Sets the field as required
# (The value for this option usually is 'required').