Skrypt
Skrypt
FFilament
Created by Skrypt on 7/16/2024 in #❓┊help
Blade Component - Button Group
Hi, anyone has any idea why the exact same code for rendering a button group looks different on my frontend than it looks in the admin panel? What am I supposed to import/include in the frontend for it to work properly? This is the code:
<x-filament::button.group class="w-max">
<x-filament::button grouped>
Test
</x-filament::button>
<x-filament::button grouped>
Test 2
</x-filament::button>
</x-filament::button.group>
<x-filament::button.group class="w-max">
<x-filament::button grouped>
Test
</x-filament::button>
<x-filament::button grouped>
Test 2
</x-filament::button>
</x-filament::button.group>
13 replies
FFilament
Created by Skrypt on 6/11/2024 in #❓┊help
Filament Blade Components in non-filament frontend
I did add @FilamentStyles and @FilamentScripts to my layout, I have everything set in vite.config.js correctly, I load the filament preset in my tailwind config but whatever I do, filament styles still don't load on the frontend. My public/filament/support.css is very small and doesn't include things like bg-custom-600 etc. Sadly apart from a list of available blade components, the documentation doesn't really say what you need to set up to make them work in your non-filament frontend work. Anyone encountered a similar issue already? I'm kinda lost 😄
2 replies
FFilament
Created by Skrypt on 5/7/2024 in #❓┊help
Locale Prefix
Hi, how would you go about creating localized routes for filament? I need routes like: - /en/admin/... for english admin panel, - /de/admin/... for german admin panel and so on Is there any way to override the routes.php file of filament? Or preferably just extend it?
9 replies
FFilament
Created by Skrypt on 4/29/2024 in #❓┊help
Dynamic actions with modal
Hi, how can I create dynamically Actions in a custom page, where each of the actions opens a modal? When I did some testing, it worked if I just created a method like testAction() { // return action } ANd rendered it using {{ $this->testAction }}. However when creating them dynamically (based on an array of records for example that can change), it stops working. The action is rendered, but modals don't open anymore. I guess it has something to do with the internals of the InteractsWithActions trait and how the mounted actions / modals are stored, but is there any way to enable this in current filament version?
3 replies
FFilament
Created by Skrypt on 4/28/2024 in #❓┊help
Navigation Builder Parent Item / Child Items
Hi, can anyone be so kind to explain how this is supposed to work? I know that inside of resources, I can simply add the navigationParentItem property and the auto-generated filament navigation will build it correctly. But for various reasons I'm building the navigation myself (by calling ->navigation() on the panel), but I can't get the 3rd level items to work. Creating items and groups is explained in the docs, but I can't find any info how to create the parent / child items (3rd level) using the NavigationBuilder. I used both the parentItem(<label>) and childItems(<array>) methods in the NavigationItem, but still no luck.
2 replies
FFilament
Created by Skrypt on 4/27/2024 in #❓┊help
Action Modal on Simple Pages?
Hey, is there any way to add the ability to open modals on actions (such as confirmation modals) within a simple page? I have extended the default Login / Register views, but no matter what I do, actions that should open modals just don't work.
9 replies
FFilament
Created by Skrypt on 4/4/2024 in #❓┊help
Testing - get created record
Hi, when testing the Create Page form, I also associate a relationship using a Select. I can test whether the newly created record is present in the database using assertDatabaseHas, but how would I check whether also the many-to-many relationship was stored? Can I somehow store the resulting new record in a variable (when calling the create action on the CreatePage test), so that I can then retrieve the ID and check the many-to-many table in a separate assertDatabaseHas call?
3 replies
FFilament
Created by Skrypt on 1/24/2024 in #❓┊help
Single login page for multiple panels
Hi guys, has anyone got any idea how to achieve a single login page under /login to access multiple panels? I know I could do something like here (https://discord.com/channels/883083792112300104/1154830375655325907) but that just makes each login page to use the same class, but I still get a different Route/URL for every panel, such as /admin/login, /user/login, /system/login etc. Has anyone got any idea how to override this so I have a single route /login for every panel?
5 replies
FFilament
Created by Skrypt on 10/18/2023 in #❓┊help
Focus on Action Modal open?
Hi, is it possible to focus a form field after a action modal is opened? I use AlpineJS dispatch an Event which opens the Modal and I'm able to pass in the name of the field which is needed to be focused. But I'm not sure if it's possible currently, I know I can execute PHP code when the modal is opened. However I probably need to execute some JS. I also tried using ->autofocus() on the form fields with a Closure that checks which field to focus, like:
->autofocus(fn() => $this->autofocus === 'field-name')
->autofocus(fn() => $this->autofocus === 'field-name')
But autofocus seems not to do anything in modals.
6 replies
FFilament
Created by Skrypt on 8/24/2023 in #❓┊help
Checkboxlist Debounce
Hi guys. I have a CheckboxList component, with debounce(2500) / live(debounce: 2500) configured. But for some reason, instead of allowing me to select multiple checkboxes within the 2500ms duration and THEN update the state with all selected options, it just debounces for the 2500ms and then sends the first selected checkbox only. Any idea how to fix this?
1 replies
FFilament
Created by Skrypt on 7/31/2023 in #❓┊help
filament v3: file upload on custom page
Hi guys, so I have this custom page which implements HasForms and uses the InteractsWithForms trait. I've added a File Upload field to the schema, but anytime I upload an image, I get this error:
Property type not supported in Livewire for property: [null]
Property type not supported in Livewire for property: [null]
Anyone encountered this error in V3?
7 replies