Module

Formless.Types.Query

Package
purescript-formless-aj
Repository
ajnsit/purescript-formless-independent

#Query Source

data Query form

The component query type. See Formless.Query for helpers related to constructing and using these queries.

Constructors

#State Source

type State form m = Record (StateRow form (internal :: InternalState form m))

The component local state

#PublicState Source

type PublicState form = Record (StateRow form ())

The component's public state

#StateRow Source

type StateRow form r = (dirty :: Boolean, errors :: Int, form :: form Record FormField, submitAttempts :: Int, submitting :: Boolean, validity :: ValidStatus | r)

The component's public state

#InternalState Source

newtype InternalState form m

A newtype to make easier type errors for end users to read by hiding internal fields

Constructors

Instances

#ValidStatus Source

data ValidStatus

A type to represent a running debouncer A type to represent validation status

Constructors

Instances

#initFormState Source

initFormState :: forall m fs is form ixs. RowToList is ixs => InputFieldsToFormFields ixs is fs => Newtype (form Record InputField) (Record is) => Newtype (form Record FormField) (Record fs) => form Record InputField -> form Record (Validation form m) -> State form m

Initialise the form state with default values. Passing in the initial inputs, and the validations.