Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(411)

Issue 441873010: DevTools: [SSP] Implement adding new rule in user stylesheet (Closed)

Created:
6 years, 4 months ago by lushnikov
Modified:
6 years, 4 months ago
Reviewers:
apavlov, vsevik
CC:
blink-reviews, caseq+blink_chromium.org, loislo+blink_chromium.org, eustas+blink_chromium.org, malch+blink_chromium.org, yurys+blink_chromium.org, lushnikov+blink_chromium.org, vsevik+blink_chromium.org, pfeldman+blink_chromium.org, paulirish+reviews_chromium.org, apavlov+blink_chromium.org, devtools-reviews_chromium.org, sergeyv+blink_chromium.org, aandrey+blink_chromium.org
Project:
blink
Visibility:
Public.

Description

DevTools: [SSP] Implement adding new rule in user stylesheet This patch implements an "add new rule" functionality to add a style rule in a user stylesheet. It is also possible to add rule inside media query rules. BUG=402461 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=180164

Patch Set 1 #

Patch Set 2 : support adding rules in MediaRule #

Patch Set 3 : full implementation of CSSAgent.addRule #

Patch Set 4 : rebaseline atop of 450533008 #

Patch Set 5 : implement front-end support #

Patch Set 6 : fix some tests #

Patch Set 7 : fix tests #

Patch Set 8 : minor changes #

Total comments: 14

Patch Set 9 : add test case with formatter rule #

Patch Set 10 : fix compilation error #

Unified diffs Side-by-side diffs Delta from patch set Stats (+951 lines, -128 lines) Patch
M LayoutTests/http/tests/inspector/elements-test.js View 1 2 3 4 5 6 1 chunk +10 lines, -5 lines 0 comments Download
A LayoutTests/inspector-protocol/css/css-add-rule.html View 1 2 3 4 5 6 7 8 1 chunk +179 lines, -0 lines 0 comments Download
A LayoutTests/inspector-protocol/css/css-add-rule-expected.txt View 1 2 3 4 5 6 7 8 1 chunk +416 lines, -0 lines 0 comments Download
M LayoutTests/inspector-protocol/css/css-create-stylesheet-and-add-rule.html View 1 2 3 4 5 6 7 2 chunks +8 lines, -2 lines 0 comments Download
M LayoutTests/inspector-protocol/css/css-create-stylesheet-and-add-rule-expected.txt View 1 2 3 4 5 6 1 chunk +8 lines, -2 lines 0 comments Download
M LayoutTests/inspector-protocol/css/css-protocol-test.js View 1 2 3 3 chunks +13 lines, -3 lines 0 comments Download
A LayoutTests/inspector-protocol/css/resources/add-rule.css View 1 2 1 chunk +21 lines, -0 lines 0 comments Download
M LayoutTests/inspector/elements/styles/add-new-rule-invalid-selector.html View 1 2 3 4 5 1 chunk +1 line, -6 lines 0 comments Download
M LayoutTests/inspector/elements/styles/add-new-rule-with-style-after-body.html View 1 2 3 4 5 1 chunk +1 line, -6 lines 0 comments Download
M LayoutTests/inspector/elements/styles/commit-selector-mark-matching.html View 1 2 3 4 5 1 chunk +1 line, -6 lines 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule.html View 1 2 3 4 5 6 1 chunk +6 lines, -2 lines 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule-colon.html View 1 2 3 4 5 6 1 chunk +6 lines, -2 lines 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule-colon-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule-expected.txt View 1 2 3 4 5 6 3 chunks +3 lines, -3 lines 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule-tab.html View 1 2 3 4 5 6 1 chunk +6 lines, -2 lines 0 comments Download
M LayoutTests/inspector/elements/styles/styles-add-new-rule-tab-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/inspector/elements/styles/styles-new-API.html View 1 2 3 4 5 6 1 chunk +7 lines, -1 line 0 comments Download
M LayoutTests/inspector/elements/styles/undo-add-new-rule-expected.txt View 1 2 3 4 5 6 3 chunks +2 lines, -2 lines 0 comments Download
M Source/core/inspector/InspectorCSSAgent.h View 1 2 3 4 5 6 7 1 chunk +1 line, -2 lines 0 comments Download
M Source/core/inspector/InspectorCSSAgent.cpp View 1 2 3 4 5 6 7 4 chunks +15 lines, -8 lines 0 comments Download
M Source/core/inspector/InspectorStyleSheet.h View 1 2 3 chunks +8 lines, -3 lines 0 comments Download
M Source/core/inspector/InspectorStyleSheet.cpp View 1 2 3 4 5 6 7 8 9 3 chunks +138 lines, -36 lines 0 comments Download
M Source/devtools/front_end/elements/StylesSidebarPane.js View 1 2 3 4 5 6 7 8 chunks +73 lines, -28 lines 0 comments Download
M Source/devtools/front_end/sdk/CSSStyleModel.js View 1 2 3 4 2 chunks +5 lines, -4 lines 0 comments Download
M Source/devtools/front_end/sidebarPane.css View 1 2 3 4 1 chunk +17 lines, -0 lines 0 comments Download
M Source/devtools/protocol.json View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -3 lines 0 comments Download

Messages

Total messages: 14 (0 generated)
lushnikov
The screenshot is attached to the bug, though it's not that interesting. Please, take a ...
6 years, 4 months ago (2014-08-11 15:19:13 UTC) #1
vsevik
https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector-protocol/css/css-add-rule.html File LayoutTests/inspector-protocol/css/css-add-rule.html (right): https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector-protocol/css/css-add-rule.html#newcode51 LayoutTests/inspector-protocol/css/css-add-rule.html:51: ruleText: "#test { content: 'EDITED'; }", Can we test ...
6 years, 4 months ago (2014-08-12 15:53:54 UTC) #2
lushnikov
https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector/elements/styles/styles-add-new-rule-colon-expected.txt File LayoutTests/inspector/elements/styles/styles-add-new-rule-colon-expected.txt (right): https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector/elements/styles/styles-add-new-rule-colon-expected.txt#newcode25 LayoutTests/inspector/elements/styles/styles-add-new-rule-colon-expected.txt:25: div#other { (inspector-stylesheet:5 -> inspector-stylesheet:5:1) On 2014/08/12 15:53:54, vsevik ...
6 years, 4 months ago (2014-08-12 15:57:02 UTC) #3
vsevik
https://chromiumcodereview.appspot.com/441873010/diff/130001/Source/devtools/front_end/elements/StylesSidebarPane.js File Source/devtools/front_end/elements/StylesSidebarPane.js (right): https://chromiumcodereview.appspot.com/441873010/diff/130001/Source/devtools/front_end/elements/StylesSidebarPane.js#newcode833 Source/devtools/front_end/elements/StylesSidebarPane.js:833: this.expand(); Why is this needed? https://chromiumcodereview.appspot.com/441873010/diff/130001/Source/devtools/front_end/elements/StylesSidebarPane.js#newcode1955 Source/devtools/front_end/elements/StylesSidebarPane.js:1955: var rulePrefix ...
6 years, 4 months ago (2014-08-12 16:06:01 UTC) #4
vsevik
lgtm https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector/elements/styles/styles-add-new-rule-colon.html File LayoutTests/inspector/elements/styles/styles-add-new-rule-colon.html (right): https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector/elements/styles/styles-add-new-rule-colon.html#newcode51 LayoutTests/inspector/elements/styles/styles-add-new-rule-colon.html:51: InspectorTest.selectNodeAndWaitForStyles("inspected", step5); I mean you select 'other' again ...
6 years, 4 months ago (2014-08-13 06:47:06 UTC) #5
lushnikov
https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector-protocol/css/css-add-rule.html File LayoutTests/inspector-protocol/css/css-add-rule.html (right): https://chromiumcodereview.appspot.com/441873010/diff/130001/LayoutTests/inspector-protocol/css/css-add-rule.html#newcode51 LayoutTests/inspector-protocol/css/css-add-rule.html:51: ruleText: "#test { content: 'EDITED'; }", On 2014/08/12 15:53:54, ...
6 years, 4 months ago (2014-08-13 09:10:49 UTC) #6
lushnikov
The CQ bit was checked by lushnikov@chromium.org
6 years, 4 months ago (2014-08-13 09:10:57 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/lushnikov@chromium.org/441873010/150001
6 years, 4 months ago (2014-08-13 09:11:53 UTC) #8
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_blink_dbg on tryserver.blink ...
6 years, 4 months ago (2014-08-13 09:47:18 UTC) #9
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 4 months ago (2014-08-13 09:54:19 UTC) #10
commit-bot: I haz the power
Try jobs failed on following builders: linux_blink_dbg on tryserver.blink (http://build.chromium.org/p/tryserver.blink/builders/linux_blink_dbg/builds/21121)
6 years, 4 months ago (2014-08-13 09:54:19 UTC) #11
lushnikov
The CQ bit was checked by lushnikov@chromium.org
6 years, 4 months ago (2014-08-13 10:09:47 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/lushnikov@chromium.org/441873010/170001
6 years, 4 months ago (2014-08-13 10:10:05 UTC) #13
commit-bot: I haz the power
6 years, 4 months ago (2014-08-13 11:09:22 UTC) #14
Message was sent while issue was closed.
Change committed as 180164

Powered by Google App Engine
This is Rietveld 408576698