New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 701336 link

Starred by 2 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Mac
Pri: 2
Type: Bug



Sign in to add a comment

adding class to table in inspector fails first time

Reported by ian.mo...@gmail.com, Mar 14 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.98 Safari/537.36

Steps to reproduce the problem:
1. load a page with a <table> on it that does not have a class
2. right click then inspect table
3. double click on <table> tag to edit it
4. move caret right to get to the end of the "table" text before the  right angle bracket.
5. enter [SPACE]class="a" to try and add a class
6. hit return
7. your "class="a"" will vanish and you will be left with a focused but empty editing box
8. add [SPACE]class="a" again and hit enter again.
9. This time your new class="a" fragment will stick

What is the expected behavior?
You should not have to add a class="xxx" fragment twice to get it to stick

What went wrong?
The initial addition of a class="xxx" fragment fails.

Did this work before? N/A 

Chrome version: 57.0.2987.98  Channel: stable
OS Version: OS X 10.10.4
Flash Version: 

Not a big thing, but annoying when you need to do it frequently.
 
Labels: prestable-57.0.2987.98 Needs-Triage-M57
Cc: brajkumar@chromium.org
Labels: Needs-Feedback
Reporter@ Thanks for filing the issue, could you please provide us with a sample test case file to test this issue from Chrome-TE end?

Thanks!

Comment 3 by ian.mo...@gmail.com, Mar 15 2017

File attached.  Having looked further I can see what is happening now and it seems like more of a simple non-intuitive interface issue. Basically:

1) Double clicking on a tag name in the DOM inspector and then pressing the right arrow key and entering a space character make it feel like you can then add parameters such as class names and ids and style etc. In fact you are simply editing the class name, which fails when you enter lots of gloop that is invalid for class names.

2) If, rather than double clicking on the tag name and hitting the right arrow key to get the caret where you want it, you instead double click on the tag name and THEN single click on the right closing angle bracket, you get put into the mode where you can edit parameters such as class names etc.

3) The behaviour I reported is then basically you editing the tag name, the edit failing / silently discarding your corrupted tag name, and then popping you along to the parameter editing box, where your second attempt then succeeds as your are now starting off in the right editing box.

4) This only shows up when you edit tags which have no parameters. When tags have parameters you naturally click somewhere in that area and not on the tag name to initiate editing.
sample.html
837 bytes View Download
Project Member

Comment 4 by sheriffbot@chromium.org, Mar 15 2017

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding requester "brajkumar@chromium.org" to the cc list and removing "Needs-Feedback" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 5 by ian.mo...@gmail.com, Mar 15 2017

(re: my comment above)

Sorry, Paragraph 1 should read:

1) Double clicking on a tag name in the DOM inspector and then pressing the right arrow key and entering a space character make it feel like you can then add parameters such as class names and ids and style etc. In fact you are simply editing the TAG name, which fails when you enter lots of gloop that is invalid for TAG names.
Components: -Platform>DevTools Platform>DevTools>Authoring
Labels: -Needs-Triage-M57 -prestable-57.0.2987.98 OS-Linux
Owner: einbinder@chromium.org
Status: Assigned (was: Unconfirmed)
Reproduced this on 59.0.3045.0 (Developer Build) (64-bit). I agree it's non-intuitive.
Project Member

Comment 7 by bugdroid1@chromium.org, Mar 27 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/eee703e7951bd989052d3d5bb326baa465863a51

commit eee703e7951bd989052d3d5bb326baa465863a51
Author: Joel Einbinder <einbinder@chromium.org>
Date: Tue Mar 27 03:24:42 2018

DevTools: Commit tag name editing on Space

When editing the tag of an Element, the user pressing space indicates
that they want to move on to editing an attribute. We have similar logic
in the StylesSidebar when the user presses : or ;.

Bug: 701336
Change-Id: Ib087a6e5a898ba9fb7c599f3d60ef3126ce66f4e
Reviewed-on: https://chromium-review.googlesource.com/976816
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Commit-Position: refs/heads/master@{#545961}
[modify] https://crrev.com/eee703e7951bd989052d3d5bb326baa465863a51/third_party/WebKit/Source/devtools/front_end/elements/ElementsTreeElement.js

Labels: TE-Verified-M67 TE-Verified-67.0.3382.0
> Able to reproduce this issue on chrome latest stable #65.0.3325.181

> Verified this issue after fix on Ubuntu 14.04 and Mac OS 10.13.3 using chrome latest canary #67.0.3382.0 by following test case provided in comment #3. Observed able to add "class=xx" to table at first attempt as expected. Hence adding TE-Verified label for M67. 

Thanks!


Sign in to add a comment