SKILL.blade.php 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  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 Pro version of Flux UI, which includes all free and Pro components and variants.
  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 (Pro Edition)
  22. Available: accordion, autocomplete, avatar, badge, brand, breadcrumbs, button, calendar, callout, card, chart, checkbox, command, composer, context, date-picker, dropdown, editor, field, file-upload, heading, icon, input, kanban, modal, navbar, otp-input, pagination, pillbox, popover, profile, radio, select, separator, skeleton, slider, switch, table, tabs, text, textarea, time-picker, toast, 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. ### Tables
  42. @boostsnippet("Table", "blade")
  43. <flux:table>
  44. <flux:table.columns>
  45. <flux:table.cell>Column Name</flux:table.cell>
  46. </flux:table.columns>
  47. <flux:table.row>
  48. <flux:table.cell>Value</flux:table.cell>
  49. </flux:table.row>
  50. </flux:table>
  51. @endboostsnippet
  52. ## Verification
  53. 1. Check component renders correctly
  54. 2. Test interactive states
  55. 3. Verify mobile responsiveness
  56. ## Common Pitfalls
  57. - Not checking if a Flux component exists before creating custom implementations
  58. - Forgetting to use the `search-docs` tool for component-specific documentation
  59. - Not following existing project patterns for Flux usage