Liking cljdoc? Tell your friends :D

reacl-c-basics.forms.core

This namespace contains replacements for the basic form elements (input, select, textbox) but with corresponding states.

The select item also supports any kind of values for the :value attribute of options, not just strings.

Additionally, the new attributes :invalid and :validate are supported for all of them, allowing for a declarative way to use setCustomValidity on the dom nodes.

An attribute :report-validity can be set to true on input items and form to call reportValidity on them on every state change.

This namespace contains replacements for the basic form
elements (input, select, textbox) but with corresponding
states.

The [[select]] item also supports any kind of values for the
`:value` attribute of [[option]]s, not just strings.

Additionally, the new attributes `:invalid` and `:validate` are
supported for all of them, allowing for a declarative way to
use `setCustomValidity` on the dom nodes.

An attribute `:report-validity` can be set to true on input items
and [[form]] to call `reportValidity` on them on every state
change.
raw docstring

formcljs

(form & content)
(form attrs & content)

The same as reacl-c.dom/form, but with the additional attribute :report-validity.

The same as `reacl-c.dom/form`, but with the additional attribute `:report-validity`.
sourceraw docstring

inputcljs

(input)
(input attrs)

An item representing its state as the value of an input element.

The :type attribute can influence the type of the state:

  • for "checkbox" and "radio" the state must be a boolean
  • for "file" it must be a nil or a js/File object
  • for "submit" and "cancel" it is ignored
  • for nil and all other strings, the state must be a string.

Note that the :type can also be one of the types defined in reacl-c-basics.forms.types.

Also supports the new attributes :invalid and :validate.

An item representing its state as the value of an input element.

 The `:type` attribute can influence the type of the state:
 - for `"checkbox"` and `"radio"` the state must be a boolean
 - for `"file"` it must be a `nil` or a `js/File` object
 - for `"submit"` and `"cancel"` it is ignored
 - for `nil` and all other strings, the state must be a string.

Note that the `:type` can also be one of the types defined in [[reacl-c-basics.forms.types]].

Also supports the new attributes `:invalid` and `:validate`.
sourceraw docstring

optgroupcljs

(optgroup & options)
(optgroup attrs & options)

An optgroup item usable to group option items in a select.

An optgroup item usable to group [[option]] items in a [[select]].
sourceraw docstring

optioncljs

(option & contents)
(option attrs & contents)

An item that can be used inside a select element to define a selectable option. The attribute :value can be any value, and the contents should be the text shown to the user.

An item that can be used inside a [[select]] element to define a
selectable option. The attribute `:value` can be any value, and the
contents should be the text shown to the user.
sourceraw docstring

selectcljs

(select & options)
(select attrs & options)

A select element that allows options to have arbitrary values. If the :multiple attribute is set, then the state of this item must be a list of values or nil.

Also supports the new attributes :invalid and :validate.

A select element that allows [[option]]s to have
arbitrary values. If the `:multiple` attribute is set, then the
state of this item must be a list of values or nil.

Also supports the new attributes `:invalid` and `:validate`.
sourceraw docstring

textareacljs

(textarea)
(textarea attrs)

An item representing its string state in a textual multiline input element.

Also supports the new attributes :invalid and :validate.

An item representing its string state in a textual multiline input element.

Also supports the new attributes `:invalid` and `:validate`.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close