We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I've attempted to use the Group fieldtype in a form on the front-end, however I've run into a few issues with field rendering inside groups.
x-text="form.errors.{{ group_handle }}.{{ handle }}"
field
{{ fields }}{{ field }}...{{/ field }}{{/ fields }}
handle="{ group_handle }.{ handle }"
Here is an example of Group field template that mostly works except for options and error rendering:
{{ group_handle = handle }} {{ fields }} {{ field }} <template x-if="{{ show_field }}"> <div> <x-label for="{{ group_handle}}.{{ handle }}" class="mb-1"> {{ display }} </x-label> <div class="my-2"> {{ partial:vendor/statamic/forms/fields/{type} handle="{group_handle}.{handle}" }} </div> <template x-if="form.invalid('{{ group_handle }}.{{ handle }}')"> <p class="text-sm text-destructive" x-text="form.errors.{{ handle }}"></p> </template> </div> </template> {{ /field }} {{ /fields }}
I've also put together a repo where you can reproduce the issue. (note the repo is using the Formatic starter kit) https://github.com/mikemartin/formatic-group/blob/main/resources/views/vendor/statamic/forms/fields/group.antlers.html
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
I've attempted to use the Group fieldtype in a form on the front-end, however I've run into a few issues with field rendering inside groups.
x-text="form.errors.{{ group_handle }}.{{ handle }}"
field
tag pair.{{ fields }}{{ field }}...{{/ field }}{{/ fields }}
handle="{ group_handle }.{ handle }"
Here is an example of Group field template that mostly works except for options and error rendering:
I've also put together a repo where you can reproduce the issue. (note the repo is using the Formatic starter kit)
https://github.com/mikemartin/formatic-group/blob/main/resources/views/vendor/statamic/forms/fields/group.antlers.html
The text was updated successfully, but these errors were encountered: