Commit Graph
69 Commits
Author SHA1 Message Date
Siddhartha 0e050ae511 Bug 2000765 - Updated q-value generation in Accept-Language Header to match chrome.r=valentin,necko-reviewers,devtools-reviewers,android-reviewers,nchevobbe,nalexander
The algorithm now generates q-value 0.9 for second language in two language option. Now q-weight of each language decrements by 0.1 (minimum 0.1) down the language list.

Differential Revision: https://phabricator.services.mozilla.com/D273761
2025-12-01 07:15:31 +00:00
Tom Marble 5ce09d7446 Bug 1995583 - test manifest cleanup for idiomatic usage r=jmaher,necko-reviewers,webcompat-reviewers,geckoview-reviewers,application-update-reviewers,media-playback-reviewers,sessionstore-reviewers,tabbrowser-reviewers,translations-reviewers,omc-reviewers,browser-installer-reviewers,twisniewski,masayuki,dom-core,smaug,nalexander,emcminn,sthompson,alwu,ai-ondevice-reviewers,valentin
For TOML manifests:

1. Change processor -> arch
2. Use arch instead of bits bits == '64' =>
   aarch64 (default on mac 15.30) or x86_64 bits == '32' => x86
3. Replace android_version with corresponding os_version
4. Remove conditions with linux os_version=="18.04"
   (unless they contain verify or verify-standalone)
5. Remove conditions with mac os_version=='11.20',
   (unless they contain verify or verify-standalone)
6. Remove conditions with win os_version=='11.2009' or win11_2009,
   (unless they contain verify or verify-standalone)
7. Linux conditions should have os_version, arch and display
   (simple "os == 'linux'" will get expanded to these two)
   "os == 'linux' && os_version == '22.04' && arch == 'x86_64' && display == 'wayland'"
   "os == 'linux' && os_version == '24.04' && arch == 'x86_64' && display == 'x11'"
8. Mac conditions should have os_version and arch
   (simple "os == 'mac'" will get expanded to these three)
   "os == 'mac' && os_version == '10.15' && arch == 'x86_64'",
   "os == 'mac' && os_version == '14.70' && arch == 'x86_64'",
   "os == 'mac' && os_version == '15.30' && arch == 'aarch64'",
9. Replace apple_catalina with
   os == 'mac' && os_version == '10.15' && arch == 'x86_64'
10. Replace apple_silicon with
   os == 'mac' && os_version = '15.30' && arch == 'aarch64'
11. Replace win10_2009 with
   os == 'win' && os_version = '10.2009' && arch == 'x86_64'
12. Replace "!debug" with three conditions "asan", "opt", or "tsan"
13. Replace literal boolean comparison with variables
    (e.g. "debug == false" => "!debug)

Resolves 2000285

Signed-off-by: Tom Marble <[email protected]>

Differential Revision: https://phabricator.services.mozilla.com/D272815
2025-11-22 00:30:39 +00:00
Hubert Boma Manilla 5210ffad6e Bug 1986142 - [devtools] Properly escape all new lines characters (make sure no carraige returns) r=devtools-reviewers,ochameau
While reverting all the work related to cross platform escaping of curl (See  Bug 1976589), i tried to cleanup the
escaping of new line characters, but introduced carriage returns (\r).

This patch reverts back to the original fix from Bug 1968414

Differential Revision: https://phabricator.services.mozilla.com/D265397
2025-09-29 09:30:00 +00:00
Cristina Horotan 8552003d6c Revert "Bug 1986142 - [devtools] Properly escape all new lines characters (make sure no carraige returns) r=devtools-reviewers,ochameau" for causing xpcshell failures on test_curl.js
This reverts commit 945a5e8dd7.
2025-09-27 23:47:20 +00:00
Hubert Boma Manilla 945a5e8dd7 Bug 1986142 - [devtools] Properly escape all new lines characters (make sure no carraige returns) r=devtools-reviewers,ochameau
While reverting all the work related to cross platform escaping of curl (See  Bug 1976589), i tried to cleanup the
escaping of new line characters, but introduced carriage returns (\r).

This patch reverts back to the original fix from Bug 1968414

Differential Revision: https://phabricator.services.mozilla.com/D265397
2025-09-27 23:11:42 +00:00
Nicolas Chevobbe c434d2bde4 Bug 1979604 - [devtools] Speedup StyleRule#form computation on declarations. r=devtools-reviewers,ochameau.
Detect CSS variables in parseDeclarationsInternal instead of using SharedCssLogic.isCssVariable.
Consider CSS variables name always valid so we avoid expensive calls to InspectorUtils.supports().

Differential Revision: https://phabricator.services.mozilla.com/D258853
2025-07-29 10:36:42 +00:00
Hubert Boma Manilla e477ad9346 Bug 1976589 - [devtools] Stop escaping for other platforms when using Copy As Curl(Windows) r=devtools-reviewers,ochameau
This patch reverts important parts of D243110 related to Bug 1950001
This goal is for the Copy As Curl(Windows) to work properly on just the windows CMD

Differential Revision: https://phabricator.services.mozilla.com/D255793
2025-07-18 18:18:33 +00:00
Nicolas Chevobbe feefecc0f3 Bug 1977551 - [devtools] Remove unused devtools/client/inspector/rules/utils/utils.js hasCSSVariable function. r=devtools-reviewers,jdescottes.
Migrate associated test to check the getCSSVariables util function, that was used
in `hasCSSVariable` and is still used in other parts of the code, so we keep
some coverage.

Differential Revision: https://phabricator.services.mozilla.com/D257467
2025-07-18 07:57:49 +00:00
Serban Stanca f8e1c59f58 Revert "Bug 1976589 - [devtools] Stop escaping for other platforms when using Copy As Curl(Windows) r=devtools-reviewers,ochameau" for causing xpcshell failures in test_curl.js.
This reverts commit 0852117cc6.
2025-07-18 04:22:48 +00:00
Hubert Boma Manilla 0852117cc6 Bug 1976589 - [devtools] Stop escaping for other platforms when using Copy As Curl(Windows) r=devtools-reviewers,ochameau
This patch reverts important parts of D243110 related to Bug 1950001
This goal is for the Copy As Curl(Windows) to work properly on just the windows CMD

Differential Revision: https://phabricator.services.mozilla.com/D255793
2025-07-17 22:36:32 +00:00
Mark Banner 3cc3379c8f Bug 1881701 - Change the devtools configurations to work with the ESLint flat configuration.r=devtools-reviewers,profiler-reviewers,julienw,nchevobbe
This consolidates the jest environment definition, and the xpcshell globals into the devtools/.eslintrc.mjs file, for easier configurations.
It also changes the restart of the configurations to work with flat config.

Differential Revision: https://phabricator.services.mozilla.com/D249948
2025-05-24 17:10:59 +00:00
Mark Banner d7c7c5369b Bug 1881701 - Rename many ESLint files to use .mjs. r=frontend-codestyle-reviewers,perftest-reviewers,Gijs,sparky,webcompat-reviewers,twisniewski
This is separate to help preserve history of the files.

Differential Revision: https://phabricator.services.mozilla.com/D249945
2025-05-24 17:10:51 +00:00
Hubert Boma Manilla 0c17bdc19f Bug 1950001 - [devtools] Fix Copy As cURL(Windows) on linux r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D243110
2025-04-22 17:15:49 +00:00
Cosmin Sabou cbc6dca88b Backed out changeset 875d51727bbd (bug 1950001) for causing xpcshell failures on test_curl. CLOSED TREE 2025-04-15 21:40:50 +03:00
Hubert Boma Manilla eb8ee5d790 Bug 1950001 - [devtools] Fix Copy As cURL(Windows) on linux r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D243110
2025-04-15 16:46:07 +00:00
Joel Maher ce1cae83af Bug 1959269 - clean and standardize devtools/**/xpcshell.toml. r=aryx,devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D244831
2025-04-15 14:47:07 +00:00
Butkovits Atila 382b3ed472 Backed out changeset 7238f9bd1c5c (bug 1950001) for causing failures at test_curl.js. CLOSED TREE 2025-04-15 14:40:28 +03:00
Hubert Boma Manilla 25ded0ab33 Bug 1950001 - [devtools] Fix Copy As cURL(Windows) on linux r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D243110
2025-04-15 10:11:07 +00:00
Alexandru Marc e82ae9699a Backed out changeset 991c7b596351 (bug 1950001) for causing xpcshell failures @ test_curl.js CLOSED TREE 2025-04-15 12:54:33 +03:00
Hubert Boma Manilla ae4447ac4d Bug 1950001 - [devtools] Fix Copy As cURL(Windows) on linux r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D243110
2025-04-15 07:52:28 +00:00
Iulian Moraru 013a0cbac2 Backed out changeset 5e3231d83f0d (bug 1950001) for causing xpcshell failures on test_curl.js. 2025-04-02 10:28:18 +03:00
Hubert Boma Manilla 494bb420bc Bug 1950001 - [devtools] Fix Copy As cURL(Windows) on linux r=devtools-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D243110
2025-04-02 02:54:22 +00:00
Nicolas Chevobbe c9dbe86592 Bug 1954704 - [devtools] Fix computing of insert index for declaration in rule with nested rules. r=devtools-reviewers,bomsy.
The offset corresponding to the line number wasn't properly computed.

Differential Revision: https://phabricator.services.mozilla.com/D242105
2025-03-20 14:50:22 +00:00
Nicolas Chevobbe b441747d21 Bug 1946442 - [devtools] Fix RuleRewriter when dealing with rules containing nested rules. r=devtools-reviewers,jdescottes.
Create a dummy rule with the content of the rule being modified so we can
check if it has a nested rule. In such case, we can then get the location
of the nested rule so we can insert the added text in the correct position.

A few unit test cases are added to make sure the RuleRewriter does handle
nested rules properly.

Differential Revision: https://phabricator.services.mozilla.com/D237734
2025-02-19 14:08:29 +00:00
Nicolas Chevobbe ebcde07a80 Bug 1946445 - [devtools] Fix parseDeclarationsInternal for nested declarations. r=devtools-reviewers,jdescottes.
Stop collecting declarations as soon as we detect a nested rule.
Any declaration that come after the nested rules are now put in a
separate CSSNestedDeclaration rule.
We still need to handle the nesting logic for commented declarations,
as highlighted by a test case in test_parseDeclarations.js.
Other test cases there for nested rules are updated, and we add
a CSSNestedDeclaration in a Rules view mochitest to make sure we
don't get the declaration in the "top level" rule anymore.

Differential Revision: https://phabricator.services.mozilla.com/D237520
2025-02-11 14:44:52 +00:00
Nicolas Chevobbe 1f5e041267 Bug 1916682 - [devtools] Refactor cubic bezier widget layout. r=devtools-reviewers,ochameau.
Use a grid for the tooltip, driven by CSS variables that we retrieve in JS
to compute the canvas size.
Retrieve CSS variables for drawing in the canvas, and draw the diagonal
between the control points in the canvas too (instead as a background gradient).
Don't overlap the canvas and the animation easing preview as it could be
hard to discernate in High Contrast Mode.
Fix a couple issues with RTL languages.

Differential Revision: https://phabricator.services.mozilla.com/D227174
2024-10-31 12:41:07 +00:00
Nicolas Chevobbe de4ffa55e6 Bug 1888607 - [devtools] Use InspectorCSSParser in parseDeclarationsInternal. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D206092
2024-04-23 08:43:03 +00:00
Gijs Kruitbosch 3288f177a4 Bug 1780071 - autofix devtools/ violations of no-comparison-or-assignment-inside-ok r=profiler-reviewers,devtools-reviewers,julienw,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D198975
2024-01-26 13:12:07 +00:00
Joel Maher cac31d18e3 Bug 1859873 - batch 13 xpcshell.ini -> .toml. r=aryx,devtools-reviewers,profiler-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D194161
2023-11-21 12:32:50 +00:00
Calum Smith c805f8c777 Bug 1859079 - display new CSS level 4 colours correctly in Rules inspector. r=devtools-reviewers,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D191008
2023-10-17 17:02:56 +00:00
Nicolas Chevobbe b46d770952 Bug 1851978 - [devtools] Pass colorUnit to CssColor.toString. r=ochameau,devtools-reviewers.
Differential Revision: https://phabricator.services.mozilla.com/D188005
2023-09-14 15:06:22 +00:00
Nicolas Chevobbe b755a233d5 Bug 1844499 - [devtools] Handle nested rule without closing paren. r=devtools-reviewers,bomsy.
Differential Revision: https://phabricator.services.mozilla.com/D184111
2023-07-24 08:54:16 +00:00
Nicolas Chevobbe 45459b66fa Bug 1838011 - [devtools] Handle CSS Nesting in parseDeclarations. r=devtools-reviewers,ochameau.
This adds different nested state so we can simply ignore nested CSS rules.
I added a lot of different test cases in the existing `parseDeclarations`
unit test so we can have good coverage.

It also removes "{" from `CSS_BLOCKS` as this wasn't something that could happen
before nesting, and we're handling that separately.
We took this as an opportunity to put opening brackets in `currentBlocks` instead
of closing ones, as it's a bit easier to understand.

Differential Revision: https://phabricator.services.mozilla.com/D180701
2023-06-29 10:39:32 +00:00
Nicolas Chevobbe 95b5460b77 Bug 1839178 - [devtools] Assert parseDeclaration offsets easier. r=devtools-reviewers,ochameau.
Seeing those offsets integer in the test case is a bit hard to assert that they
do actually refer to the expected part of the input.
This adds a `declarationText` property on the expected object that can be used
to properly asserts produced offsets.

Differential Revision: https://phabricator.services.mozilla.com/D181094
2023-06-19 13:50:45 +00:00
Julian Descottes c6ffb12853 Bug 1838488 - [devtools] Refactor test_VariablesView_filtering-without-controller.js r=nchevobbe,Itiel,devtools-reviewers,ochameau
The existing xpcshell test is not a good fit for testing a UI widget such as the VariablesView
Migrate to a browser mochitest and restore usage of document.l10n.setAttributes initially added in Bug 1830679

Differential Revision: https://phabricator.services.mozilla.com/D181096
2023-06-19 05:43:08 +00:00
Mark Banner 91fde42f7b Bug 1826062 - Automatic fixes for Prettier 2.0.5 upgrade. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,owlish
Differential Revision: https://phabricator.services.mozilla.com/D177025
2023-05-20 12:26:49 +00:00
Omid Rad f450cf8f9c Bug 1776120 - "copy as cURL" in should have --compressed r=devtools-reviewers,bomsy
Differential Revision: https://phabricator.services.mozilla.com/D174092
2023-04-15 10:43:12 +00:00
Nicolas Chevobbe 5e01ecf093 Bug 1826502 - [devtools] Create a small utils similar to the classnames node package. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D174953
2023-04-13 06:37:02 +00:00
Stanca Serban 36143c631a Backed out 2 changesets (bug 1826502) for causing devtools failures. CLOSED TREE
Backed out changeset cf951535876b (bug 1826502)
Backed out changeset 18a87184af79 (bug 1826502)
2023-04-12 15:09:18 +03:00
Nicolas Chevobbe e7e05f7464 Bug 1826502 - [devtools] Create a small utils similar to the classnames node package. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D174953
2023-04-12 10:23:45 +00:00
Nicolas Chevobbe 727b3600d3 Bug 1773549 - [devtools] Add widget for linear easing function. r=devtools-reviewers,jdescottes.
This adds an authoring tool similar to the one we have for cubic bezier.
A swatch is added next to `linear()` functions and clicking on it will show
the widget.
Modifying the line in the widget will update the value of the `linear()` function
in the rule view.

Differential Revision: https://phabricator.services.mozilla.com/D153333
2023-03-08 17:39:37 +00:00
Nicolas Chevobbe efe6b01d2e Bug 1814620 - [devtools] Remove color.js rgbToColorName. r=ochameau.
Make the callsites call InspectorUtils.rgbToColorName instead.
Since it was throwing when passed a non-valid named color,
which wasn't the expected outcome in DevTools, modify the
c++ method so it return an empty string instead.
Add a dedicated test since there wasn't one.

Differential Revision: https://phabricator.services.mozilla.com/D168989
2023-02-07 12:39:19 +00:00
Nicolas Chevobbe ffa954174a Bug 1814620 - [devtools] Replace custom color.js method with InspectorUtils ones. r=ochameau.
Let's use `InspectorUtils` `isValidCSSColor`, `rgbToColorName` and `colorToRGBA`
instead of their js-counterpart.

Differential Revision: https://phabricator.services.mozilla.com/D168669
2023-02-07 12:39:18 +00:00
Cristian Tuns 1f1f2dac5a Backed out 2 changesets (bug 1814620) as requested by dev CLOSED TREE
Backed out changeset a7cf3a7ae359 (bug 1814620)
Backed out changeset b74334ea6e48 (bug 1814620)
2023-02-07 05:26:20 -05:00
Nicolas Chevobbe 4e2036b19e Bug 1814620 - [devtools] Remove color.js rgbToColorName. r=ochameau.
Make the callsites call InspectorUtils.rgbToColorName instead.
Since it was throwing when passed a non-valid named color,
which wasn't the expected outcome in DevTools, modify the
c++ method so it return an empty string instead.
Add a dedicated test since there wasn't one.

Differential Revision: https://phabricator.services.mozilla.com/D168989
2023-02-07 08:50:18 +00:00
Nicolas Chevobbe 3cde628b0c Bug 1814620 - [devtools] Replace custom color.js method with InspectorUtils ones. r=ochameau.
Let's use `InspectorUtils` `isValidCSSColor`, `rgbToColorName` and `colorToRGBA`
instead of their js-counterpart.

Differential Revision: https://phabricator.services.mozilla.com/D168669
2023-02-07 08:50:17 +00:00
Julian Descottes f1a3dac261 Bug 1811138 - [devtools] Remove require calls to InspectorUtils r=ochameau,perftest-reviewers,sparky
Depends on D167211

Differential Revision: https://phabricator.services.mozilla.com/D167308
2023-02-06 09:47:18 +00:00
Alexandre Poirot bde84f5b65 Bug 1793604 - [devtools] Convert Loader.jsm to ESM. r=perftest-reviewers,geckoview-reviewers,preferences-reviewers,owlish,kshampur,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D158582
2022-10-14 12:19:42 +00:00
Alexandre Poirot a85b82697f Bug 1792847 - [devtools] Use absolute URLs to import modules in devtools/client/shared. r=jdescottes,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D158379
2022-09-30 15:17:39 +00:00
Alexandre Poirot aa4c0d1add Bug 1789980 - [devtools] Import "wantGlobalProperties" symbols from the module Sandbox. r=jdescottes
That, instead of involving the "debuggerSandbox", which is only meant
for exposing the "Debugger" symbol.

Differential Revision: https://phabricator.services.mozilla.com/D156934
2022-09-20 12:52:26 +00:00