GitHub user syncroniq-janthiart edited a discussion: feat: column 
picker/visibility toggle for large tables

Most programs offer a column dropdown or picker menu when viewing large tables. 
While a chart editor can select which columns to add to a chart, read-only 
users, especially on embedded dashboards, are not so lucky as they can only 
ever see the full table. Tables with many columns can requiire horizontal 
scrolling, or they may look good on a large 4k screen but become a hassle on 
smaller ones.

Therefore, I would like to introduce a column visibility picker dropdown to the 
regular table chart (can of course be extended to other plugins as well, but 
would like to get a 👍 or 👎 first).

## What this does
* Adds a small column picker button next to existing table controls (usually 
shows up next to search bar).
* Click on button opens picker menu with option to select all, none (but at 
least 1), or any number of columns in between.
* Selection is for *visibility only*. User can only pick columns defined by the 
table chart.
* (De-)Selecting a column immediately updates the chart to show/not show the 
column.


## Demo:
https://github.com/user-attachments/assets/6497fd54-bb9b-4999-8850-623660f35578

Option must be enabled by chart editors:
<img width="322" height="948" alt="grafik" 
src="https://github.com/user-attachments/assets/6037d1d4-bcea-49d4-bffa-8cf6b71c49be";
 />

## Details
The change is very limited, only a couple of lines in TableChart + new 
component. The component is "persistent enough" (survives tab switches, does 
not survive reloads, recognizes updates to columns) and relies on visibility 
switches only - no cross-talk with any CSV downloads or similar kinds of 
functionality.

I would open a PR, but "discussion first" seems to be the go-to for new 
contributors. :)

https://github.com/syncroniq-janthiart/superset/tree/feat/user-column-selector-table



GitHub link: https://github.com/apache/superset/discussions/40767

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to