Commit Graph
33 Commits
Author SHA1 Message Date
Edward Billington 26588c3216 Bug 1579663 - Allow data url background-image in styled console logs r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D55376
2019-12-04 09:31:54 +00:00
Nicolas Chevobbe d38e3fae98 Bug 1579090 - Support ObjectFronts in WebConsole. r=Honza.
Since we may now have ObjectFronts in console messages as
well as in evaluation results, we need to make the webconsole
consume those fronts.

And because we have ObjectFronts, we can now avoid using the
DebuggerClient to release the actors, and simply call front.release.
This simplifies how we track created object, since we only need
to release "root" objects, which will also cause all the sub-fronts
to be released as well. Sadly, this was causing some test failures
in mochitests because some objects were released while the connection
was closed, so we now emit an event when all the actors are released,
which we track in tests to wait until everything is over.

As a side effect, we need to change how we handle stubs for
our tests, since fronts have cycical references and can't
be serialized directly. In order to handle that, we serialize
all front as a plain object with a `_grip` property, containing
the object grip. In the stub file, we don't expose the grips
directly, but Maps that contain those stubs "rehydrated": when
a _grip object is encountered, it's turned back into a front.

Differential Revision: https://phabricator.services.mozilla.com/D54509
2019-12-04 09:03:53 +00:00
Nicolas Chevobbe 4d14f5d829 Bug 1375752 - Render empty strings as <empty string> in console. r=yzen.
This only affects console api calls where one of the
argument is an empty string. Since we don't quote
string arguments for those, it was difficult to spot
an empty string there.
Jest test are added, as well as a mochitest for the
console to make sure that we don't have unwanted
side effects (for evaluation results, object with
empty string properties, ...)

Differential Revision: https://phabricator.services.mozilla.com/D54687
2019-11-26 15:09:00 +00:00
Nicolas Chevobbe bf96766783 Bug 1067710 - Bump console.table columns limit to 21 to match Chrome. r=Honza.
Increasing the number of columnns highlighted some issues:
- Some element could be off-screen, the grid-template-columns
  needed to be adjusted
- headers could be cut-off, we add a title on the element to
  have the full content in a tooltip
- properties that are not defined were displayed as "undefined",
  which is not really true, and take a lot of space. We render
  them as an empty cell in such case now.

A test is added to check the max-column limit.

Differential Revision: https://phabricator.services.mozilla.com/D54260
2019-11-26 13:21:12 +00:00
Nicolas Chevobbe 1175e2f5b3 Bug 1326182 - Send all the console.table items in the console message. r=Honza.
This allows us to not have to reach for the server
again from the client to get all the data we need
to render the table.

We still need to keep the old function to handle
connections to older servers. We'll use Bug 1597955
in Firefox 74 to clean the bits we don't need anymore.

A test is added to ensure the bug is fixed and we don't
regress; stubs are updated.

Differential Revision: https://phabricator.services.mozilla.com/D53962
2019-11-22 09:48:58 +00:00
jaril 334eff9b62 Bug 1594096 - Display exceptions in the Replay timeline r=jlast
Differential Revision: https://phabricator.services.mozilla.com/D51949
2019-11-22 19:24:43 +00:00
Nicolas Chevobbe 30153880c1 Bug 1595594 - Add support for typed arrays to console.table. r=Honza.
In order to render a table, we first check that console.table is
called with data that can be displayed in a table. Until now, we
were missing all the typed arrays.
This revealed some smaller issues:
- BigInt64Array were not marked as typed arrays on the server.
- Generating the repeatId for a message containing BigInts would
  throw because BigInts can't be serialized.

We add test cases for all the typed array, and we take this opportunity
to add a test case to ensure object insides table cells can be expanded.

Differential Revision: https://phabricator.services.mozilla.com/D53155
2019-11-19 13:37:07 +00:00
Julian Descottes 03cdcd7b0a Bug 1593921 - Use eslint-disable-next-line to disable complexity checks in DevTools r=pbro
Using next-line is less error prone for refactorings than wrapping methods with enable/disable blocks.

Differential Revision: https://phabricator.services.mozilla.com/D51782
2019-11-05 14:29:04 +00:00
jaril c2edc49474 Bug 1592751 - Maintain purple line above paused console message in Replay r=jlast
Differential Revision: https://phabricator.services.mozilla.com/D51167
2019-10-31 01:39:19 +00:00
Nicolas Chevobbe ce25c3f455 Bug 1519103 - Remove Scratchpad panel. r=bgrins.
Differential Revision: https://phabricator.services.mozilla.com/D50583
2019-10-27 09:05:58 +00:00
Brian Hackett 5efaf938e7 Bug 1585860 - Fix console warping console menu item, r=nchevobbe.
Differential Revision: https://phabricator.services.mozilla.com/D48064
2019-10-03 14:33:06 +00:00
Jason Laster 3934a4c8a5 Bug 1582870 - Reduxify console actions. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D46674
2019-10-02 22:50:25 +00:00
Nicolas Chevobbe 31bb7f3d0a Bug 1584973 - Always lazy load Reps bundle. r=Honza.
Differential Revision: https://phabricator.services.mozilla.com/D47729
2019-10-02 08:05:57 +00:00
Oana Pop Rus ce530ebdd0 Backed out 2 changesets (bug 1584973) for devtools node failure on a CLOSED TREE
Backed out changeset c06273b25769 (bug 1584973)
Backed out changeset e63ea229519d (bug 1584973)
2019-10-02 02:30:42 +03:00
Nicolas Chevobbe 70ece40caf Bug 1584973 - Always lazy load Reps bundle. r=Honza.
Depends on D47728

Differential Revision: https://phabricator.services.mozilla.com/D47729
2019-10-01 09:36:51 +00:00
Nicolas Chevobbe 5b250d417e Bug 1577756 - Run browser_console_webconsole_console_api_calls.js can run with both Fission enabled and disabled. r=Honza.
We also add a few console API calls, as well as pass a second
object parameter for the methods that support it, so we can
check that the content object are well displayed in the
Browser Console.
As we add a new check for console.table, I realized that
hiding and showing a consoleTable component would trigger a
new request to the server, even if we already have the table
data at hand.
I fixed this by only trying to get data from the server if
we don't have them already.

Differential Revision: https://phabricator.services.mozilla.com/D44159
2019-09-02 12:29:47 +00:00
Nicolas Chevobbe 4c458599b5 Bug 1574763 - Localize the WarningGroup badge title. r=jdescottes.
Sadly the badge title wasn't localized at all, so we add a new
l10n string and use it in the component.

Differential Revision: https://phabricator.services.mozilla.com/D42517
2019-08-20 05:52:40 +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
Nicolas Chevobbe a347dba96f Bug 1571992 - Fix isScrolledToBottom usage. r=Honza.
The function was expecting the outputNode, but the
callers pass it the outputNode lastChild.
We modify the function to work with this lastNode
instead of the outputNode.

Differential Revision: https://phabricator.services.mozilla.com/D40933
2019-08-07 08:57:08 +00:00
Nicolas Chevobbe d679a0d4a9 Bug 1570985 - Don't create an ObjectClient from ConsoleTable. r=Honza.
Differential Revision: https://phabricator.services.mozilla.com/D40589
2019-08-06 15:15:09 +00:00
Florens Verschelde 24709a1d33 Bug 1568746 - Trim input text in Console messages; r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D39316
2019-07-31 12:31:30 +00:00
Armando Ferreira 67ff266803 Bug 1540722 - Copy link location should work for learn-more links. r=nchevobbe
Support for coping link location from within the Console panel (through the context menu) can be extended and cover learn more links too.

Differential Revision: https://phabricator.services.mozilla.com/D38546
2019-07-23 18:34:08 +00:00
Nicolas Chevobbe 39eeb06393 Bug 1565781 - Fix ConsoleTable with nested holey array. r=Honza.
A test is added to ensure this is fixed properly.
We also fix the Array previewer to properly return
undefined for unknown array properties, rather than null.

Differential Revision: https://phabricator.services.mozilla.com/D38467
2019-07-18 12:04:42 +00:00
Nicolas Chevobbe 5b16c0c2f8 Bug 1567067 - Fix PropTypes error in Message.js .r=Honza.
Differential Revision: https://phabricator.services.mozilla.com/D38454
2019-07-18 08:55:36 +00:00
Armando Ferreira 00945f5389 Bug 1546347 - Message location on CSS Warnings has an erroneous title attribute. r=nchevobbe
Adding a new opcional property to Frame.js, messageSource, which will allows us to know the source of the Message. We will be using this property to display the correct tooltip message.

Differential Revision: https://phabricator.services.mozilla.com/D38139
2019-07-18 06:17:16 +00:00
Armando Ferreira 285b1a4450 Bug 1524115 - When clicking and selecting source text on a collapsible message, the message expansion is toggled after releasing the mouse. r=nchevobbe
When clicking and selecting source text on a collapsible message, the message expansion is toggled after releasing the mouse

Differential Revision: https://phabricator.services.mozilla.com/D37607
2019-07-17 15:48:56 +00:00
Nicolas Chevobbe 9d703719af Bug 1564138 - Fix DevTools PropTypes errors when updating eslint. r=Ola.
Differential Revision: https://phabricator.services.mozilla.com/D38093
2019-07-17 10:35:44 +00:00
Nicolas Chevobbe 6fca865e74 Bug 1564363 - Close the network detail on Escape. r=Honza.
We use the openNetworkDetails prop which is already in use
in the netmonitor to collapse the message if the parameter
passed to the function is falsy (i.e. the panel is already
displayed)

Depends on D37388

Differential Revision: https://phabricator.services.mozilla.com/D37389
2019-07-09 10:50:50 +00:00
Nicolas Chevobbe 567783311c Bug 1563914 - Fix ConsoleTable with invalid headers. r=Honza.
Differential Revision: https://phabricator.services.mozilla.com/D37164
2019-07-09 08:47:58 +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
tanhengyeow 49725b775c Bug 1561676 - WebSocket panel crashes in WebConsole. r=nchevobbe,Honza
Hide WebSocketsPanel in console.

Differential Revision: https://phabricator.services.mozilla.com/D36158
2019-06-27 11:54:37 +00:00
Nicolas Chevobbe 476067b92d Bug 1559329 - Set "group similar messages" to true by default. r=Honza.
This was making browser_webconsole_scroll.js fail.
After some investigation, I found that the `isInWarningGroup`
prop, a function defined in `mapStateToProp` was causing a
re-rendering (because we were creating a new function each
time), impacting the shouldScrollToBottom behaviour.

To fix this, we no longer create a `isInWarningGroup` prop,
but directly use the `isMessageInWarningGroup` selector, which
was modified to take an array of visible messages instead of
the whole state.

Differential Revision: https://phabricator.services.mozilla.com/D35016
2019-06-27 11:42:15 +00:00
Armando Ferreira a3c043f6be Bug 1522104 - Re-organise devtools/client/webconsole/components/ folder. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D35932
2019-06-26 09:19:54 +00:00