Depends on D8718
Opting to first completely remove, then add the new logic, otherwise
the diff gets very confusing since most of the code changed
MozReview-Commit-ID: BbncSBhD5py
Differential Revision: https://phabricator.services.mozilla.com/D8719
--HG--
extra : moz-landing-system : lando
⚠️ **To build locally, this change series depends on the [change series](https://phabricator.services.mozilla.com/D4399) which adds the ChangesActor**.
🏋️♂️ **To test hands-on, you can download a [custom macOS build](https://queue.taskcluster.net/v1/task/HIiZcwLXTuuSYYjfwEDmmA/runs/0/artifacts/public/build/target.dmg) (updated Wed, Oct 24) which includes both change series.**
- Introduce ancestorRules getter to StyleRuleActor to get a flattened rule tree with the ancestors of the current rule;
- Introduce CSSRuleTypeName to css-logic helpers to map between CSS rule type and human-readable name;
- Log rule index position with each CSS declaration change to help differentiate between changes to rules with identical selectors at the same level of nesting.
Differential Revision: https://phabricator.services.mozilla.com/D8718
--HG--
extra : moz-landing-system : lando
The SourceMapURLService has a subscribe and an unsubscribe
functions to respectively listen and stop listening for
source map changes on a given location (url + line + column).
The unsubscribe function need to be called with the same
parameters as the subscribe function, which means the consumer
need to keep a reference to the callback.
By making the subscribe function return the unsubscribe function,
this makes things a bit easier.
Differential Revision: https://phabricator.services.mozilla.com/D9784
--HG--
extra : moz-landing-system : lando
I tried all kinds of CSS changes and experiments to get to the bottom of this.
This is due to an incompatibility between the flexbox API and `devtools/shared/layout/dom-matrix-2d.js::getWritingModeMatrix()`.
Take the following flexbox item:
```
______________________________
| ___ |
|| | |
||___| |
|______________________________|
```
In LTR mode the coordinates would be something like 5, 10, 25, 35 (x1, y1, x2, y2).
Now let's look at RTL mode:
```
______________________________
| ___ |
| | ||
| |___||
|______________________________|
```
In RTL mode the coordinates would be something like 85, 10, 105, 35 (x1, y1, x2, y2).
getWritingModeMatrix() flips the canvas in RTL mode naively assuming that this will flip our overlay. This causes 2 problems:
1. 0,0 moves from the top left to the top right, complicating our calculations.
2. The flexbox API returns coordinates relative to the top left of the canvas and not the top right.
Similar issues are caused by setting writing modes that results in flipping and rotating the canvas in similar ways.
In a nutshell rotating the canvas actually complicates our calculations instead of simplifying them.
This patch adds two named parameters to allow opting out of writing mode and RTL calculations.
Differential Revision: https://phabricator.services.mozilla.com/D9390
--HG--
extra : moz-landing-system : lando
Adds a "Refresh devices button". I was unsure on whether this button should use state for this or just plug directly into the adb module. In the end I opted for doing it via actions/state because it would also allow us to show somewhere else an indication of whether the scanner is running or not (in case we need it). But if you think this is overkill, I'll gladly change it.
To try it, with the device connected, open and close firefox. If you press Refresh you should see the list update.
Differential Revision: https://phabricator.services.mozilla.com/D9500
--HG--
extra : moz-landing-system : lando
Another regression linked to removing setContent API on HTMLTooltip.
The initial feedback to remove the method was from me, because we started seeing
two ways to set the content of the tooltip (DOM APIs or setContent) and I prefered
keeping only one. However the DOM approach still almost forces you to call setContentSize
in case your tooltip instance is shared for different content.
This is the case for the preview tooltip, which is used for CSS variables, fonts and image
previews. Maybe we should revisit the decision to remove this setContent API
Differential Revision: https://phabricator.services.mozilla.com/D9752
--HG--
extra : moz-landing-system : lando
Depends on D9122
This is a follow up to the first patch that restores the category, but shows a "disabled"
message instead of the content
Differential Revision: https://phabricator.services.mozilla.com/D9123
--HG--
extra : moz-landing-system : lando
This is an attempt to fix the intermittent on this test.
It looks like we were setting the listeners on some events
after the request message was received, which might have
made us missed some events.
We take this bug as an opportunity to do some cleanup
on the test.
Differential Revision: https://phabricator.services.mozilla.com/D9075
--HG--
extra : moz-landing-system : lando
So far, when USB list was updated, since we replace to all new instances, the
states had not been able to keep. To resolve this, re-use runtimes that retain
in runtimes state.
Depends on D9470
Differential Revision: https://phabricator.services.mozilla.com/D9471
--HG--
extra : moz-landing-system : lando
When the addon was removed/added, REQUEST_EXTENSIONS_SUCCESS action was fired.
But because current USB runtime does not support extensions debugging, we
avoid to add debug target listener for USB runtime. Likewise, we refer the
state of supporting for workers and tabs.
Differential Revision: https://phabricator.services.mozilla.com/D9469
--HG--
extra : moz-landing-system : lando
Depends on D8741
This changeset updates some calls to ok() that should actually be calls to is()
and that needed tiny fixes to match the expected value.
Differential Revision: https://phabricator.services.mozilla.com/D8742
--HG--
extra : moz-landing-system : lando
Depends on D8740.
This changeset replaces calls to ok with 3 arguments to calls with 2 arguments
in situations where the switch does not have a significant impact on the assert.
Differential Revision: https://phabricator.services.mozilla.com/D8741
--HG--
extra : moz-landing-system : lando
Depends on D8739.
This changeset updates calls to ok() that were most likely intended
for is(), but are not working as is.
Differential Revision: https://phabricator.services.mozilla.com/D8740
--HG--
extra : moz-landing-system : lando
This changeset updates all the test that were wrongly using ok() and wanted to
use is() AND for which the assert is still passing without any modification
required.
Differential Revision: https://phabricator.services.mozilla.com/D8739
--HG--
extra : moz-landing-system : lando
WiFi is not even working at the moment, so it probably should
not be tagged as recommended.
Differential Revision: https://phabricator.services.mozilla.com/D9222
--HG--
extra : moz-landing-system : lando
In this patch we use the previous change to reduce the overhead in the
specific test that fails in ccov builds, by reducing the sample
frequency.
Depends on D8548
Differential Revision: https://phabricator.services.mozilla.com/D8435
--HG--
extra : moz-landing-system : lando
The int preference profiler.sample-frequency-khz didn't make it possible
to reduce the overhead in tests, because we could have intervals bigger
than 1ms. With this change we can now do it.
Depends on D8547
Differential Revision: https://phabricator.services.mozilla.com/D8548
--HG--
extra : moz-landing-system : lando
We reduce the profiler's buffer size for all tests, to reduce the memory
pressure and the overhead. This may fix some OOM intermittent crashes.
Differential Revision: https://phabricator.services.mozilla.com/D8547
--HG--
extra : moz-landing-system : lando
Fixes contrast issue of status code in webconsole by creating and importing StatusCode.css file into webconsole/index.html which contains the rules for styling the Status Code. Also imports the StatusCode.css file to netmonitor.css since status code styles are removed from RequestList.css.
Differential Revision: https://phabricator.services.mozilla.com/D9353
--HG--
extra : moz-landing-system : lando
Depends on D9648
Note that this is not strictly necessary since the set* methods are only called when
the Swatch tooltips are built, so they always operate on "new" HTML Tooltips. But
since this is not very self explanatory I think it will be less surprising to be
on the safe side and clear innerHTML in the methods directly.
Differential Revision: https://phabricator.services.mozilla.com/D9649
--HG--
extra : moz-landing-system : lando
This patch adds localization for the WebReplay Jump icon, and uses
the same terminology as the one used in the context menu that triggers
the same action.
The Jump button was used in-place of the existing level icons (Error, Warning, …),
and was only displayed when the message was hovered. We now ensure the
level icon is always visible and that we only show the Jump icon when the
message is hovered.
Finally, the button was styled targeting the title attribute in CSS, which
seemed a little brittle. We now use a dedicated class which should
be safer and more future proof.
Differential Revision: https://phabricator.services.mozilla.com/D8533
--HG--
extra : moz-landing-system : lando
- Removed common.css
- Re-ordered the loading of stylesheets, so components sheets are loaded _after_ the more generic rules
- Refactored some of our components into more generic ones.
Note that a few styles do not match exactly `common.css` (for instance, buttons' `min-height` and `min-width`), in favor of Photon. This might change later depending on the UX guidance we'll get eventually.
Differential Revision: https://phabricator.services.mozilla.com/D8970
--HG--
rename : devtools/client/aboutdebugging-new/aboutdebugging.css => devtools/client/aboutdebugging-new/src/base.css
extra : moz-landing-system : lando
Since we do now have the list of Javascript keywords, we
import it from webconsole autocomplete service and send
the keywords matching the current expression to the client.
Differential Revision: https://phabricator.services.mozilla.com/D8709
--HG--
extra : moz-landing-system : lando
This list is generated from /js/src/frontend/ReservedWords.h,
which is already used on the platform to generate list of js
reserved words.
This list will be used in the console autocomplete code to
expose those keywords to the user.
Differential Revision: https://phabricator.services.mozilla.com/D8998
--HG--
extra : moz-landing-system : lando
- Update 'Pick an element' icon with bigger arrow, background in active state
- Update 'Pick an accessible element' icon with pixel-fitted design, background in active state
- Update 'RDM' icon with background in active state
- Use context-stroke to enable design changes, instead of a different URL, to avoid a visual glitch
Differential Revision: https://phabricator.services.mozilla.com/D9113
--HG--
extra : moz-landing-system : lando
The log we currently receive are not really
actionable (we are using ok, so we don't know
what the received value actually is). Switching
to is should give us what the value is when the
test fails, which might help us fix the failure.
Differential Revision: https://phabricator.services.mozilla.com/D9270
--HG--
extra : moz-landing-system : lando
- Removed common.css
- Re-ordered the loading of stylesheets, so components sheets are loaded _after_ the more generic rules
- Refactored some of our components into more generic ones.
Note that a few styles do not match exactly `common.css` (for instance, buttons' `min-height` and `min-width`), in favor of Photon. This might change later depending on the UX guidance we'll get eventually.
Differential Revision: https://phabricator.services.mozilla.com/D8970
--HG--
rename : devtools/client/aboutdebugging-new/aboutdebugging.css => devtools/client/aboutdebugging-new/src/base.css
extra : moz-landing-system : lando
Doing this avoid loading the addons panel and doing its related requests,
which may still be pending after closing about:debugging.
MozReview-Commit-ID: LJjaE5YVgXi
Depends on D8867
Differential Revision: https://phabricator.services.mozilla.com/D8868
--HG--
extra : moz-landing-system : lando
Opening about:debugging may lead to pending listAddons requests.
Tests that open about:debugging should be careful to wait for the end
of these requests, which this test doesn't do.
MozReview-Commit-ID: 6YyfdW78kOS
Depends on D8828
Differential Revision: https://phabricator.services.mozilla.com/D8867
--HG--
extra : moz-landing-system : lando
hud.owner can be null in some condition, so we
need to guard the access to hud.owner.target.
Differential Revision: https://phabricator.services.mozilla.com/D9069
--HG--
extra : moz-landing-system : lando
The test is failing because the result of the last
evaluation is received before we expect it. Since we
had a 500ms delay between each promise resolution, it
might happen than the time it takes to execute the
command execedes this delay, making our expected message
order wrong.
Increasing the delay between each Promise resolution seems
to resolve the issue, although it makes the test a lot longer too.
This is why a new test was created to only cover the concurrent
await case.
Differential Revision: https://phabricator.services.mozilla.com/D8698
--HG--
rename : devtools/client/webconsole/test/mochitest/browser_jsterm_await.js => devtools/client/webconsole/test/mochitest/browser_jsterm_await_concurrent.js
extra : moz-landing-system : lando
When sending a command to the server, a timestamp is
computed before evaluating the string, and is then
sent back to the client in the packet.
However, if top-level await, or somme :commands, the
evaluation takes more time, which means the timestamp
is now innacurate.
For those cases, we update the timestamp before sending
the packet to the client.
Differential Revision: https://phabricator.services.mozilla.com/D8734
--HG--
extra : moz-landing-system : lando
This patch turns property access that would result in
Syntax error (e.g. `x.data-test`) into element access
(e.g. `x["data-test"]`) when accepting a completion
value in the console input.
In order to do that, we use Reflect to parse a custom
expression where we try to define the property the user
is going to accept. If this throws, this means we need to
modify the input into an element access.
A test is added to make sure this works as expected.
Differential Revision: https://phabricator.services.mozilla.com/D8952
--HG--
extra : moz-landing-system : lando
The code we had to jump to the style-editor when a rule-view source link is clicked did
not make any distinction between multiple inline stylesheets. If you had many of them,
they would all have the same url (i.e. the url of the document, because they are
inline). And we were matching stylesheets in the style-editor by url, so we would
always select the first inline stylesheet.
This change makes use of the fact that the style-editor's selectStyleSheet function
also accept a StyleSheetFront object. When passing this object, there can be no
confusion, because they're all different.
Now, I'm only doing this for inlin stylesheets because other stylesheets have unique
urls and it's important to preserve the previous logic since source-maps may also be
involved.
I'm taking this opportunity to re-enable browser_rules_style-editor-link.js which had
been disabled a long time ago, and removing a part that just doesn't work anymore at
all apparently.
Differential Revision: https://phabricator.services.mozilla.com/D9093
--HG--
extra : moz-landing-system : lando
This preparatory work will be necessary to enable CSP for the new about
debugging.
Differential Revision: https://phabricator.services.mozilla.com/D8854
--HG--
extra : moz-landing-system : lando
The current iteration of the Fonts panel requires an instance of the Rules view
in order to get access to the element's rules.
In 2-pane mode, when the Fonts panel is the default (last used panel), the Rules
view is not yet instantiated. To guard against this, the Fonts panel makes a call
to ensure an instance of the Rules view is created (and with it a CSSRuleView object).
For some reason, the pageStyle wasn't immediately assigned to the CSSRuleView in
the constructor. The constructor signature shows that pageStyle can be passed in as a
param, but this never happens. There's only one usage of `new CSSRuleView()`.
The pageStyle exist on the inspector instance passed in to the CSSRuleView.
This patch ensures that the CSSRuleView makes use of the PageStyleFront instance
from the inspector and removes the unused param from the constructor.
Perhaps it's better for the Fonts panel to manage its own ElementStyle instance to
get access to the element's selected rules. But in the interest of time, since the
merge date is soon, I'd rather have this fix in quikcly now and keep the dependency
to a Rules view instance with the promise to revisit the Fonts panel architecture and
remove this dependency during the Firefox 65 Nightly cycle.
Differential Revision: https://phabricator.services.mozilla.com/D9002
--HG--
extra : moz-landing-system : lando
The use of <iframe mozbrowser> in test_saveHeapSnapshot_e10s_01.html has
implicitly depended on the "network.disable.ipc.security" pref set to
false, which is the default for desktop and not applicable for Fennec.
With the new mobile test harness, this pref needs to be set explicitly
by the test.
Differential Revision: https://phabricator.services.mozilla.com/D7786
--HG--
extra : moz-landing-system : lando
Before this patch, in developer console, enabling persist log, message displayed "Navigated to" ..something was not distinguishable from console.log messages. Now specific class for navigation marker is added.
Differential Revision: https://phabricator.services.mozilla.com/D7040
--HG--
extra : moz-landing-system : lando
This patches solves 2 issues:
- it doesn't return any result when the user is trying to
perform a variable, function or class declaration (e.g.
var d).
- js-property-provider used to compute the last statement
by only looking for space or ; chars. But there are a lot
of cases (basically each time using an operator), where we
should return results and we weren't.
Test cases are added to cover those fixes.
Differential Revision: https://phabricator.services.mozilla.com/D8968
--HG--
extra : moz-landing-system : lando
On the server, when looking for a flex container for a node, we were bailing
out if the displayType of the node was null. It was null for pseudo-elements.
This value was returned by the displayType getter in the NodeActor class.
Now, the reason for this dates to 4 years ago in bug 1139937 where trying to
get the display style of a pseudo-element was done in a way to failed. So we
just decided to return null at that point. It doesn't fail anymore, we're
able to return, say, "block" if a pseudo-element has a display:block style.
So I've removed the checks that returned null and that fixed the issue here.
The other part of the fix that was need is in the FlexItemActor class on the
server too. This class can be created for a pseudo-element too.
It accesses element.style without checking if that property exists. However it
does not exist for pseudo-elements. So we needed to add a check for that.
It's not a problem to just skip it in this case because pseudo-elements can't
have inline styles.
Differential Revision: https://phabricator.services.mozilla.com/D8873
--HG--
extra : moz-landing-system : lando
Depends on D8334.
In this changeset we also change the way we are reading the preferences
in adb-addon.js to avoid caching the value of the preference the first
time the module is loaded.
This allows the module to follow updates of said preferences without
having to restart Firefox.
Differential Revision: https://phabricator.services.mozilla.com/D8335
--HG--
extra : moz-landing-system : lando
Maybe we want to land the simplest solution for now and discuss
quickly how to style the message to reduce confusion in a follow up?
Differential Revision: https://phabricator.services.mozilla.com/D8334
--HG--
extra : moz-landing-system : lando
Depends on D8334.
In this changeset we also change the way we are reading the preferences
in adb-addon.js to avoid caching the value of the preference the first
time the module is loaded.
This allows the module to follow updates of said preferences without
having to restart Firefox.
Differential Revision: https://phabricator.services.mozilla.com/D8335
--HG--
extra : moz-landing-system : lando
Maybe we want to land the simplest solution for now and discuss
quickly how to style the message to reduce confusion in a follow up?
Differential Revision: https://phabricator.services.mozilla.com/D8334
--HG--
extra : moz-landing-system : lando
For now, the options panel was calling `attach` to know if the javascript was disabled
on the debugged document. But this property is already cached during the `attach`
request done by the toolbox.
MozReview-Commit-ID: JcDT6vxCUzN
Depends on D8851
Differential Revision: https://phabricator.services.mozilla.com/D8852
--HG--
extra : moz-landing-system : lando
A function was missing in the serviceContainer stub,
and the console.trace with params test needed a
Provider wrapper to work with the latest changes made
to the ObjectInspector.
Differential Revision: https://phabricator.services.mozilla.com/D8861
--HG--
extra : moz-landing-system : lando
In this patch, I converted the call sites where there was an obvious target. I left out
those where there wasn't one... Should these be converted as well?
Depends on D8369
Differential Revision: https://phabricator.services.mozilla.com/D8374
--HG--
extra : moz-landing-system : lando
This is part 1 of bug 1497545, and covers the most difficult case, which is migrating
attachURL to something a bit more modern and easier to read. The goal is to make our tests more
consistant with our code base now, and keep these tests maintainable.
UPDATE: I will split this up, as it is too large to review in one pass
Differential Revision: https://phabricator.services.mozilla.com/D8369
--HG--
extra : moz-landing-system : lando
This patch moves the parserService from the toolbox,
which isn't accessible in the case of the Browser Console,
to the console itself.
A lightweight test is added to ensure top-level await is
supported in the browser console.
Differential Revision: https://phabricator.services.mozilla.com/D8816
--HG--
extra : moz-landing-system : lando
Added new getters to the ADB scanner so our runtime objects have now the information we need.
Note that the UX of the devices in this patch doesn't still match what we had in the mockups (icons don't match, and we also need a circle with a tick), but since we have another bug to handle the CSS in the Sidebar, we can always adapt it there. The information needed to display what is shown in the mockups should be passed in this patch –if I miss anything, give me a shout!
Differential Revision: https://phabricator.services.mozilla.com/D7705
--HG--
extra : moz-landing-system : lando
This is a refactor of the components used in the sidebar. TL;DR: sidebar items now use the composition approach outlined here https://reactjs.org/docs/composition-vs-inheritance.html
Before we had a container `Sidebar` component, which in turn had `SidebarItem` components inside. The issue was that depending on what item is inside, the information and UX displayed is different. Before this patch, we had an optional commponent, `DeviceSidebarItemAction` –which was featuring a "Connect" button, and was only rendered in the runtime sidebar items. However, we now need to display even more info, so continue to pass optional components to `SidebarItem` was tricky.
What this patch does is to preserve `SidebarItem` and treat is a generic container of more specific content. This is passed via the `children` prop, which React automatically maps to the DOM content that we pass to that component (this is the same concept as slots in Web Components / Vue). `SidebarItem` now only contains the logic to select items in the sidebar and render them in `<li>` elements. Two new components, `SidebarFixedItem` (for our "static" pages) and `SidebarDeviceItem` are now the ones instancing `SidebarItem` with their specific contents.
Differential Revision: https://phabricator.services.mozilla.com/D7704
--HG--
extra : moz-landing-system : lando
Depends on D8334.
In this changeset we also change the way we are reading the preferences
in adb-addon.js to avoid caching the value of the preference the first
time the module is loaded.
This allows the module to follow updates of said preferences without
having to restart Firefox.
Differential Revision: https://phabricator.services.mozilla.com/D8335
--HG--
extra : moz-landing-system : lando
Maybe we want to land the simplest solution for now and discuss
quickly how to style the message to reduce confusion in a follow up?
Differential Revision: https://phabricator.services.mozilla.com/D8334
--HG--
extra : moz-landing-system : lando
If push the ctrl+t, browser will open the new tab. In this case,
the XUL popup panel doesn't hide automatically(autohide=false).
As the result of it, the popup menu will be displayed in the new tab
content. So this patch will hide the popup when receiving the ctr+t
shortcut in the MenuButton.
Differential Revision: https://phabricator.services.mozilla.com/D8809
--HG--
extra : moz-landing-system : lando
If we displayed the devtools across the second screen, the Screen.availLeft
might be not zero. I.e., Screen.availLeft point to second screen's left.
The HTMLTooltip does't consider this case, so this patch will change the
viewpor's left and right position if the left of anchor element is bigger than
screen.right.
Differential Revision: https://phabricator.services.mozilla.com/D8183
--HG--
extra : moz-landing-system : lando
JsTerm's focus function was called in clearOutput, which
we call when navigating to a new page (if Persist Logs is
not checked).
This means that we were forcing the JsTerm to be focused
each time the user navigated while having the console open.
This behavior, can be annoying, or at worst, if you're
debugging a focus issue in your content page, completely maddening.
The fix is striaghtforward: do not call focus in clearOutput.
A test is added to make sure we don't regress this.
Differential Revision: https://phabricator.services.mozilla.com/D8701
--HG--
extra : moz-landing-system : lando
* browser_addons_debug_webextension_popup: It looks like frame-update events are now fired earlier.
I had to move the listener to an earlier step in order to make it work.
* helper_disable_cache + toolbox.js: this test wasn't correctly listening for reconfigure request's end.
Not clear how this test was passing before without high rate of intermittent...
* test_webextension-addon-debugging-connect.html: We can no longer listen for frame-update *before* the target object is created.
(because we now need a TabTarget object or the TargetFront and not just the DebuggerClient)
* Fix reload request in shadereditor which may still be pending after test ends.
MozReview-Commit-ID: 49qvWSCn6nq
Depends on D8066
Differential Revision: https://phabricator.services.mozilla.com/D7460
--HG--
extra : moz-landing-system : lando
* debugger-controller and events.js are special and require to support two cases because this is
the only production codepath that can have a TabTarget or a WorkerTarget.
Thus, leading to either TargetFront or WorkerClient on target.activeTab.
* webide.js doesn't need to listen for tabNavigated, this is redundant with tabListChanged.
* application's initializer. In case you are wondering this code can't be spawn against a WorkerTarget.
The application panel doesn't work in worker toolboxes.
* The code modified in target is in TabTarget, so we don't have to support the WorkerClient case, we always have a TargetFront here.
* I tried to update the doc file the best I can but this all feel outdated.
MozReview-Commit-ID: 2hGchebfIub
Depends on D7458
Differential Revision: https://phabricator.services.mozilla.com/D7459
--HG--
extra : moz-landing-system : lando
TabClient appears to be a client for any actor that inherits from browsing context target actor.
So let it be a front for that.
MozReview-Commit-ID: KmpClxJ53N7
Depends on D7457
Differential Revision: https://phabricator.services.mozilla.com/D7458
--HG--
extra : moz-landing-system : lando
Added new getters to the ADB scanner so our runtime objects have now the information we need.
Note that the UX of the devices in this patch doesn't still match what we had in the mockups (icons don't match, and we also need a circle with a tick), but since we have another bug to handle the CSS in the Sidebar, we can always adapt it there. The information needed to display what is shown in the mockups should be passed in this patch –if I miss anything, give me a shout!
Differential Revision: https://phabricator.services.mozilla.com/D7705
--HG--
extra : moz-landing-system : lando
This is a refactor of the components used in the sidebar. TL;DR: sidebar items now use the composition approach outlined here https://reactjs.org/docs/composition-vs-inheritance.html
Before we had a container `Sidebar` component, which in turn had `SidebarItem` components inside. The issue was that depending on what item is inside, the information and UX displayed is different. Before this patch, we had an optional commponent, `DeviceSidebarItemAction` –which was featuring a "Connect" button, and was only rendered in the runtime sidebar items. However, we now need to display even more info, so continue to pass optional components to `SidebarItem` was tricky.
What this patch does is to preserve `SidebarItem` and treat is a generic container of more specific content. This is passed via the `children` prop, which React automatically maps to the DOM content that we pass to that component (this is the same concept as slots in Web Components / Vue). `SidebarItem` now only contains the logic to select items in the sidebar and render them in `<li>` elements. Two new components, `SidebarFixedItem` (for our "static" pages) and `SidebarDeviceItem` are now the ones instancing `SidebarItem` with their specific contents.
Differential Revision: https://phabricator.services.mozilla.com/D7704
--HG--
extra : moz-landing-system : lando
Remove the floating scrollbar implementation used on Linux now that CSS scrollbar-color
landed for Linux. Also force scrollbar-color for the DevTools light theme on Linux, to
avoid visual conflicts with dark GTK themes.
Differential Revision: https://phabricator.services.mozilla.com/D7858
--HG--
extra : moz-landing-system : lando
- Made the border for the final size thicker
- Made the delta area more transparent
- Removed the arrow-head pattern for the delta area
- Added a thin horizontal arrow instead
- Removed the background circle around the lock icon
- Added a non-blurry shadow area around it instead
The mockup also called for adding a new label for "grow".
I did not implement this yet, because this will require more
work that can be done in a separate bug. We also need to
decide what happens if there isn't enough room to display
it.
Differential Revision: https://phabricator.services.mozilla.com/D8520
--HG--
extra : moz-landing-system : lando