Create an `editorMode` prop that is initialized with the preference value, and passed to the JSTerm component.
The prop is then used to check if the input should be cleared when an evaluation is done.
A test is added to ensure this works as expected.
Differential Revision: https://phabricator.services.mozilla.com/D22171
--HG--
extra : moz-landing-system : lando
Adding feature to netmonitor for resizing of columns. In this patch the functionality is hidden behind the pref devtools.netmonitor.features.resizeColumns. This feature is currently turned off - false.
Differential Revision: https://phabricator.services.mozilla.com/D22719
--HG--
extra : moz-landing-system : lando
Before this change clicking on Storage Type use to show table headers from previous selection. Now clicking on Storage Type will reset table headers also in case empty table headers will get cleared.
Differential Revision: https://phabricator.services.mozilla.com/D22327
--HG--
extra : moz-landing-system : lando
When a message was repeated, the bubble would appear and
slightly increase the message size (by 1px), making it
lose its bottom-anchoring. Then, if a new message came,
the console won't automatically scroll anymore.
This patch modifies the repeat bubble CSS so it doesn't
impact the message height, and add a test case in the
test which asserts the scroll to bottom feature.
Differential Revision: https://phabricator.services.mozilla.com/D22672
--HG--
extra : moz-landing-system : lando
For consistency with other parts of DevTools, the Network monitor toolbar (or toolbars, when splitted in 2) should be 28px high excluding borders.
Currently it’s 29px, 1px taller than the toolbox's tab bar, and 1px taller than the Console’s toolbar.
Differential Revision: https://phabricator.services.mozilla.com/D22430
--HG--
extra : moz-landing-system : lando
This changes the colors of the odd table cells and the hover state in rows in the Network tab in DevTools.
I have updated the //--table-zebra-background// in **variables.css** and inserted a new one, which is //--table-selection-background-hover//.
I have created the new variable, in order to prevent it affecting other table colors.
Differential Revision: https://phabricator.services.mozilla.com/D21777
--HG--
extra : moz-landing-system : lando
Changed the way we to access contents of `.CodeMirror`, by using `CodeMirror.getValue()` instead of `.textContent`
Differential Revision: https://phabricator.services.mozilla.com/D22079
--HG--
extra : moz-landing-system : lando
The only fishy bit is the animation stuff. In particular, there are two places
where we just mint the revert behavior:
* When serializing web-animations keyframes (the custom properties stuff in
declaration_block.rs). That codepath is already not sound and I wanted to
get rid of it in bug 1501530, but what do I know.
* When getting an animation value from a property declaration. At that point
we no longer have the CSS rules that apply to the element to compute the
right revert value handy. It'd also use the wrong style anyway, I think,
given the way StyleBuilder::for_animation works.
We _could_ probably get them out of somewhere, but it seems like a whole lot
of code reinventing the wheel which is probably not useful, and that Blink
and WebKit just cannot implement either since they don't have a rule tree,
so it just doesn't seem worth the churn.
The custom properties code looks a bit different in order to minimize hash
lookups in the common case. FWIW, `revert` for custom properties doesn't seem
very useful either, but oh well.
Differential Revision: https://phabricator.services.mozilla.com/D21877
--HG--
extra : moz-landing-system : lando
Take into account new service worker implementation to decide if workers can be debugged
Differential Revision: https://phabricator.services.mozilla.com/D20677
--HG--
extra : moz-landing-system : lando
Similar to bug 1528654, we currently bail out too early and don't process all of the correct scripts when adding breakpoints.
Differential Revision: https://phabricator.services.mozilla.com/D22355
--HG--
extra : moz-landing-system : lando
I don't understand how the test ever worked. I think the idea was that each
operation would result in changes to the prefs, because those prefs are the
source of truth for the recent-files list. However, I don't understand why some
tests would not trigger multiple observer callbacks, which should have been a
huge mess.
The new code doesn't observe the prefs at all. Where possible, it waits for an
appropriate promise; in other places it uses `setTimeout()` to wait for the
next tick, relying on the Scratchpad implementation to be done reacting by
then.
Since the original code was event-driven, most tests were split across two
functions. Each test function had the bottom half of one test and the top half
of the next test. The new code uses async/await and can therefore at least
group related functionality into single cohesive test functions. But those test
functions aren't as independent as they look -- most of them still depend on
previous tests to set up the expected starting state.
Differential Revision: https://phabricator.services.mozilla.com/D20759
--HG--
extra : moz-landing-system : lando
Tests can use the promise to avoid racing on the text being available and the
UI ready for interaction.
Differential Revision: https://phabricator.services.mozilla.com/D20758
--HG--
extra : moz-landing-system : lando
I don't understand how the test ever worked. I think the idea was that each
operation would result in changes to the prefs, because those prefs are the
source of truth for the recent-files list. However, I don't understand why some
tests would not trigger multiple observer callbacks, which should have been a
huge mess.
The new code doesn't observe the prefs at all. Where possible, it waits for an
appropriate promise; in other places it uses `setTimeout()` to wait for the
next tick, relying on the Scratchpad implementation to be done reacting by
then.
Since the original code was event-driven, most tests were split across two
functions. Each test function had the bottom half of one test and the top half
of the next test. The new code uses async/await and can therefore at least
group related functionality into single cohesive test functions. But those test
functions aren't as independent as they look -- most of them still depend on
previous tests to set up the expected starting state.
Differential Revision: https://phabricator.services.mozilla.com/D20759
--HG--
extra : moz-landing-system : lando
Tests can use the promise to avoid racing on the text being available and the
UI ready for interaction.
Differential Revision: https://phabricator.services.mozilla.com/D20758
--HG--
extra : moz-landing-system : lando
We were clearing the ConsoleAPI messages, but not the one
issued by the ConsoleService. A previous patch added
Services.console.resetWindow, so we can use it in `clearMessagesCache`.
Differential Revision: https://phabricator.services.mozilla.com/D21694
--HG--
extra : moz-landing-system : lando
Removed the icon class from file column. I kept the css classes in RequestList.css so that we can easily add icons later.
Differential Revision: https://phabricator.services.mozilla.com/D21783
--HG--
extra : moz-landing-system : lando
Track the number of times people use any of the export options from the Changes panel:
- Copy All Changes button
- Copy Rule button
- Copy Rule context menu option
- Copy Declaration context menu option
Differential Revision: https://phabricator.services.mozilla.com/D22090
--HG--
extra : moz-landing-system : lando
This reverts commit 6e063ce2d1ff7aaa4a261b9c20fe6b2f05e842a4.
Bug 1531350 - fix flow + jest issues with column breakpoints. r=me
Differential Revision: https://phabricator.services.mozilla.com/D22249
--HG--
extra : moz-landing-system : lando
Bug 1517210 ensured that the debugger server was running in the shared system compartment.
The same one for JSMs, JS-XPCOM and DevTools Sandboxes. But that doesn't work when
the server has to debug system Javascripts. In such case, we have to ensure loading
the server in a special loader flagged with invisibleToDebugger=true. This forces
loading the server in another compartment and helps the debugger indentify the boundaries
between debugee and debugger code.
Differential Revision: https://phabricator.services.mozilla.com/D22062
--HG--
extra : moz-landing-system : lando
This patch passes the relevant options to the `openDocLink` function,
which means now links:
- will open right next to the current tab
- will open in background if Ctrl/Cmd is pressed.
A test case is added to ensures this works as expected.
Differential Revision: https://phabricator.services.mozilla.com/D22075
--HG--
extra : moz-landing-system : lando
Now that the server is by default loaded in the shared system compartment,
we have to special cases the code debugging system compartments.
When devtools.chrome.enabled is turned on, the event collector is
inspecting the system compartment's event listener.
In this case, we are using a special Debugger instance loaded in
a sandbox flagged with invisibleToDebugger=true. This forces loading it
in a distinct compartment and helps the debugger know about the boundaries
between debugger and debuggee code.
It should be safe to only load the Debugger and not the whole server here
as event collector is only inspecting and doesn't register any callback on
the Debugger API.
Differential Revision: https://phabricator.services.mozilla.com/D22070
--HG--
extra : moz-landing-system : lando
Before this change, member was considered a required Prop on the file
HeadersPanel.js. The component itself wasn't using this prop, it was only passing to the
renderValue as a prop, and then renderValue uses member to render the data. So, the simpler
solution is remove isRequired from the PropTypes.
Differential Revision: https://phabricator.services.mozilla.com/D21539
--HG--
extra : moz-landing-system : lando
Previously when a JSON response's size was over the limit specified in pref devtools.netmonitor.responseBodyLimit, when inspecting this response in the Network Monitor one simply saw a JSON parse error message. This was due to the fact that the response was truncated in this view and thus no longer a valid JSON, even if the actual response was a valid JSON. Of course the actual response could have been invalid in the first place -- there was no way to know.
This patch will ensure that in such cases a truncation warning message is displayed instead of a parse error message, thus avoiding a likely misleading parse error message.
Differential Revision: https://phabricator.services.mozilla.com/D19302
--HG--
extra : moz-landing-system : lando
Before the change, the HAR export log version is 1.1. After this change, the log version is set to 1.2.
Differential Revision: https://phabricator.services.mozilla.com/D21955
--HG--
extra : moz-landing-system : lando
Added a role=main attribute to address accessability within the browser console.
Differential Revision: https://phabricator.services.mozilla.com/D21847
--HG--
extra : moz-landing-system : lando
Updated "Load More" row in dominator trees to look more like a link in order to tell it apart from other text and to indicate that the element can be clicked.
Differential Revision: https://phabricator.services.mozilla.com/D21471
--HG--
extra : moz-landing-system : lando
Before this change, when we tried to select a URL to copy,
the label "Copy Message" or "Copy Object" was displayed which
does not represent the context. You can now detect if a link exists
and the label is "Copy link address"
Differential Revision: https://phabricator.services.mozilla.com/D21136
--HG--
extra : moz-landing-system : lando
Pass CSS warning column location through viewSourceInStyleEditor
so clicking on CSS warnings in console jumps to the right location in style editor
Differential Revision: https://phabricator.services.mozilla.com/D21682
--HG--
extra : moz-landing-system : lando
This may or may not be part of the plan to get rid of nsCSSValue ;)
Option is not usable via FFI, and they should not be needed (we should be
following the shortest serialization principle instead). These patches also do
that, which matches the other transform properties. I think that slight change
is fine, if we can make it work, and consistent with other properties.
Alternative is adding more TransformOperation variants or such, which I rather
not do.
Differential Revision: https://phabricator.services.mozilla.com/D21862
--HG--
extra : moz-landing-system : lando
Bug 1200686 - Unify pseudo class clors in markup view and rule view. r=fvsch
Differential Revision: https://phabricator.services.mozilla.com/D21426
--HG--
extra : moz-landing-system : lando
- add `key` where necessary;
- fix element attribute typos;
- use consistent Number type for axis and font property values as defined by `propTypes`.
Differential Revision: https://phabricator.services.mozilla.com/D21571
--HG--
extra : moz-landing-system : lando
With @mbalfanz's permission, I am removing the auto-increment behavior from the range inputs in the Font Editor.
The feature isn't easily discoverable and when it does work, its user experience isn't good. We never invested time to refine it and we're unlikely to do so. At this point, this is dead code so we should remove it.
What is getting removed is the logic to support the esoteric auto-increment behavior which happens when dragging the range input thumb to the end of the slider and waiting for a while (1000ms). There's needless complexity in handling the concert of events for a little perceived user value.
Users can still type out-of-range values in the text input field for the properties which allow it: `font-size` and `line-height`. For these properties' components, there's a new prop, `allowOverflow`, which permits values above the `max` defined. Other properties are bounded by `min` and `max` just like before.
Differential Revision: https://phabricator.services.mozilla.com/D21534
--HG--
extra : moz-landing-system : lando
Depends on D21526
This is a request from @mbalfanz in order to keep the naming of the option consistent.
This patch just replaces the l10n string and renames all the places where copyPropertyDeclaration is used in order to avoid confusion.
No functional changes are introduced.
Differential Revision: https://phabricator.services.mozilla.com/D21527
--HG--
extra : moz-landing-system : lando
Adds a new option to the context menu which is visible only when it's invoked on a CSS declaration.
Builds a string with the property name and value and copies to the clipboard.
If the declaration is marked as removed, the string is wrapped in a comment block.
Differential Revision: https://phabricator.services.mozilla.com/D21526
--HG--
extra : moz-landing-system : lando
* Use the right hiearchy of table elements:
<table>
<thead> (display: table-header-group)
<td>...</td> (display: table-cell)
</thead>
<tbody> (display: table-row-group)
<tr> (display: table-row)
<td>...</td>
</tr>
...
</tbody>
</table>
* Prevent using position:absolute within the <table>
Instead set the overflow: auto on the parent of <table> in order to create
an scrollable table.
* Remove any wrapper / intermediate elements that would be intermediate childs
between <table> and <thead> or between <tbody> and <tr>, ...
* Remove manual size definition in JS from RequestListContent.
Differential Revision: https://phabricator.services.mozilla.com/D20383
--HG--
extra : moz-landing-system : lando
The button is only displayed when the input is not empty.
A test case is added to ensure this works as expected.
Differential Revision: https://phabricator.services.mozilla.com/D21443
--HG--
extra : moz-landing-system : lando
Refactors the logic so the target node on which the Font Editor operates can point to a parent node in case of text nodes without explicitly changing the node selection.
The target node is assigned to `this.node`. When that is null, it means the node selection is not supported by the Font Editor. This removes the need for the `isSelectedNodeValid()` method.
Differential Revision: https://phabricator.services.mozilla.com/D21387
--HG--
extra : moz-landing-system : lando
newSource events used to be sent on the target actors on FF66 and before,
this is no longer the case. But we still have to accept them if we connect
to old remotes, otherwise the events are considered as a method reply
and confuses packet ordering.
Differential Revision: https://phabricator.services.mozilla.com/D21394
--HG--
extra : moz-landing-system : lando
Now, DevTools server is loaded with a custom loader every time we want to debug chrome
resources. We ensure toggling the "invisibleToDebugger" flag on Loader.jsm which itself
propagates to DevTools Sandboxes.
We added calls to force GC in console test to prevent crashes on Windows 7.
Differential Revision: https://phabricator.services.mozilla.com/D20347
--HG--
extra : moz-landing-system : lando
When reviewing https://bugzilla.mozilla.org/show_bug.cgi?id=1521052 I did not think about Firefox for Android which is not using e10s.
This means the main DebuggerServer will be killed when there are no connections left. Happy to discuss more about the preferred solution.
This is a regression in 66 and I hope to uplift a fix for this.
Differential Revision: https://phabricator.services.mozilla.com/D20830
--HG--
extra : moz-landing-system : lando
Refactors the logic so the target node on which the Font Editor operates can point to a parent node in case of text nodes without explicitly changing the node selection.
The target node is assigned to `this.node`. When that is null, it means the node selection is not supported by the Font Editor. This removes the need for the `isSelectedNodeValid()` method.
Differential Revision: https://phabricator.services.mozilla.com/D21387
--HG--
extra : moz-landing-system : lando
The `yieldingEach` is moved into the only file that
is using it, in canvas debugger, and is not migrated
as the panel will be removed in a few months.
Differential Revision: https://phabricator.services.mozilla.com/D20641
--HG--
extra : moz-landing-system : lando
When large files's Response tab in Network Devtools is open, Firefox freezes. This checks for file size & switches from SourceEditor to pre() when the files is too big.
Differential Revision: https://phabricator.services.mozilla.com/D12450
--HG--
extra : moz-landing-system : lando
Now that the JsTerm is a React component, we shouldn't
let external consumers have to get the instance in order
to perform some actions on the console input.
We start with the most used actions, setInputValue and getInputValue,
and might extend that in the future.
Differential Revision: https://phabricator.services.mozilla.com/D20685
--HG--
extra : moz-landing-system : lando
This abstracts the most used console input functions,
and might make it easier to refactor things in the
future.
Differential Revision: https://phabricator.services.mozilla.com/D20684
--HG--
extra : moz-landing-system : lando
This patch make sure that all the helper functions
take the hud as a reference to the webconsole.
This makes them simpler to use as the user does not
have to remember what kind of object it takes.
We also rename some functions to not include the term
JsTerm, but rather console input, to make it easier
to reason about the code.
Differential Revision: https://phabricator.services.mozilla.com/D20683
--HG--
extra : moz-landing-system : lando
Renaming this property makes it easier to grasp what
it represents (instead of the vague `owner` term).
Differential Revision: https://phabricator.services.mozilla.com/D20678
--HG--
extra : moz-landing-system : lando
The goal of this deprecation notice is to inform people that these panels are going away. This code should be short lived, only firefox versions 67-68.
Differential Revision: https://phabricator.services.mozilla.com/D19518
--HG--
extra : moz-landing-system : lando
Depends on D20471
I can drop this changeset if we prefer, but this is how I imagine the disconnect button would fit in the RuntimeInfo.
Differential Revision: https://phabricator.services.mozilla.com/D20472
--HG--
extra : moz-landing-system : lando
Depends on D20464
For this change I moved all the layout logic for the RuntimeInfo h1 to RuntimeInfo.css
I don't know if we prefer to have layout info in base.css or in specialized components, but the RuntimeInfo header has a very specific structure.
I can't see how this would be worth having in base.css. And it is the only consumer for main-heading, so I removed all layout rules from base.css for main-heading.
Differential Revision: https://phabricator.services.mozilla.com/D20471
--HG--
extra : moz-landing-system : lando
Depends on D20439
I want to separate the addon checkbox and the load temporary addon for 2 reasons:
- we will get remove the checkbox after Bug 1525533
- we may support temporary addons for remote runtimes later
The "load temporary addon" might also move inside the Temporary Extensions category.
Differential Revision: https://phabricator.services.mozilla.com/D20464
--HG--
extra : moz-landing-system : lando
Now that the JsTerm is a React component, we shouldn't
let external consumers have to get the instance in order
to perform some actions on the console input.
We start with the most used actions, setInputValue and getInputValue,
and might extend that in the future.
Differential Revision: https://phabricator.services.mozilla.com/D20685
--HG--
extra : moz-landing-system : lando