Re: [w3c/editing] Should deleting cell's content on a table inside a contenteditable area imply the whole table has to be deleted ? (#163)

> Consider the case of an user deleting content cell by cell, just to replace it with new content, and once it reaches the last cell the whole table is deleted.

Ok, but that seems like a slightly different case, right? In the case you showed above, the user was selected all contents of the table in one operation and then hits delete/backspace, the entire thing is gone. If the user instead selected the contents of individual cells and deletes them individually (before refilling), the same is not happening.

The reason I would go with the Chrome/Webkit behavior is that it's not really clear to the user whether she/he has selected the table contents or the table itself (no visual difference as far as I can tell), and in most cases (my guess) they will want to have selected the table rather than the table contents when deleting. Also, without the extra controls that only Firefox automatically adds to tables, there is no good way of deleting the entire table. Is there? 

I can see this can people having preferences of either type. It probably depends a lot on how tables are used in the given JS editor and what purpose they have there. In the end the JS editor will be deciding how to handle this and whether it needs to add some extra styling to the table if the entire table is selected to make the distinction clearer to the end user. 

So I think maybe the question of what should happen by default is less important as that the same happens in all browsers so that JS editor programmers have an easier time building their tools. So for example, that means getting rid of those extra default table controls in Firefox (as is happening alread). And maybe -- if this is not possible already without JavaScript -- it would be an idea to see if there is some way to distinguish visiually between selecting all cells of a table and selecting the entire table. 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/editing/issues/163#issuecomment-388103329

Received on Thursday, 10 May 2018 16:15:13 UTC