Skip to content

Commit 7a7404a

Browse files
ktranDevtools-frontend LUCI CQ
authored andcommitted
Show both reports and endpoints for report API tab
With the empty state update in https://crrev.com/c/6233913 we only showed reports, but actually endpoints may independently show up. This reverts parts of the previous change and makes sure to show both views for reports and endpoints. Before: https://i.imgur.com/PLg6pYF.png After: https://i.imgur.com/hMmQt9g.png Bug: 325443331 Change-Id: I0bc7ffe8a5e66d248daf3fa14a3741a9eb0cd1ec Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6244432 Reviewed-by: Kateryna Prokopenko <[email protected]> Commit-Queue: Kim-Anh Tran <[email protected]>
1 parent 13a9d11 commit 7a7404a

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

front_end/panels/application/ReportingApiView.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,11 @@ export class ReportingApiView extends UI.SplitWidget.SplitWidget {
3232
reportingApiEndpointsView.contentElement.appendChild(this.endpointsGrid);
3333
this.setMainWidget(reportingApiReportsView);
3434
this.setSidebarWidget(reportingApiEndpointsView);
35-
this.hideSidebar();
3635
void networkManager.enableReportingApi();
3736
}
3837
}
3938

4039
private onEndpointsChangedForOrigin(data: Protocol.Network.ReportingApiEndpointsChangedForOriginEvent): void {
41-
if (this.showMode() !== UI.SplitWidget.ShowMode.BOTH) {
42-
this.showBoth();
43-
}
4440
this.endpoints.set(data.origin, data.endpoints);
4541
this.endpointsGrid.data = {endpoints: this.endpoints};
4642
}

front_end/panels/application/components/ReportsGrid.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,8 @@ export class ReportsGrid extends HTMLElement {
116116
// clang-format off
117117
render(html`
118118
<div class="reporting-container" jslog=${VisualLogging.section('reports')}>
119+
<div class="reporting-header">${i18n.i18n.lockedString('Reports')}</div>
119120
${this.#reports.length > 0 ? html`
120-
<div class="reporting-header">${i18n.i18n.lockedString('Reports')}</div>
121121
<devtools-data-grid striped @select=${this.#onSelect}>
122122
<table>
123123
<tr>

0 commit comments

Comments
 (0)