Closed
Bug 1380927
Opened 8 years ago
Closed 8 years ago
Fix context menu alias
Categories
(DevTools :: Netmonitor, enhancement)
DevTools
Netmonitor
Tracking
(firefox56 fixed)
RESOLVED
FIXED
Firefox 56
| Tracking | Status | |
|---|---|---|
| firefox56 | --- | fixed |
People
(Reporter: Honza, Assigned: Honza)
Details
Attachments
(1 file)
This is a follow up for bug 1376291.
Webpack alias feature doesn't support relative URLs. So, we need to change "./utils/menu" URL to something like "devtools/client/netmonitor/src/utils/menu" and then properly alias it in Net monitor's webpack config (used when loading Net panel on top of the Launchpad).
Honza
| Comment hidden (mozreview-request) |
| Assignee | ||
Updated•8 years ago
|
Assignee: nobody → odvarko
| Assignee | ||
Comment 2•8 years ago
|
||
(In reply to Ricky Chien [:rickychien] from comment #11)
> Webpack alias cannot support ./xxx/xxx pattern [1]. So the only way you can
> do for supporting both toolbox and launchpad is to change "./utils/menu" at
> to "devtools/client/netmonitor/src/utils/menu" and then update the
> webpack alias in webpack.config.js to
> "devtools/client/netmonitor/src/utils/menu"
Yes, that's exactly what I've been doing to fix the problem, but I am still seeing:
ERROR in C:/src/mozilla.org/mozilla-central/devtools/client/netmonitor/src/request-list-header-context-menu.js
Module not found: Error: Cannot resolve module 'devtools-launchpad/src/components/shared/menu' in C:\src\mozilla.org\mozilla-central\devtools\client\netmonitor\src
@ C:/src/mozilla.org/mozilla-central/devtools/client/netmonitor/src/request-list-header-context-menu.js 9:21-73
ERROR in C:/src/mozilla.org/mozilla-central/devtools/client/netmonitor/src/request-list-context-menu.js
Module not found: Error: Cannot resolve module 'devtools-launchpad/src/components/shared/menu' in C:\src\mozilla.org\mozilla-central\devtools\client\netmonitor\src
@ C:/src/mozilla.org/mozilla-central/devtools/client/netmonitor/src/request-list-context-menu.js 22:21-73
Any tips?
Honza
Flags: needinfo?(rchien)
| Comment hidden (mozreview-request) |
| Assignee | ||
Comment 4•8 years ago
|
||
Errors, above solved offline.
@Ricky, can you please test the following:
- Apply the patch above
- Run the net monitor in the Launchpad
- Open DevTools on the Launchpad page and see if the generateod netmonitor.js bundle contains `let { top } = menuItemNode.getBoundingClientRect();` line in `showsSubMenu` method.
This line represents the change introduced in `devtools-contextmenu` module (v0.0.3), but from some reason it isn't included in the result bundle (netmonitor.js)
Honza
| Assignee | ||
Comment 5•8 years ago
|
||
@Jason: There is a new version of devtools-contextmenu module, but from some reason it isn't included in the final Netmonitor bundle when building it using Webpack.
Do you have any tips why?
STR:
- Apply the attached patch
- Go to devtools/client/netmonitor directory
- run yarn install & webpack
- Check out the bundle file: assets/build/netmonitor.js - it doesn't contain this change: https://github.com/devtools-html/devtools-core/commit/8b0e606922ddd9fcb6a3f9bc18c6f4f6f9b97c10
Honza
Flags: needinfo?(jlaster)
Comment 6•8 years ago
|
||
Can you try to upgrade devtools-launchpad to the latest version and see what happen?
Flags: needinfo?(rchien)
Comment 7•8 years ago
|
||
yep, the launchpad should be updated.
https://github.com/devtools-html/devtools-core/blob/master/packages/devtools-launchpad/package.json#L59-L60
For launchpad dependencies, we should upgrade them both at the same time.
Flags: needinfo?(jlaster)
Comment 8•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8886484 [details]
Bug 1380927 - Fix context menu alias;
https://reviewboard.mozilla.org/r/157280/#review162736
Please upgrade devtools-launchpad.
Attachment #8886484 -
Flags: review?(rchien)
| Comment hidden (mozreview-request) |
| Assignee | ||
Updated•8 years ago
|
Status: NEW → ASSIGNED
Comment 10•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8886484 [details]
Bug 1380927 - Fix context menu alias;
https://reviewboard.mozilla.org/r/157280/#review163262
Thanks Honza. Your patch looks great and it fixed the position issue in sub-menu.
Attachment #8886484 -
Flags: review?(rchien) → review+
Comment 11•8 years ago
|
||
Pushed by jodvarko@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c5e8ab69906d
Fix context menu alias; r=rickychien
Comment 12•8 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox56:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 56
Updated•7 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•