(input)
Available props: :spec - The root spec provided to the renderer. This is the spec that you would like to be rendered as a series of inputs. :ui - The style in which to render the inputs. #{:antd}
You can then provide, as a key, any spec definition you wish to customize. As an example, if you have a spec defined as :my.spec/foo, then in this props map you can provide {:my.spec/foo { ... options } } where options are defined below.
Available options on a provided spec: :disabled? - Boolean - Is this input disabled? :hidden? - Boolean - Is this input hidden? :reset-on-update? - Boolean - If this input is updated for any reason, should it be reset? (e.g. its default value) :default-value - Any/fn - Default value for this input. Alternatively, you can provide a function that will be given this input's props which you can use to generate a default value dynamically. :spec - Any - When deferring a spec, provide it here at runtime. :spec-xform - fn - Will be called in lieu of :spec, if provided, with the input's props as its only argument. The expected return value is a spec. :help - String - Error message when spec does not validate on the input. :delete? - fn - Given this input's props, can it be deleted if part of a collection. :container - React - A react component that can be provided as a container to this input. :xform-children - fn - When provided to a collection, applied to the children in the collection immediately before layout (effectively allowing you to sort them). :add-button-label - Text - When provided to a collection, the label for the 'Add Another Item' button. :style - Map - Some inputs accept various styles. API is still being worked on.
Available props: :spec - The root spec provided to the renderer. This is the spec that you would like to be rendered as a series of inputs. :ui - The style in which to render the inputs. #{:antd} You can then provide, as a key, any spec definition you wish to customize. As an example, if you have a spec defined as :my.spec/foo, then in this props map you can provide {:my.spec/foo { ... options } } where options are defined below. Available options on a provided spec: :disabled? - Boolean - Is this input disabled? :hidden? - Boolean - Is this input hidden? :reset-on-update? - Boolean - If this input is updated for any reason, should it be reset? (e.g. its default value) :default-value - Any/fn - Default value for this input. Alternatively, you can provide a function that will be given this input's props which you can use to generate a default value dynamically. :spec - Any - When deferring a spec, provide it here at runtime. :spec-xform - fn - Will be called in lieu of :spec, if provided, with the input's props as its only argument. The expected return value is a spec. :help - String - Error message when spec does not validate on the input. :delete? - fn - Given this input's props, can it be deleted if part of a collection. :container - React - A react component that can be provided as a container to this input. :xform-children - fn - When provided to a collection, applied to the children in the collection immediately before layout (effectively allowing you to sort them). :add-button-label - Text - When provided to a collection, the label for the 'Add Another Item' button. :style - Map - Some inputs accept various styles. API is still being worked on.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close