Revo Docs

Form block

A component that encapsulates label, input, and error.

Your name
Enter you name, no excuses. Be yourself
<x-ui::forms.block-v label="Your name" description="Enter you name, no excuses. Be yourself" errors="Required">
    <x-ui::forms.text-input placeholder="Your name" class="w-full" value="Bruce wayne" />
</x-ui::forms.block-v>
Copied!

Horizontal

Enable notifications
By enabling this box you will receive some notifications
<x-ui::forms.block-h label="Enable notifications" description="By enabling this box you will receive some notifications" errors="Required">
    <x-ui::forms.switch />
</x-ui::forms.block-h>
Copied!

Errors

The form block can automatically display the errors in the laravel error bag, just add the error attribute with the name of the field

Your name
Enter you name, no excuses. Be yourself
<x-ui::forms.block-v label="Your name" description="Enter you name, no excuses. Be yourself" error="theField">
    <x-ui::forms.text-input icon="bolt" placeholder="Your name" class="w-full" value="Bruce wayne" />
</x-ui::forms.block-v>
Copied!