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

[6.x] Add waitUntilEnabled and waitUntilDisabled #918

Merged
merged 2 commits into from
Aug 30, 2021
Merged

[6.x] Add waitUntilEnabled and waitUntilDisabled #918

merged 2 commits into from
Aug 30, 2021

Conversation

SjorsO
Copy link
Contributor

@SjorsO SjorsO commented Aug 29, 2021

This PR adds methods for waiting until an element is enabled or disabled.

These methods are especially useful when using wire:loading.attr="disabled" on Livewire buttons:

<x-button wire:click="generateExport"
          wire:loading.attr="disabled"
          dusk="generate-export"
>Export</x-button>
$browser->click('@generate-export')
    ->assertDisabled('@generate-export')
    ->waitUntilEnabled('@generate-export')
    ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants