Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable reorderable when tagsinput is disabled #14212

Merged

Conversation

WesleyLJH
Copy link
Contributor

@WesleyLJH WesleyLJH commented Sep 11, 2024

Description

I encountered an issue where, even when the TagsInput component is disabled, users were still able to reorder tags. However, since the input is disabled, these changes would not be saved.

To address this, here is a simple fix:

  • The reorderable functionality has been disabled when the TagsInput is in a disabled state.
  • This update aligns with the behavior of the delete cross and of course the ability to add new tags when the input is disabled.

Visual changes

Disabled before:

Disabled.-.before.mp4

Enabled before:

Enabled.-.before.mp4

Disabled after:

Disabled.-.after.mp4

Enabled after:

Enabled.-.after.mp4

As you can see, it doesn't affect the enabled state. The only change is that the user is not allowed to reorder anymore when the field is disabled.

Functional changes

  • Changes have been tested to not break existing functionality.

@danharrin danharrin added the bug Something isn't working label Sep 12, 2024
@danharrin danharrin added this to the v3 milestone Sep 12, 2024
@danharrin danharrin merged commit a56fc5e into filamentphp:3.x Sep 12, 2024
10 checks passed
@danharrin
Copy link
Member

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants