laravel-livewire-tables icon indicating copy to clipboard operation
laravel-livewire-tables copied to clipboard

[Feature Request] ImageColumn - Conditional Rendering of IMG Tag

Open lrljoe opened this issue 6 months ago • 1 comments

          One suggestion I would make is to somehow support conditional rendering of the `<img>` tag.

This would be useful in cases where, for example, not all products have an image. I'm currently handling this by displaying a placeholder:

->location(fn($row) => $row->default_image ?? Vite::image('placeholders/1x1.png')

However, it could be preferable for some use cases to just not render the <img> tag at all if the location value is empty.

Originally posted by @nathan-io in https://github.com/rappasoft/laravel-livewire-tables/issues/1601#issuecomment-1867999117

lrljoe avatar Dec 29 '23 18:12 lrljoe

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jan 30 '24 04:01 stale[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Mar 02 '24 06:03 stale[bot]