Web Inspector: Canvas: recordings with a single frame sometimes missing TreeElement
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2019-02-21  Devin Rousso  <drousso@apple.com>
2
3         Web Inspector: Canvas: recordings with a single frame sometimes missing TreeElement
4         https://bugs.webkit.org/show_bug.cgi?id=194687
5
6         Reviewed by Joseph Pecoraro.
7
8         * UserInterface/Views/CanvasSidebarPanel.js:
9         (WI.CanvasSidebarPanel):
10         Wait until the entire `Recording` has been processed before setting the selected action.
11
12         * UserInterface/Views/CanvasSidebarPanel.css:
13         (.sidebar > .panel.navigation.canvas.has-recordings > .content > .recording-content):
14         Drive-by: ensure that the recording `TreeOutline` container element has the full height to
15         take advantage of for virtualization.
16
17         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
18         (WI.RecordingStateDetailsSidebarPanel.prototype.set recording):
19         Drive-by: clear the `DataGrid` list when changing recordings since we removed all subviews.
20
21 2019-02-21  Devin Rousso  <drousso@apple.com>
22
23         Web Inspector: DOM Debugger: node-specific event breakpoints aren't cleared/recalculated on navigation
24         https://bugs.webkit.org/show_bug.cgi?id=194874
25         <rdar://problem/48253415>
26
27         Reviewed by Joseph Pecoraro.
28
29         * UserInterface/Controllers/DOMManager.js:
30         (WI.DOMManager.prototype._setDocument):
31         (WI.DOMManager.prototype.removeBreakpointForEventListener):
32
33 2019-02-21  Devin Rousso  <drousso@apple.com>
34
35         Web Inspector: macOS user agent option should be available in device settings menu
36         https://bugs.webkit.org/show_bug.cgi?id=194885
37         <rdar://problem/48259253>
38
39         Reviewed by Joseph Pecoraro.
40
41         * UserInterface/Base/Main.js:
42         (WI._handleDeviceSettingsToolbarButtonClicked):
43
44 2019-02-20  Joseph Pecoraro  <pecoraro@apple.com>
45
46         Web Inspector: RTL: Scripts Timeline loading indicator has incorrect margins
47         https://bugs.webkit.org/show_bug.cgi?id=194882
48
49         Reviewed by Matt Baker.
50
51         * UserInterface/Views/TimelineRecordingContentView.css:
52         (.content-view.timeline-recording > .content-browser .recording-progress > .status > .indeterminate-progress-spinner):
53
54 2019-02-20  Andy Estes  <aestes@apple.com>
55
56         [Xcode] Add SDKVariant.xcconfig to various Xcode projects
57         https://bugs.webkit.org/show_bug.cgi?id=194869
58
59         Rubber-stamped by Jer Noble.
60
61         * WebInspectorUI.xcodeproj/project.pbxproj:
62
63 2019-02-19  Joseph Pecoraro  <pecoraro@apple.com>
64
65         Web Inspector: Improve ES6 Class instances in Heap Snapshot instances view
66         https://bugs.webkit.org/show_bug.cgi?id=172848
67         <rdar://problem/25709212>
68
69         Reviewed by Mark Lam.
70
71         * UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:
72         (HeapSnapshot):
73         Support the new snapshot version. The only thing that changes are the
74         node flags, and its actually completely compatible with version 1.
75
76         (HeapSnapshot.updateCategoriesAndMetadata):
77         List the count of object type instances in each class category.
78
79         (HeapSnapshot.prototype.serializeNode):
80         Include whether or not the node is an object type.
81
82         * UserInterface/Proxies/HeapSnapshotNodeProxy.js:
83         (WebInspector.HeapSnapshotNodeProxy):
84         (WebInspector.HeapSnapshotNodeProxy.deserialize):
85         Add a new Node isObjectType property based on the new data.
86
87         * UserInterface/Views/HeapSnapshotClassDataGridNode.js:
88         (WebInspector.HeapSnapshotClassDataGridNode.prototype.createCellContent):
89         * UserInterface/Views/HeapSnapshotClusterContentView.js:
90         (WebInspector.HeapSnapshotClusterContentView.iconStyleClassNameForClassName):
91         If a class contains 50% or more object type instances then treat it as such
92         instead of defaulting to native.
93
94         * UserInterface/Views/HeapSnapshotDataGridTree.js:
95         (WebInspector.HeapSnapshotInstancesDataGridTree.prototype.populateTopLevel):
96         * UserInterface/Views/HeapSnapshotInstanceDataGridNode.js:
97         (WebInspector.HeapSnapshotInstanceDataGridNode.prototype.createCellContent):
98         We can be more specific than the default if the individual instance is
99         known to be an object type.
100
101 2019-02-19  Truitt Savell  <tsavell@apple.com>
102
103         Unreviewed, rolling out r241784.
104
105         Broke all OpenSource builds.
106
107         Reverted changeset:
108
109         "Web Inspector: Improve ES6 Class instances in Heap Snapshot
110         instances view"
111         https://bugs.webkit.org/show_bug.cgi?id=172848
112         https://trac.webkit.org/changeset/241784
113
114 2019-02-19  Joseph Pecoraro  <pecoraro@apple.com>
115
116         Web Inspector: Improve ES6 Class instances in Heap Snapshot instances view
117         https://bugs.webkit.org/show_bug.cgi?id=172848
118         <rdar://problem/25709212>
119
120         Reviewed by Mark Lam.
121
122         * UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:
123         (HeapSnapshot):
124         Support the new snapshot version. The only thing that changes are the
125         node flags, and its actually completely compatible with version 1.
126
127         (HeapSnapshot.updateCategoriesAndMetadata):
128         List the count of object type instances in each class category.
129
130         (HeapSnapshot.prototype.serializeNode):
131         Include whether or not the node is an object type.
132
133         * UserInterface/Proxies/HeapSnapshotNodeProxy.js:
134         (WebInspector.HeapSnapshotNodeProxy):
135         (WebInspector.HeapSnapshotNodeProxy.deserialize):
136         Add a new Node isObjectType property based on the new data.
137
138         * UserInterface/Views/HeapSnapshotClassDataGridNode.js:
139         (WebInspector.HeapSnapshotClassDataGridNode.prototype.createCellContent):
140         * UserInterface/Views/HeapSnapshotClusterContentView.js:
141         (WebInspector.HeapSnapshotClusterContentView.iconStyleClassNameForClassName):
142         If a class contains 50% or more object type instances then treat it as such
143         instead of defaulting to native.
144
145         * UserInterface/Views/HeapSnapshotDataGridTree.js:
146         (WebInspector.HeapSnapshotInstancesDataGridTree.prototype.populateTopLevel):
147         * UserInterface/Views/HeapSnapshotInstanceDataGridNode.js:
148         (WebInspector.HeapSnapshotInstanceDataGridNode.prototype.createCellContent):
149         We can be more specific than the default if the individual instance is
150         known to be an object type.
151
152 2019-02-19  Joseph Pecoraro  <pecoraro@apple.com>
153
154         Web Inspector: Scripts timeline on-going-recording text looks poor in dark mode
155         https://bugs.webkit.org/show_bug.cgi?id=194809
156
157         Reviewed by Matt Baker.
158
159         * UserInterface/Views/TimelineRecordingContentView.css:
160         (.content-view.timeline-recording > .content-browser .recording-progress > .status):
161
162 2019-02-18  Joseph Pecoraro  <pecoraro@apple.com>
163
164         Web Inspector: Provide a way to avoid a recording auto-stop on reload
165         https://bugs.webkit.org/show_bug.cgi?id=194793
166
167         Reviewed by Matt Baker.
168
169         * Localizations/en.lproj/localizedStrings.js:
170         New tooltip.
171
172         * UserInterface/Controllers/TimelineManager.js:
173         (WI.TimelineManager.prototype.willAutoStop):
174         (WI.TimelineManager.prototype.relaxAutoStop):
175         Getter and relaxer for auto stop behavior.
176
177         * UserInterface/Views/AuditNavigationSidebarPanel.js:
178         (WI.AuditNavigationSidebarPanel.prototype.showDefaultContentView):
179         Drive-by fix some whitespace issues.
180
181         * UserInterface/Views/TimelineTabContentView.js:
182         (WI.TimelineTabContentView):
183         (WI.TimelineTabContentView.prototype._showRecordButton):
184         (WI.TimelineTabContentView.prototype._showContinueButton):
185         (WI.TimelineTabContentView.prototype._updateNavigationBarButtons):
186         (WI.TimelineTabContentView.prototype._capturingStartedOrStopped):
187         (WI.TimelineTabContentView.prototype._globalModifierKeysDidChange):
188         (WI.TimelineTabContentView.prototype._continueButtonClicked):
189         Show a "continue" like icon instead of the usual stop button when
190         a recording would auto-stop and the alt key is down. When pressed
191         this button will relax the auto-stop and continue the recording
192         until explicitly stopped by the user.
193
194 2019-02-18  Joseph Pecoraro  <pecoraro@apple.com>
195
196         Web Inspector: Fix a typo causing assertions in ConsoleManager
197         https://bugs.webkit.org/show_bug.cgi?id=194792
198
199         Reviewed by Matt Baker.
200
201         * UserInterface/Controllers/ConsoleManager.js:
202         (WI.ConsoleManager.prototype.initializeLogChannels):
203         Extra comma produced an undefined value in the list.
204
205 2019-02-18  Nikita Vasilyev  <nvasilyev@apple.com>
206
207         Web Inspector: Styles: typing ";" shouldn't focus on the next property when there's open parenthesis or comment
208         https://bugs.webkit.org/show_bug.cgi?id=194789
209
210         Reviewed by Matt Baker.
211
212         * UserInterface/Views/SpreadsheetStyleProperty.js:
213         (WI.SpreadsheetStyleProperty.prototype._handleValueBeforeInput):
214
215 2019-02-18  Joseph Pecoraro  <pecoraro@apple.com>
216
217         Web Inspector: Better categorize CPU usage per-thread / worker
218         https://bugs.webkit.org/show_bug.cgi?id=194564
219
220         Reviewed by Devin Rousso.
221
222         * UserInterface/Controllers/TimelineManager.js:
223         (WI.TimelineManager.prototype.cpuProfilerTrackingUpdated):
224         * UserInterface/Models/CPUTimelineRecord.js:
225         (WI.CPUTimelineRecord.prototype.get mainThreadUsage):
226         (WI.CPUTimelineRecord.prototype.get webkitThreadUsage):
227         (WI.CPUTimelineRecord.prototype.get workerThreadUsage):
228         (WI.CPUTimelineRecord.prototype.get unknownThreadUsage):
229         Build a better record from the protocol events.
230
231 2019-02-18  Devin Rousso  <drousso@apple.com>
232
233         Web Inspector: duplicate left double quotation mark (\u201C) in 'Unable to show certificate for ā€œ%sā€œ.'
234         https://bugs.webkit.org/show_bug.cgi?id=194782
235         <rdar://problem/48159683>
236
237         Reviewed by Joseph Pecoraro.
238
239         * UserInterface/Models/Resource.js:
240         (WI.Resource.prototype.async showCertificate):
241         * Localizations/en.lproj/localizedStrings.js:
242
243 2019-02-18  Eric Carlson  <eric.carlson@apple.com>
244
245         Add MSE logging configuration
246         https://bugs.webkit.org/show_bug.cgi?id=194719
247         <rdar://problem/48122151>
248
249         Reviewed by Joseph Pecoraro.
250
251         * Localizations/en.lproj/localizedStrings.js:
252         * UserInterface/Models/ConsoleMessage.js:
253         * UserInterface/Models/IssueMessage.js:
254         (WI.IssueMessage):
255         * UserInterface/Views/LogContentView.js:
256         (WI.LogContentView):
257         * UserInterface/Views/SettingsTabContentView.js:
258         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
259
260 2019-02-17  Nikita Vasilyev  <nvasilyev@apple.com>
261
262         Web Inspector: Move CSS completion logic from SpreadsheetTextField to SpreadsheetStyleProperty
263         https://bugs.webkit.org/show_bug.cgi?id=194724
264
265         Reviewed by Devin Rousso.
266
267         Move CSS value completion logic from SpreadsheetTextField, a generic text field,
268         to SpreadsheetStyleProperty.
269
270         * UserInterface/Views/SpreadsheetStyleProperty.js:
271         (WI.SpreadsheetStyleProperty.prototype._nameCompletionDataProvider):
272         (WI.SpreadsheetStyleProperty.prototype._valueCompletionDataProvider):
273
274         * UserInterface/Views/SpreadsheetTextField.js:
275         (WI.SpreadsheetTextField):
276         (WI.SpreadsheetTextField.prototype.completionSuggestionsSelectedCompletion):
277         (WI.SpreadsheetTextField.prototype.completionSuggestionsClickedCompletion):
278         (WI.SpreadsheetTextField.prototype._updateCompletions):
279         (WI.SpreadsheetTextField.prototype._showSuggestionsView):
280         (WI.SpreadsheetTextField.prototype._getCompletionPrefix): Deleted.
281
282 2019-02-17  Matt Baker  <mattbaker@apple.com>
283
284         Web Inspector: Frontend performance is very slow reloading theverge.com - 50% of time in TreeOutline _indexOfTreeElement
285         https://bugs.webkit.org/show_bug.cgi?id=193605
286         <rdar://problem/47403986>
287
288         Reviewed by Devin Rousso.
289
290         SelectionController should track an unordered Set of represented objects
291         instead of an ordered set of indexes. This eliminates the costly and
292         error-prone updates needed to keep the selected indexes in sync as items
293         are added and removed from TreeOutline (and Table, to a far lesser extent).
294
295         The SelectionController interface is largely the same. Class and delegate
296         methods have been renamed to reflect the change from indexes to objects.
297         SelectionController tracks selected items in selection order. For the
298         operations that rely on objects being in insertion order, the controller
299         uses a comparator function provided at construction time.
300
301         * UserInterface/Base/IndexSet.js: Removed.
302         No longer used. SelectionController now uses a plain Set.
303
304         * UserInterface/Base/Utilities.js:
305         (value):
306         (get return):
307         Add utilities previously supplied by IndexSet and used by SelectionController.
308
309         * UserInterface/Controllers/SelectionController.js:
310         (WI.SelectionController):
311         (WI.SelectionController.prototype.get lastSelectedItem):
312         (WI.SelectionController.prototype.get selectedItems):
313         (WI.SelectionController.prototype.set allowsMultipleSelection):
314         (WI.SelectionController.prototype.hasSelectedItem):
315         (WI.SelectionController.prototype.selectItem):
316         (WI.SelectionController.prototype.deselectItem):
317         (WI.SelectionController.prototype.selectAll):
318         (WI.SelectionController.prototype.deselectAll):
319         (WI.SelectionController.prototype.removeSelectedItems):
320         (WI.SelectionController.prototype.reset):
321         (WI.SelectionController.prototype.didRemoveItems):
322         (WI.SelectionController.prototype.handleKeyDown):
323         (WI.SelectionController.prototype.handleItemMouseDown):
324         (WI.SelectionController.prototype._deselectAllAndSelect):
325         (WI.SelectionController.prototype._selectItemsFromArrowKey):
326         (WI.SelectionController.prototype._firstSelectableItem):
327         (WI.SelectionController.prototype._lastSelectableItem):
328         (WI.SelectionController.prototype._previousSelectableItem):
329         (WI.SelectionController.prototype._nextSelectableItem):
330         (WI.SelectionController.prototype._updateSelectedItems):
331         (WI.SelectionController.prototype._addRange):
332         (WI.SelectionController.prototype._deleteRange):
333         (WI.SelectionController.prototype.get numberOfItems): Deleted.
334         (WI.SelectionController.prototype.didInsertItem): Deleted.
335         (WI.SelectionController.prototype.handleItemMouseDown.normalizeRange): Deleted.
336         (WI.SelectionController.prototype._nextSelectableIndex): Deleted.
337         (WI.SelectionController.prototype._previousSelectableIndex): Deleted.
338
339         * UserInterface/Main.html:
340         * UserInterface/Test.html:
341         Remove IndexSet.
342
343         * UserInterface/Views/CookieStorageContentView.js:
344         (WI.CookieStorageContentView.prototype.tableIndexForRepresentedObject):
345         (WI.CookieStorageContentView.prototype.tableRepresentedObjectForIndex):
346
347         * UserInterface/Views/DOMTreeOutline.js:
348         (WI.DOMTreeOutline.prototype.objectForSelection):
349
350         * UserInterface/Views/NetworkTableContentView.js:
351         (WI.NetworkTableContentView.prototype.tableIndexForRepresentedObject):
352         (WI.NetworkTableContentView.prototype.tableRepresentedObjectForIndex):
353
354         * UserInterface/Views/Table.js:
355         (WI.Table):
356         (WI.Table.prototype.get selectedRow):
357         (WI.Table.prototype.get selectedRows):
358         (WI.Table.prototype.isRowSelected):
359         (WI.Table.prototype.selectRow):
360         (WI.Table.prototype.deselectRow):
361         (WI.Table.prototype.removeRow):
362         (WI.Table.prototype.removeSelectedRows):
363         (WI.Table.prototype.selectionControllerSelectionDidChange):
364         (WI.Table.prototype.selectionControllerFirstSelectableItem):
365         (WI.Table.prototype.selectionControllerLastSelectableItem):
366         (WI.Table.prototype.selectionControllerPreviousSelectableItem):
367         (WI.Table.prototype.selectionControllerNextSelectableItem):
368         (WI.Table.prototype._handleMouseDown):
369         (WI.Table.prototype._removeRows):
370         (WI.Table.prototype._indexForRepresentedObject):
371         (WI.Table.prototype._representedObjectForIndex):
372         (WI.Table.prototype.selectionControllerNumberOfItems): Deleted.
373         (WI.Table.prototype.selectionControllerNextSelectableIndex): Deleted.
374         (WI.Table.prototype.selectionControllerPreviousSelectableIndex): Deleted.
375         (WI.Table.prototype._toggleSelectedRowStyle): Deleted.
376
377         * UserInterface/Views/TreeOutline.js:
378         (WI.TreeOutline.compareSiblings):
379         (WI.TreeOutline):
380         (WI.TreeOutline.prototype.get selectedTreeElement):
381         (WI.TreeOutline.prototype.set selectedTreeElement):
382         (WI.TreeOutline.prototype.get selectedTreeElements):
383         (WI.TreeOutline.prototype.removeChildAtIndex):
384         (WI.TreeOutline.prototype.removeChildren):
385         (WI.TreeOutline.prototype._rememberTreeElement):
386         (WI.TreeOutline.prototype.getCachedTreeElement):
387         (WI.TreeOutline.prototype.selectionControllerSelectionDidChange):
388         (WI.TreeOutline.prototype.selectionControllerFirstSelectableItem):
389         (WI.TreeOutline.prototype.selectionControllerLastSelectableItem):
390         (WI.TreeOutline.prototype.selectionControllerPreviousSelectableItem):
391         (WI.TreeOutline.prototype.selectionControllerNextSelectableItem):
392         (WI.TreeOutline.prototype.objectForSelection):
393         (WI.TreeOutline._generateStyleRulesIfNeeded):
394         (WI.TreeOutline.prototype.selectionControllerNextSelectableIndex): Deleted.
395         (WI.TreeOutline.prototype.selectionControllerPreviousSelectableIndex): Deleted.
396         (WI.TreeOutline._generateStyleRulesIfNeeded._indexesForSubtree.numberOfElementsInSubtree): Deleted.
397
398 2019-02-15  Joseph Pecoraro  <pecoraro@apple.com>
399
400         Web Inspector: Logging a native function to the console, such as `alert`, produces unhandled rejection
401         https://bugs.webkit.org/show_bug.cgi?id=194740
402
403         Reviewed by Matt Baker.
404
405         * UserInterface/Protocol/RemoteObject.js:
406         (WI.RemoteObject.prototype.findFunctionSourceCodeLocation):
407         In case of a protocol error (common when attempting to get a location
408         for a native function) produce the NoSourceFound result.
409
410         * UserInterface/Views/ConsoleMessageView.js:
411         (WI.ConsoleMessageView.prototype._appendLocationLink):
412         Simplify with an arrow function.
413
414 2019-02-15  Joseph Pecoraro  <pecoraro@apple.com>
415
416         Web Inspector: Some timelines views work, show Legacy CPU timeline
417         https://bugs.webkit.org/show_bug.cgi?id=194738
418
419         Reviewed by Yusuke Suzuki.
420
421         * UserInterface/Views/ContentView.js:
422         (WI.ContentView.createFromRepresentedObject):
423
424 2019-02-15  Aaron Chu  <aaron_chu@apple.com>
425
426         AX: Audit tab should have built-in accessibility tests.
427         https://bugs.webkit.org/show_bug.cgi?id=194005
428         <rdar://problem/47657503>
429
430         Updated built-in accessibility audits test suite.
431
432         Reviewed by Devin Rousso.
433
434         * Localizations/en.lproj/localizedStrings.js:
435         * UserInterface/Controllers/AuditManager.js:
436         (WI.AuditManager.prototype.addDefaultTestsIfNeeded):
437         (WI.AuditManager):
438         (WI.AuditManager.prototype.addDefaultTestsIfNeeded.): Deleted.
439
440 2019-02-15  Nikita Vasilyev  <nvasilyev@apple.com>
441
442         Web Inspector: Dark Mode: commas in CSS selectors are too dim
443         https://bugs.webkit.org/show_bug.cgi?id=194729
444         <rdar://problem/48128592>
445
446         Reviewed by Matt Baker.
447
448         Use `--text-color-tertiary` for both light and dark modes.
449
450         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
451         (.spreadsheet-style-declaration-editor):
452         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
453         (.spreadsheet-css-declaration):
454         (.spreadsheet-css-declaration .selector > span):
455         (@media (prefers-color-scheme: dark)):
456         * UserInterface/Views/Variables.css:
457         (:root):
458
459 2019-02-15  Nikita Vasilyev  <nvasilyev@apple.com>
460
461         Unreviewed, fix intentation.
462
463         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
464         (.sidebar > .panel.details.css-style .rules):
465         (.sidebar > .panel.details.css-style > .content > .rules .section-header):
466
467 2019-02-15  Dean Jackson  <dino@apple.com>
468
469         Allow emulation of user gestures from Web Inspector console
470         https://bugs.webkit.org/show_bug.cgi?id=194725
471         <rdar://problem/48126604>
472
473         Reviewed by Joseph Pecoraro and Devin Rousso.
474
475         Add some UI for emulating a User Gesture when evaluating in the console. This
476         allows the developer to do things that would otherwise require actual interaction
477         with the page, such as start playback of media on iOS.
478
479         * Localizations/en.lproj/localizedStrings.js:
480         * UserInterface/Base/Setting.js: Add a new setting for this option.
481         * UserInterface/Controllers/JavaScriptLogViewController.js:
482         (WI.JavaScriptLogViewController.prototype.consolePromptTextCommitted):
483         * UserInterface/Controllers/RuntimeManager.js: Call evaluate with this new option.
484         (WI.RuntimeManager.prototype.evaluateInInspectedWindow):
485         * UserInterface/Views/LogContentView.js: Add a new checkbox in the upper bar
486         that allows the user to toggle the setting.
487         (WI.LogContentView):
488         (WI.LogContentView.prototype.get navigationItems):
489         (WI.LogContentView.prototype._handleEmulateInUserGestureSettingChanged):
490
491         * UserInterface/Views/NetworkTableContentView.js: Two drive-by typo fixes :)
492         (WI.NetworkTableContentView): perserve -> preserve
493         (WI.NetworkTableContentView.prototype.get navigationItems): checkboxs -> checkboxes
494
495 2019-02-15  Nikita Vasilyev  <nvasilyev@apple.com>
496
497         Web Inspector: Styles: valid values in style attributes are reported as unsupported property values
498         https://bugs.webkit.org/show_bug.cgi?id=194619
499         <rdar://problem/47917373>
500
501         Reviewed by Devin Rousso.
502
503         Payload of inline styles may contain `range` that doesn't match
504         the actual text of the payload - it has an extra empty line at the end.
505         Mismatching ranges caused data corruption.
506
507         * UserInterface/Models/DOMNodeStyles.js:
508         (WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
509
510 2019-02-15  Nikita Vasilyev  <nvasilyev@apple.com>
511
512         Web Inspector: remove unused parameter in _parseStylePropertyPayload
513         https://bugs.webkit.org/show_bug.cgi?id=194642
514
515         Reviewed by Devin Rousso.
516
517         * UserInterface/Models/DOMNodeStyles.js:
518         (WI.DOMNodeStyles.prototype._parseStyleDeclarationPayload):
519         The `styleText` parameter was never used
520
521 2019-02-15  Devin Rousso  <drousso@apple.com>
522
523         Web Inspector: Canvas: all actions after an offscreen path modification are marked as offscreen path errors
524         https://bugs.webkit.org/show_bug.cgi?id=194684
525
526         Reviewed by Joseph Pecoraro.
527
528         * UserInterface/Models/RecordingAction.js:
529         (WI.RecordingAction.prototype.process):
530
531 2019-02-15  Devin Rousso  <drousso@apple.com>
532
533         Web Inspector: Canvas: taking a second recording doesn't select the Initial State by default
534         https://bugs.webkit.org/show_bug.cgi?id=194685
535
536         Reviewed by Matt Baker.
537
538         * UserInterface/Views/CanvasSidebarPanel.js:
539         (WI.CanvasSidebarPanel.prototype._recordingChanged):
540
541 2019-02-14  Commit Queue  <commit-queue@webkit.org>
542
543         Unreviewed, rolling out r241497.
544         https://bugs.webkit.org/show_bug.cgi?id=194676
545
546         New test times out (Requested by NVI on #webkit).
547
548         Reverted changeset:
549
550         "Web Inspector: Styles: valid values in style attributes are
551         reported as unsupported property values"
552         https://bugs.webkit.org/show_bug.cgi?id=194619
553         https://trac.webkit.org/changeset/241497
554
555 2019-02-13  Nikita Vasilyev  <nvasilyev@apple.com>
556
557         Web Inspector: Styles: valid values in style attributes are reported as unsupported property values
558         https://bugs.webkit.org/show_bug.cgi?id=194619
559         <rdar://problem/47917373>
560
561         Reviewed by Devin Rousso.
562
563         Payload of inline styles may contain `range` that doesn't match
564         the actual text of the payload - it has an extra empty line at the end.
565         Mismatching ranges caused data corruption.
566
567         * UserInterface/Models/DOMNodeStyles.js:
568         (WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
569
570 2019-02-13  Joseph Pecoraro  <pecoraro@apple.com>
571
572         Web Inspector: Update combined and minified copyright header for 2018-2019
573         https://bugs.webkit.org/show_bug.cgi?id=194635
574
575         Reviewed by Devin Rousso.
576
577         * Scripts/copy-user-interface-resources.pl:
578
579 2019-02-13  Chris Dumez  <cdumez@apple.com>
580
581         Unreviewed, update localizable strings.
582
583         * Localizations/en.lproj/localizedStrings.js:
584
585 2019-02-12  Joseph Pecoraro  <pecoraro@apple.com>
586
587         Web Inspector: Experimental setting for CPU Usage Timeline improvements
588         https://bugs.webkit.org/show_bug.cgi?id=194556
589
590         Reviewed by Matt Baker.
591
592         * UserInterface/Main.html:
593         * UserInterface/Views/LegacyCPUTimelineView.css: Added.
594         * UserInterface/Views/LegacyCPUTimelineView.js: Added.
595         Copy of CPUTimelineView.js/css to be used when the setting is not set.
596
597         * UserInterface/Views/ContentView.js:
598         (WI.ContentView.createFromRepresentedObject):
599         ContentView to create based on the setting.
600
601         * UserInterface/Base/Setting.js:
602         * UserInterface/Views/SettingsTabContentView.js:
603         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
604         Experimental switch.
605
606 2019-02-12  Joseph Pecoraro  <pecoraro@apple.com>
607
608         Web Inspector: Timeline.prototype.recordsInTimeRange uses a property most records do not have
609         https://bugs.webkit.org/show_bug.cgi?id=194549
610
611         Reviewed by Devin Rousso.
612
613         * UserInterface/Models/Timeline.js:
614         (WI.Timeline.prototype.recordsInTimeRange):
615
616 2019-02-12  Devin Rousso  <drousso@apple.com>
617
618         Web Inspector: Timelines: clicking on an empty space in the overview should deselect any selected record bar
619         https://bugs.webkit.org/show_bug.cgi?id=194365
620         <rdar://problem/47868426>
621
622         Reviewed by Joseph Pecoraro.
623
624         * UserInterface/Views/TimelineRecordBar.js:
625         (WI.TimelineRecordBar.prototype._handleClick):
626         Mark the "click" event so that later listeners know it was handled by `WI.TimelineRecordBar`.
627
628         * UserInterface/Views/TimelineOverview.js:
629         (WI.TimelineOverview):
630         (WI.TimelineOverview.prototype._instrumentAdded):
631         (WI.TimelineOverview.prototype._instrumentRemoved):
632         (WI.TimelineOverview.prototype._handleGraphsContainerClick): Added.
633         (WI.TimelineOverview.prototype._handleOverviewGraphRecordSelected): Added.
634         (WI.TimelineOverview.prototype._recordSelected):
635         Listen for "click" on the graph container and deselect all records when fired, unless the
636         click was marked by a `WI.TimelineRecordBar`.
637
638         * UserInterface/Views/TimelineRecordingContentView.js:
639         (WI.TimelineRecordingContentView.prototype._recordSelected):
640         Ensure that all `WI.TimelineView` update their selected record whenever it changes for any
641         other `WI.TimelineView` (or if there is no selected record).
642
643         * UserInterface/Views/TimelineOverviewGraph.js:
644         (WI.TimelineOverviewGraph.prototype.didLayoutSubtree): Added.
645         Drive-by: since `WI.TimelineRecordBar` are reused when combining, we need to re-determine
646         which one holds the currently selected record.
647
648 2019-02-12  Joseph Pecoraro  <pecoraro@apple.com>
649
650         Web Inspector: Remove unused maxUsage in CPUTimelineView
651         https://bugs.webkit.org/show_bug.cgi?id=194526
652
653         Reviewed by Devin Rousso.
654
655         * UserInterface/Views/CPUTimelineView.js:
656         (WI.CPUTimelineView):
657         (WI.CPUTimelineView.prototype.shown):
658
659 2019-02-11  Devin Rousso  <drousso@apple.com>
660
661         Web Inspector: add context menu items to copy a resource's HTTP request/response data
662         https://bugs.webkit.org/show_bug.cgi?id=194261
663         <rdar://problem/21693696>
664
665         Reviewed by Joseph Pecoraro.
666
667         * UserInterface/Models/Resource.js:
668         (WI.Resource.prototype.stringifyHTTPRequest): Added.
669         (WI.Resource.prototype.stringifyHTTPResponse): Added.
670         Don't include the request/response data, as that can be very large, and can easily be
671         accessed by actually selecting the resource in the Resources/Network tab.
672
673         * UserInterface/Views/ContextMenuUtilities.js:
674         (WI.appendContextMenuItemsForSourceCode):
675
676         * Localizations/en.lproj/localizedStrings.js:
677
678 2019-02-08  Devin Rousso  <drousso@apple.com>
679
680         Web Inspector: Audit: show keyboard shortcut in export tooltip
681         https://bugs.webkit.org/show_bug.cgi?id=194454
682
683         Reviewed by Matt Baker.
684
685         * UserInterface/Views/AuditTestContentView.js:
686         (WI.AuditTestContentView):
687         (WI.AuditTestContentView.prototype.get saveData):
688         (WI.AuditTestContentView.prototype._exportResult): Added.
689         (WI.AuditTestContentView.prototype._handleExportButtonNavigationItemClicked):
690         (WI.AuditTestContentView.prototype._exportAudit): Deleted.
691
692         * Localizations/en.lproj/localizedStrings.js:
693
694 2019-02-08  Nikita Vasilyev  <nvasilyev@apple.com>
695
696         Web Inspector: Styles: easier way to select a single line
697         https://bugs.webkit.org/show_bug.cgi?id=193305
698
699         Reviewed by Devin Rousso.
700
701         Start property selection after mousedown when mouse cursor moves 8px,
702         which is ~1.5 times the width of a text character in the style editor.
703
704         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
705         (WI.SpreadsheetCSSStyleDeclarationSection):
706         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleMouseDown):
707         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleWindowMouseMove): Added.
708         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._stopSelection):
709
710 2019-02-08  Joseph Pecoraro  <pecoraro@apple.com>
711
712         Web Inspector: Debugger Popover should work with value in template string `${identifier}`
713         https://bugs.webkit.org/show_bug.cgi?id=194459
714         <rdar://problem/47932564>
715
716         Reviewed by Devin Rousso.
717
718         * UserInterface/Controllers/CodeMirrorTokenTrackingController.js:
719         (WI.CodeMirrorTokenTrackingController.prototype._processJavaScriptExpression):
720         When walking backwards to get the full expression we were walking outside
721         of the interpolation group `outside ${inside}`. Stop walking backwards once
722         we cross the boundary.
723
724 2019-02-08  Joseph Pecoraro  <pecoraro@apple.com>
725
726         Web Inspector: Import / Export Heap Snapshots
727         https://bugs.webkit.org/show_bug.cgi?id=194448
728         <rdar://problem/47928093>
729
730         Reviewed by Devin Rousso.
731
732         * Localizations/en.lproj/localizedStrings.js:
733         New strings.
734
735         * UserInterface/Proxies/HeapSnapshotProxy.js:
736         (WI.HeapSnapshotProxy):
737         (WI.HeapSnapshotProxy.deserialize):
738         (WI.HeapSnapshotProxy.prototype.get imported):
739         (WI.HeapSnapshotProxy.prototype.get snapshotStringData):
740         (WI.HeapSnapshotProxy.prototype.set snapshotStringData):
741         Include an "imported" state on the HeapSnapshot and allow for
742         stashing the snapshotStringData on the main thread side.
743
744         * UserInterface/Proxies/HeapSnapshotWorkerProxy.js:
745         (WI.HeapSnapshotWorkerProxy.prototype.createImportedSnapshot):
746         * UserInterface/Workers/HeapSnapshot/HeapSnapshotWorker.js:
747         (HeapSnapshotWorker.prototype.clearSnapshots):
748         (HeapSnapshotWorker.prototype.createSnapshot):
749         Provide a specialized way to create an imported HeapSnapshot.
750         Track imported snapshots separately since they won't want to
751         be searched for live/dead objects due to active recording GCs.
752
753         * UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:
754         (HeapSnapshot):
755         (HeapSnapshot.updateCategoriesAndMetadata):
756         (HeapSnapshot.allocationBucketCounts):
757         (HeapSnapshot.instancesWithClassName):
758         (HeapSnapshot.prototype.nodeWithIdentifier):
759         (HeapSnapshot.prototype.dominatedNodes):
760         (HeapSnapshot.prototype.retainedNodes):
761         (HeapSnapshot.prototype.retainers):
762         (HeapSnapshot.prototype.updateDeadNodesAndGatherCollectionData):
763         (HeapSnapshot.prototype.serialize):
764         (HeapSnapshot.prototype.serializeNode):
765         (HeapSnapshot.prototype._buildPostOrderIndexes):
766         (HeapSnapshot.prototype._buildDominatorIndexes):
767         (HeapSnapshot.prototype._buildRetainedSizes):
768         (HeapSnapshot.prototype._gcRootPathes.visitNode):
769         (HeapSnapshot.prototype._gcRootPathes):
770         Construct a HeapSnapshot knowinng whether or not it is imported.
771         Imported snapshots may be the "GCDebugging" snapshot type which
772         differs from "Inspector" by the number of node fields. So keep
773         the node field count a member instead of a global constant
774         in order to work with both snapshot types.
775
776         * UserInterface/Models/HeapAllocationsInstrument.js:
777         (WI.HeapAllocationsInstrument.prototype._takeHeapSnapshot):
778         * UserInterface/Protocol/ConsoleObserver.js:
779         (WI.ConsoleObserver.prototype.heapSnapshot):
780         * UserInterface/Protocol/HeapObserver.js:
781         (WI.HeapObserver.prototype.trackingStart):
782         (WI.HeapObserver.prototype.trackingComplete):
783         Stash the original string JSON data on the main thread side
784         where we already have the data.
785
786         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.js:
787         (WI.HeapAllocationsTimelineOverviewGraph.prototype.layout):
788         Don't show [S] icons for imported snapshots with no timestamp.
789
790         * UserInterface/Views/HeapAllocationsTimelineView.js:
791         (WI.HeapAllocationsTimelineView):
792         (WI.HeapAllocationsTimelineView.prototype.get navigationItems):
793         (WI.HeapAllocationsTimelineView.prototype._importButtonNavigationItemClicked):
794         (WI.HeapAllocationsTimelineView.prototype._takeHeapSnapshotClicked):
795         Import button that just creates a new snapshot.
796
797         * UserInterface/Views/HeapSnapshotContentView.js:
798         (WI.HeapSnapshotContentView):
799         (WI.HeapSnapshotContentView.prototype.get navigationItems):
800         (WI.HeapSnapshotContentView.prototype.get supportsSave):
801         (WI.HeapSnapshotContentView.prototype.get saveData):
802         (WI.HeapSnapshotContentView.prototype._exportSnapshot):
803         Export button that saves the original data.
804
805         * UserInterface/Views/TimelineTabContentView.js:
806         (WI.TimelineTabContentView.displayNameForRecord):
807         Specialized display string for imported snapshots.
808
809 2019-02-08  Joseph Pecoraro  <pecoraro@apple.com>
810
811         Web Inspector: Add Debug setting to show Internal Object Classes in Heap Snapshot
812         https://bugs.webkit.org/show_bug.cgi?id=194445
813
814         Reviewed by Devin Rousso.
815
816         * UserInterface/Base/Setting.js:
817         * UserInterface/Views/HeapSnapshotDataGridTree.js:
818         (WI.HeapSnapshotInstancesDataGridTree.prototype.populateTopLevel):
819         * UserInterface/Views/SettingsTabContentView.js:
820         (WI.SettingsTabContentView.prototype._createDebugSettingsView):
821
822 2019-02-08  Nikita Vasilyev  <nvasilyev@apple.com>
823
824         Web Inspector: Styles: close unbalanced quotes and parenthesis when editing values
825         https://bugs.webkit.org/show_bug.cgi?id=182523
826         <rdar://problem/37260209>
827
828         Reviewed by Devin Rousso.
829
830         Close CSS comments, append missing closed quotes and right parenthesis.
831
832         * UserInterface/Models/CSSCompletions.js:
833         (WI.CSSCompletions.completeUnbalancedValue):
834         * UserInterface/Models/CSSProperty.js:
835         (WI.CSSProperty.prototype.set rawValue):
836
837 2019-02-07  Joseph Pecoraro  <pecoraro@apple.com>
838
839         Web Inspector: Make Timeline markers light gray instead of black in dark mode
840         https://bugs.webkit.org/show_bug.cgi?id=194417
841
842         Reviewed by Devin Rousso.
843
844         * UserInterface/Views/RenderingFrameTimelineOverviewGraph.css:
845         (.timeline-overview-graph.rendering-frame > .divider):
846         * UserInterface/Views/TimelineRuler.css:
847         (.timeline-ruler > .markers > .divider):
848
849 2019-02-06  Devin Rousso  <drousso@apple.com>
850
851         Web Inspector: DOM: don't send the entire function string with each event listener
852         https://bugs.webkit.org/show_bug.cgi?id=194293
853         <rdar://problem/47822809>
854
855         Reviewed by Joseph Pecoraro.
856
857         * UserInterface/Views/EventListenerSectionGroup.js:
858         (WI.EventListenerSectionGroup.prototype._functionTextOrLink):
859
860 2019-02-06  Joseph Pecoraro  <pecoraro@apple.com>
861
862         Web Inspector: "Worker not found" uncaught protocol errors
863         https://bugs.webkit.org/show_bug.cgi?id=194319
864
865         Reviewed by Matt Baker.
866
867         * UserInterface/Base/Main.js:
868         (WI.terminatePageTarget):
869         Remove Worker targets associated with the Page on navigation.
870         Eventually we will have to associate Workers with their parent
871         frame, but for now a transition can only happen at the Page
872         level, so we can eliminate all workers on the page.
873
874         * UserInterface/Controllers/WorkerManager.js:
875         (WI.WorkerManager.prototype.workerCreated):
876         * UserInterface/Protocol/Connection.js:
877         (InspectorBackend.WorkerConnection.sendMessageToBackend):
878         Allow any WorkerAgent domain message to fail silently. This can
879         happen if a Worker is created and destroyed before the frontend
880         hears about it and sends messages to the backend for that Worker.
881
882 2019-02-05  Nikita Vasilyev  <nvasilyev@apple.com>
883
884         Web Inspector: Styles: PropertiesChanged shouldn't fire when old and new text are both empty
885         https://bugs.webkit.org/show_bug.cgi?id=194318
886
887         Reviewed by Devin Rousso.
888
889         Previously, WI.CSSStyleDeclaration.Event.PropertiesChanged fired when
890         old text and new text were empty strings.
891
892         * UserInterface/Models/CSSStyleDeclaration.js:
893
894 2019-02-05  Devin Rousso  <drousso@apple.com>
895
896         Web Inspector: Lots of time spent updating related resources in ResourceDetailsSidebar when loading a page with lots of resources
897         https://bugs.webkit.org/show_bug.cgi?id=159577
898         <rdar://problem/27251461>
899
900         Reviewed by Joseph Pecoraro.
901
902         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
903         (WI.ResourceDetailsSidebarPanel.prototype._refreshRelatedResourcesSection):
904         (WI.ResourceDetailsSidebarPanel.prototype._applyResourceEventListeners):
905
906 2019-02-05  Matt Baker  <mattbaker@apple.com>
907
908         Web Inspector: Elements tab: selection is broken after deleting the selected node
909         https://bugs.webkit.org/show_bug.cgi?id=194300
910         <rdar://problem/47829275>
911
912         Reviewed by Devin Rousso.
913
914         Deleting a TreeElement can cause an IndexSet including indexes
915         outside the deleted range to be passed to SelectionController,
916         corrupting the internal selection state.
917
918         * UserInterface/Views/TreeOutline.js:
919         (WI.TreeOutline.prototype._indexesForSubtree.numberOfElementsInSubtree): Added.
920         (WI.TreeOutline.prototype._indexesForSubtree):
921         Finding the last (rightmost leaf) TreeElement in the subtree used
922         TreeElement.prototype.traverseNextElement to do a depth first traversal.
923         This method did not stay within the subtree rooted at `treeElement`.
924
925 2019-02-05  Matt Baker  <mattbaker@apple.com>
926
927         Web Inspector: REGRESSION (r240947): Resources tab: can't select main frame after refreshing page
928         https://bugs.webkit.org/show_bug.cgi?id=194254
929         <rdar://problem/47805023>
930
931         Reviewed by Devin Rousso.
932
933         * UserInterface/Views/TreeOutline.js:
934         (WI.TreeOutline.prototype.selectionControllerSelectionDidChange):
935         TreeOutline should always call the TreeElement `select` and `deselect`
936         methods while processing selection changes. Having notifications
937         suppressed by `this._suppressNextSelectionDidChangeEvent` should only
938         affect the dispatching of TreeOutline events.
939
940 2019-02-05  Nikita Vasilyev  <nvasilyev@apple.com>
941
942         Web Inspector: Styles: remove harmless "property was unlocked" asserts
943         https://bugs.webkit.org/show_bug.cgi?id=194262
944
945         Reviewed by Matt Baker.
946
947         * UserInterface/Views/SpreadsheetStyleProperty.js:
948         (WI.SpreadsheetStyleProperty.prototype.remove):
949         (WI.SpreadsheetStyleProperty.prototype.update):
950         (WI.SpreadsheetStyleProperty.prototype._handleNameChange):
951         (WI.SpreadsheetStyleProperty.prototype._handleValueChange):
952
953 2019-02-04  Devin Rousso  <drousso@apple.com>
954
955         Web Inspector: Uncaught Exception: undefined is not an object (evaluating 'classes.includes')
956         https://bugs.webkit.org/show_bug.cgi?id=194280
957         <rdar://problem/47811159>
958
959         Reviewed by Matt Baker.
960
961         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:
962         (WI.GeneralStyleDetailsSidebarPanel.prototype._populateClassToggles):
963         Add a fallback value in case the `class` attribute isn't specified for the selected node.
964
965 2019-02-04  Devin Rousso  <drousso@apple.com>
966
967         Web Inspector: Resources: missing resource data for document on reload
968         https://bugs.webkit.org/show_bug.cgi?id=194243
969         <rdar://problem/47559021>
970
971         Reviewed by Joseph Pecoraro.
972
973         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
974         (WI.ResourceDetailsSidebarPanel.prototype.set resource):
975         (WI.ResourceDetailsSidebarPanel.prototype._applyResourceEventListeners):
976
977         * UserInterface/Base/Object.js:
978         (WI.Object.removeEventListener):
979         Drive-by: there's no need to iterate over the entire table to check if `thisObject` exists,
980         as that is handled for us by `ListMultimap`, which we later call anyways.
981
982 2019-02-04  Matt Baker  <mattbaker@apple.com>
983
984         Web Inspector: REGRESSION: Resources: WI.TreeOutline assertions when refreshing the page
985         https://bugs.webkit.org/show_bug.cgi?id=194242
986         <rdar://problem/47802027>
987
988         Reviewed by Joseph Pecoraro.
989
990         * UserInterface/Views/FolderizedTreeElement.js:
991         (WI.FolderizedTreeElement.prototype.removeChildren):
992         FolderTreeElements are removed by the base class call to removeChildren.
993         Calling `removeChildren` for detached TreeElements is unnecessary.
994
995 2019-02-04  Matt Baker  <mattbaker@apple.com>
996
997         Web Inspector: REGRESSION: clicking a selected call frame doesn't re-scroll
998         https://bugs.webkit.org/show_bug.cgi?id=194169
999         <rdar://problem/47743864>
1000
1001         Reviewed by Devin Rousso.
1002
1003         * UserInterface/Views/TreeOutline.js:
1004         (WI.TreeOutline.prototype._handleMouseDown):
1005         Add a special case for a single-selection TreeOutline with
1006         allowsRepeatSelection enabled. Since the element is already
1007         selected, bypass the SelectionCongroller and dispatch an
1008         event with event.data.selectedByUser set to true.
1009
1010 2019-02-04  Nikita Vasilyev  <nvasilyev@apple.com>
1011
1012         Web Inspector: Styles: fix race conditions when editing
1013         https://bugs.webkit.org/show_bug.cgi?id=192739
1014         <rdar://problem/46752925>
1015
1016         Reviewed by Devin Rousso.
1017
1018         Editing CSS property in the style editor syncronously updates CSSStyleDeclaration on the front-end
1019         and asyncronously updates the backend by calling CSSAgent.setStyleText. After the new style text is applied
1020         on the backend, CSSStyleDeclaration (on the front-end) gets updated.
1021
1022         Unsure there's no race conditions by introducing `_updatesInProgressCount`:
1023
1024           - Increment it before calling CSSAgent.setStyleText.
1025           - Decrement it after CSSAgent.setStyleText is finished.
1026
1027         Prevent updates of CSSStyleDeclaration when _updatesInProgressCount isn't 0.
1028
1029         * UserInterface/Models/CSSProperty.js:
1030         (WI.CSSProperty.prototype._updateOwnerStyleText):
1031         * UserInterface/Models/CSSStyleDeclaration.js:
1032         (WI.CSSStyleDeclaration):
1033         (WI.CSSStyleDeclaration.prototype.set text): Removed.
1034         (WI.CSSStyleDeclaration.prototype.setText): Added.
1035         Change the setter to a method since it has side effects including an asynchronous backend call.
1036
1037         * UserInterface/Models/DOMNodeStyles.js:
1038         (WI.DOMNodeStyles.prototype.changeStyleText):
1039
1040         * UserInterface/Views/SpreadsheetStyleProperty.js:
1041         (WI.SpreadsheetStyleProperty.prototype.get nameTextField): Removed.
1042         (WI.SpreadsheetStyleProperty.prototype.get valueTextField): Removed.
1043         Drive-by: remove unused code.
1044
1045 2019-02-01  Devin Rousso  <drousso@apple.com>
1046
1047         Web Inspector: create icons for media event types instead of using a blue circle
1048         https://bugs.webkit.org/show_bug.cgi?id=190381
1049         <rdar://problem/45507995>
1050
1051         Reviewed by Brian Burg.
1052
1053         * UserInterface/Models/DOMNode.js:
1054         (WI.DOMNode.isPlayEvent): Added.
1055         (WI.DOMNode.isPauseEvent): Added.
1056         (WI.DOMNode.isStopEvent): Added.
1057
1058         * UserInterface/Views/DOMEventsBreakdownView.js:
1059         (WI.DOMEventsBreakdownView.prototype.layout):
1060         * UserInterface/Views/DOMEventsBreakdownView.css:
1061         (.dom-events-breakdown tr > :matches(th, td)):
1062         (.dom-events-breakdown .graph):
1063         (.dom-events-breakdown .graph > :matches(img, .area)): Added.
1064         (.dom-events-breakdown .graph > img): Added.
1065         (.dom-events-breakdown .inherited > .name, .dom-events-breakdown .inherited > .graph > img): Added.
1066         (.dom-events-breakdown .graph > :matches(.point, .area)): Deleted.
1067         (.dom-events-breakdown .graph > .point): Deleted.
1068         (.dom-events-breakdown .inherited > .name, .dom-events-breakdown .inherited > .graph > .point): Deleted.
1069
1070         * UserInterface/Views/NetworkTableContentView.js:
1071         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.createDOMEventLine):
1072
1073         * UserInterface/Images/EventPause.svg: Added.
1074         * UserInterface/Images/EventPlay.svg: Added.
1075         * UserInterface/Images/EventProcessing.svg: Added.
1076         * UserInterface/Images/EventStop.svg: Added.
1077
1078 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1079
1080         Web Inspector: Make WI.ColumnChart a WI.View subclass
1081         https://bugs.webkit.org/show_bug.cgi?id=194171
1082
1083         Rubber-stamped by Devin Rousso.
1084
1085         * UserInterface/Views/CPUTimelineOverviewGraph.js:
1086         (WI.CPUTimelineOverviewGraph):
1087         * UserInterface/Views/ColumnChart.js:
1088         (WI.ColumnChart):
1089         (WI.ColumnChart.prototype.set size):
1090         (WI.ColumnChart.prototype.layout):
1091         (WI.ColumnChart.prototype.get element): Deleted.
1092         (WI.ColumnChart.prototype.needsLayout): Deleted.
1093         (WI.ColumnChart.prototype.updateLayout): Deleted.
1094
1095 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1096
1097         Web Inspector: Make WI.StackedLineChart a WI.View subclass
1098         https://bugs.webkit.org/show_bug.cgi?id=194119
1099
1100         Rubber-stamped by Devin Rousso.
1101
1102         * UserInterface/Views/LineChart.js:
1103         (WI.LineChart.prototype.layout):
1104         (WI.LineChart):
1105         * UserInterface/Views/MemoryTimelineOverviewGraph.js:
1106         (WI.MemoryTimelineOverviewGraph):
1107         * UserInterface/Views/StackedLineChart.js:
1108         (WI.StackedLineChart):
1109         (WI.StackedLineChart.prototype.set size):
1110         (WI.StackedLineChart.prototype.layout):
1111         (WI.StackedLineChart.prototype.get element): Deleted.
1112         (WI.StackedLineChart.prototype.get points): Deleted.
1113         (WI.StackedLineChart.prototype.needsLayout): Deleted.
1114         (WI.StackedLineChart.prototype.updateLayout): Deleted.
1115
1116 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1117
1118         Web Inspector: Make WI.CircleChart a WI.View subclass
1119         https://bugs.webkit.org/show_bug.cgi?id=194118
1120
1121         Reviewed by Matt Baker.
1122
1123         * UserInterface/Views/CircleChart.js:
1124         (WI.CircleChart.prototype.get centerElement):
1125         (WI.CircleChart.prototype.layout):
1126         (WI.CircleChart.prototype.get element): Deleted.
1127         (WI.CircleChart.prototype.needsLayout): Deleted.
1128         (WI.CircleChart.prototype.updateLayout): Deleted.
1129         * UserInterface/Views/MemoryTimelineView.js:
1130         (WI.MemoryTimelineView):
1131
1132 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1133
1134         Web Inspector: Timeline Detail Views do not reset properly when new time range selection contains nothing
1135         https://bugs.webkit.org/show_bug.cgi?id=194115
1136         <rdar://problem/47716693>
1137
1138         Rubber-stamped by Devin Rousso.
1139
1140         * UserInterface/Views/CPUTimelineView.js:
1141         (WI.CPUTimelineView.prototype.reset):
1142         (WI.CPUTimelineView.prototype.clear):
1143         (WI.CPUTimelineView.prototype.layout):
1144         * UserInterface/Views/MemoryTimelineView.js:
1145         (WI.MemoryTimelineView.prototype.reset):
1146         (WI.MemoryTimelineView.prototype.clear):
1147         (WI.MemoryTimelineView.prototype.layout):
1148         When there are no visible records in the selected range clear our UI.
1149         Introduce a `clear` method that clears the UI but keeps
1150         non-range-specific values (e.g. maximums).
1151
1152 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1153
1154         Web Inspector: Timeline graphs have drawing issues with multiple discontinuities
1155         https://bugs.webkit.org/show_bug.cgi?id=194110
1156         <rdar://problem/47714356>
1157
1158         Reviewed by Devin Rousso.
1159
1160         * UserInterface/Views/CPUTimelineView.js:
1161         (WI.CPUTimelineView):
1162         (WI.CPUTimelineView.prototype.layout.xScale): Deleted.
1163         * UserInterface/Views/MemoryTimelineOverviewGraph.js:
1164         (WI.MemoryTimelineOverviewGraph.prototype.layout.insertDiscontinuity):
1165         (WI.MemoryTimelineOverviewGraph.prototype.layout):
1166         * UserInterface/Views/MemoryTimelineView.js:
1167         (WI.MemoryTimelineView.prototype.layout.xScale):
1168         (WI.MemoryTimelineView.prototype.layout.yScale):
1169         (WI.MemoryTimelineView.prototype.layout):
1170         Handle if multiple discontinuities exist between records.
1171
1172 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1173
1174         Web Inspector: Timeline time range selection should show duration alongside start and end
1175         https://bugs.webkit.org/show_bug.cgi?id=194109
1176         <rdar://problem/47714279>
1177
1178         Reviewed by Devin Rousso.
1179
1180         * Localizations/en.lproj/localizedStrings.js:
1181         * UserInterface/Views/TimelineRecordingContentView.js:
1182         (WI.TimelineRecordingContentView.prototype._updateTimeRangePathComponents):
1183         Include the duration when not obvious.
1184
1185 2019-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1186
1187         Web Inspector: Improve API and documentation of ColumnChart
1188         https://bugs.webkit.org/show_bug.cgi?id=193982
1189
1190         Reviewed by Devin Rousso.
1191
1192         This used to be named "BarChart". Convert remaining instances
1193         of "bar" to "column" and clean up related things.
1194
1195         * UserInterface/Views/CPUTimelineOverviewGraph.css:
1196         (body[dir=rtl] .timeline-overview-graph.cpu > .column-chart):
1197         (.timeline-overview-graph.cpu > .column-chart > svg > rect):
1198         (body[dir=rtl] .timeline-overview-graph.cpu > .bar-chart): Deleted.
1199         (.timeline-overview-graph.cpu > .bar-chart > svg > rect): Deleted.
1200         * UserInterface/Views/CPUTimelineOverviewGraph.js:
1201         (WI.CPUTimelineOverviewGraph.prototype.layout):
1202         * UserInterface/Views/ColumnChart.js:
1203         (WI.ColumnChart):
1204         (WI.ColumnChart.prototype.get columns):
1205         (WI.ColumnChart.prototype.addColumn):
1206         (WI.ColumnChart.prototype.clear):
1207         (WI.ColumnChart.prototype.updateLayout):
1208         (WI.ColumnChart.prototype.get bars): Deleted.
1209         (WI.ColumnChart.prototype.addBar): Deleted.
1210         * UserInterface/Views/StackedLineChart.js:
1211         (WI.StackedLineChart.prototype.get element):
1212         (WI.StackedLineChart.prototype.get points):
1213
1214 2019-01-31  Joseph Pecoraro  <pecoraro@apple.com>
1215
1216         Web Inspector: Timeline time range selection sometimes shows 0.000, should be just 0
1217         https://bugs.webkit.org/show_bug.cgi?id=194108
1218         <rdar://problem/47714273>
1219
1220         Reviewed by Devin Rousso.
1221
1222         * UserInterface/Base/Utilities.js:
1223         Check under epsilon for the zero case.
1224
1225 2019-01-31  Matt Baker  <mattbaker@apple.com>
1226
1227         REGRESSION(r?): Web Inspector: Clicking on text doesn't move text caret when editing innerHTML/tagName/attribute
1228         https://bugs.webkit.org/show_bug.cgi?id=192652
1229         <rdar://problem/46684612>
1230
1231         Reviewed by Devin Rousso.
1232
1233         * UserInterface/Views/DOMTreeElement.js:
1234         (WI.DOMTreeElement.prototype.canSelectOnMouseDown):
1235         Call to Event.preventDefault() should be made here instead of at the
1236         TreeOutline level.
1237
1238         * UserInterface/Views/TreeElement.js:
1239         (WI.TreeElement.prototype.selectOnMouseDown): Deleted.
1240         Remove dead code.
1241
1242         * UserInterface/Views/TreeOutline.js:
1243         (WI.TreeOutline._handleMouseDown):
1244         Do not prevent default event handling when the item cannot be selected.
1245         This matches TreeOutline behavior prior to introducing SelectionController.
1246
1247 2019-01-30  Devin Rousso  <drousso@apple.com>
1248
1249         Web Inspector: Memory Timeline View should be responsive / resizable
1250         https://bugs.webkit.org/show_bug.cgi?id=153758
1251         <rdar://problem/24444320>
1252
1253         Reviewed by Joseph Pecoraro.
1254
1255         Leverage the SVG `viewBox` (which was misspelled) to scale the graphs when the width of the
1256         container changes. The `viewBox` used is equal to the total amount of time that is visible.
1257
1258         Make `WI.LineChart` (and its container classes) into subclasses of `WI.View` to leverage the
1259         existing layout system.
1260
1261         Prevent any work from being done when resizing, as this is now handled by CSS/SVG.
1262
1263         * UserInterface/Views/LineChart.js:
1264         (WI.LineChart):
1265         (WI.LineChart.prototype.set size):
1266         (WI.LineChart.prototype.addPoint):
1267         (WI.LineChart.prototype.clear):
1268         (WI.LineChart.prototype.layout):
1269         (WI.LineChart.prototype.get element): Deleted.
1270         (WI.LineChart.prototype.get points): Deleted.
1271         (WI.LineChart.prototype.needsLayout): Deleted.
1272         (WI.LineChart.prototype.updateLayout): Deleted.
1273
1274         * UserInterface/Views/CPUUsageView.js:
1275         (WI.CPUUsageView):
1276         (WI.CPUUsageView.prototype.clear):
1277         (WI.CPUUsageView.prototype.updateChart): Added.
1278         (WI.CPUUsageView.prototype.get element): Deleted.
1279         (WI.CPUUsageView.prototype.layoutWithDataPoints): Deleted.
1280         * UserInterface/Views/CPUUsageView.css:
1281         (.cpu-usage-view):
1282         (.cpu-usage-view > .details):
1283         (.cpu-usage-view > .graph, .cpu-usage-view > .graph > .line-chart, .cpu-usage-view > .graph > .line-chart > svg): Added.
1284         (.cpu-usage-view > .graph): Deleted.
1285
1286         * UserInterface/Views/CPUTimelineView.js:
1287         (WI.CPUTimelineView):
1288         (WI.CPUTimelineView.prototype.layout):
1289         (WI.CPUTimelineView.prototype.layout.layoutView):
1290         (WI.CPUTimelineView.prototype.layout.layoutView.xScale):
1291         (WI.CPUTimelineView.prototype.layout.layoutView.yScale):
1292         * UserInterface/Views/CPUTimelineView.css:
1293         (body .timeline-view.cpu): Added.
1294         (.timeline-view.cpu > .content):
1295         (.timeline-view.cpu): Deleted.
1296
1297         * UserInterface/Views/MemoryCategoryView.js:
1298         (WI.MemoryCategoryView):
1299         (WI.MemoryCategoryView.prototype.clear):
1300         (WI.MemoryCategoryView.prototype.updateChart): Added.
1301         (WI.MemoryCategoryView.prototype.get element): Deleted.
1302         (WI.MemoryCategoryView.prototype.layoutWithDataPoints): Deleted.
1303         * UserInterface/Views/MemoryCategoryView.css:
1304         (.memory-category-view):
1305         (.memory-category-view > .details):
1306         (.memory-category-view > .graph, .memory-category-view > .graph > .line-chart, .memory-category-view > .graph > .line-chart > svg): Added.
1307         (.memory-category-view > .graph): Deleted.
1308
1309         * UserInterface/Views/MemoryTimelineView.js:
1310         (WI.MemoryTimelineView.prototype.layout):
1311         (WI.MemoryTimelineView.prototype.layout.layoutCategoryView):
1312         (WI.MemoryTimelineView.prototype.layout.layoutCategoryView.xScale):
1313         (WI.MemoryTimelineView.prototype.layout.layoutCategoryView.yScale):
1314         (WI.MemoryTimelineView.prototype._initializeCategoryViews):
1315         (WI.MemoryTimelineView.prototype._initializeCategoryViews.appendLegendRow):
1316         * UserInterface/Views/MemoryTimelineView.css:
1317         (.timeline-view.memory > .content > .overview):
1318         (.timeline-view.memory > .content > .overview > .divider):
1319         (.timeline-view.memory > .content > .overview .total-usage, .timeline-view.memory > .content > .overview .max-percentage, .timeline-view.memory > .content > .overview .legend .size): Added.
1320         (.timeline-view.memory .legend):
1321         (.timeline-view.memory .legend .row): Added.
1322         (.timeline-view.memory .legend .row + .row): Added.
1323         (.timeline-view.memory .legend .swatch): Addd.
1324         (.timeline-view.memory .legend .swatch.javascript): Addd.
1325         (.timeline-view.memory .legend .swatch.images): Addd.
1326         (.timeline-view.memory .legend .swatch.layers): Addd.
1327         (.timeline-view.memory .legend .swatch.page): Addd.
1328         (.timeline-view.memory .legend .swatch.current): Addd.
1329         (.timeline-view.memory > .content): Deleted.
1330         (.timeline-view.memory > .content > .overview .total-usage, .timeline-view.memory > .content > .overview .max-percentage):
1331         (body[dir=ltr] .timeline-view.memory .legend): Deleted.
1332         (body[dir=rtl] .timeline-view.memory .legend): Deleted.
1333         (.timeline-view.memory .legend > .row): Deleted.
1334         (.timeline-view.memory .legend > .row > .swatch): Deleted.
1335         (body[dir=ltr] .timeline-view.memory .legend > .row > .swatch): Deleted.
1336         (body[dir=rtl] .timeline-view.memory .legend > .row > .swatch): Deleted.
1337         (.timeline-view.memory .legend > .row > p): Deleted.
1338         (body[dir=ltr] .timeline-view.memory .legend > .row > :matches(.label, .size)): Deleted.
1339         (body[dir=rtl] .timeline-view.memory .legend > .row > :matches(.label, .size)): Deleted.
1340         (.timeline-view.memory .legend > .row > .label): Deleted.
1341         (.timeline-view.memory .legend > .row > .size): Deleted.
1342         (.timeline-view.memory .legend > .row > .swatch.javascript): Deleted.
1343         (.timeline-view.memory .legend > .row > .swatch.images): Deleted.
1344         (.timeline-view.memory .legend > .row > .swatch.layers): Deleted.
1345         (.timeline-view.memory .legend > .row > .swatch.page): Deleted.
1346         (.timeline-view.memory .legend > .row > .swatch.current): Deleted.
1347
1348 2019-01-30  Nikita Vasilyev  <nvasilyev@apple.com>
1349
1350         Web Inspector: Changes: group CSS rules by resource
1351         https://bugs.webkit.org/show_bug.cgi?id=193940
1352         <rdar://problem/47617785>
1353
1354         Reviewed by Matt Baker.
1355
1356         Create resource sections with source links in their headers.
1357
1358         Also:
1359         - Use read-only WI.SpreadsheetStyleProperty to display inline swatches for colors;
1360         - Make the red and green background span the entire width of the panel.
1361
1362         * Localizations/en.lproj/localizedStrings.js:
1363         * UserInterface/Views/ChangesDetailsSidebarPanel.css:
1364         (.sidebar > .panel.changes-panel):
1365         (.sidebar > .panel.changes-panel .css-rule):
1366         (.sidebar > .panel.selected.changes-panel.empty):
1367         (.changes-panel .resource-section):
1368         (.changes-panel .resource-section > .header):
1369         (.changes-panel .resource-section > .header > a:hover):
1370         (.sidebar > .panel.changes-panel .selector-line,):
1371         (.changes-panel .css-property-line > .property):
1372         (.changes-panel .css-property-line.unchanged):
1373         (.changes-panel .css-property-line.added):
1374         (.changes-panel .css-property-line.removed):
1375         (.changes-panel .css-property-line.removed::before):
1376         (.changes-panel .css-property-line.added::before):
1377         (@media (prefers-color-scheme: dark)):
1378
1379         * UserInterface/Views/ChangesDetailsSidebarPanel.js:
1380         (WI.ChangesDetailsSidebarPanel.prototype.layout):
1381         (WI.ChangesDetailsSidebarPanel.prototype._createRuleElement):
1382         (WI.ChangesDetailsSidebarPanel.prototype._createLocationLink):
1383
1384         * UserInterface/Views/SpreadsheetStyleProperty.js:
1385         (WI.SpreadsheetStyleProperty.prototype._createInlineSwatch):
1386         Allow passing `null` as a delegate.
1387
1388 2019-01-30  Devin Rousso  <drousso@apple.com>
1389
1390         Web Inspector: change style of device settings override popover content
1391         https://bugs.webkit.org/show_bug.cgi?id=194049
1392
1393         Reviewed by Joseph Pecoraro.
1394
1395         * UserInterface/Base/Main.js:
1396         (WI._handleDeviceSettingsToolbarButtonClicked):
1397         (WI._handleDeviceSettingsToolbarButtonClicked.showUserAgentInput):
1398         (WI._handleDeviceSettingsToolbarButtonClicked.createContainer): Deleted.
1399         * UserInterface/Views/Main.css:
1400         (.device-settings-content):
1401         (.device-settings-content > tr > td:first-child): Added.
1402         (.device-settings-content .container):
1403         (.device-settings-content .container > * + *): Added.
1404         (.device-settings-content .column): Added.
1405         (.device-settings-content .user-agent select): Added.
1406         (.device-settings-content .user-agent input): Added.
1407         (.device-settings-content label + label): Added.
1408         (.device-settings-content label > input): Added.
1409         (.device-settings-content .columns): Deleted.
1410         (.device-settings-content .columns > .column): Deleted.
1411         (.device-settings-content .columns > .column + .column): Deleted.
1412         (.device-settings-content .user-agent-value): Deleted.
1413         (.device-settings-content .user-agent-value > select): Deleted.
1414         (.device-settings-content .user-agent-value > input): Deleted.
1415         (body[dir=ltr] .device-settings-content .user-agent-value > input): Deleted.
1416         (body[dir=rtl] .device-settings-content .user-agent-value > input): Deleted.
1417
1418 2019-01-30  Devin Rousso  <drousso@apple.com>
1419
1420         Web Inspector: Uncaught Exception: null is not an object (evaluating 'url.startsWith')
1421         https://bugs.webkit.org/show_bug.cgi?id=194029
1422
1423         Reviewed by Matt Baker.
1424
1425         * UserInterface/Views/ConsoleMessageView.js:
1426         (WI.ConsoleMessageView.prototype._appendLocationLink):
1427
1428 2019-01-29  Nikita Vasilyev  <nvasilyev@apple.com>
1429
1430         Web Inspector: Enabled Changes panel in Elements tab by default
1431         https://bugs.webkit.org/show_bug.cgi?id=193986
1432         <rdar://problem/47647683>
1433
1434         Reviewed by Matt Baker.
1435
1436         * UserInterface/Base/Setting.js:
1437         * UserInterface/Views/ElementsTabContentView.js:
1438         (WI.ElementsTabContentView):
1439         * UserInterface/Views/SettingsTabContentView.js:
1440         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1441
1442 2019-01-29  Nikita Vasilyev  <nvasilyev@apple.com>
1443
1444         Web Inspector: Styles: enable computed style cascades by default
1445         https://bugs.webkit.org/show_bug.cgi?id=193983
1446         <rdar://problem/47645821>
1447
1448         Reviewed by Matt Baker.
1449
1450         * Localizations/en.lproj/localizedStrings.js:
1451         * UserInterface/Base/Setting.js:
1452         * UserInterface/Views/ComputedStyleDetailsPanel.css:
1453         (.computed-style-properties):
1454         (.computed-style-properties .property .go-to-arrow):
1455         (.details-section.computed-style-properties:not(.collapsed) > :matches(.header, .content)):
1456         (.details-section.computed-style-properties > .content):
1457         (@media (prefers-color-scheme: dark)):
1458         (.computed-with-traces .computed-style-properties): Deleted.
1459         (.computed-with-traces .details-section.computed-style-properties:not(.collapsed) > :matches(.header, .content)): Deleted.
1460         (.computed-with-traces .details-section.computed-style-properties > .content): Deleted.
1461         (.computed-with-traces .computed-style-properties .property .go-to-arrow): Deleted.
1462         * UserInterface/Views/ComputedStyleDetailsPanel.js:
1463         (WI.ComputedStyleDetailsPanel.prototype.refresh):
1464         (WI.ComputedStyleDetailsPanel.prototype.initialLayout):
1465         * UserInterface/Views/ComputedStyleDetailsSidebarPanel.js:
1466         (WI.ComputedStyleDetailsSidebarPanel):
1467         * UserInterface/Views/SettingsTabContentView.js:
1468         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1469
1470 2019-01-28  Joseph Pecoraro  <pecoraro@apple.com>
1471
1472         Web Inspector: Remove unnecessary promise rejection handlers now that we use the global onunhandledrejection handler
1473         https://bugs.webkit.org/show_bug.cgi?id=193921
1474
1475         Reviewed by Devin Rousso.
1476
1477         * UserInterface/Base/Utilities.js:
1478         * UserInterface/Debug/UncaughtExceptionReporter.js:
1479         * UserInterface/Views/NetworkTableContentView.js:
1480         (WI.NetworkTableContentView.prototype._exportHAR):
1481         * UserInterface/Views/TextEditor.js:
1482         (WI.TextEditor.prototype.updateFormattedState):
1483
1484 2019-01-28  Devin Rousso  <drousso@apple.com>
1485
1486         Web Inspector: provide a way to edit page WebRTC settings on a remote target
1487         https://bugs.webkit.org/show_bug.cgi?id=193863
1488         <rdar://problem/47572764>
1489
1490         Reviewed by Joseph Pecoraro.
1491
1492         * UserInterface/Base/Main.js:
1493         (WI.loaded):
1494         (WI.initializeTarget):
1495         (WI._handleDeviceSettingsToolbarButtonClicked):
1496         (WI._handleDeviceSettingsToolbarButtonClicked.createCheckbox):
1497         (WI._handleDeviceSettingsToolbarButtonClicked.createColumns): Deleted.
1498         * UserInterface/Views/Main.css:
1499         (.device-settings-content .container): Added.
1500
1501         * Localizations/en.lproj/localizedStrings.js:
1502
1503 2019-01-28  Matt Baker  <mattbaker@apple.com>
1504
1505         Web Inspector: Elements tab should toggle visibility for all selected nodes
1506         https://bugs.webkit.org/show_bug.cgi?id=193089
1507         <rdar://problem/47009256>
1508
1509         Reviewed by Devin Rousso.
1510
1511         Update "Toggle Visibility" command in DOM tree for multiple selection.
1512         When both visible and hidden elements are selected in the DOM tree,
1513         the toggle command behaves contextually. If one or more elements are
1514         visible, they are hidden, otherwise they are shown. The context menu
1515         shows "Hide Elements" or "Show Elements", respectively.
1516
1517         When only one element is selected, or the context menu target element
1518         is not selected, the command continues to be "Toggle Visibility".
1519
1520         * Localizations/en.lproj/localizedStrings.js:
1521
1522         * UserInterface/Views/DOMTreeElement.js:
1523         (WI.DOMTreeElement.prototype.get isNodeHidden): Added.
1524         (WI.DOMTreeElement.prototype.toggleElementVisibility.inspectedPage_node_injectStyleAndToggleClass):
1525         (WI.DOMTreeElement.prototype.toggleElementVisibility):
1526         (WI.DOMTreeElement.prototype._populateTagContextMenu):
1527
1528         * UserInterface/Views/DOMTreeOutline.js:
1529         (WI.DOMTreeOutline):
1530         (WI.DOMTreeOutline.prototype.toggleSelectedElementsVisibility):  Added.
1531         Provide a public method for toggling the visibility of selected DOM nodes.
1532         Used by the "H" keyboard shortcut and DOMTreeElement context menu.
1533
1534         (WI.DOMTreeOutline.prototype._hideElements):
1535         (WI.DOMTreeOutline.prototype._hideElement): Deleted.
1536         Rename for multiple selection.
1537
1538 2019-01-28  Commit Queue  <commit-queue@webkit.org>
1539
1540         Unreviewed, rolling out r240351.
1541         https://bugs.webkit.org/show_bug.cgi?id=193918
1542
1543         Causes overlapping Timeline records, as some record types
1544         don't have an endTime (Requested by drousso on #webkit).
1545
1546         Reverted changeset:
1547
1548         "WebInspector: Confusingly nested events in the timeline for
1549         Mutation Observers"
1550         https://bugs.webkit.org/show_bug.cgi?id=192884
1551         https://trac.webkit.org/changeset/240351
1552
1553 2019-01-28  Matt Baker  <mattbaker@apple.com>
1554
1555         REGRESSION(?): Web Inspector: Can have multiple Timelines selected after edit mode
1556         https://bugs.webkit.org/show_bug.cgi?id=193808
1557         <rdar://problem/47537734>
1558
1559         Reviewed by Devin Rousso.
1560
1561         * UserInterface/Controllers/SelectionController.js:
1562         (WI.SelectionController.prototype.didRemoveItems):
1563
1564         * UserInterface/Views/TreeOutline.js:
1565         (WI.TreeOutline.prototype._indexesForSubtree):
1566         Fix a bug where no IndexSet was returned when passed a TreeElement with
1567         no children. This caused the Timelines tree selection to be corrupted when
1568         entering and exiting edit mode, as TreeElements are inserted and removed.
1569
1570 2019-01-28  Nikita Vasilyev  <nvasilyev@apple.com>
1571
1572         Web Inspector: Add Changes panel to Elements tab
1573         https://bugs.webkit.org/show_bug.cgi?id=193803
1574
1575         Reviewed by Devin Rousso.
1576
1577         Introduce the new experimental Changes Panel. It shows a list of CSS changes
1578         made via Web Inspector, so the changes could be copied to the source files.
1579
1580         * Localizations/en.lproj/localizedStrings.js:
1581         * UserInterface/Base/Setting.js:
1582         * UserInterface/Base/Utilities.js:
1583         (Array.diffArrays): Added.
1584
1585         * UserInterface/Controllers/CSSManager.js:
1586         (WI.CSSManager):
1587         (WI.CSSManager.prototype.get modifiedCSSRules):
1588         (WI.CSSManager.prototype.addModifiedCSSRule):
1589         (WI.CSSManager.prototype.removeModifiedCSSRule):
1590         (WI.CSSManager.prototype._mainResourceDidChange):
1591
1592         * UserInterface/Main.html:
1593         * UserInterface/Models/CSSProperty.js:
1594         (WI.CSSProperty):
1595         (WI.CSSProperty.prototype.remove):
1596         (WI.CSSProperty.prototype.replaceWithText):
1597         (WI.CSSProperty.prototype.commentOut):
1598         (WI.CSSProperty.prototype.set text):
1599         (WI.CSSProperty.prototype.get modified):
1600         (WI.CSSProperty.prototype.set name):
1601         (WI.CSSProperty.prototype.set rawValue):
1602         (WI.CSSProperty.prototype.get initialState):
1603         (WI.CSSProperty.prototype._updateOwnerStyleText):
1604         (WI.CSSProperty.prototype._markModified):
1605         Mark CSSProperty modified *before* making any changes to copy its initial state.
1606
1607         * UserInterface/Models/CSSRule.js:
1608         (WI.CSSRule):
1609         (WI.CSSRule.prototype.get id):
1610         (WI.CSSRule.prototype.get initialState):
1611         (WI.CSSRule.prototype.get stringId):
1612         (WI.CSSRule.prototype.markModified):
1613
1614         * UserInterface/Models/CSSStyleDeclaration.js:
1615         (WI.CSSStyleDeclaration):
1616         (WI.CSSStyleDeclaration.prototype.get initialState):
1617         (WI.CSSStyleDeclaration.prototype.get enabledProperties):
1618         (WI.CSSStyleDeclaration.prototype.get properties):
1619         (WI.CSSStyleDeclaration.prototype.set properties):
1620         (WI.CSSStyleDeclaration.prototype.propertyForName):
1621         (WI.CSSStyleDeclaration.prototype.newBlankProperty):
1622         (WI.CSSStyleDeclaration.prototype.markModified):
1623
1624         * UserInterface/Views/ChangesDetailsSidebarPanel.css: Added.
1625         (.sidebar > .panel.changes-panel):
1626         (.sidebar > .panel.changes-panel:not(.empty)):
1627         (.sidebar > .panel.changes-panel.empty):
1628         (.changes-panel ins):
1629         (.changes-panel del):
1630         (.changes-panel del.css-property::before):
1631         (.changes-panel ins.css-property::before):
1632         (@media (prefers-color-scheme: dark)):
1633
1634         * UserInterface/Views/ChangesDetailsSidebarPanel.js: Added.
1635         (WI.ChangesDetailsSidebarPanel):
1636         (WI.ChangesDetailsSidebarPanel.prototype.inspect):
1637         (WI.ChangesDetailsSidebarPanel.prototype.supportsDOMNode):
1638         (WI.ChangesDetailsSidebarPanel.prototype.shown):
1639         (WI.ChangesDetailsSidebarPanel.prototype.detached):
1640         (WI.ChangesDetailsSidebarPanel.prototype.layout):
1641         (WI.ChangesDetailsSidebarPanel.prototype._mainResourceDidChange):
1642
1643         * UserInterface/Views/ElementsTabContentView.js:
1644         (WI.ElementsTabContentView):
1645
1646         * UserInterface/Views/SettingsTabContentView.js:
1647         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1648
1649         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1650         (.spreadsheet-style-declaration-editor .property):
1651         (.spreadsheet-style-declaration-editor .property.modified):
1652         (.spreadsheet-style-declaration-editor .property.modified:not(.selected)):
1653         (@media (prefers-color-scheme: dark)):
1654
1655         * UserInterface/Views/SpreadsheetStyleProperty.js:
1656         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
1657
1658 2019-01-26  Devin Rousso  <drousso@apple.com>
1659
1660         Web Inspector: handle CSS Color 4 color syntaxes
1661         https://bugs.webkit.org/show_bug.cgi?id=193166
1662         <rdar://problem/47062403>
1663
1664         Reviewed by Simon Fraser.
1665
1666         * UserInterface/Models/Color.js:
1667         (WI.Color.fromString):
1668         (WI.Color.fromString.splitFunctionString): Added.
1669         (WI.Color.fromString.parseFunctionAlpha): Added.
1670         (WI.Color.fromString.parseFunctionComponent): Added.
1671         (WI.Color.fromString.parseHueComponent): Added.
1672         (WI.Color.fromString.parsePercentageComponent): Added.
1673
1674 2019-01-26  Devin Rousso  <drousso@apple.com>
1675
1676         Web Inspector: provide a way to edit the user agent of a remote target
1677         https://bugs.webkit.org/show_bug.cgi?id=193862
1678         <rdar://problem/47359292>
1679
1680         Reviewed by Joseph Pecoraro.
1681
1682         * UserInterface/Base/Main.js:
1683         (WI.loaded):
1684         (WI.contentLoaded):
1685         (WI.initializeTarget):
1686         (WI._handleDeviceSettingsToolbarButtonClicked):
1687         (WI._handleDeviceSettingsToolbarButtonClicked.updateActivatedState):
1688         (WI._handleDeviceSettingsToolbarButtonClicked.applyOverriddenUserAgent):
1689         (WI._handleDeviceSettingsToolbarButtonClicked.applyOverriddenSetting):
1690         (WI._handleDeviceSettingsToolbarButtonClicked.createContainer):
1691         (WI._handleDeviceSettingsToolbarButtonClicked.createColumns):
1692         (WI._handleDeviceSettingsToolbarButtonClicked.calculateTargetFrame):
1693         (WI._handleDeviceSettingsToolbarButtonClicked.showUserAgentInput):
1694
1695         * UserInterface/Views/Main.css:
1696         (.device-settings-content):
1697         (.device-settings-content .user-agent-value): Added.
1698         (.device-settings-content .user-agent-value > select): Added.
1699         (.device-settings-content .user-agent-value > input): Added.
1700         (body[dir=ltr] .device-settings-content .user-agent-value > input): Added.
1701         (body[dir=rtl] .device-settings-content .user-agent-value > input): Added.
1702         (.device-settings-content label > input): Added.
1703         (body[dir=ltr] .device-settings-content label > input): Deleted.
1704         (body[dir=rtl] .device-settings-content label > input): Deleted.
1705
1706         * Localizations/en.lproj/localizedStrings.js:
1707
1708 2019-01-25  Devin Rousso  <drousso@apple.com>
1709
1710         Web Inspector: provide a way to edit page settings on a remote target
1711         https://bugs.webkit.org/show_bug.cgi?id=193813
1712         <rdar://problem/47359510>
1713
1714         Reviewed by Joseph Pecoraro.
1715
1716         Add toolbar button that shows a popover with the target's (page's) settings when clicked.
1717
1718         * UserInterface/Base/Main.js:
1719         (WI.loaded):
1720         (WI.contentLoaded):
1721         (WI.initializeTarget): Added.
1722         (WI._handleDeviceSettingsToolbarButtonClicked): Added.
1723         (WI.didDismissPopover): Added.
1724         * UserInterface/Views/Main.css:
1725         (.device-settings-content): Added.
1726         (.device-settings-content .columns): Added.
1727         (.device-settings-content .columns > .column): Added.
1728         (.device-settings-content .columns > .column + .column): Added.
1729         (body[dir=ltr] .device-settings-content label > input): Added.
1730         (body[dir=rtl] .device-settings-content label > input): Added.
1731
1732         * UserInterface/Views/Popover.js:
1733         (WI.Popover.prototype._update.area):
1734         (WI.Popover.prototype._update):
1735         (WI.Popover.prototype._drawBackground):
1736         (WI.Popover.prototype._bestMetricsForEdge):
1737         (WI.Popover.prototype._drawFrame):
1738         If the best area is negative, treat it as the worst area.
1739         Allow areas to be clamped so long as the clamped edge is not the preferred edge.
1740
1741         * UserInterface/Base/Test.js:
1742         (WI.initializeTarget): Added.
1743
1744         * UserInterface/Images/Device.svg: Added.
1745         * Localizations/en.lproj/localizedStrings.js:
1746
1747 2019-01-25  Devin Rousso  <drousso@apple.com>
1748
1749         Web Inspector: Audit: unable to import audits
1750         https://bugs.webkit.org/show_bug.cgi?id=193861
1751
1752         Reviewed by Joseph Pecoraro.
1753
1754         * UserInterface/Controllers/AuditManager.js:
1755         (WI.AuditManager.prototype.async processJSON):
1756
1757 2019-01-25  Devin Rousso  <drousso@apple.com>
1758
1759         Web Inspector: Uncaught Exception: No node with given id found
1760         https://bugs.webkit.org/show_bug.cgi?id=193833
1761
1762         Reviewed by Joseph Pecoraro.
1763
1764         * UserInterface/Views/CanvasContentView.js:
1765         (WI.CanvasContentView):
1766         (WI.CanvasContentView.prototype.initialLayout):
1767         (WI.CanvasContentView.prototype.layout):
1768         (WI.CanvasContentView.prototype._refreshPixelSize):
1769         Drive-by: show the refresh button when viewing a specific canvas.
1770
1771         * UserInterface/Views/CanvasTabContentView.js:
1772         (WI.CanvasTabContentView.prototype._removeCanvas):
1773         Reset to the overview if the canvas is removed.
1774
1775 2019-01-25  Joseph Pecoraro  <pecoraro@apple.com>
1776
1777         Web Inspector: Improve Dark Mode appearance within Memory timeline
1778         https://bugs.webkit.org/show_bug.cgi?id=193804
1779
1780         Reviewed by Matt Baker.
1781
1782         * UserInterface/Views/TimelineOverview.css:
1783         (.timeline-overview.edit-instruments > .tree-outline.timelines .item.selected):
1784         (.timeline-overview > .tree-outline.timelines .item.selected + .item,):
1785         (@media (prefers-color-scheme: dark)):
1786         (.timeline-overview > .tree-outline.timelines .item.selected + .item): Deleted.
1787         (body.window-inactive .timeline-overview > .tree-outline.timelines .item.selected + .item): Deleted.
1788         Fix some colors for Timelines edit mode.
1789
1790         * UserInterface/Views/CPUTimelineOverviewGraph.css:
1791         (.timeline-overview-graph.cpu:nth-child(even) > .legend):
1792         (@media (prefers-color-scheme: dark)):
1793         (.timeline-overview-graph.cpu > .legend):
1794         (.timeline-overview-graph:nth-child(even) > .legend): Deleted.
1795         * UserInterface/Views/MemoryTimelineOverviewGraph.css:
1796         (.timeline-overview-graph.memory:nth-child(even) > .legend):
1797         (@media (prefers-color-scheme: dark)):
1798         (.timeline-overview-graph.memory > .legend):
1799         (.timeline-overview-graph:nth-child(even) > .legend): Deleted.
1800         Improved colors in CPU / Memory overview graph legends.
1801
1802         * UserInterface/Views/CPUUsageView.css:
1803         (.cpu-usage-view > .details):
1804         * UserInterface/Views/CircleChart.css:
1805         (.circle-chart > svg > path.background):
1806         * UserInterface/Views/MemoryCategoryView.css:
1807         (.memory-category-view > .details):
1808         (.memory-category-view > .details > .name):
1809         * UserInterface/Views/MemoryTimelineView.css:
1810         (.timeline-view.memory > .content > .overview .total-usage,):
1811         (.timeline-view.memory .legend > .row > .size):
1812         Improved colors in CPU / Memory detail views.
1813
1814         * UserInterface/Views/Variables.css:
1815         (:root):
1816         Add a default --text-secondary-color which will end up slightly
1817         lighter in dark mode where it was already implemented.
1818
1819         (@media (prefers-color-scheme: dark)):
1820         Improved max-comparison colors.
1821
1822 2019-01-25  Devin Rousso  <drousso@apple.com>
1823
1824         Web Inspector: Timelines: DOMContentLoaded and load event lines need to be more obvious
1825         https://bugs.webkit.org/show_bug.cgi?id=193186
1826         <rdar://problem/45100694>
1827
1828         Reviewed by Joseph Pecoraro.
1829
1830         Shift around z-index values to make Timelines markers appear behind record bars. Widen the
1831         marker hit region to make it easier to see the tooltip.
1832
1833         * UserInterface/Views/Variables.css:
1834         (:root):
1835
1836         * UserInterface/Views/TimelineRuler.css:
1837         (.timeline-ruler):
1838         (.timeline-ruler > .markers):
1839         (.timeline-ruler > .markers > .marker):
1840         (body[dir=ltr] .timeline-ruler > .markers > .marker):
1841         (body[dir=rtl] .timeline-ruler > .markers > .marker):
1842         (.timeline-ruler > .markers > .marker::before):
1843         (body[dir=ltr] .timeline-ruler > .markers > .marker::before):
1844         (body[dir=rtl] .timeline-ruler > .markers > .marker::before):
1845         (.timeline-ruler > .markers > .marker::after): Added.
1846         (body[dir=ltr] .timeline-ruler > .markers > .marker::after): Added.
1847         (body[dir=rtl] .timeline-ruler > .markers > .marker::after): Added.
1848         (.timeline-ruler > .markers > .marker.current-time):
1849         (.timeline-ruler > .markers > .marker.current-time::after): Added.
1850         (.timeline-ruler > .markers > .marker.load-event):
1851         (.timeline-ruler > .markers > .marker.dom-content-event):
1852         (.timeline-ruler > .markers > .marker.timestamp):
1853         (.timeline-ruler > .selection-handle):
1854         (.timeline-ruler.both-handles-clamped > .selection-handle):
1855         (.timeline-ruler > .shaded-area):
1856         (.timeline-ruler > .markers > .marker.current-time::before): Deleted.
1857
1858         * UserInterface/Views/TimelineRecordBar.css:
1859         (.timeline-record-bar):
1860         (.timeline-record-bar > .segment):
1861
1862         * UserInterface/Views/CPUTimelineOverviewGraph.css:
1863         (.timeline-overview-graph.cpu > .legend):
1864         * UserInterface/Views/MemoryTimelineOverviewGraph.css:
1865         (.timeline-overview-graph.memory > .legend):
1866
1867 2019-01-25  Devin Rousso  <drousso@apple.com>
1868
1869         Web Inspector: Audit: remove experimental setting
1870         https://bugs.webkit.org/show_bug.cgi?id=193743
1871         <rdar://problem/28234022>
1872
1873         Reviewed by Joseph Pecoraro.
1874
1875         * UserInterface/Base/Setting.js:
1876         (WI.Setting):
1877         (WI.Setting.localStorageKey): Added.
1878         (WI.Setting.migrateValue):
1879         Drive-by: add the localStorage key prefix to the key passed into `WI.Setting.migrateValue`.
1880
1881         * UserInterface/Base/Main.js:
1882         (WI.loaded):
1883
1884         * UserInterface/Views/AuditTabContentView.js:
1885         (WI.AuditTabContentView.isTabAllowed):
1886
1887         * UserInterface/Views/SettingsTabContentView.js:
1888         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1889
1890         * Localizations/en.lproj/localizedStrings.js:
1891
1892 2019-01-25  Devin Rousso  <drousso@apple.com>
1893
1894         Web Inspector: show uncaught exception view for unhandled promise rejections
1895         https://bugs.webkit.org/show_bug.cgi?id=193832
1896
1897         Reviewed by Matt Baker.
1898
1899         * UserInterface/Debug/UncaughtExceptionReporter.js:
1900         (handleUnhandledPromiseRejection): Added.
1901
1902 2019-01-25  Devin Rousso  <drousso@apple.com>
1903
1904         Web Inspector: REGRESSION (r237808): offscreen path warning doesn't work
1905         https://bugs.webkit.org/show_bug.cgi?id=193830
1906
1907         Reviewed by Matt Baker.
1908
1909         * UserInterface/Models/RecordingAction.js:
1910         (WI.RecordingAction.prototype.process):
1911
1912 2019-01-25  Joseph Pecoraro  <pecoraro@apple.com>
1913
1914         Web Inspector: Add another Protocol Version (iOS 12.2)
1915         https://bugs.webkit.org/show_bug.cgi?id=193810
1916         <rdar://problem/42981838>
1917
1918         Reviewed by Matt Baker.
1919
1920         * UserInterface/Protocol/Legacy/12.2/InspectorBackendCommands.js: Added.
1921         * Versions/Inspector-iOS-12.2.json: Added.
1922
1923 2019-01-25  Devin Rousso  <drousso@apple.com>
1924
1925         Web Inspector: `WI.Setting.migrateValue` doesn't take into account the key prefix
1926         https://bugs.webkit.org/show_bug.cgi?id=193814
1927
1928         Reviewed by Matt Baker.
1929
1930         * UserInterface/Base/Setting.js:
1931         (WI.Setting):
1932         (WI.Setting.migrateValue):
1933         (WI.Setting._localStorageKey): Added.
1934
1935 2019-01-25  Devin Rousso  <drousso@apple.com>
1936
1937         Web Inspector: improve invalid Audit/Recording JSON error messages
1938         https://bugs.webkit.org/show_bug.cgi?id=193476
1939         <rdar://problem/47303659>
1940
1941         Reviewed by Joseph Pecoraro.
1942
1943         * UserInterface/Models/AuditTestBase.js:
1944         (WI.AuditTestBase):
1945         * UserInterface/Models/AuditTestCase.js:
1946         (WI.AuditTestCase.async fromPayload):
1947         * UserInterface/Models/AuditTestGroup.js:
1948         (WI.AuditTestGroup.async fromPayload):
1949         * UserInterface/Models/AuditTestCaseResult.js:
1950         (WI.AuditTestCaseResult.async fromPayload.checkArray):
1951         (WI.AuditTestCaseResult.async fromPayload):
1952         * UserInterface/Models/AuditTestGroupResult.js:
1953         (WI.AuditTestGroupResult.async fromPayload):
1954         * UserInterface/Controllers/AuditManager.js:
1955         (WI.AuditManager.synthesizeWarning): Added.
1956         (WI.AuditManager.synthesizeError):
1957         (WI.AuditManager.prototype.async processJSON):
1958
1959         * UserInterface/Models/Recording.js:
1960         (WI.Recording.fromPayload):
1961         (WI.Recording.synthesizeWarning): Added.
1962         (WI.Recording.synthesizeError):
1963         * UserInterface/Models/RecordingFrame.js:
1964         (WI.RecordingFrame.fromPayload):
1965         * UserInterface/Models/RecordingAction.js:
1966         (WI.RecordingAction.fromPayload):
1967         (WI.RecordingAction.prototype.async swizzle):
1968         (WI.RecordingAction.prototype.apply):
1969         * UserInterface/Controllers/CanvasManager.js:
1970         (WI.CanvasManager.prototype.processJSON):
1971
1972         * Localizations/en.lproj/localizedStrings.js:
1973
1974 2019-01-24  Devin Rousso  <drousso@apple.com>
1975
1976         Web Inspector: Audit: add supports key to test/group for compatibility
1977         https://bugs.webkit.org/show_bug.cgi?id=193686
1978         <rdar://problem/47460872>
1979
1980         Reviewed by Joseph Pecoraro.
1981
1982         * UserInterface/Models/AuditTestBase.js:
1983         (WI.AuditTestBase):
1984         (WI.AuditTestBase.prototype.get supported): Added.
1985         (WI.AuditTestBase.prototype.set supported): Added.
1986         (WI.AuditTestBase.prototype.set disabled):
1987         (WI.AuditTestBase.prototype.async start):
1988         (WI.AuditTestBase.prototype.stop):
1989         (WI.AuditTestBase.toJSON):
1990         * UserInterface/Models/AuditTestCase.js:
1991         (WI.AuditTestCase.async fromPayload):
1992         * UserInterface/Models/AuditTestGroup.js:
1993         (WI.AuditTestGroup):
1994         (WI.AuditTestGroup.async fromPayload):
1995         (WI.AuditTestGroup.prototype.get supported): Added.
1996         (WI.AuditTestGroup.prototype.set supported): Added.
1997         Add support for a "supports" key in the test JSON that prevents the test from being run if
1998         it's value is lower than the frontend/backend version.
1999
2000         * UserInterface/Views/AuditTreeElement.js:
2001         (WI.AuditTreeElement.prototype.onattach):
2002         (WI.AuditTreeElement.prototype.ondelete):
2003         (WI.AuditTreeElement.prototype.populateContextMenu):
2004         (WI.AuditTreeElement.prototype._updateStatus): Added.
2005         (WI.AuditTreeElement.prototype._showRunningSpinner):
2006         (WI.AuditTreeElement.prototype._showRunningProgress):
2007         (WI.AuditTreeElement.prototype._updateTestGroupDisabled):
2008         (WI.AuditTreeElement.prototype._handleTestCaseCompleted):
2009         (WI.AuditTreeElement.prototype._handleTestResultCleared):
2010         (WI.AuditTreeElement.prototype._handleTestGroupCompleted):
2011         (WI.AuditTreeElement.prototype._handleManagerEditingChanged):
2012         (WI.AuditTreeElement.prototype.canSelectOnMouseDown): Deleted.
2013         (WI.AuditTreeElement.prototype._updateLevel): Deleted.
2014         * UserInterface/Views/AuditTreeElement.css:
2015         (.tree-outline .item.audit:matches(.test-case, .test-group):not(.unsupported, .manager-active) > .status:hover > img): Added.
2016         (.tree-outline .item.audit > .status:not(:hover) > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.unsupported, .editing-audits) > .status:not(:hover)): Added.
2017         (.tree-outline .item.audit.manager-active > .status > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.editing-audits) > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status, .tree-outline .item.audit.unsupported + .children .item.audit.unsupported  > .status > img): Added.
2018         (.tree-outline .item.audit.unsupported:not(.selected) > :matches(.icon, .titles)): Added.
2019         (.tree-outline .item.audit.unsupported > .status > img): Added.
2020         (.tree-outline .item.audit:matches(.test-case, .test-group):not(.manager-active) > .status:hover > img): Deleted.
2021         (.tree-outline .item.audit > .status:not(:hover) > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.editing-audits) > .status:not(:hover)): Deleted.
2022         (.tree-outline .item.audit.manager-active > .status > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.editing-audits) > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status): Deleted.
2023         Hide unsupported tests unless in edit mode, where they are greyed out and cannot be enabled.
2024         Drive-by: only allow tests to be deleted when in edit mode.
2025
2026         * UserInterface/Views/AuditNavigationSidebarPanel.js:
2027         (WI.AuditNavigationSidebarPanel.prototype._treeSelectionDidChange):
2028
2029         * Localizations/en.lproj/localizedStrings.js:
2030
2031 2019-01-24  Joseph Pecoraro  <pecoraro@apple.com>
2032
2033         Web Inspector: CPU Usage Timeline
2034         https://bugs.webkit.org/show_bug.cgi?id=193730
2035         <rdar://problem/46797201>
2036
2037         Reviewed by Devin Rousso.
2038
2039         CPU Usage is gathered in the backend twice a second, the frequency of the
2040         ResourceUsageThread in WebCore. The frontend displays cpu usage in a few
2041         ways in the Timeline.
2042
2043         We use a column chart in the timeline overview to display the frequency and
2044         relative distance of samples. This helps show if the samples were close
2045         together or far apart, which indicates how meaningful they will be at a
2046         particular scale.
2047
2048         We use a line chart in the timeline detail view which will be easier to see
2049         the changes over a particular time range selection.
2050
2051         * Localizations/en.lproj/localizedStrings.js:
2052         New strings.
2053
2054         * UserInterface/Main.html:
2055         * UserInterface/Base/Main.js:
2056         (WI.loaded):
2057         * UserInterface/Test.html:
2058         * UserInterface/Test/Test.js:
2059         (WI.loaded):
2060         * UserInterface/Protocol/CPUProfilerObserver.js:
2061         (WI.CPUProfilerObserver.prototype.trackingStart):
2062         (WI.CPUProfilerObserver.prototype.trackingUpdate):
2063         (WI.CPUProfilerObserver.prototype.trackingComplete):
2064         (WI.CPUProfilerObserver):
2065         New files and default registration.
2066
2067         * UserInterface/Protocol/Target.js:
2068         (WI.Target.prototype.get CPUProfilerAgent):
2069         New Agent.
2070
2071         * UserInterface/Controllers/TimelineManager.js:
2072         (WI.TimelineManager.availableTimelineTypes):
2073         (WI.TimelineManager.prototype.cpuProfilerTrackingStarted):
2074         (WI.TimelineManager.prototype.cpuProfilerTrackingUpdated):
2075         (WI.TimelineManager.prototype.cpuProfilerTrackingCompleted):
2076         (WI.TimelineManager.prototype._updateAutoCaptureInstruments):
2077         (WI.TimelineManager.prototype.memoryTrackingStart): Renamed.
2078         (WI.TimelineManager.prototype.memoryTrackingUpdate): Renamed.
2079         (WI.TimelineManager.prototype.memoryTrackingComplete): Renamed.
2080         * UserInterface/Models/CPUInstrument.js:
2081         (WI.CPUInstrument):
2082         (WI.CPUInstrument.supported):
2083         (WI.CPUInstrument.prototype.get timelineRecordType):
2084         (WI.CPUInstrument.prototype.startInstrumentation):
2085         (WI.CPUInstrument.prototype.stopInstrumentation):
2086         * UserInterface/Models/CPUTimelineRecord.js:
2087         (WI.CPUTimelineRecord):
2088         (WI.CPUTimelineRecord.prototype.get timestamp):
2089         (WI.CPUTimelineRecord.prototype.get usage):
2090         * UserInterface/Models/Instrument.js:
2091         (WI.Instrument.createForTimelineType):
2092         * UserInterface/Models/TimelineRecord.js:
2093         * UserInterface/Models/TimelineRecording.js:
2094         (WI.TimelineRecording.prototype.addRecord):
2095         Expose a new CPU instrument and timeline.
2096
2097         * UserInterface/Views/ColumnChart.js: Added.
2098         (WI.ColumnChart):
2099         (WI.ColumnChart.prototype.get element):
2100         (WI.ColumnChart.prototype.get bars):
2101         (WI.ColumnChart.prototype.get size):
2102         (WI.ColumnChart.prototype.set size):
2103         (WI.ColumnChart.prototype.addBar):
2104         (WI.ColumnChart.prototype.clear):
2105         (WI.ColumnChart.prototype.needsLayout):
2106         (WI.ColumnChart.prototype.updateLayout):
2107         View that will draw vertical bars with independent widths.
2108         This is meant to be used similiar to WI.LineChart.
2109
2110         * UserInterface/Images/CPUInstrument.svg: Added.
2111         * UserInterface/Views/Variables.css:
2112         (:root):
2113         CPU timeline colors and icon.
2114
2115         * UserInterface/Views/CPUTimelineOverviewGraph.css:
2116         (body .sidebar > .panel.navigation.timeline > .timelines-content li.item.cpu,):
2117         (.timeline-overview-graph.cpu):
2118         (.timeline-overview-graph.cpu > .legend):
2119         (body[dir=ltr] .timeline-overview-graph.cpu > .legend):
2120         (body[dir=rtl] .timeline-overview-graph.cpu > .legend):
2121         (.timeline-overview-graph:nth-child(even) > .legend):
2122         (body[dir=rtl] .timeline-overview-graph.cpu > .bar-chart):
2123         (.timeline-overview-graph.cpu > .bar-chart > svg > g > rect):
2124         * UserInterface/Views/CPUTimelineOverviewGraph.js: Added.
2125         (WI.CPUTimelineOverviewGraph):
2126         (WI.CPUTimelineOverviewGraph.prototype.get height):
2127         (WI.CPUTimelineOverviewGraph.prototype.reset):
2128         (WI.CPUTimelineOverviewGraph.prototype.layout.xScale):
2129         (WI.CPUTimelineOverviewGraph.prototype.layout.yScale):
2130         (WI.CPUTimelineOverviewGraph.prototype.layout.yScaleForRecord):
2131         (WI.CPUTimelineOverviewGraph.prototype.layout):
2132         (WI.CPUTimelineOverviewGraph.prototype._updateLegend):
2133         (WI.CPUTimelineOverviewGraph.prototype._cpuTimelineRecordAdded):
2134         * UserInterface/Views/CPUTimelineView.css:
2135         (.timeline-view.cpu):
2136         (.timeline-view.cpu > .content):
2137         (.timeline-view.cpu > .content .subtitle):
2138         (.timeline-view.cpu > .content > .details):
2139         (.timeline-view.cpu > .content > .details > .timeline-ruler):
2140         (body[dir=ltr] .timeline-view.cpu > .content > .details > .timeline-ruler):
2141         (body[dir=rtl] .timeline-view.cpu > .content > .details > .timeline-ruler):
2142         (.timeline-view.cpu > .content > .details > .subtitle):
2143         (.cpu-usage-view .line-chart > svg > path):
2144         (.timeline-view.cpu .legend > .row > .swatch.current):
2145         * UserInterface/Views/CPUTimelineView.js: Added.
2146         (WI.CPUTimelineView):
2147         (WI.CPUTimelineView.prototype.shown):
2148         (WI.CPUTimelineView.prototype.hidden):
2149         (WI.CPUTimelineView.prototype.closed):
2150         (WI.CPUTimelineView.prototype.reset):
2151         (WI.CPUTimelineView.prototype.get scrollableElements):
2152         (WI.CPUTimelineView.prototype.get showsFilterBar):
2153         (WI.CPUTimelineView.prototype.layout.layoutView):
2154         (WI.CPUTimelineView.prototype.layout.xScale):
2155         (WI.CPUTimelineView.prototype.layout.yScale):
2156         (WI.CPUTimelineView.prototype.layout):
2157         (WI.CPUTimelineView.prototype._cpuTimelineRecordAdded):
2158         * UserInterface/Views/CPUUsageView.css:
2159         (.cpu-usage-view):
2160         (.cpu-usage-view > .details):
2161         (body[dir=ltr] .cpu-usage-view > .details):
2162         (body[dir=rtl] .cpu-usage-view > .details):
2163         (.cpu-usage-view > .graph):
2164         (body[dir=rtl] .cpu-usage-view > .graph):
2165         * UserInterface/Views/CPUUsageView.js:
2166         (WI.CPUUsageView):
2167         (WI.CPUUsageView.prototype.get element):
2168         (WI.CPUUsageView.prototype.clear):
2169         (WI.CPUUsageView.prototype.layoutWithDataPoints):
2170         (WI.CPUUsageView.prototype._updateDetails):
2171         * UserInterface/Views/ContentView.js:
2172         (WI.ContentView.createFromRepresentedObject):
2173         * UserInterface/Views/TimelineIcons.css:
2174         (.cpu-icon .icon):
2175         * UserInterface/Views/TimelineOverviewGraph.js:
2176         (WI.TimelineOverviewGraph.createForTimeline):
2177         * UserInterface/Views/TimelineTabContentView.js:
2178         (WI.TimelineTabContentView.displayNameForTimelineType):
2179         (WI.TimelineTabContentView.iconClassNameForTimelineType):
2180         (WI.TimelineTabContentView.genericClassNameForTimelineType):
2181         (WI.TimelineTabContentView.iconClassNameForRecord):
2182         (WI.TimelineTabContentView.displayNameForRecord):
2183         Timeline views for CPU usage.
2184
2185         * UserInterface/Views/MemoryCategoryView.js:
2186         (WI.MemoryCategoryView):
2187         * UserInterface/Views/MemoryTimelineView.js:
2188         (WI.MemoryTimelineView.createChartContainer):
2189         (WI.MemoryTimelineView):
2190         (WI.MemoryTimelineView.prototype._clearMaxComparisonLegend):
2191         Minor updates to style and comments.
2192
2193 2019-01-23  Nikita Vasilyev  <nvasilyev@apple.com>
2194
2195         Web Inspector: Refactor WI.CSSStyleDeclaration.prototype.update
2196         https://bugs.webkit.org/show_bug.cgi?id=193737
2197
2198         Reviewed by Matt Baker.
2199
2200         Remove unused event data from the WI.CSSStyleDeclaration.Event.PropertiesChanged event.
2201
2202         * UserInterface/Models/CSSStyleDeclaration.js:
2203         (WI.CSSStyleDeclaration.prototype.update):
2204
2205 2019-01-23  Devin Rousso  <drousso@apple.com>
2206
2207         WebInspector: Confusingly nested events in the timeline for Mutation Observers
2208         https://bugs.webkit.org/show_bug.cgi?id=192884
2209         <rdar://problem/46854178>
2210
2211         Reviewed by Joseph Pecoraro.
2212
2213         If a microtask event (e.g. `ObserverCallback`) is contained within a `EvaluatedScript`
2214         event, move that microtask event to be a sibling of the `EvaluateScript`, subtracting the
2215         microtask's time taken from the `EvaluateScript`'s time. If there are no other children
2216         after this move, then remove the `EvaluateScript` altogether.
2217
2218         * UserInterface/Controllers/TimelineManager.js:
2219         (WI.TimelineManager.prototype.eventRecorded.fixMicrotaskPlacement): Added.
2220         (WI.TimelineManager.prototype.eventRecorded):
2221         (WI.TimelineManager.prototype._mergeScriptProfileRecords):
2222
2223 2019-01-23  Joseph Pecoraro  <pecoraro@apple.com>
2224
2225         Web Inspector: Network Waterfall column should redraw when adding/removing new columns
2226         https://bugs.webkit.org/show_bug.cgi?id=193696
2227         <rdar://problem/47464149>
2228
2229         Reviewed by Devin Rousso.
2230
2231         * UserInterface/Views/TableColumn.js:
2232         (WI.TableColumn.prototype.get needsReloadOnResize):
2233         * UserInterface/Views/NetworkTableContentView.js:
2234         (WI.NetworkTableContentView.prototype.initialLayout):
2235         Mark the waterfall column as sensitive to any resizes.
2236
2237         * UserInterface/Views/Table.js:
2238         (WI.Table.prototype.showColumn):
2239         (WI.Table.prototype.hideColumn):
2240         Update column widths and reload any columns that may be sensitive to resizes.
2241
2242 2019-01-22  Devin Rousso  <drousso@apple.com>
2243
2244         Web Inspector: InspectorInstrumentation::willEvaluateScript should include column number
2245         https://bugs.webkit.org/show_bug.cgi?id=116191
2246         <rdar://problem/13905910>
2247
2248         Reviewed by Joseph Pecoraro.
2249
2250         * UserInterface/Controllers/TimelineManager.js:
2251         (WI.TimelineManager.prototype._processRecord):
2252
2253 2019-01-22  Devin Rousso  <drousso@apple.com>
2254
2255         Web Inspector: expose Audit and Recording versions to the frontend
2256         https://bugs.webkit.org/show_bug.cgi?id=193262
2257         <rdar://problem/47130684>
2258
2259         Reviewed by Joseph Pecoraro.
2260
2261         * UserInterface/Protocol/InspectorBackend.js:
2262         (InspectorBackendClass.prototype.registerVersion): Added.
2263
2264         * UserInterface/Models/AuditTestCase.js:
2265         * UserInterface/Models/Recording.js:
2266         (WI.Recording.fromPayload):
2267         Add Interface version values.
2268
2269 2019-01-22  Nikita Vasilyev  <nvasilyev@apple.com>
2270
2271         Web Inspector: Styles: refactor properties/allProperties/visibleProperties/allVisibleProperties
2272         https://bugs.webkit.org/show_bug.cgi?id=193615
2273
2274         Reviewed by Devin Rousso.
2275
2276         Remove unused visibleProperties.
2277
2278         Rename:
2279         - properties to enabledProperties;
2280         - allProperties to properties;
2281         - allVisibleProperties to visibleProperties.
2282
2283         * UserInterface/Models/CSSProperty.js:
2284         (WI.CSSProperty.prototype._prependSemicolonIfNeeded):
2285         (WI.CSSProperty):
2286         * UserInterface/Models/CSSStyleDeclaration.js:
2287         (WI.CSSStyleDeclaration):
2288         (WI.CSSStyleDeclaration.prototype.get enabledProperties):
2289         (WI.CSSStyleDeclaration.prototype.get properties):
2290         (WI.CSSStyleDeclaration.prototype.propertyForName):
2291         (WI.CSSStyleDeclaration.prototype.newBlankProperty):
2292         (WI.CSSStyleDeclaration.prototype.shiftPropertiesAfter):
2293         (WI.CSSStyleDeclaration.prototype._rangeAfterPropertyAtIndex):
2294         * UserInterface/Models/DOMNodeStyles.js:
2295         (WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
2296         (WI.DOMNodeStyles.prototype._markOverriddenProperties):
2297         (WI.DOMNodeStyles.prototype._associateRelatedProperties):
2298         (WI.DOMNodeStyles.prototype._isPropertyFoundInMatchingRules):
2299         (WI.DOMNodeStyles):
2300         * UserInterface/Views/BoxModelDetailsSectionRow.js:
2301         (WI.BoxModelDetailsSectionRow.prototype._updateMetrics):
2302         * UserInterface/Views/ComputedStyleDetailsPanel.js:
2303         (WI.ComputedStyleDetailsPanel.prototype._computePropertyTraces):
2304         * UserInterface/Views/ComputedStyleSection.js:
2305         (WI.ComputedStyleSection.prototype.get propertiesToRender):
2306         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
2307         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get propertiesToRender):
2308         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
2309         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.layout):
2310         * UserInterface/Views/SpreadsheetStyleProperty.js:
2311         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
2312
2313 2019-01-22  Joseph Pecoraro  <pecoraro@apple.com>
2314
2315         Web Inspector: Network Table appears broken after filter - rows look collapsed
2316         https://bugs.webkit.org/show_bug.cgi?id=192730
2317         <rdar://problem/46853158>
2318
2319         Reviewed by Devin Rousso.
2320
2321         * UserInterface/Views/Table.js:
2322         (WI.Table.prototype._applyColumnWidthsToColumnsIfNeeded):
2323         Affect the filler row like the other applyColumnWidths calls since this
2324         now may be the initial call to size visible columns.
2325
2326 2019-01-22  Devin Rousso  <drousso@apple.com>
2327
2328         Web Inspector: Audit: use plural strings for Passed, Failed, and Unsupported
2329         https://bugs.webkit.org/show_bug.cgi?id=193675
2330         <rdar://problem/46628680>
2331
2332         Reviewed by Joseph Pecoraro.
2333
2334         * UserInterface/Views/AuditTestGroupContentView.js:
2335         (WI.AuditTestGroupContentView.prototype.layout):
2336
2337         * Localizations/en.lproj/localizedStrings.js:
2338
2339 2019-01-18  Jer Noble  <jer.noble@apple.com>
2340
2341         SDK_VARIANT build destinations should be separate from non-SDK_VARIANT builds
2342         https://bugs.webkit.org/show_bug.cgi?id=189553
2343
2344         Reviewed by Tim Horton.
2345
2346         * Configurations/Base.xcconfig:
2347         * Configurations/SDKVariant.xcconfig: Added.
2348
2349 2019-01-18  Devin Rousso  <drousso@apple.com>
2350
2351         Web Inspector: Uncaught Exception: TypeError: undefined is not an object (evaluating 'resource.finished')
2352         https://bugs.webkit.org/show_bug.cgi?id=193589
2353
2354         Reviewed by Joseph Pecoraro.
2355
2356         * UserInterface/Views/NetworkTableContentView.js:
2357         (WI.NetworkTableContentView.prototype.get supportsSave):
2358         (WI.NetworkTableContentView.prototype._HARResources):
2359
2360 2019-01-17  Truitt Savell  <tsavell@apple.com>
2361
2362         Unreviewed, rolling out r240124.
2363
2364         This commit broke an internal build.
2365
2366         Reverted changeset:
2367
2368         "SDK_VARIANT build destinations should be separate from non-
2369         SDK_VARIANT builds"
2370         https://bugs.webkit.org/show_bug.cgi?id=189553
2371         https://trac.webkit.org/changeset/240124
2372
2373 2019-01-17  Jer Noble  <jer.noble@apple.com>
2374
2375         SDK_VARIANT build destinations should be separate from non-SDK_VARIANT builds
2376         https://bugs.webkit.org/show_bug.cgi?id=189553
2377
2378         Reviewed by Tim Horton.
2379
2380         * Configurations/Base.xcconfig:
2381         * Configurations/SDKVariant.xcconfig: Added.
2382
2383 2019-01-16  Matt Baker  <mattbaker@apple.com>
2384
2385         Web Inspector: Fix TreeOutline TypeError:ā€‹ this._indexesForSubtree is not a function
2386         https://bugs.webkit.org/show_bug.cgi?id=193501
2387         <rdar://problem/47323967>
2388
2389         Reviewed by Joseph Pecoraro.
2390
2391         * UserInterface/Views/TreeOutline.js:
2392         (WI.TreeOutline.prototype.removeChildAtIndex):
2393
2394 2019-01-15  Devin Rousso  <drousso@apple.com>
2395
2396         Web Inspector: Audit: create new IDL type for exposing special functionality in test context
2397         https://bugs.webkit.org/show_bug.cgi?id=193149
2398         <rdar://problem/46801218>
2399
2400         Reviewed by Joseph Pecoraro.
2401
2402         Add `AuditAgent` getters and plumbing.
2403
2404         * UserInterface/Protocol/Target.js:
2405         (WI.Target.prototype.get AuditAgent): Added.
2406
2407         * UserInterface/Models/AuditTestCase.js:
2408         (WI.AuditTestCase.prototype.async run):
2409
2410         * UserInterface/Controllers/AuditManager.js:
2411         (WI.AuditManager.prototype.async start):
2412
2413         * .eslintrc:
2414
2415 2019-01-14  Devin Rousso  <drousso@apple.com>
2416
2417         Web Inspector: Event breakpoints: typing uppercase "DOM" doesn't show completions for events that start with "DOM"
2418         https://bugs.webkit.org/show_bug.cgi?id=193384
2419
2420         Reviewed by Joseph Pecoraro.
2421
2422         * UserInterface/Views/EventBreakpointPopover.js:
2423         (WI.EventBreakpointPopover.prototype.show):
2424
2425 2019-01-14  Devin Rousso  <drousso@apple.com>
2426
2427         Web Inspector: Event breakpoints: text field and completion popover fonts should match
2428         https://bugs.webkit.org/show_bug.cgi?id=193249
2429
2430         Reviewed by Matt Baker.
2431
2432         * UserInterface/Views/EventBreakpointPopover.css:
2433         (.popover .event-breakpoint-content > .event-type > input): Added.
2434         (.popover .event-breakpoint-content > .event-type > input::placeholder): Added.
2435         * UserInterface/Views/EventBreakpointPopover.js:
2436         (WI.EventBreakpointPopover.prototype.show):
2437         (WI.EventBreakpointPopover.prototype._showSuggestionsView):
2438         Subtract the <input> border and padding from the bounds position so the <input> text lines
2439         up with the `WI.CompletionSuggestionsView` text.
2440
2441         * UserInterface/Views/CompletionSuggestionsView.js:
2442         (WI.CompletionSuggestionsView):
2443         Drive-by: force `dir=ltr` to match the `text-align: left;` CSS styling.
2444
2445 2019-01-14  Nikita Vasilyev  <nvasilyev@apple.com>
2446
2447         Web Inspector: Styles: pressing Down key on empty value field shouldn't discard completion popover
2448         https://bugs.webkit.org/show_bug.cgi?id=193098
2449         <rdar://problem/47016036>
2450
2451         Reviewed by Devin Rousso.
2452
2453         Hide CompletionSuggestionsView when SpreadsheetTextField moves, e.g. by scrolling or resizing the sidebar.
2454         Update CompletionSuggestionsView position after pressing Up or Down key, because SpreadsheetTextField may
2455         move from wrapping text.
2456
2457         * UserInterface/Views/CompletionSuggestionsView.js:
2458         (WI.CompletionSuggestionsView.prototype.hide):
2459         (WI.CompletionSuggestionsView.prototype.show):
2460         (WI.CompletionSuggestionsView.prototype.showUntilAnchorMoves): Removed.
2461         (WI.CompletionSuggestionsView.prototype.hideWhenElementMoves): Added.
2462         (WI.CompletionSuggestionsView.prototype._stopMoveTimer): Added.
2463         (WI.CompletionSuggestionsView):
2464
2465         * UserInterface/Views/SpreadsheetTextField.js:
2466         (WI.SpreadsheetTextField.prototype.set suggestionHint):
2467         (WI.SpreadsheetTextField.prototype.completionSuggestionsSelectedCompletion):
2468         (WI.SpreadsheetTextField.prototype._handleKeyDownForSuggestionView):
2469         (WI.SpreadsheetTextField.prototype._updateCompletions):
2470         (WI.SpreadsheetTextField.prototype._showSuggestionsView): Added.
2471
2472         (WI.SpreadsheetTextField.prototype._reAttachSuggestionHint):
2473         Drive-by: abstract out repeating code into a private method.
2474
2475 2019-01-14  Devin Rousso  <drousso@apple.com>
2476
2477         Web Inspector: Settings: group titles should vertically align with the first editor
2478         https://bugs.webkit.org/show_bug.cgi?id=193391
2479
2480         Reviewed by Dean Jackson.
2481
2482         * UserInterface/Views/SettingsTabContentView.css:
2483         (.content-view.settings > .settings-view > .container):
2484         (.content-view.settings > .settings-view > .container > .editor-group > .editor): Added.
2485         (.content-view.settings > .settings-view > .container > .editor-group > .editor:first-child > *): Added.
2486         (.content-view.settings > .settings-view > .container > .editor-group > .editor select):
2487         (.content-view.settings > .settings-view > .container > .editor-group > .editor input[type="number"]):
2488
2489 2019-01-11  Matt Baker  <mattbaker@apple.com>
2490
2491         Web Inspector: REGRESSION: deleting an audit puts selection in a selected but invisible state
2492         https://bugs.webkit.org/show_bug.cgi?id=192917
2493         <rdar://problem/46875285>
2494
2495         Reviewed by Devin Rousso.
2496
2497         SelectionController should not be notified of removed children until the
2498         child items have been removed from the TreeOutline. Doing so at this stage
2499         is unsafe, since this method checks `this.selectedTreeElement`, which could
2500         return the adjusted index from the SelectionController before anything has
2501         actually been removed from the TreeOutline.
2502
2503         The number of calls to SelectionController.prototype.didRemoveItems is also
2504         reduced somewhat, since we're no longer calling it for every TreeElement.
2505
2506         * UserInterface/Views/TreeOutline.js:
2507         (WI.TreeOutline.prototype.removeChildAtIndex):
2508         (WI.TreeOutline.prototype.removeChildren):
2509         (WI.TreeOutline.prototype._forgetTreeElement):
2510         (WI.TreeOutline.prototype._indexesForSubtree): Added.        
2511
2512 2019-01-10  Devin Rousso  <drousso@apple.com>
2513
2514         Web Inspector: Audit: allow audits to be enabled/disabled
2515         https://bugs.webkit.org/show_bug.cgi?id=192210
2516         <rdar://problem/46423583>
2517
2518         Reviewed by Joseph Pecoraro.
2519
2520         * UserInterface/Controllers/AuditManager.js:
2521         (WI.AuditManager.prototype.get editing): Added.
2522         (WI.AuditManager.prototype.set editing): Added.
2523         (WI.AuditManager.prototype.stop):
2524         (WI.AuditManager.prototype.addDefaultTestsIfNeeded):
2525         Since default audits aren't stored, keep a list of disabled default tests in a `WI.Setting`.
2526
2527         * UserInterface/Models/AuditTestBase.js:
2528         (WI.AuditTestBase):
2529         (WI.AuditTestBase.prototype.get disabled): Added.
2530         (WI.AuditTestBase.prototype.set disabled): Added.
2531         (WI.AuditTestBase.prototype.async start):
2532         (WI.AuditTestBase.prototype.stop):
2533         (WI.AuditTestBase.toJSON):
2534
2535         * UserInterface/Models/AuditTestCase.js:
2536         (WI.AuditTestCase):
2537         (WI.AuditTestCase.async fromPayload):
2538         (WI.AuditTestCase.prototype.toJSON):
2539
2540         * UserInterface/Models/AuditTestGroup.js:
2541         (WI.AuditTestGroup):
2542         (WI.AuditTestGroup.async fromPayload):
2543         (WI.AuditTestGroup.prototype.get disabled): Added.
2544         (WI.AuditTestGroup.prototype.set disabled): Added.
2545         (WI.AuditTestGroup.prototype.toJSON):
2546         (WI.AuditTestGroup.prototype.async run):
2547         (WI.AuditTestGroup.prototype._handleTestDisabledChanged): Added.
2548         (WI.AuditTestGroup.prototype._handleTestProgress):
2549         Propagate `disabled` changes to all sub-tests, unless the change was caused by one of the
2550         sub-tests, in which case we are now in an intermediate state.
2551
2552         * UserInterface/Views/AuditNavigationSidebarPanel.js:
2553         (WI.AuditNavigationSidebarPanel):
2554         (WI.AuditNavigationSidebarPanel.prototype.showDefaultContentView):
2555         (WI.AuditNavigationSidebarPanel.prototype.initialLayout):
2556         (WI.AuditNavigationSidebarPanel.prototype.hasCustomFilters): Added.
2557         (WI.AuditNavigationSidebarPanel.prototype.matchTreeElementAgainstCustomFilters): Added.
2558         (WI.AuditNavigationSidebarPanel.prototype._addTest):
2559         (WI.AuditNavigationSidebarPanel.prototype._addResult):
2560         (WI.AuditNavigationSidebarPanel.prototype._updateStartStopButtonNavigationItemState):
2561         (WI.AuditNavigationSidebarPanel.prototype._updateEditButtonNavigationItemState): Added.
2562         (WI.AuditNavigationSidebarPanel.prototype._handleAuditManagerEditingChanged): Added.
2563         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestRemoved):
2564         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestScheduled):
2565         (WI.AuditNavigationSidebarPanel.prototype._treeSelectionDidChange):
2566         (WI.AuditNavigationSidebarPanel.prototype._handleEditButtonNavigationItemClicked): Added.
2567         * UserInterface/Views/AuditNavigationSidebarPanel.css:
2568         (.sidebar > .panel.navigation.audit > .content):
2569         (.sidebar > .panel.navigation.audit > .content > .tree-outline): Added.
2570         (.sidebar > .panel.navigation.audit > .content .edit-audits:not(.disabled):active): Added.
2571         (.sidebar > .panel.navigation.audit > .content .edit-audits:not(.disabled).activated): Added.
2572         (.sidebar > .panel.navigation.audit > .content .edit-audits:not(.disabled).activated:active): Added.
2573         (.sidebar > .panel.navigation.audit > .content .edit-audits.disabled): Added.
2574         (.finish-editing-audits-placeholder.message-text-view .navigation-item-help .navigation-bar): Added.
2575         Leverage custom filters to ensure that disabled audits arent shown when not editing and that
2576         result tree elements aren't shown while editing.
2577
2578         * UserInterface/Views/AuditTestGroupContentView.js:
2579         (WI.AuditTestGroupContentView.prototype.shown):
2580
2581         * UserInterface/Views/AuditTreeElement.js:
2582         (WI.AuditTreeElement.prototype.onattach):
2583         (WI.AuditTreeElement.prototype.canSelectOnMouseDown): Added.
2584         (WI.AuditTreeElement.prototype._updateTestGroupDisabled): Added.
2585         (WI.AuditTreeElement.prototype._handleTestDisabledChanged): Added.
2586         (WI.AuditTreeElement.prototype._handleManagerEditingChanged): Added.
2587         * UserInterface/Views/AuditTreeElement.css:
2588         (.tree-outline .item.audit > .status:not(:hover) > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.editing-audits) > .status:not(:hover)): Added.
2589         (.tree-outline .item.audit.manager-active > .status > img.show-on-hover, .tree-outline .item.audit.test-group.expanded:not(.editing-audits) > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status): Added.
2590         (.tree-outline .item.audit > .status:not(:hover) > img.show-on-hover, .tree-outline .item.audit.test-group.expanded > .status:not(:hover)): Deleted.
2591         (.tree-outline .item.audit.manager-active > .status > img.show-on-hover, .tree-outline .item.audit.test-group.expanded > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status): Deleted.
2592         Prevent selection and running when editing.
2593
2594         * UserInterface/Views/TreeOutline.css:
2595         (.tree-outline .children.expanded:not([hidden])): Added.
2596         (.tree-outline .children.expanded): Deleted.
2597
2598         * UserInterface/Base/ObjectStore.js:
2599         (WI.ObjectStore._open):
2600         Batch operations together to help avoid multiple simultaneous `indexedDB.open` calls. This
2601         should also help preserve the order of operations, as once the database is open, operations
2602         are executed in the order they were enqueued.
2603
2604         (WI.ObjectStore.prototype.async.addObject):
2605         Pass a unique `Symbol` to the `toJSON` call on the given object so that the object can save
2606         additional values that wouldn't normally be saved. This doesn't conflict with normal usage
2607         of `toJSON` (e.g. `JSON.stringify`) because that case also passes in a value:
2608          - `undefined`, if it was called directly on the object
2609          - the key for this object in the containing object
2610          - the index of this object in the containing array
2611         In any case, the value can never equal the unique `Symbol`, so it's guaranteed that the code
2612         will only run for `WI.ObjectStore` operations.
2613
2614         (WI.ObjectStore.prototype.async.clear): Added.
2615
2616         * Localizations/en.lproj/localizedStrings.js:
2617
2618 2019-01-09  Devin Rousso  <drousso@apple.com>
2619
2620         Web Inspector: Protocol Logging: log messages as objects if inspector^2 is open
2621         https://bugs.webkit.org/show_bug.cgi?id=193284
2622
2623         Reviewed by Joseph Pecoraro.
2624
2625         If inspector^2 is closed, stringify all messages.
2626         If inspector^2 is open, log each message JSON object without modifying it.
2627
2628         * UserInterface/Protocol/LoggingProtocolTracer.js:
2629         (WI.LoggingProtocolTracer.prototype._processEntry):
2630
2631 2019-01-09  Nikita Vasilyev  <nvasilyev@apple.com>
2632
2633         Web Inspector: Styles: clicking on property that soon to be discarded shouldn't start selection
2634         https://bugs.webkit.org/show_bug.cgi?id=193218
2635         <rdar://problem/47098303>
2636
2637         Reviewed by Devin Rousso.
2638
2639         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
2640         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleMouseDown):
2641         A style property may get removed on blur event, so propertyElement may get removed from the DOM right when mousedown event happens.
2642
2643         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleWindowClick):
2644         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleClick):
2645         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._stopSelection):
2646
2647 2019-01-08  Nikita Vasilyev  <nvasilyev@apple.com>
2648
2649         Web Inspector: Styles: Undo reverts all changes at once
2650         https://bugs.webkit.org/show_bug.cgi?id=177676
2651         <rdar://problem/34745031>
2652
2653         Reviewed by Devin Rousso.
2654
2655         Command-Z used to revert all changes at once because Web Inspector never
2656         set any history checkpoints in the style editor.
2657
2658         * UserInterface/Views/SpreadsheetStyleProperty.js:
2659         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidBlur):
2660         * UserInterface/Views/SpreadsheetTextField.js:
2661         (WI.SpreadsheetTextField.prototype._handleBlur):
2662
2663 2019-01-08  Nikita Vasilyev  <nvasilyev@apple.com>
2664
2665         Web Inspector: Use prefers-color-scheme instead of prefers-dark-interface
2666         https://bugs.webkit.org/show_bug.cgi?id=193265
2667
2668         Reviewed by Timothy Hatcher.
2669
2670         * UserInterface/Views/AuditTestContentView.css:
2671         (@media (prefers-color-scheme: dark)):
2672         * UserInterface/Views/AuditTestGroupContentView.css:
2673         (@media (prefers-color-scheme: dark)):
2674         * UserInterface/Views/BezierEditor.css:
2675         (@media (prefers-color-scheme: dark)):
2676         * UserInterface/Views/BoxModelDetailsSectionRow.css:
2677         (@media (prefers-color-scheme: dark)):
2678         * UserInterface/Views/BreakpointActionView.css:
2679         (@media (prefers-color-scheme: dark)):
2680         * UserInterface/Views/BreakpointPopoverController.css:
2681         (@media (prefers-color-scheme: dark)):
2682         * UserInterface/Views/ButtonNavigationItem.css:
2683         (@media (prefers-color-scheme: dark)):
2684         * UserInterface/Views/ButtonToolbarItem.css:
2685         (@media (prefers-color-scheme: dark)):
2686         * UserInterface/Views/CallFrameView.css:
2687         (@media (prefers-color-scheme: dark)):
2688         * UserInterface/Views/CanvasContentView.css:
2689         (@media (prefers-color-scheme: dark)):
2690         * UserInterface/Views/CanvasOverviewContentView.css:
2691         (@media (prefers-color-scheme: dark)):
2692         * UserInterface/Views/CanvasSidebarPanel.css:
2693         (@media (prefers-color-scheme: dark)):
2694         * UserInterface/Views/CanvasTabContentView.css:
2695         (@media (prefers-color-scheme: dark)):
2696         * UserInterface/Views/CodeMirrorOverrides.css:
2697         (@media (prefers-color-scheme: dark)):
2698         * UserInterface/Views/CompletionSuggestionsView.css:
2699         (@media (prefers-color-scheme: dark)):
2700         * UserInterface/Views/ComputedStyleDetailsPanel.css:
2701         (@media (prefers-color-scheme: dark)):
2702         * UserInterface/Views/ComputedStyleSection.css:
2703         (@media (prefers-color-scheme: dark)):
2704         * UserInterface/Views/ConsoleMessageView.css:
2705         (@media (prefers-color-scheme: dark)):
2706         * UserInterface/Views/ConsolePrompt.css:
2707         (@media (prefers-color-scheme: dark)):
2708         * UserInterface/Views/DOMNodeDetailsSidebarPanel.css:
2709         (@media (prefers-color-scheme: dark)):
2710         * UserInterface/Views/DOMTreeOutline.css:
2711         (@media (prefers-color-scheme: dark)):
2712         * UserInterface/Views/DataGrid.css:
2713         (@media (prefers-color-scheme: dark)):
2714         * UserInterface/Views/DebuggerDashboardView.css:
2715         (@media (prefers-color-scheme: dark)):
2716         * UserInterface/Views/DebuggerSidebarPanel.css:
2717         (@media (prefers-color-scheme: dark)):
2718         * UserInterface/Views/DefaultDashboardView.css:
2719         (@media (prefers-color-scheme: dark)):
2720         * UserInterface/Views/DetailsSection.css:
2721         (@media (prefers-color-scheme: dark)):
2722         * UserInterface/Views/DividerNavigationItem.css:
2723         (@media (prefers-color-scheme: dark)):
2724         * UserInterface/Views/Editing.css:
2725         (@media (prefers-color-scheme: dark)):
2726         * UserInterface/Views/FindBanner.css:
2727         (@media (prefers-color-scheme: dark)):
2728         * UserInterface/Views/FontResourceContentView.css:
2729         (@media (prefers-color-scheme: dark)):
2730         * UserInterface/Views/FormattedValue.css:
2731         (@media (prefers-color-scheme: dark)):
2732         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:
2733         (@media (prefers-color-scheme: dark)):
2734         * UserInterface/Views/HoverMenu.css:
2735         (@media (prefers-color-scheme: dark)):
2736         * UserInterface/Views/ImageResourceContentView.css:
2737         (@media (prefers-color-scheme: dark)):
2738         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.css:
2739         (@media (prefers-color-scheme: dark)):
2740         * UserInterface/Views/LogContentView.css:
2741         (@media (prefers-color-scheme: dark)):
2742
2743         * UserInterface/Views/Main.css:
2744         (:root):
2745
2746         (@media (prefers-color-scheme: dark)):
2747         * UserInterface/Views/NetworkDetailView.css:
2748         (@media (prefers-color-scheme: dark)):
2749         * UserInterface/Views/NetworkTableContentView.css:
2750         (@media (prefers-color-scheme: dark)):
2751         * UserInterface/Views/NewTabContentView.css:
2752         (@media (prefers-color-scheme: dark)):
2753         * UserInterface/Views/ObjectPreviewView.css:
2754         (@media (prefers-color-scheme: dark)):
2755         * UserInterface/Views/ObjectTreePropertyTreeElement.css:
2756         (@media (prefers-color-scheme: dark)):
2757         * UserInterface/Views/OpenResourceDialog.css:
2758         (@media (prefers-color-scheme: dark)):
2759         * UserInterface/Views/ProgressView.css:
2760         (@media (prefers-color-scheme: dark)):
2761         * UserInterface/Views/QuickConsole.css:
2762         (@media (prefers-color-scheme: dark)):
2763         * UserInterface/Views/RecordingActionTreeElement.css:
2764         (@media (prefers-color-scheme: dark)):
2765         * UserInterface/Views/RecordingContentView.css:
2766         (@media (prefers-color-scheme: dark)):
2767         * UserInterface/Views/RecordingStateDetailsSidebarPanel.css:
2768         (@media (prefers-color-scheme: dark)):
2769         * UserInterface/Views/ResourceSecurityContentView.css:
2770         (@media (prefers-color-scheme: dark)):
2771         * UserInterface/Views/ResourceSizesContentView.css:
2772         (@media (prefers-color-scheme: dark)):
2773         * UserInterface/Views/ResourceTimingBreakdownView.css:
2774         (@media (prefers-color-scheme: dark)):
2775         * UserInterface/Views/ScopeBar.css:
2776         (@media (prefers-color-scheme: dark)):
2777         * UserInterface/Views/ScopeChainDetailsSidebarPanel.css:
2778         (@media (prefers-color-scheme: dark)):
2779         * UserInterface/Views/SearchBar.css:
2780         (@media (prefers-color-scheme: dark)):
2781         * UserInterface/Views/SearchSidebarPanel.css:
2782         (@media (prefers-color-scheme: dark)):
2783         * UserInterface/Views/SettingsTabContentView.css:
2784         (@media (prefers-color-scheme: dark)):
2785         * UserInterface/Views/ShaderProgramContentView.css:
2786         (@media (prefers-color-scheme: dark)):
2787         * UserInterface/Views/ShaderProgramTreeElement.css:
2788         (@media (prefers-color-scheme: dark)):
2789         * UserInterface/Views/SourceCodeTextEditor.css:
2790         (@media (prefers-color-scheme: dark)):
2791         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2792         (@media (prefers-color-scheme: dark)):
2793         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
2794         (@media (prefers-color-scheme: dark)):
2795         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
2796         (@media (prefers-color-scheme: dark)):
2797         * UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
2798         (@media (prefers-color-scheme: dark)):
2799         * UserInterface/Views/TabBar.css:
2800         (@media (prefers-color-scheme: dark)):
2801         * UserInterface/Views/Table.css:
2802         (@media (prefers-color-scheme: dark)):
2803         * UserInterface/Views/TextEditor.css:
2804         (@media (prefers-color-scheme: dark)):
2805         * UserInterface/Views/TimelineDataGrid.css:
2806         (@media (prefers-color-scheme: dark)):
2807         * UserInterface/Views/TimelineIcons.css:
2808         (@media (prefers-color-scheme: dark)):
2809         * UserInterface/Views/TimelineOverview.css:
2810         (@media (prefers-color-scheme: dark)):
2811         * UserInterface/Views/Toolbar.css:
2812         (@media (prefers-color-scheme: dark)):
2813         * UserInterface/Views/TreeOutline.css:
2814         (@media (prefers-color-scheme: dark)):
2815         * UserInterface/Views/URLBreakpointPopover.css:
2816         (@media (prefers-color-scheme: dark)):
2817         * UserInterface/Views/Variables.css:
2818         (@media (prefers-color-scheme: dark)):
2819         * UserInterface/Views/WebSocketContentView.css:
2820         (@media (prefers-color-scheme: dark)):
2821
2822 2019-01-07  Devin Rousso  <drousso@apple.com>
2823
2824         Web Inspector: Audit: run arrow shouldn't be visible when running tests
2825         https://bugs.webkit.org/show_bug.cgi?id=192209
2826         <rdar://problem/46423615>
2827
2828         Reviewed by Brian Burg.
2829
2830         * UserInterface/Views/AuditTreeElement.js:
2831         (WI.AuditTreeElement.prototype.onattach):
2832         (WI.AuditTreeElement.prototype.ondetach):
2833         (WI.AuditTreeElement.prototype._updateLevel):
2834         (WI.AuditTreeElement.prototype._handleAuditManagerTestScheduled): Added.
2835         (WI.AuditTreeElement.prototype._handleAuditManagerTestCompleted): Added.
2836         * UserInterface/Views/AuditTreeElement.css: Added.
2837         (.tree-outline .item.audit:matches(.test-case, .test-group):not(.manager-active) > .status:hover > img): Added.
2838         (.tree-outline .item.audit.manager-active > .status > img.show-on-hover, .tree-outline .item.audit.test-group.expanded > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status): Added.
2839         (.tree-outline .item.audit:matches(.test-case, .test-group) > .status:hover > img): Deleted.
2840         (.tree-outline .item.audit.test-group.expanded > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status): Deleted.
2841
2842 2019-01-07  Devin Rousso  <drousso@apple.com>
2843
2844         Web Inspector: extend XHR breakpoints to work with fetch
2845         https://bugs.webkit.org/show_bug.cgi?id=185843
2846         <rdar://problem/40431027>
2847
2848         Reviewed by Matt Baker.
2849
2850         * UserInterface/Controllers/DOMDebuggerManager.js:
2851         (WI.DOMDebuggerManager):
2852         (WI.DOMDebuggerManager.supportsURLBreakpoints): Added.
2853         (WI.DOMDebuggerManager.prototype.get urlBreakpoints): Added.
2854         (WI.DOMDebuggerManager.prototype.urlBreakpointForURL): Added.
2855         (WI.DOMDebuggerManager.prototype.addURLBreakpoint): Added.
2856         (WI.DOMDebuggerManager.prototype.removeURLBreakpoint): Added.
2857         (WI.DOMDebuggerManager.prototype._speculativelyResolveBreakpoints):
2858         (WI.DOMDebuggerManager.prototype._updateURLBreakpoint): Added.
2859         (WI.DOMDebuggerManager.prototype._resolveURLBreakpoint): Added.
2860         (WI.DOMDebuggerManager.prototype._saveURLBreakpoints): Added.
2861         (WI.DOMDebuggerManager.prototype._urlBreakpointDisabledStateDidChange): Added.
2862         (WI.DOMDebuggerManager.prototype.get xhrBreakpoints): Deleted.
2863         (WI.DOMDebuggerManager.prototype.xhrBreakpointForURL): Deleted.
2864         (WI.DOMDebuggerManager.prototype.addXHRBreakpoint): Deleted.
2865         (WI.DOMDebuggerManager.prototype.removeXHRBreakpoint): Deleted.
2866         (WI.DOMDebuggerManager.prototype._updateXHRBreakpoint.breakpointUpdated): Deleted.
2867         (WI.DOMDebuggerManager.prototype._updateXHRBreakpoint): Deleted.
2868         (WI.DOMDebuggerManager.prototype._resolveXHRBreakpoint): Deleted.
2869         (WI.DOMDebuggerManager.prototype._saveXHRBreakpoints): Deleted.
2870         (WI.DOMDebuggerManager.prototype._xhrBreakpointDisabledStateDidChange): Deleted.
2871
2872         * UserInterface/Controllers/DebuggerManager.js:
2873         (WI.DebuggerManager.prototype._pauseReasonFromPayload):
2874
2875         * UserInterface/Views/DebuggerSidebarPanel.js:
2876         (WI.DebuggerSidebarPanel):
2877         (WI.DebuggerSidebarPanel.prototype.willDismissPopover):
2878         (WI.DebuggerSidebarPanel.prototype._addBreakpoint):
2879         (WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange):
2880         (WI.DebuggerSidebarPanel.prototype._addTreeElement):
2881         (WI.DebuggerSidebarPanel.prototype._updatePauseReasonSection):
2882         (WI.DebuggerSidebarPanel.prototype._handleCreateBreakpointClicked):
2883
2884         * UserInterface/Views/NavigationSidebarPanel.js:
2885         (WI.NavigationSidebarPanel.prototype._isTreeElementWithoutRepresentedObject):
2886
2887         * UserInterface/Models/URLBreakpoint.js: Renamed from Source/WebInspectorUI/UserInterface/Models/XHRBreakpoint.js.
2888         * UserInterface/Views/URLBreakpointPopover.css: Renamed from Source/WebInspectorUI/UserInterface/Views/XHRBreakpointPopover.css.
2889         * UserInterface/Views/URLBreakpointPopover.js: Renamed from Source/WebInspectorUI/UserInterface/Views/XHRBreakpointPopover.js.
2890         * UserInterface/Views/URLBreakpointTreeElement.css: Renamed from Source/WebInspectorUI/UserInterface/Views/XHRBreakpointTreeElement.css.
2891         * UserInterface/Views/URLBreakpointTreeElement.js: Renamed from Source/WebInspectorUI/UserInterface/Views/XHRBreakpointTreeElement.js.
2892
2893         * UserInterface/Base/Setting.js:
2894         (WI.Setting.migrateValue): Added.
2895
2896         * UserInterface/Main.html:
2897         * UserInterface/Test.html:
2898
2899         * Localizations/en.lproj/localizedStrings.js:
2900
2901 2019-01-07  Devin Rousso  <drousso@apple.com>
2902
2903         Web Inspector: Network: show secure connection details per-request
2904         https://bugs.webkit.org/show_bug.cgi?id=191539
2905         <rdar://problem/45979891>
2906
2907         Reviewed by Joseph Pecoraro.
2908
2909         * UserInterface/Models/Resource.js:
2910         (WI.Resource):
2911         (WI.Resource.prototype.get security): Added.
2912         (WI.Resource.prototype.updateForResponse):
2913         (WI.Resource.prototype.updateWithMetrics):
2914         (WI.Resource.prototype.get responseSecurity): Deleted.
2915
2916         * UserInterface/Views/ResourceSecurityContentView.js:
2917         (WI.ResourceSecurityContentView):
2918         (WI.ResourceSecurityContentView.prototype.initialLayout):
2919         (WI.ResourceSecurityContentView.prototype.layout):
2920         (WI.ResourceSecurityContentView.prototype._refreshConnectionSection): Added.
2921         (WI.ResourceSecurityContentView.prototype._refreshCetificateSection):
2922         (WI.ResourceSecurityContentView.prototype._handleResourceMetricsDidChange): Added.
2923         * UserInterface/Views/ResourceSecurityContentView.css:
2924         (body[dir] .resource-security > section:matches(.connection, .certificate) > .details): Added.
2925         (@media (prefers-dark-interface) body[dir] .resource-security > section:matches(.connection, .certificate) > .details): Added.
2926         (body[dir] .resource-security > section.certificate > .details): Deleted.
2927         (@media (prefers-dark-interface) body[dir] .resource-security > section.certificate > .details): Deleted.
2928
2929         * Localizations/en.lproj/localizedStrings.js:
2930
2931 2019-01-07  Nikita Vasilyev  <nvasilyev@apple.com>
2932
2933         Web Inspector: "white" isn't recognized as a color keyword
2934         https://bugs.webkit.org/show_bug.cgi?id=193173
2935         <rdar://problem/47068595>
2936
2937         Reviewed by Joseph Pecoraro.
2938
2939         Attempt to parse "atom" token types as colors.
2940
2941         Display color picker only for color-aware properties. For instance,
2942         display it for "color: white" but not for "-apple-pay-button-style: white".
2943
2944         * UserInterface/Models/CSSKeywordCompletions.js:
2945         (addKeywordsForName):
2946         (WI.CSSKeywordCompletions.forProperty):
2947         (WI.CSSKeywordCompletions.isColorAwareProperty):
2948         * UserInterface/Views/SpreadsheetStyleProperty.js:
2949         (WI.SpreadsheetStyleProperty.prototype._renderValue):
2950         (WI.SpreadsheetStyleProperty.prototype._addColorTokens):
2951
2952 2019-01-04  Joseph Pecoraro  <pecoraro@apple.com>
2953
2954         Web Inspector: subclasses of WI.ClusterContentView don't save/restore content views after the initial view
2955         https://bugs.webkit.org/show_bug.cgi?id=192451
2956         <rdar://problem/46800958>
2957
2958         Reviewed by Devin Rousso.
2959
2960         * UserInterface/Models/BackForwardEntry.js:
2961         (WI.BackForwardEntry.prototype.prepareToHide):
2962         * UserInterface/Views/ClusterContentView.js:
2963         (WI.ClusterContentView.prototype.get shouldSaveStateOnHide):
2964         * UserInterface/Views/ContentView.js:
2965         (WI.ContentView.prototype.get shouldSaveStateOnHide):
2966         Allow ClusterContentViews to save its state whenever its hidden,
2967         this means it can be properly restored to the last state it had
2968         instead of the initial state it was shown with.
2969
2970 2019-01-04  Devin Rousso  <drousso@apple.com>
2971
2972         Web Inspector: Audit: disable breakpoints when running Audit
2973         https://bugs.webkit.org/show_bug.cgi?id=193158
2974         <rdar://problem/47057083>
2975
2976         Reviewed by Joseph Pecoraro.
2977
2978         * UserInterface/Controllers/DebuggerManager.js:
2979         (WI.DebuggerManager):
2980         (WI.DebuggerManager.prototype._startDisablingBreakpointsTemporarily):
2981         (WI.DebuggerManager.prototype._stopDisablingBreakpointsTemporarily):
2982         (WI.DebuggerManager.prototype._handleAuditManagerTestScheduled): Added.
2983         (WI.DebuggerManager.prototype._handleAuditManagerTestCompleted): Added.
2984
2985         * UserInterface/Views/DebuggerSidebarPanel.js:
2986         (WI.DebuggerSidebarPanel.prototype._timelineCapturingWillStart):
2987         (WI.DebuggerSidebarPanel.prototype._timelineCapturingStopped):
2988         (WI.DebuggerSidebarPanel.prototype._handleAuditManagerTestScheduled): Added.
2989         (WI.DebuggerSidebarPanel.prototype._handleAuditManagerTestCompleted): Added.
2990         (WI.DebuggerSidebarPanel.prototype._updateBreakpointsDisabledBanner):
2991         * UserInterface/Views/DebuggerSidebarPanel.css:
2992         (.sidebar > .panel.navigation.debugger .warning-banner + .warning-banner): Added.
2993
2994         * UserInterface/Base/Main.js:
2995         (WI.loaded):
2996         * UserInterface/Test/Test.js:
2997         (WI.loaded):
2998         Move `WI.auditManager` higher in the managers list so that it can be used in
2999         `WI.DebuggerManager`'s constructor.
3000
3001         * Localizations/en.lproj/localizedStrings.js:
3002
3003 2019-01-04  Joseph Pecoraro  <pecoraro@apple.com>
3004
3005         Web Inspector: Add a Setting Toggle for Source Maps
3006         https://bugs.webkit.org/show_bug.cgi?id=193148
3007
3008         Reviewed by Devin Rousso.
3009
3010         * UserInterface/Controllers/NetworkManager.js:
3011         (WI.NetworkManager.prototype.downloadSourceMap):
3012         Don't download source maps if the setting is disabled.
3013
3014         * UserInterface/Base/Setting.js:
3015         * UserInterface/Views/SettingsTabContentView.js:
3016         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
3017         Settings toggle for source maps. Enabled by default.
3018
3019         * Localizations/en.lproj/localizedStrings.js:
3020
3021 2019-01-04  Joseph Pecoraro  <pecoraro@apple.com>
3022
3023         Web Inspector: Include `globalThis` in default JavaScript completions
3024         https://bugs.webkit.org/show_bug.cgi?id=193147
3025
3026         Reviewed by Devin Rousso.
3027
3028         * UserInterface/Controllers/CodeMirrorCompletionController.js:
3029         Add `globalThis` which is a new global value.
3030
3031 2019-01-03  Devin Rousso  <drousso@apple.com>
3032
3033         Web Inspector: conic-gradient color picker doesn't accurately show color when saturation value is not 100%
3034         https://bugs.webkit.org/show_bug.cgi?id=192729
3035         <rdar://problem/46746815>
3036
3037         Reviewed by Joseph Pecoraro.
3038
3039         Rework `WI.ColorWheel` to use similar canvas drawing logic as `WI.LegacyColorWheel` so that
3040         it's able to adjust the saturation value as the pixels gets closer to the center.
3041
3042         * UserInterface/Models/Color.js:
3043         (WI.Color.rgb2hsl): Added.
3044         (WI.Color.hsl2rgb): Added.
3045         (WI.Color.cmyk2rgb):
3046         (WI.Color.prototype.isKeyword):
3047         (WI.Color.prototype._toRGBString):
3048         (WI.Color.prototype._toRGBAString):
3049         (WI.Color.prototype._toHSLString):
3050         (WI.Color.prototype._toHSLAString):
3051         (WI.Color.prototype._rgbaToHSLA):
3052         (WI.Color.prototype._hslaToRGBA):
3053         (WI.Color.rgb2hsv): Deleted.
3054         (WI.Color.hsv2rgb): Deleted.
3055         (WI.Color.prototype._rgbToHSL): Deleted.
3056         (WI.Color.prototype._hslToRGB): Deleted.
3057         Adjust the conversion functions of `WI.Color` to be more accurate.
3058
3059         * UserInterface/Views/ColorWheel.js:
3060         (WI.ColorWheel):
3061         (WI.ColorWheel.prototype.set dimension):
3062         (WI.ColorWheel.prototype.set brightness):
3063         (WI.ColorWheel.prototype.get tintedColor):
3064         (WI.ColorWheel.prototype.set tintedColor):
3065         (WI.ColorWheel.prototype._updateColorForMouseEvent):
3066         (WI.ColorWheel.prototype._updateCanvas): Added.
3067         (WI.ColorWheel.prototype._updateGradient): Deleted.
3068         * UserInterface/Views/ColorWheel.css:
3069         (.color-wheel > canvas): Added.
3070         (.color-wheel > .gradient): Deleted.
3071
3072         * UserInterface/Views/ColorPicker.js:
3073         (WI.ColorPicker):
3074         (WI.ColorPicker.prototype.set color):
3075         (WI.ColorPicker.prototype.sliderValueDidChange):
3076         (WI.ColorPicker.prototype._updateSliders):
3077         (WI.ColorPicker.prototype._showColorComponentInputs):
3078         (WI.ColorPicker.supportsConicGradient): Deleted.
3079
3080         * UserInterface/Main.html:
3081
3082         * UserInterface/Views/LegacyColorWheel.js: Removed.
3083
3084 2019-01-02  Nikita Vasilyev  <nvasilyev@apple.com>
3085
3086         Web Inspector: Styles: selection lost when inspector is blurred
3087         https://bugs.webkit.org/show_bug.cgi?id=192124
3088         <rdar://problem/46800965>
3089
3090         Reviewed by Devin Rousso.
3091
3092         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
3093         (body:matches(.window-docked-inactive, .window-inactive) .spreadsheet-style-declaration-editor .property.selected):
3094         Selection should be gray when Web Inspector window isn't focused.
3095
3096         * UserInterface/Views/SpreadsheetStyleProperty.js:
3097
3098 2019-01-02  Nikita Vasilyev  <nvasilyev@apple.com>
3099
3100         Web Inspector: Styles: it shouldn't be possible to delete read-only properties
3101         https://bugs.webkit.org/show_bug.cgi?id=193099
3102         <rdar://problem/47016335>
3103
3104         Reviewed by Devin Rousso.
3105
3106         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
3107         (WI.SpreadsheetCSSStyleDeclarationEditor):
3108         Drive-by: Forward Delete should work the same way as Delete (Backspace).
3109
3110 2019-01-02  Devin Rousso  <webkit@devinrousso.com>
3111
3112         Web Inspector: Implement `queryObjects` Command Line API
3113         https://bugs.webkit.org/show_bug.cgi?id=176766
3114         <rdar://problem/34890689>
3115
3116         Reviewed by Joseph Pecoraro.
3117
3118         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
3119         (WI.JavaScriptRuntimeCompletionProvider.completionControllerCompletionsNeeded.receivedPropertyNames):
3120         Add `queryObjects` to the list of command line functions.
3121
3122 2018-12-21  Devin Rousso  <drousso@apple.com>
3123
3124         Web Inspector: Styles Redesign: remove unused CSS style icons
3125         https://bugs.webkit.org/show_bug.cgi?id=192999
3126         <rdar://problem/46912094>
3127
3128         Reviewed by Matt Baker.
3129
3130         * UserInterface/Main.html:
3131         * UserInterface/Views/StyleRuleIcons.css: Removed.
3132         * UserInterface/Images/StyleRule.svg: Removed.
3133         * UserInterface/Images/StyleRuleInheritedElement.svg: Removed.
3134         * UserInterface/Images/StyleRulePseudoElement.svg: Removed.
3135
3136         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
3137         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj.filters:
3138
3139 2018-12-21  Nikita Vasilyev  <nvasilyev@apple.com>
3140
3141         Web Inspector: Styles: editing focus lost when inspector is blurred
3142         https://bugs.webkit.org/show_bug.cgi?id=192123
3143         <rdar://problem/46800966>
3144
3145         Reviewed by Devin Rousso.
3146
3147         * UserInterface/Views/SpreadsheetSelectorField.js:
3148         (WI.SpreadsheetSelectorField.prototype._handleBlur):
3149         * UserInterface/Views/SpreadsheetTextField.js:
3150         (WI.SpreadsheetTextField.prototype._handleBlur):
3151
3152 2018-12-21  Devin Rousso  <drousso@apple.com>
3153
3154         Web Inspector: Settings: experimental setting editors are misaligned in other locales
3155         https://bugs.webkit.org/show_bug.cgi?id=192971
3156         <rdar://problem/46718451>
3157
3158         Reviewed by Joseph Pecoraro.
3159
3160         * UserInterface/Views/SettingsTabContentView.css:
3161         (.content-view.settings > .settings-view > .container):
3162         (.content-view.settings > .settings-view > .container > .title):
3163
3164 2018-12-21  Devin Rousso  <drousso@apple.com>
3165
3166         Web Inspector: update scroll position when revealing a virtualized WI.DataGridNode
3167         https://bugs.webkit.org/show_bug.cgi?id=192992
3168         <rdar://problem/46886427>
3169
3170         Reviewed by Joseph Pecoraro.
3171
3172         When `reveal`ing a `WI.DataGridNode`, if it is not currently in the DOM tree (e.g. it's been
3173         virtualized by it's owner `WI.DataGrid`), we need to scroll to it's position so that it gets
3174         added to the DOM tree before it can be revealed/selected.
3175
3176         * UserInterface/Views/DataGrid.js:
3177         (WI.DataGrid.prototype.layout):
3178         (WI.DataGrid.prototype.updateVisibleRows):
3179         (WI.DataGrid.prototype._updateVisibleRows): Deleted.
3180
3181         * UserInterface/Views/DataGridNode.js:
3182         (WI.DataGridNode.prototype.reveal):
3183
3184 2018-12-20  Nikita Vasilyev  <nvasilyev@apple.com>
3185
3186         Web Inspector: Dark Mode: Type profiler popovers have black text on dark background
3187         https://bugs.webkit.org/show_bug.cgi?id=192916
3188         <rdar://problem/46863518>
3189
3190         Reviewed by Devin Rousso.
3191
3192         * UserInterface/Views/SourceCodeTextEditor.css:
3193         (.popover .debugger-popover-content > .body):
3194         * UserInterface/Views/TypeTreeElement.css:
3195         (.item.type-tree-element.prototype):
3196         (.item.type-tree-element.prototype:hover,):
3197         * UserInterface/Views/TypeTreeView.css:
3198         (.type-tree):
3199         * UserInterface/Views/Variables.css:
3200         (:root):
3201
3202 2018-12-20  Nikita Vasilyev  <nvasilyev@apple.com>
3203
3204         Web Inspector: Styles: Pressing Esc when editing name/value should select entire property
3205         https://bugs.webkit.org/show_bug.cgi?id=192919
3206
3207         Reviewed by Devin Rousso.
3208
3209         - Esc still hides the completion popover.
3210         - Esc still discards changes.
3211         - When there's no completion popover, Esc selects outer scope.
3212           I.e., it goes from editing name/value to selecting the entire property.
3213         - Pressing Esc for newly added properties discards those properties.
3214
3215         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
3216         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyRemoved):
3217         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyDidPressEsc):
3218         * UserInterface/Views/SpreadsheetStyleProperty.js:
3219         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidPressEsc):
3220         * UserInterface/Views/SpreadsheetTextField.js:
3221         (WI.SpreadsheetTextField.prototype._discardChange):
3222         (WI.SpreadsheetTextField.prototype._handleKeyDown):
3223
3224 2018-12-20  Joseph Pecoraro  <pecoraro@apple.com>
3225
3226         Web Inspector: Charles Proxy errors opening har files exported from Safari (invalid startedDateTime)
3227         https://bugs.webkit.org/show_bug.cgi?id=192959
3228         <rdar://problem/46863411>
3229
3230         Reviewed by Brian Burg.
3231
3232         * UserInterface/Views/NetworkTableContentView.js:
3233         (WI.NetworkTableContentView.prototype.tableCellContextMenuClicked):
3234         (WI.NetworkTableContentView.prototype._updateExportButton):
3235         (WI.NetworkTableContentView.prototype._canExportHAR):
3236         Disallow HAR export if we don't have load data, such as the requestSentDate for
3237         the main resource or sub-resources.
3238
3239         (WI.NetworkTableContentView.prototype._HARResources):
3240         Only export resources that have load data.
3241
3242 2018-12-20  Joseph Pecoraro  <pecoraro@apple.com>
3243
3244         Web Inspector: Autoformat doesn't work on icloud.com (javascript-packed.js)
3245         https://bugs.webkit.org/show_bug.cgi?id=192946
3246         <rdar://problem/42546126>
3247
3248         Rubber-stamped by Devin Rousso.
3249
3250         * UserInterface/Base/Utilities.js:
3251         (whitespaceRatio):
3252         (isTextLikelyMinified):
3253         Check the first 2500 and the last 2500 characters whitespace ratio.
3254         If either is below 20% then treat as minified.
3255
3256 2018-12-20  Joseph Pecoraro  <pecoraro@apple.com>
3257
3258         ITMLKit Inspector: Elements tab does not show DOM Tree
3259         https://bugs.webkit.org/show_bug.cgi?id=192910
3260         <rdar://problem/46680585>
3261
3262         Reviewed by Brian Burg.
3263
3264         * UserInterface/Protocol/Connection.js:
3265         (InspectorBackend.Connection.prototype._dispatchEvent):
3266         Better logging for errors.
3267
3268         * UserInterface/Base/Main.js:
3269         * UserInterface/Controllers/AppController.js:
3270         (WI.AppController.prototype.activateExtraDomains):
3271         Let Targets get a chance to activate extra domains.
3272         Perform a little more work in these cases.
3273
3274         * UserInterface/Protocol/Target.js:
3275         (WI.Target):
3276         (WI.Target.prototype.activateExtraDomain):
3277         Expose agents for domains that are active.
3278         Expose agents for extra domains when they are activated.
3279
3280 2018-12-20  Joseph Pecoraro  <pecoraro@apple.com>
3281
3282         ITMLKit Inspector: Computed Style Box Model section throws exceptions
3283         https://bugs.webkit.org/show_bug.cgi?id=192911
3284         <rdar://problem/46861112>
3285
3286         Reviewed by Matt Baker.
3287
3288         * UserInterface/Views/BoxModelDetailsSectionRow.js:
3289         (WI.BoxModelDetailsSectionRow.prototype._updateMetrics.createBoxPartElement):
3290         (WI.BoxModelDetailsSectionRow.prototype._updateMetrics.createContentAreaElement):
3291         (WI.BoxModelDetailsSectionRow.prototype._updateMetrics):
3292         ITMLKit doesn't always provide a display/position/width/height etc properties.
3293         Protect against this, and just show an empty message in the box model section
3294         if those properties do not exist.
3295
3296 2018-12-20  Devin Rousso  <drousso@apple.com>
3297
3298         Web Inspector: UIString should take an optional key and description to aid localization
3299         https://bugs.webkit.org/show_bug.cgi?id=153962
3300         <rdar://problem/24542505>
3301
3302         Reviewed by Brian Burg.
3303
3304         * UserInterface/Base/LoadLocalizedStrings.js:
3305         (WI.UIString):
3306
3307         * UserInterface/Test/Test.js:
3308         (WI.UIString):
3309
3310         * UserInterface/Views/AuditTestGroupContentView.js:
3311         (WI.AuditTestGroupContentView.prototype.initialLayout):
3312
3313 2018-12-20  Devin Rousso  <drousso@apple.com>
3314
3315         Web Inspector: Audits: don't cache default audits
3316         https://bugs.webkit.org/show_bug.cgi?id=192918
3317         <rdar://problem/46626543>
3318
3319         Reviewed by Brian Burg.
3320
3321         Instead of adding the default audits to the "audits" `WI.ObjectStore`, which preserves them
3322         across WebInspector sessions, load them every time WebInspector is opened (unless there are
3323         existing audits) so that the localized strings are able to respond to locale changes.
3324
3325         * UserInterface/Controllers/AuditManager.js:
3326         (WI.AuditManager.prototype.removeTest):
3327         (WI.AuditManager.prototype.addDefaultTestsIfNeeded):
3328
3329 2018-12-20  Devin Rousso  <drousso@apple.com>
3330
3331         Web Inspector: Dark Mode: unreadable background color for tables containing object previews
3332         https://bugs.webkit.org/show_bug.cgi?id=192887
3333         <rdar://problem/46855270>
3334
3335         Reviewed by Brian Burg.
3336
3337         * UserInterface/Views/LogContentView.css:
3338         (.console-messages:focus .console-item .data-grid tr.selected td:not(:last-child)): Added.
3339         (@media (prefers-dark-interface) .console-item .data-grid tr.selected): Added.
3340         (@media (prefers-dark-interface) .console-messages:focus .console-item.selected .data-grid tr.selected): Added.
3341         (@media (prefers-dark-interface) .console-messages:focus .console-item .data-grid tr.selected td:not(:last-child)): Added.
3342
3343         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.css:
3344         (.content-view.indexed-database-object-store > .data-grid tr.selected):
3345         (.content-view.indexed-database-object-store > .data-grid:focus tr.selected): Added.
3346         (@media (prefers-dark-interface) .content-view.indexed-database-object-store > .data-grid tr.selected): Added.
3347         (@media (prefers-dark-interface) .content-view.indexed-database-object-store > .data-grid:focus tr.selected): Added.
3348         (@media (prefers-dark-interface) .content-view.indexed-database-object-store > .data-grid:focus tr.selected td:not(:last-child)): Added.
3349
3350 2018-12-19  Devin Rousso  <drousso@apple.com>
3351
3352         Web Inspector: Audit: fix descriptions for default tests
3353         https://bugs.webkit.org/show_bug.cgi?id=192764
3354         <rdar://problem/46729437>
3355
3356         Reviewed by Matt Baker.
3357
3358         * UserInterface/Controllers/AuditManager.js:
3359         (WI.AuditManager.prototype.addDefaultTestsIfNeeded):
3360
3361         * Localizations/en.lproj/localizedStrings.js:
3362
3363 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3364
3365         Web Inspector: "E" icon on debugger dashboard is too close to current function name
3366         https://bugs.webkit.org/show_bug.cgi?id=192915
3367
3368         Reviewed by Matt Baker.
3369
3370         * UserInterface/Views/DebuggerDashboardView.css:
3371         (.dashboard.debugger > .location):
3372         (body[dir=ltr] .dashboard.debugger > .location :matches(.function-icon, .event-listener-icon)):
3373         (body[dir=rtl] .dashboard.debugger > .location :matches(.function-icon, .event-listener-icon)):
3374         (.dashboard.debugger > .location .function-icon): Deleted.
3375         (body[dir=ltr] .dashboard.debugger > .location .function-icon): Deleted.
3376         (body[dir=rtl] .dashboard.debugger > .location .function-icon): Deleted.
3377
3378 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3379
3380         Web Inspector: Dark Mode: ThreadTreeElement status icon is hard to see when hovered
3381         https://bugs.webkit.org/show_bug.cgi?id=192097
3382         <rdar://problem/46318421>
3383
3384         Reviewed by Matt Baker.
3385
3386         * UserInterface/Views/ThreadTreeElement.css:
3387         (.tree-outline > .item.thread .status-button.resume):
3388         (.tree-outline > .item.thread .status-button.resume:active):
3389
3390 2018-12-19  Devin Rousso  <drousso@apple.com>
3391
3392         Web Inspector: Uncaught Exception: TypeError: null is not an object (evaluating 'effectiveDOMNode.enabledPseudoClasses')
3393         https://bugs.webkit.org/show_bug.cgi?id=192783
3394
3395         Reviewed by Joseph Pecoraro.
3396
3397         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:
3398         (WI.GeneralStyleDetailsSidebarPanel.prototype._forcedPseudoClassCheckboxChanged):
3399         (WI.GeneralStyleDetailsSidebarPanel.prototype._updatePseudoClassCheckboxes):
3400
3401 2018-12-19  Devin Rousso  <drousso@apple.com>
3402
3403         Web Inspector: REGRESSION (r237195): Timelines: selecting a rendering frame row moves the time selection
3404         https://bugs.webkit.org/show_bug.cgi?id=192773
3405         <rdar://problem/46782446>
3406
3407         Reviewed by Joseph Pecoraro.
3408
3409         * UserInterface/Views/TimelineOverview.js:
3410         (WI.TimelineOverview.prototype._recordSelected):
3411         The Frames timeline uses `frameIndex` instead of `startTime`/`endTime`, so when trying to
3412         ensure that the selected record is within the filtered range, use `frameIndex` instead.
3413         The associated `WI.TimelineRuler` will already be using an index-based approach for
3414         selection, so this will match.
3415
3416 2018-12-19  Devin Rousso  <drousso@apple.com>
3417
3418         Web Inspector: Canvas: the recording auto-capture input shouldn't start focused
3419         https://bugs.webkit.org/show_bug.cgi?id=192454
3420
3421         Reviewed by Joseph Pecoraro.
3422
3423         * UserInterface/Views/CanvasOverviewContentView.js:
3424         (WI.CanvasOverviewContentView.prototype._updateRecordingAutoCaptureCheckboxLabel):
3425         (WI.CanvasOverviewContentView.prototype._handleCanvasRecordingAutoCaptureFrameCountChanged):
3426
3427 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3428
3429         Web Inspector: Styles: shift-clicking a color-swatch to change formats starts editing the color
3430         https://bugs.webkit.org/show_bug.cgi?id=192784
3431         <rdar://problem/46801028>
3432
3433         Reviewed by Devin Rousso.
3434
3435         * UserInterface/Views/SpreadsheetStyleProperty.js:
3436         (WI.SpreadsheetStyleProperty.prototype._createInlineSwatch):
3437
3438 2018-12-19  Matt Baker  <mattbaker@apple.com>
3439
3440         Web Inspector: Elements tab: arrow key after undoing a DOM node delete selects the wrong element
3441         https://bugs.webkit.org/show_bug.cgi?id=192871
3442         <rdar://problem/46849060>
3443
3444         Reviewed by Devin Rousso.
3445
3446         Undoing a DOM node removal reinserts the node into the DOMTreeOutline.
3447         When the reinserted node precedes the selected node in the tree, the
3448         SelectionController should update `_lastSelectedIndex`.
3449
3450         * UserInterface/Controllers/SelectionController.js:
3451         (WI.SelectionController.prototype.didInsertItem):
3452
3453 2018-12-19  Devin Rousso  <drousso@apple.com>
3454
3455         Web Inspector: Audit: provide localization support for % pass display
3456         https://bugs.webkit.org/show_bug.cgi?id=192870
3457         <rdar://problem/46779245>
3458
3459         Reviewed by Brian Burg.
3460
3461         * UserInterface/Views/AuditTestGroupContentView.js:
3462         (WI.AuditTestGroupContentView.prototype.initialLayout):
3463         (WI.AuditTestGroupContentView.prototype.layout):
3464         * UserInterface/Views/AuditTestGroupContentView.css:
3465         (.content-view.audit-test-group > header > .percentage-pass):
3466         (.content-view.audit-test-group > header > .percentage-pass > span): Added.
3467         (@media (prefers-dark-interface) .content-view.audit-test-group > header > .percentage-pass): Added.
3468         (@media (prefers-dark-interface) .content-view.audit-test-group > header > .percentage-pass > span): Added.
3469         (.content-view.audit-test-group > header > .percentage-pass:not(:empty)::after): Deleted.
3470
3471         * Localizations/en.lproj/localizedStrings.js:
3472
3473 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3474
3475         Web Inspector: Computed: make UI more usable when the panel is narrow
3476         https://bugs.webkit.org/show_bug.cgi?id=192578
3477         <rdar://problem/46615753>
3478
3479         Reviewed by Devin Rousso.
3480
3481         * UserInterface/Views/ComputedStyleSection.css:
3482         (.computed-style-section .computed-property-item .property-traces):
3483         (.computed-style-section .computed-property-item.expanded .disclosure-button):
3484         (.computed-style-section .computed-property-item .property-trace-item):
3485         (.computed-style-section .computed-property-item .property-trace-item::before):
3486         (.computed-style-section .computed-property-item .property):
3487         (.computed-style-section .computed-property-item .property-trace-item .selector):
3488         Allow CSS property values and selectors to take more than one line.
3489
3490         (.computed-style-section .property-trace-item .property .name,):
3491         * UserInterface/Views/ComputedStyleSection.js:
3492         (WI.ComputedStyleSection.prototype._createTrace):
3493         * UserInterface/Views/SpreadsheetStyleProperty.js:
3494         (WI.SpreadsheetStyleProperty.prototype.update):
3495
3496 2018-12-18  Simon Fraser  <simon.fraser@apple.com>
3497
3498         Web Inspector: Timelines: correctly label Intersection Observer callbacks
3499         https://bugs.webkit.org/show_bug.cgi?id=192669
3500         <rdar://problem/46702490>
3501
3502         Reviewed by Joseph Pecoraro.
3503
3504         Add InspectorInstrumentation::willFireObserverCallback() and use it to wrap calls
3505         to Intersection Observer, Performance Observer and Mutation Observer callbacks so 
3506         that they get correctly labeled in the Inspector timeline.
3507
3508         * Localizations/en.lproj/localizedStrings.js:
3509         * UserInterface/Controllers/TimelineManager.js:
3510         (WI.TimelineManager.prototype._processRecord):
3511         * UserInterface/Models/ScriptTimelineRecord.js:
3512         (WI.ScriptTimelineRecord.EventType.displayName):
3513         * UserInterface/Views/TimelineTabContentView.js:
3514         (WI.TimelineTabContentView.iconClassNameForRecord):
3515
3516 2018-12-19  Devin Rousso  <drousso@apple.com>
3517
3518         Web Inspector: Audit: "Clear Filters" button gets clipped when window is vertically small
3519         https://bugs.webkit.org/show_bug.cgi?id=192868
3520         <rdar://problem/46780400>
3521
3522         Reviewed by Matt Baker.
3523
3524         * UserInterface/Views/Main.css:
3525         (.message-text-view):
3526
3527 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3528
3529         Web Inspector: Dark Mode: selected text is too light when Inspector window is inactive
3530         https://bugs.webkit.org/show_bug.cgi?id=190542
3531         <rdar://problem/45238712>
3532
3533         Reviewed by Devin Rousso.
3534
3535         * UserInterface/Views/CodeMirrorOverrides.css:
3536         (.CodeMirror .CodeMirror-selected):
3537
3538 2018-12-19  Nikita Vasilyev  <nvasilyev@apple.com>
3539
3540         Web Inspector: column sort controls in Layers tab sidebar don't render correctly in dark mode
3541         https://bugs.webkit.org/show_bug.cgi?id=192845
3542
3543         Reviewed by Devin Rousso.
3544
3545         * UserInterface/Views/DataGrid.css:
3546         (@media (prefers-dark-interface)):
3547         (.data-grid th.sortable:active):
3548         Drive-by: replace obnoxiously light background of the pressed header with a more subtle gray.
3549
3550         (.data-grid th.sort-ascending > div:first-child::after, .data-grid th.sort-descending > div:first-child::after):
3551         Invert colors of the arrow glyph.
3552
3553 2018-12-18  Devin Rousso  <drousso@apple.com>
3554
3555         Web Inspector: Layers: increase default column width for other localizations
3556         https://bugs.webkit.org/show_bug.cgi?id=192812
3557         <rdar://problem/46628625>
3558
3559         Reviewed by Brian Burg.
3560
3561         * UserInterface/Views/LayerDetailsSidebarPanel.js:
3562         (WI.LayerDetailsSidebarPanel.prototype._buildDataGrid):
3563         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
3564         (WI.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
3565
3566 2018-12-18  Joseph Pecoraro  <pecoraro@apple.com>
3567
3568         Web Inspector: m3u8 content not shown, it should be text
3569         https://bugs.webkit.org/show_bug.cgi?id=192731
3570         <rdar://problem/46747728>
3571
3572         Reviewed by Devin Rousso.
3573
3574         * UserInterface/Base/MIMETypeUtilities.js:
3575         (WI.shouldTreatMIMETypeAsText):
3576         Support m3u8/m3u files as text.
3577
3578 2018-12-17  Devin Rousso  <drousso@apple.com>
3579
3580         Web Inspector: Canvas: path view is misaligned
3581         https://bugs.webkit.org/show_bug.cgi?id=192761
3582
3583         Reviewed by Joseph Pecoraro.
3584
3585         * UserInterface/Views/RecordingContentView.css:
3586         (.content-view:not(.tab).recording :matches(img, canvas)):
3587         (.content-view:not(.tab).recording canvas.path):
3588
3589 2018-12-17  Devin Rousso  <drousso@apple.com>
3590
3591         Web Inspector: Audit: add plural result strings
3592         https://bugs.webkit.org/show_bug.cgi?id=192769
3593         <rdar://problem/46628680>
3594
3595         Reviewed by Brian Burg.
3596
3597         * UserInterface/Views/AuditTestContentView.js:
3598         (WI.AuditTestContentView.prototype.showNoResultDataPlaceholder):
3599
3600         * UserInterface/Views/AuditTestGroupContentView.js:
3601         (WI.AuditTestGroupContentView.prototype.layout):
3602
3603         * Localizations/en.lproj/localizedStrings.js:
3604
3605 2018-12-17  Devin Rousso  <drousso@apple.com>
3606
3607         Web Inspector: Settings: add singular "space" UIString
3608         https://bugs.webkit.org/show_bug.cgi?id=192766
3609         <rdar://problem/46776948>
3610
3611         Reviewed by Brian Burg.
3612
3613         * UserInterface/Views/SettingEditor.js:
3614         (WI.SettingEditor):
3615         (WI.SettingEditor.prototype.get label):
3616         (WI.SettingEditor.prototype.set label): Added.
3617
3618         * UserInterface/Views/SettingsTabContentView.js:
3619         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
3620         (WI.SettingsTabContentView.prototype._createGeneralSettingsView.addSpacesSetting): Added.
3621         (WI.SettingsTabContentView.prototype._createGeneralSettingsView.addSpacesSetting.updateLabel): Added.
3622
3623         * Localizations/en.lproj/localizedStrings.js:
3624
3625 2018-12-15  Nikita Vasilyev  <nvasilyev@apple.com>
3626
3627         Web Inspector: Styles: toggling selected properties may cause data corruption
3628         https://bugs.webkit.org/show_bug.cgi?id=192396
3629         <rdar://problem/46478383>
3630
3631         Reviewed by Devin Rousso.
3632
3633         Uncommenting a property after a commented out property used to insert an unnecessary semicolon,
3634         and not updating ranges of the following properties.
3635
3636         For example:
3637
3638             /* color: red; */
3639             /* font-size: 12px */
3640
3641         Uncommenting `font-size` would result in something like this:
3642
3643             /* color: red; */; font-size: 12px
3644                              ^
3645                              unnecessary semicolon
3646
3647         Now the semicolon doesn't get inserted and the white space is preserved better:
3648
3649             /* color: red; */
3650             font-size: 12px
3651
3652         * UserInterface/Models/CSSProperty.js:
3653         (WI.CSSProperty.prototype._updateOwnerStyleText):
3654         (WI.CSSProperty.prototype._appendSemicolonIfNeeded): Removed.
3655         (WI.CSSProperty.prototype._prependSemicolonIfNeeded): Added.
3656
3657         * UserInterface/Views/SpreadsheetStyleProperty.js:
3658         (WI.SpreadsheetStyleProperty.prototype.remove):
3659         (WI.SpreadsheetStyleProperty.prototype.update):
3660         (WI.SpreadsheetStyleProperty.prototype._handleNameChange):
3661         (WI.SpreadsheetStyleProperty.prototype._handleValueChange):
3662         Style declaration should be locked while editing. Add asserts to ensure this.
3663
3664 2018-12-14  Matt Baker  <mattbaker@apple.com>
3665
3666         Web Inspector: REGRESSION(r238599): Uncaught Exception: TypeError: null is not an object (evaluating 'treeElement.listItemElement.classList')
3667         https://bugs.webkit.org/show_bug.cgi?id=192090
3668         <rdar://problem/46318614>
3669
3670         Reviewed by Devin Rousso.
3671
3672         * UserInterface/Views/TreeOutline.js:
3673         (WI.TreeOutline.prototype.selectionControllerSelectionDidChange):
3674         Check that `listItemElement` is valid before accessing it to update class
3675         names. The selection can change before the TreeElement has been attached.
3676
3677 2018-12-14  Matt Baker  <mattbaker@apple.com>
3678
3679         Web Inspector: Cookies view should use model objects instead of raw payload data
3680         https://bugs.webkit.org/show_bug.cgi?id=189533
3681         <rdar://problem/44364183>
3682
3683         Reviewed by Joseph Pecoraro and Devin Rousso.
3684
3685         * UserInterface/Models/Cookie.js:
3686         (WI.Cookie):
3687         (WI.Cookie.fromPayload):
3688         (WI.Cookie.parseSetCookieResponseHeader):
3689         (WI.Cookie.prototype.get type):
3690         (WI.Cookie.prototype.get name):
3691         (WI.Cookie.prototype.get value):
3692         (WI.Cookie.prototype.get header):
3693         (WI.Cookie.prototype.get expires):
3694         (WI.Cookie.prototype.get maxAge):
3695         (WI.Cookie.prototype.get path):
3696         (WI.Cookie.prototype.get domain):
3697         (WI.Cookie.prototype.get secure):
3698         (WI.Cookie.prototype.get httpOnly):
3699         (WI.Cookie.prototype.get sameSite):
3700         (WI.Cookie.prototype.get size):
3701         (WI.Cookie.prototype.get url):
3702         (WI.Cookie.prototype.expirationDate):
3703         Cleanup Cookie object; add pubic getters for data, `url` property,
3704         static `fromPayload` method, and calculate `_size` if missing.
3705
3706         * UserInterface/Views/CookieStorageContentView.js:
3707         (WI.CookieStorageContentView.prototype.tableDidRemoveRows):
3708         (WI.CookieStorageContentView.prototype._reloadCookies):
3709         Create Cookie objects from the payload instead of using raw payload data.
3710
3711 2018-12-13  Devin Rousso  <drousso@apple.com>
3712
3713         Web Inspector: remove DOM.BackendNodeId and associated commands/events
3714         https://bugs.webkit.org/show_bug.cgi?id=192478
3715
3716         Reviewed by Matt Baker.
3717
3718         * Versions/Inspector-iOS-8.0.json:
3719         * Versions/Inspector-iOS-9.0.json:
3720         * Versions/Inspector-iOS-9.3.json:
3721         * Versions/Inspector-iOS-10.0.json:
3722         * Versions/Inspector-iOS-10.3.json:
3723         * Versions/Inspector-iOS-11.0.json:
3724         * Versions/Inspector-iOS-11.3.json:
3725         * Versions/Inspector-iOS-12.0.json:
3726         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
3727         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
3728         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
3729         * UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
3730         * UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js:
3731         * UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js:
3732         * UserInterface/Protocol/Legacy/11.3/InspectorBackendCommands.js:
3733         * UserInterface/Protocol/Legacy/12.0/InspectorBackendCommands.js:
3734
3735 2018-12-13  Devin Rousso  <drousso@apple.com>
3736
3737         Web Inspector: experimental settings reload button disappears after changing more than one setting
3738         https://bugs.webkit.org/show_bug.cgi?id=192645
3739         <rdar://problem/46626204>
3740
3741         Reviewed by Joseph Pecoraro.
3742
3743         * UserInterface/Views/SettingsTabContentView.js:
3744         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView.listenForChange):
3745         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3746
3747 2018-12-13  Matt Baker  <mattbaker@apple.com>
3748
3749         Web Inspector: REGRESSION(r238602): Elements: deleting multiple DOM nodes doesn't select the nearest node after deletion
3750         https://bugs.webkit.org/show_bug.cgi?id=192116
3751         <rdar://problem/46344339>
3752
3753         Reviewed by Devin Rousso.
3754
3755         * UserInterface/Controllers/SelectionController.js:
3756         (WI.SelectionController.prototype.removeSelectedItems):
3757         Finding a new index to select should go through the delegate instead of
3758         naively advancing the index.
3759
3760         * UserInterface/Views/DOMTreeElement.js:
3761         (WI.DOMTreeElement.prototype._populateNodeContextMenu):
3762         (WI.DOMTreeElement.prototype.ondelete): Deleted.
3763         The menu item for removing the DOM node is now managed by the parent
3764         DOMTreeOutline, since its UI and behavior now depend on whether there
3765         are multiple elements selected.
3766
3767         * UserInterface/Views/DOMTreeOutline.js:
3768         (WI.DOMTreeOutline.prototype.populateContextMenu):
3769         (WI.DOMTreeOutline.prototype.ondelete.level):
3770         (WI.DOMTreeOutline.prototype.ondelete):
3771         Implement `ondelete` to remove selected DOM nodes using the delete and
3772         backspace keys. Also used by the DOMTreeOutline's context menu handler.
3773
3774 2018-12-13  Matt Baker  <mattbaker@apple.com>
3775
3776         Web Inspector: Table selection becomes corrupted when deleting selected cookies
3777         https://bugs.webkit.org/show_bug.cgi?id=192388
3778         <rdar://problem/46472364>
3779
3780         Reviewed by Devin Rousso.
3781
3782         * UserInterface/Controllers/SelectionController.js:
3783         (WI.SelectionController):
3784         (WI.SelectionController.prototype.didRemoveItems):
3785         (WI.SelectionController.prototype._updateSelectedItems):
3786         (WI.SelectionController.prototype.didRemoveItem): Deleted.
3787         Replace `didRemoveItem` with a method taking an IndexSet. Calling the
3788         single-index version while iterating over multiple rows in ascending
3789         order is unsafe, a detail best left to the SelectionController.
3790
3791         * UserInterface/Views/Table.js:
3792         (WI.Table.prototype.removeRow):
3793         (WI.Table.prototype._removeRows):
3794         Notify SelectionController of removed rows.
3795
3796         * UserInterface/Views/TreeOutline.js:
3797         (WI.TreeOutline.prototype.insertChild):
3798         (WI.TreeOutline.prototype.removeChildAtIndex):
3799         Remove the child from the element's `children` after calling `_forgetTreeElement`,
3800         which needs to calculate the child's index to pass to the SelectionController.
3801
3802         (WI.TreeOutline.prototype.removeChildren):
3803         Remove child items during iteration so that `children` doesn't contain
3804         detached TreeElements while calling `_forgetTreeElement`.
3805
3806         (WI.TreeOutline.prototype._rememberTreeElement):
3807         (WI.TreeOutline.prototype._forgetTreeElement):
3808
3809 2018-12-10  Matt Baker  <mattbaker@apple.com>
3810
3811         Web Inspector: REGRESSION (r238599): unable to select specific timeline
3812         https://bugs.webkit.org/show_bug.cgi?id=192443
3813         <rdar://problem/46608087>
3814
3815         Reviewed by Joseph Pecoraro.
3816
3817         When determining the trailing horizontal edge for TreeElement mouse
3818         events, TreeOutline should not assume that its containing DOM element
3819         is only as wide as its <ol> element.
3820
3821         * UserInterface/Views/TreeOutline.js:
3822         (WI.TreeOutline.prototype.treeElementFromEvent):
3823
3824 2018-12-10  Matt Baker  <mattbaker@apple.com>
3825
3826         Web Inspector: Move TreeOutlineGroup coordination out of TreeElement
3827         https://bugs.webkit.org/show_bug.cgi?id=192487
3828         <rdar://problem/46543431>
3829
3830         Reviewed by Devin Rousso.
3831
3832         * UserInterface/Views/TreeElement.js:
3833         (WI.TreeElement.prototype.select):
3834         (WI.TreeElement.prototype.deselect):
3835
3836         * UserInterface/Views/TreeOutlineGroup.js:
3837         (WI.TreeOutlineGroup):
3838         (WI.TreeOutlineGroup.prototype.itemAdded):
3839         (WI.TreeOutlineGroup.prototype.itemRemoved):
3840         (WI.TreeOutlineGroup.prototype._removeConflictingTreeSelections):
3841         (WI.TreeOutlineGroup.prototype._treeOutlineSelectionDidChange):
3842         (WI.TreeOutlineGroup.groupForTreeOutline): Deleted.
3843         (WI.TreeOutlineGroup.prototype.didSelectTreeElement): Deleted.
3844         make the group responsible for listening to selection changes from the
3845         TreeOutlines it manages, and synchronizing the selection between them.
3846
3847 2018-12-10  Dean Jackson  <dino@apple.com>
3848
3849         Use text/javascript as recommended by the HTML specification
3850         https://bugs.webkit.org/show_bug.cgi?id=192525
3851         <rdar://problem/46569636>
3852
3853         Reviewed by Jon Lee.
3854
3855         The HTML specification says we should use text/javascript for
3856         JavaScript files:
3857         https://html.spec.whatwg.org/multipage/scripting.html#scriptingLanguages:javascript-mime-type
3858
3859         * UserInterface/Base/MIMETypeUtilities.js:
3860         (WI.mimeTypeForFileExtension):
3861         * UserInterface/Views/TextEditor.js:
3862         (WI.TextEditor.prototype._attemptToDetermineMIMEType):
3863
3864 2018-12-06  Matt Baker  <mattbaker@apple.com>
3865
3866         Web Inspector: REGRESSION(r238602): Elements: collapsing a DOM node with the left arrow doesn't work
3867         https://bugs.webkit.org/show_bug.cgi?id=192353
3868         <rdar://problem/46455019>
3869
3870         Reviewed by Devin Rousso.
3871
3872         * UserInterface/Views/TreeElement.js:
3873         (WI.TreeElement.prototype.deselect):
3874         Don't early return when the element is not the selected tree element.
3875         This condition no longer holds now that TreeOutline supports multiple selection.
3876
3877 2018-12-05  Matt Baker  <mattbaker@apple.com>
3878
3879         Web Inspector: SelectionController should not extend the selection when allowsMultipleSelection is false
3880         https://bugs.webkit.org/show_bug.cgi?id=192390
3881         <rdar://problem/46473624>
3882
3883         Reviewed by Devin Rousso.
3884
3885         * UserInterface/Controllers/SelectionController.js:
3886         (WI.SelectionController.prototype.selectItem):
3887
3888 2018-12-04  Nikita Vasilyev  <nvasilyev@apple.com>
3889
3890         Web Inspector: Add style editing debug mode
3891         https://bugs.webkit.org/show_bug.cgi?id=192282
3892         <rdar://problem/46399176>
3893
3894         Reviewed by Matt Baker.
3895
3896         Introduce a style editing debug mode to help to troubleshoot complex bugs in the style editor.
3897
3898           - Log CSS changes;
3899           - Display red border for locked style declarations.
3900
3901         * UserInterface/Base/Setting.js:
3902         * UserInterface/Models/CSSProperty.js:
3903         (WI.CSSProperty.prototype._updateOwnerStyleText):
3904         * UserInterface/Views/SettingsTabContentView.js:
3905         (WI.SettingsTabContentView.prototype._createDebugSettingsView):
3906         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
3907         (.spreadsheet-style-declaration-editor.debug-style-locked::after):
3908         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
3909         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
3910         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._updateStyleLock):
3911         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._updateDebugLockStatus):
3912
3913 2018-12-04  Matt Baker  <mattbaker@apple.com>
3914
3915         Web Inspector: REGRESSION(r238602): Elements: changing selection no longer highlights the selected node
3916         https://bugs.webkit.org/show_bug.cgi?id=192354
3917         <rdar://problem/46444438>
3918
3919         Reviewed by Joseph Pecoraro.
3920
3921         * UserInterface/Views/TreeOutline.js:
3922         (WI.TreeOutline.prototype._treeKeyDown):
3923         (WI.TreeOutline.prototype._handleMouseDown):
3924
3925 2018-12-04  Joseph Pecoraro  <pecoraro@apple.com>
3926
3927         Web Inspector: REGRESSION(r238330): Timeline auto-capture does not work after page transition
3928         https://bugs.webkit.org/show_bug.cgi?id=192248
3929         <rdar://problem/46390199>
3930
3931         Reviewed by Devin Rousso.
3932
3933         * UserInterface/Base/Main.js:
3934         (WI.transitionPageTarget):
3935         Let the TimelineManager perform work on page transitions.
3936
3937         * UserInterface/Controllers/TimelineManager.js:
3938         (WI.TimelineManager.prototype.initializeTarget):
3939         Initialize the autocapture state of the target.
3940
3941         (WI.TimelineManager.prototype.transitionPageTarget):
3942         When transitioning pages perform a legacy (frontend based) timeline capture.
3943
3944 2018-12-04  Matt Baker  <mattbaker@apple.com>
3945
3946         Web Inspector: Elements: $0 is sho