Commit Graph
27 Commits
Author SHA1 Message Date
Nicolas Chevobbe eed8436a83 Bug 1867321 - [devtools] Add link capability to popovertarget attribute. r=devtools-reviewers,ochameau.
Differential Revision: https://phabricator.services.mozilla.com/D195005
2023-12-01 10:39:26 +00:00
Nicolas Chevobbe e23bf181ce Bug 1864186 - [devtools] Add links for invoketarget attributes. r=devtools-reviewers,bomsy.
Differential Revision: https://phabricator.services.mozilla.com/D193316
2023-11-16 15:52:36 +00:00
Nicolas Chevobbe a450d367ce Bug 1850953 - [devtools] Add icon to select node next to idref idreflist attributes in markup view. r=devtools-reviewers,bomsy.
This will make the underlying feature more discoverable
and should help people doing accessibility work.
We take this as an opportunity to export attribute types
from node-attribute-parser.js so we can do proper check.
Since we're adding a click event listener in markup container,
to handle keyboard activation, we take care of all the
event listeners lifecycle with an abort controller.
The existing test on aria attributes is updated to also
test the button. This should be enough as this cover both
idref and idreflist cases.

Differential Revision: https://phabricator.services.mozilla.com/D193309
2023-11-16 15:52:36 +00:00
Norisz Fay 421e10625f Backed out 2 changesets (bug 1864186, bug 1850953) for causing dt failures on browser_markup_links_aria_attributes.js
Backed out changeset 0a87f6ab3e9c (bug 1864186)
Backed out changeset 374222e4595c (bug 1850953)
2023-11-16 14:52:53 +02:00
Nicolas Chevobbe d36cd57056 Bug 1864186 - [devtools] Add links for invoketarget attributes. r=devtools-reviewers,bomsy.
Differential Revision: https://phabricator.services.mozilla.com/D193316
2023-11-16 09:51:21 +00:00
Nicolas Chevobbe 5715fb4706 Bug 1850953 - [devtools] Add icon to select node next to idref idreflist attributes in markup view. r=devtools-reviewers,bomsy.
This will make the underlying feature more discoverable
and should help people doing accessibility work.
We take this as an opportunity to export attribute types
from node-attribute-parser.js so we can do proper check.
Since we're adding a click event listener in markup container,
to handle keyboard activation, we take care of all the
event listeners lifecycle with an abort controller.
The existing test on aria attributes is updated to also
test the button. This should be enough as this cover both
idref and idreflist cases.

Differential Revision: https://phabricator.services.mozilla.com/D193309
2023-11-16 09:51:21 +00:00
Takeshi Kurosawa c6ec611aff 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
Narcis Beleuzu 567c5f7419 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 be6d00d751 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
Mark Banner 6d03c63e2d Bug 1330099 - Enable object-shorthand eslint rule. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D153567
2022-08-03 14:57:05 +00:00
Nicolas Chevobbe 290ba5cb21 Bug 1568779 - Remove editors settings comments in devtools files. r=pbro.
Differential Revision: https://phabricator.services.mozilla.com/D42300
2019-08-19 12:48:16 +00:00
Gabriel Luong d3008f35ae Bug 1566467 - Speed up shared/node-attribute-parser getType function. r=nchevobbe
We can speed up the getType function by changing the dataType into an object from an array.
That way we avoid looping looking for the matching tagName and namespaceURI and access the typeData directly by their tagName.

Differential Revision: https://phabricator.services.mozilla.com/D38196
2019-07-16 11:19:59 -04:00
Nicolas Chevobbe ad8c11477d Bug 1564480 - Enhance performance on parseAttribute function. r=gl.
`hasAttribute` and `getAttribute` were using for..of loop to
get what they wanted, which wasn't ideal.
Moreover, most of those operations were happening because we
didn't pass the attribute value to the parseAttribute function,
only an array of all the attributes. This is a bit unfortunate
there's only one place where we call the parseAttribute function,
and there, we have easy access to the attribute value.

This patch removes direct calls to hasAttribute and getAttribute.
hasAttribute is removed, but we need to keep getAttribute for the
isValid function in parsers.
We add an `attributeValue` parameter to the parseAttribute function.
The unit test for this function is also modified to pass the attribute
value.

perfherder reports a ~2.5% improvement on custom open and ~3% on
custom reload.

Differential Revision: https://phabricator.services.mozilla.com/D37551
2019-07-11 08:53:53 +00:00
Victor Porof b7732ae890 Bug 1561435 - Format devtools/client/, a=automatic-formatting
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D35884
2019-07-05 11:24:38 +02:00
Michael Ratcliffe 1aaa35121f Bug 1522273 - Markup view not working on elements containing a 'constructor' attribute r=rcaliman
`ATTRIBUTE_TYPES` was an object and we used to access it's attributes using e.g.
`ATTRIBUTE_TYPES["href"]`, which is fine in almost all cases.

The problem occurred when the attribute name was `"constructor"`. This caused us
to attempt to parse `ATTRIBUTE_TYPES["constructor"]`, which returned
`{}.constructor` therefore breaking the attribute parser.

Changing `ATTRIBUTE_TYPES` to a Map fixes the issue because
`ATTRIBUTE_TYPES.get("constructor")` returns null rather than an object
constructor.

Differential Revision: https://phabricator.services.mozilla.com/D18220
2019-01-31 15:48:41 +00:00
Mark Banner 3d6aaad3f5 Bug 1486741 - Enable ESLint rule comma-dangle for all of mozilla-central (automatic fixes). r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D8389
2018-10-19 12:55:39 +00:00
Gabriel Luong cc1ab5f441 Bug 1494162 - Part 37: Speed up getTypes in node-attribute-parser.js by using keys instead of looping over an array. r=pbro 2018-10-02 09:06:24 -04:00
Julian Descottes 9456167901 Bug 1454696 - Fix leftover issues for prefer-const;r=yulia
MozReview-Commit-ID: JwOXoqw2mks
2018-06-01 12:19:35 +02:00
Julian Descottes 82711b9a8f Bug 1454696 - Run eslint --fix for prefer-const;r=yulia
MozReview-Commit-ID: F6xUXCgdRE4
2018-06-01 12:36:09 +02:00
J. Ryan Stinnett 8d1c817851 Bug 1443081 - Apply spacing via eslint --fix for DevTools. r=jdescottes
MozReview-Commit-ID: 2RVNt140Zte
2018-03-12 13:44:41 -05:00
Gijs Kruitbosch a076dc057e Bug 1425356 - remove various dead XUL sort attributes, r=bz,florian
- sort-statics-last is no longer meaningful now non-static (ie template) items don't exist
- we don't use the 'resource' attribute anywhere in XUL.
- sortResource/sortResource2 are unused.
- we don't have meaningful consumers for sortSeparators

MozReview-Commit-ID: C31vC9MCrDo
2017-12-20 15:08:27 +00:00
Sebastian Hengst c6d9ef3e98 Backed out changeset 6bc38f188ef2 (bug 1330099) for devtools failures. r=backout 2017-01-11 23:21:56 +01:00
Tim Nguyen 548b6bdbef Bug 1330099 - Enable object-shorthand eslint rule. r=jryans
MozReview-Commit-ID: 3wA25rfznBv
2017-01-11 21:22:15 +00:00
Jared Wein 21fc75d491 Bug 1326479 - Fix 'indent' eslint errors now that eslint scans multiline array and object definitions. r=Gijs
MozReview-Commit-ID: 99mWjxu8PPn
2017-01-03 10:07:50 -05:00
Tom Tromey 8f1292bce5 Bug 1270994 - Fix ESLint errors in devtools/client/shared/*.js; r=jryans
MozReview-Commit-ID: 1od43gBnUq1
2016-05-19 08:35:45 -06:00
J. Ryan Stinnett 530b903fcf Bug 1271084 - Apply ESLint autofixes to ignored /devtools files. r=tromey
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
2016-05-18 12:49:23 -05:00
J. Ryan Stinnett a3073e0420 Bug 912121 - Migrate major DevTools directories. rs=devtools
Move major DevTools files to new directories using the following steps:

hg mv browser/devtools devtools/client
hg mv toolkit/devtools/server devtools/server
hg mv toolkit/devtools devtools/shared

No other changes are made.
2015-09-21 12:02:24 -05:00