Web Inspector: support undo/redo of insertAdjacentHTML
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2017-11-09  Devin Rousso  <webkit@devinrousso.com>
2
3         Web Inspector: support undo/redo of insertAdjacentHTML
4         https://bugs.webkit.org/show_bug.cgi?id=179283
5
6         Reviewed by Joseph Pecoraro.
7
8         * UserInterface/Models/DOMNode.js:
9         (WI.DOMNode.prototype.insertAdjacentHTML):
10
11         * UserInterface/Views/DOMTreeElement.js:
12         (WI.DOMTreeElement.prototype._startEditingAsHTML):
13         Drive-by: only attempt to update the cursor if an initialValue is supplied.
14
15 2017-11-09  Joseph Pecoraro  <pecoraro@apple.com>
16
17         Web Inspector: Make domain availability a list of types instead of a single type
18         https://bugs.webkit.org/show_bug.cgi?id=179457
19
20         Reviewed by Brian Burg.
21
22         * UserInterface/Protocol/InspectorBackend.js:
23         (InspectorBackendClass.prototype.activateDomain):
24         The second value changed to be an optional list. Check if the active
25         debuggable type is in the list or not.
26
27         * UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
28         * UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js:
29         * UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js:
30         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
31         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
32         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
33         * Versions/Inspector-iOS-10.0.json:
34         * Versions/Inspector-iOS-10.3.json:
35         * Versions/Inspector-iOS-11.0.json:
36         * Versions/Inspector-iOS-8.0.json:
37         * Versions/Inspector-iOS-9.0.json:
38         * Versions/Inspector-iOS-9.3.json:
39         Since this is a change to how we generate the frontend resource,
40         update the legacy versioned backends and regenerate their resource.
41
42 2017-11-09  Carlos Garcia Campos  <cgarcia@igalia.com>
43
44         REGRESSION(r224566): [GTK][WPE] Many inspector tests are failing after r224566
45         https://bugs.webkit.org/show_bug.cgi?id=179419
46
47         Reviewed by Carlos Alberto Lopez Perez.
48
49         All of them fail with the following error:
50
51         Uncaught exception in Inspector page: ReferenceError: Can't find variable: CodeMirror [TestCombined.js:36658:15]
52
53         This is because Test.html, even when combined, is trying to load CodeMirror from External/CodeMirror, but
54         CodeMirror was already combined for Main.html. We need to also combine CodeMirror for Test.html.
55
56         * Scripts/copy-user-interface-resources.pl:
57
58 2017-11-08  Joseph Pecoraro  <pecoraro@apple.com>
59
60         Web Inspector: Show Internal properties of PaymentRequest in Web Inspector Console
61         https://bugs.webkit.org/show_bug.cgi?id=179276
62
63         Reviewed by Andy Estes.
64
65         * UserInterface/Test.html:
66         * UserInterface/Test/FrontendTestHarness.js:
67         (FrontendTestHarness.prototype.evaluateInPage):
68         * UserInterface/Test/TestUtilities.js: Added.
69         (promisify):
70         Make async tests a little easier to work with by providing promises
71         in some cases that would normally take a callback.
72
73 2017-11-08  Brian Burg  <bburg@apple.com>
74
75         Web Inspector: fix incorrect curly quote orientation in a UIString
76         https://bugs.webkit.org/show_bug.cgi?id=179353
77         <rdar://problem/35368697>
78
79         Reviewed by Joseph Pecoraro.
80
81         I didn't see any other instances of this mistake in our localized strings.
82
83         * Localizations/en.lproj/localizedStrings.js:
84         * UserInterface/Views/ResourceTimelineDataGridNode.js:
85         Fix it.
86
87 2017-11-08  Joseph Pecoraro  <pecoraro@apple.com>
88
89         Web Inspector: Remove unused Page.ScriptIdentifier protocol type
90         https://bugs.webkit.org/show_bug.cgi?id=179407
91
92         Reviewed by Matt Baker.
93
94         * Versions/Inspector-iOS-10.0.json:
95         * Versions/Inspector-iOS-10.3.json:
96         * Versions/Inspector-iOS-11.0.json:
97         * Versions/Inspector-iOS-7.0.json:
98         * Versions/Inspector-iOS-8.0.json:
99         * Versions/Inspector-iOS-9.0.json:
100         * Versions/Inspector-iOS-9.3.json:
101         Remove unused protocol type.
102
103 2017-11-06  Nikita Vasilyev  <nvasilyev@apple.com>
104
105         Web Inspector: Styles Redesign: Display warnings
106         https://bugs.webkit.org/show_bug.cgi?id=179215
107
108         Reviewed by Brian Burg.
109
110         Display warning icons on the right of the property.
111
112         For now, the warning icons have only three title messages:
113         - Invalid property name;
114         - Invalid property value;
115         - Duplicate property.
116
117         * Localizations/en.lproj/localizedStrings.js:
118         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
119         (.spreadsheet-style-declaration-editor .property):
120         (.spreadsheet-style-declaration-editor .property-toggle):
121         (.spreadsheet-style-declaration-editor .property.invalid-value:not(.disabled) .value):
122         (.spreadsheet-style-declaration-editor .property.has-warning):
123         (.spreadsheet-style-declaration-editor .property .warning):
124         Draw the warning arrow and icon using only one HTML element.
125         Don't set "top" property so the element remains vertically where it would be if it had "position: static".
126
127         (.spreadsheet-style-declaration-editor .property.has-warning .warning):
128         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
129         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesChanged):
130         (WI.SpreadsheetCSSStyleDeclarationEditor):
131         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
132         (.spreadsheet-css-declaration):
133         (.spreadsheet-css-declaration :matches(.header, .header-media)):
134         (.spreadsheet-css-declaration .close-brace):
135         Make properties span the entire width of the styles sidebar. Unsupported properties have yellow
136         background. There should be no gaps between the property element and sidebar left and right edges.
137
138         * UserInterface/Views/SpreadsheetStyleProperty.js:
139         (WI.SpreadsheetStyleProperty):
140         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
141         (WI.SpreadsheetStyleProperty.prototype._update):
142         (WI.SpreadsheetStyleProperty.prototype.updateClassNames): Deleted.
143         Rename updateClassNames to updateStatus since it modifies title attribute of the warning element.
144
145 2017-11-06  Ross Kirsling  <ross.kirsling@sony.com>
146
147         Web Inspector: Two little Layers tab fixes
148         https://bugs.webkit.org/show_bug.cgi?id=179273
149
150         Reviewed by Devin Rousso.
151
152         * UserInterface/Views/LayerDetailsSidebarPanel.js:
153         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
154         Even when we suppress refire of the selected event, we still want a popover.
155
156         * UserInterface/Views/Layers3DContentView.js:
157         (WI.Layers3DContentView):
158         (WI.Layers3DContentView.prototype.shown):
159         (WI.Layers3DContentView.prototype.hidden):
160         (WI.Layers3DContentView.prototype.closed):
161         (WI.Layers3DContentView.prototype._layerTreeDidChange):
162         Opening WI directly to the Layers tab wasn't fetching layers right away. Let's fetch on every shown() and
163         prune the hacky logic we were previously using -- it's overkill anyway, now that we're tracking mutations.
164
165 2017-11-06  Joseph Pecoraro  <pecoraro@apple.com>
166
167         Web Inspector: no way to navigate from Resource tree element to its entry in Network Tab
168         https://bugs.webkit.org/show_bug.cgi?id=179328
169         <rdar://problem/35367294>
170
171         Reviewed by Brian Burg.
172
173         * Localizations/en.lproj/localizedStrings.js:
174         New reveal in network tab string.
175
176         * UserInterface/Base/Main.js:
177         (WI.isShowingNetworkTab):
178         Utility to know if the network tab is showing.
179
180         * UserInterface/Views/ContextMenuUtilities.js:
181         (WI.appendContextMenuItemsForSourceCode):
182         (showResourceWithOptions):
183         (WI.appendContextMenuItemsForURL):
184         Generalize context menus for just a URL.
185
186         * UserInterface/Views/TabBrowser.js:
187         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
188         Support more tab ignore options, this is starting to get icky. We may want to
189         move to just a preferredTab approach, since that is what some of these want.
190
191         * UserInterface/Views/DOMTreeElement.js:
192         (WI.DOMTreeElement.prototype._populateTagContextMenu):
193         Make use of new ContextMenu utility to add menu items for a URL.
194
195         * UserInterface/Views/NetworkTabContentView.js:
196         (WI.NetworkTabContentView.prototype.showRepresentedObject):
197         * UserInterface/Views/NetworkTableContentView.js:
198         (WI.NetworkTableContentView.prototype.showRepresentedObject):
199         Handle showing a Resource in the NetworkTab. We immediately show
200         the details view for it, otherwise we fallback to the list view.
201
202 2017-11-06  Joseph Pecoraro  <pecoraro@apple.com>
203
204         Uncaught Exception: TypeError: null is not an object (evaluating 'mimeType.endsWith')
205         https://bugs.webkit.org/show_bug.cgi?id=179325
206         <rdar://problem/35366896>
207
208         Reviewed by Brian Burg.
209
210         * UserInterface/Base/MIMETypeUtilities.js:
211         (WI.fileExtensionForMIMEType):
212         (WI.shouldTreatMIMETypeAsText):
213         Handle null mime types.
214
215 2017-11-06  Joseph Pecoraro  <pecoraro@apple.com>
216
217         Web Inspector: Selecting a DOM Search Result in Search Tab unexpectedly changes Tabs
218         https://bugs.webkit.org/show_bug.cgi?id=179223
219         <rdar://problem/33949556>
220
221         Reviewed by Devin Rousso.
222
223         * Localizations/en.lproj/localizedStrings.js:
224         New string.
225
226         * UserInterface/Views/SearchResultTreeElement.js:
227         (WI.SearchResultTreeElement.prototype.populateContextMenu):
228         Add a context menu for search results to jump to a different tab.
229         These behaviors match the double click behavior for search results.
230
231         * UserInterface/Views/SearchTabContentView.js:
232         (WI.SearchTabContentView.prototype.canShowRepresentedObject):
233         Always support showing a DOM Tree. Clients should be using
234         ignoreSearchTab if they don't want to jump here.
235
236         * UserInterface/Views/DOMTreeDataGridNode.js:
237         (WI.DOMTreeDataGridNode.prototype._goToArrowWasClicked):
238         * UserInterface/Views/LayerTreeDataGridNode.js:
239         (WI.LayerTreeDataGridNode.prototype._goToArrowWasClicked):
240         Use ignoreSearchTab just in case when showing a DOM Tree.
241
242         * UserInterface/Views/ContentBrowser.js:
243         (WI.ContentBrowser.prototype.shown):
244         When showing, update our UI to reflect the values of the current content view, which
245         for a while may have been owned by another ContentBrowser.
246
247         (WI.ContentBrowser.prototype._contentViewSelectionPathComponentDidChange):
248         (WI.ContentBrowser.prototype._contentViewSupplementalRepresentedObjectsDidChange):
249         (WI.ContentBrowser.prototype._contentViewNavigationItemsDidChange):
250         We can avoid work in a few places where we might not be the owning ContentBrowser
251         of a ContentView that is changing.
252
253 2017-11-05  Nikita Vasilyev  <nvasilyev@apple.com>
254
255         REGRESSION (r221338): Web Inspector: NavigationBar incorrectly calculates minimumWidth
256         https://bugs.webkit.org/show_bug.cgi?id=179292
257
258         Reviewed by Devin Rousso.
259
260         * UserInterface/Views/NavigationBar.js:
261         (WI.NavigationBar.prototype._calculateMinimumWidth):
262         totalItemWidth was the minimumWidth of the last item.
263
264 2017-11-05  Devin Rousso  <webkit@devinrousso.com>
265
266         Web Inspector: Canvas Tab: selecting Frame tree element should update preview/slider, does nothing
267         https://bugs.webkit.org/show_bug.cgi?id=179072
268         <rdar://problem/35278711>
269
270         Reviewed by Matt Baker.
271
272         * UserInterface/Views/CanvasTabContentView.js:
273         (WI.CanvasTabContentView.prototype._navigationSidebarTreeOutlineSelectionChanged):
274
275         * UserInterface/Views/RecordingActionTreeElement.css:
276         (.item.action > .titles .parameter.swizzled):
277         (.tree-outline:not(:focus, .force-focus) .item.action:not(.initial-state, .parent, .invalid) > .icon): Deleted.
278         (body:not(.window-inactive, .window-docked-inactive) .item.action > .titles .parameter.swizzled): Deleted.
279         Drive-by: remove extra :focus selectors to prevent icon flashing when the window is blurred.
280
281 2017-11-04  Devin Rousso  <webkit@devinrousso.com>
282
283         Web Inspector: add contextmenu item to arbitrarily add HTML/Child to DOMTree
284         https://bugs.webkit.org/show_bug.cgi?id=179042
285
286         Reviewed by Joseph Pecoraro.
287
288         * Localizations/en.lproj/localizedStrings.js:
289
290         * UserInterface/Models/DOMNode.js:
291         (WI.DOMNode.prototype.insertAdjacentHTML.inspectedPage_node_insertAdjacentHTML):
292         (WI.DOMNode.prototype.insertAdjacentHTML):
293         Call-through to `insertAdjacentHTML` on the corresponding node in the inspected page.
294
295         * UserInterface/Views/DOMTreeElement.js:
296         (WI.DOMTreeElement):
297         (WI.DOMTreeElement.prototype._populateNodeContextMenu):
298         (WI.DOMTreeElement.prototype._startEditingAsHTML.dispose):
299         (WI.DOMTreeElement.prototype._startEditingAsHTML):
300         (WI.DOMTreeElement.prototype._insertAdjacentHTML.commitCallback):
301         (WI.DOMTreeElement.prototype._insertAdjacentHTML):
302         (WI.DOMTreeElement.prototype.updateTitle):
303         (WI.DOMTreeElement.prototype._singleTextChild):
304         (WI.DOMTreeElement.prototype._nodeTitleInfo):
305         (WI.DOMTreeElement.prototype._addHTML):
306         (WI.DOMTreeElement.prototype._addPreviousSibling):
307         (WI.DOMTreeElement.prototype._addNextSibling):
308         (WI.DOMTreeElement.prototype._editAsHTML):
309         Adjust where the editing element is placed depending on the options passed to `_editAsHTML`.
310         If the placement is as a child, put it inside the child list. If the placement is as a
311         sibling, place it before/after the selected TreeElement. Otherwise, add it as a child.
312
313         * UserInterface/Views/DOMTreeOutline.css:
314         (.tree-outline.dom):
315         (.tree-outline.dom li):
316         (.tree-outline.dom li:not(.editing)):
317         (.tree-outline.dom li.editing):
318         (body[dir=ltr] .tree-outline.dom li): Deleted.
319         (body[dir=rtl] .tree-outline.dom li): Deleted.
320         Don't add padding when the list item is being edited.
321
322 2017-11-03  Nikita Vasilyev  <nvasilyev@apple.com>
323
324         Web Inspector: Uncaught Exception: null is not an object (evaluating 'selector.specificity.map') (at SpreadsheetCSSStyleDeclarationSection.js:199:51)
325         https://bugs.webkit.org/show_bug.cgi?id=179225
326         <rdar://problem/35329019>
327
328         Reviewed by Joseph Pecoraro.
329
330         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
331         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._renderSelector):
332         selector.specificity may not exist when the selector is dynamic and doesn't match the selected element.
333
334 2017-11-03  Ross Kirsling  <ross.kirsling@sony.com>
335
336         Web Inspector: Move Show Compositing Borders/Paint Flashing buttons from Elements tab to Layers tab
337         https://bugs.webkit.org/show_bug.cgi?id=179211
338
339         Reviewed by Joseph Pecoraro.
340
341         * UserInterface/Views/DOMTreeContentView.js:
342         (WI.DOMTreeContentView.prototype.get navigationItems):
343         (WI.DOMTreeContentView.prototype._updateCompositingBordersButtonToMatchPageSettings):
344         Guard old buttons with experimental flag.
345
346         * UserInterface/Views/Layers3DContentView.js:
347         (WI.Layers3DContentView):
348         (WI.Layers3DContentView.prototype.get navigationItems):
349         (WI.Layers3DContentView.prototype.shown):
350         (WI.Layers3DContentView.prototype.closed):
351         (WI.Layers3DContentView.prototype._showPaintRectsSettingChanged):
352         (WI.Layers3DContentView.prototype._togglePaintFlashing):
353         (WI.Layers3DContentView.prototype._updateCompositingBordersButtonState):
354         (WI.Layers3DContentView.prototype._toggleCompositingBorders):
355         Add buttons to new home.
356         No need to guard for get/setCompositingBordersVisible anymore, as these were introduced in iOS 7.
357
358 2017-11-03  Devin Rousso  <webkit@devinrousso.com>
359
360         Web Inspector: move top-level namespace functions in ImageUtilities to static class
361         https://bugs.webkit.org/show_bug.cgi?id=179207
362
363         Reviewed by Brian Burg.
364
365         * .eslintrc:
366         * UserInterface/Base/ImageUtilities.js:
367         (WI.ImageUtilities.useSVGSymbol):
368         (WI.ImageUtilities.scratchCanvasContext2D):
369         (WI.ImageUtilities.imageFromImageData):
370         (WI.ImageUtilities.imageFromCanvasGradient):
371         (WI.ImageUtilities):
372         (useSVGSymbol): Deleted.
373         (WI.scratchCanvasContext2D): Deleted.
374         (WI.imageFromImageData): Deleted.
375         (WI.imageFromCanvasGradient): Deleted.
376
377         * UserInterface/Models/Recording.js:
378         (WI.Recording.prototype.async swizzle):
379         * UserInterface/Views/ButtonNavigationItem.js:
380         (WI.ButtonNavigationItem.prototype.set image):
381         * UserInterface/Views/CallFrameTreeElement.js:
382         (WI.CallFrameTreeElement.prototype._updateStatus):
383         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
384         (WI.DOMNodeDetailsSidebarPanel.prototype.initialLayout):
385         * UserInterface/Views/DOMTreeElement.js:
386         (WI.DOMTreeElement.prototype._updateBreakpointStatus):
387         * UserInterface/Views/MultipleScopeBarItem.js:
388         (WI.MultipleScopeBarItem):
389         * UserInterface/Views/RecordingActionTreeElement.js:
390         (WI.RecordingActionTreeElement._generateDOM):
391         (WI.RecordingActionTreeElement.prototype._handleHasVisibleEffectChanged):
392         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
393         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
394         * UserInterface/Views/ResourceMetricsContentView.js:
395         (WI.ResourceMetricsContentView.prototype._refreshResourceSizeSection):
396         * UserInterface/Views/ScopeRadioButtonNavigationItem.js:
397         (WI.ScopeRadioButtonNavigationItem):
398         * UserInterface/Views/ThreadTreeElement.js:
399         (WI.ThreadTreeElement.prototype._updateStatus):
400         * UserInterface/Views/TimelineTreeElement.js:
401         (WI.TimelineTreeElement.prototype._showCloseButton):
402         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.js:
403         (WI.VisualStyleCommaSeparatedKeywordEditor):
404         * UserInterface/Views/VisualStyleKeywordIconList.js:
405         (WI.VisualStyleKeywordIconList):
406         * UserInterface/Views/VisualStylePropertyEditorLink.js:
407         (WI.VisualStylePropertyEditorLink):
408         * UserInterface/Views/VisualStyleSelectorSection.js:
409         (WI.VisualStyleSelectorSection):
410         * UserInterface/Views/WebSocketDataGridNode.js:
411         (WI.WebSocketDataGridNode.prototype.createCellContent):
412
413 2017-11-03  Ross Kirsling  <ross.kirsling@sony.com>
414
415         Web Inspector: Hide legacy Layers sidebar on Search tab
416         https://bugs.webkit.org/show_bug.cgi?id=179257
417
418         Reviewed by Joseph Pecoraro.
419
420         * UserInterface/Views/SearchTabContentView.js:
421         (WI.SearchTabContentView):
422
423 2017-11-03  Joseph Pecoraro  <pecoraro@apple.com>
424
425         Web Inspector: Network Table - Include a secure lock indicator in the domain column
426         https://bugs.webkit.org/show_bug.cgi?id=179233
427         <rdar://problem/34070883>
428
429         Reviewed by Devin Rousso.
430
431         * UserInterface/Views/NetworkTableContentView.css:
432         (.network-table .cell.domain > .lock):
433         * UserInterface/Views/NetworkTableContentView.js:
434         (WI.NetworkTableContentView.prototype.tablePopulateCell):
435         (WI.NetworkTableContentView.prototype._populateDomainCell):
436         Add a small lock icon by the domain if the request was https/wss.
437
438 2017-11-03  Devin Rousso  <webkit@devinrousso.com>
439
440         Web Inspector: Canvas2D Profiling: highlight expensive context commands in the captured command log
441         https://bugs.webkit.org/show_bug.cgi?id=178302
442         <rdar://problem/33158849>
443
444         Reviewed by Brian Burg.
445
446         * UserInterface/Models/RecordingFrame.js:
447         (WI.RecordingFrame):
448         (WI.RecordingFrame.fromPayload):
449         (WI.RecordingFrame.prototype.get duration):
450         (WI.RecordingFrame.prototype.toJSON):
451
452         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
453         (WI.RecordingNavigationSidebarPanel.prototype.set recording):
454         * UserInterface/Views/RecordingNavigationSidebarPanel.css:
455         (.sidebar > .panel.navigation.recording > .content > .tree-outline .item.folder-icon > .status):
456
457 2017-11-02  Devin Rousso  <webkit@devinrousso.com>
458
459         Web Inspector: Canvas Tab: show supported GL extensions for selected canvas
460         https://bugs.webkit.org/show_bug.cgi?id=179070
461         <rdar://problem/35278276>
462
463         Reviewed by Brian Burg.
464
465         * Localizations/en.lproj/localizedStrings.js:
466
467         * UserInterface/Protocol/CanvasObserver.js:
468         (WI.CanvasObserver.prototype.extensionEnabled):
469
470         * UserInterface/Controllers/CanvasManager.js:
471         (WI.CanvasManager.prototype.extensionEnabled):
472
473         * UserInterface/Models/Canvas.js:
474         (WI.Canvas.prototype.get extensions):
475         (WI.Canvas.prototype.enableExtension):
476         Maintain a Set of enabled extensions, and dispatch an event whenever an extension is enabled.
477
478         * UserInterface/Views/CanvasDetailsSidebarPanel.css:
479         (.sidebar > .panel.details.canvas .details-section.canvas-extensions .content > ul):
480         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
481         (WI.CanvasDetailsSidebarPanel.prototype.set canvas):
482         (WI.CanvasDetailsSidebarPanel.prototype.initialLayout):
483         (WI.CanvasDetailsSidebarPanel.prototype.layout):
484         (WI.CanvasDetailsSidebarPanel.prototype._refreshAttributesSection):
485         (WI.CanvasDetailsSidebarPanel.prototype._refreshExtensionsSection):
486         Drive-by: hide Attributes section when the canvas has no attributes.
487
488 2017-11-02  Joseph Pecoraro  <pecoraro@apple.com>
489
490         Make ServiceWorker a Remote Inspector debuggable target
491         https://bugs.webkit.org/show_bug.cgi?id=179043
492         <rdar://problem/34126008>
493
494         Reviewed by Brian Burg.
495
496         Customize the Web Inspector frontend for a ServiceWorker target.
497         Currently this just behaves like a JavaScript Context target because
498         we haven't yet added support for Networking capabilities.
499
500         * UserInterface/Controllers/DebuggerManager.js:
501         (WI.DebuggerManager.prototype.get knownNonResourceScripts):
502         Drive-by fix a bug where lazily initializing the Resources / Debugger tabs
503         would show Console evaluation scripts. We should ignore them, like we
504         do in other places.
505
506         * Localizations/en.lproj/localizedStrings.js:
507         * UserInterface/Controllers/AppController.js:
508         (WI.AppController):
509         (WI.AppController.debuggableTypeFromHost):
510         * UserInterface/Controllers/AppControllerBase.js:
511         * UserInterface/Controllers/TimelineManager.js:
512         (WI.TimelineManager.defaultTimelineTypes):
513         (WI.TimelineManager.availableTimelineTypes):
514         * UserInterface/Models/TimelineRecording.js:
515         (WI.TimelineRecording.sourceCodeTimelinesSupported):
516         * UserInterface/Protocol/MainTarget.js:
517         (WI.MainTarget.prototype.get displayName):
518         * UserInterface/Test/TestAppController.js:
519         * UserInterface/Views/DashboardContainerView.css:
520         (body:not(.web) .toolbar .dashboard-container):
521         (body.javascript .toolbar .dashboard-container): Deleted.
522         * UserInterface/Views/DefaultDashboardView.css:
523         (body:not(.web) .toolbar .dashboard.default > :matches(.resourcesCount, .resourcesSize, .time)):
524         (body.javascript .toolbar .dashboard.default > :matches(.resourcesCount, .resourcesSize, .time)): Deleted.
525         * UserInterface/Views/ResourceSidebarPanel.js:
526         (WI.ResourceSidebarPanel):
527         (WI.ResourceSidebarPanel.shouldPlaceResourcesAtTopLevel):
528         (WI.ResourceSidebarPanel.prototype.initialLayout):
529         (WI.ResourceSidebarPanel.prototype._addScript):
530         (WI.ResourceSidebarPanel.prototype._extraDomainsActivated):
531         * UserInterface/Views/Toolbar.js:
532
533 2017-11-02  Devin Rousso  <webkit@devinrousso.com>
534
535         Web Inspector: Canvas: recording parameters that include an Image should show an InlineSwatch (2D canvas)
536         https://bugs.webkit.org/show_bug.cgi?id=177032
537
538         Reviewed by Brian Burg.
539
540         * Localizations/en.lproj/localizedStrings.js:
541
542         * UserInterface/Test.html:
543         * UserInterface/Base/ImageUtilities.js:
544         (WI.scratchCanvasContext2D):
545         Creates a static canvas that can be used for scratch purposes, such as converting ImageData
546         to an Image, or rendering the result of a CanvasGradient. The canvas is reset after each
547         call of the function so it can be reused by other callers.
548
549         (WI.imageFromImageData):
550         (WI.imageFromCanvasGradient):
551         Utility functions for getting a dataURL image of ImageData/CanvasGradient after drawing it
552         onto WI.scratchCanvasContext2D.
553
554         * UserInterface/Models/Recording.js:
555         (WI.Recording.prototype.async.swizzle):
556         Set the Image used to create a CanvasPattern as an expando property for later use.
557
558         * UserInterface/Models/RecordingAction.js:
559         (WI.RecordingAction.prototype.getImageParameters):
560
561         * UserInterface/Views/RecordingActionTreeElement.js:
562         (WI.RecordingActionTreeElement._generateDOM):
563         Add Image InlineSwatch elements for parameters that are viewable as an image. For ImageData
564         and CanvasGradient, WI.scratchCanvasContext2D is used to draw the ImageData/CanvasGradient
565         and get a dataURL to be used as the image.
566
567         (WI.RecordingActionTreeElement._createSwatchForColorParameters):
568         Drive-by: add checks that the parameter is not a CanvasGradient or CanvasPattern.
569
570         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
571         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
572         Add Image InlineSwatch elements for fillStyle/strokeStyle when the value is a CanvasGradient
573         or a CanvasPattern.
574
575         * UserInterface/Views/InlineSwatch.js:
576         (WI.InlineSwatch):
577         (WI.InlineSwatch.prototype._updateSwatch):
578         (WI.InlineSwatch.prototype._swatchElementClicked):
579         * UserInterface/Views/InlineSwatch.css:
580         (.inline-swatch):
581         (.inline-swatch:matches(.color, .gradient)):
582         (.inline-swatch:matches(.bezier, .spring, .variable)):
583         (.inline-swatch:not(.read-only):matches(.bezier, .spring, .variable):hover):
584         (.inline-swatch:not(.read-only):matches(.bezier, .spring, .variable):active):
585         (.inline-swatch:not(.read-only):active > span):
586         (.inline-swatch:matches(.bezier, .spring, .variable) > span):
587         (.inline-swatch.image > span):
588         (.inline-swatch:matches(.bezier, .spring, .variable):hover): Deleted.
589         (.inline-swatch:matches(.bezier, .spring, .variable):active): Deleted.
590         (.inline-swatch:active > span): Deleted.
591         (.inline-swatch:matches(.bezier, .spring) > span): Deleted.
592         Add Image type for showing previews of images.
593         Drive-by: simplify some styles.
594
595         * UserInterface/Views/RecordingActionTreeElement.css:
596         (.item.action > .titles .parameters > .inline-swatch):
597         (.tree-outline:matches(:focus, .force-focus) .item.action > .titles .parameters > .inline-swatch): Deleted.
598         Drive-by: remove the :focus requirement, as it would cause the InlineSwatch to shift when
599         the user clicked out of the WebInspector window.
600
601 2017-11-02  Joseph Pecoraro  <pecoraro@apple.com>
602
603         Inspector should display service worker served responses properly
604         https://bugs.webkit.org/show_bug.cgi?id=178597
605         <rdar://problem/35186111>
606
607         Reviewed by Brian Burg.
608
609         * Localizations/en.lproj/localizedStrings.js:
610         New Service Worker related strings.
611
612         * UserInterface/Controllers/HARBuilder.js:
613         (WI.HARBuilder.entry):
614         (WI.HARBuilder.timings):
615         Only output timing data when we have real resource timing data.
616
617         (WI.HARBuilder.fetchType):
618         Output a new string for a Service Worker load in our custom field.
619
620         * UserInterface/Models/ResourceTimingData.js:
621         (WI.ResourceTimingData.prototype.get responseStart):
622         Fallback further to the responseEnd. This can happen if the response
623         itself is an error/failure and there was no response, so treat it as
624         the same as response end.
625
626         * UserInterface/Models/Resource.js:
627         (WI.Resource.responseSourceFromPayload):
628         (WI.Resource.prototype.updateForRedirectResponse):
629         (WI.Resource.prototype.updateForResponse):
630         A fetch response won't change the URL, so if the URL is empty
631         don't change it from what the request's URL was.
632
633         (WI.Resource.prototype.hasResponse):
634         Failure is like finished. We should likely transition to an "isComplete" method.
635
636         * UserInterface/Views/NetworkTableContentView.js:
637         (WI.NetworkTableContentView.prototype._populateTransferSizeCell):
638         (WI.NetworkTableContentView.prototype._generateSortComparator):
639         Output "(service worker)" in the transfer size field, to indicate this came
640         from a Service worker. Sort such loads together.
641
642         * UserInterface/Views/ResourceHeadersContentView.js:
643         (WI.ResourceHeadersContentView.prototype._responseSourceDisplayString):
644         (WI.ResourceHeadersContentView.prototype._refreshSummarySection):
645         Include the Service Worker response source in this details view. Also include
646         a FIXME, since we would like to link directly to the service worker in the future.
647
648 2017-11-02  Nikita Vasilyev  <nvasilyev@apple.com>
649
650         Web Inspector: Styles Redesign: turn on CSS spreadsheet editor by default
651         https://bugs.webkit.org/show_bug.cgi?id=179100
652         <rdar://problem/35285990>
653
654         Reviewed by Brian Burg.
655
656         Add a "Legacy Style Editor" checkbox and remove the experimental "Spreadsheet Style Editor" checkbox.
657
658         Remove settings of the legacy styles editor:
659         - Show inline warnings
660         - Automatically insert newline
661         - Select text on first click
662
663         These settings are not applicable for the spreadsheet styles editor and
664         now are always enabled for the legacy styles editor.
665
666         * Localizations/en.lproj/localizedStrings.js:
667         * UserInterface/Base/Setting.js:
668         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
669         (WI.CSSStyleDeclarationTextEditor):
670         (WI.CSSStyleDeclarationTextEditor.prototype._handleMouseUp):
671         (WI.CSSStyleDeclarationTextEditor.):
672         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
673         (WI.CSSStyleDetailsSidebarPanel):
674         * UserInterface/Views/SettingsTabContentView.js:
675         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
676         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
677
678 2017-11-01  Devin Rousso  <webkit@devinrousso.com>
679
680         Web Inspector: consolidate DOMTreeElement contextmenu items into submenus
681         https://bugs.webkit.org/show_bug.cgi?id=178996
682
683         Reviewed by Joseph Pecoraro.
684
685         * Localizations/en.lproj/localizedStrings.js:
686
687         * UserInterface/Views/ContextMenu.js:
688         (WI.ContextSubMenuItem.prototype.appendItem):
689         (WI.ContextSubMenuItem.prototype.appendSubMenuItem):
690         (WI.ContextSubMenuItem.prototype.appendCheckboxItem):
691         (WI.ContextSubMenuItem.prototype.pushItem):
692         (WI.ContextSubMenuItem.prototype._pushItem): Deleted.
693         Made `pushItem` public so that it is possible to create a ContextMenuItem without
694         immediately adding it to the ContextMenu.
695
696         (WI.ContextSubMenuItem.prototype._buildDescriptor):
697         (WI.ContextMenu.prototype._buildDescriptor):
698         Filter out submenus that have no items.
699
700         * UserInterface/Views/ContextMenuUtilities.js:
701         (WI.appendContextMenuItemsForDOMNode):
702         * UserInterface/Views/DOMTreeElement.js:
703         (WI.DOMTreeElement.prototype.toggleElementVisibility):
704         (WI.DOMTreeElement.prototype._populateTagContextMenu):
705         (WI.DOMTreeElement.prototype._populateTextContextMenu):
706         (WI.DOMTreeElement.prototype._populateNodeContextMenu):
707         (WI.DOMTreeElement.prototype._populateForcedPseudoStateItems): Deleted.
708         Add relevant items to the provided submenus and reorder the entire contextmenu for better
709         readability and consistency.
710
711         * UserInterface/Views/DOMTreeOutline.js:
712         (WI.DOMTreeOutline.prototype.populateContextMenu):
713         Create submenus for Add, Edit, Copy, and Delete, and pass them to the DOMTreeElement
714         "populate*ContextMenu" functions so that they can add items to each submenu.
715
716         (WI.DOMTreeOutline.prototype._hideElement):
717         Move to DOMTreeElement so that it can be used by a contextmenu item.
718
719 2017-11-01  Ross Kirsling  <ross.kirsling@sony.com>
720
721         Web Inspector: Improve UX of Layers tab visualization
722         https://bugs.webkit.org/show_bug.cgi?id=178966
723
724         Reviewed by Devin Rousso.
725
726         * UserInterface/Views/Layers3DContentView.js:
727         (WI.Layers3DContentView):
728         (WI.Layers3DContentView.prototype.initialLayout):
729         (WI.Layers3DContentView.prototype._canvasMouseDown):
730         (WI.Layers3DContentView.prototype._createLayerGroup): Renamed from _addLayerGroup.
731         (WI.Layers3DContentView.prototype._updateLayerGroupPosition): Merged into _updateLayers.
732         Set up zoom and pan.
733
734         (WI.Layers3DContentView.prototype._animate):
735         (WI.Layers3DContentView.prototype._restrictPan):
736         Restrict pan to bounding box on XY plane.
737
738         (WI.Layers3DContentView.prototype.layout):
739         (WI.Layers3DContentView.prototype._updateDocument):
740         (WI.Layers3DContentView.prototype._resetCamera):
741         On new document, throw out all old layers and center the camera on the new document layer.
742
743         (WI.Layers3DContentView.prototype.selectLayerById):
744         (WI.Layers3DContentView.prototype._centerOnSelection):
745         Recenter the camera when layer group selection is updated programmatically.
746
747         (WI.Layers3DContentView.prototype._updateLayers):
748         (WI.Layers3DContentView.prototype._createLayerMesh):
749         Fix visual artifact due to "depthWrite" flag.
750
751         * UserInterface/Views/LayerDetailsSidebarPanel.js:
752         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
753         Suppress selection update event when the data grid selection is updated programmatically.
754
755         * UserInterface/Views/DataGridNode.js:
756         (WI.DataGridNode.prototype.revealAndSelect):
757         Allow forwarding of select()'s parameter.
758
759 2017-11-01  Joseph Pecoraro  <pecoraro@apple.com>
760
761         Web Inspector: Combine all storage icon files into a single file
762         https://bugs.webkit.org/show_bug.cgi?id=179134
763
764         Reviewed by Devin Rousso.
765
766         * UserInterface/Main.html:
767         * UserInterface/Views/CookieIcon.css: Removed.
768         * UserInterface/Views/DOMStorageIcons.css: Removed.
769         * UserInterface/Views/DatabaseIcon.css: Removed.
770         * UserInterface/Views/DatabaseTableIcon.css: Removed.
771         * UserInterface/Views/StorageIcons.css: Added.
772         (.application-cache-manifest .icon):
773         (.application-cache-frame .icon):
774         (.cookie-icon .icon):
775         (.local-storage-icon .icon):
776         (.session-storage-icon .icon):
777         (.database-icon .icon):
778         (.database-table-icon .icon):
779
780 2017-11-01  Nikita Vasilyev  <nvasilyev@apple.com>
781
782         Web Inspector: Styles Redesign: Hovering over a selector should highlight matching elements on the page
783         https://bugs.webkit.org/show_bug.cgi?id=179040
784
785         Reviewed by Devin Rousso.
786
787         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
788         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
789         Use mouseenter/mouseleave events instead of mousein/mouseout (as in the old styles sidebar)
790         to avoid unnecessary events being fired.
791
792         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._highlightNodesWithSelector):
793         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._hideDOMNodeHighlight):
794
795 2017-10-30  Nikita Vasilyev  <nvasilyev@apple.com>
796
797         Web Inspector: [PARITY] Styles Redesign: Ability to modify style attributes
798         https://bugs.webkit.org/show_bug.cgi?id=178328
799         <rdar://problem/35000990>
800
801         Reviewed by Joseph Pecoraro.
802
803         Before this patch, modifying a property of a style attribute duplicated the old property
804         and appended the new one. This happened because WI.TextRange.prototype.resolveOffsets
805         didn't resolve offsets correctly when text didn't end with a trailing new line.
806
807         Since WI.TextRange.prototype.resolveOffsets is used elsewhere and this could be expected
808         behavior, append a line break before resolving a range.
809
810         * UserInterface/Models/CSSProperty.js:
811         (WI.CSSProperty.prototype._updateOwnerStyleText):
812
813 2017-10-30  Ross Kirsling  <ross.kirsling@sony.com>
814
815         Web Inspector: Clicking filler in data grid should clear selection
816         https://bugs.webkit.org/show_bug.cgi?id=179027
817
818         Reviewed by Brian Burg.
819
820         * UserInterface/Views/DataGrid.js:
821         (WI.DataGrid.prototype._mouseDownInDataTable):
822
823 2017-10-30  Devin Rousso  <webkit@devinrousso.com>
824
825         Web Inspector: Canvas Tab: no path components shown in recording content view after selecting a recording via View Recordings... dropdown
826         https://bugs.webkit.org/show_bug.cgi?id=178807
827         <rdar://problem/35176463>
828
829         Reviewed by Brian Burg.
830
831         When the first Recording is taken of a canvas, it is immediately added as a child. When the
832         CanvasTreeElement is `attached`, however, it will attempt to regenerate its children if
833         necessary. This is especially true for canvases with ShaderPrograms, as they are added with
834         `addRepresentedObjectToNewChildQueue`, meaning that the child TreeElements aren't actually
835         added until the next tick, preventing the ContentBrowser logic from generating path
836         components correctly.
837
838         This patch switches to using `addChildForRepresentedObject` so that there is no delay when
839         adding children, and also ensures that any existing recordings are also added on regeneration.
840
841         * UserInterface/Views/CanvasTabContentView.js:
842         (WI.CanvasTabContentView.prototype._recordingAdded):
843         Move logic for adding TreeElements for new Recordings to CanvasTreeElement.
844
845         * UserInterface/Views/CanvasTreeElement.js:
846         (WI.CanvasTreeElement.createRecordingTreeElement):
847         (WI.CanvasTreeElement):
848         (WI.CanvasTreeElement.prototype.onattach):
849         (WI.CanvasTreeElement.prototype.ondetach):
850         (WI.CanvasTreeElement.prototype.onpopulate):
851         (WI.CanvasTreeElement.prototype._handleItemAdded):
852         (WI.CanvasTreeElement.prototype._handleItemRemoved):
853         (WI.CanvasTreeElement.prototype._shaderProgramAdded): Deleted.
854         (WI.CanvasTreeElement.prototype._shaderProgramRemoved): Deleted.
855
856 2017-10-30  Fujii Hironori  <Hironori.Fujii@sony.com>
857
858         [GTK] Web Inspector: Add Path.svg
859         https://bugs.webkit.org/show_bug.cgi?id=178432
860
861         Reviewed by Carlos Garcia Campos.
862
863         * UserInterface/Images/gtk/Path.svg: Added.
864
865 2017-10-30  Nikita Vasilyev  <nvasilyev@apple.com>
866
867         Web Inspector: [PARITY] Styles Redesign: clicking on the white space after the property should create a blank property
868         https://bugs.webkit.org/show_bug.cgi?id=178022
869         <rdar://problem/34861687>
870
871         Reviewed by Matt Baker.
872
873         - Clicking on the whitespace on the right side of a property should insert a blank property after the clicked one.
874         - Clicking on the whitespace at the end of a CSS rule should append a blank property.
875         - Clicking on the whitespace before the first property should insert a blank property before the first one.
876
877         * UserInterface/Models/CSSProperty.js:
878         (WI.CSSProperty.prototype.remove):
879         (WI.CSSProperty.prototype._updateOwnerStyleText):
880         Remove method previously didn't do anything for a newly added property.
881
882         * UserInterface/Models/CSSStyleDeclaration.js:
883         (WI.CSSStyleDeclaration.prototype.newBlankProperty):
884         Update indices of all properties after the newly added property.
885
886         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
887         (WI.SpreadsheetCSSStyleDeclarationEditor):
888         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
889         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.startEditingFirstProperty):
890         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.startEditingLastProperty):
891         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.isFocused):
892         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.addBlankProperty):
893         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetCSSStyleDeclarationEditorFocusMoved):
894         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesChanged):
895         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._addBlankProperty): Deleted.
896         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._isFocused): Deleted.
897         Re-layout SpreadsheetCSSStyleDeclarationEditor after adding a new property. Preserve edited property
898         so we can restore editing state after the re-layout.
899
900         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
901         (WI.SpreadsheetCSSStyleDeclarationSection):
902         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
903         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleMouseDown):
904         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleClick):
905         Clicking should add a new property only when we aren't editing an existing property.
906
907         * UserInterface/Views/SpreadsheetStyleProperty.js:
908         (WI.SpreadsheetStyleProperty):
909         (WI.SpreadsheetStyleProperty.prototype.updateClassNames):
910         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidCommit):
911         Remove newlyAdded property of SpreadsheetStyleProperty. During layout SpreadsheetCSSStyleDeclarationEditor
912         recreates SpreadsheetStyleProperty views and newlyAdded property gets lost.
913
914         * UserInterface/Views/SpreadsheetTextField.js:
915         (WI.SpreadsheetTextField.prototype.get valueBeforeEditing):
916         (WI.SpreadsheetTextField.prototype.startEditing):
917         (WI.SpreadsheetTextField.prototype.stopEditing):
918         (WI.SpreadsheetTextField.prototype._discardChange):
919
920 2017-10-27  Devin Rousso  <webkit@devinrousso.com>
921
922         Web Inspector: Canvas Tab: no way to see backtrace of where a canvas context was created
923         https://bugs.webkit.org/show_bug.cgi?id=178799
924         <rdar://problem/35175805>
925
926         Reviewed by Brian Burg.
927
928         * Localizations/en.lproj/localizedStrings.js:
929
930         * UserInterface/Models/Canvas.js:
931         (WI.Canvas.fromPayload):
932         (WI.Canvas.prototype.get backtrace):
933
934         * UserInterface/Views/CanvasDetailsSidebarPanel.css:
935         (.sidebar > .panel.details.canvas .details-section.canvas-backtrace .call-frame):
936
937         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
938         (WI.CanvasDetailsSidebarPanel.prototype.initialLayout):
939         (WI.CanvasDetailsSidebarPanel.prototype.layout):
940         (WI.CanvasDetailsSidebarPanel.prototype._refreshBacktraceSection):
941
942         * UserInterface/Views/ResourceIcons.css:
943         (.canvas > .icon):
944         (.canvas .icon): Deleted.
945
946 2017-10-26  Devin Rousso  <webkit@devinrousso.com>
947
948         Web Inspector: Canvas Tab: canvas path components from old page stick around when page is reloaded
949         https://bugs.webkit.org/show_bug.cgi?id=178806
950         <rdar://problem/35176360>
951
952         Reviewed by Brian Burg.
953
954         Before this change, the CanvasCollection was regenerated each time the Canvas tab was
955         attached. This also caused the invisible TreeOutline, used for the path components and to
956         manage selection, to be reset as well. Whenever the page refreshed, however, the old
957         canvases, and associated recordings, were not removed. This patch reworks all of this logic
958         to create the CanvasCollection on construction of the tab and add/remove canvases as needed.
959
960         * UserInterface/Controllers/CanvasManager.js:
961         (WI.CanvasManager.prototype.canvasAdded):
962         (WI.CanvasManager.prototype.canvasRemoved):
963         (WI.CanvasManager.prototype._removeCanvas):
964         (WI.CanvasManager.prototype._mainResourceDidChange):
965         Replaced the "Cleared" event by instead firing "CanvasRemoved" for every tracked canvas. This
966         massively simplifies the logic for when the page navigates, as everything goes through a
967         single event listener.
968         Drive-by: changed existing event names to remove unnecessary words.
969
970         * UserInterface/Views/CanvasTabContentView.js:
971         (WI.CanvasTabContentView):
972         (WI.CanvasTabContentView.prototype.attached):
973         (WI.CanvasTabContentView.prototype.detached):
974         (WI.CanvasTabContentView.prototype._addCanvas):
975         (WI.CanvasTabContentView.prototype._removeCanvas):
976         (WI.CanvasTabContentView.prototype._handleCanvasAdded):
977         (WI.CanvasTabContentView.prototype._handleCanvasRemoved):
978         (WI.CanvasTabContentView.prototype._canvasAdded): Deleted.
979         (WI.CanvasTabContentView.prototype._canvasRemoved): Deleted.
980         (WI.CanvasTabContentView.prototype._mainResourceDidChange): Deleted.
981         Rework logic for the way that the CanvasCollection is maintained. It is no longer
982         created/destroyed each time the view is attached/detached, and instead a diff is calculated
983         for the added/existing/removed canvases and the content views are added/removed as such.
984
985         * UserInterface/Views/CanvasOverviewContentView.js:
986         (WI.CanvasOverviewContentView.prototype._selectionPathComponentsChanged):
987         Drive-by: if an imported recording is selected on the Canvas Overview view, we should show it.
988
989 2017-10-26  Devin Rousso  <webkit@devinrousso.com>
990
991         Web Inspector: Canvas Tab: canvases overview should support navigation via keyboard
992         https://bugs.webkit.org/show_bug.cgi?id=178800
993         <rdar://problem/35175856>
994
995         Reviewed by Brian Burg.
996
997         Create a KeyboardShorcut for each of the following:
998          - Up: selects the previous canvas in the selected column
999          - Down: selects the next canvas in the selected column
1000          - Right: selects the next canvas in the selected row
1001          - Left: selects the previous canvas in the selected row
1002          - Space: toggle recording of the selected canvas
1003          - Shift+Space: toggle single-frame recording of the selected canvas
1004
1005         The calculation for selected row/colum is based on the `offsetWidth` of the parent element
1006         and the selected item's content view element. Since this view uses a flexbox, all of the
1007         items are expected to have the same dimensions, meaning that this value is uniform. The
1008         intended functionality is that of a spreadsheet, where pressing pressing left/right will
1009         never change the selected row and up/down will never change the selected column.
1010
1011         * UserInterface/Views/CanvasOverviewContentView.css:
1012         (.content-view.canvas-overview):
1013         (.content-view.canvas-overview .content-view.canvas):
1014         Move margin value to a CSS variable so that it can be easily retrieved via JavaScript.
1015
1016         * UserInterface/Views/CanvasOverviewContentView.js:
1017         (WI.CanvasOverviewContentView):
1018         (WI.CanvasOverviewContentView.prototype.contentViewAdded):
1019         (WI.CanvasOverviewContentView.prototype.contentViewRemoved):
1020         (WI.CanvasOverviewContentView.prototype.attached):
1021         (WI.CanvasOverviewContentView.prototype.detached):
1022         (WI.CanvasOverviewContentView.prototype.get _itemMargin):
1023         (WI.CanvasOverviewContentView.prototype._changeSelectedItemVertically):
1024         (WI.CanvasOverviewContentView.prototype._changeSelectedItemHorizontally):
1025         (WI.CanvasOverviewContentView.prototype._updateNavigationItems):
1026         (WI.CanvasOverviewContentView.prototype._handleUp):
1027         (WI.CanvasOverviewContentView.prototype._handleRight):
1028         (WI.CanvasOverviewContentView.prototype._handleDown):
1029         (WI.CanvasOverviewContentView.prototype._handleLeft):
1030         (WI.CanvasOverviewContentView.prototype._handleSpace):
1031         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange):
1032         Drive-by: call `_updateNavigationItems` whenever an item is added/removed so that if there
1033         are no items the navigation items cannot be clicked.
1034
1035 2017-10-26  Nikita Vasilyev  <nvasilyev@apple.com>
1036
1037         Web Inspector: Styles Redesign: Make "Style Attribute" text darker and non-focusable
1038         https://bugs.webkit.org/show_bug.cgi?id=178837
1039
1040         Reviewed by Brian Burg.
1041
1042         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
1043         (.spreadsheet-css-declaration .selector.style-attribute):
1044         Use the same shade of gray as in the "Inherited from" sections.
1045
1046         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
1047         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
1048         Only editable selectors should be focusable.
1049
1050 2017-10-26  Fujii Hironori  <Hironori.Fujii@sony.com>
1051
1052         [GTK] Web Inspector: Add CanvasOverview.svg and Canvas.svg
1053         https://bugs.webkit.org/show_bug.cgi?id=178426
1054
1055         Reviewed by Carlos Garcia Campos.
1056
1057         * UserInterface/Images/gtk/Canvas.svg: Added.
1058         * UserInterface/Images/gtk/CanvasOverview.svg: Added.
1059
1060 2017-10-25  Devin Rousso  <webkit@devinrousso.com>
1061
1062         Web Inspector: provide a way to enable/disable event listeners
1063         https://bugs.webkit.org/show_bug.cgi?id=177451
1064         <rdar://problem/34994925>
1065
1066         Reviewed by Joseph Pecoraro.
1067
1068         * Localizations/en.lproj/localizedStrings.js:
1069
1070         * UserInterface/Controllers/DOMTreeManager.js:
1071         (WI.DOMTreeManager.prototype.setEventListenerDisabled):
1072
1073         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
1074         (WI.DOMNodeDetailsSidebarPanel.prototype.attached):
1075         (WI.DOMNodeDetailsSidebarPanel.prototype.detached):
1076         (WI.DOMNodeDetailsSidebarPanel.prototype._eventListenersChanged):
1077         (WI.DOMNodeDetailsSidebarPanel.prototype.addEventListeners): Deleted.
1078         (WI.DOMNodeDetailsSidebarPanel.prototype.removeEventListeners): Deleted.
1079         Listen for `WI.DOMNode.Event.EventListenersChanged` on all instances of WI.DOMNode, since we
1080         will still want to refresh the event listeners section in the event that an event listener
1081         is removed from a parent node.
1082
1083         * UserInterface/Views/EventListenerSectionGroup.js:
1084         (WI.EventListenerSectionGroup):
1085         (WI.EventListenerSectionGroup.prototype._eventText):
1086         (WI.EventListenerSectionGroup.prototype._nodeTextOrLink):
1087         (WI.EventListenerSectionGroup.prototype._createDisabledToggleElement):
1088         (WI.EventListenerSectionGroup.prototype._createDisabledToggleElement.updateTitle):
1089         * UserInterface/Views/EventListenerSectionGroup.css:
1090         (.event-listener-section > .content input[type="checkbox"]):
1091
1092         * UserInterface/Views/DetailsSectionSimpleRow.js:
1093         (WI.DetailsSectionSimpleRow.prototype.get label):
1094         (WI.DetailsSectionSimpleRow.prototype.set label):
1095
1096 2017-10-25  Devin Rousso  <webkit@devinrousso.com>
1097
1098         Web Inspector: replace TypeVerifier with subclasses of WI.Collection
1099         https://bugs.webkit.org/show_bug.cgi?id=178045
1100         <rdar://problem/35174307>
1101
1102         Reviewed by Brian Burg.
1103
1104         * UserInterface/Models/Collection.js:
1105         (WI.Collection):
1106         (WI.Collection.prototype.get displayName):
1107         (WI.Collection.prototype.objectIsRequiredType):
1108         (WI.Collection.prototype.add):
1109         (WI.Collection.prototype.get typeVerifier): Deleted.
1110         Instead of exposing the typeVerifier, we create a public predicate that returns whether the
1111         given object matches the expected type of the Collection. Subclasses can override it to
1112         limit the scope of the collection to a particular type.
1113
1114         * UserInterface/Models/CollectionTypes.js:
1115         (WI.FrameCollection.prototype.get displayName):
1116         (WI.FrameCollection.prototype.objectIsRequiredType):
1117         (WI.FrameCollection): Deleted.
1118         (WI.ScriptCollection.prototype.get displayName):
1119         (WI.ScriptCollection.prototype.objectIsRequiredType):
1120         (WI.ScriptCollection): Deleted.
1121         (WI.CSSStyleSheetCollection.prototype.get displayName):
1122         (WI.CSSStyleSheetCollection.prototype.objectIsRequiredType):
1123         (WI.CSSStyleSheetCollection): Deleted.
1124         (WI.CanvasCollection.prototype.get displayName):
1125         (WI.CanvasCollection.prototype.objectIsRequiredType):
1126         (WI.CanvasCollection): Deleted.
1127         (WI.ShaderProgramCollection.prototype.get displayName):
1128         (WI.ShaderProgramCollection.prototype.objectIsRequiredType):
1129         (WI.ShaderProgramCollection): Deleted.
1130         (WI.RecordingCollection.prototype.get displayName):
1131         (WI.RecordingCollection.prototype.objectIsRequiredType):
1132         (WI.RecordingCollection): Deleted.
1133         * UserInterface/Models/ResourceCollection.js:
1134         (WI.ResourceCollection):
1135         (WI.ResourceCollection.prototype.get displayName):
1136         (WI.ResourceCollection.prototype.objectIsRequiredType):
1137         (WI.ResourceCollection.verifierForType): Deleted.
1138         * UserInterface/Views/TreeOutlineGroup.js:
1139         (WI.TreeOutlineGroup.prototype.objectIsRequiredType):
1140         (WI.TreeOutlineGroup): Deleted.
1141         Introduce additional subclasses of Collection for other model types. Modify existing
1142         subclasses to remove `typeVerifier` and instead extend `objectIsRequiredType`.
1143
1144         * UserInterface/Models/Canvas.js:
1145         (WI.Canvas):
1146         * UserInterface/Models/Frame.js:
1147         (WI.Frame):
1148         * UserInterface/Protocol/Target.js:
1149         (WI.Target):
1150         * UserInterface/Views/ResourceSidebarPanel.js:
1151         (WI.ResourceSidebarPanel.prototype.treeElementForRepresentedObject):
1152         (WI.ResourceSidebarPanel.prototype._addScript):
1153
1154         * UserInterface/Views/CollectionContentView.js:
1155         (WI.CollectionContentView):
1156         (WI.CollectionContentView.titleForCollection): Delete.
1157         * UserInterface/Views/ResourceCollectionContentView.js:
1158         (WI.ResourceCollectionContentView):
1159         Require that subclasses of Collection override `get displayName` if the CollectionContentView
1160         is not provided with a `contentPlaceholderText`.
1161
1162         (WI.CollectionContentView.prototype.initialLayout):
1163         We don't need to create and add ContentView for each item of the Collection, as this is
1164         already done by attached().
1165
1166         (WI.CollectionContentView.prototype._showContentPlaceholder):
1167         Remove the 250ms delay before showing the placeholder TitleView.
1168
1169         * UserInterface/Views/FolderizedTreeElement.js:
1170         (WI.FolderizedTreeElement.prototype._settingsForRepresentedObject):
1171
1172 2017-10-25  Joseph Pecoraro  <pecoraro@apple.com>
1173
1174         Web Inspector: Display fetch() initiated loads as "fetch" instead of "xhr" in the Network Tab
1175         https://bugs.webkit.org/show_bug.cgi?id=178826
1176
1177         Reviewed by Youenn Fablet.
1178
1179         * UserInterface/Views/NetworkTableContentView.js:
1180         (WI.NetworkTableContentView.shortDisplayNameForResourceType):
1181         Fetch and XHR loads are still grouped under the succinct "XHR" filter, but
1182         at least display the better type name in the "Type" column of the table.
1183
1184 2017-10-25  Devin Rousso  <webkit@devinrousso.com>
1185
1186         Web Inspector: Canvas Tab: selected canvas card loses selection outline style while recording
1187         https://bugs.webkit.org/show_bug.cgi?id=178814
1188         <rdar://problem/35177317>
1189
1190         Reviewed by Brian Burg.
1191
1192         * UserInterface/Views/CanvasOverviewContentView.css:
1193         (.content-view.canvas-overview .content-view.canvas):
1194         (.content-view.canvas-overview .content-view.canvas > :matches(header, .preview, footer)):
1195         (.content-view.canvas-overview .content-view.canvas.selected > :matches(.preview, footer),):
1196         (.content-view.canvas-overview .content-view.canvas > header):
1197         (.content-view.canvas-overview .content-view.canvas.is-recording > header):
1198         (.content-view.canvas-overview .content-view.canvas > .preview):
1199         (.content-view.canvas-overview .content-view.canvas > footer):
1200         (.content-view.canvas-overview .content-view.canvas.selected:not(.is-recording)): Deleted.
1201         Instead of applying the border to the entire element, apply parts of the border to each of
1202         its children so that we can choose what colors to use for each part.
1203
1204 2017-10-25  Nikita Vasilyev  <nvasilyev@apple.com>
1205
1206         Web Inspector: [PARITY] Styles Redesign: Add color gradient, bezier curve, and spring inline widgets
1207         https://bugs.webkit.org/show_bug.cgi?id=178404
1208         <rdar://problem/35035992>
1209
1210         Reviewed by Devin Rousso.
1211
1212         Add inline widgets for the following CSS values:
1213         - Gradients, e.g. `background-image: linear-gradient(yellow, orange)`
1214         - Bezier curves, e.g. `transition-timing-function: cubic-bezier(0.68, -0.55, 0.265, 1.55)`
1215         - Spring functions, e.g. `transition-timing-function: spring(1, 2, 2, 4)`
1216
1217         * UserInterface/Models/Color.js:
1218         (WI.Color.prototype.toString):
1219         Don't throw. The are never try/catch blocks on the callsites.
1220
1221         * UserInterface/Views/SpreadsheetStyleProperty.js:
1222         (WI.SpreadsheetStyleProperty.prototype._renderValue):
1223         (WI.SpreadsheetStyleProperty.prototype._createInlineSwatch):
1224         (WI.SpreadsheetStyleProperty.prototype._addGradientTokens):
1225         (WI.SpreadsheetStyleProperty.prototype._addColorTokens):
1226         (WI.SpreadsheetStyleProperty.prototype._addTimingFunctionTokens):
1227
1228 2017-10-25  Nikita Vasilyev  <nvasilyev@apple.com>
1229
1230         Web Inspector: Styles Redesign: Newly added invalid property isn't immediately shown as invalid
1231         https://bugs.webkit.org/show_bug.cgi?id=178488
1232
1233         Reviewed by Brian Burg.
1234
1235         * UserInterface/Models/CSSStyleDeclaration.js:
1236         (WI.CSSStyleDeclaration.prototype.newBlankProperty):
1237         Call this.update to update _properties, _allProperties, _visibleProperties, and _allVisibleProperties.
1238
1239         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1240         (.spreadsheet-style-declaration-editor .property:matches(.invalid-name, .other-vendor, .overridden):not(.disabled)):
1241         (.spreadsheet-style-declaration-editor .property.invalid-name:not(.disabled)):
1242         (.spreadsheet-style-declaration-editor .property.invalid-value:not(.disabled) .value):
1243         When the property name is valid, but the value isn't, display red line-through only for the value.
1244         This is how it works in the old styles sidebar as well.
1245
1246         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1247         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesChanged):
1248         (WI.SpreadsheetCSSStyleDeclarationEditor):
1249         * UserInterface/Views/SpreadsheetStyleProperty.js:
1250         (WI.SpreadsheetStyleProperty):
1251         (WI.SpreadsheetStyleProperty.prototype.updateClassNames):
1252         (WI.SpreadsheetStyleProperty.prototype._update):
1253         Introduce updateClassNames method. Unlike _update, it doesn't change text selection or focus and
1254         can be safely called on a property while it's being edited.
1255
1256 2017-10-25  Devin Rousso  <webkit@devinrousso.com>
1257
1258         Web Inspector: Canvas Tab: clicking on a canvas card causes details sidebar to show and mess up card arrangement
1259         https://bugs.webkit.org/show_bug.cgi?id=178803
1260         <rdar://problem/35176082>
1261
1262         Reviewed by Brian Burg.
1263
1264         * Localizations/en.lproj/localizedStrings.js:
1265         * UserInterface/Views/CanvasDetailsSidebarPanel.css:
1266         (.sidebar > .panel.details.canvas > .content > .empty-content-placeholder):
1267         (.sidebar > .panel.details.canvas > .content > .empty-content-placeholder > .message):
1268         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
1269         (WI.CanvasDetailsSidebarPanel):
1270         (WI.CanvasDetailsSidebarPanel.prototype.inspect):
1271         (WI.CanvasDetailsSidebarPanel.prototype.initialLayout):
1272         (WI.CanvasDetailsSidebarPanel.prototype.layout):
1273
1274         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
1275         (WI.RecordingNavigationSidebarPanel.disallowInstanceForClass): Deleted.
1276         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1277         (WI.RecordingStateDetailsSidebarPanel.disallowInstanceForClass): Deleted.
1278         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js:
1279         (WI.RecordingTraceDetailsSidebarPanel.disallowInstanceForClass): Deleted.
1280         Drive-by: these sidebar panels are now only used by the Canvas tab, so we no longer need to
1281         provide support for multiple instances of them.
1282
1283 2017-10-25  Devin Rousso  <webkit@devinrousso.com>
1284
1285         Web Inspector: preserve Recordings for each Canvas after closing the Canvas tab
1286         https://bugs.webkit.org/show_bug.cgi?id=178767
1287         <rdar://problem/35167239>
1288
1289         Reviewed by Brian Burg.
1290
1291         * UserInterface/Test.html:
1292         Include CollectionTypes for tests.
1293
1294         * UserInterface/Controllers/CanvasManager.js:
1295         (WI.CanvasManager.prototype.recordingFinished):
1296
1297         * UserInterface/Models/Canvas.js:
1298         (WI.Canvas):
1299         (WI.Canvas.prototype.get recordingCollection):
1300
1301         * UserInterface/Models/CollectionTypes.js:
1302         (WI.CanvasCollection):
1303         (WI.RecordingCollection):
1304
1305         * UserInterface/Views/CanvasContentView.js:
1306         (WI.CanvasContentView.prototype.initialLayout):
1307         (WI.CanvasContentView.prototype._addRecording):
1308         (WI.CanvasContentView.prototype._recordingStopped):
1309
1310         * UserInterface/Views/CanvasTabContentView.js:
1311         (WI.CanvasTabContentView.prototype.attached):
1312         (WI.CanvasTabContentView.prototype._recordingAdded):
1313
1314 2017-10-24  Joseph Pecoraro  <pecoraro@apple.com>
1315
1316         REGRESSION(r222181): Web Inspector: Augmenting Agents Domains are not getting activated
1317         https://bugs.webkit.org/show_bug.cgi?id=178768
1318         <rdar://problem/35081334>
1319
1320         Reviewed by Brian Burg.
1321
1322         * UserInterface/Base/Main.js:
1323         Simplify event dispatch.
1324
1325         * UserInterface/Controllers/AppController.js:
1326         (WI.AppController.prototype.activateExtraDomains):
1327         Pass the domains on.
1328
1329 2017-10-24  Joseph Pecoraro  <pecoraro@apple.com>
1330
1331         Web Inspector: Console Drawer resizing doesn't match cursor position
1332         https://bugs.webkit.org/show_bug.cgi?id=178753
1333         <rdar://problem/35160484>
1334
1335         Reviewed by Brian Burg.
1336
1337         * UserInterface/Views/ConsoleDrawer.js:
1338         (WI.ConsoleDrawer.prototype._updateDrawerHeight):
1339         Drive-by fix an early return that would never have worked.
1340
1341         * UserInterface/Views/Main.css:
1342         (#content):
1343         Give the #content a flex grow of 1. This causes the space to grow as it
1344         already was but now it does not affect the size of the fixed height sibling.
1345
1346 2017-10-24  Eric Carlson  <eric.carlson@apple.com>
1347
1348         Web Inspector: Enable WebKit logging configuration and display
1349         https://bugs.webkit.org/show_bug.cgi?id=177027
1350         <rdar://problem/33964767>
1351
1352         Reviewed by Joseph Pecoraro.
1353
1354         * Localizations/en.lproj/localizedStrings.js: Add new localized strings.
1355
1356         * UserInterface/Controllers/LogManager.js:
1357         (WI.LogManager): Initialize _loggingChannelSources, fetch _customLoggingChannels.
1358         (WI.LogManager.supportsLogChannels): New.
1359         (WI.LogManager.prototype.get customLoggingChannels): New.
1360         (WI.LogManager.prototype.get logChannelSources): New.
1361
1362         * UserInterface/Main.html:
1363         * UserInterface/Models/ConsoleMessage.js: Add Media and WebRTC.
1364
1365         * UserInterface/Models/IssueMessage.js:
1366         (WI.IssueMessage): Add media and webrtc.
1367
1368         * UserInterface/Models/LoggingChannel.js: Added.
1369         (WI.LoggingChannel):
1370         (WI.LoggingChannel.fromPayload):
1371         (WI.LoggingChannel.prototype.get source):
1372         (WI.LoggingChannel.prototype.get level):
1373
1374         * UserInterface/Views/LogContentView.js:
1375         (WI.LogContentView): Add new scope buttons for "Log", "Info", and "Debug". Create log channel
1376             scope buttons once logging has started.
1377         (WI.LogContentView.prototype.get navigationItems): Add the log message scope bar when necessary.
1378         (WI.LogContentView.prototype._scopeFromMessageSource): New.
1379         (WI.LogContentView.prototype._scopeFromMessageLevel): Don't group Info, Log, and Debug.
1380         (WI.LogContentView.prototype._messageAdded): Force a UI update the first time a WebKit log
1381             message is added.
1382
1383         (WI.LogContentView.prototype._messageShouldBeVisible): New, deal with message source bar buttons.
1384         (WI.LogContentView.prototype._messageSourceBarSelectionDidChange): New.
1385         (WI.LogContentView.prototype._filterMessageElements): Deal with message source bar buttons.
1386
1387         * UserInterface/Views/SettingsTabContentView.js:
1388         (WI.SettingsTabContentView.prototype._createGeneralSettingsView): Create and initialize menus
1389             for each log channel.
1390
1391 2017-10-24  Joseph Pecoraro  <pecoraro@apple.com>
1392
1393         Uncaught Exception: TypeError: null is not an object (evaluating 'this.treeOutline.isXMLMimeType')
1394         https://bugs.webkit.org/show_bug.cgi?id=178745
1395
1396         Reviewed by Brian Burg.
1397
1398         * UserInterface/Views/DOMTreeUpdater.js:
1399         (WI.DOMTreeUpdater.prototype._updateModifiedNodes):
1400         An earlier tree element update might have caused this other tree element's
1401         waiting to be updated to actually be removed. So just skip past them.
1402
1403 2017-10-24  Fujii Hironori  <Hironori.Fujii@sony.com>
1404
1405         [GTK] Web Inspector: Add Recording.svg
1406         https://bugs.webkit.org/show_bug.cgi?id=175045
1407
1408         Reviewed by Brian Burg.
1409
1410         * UserInterface/Images/gtk/Recording.svg: Added.
1411
1412 2017-10-24  Devin Rousso  <webkit@devinrousso.com>
1413
1414         Web Inspector: allow ShaderProgram to be shown in CanvasContentView
1415         https://bugs.webkit.org/show_bug.cgi?id=178714
1416
1417         Reviewed by Brian Burg.
1418
1419         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
1420         (WI.CanvasDetailsSidebarPanel.prototype.inspect):
1421         Allow ShaderProgram to show the related Canvas information.
1422
1423         * UserInterface/Views/CanvasTabContentView.js:
1424         (WI.CanvasTabContentView.prototype.canShowRepresentedObject):
1425         (WI.CanvasTabContentView.prototype.showRepresentedObject):
1426         (WI.CanvasTabContentView.prototype._canvasTreeOutlineSelectionDidChange):
1427         If a ShaderProgram is selected in the path component, display a ShaderProgramContentView.
1428
1429 2017-10-24  Devin Rousso  <webkit@devinrousso.com>
1430
1431         Web Inspector: remove canvases from Resources and experimental setting/UI
1432         https://bugs.webkit.org/show_bug.cgi?id=178711
1433
1434         Reviewed by Brian Burg.
1435
1436         * UserInterface/Base/Main.js:
1437         (WI.tabContentViewClassForRepresentedObject):
1438         * UserInterface/Base/Setting.js:
1439         * UserInterface/Controllers/CanvasManager.js:
1440         (WI.CanvasManager.prototype.canvasAdded):
1441         (WI.CanvasManager.prototype.canvasRemoved):
1442         * UserInterface/Models/Canvas.js:
1443         * UserInterface/Models/Frame.js:
1444         (WI.Frame):
1445         (WI.Frame.prototype.get extraScriptCollection):
1446         (WI.Frame.prototype.commitProvisionalLoad):
1447         (WI.Frame.prototype.get canvasCollection): Deleted.
1448         * UserInterface/Views/CanvasTabContentView.js:
1449         (WI.CanvasTabContentView.isTabAllowed):
1450         * UserInterface/Views/FrameTreeElement.js:
1451         (WI.FrameTreeElement):
1452         (WI.FrameTreeElement.prototype.onattach):
1453         (WI.FrameTreeElement.prototype.ondetach):
1454         (WI.FrameTreeElement.prototype.onpopulate):
1455         (WI.FrameTreeElement.prototype._styleSheetAdded):
1456         (WI.FrameTreeElement.prototype._canvasWasAdded): Deleted.
1457         (WI.FrameTreeElement.prototype._canvasWasRemoved): Deleted.
1458         * UserInterface/Views/ResourceSidebarPanel.js:
1459         (WI.ResourceSidebarPanel):
1460         (WI.ResourceSidebarPanel.prototype.matchTreeElementAgainstCustomFilters.match):
1461         (WI.ResourceSidebarPanel.prototype.matchTreeElementAgainstCustomFilters):
1462         (WI.ResourceSidebarPanel.prototype._treeSelectionDidChange):
1463         * UserInterface/Views/ResourcesTabContentView.js:
1464         (WI.ResourcesTabContentView):
1465         (WI.ResourcesTabContentView.prototype.canShowRepresentedObject):
1466         * UserInterface/Views/SettingsTabContentView.js:
1467         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1468
1469 2017-10-24  Devin Rousso  <webkit@devinrousso.com>
1470
1471         Web Inspector: Show recordings in CanvasTabContentView
1472         https://bugs.webkit.org/show_bug.cgi?id=177606
1473         <rdar://problem/34715819>
1474
1475         Reviewed by Brian Burg.
1476
1477         Original patch by Matt Baker <mattbaker@apple.com>.
1478
1479         This patch folds canvas recordings into the new Canvas tab, which now
1480         supports showing both CanvasCollections and Recordings.
1481
1482         When viewing recordings, a back button is shown at the start of the
1483         navigation bar, allowing the user to return to the overview. It has been
1484         styled with a back arrow, to make its function as clear as possible.
1485         Like other navigation path components, the item for the recording can
1486         clicked to select another recording taken from the same canvas.
1487
1488         The recording action scrubber has been moved from the content browser's
1489         navigation bar to a more prominent location in the recording content view.
1490         Selecting a frame tree element in the navigation sidebar no longer selects
1491         the last action for that frame. This was changed to prevent the scrubber
1492         position from behaving non-monotonically when selecting actions in sequential
1493         order.
1494
1495         While this patch retains support for importing recordings, the feature
1496         is not polished. Currently it is not possible to return to an imported
1497         recording after leaving closing the view. In the future we may want to
1498         consider including a navigation sidebar panel for the overview, which
1499         could list canvas recordings (and eventually shaders).
1500
1501         * .eslintrc:
1502         Drive-by: remove duplicate key.
1503
1504         * Localizations/en.lproj/localizedStrings.js:
1505         * UserInterface/Base/Main.js:
1506         (WI.contentLoaded):
1507         (WI.tabContentViewClassForRepresentedObject):
1508         * UserInterface/Main.html:
1509         * UserInterface/Views/RecordingTabContentView.js: Removed.
1510         Remove RecordingTabContentView.
1511
1512         * UserInterface/Images/Recording.svg:
1513         New recording icon, used for tree elements and canvas preview UI.
1514
1515         * UserInterface/Models/Recording.js:
1516         (WI.Recording):
1517         (WI.Recording.prototype.get visualActionIndexes):
1518         Visual action indexes should be computed by the recording.
1519
1520         * UserInterface/Views/CanvasContentView.js:
1521         (WI.CanvasContentView):
1522         (WI.CanvasContentView.prototype.refresh):
1523         (WI.CanvasContentView.prototype.initialLayout):
1524         (WI.CanvasContentView.prototype.attached):
1525         (WI.CanvasContentView.prototype._recordingStopped):
1526         (WI.CanvasContentView.prototype._handleRecordingSelectElementChange):
1527         New UI for showing CanvasContentView as a CollectionView item. Includes
1528         recordings button and select for choosing a recording to view.
1529
1530         * UserInterface/Views/CanvasOverviewContentView.css:
1531         (.content-view.canvas-overview .content-view.canvas > header):
1532         Switch to 13px, which is more frequently used.
1533
1534         (.content-view.canvas-overview .content-view.canvas > header .subtitle::before):
1535         Switch to literal em dash. Surrounding spaces were ignored when using
1536         the backslash-escaped character.
1537
1538         (.content-view.canvas-overview .content-view.canvas:not(:hover, .is-recording, .selected) > header > .navigation-bar):
1539         (.content-view.canvas-overview .content-view.canvas > footer > .recordings):
1540         (.content-view.canvas-overview .content-view.canvas > footer > .recordings::before):
1541         (.content-view.canvas-overview .content-view.canvas > footer > .recordings > select):
1542         (.content-view.canvas-overview .content-view.canvas > footer .recordings > select:focus):
1543         (.content-view.canvas-overview .content-view.canvas > footer > .flexible-space):
1544         (.popover-content > .tree-outline .item.recording > .icon):
1545         (.popover-content > .tree-outline .item.recording:hover):
1546         (.popover-content > .tree-outline .item.recording:hover > .icon):
1547         (.content-view.canvas-overview .content-view.canvas:not(:hover, .is-recording) > header > .navigation-bar): Deleted.
1548         (.content-view.canvas-overview .content-view.canvas > footer): Deleted.
1549         New styles for the recording picker.
1550
1551         * UserInterface/Views/CanvasOverviewContentView.js:
1552         (WI.CanvasOverviewContentView):
1553         (WI.CanvasOverviewContentView.prototype.get selectionPathComponents):
1554         (WI.CanvasOverviewContentView.prototype.contentViewAdded):
1555         (WI.CanvasOverviewContentView.prototype.contentViewRemoved):
1556         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange):
1557         (WI.CanvasOverviewContentView.prototype._selectedPathComponentChanged): Deleted.
1558         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange.createCanvasPathComponent): Deleted.
1559         Canvas tree elements are now managed by CanvasTabContentView, which is
1560         now responsible for maintaining the tree of canvas objects. For now the
1561         tree holds canvases and recordings, but will eventually include shader programs.
1562
1563         * UserInterface/Views/CanvasTabContentView.css:
1564         (.content-view.tab.canvas .navigation-bar > .item .recording > .icon):
1565         (.content-view.tab.canvas .navigation-bar > .item > .canvas-overview > .icon): Deleted.
1566         Add styles for recording path components.
1567
1568         * UserInterface/Views/CanvasTabContentView.js:
1569         (WI.CanvasTabContentView):
1570         (WI.CanvasTabContentView.prototype.treeElementForRepresentedObject):
1571         (WI.CanvasTabContentView.prototype.canShowRepresentedObject):
1572         (WI.CanvasTabContentView.prototype.showRepresentedObject):
1573         (WI.CanvasTabContentView.prototype.shown):
1574         (WI.CanvasTabContentView.prototype.restoreStateFromCookie):
1575         (WI.CanvasTabContentView.prototype.attached):
1576         (WI.CanvasTabContentView.prototype.detached):
1577         (WI.CanvasTabContentView.prototype._canvasAdded):
1578         (WI.CanvasTabContentView.prototype._canvasRemoved):
1579         (WI.CanvasTabContentView.prototype._canvasTreeOutlineSelectionDidChange):
1580         (WI.CanvasTabContentView.prototype._recordingStopped):
1581         (WI.CanvasTabContentView.prototype._navigationSidebarImport):
1582         (WI.CanvasTabContentView.prototype._navigationSidebarTreeOutlineSelectionChanged):
1583         (WI.CanvasTabContentView.prototype._recordingAdded):
1584         (WI.CanvasTabContentView.prototype._recordingActionIndexChanged):
1585         (WI.CanvasTabContentView.prototype._updateActionIndex):
1586         (WI.CanvasTabContentView.prototype.restoreFromCookie): Deleted.
1587         (WI.CanvasTabContentView.prototype._overviewPathComponentClicked): Deleted.
1588
1589         * UserInterface/Views/ContentView.js:
1590         (WI.ContentView.createFromRepresentedObject):
1591
1592         * UserInterface/Views/RecordingActionTreeElement.css:
1593         (body:not(.window-inactive, .window-docked-inactive) .tree-outline:matches(:focus, .force-focus) .item.action.selected > .titles .parameter.swizzled,):
1594         (body:not(.window-inactive, .window-docked-inactive) :matches(:focus, .force-focus) .item.action.selected > .titles .parameter.swizzled,): Deleted.
1595
1596         * UserInterface/Views/RecordingContentView.css:
1597         (.content-view:not(.tab).recording):
1598         (.content-view:not(.tab).recording > header):
1599         (.content-view:not(.tab).recording > header > .slider-container):
1600         (.content-view:not(.tab).recording > header > .slider-container > input[type=range]):
1601         (.content-view:not(.tab).recording > header > .slider-container > input[type=range]::-webkit-slider-runnable-track):
1602         (.content-view:not(.tab).recording > header > .slider-container > input[type=range]::-webkit-slider-thumb):
1603         (.content-view:not(.tab).recording > .preview-container):
1604
1605         * UserInterface/Views/RecordingContentView.js:
1606         (WI.RecordingContentView):
1607         (WI.RecordingContentView.prototype.updateActionIndex):
1608         (WI.RecordingContentView.prototype.initialLayout):
1609         (WI.RecordingContentView.prototype.async._generateContentCanvas2D):
1610         (WI.RecordingContentView.prototype._updateSliderValue):
1611         (WI.RecordingContentView.prototype._sliderChanged):
1612         (WI.RecordingContentView.prototype.get supplementalRepresentedObjects): Deleted.
1613
1614         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
1615         (WI.RecordingNavigationSidebarPanel.prototype.set recording):
1616         (WI.RecordingNavigationSidebarPanel.prototype.updateActionIndex):
1617
1618         * UserInterface/Views/ResourceIcons.css:
1619         (.canvas .icon):
1620         (.canvas.canvas-2d .icon): Deleted.
1621         (.canvas:matches(.webgl, .webgl2, .webgpu) .icon): Deleted.
1622
1623 2017-10-24  Ross Kirsling  <ross.kirsling@sony.com>
1624
1625         Web Inspector: Layer mutations should be purely based on layerId, not based on nodeId
1626         https://bugs.webkit.org/show_bug.cgi?id=178554
1627
1628         Reviewed by Devin Rousso.
1629
1630         * UserInterface/Controllers/LayerTreeManager.js:
1631         (WI.LayerTreeManager.prototype.layerTreeMutations):
1632         Looking for special cases involving nodeIds is incorrect, as nodeIds need not be unique in the layer list (such
1633         as when an element and a pseudo-element thereof each give rise to a layer). A layer object marked "preserved" in
1634         this way shares no data with its predecessor, meaning that no consumer can act upon this so-called preservation.
1635         A preserved layer should be nothing more or less than a recycled layerId (the thing that *is* unique).
1636
1637 2017-10-23  Nikita Vasilyev  <nvasilyev@apple.com>
1638
1639         Web Inspector: Styles Redesign: Inline widgets don't hide when starting editing by tabbing from property name
1640         https://bugs.webkit.org/show_bug.cgi?id=178638
1641
1642         Reviewed by Joseph Pecoraro.
1643
1644         * UserInterface/Views/SpreadsheetStyleProperty.js:
1645         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidBlur):
1646         Blur event on the property name text field caused WI.SpreadsheetStyleProperty.prototype._renderValue,
1647         which displayed inline swatches. Display inline swatches only after blur event on the property value.
1648
1649 2017-10-23  Joseph Pecoraro  <pecoraro@apple.com>
1650
1651         Web Inspector: Please support HAR Export for network traffic
1652         https://bugs.webkit.org/show_bug.cgi?id=146692
1653         <rdar://problem/7463672>
1654
1655         Reviewed by Brian Burg.
1656
1657         * UserInterface/Main.html:
1658         * UserInterface/Test.html:
1659         New resources.
1660
1661         * UserInterface/Base/Platform.js:
1662         Include a build number as well.
1663         
1664         * UserInterface/Base/URLUtilities.js:
1665         (parseLocationQueryParameters): Deleted.
1666         Remove unused function.
1667
1668         * UserInterface/Controllers/FrameResourceManager.js:
1669         (WI.FrameResourceManager.prototype.frameDidNavigate):
1670         (WI.FrameResourceManager.prototype.resourceRequestWillBeSent):
1671         (WI.FrameResourceManager.prototype.resourceRequestWasServedFromMemoryCache):
1672         (WI.FrameResourceManager.prototype.resourceRequestDidReceiveResponse):
1673         (WI.FrameResourceManager.prototype._addNewResourceToFrameOrTarget):
1674         Pass along a walltime.
1675
1676         * UserInterface/Protocol/NetworkObserver.js:
1677         (WI.NetworkObserver.prototype.requestWillBeSent):
1678         Pass along a walltime. This new parameter shifts old parameters.
1679
1680         * UserInterface/Controllers/HARBuilder.js: Added.
1681         (WI.HARBuilder.async.buildArchive):
1682         (WI.HARBuilder.creator):
1683         (WI.HARBuilder.pages):
1684         (WI.HARBuilder.pageTimings):
1685         (WI.HARBuilder.entry):
1686         (WI.HARBuilder.request):
1687         (WI.HARBuilder.response):
1688         (WI.HARBuilder.cookies):
1689         (WI.HARBuilder.headers):
1690         (WI.HARBuilder.content):
1691         (WI.HARBuilder.postData):
1692         (WI.HARBuilder.cache):
1693         (WI.HARBuilder.timings):
1694         (WI.HARBuilder.ipAddress):
1695         (WI.HARBuilder.date):
1696         (WI.HARBuilder.fetchType):
1697         HAR construction and helpers.
1698
1699         * UserInterface/Models/Cookie.js:
1700         (WI.Cookie.prototype.expirationDate):
1701         * UserInterface/Models/Resource.js:
1702         (WI.Resource.prototype.get queryStringParameters):
1703         (WI.Resource.prototype.get requestFormParameters):
1704         (WI.Resource.prototype.get requestSentWalltime):
1705         (WI.Resource.prototype.get requestSentDate):
1706         (WI.Resource.prototype.hasRequestFormParameters):
1707         Helpers for HAR generation and sub-sets of data.
1708
1709         * UserInterface/Models/SourceCode.js:
1710         (WI.SourceCode.prototype._processContent):
1711         Capture the raw, unmodified, base64 encoded flag and content. This ends
1712         up getting used by HAR generation and is otherwise lost.
1713
1714         * UserInterface/Test/TestHarness.js:
1715         (TestHarness.prototype.json):
1716         Helper for just logging JSON data with a filter. This defaults to
1717         a reasonable 2 space indent for JSON logs in our test output.
1718
1719         * UserInterface/Views/DOMTreeContentView.js:
1720         (WI.DOMTreeContentView.prototype.get saveData):
1721         (WI.DOMTreeContentView.get saveData.saveHandler): Deleted.
1722         Drive-by simplify while looking at other save handlers.
1723
1724         * UserInterface/Views/NetworkTableContentView.js:
1725         (WI.NetworkTableContentView.prototype.get supportsSave):
1726         (WI.NetworkTableContentView.prototype.get saveData):
1727         (WI.NetworkTableContentView.prototype.tableCellContextMenuClicked):
1728         (WI.NetworkTableContentView.prototype._HARResources):
1729         (WI.NetworkTableContentView.prototype._exportHAR):
1730         Provide a context menu and save keyboard handler to export a HAR.
1731         This matches other browsers.
1732
1733         * UserInterface/Views/ResourceClusterContentView.js:
1734         (WI.ResourceClusterContentView.prototype._canShowRequestContentView):
1735         Use code that is now available in Resource.
1736
1737 2017-10-20  Matt Baker  <mattbaker@apple.com>
1738
1739         Web Inspector: scrolling the editor while debugging shouldn't trigger popovers
1740         https://bugs.webkit.org/show_bug.cgi?id=178325
1741
1742         Reviewed by Devin Rousso.
1743
1744         Ignore the next "mousemove" event immediately following a "mousewheel",
1745         when determining the hovered item for purposes of triggering a popover.
1746
1747         * UserInterface/Controllers/CodeMirrorTokenTrackingController.js:
1748         (WI.CodeMirrorTokenTrackingController):
1749         (WI.CodeMirrorTokenTrackingController.prototype._startTracking):
1750         (WI.CodeMirrorTokenTrackingController.prototype._stopTracking):
1751         (WI.CodeMirrorTokenTrackingController.prototype.handleEvent):
1752         (WI.CodeMirrorTokenTrackingController.prototype._mouseMovedOverEditor):
1753
1754 2017-10-20  Joseph Pecoraro  <pecoraro@apple.com>
1755
1756         Web Inspector: preview content view for MIME type application/json should be a collapsible tree outline
1757         https://bugs.webkit.org/show_bug.cgi?id=158938
1758         <rdar://problem/26891128>
1759
1760         Reviewed by Brian Burg.
1761
1762         * Localizations/en.lproj/localizedStrings.js:
1763         * UserInterface/Main.html:
1764         New files and strings.
1765
1766         * UserInterface/Views/JSONResourceContentView.css: Added.
1767         (.content-view.resource.json):
1768         (.content-view.resource.json .object-tree .prototype-property):
1769         Some padding and scrolling for the JSON content view.
1770
1771         * UserInterface/Views/JSONResourceContentView.js: Added.
1772         (WI.JSONResourceContentView):
1773         (WI.JSONResourceContentView.customContentViewDisplayName):
1774         (WI.JSONResourceContentView.prototype.contentAvailable):
1775         (WI.JSONResourceContentView.prototype.closed):
1776         JSON view evaluates the JSON content on the page and shows an ObjectTree
1777         for the resulting object.
1778
1779         * UserInterface/Views/ResourceClusterContentView.js:
1780         (WI.ResourceClusterContentView):
1781         (WI.ResourceClusterContentView.prototype.get customResponseContentView):
1782         (WI.ResourceClusterContentView.prototype.get selectionPathComponents):
1783         (WI.ResourceClusterContentView.prototype.restoreFromCookie):
1784         (WI.ResourceClusterContentView.prototype.showResponse):
1785         (WI.ResourceClusterContentView.prototype._canShowRequestContentView):
1786         (WI.ResourceClusterContentView.prototype._canShowCustomResponseContentView):
1787         (WI.ResourceClusterContentView.prototype._pathComponentForContentView):
1788         (WI.ResourceClusterContentView.prototype._identifierForContentView):
1789         (WI.ResourceClusterContentView.prototype._showContentViewForIdentifier):
1790         (WI.ResourceClusterContentView.prototype._resourceTypeDidChange):
1791         (WI.ResourceClusterContentView.prototype._resourceLoadingDidFinish):
1792         (WI.ResourceClusterContentView.prototype._tryEnableCustomResponseContentView):
1793         (WI.ResourceClusterContentView.prototype._customContentViewConstructorForResource):
1794         Allow a custom content view to be used for a resource based on the response.
1795         Currently the only custom content view is the JSON content view.
1796
1797 2017-10-20  Joseph Pecoraro  <pecoraro@apple.com>
1798
1799         Web Inspector: Network Tab - Turn on the new tab by default, remove the legacy network tab
1800         https://bugs.webkit.org/show_bug.cgi?id=178559
1801         <rdar://problem/34985503>
1802
1803         Reviewed by Matt Baker.
1804
1805         * Localizations/en.lproj/localizedStrings.js:
1806         * UserInterface/Base/Main.js:
1807         (WI.contentLoaded):
1808         * UserInterface/Base/Setting.js:
1809         * UserInterface/Main.html:
1810         * UserInterface/Views/LegacyNetworkSidebarPanel.css: Removed.
1811         * UserInterface/Views/LegacyNetworkSidebarPanel.js: Removed.
1812         * UserInterface/Views/LegacyNetworkTabContentView.js: Removed.
1813         * UserInterface/Views/NetworkGridContentView.css: Removed.
1814         * UserInterface/Views/NetworkGridContentView.js: Removed.
1815         * UserInterface/Views/TabBrowser.js:
1816         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
1817         Remove LegacyNetwork tab, its NetworkGridContentView, and associated content.
1818
1819         * UserInterface/Views/NetworkTabContentView.js:
1820         (WI.NetworkTabContentView.isTabAllowed):
1821         Simplify now that this is the only Network tab.
1822
1823         * UserInterface/Views/SettingsTabContentView.js:
1824         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1825         Remove experimental setting.
1826
1827
1828 2017-10-19  Joseph Pecoraro  <pecoraro@apple.com>
1829
1830         Unreviewed localized strings update.
1831
1832         * Localizations/en.lproj/localizedStrings.js:
1833         Add missing string after r223735.
1834
1835 2017-10-19  Joseph Pecoraro  <pecoraro@apple.com>
1836
1837         Web Inspector: Network Tab: Metrics Detail View
1838         https://bugs.webkit.org/show_bug.cgi?id=178323
1839         <rdar://problem/34071929>
1840
1841         Reviewed by Devin Rousso.
1842
1843         Provide a Metrics detail view for resources in the Network tab.
1844         This detail view shows:
1845         
1846           - Transfer Size information (Header + Body bytes)
1847           - Resource Size information (Compression, MIME)
1848           - Timing information (ResourceTiming, Waterfall breakdown)
1849
1850         The display of timing information isn't quite final. But this
1851         is a good starting point for all the information.
1852
1853         * Localizations/en.lproj/localizedStrings.js:
1854         * UserInterface/Main.html:
1855         New resources and strings.
1856
1857         * UserInterface/Base/MIMETypeUtilities.js:
1858         (WI.shouldTreatMIMETypeAsText):
1859         Helper for detecting text resources.
1860
1861         * UserInterface/Images/Receiving.svg: Added.
1862         * UserInterface/Images/Sending.svg: Added.
1863         * UserInterface/Images/gtk/Receiving.svg: Added.
1864         * UserInterface/Images/gtk/Sending.svg: Added.
1865         Same images for main and linux ports with different licenses.
1866
1867         * UserInterface/Views/NetworkResourceDetailView.js:
1868         (WI.NetworkResourceDetailView):
1869         (WI.NetworkResourceDetailView.prototype.metricsContentViewGoToHeaders):
1870         (WI.NetworkResourceDetailView.prototype.metricsContentViewGoToRequestBody):
1871         (WI.NetworkResourceDetailView.prototype.metricsContentViewGoToResponseBody):
1872         (WI.NetworkResourceDetailView.prototype.initialLayout):
1873         (WI.NetworkResourceDetailView.prototype._showPreferredContentView):
1874         (WI.NetworkResourceDetailView.prototype._showContentViewForNavigationItem):
1875         Replace "Timing" and "Details" stubs with a single "Metrics" section.
1876         Handle delegate cases from the Metrics content view.
1877
1878         * UserInterface/Views/NetworkTableContentView.js:
1879         (WI.NetworkTableContentView.displayNameForResource):
1880         (WI.NetworkTableContentView.prototype._displayType): Deleted.
1881         (WI.NetworkTableContentView.prototype._entryForResource):
1882         Promote this to a static helper in case anyone else wants it.
1883
1884         (WI.NetworkTableContentView.prototype.closed):
1885         (WI.NetworkTableContentView.prototype.reset):
1886         (WI.NetworkTableContentView.prototype.networkResourceDetailViewClose):
1887         Reorder code a bit to reduce work since hiding the detail view currently
1888         forces a layout.
1889
1890         * UserInterface/Views/ResourceHeadersContentView.js:
1891         (WI.ResourceHeadersContentView):
1892         (WI.ResourceHeadersContentView.prototype._refreshRequestDataSection):
1893         (WI.ResourceHeadersContentView.prototype._resourceResponseReceived):
1894         (WI.ResourceHeadersContentView.prototype._goToRequestDataClicked): Deleted.
1895         Simplify by making the delegate required.
1896
1897         * UserInterface/Views/ResourceMetricsContentView.css: Added.
1898         (.resource-metrics):
1899         (.resource-metrics > .content):
1900         (.resource-metrics > .content .label):
1901         General metrics styles.
1902
1903         (.resource-metrics > .content > section):
1904         (.resource-metrics > .content > section .subtitle):
1905         (.resource-metrics > .content > section:not(:last-of-type)):
1906         (.resource-metrics > .content > section.split):
1907         (.resource-metrics > .content > section.split > .subsection):
1908         (.resource-metrics > .content > section.split > .subsection > table):
1909         (.resource-metrics > .content > section.split > .divider):
1910         (.resource-metrics > .content > section.network > .subsection > .container):
1911         (.resource-metrics > .content > section.network .bytes-group):
1912         (.resource-metrics > .content > section.network .bytes):
1913         (body[dir=ltr] .resource-metrics > .content > section.network table > tr > td.label):
1914         (body[dir=rtl] .resource-metrics > .content > section.network table > tr > td.label):
1915         (.resource-metrics > .content > section.network .suffix):
1916         (.resource-metrics > .content > section.network img):
1917         (.resource-metrics > .content > section.network .go-to-arrow):
1918         (.resource-metrics > .content > section.network .warning):
1919         Styles for Sizes sections.
1920
1921         (.resource-metrics > .content > section.timing):
1922         (.resource-metrics > .content > section.timing .subtitle):
1923         (.resource-metrics > .content > section.timing > ul):
1924         (.resource-metrics > .content > section.timing > ul > li):
1925         (.resource-metrics > .content > section.timing > .waterfall):
1926         (.resource-metrics > .content > section.timing > .waterfall .block):
1927         (.resource-metrics > .content > section.timing > ul > li > .row-label):
1928         (body[dir=ltr] .resource-metrics > .content > section.timing > ul > li > .row-label):
1929         (body[dir=rtl] .resource-metrics > .content > section.timing > ul > li > .row-label):
1930         (.resource-metrics > .content > section.timing > ul > li > .time-label):
1931         (.resource-metrics > .content > section.timing > ul > li.total .block):
1932         (.resource-metrics > .content > section.timing > ul > li.total .time-label):
1933         (.resource-metrics > .content > section.timing .indeterminate-progress-spinner):
1934         (.resource-metrics > .content > section.timing .empty):
1935         Styles for Timing section.
1936
1937         * UserInterface/Views/ResourceMetricsContentView.js: Added.
1938         (WI.ResourceMetricsContentView):
1939         (WI.ResourceMetricsContentView.prototype.initialLayout.createSizeComponents):
1940         (WI.ResourceMetricsContentView.prototype.initialLayout):
1941         (WI.ResourceMetricsContentView.prototype.layout):
1942         (WI.ResourceMetricsContentView.prototype.closed):
1943         (WI.ResourceMetricsContentView.prototype._sizeComponents):
1944         (WI.ResourceMetricsContentView.prototype._refreshTransferSizeSections.appendGoToArrow):
1945         (WI.ResourceMetricsContentView.prototype._refreshTransferSizeSections):
1946         (WI.ResourceMetricsContentView.prototype._refreshResourceSizeSection):
1947         (WI.ResourceMetricsContentView.prototype._refreshTimingSection.createBlock):
1948         (WI.ResourceMetricsContentView.prototype._refreshTimingSection.createTimeLabel):
1949         (WI.ResourceMetricsContentView.prototype._refreshTimingSection.createRow):
1950         (WI.ResourceMetricsContentView.prototype._refreshTimingSection):
1951         (WI.ResourceMetricsContentView.prototype._resourceSizeDidChange):
1952         (WI.ResourceMetricsContentView.prototype._resourceTransferSizeDidChange):
1953         (WI.ResourceMetricsContentView.prototype._resourceMetricsDidChange):
1954         (WI.ResourceMetricsContentView.prototype._resourceTimestampsDidChange):
1955         Metrics content. This just creates all of the elements, and saves a
1956         few to get populated with data later on.
1957
1958 2017-10-19  Joseph Pecoraro  <pecoraro@apple.com>
1959
1960         Web Inspector: Network Tab - Improve graphical representation of network waterfall
1961         https://bugs.webkit.org/show_bug.cgi?id=147897
1962         <rdar://problem/27482198>
1963
1964         Reviewed by Brian Burg.
1965
1966         * Localizations/en.lproj/localizedStrings.js:
1967         * UserInterface/Main.html:
1968         New strings and resources.
1969
1970         * UserInterface/Views/Variables.css:
1971         (:root):
1972         Global styles.
1973
1974         * UserInterface/Views/NetworkTableContentView.css:
1975         (.network-table .header .cell.waterfall):
1976         (.network-table .timeline-ruler):
1977         (.network-table .timeline-ruler > .header):
1978         Styles for having a TimelineRuler in the Waterfall's table header.
1979
1980         (.network-table :not(.header) .cell.waterfall):
1981         (.network-table :not(.header) .cell.waterfall .waterfall-container):
1982         (.waterfall .block):
1983         (.waterfall .block.request,):
1984         (.waterfall .block.mouse):
1985         (.waterfall .block.queue):
1986         (.waterfall .block.dns):
1987         (.waterfall .block.connect):
1988         (.waterfall .block.secure):
1989         (.waterfall .block.request):
1990         (.waterfall .block.response):
1991         Waterfall styles inside the Network Table.
1992
1993         * UserInterface/Views/NetworkTableContentView.js:
1994         (WI.NetworkTableContentView):
1995         (WI.NetworkTableContentView.prototype.reset):
1996         (WI.NetworkTableContentView.prototype.tablePopulateCell):
1997         (WI.NetworkTableContentView.prototype.initialLayout):
1998         (WI.NetworkTableContentView.prototype._updateWaterfallTimelineRuler):
1999         (WI.NetworkTableContentView.prototype._updateEntryForResource):
2000         (WI.NetworkTableContentView.prototype._resourceLoadingDidFinish):
2001         (WI.NetworkTableContentView.prototype._resourceLoadingDidFail):
2002         (WI.NetworkTableContentView.prototype._networkTimelineRecordAdded):
2003         (WI.NetworkTableContentView.prototype._tableWaterfallColumnDidChangeWidth):
2004         Update the TimelineRuler and Waterfall column when the column's
2005         size changes or the time bounds change. The time bounds right now
2006         are the earliest and latest time of resources. Later we hope to
2007         bound this by a timeline selection.
2008
2009         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResource):
2010         (WI.NetworkTableContentView.prototype._handleMousedownWaterfall):
2011         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.appendBlock):
2012         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
2013         (WI.NetworkTableContentView.prototype._hidePopover):
2014         Create and manage a popover for the waterfall column.
2015
2016         * UserInterface/Views/Popover.js:
2017         (WI.Popover):
2018         (WI.Popover.prototype.get element):
2019         (WI.Popover.prototype.get visible):
2020         (WI.Popover.prototype.get backgroundStyle):
2021         (WI.Popover.prototype.set backgroundStyle):
2022         (WI.Popover.prototype._drawBackground):
2023         Provide an option to have a white background popover.
2024
2025         * UserInterface/Views/ResourceTimingBreakdownView.css: Added.
2026         (.resource-timing-breakdown):
2027         (.resource-timing-breakdown .waterfall):
2028         (.resource-timing-breakdown .waterfall .block):
2029         (.resource-timing-breakdown .waterfall .block.request):
2030         (body[dir=ltr] .resource-timing-breakdown .waterfall .block.queue,):
2031         (body[dir=ltr] .resource-timing-breakdown .waterfall .block.response):
2032         (body[dir=rtl] .resource-timing-breakdown .waterfall .block.queue,):
2033         (body[dir=rtl] .resource-timing-breakdown .waterfall .block.response):
2034         (.resource-timing-breakdown .numbers):
2035         (body[dir=ltr] .resource-timing-breakdown .numbers):
2036         (body[dir=rtl] .resource-timing-breakdown .numbers):
2037         Waterfall styles and sizes in the popover's breakdown view.
2038
2039         (.resource-timing-breakdown .numbers > p):
2040         (.resource-timing-breakdown .numbers > p > .swatch):
2041         (.resource-timing-breakdown .numbers .swatch.queue):
2042         (.resource-timing-breakdown .numbers .swatch.dns):
2043         (.resource-timing-breakdown .numbers .swatch.connect):
2044         (.resource-timing-breakdown .numbers .swatch.secure):
2045         (.resource-timing-breakdown .numbers .swatch.request):
2046         (.resource-timing-breakdown .numbers .swatch.response):
2047         (.resource-timing-breakdown .numbers > p > .label):
2048         (.resource-timing-breakdown .numbers > p.total):
2049         Number and label styles in the popover's breakdown view.
2050
2051         * UserInterface/Views/ResourceTimingBreakdownView.js: Added.
2052         (WI.ResourceTimingBreakdownView):
2053         (WI.ResourceTimingBreakdownView.prototype.initialLayout):
2054         (WI.ResourceTimingBreakdownView.prototype.initialLayout.appendBlock):
2055         (WI.ResourceTimingBreakdownView.prototype.initialLayout.appendRow):
2056         Show a section for a waterfall visualization and a section for the numbers.
2057
2058         * UserInterface/Views/Table.js:
2059         (WI.Table.prototype.reloadVisibleColumnCells):
2060         (WI.Table.prototype.cellForRowAndColumn):
2061         (WI.Table.prototype.addColumn):
2062         (WI.Table.prototype.showColumn):
2063         (WI.Table.prototype.hideColumn):
2064         (WI.Table.prototype.resizerDragging):
2065         (WI.Table.prototype.resizerDragEnded):
2066         (WI.Table.prototype._resizeColumnsAndFiller):
2067         (WI.Table.prototype._applyColumnWidths):
2068         (WI.Table.prototype._positionHeaderViews):
2069         * UserInterface/Views/TableColumn.js:
2070         (WI.TableColumn.prototype.get headerView):
2071         Provide a way to include a WI.View with a TableColumn Header. This
2072         matches what we do with DataGrid, and ends up being pretty concise.
2073
2074         * UserInterface/Views/TimelineRuler.css:
2075         (.timeline-ruler > .header):
2076         Make the height a variable so that other code can work off of it.
2077
2078 2017-10-19  Ross Kirsling  <ross.kirsling@sony.com>
2079
2080         Web Inspector: Remove superfluous file External/.eslintrc
2081         https://bugs.webkit.org/show_bug.cgi?id=178474
2082
2083         Reviewed by Joseph Pecoraro.
2084
2085         * UserInterface/External/.eslintrc: Removed.
2086
2087 2017-10-19  Adrian Perez de Castro  <aperez@igalia.com>
2088
2089         [GTK] Inspector UI does not use system font despite -webkit-system-font being supported
2090         https://bugs.webkit.org/show_bug.cgi?id=178388
2091
2092         Reviewed by Joseph Pecoraro.
2093
2094         Change ocurrences of the "-apple-system" generic font name to
2095         "-webkit-system-font", which is also implemented by the GTK+ port.
2096
2097         * UserInterface/Views/CodeMirrorOverrides.css:
2098         (.CodeMirror .CodeMirror-linenumber):
2099         (.CodeMirror .CodeMirror-placeholder):
2100         * UserInterface/Views/ConsoleMessageView.css:
2101         (.console-user-command.special-user-log > .console-message-text):
2102         (.console-message .console-message-extra-parameters-container > li::before):
2103         (.console-message .console-message-location):
2104         * UserInterface/Views/DataGrid.css:
2105         (.data-grid td):
2106         * UserInterface/Views/DefaultDashboardView.css:
2107         (.toolbar .dashboard.default > .item):
2108         * UserInterface/Views/HeapSnapshotInstancesContentView.css:
2109         (.heap-snapshot-instance-popover-content > .title):
2110         * UserInterface/Views/HierarchicalPathComponent.css:
2111         (.hierarchical-path-component):
2112         * UserInterface/Views/LogContentView.css:
2113         (.console-messages):
2114         * UserInterface/Views/Main.css:
2115         (body):
2116         * UserInterface/Views/ObjectTreeArrayIndexTreeElement.css:
2117         (.object-tree-array-index .index-name):
2118         * UserInterface/Views/ObjectTreePropertyTreeElement.css:
2119         (.object-tree-property .property-name,):
2120         * UserInterface/Views/ObjectTreeView.css:
2121         (.tree-outline.object li .empty-message):
2122         * UserInterface/Views/RecordingActionTreeElement.css:
2123         (.item.action:not(.initial-state)::before):
2124         * UserInterface/Views/SourceCodeTextEditor.css:
2125         (.source-code.text-editor > .CodeMirror .line-indicator-widget > .text):
2126         (.popover .debugger-popover-content > .title):
2127         * UserInterface/Views/TypeTreeView.css:
2128         (.type-tree):
2129         * UserInterface/Views/VisualStyleFontFamilyTreeElement.js:
2130
2131 2017-10-18  Ross Kirsling  <ross.kirsling@sony.com>
2132
2133         Web Inspector: Layers sidebar footer should not have white background with full-width quick console
2134         https://bugs.webkit.org/show_bug.cgi?id=178493
2135
2136         Reviewed by Matt Baker.
2137
2138         * UserInterface/Views/LayerDetailsSidebarPanel.css:
2139         Update CSS for new sidebar.
2140
2141         * UserInterface/Views/LayerTreeDetailsSidebarPanel.css:
2142         Update CSS for legacy sidebar.
2143
2144 2017-10-18  Fujii Hironori  <Hironori.Fujii@sony.com>
2145
2146         [GTK] Web Inspector: Add Layers.svg
2147         https://bugs.webkit.org/show_bug.cgi?id=178430
2148
2149         Reviewed by Michael Catanzaro.
2150
2151         * UserInterface/Images/gtk/Layers.svg: Added.
2152
2153 2017-10-18  Commit Queue  <commit-queue@webkit.org>
2154
2155         Unreviewed, rolling out r223321.
2156         https://bugs.webkit.org/show_bug.cgi?id=178476
2157
2158         This protocol change broke some internal builds (Requested by
2159         brrian__ on #webkit).
2160
2161         Reverted changeset:
2162
2163         "Web Inspector: provide a way to enable/disable event
2164         listeners"
2165         https://bugs.webkit.org/show_bug.cgi?id=177451
2166         https://trac.webkit.org/changeset/223321
2167
2168 2017-10-17  Nikita Vasilyev  <nvasilyev@apple.com>
2169
2170         Web Inspector: [PARITY] Styles Redesign: Add color picker inline widget
2171         https://bugs.webkit.org/show_bug.cgi?id=178354
2172
2173         Reviewed by Joseph Pecoraro.
2174
2175         Show color picker using the existing WI.InlineSwatch.
2176
2177         * UserInterface/Models/Color.js:
2178         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2179         (.spreadsheet-style-declaration-editor .property:not(.disabled) .token-comment):
2180         Syntax highlight comments in values.
2181
2182         * UserInterface/Views/SpreadsheetStyleProperty.js:
2183         (WI.SpreadsheetStyleProperty.prototype._renderValue):
2184         (WI.SpreadsheetStyleProperty.prototype._addColorTokens):
2185         Find colors in CodeMirror tokens and replace them with color token elements.
2186
2187 2017-10-17  Nikita Vasilyev  <nvasilyev@apple.com>
2188
2189         Web Inspector: Styles: Command-click on a property name should jump to definition in Resources tab
2190         https://bugs.webkit.org/show_bug.cgi?id=174329
2191         <rdar://problem/33225564>
2192
2193         Reviewed by Joseph Pecoraro.
2194
2195         * UserInterface/Base/Main.js:
2196         Add "meta-key-pressed" class to <body> when Command key is pressed.
2197
2198         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2199         (.meta-key-pressed .spreadsheet-css-declaration:not(.locked) :matches(.name, .value):not(.editing):hover):
2200         Use the same styles as in CodeMirrorTokenTrackingController.css.
2201
2202         * UserInterface/Views/SpreadsheetStyleProperty.js:
2203         (WI.SpreadsheetStyleProperty.prototype._update):
2204         (WI.SpreadsheetStyleProperty.prototype._setupJumpToSymbol):
2205         This is very similar to WI.CSSStyleDeclarationTextEditor.prototype.tokenTrackingControllerHighlightedRangeWasClicked,
2206         except it doesn't include special cases for CSS variables and links yet.
2207
2208 2017-10-16  Nikita Vasilyev  <nvasilyev@apple.com>
2209
2210         Web Inspector: Styles Redesign: apply syntax highlighting to property values
2211         https://bugs.webkit.org/show_bug.cgi?id=178176
2212
2213         Reviewed by Matt Baker.
2214
2215         - Highlight links blue and CSS strings dark red.
2216         - Truncate URLs and strings over 150 characters.
2217
2218         * UserInterface/Views/CodeMirrorAdditions.js:
2219         Parse CSS values using CodeMirror.
2220
2221         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2222         (.spreadsheet-style-declaration-editor .property:not(.disabled) .token-link):
2223         (.spreadsheet-style-declaration-editor .property:not(.disabled) .token-string):
2224
2225         * UserInterface/Views/SpreadsheetStyleProperty.js:
2226         (WI.SpreadsheetStyleProperty.prototype._update):
2227         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldWillStartEditing):
2228         Replace trancated values with their full version.
2229
2230         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidCommit):
2231         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidBlur):
2232         (WI.SpreadsheetStyleProperty.prototype._renderValue):
2233         Highlight links and CSS strings in values when not editing.
2234
2235         * UserInterface/Views/SpreadsheetTextField.js:
2236         (WI.SpreadsheetTextField.prototype.startEditing):
2237         Disabling of syntax highlighting moved to spreadsheetTextFieldWillStartEditing.
2238
2239         * UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
2240         (.syntax-highlighted a):
2241         * UserInterface/Views/Variables.css:
2242         (:root):
2243         Make link color a variable.
2244
2245 2017-10-16  Ross Kirsling  <ross.kirsling@sony.com>
2246
2247         Web Inspector: Layers tab mistakenly throws out the root element's layer.
2248         https://bugs.webkit.org/show_bug.cgi?id=178222
2249
2250         Reviewed by Brian Burg.
2251
2252         * UserInterface/Controllers/LayerTreeManager.js:
2253         (WI.LayerTreeManager.prototype.layersForNode):
2254         Fix the issue at the manager level.
2255
2256         * UserInterface/Views/Layers3DContentView.js:
2257         (WI.Layers3DContentView.prototype.layout):
2258         Update new sidebar based on simplified manager API.
2259
2260         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
2261         (WI.LayerTreeDetailsSidebarPanel.prototype.layout):
2262         Move overtailored code from manager to legacy sidebar.
2263
2264 2017-10-15  Nikita Vasilyev  <nvasilyev@apple.com>
2265
2266         Web Inspector: Modify CSS number values with up key and down key
2267         https://bugs.webkit.org/show_bug.cgi?id=170779
2268         <rdar://problem/33170633>
2269
2270         Reviewed by Matt Baker.
2271
2272         Up key increments a number, Down key decrements it.
2273
2274         Holding modifier keys changes the step value:
2275         - Option modifies the value by 0.1
2276         - Shift modifies the value by 10
2277         - Command modifies the value by 100
2278
2279         * UserInterface/Test.html:
2280         * UserInterface/Views/EditingSupport.js:
2281         (WI.incrementElementValue):
2282         Abstract away incrementElementValue into a public method.
2283
2284         * UserInterface/Views/SpreadsheetTextField.js:
2285         (WI.SpreadsheetTextField.prototype._handleKeyDown):
2286
2287 2017-10-15  Devin Rousso  <webkit@devinrousso.com>
2288
2289         Web Inspector: show warning when recorded Canvas action caused no visual change
2290         https://bugs.webkit.org/show_bug.cgi?id=175282
2291
2292         Reviewed by Joseph Pecoraro.
2293
2294         * Localizations/en.lproj/localizedStrings.js:
2295
2296         * UserInterface/Models/RecordingAction.js:
2297         (WI.RecordingAction):
2298         (WI.RecordingAction.prototype.get valid):
2299         (WI.RecordingAction.prototype.get hasVisibleEffect):
2300         (WI.RecordingAction.prototype.markInvalid):
2301         (WI.RecordingAction.prototype.apply):
2302         (WI.RecordingAction.prototype.async._swizzle):
2303         If the selected action is visual, save a copy of the preview canvas' dataURL before
2304         applying the action and compare it to its dataURL after. If there is no difference, the
2305         action had no visual effect.
2306
2307         * UserInterface/Models/Recording.js:
2308         (WI.Recording):
2309
2310         * UserInterface/Views/RecordingActionTreeElement.js:
2311         (WI.RecordingActionTreeElement):
2312         (WI.RecordingActionTreeElement.prototype._handleValidityChanged):
2313         (WI.RecordingActionTreeElement.prototype._handleHasVisibleEffectChanged):
2314         * UserInterface/Views/RecordingActionTreeElement.css:
2315         (.item.action.visual.no-visible-effect:not(.invalid) > .status > .warning):
2316
2317         * UserInterface/Views/RecordingContentView.js:
2318         (WI.RecordingContentView):
2319         (WI.RecordingContentView.prototype.async._generateContentCanvas2D):
2320         (WI.RecordingContentView.prototype._applyAction): Deleted.
2321
2322 2017-10-15  Nikita Vasilyev  <nvasilyev@apple.com>
2323
2324         Web Inspector: [PARITY] Styles Redesign: clicking on the go-to arrow in Computed tab should work
2325         https://bugs.webkit.org/show_bug.cgi?id=178286
2326         <rdar://problem/34986379>
2327
2328         Reviewed by Joseph Pecoraro.
2329
2330         Highlight the matching property using a yellow background and focus on the property value
2331         if the property is editable (e.g., not a User Agent style).
2332
2333         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2334         (.spreadsheet-style-declaration-editor):
2335         (.spreadsheet-style-declaration-editor .property):
2336         Move left padding to the property element so there's no awkward gap on the left side
2337         when the property is highlighted.
2338
2339         (.spreadsheet-style-declaration-editor .property.highlighted):
2340         (@keyframes style-property-highlight):
2341         Use the same animation duration as we used in `.text-editor > .CodeMirror .highlighted`.
2342         The highlight color was changed from light blue to yellow.
2343
2344         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
2345         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.highlightProperty):
2346         Use the same logic as in WI.CSSStyleDeclarationTextEditor.prototype.highlightProperty
2347         to find matching style property to highlight.
2348
2349         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
2350         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.highlightProperty):
2351         Use the same logic as in WI.CSSStyleDeclarationSection.prototype.highlightProperty.
2352
2353         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
2354         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.scrollToSectionAndHighlightProperty):
2355         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.nodeStylesRefreshed):
2356         Copied from WI.RulesStyleDetailsPanel.
2357
2358         * UserInterface/Views/SpreadsheetStyleProperty.js:
2359         (WI.SpreadsheetStyleProperty):
2360         (WI.SpreadsheetStyleProperty.prototype.detached):
2361         (WI.SpreadsheetStyleProperty.prototype.highlight):
2362
2363 2017-10-14  Nikita Vasilyev  <nvasilyev@apple.com>
2364
2365         REGRESSION (r223310): Web Inspector: Class list container is transparent and unreadable
2366         https://bugs.webkit.org/show_bug.cgi?id=178311
2367
2368         Reviewed by Devin Rousso.
2369
2370         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
2371         (.sidebar > .panel.details.css-style > .content ~ .class-list-container):
2372         Fix 1px hole below the class container.
2373
2374 2017-10-14  Matt Baker  <mattbaker@apple.com>
2375
2376         Web Inspector: Canvas tab: recordings should have a unique name
2377         https://bugs.webkit.org/show_bug.cgi?id=178188
2378         <rdar://problem/34943364>
2379
2380         Reviewed by Devin Rousso.
2381
2382         * Localizations/en.lproj/localizedStrings.js:
2383         New format string "Recording %d".
2384
2385         * UserInterface/Base/FileUtilities.js:
2386         (WI.loadDataFromFile):
2387         Pass chosen filename to callback.
2388
2389         * UserInterface/Controllers/CanvasManager.js:
2390         (WI.CanvasManager.prototype.recordingFinished):
2391         Create a unique name for the recording.
2392
2393         * UserInterface/Models/Recording.js:
2394         (WI.Recording):
2395         (WI.Recording.fromPayload):
2396         (WI.Recording.prototype.get displayName):
2397         (WI.Recording.prototype.createDisplayName):
2398
2399         * UserInterface/Views/RecordingContentView.js:
2400         (WI.RecordingContentView.prototype.get saveData):
2401         Use encodeURI so that special characters can be used in filenames, and
2402         to be consistent with other `saveData` implementations.
2403
2404         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
2405         (WI.RecordingNavigationSidebarPanel.prototype.set recording):
2406         (WI.RecordingNavigationSidebarPanel.prototype._importNavigationItemClicked):
2407         Drive-by fix: wait until actions are resolved before updating UI.
2408
2409         * UserInterface/Views/RecordingTabContentView.js:
2410         (WI.RecordingTabContentView.prototype._navigationSidebarImport):
2411         Try to use the imported filename as the recording name. If the name
2412         collides with that of another imported recording, append a unique suffix.
2413
2414 2017-10-14  Devin Rousso  <webkit@devinrousso.com>
2415
2416         Web Inspector: provide a way to enable/disable event listeners
2417         https://bugs.webkit.org/show_bug.cgi?id=177451
2418
2419         Reviewed by Joseph Pecoraro.
2420
2421         * Localizations/en.lproj/localizedStrings.js:
2422
2423         * UserInterface/Controllers/DOMTreeManager.js:
2424         (WI.DOMTreeManager.prototype.setEventListenerDisabled):
2425
2426         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
2427         (WI.DOMNodeDetailsSidebarPanel.prototype.attached):
2428         (WI.DOMNodeDetailsSidebarPanel.prototype.detached):
2429         (WI.DOMNodeDetailsSidebarPanel.prototype._eventListenersChanged):
2430         (WI.DOMNodeDetailsSidebarPanel.prototype.addEventListeners): Deleted.
2431         (WI.DOMNodeDetailsSidebarPanel.prototype.removeEventListeners): Deleted.
2432         Listen for `WI.DOMNode.Event.EventListenersChanged` on all instances of WI.DOMNode, since we
2433         will still want to refresh the event listeners section in the event that an event listener
2434         is removed from a parent node.
2435
2436         * UserInterface/Views/EventListenerSectionGroup.js:
2437         (WI.EventListenerSectionGroup):
2438         (WI.EventListenerSectionGroup.prototype._eventText):
2439         (WI.EventListenerSectionGroup.prototype._nodeTextOrLink):
2440         (WI.EventListenerSectionGroup.prototype._createDisabledToggleElement):
2441         (WI.EventListenerSectionGroup.prototype._createDisabledToggleElement.updateTitle):
2442         * UserInterface/Views/EventListenerSectionGroup.css:
2443         (.event-listener-section > .content input[type="checkbox"]):
2444
2445         * UserInterface/Views/DetailsSectionSimpleRow.js:
2446         (WI.DetailsSectionSimpleRow.prototype.get label):
2447         (WI.DetailsSectionSimpleRow.prototype.set label):
2448
2449 2017-10-13  Devin Rousso  <webkit@devinrousso.com>
2450
2451         Web Inspector: make split console full width of view
2452         https://bugs.webkit.org/show_bug.cgi?id=176635
2453
2454         Reviewed by Timothy Hatcher.
2455
2456         * UserInterface/Main.html:
2457         * UserInterface/Views/Main.css:
2458         (#main):
2459         (#content):
2460         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
2461         (.sidebar > .panel.details.css-style > .content ~ :matches(.options-container, .class-list-container)):
2462         (.sidebar > .panel.details.css-style > .content ~ .options-container):
2463
2464 2017-10-13  Devin Rousso  <webkit@devinrousso.com>
2465
2466         Web Inspector: fix ESLint errors
2467         https://bugs.webkit.org/show_bug.cgi?id=175065
2468
2469         Reviewed by Joseph Pecoraro.
2470
2471         Removed trailing whitespace, extra parenthesis, and some unnecessary escape characters.
2472         Added missing semicolons, spacing around default values for parameters, and changed `==` to
2473         `===` where applicable.
2474
2475         Specific changes to each file were removed for brevity.
2476
2477         * .eslintrc:
2478         Alphabetize each list of global variables and add some missing utility functions.
2479
2480         * UserInterface/Base/EventListener.js:
2481         * UserInterface/Base/EventListenerSet.js:
2482         * UserInterface/Base/Main.js:
2483         * UserInterface/Base/Setting.js:
2484         * UserInterface/Base/TextUtilities.js:
2485         * UserInterface/Base/URLUtilities.js:
2486         * UserInterface/Base/Utilities.js:
2487         * UserInterface/Base/YieldableTask.js:
2488         * UserInterface/Controllers/AppControllerBase.js:
2489         * UserInterface/Controllers/CanvasManager.js:
2490         * UserInterface/Controllers/CodeMirrorCompletionController.js:
2491         * UserInterface/Controllers/DOMDebuggerManager.js:
2492         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
2493         * UserInterface/Controllers/RuntimeManager.js:
2494         * UserInterface/Controllers/SourceMapManager.js:
2495         * UserInterface/Debug/DebugContentView.js:
2496         * UserInterface/Debug/UncaughtExceptionReporter.js:
2497         * UserInterface/Models/CSSKeywordCompletions.js:
2498         * UserInterface/Models/DOMNode.js:
2499         * UserInterface/Models/DOMNodeStyles.js:
2500         * UserInterface/Models/KeyboardShortcut.js:
2501         * UserInterface/Models/ProfileNode.js:
2502         * UserInterface/Models/Resource.js:
2503         * UserInterface/Models/ResourceCollection.js:
2504         * UserInterface/Models/Script.js:
2505         * UserInterface/Models/ScriptSyntaxTree.js:
2506         * UserInterface/Models/ScriptTimelineRecord.js:
2507         * UserInterface/Protocol/Connection.js:
2508         * UserInterface/Test/FrontendTestHarness.js:
2509         * UserInterface/Test/TestHarness.js:
2510         * UserInterface/Views/CSSStyleDeclarationSection.js:
2511         * UserInterface/Views/ChartDetailsSectionRow.js:
2512         * UserInterface/Views/CodeMirrorAdditions.js:
2513         * UserInterface/Views/CodeMirrorFormatters.js:
2514         * UserInterface/Views/CodeMirrorRegexMode.js:
2515         * UserInterface/Views/ContentBrowserTabContentView.js:
2516         * UserInterface/Views/DataGrid.js:
2517         * UserInterface/Views/DataGridNode.js:
2518         * UserInterface/Views/FindBanner.js:
2519         * UserInterface/Views/GroupNavigationItem.js:
2520         * UserInterface/Views/HierarchicalPathNavigationItem.js:
2521         * UserInterface/Views/NetworkTableContentView.js:
2522         * UserInterface/Views/NetworkTimelineView.js:
2523         * UserInterface/Views/ObjectTreePropertyTreeElement.js:
2524         * UserInterface/Views/ObjectTreeView.js:
2525         * UserInterface/Views/RecordingContentView.js:
2526         * UserInterface/Views/RenderingFrameTimelineOverviewGraph.js:
2527         * UserInterface/Views/ResourceCookiesContentView.js:
2528         * UserInterface/Views/ResourceDetailsSection.js:
2529         * UserInterface/Views/ResourceHeadersContentView.js:
2530         * UserInterface/Views/ResourceTimelineDataGridNode.js:
2531         * UserInterface/Views/SettingEditor.js:
2532         * UserInterface/Views/Sidebar.js:
2533         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
2534         * UserInterface/Views/Table.js:
2535         * UserInterface/Views/TextEditor.js:
2536         * UserInterface/Views/TimelineDataGridNode.js:
2537         * UserInterface/Views/TreeElement.js:
2538         * UserInterface/Views/TreeOutline.js:
2539         * UserInterface/Views/WebSocketDataGridNode.js:
2540         * UserInterface/Workers/Formatter/EsprimaFormatter.js:
2541         * UserInterface/Workers/Formatter/FormatterWorker.js:
2542
2543 2017-10-13  Nikita Vasilyev  <nvasilyev@apple.com>
2544
2545         Web Inspector: Styles Redesign: hook up autocompletion to property names and values
2546         https://bugs.webkit.org/show_bug.cgi?id=177313
2547         <rdar://problem/34577057>
2548
2549         Reviewed by Joseph Pecoraro.
2550
2551         - Arrow Right accept the current completion item and places the text caret after it.
2552         - Arrow Left hides the completion popover.
2553         - Arrow Up selects the previous completion item.
2554         - Arrow Down selects the next completion item.
2555         - Enter and Tab accept the current completion item and navigate to the next focusable item.
2556         - Escape hides the completion popover, if there is one.
2557
2558         * UserInterface/Views/CompletionSuggestionsView.js:
2559         (WI.CompletionSuggestionsView):
2560         (WI.CompletionSuggestionsView.prototype._mouseDown):
2561         Add a preventBlur option so clicking on an completion item doesn't change the focus and
2562         doesn't cause "blur" event on the target text field.
2563
2564         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2565         (.spreadsheet-style-declaration-editor .completion-hint):
2566         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
2567         (WI.SpreadsheetCSSStyleDeclarationEditor):
2568         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
2569         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.detached):
2570         Call detached on every SpreadsheetTextField to hide CompletionSuggestionsView once
2571         SpreadsheetCSSStyleDeclarationEditor is removed from the DOM.
2572
2573         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._addBlankProperty):
2574         Remove index argument since it is no longer used.
2575
2576         * UserInterface/Views/SpreadsheetStyleProperty.js:
2577         (WI.SpreadsheetStyleProperty):
2578         (WI.SpreadsheetStyleProperty.prototype.detached):
2579         (WI.SpreadsheetStyleProperty.prototype._remove):
2580         (WI.SpreadsheetStyleProperty.prototype._update):
2581         (WI.SpreadsheetStyleProperty.prototype._nameCompletionDataProvider):
2582         (WI.SpreadsheetStyleProperty.prototype._valueCompletionDataProvider):
2583         Add an extra parameter to SpreadsheetTextField to pass a completion data provider.
2584
2585         * UserInterface/Views/SpreadsheetTextField.js:
2586         (WI.SpreadsheetTextField):
2587         (WI.SpreadsheetTextField.prototype.get suggestionHint):
2588         (WI.SpreadsheetTextField.prototype.set suggestionHint):
2589         (WI.SpreadsheetTextField.prototype.startEditing):
2590         (WI.SpreadsheetTextField.prototype.stopEditing):
2591         (WI.SpreadsheetTextField.prototype.detached):
2592         (WI.SpreadsheetTextField.prototype.completionSuggestionsSelectedCompletion):
2593         (WI.SpreadsheetTextField.prototype.completionSuggestionsClickedCompletion):
2594         (WI.SpreadsheetTextField.prototype._getPrefix):
2595         (WI.SpreadsheetTextField.prototype._handleBlur):
2596         (WI.SpreadsheetTextField.prototype._handleKeyDown):
2597         (WI.SpreadsheetTextField.prototype._handleKeyDownForSuggestionView):
2598         (WI.SpreadsheetTextField.prototype._handleInput):
2599         (WI.SpreadsheetTextField.prototype._updateCompletions):
2600         (WI.SpreadsheetTextField.prototype._getCaretRect):
2601         (WI.SpreadsheetTextField.prototype._getCompletionPrefix):
2602         (WI.SpreadsheetTextField.prototype._applyCompletionHint):
2603         (WI.SpreadsheetTextField.prototype._hideCompletions):
2604         Provide text completion based on the existing CompletionSuggestionsView when completionProvider is passed to SpreadsheetTextField.
2605
2606 2017-10-12  Joseph Pecoraro  <pecoraro@apple.com>
2607
2608         Web Inspector: Switch Clear navigation item back to the Trash icon (Console, Timelines, Network)
2609         https://bugs.webkit.org/show_bug.cgi?id=178244
2610         <rdar://problem/34966525>
2611
2612         Reviewed by Brian Burg.
2613
2614         * UserInterface/Images/NavigationItemClear.svg: Removed.
2615         * UserInterface/Images/gtk/NavigationItemClear.svg: Removed.
2616         * UserInterface/Views/LogContentView.js:
2617         (WI.LogContentView):
2618         * UserInterface/Views/NetworkGridContentView.js:
2619         (WI.NetworkGridContentView):
2620         * UserInterface/Views/NetworkTableContentView.js:
2621         (WI.NetworkTableContentView):
2622         * UserInterface/Views/TimelineRecordingContentView.js:
2623         (WI.TimelineRecordingContentView):
2624         Many users found the new Clear icon confusing. Revert to the Trash icon.
2625
2626 2017-10-11  Ross Kirsling  <ross.kirsling@sony.com>
2627
2628         Web Inspector: Make 3D objects selectable in Layers visualization
2629         https://bugs.webkit.org/show_bug.cgi?id=178136
2630
2631         Reviewed by Devin Rousso.
2632
2633         * UserInterface/Views/Layers3DContentView.js:
2634         (WI.Layers3DContentView):
2635         (WI.Layers3DContentView.prototype.initialLayout):
2636         (WI.Layers3DContentView.prototype._canvasMouseDown):
2637         (WI.Layers3DContentView.prototype._updateLayerGroupSelection):
2638         Implement selection of 3D layer objects.
2639         
2640         (WI.Layers3DContentView.prototype._addLayerGroup): Renamed from _addLayer.
2641         (WI.Layers3DContentView.prototype._updateLayerGroupPosition):
2642         (WI.Layers3DContentView.prototype._createLayerMesh):
2643         Refactor -- one group per layer (visible plane and composited outline), not groups by shape.
2644
2645         (WI.Layers3DContentView.prototype.layout):
2646         (WI.Layers3DContentView.prototype._updateLayers):
2647         (WI.Layers3DContentView.prototype._clearLayers): Deleted.
2648         Don't destroy all 3D objects on every LayerTreeDidChange; make use of layerTreeMutations.
2649         (Not only a performance improvement, but also necessary to properly preserve highlighting.) 
2650         
2651         (WI.Layers3DContentView.prototype.selectLayerById):
2652         Allow selection to be updated from the outside.
2653
2654         * UserInterface/Views/LayerDetailsSidebarPanel.js:
2655         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
2656         (WI.LayerDetailsSidebarPanel.prototype._buildDataGrid):
2657         (WI.LayerDetailsSidebarPanel.prototype._dataGridSelectedNodeChanged):
2658         Allow selection to be updated from the outside.
2659
2660         (WI.LayerDetailsSidebarPanel.prototype.inspect):
2661         (WI.LayerDetailsSidebarPanel.prototype._updateLayers): Renamed from _updateDisplayWithLayers.
2662         (WI.LayerDetailsSidebarPanel.prototype._updateDataGrid):
2663         (WI.LayerDetailsSidebarPanel.prototype._updateBottomBar):
2664         (WI.LayerDetailsSidebarPanel.prototype._contentForPopover):
2665         (WI.LayerDetailsSidebarPanel.prototype._dataGridNodeForLayer): Deleted.
2666         Cleanup.
2667         
2668         * UserInterface/Views/LayersTabContentView.js:
2669         (WI.LayersTabContentView):
2670         (WI.LayersTabContentView.prototype._detailsSidebarSelectedLayerChanged):
2671         (WI.LayersTabContentView.prototype._contentViewSelectedLayerChanged):
2672         Orchestrate communication of selection state between visualization and sidebar.
2673
2674 2017-10-11  Joseph Pecoraro  <pecoraro@apple.com>
2675
2676         Web Inspector: Avoid "100.00ms" vs "100.0ms" jitter in TimelineRuler labels
2677         https://bugs.webkit.org/show_bug.cgi?id=178143
2678
2679         Reviewed by Brian Burg.
2680
2681         * UserInterface/Base/Utilities.js:
2682         Allow a small slop factor that wouldn't have changed the display value's
2683         significant figures anyways. This addresses cases where 100.0000000000001
2684         were being treated slightly differently from 100.0.
2685
2686 2017-10-11  Joseph Pecoraro  <pecoraro@apple.com>
2687
2688         Web Inspector: Network Tab - Show initially loaded resources even if network info not logged
2689         https://bugs.webkit.org/show_bug.cgi?id=178098
2690         <rdar://problem/34073529>
2691
2692         Reviewed by Devin Rousso.
2693
2694         * UserInterface/Models/Resource.js:
2695         (WI.Resource.prototype.hasResponse):
2696         Resources loaded by Page.getFrameTree have a response but no status code data.
2697         So include finished resources as having a resource.
2698
2699         * UserInterface/Views/NetworkTableContentView.js:
2700         (WI.NetworkTableContentView):
2701         (WI.NetworkTableContentView.prototype.closed):
2702         (WI.NetworkTableContentView.prototype._populateWithInitialResourcesIfNeeded):
2703         (WI.NetworkTableContentView.prototype._mainFrameDidChange):
2704         Listen for the first main frame change to perform an initial population.
2705
2706         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
2707         This path is not currently taken when table is null, but change the code so
2708         that if it is reached without the table it would behave gracefully.
2709
2710         * UserInterface/Views/ResourceHeadersContentView.js:
2711         (WI.ResourceHeadersContentView.prototype._refreshSummarySection):
2712         On first open none of the resources have a statusCode. Show an emDash.
2713
2714 2017-10-10  Brian Burg  <bburg@apple.com>
2715
2716         Web Inspector: Quick Open: source mapped files are not shown as search results
2717         https://bugs.webkit.org/show_bug.cgi?id=178151
2718         <rdar://problem/31561718>
2719
2720         Reviewed by Joseph Pecoraro.
2721
2722         * UserInterface/Views/OpenResourceDialog.js:
2723         (WI.OpenResourceDialog.prototype._addResource):
2724         Also consider matching the query string against SourceMapResources
2725         attached to a resource's source maps.
2726
2727 2017-10-10  Joseph Pecoraro  <pecoraro@apple.com>
2728
2729         Web Inspector: Network Tab - Set column initial widths to try allow waterfall column to expand more by default
2730         https://bugs.webkit.org/show_bug.cgi?id=178142
2731         <rdar://problem/34918233>
2732
2733         Reviewed by Brian Burg.
2734
2735         * UserInterface/Views/NetworkTableContentView.js:
2736         (WI.NetworkTableContentView.prototype.initialLayout):
2737         Provide initial widths for many columns where the max could fit
2738         but we'd prefer a smaller than max initial width in wide cases.
2739
2740         * UserInterface/Views/Table.js:
2741         (WI.Table.prototype._resizeColumnsAndFiller):
2742         When auto sizing all columns use the preferred initial widths.
2743
2744         * UserInterface/Views/TableColumn.js:
2745         (WI.TableColumn.prototype.get preferredInitialWidth):
2746         Save the initial width.
2747
2748 2017-10-10  Ross Kirsling  <ross.kirsling@sony.com>
2749
2750         Web Inspector: Views should explicitly remove event listeners from managers/Frame
2751         https://bugs.webkit.org/show_bug.cgi?id=175951
2752
2753         Reviewed by Brian Burg.
2754
2755         * UserInterface/Views/ApplicationCacheDetailsSidebarPanel.js:
2756         (WI.ApplicationCacheDetailsSidebarPanel.prototype.closed):
2757         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
2758         (WI.DOMNodeDetailsSidebarPanel.prototype.closed):
2759         * UserInterface/Views/DebuggerDashboardView.js:
2760         (WI.DebuggerDashboardView.prototype.closed):
2761         * UserInterface/Views/LogContentView.js:
2762         (WI.LogContentView.prototype.closed):
2763         * UserInterface/Views/NetworkGridContentView.js:
2764         (WI.NetworkGridContentView.prototype.closed):
2765         * UserInterface/Views/ProbeDetailsSidebarPanel.js:
2766         (WI.ProbeDetailsSidebarPanel.prototype.closed):
2767         * UserInterface/Views/QuickConsole.js:
2768         (WI.QuickConsole.prototype.closed):
2769         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
2770         (WI.ScopeChainDetailsSidebarPanel.prototype.closed):
2771         * UserInterface/Views/TimelineOverview.js:
2772         (WI.TimelineOverview.prototype.closed):
2773
2774 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2775
2776         Web Inspector: Network Tab - Include remote address in the Headers view
2777         https://bugs.webkit.org/show_bug.cgi?id=178094
2778         <rdar://problem/34895221>
2779
2780         Reviewed by Devin Rousso.
2781
2782         * Localizations/en.lproj/localizedStrings.js:
2783         * UserInterface/Views/ResourceHeadersContentView.js:
2784         (WI.ResourceHeadersContentView.prototype._refreshSummarySection):
2785         (WI.ResourceHeadersContentView.prototype._resourceMetricsDidChange):
2786
2787 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2788
2789         Unreviewed, minified WebInspector opens blank.
2790         <rdar://problem/34892307>
2791
2792         * UserInterface/Views/ResourceHeadersContentView.js:
2793         (WI.ResourceHeadersContentView.prototype._refreshRequestHeadersSection):
2794         Regression introduced in r223006. The minified build has a SyntaxError
2795         causing WebInspector top open blank. Add the missing semicolon.
2796
2797 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2798
2799         Web Inspector: Network Tab - Filter resources based on URL / Text Content
2800         https://bugs.webkit.org/show_bug.cgi?id=178071
2801         <rdar://problem/34071562>
2802
2803         Reviewed by Brian Burg.
2804
2805         * Localizations/en.lproj/localizedStrings.js:
2806         New strings.
2807
2808         * UserInterface/Views/FilterBar.css:
2809         (.filter-bar.active > input[type="search"]::-webkit-search-decoration):
2810         (.filter-bar.indicating-progress > input[type="search"]::-webkit-search-decoration):
2811         New icon for progress / active states.
2812
2813         * UserInterface/Views/FilterBar.js:
2814         (WI.FilterBar.prototype.get inputField):
2815         (WI.FilterBar.prototype.get placeholder):
2816         (WI.FilterBar.prototype.set placeholder):
2817         (WI.FilterBar.prototype.get incremental):
2818         (WI.FilterBar.prototype.set incremental):
2819         (WI.FilterBar.prototype.get indicatingProgress):
2820         (WI.FilterBar.prototype.set indicatingProgress):
2821         (WI.FilterBar.prototype.get indicatingActive):
2822         (WI.FilterBar.prototype.set indicatingActive):
2823         (WI.FilterBar.prototype._handleFilterInputEvent):
2824         When incremental is set to false on the FilterBar still dispatch an
2825         event when the textfield clears.
2826
2827         * UserInterface/Images/FilterFieldActiveGlyph.svg: Added.
2828         * UserInterface/Images/gtk/FilterFieldActiveGlyph.svg: Added.
2829         New blue icon for active state.
2830
2831         * UserInterface/Controllers/FrameResourceManager.js:
2832         (WI.FrameResourceManager.prototype.resourceForIdentifier):
2833         Accessor for arbitrary resource.
2834
2835         * UserInterface/Views/NetworkTableContentView.css:
2836         (.content-view.network .navigation-bar .filter-bar):
2837         (.content-view.network .warning-banner):
2838         (body[dir=ltr] .content-view.network .warning-banner):
2839         (body[dir=rtl] .content-view.network .warning-banner):
2840         (.content-view.network .warning-banner > a):
2841         Warning banner when the filter produces no results. This matches the
2842         warning in the Debugger tab when breakpoints are disabled.
2843
2844         * UserInterface/Views/ScopeBar.js:
2845         (WI.ScopeBar.prototype.resetToDefault):
2846         Provide a way to easily reset a scope bar to the default item.
2847
2848         * UserInterface/Views/RadioButtonNavigationItem.css:
2849         (.navigation-bar .item.radio.button.text-only:active):
2850         * UserInterface/Views/ScopeBar.css:
2851         (.scope-bar > li:active):
2852         Cleanup some styles that should be using a variable.
2853
2854         * UserInterface/Views/NetworkTableContentView.js:
2855         (WI.NetworkTableContentView):
2856         (WI.NetworkTableContentView.prototype.get filterNavigationItems):
2857         (WI.NetworkTableContentView.prototype.layout):
2858         (WI.NetworkTableContentView.prototype._processPendingEntries):
2859         (WI.NetworkTableContentView.prototype._checkTextFilterAgainstFinishedResource):
2860         (WI.NetworkTableContentView.prototype._checkTextFilterAgainstFailedResource):
2861         (WI.NetworkTableContentView.prototype._updateTextFilterActiveIndicator):
2862         (WI.NetworkTableContentView.prototype._updateEmptyFilterResultsWarning):
2863         (WI.NetworkTableContentView.prototype._showEmptyFilterResultsWarning):
2864         (WI.NetworkTableContentView.prototype._hideEmptyFilterResultsWarning):
2865         (WI.NetworkTableContentView.prototype._positionEmptyFilterMessage):
2866         (WI.NetworkTableContentView.prototype._resourceLoadingDidFinish):
2867         (WI.NetworkTableContentView.prototype._resourceLoadingDidFail):
2868         (WI.NetworkTableContentView.prototype._networkTimelineRecordAdded):
2869         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
2870         (WI.NetworkTableContentView.prototype._hasTypeFilter):
2871         (WI.NetworkTableContentView.prototype._hasTextFilter):
2872         (WI.NetworkTableContentView.prototype._hasActiveFilter):
2873         (WI.NetworkTableContentView.prototype._passTypeFilter):
2874         (WI.NetworkTableContentView.prototype._passTextFilter):
2875         (WI.NetworkTableContentView.prototype._passFilter):
2876         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
2877         (WI.NetworkTableContentView.prototype._resetFilters):
2878         (WI.NetworkTableContentView.prototype._textFilterDidChange):
2879         (WI.NetworkTableContentView.prototype._tableNameColumnDidChangeWidth):
2880         There are now two filters.
2881
2882           - FilterBar - Filters URL and Full Text Content
2883           - ScopeBar  - Filters Resource Type
2884
2885         The text content filter is asynchronous. We reuse the existing Search
2886         functionality when filtering on text. We need to defer text content
2887         filtering until the resource finishes loading.
2888
2889 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2890
2891         Web Inspector: Network Tab: Row wrapping (waterfall displaying behind next row's name)
2892         https://bugs.webkit.org/show_bug.cgi?id=178015
2893         <rdar://problem/34858720>
2894
2895         Reviewed by Brian Burg.
2896
2897         * UserInterface/Views/Table.css:
2898         (.table > .header):
2899         (.table > .data-container > .data-list > li):
2900         Disallow wrapping.
2901
2902 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2903
2904         Web Inspector: Network Tab - Cookies Detail View
2905         https://bugs.webkit.org/show_bug.cgi?id=177988
2906         <rdar://problem/34071927>
2907
2908         Reviewed by Brian Burg.
2909
2910         * Localizations/en.lproj/localizedStrings.js:
2911         * UserInterface/Main.html:
2912         * UserInterface/Test.html:
2913         New strings and resources.
2914
2915         * UserInterface/Models/Cookie.js: Added.
2916         (WI.Cookie):
2917         (WI.Cookie.parseCookieRequestHeader):
2918         (WI.Cookie.parseSetCookieResponseHeader):
2919         Encapsulation for Cookie attributes.
2920
2921         * UserInterface/Models/Resource.js:
2922         (WI.Resource.prototype.get requestCookies):
2923         (WI.Resource.prototype.get responseCookies):
2924         (WI.Resource.prototype.updateForRedirectResponse):
2925         (WI.Resource.prototype.updateForResponse):
2926         (WI.Resource.prototype.updateWithMetrics):
2927         New computed accessors for requestCookies and responseCookies.
2928
2929         * UserInterface/Views/NetworkResourceDetailView.js:
2930         (WI.NetworkResourceDetailView.prototype._showContentViewForNavigationItem):
2931         Show the new Cookie View.
2932
2933         * UserInterface/Views/NetworkTableContentView.css:
2934         (.content-view.network .network-table .icon):
2935         (.network-table li:not(.filler) .cell.name):
2936         (.network-table .cache-type):
2937         (.network-table .error):
2938         (body[dir=ltr] .network-table .cell.name > .status):
2939         (body[dir=rtl] .network-table .cell.name > .status):
2940         (.network-table .cell.name > .status .indeterminate-progress-spinner):
2941         (.showing-detail .network-table .cell:not(.name)):
2942         (.showing-detail .network-table .resizer:not(:first-of-type)):
2943         (.network-table :not(.header) .cell:first-of-type):
2944         Rework these styles to be specific to the .network-table.
2945
2946         * UserInterface/Views/Table.css:
2947         (.table :not(.header) .cell:first-of-type): Deleted.
2948         Move this to the network table styles, it shouldn't apply to all tables. 
2949
2950         * UserInterface/Views/ResourceCookiesContentView.css:
2951         (.resource-cookies > section > .details.has-table):
2952         (.resource-cookies .table):
2953         (.resource-cookies .table > .header):
2954         Styles for Cookies view and table.
2955
2956         * UserInterface/Views/ResourceCookiesContentView.js: Added.
2957         (WI.ResourceCookiesContentView):
2958         (WI.ResourceCookiesContentView.prototype.tableNumberOfRows):
2959         (WI.ResourceCookiesContentView.prototype.tableSortChanged):
2960         (WI.ResourceCookiesContentView.prototype.tablePopulateCell):
2961         (WI.ResourceCookiesContentView.prototype.initialLayout):
2962         (WI.ResourceCookiesContentView.prototype._incompleteSectionWithMessage):
2963         (WI.ResourceCookiesContentView.prototype._incompleteSectionWithLoadingIndicator):
2964         (WI.ResourceCookiesContentView.prototype._dataSourceForTable):
2965         (WI.ResourceCookiesContentView.prototype._generateSortComparator):
2966         (WI.ResourceCookiesContentView.prototype._refreshRequestCookiesSection):
2967         (WI.ResourceCookiesContentView.prototype._refreshResponseCookiesSection):
2968         (WI.ResourceCookiesContentView.prototype._sizeForTable):
2969         (WI.ResourceCookiesContentView.prototype._resourceRequestHeadersDidChange):
2970         (WI.ResourceCookiesContentView.prototype._resourceResponseReceived):
2971         Tables for Request and Response cookies. They are simliar with slightly different columns.
2972         Handle simple display and sorting for the tables.
2973
2974         * UserInterface/Views/ResourceHeadersContentView.js:
2975         (WI.ResourceHeadersContentView.prototype._refreshResponseHeadersSection):
2976         Break out Set-Cookie headers as multiple headers. THey should never be combined.
2977
2978         * UserInterface/Views/Table.js:
2979         (WI.Table.prototype.showColumn):
2980         (WI.Table.prototype.hideColumn):
2981         (WI.Table.prototype._handleHeaderContextMenu):
2982         * UserInterface/Views/TableColumn.js:
2983         (WI.TableColumn.prototype.get hideable):
2984         (WI.TableColumn.prototype.set hidden):
2985         (WI.TableColumn):
2986         (WI.TableColumn.prototype.setHidden): Deleted.
2987         Make it so some columns can not be hidden. For example the "value" column
2988         in the Cookie tables.
2989
2990 2017-10-09  Joseph Pecoraro  <pecoraro@apple.com>
2991
2992         Web Inspector: Network Tab - Search Headers Detail View
2993         https://bugs.webkit.org/show_bug.cgi?id=177981
2994
2995         Reviewed by Brian Burg.
2996
2997         * UserInterface/Base/Main.js:
2998         * UserInterface/Views/LogContentView.js:
2999         (WI.LogContentView.prototype.performSearch):
3000         Rename "Dom" to "DOM" in utility function.
3001
3002         * UserInterface/Views/ResourceHeadersContentView.css:
3003         (.resource-headers.showing-find-banner .search-highlight):
3004         Search highlight styles.
3005
3006         * UserInterface/Views/ResourceHeadersContentView.js:
3007         (WI.ResourceHeadersContentView.prototype.get supportsSearch):
3008         (WI.ResourceHeadersContentView.prototype.get numberOfSearchResults):
3009         (WI.ResourceHeadersContentView.prototype.get hasPerformedSearch):
3010         (WI.ResourceHeadersContentView.prototype.set automaticallyRevealFirstSearchResult):
3011         (WI.ResourceHeadersContentView.prototype.performSearch):
3012         (WI.ResourceHeadersContentView.prototype.searchCleared):
3013         (WI.ResourceHeadersContentView.prototype.revealPreviousSearchResult):
3014         (WI.ResourceHeadersContentView.prototype.revealNextSearchResult):
3015         (WI.ResourceHeadersContentView.prototype._perfomSearchOnKeyValuePairs):
3016         (WI.ResourceHeadersContentView.prototype._revealSearchResult):
3017         Implement ContentView search behavior.
3018
3019 2017-10-08  Devin Rousso  <webkit@devinrousso.com>
3020
3021         Web Inspector: add autocompletion for min/max within a CSS calc
3022         https://bugs.webkit.org/show_bug.cgi?id=178068
3023
3024         Reviewed by Joseph Pecoraro.
3025
3026         * UserInterface/Models/CSSKeywordCompletions.js:
3027         (WI.CSSKeywordCompletions.forFunction):
3028
3029 2017-10-06  Matt Baker  <mattbaker@apple.com>
3030
3031         Web Inspector: Add Canvas tab and CanvasOverviewContentView
3032         https://bugs.webkit.org/show_bug.cgi?id=177604
3033         <rdar://problem/34714650>
3034
3035         Reviewed by Devin Rousso.
3036
3037         This patch adds experimental feature support for the Canvas tab. Initially
3038         the tab provides only an overview of the canvases in the page, and will
3039         exist side-by-side with the existing experimental Canvas UI.
3040
3041         * Localizations/en.lproj/localizedStrings.js:
3042         * UserInterface/Base/Main.js:
3043         (WI.contentLoaded):
3044         * UserInterface/Base/Setting.js:
3045
3046         * UserInterface/Images/Canvas.svg: Added.
3047         * UserInterface/Images/CanvasOverview.svg: Added.
3048         * UserInterface/Main.html:
3049         Add new art and canvas UI classes.
3050
3051         * UserInterface/Models/Canvas.js:
3052         (WI.Canvas.requestNode):
3053         (WI.Canvas.prototype.requestContent):
3054         (WI.Canvas.prototype.requestCSSCanvasClientNodes):
3055         (WI.Canvas.prototype.requestSize.calculateSize.getAttributeValue):
3056         (WI.Canvas.prototype.requestSize.calculateSize):
3057         (WI.Canvas.prototype.requestSize.getPropertyValue):
3058         (WI.Canvas.prototype.requestSize):
3059         Use promises to retrieve canvas data asynchronously.
3060
3061         * UserInterface/Models/CollectionTypes.js: Added.
3062         (WI.CanvasCollection):
3063         New location for concrete collection types. Having a class to type check
3064         makes using a collection as a represented object a bit simpler.
3065
3066         * UserInterface/Views/CanvasContentView.css:
3067         (.content-view.canvas:not(.tab)):
3068         (.content-view.canvas:not(.tab) > .preview):
3069         (.content-view.canvas:not(.tab) > .preview > img):
3070         (.content-view.canvas:not(.tab) > :matches(header, footer)):
3071         (.content-view.canvas): Deleted.
3072         (.content-view.canvas > .preview): Deleted.
3073         (.content-view.canvas > .preview > img): Deleted.
3074         During the transition to the new Canvas tab, CanvasContentView needs to
3075         support being shown as a full-size content view, and as an item in a
3076         CollectionContentView. Hide header and footer elements by default.
3077
3078         * UserInterface/Views/CanvasContentView.js:
3079         (WI.CanvasContentView):
3080         (WI.CanvasContentView.prototype.refresh):
3081         (WI.CanvasContentView.prototype.initialLayout):
3082         (WI.CanvasContentView.prototype.layout):
3083         (WI.CanvasContentView.prototype.shown):
3084         (WI.CanvasContentView.prototype.attached):
3085         (WI.CanvasContentView.prototype.detached):
3086         (WI.CanvasContentView.prototype._showError):
3087         (WI.CanvasContentView.prototype._refreshPixelSize):
3088         (WI.CanvasContentView.prototype._showGridButtonClicked):
3089         (WI.CanvasContentView.prototype._updateImageGrid):
3090         (WI.CanvasContentView.prototype._updateMemoryCost):
3091         (WI.CanvasContentView.prototype._updatePixelSize):
3092         (WI.CanvasContentView.prototype._updateRecordNavigationItem):
3093         (WI.CanvasContentView.prototype.hidden): Deleted.
3094         (WI.CanvasContentView.prototype.closed): Deleted.
3095         (WI.CanvasContentView.prototype._showPreview): Deleted.
3096         Added new UI for display in the Canvas overview. These elements are always
3097         created, but only appear when the canvas is viewed as a "card".
3098
3099         Canvas previews are no longer shown as soon as they are available from
3100         the backend. Instead, once the canvas content is ready a layout is scheduled.
3101         This guarantees that refreshing all canvases at once causes no flicker,
3102         and introduces no perceptible delay.
3103
3104         Finally, the "Cancel recording" tooltip has been renamed "Stop recording",
3105         to match the behavior of the command.
3106
3107         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
3108         (WI.CanvasDetailsSidebarPanel.prototype._refreshSourceSection.this._canvas.requestNode.): Deleted.
3109         Canvas.prototype.requestNode now returns a promise.
3110
3111         * UserInterface/Views/CanvasOverviewContentView.css: Added.
3112         (.content-view.canvas-overview):
3113         (.content-view.canvas-overview .content-view.canvas):
3114         (.content-view.canvas-overview .content-view.canvas.selected:not(.is-recording)):
3115         (.content-view.canvas-overview .content-view.canvas > :matches(header, footer)):
3116         (.content-view.canvas-overview .content-view.canvas > header):
3117         (.content-view.canvas-overview .content-view.canvas.is-recording > header):
3118         (.content-view.canvas-overview .content-view.canvas > header > .titles,):
3119         (.content-view.canvas-overview .content-view.canvas > header > .titles > .title):
3120         (.content-view.canvas-overview .content-view.canvas > header > .titles > .subtitle,):
3121         (.content-view.canvas-overview .content-view.canvas > header .subtitle::before):
3122         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .titles > .title):
3123         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .titles > .subtitle):
3124         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .navigation-bar > .item):
3125         (.content-view.canvas-overview .content-view.canvas > header > .navigation-bar):
3126         (.content-view.canvas-overview .content-view.canvas:not(:hover, .is-recording) > header > .navigation-bar):
3127         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop.disabled):
3128         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop):
3129         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop:not(.disabled):hover):
3130         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop:not(.disabled):active):
3131         (.content-view.canvas-overview .content-view.canvas > .preview):
3132         (.content-view.canvas-overview .content-view.canvas > .preview > img):
3133         (.content-view.canvas-overview .content-view.canvas > .preview > .message-text-view):
3134         (.content-view.canvas-overview .content-view.canvas > footer):
3135         (.content-view.canvas-overview .content-view.canvas > footer .memory-cost):
3136         Add header, navigation bar, and footer styles to CanvasContentView when
3137         it is being shown as an item in a CollectionContentView.
3138
3139         * UserInterface/Views/CanvasOverviewContentView.js: Added.
3140         (WI.CanvasOverviewContentView):
3141         (WI.CanvasOverviewContentView.prototype.get navigationItems):
3142         (WI.CanvasOverviewContentView.prototype.get selectionPathComponents):
3143         (WI.CanvasOverviewContentView.prototype.hidden):
3144         (WI.CanvasOverviewContentView.prototype.contentViewAdded):
3145         (WI.CanvasOverviewContentView.prototype.contentViewRemoved):
3146         (WI.CanvasOverviewContentView.prototype.attached):
3147         (WI.CanvasOverviewContentView.prototype.detached):
3148         (WI.CanvasOverviewContentView.prototype._refreshPreviews):
3149         (WI.CanvasOverviewContentView.prototype._selectedPathComponentChanged):
3150         (WI.CanvasOverviewContentView.prototype._showGridButtonClicked):
3151         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange.createCanvasPathComponent):
3152         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange):
3153         (WI.CanvasOverviewContentView.prototype._updateNavigationItems):
3154         (WI.CanvasOverviewContentView.prototype._updateShowImageGrid):
3155         (WI.CanvasOverviewContentView.prototype._contentViewMouseEnter):
3156         (WI.CanvasOverviewContentView.prototype._contentViewMouseLeave):
3157         The overview extends CollectionContentView, adding buttons for global canvas actions
3158         (refresh all and show/hide grid for all), and maintains a non-visible
3159         outline of CanvasTreeElements to facilitate display of the hierarchical
3160         path in the navigation bar.
3161
3162         * UserInterface/Views/CanvasTabContentView.css: Added.
3163         (.content-view.tab.canvas .navigation-bar > .item > .hierarchical-path-component > .icon):
3164         (.content-view.tab.canvas .navigation-bar > .item > .canvas-overview > .icon):
3165         (.content-view.tab.canvas .navigation-bar > .item .canvas .icon):
3166
3167         * UserInterface/Views/CanvasTabContentView.js: Added.
3168         (WI.CanvasTabContentView):
3169         (WI.CanvasTabContentView.tabInfo):
3170         (WI.CanvasTabContentView.isTabAllowed):
3171         (WI.CanvasTabContentView.prototype.get type):
3172         (WI.CanvasTabContentView.prototype.get supportsSplitContentBrowser):
3173         (WI.CanvasTabContentView.prototype.canShowRepresentedObject):
3174         (WI.CanvasTabContentView.prototype.shown):
3175         (WI.CanvasTabContentView.prototype.treeElementForRepresentedObject):
3176         (WI.CanvasTabContentView.prototype.restoreFromCookie):
3177         (WI.CanvasTabContentView.prototype.saveStateToCookie):
3178         (WI.CanvasTabContentView.prototype.attached):
3179         (WI.CanvasTabContentView.prototype.detached):
3180         (WI.CanvasTabContentView.prototype._canvasAdded):
3181         (WI.CanvasTabContentView.prototype._canvasRemoved):
3182         (WI.CanvasTabContentView.prototype._overviewPathComponentClicked):
3183         (WI.CanvasTabContentView.prototype._mainResourceDidChange):
3184
3185         * UserInterface/Views/CollectionContentView.js:
3186         (WI.CollectionContentView):
3187         (WI.CollectionContentView.prototype.setSelectedItem):
3188         (WI.CollectionContentView.prototype.addContentViewForItem):
3189         (WI.CollectionContentView.prototype.removeContentViewForItem):
3190         (WI.CollectionContentView.prototype.initialLayout):
3191         (WI.CollectionContentView.prototype._showContentPlaceholder):
3192         (WI.CollectionContentView.prototype._hideContentPlaceholder):
3193         Placeholder content should be created lazily, and shown after a slight delay
3194         to give represented objects a chance to load. Make sure to call the
3195         shown or hidden method after adding or removing a content view.
3196
3197         * UserInterface/Views/SettingsTabContentView.js:
3198         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3199
3200         * UserInterface/Views/Variables.css:
3201         (:root):
3202         (body.window-inactive *):
3203
3204         * UserInterface/Views/View.js:
3205         (WI.View.fromElement):
3206
3207 2017-10-06  Joseph Pecoraro  <pecoraro@apple.com>
3208
3209         Web Inspector: Network Tab - Headers Detail View
3210         https://bugs.webkit.org/show_bug.cgi?id=177896
3211         <rdar://problem/34071924>
3212
3213         Reviewed by Devin Rousso.
3214
3215         * Localizations/en.lproj/localizedStrings.js:
3216         * UserInterface/Main.html:
3217         New resources and strings.
3218
3219         * UserInterface/Base/URLUtilities.js:
3220         (parseURL):
3221         (WI.h2Authority):
3222         (WI.h2Path):
3223         Utility methods to get the :authority and :path pseudo-headers from a URL.
3224         This required adding user info (user:pass@) support to URL parsing.
3225
3226         * UserInterface/Views/NetworkTabContentView.js:
3227         (WI.NetworkTabContentView):
3228         * UserInterface/Views/NetworkTableContentView.js:
3229         (WI.NetworkTableContentView.prototype.get navigationItems):
3230         (WI.NetworkTableContentView.prototype.get filterNavigationItems):
3231         Move the NetworkTab's filter controls to the left. Since these are not
3232         dynamic just vend them from the TableContentView and place them in the
3233         navigation bar.
3234
3235         * UserInterface/Models/Resource.js:
3236         (WI.Resource.prototype.updateWithMetrics):
3237         New event whenever metrics change. This is the first event that will allow
3238         a client to react to a resource.protocol change.
3239
3240         * UserInterface/Views/NetworkResourceDetailView.css:
3241         (.content-view.resource-details):
3242         Base styles for the sub detail views.
3243
3244         * UserInterface/Views/NetworkResourceDetailView.js:
3245         (WI.NetworkResourceDetailView):
3246         (WI.NetworkResourceDetailView.prototype.headersContentViewGoToRequestData):
3247         (WI.NetworkResourceDetailView.prototype.initialLayout):
3248         (WI.NetworkResourceDetailView.prototype._showPreferredContentView):
3249         (WI.NetworkResourceDetailView.prototype._showContentViewForNavigationItem):
3250         Create a Header view and provide a way to switch to a particular view. This wil
3251         be useful to jump from the Header's Request Data directly to the Preview's
3252         Request ContentView.
3253
3254         * UserInterface/Views/ResourceDetailsSection.css:
3255         (.resource-details > section):
3256         (.resource-details > section > .title):
3257         (.resource-details > section > .details):
3258         (.resource-details > section > .details > p):
3259         (.resource-details > section.incomplete > .details):
3260         * UserInterface/Views/ResourceDetailsSection.js:
3261         (WI.ResourceDetailsSection):
3262         (WI.ResourceDetailsSection.prototype.get element):
3263         (WI.ResourceDetailsSection.prototype.get titleElement):
3264         (WI.ResourceDetailsSection.prototype.get detailsElement):
3265         (WI.ResourceDetailsSection.prototype.toggleIncomplete):
3266         (WI.ResourceDetailsSection.prototype.toggleError):
3267         Simple sections with a title and details div with a border.
3268         It may be common to have an incomplete load / error so this
3269         provides some APIs and styles for sections marked incomplete
3270         or with errors.
3271
3272         * UserInterface/Views/ResourceHeadersContentView.css:
3273         (.resource-headers > section > .details):
3274         (.resource-headers > section.headers > .details):
3275         (.resource-headers > section.error > .details):
3276         (.resource-headers > section.error .key):
3277         Style the left border different colors for different sections or cases.
3278
3279         (.resource-headers .details):
3280         (.resource-headers .details .pair):
3281         (.resource-headers .details .key):
3282         (.resource-headers .value):
3283         (.resource-headers .header > .key):
3284         (.resource-headers .h1-status > .key):
3285         (.resource-headers .h2-pseudo-header > .key):
3286         Wrapped text for key/value pairs and different colors for different
3287         sections or cases.
3288
3289         (.resource-headers .go-to-arrow):
3290         Go-to arrow styles for a request data section.
3291
3292         * UserInterface/Views/ResourceHeadersContentView.js: Added.
3293         (WI.ResourceHeadersContentView):
3294         (WI.ResourceHeadersContentView.prototype.initialLayout):
3295         (WI.ResourceHeadersContentView.prototype.layout):
3296         (WI.ResourceHeadersContentView.prototype._incompleteSectionWithMessage):
3297         (WI.ResourceHeadersContentView.prototype._incompleteSectionWithLoadingIndicator):
3298         (WI.ResourceHeadersContentView.prototype._appendKeyValuePair):
3299         (WI.ResourceHeadersContentView.prototype._responseSourceDisplayString):
3300         (WI.ResourceHeadersContentView.prototype._refreshSummarySection):
3301         (WI.ResourceHeadersContentView.prototype._refreshRequestHeadersSection):
3302         (WI.ResourceHeadersContentView.prototype._refreshResponseHeadersSection):
3303         (WI.ResourceHeadersContentView.prototype._refreshQueryStringSection):
3304         (WI.ResourceHeadersContentView.prototype._refreshRequestDataSection):
3305         (WI.ResourceHeadersContentView.prototype._resourceMetricsDidChange):
3306         (WI.ResourceHeadersContentView.prototype._resourceRequestHeadersDidChange):
3307         (WI.ResourceHeadersContentView.prototype._resourceResponseReceived):
3308         (WI.ResourceHeadersContentView.prototype._goToRequestDataClicked):
3309         Summary, Request, Response, Query String, and Request Data sections.
3310         The sections refresh as data becomes available.
3311
3312         * UserInterface/Views/Table.css:
3313         (.table):
3314         These variables are already defined globally.
3315
3316         * UserInterface/Views/Variables.css:
3317         (:root):
3318         New variables for the colors we use. They closely match, and are
3319         sometimes identical to ones used in Timelines / Memory views.
3320
3321 2017-10-06  Joseph Pecoraro  <pecoraro@apple.com>
3322
3323         Web Inspector: Network Tab - Make selection in the table more reliable (mousedown instead of click)
3324        &nbs