Skip to content

Datepicker input has no red border when invalid like other inputs #1158

Open
@lucasromanojf

Description

Flux version

v2.0.2

Livewire version

v3.5.20

Tailwind version

v4.0.7

Browser and Operating System

Edge on MacOS

What is the problem?

When using the datepicker with input, the input border does not turn red when it is invalid.

Code snippets

<?php

use function Livewire\Volt\{state};

state('date')->url();
state('other')->url();

$submit = function () {
    $this->validate([
        'date' => 'required',
        'other' => 'required',
    ]);
};

?>

<div>
    <form wire:submit.prevent="submit" class="space-y-6">
        <flux:date-picker
            label="Date"
            wire:model="date"
        >
            <x-slot name="trigger">
                <flux:date-picker.input />
            </x-slot>
        </flux:date-picker>

        <flux:input label="Other" wire:model="other"/>

        <flux:button type="submit" variant="primary">Submit</flux:button>
    </form>
</div>

Just submit the form as is. The datefield input won't be red and the other input will.

How do you expect it to work?

The datepicker input should be red bordered when invalid, just like the other inputs.

Please confirm (incomplete submissions will not be addressed)

  • I have provided easy and step-by-step instructions to reproduce the bug.
  • I have provided code samples as text and NOT images.
  • I understand my bug report will be closed if I haven't met the criteria above.

Activity

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

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions