Web Inspector: testCellRoleForRequiredChidren accessibility audit checks for rows...
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2019-03-24  Simon Welsh  <simon@welsh-au.com>
2
3         Web Inspector: testCellRoleForRequiredChidren accessibility audit checks for rows in cells
4         https://bugs.webkit.org/show_bug.cgi?id=195988
5
6         Reviewed by Timothy Hatcher.
7
8         The audit now checks that rows contain cells, allowing any of the four
9         cell-based roles.
10
11         * UserInterface/Controllers/AuditManager.js:
12         (WI.AuditManager.prototype.addDefaultTestsIfNeeded):
13         (WI.AuditManager):
14         (WI.AuditManager.prototype.addDefaultTestsIfNeeded.const.testCellRoleForRequiredChidren): Deleted.
15
16 2019-03-24  Devin Rousso  <drousso@apple.com>
17
18         Web Inspector: Canvas: missing icons for WebGL2 contexts
19         https://bugs.webkit.org/show_bug.cgi?id=196136
20
21         Reviewed by Timothy Hatcher.
22
23         * UserInterface/Views/CanvasSidebarPanel.css:
24         (.sidebar > .panel.navigation.canvas > .navigation-bar > .item.record-start-stop.disabled > .glyph): Added.
25         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.canvas:matches(.canvas-2d, .bitmaprenderer) .icon): Added.
26         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.canvas:matches(.webgl, .webgl2, .webgpu, .webmetal) .icon): Added.
27         (@media (prefers-color-scheme: dark)):
28         (.sidebar > .panel.navigation.canvas > .navigation-bar > .item.record-start-stop.disabled): Deleted.
29         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.canvas.canvas-2d .icon): Deleted.
30         (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.casnvas.webgl .icon): Deleted.
31         Use the 2D icon for BitmapRenderer and the 3D icon for WebGL2, WebMetals, and WebGPU.
32         Drive-by: the start/stop button text was too dark when disabled in dark mode.
33
34         * UserInterface/Models/Canvas.js:
35         Drive-by: "gpu" => "webgpu", to match the protocol string.
36
37 2019-03-22  Devin Rousso  <drousso@apple.com>
38
39         Web Inspector: Sources: "Reveal in Resources Tab" still shown when Sources tab is enabled
40         https://bugs.webkit.org/show_bug.cgi?id=196134
41
42         Reviewed by Joseph Pecoraro.
43
44         * UserInterface/Views/RecordingActionTreeElement.js:
45         (WI.RecordingActionTreeElement.prototype.populateContextMenu):
46         Drive-by: find the first call frame that has a source code location, rather than naively
47         always using the top call frame.
48
49         * UserInterface/Views/SearchResultTreeElement.js:
50         (WI.SearchResultTreeElement.prototype.populateContextMenu):
51
52 2019-03-22  Keith Rollin  <krollin@apple.com>
53
54         Enable ThinLTO support in Production builds
55         https://bugs.webkit.org/show_bug.cgi?id=190758
56         <rdar://problem/45413233>
57
58         Reviewed by Daniel Bates.
59
60         Enable building with Thin LTO in Production when using Xcode 10.2 or
61         later. This change results in a 1.45% progression in PLT5. Full
62         Production build times increase about 2-3%. Incremental build times
63         are more severely affected, and so LTO is not enabled for local
64         engineering builds.
65
66         LTO is enabled only on macOS for now, until rdar://problem/49013399,
67         which affects ARM builds, is fixed.
68
69         To change the LTO setting when building locally:
70
71         - If building with `make`, specify WK_LTO_MODE={none,thin,full} on the
72           command line.
73         - If building with `build-webkit`, specify --lto-mode={none,thin,full}
74           on the command line.
75         - If building with `build-root`, specify --lto={none,thin,full} on the
76           command line.
77         - If building with Xcode, create a LocalOverrides.xcconfig file at the
78           top level of your repository directory (if needed) and define
79           WK_LTO_MODE to full, thin, or none.
80
81         * Configurations/Base.xcconfig:
82
83 2019-03-21  Joseph Pecoraro  <pecoraro@apple.com>
84
85         Web Inspector: Timelines - Cannot export on about:blank - suggested filename containing a colon silently fails
86         https://bugs.webkit.org/show_bug.cgi?id=196109
87
88         Reviewed by Timothy Hatcher.
89
90         * UserInterface/Base/FileUtilities.js:
91         (WI.FileUtilities.sanitizeFilename):
92         (WI.FileUtilities.inspectorURLForFilename):
93         New utility functions.
94
95         * UserInterface/Test.html:
96         Include FileUtilities.
97
98         * UserInterface/Base/Main.js:
99         * UserInterface/Controllers/AuditManager.js:
100         (WI.AuditManager.prototype.export):
101         * UserInterface/Debug/ProtocolTrace.js:
102         (WI.ProtocolTrace.prototype.get saveData):
103         (WI.ProtocolTrace):
104         * UserInterface/Views/ConsoleMessageView.js:
105         (WI.ConsoleMessageView.prototype._handleContextMenu):
106         (WI.ConsoleMessageView):
107         * UserInterface/Views/ContextMenuUtilities.js:
108         * UserInterface/Views/HeapSnapshotContentView.js:
109         (WI.HeapSnapshotContentView.prototype._exportSnapshot):
110         * UserInterface/Views/LogContentView.js:
111         (WI.LogContentView.prototype.get saveData):
112         (WI.LogContentView.prototype._handleContextMenuEvent):
113         * UserInterface/Views/NetworkTableContentView.js:
114         (WI.NetworkTableContentView.prototype._exportHAR):
115         * UserInterface/Views/RecordingContentView.js:
116         (WI.RecordingContentView.prototype._exportRecording):
117         (WI.RecordingContentView.prototype._exportReduction):
118         * UserInterface/Views/ScriptContentView.js:
119         (WI.ScriptContentView.prototype.get saveData):
120         * UserInterface/Views/ShaderProgramContentView.js:
121         (WI.ShaderProgramContentView.prototype.get saveData):
122         * UserInterface/Views/TextContentView.js:
123         (WI.TextContentView.prototype.get saveData):
124         * UserInterface/Views/TextResourceContentView.js:
125         (WI.TextResourceContentView.prototype.get saveData):
126         * UserInterface/Views/TimelineRecordingContentView.js:
127         (WI.TimelineRecordingContentView.prototype._exportTimelineRecording):
128         Update "web-inspector:///" URL building code to use the utility.
129
130 2019-03-21  Nikita Vasilyev  <nvasilyev@apple.com>
131
132         Web Inspector: Use CSS variables for text color in Computed panel
133         https://bugs.webkit.org/show_bug.cgi?id=196117
134
135         Reviewed by Timothy Hatcher.
136
137         * UserInterface/Views/ComputedStyleSection.css:
138         (.computed-style-section):
139         (.computed-style-section .computed-property-item .property-trace-item .selector):
140         (.computed-style-section .computed-property-item .go-to-link):
141
142 2019-03-21  Devin Rousso  <drousso@apple.com>
143
144         Web Inspector: Timelines: flatten the overview to show all records, one per line
145         https://bugs.webkit.org/show_bug.cgi?id=191901
146         <rdar://problem/46423618>
147
148         Reviewed by Timothy Hatcher.
149
150         * UserInterface/Views/OverviewTimelineView.js:
151         (WI.OverviewTimelineView):
152         (WI.OverviewTimelineView.prototype.closed):
153         (WI.OverviewTimelineView.prototype.get navigationItems): Added.
154         (WI.OverviewTimelineView.prototype.reset):
155         (WI.OverviewTimelineView.prototype.layout):
156         (WI.OverviewTimelineView.prototype.get _relevantTimelines): Added.
157         (WI.OverviewTimelineView.prototype.get _shouldGroupBySourceCode): Added.
158         (WI.OverviewTimelineView.prototype._loadExistingRecords): Added.
159         (WI.OverviewTimelineView.prototype._insertDataGridNode):
160         (WI.OverviewTimelineView.prototype._addResourceToDataGridIfNeeded):
161         (WI.OverviewTimelineView.prototype._addSourceCodeTimeline):
162         (WI.OverviewTimelineView.prototype._processPendingRepresentedObjects):
163         (WI.OverviewTimelineView.prototype._handleGroupBySourceCodeSettingChanged): Added.
164         (WI.OverviewTimelineView.prototype._handleGroupBySourceCodeNavigationItemCheckedDidChange): Added.
165         (WI.OverviewTimelineView.prototype._handleTimelineRecordAdded): Added.
166         (WI.OverviewTimelineView.prototype._sourceCodeTimelineAdded):
167         (WI.OverviewTimelineView.prototype._networkTimelineRecordAdded): Deleted.
168         Listen for new records on all timelines. Add each record as a new line. Since each timeline
169         has different data to display, only show the "name" and "graph" for all records.
170
171         * UserInterface/Views/TimelineRecordingContentView.js:
172         (WI.TimelineRecordingContentView):
173         (WI.TimelineRecordingContentView.prototype._currentContentViewDidChange):
174         (WI.TimelineRecordingContentView.prototype._updateImportedView): Deleted.
175         When viewing the overview of an imported recording, show the non-grouped overview.
176
177         * UserInterface/Models/TimelineRecording.js:
178         (WI.TimelineRecording.prototype.addRecord):
179         (WI.TimelineRecording.prototype._keyForRecord):
180         Drive-by: show Media timeline events under the owner frame's resource when grouped.
181
182         * UserInterface/Views/TimelineRecordBar.css:
183         (.timeline-record-bar.timeline-record-type-script.garbage-collected > .segment, .timeline-record-bar.timeline-record-type-heap-allocations > .segment): Added.
184         (.timeline-record-bar.timeline-record-type-script.garbage-collected > .segment): Deleted.
185
186         * UserInterface/Base/Setting.js:
187         Add setting for controlling the Timeline overview grouping.
188
189         * UserInterface/Main.html:
190         * UserInterface/Views/SourceCodeTimelineTreeElement.js: Removed.
191         * UserInterface/Views/TimelineRecordingImportedView.js: Removed.
192         * UserInterface/Views/TimelineRecordingImportedView.css: Removed.
193         Remove unused files.
194
195         * Localizations/en.lproj/localizedStrings.js:
196
197 2019-03-21  Devin Rousso  <drousso@apple.com>
198
199         Web Inspector: Sources: the name of the file should not be used as a folder
200         https://bugs.webkit.org/show_bug.cgi?id=196064
201         <rdar://problem/49097710>
202
203         Reviewed by Timothy Hatcher.
204
205         * UserInterface/Views/GeneralTreeElement.js:
206         (WI.GeneralTreeElement.prototype.createFoldersAsNeededForSubpath):
207
208         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
209         (WI.SourcesNavigationSidebarPanel.prototype._addResource):
210         Drive-by: sort resources in each folder by name when grouping by path.
211
212 2019-03-20  Devin Rousso  <drousso@apple.com>
213
214         Web Inspector: Canvas: rework how Canvas.enable/Canvas.disable is used so that events are not sent when the Canvas tab isn't enabled
215         https://bugs.webkit.org/show_bug.cgi?id=195828
216         <rdar://problem/48941756>
217
218         Reviewed by Timothy Hatcher.
219
220         * UserInterface/Controllers/CanvasManager.js:
221         (WI.CanvasManager):
222         (WI.CanvasManager.prototype.initializeTarget):
223         (WI.CanvasManager.prototype.enable): Added.
224         (WI.CanvasManager.prototype.disable): Added.
225
226         * UserInterface/Views/CanvasTabContentView.js:
227         (WI.CanvasTabContentView):
228         (WI.CanvasTabContentView.prototype.closed): Added.
229
230         * UserInterface/Base/Test.js:
231         (WI.contentLoaded):
232
233 2019-03-20  Devin Rousso  <drousso@apple.com>
234
235         Web Inspector: Sources: collapsing a section doesn't shrink the space used by that section
236         https://bugs.webkit.org/show_bug.cgi?id=196045
237
238         Reviewed by Timothy Hatcher.
239
240         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
241         (WI.SourcesNavigationSidebarPanel):
242         (WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerPaused):
243         (WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerResumed):
244         * UserInterface/Views/SourcesNavigationSidebarPanel.css:
245         (.sidebar > .panel.navigation.sources > .content > .details-section):
246         (.sidebar > .panel.navigation.sources > .content > .details-section:matches(.paused-reason, .breakpoins).collapsed > .header > .options,):
247         (.sidebar > .panel.navigation.sources > .content > .details-section.collapsed > .content):
248         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints > .header > .options .create-breakpoint):
249         (.sidebar > .panel.navigation.sources > .content > .details-section:matches(.pause-reason, .call-stack, .breakpoints) > .content,):
250         (.sidebar > .panel.navigation.sources > .content > .details-section:matches(.call-stack, .breakpoints) > .content):
251         (.sidebar > .panel.navigation.sources > .content > .details-section:matches(.call-stack, .breakpoints):not(.collapsed) > .content):
252         (.sidebar > .panel.navigation.sources > .content > .details-section.call-stack):
253         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints):
254         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints .create-breakpoint):
255         (.sidebar > .panel.navigation.sources > .content > .pause-reason):
256         (.sidebar > .panel.navigation.sources > .content > .details-section:matches(.call-stack, .breakpoints):not(.collapsed) > .content,):
257         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints .tree-outline .item.event-target-window .icon):
258         (.sidebar > .panel.navigation.sources > .content .details-section): Deleted.
259         (.sidebar > .panel.navigation.sources > .content .details-section:matches(.paused-reason, .breakpoins).collapsed > .header > .options,): Deleted.
260         (.sidebar > .panel.navigation.sources > .content .details-section.collapsed > .content): Deleted.
261         (.sidebar > .panel.navigation.sources > .content .details-section.breakpoints > .header > .options .create-breakpoint): Deleted.
262         (.sidebar > .panel.navigation.sources > .content > :matches(.pause-reason-container, .call-stack-container, .breakpoints-container)): Deleted.
263         (.sidebar > .panel.navigation.sources > .content > .call-stack-container): Deleted.
264         (.sidebar > .panel.navigation.sources > .content > .breakpoints-container): Deleted.
265         (.sidebar > .panel.navigation.sources > .content > .breakpoints-container .create-breakpoint): Deleted.
266         (.sidebar > .panel.navigation.sources > .content > .resources-container): Deleted.
267         (.sidebar > .panel.navigation.sources > .content > .pause-reason-container): Deleted.
268         (.sidebar > .panel.navigation.sources > .content > :matches(.call-stack-container, .breakpoints-container, .resources-container)): Deleted.
269         (.sidebar > .panel.navigation.sources > .content > .breakpoints .tree-outline .item.event-target-window .icon): Deleted.
270          - Apply the overflow scrolling to the content element of each `WI.DetailsSection`.
271          - Ensure that there is a maximum height for each section.
272          - When `.collapsed`, don't try to grow/shrink the section based on its contents.
273
274         * UserInterface/Views/CallFrameTreeElement.css:
275         (.tree-outline .item.call-frame):
276         (.tree-outline .item.call-frame .status):
277         Make the container of the active call frame status indicator relatively positioned so that
278         the active call frame status indicator will follow the container when scrolling.
279
280 2019-03-20  Devin Rousso  <drousso@apple.com>
281
282         Web Inspector: Timeline should show when events preventDefault() was called on an event or not
283         https://bugs.webkit.org/show_bug.cgi?id=176824
284         <rdar://problem/34290931>
285
286         Reviewed by Timothy Hatcher.
287
288         Original patch by Joseph Pecoraro <pecoraro@apple.com>.
289
290         * Localizations/en.lproj/localizedStrings.js:
291         New string.
292
293         * UserInterface/Controllers/TimelineManager.js:
294         (WI.TimelineManager.prototype._processRecord):
295         Include the whole data object as extra details.
296
297         * UserInterface/Models/ScriptTimelineRecord.js:
298         (WI.ScriptTimelineRecord):
299         (WI.ScriptTimelineRecord.prototype.get eventType):
300         Wholesale copy of the extra data instead of just a single property.
301
302         * UserInterface/Views/ScriptDetailsTimelineView.js:
303         (WI.ScriptDetailsTimelineView):
304         Give the name column more initial space, there is still extra space
305         after this adjustment but name is comfortably larger (and the most
306         likely to be expanded).
307
308         * UserInterface/Views/ScriptTimelineDataGridNode.js:
309         (WI.ScriptTimelineDataGridNode.prototype.get subtitle):
310         Include "default prevented" as the event's subtitle if it was prevented.
311
312 2019-03-20  Devin Rousso  <drousso@apple.com>
313
314         Web Inspector: Styles Redesign: Editing selector should not hide the rule
315         https://bugs.webkit.org/show_bug.cgi?id=178489
316         <rdar://problem/35062434>
317
318         Reviewed by Timothy Hatcher.
319
320         Extracts the selector payload parsing logic inside `WI.DOMNodeStyles` into static functions
321         so that when the user changes the selector of a `WI.CSSRule`, it's able to process and
322         update itself with the new selector. This is mainly useful in the case where the `WI.CSSRule`
323         no longer applies to the selected node (meaning it won't be part of that node's
324         `WI.DOMNodeStyles`) in that it allows the `WI.SpreadsheetCSSStyleDeclarationSection` to
325         display the new selector text and the owner `WI.SpreadsheetRulesStyleDetailsPanel` to keep
326         that section visible even though it isn't applicable to the current node anymore.
327
328         * UserInterface/Models/DOMNodeStyles.js:
329         (WI.DOMNodeStyles):
330         (WI.DOMNodeStyles.parseSelectorListPayload): Added.
331         (WI.DOMNodeStyles.createSourceCodeLocation): Added.
332         (WI.DOMNodeStyles.prototype.refresh):
333         (WI.DOMNodeStyles.prototype.refresh.fetchedMatchedStyles):
334         (WI.DOMNodeStyles.prototype.refresh.fetchedInlineStyles):
335         (WI.DOMNodeStyles.prototype.refresh.fetchedComputedStyle):
336         (WI.DOMNodeStyles.prototype._parseStyleDeclarationPayload):
337         (WI.DOMNodeStyles.prototype._parseRulePayload):
338         (WI.DOMNodeStyles.prototype._styleSheetContentDidChange):
339         (WI.DOMNodeStyles.prototype.refresh.parseRuleMatchArrayPayload): Deleted.
340         (WI.DOMNodeStyles.prototype._createSourceCodeLocation): Deleted.
341         (WI.DOMNodeStyles.prototype._parseSelectorListPayload): Deleted.
342         Keep track of all `WI.CSSRule` and `WI.CSSStyleDeclaration` that have ever been associated
343         with this object, so that if a rule's selector is changed to no longer match, and then is
344         changed back to match again, we are able to update that rule instead of creating a new one.
345
346         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
347         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.layout):
348         (WI.SpreadsheetRulesStyleDetailsPanel.prototype._handleSectionFilterApplied):
349         (WI.SpreadsheetRulesStyleDetailsPanel.prototype._handleSectionSelectorWillChange): Added.
350         Attempt to preserve the position of any sections that are changed and no longer apply to the
351         current node.
352
353         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
354         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetSelectorFieldDidChange):
355         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._renderSelector):
356         Drive-by: remove unused CSS classes.
357
358         * UserInterface/Models/CSSRule.js:
359         (WI.CSSRule.prototype.update):
360         (WI.CSSRule.prototype._selectorResolved):
361         Drive-by: remove unused event.
362
363         * UserInterface/Base/Multimap.js:
364         (Multimap.prototype.has): Added.
365         (Multimap.prototype.sets): Added.
366         (Multimap.prototype.copy): Added.
367
368 2019-03-20  Devin Rousso  <drousso@apple.com>
369
370         Web Inspector: no way to filter out all console messages or all evaluations/results
371         https://bugs.webkit.org/show_bug.cgi?id=167035
372         <rdar://problem/30023523>
373
374         Reviewed by Timothy Hatcher.
375
376         * UserInterface/Views/LogContentView.js:
377         (WI.LogContentView):
378         (WI.LogContentView.prototype.didAppendConsoleMessageView):
379         (WI.LogContentView.prototype._markScopeBarItemUnread):
380         (WI.LogContentView.prototype._markScopeBarItemForMessageLevelUnread): Added.
381         (WI.LogContentView.prototype._previousMessageRepeatCountUpdated):
382         (WI.LogContentView.prototype._messageSourceBarSelectionDidChange):
383         (WI.LogContentView.prototype._scopeBarSelectionDidChange):
384         (WI.LogContentView.prototype._filterMessageElements):
385         (WI.LogContentView.prototype.performSearch):
386         * UserInterface/Views/LogContentView.css:
387         (.log-scope-bar > li.unread.evaluations::before): Added.
388
389         * UserInterface/Views/ConsoleCommandView.js:
390         (WI.ConsoleCommandView):
391         Drive-by: remove unnecessary super-class extends.
392
393         * Localizations/en.lproj/localizedStrings.js:
394
395 2019-03-20  Nikita Vasilyev  <nvasilyev@apple.com>
396
397         Web Inspector: Styles: enabledProperties don't get invalidated after removing property
398         https://bugs.webkit.org/show_bug.cgi?id=196038
399
400         Reviewed by Timothy Hatcher.
401
402         * UserInterface/Models/CSSStyleDeclaration.js:
403         (WI.CSSStyleDeclaration.prototype.shiftPropertiesAfter):
404
405 2019-03-20  Devin Rousso  <drousso@apple.com>
406
407         Web Inspector: DOM: include window as part of any event listener chain
408         https://bugs.webkit.org/show_bug.cgi?id=195730
409         <rdar://problem/48916872>
410
411         Reviewed by Timothy Hatcher.
412
413         Allow non-nodes (e.g. `window`) to be listed as the target of an event listener.
414         Add support for the same concept when showing breakpoint details after pausing on a specific
415         event listener in the Debugger/Sources navigation sidebar.
416
417         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
418         (WI.DOMNodeDetailsSidebarPanel.prototype.initialLayout):
419         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByEvent):
420         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByTarget): Added.
421         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.eventListenersCallback):
422         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners):
423         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByNode): Deleted.
424
425         * UserInterface/Views/EventListenerSectionGroup.js:
426         (WI.EventListenerSectionGroup.prototype._targetTextOrLink): Added.
427         (WI.EventListenerSectionGroup.prototype._nodeTextOrLink): Deleted.
428
429         * UserInterface/Views/DebuggerSidebarPanel.js:
430         (WI.DebuggerSidebarPanel.prototype._addBreakpoint):
431         (WI.DebuggerSidebarPanel.prototype._breakpointTreeOutlineDeleteTreeElement):
432         (WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange):
433         (WI.DebuggerSidebarPanel.prototype._updatePauseReasonSection):
434         * UserInterface/Views/DebuggerSidebarPanel.css:
435         (.sidebar > .panel.navigation.debugger > .content > .breakpoints .tree-outline .item.event-target-window .icon): Added.
436
437         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
438         (WI.SourcesNavigationSidebarPanel):
439         (WI.SourcesNavigationSidebarPanel.prototype._addBreakpoint):
440         (WI.SourcesNavigationSidebarPanel.prototype._updatePauseReasonSection):
441         (WI.SourcesNavigationSidebarPanel.prototype._handleTreeSelectionDidChange):
442         * UserInterface/Views/SourcesNavigationSidebarPanel.css:
443         (.sidebar > .panel.navigation.sources > .content > .breakpoints .tree-outline .item.event-target-window .icon): Added.
444
445         * Localizations/en.lproj/localizedStrings.js:
446
447 2019-03-20  Devin Rousso  <drousso@apple.com>
448
449         Web Inspector: Debugger: virtualize the list of variables in the Scope sidebar
450         https://bugs.webkit.org/show_bug.cgi?id=192648
451         <rdar://problem/46800949>
452
453         Reviewed by Joseph Pecoraro.
454
455         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
456         (WI.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
457
458         * UserInterface/Views/TreeElement.js:
459         (WI.TreeElement.prototype.set hidden):
460         (WI.TreeElement.prototype._attach):
461         (WI.TreeElement.prototype._detach):
462         (WI.TreeElement.prototype.collapse):
463         (WI.TreeElement.prototype.expand):
464         Move `updateVirtualizedElements` calls to the owner `WI.TreeOutline` to ensure that they get
465         called. Make the remaining calls use rAF debouncing to better coalesce updates.
466
467         * UserInterface/Views/TreeOutline.js:
468         (WI.TreeOutline.prototype._rememberTreeElement):
469         (WI.TreeOutline.prototype._forgetTreeElement):
470         (WI.TreeOutline.prototype.registerScrollVirtualizer):
471         (WI.TreeOutline.prototype._updateVirtualizedElements.calculateOffsetFromContainer): Added.
472         (WI.TreeOutline.prototype._updateVirtualizedElements):
473         (WI.TreeOutline.prototype._calculateVirtualizedValues): Deleted.
474         Calculate the `WI.TreeOutline`'s top offset within the scroll container so that it will only
475         update when it's within the visual area.
476
477         * UserInterface/Views/Utilities.js:
478         (Array.prototype.remove):
479         Return whether the item was actually removed from the array.
480
481 2019-03-20  Joseph Pecoraro  <pecoraro@apple.com>
482
483         Web Inspector: Timelines - Export fails for MediaTimelineRecords with originator DOM Node - Cannot serialize cyclic structure
484         https://bugs.webkit.org/show_bug.cgi?id=196027
485
486         Reviewed by Timothy Hatcher.
487
488         * UserInterface/Models/MediaTimelineRecord.js:
489         (WI.MediaTimelineRecord.prototype.toJSON):
490         Remove the originator since that is a WI.DOMNode and cannot
491         be JSON serialized.
492
493 2019-03-20  Devin Rousso  <drousso@apple.com>
494
495         Web Inspector: Debugger: move breakpoint storage to use `WI.ObjectStore`
496         https://bugs.webkit.org/show_bug.cgi?id=192719
497         <rdar://problem/46746857>
498
499         Reviewed by Timothy Hatcher.
500
501         * UserInterface/Controllers/DebuggerManager.js:
502         (WI.DebuggerManager):
503         (WI.DebuggerManager.prototype.addBreakpoint):
504         (WI.DebuggerManager.prototype.removeBreakpoint):
505         (WI.DebuggerManager.prototype._debuggerBreakpointOptions):
506         (WI.DebuggerManager.prototype._setBreakpoint.didSetBreakpoint):
507         (WI.DebuggerManager.prototype._setBreakpoint):
508         (WI.DebuggerManager.prototype._breakpointDisabledStateDidChange):
509         (WI.DebuggerManager.prototype._breakpointEditablePropertyDidChange):
510         (WI.DebuggerManager.prototype._saveBreakpoints): Deleted.
511
512         * UserInterface/Models/Breakpoint.js:
513         (WI.Breakpoint.prototype.saveIdentityToCookie):
514         (WI.Breakpoint.prototype.serializeOptions): Added.
515         (WI.Breakpoint.prototype.toJSON): Added.
516         (WI.Breakpoint.prototype.get options): Deleted.
517         (WI.Breakpoint.prototype.get info): Deleted.
518         (WI.Breakpoint.prototype._serializableActions): Deleted.
519         * UserInterface/Models/BreakpointAction.js:
520         (WI.BreakpointAction.prototype.toJSON): Added.
521         (WI.BreakpointAction.prototype.get info): Deleted.
522
523         * UserInterface/Base/ObjectStore.js:
524         (WI.ObjectStore.async reset): Added.
525         (WI.ObjectStore._open):
526         (WI.ObjectStore.prototype.get keyPath): Added.
527         (WI.ObjectStore.prototype.async.getAll):
528         (WI.ObjectStore.prototype.async.put): Added.
529         (WI.ObjectStore.prototype.async.putObject): Added.
530         (WI.ObjectStore.prototype.async.add): Deleted.
531         (WI.ObjectStore.prototype.async.addObject): Deleted.
532         Replace `add` with `put` so that if a key already exists, it is overridden.
533
534         * UserInterface/Controllers/AuditManager.js:
535         (WI.AuditManager.prototype.set editing):
536         (WI.AuditManager.prototype.async processJSON):
537
538         * UserInterface/Controllers/BreakpointPopoverController.js:
539         (WI.BreakpointPopoverController.prototype._popoverActionsAddActionButtonClicked):
540         Inline some `WI.Breakpoint` static values.
541
542 2019-03-20  Devin Rousso  <drousso@apple.com>
543
544         Web Inspector: Sources: disabled breakpoints banner should be sticky
545         https://bugs.webkit.org/show_bug.cgi?id=195104
546         <rdar://problem/48442259>
547
548         Reviewed by Timothy Hatcher.
549
550         Allow each of the individual sections to be scrolled separately from the entire sidebar.
551
552         Leverage CSS variables set via JavaScript to be able to calculate the maximum height of each
553         `WI.TreeOutline` section based on the number of items.
554
555         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
556         (WI.SourcesNavigationSidebarPanel):
557         (WI.SourcesNavigationSidebarPanel.prototype._handleCallStackElementAddedOrRemoved): Added.
558         (WI.SourcesNavigationSidebarPanel.prototype._handleBreakpointElementAddedOrRemoved):
559         (WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerPaused):
560         (WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerResumed):
561         * UserInterface/Views/SourcesNavigationSidebarPanel.css:
562         (.sidebar > .panel.navigation.sources > .content):
563         (.sidebar > .panel.navigation.sources > .content .details-section): Added.
564         (.sidebar > .panel.navigation.sources > .content .details-section.paused-reason.collapsed > .header > .options,): Added.
565         (.sidebar > .panel.navigation.sources > .content .details-section.collapsed > .content): Added.
566         (.sidebar > .panel.navigation.sources > .content > :matches(.pause-reason-container, .call-stack-container, .breakpoints-container)): Added.
567         (.sidebar > .panel.navigation.sources > .content > .call-stack-container): Added.
568         (.sidebar > .panel.navigation.sources > .content > .breakpoints-container): Added.
569         (.sidebar > .panel.navigation.sources > .content > .breakpoints-container .create-breakpoint): Added.
570         (.sidebar > .panel.navigation.sources > .content > .resources-container): Added.
571         (.sidebar > .panel.navigation.sources > .content .tree-outline.single-thread): Added.
572         (.sidebar > .panel.navigation.sources > .content .tree-outline.single-thread > .item.thread): Added.
573         (@media (min-height: 600px) .sidebar > .panel.navigation.sources > .content): Added.
574         (@media (min-height: 600px) .sidebar > .panel.navigation.sources > .content > .pause-reason-container): Added.
575         (@media (min-height: 600px) .sidebar > .panel.navigation.sources > .content > :matches(.call-stack-container, .breakpoints-container, .resources-container)): Added.
576         (.sidebar > .panel.navigation.sources > .content > .details-section): Deleted.
577         (.sidebar > .panel.navigation.sources > .content > .details-section.paused-reason.collapsed > .header > .options,): Deleted.
578         (.sidebar > .panel.navigation.sources > .content > .details-section.collapsed > .content): Deleted.
579         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints > .header > .options .create-breakpoint): Deleted.
580         (.sidebar > .panel.navigation.sources > .content > .tree-outline.single-thread): Deleted.
581         (.sidebar > .panel.navigation.sources > .content > .tree-outline.single-thread > .item.thread): Deleted.
582         (.sidebar > .panel.navigation.sources > .content > .resources): Deleted.
583
584 2019-03-20  Devin Rousso  <drousso@apple.com>
585
586         "Reveal in Layers Tab" context menu option should not be available if the Layers Tab has not been enabled
587         https://bugs.webkit.org/show_bug.cgi?id=196009
588
589         Reviewed by Joseph Pecoraro.
590
591         * UserInterface/Views/ContextMenuUtilities.js:
592         (WI.appendContextMenuItemsForDOMNode):
593
594 2019-03-20  Devin Rousso  <drousso@apple.com>
595
596         Web Inspector: Console: add a setting for controlling auto-expansion of Trace messages
597         https://bugs.webkit.org/show_bug.cgi?id=195690
598
599         Reviewed by Timothy Hatcher.
600
601         * UserInterface/Views/ConsoleMessageView.js:
602         (WI.ConsoleMessageView.prototype._appendStackTrace):
603
604         * UserInterface/Base/Setting.js:
605         * UserInterface/Views/SettingsTabContentView.js:
606         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
607
608         * Localizations/en.lproj/localizedStrings.js:
609
610 2019-03-20  Devin Rousso  <drousso@apple.com>
611
612         Web Inspector: DOM: selecting a node in a different frame should automatically switch the console prompt's execution context
613         https://bugs.webkit.org/show_bug.cgi?id=195805
614         <rdar://problem/48930866>
615
616         Reviewed by Timothy Hatcher.
617
618         Add an "Auto" execution context item that is selected by default and will update the
619         selected execution context whenever the inspected node changes. It will also display the
620         preferred name for whatever execution context is currently active.
621
622         * UserInterface/Views/QuickConsole.js:
623         (WI.QuickConsole):
624         (WI.QuickConsole.prototype.initializeMainExecutionContextPathComponent):
625         (WI.QuickConsole.prototype._preferredNameForFrame): Added.
626         (WI.QuickConsole.prototype._selectExecutionContext): Added.
627         (WI.QuickConsole.prototype._executionContextPathComponentsToDisplay):
628         (WI.QuickConsole.prototype._rebuildExecutionContextPathComponents):
629         (WI.QuickConsole.prototype._framePageExecutionContextsChanged):
630         (WI.QuickConsole.prototype._frameExecutionContextsCleared):
631         (WI.QuickConsole.prototype._activeExecutionContextChanged):
632         (WI.QuickConsole.prototype._createExecutionContextPathComponent):
633         (WI.QuickConsole.prototype._insertOtherExecutionContextPathComponent):
634         (WI.QuickConsole.prototype._removeOtherExecutionContextPathComponent):
635         (WI.QuickConsole.prototype._insertExecutionContextPathComponentForFrame):
636         (WI.QuickConsole.prototype._removeExecutionContextPathComponentForFrame):
637         (WI.QuickConsole.prototype._targetRemoved):
638         (WI.QuickConsole.prototype._pathComponentSelected):
639         (WI.QuickConsole.prototype._handleInspectedNodeChanged): Added.
640         (WI.QuickConsole.prototype.get selectedExecutionContext): Deleted.
641         (WI.QuickConsole.prototype.set selectedExecutionContext): Deleted.
642         (WI.QuickConsole.prototype._createExecutionContextPathComponentFromFrame): Deleted.
643         * UserInterface/Views/QuickConsole.css:
644         (.quick-console > .navigation-bar > .hierarchical-path:not(.automatic-execution-context)): Added.
645         (.quick-console > .navigation-bar > .hierarchical-path:not(.automatic-execution-context) .execution-context): Added.
646         (.quick-console > .navigation-bar > .hierarchical-path:not(.automatic-execution-context) .execution-context .selector-arrows): Added.
647         (.quick-console > .navigation-bar > .hierarchical-path.non-default-execution-context .execution-context): Deleted.
648         (.quick-console > .navigation-bar > .hierarchical-path.non-default-execution-context .execution-context .selector-arrows): Deleted.
649
650         * UserInterface/Controllers/DOMManager.js:
651         (WI.DOMManager.prototype.get inspectedNode): Added.
652         (WI.DOMManager.prototype.setInspectedNode):
653         Broadcast when the inspected node changes.
654
655         * UserInterface/Views/NavigationBar.js:
656         (WI.NavigationBar.prototype.layout):
657         When `sizesToFit` is enabled, don't force any items to be hidden.
658
659         * Localizations/en.lproj/localizedStrings.js:
660
661 2019-03-20  Devin Rousso  <drousso@apple.com>
662
663         Web Inspector: refactor WI.TimelineDataGridNode and its subclasses to unify the API surface
664         https://bugs.webkit.org/show_bug.cgi?id=195959
665         <rdar://problem/49028896>
666
667         Reviewed by Timothy Hatcher.
668
669         * UserInterface/Views/TimelineDataGridNode.js:
670         (WI.TimelineDataGridNode.prototype.get records):
671         (WI.TimelineDataGridNode.prototype.get data):
672         (WI.TimelineDataGridNode.prototype.refresh):
673
674         * UserInterface/Views/HeapAllocationsTimelineDataGridNode.js:
675         (WI.HeapAllocationsTimelineDataGridNode):
676         (WI.HeapAllocationsTimelineDataGridNode.prototype.get heapSnapshot): Added.
677         (WI.HeapAllocationsTimelineDataGridNode.prototype.get data):
678         (WI.HeapAllocationsTimelineDataGridNode.prototype.createCellContent):
679         (WI.HeapAllocationsTimelineDataGridNode.prototype.createCells):
680         (WI.HeapAllocationsTimelineDataGridNode.prototype._handleHeapSnapshotCollectedNodes):
681         (WI.HeapAllocationsTimelineDataGridNode.prototype._handleHeapSnapshotInvalidated):
682         (WI.HeapAllocationsTimelineDataGridNode.prototype.get record): Deleted.
683         (WI.HeapAllocationsTimelineDataGridNode.prototype.updateTimestamp): Deleted.
684         (WI.HeapAllocationsTimelineDataGridNode.prototype._heapSnapshotCollectedNodes): Deleted.
685         (WI.HeapAllocationsTimelineDataGridNode.prototype._heapSnapshotInvalidated): Deleted.
686
687         * UserInterface/Views/LayoutTimelineDataGridNode.js:
688         (WI.LayoutTimelineDataGridNode):
689         (WI.LayoutTimelineDataGridNode.prototype.get data):
690         (WI.LayoutTimelineDataGridNode.prototype.createCellContent):
691         (WI.LayoutTimelineDataGridNode.prototype.get records): Deleted.
692
693         * UserInterface/Views/MediaTimelineDataGridNode.js:
694         (WI.MediaTimelineDataGridNode):
695         (WI.MediaTimelineDataGridNode.prototype.get records): Deleted.
696
697         * UserInterface/Views/ProfileNodeDataGridNode.js:
698         (WI.ProfileNodeDataGridNode):
699         (WI.ProfileNodeDataGridNode.prototype.get profileNode):
700         (WI.ProfileNodeDataGridNode.prototype.get data):
701         (WI.ProfileNodeDataGridNode.prototype.createCellContent):
702         (WI.ProfileNodeDataGridNode.prototype._populate):
703         (WI.ProfileNodeDataGridNode.prototype.get records): Deleted.
704         (WI.ProfileNodeDataGridNode.prototype.get baseStartTime): Deleted.
705         (WI.ProfileNodeDataGridNode.prototype.get rangeStartTime): Deleted.
706         (WI.ProfileNodeDataGridNode.prototype.get rangeEndTime): Deleted.
707         (WI.ProfileNodeDataGridNode.prototype.updateRangeTimes): Deleted.
708         (WI.ProfileNodeDataGridNode.prototype.refresh): Deleted.
709
710         * UserInterface/Views/RenderingFrameTimelineDataGridNode.js:
711         (WI.RenderingFrameTimelineDataGridNode):
712         (WI.RenderingFrameTimelineDataGridNode.prototype.get data):
713         (WI.RenderingFrameTimelineDataGridNode.prototype.createCellContent):
714         (WI.RenderingFrameTimelineDataGridNode.prototype.get records): Deleted.
715
716         * UserInterface/Views/ResourceTimelineDataGridNode.js:
717         (WI.ResourceTimelineDataGridNode):
718         (WI.ResourceTimelineDataGridNode.prototype.get resource):
719         (WI.ResourceTimelineDataGridNode.prototype.get data):
720         (WI.ResourceTimelineDataGridNode.prototype.createCellContent):
721         (WI.ResourceTimelineDataGridNode.prototype.appendContextMenuItems):
722         (WI.ResourceTimelineDataGridNode.prototype.filterableDataForColumn):
723         (WI.ResourceTimelineDataGridNode.prototype._createNameCellDocumentFragment):
724         (WI.ResourceTimelineDataGridNode.prototype._cachedCellContent):
725         (WI.ResourceTimelineDataGridNode.prototype._timelineRecordUpdated):
726         (WI.ResourceTimelineDataGridNode.prototype._dataGridNodeGoToArrowClicked):
727         (WI.ResourceTimelineDataGridNode.prototype._updateStatus):
728         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar.else.let.graphDataSource.get startTime):
729         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar.else.let.graphDataSource.get currentTime):
730         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar.else.let.graphDataSource.get endTime):
731         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar.else.let.graphDataSource.get _extraTimePadding):
732         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar):
733         (WI.ResourceTimelineDataGridNode.prototype.get records): Deleted.
734
735         * UserInterface/Views/ResourceTimingPopoverDataGridNode.js:
736         (WI.ResourceTimingPopoverDataGridNode):
737         (WI.ResourceTimingPopoverDataGridNode.prototype.get records): Deleted.
738
739         * UserInterface/Views/ScriptTimelineDataGridNode.js:
740         (WI.ScriptTimelineDataGridNode.prototype.get data):
741         (WI.ScriptTimelineDataGridNode.prototype.get subtitle):
742         (WI.ScriptTimelineDataGridNode.prototype.createCellContent):
743         (WI.ScriptTimelineDataGridNode.prototype.get records): Deleted.
744         (WI.ScriptTimelineDataGridNode.prototype.get baseStartTime): Deleted.
745         (WI.ScriptTimelineDataGridNode.prototype.get rangeStartTime): Deleted.
746         (WI.ScriptTimelineDataGridNode.prototype.get rangeEndTime): Deleted.
747         (WI.ScriptTimelineDataGridNode.prototype.updateRangeTimes): Deleted.
748
749         * UserInterface/Views/SourceCodeTimelineTimelineDataGridNode.js:
750         (WI.SourceCodeTimelineTimelineDataGridNode.prototype.get data):
751
752         * UserInterface/Views/HeapAllocationsTimelineView.js:
753         (WI.HeapAllocationsTimelineView):
754         (WI.HeapAllocationsTimelineView.prototype.layout):
755         (WI.HeapAllocationsTimelineView.prototype.reset):
756         * UserInterface/Views/LayoutTimelineView.js:
757         (WI.LayoutTimelineView.prototype._processPendingRecords):
758         * UserInterface/Views/MediaTimelineView.js:
759         (WI.MediaTimelineView.prototype._processPendingRecords):
760         * UserInterface/Views/NetworkTimelineView.js:
761         (WI.NetworkTimelineView.prototype._processPendingRecords):
762         * UserInterface/Views/OverviewTimelineView.js:
763         (WI.OverviewTimelineView.prototype._addResourceToDataGridIfNeeded):
764         (WI.OverviewTimelineView.prototype._addSourceCodeTimeline):
765         * UserInterface/Views/RenderingFrameTimelineView.js:
766         (WI.RenderingFrameTimelineView.prototype._processPendingRecords):
767         * UserInterface/Views/ScriptDetailsTimelineView.js:
768         (WI.ScriptDetailsTimelineView.prototype.layout):
769         (WI.ScriptDetailsTimelineView.prototype._processPendingRecords):
770         Update Timeline `WI.DataGrid` views to use the new constructor format.
771
772         * UserInterface/Views/ResourceTimelineDataGridNode.css:
773         (.resource-timing-popover-content .data-grid td.graph-column):
774         Drive-by: add extra padding before/after resource timing bars shown when hovering.
775
776 2019-03-20  Devin Rousso  <drousso@apple.com>
777
778         Web Inspector: changes to CSS resources only take affect once editing stops
779         https://bugs.webkit.org/show_bug.cgi?id=195774
780         <rdar://problem/48905413>
781
782         Reviewed by Timothy Hatcher.
783
784         * UserInterface/Controllers/CSSManager.js:
785         (WI.CSSManager.prototype._resourceContentDidChange.applyStyleSheetChanges.styleSheetFound):
786         (WI.CSSManager.prototype._resourceContentDidChange):
787         (WI.CSSManager.prototype._updateResourceContent.fetchedStyleSheetContent):
788         (WI.CSSManager.prototype._updateResourceContent):
789         Use a `Throttler` instead of a 500ms debounce.
790
791 2019-03-20  Devin Rousso  <drousso@apple.com>
792
793         Web Inspector: Search: allow DOM searches to be case sensitive
794         https://bugs.webkit.org/show_bug.cgi?id=194673
795         <rdar://problem/48087577>
796
797         Reviewed by Timothy Hatcher.
798
799         * UserInterface/Views/SearchSidebarPanel.js:
800         (WI.SearchSidebarPanel.prototype.performSearch):
801
802         * UserInterface/Views/DOMTreeContentView.js:
803         (WI.DOMTreeContentView.prototype.performSearch.contextNodesReady):
804
805         * UserInterface/Controllers/DOMManager.js:
806         (WI.DOMManager.prototype.performSearch.callback): Deleted.
807         (WI.DOMManager.prototype.performSearch): Deleted.
808         (WI.DOMManager.prototype.searchResult.mycallback): Deleted.
809         (WI.DOMManager.prototype.searchResult): Deleted.
810         (WI.DOMManager.prototype.cancelSearch): Deleted.
811         Drive-by: remove unused code.
812
813 2019-03-19  Devin Rousso  <drousso@apple.com>
814
815         Web Inspector: Sources: provide option to group by path
816         https://bugs.webkit.org/show_bug.cgi?id=195203
817         <rdar://problem/27340680>
818
819         Reviewed by Timothy Hatcher.
820
821         Create top-level folders for each origin and nest all resources (in a folder chain) underneath.
822
823         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
824         (WI.SourcesNavigationSidebarPanel):
825         (WI.SourcesNavigationSidebarPanel.prototype.closed):
826         (WI.SourcesNavigationSidebarPanel.prototype.treeElementForRepresentedObject.searchTreeOutline): Added.
827         (WI.SourcesNavigationSidebarPanel.prototype.treeElementForRepresentedObject):
828         (WI.SourcesNavigationSidebarPanel.prototype._compareTreeElements):
829         (WI.SourcesNavigationSidebarPanel.prototype._updateMainFrameTreeElement):
830         (WI.SourcesNavigationSidebarPanel.prototype._addResource):
831         (WI.SourcesNavigationSidebarPanel.prototype._addScript):
832         (WI.SourcesNavigationSidebarPanel.prototype._addWorkerTargetWithMainResource):
833         (WI.SourcesNavigationSidebarPanel.prototype._handleResourceGroupingModeMouseDown.addOption): Added.
834         (WI.SourcesNavigationSidebarPanel.prototype._handleResourceGroupingModeMouseDown): Added.
835         (WI.SourcesNavigationSidebarPanel.prototype._handleTreeSelectionDidChange):
836         (WI.SourcesNavigationSidebarPanel.prototype._handleResourceGroupingModeChanged):
837         (WI.SourcesNavigationSidebarPanel.prototype._handleFrameMainResourceDidChange):
838         (WI.SourcesNavigationSidebarPanel.prototype._handleMainFrameDidChange):
839         * UserInterface/Views/SourcesNavigationSidebarPanel.css:
840         (.sidebar > .panel.navigation.sources > .content):
841         (.sidebar > .panel.navigation.sources > .content > .details-section.paused-reason.collapsed > .header > .options,):
842         (.sidebar > .panel.navigation.sources > .content > .details-section.breakpoints > .header > .options .create-breakpoint): Added.
843         (.sidebar > .panel.navigation.sources > .content > .resources): Added.
844         (.sidebar > .panel.navigation.sources > .content .tree-outline.single-thread): Added.
845         (.sidebar > .panel.navigation.sources > .content .tree-outline.single-thread > .item.thread): Added.
846         (.sidebar > .panel.navigation.sources > .content > .details-section.scripts:not(.collapsed)): Deleted.
847         (.sidebar > .panel.navigation.sources > .content > .tree-outline.single-thread): Deleted.
848         (.sidebar > .panel.navigation.sources > .content > .tree-outline.single-thread > .item.thread): Deleted.
849         Drive-by: fix "No Filter Results" message view to not overlap eachother.
850         Drive-by: try to be more smart about what tree we focus when selecting a represented object.
851
852         * UserInterface/Views/ResourceTreeElement.js:
853         (WI.ResourceTreeElement):
854         (WI.ResourceTreeElement.prototype.get mainTitleText):
855         (WI.ResourceTreeElement.prototype._updateTitles):
856         * UserInterface/Base/URLUtilities.js:
857         (WI.displayNameForURL):
858         Provide a way for the display name to use a directory "/" instead of the last path component.
859         This is needed in cases where the loaded resource is an implicit "index.*".
860
861         * UserInterface/Views/GeneralTreeElement.js:
862         (WI.GeneralTreeElement.prototype.createFoldersAsNeededForSubpath): Added.
863         * UserInterface/Views/SourceCodeTreeElement.js:
864         (WI.SourceCodeTreeElement.prototype.createFoldersAsNeededForSubpath): Deleted.
865
866         * Localizations/en.lproj/localizedStrings.js:
867         * UserInterface/Models/Resource.js:
868
869         * UserInterface/Views/DetailsSection.css:
870         (.details-section > .header .go-to-arrow):
871         Drive-by: vertically center go-to-arrow.
872
873         * UserInterface/Protocol/InspectorFrontendAPI.js:
874         (InspectorFrontendAPI.contextMenuItemSelected):
875
876         * UserInterface/Base/Setting.js:
877         * UserInterface/Views/NetworkTableContentView.js:
878         (WI.NetworkTableContentView):
879         (WI.NetworkTableContentView.prototype.get filterNavigationItems):
880         (WI.NetworkTableContentView.prototype._populateNameCell):
881         (WI.NetworkTableContentView.prototype._generateSortComparator):
882         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
883         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
884         (WI.NetworkTableContentView.prototype._handleGroupMediaRequestsByDOMNodeCheckedDidChange): Added.
885         (WI.NetworkTableContentView.prototype._handleGroupByDOMNodeCheckedDidChange): Deleted.
886         Rename the `groupByNode` setting to be more specific.
887
888 2019-03-19  Devin Rousso  <drousso@apple.com>
889
890         Web Inspector: CPU Usage Timeline - the right edge of each column should align with a CPU measurement
891         https://bugs.webkit.org/show_bug.cgi?id=195789
892         <rdar://problem/48915271>
893
894         Reviewed by Joseph Pecoraro.
895
896         Right now, each column is rendered such that the middle of the column is aligned with the
897         time of the CPU measurement. This could potentially be misleading, as the width/position of
898         the bar implies that there was a period of time after the actual time of the CPU measurement
899         that should be "attributed" to that same CPU measurement.
900
901            1      2      3
902                _______
903                [  *  ]
904                [  *  ]_______
905                [  *  ][  *  ]
906         _______[  *  ][  *  ]
907         [  *  ][  *  ][  *  ]
908         [__*__][__*__][__*__]
909          A   B  C   D  E   F
910
911         In this example, one might "attribute" any work done at time B to record 1, when in reality,
912         it should be "attributed" to record 2, since the CPU measurement had already been taken by
913         the time B was captured, meaning that the work for B hadn't yet been done and could
914         therefore not have affected the CPU measurement for record 1.
915
916         We should be rendering the columns such that the CPU measurement aligns with the trailing
917         edge of the column, so that all of the work that could be "attributed" to a given CPU
918         measurement comes before it.
919
920           1      2      3
921             _______       ___
922             [    *]       [
923             [    *]_______[
924             [    *][    *][
925         ____[    *][    *][
926           *][    *][    *][
927         __*][____*][____*][__
928          A   B  C   D  E   F
929
930                 NOTE: this "rendering" isn't exactly accurate, as the `*` should overlap the `]`.
931
932         Legend:
933          - `[     ]` represents a column for a CPU measurement
934          - `*` represents the time when the measurement actually takes place
935
936         * UserInterface/Views/CPUTimelineOverviewGraph.js:
937         (WI.CPUTimelineOverviewGraph.prototype.layout):
938         (WI.CPUTimelineOverviewGraph.prototype._handleChartClick):
939         * UserInterface/Views/TimelineOverview.js:
940         (WI.TimelineOverview.prototype._recordSelected):
941
942 2019-03-19  Devin Rousso  <drousso@apple.com>
943
944         Web Inspector: Provide $event in the console when paused on an event listener
945         https://bugs.webkit.org/show_bug.cgi?id=188672
946
947         Reviewed by Timothy Hatcher.
948
949         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
950         (WI.JavaScriptRuntimeCompletionProvider.prototype.completionControllerCompletionsNeeded.receivedPropertyNames):
951
952 2019-03-19  Devin Rousso  <drousso@apple.com>
953
954         Web Inspector: DOM: "Capture Screenshot" should only be shown if the node is attached
955         https://bugs.webkit.org/show_bug.cgi?id=195793
956         <rdar://problem/48916594>
957
958         Reviewed by Joseph Pecoraro.
959
960         * UserInterface/Models/DOMNode.js:
961         (WI.DOMNode.prototype.get attached): Added.
962
963         * UserInterface/Views/ContextMenuUtilities.js:
964         (WI.appendContextMenuItemsForDOMNode):
965         * UserInterface/Views/DOMTreeElement.js:
966         (WI.DOMTreeElement.prototype._populateTagContextMenu):
967
968 2019-03-18  Joseph Pecoraro  <pecoraro@apple.com>
969
970         Web Inspector: HAR Extension for `serverIPAddress` port number
971         https://bugs.webkit.org/show_bug.cgi?id=195695
972
973         Reviewed by Matt Baker.
974
975         * UserInterface/Controllers/HARBuilder.js:
976         (WI.HARBuilder.entry):
977         (WI.HARBuilder.port):
978         * UserInterface/Models/LocalResource.js:
979         (WI.LocalResource.fromHAREntry):
980
981 2019-03-16  Nikita Vasilyev  <nvasilyev@apple.com>
982
983         Web Inspector: Changes: style attribute changes aren't being tracked
984         https://bugs.webkit.org/show_bug.cgi?id=193859
985         <rdar://problem/47568977>
986
987         Reviewed by Devin Rousso.
988
989         * UserInterface/Controllers/CSSManager.js:
990         (WI.CSSManager):
991         (WI.CSSManager.prototype.get modifiedStyles):
992         (WI.CSSManager.prototype.addModifiedStyle):
993         (WI.CSSManager.prototype._mainResourceDidChange):
994         (WI.CSSManager.prototype.get modifiedCSSRules): Deleted.
995         (WI.CSSManager.prototype.addModifiedCSSRule): Deleted.
996         (WI.CSSManager.prototype.removeModifiedCSSRule): Deleted.
997         * UserInterface/Models/CSSRule.js:
998         (WI.CSSRule.prototype.get stringId): Deleted.
999         (WI.CSSRule.prototype.markModified): Deleted.
1000         * UserInterface/Models/CSSStyleDeclaration.js:
1001         (WI.CSSStyleDeclaration.prototype.get stringId):
1002         (WI.CSSStyleDeclaration.prototype.markModified):
1003         Inline styles weren't tracked because they didn't have owner rules.
1004         Track style declarations instead of CSS rules.
1005
1006         * UserInterface/Views/ChangesDetailsSidebarPanel.css:
1007         (.sidebar > .panel.changes-panel .css-rule):
1008         (.sidebar > .panel.changes-panel .css-rule + .css-rule):
1009         (.changes-panel .selector.style-attribute):
1010         (.changes-panel .selector:not(.style-attribute)):
1011         (.changes-panel .css-property-line > .property):
1012         (.changes-panel .css-property-line.unchanged): Deleted.
1013         Drive-by: use text-color-secondary for unchanged properties instead of altering opacity.
1014
1015         * UserInterface/Views/ChangesDetailsSidebarPanel.js:
1016         (WI.ChangesDetailsSidebarPanel.prototype.layout):
1017         (WI.ChangesDetailsSidebarPanel.prototype._createRuleElement):
1018         For an inline style declaration, instead of showing a CSS source file location show an appropriate selector for its DOM node.
1019
1020 2019-03-15  Joseph Pecoraro  <pecoraro@apple.com>
1021
1022         Web Inspector: HAR Extension for Resource Priority
1023         https://bugs.webkit.org/show_bug.cgi?id=195693
1024
1025         Reviewed by Devin Rousso.
1026
1027         * UserInterface/Controllers/HARBuilder.js:
1028         (WI.HARBuilder.entry):
1029         (WI.HARBuilder.priority):
1030         (WI.HARBuilder.networkPriorityFromHARPriority):
1031         Include priority custom extension.
1032
1033         * UserInterface/Models/LocalResource.js:
1034         (WI.LocalResource.fromHAREntry):
1035         Import priority.
1036
1037 2019-03-15  Joseph Pecoraro  <pecoraro@apple.com>
1038
1039         Web Inspector: CPU Usage Timeline - Give long thread names a tooltip if they could be ellipsized
1040         https://bugs.webkit.org/show_bug.cgi?id=195314
1041
1042         Reviewed by Devin Rousso.
1043
1044         * UserInterface/Views/CPUUsageView.js:
1045         (WI.CPUUsageView):
1046
1047 2019-03-15  Joseph Pecoraro  <pecoraro@apple.com>
1048
1049         Web Inspector: CPU Usage Timeline - Reduce the intensity of the orange overlay color in dark mode
1050         https://bugs.webkit.org/show_bug.cgi?id=195772
1051
1052         Reviewed by Devin Rousso.
1053
1054         * UserInterface/Views/Variables.css:
1055         (@media (prefers-color-scheme: dark)):
1056         (:root):
1057
1058 2019-03-15  Joseph Pecoraro  <pecoraro@apple.com>
1059
1060         Web Inspector: Timelines - Import / Export Timeline Recordings
1061         https://bugs.webkit.org/show_bug.cgi?id=195709
1062         <rdar://problem/23188921>
1063
1064         Reviewed by Devin Rousso.
1065
1066         Timeline exporting saves TimelineRecording and TimelineOverview state.
1067         The TimelineRecording includes all kinds of model objects, such as
1068         records, markers, memory pressure events, etc. It also includes raw
1069         protocol data, such as script profiler samples. TimelineOverview
1070         includes some of the view state to restore, such as the selected
1071         time range, zoom level, and selected timeline.
1072
1073         Timeline importing constructs a new TimelineRecording by replaying
1074         the records, markers, and other events, as well as re-initializing
1075         more state. To finally display the imported recording, the content
1076         view will immediately initialize start/current/end times and the
1077         overview will restore the view state.
1078
1079         * Localizations/en.lproj/localizedStrings.js:
1080         New strings.
1081
1082         * UserInterface/Controllers/TimelineManager.js:
1083         (WI.TimelineManager.synthesizeImportError):
1084         (WI.TimelineManager.prototype.importRecording):
1085         Import API.
1086
1087         (WI.TimelineManager.prototype.scriptProfilerTrackingCompleted):
1088         Initialize the samples on the recording via a different path
1089         so that the data can be saved for exporting.
1090
1091         * UserInterface/Models/TimelineRecording.js:
1092         (WI.TimelineRecording):
1093         (WI.TimelineRecording.import):
1094         (WI.TimelineRecording.prototype.exportData):
1095         (WI.TimelineRecording.prototype.get capturing):
1096         (WI.TimelineRecording.prototype.get imported):
1097         (WI.TimelineRecording.prototype.unloaded):
1098         (WI.TimelineRecording.prototype.reset):
1099         (WI.TimelineRecording.prototype.addEventMarker):
1100         (WI.TimelineRecording.prototype.addRecord):
1101         (WI.TimelineRecording.prototype.addMemoryPressureEvent):
1102         (WI.TimelineRecording.prototype.initializeCallingContextTrees):
1103         (WI.TimelineRecording.prototype.canExport):
1104         Save data at the TimelineRecording level that can be used for export.
1105         We only allow exporting a TimelineRecording that has started/stopped
1106         at least once and is not currently capturing.
1107
1108         * UserInterface/Views/TimelineRecordingContentView.js:
1109         (WI.TimelineRecordingContentView):
1110         (WI.TimelineRecordingContentView.prototype.get navigationItems):
1111         (WI.TimelineRecordingContentView.prototype.get supportsSave):
1112         (WI.TimelineRecordingContentView.prototype.get saveData):
1113         (WI.TimelineRecordingContentView.prototype.shown):
1114         (WI.TimelineRecordingContentView.prototype._capturingStarted):
1115         (WI.TimelineRecordingContentView.prototype._capturingStopped):
1116         (WI.TimelineRecordingContentView.prototype._initializeImportedRecording):
1117         (WI.TimelineRecordingContentView.prototype._exportTimelineRecording):
1118         (WI.TimelineRecordingContentView.prototype._importButtonNavigationItemClicked):
1119         (WI.TimelineRecordingContentView.prototype._recordingReset):
1120         Add Import and Export buttons in the Timeline navigation bar.
1121
1122         * UserInterface/Views/TimelineOverview.js:
1123         (WI.TimelineOverview):
1124         (WI.TimelineOverview.prototype.exportData):
1125         (WI.TimelineOverview.prototype._instrumentAdded):
1126         (WI.TimelineOverview.prototype._recordingImported):
1127         When importing a recording update the TimelineOverview state
1128         soon afterwards.
1129
1130         * UserInterface/Models/CPUTimelineRecord.js:
1131         (WI.CPUTimelineRecord.fromJSON):
1132         (WI.CPUTimelineRecord.prototype.toJSON):
1133         * UserInterface/Models/GarbageCollection.js:
1134         (WI.GarbageCollection.fromJSON):
1135         (WI.GarbageCollection.prototype.toJSON):
1136         * UserInterface/Models/Geometry.js:
1137         (WI.Quad.fromJSON):
1138         (WI.Quad.prototype.toJSON):
1139         * UserInterface/Models/HeapAllocationsTimelineRecord.js:
1140         (WI.HeapAllocationsTimelineRecord.fromJSON):
1141         (WI.HeapAllocationsTimelineRecord.prototype.toJSON):
1142         * UserInterface/Models/LayoutTimelineRecord.js:
1143         (WI.LayoutTimelineRecord.fromJSON):
1144         (WI.LayoutTimelineRecord.prototype.toJSON):
1145         * UserInterface/Models/MediaTimelineRecord.js:
1146         (WI.MediaTimelineRecord.fromJSON):
1147         (WI.MediaTimelineRecord.prototype.toJSON):
1148         * UserInterface/Models/MemoryPressureEvent.js:
1149         (WI.MemoryPressureEvent.fromJSON):
1150         (WI.MemoryPressureEvent.prototype.toJSON):
1151         * UserInterface/Models/MemoryTimelineRecord.js:
1152         (WI.MemoryTimelineRecord):
1153         (WI.MemoryTimelineRecord.fromJSON):
1154         (WI.MemoryTimelineRecord.prototype.toJSON):
1155         * UserInterface/Models/RenderingFrameTimelineRecord.js:
1156         (WI.RenderingFrameTimelineRecord.fromJSON):
1157         (WI.RenderingFrameTimelineRecord.prototype.toJSON):
1158         * UserInterface/Models/ResourceTimelineRecord.js:
1159         (WI.ResourceTimelineRecord.fromJSON):
1160         (WI.ResourceTimelineRecord.prototype.toJSON):
1161         * UserInterface/Models/ScriptTimelineRecord.js:
1162         (WI.ScriptTimelineRecord.fromJSON):
1163         (WI.ScriptTimelineRecord.prototype.toJSON):
1164         * UserInterface/Models/TimelineMarker.js:
1165         (WI.TimelineMarker.fromJSON):
1166         (WI.TimelineMarker.prototype.toJSON):
1167         (WI.TimelineMarker.prototype.get type):
1168         (WI.TimelineMarker.prototype.get details):
1169         (WI.TimelineMarker.prototype.set time):
1170         (WI.TimelineMarker):
1171         * UserInterface/Models/TimelineRecord.js:
1172         (WI.TimelineRecord.fromJSON):
1173         (WI.TimelineRecord.prototype.toJSON):
1174         Import / Export toJSON / fromJSON implementations.
1175         
1176         * UserInterface/Views/CPUTimelineOverviewGraph.js:
1177         (WI.CPUTimelineOverviewGraph):
1178         (WI.CPUTimelineOverviewGraph.prototype._cpuTimelineRecordAdded):
1179         (WI.CPUTimelineOverviewGraph.prototype._processRecord):
1180         * UserInterface/Views/LayoutTimelineOverviewGraph.js:
1181         (WI.LayoutTimelineOverviewGraph):
1182         (WI.LayoutTimelineOverviewGraph.prototype._layoutTimelineRecordAdded):
1183         (WI.LayoutTimelineOverviewGraph.prototype._processRecord):
1184         * UserInterface/Views/LayoutTimelineView.js:
1185         (WI.LayoutTimelineView):
1186         (WI.LayoutTimelineView.prototype._layoutTimelineRecordAdded):
1187         (WI.LayoutTimelineView.prototype._processRecord):
1188         * UserInterface/Views/MediaTimelineView.js:
1189         (WI.MediaTimelineView):
1190         (WI.MediaTimelineView.prototype._handleRecordAdded):
1191         (WI.MediaTimelineView.prototype._processRecord):
1192         * UserInterface/Views/MemoryTimelineOverviewGraph.js:
1193         (WI.MemoryTimelineOverviewGraph):
1194         (WI.MemoryTimelineOverviewGraph.prototype._memoryTimelineRecordAdded):
1195         (WI.MemoryTimelineOverviewGraph.prototype._processRecord):
1196         * UserInterface/Views/MemoryTimelineView.js:
1197         (WI.MemoryTimelineView):
1198         (WI.MemoryTimelineView.prototype._memoryTimelineRecordAdded):
1199         (WI.MemoryTimelineView.prototype._processRecord):
1200         * UserInterface/Views/NetworkTimelineOverviewGraph.js:
1201         (WI.NetworkTimelineOverviewGraph):
1202         (WI.NetworkTimelineOverviewGraph.prototype.reset):
1203         (WI.NetworkTimelineOverviewGraph.prototype._networkTimelineRecordAdded):
1204         (WI.NetworkTimelineOverviewGraph.prototype._processRecord):
1205         (WI.NetworkTimelineOverviewGraph.prototype._networkTimelineRecordAdded.compareByStartTime): Deleted.
1206         * UserInterface/Views/NetworkTimelineView.js:
1207         (WI.NetworkTimelineView):
1208         (WI.NetworkTimelineView.prototype._networkTimelineRecordAdded):
1209         (WI.NetworkTimelineView.prototype._processRecord):
1210         * UserInterface/Views/RenderingFrameTimelineView.js:
1211         (WI.RenderingFrameTimelineView):
1212         (WI.RenderingFrameTimelineView.prototype._renderingFrameTimelineRecordAdded):
1213         (WI.RenderingFrameTimelineView.prototype._processRecord):
1214         * UserInterface/Views/ScriptDetailsTimelineView.js:
1215         (WI.ScriptDetailsTimelineView):
1216         (WI.ScriptDetailsTimelineView.prototype._scriptTimelineRecordAdded):
1217         (WI.ScriptDetailsTimelineView.prototype._processRecord):
1218         Add common _processRecord path to each timeline OverviewGraph and TimelineView.
1219         By calling this in construction we populate graphs with TimelineRecords that
1220         may have already existed. This is necessary for imports, but this also fixes
1221         the case where you enable a timeline that had data and it didn't show data.
1222
1223         * UserInterface/Views/LayoutTimelineOverviewGraph.css:
1224         (.timeline-overview-graph.layout-overview > .graph-row):
1225         (.timeline-overview-graph.layout-overview > .graph-row > .timeline-record-bar):
1226         (.timeline-overview-graph.layout-overview > .graph-row > .timeline-record-bar > .segment):
1227         (.timeline-overview-graph.layout > .graph-row): Deleted.
1228         (.timeline-overview-graph.layout > .graph-row > .timeline-record-bar): Deleted.
1229         (.timeline-overview-graph.layout > .graph-row > .timeline-record-bar > .segment): Deleted.
1230         * UserInterface/Views/TimelineRecordBar.css:
1231         (.timeline-record-bar.timeline-record-type-layout.paint > .segment,):
1232         (.timeline-record-bar.timeline-record-type-layout.layout-timeline-record-paint > .segment,): Deleted.
1233         We simplified some of the sub-record type enum strings. To do this we needed to change
1234         "layout" to "layout-overview" to avoid a conflict.
1235
1236 2019-03-15  Joseph Pecoraro  <pecoraro@apple.com>
1237
1238         Web Inspector: Network - Toggle Between Live Activity and Imported HAR resource collections
1239         https://bugs.webkit.org/show_bug.cgi?id=195734
1240
1241         Reviewed by Devin Rousso.
1242
1243         * Localizations/en.lproj/localizedStrings.js:
1244         * UserInterface/Images/NetworkHAR.svg: Added.
1245         * UserInterface/Images/NetworkOverview.svg: Added.
1246         * UserInterface/Views/NetworkTableContentView.css:
1247         (.content-view.tab.network > .content-browser > .navigation-bar .hierarchical-path .icon):
1248         (.network-overview-icon > .icon):
1249         (.network-har-icon > .icon):
1250         (@media (prefers-color-scheme: dark)):
1251
1252         * UserInterface/Views/NetworkTableContentView.js:
1253         (WI.NetworkTableContentView):
1254         (WI.NetworkTableContentView.prototype.get navigationItems):
1255         (WI.NetworkTableContentView.prototype.reset):
1256         (WI.NetworkTableContentView.prototype.tableIndexForRepresentedObject):
1257         (WI.NetworkTableContentView.prototype.tableRepresentedObjectForIndex):
1258         (WI.NetworkTableContentView.prototype.tableNumberOfRows):
1259         (WI.NetworkTableContentView.prototype.tableCellContextMenuClicked):
1260         (WI.NetworkTableContentView.prototype.tableSelectionDidChange):
1261         (WI.NetworkTableContentView.prototype.tablePopulateCell):
1262         (WI.NetworkTableContentView.prototype._addCollection):
1263         (WI.NetworkTableContentView.prototype._setActiveCollection):
1264         (WI.NetworkTableContentView.prototype._addCollectionPathComponent):
1265         (WI.NetworkTableContentView.prototype._collectionsHierarchicalPathComponentWasSelected):
1266         (WI.NetworkTableContentView.prototype._changeCollection):
1267         (WI.NetworkTableContentView.prototype.handleClearShortcut):
1268         (WI.NetworkTableContentView.prototype._updateWaterfallTimeRange):
1269         (WI.NetworkTableContentView.prototype._updateWaterfallTimelineRuler):
1270         (WI.NetworkTableContentView.prototype._canExportHAR):
1271         (WI.NetworkTableContentView.prototype._processPendingEntries):
1272         (WI.NetworkTableContentView.prototype._populateWithInitialResourcesIfNeeded):
1273         (WI.NetworkTableContentView.prototype._rowIndexForRepresentedObject):
1274         (WI.NetworkTableContentView.prototype._updateEntryForResource):
1275         (WI.NetworkTableContentView.prototype._updateEmptyFilterResultsMessage):
1276         (WI.NetworkTableContentView.prototype._mainResourceDidChange):
1277         (WI.NetworkTableContentView.prototype._mainFrameDidChange):
1278         (WI.NetworkTableContentView.prototype._resourceLoadingDidFinish):
1279         (WI.NetworkTableContentView.prototype._resourceLoadingDidFail):
1280         (WI.NetworkTableContentView.prototype._resourceTransferSizeDidChange):
1281         (WI.NetworkTableContentView.prototype._handleResourceAdded):
1282         (WI.NetworkTableContentView.prototype._runForMainCollection):
1283         (WI.NetworkTableContentView.prototype._isShowingMainCollection):
1284         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
1285         (WI.NetworkTableContentView.prototype._handleNodeDidFireEvent):
1286         (WI.NetworkTableContentView.prototype._handleNodeLowPowerChanged):
1287         (WI.NetworkTableContentView.prototype._updateSort):
1288         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
1289         (WI.NetworkTableContentView.prototype._urlFilterDidChange):
1290         (WI.NetworkTableContentView.prototype._HARResources):
1291         (WI.NetworkTableContentView.prototype._importHAR):
1292         Introduce the concept of collections that can be swapped in/out
1293         to re-render the Network Table with different contents.
1294
1295 2019-03-15  Devin Rousso  <drousso@apple.com>
1296
1297         Web Inspector: provide a way to capture a screenshot of a node from within the page
1298         https://bugs.webkit.org/show_bug.cgi?id=194279
1299         <rdar://problem/10731573>
1300
1301         Reviewed by Joseph Pecoraro.
1302
1303         Add `console.screenshot` functionality, which displays a screenshot of a given object (if
1304         able) within Web Inspector's Console tab. From there, it can be viewed and saved.
1305
1306         Currently, `console.screenshot` will
1307          - capture an image of a `Node` (if provided)
1308          - capture an image of the viewport if nothing is provided
1309
1310         * UserInterface/Models/ConsoleMessage.js:
1311         (WI.ConsoleMessage):
1312         * UserInterface/Views/ConsoleCommandView.js:
1313         (WI.ConsoleCommandView.prototype.render):
1314         * UserInterface/Views/ConsoleMessageView.js:
1315         (WI.ConsoleMessageView.prototype.render):
1316         (WI.ConsoleMessageView.prototype.toClipboardString):
1317         (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments):
1318         (WI.ConsoleMessageView.prototype._appendSavedResultIndex):
1319         (WI.ConsoleMessageView.prototype._appendStackTrace):
1320         (WI.ConsoleMessageView.prototype._makeExpandable):
1321         (WI.ConsoleMessageView.prototype._handleContextMenu): Added.
1322         * UserInterface/Views/ConsoleMessageView.css:
1323         (.console-user-command.special-user-log > .console-message-body): Added.
1324         (.console-message-body): Added.
1325         (.console-message-body > span): Added.
1326         (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added.
1327         (.console-message-body > .console-image): Added.
1328         (.console-message-body > .show-grid): Added.
1329         (.console-error-level .console-message-body): Added.
1330         (.console-warning-level .console-message-body): Added.
1331         (.console-log-level.console-image-container::before): Added.
1332         (.console-user-command > .console-message-body): Added.
1333         (.console-warning-level .console-message-body): Added.
1334         (.console-error-level .console-message-body): Added.
1335         (.console-user-command > .console-message-body): Added.
1336         (.console-user-command.special-user-log > .console-message-text): Deleted.
1337         (.console-message-text): Deleted.
1338         (.console-message-text > span): Deleted.
1339         (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted.
1340         (.console-error-level .console-message-text): Deleted.
1341         (.console-warning-level .console-message-text): Deleted.
1342         (.console-user-command > .console-message-text): Deleted.
1343         (.console-warning-level .console-message-text): Deleted.
1344         (.console-error-level .console-message-text): Deleted.
1345         (.console-user-command > .console-message-text): Deleted.
1346         * UserInterface/Views/LogContentView.css:
1347         (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added.
1348         (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted.
1349         Renamed variables/classes to be more semantically correct when the content is an image.
1350          - `_messageTextElement` to `_messageBodyElement` (JS)
1351          - `.console-message-text` to `.console-message-body` (CSS)
1352
1353         * UserInterface/Controllers/JavaScriptLogViewController.js:
1354         (WI.JavaScriptLogViewController.prototype.renderPendingMessages):
1355
1356         * UserInterface/Views/Main.css:
1357         (:matches(img, canvas).show-grid):
1358         (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid):
1359
1360         * UserInterface/Base/FileUtilities.js:
1361         (WI.FileUtilities.screenshotString): Added.
1362
1363         * UserInterface/Models/NativeFunctionParameters.js:
1364         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
1365
1366         * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg.
1367         * Localizations/en.lproj/localizedStrings.js:
1368
1369 2019-03-14  Nikita Vasilyev  <nvasilyev@apple.com>
1370
1371         Web Inspector: Styles: Jump to effective property button doesn't hide after overridden property become effective
1372         https://bugs.webkit.org/show_bug.cgi?id=195770
1373         <rdar://problem/48903634>
1374
1375         Reviewed by Matt Baker.
1376
1377         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1378         (.spreadsheet-style-declaration-editor .property .select-effective-property): Added.
1379         (.spreadsheet-style-declaration-editor .property.overridden .select-effective-property): Deleted.
1380         Hide `.select-effective-property` element for properties that aren't overridden.
1381
1382 2019-03-14  Devin Rousso  <drousso@apple.com>
1383
1384         Web Inspector: REGRESSION: Canvas: the first processed action should be selected as soon as it's available if no previous selected action exists
1385         https://bugs.webkit.org/show_bug.cgi?id=195732
1386         <rdar://problem/48875214>
1387
1388         Reviewed by Matt Baker.
1389
1390         * UserInterface/Views/CanvasSidebarPanel.js:
1391         (WI.CanvasSidebarPanel.prototype._handleRecordingProcessedAction):
1392         Rather than wait until the entire recording is ready, set the selected action as soon as the
1393         first action is ready (assuming there isn't already a selected action).
1394
1395 2019-03-14  Joseph Pecoraro  <pecoraro@apple.com>
1396
1397         Web Inspector: Network - HAR Import
1398         https://bugs.webkit.org/show_bug.cgi?id=195642
1399         <rdar://problem/34820974>
1400
1401         Reviewed by Devin Rousso.
1402
1403         * Localizations/en.lproj/localizedStrings.js
1404         * UserInterface/Test.html:
1405         * UserInterface/Test.html:
1406         New strings and resources.
1407
1408         * UserInterface/Controllers/HARBuilder.js:
1409         (WI.HARBuilder.dateFromHARDate):
1410         (WI.HARBuilder.protocolFromHARProtocol):
1411         (WI.HARBuilder.responseSourceFromHARFetchType):
1412         Reverse parsers from HAR to WI.Resource types.
1413
1414         * UserInterface/Models/LocalResource.js: Added.
1415         (WI.LocalResource):
1416         (WI.LocalResource.headersArrayToHeadersObject):
1417         (WI.LocalResource.fromHAREntry):
1418         (WI.LocalResource.prototype.hasContent):
1419         (WI.LocalResource.prototype.setContent):
1420         (WI.LocalResource.prototype.requestContentFromBackend):
1421         A Resource subclass with data fully supplied in the frontend.
1422
1423         * UserInterface/Controllers/NetworkManager.js:
1424         (WI.NetworkManager):
1425         (WI.NetworkManager.synthesizeImportError):
1426         (WI.NetworkManager.prototype.localResourceForURL):
1427         (WI.NetworkManager.prototype.processHAR):
1428         Process a HAR and extract local resources.
1429
1430         * UserInterface/Views/NetworkTableContentView.js:
1431         (WI.NetworkTableContentView):
1432         (WI.NetworkTableContentView.prototype.reset):
1433         (WI.NetworkTableContentView.prototype._handleResourceAdded):
1434         (WI.NetworkTableContentView.prototype._importHAR):
1435         Add an import button. When an import succeeds reset the
1436         table and only show imported resources (ignoring page
1437         loaded resources).
1438
1439 2019-03-14  Devin Rousso  <drousso@apple.com>
1440
1441         Web Inspector: Console: getEventListeners should work for any EventTarget
1442         https://bugs.webkit.org/show_bug.cgi?id=195713
1443
1444         Reviewed by Joseph Pecoraro.
1445
1446         * UserInterface/Models/NativeFunctionParameters.js:
1447
1448 2019-03-14  Devin Rousso  <drousso@apple.com>
1449
1450         Web Inspector: Styles: `::-webkit-scrollbar*` rules aren't shown
1451         https://bugs.webkit.org/show_bug.cgi?id=195123
1452         <rdar://problem/48450148>
1453
1454         Reviewed by Joseph Pecoraro.
1455
1456         * UserInterface/Controllers/CSSManager.js:
1457         (WI.CSSManager.displayNameForPseudoId): Added.
1458
1459         * UserInterface/Models/DOMNodeStyles.js:
1460         (WI.DOMNodeStyles.static uniqueOrderedStyles): Added.
1461         (WI.DOMNodeStyles.prototype.get uniqueOrderedStyles):
1462
1463         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
1464         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.layout):
1465         (WI.SpreadsheetRulesStyleDetailsPanel.prototype._handleSectionFilterApplied):
1466         Rather than iterate over the `WI.DOMNode`'s list of pseudo-elements (which is only ::before
1467         and ::after), we iterate over the `WI.DOMNodeStyle`'s list of pseudo-element rules. This is
1468         an object where the key is a `CSS.PseudoId` and the value is an object containing all the
1469         matched rules and ordered styles for that pseudo-type. We can preserve the current
1470         functionality by using the ::before/::after `WI.DOMNode` when we encounter one of those
1471         pseudo-ids.
1472
1473         An additional benefit of this change is that `::before`/`::after` styles will still appear
1474         in the Rules panel even if they don't have a `content` property set (e.g. when the
1475         `::before`/`::after` pseudo-element doesn't exist). This is because the styles are no longer
1476         fetched from those pseudo-element nodes directly, but rather as a matched style for the
1477         parent node. As such, editing a `content` property to become invalid/disablde in a
1478         `::before`/`::after` rule won't make the entire rule disappeaer.
1479
1480 2019-03-14  Devin Rousso  <drousso@apple.com>
1481
1482         Web Inspector: we should show artificial context menus on mousedown instead of click
1483         https://bugs.webkit.org/show_bug.cgi?id=195494
1484
1485         Reviewed by Joseph Pecoraro.
1486
1487         * UserInterface/Views/ContextMenu.js:
1488         (WI.ContextMenu):
1489         (WI.ContextMenu.prototype.show):
1490         (WI.ContextMenu.prototype.addBeforeShowCallback): Added.
1491         (WI.ContextMenu.prototype.handleEvent):
1492         Provide a way to register a callback that will be called right as the "contextmenu" event is
1493         handled, but before the context menu is actually shown. Since "mousedown" events are also
1494         fired when/before a "contextmenu" event is fired, each of the below callers has to maintain
1495         some state indicating "we are about to show a context menu, so ignore all "mousedown" events
1496         until that time". Without this, the below callers wouldn't be able to tell when the context
1497         menu is finally shown.
1498
1499         * UserInterface/Base/SearchUtilities.js:
1500         (WI.SearchUtilities.createSettingsButton):
1501         * UserInterface/Views/CanvasContentView.js:
1502         (WI.CanvasContentView):
1503         (WI.CanvasContentView.prototype.initialLayout):
1504         (WI.CanvasContentView.prototype._handleCanvasElementButtonMouseDown): Added.
1505         (WI.CanvasContentView.prototype._handleViewShaderButtonMouseDown): Added.
1506         (WI.CanvasContentView.prototype._handleViewRecordingButtonMouseDown): Added.
1507         (WI.CanvasContentView.prototype._canvasElementButtonClicked): Deleted.
1508         (WI.CanvasContentView.prototype._handleViewShaderButtonClicked): Deleted.
1509         (WI.CanvasContentView.prototype._handleViewRecordingButtonClicked): Deleted.
1510         * UserInterface/Views/DebuggerSidebarPanel.js:
1511         (WI.DebuggerSidebarPanel):
1512         (WI.DebuggerSidebarPanel.prototype._handleCreateBreakpointMouseDown): Added.
1513         (WI.DebuggerSidebarPanel.prototype._handleCreateBreakpointClicked): Deleted.
1514         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
1515         (WI.SourcesNavigationSidebarPanel):
1516         (WI.SourcesNavigationSidebarPanel.prototype._handleCreateBreakpointMouseDown): Added.
1517         (WI.SourcesNavigationSidebarPanel.prototype._handleCreateBreakpointClicked): Deleted.
1518         * UserInterface/Views/TabBar.js:
1519         (WI.TabBar.prototype._handleMouseDown):
1520         * UserInterface/Views/LegacyTabBar.js:
1521         (WI.LegacyTabBar.prototype._handleMouseDown):
1522
1523 2019-03-13  Devin Rousso  <drousso@apple.com>
1524
1525         Web Inspector: Debugger: pausing in an inline script on a page with a URL query creates an Extra Script
1526         https://bugs.webkit.org/show_bug.cgi?id=195705
1527         <rdar://problem/48853820>
1528
1529         Reviewed by Antoine Quint.
1530
1531         * UserInterface/Models/Script.js:
1532         (WI.Script.prototype._resolveResource):
1533         If the page's URL has a query parameter, the payload we receive for any inline <script>s
1534         doesn't include the query parameter as part of its URL. As such, if there isn't an existing
1535         resource with a URL that exactly matches the URL of the script and if the URL of the main
1536         resource for the script's target starts with the URL of the script, we assume that the
1537         script "belongs" to the target's main resource and associate the script with it as such.
1538
1539 2019-03-13  Keith Rollin  <krollin@apple.com>
1540
1541         Add support for new StagedFrameworks layout
1542         https://bugs.webkit.org/show_bug.cgi?id=195543
1543
1544         Reviewed by Alexey Proskuryakov.
1545
1546         When creating the WebKit layout for out-of-band Safari/WebKit updates,
1547         use an optional path prefix when called for.
1548
1549         Opportunistic cleanup: remove unused
1550         OTHER_LDFLAGS_VERSIONED_FRAMEWORK_PATH variable, which otherwise would
1551         have needlessly been updated to also incorporate the new prefix.
1552
1553         * Configurations/Base.xcconfig:
1554         * Configurations/WebKitTargetConditionals.xcconfig: Added.
1555
1556 2019-03-13  Nikita Vasilyev  <nvasilyev@apple.com>
1557
1558         REGRESSION(r240946): Web Inspector: Styles: removing selected property doesn't update overridden status
1559         https://bugs.webkit.org/show_bug.cgi?id=195389
1560         <rdar://problem/48658929>
1561
1562         Reviewed by Matt Baker.
1563
1564         * UserInterface/Models/DOMNodeStyles.js:
1565         (WI.DOMNodeStyles.prototype.changeStyleText):
1566         Call DOMNodeStyles.prototype.refresh after the callback. No updates
1567         to CSSStyleDeclaration happen until the callback is called.
1568
1569 2019-03-13  Devin Rousso  <drousso@apple.com>
1570
1571         Web Inspector: Protocol Logging: log messages with backtrace if inspector^2 is open
1572         https://bugs.webkit.org/show_bug.cgi?id=195687
1573
1574         Reviewed by Joseph Pecoraro.
1575
1576         * UserInterface/Protocol/LoggingProtocolTracer.js:
1577         (WI.LoggingProtocolTracer.prototype._processEntry):
1578
1579 2019-03-13  Devin Rousso  <drousso@apple.com>
1580
1581         Web Inspector: REGRESSION(r242737): unnecessary semicolon added when populating WI.TreeOutline stylesheet
1582         https://bugs.webkit.org/show_bug.cgi?id=195689
1583
1584         Reviewed by Joseph Pecoraro.
1585
1586         * UserInterface/Views/TreeOutline.js:
1587         (WI.TreeOutline._generateStyleRulesIfNeeded):
1588
1589 2019-03-13  Joseph Pecoraro  <pecoraro@apple.com>
1590
1591         Web Inspector: Network - HAR Export duplicates blocked/send time if there was no dns/connect block
1592         https://bugs.webkit.org/show_bug.cgi?id=195655
1593         <rdar://problem/48831152>
1594
1595         Reviewed by Devin Rousso.
1596
1597         * UserInterface/Controllers/HARBuilder.js:
1598         (WI.HARBuilder.timings):
1599
1600 2019-03-12  Devin Rousso  <drousso@apple.com>
1601
1602         Web Inspector: Sources: allow image collections to be filtered by type
1603         https://bugs.webkit.org/show_bug.cgi?id=195630
1604
1605         Reviewed by Matt Baker.
1606
1607         * UserInterface/Views/ResourceCollectionContentView.js:
1608         (WI.ResourceCollectionContentView):
1609         (WI.ResourceCollectionContentView.prototype.get navigationItems): Added.
1610         (WI.ResourceCollectionContentView.prototype.contentViewAdded):
1611         (WI.ResourceCollectionContentView.prototype.contentViewRemoved): Added.
1612         (WI.ResourceCollectionContentView.prototype._updateImageTypeScopeBar): Added.
1613         (WI.ResourceCollectionContentView.prototype._handleImageTypeSelectionChanged): Added.
1614         * UserInterface/Views/ResourceCollectionContentView.css: Asdded.
1615         (.resource-collection-image-type-scope-bar.default-item-selected):
1616
1617         * UserInterface/Views/CollectionContentView.css:
1618         (.content-view.collection > .content-view[hidden]): Added.
1619
1620         * UserInterface/Views/ScopeBarItem.js:
1621         (WI.ScopeBarItem.prototype.set hidden):
1622         * UserInterface/Views/MultipleScopeBarItem.js:
1623         (WI.MultipleScopeBarItem.prototype.set scopeBarItems):
1624         (WI.MultipleScopeBarItem.prototype.set selectedScopeBarItem):
1625         (WI.MultipleScopeBarItem.prototype.get _visibleScopeBarItems): Added.
1626         (WI.MultipleScopeBarItem.prototype._selectElementSelectionChanged):
1627         (WI.MultipleScopeBarItem.prototype._handleItemHiddenChanged): Added.
1628         Dispatch an event when an item is hidden so that any owner `WI.MultipleScopeBarItem` can
1629         rerender it's <select> without that item.
1630
1631         * Localizations/en.lproj/localizedStrings.js:
1632         * UserInterface/Main.html:
1633
1634 2019-03-12  Nikita Vasilyev  <nvasilyev@apple.com>
1635
1636         Web Inspector: Keyboard shortcut for settings tab too greedy on non-US keyboards
1637         https://bugs.webkit.org/show_bug.cgi?id=192947
1638         <rdar://problem/46886779>
1639
1640         Reviewed by Devin Rousso.
1641
1642         * UserInterface/Base/Main.js:
1643         (WI._showSettingsTab):
1644
1645 2019-03-12  Devin Rousso  <drousso@apple.com>
1646
1647         Web Inspector: Elements: provide node context menu items for event listeners sorted by node
1648         https://bugs.webkit.org/show_bug.cgi?id=195633
1649
1650         Reviewed by Matt Baker.
1651
1652         * UserInterface/Base/DOMUtilities.js:
1653         (WI.linkifyNodeReferenceElement):
1654         (WI.bindInteractionsForNodeToElement): Added.
1655         Split logic for adding event listeners into a separate function so it can be used on
1656         existing DOM without modifying it.
1657
1658         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
1659         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByNode):
1660
1661 2019-03-12  Devin Rousso  <drousso@apple.com>
1662
1663         Web Inspector: DOM Debugger: remove left padding when the last DOM breakpoint is removed
1664         https://bugs.webkit.org/show_bug.cgi?id=195522
1665
1666         Reviewed by Matt Baker.
1667
1668         * UserInterface/Views/DOMTreeContentView.js:
1669         (WI.DOMTreeContentView.prototype._updateBreakpointStatus):
1670         * UserInterface/Views/DOMTreeElement.js:
1671         (WI.DOMTreeElement.prototype.get hasBreakpoint): Added.
1672
1673 2019-03-12  Devin Rousso  <drousso@apple.com>
1674
1675         Web Inspector: Canvas: export recording as HTML
1676         https://bugs.webkit.org/show_bug.cgi?id=195311
1677         <rdar://problem/48588673>
1678
1679         Reviewed by Joseph Pecoraro.
1680
1681         * UserInterface/Models/Recording.js:
1682         (WI.Recording.prototype.async swizzle):
1683         (WI.Recording.prototype.toHTML): Added.
1684         (WI.Recording.prototype.toHTML.escapeHTML): Added.
1685         (WI.Recording.prototype.toHTML.processObject): Added.
1686         (WI.Recording.prototype.toHTML.processValue): Added.
1687
1688         * UserInterface/Views/RecordingContentView.js:
1689         (WI.RecordingContentView):
1690         (WI.RecordingContentView.prototype._exportRecording):
1691         (WI.RecordingContentView.prototype._exportReduction): Added.
1692         (WI.RecordingContentView.prototype._updateExportButton): Added.
1693         (WI.RecordingContentView.prototype._handleExportNavigationItemClicked): Added.
1694         (WI.RecordingContentView.prototype._handleRecordingProcessedAction):
1695
1696         * UserInterface/Views/CanvasOverviewContentView.js:
1697         (WI.CanvasOverviewContentView):
1698         * UserInterface/Views/HeapAllocationsTimelineView.js:
1699         (WI.HeapAllocationsTimelineView):
1700         * UserInterface/Views/HeapSnapshotContentView.js:
1701         (WI.HeapSnapshotContentView):
1702         Drive-by: s/`toolTip`/`tooltip`.
1703
1704         * Localizations/en.lproj/localizedStrings.js:
1705
1706 2019-03-12  Devin Rousso  <drousso@apple.com>
1707
1708         Web Inspector: Audit: there should be a centralized place for reusable code
1709         https://bugs.webkit.org/show_bug.cgi?id=195265
1710         <rdar://problem/47040673>
1711
1712         Reviewed by Joseph Pecoraro.
1713
1714         * UserInterface/Controllers/AuditManager.js:
1715         (WI.AuditManager.prototype.async start):
1716         (WI.AuditManager.prototype._topLevelTestForTest): Added.
1717         (WI.AuditManager.prototype._topLevelTestForTest.walk): Added.
1718
1719         * UserInterface/Models/AuditTestBase.js:
1720         (WI.AuditTestBase):
1721         (WI.AuditTestBase.prototype.async setup): Added.
1722         (WI.AuditTestBase.toJSON):
1723
1724         * UserInterface/Models/AuditTestCase.js:
1725         (WI.AuditTestCase.async.fromPayload):
1726         (WI.AuditTestCase.prototype.async run.async parseResponse):
1727         Allow additional data to be passed back to the result's `data` for testing.
1728
1729         * UserInterface/Models/AuditTestGroup.js:
1730         (WI.AuditTestGroup.async.fromPayload):
1731
1732 2019-03-12  Joseph Pecoraro  <pecoraro@apple.com>
1733
1734         Web Inspector: Timelines - Improve handling of past recordings (readonly)
1735         https://bugs.webkit.org/show_bug.cgi?id=195594
1736
1737         Reviewed by Devin Rousso.
1738
1739         * UserInterface/Views/TimelineRecordingContentView.js:
1740         (WI.TimelineRecordingContentView.prototype._clearTimeline):
1741         Don't allow clearing of a readonly recording.
1742
1743         * UserInterface/Views/TimelineTabContentView.js:
1744         (WI.TimelineTabContentView.prototype._toggleRecordingOnSpacebar):
1745         Don't do anything when viewing a readonly recording.
1746
1747         (WI.TimelineTabContentView.prototype._recordButtonClicked):
1748         Start a new recording if viewing a readonly recording.
1749
1750 2019-03-11  Joseph Pecoraro  <pecoraro@apple.com>
1751
1752         Web Inspector: REGRESSION: Network Cookies Table does not load
1753         https://bugs.webkit.org/show_bug.cgi?id=195599
1754
1755         Reviewed by Devin Rousso.
1756
1757         * UserInterface/Views/ResourceCookiesContentView.js:
1758         (WI.ResourceCookiesContentView.prototype.tableIndexForRepresentedObject):
1759         (WI.ResourceCookiesContentView.prototype.tableRepresentedObjectForIndex):
1760         Include needed delegate methods.
1761
1762 2019-03-11  Devin Rousso  <drousso@apple.com>
1763
1764         Web Inspector: use -webkit-{margin,padding}-{start,end} instead of [dir={ltr/rtl}] rules
1765         https://bugs.webkit.org/show_bug.cgi?id=195569
1766         <rdar://problem/48778727>
1767
1768         Reviewed by Matt Baker.
1769
1770         * UserInterface/Debug/UncaughtExceptionReporter.css:
1771         * UserInterface/Views/BoxModelDetailsSectionRow.css:
1772         * UserInterface/Views/BreakpointActionView.css:
1773         * UserInterface/Views/BreakpointPopoverController.css:
1774         * UserInterface/Views/CPUTimelineView.css:
1775         * UserInterface/Views/CallFrameTreeElement.css:
1776         * UserInterface/Views/CallFrameView.css:
1777         * UserInterface/Views/DOMTreeContentView.css:
1778         * UserInterface/Views/DOMTreeOutline.css:
1779         * UserInterface/Views/DashboardContainerView.css:
1780         * UserInterface/Views/DataGrid.css:
1781         * UserInterface/Views/DebuggerDashboardView.css:
1782         * UserInterface/Views/DebuggerSidebarPanel.css:
1783         * UserInterface/Views/DefaultDashboardView.css:
1784         * UserInterface/Views/DetailsSection.css:
1785         * UserInterface/Views/FilterBar.css:
1786         * UserInterface/Views/FindBanner.css:
1787         * UserInterface/Views/FontResourceContentView.css:
1788         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:
1789         * UserInterface/Views/HierarchicalPathComponent.css:
1790         * UserInterface/Views/LayerTreeDetailsSidebarPanel.css:
1791         * UserInterface/Views/Main.css:
1792         * UserInterface/Views/NetworkTableContentView.css:
1793         * UserInterface/Views/OpenResourceDialog.css:
1794         * UserInterface/Views/RecordingActionTreeElement.css:
1795         * UserInterface/Views/ScopeRadioButtonNavigationItem.css:
1796         * UserInterface/Views/SettingsTabContentView.css:
1797         * UserInterface/Views/ThreadTreeElement.css:
1798         * UserInterface/Views/Toolbar.css:
1799         * UserInterface/Views/TreeOutline.css:
1800         * UserInterface/Views/TypeTreeElement.css:
1801         * UserInterface/Views/TypeTreeView.css:
1802         * UserInterface/Views/URLBreakpointPopover.css:
1803         * UserInterface/Views/WebSocketContentView.css:
1804
1805         * UserInterface/Views/RecordingActionTreeElement.js:
1806         (WI.RecordingActionTreeElement.static _getClassNames):
1807         Replace class `.action` with `.recording-action` for better uniqueness/clarity.
1808
1809 2019-03-11  Devin Rousso  <drousso@apple.com>
1810
1811         Web Inspector: DOMDebugger: protocol error on first open
1812         https://bugs.webkit.org/show_bug.cgi?id=195248
1813         <rdar://problem/48538465>
1814
1815         Unreviewed followup of r242743 to fix test inspector/dom-debugger/dom-breakpoints.html.
1816
1817         * UserInterface/Controllers/DOMDebuggerManager.js:
1818         (WI.DOMDebuggerManager.prototype.addDOMBreakpoint):
1819         (WI.DOMDebuggerManager.prototype._resolveDOMBreakpoint):
1820         Still attempt to resolve the DOM breakpoint if it already has a `domNodeIdentifier` so that
1821         it will get added to the node's frame's DOM breakpoint map. Without this, some breakpoints
1822         might get "missed" when calling `WI.domDebuggerManager.removeDOMBreakpointsForNode`.
1823
1824 2019-03-11  Justin Fan  <justin_fan@apple.com>
1825
1826         [Web GPU] Update GPUSwapChainDescriptor, GPUSwapChain and implement GPUCanvasContext
1827         https://bugs.webkit.org/show_bug.cgi?id=194406
1828         <rdar://problem/47892466>
1829
1830         Reviewed by Myles C. Maxfield.
1831
1832         Name updates for Web GPU renaming in inspector.
1833
1834         * UserInterface/Models/Canvas.js:
1835         (WI.Canvas.displayNameForContextType):
1836
1837 2019-03-11  Joseph Pecoraro  <pecoraro@apple.com>
1838
1839         Web Inspector: Editing Timelines shows two CPU Timelines
1840         https://bugs.webkit.org/show_bug.cgi?id=195578
1841
1842         Reviewed by Devin Rousso.
1843
1844         * UserInterface/Controllers/TimelineManager.js:
1845         (WI.TimelineManager.availableTimelineTypes):
1846         The CPU Instrument is already in the default list.
1847
1848 2019-03-11  Devin Rousso  <drousso@apple.com>
1849
1850         Web Inspector: DOMDebugger: protocol error on first open
1851         https://bugs.webkit.org/show_bug.cgi?id=195248
1852         <rdar://problem/48538465>
1853
1854         Reviewed by Joseph Pecoraro.
1855
1856         Don't try to call `DOMDebugger` commands until a target has been initialized.
1857         Still attempt to resolve DOM breakpoints whenever the main resource/frame changes.
1858
1859         * UserInterface/Controllers/DOMDebuggerManager.js:
1860         (WI.DOMDebuggerManager):
1861         (WI.DOMDebuggerManager.prototype.initializeTarget): Added.
1862         (WI.DOMDebuggerManager.supportsEventBreakpoints):
1863         (WI.DOMDebuggerManager.prototype.get supported):
1864         (WI.DOMDebuggerManager.prototype.addDOMBreakpoint):
1865         (WI.DOMDebuggerManager.prototype.removeDOMBreakpoint):
1866         (WI.DOMDebuggerManager.prototype.addEventBreakpoint):
1867         (WI.DOMDebuggerManager.prototype.removeEventBreakpoint):
1868         (WI.DOMDebuggerManager.prototype.addURLBreakpoint):
1869         (WI.DOMDebuggerManager.prototype.removeURLBreakpoint):
1870         (WI.DOMDebuggerManager.prototype._speculativelyResolveDOMBreakpointsForURL): Added.
1871         (WI.DOMDebuggerManager.prototype._resolveDOMBreakpoint):
1872         (WI.DOMDebuggerManager.prototype._updateDOMBreakpoint):
1873         (WI.DOMDebuggerManager.prototype._updateEventBreakpoint):
1874         (WI.DOMDebuggerManager.prototype._updateURLBreakpoint):
1875         (WI.DOMDebuggerManager.prototype._saveDOMBreakpoints):
1876         (WI.DOMDebuggerManager.prototype._handleDOMBreakpointDisabledStateChanged):
1877         (WI.DOMDebuggerManager.prototype._handleEventBreakpointDisabledStateChanged):
1878         (WI.DOMDebuggerManager.prototype._handleURLBreakpointDisabledStateChanged):
1879         (WI.DOMDebuggerManager.prototype._mainFrameDidChange):
1880         (WI.DOMDebuggerManager.prototype._mainResourceDidChange):
1881         (WI.DOMDebuggerManager.prototype.removeEventBreakpoint.breakpointRemoved): Deleted.
1882         (WI.DOMDebuggerManager.prototype._speculativelyResolveBreakpoints): Deleted.
1883         (WI.DOMDebuggerManager.prototype._updateDOMBreakpoint.breakpointUpdated): Deleted.
1884         (WI.DOMDebuggerManager.prototype._resolveEventBreakpoint): Deleted.
1885         (WI.DOMDebuggerManager.prototype._resolveURLBreakpoint): Deleted.
1886
1887         * UserInterface/Base/Multimap.js: Added.
1888         (Multimap):
1889         (Multimap.prototype.get):
1890         (Multimap.prototype.add):
1891         (Multimap.prototype.delete):
1892         (Multimap.prototype.clear):
1893         (Multimap.prototype.keys):
1894         (Multimap.prototype.*values):
1895         (Multimap.prototype.*[Symbol.iterator]):
1896         (Multimap.prototype.toJSON):
1897         * .eslintrc:
1898         * UserInterface/Main.html:
1899         * UserInterface/Test.html:
1900         Helper data structure for managing Maps of Sets (e.g. all DOM breakpoints for a URL).
1901
1902 2019-03-11  Joseph Pecoraro  <pecoraro@apple.com>
1903
1904         Web Inspector: CPU Usage Timeline - Enable by default
1905         https://bugs.webkit.org/show_bug.cgi?id=195471
1906
1907         Reviewed by Devin Rousso.
1908
1909         Remove experimental setting and include the CPU timeline in the
1910         default set of timelines.
1911
1912         * UserInterface/Base/Setting.js:
1913         * UserInterface/Controllers/TimelineManager.js:
1914         (WI.TimelineManager.defaultTimelineTypes):
1915         * UserInterface/Main.html:
1916         * UserInterface/Views/CPUTimelineOverviewGraph.css:
1917         (.timeline-overview-graph.cpu > .stacked-column-chart > svg > rect.selected):
1918         (.timeline-overview-graph.cpu > .column-chart > svg > rect): Deleted.
1919         (body[dir=rtl] .timeline-overview-graph.cpu > .column-chart): Deleted.
1920         * UserInterface/Views/CPUTimelineOverviewGraph.js:
1921         (WI.CPUTimelineOverviewGraph):
1922         (WI.CPUTimelineOverviewGraph.prototype.layout):
1923         * UserInterface/Views/ContentView.js:
1924         (WI.ContentView.createFromRepresentedObject):
1925         * UserInterface/Views/LegacyCPUTimelineView.css: Removed.
1926         * UserInterface/Views/LegacyCPUTimelineView.js: Removed.
1927         * UserInterface/Views/SettingsTabContentView.js:
1928         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1929         * UserInterface/Views/Variables.css:
1930         (:root):
1931
1932 2019-03-11  Joseph Pecoraro  <pecoraro@apple.com>
1933
1934         Web Inspector: CPU Usage Timeline - Better Thread chart layout values
1935         https://bugs.webkit.org/show_bug.cgi?id=195547
1936
1937         Reviewed by Devin Rousso.
1938
1939         * UserInterface/Views/CPUTimelineView.js:
1940         (WI.CPUTimelineView.prototype.layout.bestThreadLayoutMax):
1941         (WI.CPUTimelineView.prototype.layout.layoutView):
1942         (WI.CPUTimelineView.prototype._showGraphOverlay):
1943         Include a separate layoutMax for the combined view and a thread layoutMax
1944         for the thread groups.
1945
1946 2019-03-11  Joseph Pecoraro  <pecoraro@apple.com>
1947
1948         Web Inspector: CPU Usage Timeline - Add legend and graph hover effects
1949         https://bugs.webkit.org/show_bug.cgi?id=195390
1950
1951         Reviewed by Devin Rousso.
1952
1953         * Localizations/en.lproj/localizedStrings.js:
1954         New strings for the legends.
1955
1956         * UserInterface/Main.html:
1957         Combined files.
1958
1959         * UserInterface/Views/Variables.css:
1960         (:root):
1961         (@media (prefers-color-scheme: dark)):
1962         Tweaked colors, including individual stroke and fill colors for each CPU section.
1963
1964         * UserInterface/Views/CPUTimelineOverviewGraph.css:
1965         (.timeline-overview-graph.cpu > .stacked-column-chart > svg > rect.total-usage):
1966         (.timeline-overview-graph.cpu > .stacked-column-chart > svg > rect.main-thread-usage):
1967         (.timeline-overview-graph.cpu > .stacked-column-chart > svg > rect.worker-thread-usage):
1968         Updated colors.
1969
1970         * UserInterface/Views/CPUUsageCombinedView.css: Renamed from Source/WebInspectorUI/UserInterface/Views/CPUUsageStackedView.css.
1971         (.cpu-usage-combined-view > .details > .legend-container):
1972         (.cpu-usage-combined-view > .details > .legend-container > .row):
1973         (.cpu-usage-combined-view > .details > .legend-container > .row + .row):
1974         (.cpu-usage-combined-view > .details > .legend-container > .row > .swatch):
1975         * UserInterface/Views/CPUUsageCombinedView.js: Renamed from Source/WebInspectorUI/UserInterface/Views/CPUUsageStackedView.js.
1976         (WI.CPUUsageCombinedView.appendLegendRow):
1977         (WI.CPUUsageCombinedView):
1978         (WI.CPUUsageCombinedView.prototype.get graphElement):
1979         (WI.CPUUsageCombinedView.prototype.get chart):
1980         (WI.CPUUsageCombinedView.prototype.get rangeChart):
1981         (WI.CPUUsageCombinedView.prototype.clear):
1982         (WI.CPUUsageCombinedView.prototype.updateChart):
1983         (WI.CPUUsageCombinedView.prototype.updateMainThreadIndicator):
1984         (WI.CPUUsageCombinedView.prototype.clearLegend):
1985         (WI.CPUUsageCombinedView.prototype.updateLegend):
1986         (WI.CPUUsageCombinedView.prototype._updateDetails):
1987         * UserInterface/Views/CPUUsageIndicatorView.css: Removed.
1988         * UserInterface/Views/CPUUsageIndicatorView.js: Removed.
1989         Combined the Indicator and StackedAreaChart into a single view
1990         that share a left details section.
1991
1992         * UserInterface/Views/CPUUsageView.js:
1993         (WI.CPUUsageView):
1994         (WI.CPUUsageView.prototype.get graphElement):
1995         (WI.CPUUsageView.prototype.clear):
1996         (WI.CPUUsageView.prototype.updateChart):
1997         (WI.CPUUsageView.prototype.clearLegend):
1998         (WI.CPUUsageView.prototype.updateLegend):
1999         (WI.CPUUsageView.prototype._updateDetails):
2000         Include a legend in the left details section.
2001
2002         * UserInterface/Views/AreaChart.js:
2003         (WI.AreaChart):
2004         (WI.AreaChart.prototype.addPointMarker):
2005         (WI.AreaChart.prototype.clearPointMarkers):
2006         (WI.AreaChart.prototype.clear):
2007         (WI.AreaChart.prototype.layout):
2008         * UserInterface/Views/StackedAreaChart.js:
2009         (WI.StackedAreaChart):
2010         (WI.StackedAreaChart.prototype.addPointMarker):
2011         (WI.StackedAreaChart.prototype.clearPointMarkers):
2012         (WI.StackedAreaChart.prototype.clear):
2013         (WI.StackedAreaChart.prototype.layout):
2014         Add point markers for the area charts.
2015
2016         * UserInterface/Views/CPUTimelineView.css:
2017         * UserInterface/Views/CPUTimelineView.js:
2018         (WI.CPUTimelineView):
2019         (WI.CPUTimelineView.prototype.get cpuUsageViewHeight):
2020         (WI.CPUTimelineView.prototype.clear):
2021         (WI.CPUTimelineView.prototype.initialLayout.appendLegendRow):
2022         (WI.CPUTimelineView.prototype.initialLayout):
2023         (WI.CPUTimelineView.prototype.layout):
2024         (WI.CPUTimelineView.prototype._graphPositionForMouseEvent):
2025         (WI.CPUTimelineView.prototype._handleMouseClick):
2026         (WI.CPUTimelineView.prototype._handleGraphMouseMove):
2027         (WI.CPUTimelineView.prototype._showGraphOverlayNearTo):
2028         (WI.CPUTimelineView.prototype._updateGraphOverlay):
2029         (WI.CPUTimelineView.prototype._showGraphOverlay.xScale):
2030         (WI.CPUTimelineView.prototype._showGraphOverlay.yScale):
2031         (WI.CPUTimelineView.prototype._showGraphOverlay.addOverlayPoint):
2032         (WI.CPUTimelineView.prototype._showGraphOverlay):
2033         (WI.CPUTimelineView.prototype._clearOverlayMarkers.clearGraphOverlayElement):
2034         (WI.CPUTimelineView.prototype._clearOverlayMarkers):
2035         (WI.CPUTimelineView.prototype._hideGraphOverlay):
2036         Include graph overlay markers.
2037
2038 2019-03-11  Devin Rousso  <drousso@apple.com>
2039
2040         Web Inspector: eliminate manual syncing of numeric constants used by JavaScript and CSS
2041         https://bugs.webkit.org/show_bug.cgi?id=194883
2042         <rdar://problem/48257785>
2043
2044         Reviewed by Joseph Pecoraro.
2045
2046         * UserInterface/Views/CanvasOverviewContentView.js:
2047         (WI.CanvasOverviewContentView):
2048         (WI.CanvasOverviewContentView.static get recordingAutoCaptureInputMargin): Added.
2049         (WI.CanvasOverviewContentView.prototype._updateRecordingAutoCaptureInputElementSize):
2050         * UserInterface/Views/CanvasOverviewContentView.css:
2051         (.navigation-bar > .item.canvas-recording-auto-capture > label > input):
2052
2053         * UserInterface/Views/MemoryTimelineView.js:
2054         (WI.MemoryTimelineView.static get memoryCategoryViewHeight): Added.
2055         (WI.MemoryTimelineView.prototype.initialLayout): Added.
2056         (WI.MemoryTimelineView.prototype.layout):
2057         * UserInterface/Views/MemoryCategoryView.css:
2058         (.memory-category-view):
2059
2060         * UserInterface/Views/NetworkTableContentView.js:
2061         (WI.NetworkTableContentView.static get nodeWaterfallDOMEventSize): Added.
2062         (WI.NetworkTableContentView.prototype.initialLayout):
2063         * UserInterface/Views/NetworkTableContentView.css:
2064         (.content-view.network .network-table): Deleted.
2065
2066         * UserInterface/Views/TreeOutline.js:
2067         (WI.TreeOutline._generateStyleRulesIfNeeded):
2068         * UserInterface/Views/TreeOutline.css:
2069         (.tree-outline, .tree-outline .children):
2070         (.tree-outline .item):
2071
2072         * UserInterface/Controllers/CanvasManager.js:
2073         (WI.CanvasManager.supportsRecordingAutoCapture):
2074         Drive-by: fix usage of InspectorBackend.domains.{CanvasAgent => Canvas}
2075
2076 2019-03-11  Nikita Vasilyev  <nvasilyev@apple.com>
2077
2078         REGRESSION(r242622): Web Inspector: Fix asserts "Overridden property is missing overridingProperty"
2079         https://bugs.webkit.org/show_bug.cgi?id=195515
2080         <rdar://problem/48737315>
2081
2082         Reviewed by Matt Baker.
2083
2084         * UserInterface/Views/SpreadsheetStyleProperty.js:
2085         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
2086
2087 2019-03-07  Nikita Vasilyev  <nvasilyev@apple.com>
2088
2089         Web Inspector: Styles: overridden CSS property should have go-to button to jump to effective property
2090         https://bugs.webkit.org/show_bug.cgi?id=185930
2091         <rdar://problem/40506252>
2092
2093         Reviewed by Matt Baker.
2094
2095         Introduce a new experimental jump to effective property button. The button is a small arrow button
2096         next to an overridden CSS property. Clicking the button scrolls to the effective CSS property and
2097         selects it.
2098
2099         * Localizations/en.lproj/localizedStrings.js:
2100         * UserInterface/Base/Setting.js:
2101         * UserInterface/Models/CSSProperty.js:
2102         (WI.CSSProperty):
2103         (WI.CSSProperty.prototype.update):
2104         (WI.CSSProperty.prototype.get overridingProperty):
2105         (WI.CSSProperty.prototype.set overridingProperty):
2106         * UserInterface/Models/DOMNodeStyles.js:
2107         (WI.DOMNodeStyles.prototype._markOverriddenProperties):
2108         * UserInterface/Views/SettingsTabContentView.js:
2109         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
2110         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2111         (.spreadsheet-style-declaration-editor .property.overridden .select-effective-property):
2112         (.spreadsheet-style-declaration-editor .property.overridden:hover .select-effective-property,):
2113         (.spreadsheet-style-declaration-editor .property.overridden:hover .select-effective-property::after,):
2114         (@media (prefers-color-scheme: dark)):
2115         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
2116         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertySelectByProperty):
2117         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
2118         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetCSSStyleDeclarationEditorSelectProperty):
2119         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
2120         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.spreadsheetCSSStyleDeclarationSectionSelectProperty):
2121         * UserInterface/Views/SpreadsheetStyleProperty.js:
2122         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
2123
2124 2019-03-07  Devin Rousso  <drousso@apple.com>
2125
2126         Web Inspector: Protocol: add type checking when commands are called via invoke
2127         https://bugs.webkit.org/show_bug.cgi?id=195310
2128         <rdar://problem/48588679>
2129
2130         Reviewed by Joseph Pecoraro.
2131
2132         * UserInterface/Protocol/InspectorBackend.js:
2133         (InspectorBackend.Command.prototype.invoke.deliverFailure): Added.
2134         (InspectorBackend.Command.prototype.invoke):
2135         (InspectorBackend.Command.prototype._invokeWithArguments):
2136
2137 2019-03-07  Devin Rousso  <drousso@apple.com>
2138
2139         Web Inspector: REGRESSION(r242118): WI.ScopeBar missing background
2140         https://bugs.webkit.org/show_bug.cgi?id=195299
2141
2142         Reviewed by Joseph Pecoraro.
2143
2144         Rework the way `color`, `background-color`, and `border-color` are set for `WI.ScopeBar` to
2145         use CSS variables instead. Divides the variables into three categories:
2146          - default: these are the values that the `WI.ScopeBar` would use normally
2147          - override: these are values that take precidence over the default (e.g. set by other elements)
2148             - falls back to default when no value is set
2149          - actual: this is the resulting value that will be used when displaying
2150             - this way, other elements can "mirror" the styling of the `WI.ScopeBar`
2151
2152         * UserInterface/Views/ScopeBar.css:
2153         (.scope-bar):
2154         (.scope-bar > li):
2155         (.scope-bar > li::before):
2156         (.scope-bar > li:matches(.selected, :hover)):
2157         (.scope-bar > li:not(.selected):hover::after):
2158         (.scope-bar > li.selected:active::after):
2159         (.scope-bar > li.multiple > select):
2160         (body[dir=ltr] .scope-bar > li.multiple > select):
2161         (body[dir=rtl] .scope-bar > li.multiple > select):
2162         (.scope-bar > li.multiple:not(.selected) > select): Added.
2163         (.scope-bar > li.multiple > .arrows):
2164         (.scope-bar > li::before): Deleted.
2165         (.scope-bar.default-item-selected > li.multiple.selected::before): Deleted.
2166         (.scope-bar > li:matches(.selected, :hover)::before): Deleted.
2167         (.scope-bar > li.selected:active::before): Deleted.
2168         (.scope-bar > li.multiple.selected > select): Deleted.
2169         (body[dir=ltr] .scope-bar > li.multiple > .arrows): Deleted.
2170         (body[dir=rtl] .scope-bar > li.multiple > .arrows): Deleted.
2171         (.scope-bar > li.multiple:matches(.selected, :hover, :active) > .arrows): Deleted.
2172         (.scope-bar > li:matches(.selected, :active)): Deleted.
2173         (@media (prefers-color-scheme: dark)): Deleted.
2174         Switch to using `::after` since `::before` is more commonly used.
2175
2176         * UserInterface/Views/MultipleScopeBarItem.js:
2177         (WI.MultipleScopeBarItem.prototype._handleMouseDown):
2178         Drive-by: fix the <select> alignment by re-firing the "mousedown" event on it.
2179
2180         * UserInterface/Views/AuditTestGroupContentView.js:
2181         (WI.AuditTestGroupContentView.prototype.layout):
2182         * UserInterface/Views/AuditTestGroupContentView.css:
2183         (.content-view.audit-test-group > header > nav > .scope-bar > li):
2184         (.content-view.audit-test-group > header > nav > .scope-bar > li:not(:hover, .selected)):
2185         (.content-view.audit-test-group > header > nav > .scope-bar > li > img): Added.
2186         (.content-view.audit-test-group > header > nav > .scope-bar > li.pass > img): Added.
2187         (.content-view.audit-test-group > header > nav > .scope-bar > li.warn > img): Added.
2188         (.content-view.audit-test-group > header > nav > .scope-bar > li.fail > img): Added.
2189         (.content-view.audit-test-group > header > nav > .scope-bar > li.error > img): Added.
2190         (.content-view.audit-test-group > header > nav > .scope-bar > li.unsupported > img): Added.
2191         (.content-view.audit-test-group > section > .audit-test-case:first-child, .content-view.audit-test-group > section > .audit-test-case.filtered ~ .audit-test-case:not(.filtered), .content-view.audit-test-group > section > .audit-test-group + .audit-test-case, .content-view.audit-test-group > section > .audit-test-case + .audit-test-group): Added.
2192         (.content-view.audit-test-group > section > .audit-test-case:not(.filtered) ~ .audit-test-case:not(.filtered)): Added.
2193         (.content-view.audit-test-group > header > nav > .scope-bar > li::before): Deleted.
2194         (.content-view.audit-test-group > header > nav > .scope-bar > li.pass::before): Deleted.
2195         (.content-view.audit-test-group > header > nav > .scope-bar > li.warn::before): Deleted.
2196         (.content-view.audit-test-group > header > nav > .scope-bar > li.fail::before): Deleted.
2197         (.content-view.audit-test-group > header > nav > .scope-bar > li.error::before): Deleted.
2198         (.content-view.audit-test-group > header > nav > .scope-bar > li.unsupported::before): Deleted.
2199         (.content-view.audit-test-group > section > .audit-test-case:first-child, .content-view.audit-test-group > section > .audit-test-group + .audit-test-case, .content-view.audit-test-group > section > .audit-test-case + .audit-test-group): Deleted.
2200         Replace the `::before` image with an actual `<img>` now that the `WI.ScopeBar` itself uses
2201         a pseudo-element for the background styling.
2202
2203         * UserInterface/Views/LogContentView.js:
2204         (WI.LogContentView):
2205         * UserInterface/Views/LogContentView.css:
2206         (.log-scope-bar > li:not(.unread) > .indicator): Added.
2207         (.log-scope-bar > li.unread > .indicator): Added.
2208         (.log-scope-bar > li.unread:hover > .indicator): Added.
2209         (.log-scope-bar > li.unread.errors > .indicator): Added.
2210         (.log-scope-bar > li.unread.warnings > .indicator): Added.
2211         (.log-scope-bar > li.unread.logs > .indicator): Added.
2212         (.log-scope-bar > li.unread::before): Deleted.
2213         (body[dir=ltr] .log-scope-bar > li.unread::before): Deleted.
2214         (body[dir=rtl] .log-scope-bar > li.unread::before): Deleted.
2215         (.log-scope-bar > li.unread:hover::before): Deleted.
2216         (.log-scope-bar > li.unread.errors::before): Deleted.
2217         (.log-scope-bar > li.unread.warnings::before): Deleted.
2218         (.log-scope-bar > li.unread.logs::before): Deleted.
2219         Replace the `::before` unread indicator with an actual `<div>` now that the `WI.ScopeBar`
2220         itself uses a pseudo-element for the background styling.
2221
2222         * UserInterface/Views/TimelineRecordingContentView.css:
2223         (.content-view.timeline-recording > .content-browser > .navigation-bar > .item.scope-bar.default-item-selected):
2224         (.content-view.timeline-recording > .content-browser > .navigation-bar > .item.scope-bar.default-item-selected > .multiple): Deleted.
2225         (.content-view.timeline-recording > .content-browser > .navigation-bar > .item.scope-bar.default-item-selected > .multiple .arrows): Deleted.
2226
2227         * UserInterface/Views/CanvasSidebarPanel.js:
2228         (WI.CanvasSidebarPanel.prototype._updateRecordingScopeBar):
2229         Drive-by: fix typo.
2230
2231 2019-03-07  Devin Rousso  <drousso@apple.com>
2232
2233         Web Inspector: CSS: there should be a way to inline-replace a variable with it's value
2234         https://bugs.webkit.org/show_bug.cgi?id=195335
2235
2236         Reviewed by Joseph Pecoraro.
2237
2238         * UserInterface/Views/InlineSwatch.js:
2239         (WI.InlineSwatch):
2240         (WI.InlineSwatch.prototype.didDismissPopover):
2241         (WI.InlineSwatch.prototype._swatchElementClicked):
2242         (WI.InlineSwatch.prototype._swatchElementClicked.optionsForType): Added.
2243         Shift-clicking a variable swatch replaces the text with the variable's value.
2244         Drive-by: try to create a readonly swatch for the variable's value (e.g. a color indicator).
2245
2246         * UserInterface/Views/SpreadsheetStyleProperty.js:
2247         (WI.SpreadsheetStyleProperty.prototype._createInlineSwatch):
2248         If the value of a variable swatch changes, re-render the value.
2249
2250         * UserInterface/Views/CodeMirrorTextMarkers.js:
2251         (createCodeMirrorTextMarkers):
2252         (createCodeMirrorColorTextMarkers):
2253         (createCodeMirrorGradientTextMarkers):
2254         (createCodeMirrorBezierTextMarkers):
2255         (createCodeMirrorSpringTextMarkers):
2256         Refactor function parameters for more flexibility.
2257
2258         * Localizations/en.lproj/localizedStrings.js:
2259
2260 2019-03-06  Devin Rousso  <drousso@apple.com>
2261
2262         Web Inspector: Elements: highlight the node when hovering event listeners sorted by node
2263         https://bugs.webkit.org/show_bug.cgi?id=195368
2264
2265         Reviewed by Joseph Pecoraro.
2266
2267         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
2268         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByNode):
2269
2270 2019-03-06  Matt Baker  <mattbaker@apple.com>
2271
2272         Web Inspector: system accent color follow-ups
2273         https://bugs.webkit.org/show_bug.cgi?id=195190
2274
2275         Reviewed by Devin Rousso.
2276
2277         * UserInterface/Views/ButtonToolbarItem.css:
2278         (.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated)):
2279         (@media (prefers-color-scheme: dark)):
2280         (.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated)): Deleted.
2281         Drop pressed toolbar button style. It's extremely subtle and not worth the hassle.
2282
2283         * UserInterface/Views/LogContentView.css:
2284         (.console-messages:focus .console-item.selected::after):
2285         (@media (prefers-color-scheme: dark)):
2286
2287         * UserInterface/Views/ScopeBar.css:
2288         (.scope-bar > li.selected:active::before):
2289
2290         * UserInterface/Views/TimelineRecordBar.css:
2291         (.timeline-record-bar.selected > .segment):
2292
2293 2019-03-06  Matt Baker  <mattbaker@apple.com>
2294
2295         REGRESSION: Elements tab: Uncaught Exception: No node with given id found
2296         https://bugs.webkit.org/show_bug.cgi?id=194299
2297         <rdar://problem/47828647>
2298
2299         Reviewed by Devin Rousso.
2300
2301         When removing the selection, TreeOutline subclasses should have more
2302         control over which item becomes selected after the selection is removed.
2303         DOMTreeOutline should track the items that are being removed, and prevent
2304         them or their descendants from becoming selected.
2305
2306         * UserInterface/Views/DOMTreeOutline.js:
2307         (WI.DOMTreeOutline):
2308         (WI.DOMTreeOutline.prototype.ondelete):
2309         (WI.DOMTreeOutline.prototype.canSelectTreeElement):
2310
2311         * UserInterface/Views/TreeOutline.js:
2312         (WI.TreeOutline.prototype.selectionControllerLastSelectableItem):
2313         (WI.TreeOutline.prototype.selectionControllerPreviousSelectableItem):
2314         (WI.TreeOutline.prototype.selectionControllerNextSelectableItem):
2315         (WI.TreeOutline.prototype.canSelectTreeElement):
2316
2317 2019-03-06  Joseph Pecoraro  <pecoraro@apple.com>
2318
2319         Web Inspector: CPU Usage Timeline - Allow clicking a bar in the overview to select a tight time range around it
2320         https://bugs.webkit.org/show_bug.cgi?id=195321
2321
2322         Reviewed by Devin Rousso.
2323
2324         * UserInterface/Models/Timeline.js:
2325         (WI.Timeline.prototype.closestRecordTo):
2326         Helper to get the closest record to a timestamp.
2327
2328         * UserInterface/Views/CPUTimelineOverviewGraph.css:
2329         (.timeline-overview-graph.cpu > .stacked-column-chart):
2330         (.timeline-overview-graph.cpu > .stacked-column-chart > svg > rect.selected):
2331         Style a selected record with the active color.
2332
2333         * UserInterface/Views/CPUTimelineOverviewGraph.js:
2334         (WI.CPUTimelineOverviewGraph):
2335         (WI.CPUTimelineOverviewGraph.prototype.get samplingRatePerSecond):
2336         (WI.CPUTimelineOverviewGraph.prototype.reset):
2337         (WI.CPUTimelineOverviewGraph.prototype.layout):
2338         (WI.CPUTimelineOverviewGraph.prototype.updateSelectedRecord):
2339         (WI.CPUTimelineOverviewGraph.prototype._graphPositionForMouseEvent):
2340         (WI.CPUTimelineOverviewGraph.prototype._handleGraphMouseClick):
2341         A click in the overview which hits a rect triggers a selection of
2342         the associated timeline record.
2343
2344         * UserInterface/Views/StackedColumnChart.js:
2345         (WI.StackedColumnChart.prototype.addColumnSet):
2346         (WI.StackedColumnChart.prototype.layout):
2347         Allow setting an additional class name with a column set.
2348         It will set the class name on each rect in that column.
2349
2350         * UserInterface/Views/TimelineOverview.js:
2351         (WI.TimelineOverview.prototype._recordSelected):
2352         When selecting a CPU record, make a selection range of 2 neighboring
2353         columns in each direction.
2354
2355         * UserInterface/Views/TimelineRuler.js:
2356         (WI.TimelineRuler.prototype._handleClick):
2357         When a sub-element has handled the click stop further event propagation.
2358
2359         * UserInterface/Views/TimelineOverviewGraph.js:
2360         (WI.TimelineOverviewGraph.prototype.get selected):
2361         Drive-by style fix.
2362
2363 2019-03-06  Joseph Pecoraro  <pecoraro@apple.com>
2364
2365         Web Inspector: TimelineOverview clicks do not always behave as expected
2366         https://bugs.webkit.org/show_bug.cgi?id=195319
2367
2368         Reviewed by Devin Rousso.
2369
2370         * UserInterface/Views/TimelineRuler.js:
2371         (WI.TimelineRuler.prototype._shouldIgnoreMicroMovement):
2372         (WI.TimelineRuler.prototype._handleMouseDown):
2373         (WI.TimelineRuler.prototype._handleMouseMove):
2374         Ignore moves that haven't gone more than 4px. Once the threshold is
2375         passed allow all moves. This improves the click behavior since
2376         previously click would never re-dispatch if there was any movement.
2377
2378 2019-03-06  Joseph Pecoraro  <pecoraro@apple.com>
2379
2380         Web Inspector: CPU Usage Timeline - Statistics and Sources sections
2381         https://bugs.webkit.org/show_bug.cgi?id=195202
2382
2383         Reviewed by Devin Rousso.
2384
2385         * Localizations/en.lproj/localizedStrings.js:
2386         New strings.
2387
2388         * UserInterface/Base/Utilities.js:
2389         (Map.prototype.getOrInitialize):
2390         Helper to get and if not found initialize with a value.
2391
2392         * UserInterface/Views/CPUTimelineView.css:
2393         (.timeline-view.cpu > .content > .overview > .chart > .container.stats):
2394         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table):
2395         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table > tr > th):
2396         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table > tr > td.number):
2397         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table > tr > td.label):
2398         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table .show-more):
2399         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table .filter):
2400         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table .filter:hover):
2401         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table .active):
2402         (.timeline-view.cpu > .content > .overview > .chart > .container.stats > table .active + .active):
2403         (@media (prefers-color-scheme: dark)):
2404         Colors for the statistics sections.
2405
2406         * UserInterface/Views/CPUTimelineView.js:
2407         (WI.CPUTimelineView):
2408         (WI.CPUTimelineView.prototype.reset):
2409         (WI.CPUTimelineView.prototype.clear):
2410         (WI.CPUTimelineView.prototype._clearStatistics):
2411         (WI.CPUTimelineView.prototype._clearSources):
2412         Updates for additional sections.
2413         Include a cache of the statisiticsData so we can relayout parts of the UI and
2414         avoid an entire UI update.
2415
2416         (WI.CPUTimelineView.prototype.initialLayout):
2417         (WI.CPUTimelineView.prototype._layoutBreakdownChart):
2418         (WI.CPUTimelineView.prototype._layoutStatisticsAndSources):
2419         (WI.CPUTimelineView.prototype._layoutStatisticsSection.createEllipsisElement):
2420         (WI.CPUTimelineView.prototype._layoutStatisticsSection):
2421         (WI.CPUTimelineView.prototype._layoutSourcesSection.firstNonNativeCallFrame):
2422         (WI.CPUTimelineView.prototype._layoutSourcesSection.keyForSourceCodeLocation):
2423         (WI.CPUTimelineView.prototype._layoutSourcesSection.labelForLocation):
2424         (WI.CPUTimelineView.prototype._layoutSourcesSection.createEllipsisElement):
2425         (WI.CPUTimelineView.prototype._layoutSourcesSection):
2426         Extract layouts into helper methods to avoid an enormous layout method.
2427
2428         (WI.CPUTimelineView.prototype._computeSamplingData.incrementTypeCount):
2429         (WI.CPUTimelineView.prototype._computeSamplingData):
2430         Compute additional data when going through script events.
2431
2432         (WI.CPUTimelineView.prototype._resetSourcesFilters):
2433         (WI.CPUTimelineView.prototype._addSourcesFilter):
2434         (WI.CPUTimelineView.prototype._removeSourcesFilter):
2435         (WI.CPUTimelineView.prototype._updateSourcesFilters):
2436         Helpers for updating the source filters.
2437
2438         (WI.CPUTimelineView.prototype._createTableRow):
2439         (WI.CPUTimelineView.prototype._insertTableRow):
2440         Helpers for creating rows in the statistics / sources tables.
2441
2442 2019-03-06  Joseph Pecoraro  <pecoraro@apple.com>
2443
2444         Web Inspector: Simplify chart <rect>s with x/y attributes instead of transform(x, y)
2445         https://bugs.webkit.org/show_bug.cgi?id=195352
2446
2447         Reviewed by Matt Baker.
2448
2449         * UserInterface/Views/ColumnChart.js:
2450         (WI.ColumnChart.prototype.layout):
2451         (WI.ColumnChart):
2452         * UserInterface/Views/RangeChart.js:
2453         (WI.RangeChart.prototype.layout):
2454         (WI.RangeChart):
2455         * UserInterface/Views/StackedColumnChart.js:
2456         (WI.StackedColumnChart.prototype.layout):
2457         (WI.StackedColumnChart):
2458
2459 2019-03-06  Devin Rousso  <drousso@apple.com>
2460
2461         Web Inspector: CSS Changes: only show changes for the given node
2462         https://bugs.webkit.org/show_bug.cgi?id=194608
2463         <rdar://problem/48050206>
2464
2465         Reviewed by Timothy Hatcher.
2466
2467         * UserInterface/Views/ChangesDetailsSidebarPanel.js:
2468         (WI.ChangesDetailsSidebarPanel.prototype.inspect):
2469         (WI.ChangesDetailsSidebarPanel.prototype.supportsDOMNode):
2470         (WI.ChangesDetailsSidebarPanel.prototype.layout):
2471         Make this panel a subclass of `WI.DOMDetailsSidebarPanel` so it has access to the selected
2472         DOM node in the Elements tab.
2473
2474         * UserInterface/Base/Setting.js:
2475         * UserInterface/Views/SettingsTabContentView.js:
2476         (WI.SettingsTabContentView.prototype._createGeneralSettingsView):
2477         Create new general setting for controlling this change.
2478
2479         * Localizations/en.lproj/localizedStrings.js:
2480
2481 2019-03-06  Devin Rousso  <drousso@apple.com>
2482
2483         Web Inspector: Canvas: color swatches aren't shown for valid inputs with leading/trailing whitespace
2484         https://bugs.webkit.org/show_bug.cgi?id=195298
2485
2486         Reviewed by Timothy Hatcher.
2487
2488         * UserInterface/Views/RecordingActionTreeElement.js:
2489         (WI.RecordingActionTreeElement._generateDOM):
2490         (WI.RecordingActionTreeElement._createSwatchForColorParameters):
2491         Trim the color string since it can be an arbitrary string, seeing as it is captured before
2492         the <canvas> has a chance to parse/fix it.
2493
2494 2019-03-05  Joseph Pecoraro  <pecoraro@apple.com>
2495
2496         Web Inspector: recordsInTimeRange sometimes does not get the expected record when includeRecordBeforeStart
2497         https://bugs.webkit.org/show_bug.cgi?id=195317
2498
2499         Reviewed by Devin Rousso.
2500
2501         * UserInterface/Models/Timeline.js:
2502         (WI.Timeline.prototype.recordsOverlappingTimeRange):
2503
2504 2019-03-05  Devin Rousso  <drousso@apple.com>
2505
2506         Web Inspector: Canvas: remove event listeners once a recording is ready
2507         https://bugs.webkit.org/show_bug.cgi?id=195324
2508
2509         Reviewed by Matt Baker.
2510
2511         * UserInterface/Models/Recording.js:
2512         (WI.Recording):
2513         (WI.Recording.prototype.async swizzle):
2514         (WI.Recording.prototype.async _process):
2515
2516         * UserInterface/Views/RecordingActionTreeElement.js:
2517         (WI.RecordingActionTreeElement):
2518         (WI.RecordingActionTreeElement.prototype._handleValidityChanged):
2519
2520         * UserInterface/Views/CanvasSidebarPanel.js:
2521         (WI.CanvasSidebarPanel.prototype.set recording):
2522         (WI.CanvasSidebarPanel.prototype._handleRecordingProcessedAction):
2523
2524         * UserInterface/Views/RecordingContentView.js:
2525         (WI.RecordingContentView.prototype.initialLayout):
2526         (WI.RecordingContentView.prototype._handleRecordingProcessedAction):
2527
2528 2019-03-05  Joseph Pecoraro  <pecoraro@apple.com>
2529
2530         Web Inspector: Attempting to select records in the bottom 16px of the timeline overview graph fails
2531         https://bugs.webkit.org/show_bug.cgi?id=195318
2532
2533         Reviewed by Devin Rousso.
2534
2535         The bottom few pixels of the overview are reserved for the scroll-container
2536         which may show a scrollbar if the overview needs to scroll. When the scrollbars
2537         are not visible we can allow pointer events to click through the invisible
2538         scroll-container and allow record selection.
2539
2540         * UserInterface/Views/TimelineOverview.css:
2541         (.timeline-overview:not(.has-scrollbar) > .scroll-container):
2542         * UserInterface/Views/TimelineOverview.js:
2543         (WI.TimelineOverview.prototype._handleScrollEvent):
2544         (WI.TimelineOverview.prototype._handleWheelEvent):
2545         (WI.TimelineOverview._handleGestureStart):
2546
2547 2019-03-05  Devin Rousso  <drousso@apple.com>
2548
2549         Web Inspector: iPod user agent UIString should have a lowercase "T"
2550         https://bugs.webkit.org/show_bug.cgi?id=195312
2551         <rdar://problem/48586853>
2552
2553         Reviewed by Matt Baker.
2554
2555         * UserInterface/Base/Main.js:
2556         (WI._handleDeviceSettingsToolbarButtonClicked):
2557
2558 2019-03-05  Joseph Pecoraro  <pecoraro@apple.com>
2559
2560         Web Inspector: CPU Usage Timeline - Adjust sizes in timeline overview
2561         https://bugs.webkit.org/show_bug.cgi?id=195313
2562
2563         Reviewed by Devin Rousso.
2564
2565         Reduce the height slightly to save some precious vertical space.
2566         Also increase the size of the minimum bar height so that it doesn't
2567         look like there are no events when there is low CPU.
2568
2569         * UserInterface/Views/CPUTimelineOverviewGraph.css:
2570         (body .sidebar > .panel.navigation.timeline > .timelines-content li.item.cpu,):
2571         * UserInterface/Views/CPUTimelineOverviewGraph.js:
2572         (WI.CPUTimelineOverviewGraph.prototype.get height):
2573         Reduce the CPU overview graph height to 60px.
2574
2575         (WI.CPUTimelineOverviewGraph.prototype.layout):
2576         Increase the minimum size of a column bar to 4px.
2577
2578 2019-03-04  Joseph Pecoraro  <pecoraro@apple.com>
2579
2580         Web Inspector: Reload actions from second level inspector should properly reload the inspected inspector
2581         https://bugs.webkit.org/show_bug.cgi?id=195306
2582
2583         Reviewed by Matt Baker.
2584
2585         * UserInterface/Base/Main.js:
2586         Provide a better reload for a Nth level inspector.
2587
2588         * UserInterface/Debug/Bootstrap.js:
2589         (WI.runBootstrapOperations):
2590         Simplify, should not need to check for InspectorFrontendHost.
2591
2592 2019-03-04  Joseph Pecoraro  <pecoraro@apple.com>
2593
2594         Web Inspector: MediaSource logging not initialized properly
2595         https://bugs.webkit.org/show_bug.cgi?id=195307
2596
2597         Reviewed by Matt Baker.
2598
2599         * UserInterface/Controllers/ConsoleManager.js:
2600         (WI.ConsoleManager.prototype.initializeLogChannels):
2601         Typo caused undefined to be included and trigger assertions.
2602
2603 2019-03-04  Devin Rousso  <drousso@apple.com>
2604
2605         Web Inspector: CSS: class input isn't fully centered
2606         https://bugs.webkit.org/show_bug.cgi?id=195297
2607
2608         Reviewed by Matt Baker.
2609
2610         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:
2611         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > .class-name-input):
2612         (body[dir=ltr] .sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > .class-name-input): Deleted.
2613         (body[dir=rtl] .sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > .class-name-input): Deleted.
2614
2615 2019-03-04  Devin Rousso  <drousso@apple.com>
2616
2617         Web Inspector: Audit: show the version number in the UI
2618         https://bugs.webkit.org/show_bug.cgi?id=195292
2619
2620         Reviewed by Matt Baker.
2621
2622         * UserInterface/Views/AuditNavigationSidebarPanel.js:
2623         (WI.AuditNavigationSidebarPanel.prototype.showDefaultContentView):
2624         (WI.AuditNavigationSidebarPanel.prototype._updateNoAuditsPlaceholder):
2625         Fix the logic for showing a placeholder when editing or with only disabled tests.
2626
2627         * UserInterface/Views/AuditNavigationSidebarPanel.css:
2628         (.sidebar > .panel.navigation.audit > .content > .message-text-view): Added.
2629         (.audit-version): Added.
2630         Don't obstruct the "Edit" button when showing a placeholder.
2631
2632         * Localizations/en.lproj/localizedStrings.js:
2633
2634 2019-03-04  Joseph Pecoraro  <pecoraro@apple.com>
2635
2636         ITMLKit Inspector: Data Bindings / Associated Data for nodes
2637         https://bugs.webkit.org/show_bug.cgi?id=195290
2638         <rdar://problem/48304019>
2639
2640         Reviewed by Devin Rousso.
2641
2642         * Localizations/en.lproj/localizedStrings.js:
2643         New title and empty message strings.
2644
2645         * UserInterface/Views/DOMNodeDetailsSidebarPanel.css:
2646         (.sidebar > .panel.dom-node-details .details-section.dom-node-associated-data > .content .row):
2647         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
2648         (WI.DOMNodeDetailsSidebarPanel.prototype.initialLayout):
2649         (WI.DOMNodeDetailsSidebarPanel.prototype.layout):
2650         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshDataBindings):
2651         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshAssociatedData):
2652         (WI.DOMNodeDetailsSidebarPanel.prototype._attributesChanged):
2653         New Node sections only enabled for ITMLKit `WI.sharedApp.hasExtraDomains`.
2654
2655         * UserInterface/Views/ObjectTreeView.js:
2656         (WI.ObjectTreeView):
2657         Provide a way, like TreeElement/View to access the ObjectTreeView from an element.
2658
2659 2019-03-04  Devin Rousso  <drousso@apple.com>
2660
2661         Web Inspector: Canvas: protocol error on first open
2662         https://bugs.webkit.org/show_bug.cgi?id=195059
2663         <rdar://problem/48407871>
2664
2665         Reviewed by Joseph Pecoraro.
2666
2667         * UserInterface/Controllers/CanvasManager.js:
2668         (WI.CanvasManager.prototype.initializeTarget):
2669         (WI.CanvasManager.prototype.static supportsRecordingAutoCapture):
2670         (WI.CanvasManager.prototype.setRecordingAutoCaptureFrameCount):
2671         If targets aren't available, wait until they are and then set the auto-capture frame count.
2672
2673 2019-03-04  Devin Rousso  <drousso@apple.com>
2674
2675         Web Inspector: Toggling Timeline "Stop when page loads" to on should stop (immediately or soon) any active recording if already past the load event
2676         https://bugs.webkit.org/show_bug.cgi?id=195239
2677
2678         Reviewed by Joseph Pecoraro.
2679
2680         * UserInterface/Controllers/TimelineManager.js:
2681         (WI.TimelineManager.prototype._handleTimelinesAutoStopSettingChanged):
2682
2683 2019-03-02  Devin Rousso  <drousso@apple.com>
2684
2685         Web Inspector: Unexpectedly frequent flashing of DOM node attributes
2686         https://bugs.webkit.org/show_bug.cgi?id=148049
2687         <rdar://problem/22296830>
2688
2689         Reviewed by Joseph Pecoraro.
2690
2691         Save a timestamp of when the CSS animation began, so that if the attribute's node is replaced,
2692         we can "resume" the CSS animation at the same point with the attribute's new node.
2693
2694         * UserInterface/Views/DOMTreeElement.js:
2695         (WI.DOMTreeElement):
2696         (WI.DOMTreeElement.prototype.attributeDidChange):
2697         (WI.DOMTreeElement.prototype._buildAttributeDOM):
2698         (WI.DOMTreeElement.prototype._createModifiedAnimation):
2699         (WI.DOMTreeElement.prototype._markNodeChanged): Deleted.
2700         (WI.DOMTreeElement.prototype._nodeChangedAnimationEnd): Deleted.
2701         (WI.DOMTreeElement.prototype._fireDidChange): Deleted.
2702
2703 2019-03-02  Devin Rousso  <drousso@apple.com>
2704
2705         Web Inspector: Debugger: DOM, URL, and Event breakpoints don't grey out when all breakpoints are disabled
2706         https://bugs.webkit.org/show_bug.cgi?id=195170
2707         <rdar://problem/48478193>
2708
2709         Reviewed by Joseph Pecoraro.
2710
2711         * UserInterface/Views/DOMBreakpointTreeElement.js:
2712         (WI.DOMBreakpointTreeElement):
2713         (WI.DOMBreakpointTreeElement.prototype.onattach):
2714         (WI.DOMBreakpointTreeElement.prototype.ondetach):
2715         (WI.DOMBreakpointTreeElement.prototype._updateStatus):
2716         * UserInterface/Views/EventBreakpointTreeElement.js:
2717         (WI.EventBreakpointTreeElement):
2718         (WI.EventBreakpointTreeElement.prototype.onattach):
2719         (WI.EventBreakpointTreeElement.prototype.ondetach):
2720         (WI.EventBreakpointTreeElement.prototype._updateStatus):
2721         * UserInterface/Views/URLBreakpointTreeElement.js:
2722         (WI.URLBreakpointTreeElement):
2723         (WI.URLBreakpointTreeElement.prototype.onattach):
2724         (WI.URLBreakpointTreeElement.prototype.ondetach):
2725         (WI.URLBreakpointTreeElement.prototype._updateStatus):
2726         Remove the `"resolved"` class when the global "breakpoints enabled" state is changed.
2727
2728         * UserInterface/Controllers/DOMDebuggerManager.js:
2729         (WI.DOMDebuggerManager):
2730         (WI.DOMDebuggerManager.prototype._handleDOMBreakpointDisabledStateChanged): Added.
2731         (WI.DOMDebuggerManager.prototype._handleEventBreakpointDisabledStateChanged): Added.
2732         (WI.DOMDebuggerManager.prototype._handleURLBreakpointDisabledStateChanged): Added.
2733         (WI.DOMDebuggerManager.prototype._updateEventBreakpoint):
2734         (WI.DOMDebuggerManager.prototype._updateURLBreakpoint):
2735         (WI.DOMDebuggerManager.prototype._resolveEventBreakpoint):
2736         (WI.DOMDebuggerManager.prototype._resolveURLBreakpoint):
2737         (WI.DOMDebuggerManager.prototype._updateEventBreakpoint.breakpointUpdated): Deleted.
2738         (WI.DOMDebuggerManager.prototype._updateURLBreakpoint.breakpointUpdated): Deleted.
2739         * UserInterface/Models/DOMBreakpoint.js:
2740         (WI.DOMBreakpoint):
2741         (WI.DOMBreakpoint.deserialize): Added.
2742         (WI.DOMBreakpoint.prototype.set disabled):
2743         (WI.DOMBreakpoint.prototype.set domNodeIdentifier):
2744         * UserInterface/Models/EventBreakpoint.js:
2745         (WI.EventBreakpoint.deserialize): Added.
2746         (WI.EventBreakpoint.prototype.set disabled):
2747         (WI.EventBreakpoint.fromPayload): Deleted.
2748         * UserInterface/Models/URLBreakpoint.js:
2749         (WI.URLBreakpoint.deserialize): Added.
2750         (WI.URLBreakpoint.prototype.set disabled):
2751         * UserInterface/Views/DOMTreeContentView.js:
2752         (WI.DOMTreeContentView):
2753         (WI.DOMTreeContentView.prototype._handleDOMBreakpointDisabledStateChanged): Added.
2754         (WI.DOMTreeContentView.prototype._handleDOMBreakpointDOMNodeChanged): Added.
2755         * UserInterface/Views/DebuggerSidebarPanel.js:
2756         (WI.DebuggerSidebarPanel.prototype._handleDOMBreakpointResolvedStateChanged): Added.
2757         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
2758         (WI.SourcesNavigationSidebarPanel):
2759         (WI.SourcesNavigationSidebarPanel.prototype._handleDOMBreakpointResolvedStateChanged): Added.
2760         Drive-by: rename all events with the name `*DidChange` to `*Changed`.
2761         Drive-by: create static `deserialize` helper functions.
2762
2763 2019-03-02  Devin Rousso  <drousso@apple.com>
2764
2765         Web Inspector: Sources: breakpoints should be disabled when an audit is running
2766         https://bugs.webkit.org/show_bug.cgi?id=195105
2767         <rdar://problem/48441373>
2768
2769         Reviewed by Joseph Pecoraro.
2770
2771         * UserInterface/Views/SourcesNavigationSidebarPanel.js:
2772         (WI.SourcesNavigationSidebarPanel):
2773         (WI.SourcesNavigationSidebarPanel.prototype.closed):
2774         (WI.SourcesNavigationSidebarPanel.prototype._updateTemporarilyDisabledBreakpointsButtons): Added.
2775         (WI.SourcesNavigationSidebarPanel.prototype._updateBreakpointsDisabledBanner):
2776         (WI.SourcesNavigationSidebarPanel.prototype._handleTimelineCapturingWillStart):
2777         (WI.SourcesNavigationSidebarPanel.prototype._handleTimelineCapturingStopped):
2778         (WI.SourcesNavigationSidebarPanel.prototype._handleAuditManagerTestScheduled): Added.
2779         (WI.SourcesNavigationSidebarPanel.prototype._handleAuditManagerTestCompleted): Added.
2780         * UserInterface/Views/SourcesNavigationSidebarPanel.css:
2781         (.sidebar > .panel.navigation.sources > .content > .warning-banner + .warning-banner): Added.
2782
2783         * UserInterface/Views/DebuggerSidebarPanel.js:
2784         (WI.DebuggerSidebarPanel):
2785
2786 2019-03-02  Devin Rousso  <drousso@apple.com>
2787
2788         Web Inspector: Debugger: don't enable breakpoints when source location changes
2789         https://bugs.webkit.org/show_bug.cgi?id=195081
2790         <rdar://problem/48422701>
2791
2792         Reviewed by Joseph Pecoraro.
2793
2794         * UserInterface/Controllers/DebuggerManager.js:
2795         (WI.DebuggerManager.prototype._breakpointDisplayLocationDidChange):
2796         (WI.DebuggerManager.prototype._breakpointEditablePropertyDidChange):
2797
2798 2019-03-01  Joseph Pecoraro  <pecoraro@apple.com>
2799
2800         Web Inspector: CPU Usage - Energy Impact Section
2801         https://bugs.webkit.org/show_bug.cgi?id=195151
2802
2803         Reviewed by Devin Rousso.
2804
2805         * Localizations/en.lproj/localizedStrings.js:
2806         * UserInterface/Main.html:
2807         New strings and resources.
2808
2809         * UserInterface/Views/CPUTimelineView.css:
2810         (.timeline-view.cpu > .content .subtitle > .info):
2811         (@media (prefers-color-scheme: dark)):
2812         (.energy-info-popover-content):
2813         (.timeline-view.cpu > .content > .overview > .divider):
2814         (body[dir=ltr] .timeline-view.cpu > .content > .overview > .divider):
2815         (body[dir=rtl] .timeline-view.cpu > .content > .overview > .divider):
2816         (.timeline-view.cpu :matches(.area-chart, .stacked-area-chart) svg > path):
2817         (.timeline-view.cpu .gauge-chart:not(.empty) > svg > path.low):
2818         (.timeline-view.cpu .gauge-chart:not(.empty) > svg > path.medium):
2819         (.timeline-view.cpu .gauge-chart:not(.empty) > svg > path.high):
2820         (.timeline-view.cpu .gauge-chart:not(.empty) > svg > polygon.needle):
2821         (.timeline-view.cpu .energy):
2822         (.timeline-view.cpu .energy .energy-impact):
2823         (.timeline-view.cpu .energy .energy-impact.low):
2824         (.timeline-view.cpu .energy .energy-impact.medium):
2825         (.timeline-view.cpu .energy .energy-impact.high):
2826         (.timeline-view.cpu .energy .energy-impact-number):
2827         Styling the chart and text for the different energy impact levels.
2828
2829         * UserInterface/Views/CPUTimelineView.js:
2830         (WI.CPUTimelineView.prototype.get lowEnergyValue):
2831         (WI.CPUTimelineView.prototype.get highEnergyValue):
2832         (WI.CPUTimelineView.prototype.initialLayout):
2833         (WI.CPUTimelineView.prototype.layout):
2834         (WI.CPUTimelineView.prototype._layoutEnergyChart.mapWithBias):
2835         (WI.CPUTimelineView.prototype._layoutEnergyChart.valuesForGauge):
2836         (WI.CPUTimelineView.prototype._layoutEnergyChart):
2837         (WI.CPUTimelineView.prototype._clearEnergyImpactText):
2838         New gauge chart and associated popover.
2839         We do a bit of biasing of the data for each of the sections
2840         in the gauge chart. Each section biases toward the cap of the
2841         section so that:
2842           - we encourage lower power usage (sub 3%)
2843           - the gauge needle quickly moves past the low value of a range
2844
2845         * UserInterface/Views/GaugeChart.css: Added.
2846         (.gauge-chart):
2847         (body[dir=rtl] .gauge-chart):
2848         (.gauge-chart > svg > path,):
2849         (.gauge-chart > svg > polygon.needle):
2850         (.gauge-chart.empty > svg > polygon.needle):
2851         (@media (prefers-color-scheme: dark)):
2852         * UserInterface/Views/GaugeChart.js: Added.
2853         (WI.GaugeChart.prototype.get size):
2854         (WI.GaugeChart.prototype.get segments):
2855         (WI.GaugeChart.prototype.get value):
2856         (WI.GaugeChart.prototype.set value):
2857         (WI.GaugeChart.prototype.clear):
2858         (WI.GaugeChart.prototype.initialLayout):
2859         (WI.GaugeChart.prototype.layout):
2860         (WI.GaugeChart.prototype._validateSegments):
2861         (WI.GaugeChart.prototype._createSegmentPathData):
2862         GaugeChart with variable number of sections and a
2863         current value needle. It has a bit of customization
2864         when drawing the arc at the start of each segment.
2865
2866         * UserInterface/Views/Variables.css:
2867         (:root):
2868         (@media (prefers-color-scheme: dark)):
2869         New CPU colors for the different energy impact levels.
2870
2871 2019-03-01  Nikita Vasilyev  <nvasilyev@apple.com>
2872
2873         Web Inspector: Data grid border colors don't match accent colors
2874         https://bugs.webkit.org/show_bug.cgi?id=195232
2875
2876         Reviewed by Matt Baker.
2877
2878         * UserInterface/Views/DataGrid.css:
2879         (.data-grid:focus tr.selected td:not(:last-child)):
2880         (body[dir=ltr] .data-grid:focus tr.selected td:not(:last-child)):
2881         (body[dir=rtl] .data-grid:focus tr.selected td:not(:last-child)):
2882
2883 2019-02-28  Devin Rousso  <drousso@apple.com>
2884
2885         Web Inspector: Timelines: don't show the auto-stop UI when not inspecting a page
2886         https://bugs.webkit.org/show_bug.cgi?id=195192
2887
2888         Reviewed by Joseph Pecoraro.
2889
2890         * UserInterface/Views/TimelineRecordingContentView.js:
2891         (WI.TimelineRecordingContentView):
2892         (WI.TimelineRecordingContentView.prototype.get navigationItems):
2893
2894 2019-02-28  Joseph Pecoraro  <pecoraro@apple.com>
2895
2896         Web Inspector: CPU Usage: Worker thread that dies might stay at a high value forever
2897         https://bugs.webkit.org/show_bug.cgi?id=195148
2898
2899         Reviewed by Matt Baker.
2900
2901         * UserInterface/Views/CPUTimelineView.js:
2902         (CPUTimelineView.prototype.layout):
2903         Handle workers dieing or at least zeroing out between records.
2904
2905 2019-02-28  Joseph Pecoraro  <pecoraro@apple.com>
2906
2907         Web Inspector: CPU Usage Timeline - Make Threads section expandable / collapsable
2908         https://bugs.webkit.org/show_bug.cgi?id=195085
2909
2910         Reviewed by Matt Baker.
2911
2912         * UserInterface/Base/Setting.js:
2913         New setting to save the Threads expanded/collapsed state.
2914
2915         * UserInterface/Views/CPUTimelineView.css:
2916         (.timeline-view.cpu > .content > .details > .subtitle):
2917         (.timeline-view.cpu > .content > .details > details > .subtitle.threads):
2918         (.timeline-view.cpu > .content > .details > .subtitle): Deleted.
2919         (.timeline-view.cpu > .content > .details > .subtitle.threads): Deleted.
2920         Ensure subtitle styles apply now that one of the subtitles is inside
2921         of a <details> / <summary> element.
2922
2923         * UserInterface/Views/CPUTimelineView.js:
2924         (WI.CPUTimelineView.prototype.initialLayout):
2925         Make the Threads group a <details> / <summary> expandable / collapsed element.
2926
2927         * UserInterface/Views/Main.css:
2928         (summary):
2929         (summary::-webkit-details-marker):
2930         Default styles for <summary>.
2931
2932 2019-02-28  Joseph Pecoraro  <pecoraro@apple.com>
2933
2934         Web Inspector: View.removeSubview not removing the element properly when not parented
2935         https://bugs.webkit.org/show_bug.cgi?id=195146
2936
2937         Reviewed by Matt Baker.
2938
2939         * UserInterface/Views/View.js:
2940         (WI.View.prototype.removeSubview):
2941         Since the element may not be a direct child, just use Element.prototype.remove.
2942
2943 2019-02-28  Matt Baker  <mattbaker@apple.com>
2944
2945         Web Inspector: Debugger: disabled breakpoint color is too dark
2946         https://bugs.webkit.org/show_bug.cgi?id=195103
2947         <rdar://problem/48440678>
2948
2949         Reviewed by Devin Rousso.
2950
2951         Increase the disabled breakpoint contrast, as well as the contrast between
2952         disabled and auto-continue breakpoints. Disabled breakpoints stand out by
2953         being somewhat brighter and less saturated. Using the same strategy for
2954         auto-continue breakpoints is too subtle to provide sufficient contrast.
2955
2956         We can adopt the technique used by Xcode, and overlay a white triangle
2957         marker on the breakpoint arrow to indicate an auto-continue breakpoint.
2958
2959         * UserInterface/Views/BreakpointTreeElement.css:
2960         (.item.breakpoint .status > .status-image):
2961         (.item.breakpoint.selected .status > .status-image.resolved):
2962         Add white outline to make selected breakpoint button stand out.
2963         (.item.breakpoint .status > .status-image.auto-continue::after):
2964         (.item.breakpoint .status > .status-image.disabled):
2965         (.item.breakpoint .status > .status-image.auto-continue): Deleted.
2966
2967
2968         * UserInterface/Views/DOMTreeContentView.css:
2969         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint):
2970         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled):
2971         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.subtree):
2972         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled,): Deleted.
2973
2974         * UserInterface/Views/TextEditor.css:
2975         (.text-editor > .CodeMirror .has-breakpoint .CodeMirror-linenumber::before):
2976         (.text-editor > .CodeMirror .breakpoint-auto-continue:not(.execution-line.primary) .CodeMirror-linenumber::after):
2977         (.text-editor > .CodeMirror .breakpoint-disabled .CodeMirror-linenumber::before):
2978         (.text-editor > .CodeMirror .breakpoint-auto-continue:not(.breakpoint-disabled) .CodeMirror-linenumber::before): Deleted.
2979
2980         * UserInterface/Views/Variables.css:
2981         (:root):
2982         Add breakpoint color variables to use across all breakpoint controls.
2983         Use system colors if available, otherwise fall back to hard-coded values
2984         based on sampling the default (blue) accent color on Mojave.
2985
2986 2019-02-28  Nikita Vasilyev  <nvasilyev@apple.com>
2987
2988         Web Inspector: Styles: Control-Space should force completion
2989         https://bugs.webkit.org/show_bug.cgi?id=194796
2990         <rdar://problem/48180822>
2991
2992         Reviewed by Matt Baker.
2993
2994         Pressing Control-Space when editing CSS property should show completion popover,
2995         even if the value is empty.
2996
2997         * UserInterface/Models/CSSCompletions.js:
2998         (WI.CSSCompletions.prototype.startsWith):
2999         Performance optimization: exit early when `prefix` is empty.
3000
3001         * UserInterface/Views/SpreadsheetStyleProperty.js:
3002         (WI.SpreadsheetStyleProperty.prototype._nameCompletionDataProvider):
3003         (WI.SpreadsheetStyleProperty.prototype._valueCompletionDataProvider):
3004         * UserInterface/Views/SpreadsheetTextField.js:
3005         (WI.SpreadsheetTextField):
3006         (WI.SpreadsheetTextField.prototype._handleKeyDown):
3007         (WI.SpreadsheetTextField.prototype._updateCompletions):
3008
3009 2019-02-28  Devin Rousso  <drousso@apple.com>
3010
3011         Web Inspector: Canvas: enabling auto-capture if the frame count is empty triggers an assertion
3012         https://bugs.webkit.org/show_bug.cgi?id=195060
3013
3014         Reviewed by Matt Baker.
3015
3016         * UserInterface/Views/CanvasOverviewContentView.js:
3017         (WI.CanvasOverviewContentView.prototype._setRecordingAutoCaptureFrameCount):
3018         (WI.CanvasOverviewContentView.prototype._updateRecordingAutoCaptureCheckboxLabel):
3019         (WI.CanvasOverviewContentView.prototype._handleRecordingAutoCaptureCheckedDidChange):
3020
3021 2019-02-28  Joseph Pecoraro  <pecoraro@apple.com>
3022
3023         Web Inspector: Revert -webkit-border-end changes that are unreliable
3024         https://bugs.webkit.org/show_bug.cgi?id=195149
3025
3026         Reviewed by Matt Baker.
3027
3028         * UserInterface/Views/CPUUsageIndicatorView.css:
3029         (.cpu-usage-indicator-view > .details):
3030         (body[dir=ltr] .cpu-usage-indicator-view > .details):
3031         (body[dir=rtl] .cpu-usage-indicator-view > .details):
3032         * UserInterface/Views/CPUUsageStackedView.css:
3033         (.cpu-usage-stacked-view > .details):
3034         (body[dir=ltr] .cpu-usage-stacked-view > .details):
3035         (body[dir=rtl] .cpu-usage-stacked-view > .details):
3036         * UserInterface/Views/CPUUsageView.css:
3037         (.cpu-usage-view > .details):
3038         (body[dir=ltr] .cpu-usage-view > .details):
3039         (body[dir=rtl] .cpu-usage-view > .details):
3040         * UserInterface/Views/MemoryCategoryView.css:
3041         (.memory-category-view > .details):
3042         (body[dir=ltr] .memory-category-view > .details):
3043         (body[dir=rtl] .memory-category-view > .details):
3044
3045 2019-02-28  Joseph Pecoraro  <pecoraro@apple.com>
3046
3047         Web Inspector: Cleanup some Chart code
3048         https://bugs.webkit.org/show_bug.cgi?id=195147
3049
3050         Reviewed by Matt Baker.
3051
3052         * UserInterface/Views/RangeChart.js:
3053         (WI.RangeChart.prototype.layout):
3054         (WI.RangeChart):
3055         * UserInterface/Views/StackedColumnChart.js:
3056         (WI.StackedColumnChart.prototype.layout):
3057         (WI.StackedColumnChart):
3058
3059 2019-02-27  Joseph Pecoraro  <pecoraro@apple.com>
3060
3061         Web Inspector: Add a new Scanner TimelineMarker to show up when mousing over TimelineView graphs
3062         https://bugs.webkit.org/show_bug.cgi?id=195079
3063
3064         Reviewed by Devin Rousso.
3065
3066         * UserInterface/Base/Utilities.js:
3067         (Note.prototype.enclosingNodeOrSelfWithClassInArray):
3068         Helper for a set of classes.
3069
3070         * UserInterface/Models/TimelineMarker.js:
3071         Add a new marker type, "Scanner".
3072
3073         * UserInterface/Views/CPUTimelineView.js:
3074         (WI.CPUTimelineView.prototype.initialLayout):
3075         (WI.CPUTimelineView.prototype._graphPositionForMouseEvent):
3076         (WI.CPUTimelineView.prototype._handleGraphMouseMove):
3077         * UserInterface/Views/MemoryTimelineView.js:
3078         (WI.MemoryTimelineView):
3079         (WI.MemoryTimelineView.prototype._graphPositionForMouseEvent):
3080         (WI.MemoryTimelineView.prototype._handleGraphMouseMove):
3081         Update a scanner time when mousing over various graphs that span the entire time range.
3082         These use the containing graph element because there was a single pixel between
3083         adjacent graphs which would cause the scanner to flicker because the mouse event target
3084         was not an svg element.
3085
3086         * UserInterface/Views/TimelineOverview.js:
3087         (WI.TimelineOverview.prototype.hidden):
3088         (WI.TimelineOverview.prototype.updateScannerTime):
3089         (WI.TimelineOverview.prototype.clearScanner):
3090         * UserInterface/Views/TimelineRecordingContentView.js:
3091         (WI.TimelineRecordingContentView):
3092         (WI.TimelineRecordingContentView.prototype._handleTimelineViewScannerTimeDidChange):
3093         (WI.TimelineRecordingContentView.prototype._handleTimelineViewScannerDidClear):
3094         Update the overview's ruler with scanner changes.
3095
3096         * UserInterface/Views/TimelineRuler.css:
3097         (.timeline-ruler > .markers > .marker.scanner):
3098         * UserInterface/Views/TimelineRuler.js:
3099         (WI.TimelineRuler):
3100         (WI.TimelineRuler.prototype.clearMarkers):
3101         (WI.TimelineRuler.prototype.updateScannerTime):
3102         (WI.TimelineRuler.prototype.clearScanner):
3103         (WI.TimelineRuler.prototype._updateMarkers):
3104         Have a special scanner marker that updates.
3105
3106         * UserInterface/Views/TimelineView.js:
3107         New events that a TimelineView can dispatch to update the overview.
3108
3109         * UserInterface/Views/Variables.css:
3110         (:root):
3111         (@media (prefers-color-scheme: dark)):
3112         Scanner marker colors.
3113
3114 2019-02-27  Devin Rousso  <drousso@apple.com>
3115
3116         Web Inspector: Use Element.closest for internal code
3117         https://bugs.webkit.org/show_bug.cgi?id=173747
3118
3119         Reviewed by Joseph Pecoraro.
3120
3121         Replace usage of added utility functions on the `Node` prototype with the built-in
3122         `Element.prototype.closest` as it's more flexible and is capable of doing the same thing.
3123
3124         * UserInterface/Base/Utilities.js:
3125         (Node.prototype.enclosingNodeOrSelfWithClass): Deleted.
3126         (Node.prototype.enclosingNodeOrSelfWithNodeNameInArray): Deleted.
3127         (Node.prototype.enclosingNodeOrSelfWithNodeName): Deleted.
3128         * UserInterface/Base/Main.js:
3129         (WI.handlePossibleLinkClick):
3130         (WI._focusedContentBrowser):
3131         * UserInterface/Views/CPUTimelineView.js:
3132         (WI.CPUTimelineView.prototype._graphPositionForMouseEvent):
3133         * UserInterface/Views/CompletionSuggestionsView.js:
3134         (WI.CompletionSuggestionsView.prototype.set selectedIndex):
3135         (WI.CompletionSuggestionsView.prototype.update):
3136         (WI.CompletionSuggestionsView.prototype._itemClicked):
3137         * UserInterface/Views/ConsoleGroup.js:
3138         (WI.ConsoleGroup.prototype._titleClicked):
3139         * UserInterface/Views/DOMTreeContentView.js:
3140         (WI.DOMTreeContentView.prototype._mouseWasClicked):
3141         * UserInterface/Views/DOMTreeElement.js:
3142         (WI.DOMTreeElement.prototype._startEditingTarget):
3143         (WI.DOMTreeElement.prototype._populateTagContextMenu):
3144         * UserInterface/Views/DOMTreeOutline.js:
3145         (WI.DOMTreeOutline.prototype.populateContextMenu):
3146         * UserInterface/Views/DataGrid.js:
3147         (WI.DataGrid.prototype._startEditing):
3148         (WI.DataGrid.prototype._editingCancelled):
3149         (WI.DataGrid.prototype.dataGridNodeFromNode):
3150         (WI.DataGrid.prototype.dataGridNodeFromPoint):
3151         (WI.DataGrid.prototype._headerCellClicked):
3152         (WI.DataGrid.prototype._mouseoverColumnCollapser):
3153         (WI.DataGrid.prototype._mouseoutColumnCollapser):
3154         (WI.DataGrid.prototype._clickInColumnCollapser):
3155         (WI.DataGrid.prototype._contextMenuInHeader):
3156         (WI.DataGrid.prototype._contextMenuInDataTable):
3157         * UserInterface/Views/DataGridNode.js:
3158         (WI.DataGridNode.prototype.isEventWithinDisclosureTriangle):
3159         * UserInterface/Views/LegacyTabBar.js:
3160         (WI.LegacyTabBar.prototype._handleMouseDown):
3161         (WI.LegacyTabBar.prototype._handleClick):
3162         * UserInterface/Views/LogContentView.js:
3163         (WI.LogContentView.prototype._handleContextMenuEvent):
3164         (WI.LogContentView.prototype._mousedown):
3165         (WI.LogContentView.prototype._targetInMessageCanBeSelected):
3166         (WI.LogContentView.prototype._mousemove):
3167         (WI.LogContentView.prototype._mouseup):
3168         (WI.LogContentView.prototype._ondragstart):
3169         * UserInterface/Views/NavigationBar.js:
3170         (WI.NavigationBar.prototype._mouseDown):
3171         (WI.NavigationBar.prototype._mouseMoved):
3172         * UserInterface/Views/Popover.js:
3173         (WI.Popover.prototype.handleEvent):
3174         * UserInterface/Views/TabBar.js:
3175         (WI.TabBar.prototype._handleMouseDown):
3176         (WI.TabBar.prototype._handleClick):
3177         * UserInterface/Views/Table.js:
3178         (WI.Table.prototype._handleMouseDown):
3179         (WI.Table.prototype._handleContextMenu):
3180         * UserInterface/Views/TreeOutline.js:
3181         (WI.TreeOutline.prototype.treeElementFromNode):
3182
3183 2019-02-27  Devin Rousso  <drousso@apple.com>
3184
3185         Web Inspector: REGRESSION(r242118): Debugger: event breakpoints have no icon
3186         https://bugs.webkit.org/show_bug.cgi?id=195119
3187
3188         Reviewed by Matt Baker.
3189
3190         * UserInterface/Views/EventBreakpointTreeElement.js:
3191         (WI.EventBreakpointTreeElement):
3192
3193 2019-02-27  Devin Rousso  <drousso@apple.com>
3194
3195         Web Inspector: Dark Mode: unreadable text in bezier curve editor numeric input fields
3196         https://bugs.webkit.org/show_bug.cgi?id=195018
3197         <rdar://problem/48378541>
3198
3199         Reviewed by Matt Baker.
3200
3201         Simplify some styles using `-webkit-*` properties instead of `[dir=ltr]`/`[dir=rtl]` selectors.
3202
3203         * UserInterface/Views/BezierEditor.css:
3204         (.bezier-editor):
3205         (.bezier-editor > .bezier-preview):
3206         (.bezier-editor > .bezier-preview-timing):
3207         (.bezier-editor > .bezier-container .linear-curve):
3208         (.bezier-editor > .bezier-container .bezier-curve):
3209         (.bezier-editor > .bezier-container .control-line):
3210         (.bezier-editor > .bezier-container .control-handle):
3211         (.bezier-editor > .number-input-container):
3212         (.bezier-editor > .number-input-container > input):
3213         (body[dir=ltr] .bezier-editor > .bezier-preview-timing): Deleted.
3214         (body[dir=rtl] .bezier-editor > .bezier-preview-timing): Deleted.
3215         (body[dir=ltr] .bezier-editor > .number-input-container > input): Deleted.
3216         (body[dir=rtl] .bezier-editor > .number-input-container > input): Deleted.
3217         (@media (prefers-color-scheme: dark)): Deleted.
3218         Remove all custom styling on any <input>s, as they look fine with their default styling.
3219
3220         * UserInterface/Views/SpringEditor.css:
3221         (.spring-editor > .spring-preview):
3222         (.spring-editor > .spring-preview > div):
3223         (.spring-editor > .spring-timing > div):
3224
3225 2019-02-27  Devin Rousso  <drousso@apple.com>
3226
3227         Web Inspector: popover colors don't change when transitioning to/from dark mode
3228         https://bugs.webkit.org/show_bug.cgi?id=195113
3229         <rdar://problem/48444188>
3230
3231         Reviewed by Timothy Hatcher.
3232
3233         * UserInterface/Views/Popover.js:
3234         (WI.Popover.prototype.dismiss):
3235         (WI.Popover.prototype._addListenersIfNeeded):
3236
3237 2019-02-26  Matt Baker  <mattbaker@apple.com>
3238
3239         Web Inspector: Use system accent color throughout UI
3240         https://bugs.webkit.org/show_bug.cgi?id=193507
3241         <rdar://problem/47327971>
3242
3243         Reviewed by Timothy Hatcher.
3244
3245         * UserInterface/Images/Breakpoint.png: Removed.
3246         * UserInterface/Images/Breakpoint.svg: Added.
3247         * UserInterface/Images/Breakpoint@2x.png: Removed.
3248         * UserInterface/Images/BreakpointInactive.png: Removed.
3249         * UserInterface/Images/BreakpointInactive@2x.png: Removed.
3250         Replace breakpoint pixel art with an SVG image that can be styled in CSS.
3251
3252         * UserInterface/Images/CSSVariable.svg:
3253         * UserInterface/Images/CubicBezier.svg:
3254         * UserInterface/Images/UserInputPrompt.svg:
3255         Remove fill color since it is now styled in CSS.
3256
3257         * UserInterface/Views/BezierEditor.css:
3258         (.bezier-editor > .bezier-preview > div):
3259         (@media (prefers-color-scheme: dark)):
3260         (.bezier-editor > .bezier-container .control-handle):
3261         (.bezier-editor > .bezier-container .control-line):
3262         Use system accent color for control handles.
3263
3264         * UserInterface/Views/BreakpointTreeElement.css:
3265         (.item.breakpoint .status > .status-image):
3266         (.item.breakpoint .status > .status-image.resolved):
3267         Use system accent color for breakpoint fill, with a dark outline
3268         to match Xcode and make the button stand out against the selection.
3269
3270         * UserInterface/Views/BreakpointTreeElement.js:
3271         (WI.BreakpointTreeElement.prototype._updateStatus):
3272
3273         * UserInterface/Views/ButtonNavigationItem.css:
3274         (.navigation-bar .item.button > .glyph):
3275
3276         * UserInterface/Views/ConsolePrompt.js:
3277         (WI.ConsolePrompt):
3278
3279         * UserInterface/Views/DOMBreakpointTreeElement.js:
3280         * UserInterface/Views/DOMTreeContentView.css:
3281         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint):
3282         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled,):
3283         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.subtree):
3284         (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled): Deleted.
3285         (.content-view.dom-tree .tree-outline.dom.breakpoints-disabled li .status-image.breakpoint): Deleted.
3286         (.content-view.dom-tree .tree-outline.dom.breakpoints-disabled li .status-image.breakpoint.disabled): Deleted.
3287
3288         * UserInterface/Views/DOMTreeOutline.css:
3289         (.tree-outline.dom li.selected .selection-area):
3290         (.tree-outline.dom li.elements-drag-over .selection-area):
3291         (.tree-outline.dom:focus li:matches(.selected, .hovered) .selection-area):
3292         (.tree-outline.dom li.hovered:not(.selected) .selection-area):
3293         (.tree-outline.dom li.pseudo-class-enabled > .selection-area::before):
3294         Use the system accent color for the "pseudo-class enabled" marker.
3295         (@media (prefers-color-scheme: dark)):
3296         (.tree-outline.dom:focus li.selected .selection-area): Deleted.
3297         Use --selected-background-color for selection and hover styles, which is
3298         set to the system highlight color if available.
3299
3300         * UserInterface/Views/InlineSwatch.css:
3301         (.inline-swatch:matches(.bezier, .spring, .variable)):
3302         (.inline-swatch:matches(.bezier, .spring)): Deleted.
3303         (.inline-swatch.variable): Deleted.
3304
3305         * UserInterface/Views/InlineSwatch.js:
3306         (WI.InlineSwatch):