WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
132090
Web Inspector: CSS autofill suggests properties instead of values when values are needed
https://bugs.webkit.org/show_bug.cgi?id=132090
Summary
Web Inspector: CSS autofill suggests properties instead of values when values...
Jonathan Wells
Reported
2014-04-23 16:34:39 PDT
In the styles sidebar, property names are suggested in place of values. For instance, 'display: b' should suggest 'block' but instead 'background' and other possible property names appear.
Attachments
[PATCH] Proposed Fix: Updated to CSS mode handling to fix autocomplete, other issues
(34.82 KB, patch)
2014-04-24 14:50 PDT
,
Jonathan Wells
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2014-04-23 16:35:55 PDT
<
rdar://problem/16706366
>
Jonathan Wells
Comment 2
2014-04-24 14:50:14 PDT
Created
attachment 230108
[details]
[PATCH] Proposed Fix: Updated to CSS mode handling to fix autocomplete, other issues
Joseph Pecoraro
Comment 3
2014-04-24 14:59:30 PDT
Comment on
attachment 230108
[details]
[PATCH] Proposed Fix: Updated to CSS mode handling to fix autocomplete, other issues View in context:
https://bugs.webkit.org/attachment.cgi?id=230108&action=review
r=me
> Source/WebInspectorUI/ChangeLog:13 > + data structure. All references to state.stack are obscelete. Many
Typo: obscelete
> Source/WebInspectorUI/ChangeLog:884 > - Add missing semicolon. > + Add missing semicolon.
I wonder if commit queue will allow a patch that fixes this trailing whitespace. Maybe it will, maybe it won't.
> Source/WebInspectorUI/Tools/PrettyPrinting/CodeMirrorFormatters.js:398 > + if (!state.stack || !state.stack.length || state.stack.lastValue === "@media{")
These only fix the exception, but I assume they don't make CSS pretty printing work?
Jonathan Wells
Comment 4
2014-04-24 15:20:37 PDT
That's right, this just fixes the exception. See
https://bugs.webkit.org/show_bug.cgi?id=132149
Jonathan Wells
Comment 5
2014-04-24 15:22:17 PDT
Good question re: the whitespace. I meant to remove that and did so incorrectly. That should be done in a separate patch probably.
WebKit Commit Bot
Comment 6
2014-04-24 15:29:44 PDT
Comment on
attachment 230108
[details]
[PATCH] Proposed Fix: Updated to CSS mode handling to fix autocomplete, other issues Clearing flags on attachment: 230108 Committed
r167779
: <
http://trac.webkit.org/changeset/167779
>
WebKit Commit Bot
Comment 7
2014-04-24 15:29:47 PDT
All reviewed patches have been landed. Closing bug.
Timothy Hatcher
Comment 8
2014-04-24 17:01:13 PDT
Comment on
attachment 230108
[details]
[PATCH] Proposed Fix: Updated to CSS mode handling to fix autocomplete, other issues View in context:
https://bugs.webkit.org/attachment.cgi?id=230108&action=review
> Source/WebInspectorUI/UserInterface/Controllers/CodeMirrorCompletionController.js:523 > + if (!mainToken.state || !mainToken.state.state || !mainToken.state.state === "block") > return [];
This is not right. The while loop later looks for "prop", but this returns early if there is no "block" state. This needs to do a similar contains check up the state stack for "block". As-is only proper name completions will work, property value completions will not work. But maybe you intended to fix this in the other bug.
Jonathan Wells
Comment 9
2014-04-24 17:34:26 PDT
Yes, this was just a quick fix to avoid total breakage of the inspector. Plan to rework in
https://bugs.webkit.org/show_bug.cgi?id=132149
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug