nathan269_
nathan269_
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
Forgot to put this in here but I used this as my solution:
->hidden(Str::contains(request()->getRequestUri(), 'pages'))
->hidden(Str::contains(request()->getRequestUri(), 'pages'))
I didn't want the exit popup to be an option for the pages section of the admin.
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
what's also weird is that if I have this:
->hidden(str_contains(get_called_class(), 'App\Filament\Resources\ComponentResource'))
->hidden(str_contains(get_called_class(), 'App\Filament\Resources\ComponentResource'))
it does display as an option
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
and get_called_class() definitely returns "App\Filament\Resources\ComponentResource"
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
yeah it's removed
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
doesn't work either
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
tried that also. No luck
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
Thanks Tieme but that doesn't work either
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
both get_called_class() and ComponentResource::class are the same value on the page I'm testing on, so I don't see why it shouldn't work. I also tried ->hidden !==
17 replies
FFilament
Created by nathan269_ on 2/23/2024 in #❓┊help
Conditional Pageblock Dependent On Resource
Thanks for the suggestion Leandro, but no luck with that. It doesn't display on any resource when I try that.
17 replies
FFilament
Created by nathan269_ on 1/9/2024 in #❓┊help
Light/Dark Mode Logo
brilliant, that works great
5 replies
FFilament
Created by nathan269_ on 12/13/2023 in #❓┊help
Filament Curator (srcset not working)
9 replies
FFilament
Created by nathan269_ on 12/13/2023 in #❓┊help
Filament Curator (srcset not working)
In the example shown in the documentation (https://github.com/awcodes/filament-curator?tab=readme-ov-file), it's set as largest to smallest like so:
:srcset="['1024w','640w']"
sizes="(max-width: 1200px) 100vw, 1024px"
:srcset="['1024w','640w']"
sizes="(max-width: 1200px) 100vw, 1024px"
My images are uploaded/stored in an s3 bucket. Even with using the exact same example in the docs, the image is always the largest width (1024px). I'll report an issue.
9 replies
FFilament
Created by nathan269_ on 12/13/2023 in #❓┊help
Filament Curator (srcset not working)
Yeah I had also tried that but had the same outcome
9 replies
FFilament
Created by nathan269_ on 10/27/2023 in #❓┊help
How do I Determine What Action is Called?
I've found an alternative solution. I've done this:
->rules([
function () {
return function (string $attribute, $value, Closure $fail) {
// dd(request()->components[0]['calls'][0]['method']);
if (request()->components[0]['calls'][0]['method'] == 'save') {
//
} else if (request()->components[0]['calls'][0]['method'] == 'mountAction') {
// //
}
};
}
]),
->rules([
function () {
return function (string $attribute, $value, Closure $fail) {
// dd(request()->components[0]['calls'][0]['method']);
if (request()->components[0]['calls'][0]['method'] == 'save') {
//
} else if (request()->components[0]['calls'][0]['method'] == 'mountAction') {
// //
}
};
}
]),
3 replies
FFilament
Created by nathan269_ on 10/19/2023 in #❓┊help
How to Position Package Resources?
ah i see, no problem. Thanks for the quick response!
7 replies