Skip to content

[Bug]: rule date within dehydrate function not applied #122

Closed

Description

@Abdulmajeed-Jamaan

What happened?

In following lines, the rule not applied at all:

$component->rule(
'date',
static fn (Flatpickr $component): bool => $component->isMultiplePicker() && ! $component->isRangePicker() && $component->hasDate(),
);

Filament calls the dehydrate after the validation happens:

https://github.com/filamentphp/filament/blob/4b2665d934235f05dc49a9668c2c35c073d42a00/packages/schemas/src/Concerns/HasState.php#L418-L427

How to reproduce the bug

Check if date rule applied or not.

$component->rule(
'date',
static fn (Flatpickr $component): bool => $component->isMultiplePicker() && ! $component->isRangePicker() && $component->hasDate(),
);

Package Version

5

PHP Version

8.3

Laravel Version

12

Which operating systems does with happen with?

macOS

Notes

No response

Activity

  1. Abdulmajeed-Jamaan commented on Oct 5, 2025

    @Abdulmajeed-Jamaan
    Author

    Also, the date validation does not work with multiplePicker from my testing

  2. coolsam726 commented on Jun 13, 2026

    @coolsam726
    Owner

    Fixed in #144 (and #143 where applicable). Closing manually because the PR did not include Closes #122 keywords for auto-close on merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions