Installation
app.css, so there's no Tailwind config to edit.
1 Requirements
- PHP 8.2 or later
- Laravel 12 or 13
- Livewire 4
- Tailwind CSS 4.1 or later, set up with Vite
2 Install the package
Require TallCraftUI with Composer:
composer require developermithu/tallcraftui
3.0 is in beta. Until the stable release, require it with the beta flag:
composer require developermithu/tallcraftui:^3.0@beta
3 Run the installer
php artisan install:tallcraftui
The installer:
- publishes
resources/css/tallcraftui.css, which registers the component source path for Tailwind and sets default brand colors, - adds any missing lines to
resources/css/app.css, right after your existing@importrules, - offers to install
@tailwindcss/formswith the package manager it finds from your lockfile, - switches to a
tc-component prefix if your app already has components with the same names.
It only adds what's missing, so it's safe to run again. Afterwards, app.css contains:
@import 'tailwindcss';@import './tallcraftui.css';@plugin '@tailwindcss/forms';@custom-variant dark (&:where(.dark, .dark *));
The @custom-variant line enables class-based dark mode, which the theme toggle uses.
Leave it out if dark mode should follow the operating system only.
4 Set your brand colors
Components use two theme colors, primary and secondary. They default to #6d28d9 and #a21caf.
Define your own in app.css to override them:
@theme { --color-primary: #0e7c72; --color-secondary: #5b61e8;}
Then start Vite:
npm run dev # or: bun dev
5 Use your first component
Components work in any Blade view. Inside a Livewire component, bind them with wire:model like any input.
Validation errors for the bound property appear under the field automatically. Try submitting this form empty:
@php // public string $email = ''; // public function save() { $this->validate(['email' => 'required|email']); }@endphp <form wire:submit="save" class="flex max-w-sm flex-col gap-4" novalidate> <x-input label="Email" type="email" wire:model="email" placeholder="you@example.com" /> <x-button label="Subscribe" spinner="save" class="w-fit" /></form>
Existing projects
Breeze and Jetstream ship their own <x-input>, <x-button> and similar components.
When the installer finds components with the same names, it publishes config/tallcraftui.php with a tc- prefix to avoid conflicts. Use the components like this:
<x-tc-input label="Name" wire:model="name" /><x-tc-button label="Save" />
You can change the prefix any time. See component prefix.
Next steps
- Configuration: change defaults such as button size, modal position or toast timeout.
- Theming: colors, dark mode and overriding styles with classes.
- Browse the components, starting with Button.