WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
51581
Web Inspector: Pasting a style property with value should automatically split it into prop/value
https://bugs.webkit.org/show_bug.cgi?id=51581
Summary
Web Inspector: Pasting a style property with value should automatically split...
temp01
Reported
2010-12-23 22:07:36 PST
1) Copy a style rule e.g. "color: red" (without quotes) 2) Double click in inspector/style panel to create a new rule 3) Try to paste style rule from 1) Currently, pasting the rule puts the whole rule (including value) in the "property" column/input and that doesn't work. It should either get split into the two input boxes automatically or inspector should parse it as a whole rule when you hit enter (with blank value).
Attachments
[PATCH] Suggested solution
(5.79 KB, patch)
2010-12-30 04:50 PST
,
Alexander Pavlov (apavlov)
pfeldman
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Alexander Pavlov (apavlov)
Comment 1
2010-12-30 04:50:22 PST
Created
attachment 77672
[details]
[PATCH] Suggested solution
Pavel Feldman
Comment 2
2010-12-30 05:15:52 PST
Comment on
attachment 77672
[details]
[PATCH] Suggested solution View in context:
https://bugs.webkit.org/attachment.cgi?id=77672&action=review
> WebCore/inspector/front-end/StylesSidebarPane.js:1589 > + var nameValue = data.split(":", 2);
If we are supporting pasting "name:value" snippets, why don't we support pasting name1 : value1; name2 : value2; name3 : value3; ?
Alexander Pavlov (apavlov)
Comment 3
2010-12-30 05:58:50 PST
(In reply to
comment #2
)
> (From update of
attachment 77672
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=77672&action=review
> > > WebCore/inspector/front-end/StylesSidebarPane.js:1589 > > + var nameValue = data.split(":", 2); > > If we are supporting pasting "name:value" snippets, why don't we support pasting > name1 : value1; > name2 : value2; > name3 : value3; > ?
It is not so easy to handle similar strings in the current editing infrastructure. I also envision a small UX inconsistency: a single name:value pair pasted into a new property does not commit it but allows tweaking of the name/value. In multiline texts, all properties but the last one should be committed and hence there is no way to tweak them as needed.
Alexander Pavlov (apavlov)
Comment 4
2010-12-30 09:27:21 PST
Committing to
http://svn.webkit.org/repository/webkit/trunk
... M WebCore/ChangeLog M WebCore/inspector/front-end/StylesSidebarPane.js M WebCore/inspector/front-end/inspector.js Committed
r74799
WebKit Review Bot
Comment 5
2010-12-30 12:25:34 PST
http://trac.webkit.org/changeset/74799
might have broken Leopard Intel Debug (Tests)
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