rappasoft/laravel-livewire-tables

[Feature Request]: Add a hideValueIf option for Column.

amshehzad opened this issue · 3 comments

Overview

I think it'll be nice to pass the current row to hideIf so we can hide the column based on the row value e.g if a row is created_by admin, hide it

Detailed explanation

No response

Notes

No response

as discussed, suggest a hideValueIf approach

Assigned to @amshehzad initially, but can review

Should add the method hideValueIf() with a callback:

hideValueIf(callback $callback)

The end code should add the usual functions has/get/set for the hideValueIf

If the hideValueIf callback returns false, the value should be returned
If the hideValueIf callback returns true, the value should not be returned

This should not use classes to hide the content, but actually remove the content, and return an empty