-
-
Notifications
You must be signed in to change notification settings - Fork 221
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
When a button is hidden, it shows a blank space. #1294
Labels
Comments
Hello, can you show an example? Do you have any idea how to resolve this? |
Of course, since the button returns a Null Action when is ->hide(), it would be easy not to draw them if they contain a Null value.
Screenshots:

my correction proposal in vendor/livewire-powergrid/components/row.blade..php:
<div class="pg-actions">
<!-- Render Action -->
@if (filled(data_get($row, 'actions')) && $column->isAction)
@foreach (data_get($row, 'actions') as $key => $action)
@if ($action != null)
<div wire:key="action-{{ $row->id }}-{{ $key }}">
{!! $action !!}
</div>
@endif
@Endforeach
@endif
</div>
|
luanfreitasdev
added
enhancement
New feature or request
and removed
need more info
Further information is requested
labels
Dec 28, 2023
7 tasks
7 tasks
luanfreitasdev
changed the title
🐛 When a button is hidden, it shows a blank space.
When a button is hidden, it shows a blank space.
Dec 28, 2023
7 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Have you searched through other issues to see if your problem is already reported or has been fixed?
Yes, I did not find it.
Did you read the documentation?
Yes, I did not find it.
Have you tried to publish the views?
Yes - I didn't work.
Is there an error in the console?
No
PHP Version
8.1
PowerGrid
5.1.16
Laravel
10
Livewire
3.0.1
Alpine JS
No response
Theme
Tailwind 3.x
Describe the bug.
When a button is hidden, it shows a blank space.
By having the hidden buttons as a div element (even if they are null), they generate a space for the .pg-actions class
components/row.blade.php
To Reproduce...
Create three buttons in the Action column and hide the middle one with rule()
Extra information
The text was updated successfully, but these errors were encountered: