mocks.js (1548B)
1 /* Any copyright is dedicated to the Public Domain. 2 http://creativecommons.org/publicdomain/zero/1.0/ */ 3 /* eslint-disable comma-dangle */ 4 5 "use strict"; 6 7 /** 8 * Snapshot of the Redux state for the Changes panel. 9 * 10 * It corresponds to the tracking of a single property value change (background-color) 11 * within a deeply nested CSS at-rule structure from an inline stylesheet: 12 * 13 * ``` 14 * @media (min-width: 50em) { 15 * @supports (display: grid) { 16 * body { 17 * - background-color: royalblue; 18 * + background-color: red; 19 * } 20 * } 21 * } 22 * ``` 23 */ 24 module.exports.CHANGES_STATE = { 25 source1: { 26 type: "inline", 27 href: "http://localhost:5000/at-rules-nested.html", 28 id: "source1", 29 index: 0, 30 isFramed: false, 31 rules: { 32 rule1: { 33 selectors: ["@media (min-width: 50em)"], 34 ruleId: "rule1", 35 add: [], 36 remove: [], 37 children: ["rule2"], 38 }, 39 rule2: { 40 selectors: ["@supports (display: grid)"], 41 ruleId: "rule2", 42 add: [], 43 remove: [], 44 children: ["rule3"], 45 parent: "rule1", 46 }, 47 rule3: { 48 selectors: ["body"], 49 ruleId: "rule3", 50 add: [ 51 { 52 property: "background-color", 53 value: "red", 54 index: 0, 55 }, 56 ], 57 remove: [ 58 { 59 property: "background-color", 60 value: "royalblue", 61 index: 0, 62 }, 63 ], 64 children: [], 65 parent: "rule2", 66 }, 67 }, 68 }, 69 };