Граф коммитов

27115 Коммитов

Автор SHA1 Сообщение Дата
Tooru Fujisawa bfb39b4a60 Bug 1847469 - Part 9: Use column number types in SavedFrame API. r=iain
Differential Revision: https://phabricator.services.mozilla.com/D185747
2023-08-16 10:26:29 +00:00
Tooru Fujisawa ca7ba27825 Bug 1847469 - Part 8: Use column number types in ubi. r=iain
Differential Revision: https://phabricator.services.mozilla.com/D185746
2023-08-16 10:26:29 +00:00
Nicolas Chevobbe 6d6a70bb42 Bug 1840872 - [devtools] Show `::highlight` pseudo element in rules view. r=devtools-reviewers,ochameau.
We need to do things a bit differently than for other pseudo elements as
`InspectorUtil.getCSSStyleRules` expects the highlight function + the highlight
name (e.g. `::highlight(myHighlight)`.
We loop through all registered Highlights via `CSS.highlights` and only consider
the ones that are currently used in the page (i.e. their `size` is > 0).
A test is added to ensure everything works as expected.

Differential Revision: https://phabricator.services.mozilla.com/D184551
2023-08-16 09:56:43 +00:00
Nicolas Chevobbe 69d2ab5554 Bug 1847517 - [devtools] Tweak preview popup style. r=devtools-reviewers,ochameau.
Don't display the arrow on the root node, and remove the ability to collapse it.
Add a border at the bottom of the root node so it looks like a header
Add a new `HEADER` Rep mode that will be used for the root node, so we're
showing relevant information in this context (e.g. the object type/class name)
but not the preview when it would be redundant with the content of the tooltip.

For example, we don't want to show the preview for simple objects, arrays, maps, …
but we still have a "longer" description for objects where the properties in
the preview are handpicked (e.g. elements, window, document, …)

Differential Revision: https://phabricator.services.mozilla.com/D185770
2023-08-16 09:53:17 +00:00
Emilio Cobos Álvarez 0cd41b3262 Bug 1847440 - Other misc cleanups in style-rule.js. r=nchevobbe,devtools-reviewers
No need to explicitly return a promise in async functions.

Depends on D185916

Differential Revision: https://phabricator.services.mozilla.com/D186090
2023-08-16 09:36:56 +00:00
Emilio Cobos Álvarez 6b114cbb5f Bug 1847440 - Part 2: Simplify some callers now that getAuthoredCssText doesn't throw. r=nchevobbe,devtools-reviewers
Depends on D185906

Differential Revision: https://phabricator.services.mozilla.com/D186089
2023-08-16 09:12:34 +00:00
Emilio Cobos Álvarez 55eec79fa6 Bug 1847440 - Part 1: Cache failure in getAuthoredCssText(). r=nchevobbe,devtools-reviewers
If our line numbers etc are wrong, then we might throw and retry later.

Given the empty string already represents failure, make
getAuthoredCssText not throw and just return the empty string on
failure.

This avoids retrying over and over just to fail. It doesn't fix the
initial hang, but makes it more manageable.

Will still try to find a proper fix / root cause of course, but this
seems harmless enough either way.

Differential Revision: https://phabricator.services.mozilla.com/D185906
2023-08-16 09:12:34 +00:00
Emilio Cobos Álvarez 4701bd9d26 Bug 1847440 - Part 0: Split canSetRuleText so that it's easier to follow. r=nchevobbe,devtools-reviewers
No behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D186088
2023-08-16 09:12:33 +00:00
Nicolas Chevobbe d81e60336d Bug 1792737 - [devtools] Handle undefined DebuggerObject.environment in JQueryLiveEventCollector. r=devtools-reviewers,ochameau.
This could cause the event tooltip to not be displayed for some jQuery events.
A test is added to ensure we don't regress this.

Differential Revision: https://phabricator.services.mozilla.com/D185976
2023-08-16 07:24:51 +00:00
Nicolas Chevobbe 83325686ef Bug 1848119 - [devtools] Remove unnecessary PageStyleActor#_expandRules. r=devtools-reviewers,jdescottes.
Depends on D184728

Differential Revision: https://phabricator.services.mozilla.com/D185915
2023-08-16 07:24:29 +00:00
jackyzy823 f569bcae2f Bug 1847513 - Fix typo in DevToolsUtils.js. r=devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D186072
2023-08-14 21:59:42 +00:00
Sebastian Zartner 742cbfe525 Bug 1583912 - [devtools] Handle ignored properties in non-multi-column containers in inactive CSS. r=devtools-reviewers,fluent-reviewers,flod,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D186096
2023-08-14 20:41:29 +00:00
Sebastian Zartner b9571502ba Bug 1583906 - [devtools] Handle 'empty-cells' property in inactive CSS. r=devtools-reviewers,fluent-reviewers,flod,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D186082
2023-08-14 20:14:34 +00:00
Iulian Moraru c5d2f8a7d1 Backed out changeset bc9a3a0b8e55 (bug 1847517) for causing Bug 1848531. 2023-08-14 18:55:39 +03:00
Cosmin Sabou 34c18a6638 Bug 1804489 - Disable browser_dbg-inspector-integration.js on all platforms because of frequent failures. a=test-only 2023-08-12 10:56:06 +03:00
Tooru Fujisawa 441e14104a Bug 1846913 - Part 1: Use 1-origin column number for compile errors, compile wanring, and error notes. r=iain,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185370
2023-08-11 08:11:48 +00:00
Noemi Erli 3f8108db03 Backed out 4 changesets (bug 1776831) for causing failures in browser_rules_add-rule-and-remove-style-node.js CLOSED TREE
Backed out changeset e4dbab6b2e3f (bug 1776831)
Backed out changeset bba9f83f2d27 (bug 1776831)
Backed out changeset f77f0a2577a1 (bug 1776831)
Backed out changeset c306b234b8ca (bug 1776831)
2023-08-11 10:26:04 +03:00
Tooru Fujisawa 8d94c528d7 Bug 1846760 - Part 3: Move help shortcut "help" to evalWithDebugger. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185884
2023-08-11 06:41:12 +00:00
Tooru Fujisawa d3b49e15a5 Bug 1846760 - Part 2: Move help shortcut "?" to evalWithDebugger. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185883
2023-08-11 06:41:12 +00:00
Tooru Fujisawa 77997b4893 Bug 1846760 - Part 1: Add dedicate-simplified path for ':command'. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185882
2023-08-11 06:41:12 +00:00
Tooru Fujisawa abefaadaf1 Bug 1847222 - Always define bindings if options.disableBreaks is true. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185881
2023-08-11 06:41:12 +00:00
Nicolas Chevobbe 14e88e2b98 Bug 1776831 - [devtools] Refresh ruleview when inspector is selected. r=devtools-reviewers,jdescottes.
We are already refreshing the view when the sidebar is selected (so for example,
going from the layout to the rules view), but we were not refreshing it when
selecting the panel (so for example, going from the styleeditor to the inspector,
while the rule view is the active sidebar panel).

While writing a test, I realized `CssRuleView#isPanelVisible` was always returning
true when the 3 pane mode is enabled, even if the inspector isn't the active tool,
which is incorrect, so I fixed it.

A test is added to ensure we covers this, by adding a stylesheet from the style editor.

Differential Revision: https://phabricator.services.mozilla.com/D185560
2023-08-11 06:13:34 +00:00
Nicolas Chevobbe 865b966274 Bug 1776831 - [devtools] Control RuleViewTool with an AbortController. r=devtools-reviewers,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D185558
2023-08-11 06:13:33 +00:00
Nicolas Chevobbe d3dc17a0cc Bug 1776831 - [devtools] Turn RuleViewTool into an ES6 class. r=devtools-reviewers,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D185557
2023-08-11 06:13:33 +00:00
Nicolas Chevobbe fbb3944d04 Bug 1776831 - [devtools] Refresh rules view on STYLESHEET resource available. r=jdescottes,devtools-reviewers.
Differential Revision: https://phabricator.services.mozilla.com/D185393
2023-08-11 06:13:33 +00:00
Eemeli Aro a5dabe8f0d Bug 1834305 - Remove intl/locale/PluralForm.sys.mjs as unused. r=nordzilla,devtools-reviewers
This library is now completely unused in m-c.

Differential Revision: https://phabricator.services.mozilla.com/D185699
2023-08-10 20:39:20 +00:00
Takeshi Kurosawa 81ea82b670 Bug 1546003 - [markup view] Linkify ARIA attributes. r=devtools-reviewers,nchevobbe
Add support to linkify ARIA attributes referencing other elements in Inspector.

Differential Revision: https://phabricator.services.mozilla.com/D95682
2023-08-10 19:40:23 +00:00
Nicolas Chevobbe 723ec06e07 Bug 1845730 - [devtools] Don't return rules from PageStyleActor#getApplied. r=devtools-reviewers,devtools-backward-compat-reviewers,jdescottes.
The property isn't used anywhere, but those objects would still be serialized
(via `form()`) and sent to the client.
Specs are updated to reflect the new situation, and handle backward compatibility.

Differential Revision: https://phabricator.services.mozilla.com/D184728
2023-08-10 14:54:19 +00:00
Nicolas Chevobbe 65faf2c8f8 Bug 1771113 - [devtools] Remove stylesheets from StyleEditor on STYLESHEET resource destroyed. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D185791
2023-08-10 14:36:04 +00:00
Nicolas Chevobbe a825b29421 Bug 1771113 - [devtools] Notify about removed stylesheet resources. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D185790
2023-08-10 14:36:04 +00:00
Alexandre Poirot bc10fd3dc9 Bug 1841573 - [devtools] Avoid using a unique tab for all sources without a url. r=devtools-reviewers,nchevobbe
We were using a unique tab for all sources without a URL.
This forced to update tab's title and text content everytime a new source without a URL was notified by the server.

Even if we don't pause on these new evaled scripts, we would still update the text content which may freeze firefox when instantiating lots of scripts.

Differential Revision: https://phabricator.services.mozilla.com/D185549
2023-08-10 12:36:58 +00:00
Narcis Beleuzu 77dd6aa381 Backed out changeset b544a2a99919 (bug 1546003) for dt failures on browser_markup_links_aria_attributes.js 2023-08-10 15:41:51 +03:00
Takeshi Kurosawa 287025b116 Bug 1546003 - [markup view] Linkify ARIA attributes. r=devtools-reviewers,nchevobbe
Add support to linkify ARIA attributes referencing other elements in Inspector.

Differential Revision: https://phabricator.services.mozilla.com/D95682
2023-08-10 11:39:48 +00:00
Florian Quèze bdaa3415cc Bug 1838497 - Add a profiler feature to record the clock frequency of every core while sampling, r=canaltinova.
Differential Revision: https://phabricator.services.mozilla.com/D180983
2023-08-10 10:27:14 +00:00
Nicolas Chevobbe d11c1d6a01 Bug 1847517 - [devtools] Tweak preview popup style. r=devtools-reviewers,ochameau.
Don't display the arrow on the root node, and remove the ability to collapse it.
Add a border at the bottom of the root node so it looks like a header
Add a new `HEADER` Rep mode that will be used for the root node, so we're
showing relevant information in this context (e.g. the object type/class name)
but not the preview when it would be redundant with the content of the tooltip.

For example, we don't want to show the preview for simple objects, arrays, maps, …
but we still have a "longer" description for objects where the properties in
the preview are handpicked (e.g. elements, window, document, …)

Differential Revision: https://phabricator.services.mozilla.com/D185770
2023-08-10 10:17:56 +00:00
Alexandre Poirot e6b9f12a45 Bug 1792803 - [devtools] Stop exposing devtools resource to content to implement JSON Viewer. r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D185551
2023-08-09 13:36:05 +00:00
Alexandre Poirot fa14472665 Bug 1792803 - [devtools] Load JSON viewer modules from resource://devtools/. r=devtools-reviewers,Gijs,nchevobbe
This reproduces the current setup of PDF.js.
Using request's `owner` attribute to allow JSON files to load devtools modules
used to implement the JSON Viewer.

This helps use the same URL for devtools modules.

Differential Revision: https://phabricator.services.mozilla.com/D158318
2023-08-09 13:36:05 +00:00
Alexandre Poirot ab708dfa41 Bug 1847753 - [devtools] Stop storing pseudo elements in properties-db. r=devtools-reviewers,nchevobbe
This appears to be unused and only page-actor is reading the list of all pseudo elements
by querying InspectorUtils directly.

Differential Revision: https://phabricator.services.mozilla.com/D185664
2023-08-09 13:30:40 +00:00
Nicolas Chevobbe 79b767af4b Bug 1845731 - [devtools] Cache StyleRule desugared selectors. r=devtools-reviewers,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D184727
2023-08-09 06:01:56 +00:00
Nicolas Chevobbe e58c09ac53 Bug 1847565 - [devtools] Speedup StyleSheetsManager#getStyleSheetRuleCountAndAtRules . r=devtools-reviewers,jdescottes.
Don't check if rules are instances of `CSSGroupingRule` (as `CSSStyleRule` would
match now, so it's not providing the guard we want anymore).
Avoid retrieving stylesheet window and document until it's needed, and only
compute rule line and column for the at-rules we'll return.

Differential Revision: https://phabricator.services.mozilla.com/D185636
2023-08-09 05:25:57 +00:00
Nicolas Chevobbe b957e6496f Bug 1847747 - [devtools] Ignore devtools-highlighter-styles/highlighters.css in regular toolbox. r=devtools-reviewers,jdescottes.
Differential Revision: https://phabricator.services.mozilla.com/D185661
2023-08-09 04:57:15 +00:00
Julian Descottes ec53592eaa Bug 1847498 - [devtools] Fix and update browser_net_resend_cors to check for ORB blocked requests r=devtools-reviewers,nchevobbe
The test has been incorrectly refactored and did not assert the resent requests.
We are fixing the test and also checking that the requests are not blocked.

Differential Revision: https://phabricator.services.mozilla.com/D185537
2023-08-08 07:58:59 +00:00
Boris Chiou 378ff4b2f1 Bug 1598158 - Support offset-path:url() in style. r=devtools-reviewers,emilio
In layout, we build a default `path("m 0 0")` for now. We will implement
it later.

Besides, we don't support compositor animations for `url()`, so we don't
have to serialize it for IPC.

Note:
`<url>` includes `url()` and `src()`. For now we only support `url()`.
We should revisit `src()` in Bug 1845390.

Differential Revision: https://phabricator.services.mozilla.com/D184429
2023-08-07 22:04:01 +00:00
Tom Schuster 6941e534d8 Bug 1845127 - Await both messages. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185540
2023-08-07 14:11:06 +00:00
Gregory Pappas d317aecd00 Bug 1847285 - Remove unused devtools.storage.test.forceLegacyActors r=devtools-reviewers,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D185467
2023-08-07 12:33:49 +00:00
Tooru Fujisawa c2fa29e8f5 Bug 1842701 - Part 5: Add tests for devtools. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D184328
2023-08-07 12:12:25 +00:00
Tooru Fujisawa 31a3563e77 Bug 1842701 - Part 2: Use CompileGlobalScriptWithExtraBindings in Debugger.Object.prototype.executeInGlobalWithBindings unless useInnerBindings option is specified. r=nbp,devtools-reviewers,nchevobbe
In order to keep the compatibility with DevTools internal methods, the existing
behavior where all bindings are shadowed is kept as `useInnerBindings` option.

Differential Revision: https://phabricator.services.mozilla.com/D184197
2023-08-07 12:12:23 +00:00
Tooru Fujisawa dca77df12a Bug 1842701 - Part 1.9: Directly call command function for :command style. r=nchevobbe,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D185115
2023-08-07 12:12:23 +00:00
Hubert Boma Manilla 1e1380ba5e Bug 1828573 - [devtools] Remove the jsx plugin from the build script r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D185049
2023-08-07 07:40:18 +00:00
Hubert Boma Manilla 87c3487eaa Bug 1828573 - [devtools] Convert all component jest tests from jsx r=devtools-reviewers,nchevobbe
Depends on D184937

Differential Revision: https://phabricator.services.mozilla.com/D185521
2023-08-07 07:40:17 +00:00