SKILL.blade.php 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. ---
  2. name: fluxui-development
  3. description: "Use this skill for Flux UI development in Livewire applications only. Trigger when working with <flux:*> components, building or customizing Livewire component UIs, creating forms, modals, tables, or other interactive elements. Covers: flux: components (buttons, inputs, modals, forms, tables, date-pickers, kanban, badges, tooltips, etc.), component composition, Tailwind CSS styling, Heroicons/Lucide icon integration, validation patterns, responsive design, and theming. Do not use for non-Livewire frameworks or non-component styling."
  4. license: MIT
  5. metadata:
  6. author: laravel
  7. ---
  8. @php
  9. /** @var \Laravel\Boost\Install\GuidelineAssist $assist */
  10. @endphp
  11. # Flux UI Development
  12. ## Documentation
  13. Use `search-docs` for detailed Flux UI patterns and documentation.
  14. ## Basic Usage
  15. This project uses the free edition of Flux UI, which includes all free components and variants but not Pro components.
  16. Flux UI is a component library for Livewire built with Tailwind CSS. It provides components that are easy to use and customize.
  17. Use Flux UI components when available. Fall back to standard Blade components when no Flux component exists for your needs.
  18. @boostsnippet("Basic Button", "blade")
  19. <flux:button variant="primary">Click me</flux:button>
  20. @endboostsnippet
  21. ## Available Components (Free Edition)
  22. Available: avatar, badge, brand, breadcrumbs, button, callout, checkbox, dropdown, field, heading, icon, input, modal, navbar, otp-input, profile, radio, select, separator, skeleton, switch, text, textarea, tooltip
  23. ## Icons
  24. Flux includes [Heroicons](https://heroicons.com/) as its default icon set. Search for exact icon names on the Heroicons site - do not guess or invent icon names.
  25. @boostsnippet("Icon Button", "blade")
  26. <flux:button icon="arrow-down-tray">Export</flux:button>
  27. @endboostsnippet
  28. For icons not available in Heroicons, use [Lucide](https://lucide.dev/). Import the icons you need with the Artisan command:
  29. ```bash
  30. {{ $assist->artisanCommand('flux:icon crown grip-vertical github') }}
  31. ```
  32. ## Common Patterns
  33. ### Form Fields
  34. @boostsnippet("Form Field", "blade")
  35. <flux:field>
  36. <flux:label>Email</flux:label>
  37. <flux:input type="email" wire:model="email" />
  38. <flux:error name="email" />
  39. </flux:field>
  40. @endboostsnippet
  41. ### Modals
  42. @boostsnippet("Modal", "blade")
  43. <flux:modal wire:model="showModal">
  44. <flux:heading>Title</flux:heading>
  45. <p>Content</p>
  46. </flux:modal>
  47. @endboostsnippet
  48. ## Verification
  49. 1. Check component renders correctly
  50. 2. Test interactive states
  51. 3. Verify mobile responsiveness
  52. ## Common Pitfalls
  53. - Trying to use Pro-only components in the free edition
  54. - Not checking if a Flux component exists before creating custom implementations
  55. - Forgetting to use the `search-docs` tool for component-specific documentation
  56. - Not following existing project patterns for Flux usage