Commit Graph
12 Commits
Author SHA1 Message Date
Joel Einbinder 83fc76e621 DevTools: Follow Lighthouse's a11y suggestions
Running Lighthouse on DevTools lead to these changes:
 * Label our <select> toolbar items
 * Don't use tabIndex=1 for our canvas elements
 * Don't use li items in the network panel
 * add lang=en to our html tags

Change-Id: I9fef3d731dbbcbb56c3f73d81fd5669d65fa9827
Reviewed-on: https://chromium-review.googlesource.com/1093399
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#566195}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 237b755cd007b58b585ad34137353e11e2bc3ccd
2018-06-11 23:19:47 +00:00
Joel Einbinder f5ea74e541 DevTools: Make CodeMirror accessible
This overrides the default CodeMirror input logic to put more text in
the textarea.

CodeMirror uses an offscreen <textarea> to detect input. Due to
inconsistencies in the many browsers it supports, it simplifies things
by regularly checking if something is in the <textarea>, adding those
characters to the document, and then clearing the <textarea>. This
breaks assistive technology that wants to read from CodeMirror,
because the <textarea> that they interact with is constantly empty.

Because we target up-to-date Chrome, we can guarantee consistent
input events. This lets us leave the current line from the editor in
our <textarea>. CodeMirror still expects a mostly empty <textarea>, so
we pass CodeMirror a fake <textarea> that only contains the user's input.

Change-Id: I025a1937bfd66fa574fd692da079a5888d9cb529
Reviewed-on: https://chromium-review.googlesource.com/1020193
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#564347}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: d06dd5982b810b4c3576388ef3a31f060685dff7
2018-06-05 02:14:19 +00:00
Joel Einbinder 7ddfa6c277 DevTools: Don't overwrite unprocessed lines in TextEditorAutocomplete
CodeMirror change events can be batched, so multiple before change
events can happen before a change. If a line has not been processed
yet, we shouldn't overwrite it on the intermediate beforechange
or words can be left behind in the dictionary.

Change-Id: I056d95a85870cb1a5d25797159bad01628848edf
Reviewed-on: https://chromium-review.googlesource.com/1083213
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Commit-Queue: Andrey Lushnikov <lushnikov@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#563818}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: df8ba004326cd0a2182b002b29475111d7737a05
2018-06-01 21:56:02 +00:00
Joel Einbinder d7595c7afb DevTools: Auto pretty print in sources panel experiment
Change-Id: Ib16be938e7df8c90f02da1211f350d172c34ebff
Reviewed-on: https://chromium-review.googlesource.com/1047949
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#558766}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 6cc4917ff46b654205b4aa1700c049c14d2ebabd
2018-05-15 17:41:54 +00:00
Joel Einbinder 3f23eb2bdd DevTools: Argument hints for native functions
Change-Id: Ia0e9f3c98735d64a1188b4373c90b7ef2684ea48
Reviewed-on: https://chromium-review.googlesource.com/1054582
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Reviewed-by: Erik Luo <luoe@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#558527}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a5be1a79f122d4496aa4a09ddfad0b475d878248
2018-05-14 23:27:51 +00:00
Joel Einbinder 13157addd1 DevTools: Have the console SuggestBox prefer top when eager eval is on
This should make the suggest box obscure eager eval less often.

Change-Id: I60573ed142947daa005f648c13d1c3a32f8d492b
Reviewed-on: https://chromium-review.googlesource.com/1048025
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#558097}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a5f5f164294fd4d330f9b6f758d8b73056684838
2018-05-12 02:16:37 +00:00
Joel Einbinder 2fc0fb7ea3 DevTools: Give argument hints in the console prompt
https://i.imgur.com/Y3OlPM2.png

Change-Id: Ic1d9ef1d47ff93ce77bfc3ae7173689bccf0cb2c
Reviewed-on: https://chromium-review.googlesource.com/1031096
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#557030}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 66bdf19b13c9a1dffbd47121101e0b8aedde3495
2018-05-09 00:43:10 +00:00
Erik Luo 6f5c111941 DevTools: convert below prompt experiment into setting
The new setting is in the toolbar behind the gear.
Screenshot: https://imgur.com/a/09myIJH

Bug: 810176
Change-Id: Ifbd2a2bfc6712e2f2415e384c040f5520b1e2347
Reviewed-on: https://chromium-review.googlesource.com/1045180
Commit-Queue: Erik Luo <luoe@chromium.org>
Reviewed-by: Pavel Feldman <pfeldman@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#556734}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 93eb26e6cbda0437be38d2d4f00f0ab2b9b411c1
2018-05-08 08:59:22 +00:00
Joel Einbinder b6b043b39d DevTools: Use current suggestion for eager eval
Change-Id: I4079e769b46f16d3635c25276beb832ced10107b
Reviewed-on: https://chromium-review.googlesource.com/1041076
Reviewed-by: Erik Luo <luoe@chromium.org>
Reviewed-by: Andrey Lushnikov <lushnikov@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#556594}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: ef612396f8ca20e7070b770cb39293bf0882f462
2018-05-07 22:58:13 +00:00
Joel Einbinder 5d6cc6eeaa DevTools: SourceFrame pretty print improvements
I extracted out some improvements to inplace pretty print in
SourceFrame from my sources auto pretty print patch.

* Line numbers become blue when pretty print is active
* Selection is properly scrolled into view when pretty print is toggled

Change-Id: Ib1cf8f0a15b8495594ecf121cef8786d8cfd0f16
Reviewed-on: https://chromium-review.googlesource.com/1044878
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#556318}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: d893a023c6a2ad473795fc680170c2a018eedab3
2018-05-05 06:29:47 +00:00
Joel Einbinder cb4688dbaa DevTools: Select console suggestions with enter
* Enter accepts the current suggestion in the console.

* History suggestions are not auto-selected. The user must use the
  arrow keys or manually click to select them now.

Previously we worried about that the user would accidentally select a
suggestion in the console when they actually wanted to run the command
as is. Due to recent improvements in autocomplete, this is less of a
problem. Autocomplete showing up on an already complete expression
should be extremely rare. The only exception is history completions,
which are no longer autoselected.

Change-Id: Id9d567ae69f4c29c63e875a1f3285448adbd7ce3
Reviewed-on: https://chromium-review.googlesource.com/1026838
Reviewed-by: Erik Luo <luoe@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#555609}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: ca3ac226e566791986bb6451bdfcb02d661c6eb8
2018-05-02 23:29:16 +00:00
Blink Reformat 4c46d0969f The Great Blink mv for source files, part 2.
Move and rename files.

NOAUTOREVERT=true
NOPRESUBMIT=true
NOTREECHECKS=true
Bug: 768828
TBR=darin@chromium.org
NOTRY=true

Change-Id: I66d3b155808bc5bdbf237b80208e1e552bcf7f28
Reviewed-on: https://chromium-review.googlesource.com/1001153
Reviewed-by: Blink Reformat <blink-reformat@chromium.org>
Commit-Queue: Blink Reformat <blink-reformat@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#549061}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 0aee4434a4dba42a42abaea9bfbc0cd196a63bc1
2018-04-07 15:32:37 +00:00