Unreviewed build fix; fix WebInspectorUI copy resources step after r231063.
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2018-04-26  Jer Noble  <jer.noble@apple.com>
2
3         Unreviewed build fix; fix WebInspectorUI copy resources step after r231063.
4
5         * Configurations/Base.xcconfig:
6
7 2018-04-26  Jer Noble  <jer.noble@apple.com>
8
9         WK_COCOA_TOUCH all the things.
10         https://bugs.webkit.org/show_bug.cgi?id=185006
11
12         Reviewed by Tim Horton.
13
14         * Configurations/WebInspectorUIFramework.xcconfig:
15
16 2018-04-21  Nikita Vasilyev  <nvasilyev@apple.com>
17
18         REGRESSION(r214076): Web Inspector: Timelines load and DOMContentLoaded markers aren't visible
19         https://bugs.webkit.org/show_bug.cgi?id=184858
20
21         Reviewed by Brian Burg.
22
23         r214076 changed the color of all markers to light gray.
24
25         * UserInterface/Views/TimelineRuler.css:
26         (.timeline-ruler > .markers > .marker):
27         (body[dir=ltr] .timeline-ruler > .markers > .marker):
28         (body[dir=rtl] .timeline-ruler > .markers > .marker):
29         (.timeline-ruler > .markers > .marker.current-time):
30         (.timeline-ruler > .markers > .marker.load-event):
31         (.timeline-ruler > .markers > .marker.dom-content-event):
32         (.timeline-ruler > .markers > .marker.timestamp):
33         (body[dir=ltr] .timeline-ruler > .markers > .marker.current-time): Deleted.
34         (body[dir=rtl] .timeline-ruler > .markers > .marker.current-time): Deleted.
35
36 2018-04-19  Chris Dumez  <cdumez@apple.com>
37
38         Rename JSDOMWindowProxy to JSWindowProxy
39         https://bugs.webkit.org/show_bug.cgi?id=184797
40
41         Reviewed by Sam Weinig.
42
43         Rename JSDOMWindowProxy to JSWindowProxy for consistency with WindowProxy.
44
45         * UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:
46         (HeapSnapshot.prototype._isNodeGlobalObject):
47
48 2018-04-19  David Kilzer  <ddkilzer@apple.com>
49
50         Enable Objective-C weak references
51         <https://webkit.org/b/184789>
52         <rdar://problem/39571716>
53
54         Reviewed by Dan Bernstein.
55
56         * Configurations/Base.xcconfig:
57         (CLANG_ENABLE_OBJC_WEAK): Enable.
58
59 2018-04-16  Nikita Vasilyev  <nvasilyev@apple.com>
60
61         Web Inspector: Can't select and copy text from Network tab popover
62         https://bugs.webkit.org/show_bug.cgi?id=184606
63
64         Reviewed by Matt Baker.
65
66         * UserInterface/Views/ResourceTimingBreakdownView.css:
67         (.waterfall-popover .resource-timing-breakdown):
68
69 2018-04-12  Nikita Vasilyev  <nvasilyev@apple.com>
70
71         Web Inspector: Refactoring: move popover styles from JS to CSS
72         https://bugs.webkit.org/show_bug.cgi?id=184558
73
74         Reviewed by Brian Burg.
75
76         Introduce several CSS variables to customize popover appearance in CSS
77         and not JavaScript.
78
79         * UserInterface/Views/NetworkTableContentView.js:
80         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResource):
81         (WI.NetworkTableContentView.prototype._handleMousedownWaterfall):
82         * UserInterface/Views/Popover.css:
83         (.popover):
84         * UserInterface/Views/Popover.js:
85         (WI.Popover):
86         (WI.Popover.prototype._drawBackground):
87         Replace `var` with `let`.
88
89         (WI.Popover.prototype.get backgroundStyle): Deleted.
90         (WI.Popover.prototype.set backgroundStyle): Deleted.
91         * UserInterface/Views/ResourceTimingBreakdownView.css:
92         (.popover.waterfall-popover):
93         (.waterfall-popover-content .resource-timing-breakdown):
94         (.waterfall-popover .resource-timing-breakdown): Deleted.
95
96         * UserInterface/Views/NetworkTableContentView.js:
97         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResource):
98         (WI.NetworkTableContentView.prototype._handleMousedownWaterfall):
99         * UserInterface/Views/Popover.css:
100         (.popover):
101         * UserInterface/Views/Popover.js:
102         (WI.Popover):
103         (WI.Popover.prototype._drawBackground):
104         * UserInterface/Views/ResourceTimingBreakdownView.css:
105         (.popover.waterfall-popover):
106         (.waterfall-popover-content .resource-timing-breakdown):
107
108 2018-04-07  Nikita Vasilyev  <nvasilyev@apple.com>
109
110         Web Inspector: Errors glyph doesn't fully change to blue when active
111         https://bugs.webkit.org/show_bug.cgi?id=184389
112
113         Reviewed by Joseph Pecoraro.
114
115         The dot of the exclamation mark was always black.
116
117         * UserInterface/Images/Errors.svg:
118
119 2018-04-03  Aaron Chu  <aaron_chu@apple.com>
120
121         AX: Add Experimental setting for Accessibility Audit
122         https://bugs.webkit.org/show_bug.cgi?id=183646
123         <rdar://problem/38478583>
124
125         Reviewed by Brian Burg.
126
127         Added experimental feature flag for Accessibility Audit work.
128
129         * Localizations/en.lproj/localizedStrings.js:
130         * UserInterface/Base/Setting.js:
131         * UserInterface/Views/SettingsTabContentView.js:
132         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
133
134 2018-04-01  Matt Baker  <mattbaker@apple.com>
135
136         Web Inspector: Remove dead TabBrowser/TabContentView code
137         https://bugs.webkit.org/show_bug.cgi?id=184104
138
139         Reviewed by Devin Rousso.
140
141         * UserInterface/Base/Main.js:
142         (WI._tryToRestorePendingTabs):
143         * UserInterface/Views/NewTabContentView.js:
144         (WI.NewTabContentView.prototype.shown):
145         (WI.NewTabContentView.prototype.hidden):
146         * UserInterface/Views/TabBrowser.js:
147         (WI.TabBrowser.prototype.addTabForContentView):
148         (WI.TabBrowser.prototype.showTabForContentView):
149         (WI.TabBrowser._tabBarItemRemoved):
150         * UserInterface/Views/TabContentView.js:
151         (WI.TabContentView.prototype.get parentTabBrowser): Deleted.
152         (WI.TabContentView.prototype.set parentTabBrowser): Deleted.
153
154 2018-03-30  Devin Rousso  <webkit@devinrousso.com>
155
156         Web Inspector: tint all pixels drawn by shader program when hovering ShaderProgramTreeElement
157         https://bugs.webkit.org/show_bug.cgi?id=175223
158
159         Reviewed by Matt Baker.
160
161         * UserInterface/Models/ShaderProgram.js:
162         (WI.ShaderProgram):
163         (WI.ShaderProgram.prototype.showHighlight):
164         (WI.ShaderProgram.prototype.hideHighlight):
165
166         * UserInterface/Views/ShaderProgramTreeElement.js:
167         (WI.ShaderProgramTreeElement.prototype.onattach):
168         (WI.ShaderProgramTreeElement.prototype._handleMouseOver):
169         (WI.ShaderProgramTreeElement.prototype._handleMouseOut):
170         Whenever a ShaderProgramTreeElement is hovered, highlight the corresponding shader program
171         by tinting the pixels it draws via a blend.
172
173 2018-03-27  Timothy Hatcher  <timothy@apple.com>
174
175         Web Inspector: Modernize some utility functions
176         https://bugs.webkit.org/show_bug.cgi?id=184047
177
178         Reviewed by Matt Baker.
179
180         * UserInterface/Base/Utilities.js:
181         (Node.prototype.enclosingNodeOrSelfWithClass): Use parentElement instead of parentNode, so we don't need to check for document.
182         (Node.prototype.enclosingNodeOrSelfWithNodeNameInArray): Ditto. Also just toUpperCase input, since nodeName is already upper case.
183         (String.prototype.escapeCharacters): Use Set and string iteration instead of indexOf and charAt.
184
185 2018-03-27  Nikita Vasilyev  <nvasilyev@apple.com>
186
187         Web Inspector: Command-Shift-left/right arrow keys should not switch tabs when focused on color picker text fields
188         https://bugs.webkit.org/show_bug.cgi?id=184028
189
190         Reviewed by Timothy Hatcher.
191
192         * UserInterface/Views/EditingSupport.js:
193         (WI.isEventTargetAnEditableField):
194         Detect <input type="number"> as an editable text field.
195
196 2018-03-23  Nikita Vasilyev  <nvasilyev@apple.com>
197
198         Web Inspector: Styles: don't show checkboxes for invalid properties
199         https://bugs.webkit.org/show_bug.cgi?id=183951
200         <rdar://problem/38807602>
201
202         Reviewed by Matt Baker.
203
204         Since toggling of invalid properties isn't supported by the backend, don't show checkboxes for invalid properties.
205
206         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
207         (.spreadsheet-css-declaration:matches(:hover, :focus) .property:not(:matches(.invalid-name, .invalid-value)) .property-toggle,):
208         (.spreadsheet-css-declaration:matches(:hover, :focus) .property-toggle,): Deleted.
209         Don't show checkboxes for invalid properties but still show them for duplicate properties.
210
211 2018-03-23  Brian Burg  <bburg@apple.com>
212
213         Web Inspector: add WebKitAdditions hooks for WebInspectorUI
214         https://bugs.webkit.org/show_bug.cgi?id=183940
215         <rdar://problem/38796310>
216
217         Reviewed by Timothy Hatcher.
218
219         * Scripts/combine-resources.pl:
220         (debugLog): Added. Leave in the logging I used to debug this.
221
222         (concatenateIncludedFilesMatchingPattern):
223         (stripIncludedFilesMatchingPattern):
224         (concatenateFiles): Deleted.
225         This function tried to do too many things. Split it into
226         two functions, one for stripping includes and one for concatenating
227         files referenced by includes.
228
229         Lastly, add a negative lookahead clause for 'WebKitAdditions' so includes
230         containing that string are not combined when no input directory is passed
231         to the script.
232
233         * Scripts/copy-user-interface-resources.pl:
234         WebKitAdditions is computed either from BUILT_PRODUCTS_DIR or SDKROOT,
235         depending on the build style. Just try them in order and use the first
236         one that exists. WebInspectorUI files are in their own directory, so
237         we can assume there are files to process if that directory exists.
238
239         Copy Main.html to derived sources before doing any processing on it.
240         This makes all combining phases have the same --input-html argument.
241
242         (debugLog): Added. Leave in the logging I used to debug this.
243
244         (combineOrStripResourcesForWebKitAdditions):
245         (stripResourcesForWebKitAdditions):
246         (combineResourcesForWebKitAdditions):
247         Determine if WebKitAdditions exists and whether there are any
248         resources for WebInspectorUI present that need to be processed.
249
250         * UserInterface/Main.html:
251         Add stub .js and .css WebKitAdditions files. We can add more later
252         if it makes sense but this is good enough to validate the build machinery.
253
254 2018-03-23  Nikita Vasilyev  <nvasilyev@apple.com>
255
256         Web Inspector: Styles Redesign: flashing when switching between nodes
257         https://bugs.webkit.org/show_bug.cgi?id=179291
258         <rdar://problem/35352660>
259
260         Reviewed by Matt Baker.
261
262         Flashing was happening because the layout was a two-step process:
263         1. Append empty sections.
264         2. Layout everything inside of the section on requestAnimationFrame.
265
266         SpreadsheetRulesStyleDetailsPanel was converted to use layout method,
267         so both steps happen on requestAnimationFrame.
268
269         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
270         (WI.SpreadsheetRulesStyleDetailsPanel):
271         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.refresh):
272         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.layout):
273         The removed lines from the refresh method moved to the layout method without any changes.
274
275 2018-03-22  Nikita Vasilyev  <nvasilyev@apple.com>
276
277         Uncaught Exception: TypeError: this._textEditor.toggleUnexecutedCodeHighlights().then is not a function
278         https://bugs.webkit.org/show_bug.cgi?id=181912
279         <rdar://problem/36700022>
280
281         Reviewed by Matt Baker.
282
283         The uncaught exception was caused by returning `false` instead of a promise object.
284         This patch only fixes the exception. Further enhancements should be done in <https://webkit.org/b/183887>.
285
286         * UserInterface/Views/SourceCodeTextEditor.js:
287         (WI.SourceCodeTextEditor.prototype.toggleTypeAnnotations):
288         (WI.SourceCodeTextEditor.prototype.toggleUnexecutedCodeHighlights):
289
290 2018-03-20  Nikita Vasilyev  <nvasilyev@apple.com>
291
292         Web Inspector: Styles: Loses focus when editing a property while page is being loaded
293         https://bugs.webkit.org/show_bug.cgi?id=182619
294         <rdar://problem/37363185>
295
296         Reviewed by Matt Baker.
297
298         Adding or removing a stylesheet causes SpreadsheetRulesStyleDetailsPanel to refresh, triggering a layout
299         of all SpreadsheetCSSStyleDeclarationSection child views. This resets the focus, selection, and
300         auto-completion state.
301
302         This patch prevents SpreadsheetCSSStyleDeclarationSection from performing a layout when a property is being edited.
303
304         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
305         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
306         Allow re-layout after creating a blank CSS property and pasting CSS code.
307         - _pendingAddBlankPropertyIndexOffset is a number after pasting CSS rules.
308         - _propertyPendingStartEditing is a property model after creating a new property.
309
310 2018-03-20  Devin Rousso  <webkit@devinrousso.com>
311
312         Web Inspector: Session dividers are not added when Console tab is not visible
313         https://bugs.webkit.org/show_bug.cgi?id=168622
314
315         Reviewed by Matt Baker.
316
317         Restructure `_pendingMessages` to be a `Map [ConsoleSession, ConsoleMessageView]`. Instead
318         of rendering to the `_currentConsoleGroup`, we now render to the saved `ConsoleSession`.
319         Also ensure that `_pendingMessages` is cleared when navigating and "Preserve Log" is off.
320
321         * UserInterface/Controllers/JavaScriptLogViewController.js:
322         (WI.JavaScriptLogViewController):
323         (WI.JavaScriptLogViewController.prototype.startNewSession):
324         (WI.JavaScriptLogViewController.prototype.consolePromptHistoryDidChange):
325         (WI.JavaScriptLogViewController.prototype._appendConsoleMessageView):
326         (WI.JavaScriptLogViewController.prototype.renderPendingMessages):
327         (WI.JavaScriptLogViewController.prototype.get prompt): Deleted.
328         (WI.JavaScriptLogViewController.prototype.get currentConsoleGroup): Deleted.
329
330 2018-03-20  Nikita Vasilyev  <nvasilyev@apple.com>
331
332         Web Inspector: Can't add a new class by editing class attribute in DOM outline
333         https://bugs.webkit.org/show_bug.cgi?id=180890
334
335         Reviewed by Ryosuke Niwa.
336
337         Typing "my-foo my-bar" creates a single "my-foo\xA0my-bar" class name because
338         contentEditable-based attribute editor sometimes inserts non-breaking space characters (\xA0).
339
340         Replace all non-breaking space characters with the regular space characters when
341         commiting attribute change.
342
343         * UserInterface/Views/DOMTreeElement.js:
344
345 2018-03-16  Nikita Vasilyev  <nvasilyev@apple.com>
346
347         Web Inspector: Elements: "Force Print Media Styles" should not persist across Web Inspector sessions
348         https://bugs.webkit.org/show_bug.cgi?id=183708
349         <rdar://problem/36452183>
350
351         Reviewed by Matt Baker.
352
353         * UserInterface/Base/Main.js:
354         (WI.loaded):
355         * UserInterface/Views/DOMTreeContentView.js:
356         (WI.DOMTreeContentView):
357         (WI.DOMTreeContentView.prototype._showPrintStylesChanged):
358         (WI.DOMTreeContentView.prototype._togglePrintStyles):
359         (WI.DOMTreeContentView.prototype._showPrintStylesSettingChanged): Deleted.
360         (WI.DOMTreeContentView.prototype._togglePrintStylesSetting): Deleted.
361
362 2018-03-14  Devin Rousso  <webkit@devinrousso.com>
363
364         Web Inspector: Canvas: a recording initiated by the user should be shown immediately on completion
365         https://bugs.webkit.org/show_bug.cgi?id=183647
366         <rdar://problem/38479187>
367
368         Reviewed by Matt Baker.
369
370         When recordings are initiated via `console.record`, we don't want to automatically show the
371         recording after it's payload is sent to the frontend. We determine whether a recording came
372         from the console by comparing the recording's associated canvas with the current value of
373         `_recordingCanvas`. Previously, when stopping a recording, we would always null the value,
374         which meant that all non-single-frame recordings (single-frame recordings are stopped by
375         the agent after the first paint or tick after an action is performed) would be categorized
376         as coming from the console, since `_recordingCanvas` would be null by the time the frontend
377         recieved the payload.
378
379         This patch changes it so that the nulling of `_recordingCanvas` in `stopRecording` is only
380         done if the agent command errors. It was already the case that `_recordingCanvas` was nulled
381         in `stopRecording`, so this patch just prevents it from being nulled too early.
382
383         * UserInterface/Controllers/CanvasManager.js:
384         (WI.CanvasManager.prototype.stopRecording):
385
386 2018-03-12  Jon Davis  <jond@apple.com>
387
388         Web Inspector: Remove redundant tooltips
389         https://bugs.webkit.org/show_bug.cgi?id=183099
390
391         Reviewed by Matt Baker.
392
393         * Localizations/en.lproj/localizedStrings.js:
394         * UserInterface/Base/Main.js:
395         (WI.contentLoaded):
396         Instantiate ConsoleDrawer so the keyboard shortcuts for FindBanner are available.
397
398         * UserInterface/Views/BreakpointTreeElement.js:
399         (WI.BreakpointTreeElement):
400         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
401
402         * UserInterface/Views/ButtonNavigationItem.js:
403         (WI.ButtonNavigationItem):
404         Only show tooltips when the button style is an image.
405
406         * UserInterface/Views/ConsoleDrawer.js:
407         (WI.ConsoleDrawer):
408         (WI.ConsoleDrawer.prototype.toggleButtonShortcutTooltip):
409         Added helper to set the toggle button keyboard shortcut tooltip.
410
411         * UserInterface/Views/DOMBreakpointTreeElement.js:
412         (WI.DOMBreakpointTreeElement):
413         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
414
415         * UserInterface/Views/DOMNodeTreeElement.js:
416         (WI.DOMNodeTreeElement):
417         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
418
419         * UserInterface/Views/FindBanner.js:
420         (WI.FindBanner):
421         * UserInterface/Views/HierarchicalPathComponent.js:
422         (WI.HierarchicalPathComponent):
423         (WI.HierarchicalPathComponent.prototype.get tooltip):
424         (WI.HierarchicalPathComponent.prototype.set tooltip):
425         (WI.HierarchicalPathComponent.prototype.get hideTooltip):
426         (WI.HierarchicalPathComponent.prototype.set hideTooltip):
427         (WI.HierarchicalPathComponent.prototype._updateElementTitleAndText):
428         Add tooltip management features to manage tooltips separately of the displayName,
429         and provide a behavior to hide tooltips while retaining the tooltip data.
430
431         * UserInterface/Views/HierarchicalPathNavigationItem.js:
432         (WI.HierarchicalPathNavigationItem.prototype.updateLayout):
433         Hide tooltips when fully visible, show tooltips for collapsed items.
434
435         * UserInterface/Views/PinnedTabBarItem.js:
436         (WI.PinnedTabBarItem.prototype.titleDidChange):
437         Set tooltips for pinned tab bar items.
438
439         * UserInterface/Views/QuickConsole.js:
440         (WI.QuickConsole):
441         Set the ConsoleDrawer toggle button tooltip after the keyboard shortcut is registered.
442
443         * UserInterface/Views/StorageTreeElement.js:
444         (WI.StorageTreeElement):
445         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
446
447         * UserInterface/Views/TabBarItem.js:
448         (WI.TabBarItem.prototype.get title):
449         (WI.TabBarItem.prototype.set title):
450         (WI.TabBarItem.prototype.titleDidChange):
451         (WI.TabBarItem):
452         Add title property management with an overridable titleDidChange handler for
453         setting tooltips when needed.
454
455         * UserInterface/Views/TimelineTreeElement.js:
456         (WI.TimelineTreeElement):
457         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
458
459         * UserInterface/Views/ToggleButtonNavigationItem.js:
460         (WI.ToggleButtonNavigationItem.prototype.set defaultToolTip):
461         Added a setter for manging the default tooltip of a toggle button.
462
463         * UserInterface/Views/XHRBreakpointTreeElement.js:
464         (WI.XHRBreakpointTreeElement):
465         Suppress tooltips by setting the tooltipHandledSeprately flag with no custom handler.
466
467 2018-03-09  Nikita Vasilyev  <nvasilyev@apple.com>
468
469         Web Inspector: Sources: Open all resources in Sources tab instead of Resources/Debugger
470         https://bugs.webkit.org/show_bug.cgi?id=183317
471         <rdar://problem/38108455>
472
473         Reviewed by Matt Baker.
474
475         * Localizations/en.lproj/localizedStrings.js:
476         * UserInterface/Base/Main.js:
477         * UserInterface/Views/ContextMenuUtilities.js:
478         (WI.appendContextMenuItemsForURL):
479         Introduce preferredTabType option instead of listing ignoreResourcesTab, ignoreDebuggerTab, ignoreSearchTab, and ignoreNetworkTab.
480         The only correct outcome of selecting "Reveal in Sources Tab" context menu is to open Sources tab, not any other tab.
481
482         * UserInterface/Views/SourceCodeTextEditor.js:
483         (WI.SourceCodeTextEditor.prototype.textEditorGutterContextMenu):
484         * UserInterface/Views/TabBrowser.js:
485         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
486
487 2018-03-08  Nikita Vasilyev  <nvasilyev@apple.com>
488
489         Web Inspector: Sources: add SourcesTabContentView and SourceSidebarPanel classes
490         https://bugs.webkit.org/show_bug.cgi?id=183316
491         <rdar://problem/38107639>
492
493         Reviewed by Matt Baker.
494
495         Add Sources tab and sidebar panel, which are copies of the corresponding Resources classes.
496         The Sources tab is shown when it's enabled in the experimental settings. This patch doesn't
497         remove existing Resources and Debugger tabs.
498
499         * UserInterface/Base/Main.js:
500         (WI.contentLoaded):
501         * UserInterface/Main.html:
502         * UserInterface/Views/SourcesSidebarPanel.css: Added.
503         (.sidebar > .panel.navigation.sources > .content):
504         (.sidebar > .panel.navigation.sources > .navigation-bar):
505         * UserInterface/Views/SourcesSidebarPanel.js: Added.
506         (WI.SourcesSidebarPanel):
507         (WI.SourcesSidebarPanel.shouldPlaceResourcesAtTopLevel):
508         (WI.SourcesSidebarPanel.prototype.get minimumWidth):
509         (WI.SourcesSidebarPanel.prototype.closed):
510         (WI.SourcesSidebarPanel.prototype.showDefaultContentView):
511         (WI.SourcesSidebarPanel.prototype.treeElementForRepresentedObject.isAncestor):
512         (WI.SourcesSidebarPanel.prototype.treeElementForRepresentedObject.getParent):
513         (WI.SourcesSidebarPanel.prototype.treeElementForRepresentedObject):
514         (WI.SourcesSidebarPanel.prototype.initialLayout):
515         (WI.SourcesSidebarPanel.prototype.hasCustomFilters):
516         (WI.SourcesSidebarPanel.prototype.matchTreeElementAgainstCustomFilters.match):
517         (WI.SourcesSidebarPanel.prototype.matchTreeElementAgainstCustomFilters):
518         (WI.SourcesSidebarPanel.prototype._mainResourceDidChange):
519         (WI.SourcesSidebarPanel.prototype._mainFrameDidChange):
520         (WI.SourcesSidebarPanel.prototype._mainFrameMainResourceDidChange.delayedWork):
521         (WI.SourcesSidebarPanel.prototype._mainFrameMainResourceDidChange):
522         (WI.SourcesSidebarPanel.prototype._scriptWasAdded):
523         (WI.SourcesSidebarPanel.prototype._addScript):
524         (WI.SourcesSidebarPanel.prototype._scriptWasRemoved):
525         (WI.SourcesSidebarPanel.prototype._scriptsCleared):
526         (WI.SourcesSidebarPanel.prototype._styleSheetAdded):
527         (WI.SourcesSidebarPanel.prototype._addTargetWithMainResource):
528         (WI.SourcesSidebarPanel.prototype._targetRemoved):
529         (WI.SourcesSidebarPanel.prototype._treeSelectionDidChange):
530         (WI.SourcesSidebarPanel.prototype._compareTreeElements):
531         (WI.SourcesSidebarPanel.prototype._extraDomainsActivated):
532         (WI.SourcesSidebarPanel.prototype._scopeBarSelectionDidChange):
533         * UserInterface/Views/SourcesTabContentView.js: Added.
534         (WI.SourcesTabContentView):
535         (WI.SourcesTabContentView.tabInfo):
536         (WI.SourcesTabContentView.isTabAllowed):
537         (WI.SourcesTabContentView.prototype.get type):
538         (WI.SourcesTabContentView.prototype.get supportsSplitContentBrowser):
539         (WI.SourcesTabContentView.prototype.canShowRepresentedObject):
540
541 2018-03-07  Devin Rousso  <webkit@devinrousso.com>
542
543         Web Inspector: Canvas tab: ensure that the Recording TreeOutline has a specified height for virtualization
544         https://bugs.webkit.org/show_bug.cgi?id=183015
545
546         Reviewed by Matt Baker.
547
548         * UserInterface/Views/CanvasSidebarPanel.js:
549         (WI.CanvasSidebarPanel):
550
551         * UserInterface/Views/CanvasSidebarPanel.css:
552         (.sidebar > .panel.navigation.canvas > .content):
553         (.sidebar > .panel.navigation.canvas > .content > .navigation-bar):
554         (.sidebar > .panel.navigation.canvas.has-recordings > .content > .recording-content):
555         (.sidebar > .panel.navigation.canvas:not(.has-recordings) > .filter-bar,):
556         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .navigation-bar): Deleted.
557         (.sidebar > .panel.navigation.canvas.has-recordings > .content > .tree-outline.canvas): Deleted.
558
559         * UserInterface/Views/TreeElement.js:
560         (WI.TreeElement.prototype._detach):
561
562 2018-02-26  Devin Rousso  <webkit@devinrousso.com>
563
564         Web Inspector: Canvas Tab: Scroll into view / Inspect element if Canvas has DOM node
565         https://bugs.webkit.org/show_bug.cgi?id=181769
566
567         Reviewed by Matt Baker.
568
569         * Localizations/en.lproj/localizedStrings.js:
570
571         * UserInterface/Images/Markup.svg: Added.
572
573         * UserInterface/Views/CanvasContentView.js:
574         (WI.CanvasContentView):
575         (WI.CanvasContentView.prototype.initialLayout):
576         (WI.CanvasContentView.prototype._canvasElementButtonClicked):
577
578 2018-02-19  Matt Baker  <mattbaker@apple.com>
579
580         Web Inspector: Canvas tab: hide navigation sidebar when viewing the overview
581         https://bugs.webkit.org/show_bug.cgi?id=182597
582         <rdar://problem/37341564>
583
584         Reviewed by Devin Rousso.
585
586         Support showing/hiding the navigation sidebar panel based on the current
587         represented object. Individual TabContentViews can opt-in to this behavior,
588         by overriding TabContentView.prototype.managesNavigationSidebarPanel.
589
590         * UserInterface/Views/CanvasSidebarPanel.js:
591         (WI.CanvasSidebarPanel.prototype.canShowRepresentedObject):
592         * UserInterface/Views/CanvasTabContentView.js:
593         (WI.CanvasTabContentView.prototype.get managesNavigationSidebarPanel):
594         Hide the Canvas navigation sidebar when viewing the overview.
595
596         * UserInterface/Views/ContentBrowserTabContentView.js:
597         (WI.ContentBrowserTabContentView):
598         (WI.ContentBrowserTabContentView.prototype.showNavigationSidebarPanel):
599         (WI.ContentBrowserTabContentView.prototype._navigationSidebarCollapsedStateDidChange):
600         (WI.ContentBrowserTabContentView.prototype._contentBrowserCurrentRepresentedObjectsDidChange):
601
602         * UserInterface/Views/NavigationSidebarPanel.js:
603         (WI.NavigationSidebarPanel.prototype.canShowRepresentedObject):
604         Provide default implementation that just defers to the TabContentView.
605         This exists so that a NavigationSidebarPanel that implements canShowRepresentedObject
606         will have a meaningful default to fall back on.
607
608         * UserInterface/Views/TabBrowser.js:
609         (WI.TabBrowser.prototype._sidebarCollapsedStateDidChange):
610         (WI.TabBrowser.prototype._showNavigationSidebarPanelForTabContentView):
611
612         * UserInterface/Views/TabContentView.js:
613         (WI.TabContentView.prototype.get managesNavigationSidebarPanel):
614
615 2018-02-16  Matt Baker  <mattbaker@apple.com>
616
617         Web Inspector: TabBar redesign: remove top-level search field and pin the Search tab
618         https://bugs.webkit.org/show_bug.cgi?id=182353
619         <rdar://problem/37088644>
620
621         Reviewed by Devin Rousso.
622
623         * Localizations/en.lproj/localizedStrings.js:
624
625         * UserInterface/Base/Main.js:
626         (WI.contentLoaded):
627         Create Search UI based on experimental setting. When the new TabBar is
628         enabled, the Search tab is a pinned tab. Since it is also saveable, it
629         needs to be added to the TabBrowser (the browser adds the item to the bar).
630
631         When restoring saved tabs, make an additional check to prevent a tab
632         from being added twice. This can occur now that the Search tab is pinned.
633
634         * UserInterface/Images/Search.svg:
635         Update art to better match Safari/macOS. Slightly increase the radius of
636         the lens, and shorten the length of the handle.
637
638         * UserInterface/Views/GoToLineDialog.css:
639         (.go-to-line-dialog > div::before):
640         Update styles for new Search icon.
641
642         * UserInterface/Views/LegacyTabBar.js:
643         (WI.LegacyTabBar.prototype.get saveableTabCount):
644         Backported new TabBar method which is called by TabBrowser.
645
646         * UserInterface/Views/OpenResourceDialog.css:
647         (.open-resource-dialog > .field::before):
648         Update styles for new Search icon.
649
650         * UserInterface/Views/PinnedTabBarItem.js:
651         (WI.PinnedTabBarItem.prototype.fromTabInfo):
652         Match GeneralTabBarItem.fromTabInfo.
653
654         * UserInterface/Views/SearchTabContentView.js:
655         (WI.SearchTabContentView):
656         (WI.SearchTabContentView.tabInfo):
657         New image (magnifying glass without border) when new TabBar is enabled.
658
659         * UserInterface/Views/SettingsTabContentView.js:
660         (WI.SettingsTabContentView):
661
662         * UserInterface/Views/TabBar.js:
663         (WI.TabBar):
664         Move creation of the Settings item out of TabBar. The TabBar should
665         only be concerned with managing tabs.
666
667         (WI.TabBar.prototype.get saveableTabCount):
668         (WI.TabBar.prototype._handleContextMenu):
669         (WI.TabBar.prototype.get normalNonEphemeralTabCount): Deleted.
670         Now that the Search tab is pinned, there aren't any normal tabs that
671         are also ephemeral. For the LegacyTabBar, both the Search and New Tab
672         tabs are still in this category.
673
674         * UserInterface/Views/TabBrowser.js:
675         (WI.TabBrowser.prototype.addTabForContentView):
676         (WI.TabBrowser.prototype.closeTabForContentView):
677         (WI.TabBrowser.prototype._tabBarItemSelected):
678         (WI.TabBrowser._tabBarItemRemoved):
679         Recent tab list should be validated against the list of saveable tabs,
680         since the Search tab is no longer a normal tab (a GeneralTabBarItem),
681         but is still persisted across Inspector sessions.
682
683 2018-02-16  Matt Baker  <mattbaker@apple.com>
684
685         Web Inspector: TabBar redesign: TabBarItem close button is incorrectly positioned
686         https://bugs.webkit.org/show_bug.cgi?id=182844
687         <rdar://problem/37586749>
688
689         Reviewed by Timothy Hatcher.
690
691         * UserInterface/Views/GeneralTabBarItem.js:
692         (WI.GeneralTabBarItem.prototype.set title):
693         Insert the title before the last flexible space item.
694
695         * UserInterface/Views/TabBar.css:
696         (.tab-bar > .item):
697         (.tab-bar > .item > .close):
698         (.tab-bar > .item > .flex-space):
699         (.tab-bar > .item.ephemeral > .flex-space:last-child):
700         (.tab-bar.collapsed > .item):
701         (.tab-bar.collapsed > .item > .flex-space):
702         (.tab-bar.collapsed > .item > .close):
703         (.tab-bar.collapsed > .item:hover > .close):
704         (.tab-bar.collapsed > .item.ephemeral:hover > .icon):
705         (.tab-bar > .item:hover > .close): Deleted.
706         (.tab-bar:not(.collapsed) > .item.ephemeral:hover > .icon): Deleted.
707
708         * UserInterface/Views/TabBarItem.js:
709         (WI.TabBarItem):
710         Restore flexible space items before and after the icon.
711
712 2018-02-14  Nikita Vasilyev  <nvasilyev@apple.com>
713
714         Web Inspector: Styles: completion popover doesn't hide when switching panels
715         https://bugs.webkit.org/show_bug.cgi?id=182464
716         <rdar://problem/37202763>
717
718         Reviewed by Timothy Hatcher.
719
720         Save the position of the anchor, an element the popover is shown for, and hide the completion popover
721         when the position changes.
722
723         * UserInterface/Views/CompletionSuggestionsView.js:
724         (WI.CompletionSuggestionsView.prototype.showUntilAnchorMoves):
725         When the popover is visible, check every 200ms if the anchor moved.
726
727         (WI.CompletionSuggestionsView.prototype.hide):
728         * UserInterface/Views/SpreadsheetTextField.js:
729         (WI.SpreadsheetTextField.prototype._updateCompletions):
730         (WI.SpreadsheetTextField.prototype._getCaretRect):
731         getBoundingClientRect returns {x: 0, y: 0} when it can't determine node's position.
732         This happens when a node isn't attached to DOM, attached to DOM but not visible, and
733         a number of odd cases.
734
735 2018-02-14  Matt Baker  <mattbaker@apple.com>
736
737         Web Inspector: TabBar redesign: only show allowed tabs in the available tabs context menu
738         https://bugs.webkit.org/show_bug.cgi?id=182721
739         <rdar://problem/37479019>
740
741         Reviewed by Timothy Hatcher.
742
743         In addition to only including allowed tabs in the TabBar context menu,
744         perform a sanity check when setting the selected tab item, since the
745         serialized selection index could refer to a tab that is no longer allowed.
746
747         * UserInterface/Views/LegacyTabBar.js:
748         (WI.LegacyTabBar.prototype.set selectedTabBarItem):
749         (WI.LegacyTabBar.prototype._handleContextMenu):
750
751         * UserInterface/Views/TabBar.js:
752         (WI.TabBar.prototype.set selectedTabBarItem):
753         (WI.TabBar.prototype._handleContextMenu):
754
755 2018-02-09  Matt Baker  <mattbaker@apple.com>
756
757         Web Inspector: Canvas tab: tree selection abruptly changes when selecting a recording frame
758         https://bugs.webkit.org/show_bug.cgi?id=182667
759         <rdar://problem/37412639>
760
761         Reviewed by Devin Rousso.
762
763         * UserInterface/Views/CanvasSidebarPanel.css:
764         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .navigation-bar):
765         (.sidebar > .panel.navigation.canvas:not(.has-recordings) > .filter-bar,):
766         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.recording > .icon):
767         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .icon):
768         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .status):
769         (.sidebar > .panel.navigation.canvas > .content > .navigation-bar): Deleted.
770         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.recording > .icon): Deleted.
771         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .icon): Deleted.
772         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .status): Deleted.
773         Style changes for the additional DOM element required to virtualize the recording tree outline.
774
775         * UserInterface/Views/CanvasSidebarPanel.js:
776         (WI.CanvasSidebarPanel):
777         In order to be virtualized, the tree must be the only child of its parent.
778
779         (WI.CanvasSidebarPanel.prototype.set action):
780         Ensure that a frame tree element isn't deselected when the last action
781         in the frame becomes selected in the RecordingContentView.
782
783         (WI.CanvasSidebarPanel.prototype.shown):
784         Refresh the sidebar, as represented objects may have changed while hidden.
785
786         (WI.CanvasSidebarPanel.prototype._currentRepresentedObjectsDidChange):
787         Unset the recording when no valid represented objects are found, to
788         prevent a stale recording tree from being shown when viewing the overview.
789
790         (WI.CanvasSidebarPanel.prototype._canvasChanged):
791         (WI.CanvasSidebarPanel.prototype._recordingChanged):
792         (WI.CanvasSidebarPanel.prototype._updateRecordingScopeBar):
793         Moved toggling of the "has-recordings" style to _canvasChanged, since
794         the navigation bar should be hidden when no canvas exists.
795
796         * UserInterface/Views/CollectionContentView.js:
797         (WI.CollectionContentView.prototype.addContentViewForItem):
798         (WI.CollectionContentView.prototype.removeContentViewForItem):
799         Drive by fixes for child view visible state.
800
801         * UserInterface/Views/TreeOutline.css:
802         (.tree-outline:not(.large):matches(:focus, .force-focus) .item.selected .status .indeterminate-progress-spinner):
803         Make spinner easier to see against the selection background color.
804
805 2018-02-09  Matt Baker  <mattbaker@apple.com>
806
807         Web Inspector: Object.shallowEqual always fails when comparing array property values
808         https://bugs.webkit.org/show_bug.cgi?id=182634
809         <rdar://problem/37374639>
810
811         Reviewed by Devin Rousso.
812
813         Object.shallowEqual should use Array.shallowEqual when comparing property
814         values, since strictly comparing objects/arrays is only true if both
815         operands reference the same Object.
816
817         * UserInterface/Base/Utilities.js:
818         (value):
819
820 2018-02-08  Matt Baker  <mattbaker@apple.com>
821
822         Web Inspector: add listing of Canvases/Programs/Recordings to the NavigationSidebar
823         https://bugs.webkit.org/show_bug.cgi?id=178744
824         <rdar://problem/35374379>
825
826         Reviewed by Devin Rousso.
827
828         * Localizations/en.lproj/localizedStrings.js:
829
830         * UserInterface/Images/Canvas2D.svg:
831         * UserInterface/Images/Canvas3D.svg:
832         * UserInterface/Images/Recording.svg:
833         Update canvas icons to be monochrome. Simplified the recording icon.
834
835         * UserInterface/Main.html:
836
837         * UserInterface/Models/RecordingAction.js:
838         (WI.RecordingAction.prototype.get state):
839         (WI.RecordingAction.prototype.set state):
840         Allow (2D) snapshot state to be associated with the action. Used by
841         RecordingActionDetailsSidebarPanel to retrieve the snapshot state.
842
843         * UserInterface/Views/CanvasContentView.css:
844         (.content-view.canvas:not(.tab)):
845         (.content-view.canvas:not(.tab) > .progress): Deleted.
846         (.content-view.canvas:not(.tab) > .progress > .frame-count): Deleted.
847
848         * UserInterface/Views/CanvasContentView.js:
849         (WI.CanvasContentView):
850         (WI.CanvasContentView.prototype.get navigationItems):
851         (WI.CanvasContentView.prototype.layout):
852         (WI.CanvasContentView.prototype.shown):
853         (WI.CanvasContentView.prototype._recordingStarted):
854         (WI.CanvasContentView.prototype._recordingProgress):
855         (WI.CanvasContentView.prototype._recordingStopped):
856         (WI.CanvasContentView.prototype._updateRecordNavigationItem):
857         (WI.CanvasContentView.prototype._updateProgressView):
858         Replace progress UI with a reusable ProgressView class.
859         When in the overview, clicking the CanvasContentView shows a dedicated
860         CanvasContentView for inspecting shaders and recordings. This behavior
861         is controlled by CollectionContentView, so we need to prevent it when
862         clicking inside the header and footer elements, which contain clickable UI.
863
864         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
865         (WI.CanvasDetailsSidebarPanel.prototype.inspect):
866
867         * UserInterface/Views/CanvasOverviewContentView.css:
868         (.content-view.canvas-overview .content-view.canvas):
869         (.content-view.canvas-overview .content-view.canvas.is-recording):
870         (.content-view.canvas-overview .content-view.canvas > :matches(header, footer)):
871         (.content-view.canvas-overview .content-view.canvas > header):
872         (.content-view.canvas-overview .content-view.canvas.is-recording > header):
873         (.content-view.canvas-overview .content-view.canvas > header > .navigation-bar):
874         (.content-view.canvas-overview .content-view.canvas:matches(:hover, .is-recording) > header > .navigation-bar):
875         (.content-view.canvas-overview .content-view.canvas.is-recording > .progress-view,):
876         (.content-view.canvas-overview .content-view.canvas.is-recording > .preview):
877         (.content-view.canvas-overview .content-view.canvas > :matches(header, .progress, .preview, footer)): Deleted.
878         (.content-view.canvas-overview .content-view.canvas.selected > :matches(.progress, .preview, footer),): Deleted.
879         (.content-view.canvas-overview .content-view.canvas:not(:hover, .is-recording, .selected) > header > .navigation-bar): Deleted.
880         (.content-view.canvas-overview .content-view.canvas > :matches(.progress, .preview)): Deleted.
881         (.content-view.canvas-overview .content-view.canvas > .preview): Deleted.
882         (.content-view.canvas-overview .content-view.canvas > .progress ~ .preview): Deleted.
883         Clean up styles, and remove selection styles as canvases are no longer selectable in the overview.
884
885         * UserInterface/Views/CanvasOverviewContentView.js:
886         (WI.CanvasOverviewContentView):
887         (WI.CanvasOverviewContentView.prototype.get navigationItems):
888         (WI.CanvasOverviewContentView.prototype.attached):
889         (WI.CanvasOverviewContentView.prototype.detached):
890         (WI.CanvasOverviewContentView.prototype.get selectionPathComponents): Deleted.
891         (WI.CanvasOverviewContentView.prototype._changeSelectedItemVertically): Deleted.
892         (WI.CanvasOverviewContentView.prototype._changeSelectedItemHorizontally): Deleted.
893         (WI.CanvasOverviewContentView.prototype._selectionPathComponentsChanged): Deleted.
894         (WI.CanvasOverviewContentView.prototype._handleUp): Deleted.
895         (WI.CanvasOverviewContentView.prototype._handleRight): Deleted.
896         (WI.CanvasOverviewContentView.prototype._handleDown): Deleted.
897         (WI.CanvasOverviewContentView.prototype._handleLeft): Deleted.
898         (WI.CanvasOverviewContentView.prototype._handleSpace): Deleted.
899         (WI.CanvasOverviewContentView.prototype._supplementalRepresentedObjectsDidChange): Deleted.
900         Disable canvas selection. Remove logic for supplemental represented objects,
901         path components, and selection keyboard shortcuts.
902
903         * UserInterface/Views/CanvasSidebarPanel.css: Added.
904         (.sidebar > .panel.navigation.canvas > .content):
905         (.sidebar > .panel.navigation.canvas > .navigation-bar > .item.record-start-stop.disabled):
906         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.canvas.canvas-2d .icon):
907         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.canvas.webgl .icon):
908         (.sidebar > .panel.navigation.canvas > .content > .navigation-bar):
909         (.sidebar > .panel.navigation.canvas.has-recordings > .content > .tree-outline.canvas):
910         (.sidebar > .panel.navigation.canvas:not(.has-recordings) > .filter-bar,):
911         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.recording > .icon):
912         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.shader-program > .icon):
913         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .icon):
914         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .status):
915
916         * UserInterface/Views/CanvasSidebarPanel.js: Added.
917         (WI.CanvasSidebarPanel):
918         (WI.CanvasSidebarPanel.prototype.get canvas):
919         (WI.CanvasSidebarPanel.prototype.set canvas):
920         (WI.CanvasSidebarPanel.prototype.set recording):
921         (WI.CanvasSidebarPanel.prototype.set action):
922         (WI.CanvasSidebarPanel.prototype.shown):
923         (WI.CanvasSidebarPanel.prototype.hidden):
924         (WI.CanvasSidebarPanel.prototype.hasCustomFilters):
925         (WI.CanvasSidebarPanel.prototype.matchTreeElementAgainstCustomFilters):
926         (WI.CanvasSidebarPanel.prototype.initialLayout):
927         (WI.CanvasSidebarPanel.prototype._recordingAdded):
928         (WI.CanvasSidebarPanel.prototype._recordingRemoved):
929         (WI.CanvasSidebarPanel.prototype._scopeBarSelectionChanged):
930         (WI.CanvasSidebarPanel.prototype._toggleRecording):
931         (WI.CanvasSidebarPanel.prototype._currentRepresentedObjectsDidChange):
932         (WI.CanvasSidebarPanel.prototype._treeOutlineSelectionDidChange):
933         (WI.CanvasSidebarPanel.prototype._canvasChanged):
934         (WI.CanvasSidebarPanel.prototype._recordingChanged):
935         (WI.CanvasSidebarPanel.prototype._updateRecordNavigationItem):
936         (WI.CanvasSidebarPanel.prototype._updateRecordingScopeBar):
937         Add new navigation sidebar, split into two sections. The upper section
938         contains a tree with a single element for the current canvas, and child
939         elements for any shader programs. The maximum height of this section is 50%
940         of the sidebar's height. The lower section contains a tree for the selected
941         recording, and a scope bar for choosing between recordings.
942
943         * UserInterface/Views/CanvasTabContentView.css:
944         (.content-view.tab.canvas .navigation-bar > .item .canvas-overview .icon):
945         (.content-view.tab.canvas .navigation-bar > .item .canvas.canvas-2d .icon):
946         (.content-view.tab.canvas .navigation-bar > .item .canvas.webgl .icon):
947         (.content-view.tab.canvas .navigation-bar > .item .shader-program > .icon):
948         (.content-view.tab.canvas .navigation-bar > .item > .hierarchical-path-component > .icon): Deleted.
949         (.content-view.tab.canvas .navigation-bar > .item .canvas .icon): Deleted.
950
951         * UserInterface/Views/CanvasTabContentView.js:
952         (WI.CanvasTabContentView):
953         (WI.CanvasTabContentView.prototype.canShowRepresentedObject):
954         (WI.CanvasTabContentView.prototype.attached):
955         (WI.CanvasTabContentView.prototype._addCanvas):
956         (WI.CanvasTabContentView.prototype._removeCanvas):
957         (WI.CanvasTabContentView.prototype._canvasTreeOutlineSelectionDidChange):
958         (WI.CanvasTabContentView.prototype._recordingAdded):
959         (WI.CanvasTabContentView.prototype._handleSpace):
960         (WI.CanvasTabContentView.prototype.showRepresentedObject): Deleted.
961         (WI.CanvasTabContentView.prototype._navigationSidebarTreeOutlineSelectionChanged): Deleted.
962         (WI.CanvasTabContentView.prototype._recordingActionIndexChanged): Deleted.
963         (WI.CanvasTabContentView.prototype._updateActionIndex): Deleted.
964         The canvas tab now maintains a tree outline of all canvases, with an
965         "Overview" element as the root. The Overview element is always the first
966         item of content browser's hierarchical path.
967
968         * UserInterface/Views/CanvasTreeElement.js:
969         (WI.CanvasTreeElement.createRecordingTreeElement):
970         (WI.CanvasTreeElement):
971         (WI.CanvasTreeElement.prototype.onattach):
972         (WI.CanvasTreeElement.prototype.onpopulate):
973         (WI.CanvasTreeElement.prototype._updateStatus):
974         (WI.CanvasTreeElement.prototype.ondetach): Deleted.
975         Make it possible to not show recordings under the Canvas element.
976         Create `isRecording` status element (spinner).
977
978         * UserInterface/Views/CollectionContentView.js:
979         (WI.CollectionContentView.prototype.shown):
980         (WI.CollectionContentView.prototype.hidden):
981         Child ContentViews need to be updated when the collection's visibility changes.
982
983         * UserInterface/Views/ContentView.js:
984         (WI.ContentView.isViewable):
985
986         * UserInterface/Views/ProgressView.css: Added.
987         (.progress-view):
988         (.progress-view > .titles):
989         (.progress-view > .titles > .title):
990         (.progress-view > .titles > .subtitle):
991         (.progress-view > .titles > .subtitle::before):
992         (.progress-view > .indeterminate-progress-spinner):
993
994         * UserInterface/Views/ProgressView.js: Added.
995         (WI.ProgressView):
996         (WI.ProgressView.prototype.get title):
997         (WI.ProgressView.prototype.set title):
998         (WI.ProgressView.prototype.get subtitle):
999         (WI.ProgressView.prototype.set subtitle):
1000         (WI.ProgressView.prototype.get visible):
1001         (WI.ProgressView.prototype.set visible):
1002         (WI.ProgressView.prototype.initialLayout):
1003         (WI.ProgressView.prototype._updateTitles):
1004         New view class (not a ContentView) for showing a generic progress message,
1005         with a title, subtitle, and progress spinner.
1006
1007         * UserInterface/Views/RecordingContentView.css:
1008         (.content-view:not(.tab).recording > .preview-container):
1009         Remove unnecessary styles.
1010
1011         * UserInterface/Views/RecordingContentView.js:
1012         (WI.RecordingContentView):
1013         (WI.RecordingContentView.prototype.get navigationItems):
1014         (WI.RecordingContentView.prototype.get supplementalRepresentedObjects):
1015         (WI.RecordingContentView.prototype.updateActionIndex):
1016         (WI.RecordingContentView.prototype.get saveData):
1017         (WI.RecordingContentView.prototype._exportRecording):
1018         Relocate the recording export logic and UI.
1019         (WI.RecordingContentView.prototype.async._generateContentCanvas2D):
1020         (WI.RecordingContentView.prototype.async._generateContentCanvasWebGL):
1021         (WI.RecordingContentView.prototype._sliderChanged):
1022         Refactor logic for notifying the rest of the UI of changes to the action slider.
1023         The selected action is now exposed as a supplemental represented object, and a
1024         corresponding SupplementalRepresentedObjectsDidChange event.
1025
1026         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1027         (WI.RecordingStateDetailsSidebarPanel.prototype.inspect):
1028         (WI.RecordingStateDetailsSidebarPanel.prototype.set action):
1029         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
1030         (WI.RecordingStateDetailsSidebarPanel):
1031         (WI.RecordingStateDetailsSidebarPanel.prototype.updateAction): Deleted.
1032
1033         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js:
1034         (WI.RecordingTraceDetailsSidebarPanel.prototype.inspect):
1035         (WI.RecordingTraceDetailsSidebarPanel.prototype.set action):
1036         (WI.RecordingTraceDetailsSidebarPanel):
1037         (WI.RecordingTraceDetailsSidebarPanel.prototype.updateAction): Deleted.
1038         Now that the selected action is exposed to the UI as a supplemental
1039         represented object, details sidebars can be more decoupled from the
1040         canvas tab, and be notified of changes to the selection via `inspect()`.
1041
1042         * UserInterface/Views/ResourceIcons.css:
1043         (.canvas > .icon): Deleted.
1044         (.shader-program .icon): Deleted.
1045
1046 2018-02-08  Nikita Vasilyev  <nvasilyev@apple.com>
1047
1048         Web Inspector: Styles: Typing value and quickly moving focus away may display outdated value in UI
1049         https://bugs.webkit.org/show_bug.cgi?id=182588
1050         <rdar://problem/37332161>
1051
1052         Reviewed by Matt Baker.
1053
1054         CSSProperty models were updated with a 250ms delay. Quickly adding a blank property after modifying
1055         an existing property could result in outdated values being shown.
1056
1057         This patch removes the 250ms delay.
1058
1059         * UserInterface/Views/SpreadsheetStyleProperty.js:
1060         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidChange):
1061
1062 2018-02-07  Matt Baker  <mattbaker@apple.com>
1063
1064         Web Inspector: replace isAncestor with Node.contains() in LegacyTabBar
1065         https://bugs.webkit.org/show_bug.cgi?id=182586
1066
1067         Reviewed by Timothy Hatcher.
1068
1069         * UserInterface/Views/LegacyTabBar.js:
1070
1071 2018-02-07  Nikita Vasilyev  <nvasilyev@apple.com>
1072
1073         Web Inspector: Styles: completion popover doesn't hide when switching panels
1074         https://bugs.webkit.org/show_bug.cgi?id=182464
1075         <rdar://problem/37202763>
1076
1077         Reviewed by Timothy Hatcher.
1078
1079         Hide completion popover by triggering blur event on the focused text field.
1080         Removing text fields from the DOM tree would hide the completion popovers as well,
1081         but switching sidebar panels doesn't remove them from the DOM.
1082
1083         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1084         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.hidden):
1085         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
1086         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.hidden):
1087         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
1088         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.hidden):
1089         * UserInterface/Views/SpreadsheetStyleProperty.js:
1090         (WI.SpreadsheetStyleProperty.prototype.hidden):
1091
1092 2018-02-06  Devin Rousso  <webkit@devinrousso.com>
1093
1094         Web Inspector: Replace isAncestor and isDescendant with native DOM contains method
1095         https://bugs.webkit.org/show_bug.cgi?id=182069
1096
1097         Reviewed by Brian Burg.
1098
1099         * UserInterface/Base/Main.js:
1100         (WI.restoreFocusFromElement):
1101         (WI._mouseDown):
1102         (WI._focusedContentBrowser):
1103         (WI._focusedContentView):
1104         * UserInterface/Base/Utilities.js:
1105         (Node.prototype.traverseNextNode):
1106         (Node.prototype.isAncestor): Deleted.
1107         (Node.prototype.isDescendant): Deleted.
1108         (Node.prototype.isSelfOrAncestor): Deleted.
1109         (Node.prototype.isSelfOrDescendant): Deleted.
1110         * UserInterface/Views/BoxModelDetailsSectionRow.js:
1111         (WI.BoxModelDetailsSectionRow.prototype._handleKeyDown):
1112         * UserInterface/Views/CSSStyleDeclarationSection.js:
1113         (WI.CSSStyleDeclarationSection.prototype._handleSelectorPaste):
1114         * UserInterface/Views/DOMTreeOutline.js:
1115         (WI.DOMTreeOutline.prototype._onmouseout):
1116         * UserInterface/Views/DetailsSection.js:
1117         (WI.DetailsSection.prototype._headerElementClicked):
1118         * UserInterface/Views/EditingSupport.js:
1119         (WI.incrementElementValue):
1120         * UserInterface/Views/LogContentView.js:
1121         (WI.LogContentView.prototype._handleContextMenuEvent):
1122         * UserInterface/Views/ShaderProgramTreeElement.js:
1123         (WI.ShaderProgramTreeElement.prototype.selectOnMouseDown):
1124         * UserInterface/Views/SoftContextMenu.js:
1125         (WI.SoftContextMenu.prototype._menuItemMouseOut):
1126         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1127         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.initialLayout):
1128         * UserInterface/Views/TabBar.js:
1129         (WI.TabBar.prototype.insertTabBarItem):
1130
1131 2018-02-06  Devin Rousso  <webkit@devinrousso.com>
1132
1133         Web Inspector: Elements tab should have "Jump to Layer" functionality
1134         https://bugs.webkit.org/show_bug.cgi?id=181800
1135
1136         Reviewed by Joseph Pecoraro.
1137
1138         * Localizations/en.lproj/localizedStrings.js:
1139
1140         * UserInterface/Base/Main.js:
1141         (WI.isShowingElementsTab):
1142         (WI.showLayersTab):
1143         (WI.isShowingLayersTab):
1144
1145         * UserInterface/Views/ContextMenuUtilities.js:
1146         (WI.appendContextMenuItemsForDOMNode):
1147
1148         * UserInterface/Views/LayersTabContentView.js:
1149         (WI.LayersTabContentView.prototype.selectLayerForNode):
1150
1151         * UserInterface/Views/Layers3DContentView.js:
1152         (WI.Layers3DContentView):
1153         (WI.Layers3DContentView.prototype.selectLayerForNode):
1154         (WI.Layers3DContentView.prototype.layout):
1155
1156         * UserInterface/Views/LayerDetailsSidebarPanel.js:
1157         (WI.LayerDetailsSidebarPanel):
1158         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
1159         (WI.LayerDetailsSidebarPanel.prototype._updateDataGrid):
1160
1161 2018-02-06  Nikita Vasilyev  <nvasilyev@apple.com>
1162
1163         Web Inspector: Rename String.prototype.trimEnd to avoid conflicts with native trimEnd
1164         https://bugs.webkit.org/show_bug.cgi?id=182545
1165
1166         Reviewed by Brian Burg.
1167
1168         Rename:
1169         - trimEnd to truncateEnd
1170         - trimMiddle to truncateMiddle
1171
1172         * UserInterface/Base/Utilities.js:
1173         (String.prototype.trimMiddle): Deleted.
1174         (String.prototype.trimEnd): Deleted.
1175         (String.prototype.truncateMiddle): Added.
1176         (String.prototype.truncateEnd): Added.
1177         Use strict mode. Scrict mode allows `this` to be a primitive (a string, in our case).
1178         In non-strict mode, `this` is always an object. Without the strict mode,
1179         "a".truncateEnd(42) !== "a", because truncateEnd returns a string object.
1180
1181         * UserInterface/Views/DOMTreeElement.js:
1182         (WI.DOMTreeElement.prototype._buildAttributeDOM):
1183         * UserInterface/Views/DOMTreeElementPathComponent.js:
1184         (WI.DOMTreeElementPathComponent):
1185         * UserInterface/Views/SearchResultTreeElement.js:
1186         Remove an obvious comment.
1187
1188         (WI.SearchResultTreeElement.truncateAndHighlightTitle):
1189         * UserInterface/Views/SpreadsheetStyleProperty.js:
1190         (WI.SpreadsheetStyleProperty.prototype._renderValue):
1191
1192 2018-02-05  Nikita Vasilyev  <nvasilyev@apple.com>
1193
1194         Web Inspector: Add an experimental setting to enable Sources tab
1195         https://bugs.webkit.org/show_bug.cgi?id=182461
1196
1197         Reviewed by Brian Burg.
1198
1199         This patch only adds a setting. It doesn't add the Sources tab.
1200
1201         * Localizations/en.lproj/localizedStrings.js:
1202         * UserInterface/Base/Setting.js:
1203         * UserInterface/Views/SettingsTabContentView.js:
1204
1205 2018-02-02  Devin Rousso  <webkit@devinrousso.com>
1206
1207         Web Inspector: Styles Redesign: Pasting multiple properties should create properties instead of a bad property
1208         https://bugs.webkit.org/show_bug.cgi?id=179622
1209         <rdar://problem/35511170>
1210
1211         Reviewed by Matt Baker.
1212
1213         * UserInterface/Views/SpreadsheetStyleProperty.js:
1214         (WI.SpreadsheetStyleProperty.prototype._remove):
1215         (WI.SpreadsheetStyleProperty.prototype._update):
1216         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidCommit):
1217         (WI.SpreadsheetStyleProperty.prototype._handleNamePaste):
1218         When the user pastes into the name field, parse the text for a list of name-value pairs and
1219         replace the property being edited with the text of those pairs.
1220
1221         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1222         (WI.SpreadsheetCSSStyleDeclarationEditor):
1223         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
1224         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.addBlankProperty):
1225         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyFocusMoved):
1226         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyAddBlankPropertySoon):
1227         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyRemoved):
1228         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesChanged):
1229         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetCSSStyleDeclarationEditorFocusMoved): Deleted.
1230         Calling `addBlankProperty` will trigger a layout on the next frame, but that might be before
1231         the CSSAgent has had a chance to finish refreshing, so we need a way to defer the creation
1232         of a new property until after we have finished the next layout (which is after the refresh).
1233         Drive-by: fix naming of some delegate functions.
1234
1235         * UserInterface/Models/CSSProperty.js:
1236         (WI.CSSProperty.prototype.replaceWithText):
1237         Provide a way for replacing the property with new text.
1238
1239 2018-02-02  Matt Baker  <mattbaker@apple.com>
1240
1241         Web Inspector: TabBar redesign: remove New Tab button and add experimental feature flag
1242         https://bugs.webkit.org/show_bug.cgi?id=182342
1243         <rdar://problem/37078662>
1244
1245         Reviewed by Devin Rousso.
1246
1247         This patch adds a new experimental setting group, "User Interface", with
1248         a single setting, "Enable New TabBar". When enabled, the New Tab button is
1249         no longer available in the top-level TabBar. The 'open tabs' context menu
1250         no longer allows the last non-ephemeral open tab to be closed (unchecked).
1251
1252         * Localizations/en.lproj/localizedStrings.js:
1253
1254         * UserInterface/Base/Main.js:
1255         (WI.contentLoaded):
1256         (WI._tryToRestorePendingTabs):
1257         Retain legacy behavior behind experimental feature setting.
1258         (WI.isNewTabWithTypeAllowed):
1259
1260         * UserInterface/Base/Setting.js:
1261         * UserInterface/Main.html:
1262
1263         * UserInterface/Views/CanvasTabContentView.js:
1264         (WI.CanvasTabContentView):
1265         * UserInterface/Views/ConsoleTabContentView.js:
1266         (WI.ConsoleTabContentView):
1267         * UserInterface/Views/DebuggerTabContentView.js:
1268         (WI.DebuggerTabContentView):
1269         * UserInterface/Views/ElementsTabContentView.js:
1270         (WI.ElementsTabContentView):
1271
1272         * UserInterface/Views/GeneralTabBarItem.js:
1273         (WI.GeneralTabBarItem):
1274         (WI.GeneralTabBarItem.prototype.fromTabInfo):
1275         (WI.GeneralTabBarItem.prototype.get isEphemeral):
1276         (WI.GeneralTabBarItem.fromTabContentViewConstructor): Deleted.
1277
1278         * UserInterface/Views/LayersTabContentView.js:
1279         (WI.LayersTabContentView):
1280
1281         * UserInterface/Views/LegacyTabBar.js: Copied from Source/WebInspectorUI/UserInterface/Views/TabBar.js.
1282         (WI.LegacyTabBar):
1283         (WI.LegacyTabBar.prototype.get newTabTabBarItem):
1284         (WI.LegacyTabBar.prototype.updateNewTabTabBarItemState):
1285         (WI.LegacyTabBar.prototype.addTabBarItem):
1286         (WI.LegacyTabBar.prototype.insertTabBarItem.animateTabs):
1287         (WI.LegacyTabBar.prototype.insertTabBarItem.removeStyles):
1288         (WI.LegacyTabBar.prototype.insertTabBarItem):
1289         (WI.LegacyTabBar.prototype.removeTabBarItem.animateTabs):
1290         (WI.LegacyTabBar.prototype.removeTabBarItem.removeStyles):
1291         (WI.LegacyTabBar.prototype.removeTabBarItem):
1292         (WI.LegacyTabBar.prototype.selectPreviousTab):
1293         (WI.LegacyTabBar.prototype.selectNextTab):
1294         (WI.LegacyTabBar.prototype.get selectedTabBarItem):
1295         (WI.LegacyTabBar.prototype.set selectedTabBarItem):
1296         (WI.LegacyTabBar.prototype.get tabBarItems):
1297         (WI.LegacyTabBar.prototype.get normalTabCount):
1298         (WI.LegacyTabBar.prototype.layout.forceItemHidden):
1299         (WI.LegacyTabBar.prototype.layout):
1300         (WI.LegacyTabBar.prototype._tabBarItemsFromLeftToRight):
1301         (WI.LegacyTabBar.prototype._findTabBarItem):
1302         (WI.LegacyTabBar.prototype._hasMoreThanOneNormalTab):
1303         (WI.LegacyTabBar.prototype._openDefaultTab):
1304         (WI.LegacyTabBar.prototype._recordTabBarItemSizesAndPositions):
1305         (WI.LegacyTabBar.prototype._applyTabBarItemSizesAndPositions):
1306         (WI.LegacyTabBar.prototype._clearTabBarItemSizesAndPositions):
1307         (WI.LegacyTabBar.prototype._finishExpandingTabsAfterClose.):
1308         (WI.LegacyTabBar.prototype._finishExpandingTabsAfterClose):
1309         (WI.LegacyTabBar.prototype._handleMouseDown):
1310         (WI.LegacyTabBar.prototype._handleClick):
1311         (WI.LegacyTabBar.prototype._handleMouseMoved):
1312         (WI.LegacyTabBar.prototype._handleMouseUp):
1313         (WI.LegacyTabBar.prototype._handleMouseLeave):
1314         (WI.LegacyTabBar.prototype._handleContextMenu):
1315         (WI.LegacyTabBar.prototype._handleNewTabClick):
1316         (WI.LegacyTabBar.prototype._handleTabPickerTabContextMenu):
1317         (WI.LegacyTabBar.prototype._handleNewTabMouseEnter):
1318
1319         * UserInterface/Views/NetworkTabContentView.js:
1320         (WI.NetworkTabContentView):
1321         * UserInterface/Views/NewTabContentView.js:
1322         (WI.NewTabContentView):
1323         (WI.NewTabContentView.tabInfo):
1324         (WI.NewTabContentView.isEphemeral): Deleted.
1325         * UserInterface/Views/ResourcesTabContentView.js:
1326         (WI.ResourcesTabContentView):
1327         * UserInterface/Views/SearchTabContentView.js:
1328         (WI.SearchTabContentView):
1329         (WI.SearchTabContentView.tabInfo):
1330         (WI.SearchTabContentView.isEphemeral): Deleted.
1331
1332         * UserInterface/Views/SettingsTabContentView.js:
1333         (WI.SettingsTabContentView.tabInfo):
1334         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1335         (WI.SettingsTabContentView.isEphemeral): Deleted.
1336
1337         * UserInterface/Views/StorageTabContentView.js:
1338         (WI.StorageTabContentView):
1339
1340         * UserInterface/Views/TabBar.css:
1341         * UserInterface/Views/TabBar.js:
1342         (WI.TabBar):
1343         (WI.TabBar.prototype.insertTabBarItem):
1344         (WI.TabBar.prototype.removeTabBarItem):
1345         (WI.TabBar.prototype.set selectedTabBarItem):
1346         (WI.TabBar.prototype.get normalNonEphemeralTabCount):
1347         (WI.TabBar.prototype._handleMouseDown):
1348         (WI.TabBar.prototype._handleClick):
1349         (WI.TabBar.prototype._handleMouseMoved):
1350         (WI.TabBar.prototype._handleMouseLeave):
1351         (WI.TabBar.prototype._handleContextMenu):
1352         (WI.TabBar.prototype._handleTabPickerTabContextMenu):
1353         (WI.TabBar.prototype.get newTabTabBarItem): Deleted.
1354         (WI.TabBar.prototype.updateNewTabTabBarItemState): Deleted.
1355         (WI.TabBar.prototype._openDefaultTab): Deleted.
1356         (WI.TabBar.prototype._handleNewTabClick): Deleted.
1357         (WI.TabBar.prototype._handleNewTabMouseEnter): Deleted.
1358         Remove support for the New Tab button and default tab. Without a default
1359         tab, there is nothing to display when no tabs are open, so prevent the
1360         last non-pinned tab from being removed.
1361
1362         * UserInterface/Views/TabBrowser.js:
1363         (WI.TabBrowser._tabBarItemRemoved):
1364         * UserInterface/Views/TabContentView.js:
1365         (WI.TabContentView.isEphemeral): Deleted.
1366         * UserInterface/Views/TimelineTabContentView.js:
1367         (WI.TimelineTabContentView):
1368
1369 2018-01-30  Devin Rousso  <webkit@devinrousso.com>
1370
1371         Web Inspector: Replace Object.shallowMerge with ES2018 spread operator
1372         https://bugs.webkit.org/show_bug.cgi?id=182219
1373
1374         Reviewed by Brian Burg.
1375
1376         * UserInterface/Base/Utilities.js:
1377         (Object.shallowMerge): Deleted.
1378         * UserInterface/Base/DOMUtilities.js:
1379         (WI.linkifyNodeReference):
1380         * UserInterface/Base/Main.js:
1381         (WI.handlePossibleLinkClick):
1382         (WI.openURL):
1383         (WI.showSourceCodeLocation):
1384         (WI.showOriginalUnformattedSourceCodeLocation):
1385         (WI.showOriginalOrFormattedSourceCodeLocation):
1386         (WI.showOriginalOrFormattedSourceCodeTextRange):
1387         (WI.linkifyLocation):
1388         * UserInterface/Views/DOMTreeElement.js:
1389         (WI.DOMTreeElement.prototype._insertAdjacentHTML):
1390         * UserInterface/Views/WebSocketContentView.js:
1391         (WI.WebSocketContentView.prototype._addRow):
1392
1393 2018-01-26  Matt Baker  <mattbaker@apple.com>
1394
1395         Web Inspector: Timelines content browser NavigationBar is squashed at narrow heights
1396         https://bugs.webkit.org/show_bug.cgi?id=182196
1397         <rdar://problem/36929899>
1398
1399         Reviewed by Joseph Pecoraro.
1400
1401         * UserInterface/Views/NavigationBar.css:
1402         (.navigation-bar):
1403
1404 2018-01-26  Matt Baker  <mattbaker@apple.com>
1405
1406         Web Inspector: TabBar redesign: improvements to tab layout and resize behavior
1407         https://bugs.webkit.org/show_bug.cgi?id=181468
1408         <rdar://problem/36395439>
1409
1410         Reviewed by Devin Rousso.
1411
1412         * Localizations/en.lproj/localizedStrings.js:
1413
1414         * UserInterface/Images/TabPicker.svg: Added.
1415         New ">>" icon for the tab picker button.
1416
1417         * UserInterface/Views/CanvasTabContentView.js:
1418         (WI.CanvasTabContentView):
1419         * UserInterface/Views/ConsoleTabContentView.js:
1420         (WI.ConsoleTabContentView):
1421         * UserInterface/Views/DebuggerTabContentView.js:
1422         (WI.DebuggerTabContentView):
1423         * UserInterface/Views/ElementsTabContentView.js:
1424         (WI.ElementsTabContentView):
1425
1426         * UserInterface/Views/GeneralTabBarItem.js:
1427         (WI.GeneralTabBarItem):
1428         (WI.GeneralTabBarItem.fromTabContentViewConstructor):
1429         (WI.GeneralTabBarItem.prototype.get title):
1430         Add missing override for getter/setter pair.
1431         (WI.GeneralTabBarItem.prototype.set title):
1432         (WI.GeneralTabBarItem.prototype._handleContextMenuEvent):
1433         Show the close button on ephemeral tabs only (Search, New Tab).
1434         Replace unused `representedObject` parameter with `isEphemeral`, which
1435         determines whether to show a close button for the tab.
1436
1437         * UserInterface/Views/LayersTabContentView.js:
1438         (WI.LayersTabContentView):
1439
1440         * UserInterface/Views/NavigationBar.js:
1441         Remove unused symbol.
1442
1443         * UserInterface/Views/NetworkTabContentView.js:
1444         (WI.NetworkTabContentView):
1445         * UserInterface/Views/NewTabContentView.js:
1446         (WI.NewTabContentView):
1447
1448         * UserInterface/Views/PinnedTabBarItem.js:
1449         (WI.PinnedTabBarItem):
1450         Remove unused parameter.
1451
1452         * UserInterface/Views/ResourcesTabContentView.js:
1453         (WI.ResourcesTabContentView):
1454         * UserInterface/Views/SearchTabContentView.js:
1455         (WI.SearchTabContentView):
1456         * UserInterface/Views/StorageTabContentView.js:
1457         (WI.StorageTabContentView):
1458
1459         * UserInterface/Views/TabBar.css:
1460         (.tab-bar > .item):
1461         (.tab-bar.calculate-width > .item):
1462         (.tab-bar > .item.pinned.tab-picker):
1463         (.tab-bar > .item > .close):
1464         (.tab-bar > .item > .title):
1465         (.tab-bar:not(.collapsed) > .item > .title):
1466         (.tab-bar.collapsed > .item:not(.pinned) > .icon):
1467         (.tab-bar > .item:hover > .close):
1468         (.tab-bar.collapsed > .item:hover > .close):
1469         (.tab-bar:not(.collapsed) > .item.ephemeral:hover > .icon):
1470         (.tab-bar.collapsed > .item.ephemeral:hover > .title):
1471         (body[dir=ltr] .tab-bar > .item > .close): Deleted.
1472         (body[dir=rtl] .tab-bar > .item > .close): Deleted.
1473         (.tab-bar > .item > .flex-space): Deleted.
1474         (.tab-bar > .item:not(.pinned) > .flex-space:last-child): Deleted.
1475         (body[dir=ltr] .tab-bar > .item:not(.pinned) > .flex-space:last-child): Deleted.
1476         (body[dir=rtl] .tab-bar > .item:not(.pinned) > .flex-space:last-child): Deleted.
1477         (body[dir=ltr] .tab-bar > .item > .title): Deleted.
1478         (body[dir=rtl] .tab-bar > .item > .title): Deleted.
1479         (.tab-bar.collapsed > .item): Deleted.
1480         (.tab-bar.collapsed > .item > .flex-space): Deleted.
1481         (.tab-bar.collapsed > .item > .close): Deleted.
1482         (body[dir=ltr] .tab-bar.collapsed > .item > .close): Deleted.
1483         (body[dir=rtl] .tab-bar.collapsed > .item > .close): Deleted.
1484         (.tab-bar.hide-titles > .item > .title): Deleted.
1485         (.tab-bar.collapsed:not(.hide-titles) > .item:not(.pinned):hover > .icon,): Deleted.
1486         (.tab-bar.collapsed:not(.hide-titles) > .item:hover > .close,): Deleted.
1487         Clean up tab styles and prevent tabs from shrinking during flex layout.
1488         Added new `calculate-width` class, to disable flex layout when measuring
1489         the minimum width of the TabBar required to fit all tab items.
1490
1491         * UserInterface/Views/TabBar.js:
1492         (WI.TabBar):
1493         (WI.TabBar.prototype.set selectedTabBarItem):
1494         (WI.TabBar.prototype.layout.forceItemHidden):
1495         (WI.TabBar.prototype.layout):
1496         Perform two layout passes, similar to NavigationBar. The first pass disables
1497         flex layout and measures tab items at full size. If the bar isn't wide enough
1498         to show all the tabs, hide their icons and measure again. If there still isn't
1499         room, hide tabs starting from the end of the bar and display the tab picker.
1500
1501         (WI.TabBar.prototype._handleMouseDown):
1502         (WI.TabBar.prototype._handleTabPickerTabContextMenu):
1503
1504         * UserInterface/Views/TabBarItem.js:
1505         (WI.TabBarItem):
1506
1507         * UserInterface/Views/TimelineTabContentView.js:
1508         (WI.TimelineTabContentView):
1509
1510 2018-01-25  Joseph Pecoraro  <pecoraro@apple.com>
1511
1512         Web Inspector: Network Table: Sort indicator is not displayed when sorted column is hidden and re-shown
1513         https://bugs.webkit.org/show_bug.cgi?id=182164
1514         <rdar://problem/36892619>
1515
1516         Reviewed by Brian Burg.
1517
1518         * UserInterface/Views/Table.js:
1519         (WI.Table.prototype.showColumn):
1520         Re-add the sort classes if the column being shown is the active sort column.
1521
1522 2018-01-25  Joseph Pecoraro  <pecoraro@apple.com>
1523
1524         Web Inspector: Network - Cookies view should behave better at narrow widths, all data is hidden
1525         https://bugs.webkit.org/show_bug.cgi?id=182163
1526         <rdar://problem/36893241>
1527
1528         Reviewed by Brian Burg.
1529
1530         * UserInterface/Views/ResourceCookiesContentView.css:
1531         (.resource-cookies .table):
1532         Give these tables a reasonable minimum size so that if the inspector
1533         is narrow, the content view can still be scrolled to see all of
1534         the table data.
1535
1536         * UserInterface/Views/Table.css:
1537         (.table > .header):
1538         Match the data-container and mark overflow as hidden, otherwise
1539         super narrow widths show header content beyond the edge.
1540
1541 2018-01-25  Joseph Pecoraro  <pecoraro@apple.com>
1542
1543         Web Inspector: "Displayed Columns" should not be displayed in context menu if all columns are required columns
1544         https://bugs.webkit.org/show_bug.cgi?id=182162
1545         <rdar://problem/36893758>
1546
1547         Reviewed by Matt Baker.
1548
1549         * UserInterface/Views/Table.js:
1550         (WI.Table.prototype._handleHeaderContextMenu):
1551         Only add the header column when we know there are hideable columns.
1552
1553 2018-01-24  Joseph Pecoraro  <pecoraro@apple.com>
1554
1555         Web Inspector: Simplify update-LegacyInspectorBackendCommands.rb
1556         https://bugs.webkit.org/show_bug.cgi?id=182067
1557
1558         Reviewed by Brian Burg.
1559
1560         * Scripts/update-LegacyInspectorBackendCommands.rb:
1561         Remove stale dependency_json, it has always been empty for a while now.
1562         Switch to framework WebInspectorUI to generate only the backend commands
1563         and not spend time generating a bunch of cpp files.
1564
1565 2018-01-24  Nikita Vasilyev  <nvasilyev@apple.com>
1566
1567         REGRESSION (r226994): Web Inspector: Styles: Suggestions popover floats in top-left corner of Web Inspector after tabbing
1568         https://bugs.webkit.org/show_bug.cgi?id=182027
1569
1570         Reviewed by Matt Baker.
1571
1572         r226994 added a layout of all properties on property removal. Layout caused
1573         a property element to be removed from DOM right before dislaying the suggestion
1574         popover, resulting in the popover being displayed at the top left corner.
1575
1576         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1577         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
1578         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyRemoved):
1579         Only update property view indices when a property is removed.
1580
1581         * UserInterface/Views/SpreadsheetStyleProperty.js:
1582         (WI.SpreadsheetStyleProperty):
1583         (WI.SpreadsheetStyleProperty.prototype.set index):
1584
1585         * UserInterface/Views/SpreadsheetTextField.js:
1586         (WI.SpreadsheetTextField.prototype._updateCompletions):
1587         Checking this._element.parentNode to see if the element is attached to the DOM tree is unreliable,
1588         since the element may have a non-null parent node that is detached from the DOM tree. To fix that,
1589         we could traverse element's ancestors, but I used a concise isConnected property instead.
1590
1591 2018-01-24  Joseph Pecoraro  <pecoraro@apple.com>
1592
1593         ReferenceError:​ Can't find variable:​ DOMAgent (at ScriptSyntaxTree.js:​178:​22)​
1594         https://bugs.webkit.org/show_bug.cgi?id=182059
1595
1596         Reviewed by Matt Baker.
1597
1598         * UserInterface/Models/ScriptSyntaxTree.js:
1599         (WI.ScriptSyntaxTree.functionReturnDivot):
1600         DOMAgent won't be available in a ServiceWorker or JSContext inspector. So add
1601         a check for DOMAgent, and assume if DOMAgent doesn't exist that we should fall
1602         back to the latest path (non-iOS 9) target.
1603
1604 2018-01-23  Joseph Pecoraro  <pecoraro@apple.com>
1605
1606         Web Inspector: Network's columns shake when scrolling at non-default zoom level
1607         https://bugs.webkit.org/show_bug.cgi?id=181998
1608         <rdar://problem/36449808>
1609
1610         Reviewed by Matt Baker.
1611
1612         * UserInterface/Views/Table.js:
1613         When zoomed the bounding client rect values were fractional, which was
1614         unexpected by this area of code. Floor the values to get a value we expect
1615         to be able to evenly distribute.
1616
1617 2018-01-22  Nikita Vasilyev  <nvasilyev@apple.com>
1618
1619         Web Inspector: Styles Redesign: data corruption when updating values quickly
1620         https://bugs.webkit.org/show_bug.cgi?id=179461
1621         <rdar://problem/35431882>
1622
1623         Reviewed by Joseph Pecoraro.
1624
1625         Data corruption used to happen because CSSStyleDeclaration.prototype.text didn't
1626         update synchronously. Making two or more quick changes resulted in corrupted data.
1627
1628         Imagine we modify a CSS value 3 times:
1629
1630         Front-end:  (1)-(2)---(3)
1631         Back-end:          (1)-----(2)-(3)
1632
1633         The first response from the backend could happen after the 2nd edit. In this patch,
1634         CSSStyleDeclaration is locked when its view is being edited.
1635
1636         To correctly display invalid and overridden properties, the backend is allowed to update
1637         CSSStyleDeclaration and CSSProperty when they're locked if the text from the backend
1638         matches the model's text. This should happen when the backend is caught up with the
1639         front-end changes.
1640
1641         * UserInterface/Models/CSSProperty.js:
1642         (WI.CSSProperty.prototype.update):
1643         * UserInterface/Models/CSSStyleDeclaration.js:
1644         (WI.CSSStyleDeclaration):
1645         (WI.CSSStyleDeclaration.prototype.get locked):
1646         (WI.CSSStyleDeclaration.prototype.set locked):
1647         (WI.CSSStyleDeclaration.prototype.set text):
1648
1649         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1650         (WI.SpreadsheetCSSStyleDeclarationEditor):
1651         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.initialLayout):
1652         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.detached):
1653         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get editing):
1654         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.set focused):
1655         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.set inlineSwatchActive):
1656         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.stylePropertyInlineSwatchActivated):
1657         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.stylePropertyInlineSwatchDeactivated):
1658         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesChanged):
1659         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._updateStyleLock):
1660         Lock CSSStyleDeclaration when a CSS property name or value is focused or
1661         an inline widget is active.
1662
1663         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
1664         (WI.SpreadsheetCSSStyleDeclarationSection):
1665         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleMouseDown):
1666         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleClick):
1667         * UserInterface/Views/SpreadsheetStyleProperty.js:
1668         (WI.SpreadsheetStyleProperty):
1669         (WI.SpreadsheetStyleProperty.prototype._createInlineSwatch):
1670         When selector is focused, clicking on the white-space should not add a new blank property.
1671
1672 2018-01-19  Ross Kirsling  <ross.kirsling@sony.com>
1673
1674         Web Inspector: Layers tab should do away with popovers (if possible)
1675         https://bugs.webkit.org/show_bug.cgi?id=181805
1676
1677         Reviewed by Matt Baker.
1678
1679         * Localizations/en.lproj/localizedStrings.js:
1680         Remove superfluous colon from a string.
1681
1682         * UserInterface/Main.html:
1683         * UserInterface/Views/LayerDetailsSidebarPanel.css:
1684         * UserInterface/Views/Layers3DContentView.css: Added.
1685         Remove popover styling from sidebar, add new file with similar styling for canvas overlay.
1686
1687         * UserInterface/Views/LayerDetailsSidebarPanel.js:
1688         (WI.LayerDetailsSidebarPanel):
1689         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
1690         (WI.LayerDetailsSidebarPanel.prototype._dataGridSelectedNodeChanged):
1691         (WI.LayerDetailsSidebarPanel.prototype._updateLayers):
1692         (WI.LayerDetailsSidebarPanel.prototype._updateBottomBar):
1693         (WI.LayerDetailsSidebarPanel.prototype.willDismissPopover): Deleted.
1694         (WI.LayerDetailsSidebarPanel.prototype._showPopoverForSelectedNode): Deleted.
1695         (WI.LayerDetailsSidebarPanel.prototype._presentPopover): Deleted.
1696         (WI.LayerDetailsSidebarPanel.prototype._contentForPopover): Deleted.
1697         (WI.LayerDetailsSidebarPanel.prototype._populateListOfCompositingReasons.addReason): Deleted.
1698         (WI.LayerDetailsSidebarPanel.prototype._populateListOfCompositingReasons): Deleted.
1699         * UserInterface/Views/Layers3DContentView.js:
1700         (WI.Layers3DContentView):
1701         (WI.Layers3DContentView.prototype.shown):
1702         (WI.Layers3DContentView.prototype.selectLayerById):
1703         (WI.Layers3DContentView.prototype._canvasMouseDown):
1704         (WI.Layers3DContentView.prototype._buildLayerInfoElement):
1705         (WI.Layers3DContentView.prototype._updateLayerInfoElement):
1706         (WI.Layers3DContentView.prototype._updateReasonsList):
1707         Remove popover from sidebar table, overlay div with same data arrangement on top of the canvas.
1708         Also reverse the fix from r226671 since the visualization is no longer unusable without the sidebar!
1709
1710 2018-01-19  Matt Baker  <mattbaker@apple.com>
1711
1712         Web Inspector: Canvas Tab: Multiple "waiting for frames" messages displayed
1713         https://bugs.webkit.org/show_bug.cgi?id=181865
1714         <rdar://problem/36664737>
1715
1716         Reviewed by Devin Rousso.
1717
1718         * UserInterface/Views/CanvasContentView.js:
1719         (WI.CanvasContentView.prototype._recordingStarted):
1720         (WI.CanvasContentView.prototype._recordingStopped):
1721
1722 2018-01-19  Nikita Vasilyev  <nvasilyev@apple.com>
1723
1724         Web Inspector: Styles Redesign: tabbing on commented out property throws exception
1725         https://bugs.webkit.org/show_bug.cgi?id=180676
1726         <rdar://problem/35981058>
1727
1728         Reviewed by Joseph Pecoraro.
1729
1730         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1731         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.startEditingFirstProperty):
1732         Tabbing from the selector field should focus on the first editable property.
1733         When no editable properties are present, a new blank property should be added after the commented out ones.
1734
1735         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.startEditingLastProperty):
1736         Shift-tabbing from the selector field should focus on the last editable property of the previous CSS rule.
1737         When no editable properties are present, a new blank property should be added after the commented out ones.
1738
1739         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetCSSStyleDeclarationEditorFocusMoved):
1740         When navigating between properties skip the commented out ones.
1741
1742         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._editablePropertyAfter):
1743         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._editablePropertyBefore):
1744         * UserInterface/Views/SpreadsheetStyleProperty.js:
1745         (WI.SpreadsheetStyleProperty.prototype.get enabled):
1746         (WI.SpreadsheetStyleProperty.prototype._update):
1747
1748 2018-01-19  Nikita Vasilyev  <nvasilyev@apple.com>
1749
1750         Web Inspector: Make styles sidebar always LTR
1751         https://bugs.webkit.org/show_bug.cgi?id=175357
1752         <rdar://problem/33787988>
1753
1754         Reviewed by Joseph Pecoraro.
1755
1756         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
1757         (WI.SpreadsheetRulesStyleDetailsPanel):
1758
1759 2018-01-19  Keith Miller  <keith_miller@apple.com>
1760
1761         HaveInternalSDK includes should be "#include?"
1762         https://bugs.webkit.org/show_bug.cgi?id=179670
1763
1764         Reviewed by Dan Bernstein.
1765
1766         * Configurations/Base.xcconfig:
1767
1768 2018-01-18  Dan Bernstein  <mitz@apple.com>
1769
1770         [Xcode] Streamline and future-proof target-macOS-version-dependent build setting definitions
1771         https://bugs.webkit.org/show_bug.cgi?id=181803
1772
1773         Reviewed by Tim Horton.
1774
1775         * Configurations/Base.xcconfig: Updated.
1776         * Configurations/DebugRelease.xcconfig: Ditto.
1777         * Configurations/Version.xcconfig: Ditto.
1778
1779 2018-01-18  Devin Rousso  <webkit@devinrousso.com>
1780
1781         Web Inspector: Canvas Tab: record button on canvas card doesn't always show on hover, or is misplaced
1782         https://bugs.webkit.org/show_bug.cgi?id=179183
1783
1784         Reviewed by Joseph Pecoraro.
1785
1786         * UserInterface/Views/CanvasOverviewContentView.css:
1787         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop): Deleted.
1788
1789 2018-01-17  Devin Rousso  <webkit@devinrousso.com>
1790
1791         Web Inspector: clicking on a path component that has no siblings should select it
1792         https://bugs.webkit.org/show_bug.cgi?id=181772
1793
1794         Reviewed by Joseph Pecoraro.
1795
1796         * UserInterface/Views/HierarchicalPathComponent.js:
1797         (WI.HierarchicalPathComponent.prototype._updateSelectElement):
1798         (WI.HierarchicalPathComponent.prototype._selectElementMouseDown):
1799
1800 2018-01-17  Joseph Pecoraro  <pecoraro@apple.com>
1801
1802         Web Inspector: Add back localized strings for Styles sidebar panels
1803         https://bugs.webkit.org/show_bug.cgi?id=181748
1804         <rdar://problem/36583184>
1805
1806         Reviewed by Brian Burg.
1807
1808         * Localizations/en.lproj/localizedStrings.js:
1809         * UserInterface/Views/ComputedStyleDetailsSidebarPanel.js:
1810         (WI.ComputedStyleDetailsSidebarPanel):
1811         * UserInterface/Views/RulesStyleDetailsSidebarPanel.js:
1812         (WI.RulesStyleDetailsSidebarPanel):
1813         * UserInterface/Views/VisualStyleDetailsSidebarPanel.js:
1814         (WI.VisualStyleDetailsSidebarPanel):
1815         Add back localized strings for panel titles lost in r225547.
1816
1817 2018-01-17  Joseph Pecoraro  <pecoraro@apple.com>
1818
1819         Web Inspector: Super long URL string causes bad wrapping in Resources detail sidebar
1820         https://bugs.webkit.org/show_bug.cgi?id=181617
1821
1822         Reviewed by Brian Burg.
1823
1824         * UserInterface/Views/DetailsSection.css:
1825         (.details-section > .content > .group > .row.simple > .value):
1826         Set the break to all characters.
1827
1828 2018-01-16  Matt Baker  <mattbaker@apple.com>
1829
1830         Web Inspector: Canvas tab: typing a "space" in the QuickConsole shouldn't trigger a recording
1831         https://bugs.webkit.org/show_bug.cgi?id=181706
1832         <rdar://problem/36558221>
1833
1834         Reviewed by Joseph Pecoraro.
1835
1836         * UserInterface/Views/CanvasOverviewContentView.js:
1837         (WI.CanvasOverviewContentView):
1838         (WI.CanvasOverviewContentView.prototype._handleSpace):
1839
1840 2018-01-16  Joseph Pecoraro  <pecoraro@apple.com>
1841
1842         Web Inspector: Make Console's Execution Context picker stand out when it is non-default
1843         https://bugs.webkit.org/show_bug.cgi?id=181628
1844         <rdar://problem/36492044>
1845
1846         Reviewed by Matt Baker.
1847
1848         * UserInterface/Views/HierarchicalPathComponent.css:
1849         (.hierarchical-path-component > .selector-arrows):
1850         * UserInterface/Views/HierarchicalPathComponent.js:
1851         (WI.HierarchicalPathComponent.prototype.set selectorArrows):
1852         Switch to SVG element so we can style the arrows.
1853
1854         * UserInterface/Views/QuickConsole.css:
1855         (.quick-console > .navigation-bar > .hierarchical-path .execution-context):
1856         (.quick-console > .navigation-bar > .hierarchical-path .execution-context .separator):
1857         (.quick-console > .navigation-bar > .hierarchical-path.non-default-execution-context .execution-context):
1858         (.quick-console > .navigation-bar > .hierarchical-path.non-default-execution-context .execution-context .selector-arrows):
1859         Styles for the execution context picker. We hide the unused separator
1860         and instead use margin so that the selected background and border don't
1861         have an extra 7px on the right/end side.
1862
1863         * UserInterface/Views/QuickConsole.js:
1864         (WI.QuickConsole.prototype._activeExecutionContextChanged):
1865         Toggle the non-default class name on the path.
1866
1867 2018-01-16  Nikita Vasilyev  <nvasilyev@apple.com>
1868
1869         Web Inspector: Styles: pressing down key should select first item from completion list when focusing on empty value
1870         https://bugs.webkit.org/show_bug.cgi?id=181633
1871         <rdar://problem/36501797>
1872
1873         Reviewed by Joseph Pecoraro.
1874
1875         * UserInterface/Views/SpreadsheetTextField.js:
1876         (WI.SpreadsheetTextField.prototype._updateCompletions):
1877
1878 2018-01-16  Nikita Vasilyev  <nvasilyev@apple.com>
1879
1880         Web Inspector: Styles Redesign: Long value causes bad wrapping
1881         https://bugs.webkit.org/show_bug.cgi?id=181618
1882         <rdar://problem/36485175>
1883
1884         Reviewed by Joseph Pecoraro.
1885
1886         Wrap long values only when editing.
1887
1888         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1889         (.spreadsheet-style-declaration-editor .value.editing):
1890
1891 2018-01-16  Nikita Vasilyev  <nvasilyev@apple.com>
1892
1893         Web Inspector: Styles Redesign: clicking on the white space after the property sometimes places a blank property at the wrong index
1894         https://bugs.webkit.org/show_bug.cgi?id=179585
1895         <rdar://problem/35490780>
1896
1897         Reviewed by Joseph Pecoraro.
1898
1899         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
1900         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyRemoved):
1901         Layout call is needed to update data-property-index attributes on the property views.
1902
1903 2018-01-16  Joseph Pecoraro  <pecoraro@apple.com>
1904
1905         Web Inspector: Network Tab - Export HAR Context Menu not working
1906         https://bugs.webkit.org/show_bug.cgi?id=181694
1907         <rdar://problem/36479197>
1908
1909         Reviewed by Brian Burg.
1910
1911         * UserInterface/Views/NetworkTableContentView.js:
1912         (WI.NetworkTableContentView.prototype.tableCellContextMenuClicked):
1913         Ensure `this` works in the handler.
1914
1915 2018-01-15  Matt Baker  <mattbaker@apple.com>
1916
1917         Web Inspector: TabBar redesign: add context menu to TabBar for toggling available tabs
1918         https://bugs.webkit.org/show_bug.cgi?id=181448
1919         <rdar://problem/36383298>
1920
1921         Reviewed by Devin Rousso.
1922
1923         * UserInterface/Base/Main.js:
1924         (WI.loaded):
1925         (WI.contentLoaded):
1926         Reorder production tab classes and default (open) tabs.
1927         (WI.registerTabClass): Removed.
1928         Not used.
1929
1930         * UserInterface/Base/Object.js:
1931         Remove notification that is no longer used.
1932
1933         * UserInterface/Views/GeneralTabBarItem.js:
1934         (WI.GeneralTabBarItem):
1935         (WI.GeneralTabBarItem.prototype.set title):
1936         (WI.GeneralTabBarItem.prototype._handleContextMenuEvent): Deleted.
1937         Remove per-tab context menu (provided Close Tab and Close Other Tabs).
1938
1939         * UserInterface/Views/NewTabContentView.js:
1940         (WI.NewTabContentView):
1941
1942         * UserInterface/Views/TabBar.js:
1943         (WI.TabBar):
1944         (WI.TabBar.prototype._handleContextMenu):
1945
1946         * UserInterface/Views/TabBrowser.js:
1947         (WI.TabBrowser):
1948         (WI.TabBrowser._handleNewTabContextMenu): Deleted.
1949         No longer needed.
1950
1951 2018-01-13  Nikita Vasilyev  <nvasilyev@apple.com>
1952
1953         Web Inspector: Styles Redesign: properties should never be semitransparent or crossed out while editing
1954         https://bugs.webkit.org/show_bug.cgi?id=180793
1955         <rdar://problem/36038813>
1956
1957         Reviewed by Devin Rousso.
1958
1959         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1960         (.spreadsheet-style-declaration-editor .value.editing):
1961         (.spreadsheet-style-declaration-editor .property:matches(.invalid-name, .other-vendor, .overridden):not(.disabled) .content > *):
1962         (.spreadsheet-style-declaration-editor .property.invalid-name:not(.disabled) .content > *):
1963         (.spreadsheet-style-declaration-editor .property.invalid-value:not(.disabled) .content .value):
1964         (.spreadsheet-style-declaration-editor .property.not-inherited .content > *):
1965         * UserInterface/Views/SpreadsheetStyleProperty.js:
1966         (WI.SpreadsheetStyleProperty.prototype._update):
1967
1968 2018-01-12  Joseph Pecoraro  <pecoraro@apple.com>
1969
1970         Web Inspector: Drop support for iOS 7 targets
1971         https://bugs.webkit.org/show_bug.cgi?id=181549
1972         <rdar://problem/36444813>
1973
1974         Reviewed by Brian Burg.
1975
1976         * Versions/Inspector-iOS-7.0.json: Removed.
1977         * UserInterface/Protocol/Legacy/7.0/InspectorBackendCommands.js: Removed.
1978         Remove protocol snapshot and generated commands for iOS 7.
1979
1980         * UserInterface/Base/Main.js:
1981         * UserInterface/Controllers/BreakpointPopoverController.js:
1982         (WI.BreakpointPopoverController.prototype._createPopoverContent):
1983         * UserInterface/Controllers/DebuggerManager.js:
1984         (WI.DebuggerManager.prototype._setBreakpoint):
1985         * UserInterface/Controllers/SourceMapManager.js:
1986         (WI.SourceMapManager.prototype._loadAndParseSourceMap):
1987         * UserInterface/Models/Instrument.js:
1988         (WI.Instrument.startLegacyTimelineAgent):
1989         * UserInterface/Models/ResourceTimingData.js:
1990         * UserInterface/Models/ScriptTimelineRecord.js:
1991         (WI.ScriptTimelineRecord.EventType.displayName):
1992         * UserInterface/Models/SourceMapResource.js:
1993         (WI.SourceMapResource.prototype.requestContentFromBackend):
1994         * UserInterface/Protocol/CSSObserver.js:
1995         (WI.CSSObserver.prototype.regionLayoutUpdated): Deleted.
1996         * UserInterface/Protocol/RemoteObject.js:
1997         (WI.RemoteObject.fromPayload):
1998         Remove code that was only necessary to support iOS 7.
1999
2000 2018-01-12  Joseph Pecoraro  <pecoraro@apple.com>
2001
2002         Web Inspector: Support JSX (React) syntax highlighting
2003         https://bugs.webkit.org/show_bug.cgi?id=181607
2004         <rdar://problem/36442564>
2005
2006         Reviewed by Brian Burg.
2007
2008         * UserInterface/Base/MIMETypeUtilities.js:
2009         (WI.mimeTypeForFileExtension):
2010         (WI.fileExtensionForMIMEType):
2011         * UserInterface/Models/Resource.js:
2012         Support the jsx extension and mime types.
2013
2014         * UserInterface/Main.html:
2015         * Scripts/update-codemirror-resources.rb:
2016         * UserInterface/External/CodeMirror/jsx.js: Added.
2017         Include new mode from CodeMirror@d8926768.
2018
2019 2018-01-11  Joseph Pecoraro  <pecoraro@apple.com>
2020
2021         Web Inspector: Rename "Query String" section as "Query String Parameters" for clarity
2022         https://bugs.webkit.org/show_bug.cgi?id=181464
2023
2024         Reviewed by Darin Adler.
2025
2026         * Localizations/en.lproj/localizedStrings.js:
2027         * UserInterface/Views/ResourceHeadersContentView.js:
2028         (WI.ResourceHeadersContentView.prototype.initialLayout):
2029
2030 2018-01-11  Joseph Pecoraro  <pecoraro@apple.com>
2031
2032         Web Inspector: Remove unused variable in WI.DebuggerSidebarPanel
2033         https://bugs.webkit.org/show_bug.cgi?id=181517
2034
2035         Reviewed by Matt Baker.
2036
2037         * UserInterface/Views/DebuggerSidebarPanel.js:
2038
2039 2018-01-10  Joseph Pecoraro  <pecoraro@apple.com>
2040
2041         REGRESSION(r218975): Web Inspector: Add back NavigationSidebarPanel initialization parameter used by SearchSidebarPanel (top overflow shadow)
2042         https://bugs.webkit.org/show_bug.cgi?id=181518
2043         <rdar://problem/36427197>
2044
2045         Reviewed by Matt Baker.
2046
2047         * UserInterface/Views/NavigationSidebarPanel.css:
2048         (.sidebar > .panel.navigation > .overflow-shadow.top):
2049         * UserInterface/Views/NavigationSidebarPanel.js:
2050         (WI.NavigationSidebarPanel):
2051         Add back the initialization parameter still used by SearchSidebarPanel
2052         and add back its implementation. There were still references to
2053         dynamically update _topOverflowShadowElement in NavigationSidebarPanel.
2054
2055 2018-01-10  Joseph Pecoraro  <pecoraro@apple.com>
2056
2057         Web Inspector: Incorrect check with WI.debuggableType
2058         https://bugs.webkit.org/show_bug.cgi?id=181515
2059         <rdar://problem/36425509>
2060
2061         Reviewed by Brian Burg.
2062
2063         * UserInterface/Base/Main.js:
2064         (WI.contentLoaded):
2065         This moved to WI.sharedApp a while ago.
2066
2067 2018-01-10  Matt Baker  <mattbaker@apple.com>
2068
2069         Web Inspector: Canvas tab: throttle recording slider updates
2070         https://bugs.webkit.org/show_bug.cgi?id=180839
2071         <rdar://problem/36057849>
2072
2073         Reviewed by Joseph Pecoraro
2074
2075         * UserInterface/Base/Utilities.js:
2076         Add Object.throttle and Function.cancelThrottle. Repeated calls to a
2077         function on a throttled object are delayed, so that the function isn't
2078         invoked more frequently than the specified delay value.
2079
2080         For a description of throttling behavior see:
2081           - http://www.chrislondon.co/throttling-vs-debouncing
2082           - http://benalman.com/projects/jquery-throttle-debounce-plugin
2083
2084         * UserInterface/Views/RecordingContentView.js:
2085         (WI.RecordingContentView.prototype.updateActionIndex):
2086         Throttle frequency of canvas snapshot creation to 200ms.
2087         (WI.RecordingContentView.prototype.hidden):
2088         Prevent trailing edge call after hiding the view.
2089
2090 2018-01-10  Joseph Pecoraro  <pecoraro@apple.com>
2091
2092         Web Inspector: Should not try to autocomplete subsections of a string
2093         https://bugs.webkit.org/show_bug.cgi?id=181461
2094         <rdar://problem/36369421>
2095
2096         Reviewed by Brian Burg.
2097
2098         * UserInterface/Controllers/CodeMirrorCompletionController.js:
2099         (WI.CodeMirrorCompletionController.prototype._completeAtCurrentPosition):
2100         Disable autocompletion within strings.
2101
2102 2018-01-09  Joseph Pecoraro  <pecoraro@apple.com>
2103
2104         REGRESSION(r201855): Web Inspector: Should see "length" autocompletion suggestion on a string literal
2105         https://bugs.webkit.org/show_bug.cgi?id=181462
2106         <rdar://problem/36390699>
2107
2108         Reviewed by Matt Baker.
2109
2110         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
2111         (WI.JavaScriptRuntimeCompletionProvider.prototype.completionControllerCompletionsNeeded.inspectedPage_evalResult_getCompletions):
2112         This is code that runs on the inspected target, which may have an old version of
2113         WebKit/JavaScriptCore, so don't use new syntax like this.
2114
2115         (WI.JavaScriptRuntimeCompletionProvider.prototype.completionControllerCompletionsNeeded):
2116         We intended to return the result by as a JSON value instead of a RemoteObject.
2117
2118 2018-01-09  Ross Kirsling  <ross.kirsling@sony.com>
2119
2120         Web Inspector: Layers sidebar shows popover on selection even when collapsed
2121         https://bugs.webkit.org/show_bug.cgi?id=181465
2122
2123         Reviewed by Matt Baker.
2124
2125         * UserInterface/Views/LayerDetailsSidebarPanel.js:
2126         (WI.LayerDetailsSidebarPanel.prototype.selectNodeByLayerId):
2127         Have sidebar show itself if necessary before displaying popover.
2128
2129 2018-01-08  Joseph Pecoraro  <pecoraro@apple.com>
2130
2131         Web Inspector: Find next / previous within a resource content view does not have bouncy highlight when editor scrolls
2132         https://bugs.webkit.org/show_bug.cgi?id=181279
2133         <rdar://problem/36291097>
2134
2135         Reviewed by Brian Burg.
2136
2137         * UserInterface/Views/TextEditor.js:
2138         (WI.TextEditor.prototype._revealSearchResult):
2139         Reposition the bouncy highlight on scroll based on the CodeMirror
2140         line/ch position of the search result.
2141
2142         (WI.TextEditor.prototype._removeBouncyHighlightElementIfNeeded):
2143         Track the bouncy highlight scroll handler in a member variable so that
2144         we always remember to remove it and don't leak scroll handlers.
2145
2146 2018-01-07  David Kilzer  <ddkilzer@apple.com>
2147
2148         Enable -Wcast-qual for WebInspectorUI, WebKitLegacy, WebKit projects
2149         <https://webkit.org/b/181256>
2150         <rdar://problem/36281730>
2151
2152         Reviewed by Darin Adler.
2153
2154         * Configurations/Base.xcconfig:
2155         (WARNING_CFLAGS): Add -Wcast-qual.
2156
2157 2018-01-05  Joseph Pecoraro  <pecoraro@apple.com>
2158
2159         Web Inspector: Add another Protocol Version
2160         https://bugs.webkit.org/show_bug.cgi?id=181354
2161         <rdar://problem/35432817>
2162
2163         Reviewed by Matt Baker.
2164
2165         * UserInterface/Protocol/Legacy/11.3/InspectorBackendCommands.js: Added.
2166         * Versions/Inspector-iOS-11.3.json: Added.
2167
2168 2018-01-04  Devin Rousso  <webkit@devinrousso.com>
2169
2170         Web Inspector: replace HTMLCanvasElement with CanvasRenderingContext for instrumentation logic
2171         https://bugs.webkit.org/show_bug.cgi?id=180770
2172
2173         Reviewed by Joseph Pecoraro.
2174
2175         * UserInterface/Models/Canvas.js:
2176         (WI.Canvas.fromPayload):
2177         (WI.Canvas.prototype.get contextType):
2178         (WI.Canvas.prototype.saveIdentityToCookie):
2179         (WI.Canvas.prototype.get frame): Deleted.
2180
2181 2018-01-04  Joseph Pecoraro  <pecoraro@apple.com>
2182
2183         REGRESSION (r225709): Web Inspector: CSS Source maps not loading
2184         https://bugs.webkit.org/show_bug.cgi?id=181314
2185         <rdar://problem/36177620>
2186
2187         Reviewed by Brian Burg.
2188
2189         * UserInterface/Controllers/SourceMapManager.js:
2190         (WI.SourceMapManager.prototype._loadAndParseSourceMap):
2191         * UserInterface/Models/SourceMapResource.js:
2192         (WI.SourceMapResource.prototype.requestContentFromBackend):
2193         Correct this so that we only fall back to a reasonable frame id
2194         if we couldn't determine a frame id from earlier. Previously this
2195         was incorrectly clearing the frame id if we had gotten it earlier.
2196
2197         * UserInterface/Test.html:
2198         * UserInterface/Test/Test.js:
2199         (WI.loaded):
2200         Add SourceMap related files for tests.
2201
2202 2018-01-04  Brian Burg  <bburg@apple.com>
2203
2204         Web Inspector: Capture Element Screenshot looks fuzzy
2205         https://bugs.webkit.org/show_bug.cgi?id=175734
2206         <rdar://problem/33803377>
2207
2208         Reviewed by Joseph Pecoraro and Simon Fraser.
2209
2210         Spruce up these functions a bit. They now optionally return a promise
2211         if no callback is supplied. They now can take either a WI.DOMNode or a node id.
2212
2213         * UserInterface/Controllers/DOMTreeManager.js:
2214         (WI.DOMTreeManager.prototype.querySelector):
2215         (WI.DOMTreeManager.prototype.querySelectorAll):
2216
2217 2018-01-04  Brian Burg  <bburg@apple.com>
2218
2219         Web Inspector: add RemoteObject.fetchProperties and some basic tests for RemoteObject API
2220         https://bugs.webkit.org/show_bug.cgi?id=180945
2221
2222         Reviewed by Joseph Pecoraro.
2223
2224         Add a new method, fetchProperties, which async fetches an arbitrary list of properties
2225         from a RemoteObject. This is intended for writing tests and other quick evaluations,
2226         so it has some behaviors that are suitable in these situations:
2227         - If the evaluation throws an exception, the result will reject with that exception.
2228         - If there is a protocol error for some reason, the result will reject with an exception.
2229         - Non-string and non-number keys cause an exception, as this is probably not intended.
2230         - Does not accept a callback, returns a promise only. New code should use async.
2231
2232         For full fidelity introspection of property descriptors, clients should use the existing
2233         getOwnPropertyDescriptor[s] class of methods.
2234
2235         * UserInterface/Protocol/RemoteObject.js:
2236         (WI.RemoteObject.prototype.async.fetchProperties): Added.
2237         - Validate specified keys and remove duplicates.
2238         - Request properties one-by-one to avoid fetching all descriptors and dealing with previews.
2239         - Unwrap returned primitive values to avoid unnecessary munging in tests.
2240
2241         (WI.RemoteObject.prototype.getProperty):
2242         - Rework this to return a promise if no callback was supplied.
2243         - Introduce stricter property type checking to avoid unintended mistakes.
2244
2245         (WI.RemoteObject.prototype.callFunction):
2246         - Rework this to return a promise if no callback was supplied.
2247         - Turn thrown exceptions and protocol errors into rejected promises.
2248
2249 2018-01-04  Joseph Pecoraro  <pecoraro@apple.com>
2250
2251         Web Inspector: ⌘G / ⇧⌘G text search does not working after closing find banner
2252         https://bugs.webkit.org/show_bug.cgi?id=181280
2253         <rdar://problem/36291175>
2254
2255         Reviewed by Matt Baker.
2256
2257         * UserInterface/Views/ContentBrowser.js:
2258         (WI.ContentBrowser.prototype._findBannerDidHide):
2259         When the find banner is hidden trigger a new ContentView method,
2260         searchHidden instead of the destructive searchCleared. This allows
2261         most content views (text editors, DOM tree, Network Headers view)
2262         to keep their populated search results.
2263
2264         * UserInterface/Views/ContentView.js:
2265         (WI.ContentView.prototype.searchHidden):
2266         * UserInterface/Views/LogContentView.js:
2267         (WI.LogContentView.prototype.searchHidden):
2268         By default searchHidden does nothing. The Console's LogContentView
2269         treats the find banner differently and clears its search results.
2270
2271         * UserInterface/Views/TextEditor.js:
2272         (WI.TextEditor.prototype.searchCleared):
2273         Modernize some code while working in this area.
2274
2275         * UserInterface/Views/Main.css:
2276         (.bouncy-highlight):
2277         Ensure black text on yellow background in the bouncy highlight. In the
2278         DOM Tree it could have been white if the find banner was closed.
2279
2280 2018-01-03  Ting-Wei Lan  <lantw44@gmail.com>
2281
2282         Replace hard-coded paths in shebangs with #!/usr/bin/env
2283         https://bugs.webkit.org/show_bug.cgi?id=181040
2284
2285         Reviewed by Alex Christensen.
2286
2287         * Scripts/combine-resources.pl:
2288         * Scripts/copy-user-interface-resources-dryrun.rb:
2289         * Scripts/copy-user-interface-resources.pl:
2290         * Scripts/fix-worker-imports-for-optimized-builds.pl:
2291         * Scripts/remove-console-asserts-dryrun.rb:
2292         * Scripts/remove-console-asserts.pl:
2293         * Scripts/update-LegacyInspectorBackendCommands.rb:
2294         * Scripts/update-codemirror-resources.rb:
2295         * WebInspectorUI.vcxproj/build-webinspectorui.pl:
2296
2297 2018-01-03  Joseph Pecoraro  <pecoraro@apple.com>
2298
2299         Web Inspector: "Log Value" context menu is sometimes unavailable
2300         https://bugs.webkit.org/show_bug.cgi?id=181278
2301         <rdar://problem/36281649>
2302
2303         Reviewed by Devin Rousso.
2304
2305         * UserInterface/Views/ObjectPreviewView.css:
2306         (.object-preview > .title):
2307         * UserInterface/Views/ObjectTreeView.css:
2308         (.object-tree.expanded > .title):
2309         Make the expanded object title information 16px tall to match ObjectTree
2310         tree element row heights. This eliminates the floating console message
2311         location from overlapping the first ObjectTree's TreeElement and causing
2312         truncation and other behavior issues (like Context Menu identification).
2313
2314 2018-01-03  Joseph Pecoraro  <pecoraro@apple.com>
2315
2316         Web Inspector: RTL - DOM Tree Element selection doesn't work
2317         https://bugs.webkit.org/show_bug.cgi?id=181275
2318         <rdar://problem/36290450>
2319
2320         Reviewed by Devin Rousso.
2321
2322         * UserInterface/Views/TreeOutline.js:
2323         (WI.TreeOutline.prototype.treeElementFromEvent):
2324         Provide a better explanation for why we are making the `x` adjustment here,
2325         to detect the inner most tree element along the horizontal. Fix the algorithm
2326         for RTL, since the intent is to adjust to the trailing edge of the container
2327         which is on the opposite side in RTL.
2328
2329 2018-01-03  Joseph Pecoraro  <pecoraro@apple.com>
2330
2331         Web Inspector: Find banner sometimes does not work (when already populated and shown for first time on resource)
2332         https://bugs.webkit.org/show_bug.cgi?id=181255
2333         <rdar://problem/36248855>
2334
2335         Reviewed by Matt Baker.
2336
2337         * UserInterface/Views/TextEditor.js:
2338         (WI.TextEditor.prototype.set string):
2339         Defer any early searches until the initial content of a TextEditor has been set.
2340         Such searches can happen when the FindBanner already has content when a
2341         ContentView is first opened and needs to load its content from the backend.
2342         Further, even though the content may be loaded from the backend before the
2343         search results, microtask hops might cause the content to get to the TextEditor
2344         after the search results.
2345
2346 2018-01-03  Joseph Pecoraro  <pecoraro@apple.com>
2347
2348         REGRESSION: Web Inspector: Debugger tab doesn't restore selected resource on reload
2349         https://bugs.webkit.org/show_bug.cgi?id=181253
2350         <rdar://problem/36280564>
2351
2352         Reviewed by Matt Baker.
2353
2354         * UserInterface/Views/DebuggerSidebarPanel.js:
2355         (WI.DebuggerSidebarPanel.prototype.restoreStateFromCookie):
2356         Add braces to ensure the trailing else is actually trailing the outer
2357         chain as it was intended to be.
2358
2359 2018-01-02  Joseph Pecoraro  <pecoraro@apple.com>
2360
2361         Web Inspector: Clicking source location link in Console unexpectedly jumps to Network tab
2362         https://bugs.webkit.org/show_bug.cgi?id=181229
2363         <rdar://problem/36075219>
2364
2365         Reviewed by Matt Baker.
2366
2367         * UserInterface/Base/Main.js:
2368         Cleanup linkifyURLAsNode. Ignore Search tab in generic handlePossibleLinkClick
2369         when not already in the Search tab.
2370
2371         * UserInterface/Views/CallFrameView.js:
2372         (WI.CallFrameView):
2373         Ignore Search and Network tab in CallFrame links.
2374
2375         * UserInterface/Views/TabBrowser.js:
2376         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
2377         Improve style.
2378
2379 == Rolled over to ChangeLog-2018-01-01 ==