WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
154048
Web Inspector: Allow copying all headers in the request/response header tables
https://bugs.webkit.org/show_bug.cgi?id=154048
Summary
Web Inspector: Allow copying all headers in the request/response header tables
Derk-Jan Hartman
Reported
2016-02-09 14:43:59 PST
Quite often I have to file bugreports, where caching headers and varnish IDs and dates and cookies and basically everything that might remotely influence your session is important. Most of this information (with the exception of cookies, which is
bug 16531
) is available to me right there in the response section of the request. But if I want to use it, I have to select each individual value and copy and past it somewhere else. This leads to a routine of "Type name of header (faster than copying it from inspector), copy value, repeat". After 2 headers i'm annoyed that I have to do it like this, after 8 headers i'm cursing :) JoePeck> thedj: hmm, our DataGrid class doesn't yet have multiple-selection, so that would require some implementation work JoePeck> thedj: we have a context menu for "Copy Row" maybe a "Copy All Rows" would be a reasonable short term hack"
Attachments
[PATCH] Proposed Fix
(5.23 KB, patch)
2016-02-09 15:16 PST
,
Joseph Pecoraro
timothy
: review+
Details
Formatted Diff
Diff
[PATCH] For Landing
(5.35 KB, patch)
2016-02-09 16:13 PST
,
Joseph Pecoraro
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2016-02-09 14:44:26 PST
<
rdar://problem/24576302
>
Joseph Pecoraro
Comment 2
2016-02-09 14:53:25 PST
It was easy to add a "Copy Table" context menu item here, which includes the DataGrid header names and then all the copyable row data. I'll test this a bit more and put up a patch.
Joseph Pecoraro
Comment 3
2016-02-09 15:16:54 PST
Created
attachment 270956
[details]
[PATCH] Proposed Fix There are other enhancement requests around copying requests as cURL and getting more exportable data about requests/responses. However a quick fix for this, which makes sense elsewhere as well, is to add a "Copy Table" context menu to any DataGrid that has copyable data. This patch adds it to rows and headers.
Timothy Hatcher
Comment 4
2016-02-09 15:30:25 PST
Comment on
attachment 270956
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=270956&action=review
> Source/WebInspectorUI/UserInterface/Views/DataGrid.js:1250 > + var fields = []; > + for (var identifier of this.orderedColumns)
let
Devin Rousso
Comment 5
2016-02-09 15:44:32 PST
Comment on
attachment 270956
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=270956&action=review
>> Source/WebInspectorUI/UserInterface/Views/DataGrid.js:1250 >> + for (var identifier of this.orderedColumns) > > let
Actually, couldn't you just use an Array.prototype.map() here? let fields = this.orderedColumns.map(item => this.headerTableHeader(identifier).textContent);
Joseph Pecoraro
Comment 6
2016-02-09 16:13:17 PST
Comment on
attachment 270956
[details]
[PATCH] Proposed Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=270956&action=review
>>> Source/WebInspectorUI/UserInterface/Views/DataGrid.js:1250 >>> + for (var identifier of this.orderedColumns) >> >> let > > Actually, couldn't you just use an Array.prototype.map() here? > let fields = this.orderedColumns.map(item => this.headerTableHeader(identifier).textContent);
I like it. Used this for both this and the other similar method.
Joseph Pecoraro
Comment 7
2016-02-09 16:13:46 PST
Created
attachment 270960
[details]
[PATCH] For Landing
Joseph Pecoraro
Comment 8
2016-02-09 16:16:14 PST
> > Actually, couldn't you just use an Array.prototype.map() here? > > let fields = this.orderedColumns.map(item => this.headerTableHeader(identifier).textContent);
s/item/identifier/ Also we were avoiding arrow functions that used `this` in their body because the implicit lexical this binding was flakey until recently. But from what I understand this is working well now, and I tested this case and it worked well. So, onward with arrow functions!
WebKit Commit Bot
Comment 9
2016-02-09 17:13:41 PST
Comment on
attachment 270960
[details]
[PATCH] For Landing Clearing flags on attachment: 270960 Committed
r196348
: <
http://trac.webkit.org/changeset/196348
>
Derk-Jan Hartman
Comment 10
2016-02-22 03:39:53 PST
Super useful change, I've already used it twice today !
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug