Mity Docs Mity Docs for Mity Digital
Variable Number Fieldtype Documentation

How to use

After you have added the Variable Number fieldtype to your Form blueprint, you're ready to head to the front end of your site.

There are two things you need to do.

Include the Variable Number tag

Within your form tag, include the Variable Number fieldtype tag.

1{{ variable_number }}

This will include the logic for the fieldtype.

You can put this anywhere within your form but ensure that it is not in a looping part of your form (such as looping through Statamic's {{ fields }}.

This only needs to be included once.

Style your layouts

After you have published the layouts, in your resources/views/vendor/statamic-variable-number-fieldtype/forms/fields folder, you will see four layout files - one for each of the Layout configuration options, and one for the error message that is displayed if you use the fieldtype on a non-Form Blueprint.

The styles in the default layouts is purposely bland. Maybe you use Tailwind... maybe you write your own CSS... this addon won't get in your way. We've provided enough styles to make the out-of-the-box fieldtype layouts be usable, but they are definitely not pretty.

Rather than have you needlessly strip away opinionated styles, the bare minimum is included. You can adjust these to suit the style and layout of your site.