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