Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

576 - column edits with hidden columns #578

Merged
merged 5 commits into from
Sep 14, 2019
Merged

Conversation

alexcjohnson
Copy link
Collaborator

Fixes #576 - editing column names or deleting (and clearing, which already worked correctly, but I made sure it still does) columns while some columns are hidden.

Also fixes a minor issue I encountered along the way: if you click to edit a column name then click Cancel at the prompt, it would clear the name. Fixed it so now it keeps the previous name.

I chose two slightly different behaviors for merged columns with only part of the merged set hidden, but I think it makes sense:

  • For name edits, even the hidden pieces get renamed. The rationale being that if several columns have a merged header, that defines them as a category, and by editing that part of the name you're altering the category name, not altering what's in that category.
  • For deleting / clearing, nothing hidden is removed. Here I felt it was more important, because this is an irreversible change, to only affect things you can see.

This creates a weird edge case with name editing:

I'm torn about whether to consider this a bug or not... but there it is. It's pretty esoteric and I could see arguments either way

@Marc-Andre-Rivet
Copy link
Contributor

Would you mind documenting the edge case as a standalone issue.. let's say a bug + discussion needed so as to not lose track of it?

First reaction is that very little distinguishes a hidden column from a deleted column. I think it's more surprising to the user to see table 1 with deleted B go from A A -> C A and table 2 with hidden B go from A A -> C C then having both behave the same.

But you're right, this is not clear cut.

Copy link
Contributor

@Marc-Andre-Rivet Marc-Andre-Rivet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Just make sure to create an issue for the edge-case as described above.

Missing a changelog.

@alexcjohnson
Copy link
Collaborator Author

@Marc-Andre-Rivet changelog added and new issue created for the edge case mentioned #585 - any more comments?

@alexcjohnson alexcjohnson merged commit 293ee33 into master Sep 14, 2019
@alexcjohnson alexcjohnson deleted the 576-hidden-edits branch September 14, 2019 01:58
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug editing column names while columns are hidden
3 participants