lib/formular/element.rb
def evaluate_option_condition?(condition = {})
      return true if condition.empty?
      operator = condition.keys[0]
      condition_result = Uber::Options::Value.new(condition.values[0]).evaluate(self)

      case operator.to_sym
      when :if     then condition_result
      when :unless then !condition_result
      end
    end
# this evaluates any conditons placed on our defaults returning true or false
# e.g.
# set_default :checked, "checked", if: :is_checked?
# set_default :class, ["form-control"], unless: :file_input?
this evaluates any conditons placed on our defaults returning true or false
e.g.
this evaluates any conditons placed on our defaults returning true or false e . g .
def evaluate_option_condition?(condition = {})
      return true if condition.empty?
      operator = condition.keys[0]
      condition_result = Uber::Options::Value.new(condition.values[0]).evaluate(self)
      case operator.to_sym
      when :if     then condition_result
      when :unless then !condition_result
      end
    end
def evaluate_option_condition? ( condition = { } ) return true if condition . empty? operator = condition . keys [ 0 ] condition_result = Uber :: Options :: Value . new ( condition . values [ 0 ] ) . evaluate ( self ) case operator . to_sym when :if then condition_result when :unless then ! condition_result end end
this evaluates any conditons placed on our defaults returning true or false
e.g.
this evaluates any conditons placed on our defaults returning true or false e . g .
condition