Commit Graph
149 Commits
Author SHA1 Message Date
Andres Olivares fe25667745 [module.json extensions] lighthouse
Bug: 1134103
Change-Id: Ic4799907f8b3b29b6c51bf9f908c994be88b72ed
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2630309
Reviewed-by: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Andres Olivares <andoli@chromium.org>
2021-01-19 16:22:39 +00:00
Andres Olivares f738ca6aff [module.json extensions] js_profiler
Bug: 1134103
Change-Id: Id4c8715f0af09ae13dc0b826d4977f75aeb17973
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2630307
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-19 15:27:59 +00:00
Andres Olivares 0ed100f0df [module.json extensions] layers
Bug: 1134103
Change-Id: I52bef8418bc7f103a2d4e301ce548597b3dbb73f
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2630308
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-19 15:16:27 +00:00
Andres Olivares ba24df0ed5 [module.json extensions] linear_memory_inspector
Bug: 1134103
Change-Id: I3e0064e3da93d99857358af7860e82b6fa84ebce
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2631961
Commit-Queue: Andres Olivares <andoli@chromium.org>
Auto-Submit: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-19 14:18:57 +00:00
Andres Olivares f2a99e868d [module.json extensions] help views
Bug: 1134103
Change-Id: I797fc82b277511f0aa11cb365c7dfd0f933b4ef4
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2629728
Commit-Queue: Andres Olivares <andoli@chromium.org>
Auto-Submit: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-18 20:31:36 +00:00
Andres Olivares 5135060ac7 [module.json extensions] issues views
Bug: 1134103
Change-Id: I0a919093cf3463f248a50aaf3152c903928570af
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2630305
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-18 18:29:56 +00:00
Andres Olivares 49a36a120b [module.json extensions] resources views
Bug: 1134103
Change-Id: Idb39a93006a87a885800b7e668e015fa7d65b37a
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2631962
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-18 14:39:26 +00:00
Andres Olivares 3100aca993 [module.json extensions] inspector_main views
Bug: 1134103
Change-Id: I469e5c7799f8286a41d7ecd59354ac6a91aaa8d9
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2629730
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-15 14:45:10 +00:00
Andres Olivares f125cbd2cc [module.json extensions] input views
Bug: 1134103
Change-Id: Ia9ea0ccad3064a3c80a9902206a4b977b908df86
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2629729
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2021-01-15 14:33:00 +00:00
Tim van der Lippe 6d5bdf4f7e [module.json extensions] developer_resources
R=andoli@chromium.org

Bug: 1134103
Change-Id: I433c9a8d02541ace0fbf7662f6689faaa7f0607a
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2612856
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-13 12:40:02 +00:00
Tim van der Lippe 2f1ea1c2ca [module.json extensions] changes
R=andoli@chromium.org

Bug: 1134103
Change-Id: Ic2d249ae33f7e291ff7bdf921e35c92d8f5649ad
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2612853
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-13 10:55:43 +00:00
Tim van der Lippe 6d21034c1b [module.json extensions] animation
R=andoli@chromium.org

Bug: 1134103
Change-Id: I40dd16d7e5ddc9c3b1a879bdda0b9d0de13fdf20
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2612854
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-13 10:35:02 +00:00
Tim van der Lippe a71272ea25 [module.json extensions] coverage
R=andoli@chromium.org

Bug: 1134103
Change-Id: Iefcbb03583eaeb7d008abb0d4cbce7256747a149
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2612857
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-12 15:38:31 +00:00
Tim van der Lippe 677a98d1c4 Remove component_docs from GRD
These files are not intended to be included in the DevTools release
bundle and therefore should be treated as testonly. This also means
that we should be using `ts_library` instead of `devtools_module`,
as we don't intend to copy these files into `resources/inspector`.

R=jacktfranklin@chromium.org

Fixed: 1152777
Change-Id: Id23d403c64445dd1c0ea59e36117dfc667f7e8e5
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2617796
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2021-01-08 16:09:47 +00:00
Tim van der Lippe 413e363c0d [module.json extensions] console
R=andoli@chromium.org

Bug: 1134103
Change-Id: If5b847276297ee1f8a37b6adf01816f430cdfc02
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2589955
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-05 12:26:49 +00:00
Tim van der Lippe 6dd4b0c912 [module.json extensions] Security
This also fixes a bug where `build_release_applications` wasn't
rebuilding when changes would be made to devtools_app.js

R=andoli@chromium.org

Bug: 1134103
Change-Id: I50831c41e0ce7c04ddeb0c1a44acd51436ef92b3
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2593143
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2021-01-05 12:14:09 +00:00
Andres Olivares f1c7fd55a5 [module.json extensions] Migrate profiler views
Bug: 1134103
Change-Id: Iee95736b9604d3b0fb7d065ecc37b92758fa1156
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2589758
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-12-16 21:51:45 +00:00
Tim van der Lippe 9e5d60a44d [module.json extensions] Accessibility
R=andoli@chromium.org

Bug: 1134103
Change-Id: I4f84afb3ad98939096360aa385e6605374f69186
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2593141
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2020-12-16 14:52:20 +00:00
Tim van der Lippe 5e8c855ced Remove css_overview-legacy.js
Its extensions have been moved into the css_overview-meta.ts file
and all other content of the module.json is unused. Since none
of the layout tests use the CSSOverview symbols, we don't have
to add them to the integration_test_runner.js either.

R=aerotwist@chromium.org

Bug: 1127902
Change-Id: I10c70babc913b80d8b751386805520caa84640d2
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2587021
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-12-15 11:47:57 +00:00
Tim van der Lippe 4b527cff8b [module.json extensions] emulation
R=andoli@chromium.org

Bug: 1134103
Change-Id: I23be42ec86fbcab1f7a5f62972fcb73a296fb961
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2587017
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2020-12-14 16:24:06 +00:00
Tim van der Lippe 28d5ad7efb [module.json extensions] css_overview
R=andoli@chromium.org

Bug: 1134103
Change-Id: Icef477bfebec409bdcb7fa1d2af6d5d034968b9d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2587020
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2020-12-14 16:06:46 +00:00
Tim van der Lippe 6be8c13512 Add assertNever to platform for exhaustive switch statements
To make sure that a particular switch statement implements all
branches of, for example, a union or enum, we can implement the
`assertNever` function. This function will ensure in the type
system that the relevant branches are covered and will result
in compilation errors if a branch is missing.

This `assertNever` call is used together with a refactoring of
FormatterActions (which is a inlineable const enum) to ensure
that the tasks posted to the FormatterWorker stay in sync between
the formatter_worker and the FormatterWorkerPool. Since we can
not import the `formatter_worker` bundle in a non-worker context,
we instead extract it into a separate entrypoint, imported by both.

R=jacktfranklin@chromium.org

Bug: 1158395
Change-Id: Id643486936e7fad300d0f40774ee851adcc76ef5
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2589953
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2020-12-14 15:59:06 +00:00
Andres Olivares 70b668a4fd [module.json extensions] Migrate network views
Bug: 1134103
Change-Id: I3bcc8c238bf0ec2734236777ed696067846aa7a3
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2577165
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-12-10 17:14:28 +00:00
Andres Olivares fd431fb765 [module.json extensions] sources views
Bug: 1134103
Change-Id: I1f050156edc6c0500aa19dc18f43d7463541128b
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2584524
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-12-10 16:42:44 +00:00
Tim van der Lippe 59ff4e28de Move worker integration into entrypoint for wasmparser_worker
This allows us to test the wasmparser_worker implementation
in isolation in unit tests, while extracting out the worker
integration into a separate file. A follow-up CL will migrate
the wasmparser_worker to use URL-based worker construction,
which will allow us to remove the wasmparser_worker-entrypoint
in front_end/ and cleanup the RuntimeInstantiator.js logic.

R=jacktfranklin@chromium.org,bmeurer@chromium.org

Bug: 1009443
Change-Id: I77d04ab870b38ec9f9209c1a156c123c941d169b
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2581927
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
2020-12-10 10:21:28 +00:00
Tim van der Lippe c8dc38a7d6 Move worker integration into entrypoint for heap_snapshot_worker
This allows us to import the heap_snapshot_worker bundle in the
unit tests, to start computing coverage for it.

R=jacktfranklin@chromium.org

Bug: 1009443
Change-Id: I5f1456c8c28679da3e259b2da8c3e0386af5e38d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2581926
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
2020-12-10 10:02:48 +00:00
Tim van der Lippe d47c1d7073 Fold cm_modes into text_editor
Historically, cm_modes was used to lazily load CodeMirror MIME modes.
However, since we are no longer using CodeMirror MIME modes as
remote modules, we have switched to using ES imports to load them
instead. To that end, we made the `DefaultCodeMirrorMimeMode` extension
obsolete, as it became a noop for loading.

Moreover, cm_modes was loaded via the module.json infrastructure
present in the shell.json file. As such, in release mode these
files would properly load, but in a standalone (e.g. unit test)
environment, the missing links would cause these modes not to load.

To remedy the situation, we perform multiple fixes:
1. Remove the module.json extensions, since we are using ES imports
instead.
2. Remove DefaultCodeMirrorMimeMode.js (it is obsolete)
3. Move cm_modes.js into text_editor (this was the only module
that actually was loading the full version of CodeMirror)
4. Remove the infrastructure in CodeMirrorTextEditor.js to retrieve
the Mime modes (these were effectfully noops).

I have personally verified these Mime modes are still correctly
loading by opening a personal workspace with various Python/CC files
and confirmed that the syntax highlighting in the sources panel
is as expected.

R=aerotwist@chromium.org

Bug: 1127902
Change-Id: Ia3502713be247dc373e80fc3daa65ca7d9ecc1fe
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2577560
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-12-07 16:33:06 +00:00
Tim van der Lippe 441af8af42 Fix formatter_worker entrypoint inclusion for unit tests
For our unit tests, we couldn't import the entrypoint of the
formatter_worker, since that entrypoint assumed it was running
in a worker context. Since our Karma unit tests run in a browser
context, it would start throwing errors on the postMessage call.

Instead, we should separate out the concerns of the formatter_worker
implementation and integration of its worker context with the
FormatterPool. To that end, we separate the implementation bundle
from the worker integration into a separate file "formatter_worker-entrypoint.ts".

To ensure we retain full test coverage, the integration part is
tested through e2e-tests, while the implementation of the
formatter_worker will remain being tested by unit tests.

After this change, we will now also compute full code coverage for
the formatter_worker folder, which we couldn't do before.

All of this will be used to port CSS pretty-printing tests from
layout to Karma tests, which will require yet another implementation
detail of the formatter_worker, which will now be exported through
its bundle entrypoint.

R=aerotwist@chromium.org

Bug: 1024752
Change-Id: I5f10a3ebab10e1012cf2244df779cdc31da06ed7
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2575091
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
2020-12-07 16:24:51 +00:00
Tim van der Lippe d18c704c60 Cleanup devtools_module_entrypoints.gni
Both front_end_devtools_module_entrypoint_sources and
generated_devtools_module_entrypoint_sources were unused, since
the `devtools_entrypoint` migration has finished.

Secondly, we can rename generated_typescript_entrypoint_sources to
generated_module_entrypoint_sources, since we no longer need to
distinguish between JavaScript and TypeScript entrypoints.

Lastly, we can clean up the definition of
devtools_module_entrypoint_sources to no longer include the
$resources_out_dir line, which saves some duplication.

R=aerotwist@chromium.org

Change-Id: I1a327cf40cec6630b3be7ac53e2c87f7e179c895
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2566802
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-12-03 11:43:03 +00:00
Tim van der Lippe 08ecb1751c [module.json extensions] browser_debugger views
R=andoli@chromium.org

Bug: 1134103
Change-Id: I6751bbf874b4e42b4650398d8d5c121e748fed6e
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2565573
Reviewed-by: Andres Olivares <andoli@chromium.org>
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
2020-12-01 13:20:55 +00:00
Tim van der Lippe 846d414664 Fix Node inspect debugger
Similarly to crrev.com/c/2560757 the node_debugger module was
also missing its entrypoint.

R=aerotwist@chromium.org

Fixed: 1152203
Change-Id: Ic079029a82a39f265ae49a8f9fcc460e0f8ef5c7
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2562340
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Commit-Queue: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-11-26 16:43:53 +00:00
Jack Franklin 3642900e6d Load new theme colours in the component docs.
This CL updates the component docs server so it automatically injects the new
colour variables (which are part of the dark mode work) into the server. It
contains the following changes:

1. Pulling out the new colours into a new CSS file,
   `ui/themeColors.css`, which contain all the new definitions.
2. Injecting that new file where we inject `inspectorStyles.css`
   currently.
3. Updating the component docs server to intercept any requests to load
   an HTML example file, read the HTML contents and inject a `<style>`
   tag to load in the theme colours.
4. Additionally we now provide a small bit of JS that adds a handy
   button to toggle light/dark mode without needing to dive into the dev
   tools.

Fixed: 1152774
Change-Id: Ia2df0e00315dfeb532570ea5634fa54677337f76
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2560941
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-25 16:26:10 +00:00
Tim van der Lippe 26b7dab721 Reland "Migrate elements/ extensions of type 'view'"
This reverts commit ed2a064ac1.

Reason for revert: Autoroller issues have been addressed in separate CLs

Original change's description:
> Revert "Migrate elements/ extensions of type 'view'"
>
> This reverts commit e9b95b83fe.
>
> Reason for revert: Breaks Autoroller when trying to roll to Chromium 
>
> Original change's description:
> > Migrate elements/ extensions of type 'view'
> >
> > Bug:1134103
> > Change-Id: I800a19dc9b721ea17e3241f387eb7af70cabca85
> > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2552055
> > Commit-Queue: Andres Olivares <andoli@chromium.org>
> > Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
>
> TBR=tvanderlippe@chromium.org,andoli@chromium.org
>
> Change-Id: I7852464be52dec0e0b8f413c2841e2e01474ede5
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: 1134103
> Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2555599
> Commit-Queue: Andres Olivares <andoli@chromium.org>
> Reviewed-by: Andres Olivares <andoli@chromium.org>

Bug: 1134103
Change-Id: I1ea4832c76ebf034ee901df4b70ea937d420e2e4
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2557046
Reviewed-by: Andres Olivares <andoli@chromium.org>
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-25 14:04:47 +00:00
Tim van der Lippe aa37563fe9 Fix Node inspect profiler
While js_profiler is an empty module, it has a single purpose:
specify a panel in its `module.json`. Therefore, it needs a corresponding
(unused) entrypoint file, with the appropriate GN infrastructure.

While the files itself are basically unused, the Runtime enforces
that every single module has a corresponding entrypoint. And that
assumption was invalid for `js_profiler`.

R=aerotwist@chromium.org

Fixed: 1151855
Change-Id: I14acce9c547c22c67a3b4bb26e8a7a2224015254
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2556689
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-11-24 16:07:57 +00:00
Andres Olivares ed2a064ac1 Revert "Migrate elements/ extensions of type 'view'"
This reverts commit e9b95b83fe.

Reason for revert: Breaks Autoroller when trying to roll to Chromium 

Original change's description:
> Migrate elements/ extensions of type 'view'
>
> Bug:1134103
> Change-Id: I800a19dc9b721ea17e3241f387eb7af70cabca85
> Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2552055
> Commit-Queue: Andres Olivares <andoli@chromium.org>
> Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>

TBR=tvanderlippe@chromium.org,andoli@chromium.org

Change-Id: I7852464be52dec0e0b8f413c2841e2e01474ede5
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 1134103
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2555599
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
2020-11-23 22:08:38 +00:00
Andres Olivares e9b95b83fe Migrate elements/ extensions of type 'view'
Bug:1134103
Change-Id: I800a19dc9b721ea17e3241f387eb7af70cabca85
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2552055
Commit-Queue: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-23 15:48:56 +00:00
Jan Scheffler 3a230e2849 [Recorder] Add recording to DevTools
Bug: chromium:1144127
Change-Id: I58a5add98bf08a8113ecdf674e08911a79f7b12b
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2505657
Commit-Queue: Jan Scheffler <janscheffler@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Mathias Bynens <mathias@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-19 13:55:32 +00:00
Jack Franklin b14dbe3426 Fix heuristic for determining external bundles in Release
The current bundling system with Rollup tries to determine when given a
file if it’s an entry point (e.g. ui/ui.js) or not (e.g ui/someFile.js).
If it’s not an entry point, it will bundle that file into the entry
point JS file. So when we go to bundle ui/ui.js, it’ll find files like
ui/someFile.js, and pull them into ui/ui.js, which ends up being a fully
“rolled up” version of the ui folder.

The problem comes when you nest these folders;
ui/components/components.js is an entry point but the logic that the
Rollup bundling code uses incorrectly detects it as a regular file. So
you end up with ui/ui.js including a rolled-up version of
ui/components/components.js, which itself is a rolled-up file. We then
ship ui/ui.js and ui/components/components.js, meaning we’ve shipped
components.js twice - once as a standalone file, and once because it was
rolled up into ui.js.

This CL fixes this by changing how we detect bundles, we now look for
importing files whose parent directory is the same, so:

- components/components.js is a bundle
- but components/foo.js is not a bundle

By making this change we also now correctly detect third_party bundles,
with the exception of Acorn which is a special case, so we can lose the
checks for that in our Rollup config.

The logic here is somewhat duplicated between Rollup's config and the
ESLint rule plugin that we have; I plan on making a follow-up CL that
tries to define this logic in one place so if it changes in the future
we can update the code in one place and have the linting & rollup
update, plus we'll be able to use the ESLint tests as coverage to ensure
we've not broken our bundling.

Fixed: 1144123
Change-Id: Idd82a3ef69a09871867626a0d74266e25801243f
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2534202
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-18 14:19:58 +00:00
Kim-Anh Tran c9ec4beff0 Show linear memory inspector as drawer
If the 'wasmDWARFDebugging' experiment is on one can right click
on the a Uint8Array within the Scope View to open the linear memory
inspector drawer.

After: https://imgur.com/a/CXJi7Ks

Bug: chromium:1110202
Change-Id: I7e5255f8f3c021ac2e581235e34b83e65dc8ad43
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2518044
Commit-Queue: Kim-Anh Tran <kimanh@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
2020-11-17 06:59:47 +00:00
Tim van der Lippe 801f27f7e0 Redirect front_end/marked to third_party/marked
Since issues is now TypeScript-authored and is the only module
that was relying on Marked, we are no longer bound by marked
being in a direct subdirectory of front_end. Therefore, we
can treat it as lit-html and directly import from
third_party/marked instead.

To make sure that we don't bundle Marked in issues itself,
we have to update the Rollup logic to exclude it for now.
We will clean that up in a future Cl, where we are changing
the heuristic for "bundliness".

R=szuend@chromium.org,jacktfranklin@chromium.org

Bug: 1011811
Change-Id: Ieb40470a9efcd072ff5b360b7bd487f15df2a689
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2529157
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Simon Zünd <szuend@chromium.org>
2020-11-11 14:45:09 +00:00
Jack Franklin f3ebb1429d New DataGrid component.
This CL introduces the new DataGrid component, and is split into two:

- DataGrid, which is a "plain" component that takes data and renders it.
- DataGridController, which is a "smart" component that can take the
data and manipulate it (e.g. sorting), before passing it into a DataGrid
to be rendered.

These components are not feature complete in that they do not support
all features of the incumbent `DataGrid.js` but they are not designed
to. The goal here is to land the initial data-grid components, and then
work on using them in DevTools (as part of the protocol monitor). At
that point we can extend functionality by seeing what is missing and
testing in DevTools, rather than testing in isolation.

This CL includes the implementation, unit tests and component
documentation examples of the functionality that does exist, along with
a README explaining the two components and when to use each one.

Bug: 1125966
Change-Id: I1b5c9a0174c4563be64b5b4adcc8251d1498b55d
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2461772
Commit-Queue: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Reviewed-by: Andres Olivares <andoli@chromium.org>
Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org>
2020-11-05 15:40:11 +00:00
Kim-Anh Tran ba5e4813da Adding linear memory inspector navigator component
This adds the navigator component of the linear memory inspector
that is used to navigate through an array buffer.

After: https://imgur.com/a/RPELp6P

Bug: chromium:1110202
Change-Id: Id2acd96222ed11de92cd2a1fb5130ea5d79c9ab5
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2484363
Commit-Queue: Kim-Anh Tran <kimanh@chromium.org>
Reviewed-by: Jack Franklin <jacktfranklin@chromium.org>
Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
2020-10-20 13:41:04 +00:00
Tim van der Lippe 3387bd4064 Move startup files to GN
There previously were two special files that were handled
by `build_release_applications`: root.js and RuntimeInstantiator.js.
Both files are explicitly part of the startup process of DevTools
and its various entrypoints.

To remove the copying from `build_release_applications`, we have
to move these to the relevant `devtools_entrypoint`. Since a
`devtools_entrypoints` bundles all subdirectories, we can't keep
these files in `front_end/` directly. Instead, we move these files
to `startup/` to denote their special-casing in the startup process.

Next to that, we have to fix all usages of these files in the entrypoints.
For all JavaScript entrypoint files, all side-effect legacy files
that are loaded by `startup.js` (previously known as `root.js` and renamed
to prevent confusion with the `root/` module) are removed. All
"additional" legacy files that a particular entrypoint requires are
still loaded as-is.

The RuntimeInstantiator is moved to become an implementation detail
of `startup/`. Therefore, all of the usages that were previously
importing from `RuntimeInstantiator` now import via `startup.js`.

In the end, the special-casing of these files are removed and renamed
for clarity. In the future, we want to remove the complicated
entrypoints startup process, but we are not ready for that yet.
That will require additional cleanups with `resources` in `module.json`
before that change can happen.

R=aerotwist@chromium.org

Bug: 1131500
Change-Id: I198d5a62d2aab70f842c68d9b4c0871fde1587a4
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2485072
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-20 12:55:34 +00:00
Tim van der Lippe ead1fa43d0 Move remaining legacy files to GN
R=aerotwist@chromium.org

Bug: 1131500
Change-Id: Ibb247dd02a5032604824517be4276c4b83c8fc8c
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2479140
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-19 09:25:50 +00:00
Tim van der Lippe c20afe742b Move legacy files from ui modules to GN
R=aerotwist@chromium.org

Bug: 1131500
Change-Id: I8ece4d0b8373584333b9639e2ba3f4a584088619
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2476335
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-16 11:03:37 +00:00
Tim van der Lippe 42fbb0aca2 Move legacy files from model modules to GN
R=aerotwist@chromium.org

Bug: 1131500
Change-Id: I28b598c770801947eace05164e5308c621f5407a
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2476334
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-16 10:58:47 +00:00
Tim van der Lippe 8a408c1be4 Move legacy files from core modules to GN
R=aerotwist@chromium.org

Bug: 1131500
Change-Id: Ic61ee8b06fc5c6cfbc41682aebbdc232e91e556e
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2476333
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-16 10:50:32 +00:00
Tim van der Lippe 8fa9d45123 Build common-legacy.js with devtools_entrypoint
To continue to move away from `build_release_applications.py`, move
building `common-legacy.js` into `devtools_entrypoint`. In the end,
it will allow us to remove `_rollup_module` from
`build_release_applications.py`.

The logic in `build_release_applications.py` is updated to assume
a pregenerated `-legacy.js` file based on the `pre_generates_legacy`
option in the `module.json` file. Once all `-legacy.js are migrated,
we can remove this option once again.

To make sure that we Rollup properly, we should assume that an
entrypoint in the same folder is regarded as external. Otherwise,
we would rollup the contents of `common.js` into `common-legacy.js`,
which is not what we want.

R=aerotwist@chromium.org

Bug: 1131500
Change-Id: Idcda3e1c2436a0bebb36501523c8d586d6e86fac
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2450297
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-10-14 11:42:10 +00:00
Tim van der Lippe f5feb1fec6 Reland "Reland "Remove support for remote modules""
This reverts commit 862107080d.

Reason for revert: Chromium build issue fixed.

Original change's description:
> Revert "Reland "Remove support for remote modules""
> 
> This reverts commit b3859e8d65.
> 
> Reason for revert: Breaking roll (https://ci.chromium.org/p/chromium/builders/ci/win-archive-rel/17700)
> 
> Original change's description:
> > Reland "Remove support for remote modules"
> > 
> > This reverts commit d5044ddf05.
> > 
> > Reason for revert: Fixed Chromium debug issue.
> > 
> > Original change's description:
> > > Revert "Remove support for remote modules"
> > > 
> > > This reverts commit 419c91eff6.
> > > 
> > > Reason for revert: Breaks roll https://chromium-review.googlesource.com/c/chromium/src/+/2416805
> > > 
> > > Original change's description:
> > > > Remove support for remote modules
> > > > 
> > > > LightHouse is currently broken in Canary, because of problems with
> > > > the appspot server. This isn't the first occurrence of this problem
> > > > and it becomes increasingly more difficult to figure out why the
> > > > server keeps on breaking. This is combined with a large infrastructure
> > > > cost of supporting remote modules and a confusing debugging experience
> > > > when working with it locally.
> > > > 
> > > > The reason we had remote modules was the fact that these modules are
> > > > too large to be included in the Chromium bundle. In the last months,
> > > > we have made numerous remote modules bundled, by applying minifications
> > > > and optimizations to each module.
> > > > 
> > > > The remaining remote module that we are currently shipping is LightHouse.
> > > > Since the remote appspot server is broken and unlikely to be fixed
> > > > anytime soon, now is the best time to finally resolve the remote
> > > > modules question.
> > > > 
> > > > Therefore, we remove support for remote modules from the `module.json`
> > > > files and `Runtime.js`. Additionally, we update the build system
> > > > to properly generate the required files and load them via ES modules.
> > > > 
> > > > We will be able to perform subsequent cleanups in the Runtime to remove
> > > > more infrastructure related to scripts/remote modules, but given that
> > > > this CL is already quite large we are doing that in a follow-up CL.
> > > > 
> > > > Follow-up action items for the LightHouse folks are to further decrease
> > > > the bundle size for LightHouse. Since we are now loading it via ES
> > > > modules, we can now use ES imports in the `devtools-dt-bundle.js` as
> > > > well. This allows us to remove the copy of the SDK files, as well as
> > > > make use of proper ES exports, rather than the browserified requires.
> > > > 
> > > > R=​aerotwist@chromium.org,yangguo@chromium.org,paulirish@chromium.org
> > > > 
> > > > Fixed: 1128890
> > > > Change-Id: Ib4271a8064b18d31b75d9e28dbe5e3cb3c77d7ff
> > > > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2416511
> > > > Reviewed-by: Paul Lewis <aerotwist@chromium.org>
> > > > Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
> > > 
> > > TBR=yangguo@chromium.org,paulirish@chromium.org,aerotwist@chromium.org,tvanderlippe@chromium.org
> > > 
> > > Change-Id: I9d3da08108a35d7dadeefd526ea9dbd562ad3432
> > > No-Presubmit: true
> > > No-Tree-Checks: true
> > > No-Try: true
> > > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2416519
> > > Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
> > > Commit-Queue: Alex Rudenko <alexrudenko@chromium.org>
> > 
> > Change-Id: I26bf0565297c8e167039362b30109d7020bbca56
> > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2418431
> > Commit-Queue: Paul Lewis <aerotwist@chromium.org>
> > Reviewed-by: Paul Lewis <aerotwist@chromium.org>
> 
> TBR=yangguo@chromium.org,paulirish@chromium.org,aerotwist@chromium.org,tvanderlippe@chromium.org,alexrudenko@chromium.org
> 
> Change-Id: I0ed24d32c9b68bc4cb8026f6fc362540800beeb0
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2418408
> Reviewed-by: Paul Lewis <aerotwist@chromium.org>
> Commit-Queue: Paul Lewis <aerotwist@chromium.org>

Change-Id: I8718e9d94c384a13fd18261f8f497d32418658fb
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2421690
Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
2020-09-21 12:11:10 +00:00
Paul Lewis 862107080d Revert "Reland "Remove support for remote modules""
This reverts commit b3859e8d65.

Reason for revert: Breaking roll (https://ci.chromium.org/p/chromium/builders/ci/win-archive-rel/17700)

Original change's description:
> Reland "Remove support for remote modules"
> 
> This reverts commit d5044ddf05.
> 
> Reason for revert: Fixed Chromium debug issue.
> 
> Original change's description:
> > Revert "Remove support for remote modules"
> > 
> > This reverts commit 419c91eff6.
> > 
> > Reason for revert: Breaks roll https://chromium-review.googlesource.com/c/chromium/src/+/2416805
> > 
> > Original change's description:
> > > Remove support for remote modules
> > > 
> > > LightHouse is currently broken in Canary, because of problems with
> > > the appspot server. This isn't the first occurrence of this problem
> > > and it becomes increasingly more difficult to figure out why the
> > > server keeps on breaking. This is combined with a large infrastructure
> > > cost of supporting remote modules and a confusing debugging experience
> > > when working with it locally.
> > > 
> > > The reason we had remote modules was the fact that these modules are
> > > too large to be included in the Chromium bundle. In the last months,
> > > we have made numerous remote modules bundled, by applying minifications
> > > and optimizations to each module.
> > > 
> > > The remaining remote module that we are currently shipping is LightHouse.
> > > Since the remote appspot server is broken and unlikely to be fixed
> > > anytime soon, now is the best time to finally resolve the remote
> > > modules question.
> > > 
> > > Therefore, we remove support for remote modules from the `module.json`
> > > files and `Runtime.js`. Additionally, we update the build system
> > > to properly generate the required files and load them via ES modules.
> > > 
> > > We will be able to perform subsequent cleanups in the Runtime to remove
> > > more infrastructure related to scripts/remote modules, but given that
> > > this CL is already quite large we are doing that in a follow-up CL.
> > > 
> > > Follow-up action items for the LightHouse folks are to further decrease
> > > the bundle size for LightHouse. Since we are now loading it via ES
> > > modules, we can now use ES imports in the `devtools-dt-bundle.js` as
> > > well. This allows us to remove the copy of the SDK files, as well as
> > > make use of proper ES exports, rather than the browserified requires.
> > > 
> > > R=​aerotwist@chromium.org,yangguo@chromium.org,paulirish@chromium.org
> > > 
> > > Fixed: 1128890
> > > Change-Id: Ib4271a8064b18d31b75d9e28dbe5e3cb3c77d7ff
> > > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2416511
> > > Reviewed-by: Paul Lewis <aerotwist@chromium.org>
> > > Commit-Queue: Tim van der Lippe <tvanderlippe@chromium.org>
> > 
> > TBR=yangguo@chromium.org,paulirish@chromium.org,aerotwist@chromium.org,tvanderlippe@chromium.org
> > 
> > Change-Id: I9d3da08108a35d7dadeefd526ea9dbd562ad3432
> > No-Presubmit: true
> > No-Tree-Checks: true
> > No-Try: true
> > Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2416519
> > Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
> > Commit-Queue: Alex Rudenko <alexrudenko@chromium.org>
> 
> Change-Id: I26bf0565297c8e167039362b30109d7020bbca56
> Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2418431
> Commit-Queue: Paul Lewis <aerotwist@chromium.org>
> Reviewed-by: Paul Lewis <aerotwist@chromium.org>

TBR=yangguo@chromium.org,paulirish@chromium.org,aerotwist@chromium.org,tvanderlippe@chromium.org,alexrudenko@chromium.org

Change-Id: I0ed24d32c9b68bc4cb8026f6fc362540800beeb0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2418408
Reviewed-by: Paul Lewis <aerotwist@chromium.org>
Commit-Queue: Paul Lewis <aerotwist@chromium.org>
2020-09-18 21:55:03 +00:00