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