Create some css variables matching the ones found in common.css (we cannot import common.css as is, as it brings too many default styles not
scoped to a specific classname etc...).
The main changes should be around the colors of links and of the selected category in the left sidebar
The separator in the sidebar also uses different colors in light/dark theme, mostly to be able to follow the base border color.
Differential Revision: https://phabricator.services.mozilla.com/D159664
This patch tries to cover a few things :-
1) The `location` object now also maintains an optional `sourceActorId` property
2) `selectSource` now takes an optional `sourceActor` argument which is used to
augument the `location` object and passed to `selectLocation` then onto
`loadSourceText` function to load the specific source text.
3) A new selector `getFirstSourceActorForGeneratedSource` to select the source actor to load the
source text.
4) `LoadSourceText`now always track the selected source actor (which should load the source text)
each time a location is selected.
Differential Revision: https://phabricator.services.mozilla.com/D155952
Depends on D156968
Cleanup of the ChannelMap class
- use private fields
- move static method to module-local method
- add comments
- rename methods to match behavior
Differential Revision: https://phabricator.services.mozilla.com/D156989
This is a very basic migration from commonjs modules to ESM for all modules related to network observation.
A few classes have been introduced instead of prototype-based classes, but otherwise the code remains mostly untouched.
We can followup to introduce private fields and methods if there's interest?
Differential Revision: https://phabricator.services.mozilla.com/D156968
ESM can't be loaded while loading.
So that Loader.jsm/sys.mjs can't load builtin-modules.js with itself loading Loader.jsm/sys.mjs.
We do that in order to inject JSM/ESM globals from builtin-modules.js.
Let's instead inject the few globals of JSM/ESM directly from Loader.
This isn't ideal, but as Loader is meant to be removed when moving to ESM...
Differential Revision: https://phabricator.services.mozilla.com/D158583
The dom::MaybeWrapValue() method was calling `isObject()` rather than
`hasObjectPayload()`, causing an assertion failure when passed a value
representing an ExtendedPrimitive (record or tuple). This was causing a crash
when evaluating a record or tuple literal either in the navigation bar or
the developer console. In addition, js::ToBooleanSlow() was missing a case
for ExtendedPrimitives, which would also cause an assertion failure in the
same scenario.
For documentation, I also added explicit assertions to dom::...Wrap...()
methods defined in BindingUtils.h that aren't expected to support
ExtendedPrimitives.
I also added placeholders for pretty-printing records and tuples in the
console (fully rendering these values is left for Bug 1772157).
Depends on D156494
Differential Revision: https://phabricator.services.mozilla.com/D148062
This migrate gDevTools.showToolbox, but also the Toolbox now receives a commands right away,
and no longer need to create commands out of the descriptor front.
I'm removing browser_two_tabs as it is focusing on testing Tab Descriptors (RootFront.listTabs+getTab)
and Tab targets (TabDescriptor.getTarget).
Using getTarget on descriptor is legacy codepath for a while now.
We should now rather cover commands instead of these low level RDP methods.
Differential Revision: https://phabricator.services.mozilla.com/D157796
Note that this depends on the following patch, in order to destroy commands from the toolbox.
Commands have always been destroying the related client. This was a significant simplification in test.
So that I had to reverse the default value of shouldCloseClient and only toggle it to false
where it is strictly needed. Ideally only for about:debugging toolboxes (and two tests).
Differential Revision: https://phabricator.services.mozilla.com/D158206
Breakpoints seem to now work with sources generated from sourcemaps where the
mappings are defined in the sections property.
Differential Revision: https://phabricator.services.mozilla.com/D158424
When using --enable-debug-js-modules in mozconfig,
today, we ship the modules with different filename and so different URLs.
This won't work once the modules will become ES Modules
as we would load the modules from a fixed URL and there won't be
any way to hack the module loader anymore.
So, we should rather have the build system to ship the right file
(production or dev version), using the same filename and URL.
Unfortunately, I didn't find any easier way to rename a file from moz.build
Differential Revision: https://phabricator.services.mozilla.com/D158665
This migrate gDevTools.showToolbox, but also the Toolbox now receives a commands right away,
and no longer need to create commands out of the descriptor front.
I'm removing browser_two_tabs as it is focusing on testing Tab Descriptors (RootFront.listTabs+getTab)
and Tab targets (TabDescriptor.getTarget).
Using getTarget on descriptor is legacy codepath for a while now.
We should now rather cover commands instead of these low level RDP methods.
Differential Revision: https://phabricator.services.mozilla.com/D157796
Note that this depends on the following patch, in order to destroy commands from the toolbox.
Commands have always been destroying the related client. This was a significant simplification in test.
So that I had to reverse the default value of shouldCloseClient and only toggle it to false
where it is strictly needed. Ideally only for about:debugging toolboxes (and two tests).
Differential Revision: https://phabricator.services.mozilla.com/D158206