Composable Form Versions Save

Build type-safe composable forms in Elm

8.0.1

4 years ago

Fixed

  • README example. The new error attribute was missing.

8.0.0

4 years ago

Added

  • Success variant to Form.View.State. By default, it can be styled using the .elm-form-success CSS selector. #26
  • Form.disable and Form.Base.disable, which allow disabling the fields of a form. #27

Changed

  • Form.Base.FilledField has been renamed to Form.Base.CustomField and its field property has been renamed to state. #27
  • The tuple ( field, Maybe Error ) is replaced with the new record Form.Base.FilledField everywhere. #27
  • An error : values -> Maybe String attribute was added to field configuration. Useful to show server-side validation errors. #29
  • The Error type was extended with an External variant. It is meant to represent an external error not caused by client-side validation. #29
  • NumberField value storage has been changed from Maybe Float to String to fix issues entering values after the decimal point. #25 & #30
  • The step item in the Form.Base.NumberField.Attributes record has been changed from number to Maybe number to allow a step attribute of "any". #30

Fixed

  • Default select field in Form.View now listens to the change event instead of input. Internet Explorer and Edge now should work properly with this field. #28

7.1.0

5 years ago

Added

  • Form.View.htmlViewConfig, which allows easy customization of the default Form.View.asHtml function. #23

7.0.2

5 years ago

Fixed

  • Textarea not updating its value properly when using Form.View.asHtml. #21

7.0.1

5 years ago

Changed

  • Stop asking users to copy-paste code in the Form.Base docs.

7.0.0

5 years ago

Added

  • Form.list and Form.Base.FormList that allow to build a variable list of forms.

Changed

  • Improved introduction to the Form type.

6.0.1

5 years ago

Changed

  • Fix radio fields being rendered inside a main label when using Form.View.asHtml.
  • Remove fieldset parent when rendering radio fields using Form.View.asHtml.

6.0.0

5 years ago

Added

  • Form.section (thanks to @russelldavies).
  • Ellie snippet on README.

Changed

  • Fix optional groups / sections rendering field errors when empty.

5.0.0

5 years ago

Added

  • View strategy selector on examples website.

Changed

  • Render fields inside HTML label for accessibility in Form.View.asHtml. The previous label elements are now div elements with the elm-form-label class. To migrate, replace your old CSS rules .elm-form label { ... } with .elm-form .elm-form-label { ... }.

Removed

  • Form.Value. Elm 0.19 makes this module unnecessary! The API is simpler now, allowing you to work with your types directly. To migrate, replace Value a with a and initialize your form values explicitly.