If you find this website useful, your sponsorship would greatly support its ongoing development and maintenance. Learn more


To create a modal use the modal container:
<x-modal> ... </x-modal>

Inside the container:

Set the trigger to open the modal:

    <x-slot name="trigger">
        <button @click="on = true" class="text-primary">
            Open Modal

Set the modal title:

<x-slot name="title">The Modal Title</x-slot>

Set the modal body:

<x-slot name="content">The Body</x-slot>

Set the modal footer:

<x-slot name="footer">The Footer</x-slot>

To change the classes edit the blade component at:


                        <x-slot name="trigger">
                            <x-slot name="trigger">
                                <button @click="on = true" class="text-primary">Open Modal using a text style</button>
                                <button @click="on = true" class="btn btn-primary">Open Modal using a button style</button>

                        <x-slot name="title">The Modal Title</x-slot>

                        <x-slot name="content">
                            <p>The Body</p>

                        <x-slot name="footer">
                            <button class="btn btn-primary" @click="on = false">Close</button>

© 2024 Laravel AdminTW. All rights reserved.

Built by David Carr