For simple rules like function spacing, we can auto-fix these across the code
base so they are followed in a consistent way.
To generate this patch, I ran:
./mach eslint devtools --no-ignore --fix
After this, I reverted any changes to third party files that we really do want
to ignore.
MozReview-Commit-ID: 6Q8BApkAW20
Add support for both syntax in CssColor
Add support in value increment
Edit several tests to make sure we handle these syntaxes all across the inspector (display swatch,
color increment, unit switching, …).
MozReview-Commit-ID: FLw9va3i8H0
--HG--
extra : transplant_source : m%24%C9%E1%EFQ%18%C3%0C%8F%C6%DB%E8%E5%D2%7D%A8c%5Bl
The breadcrumbs widget used to have a feature where it would show the first
child of the current selection even the DOM tree hadn't been expanded that
far yet.
This was to allow keyboard navigating the DOM through the breadcrumbs.
The breadcrumbs is a very rarely used widget and this code was unnecessarily
making things complex.
It was decided that this feature would be removed.
Instead, the breadcrumbs now act as simple linear elements in a toolbar and
you can keyboard navigate them with LEFT/RIGHT only. TAB/shift-TAB simply go
in/out of the breadcrumbs widget.
MozReview-Commit-ID: BmcaLnVBOBn
--HG--
extra : rebase_source : 1673a6c9da02cf8b3b542e4ce905ccb239250aa7
- StyleRuleActors now parse declarations and send them within the form
- Each declaration also contains isValid flag
- Parsing is still done client side for old backends (back compat)
- Declarations are sent with the form, so updated every time the rule changes
- Also made StyleRuleActors send the declarations array for element styles, and made canSetRuleText true for this, since we can simply set the style attribute
MozReview-Commit-ID: 2nI4bRyvwwi
--HG--
extra : rebase_source : 0ccfaeb0edb0b1a60a7c0d741295d61ad66ac57e
Previously, the targetNodeCb used in TooltipToggle had an inconsistent API. If
returning synchronously, "false" would prevent the tooltip from appearing.
However, if using a promise, resolving "false" would still show the tooltip.
It was needed to reject the promise in this case to prevent the tooltip from
being displayed.
This commit makes TooltipToggle always expect a consistent return value from
this callback, whether it is synchronous, or using promises.
- true -> show the tooltip on the event target
- DOM node -> show the tooltip on the provided node
- false (or falsy value) -> do not show the tooltip
MozReview-Commit-ID: 7PIPwBJxjWO
--HG--
extra : rebase_source : 279bab30f631a3a65a93b52226c6980210abf2f1
The code used to make the tooltip appear/disappear when hovering targets
has been extracted to a separate class that can be shared between the
current Tooltip.js implementation and the upcoming HTMLTooltip.
MozReview-Commit-ID: UYSjPFeMYK
--HG--
extra : rebase_source : 5dcca2d5887ffc98fec621092640073a0909c13f
Usability changes to the ruleview autocomplete:
- max suggestions is now capped to 500 to make sure as many suggestions as possible
as possible are displayed
- vendor-prefixed properties are moved to the end of the list
- !important is no longer the first suggested item
MozReview-Commit-ID: AOfHyqS3n8s
--HG--
extra : rebase_source : 5a4842974672bebc7427a546b4e4014201147465
extra : histedit_source : 0c008a8e7aedb60c2df0774977e54074702d555d
Make sure that result node id is not empty before appending it to the results
MozReview-Commit-ID: 5SuTrNf4t8v
--HG--
extra : transplant_source : E%AF%D7%A9W%DC%C6u%8B%9F%FF%00%A7%FEY%1A%7E%CA%AE%95
Add an ATTRIBUTE search state to better handle attribute's search.
Edit test to make sure we handle it right
MozReview-Commit-ID: ADcIJRbhjO
--HG--
extra : transplant_source : %C7R%AC%EE%2A%BA%C1%FE%B4%E4%D3%B0%D6c%B1%AB%B5%04%C6%CB
To create new rules, style elements are added to the content document.
For nodes located in an iframe, the style element should be added to the
ownerDocument of this particular node.
MozReview-Commit-ID: 7ynd7YU3WeL
--HG--
extra : rebase_source : 48e989e229b7972101c2761c881127244530273d
Though, if the element has pseudo-elements, and thus can be expanded, show
the closing tag when the void element is expanded.
MozReview-Commit-ID: 7UMMlVjYqLX
5 tests of the styleeditor suite are importing shared/test/head.
Now that this also includes shared-head.js, it conflicts with the existing
styleeditor head file.
For now, the import was moved to the head, so it's always imported.
The tests have been updated accordingly.
Should file a follow-up to split the inspector test suites head files in a
head.js + helpers.js (see commandline/test). It should be possible to
include helpers in other tests without impact on the test lifecycle.
MozReview-Commit-ID: BU3LiEr0UtZ
--HG--
extra : rebase_source : b0b232e25f387238b5c7256691992c7fcc7ff929
shared/test/head had custom methods to open the Computed & Rule view.
They did not register any test actor and could be called several times
in the same test.
In order to reuse the openInspector method from inspector/test/head, the
tests have been modified.
We are moving from
openRuleView() -> do rule view tests -> openComputedView() -> do computed view tests
to
openInspector() -> select rule view -> do rule view tests -> select computed view -> do computed view tests
A bit more verbose for the tests themselves, but this will be useful when
migrating the shared tests to using the testActor.
MozReview-Commit-ID: 94cOqhPICyI
--HG--
extra : rebase_source : f7892af19b78ecdbb759fb21d17920f0f6e0f4c6