chrome-devtools-frontend 1.0.1571573 → 1.0.1572937
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/front_end/Images/geminiInDevTools.png +0 -0
- package/front_end/Images/geminiInDevTools_2x.png +0 -0
- package/front_end/Images/src/database-off.svg +1 -0
- package/front_end/Images/src/lock-person.svg +1 -1
- package/front_end/core/common/Debouncer.ts +10 -1
- package/front_end/core/common/SettingRegistration.ts +1 -1
- package/front_end/core/host/AidaClient.ts +8 -0
- package/front_end/core/host/InspectorFrontendHostAPI.ts +0 -6
- package/front_end/core/host/UserMetrics.ts +0 -30
- package/front_end/core/root/ExperimentNames.ts +30 -0
- package/front_end/core/root/Runtime.ts +12 -27
- package/front_end/core/root/root.ts +2 -0
- package/front_end/core/sdk/CSSModel.ts +36 -13
- package/front_end/core/sdk/CSSProperty.ts +1 -1
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +9 -0
- package/front_end/core/sdk/CookieModel.ts +2 -1
- package/front_end/core/sdk/DOMModel.ts +1 -1
- package/front_end/core/sdk/DebuggerModel.ts +1 -1
- package/front_end/core/sdk/OverlayModel.ts +1 -1
- package/front_end/core/sdk/SourceMap.ts +1 -1
- package/front_end/devtools_compatibility.js +0 -6
- package/front_end/entrypoints/main/MainImpl.ts +34 -25
- package/front_end/entrypoints/main/main-meta.ts +1 -1
- package/front_end/generated/SupportedCSSProperties.js +4 -8
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +0 -180
- package/front_end/models/ai_assistance/ai_assistance.ts +0 -2
- package/front_end/models/breakpoints/BreakpointManager.ts +3 -3
- package/front_end/models/issues_manager/ContrastCheckTrigger.ts +2 -2
- package/front_end/models/source_map_scopes/NamesResolver.ts +1 -1
- package/front_end/models/trace/EventsSerializer.ts +5 -1
- package/front_end/models/trace/types/TraceEvents.ts +4 -0
- package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +1 -1
- package/front_end/panels/accessibility/AccessibilitySidebarView.ts +1 -1
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +8 -63
- package/front_end/panels/ai_assistance/aiAssistancePanel.css +0 -16
- package/front_end/panels/ai_assistance/ai_assistance.ts +0 -1
- package/front_end/panels/ai_assistance/components/ChatView.ts +123 -108
- package/front_end/panels/ai_assistance/components/PerformanceAgentMarkdownRenderer.ts +1 -145
- package/front_end/panels/application/DeviceBoundSessionsModel.ts +23 -1
- package/front_end/panels/application/DeviceBoundSessionsTreeElement.ts +23 -0
- package/front_end/panels/application/FrameDetailsView.ts +11 -10
- package/front_end/panels/application/components/BackForwardCacheView.ts +6 -8
- package/front_end/panels/application/components/BounceTrackingMitigationsView.ts +4 -3
- package/front_end/panels/application/components/ProtocolHandlersView.ts +5 -6
- package/front_end/panels/application/components/ReportsGrid.ts +8 -9
- package/front_end/panels/application/components/SharedStorageAccessGrid.ts +5 -4
- package/front_end/panels/application/components/TrustTokensView.ts +4 -6
- package/front_end/panels/application/preloading/PreloadingView.ts +9 -8
- package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +237 -230
- package/front_end/panels/application/preloading/components/PreloadingGrid.ts +3 -2
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +6 -10
- package/front_end/panels/application/resourcesSidebar.css +8 -0
- package/front_end/panels/autofill/AutofillView.ts +4 -3
- package/front_end/panels/common/AiCodeGenerationTeaser.ts +35 -4
- package/front_end/panels/common/BadgeNotification.ts +17 -14
- package/front_end/panels/common/GdpSignUpDialog.ts +5 -6
- package/front_end/panels/common/GeminiRebrandPromoDialog.ts +192 -0
- package/front_end/panels/common/aiCodeGenerationTeaser.css +16 -1
- package/front_end/panels/common/common.ts +1 -0
- package/front_end/panels/common/geminiRebrandPromoDialog.css +47 -0
- package/front_end/panels/console/ErrorStackParser.ts +11 -16
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewModel.ts +1 -1
- package/front_end/panels/elements/ComputedStyleModel.ts +7 -54
- package/front_end/panels/elements/ElementsPanel.ts +33 -6
- package/front_end/panels/elements/ElementsTreeOutline.ts +1 -1
- package/front_end/panels/elements/StylePropertiesSection.ts +16 -8
- package/front_end/panels/elements/StylePropertyTreeElement.ts +67 -32
- package/front_end/panels/elements/StylesSidebarPane.ts +28 -11
- package/front_end/panels/elements/components/CSSHintDetailsView.ts +3 -2
- package/front_end/panels/elements/components/CSSPropertyDocsView.ts +3 -2
- package/front_end/panels/elements/elements-meta.ts +1 -1
- package/front_end/panels/issues/IssueView.ts +6 -6
- package/front_end/panels/network/RequestConditionsDrawer.ts +4 -3
- package/front_end/panels/network/RequestCookiesView.ts +3 -4
- package/front_end/panels/network/RequestTimingView.ts +2 -7
- package/front_end/panels/network/components/HeaderSectionRow.ts +3 -2
- package/front_end/panels/network/components/RequestHeaderSection.ts +3 -1
- package/front_end/panels/profiler/HeapProfileView.ts +3 -3
- package/front_end/panels/profiler/HeapSnapshotView.ts +1 -1
- package/front_end/panels/profiler/profiler-meta.ts +3 -3
- package/front_end/panels/protocol_monitor/protocol_monitor-meta.ts +1 -1
- package/front_end/panels/recorder/RecorderController.ts +2 -7
- package/front_end/panels/recorder/components/CreateRecordingView.ts +6 -6
- package/front_end/panels/recorder/components/RecordingView.ts +0 -38
- package/front_end/panels/recorder/components/ReplaySection.ts +0 -14
- package/front_end/panels/recorder/components/StepEditor.ts +2 -40
- package/front_end/panels/recorder/recorderController.css +3 -3
- package/front_end/panels/security/CookieReportView.ts +14 -14
- package/front_end/panels/security/cookieControlsView.css +1 -1
- package/front_end/panels/security/cookieReportView.css +1 -1
- package/front_end/panels/settings/AISettingsTab.ts +8 -10
- package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +4 -12
- package/front_end/panels/settings/settings-meta.ts +1 -1
- package/front_end/panels/sources/BreakpointEditDialog.ts +4 -3
- package/front_end/panels/sources/FilteredUISourceCodeListProvider.ts +1 -1
- package/front_end/panels/sources/NavigatorView.ts +4 -4
- package/front_end/panels/sources/SourcesPanel.ts +5 -4
- package/front_end/panels/sources/components/HeadersView.ts +2 -2
- package/front_end/panels/timeline/CompatibilityTracksAppender.ts +3 -2
- package/front_end/panels/timeline/ThreadAppender.ts +2 -1
- package/front_end/panels/timeline/TimelineController.ts +3 -3
- package/front_end/panels/timeline/TimelinePanel.ts +6 -4
- package/front_end/panels/timeline/TimelineUIUtils.ts +2 -2
- package/front_end/panels/timeline/components/ExportTraceOptions.ts +4 -4
- package/front_end/panels/timeline/components/FieldSettingsDialog.ts +13 -6
- package/front_end/panels/timeline/components/LiveMetricsView.ts +13 -9
- package/front_end/panels/timeline/components/exportTraceOptions.css +1 -1
- package/front_end/panels/timeline/components/fieldSettingsDialog.css +1 -1
- package/front_end/panels/timeline/components/insights/BaseInsightComponent.ts +2 -19
- package/front_end/panels/timeline/components/insights/InsightRenderer.ts +3 -4
- package/front_end/panels/timeline/components/insights/baseInsightComponent.css +0 -5
- package/front_end/panels/timeline/components/liveMetricsView.css +1 -1
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/ui/components/buttons/button.css +4 -0
- package/front_end/ui/components/panel_feedback/PreviewToggle.ts +5 -5
- package/front_end/ui/components/panel_feedback/previewToggle.css +2 -2
- package/front_end/ui/components/text_editor/AiCodeGenerationParser.ts +27 -8
- package/front_end/ui/components/text_editor/AiCodeGenerationProvider.ts +36 -6
- package/front_end/ui/legacy/ActionRegistration.ts +1 -1
- package/front_end/ui/legacy/ContextMenu.ts +2 -2
- package/front_end/ui/legacy/EmptyWidget.ts +3 -3
- package/front_end/ui/legacy/LinkContextMenuProvider.ts +42 -0
- package/front_end/ui/legacy/ViewRegistration.ts +1 -1
- package/front_end/ui/legacy/XLink.ts +0 -27
- package/front_end/ui/legacy/components/color_picker/ContrastDetails.ts +1 -1
- package/front_end/ui/legacy/components/color_picker/ContrastOverlay.ts +4 -4
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +2 -2
- package/front_end/ui/legacy/components/perf_ui/perf_ui-meta.ts +1 -1
- package/front_end/ui/legacy/inspectorCommon.css +2 -1
- package/front_end/ui/legacy/legacy.ts +3 -1
- package/front_end/ui/visual_logging/KnownContextValues.ts +2 -0
- package/front_end/ui/visual_logging/LoggingDriver.ts +3 -0
- package/package.json +1 -1
- package/front_end/models/ai_assistance/ArtifactsManager.ts +0 -67
- package/front_end/panels/ai_assistance/components/ArtifactsViewer.ts +0 -183
- package/front_end/panels/ai_assistance/components/CollapsibleAssistanceContentWidget.ts +0 -89
- package/front_end/panels/ai_assistance/components/PerformanceAgentFlameChart.ts +0 -133
- package/front_end/panels/ai_assistance/components/artifactsViewer.css +0 -15
- package/front_end/panels/ai_assistance/components/collapsibleAssistanceContentWidget.css +0 -32
|
@@ -16,7 +16,7 @@ import * as IssueCounter from '../../ui/components/issue_counter/issue_counter.j
|
|
|
16
16
|
import * as MarkdownView from '../../ui/components/markdown_view/markdown_view.js';
|
|
17
17
|
import {Icon} from '../../ui/kit/kit.js';
|
|
18
18
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
19
|
-
import
|
|
19
|
+
import {html, render} from '../../ui/lit/lit.js';
|
|
20
20
|
|
|
21
21
|
import {AffectedBlockedByResponseView} from './AffectedBlockedByResponseView.js';
|
|
22
22
|
import {AffectedCookiesView, AffectedRawCookieLinesView} from './AffectedCookiesView.js';
|
|
@@ -452,12 +452,12 @@ export class IssueView extends UI.TreeOutline.TreeElement {
|
|
|
452
452
|
|
|
453
453
|
const linkList = linkWrapper.listItemElement.createChild('ul', 'link-list');
|
|
454
454
|
for (const description of this.#description.links) {
|
|
455
|
-
const link = UI.Fragment.html`<x-link class="link devtools-link" tabindex="0" href=${description.link}>${
|
|
456
|
-
i18nString(UIStrings.learnMoreS, {PH1: description.linkTitle})}</x-link>` as UI.XLink.XLink;
|
|
457
|
-
link.setAttribute('jslog', `${VisualLogging.link('learn-more').track({click: true})}`);
|
|
458
|
-
|
|
459
455
|
const linkListItem = linkList.createChild('li');
|
|
460
|
-
|
|
456
|
+
// eslint-disable-next-line @devtools/no-lit-render-outside-of-view
|
|
457
|
+
render(
|
|
458
|
+
html`<devtools-link class="link devtools-link" href=${description.link} .jslogContext=${'learn-more'}>${
|
|
459
|
+
i18nString(UIStrings.learnMoreS, {PH1: description.linkTitle})}</devtools-link>`,
|
|
460
|
+
linkListItem);
|
|
461
461
|
}
|
|
462
462
|
this.appendChild(linkWrapper);
|
|
463
463
|
}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
/* eslint-disable @devtools/no-lit-render-outside-of-view */
|
|
5
5
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
6
6
|
|
|
7
|
+
import '../../ui/kit/kit.js';
|
|
7
8
|
import '../../ui/legacy/legacy.js';
|
|
8
9
|
import '../../ui/components/tooltips/tooltips.js';
|
|
9
10
|
|
|
@@ -325,13 +326,13 @@ export class AffectedCountWidget extends UI.Widget.Widget {
|
|
|
325
326
|
}
|
|
326
327
|
|
|
327
328
|
function learnMore(): LitTemplate {
|
|
328
|
-
return html`<
|
|
329
|
+
return html`<devtools-link
|
|
329
330
|
href=${NETWORK_REQUEST_BLOCKING_EXPLANATION_URL}
|
|
330
331
|
tabindex=0
|
|
331
332
|
class=devtools-link
|
|
332
|
-
|
|
333
|
+
.jslogContext=${'learn-more'}>
|
|
333
334
|
${i18nString(UIStrings.learnMore)}
|
|
334
|
-
</
|
|
335
|
+
</devtools-link>`;
|
|
335
336
|
}
|
|
336
337
|
|
|
337
338
|
export class RequestConditionsDrawer extends UI.Widget.VBox implements
|
|
@@ -121,10 +121,9 @@ export const DEFAULT_VIEW: ViewFunction = (input, _output, target) => {
|
|
|
121
121
|
` : Lit.nothing}
|
|
122
122
|
|
|
123
123
|
<div class="cookies-panel-item site-has-cookies-in-other-partition ${input.siteHasCookieInOtherPartition ? '' : 'hidden'}">
|
|
124
|
-
${uiI18n.
|
|
125
|
-
PH1:
|
|
126
|
-
|
|
127
|
-
undefined, 'learn-more'),})}
|
|
124
|
+
${uiI18n.getFormatLocalizedStringTemplate(str_, UIStrings.siteHasCookieInOtherPartition, {
|
|
125
|
+
PH1: html`<devtools-link href="https://developer.chrome.com/en/docs/privacy-sandbox/chips/" .jslogContext=${'learn-more'}>${i18nString(UIStrings.learnMore)}</devtools-link>`
|
|
126
|
+
})}
|
|
128
127
|
</div>
|
|
129
128
|
|
|
130
129
|
<div class="request-cookies-title ${input.responseCookies.cookies.length ? '' : 'hidden'}"
|
|
@@ -528,13 +528,8 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
528
528
|
${input.serverTimings.length === 0 ? html`
|
|
529
529
|
<tr>
|
|
530
530
|
<td colspan=3>
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
'https://web.dev/custom-metrics/#server-timing-api',
|
|
534
|
-
i18nString(UIStrings.theServerTimingApi),
|
|
535
|
-
undefined,
|
|
536
|
-
undefined,
|
|
537
|
-
'server-timing-api')})}
|
|
531
|
+
${uiI18n.getFormatLocalizedStringTemplate(str_, UIStrings.duringDevelopmentYouCanUseSToAdd, {PH1:
|
|
532
|
+
html`<devtools-link href="https://web.dev/custom-metrics/#server-timing-api" .jslogContext=${'server-timing-api'}>${i18nString(UIStrings.theServerTimingApi)}</devtools-link>`})}
|
|
538
533
|
</td>
|
|
539
534
|
</tr>` : nothing}
|
|
540
535
|
</table>`,
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
/* eslint-disable @devtools/no-lit-render-outside-of-view */
|
|
5
5
|
|
|
6
|
+
import '../../../ui/kit/kit.js';
|
|
6
7
|
import '../../../ui/legacy/legacy.js';
|
|
7
8
|
|
|
8
9
|
import * as Host from '../../../core/host/host.js';
|
|
@@ -339,11 +340,11 @@ export class HeaderSectionRow extends HTMLElement {
|
|
|
339
340
|
// Disabled until https://crbug.com/1079231 is fixed.
|
|
340
341
|
// clang-format off
|
|
341
342
|
return html`
|
|
342
|
-
<
|
|
343
|
+
<devtools-link href=${blockedDetails.link.url} class="link">
|
|
343
344
|
<devtools-icon name="open-externally" class="inline-icon extra-large" style="color: var(--icon-link);">
|
|
344
345
|
</devtools-icon
|
|
345
346
|
>${i18nString(UIStrings.learnMore)}
|
|
346
|
-
</
|
|
347
|
+
</devtools-link>
|
|
347
348
|
`;
|
|
348
349
|
// clang-format on
|
|
349
350
|
}
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
+
import '../../../ui/kit/kit.js';
|
|
6
|
+
|
|
5
7
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
6
8
|
import * as Platform from '../../../core/platform/platform.js';
|
|
7
9
|
import type * as SDK from '../../../core/sdk/sdk.js';
|
|
@@ -81,7 +83,7 @@ function renderProvisionalHeadersWarning(isRequestCached: boolean): Lit.LitTempl
|
|
|
81
83
|
<div class="explanation" title=${cautionTitle}>
|
|
82
84
|
<devtools-icon class="inline-icon medium" name='warning-filled'>
|
|
83
85
|
</devtools-icon>
|
|
84
|
-
${cautionText} <
|
|
86
|
+
${cautionText} <devtools-link href="https://developer.chrome.com/docs/devtools/network/reference/#provisional-headers" class="link">${i18nString(UIStrings.learnMore)}</devtools-link>
|
|
85
87
|
</div>
|
|
86
88
|
</div>
|
|
87
89
|
</div>
|
|
@@ -144,7 +144,7 @@ export class HeapProfileView extends ProfileView implements UI.SearchableView.Se
|
|
|
144
144
|
|
|
145
145
|
this.timelineOverview = new HeapTimelineOverview();
|
|
146
146
|
|
|
147
|
-
if (Root.Runtime.experiments.isEnabled(Root.
|
|
147
|
+
if (Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.SAMPLING_HEAP_PROFILER_TIMELINE)) {
|
|
148
148
|
this.timelineOverview.addEventListener(Events.IDS_RANGE_CHANGED, this.onIdsRangeChanged.bind(this));
|
|
149
149
|
this.timelineOverview.show(this.element, this.element.firstChild);
|
|
150
150
|
this.timelineOverview.start();
|
|
@@ -368,7 +368,7 @@ export class SamplingHeapProfileType extends SamplingHeapProfileTypeBase {
|
|
|
368
368
|
}
|
|
369
369
|
|
|
370
370
|
override hasTemporaryView(): boolean {
|
|
371
|
-
return Root.Runtime.experiments.isEnabled(Root.
|
|
371
|
+
return Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.SAMPLING_HEAP_PROFILER_TIMELINE);
|
|
372
372
|
}
|
|
373
373
|
|
|
374
374
|
override startSampling(): void {
|
|
@@ -378,7 +378,7 @@ export class SamplingHeapProfileType extends SamplingHeapProfileTypeBase {
|
|
|
378
378
|
}
|
|
379
379
|
|
|
380
380
|
void heapProfilerModel.startSampling();
|
|
381
|
-
if (Root.Runtime.experiments.isEnabled(Root.
|
|
381
|
+
if (Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.SAMPLING_HEAP_PROFILER_TIMELINE)) {
|
|
382
382
|
this.updateTimer = window.setTimeout(() => {
|
|
383
383
|
void this.updateStats();
|
|
384
384
|
}, this.updateIntervalMs);
|
|
@@ -1338,7 +1338,7 @@ export class HeapSnapshotProfileType extends
|
|
|
1338
1338
|
|
|
1339
1339
|
override customContent(): Element|null {
|
|
1340
1340
|
const showOptionToExposeInternalsInHeapSnapshot = Root.Runtime.experiments.isEnabled(
|
|
1341
|
-
Root.
|
|
1341
|
+
Root.ExperimentNames.ExperimentName.SHOW_OPTION_TO_EXPOSE_INTERNALS_IN_HEAP_SNAPSHOT);
|
|
1342
1342
|
const exposeInternalsInHeapSnapshotCheckbox =
|
|
1343
1343
|
SettingsUI.SettingsUI.createSettingCheckbox(i18nString(UIStrings.exposeInternals), this.exposeInternals);
|
|
1344
1344
|
this.customContentInternal = exposeInternalsInHeapSnapshotCheckbox;
|
|
@@ -101,7 +101,7 @@ UI.ViewManager.registerViewExtension({
|
|
|
101
101
|
const Profiler = await loadProfilerModule();
|
|
102
102
|
return Profiler.LiveHeapProfileView.LiveHeapProfileView.instance();
|
|
103
103
|
},
|
|
104
|
-
experiment: Root.
|
|
104
|
+
experiment: Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE,
|
|
105
105
|
});
|
|
106
106
|
|
|
107
107
|
UI.ActionRegistration.registerActionExtension({
|
|
@@ -115,7 +115,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
115
115
|
return new Profiler.LiveHeapProfileView.ActionDelegate();
|
|
116
116
|
},
|
|
117
117
|
category: UI.ActionRegistration.ActionCategory.MEMORY,
|
|
118
|
-
experiment: Root.
|
|
118
|
+
experiment: Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE,
|
|
119
119
|
options: [
|
|
120
120
|
{
|
|
121
121
|
value: true,
|
|
@@ -136,7 +136,7 @@ UI.ActionRegistration.registerActionExtension({
|
|
|
136
136
|
return new Profiler.LiveHeapProfileView.ActionDelegate();
|
|
137
137
|
},
|
|
138
138
|
category: UI.ActionRegistration.ActionCategory.MEMORY,
|
|
139
|
-
experiment: Root.
|
|
139
|
+
experiment: Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE,
|
|
140
140
|
title: i18nLazyString(UIStrings.startRecordingHeapAllocationsAndReload),
|
|
141
141
|
});
|
|
142
142
|
|
|
@@ -44,5 +44,5 @@ UI.ViewManager.registerViewExtension({
|
|
|
44
44
|
const ProtocolMonitor = await loadProtocolMonitorModule();
|
|
45
45
|
return new ProtocolMonitor.ProtocolMonitor.ProtocolMonitorImpl();
|
|
46
46
|
},
|
|
47
|
-
experiment: Root.
|
|
47
|
+
experiment: Root.ExperimentNames.ExperimentName.PROTOCOL_MONITOR,
|
|
48
48
|
});
|
|
@@ -692,7 +692,6 @@ export class RecorderController extends LitElement {
|
|
|
692
692
|
const indexToInsertAt = currentIndex + (position === Components.StepView.AddStepPosition.BEFORE ? 0 : 1);
|
|
693
693
|
steps.splice(indexToInsertAt, 0, {type: Models.Schema.StepType.WaitForElement, selectors: ['body']});
|
|
694
694
|
const recording = {...this.currentRecording, flow: {...this.currentRecording.flow, steps}};
|
|
695
|
-
Host.userMetrics.recordingEdited(Host.UserMetrics.RecordingEdited.STEP_ADDED);
|
|
696
695
|
this.#stepBreakpointIndexes = new Set([...this.#stepBreakpointIndexes.values()].map(breakpointIndex => {
|
|
697
696
|
if (indexToInsertAt > breakpointIndex) {
|
|
698
697
|
return breakpointIndex;
|
|
@@ -723,7 +722,6 @@ export class RecorderController extends LitElement {
|
|
|
723
722
|
const currentIndex = steps.indexOf(event.step);
|
|
724
723
|
steps.splice(currentIndex, 1);
|
|
725
724
|
const flow = {...this.currentRecording.flow, steps};
|
|
726
|
-
Host.userMetrics.recordingEdited(Host.UserMetrics.RecordingEdited.STEP_REMOVED);
|
|
727
725
|
this.#stepBreakpointIndexes = new Set([...this.#stepBreakpointIndexes.values()]
|
|
728
726
|
.map(breakpointIndex => {
|
|
729
727
|
if (currentIndex > breakpointIndex) {
|
|
@@ -958,10 +956,8 @@ export class RecorderController extends LitElement {
|
|
|
958
956
|
await this.#exportContent(converter.getFilename(this.currentRecording.flow), content);
|
|
959
957
|
const builtInMetric = CONVERTER_ID_TO_METRIC[converter.getId()];
|
|
960
958
|
if (builtInMetric) {
|
|
961
|
-
Host.userMetrics.recordingExported(builtInMetric);
|
|
962
959
|
UI.ARIAUtils.LiveAnnouncer.alert(i18nString(UIStrings.recordingExported));
|
|
963
960
|
} else if (converter.getId().startsWith(Converters.ExtensionConverter.EXTENSION_PREFIX)) {
|
|
964
|
-
Host.userMetrics.recordingExported(Host.UserMetrics.RecordingExported.TO_EXTENSION);
|
|
965
961
|
UI.ARIAUtils.LiveAnnouncer.alert(i18nString(UIStrings.recordingExported));
|
|
966
962
|
} else {
|
|
967
963
|
throw new Error('Could not find a metric for the export option with id = ' + id);
|
|
@@ -993,7 +989,6 @@ export class RecorderController extends LitElement {
|
|
|
993
989
|
this.#setCurrentRecording(
|
|
994
990
|
await this.#storage.updateRecording(this.currentRecording.storageName, flow),
|
|
995
991
|
{keepBreakpoints: true, updateSession: true});
|
|
996
|
-
Host.userMetrics.recordingAssertion(Host.UserMetrics.RecordingAssertion.ASSERTION_ADDED);
|
|
997
992
|
await this.updateComplete;
|
|
998
993
|
// FIXME: call a method on the recording view widget.
|
|
999
994
|
await this.#recordingView?.updateComplete;
|
|
@@ -1195,7 +1190,7 @@ export class RecorderController extends LitElement {
|
|
|
1195
1190
|
<div class="empty-state-description">
|
|
1196
1191
|
<span>${i18nString(UIStrings.recordingDescription)}</span>
|
|
1197
1192
|
<devtools-link
|
|
1198
|
-
class="
|
|
1193
|
+
class="devtools-link"
|
|
1199
1194
|
href=${RECORDER_EXPLANATION_URL}
|
|
1200
1195
|
.jslogContext=${'learn-more'}
|
|
1201
1196
|
>${i18nString(UIStrings.learnMore)}</devtools-link>
|
|
@@ -1473,7 +1468,7 @@ export class RecorderController extends LitElement {
|
|
|
1473
1468
|
}
|
|
1474
1469
|
></devtools-button>
|
|
1475
1470
|
<div class="feedback">
|
|
1476
|
-
<devtools-link class="
|
|
1471
|
+
<devtools-link class="devtools-link" title=${i18nString(UIStrings.sendFeedback)} href=${
|
|
1477
1472
|
FEEDBACK_URL
|
|
1478
1473
|
} .jslogContext=${'feedback'}>${i18nString(UIStrings.sendFeedback)}</devtools-link>
|
|
1479
1474
|
</div>
|
|
@@ -211,13 +211,13 @@ export const DEFAULT_VIEW = (input: ViewInput, output: ViewOutput, target: HTMLE
|
|
|
211
211
|
/>
|
|
212
212
|
<label class="row-label" for="selector-attribute">
|
|
213
213
|
<span>${i18nString(UIStrings.selectorAttribute)}</span>
|
|
214
|
-
<
|
|
214
|
+
<devtools-link
|
|
215
215
|
class="link" href="https://g.co/devtools/recorder#selector"
|
|
216
216
|
title=${i18nString(UIStrings.learnMore)}
|
|
217
|
-
|
|
217
|
+
.jslogContext=${'recorder-selector-help'}>
|
|
218
218
|
<devtools-icon name="help">
|
|
219
219
|
</devtools-icon>
|
|
220
|
-
</
|
|
220
|
+
</devtools-link>
|
|
221
221
|
</label>
|
|
222
222
|
<input
|
|
223
223
|
value=${selectorAttribute}
|
|
@@ -232,13 +232,13 @@ export const DEFAULT_VIEW = (input: ViewInput, output: ViewOutput, target: HTMLE
|
|
|
232
232
|
/>
|
|
233
233
|
<label class="row-label">
|
|
234
234
|
<span>${i18nString(UIStrings.selectorTypes)}</span>
|
|
235
|
-
<
|
|
235
|
+
<devtools-link
|
|
236
236
|
class="link" href="https://g.co/devtools/recorder#selector"
|
|
237
237
|
title=${i18nString(UIStrings.learnMore)}
|
|
238
|
-
|
|
238
|
+
.jslogContext=${'recorder-selector-help'}>
|
|
239
239
|
<devtools-icon name="help">
|
|
240
240
|
</devtools-icon>
|
|
241
|
-
</
|
|
241
|
+
</devtools-link>
|
|
242
242
|
</label>
|
|
243
243
|
<div class="checkbox-container">
|
|
244
244
|
${repeat(selectorTypes, item => {
|
|
@@ -177,38 +177,6 @@ const networkConditionPresets = [
|
|
|
177
177
|
SDK.NetworkManager.Fast4GConditions,
|
|
178
178
|
];
|
|
179
179
|
|
|
180
|
-
function converterIdToFlowMetric(
|
|
181
|
-
converterId: string,
|
|
182
|
-
): Host.UserMetrics.RecordingCopiedToClipboard {
|
|
183
|
-
switch (converterId) {
|
|
184
|
-
case Models.ConverterIds.ConverterIds.PUPPETEER:
|
|
185
|
-
case Models.ConverterIds.ConverterIds.PUPPETEER_FIREFOX:
|
|
186
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_RECORDING_WITH_PUPPETEER;
|
|
187
|
-
case Models.ConverterIds.ConverterIds.JSON:
|
|
188
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_RECORDING_WITH_JSON;
|
|
189
|
-
case Models.ConverterIds.ConverterIds.REPLAY:
|
|
190
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_RECORDING_WITH_REPLAY;
|
|
191
|
-
default:
|
|
192
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_RECORDING_WITH_EXTENSION;
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
function converterIdToStepMetric(
|
|
197
|
-
converterId: string,
|
|
198
|
-
): Host.UserMetrics.RecordingCopiedToClipboard {
|
|
199
|
-
switch (converterId) {
|
|
200
|
-
case Models.ConverterIds.ConverterIds.PUPPETEER:
|
|
201
|
-
case Models.ConverterIds.ConverterIds.PUPPETEER_FIREFOX:
|
|
202
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_STEP_WITH_PUPPETEER;
|
|
203
|
-
case Models.ConverterIds.ConverterIds.JSON:
|
|
204
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_STEP_WITH_JSON;
|
|
205
|
-
case Models.ConverterIds.ConverterIds.REPLAY:
|
|
206
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_STEP_WITH_REPLAY;
|
|
207
|
-
default:
|
|
208
|
-
return Host.UserMetrics.RecordingCopiedToClipboard.COPIED_STEP_WITH_EXTENSION;
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
|
|
212
180
|
function renderSettings({
|
|
213
181
|
settings,
|
|
214
182
|
replaySettingsExpanded,
|
|
@@ -1193,8 +1161,6 @@ export class RecordingView extends UI.Widget.Widget {
|
|
|
1193
1161
|
}
|
|
1194
1162
|
|
|
1195
1163
|
Host.InspectorFrontendHost.InspectorFrontendHostInstance.copyText(text);
|
|
1196
|
-
const metric = step ? converterIdToStepMetric(converter.getId()) : converterIdToFlowMetric(converter.getId());
|
|
1197
|
-
Host.userMetrics.recordingCopiedToClipboard(metric);
|
|
1198
1164
|
}
|
|
1199
1165
|
|
|
1200
1166
|
#onCopyStepEvent(event: CopyStepEvent): void {
|
|
@@ -1223,10 +1189,6 @@ export class RecordingView extends UI.Widget.Widget {
|
|
|
1223
1189
|
|
|
1224
1190
|
showCodeToggle = (): void => {
|
|
1225
1191
|
this.#showCodeView = !this.#showCodeView;
|
|
1226
|
-
Host.userMetrics.recordingCodeToggled(
|
|
1227
|
-
this.#showCodeView ? Host.UserMetrics.RecordingCodeToggled.CODE_SHOWN :
|
|
1228
|
-
Host.UserMetrics.RecordingCodeToggled.CODE_HIDDEN,
|
|
1229
|
-
);
|
|
1230
1192
|
void this.#convertToCode();
|
|
1231
1193
|
};
|
|
1232
1194
|
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
// Copyright 2023 The Chromium Authors
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
|
-
/* eslint-disable @devtools/no-lit-render-outside-of-view */
|
|
5
4
|
|
|
6
|
-
import * as Host from '../../../core/host/host.js';
|
|
7
5
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
8
6
|
import * as Platform from '../../../core/platform/platform.js';
|
|
9
7
|
import * as Buttons from '../../../ui/components/buttons/buttons.js';
|
|
@@ -66,13 +64,6 @@ const UIStrings = {
|
|
|
66
64
|
extensionGroup: 'Extensions',
|
|
67
65
|
} as const;
|
|
68
66
|
|
|
69
|
-
const replaySpeedToMetricSpeedMap = {
|
|
70
|
-
[PlayRecordingSpeed.NORMAL]: Host.UserMetrics.RecordingReplaySpeed.NORMAL,
|
|
71
|
-
[PlayRecordingSpeed.SLOW]: Host.UserMetrics.RecordingReplaySpeed.SLOW,
|
|
72
|
-
[PlayRecordingSpeed.VERY_SLOW]: Host.UserMetrics.RecordingReplaySpeed.VERY_SLOW,
|
|
73
|
-
[PlayRecordingSpeed.EXTREMELY_SLOW]: Host.UserMetrics.RecordingReplaySpeed.EXTREMELY_SLOW,
|
|
74
|
-
} as const;
|
|
75
|
-
|
|
76
67
|
const str_ = i18n.i18n.registerUIStrings(
|
|
77
68
|
'panels/recorder/components/ReplaySection.ts',
|
|
78
69
|
UIStrings,
|
|
@@ -185,7 +176,6 @@ export const DEFAULT_VIEW = (input: ViewInput, _output: ViewOutput, target: HTML
|
|
|
185
176
|
</devtools-button>
|
|
186
177
|
</div>`,
|
|
187
178
|
target,
|
|
188
|
-
{ host: target },
|
|
189
179
|
);
|
|
190
180
|
// clang-format on
|
|
191
181
|
};
|
|
@@ -334,10 +324,6 @@ export class ReplaySection extends UI.Widget.Widget {
|
|
|
334
324
|
this.#settings.speed = speed;
|
|
335
325
|
this.#settings.replayExtension = '';
|
|
336
326
|
}
|
|
337
|
-
|
|
338
|
-
if (replaySpeedToMetricSpeedMap[speed]) {
|
|
339
|
-
Host.userMetrics.recordingReplaySpeed(replaySpeedToMetricSpeedMap[speed]);
|
|
340
|
-
}
|
|
341
327
|
this.performUpdate();
|
|
342
328
|
}
|
|
343
329
|
}
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import * as Host from '../../../core/host/host.js';
|
|
6
5
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
7
6
|
import * as Platform from '../../../core/platform/platform.js';
|
|
8
7
|
import type * as Puppeteer from '../../../third_party/puppeteer/puppeteer.js';
|
|
@@ -517,19 +516,14 @@ export class StepEditor extends LitElement {
|
|
|
517
516
|
this.dispatchEvent(new RequestSelectorAttributeEvent(send));
|
|
518
517
|
};
|
|
519
518
|
|
|
520
|
-
#handleAddOrRemoveClick =
|
|
521
|
-
(
|
|
522
|
-
metric: Host.UserMetrics.RecordingEdited): ((event: Event) => void) => event => {
|
|
519
|
+
#handleAddOrRemoveClick = (assignments: DeepImmutable<DeepPartial<Assignments<EditorState>>>, query: string):
|
|
520
|
+
((event: Event) => void) => event => {
|
|
523
521
|
event.preventDefault();
|
|
524
522
|
event.stopPropagation();
|
|
525
523
|
|
|
526
524
|
this.#commit(immutableDeepAssign(this.state, assignments));
|
|
527
525
|
|
|
528
526
|
this.#ensureFocus(query);
|
|
529
|
-
|
|
530
|
-
if (metric) {
|
|
531
|
-
Host.userMetrics.recordingEdited(metric);
|
|
532
|
-
}
|
|
533
527
|
};
|
|
534
528
|
|
|
535
529
|
#handleKeyDownEvent = (event: Event): void => {
|
|
@@ -551,7 +545,6 @@ export class StepEditor extends LitElement {
|
|
|
551
545
|
attribute: A,
|
|
552
546
|
// If there are not assignments, then we should ignore the event.
|
|
553
547
|
from(this: StepEditor, value: DataType<A>): DeepImmutable<DeepPartial<Assignments<EditorState>>>|undefined,
|
|
554
|
-
metric: Host.UserMetrics.RecordingEdited,
|
|
555
548
|
}): ((event: Event) => void) => event => {
|
|
556
549
|
assert(event.target instanceof SuggestionInput.SuggestionInput.SuggestionInput);
|
|
557
550
|
if (event.target.disabled) {
|
|
@@ -565,10 +558,6 @@ export class StepEditor extends LitElement {
|
|
|
565
558
|
return;
|
|
566
559
|
}
|
|
567
560
|
this.#commit(immutableDeepAssign(this.state, assignments));
|
|
568
|
-
|
|
569
|
-
if (opts.metric) {
|
|
570
|
-
Host.userMetrics.recordingEdited(opts.metric);
|
|
571
|
-
}
|
|
572
561
|
};
|
|
573
562
|
|
|
574
563
|
#handleTypeInputBlur = async(event: Event): Promise<void> => {
|
|
@@ -586,7 +575,6 @@ export class StepEditor extends LitElement {
|
|
|
586
575
|
return;
|
|
587
576
|
}
|
|
588
577
|
this.#commit(await EditorState.default(value));
|
|
589
|
-
Host.userMetrics.recordingEdited(Host.UserMetrics.RecordingEdited.TYPE_CHANGED);
|
|
590
578
|
};
|
|
591
579
|
|
|
592
580
|
#handleAddRowClickEvent = async(event: MouseEvent): Promise<void> => {
|
|
@@ -702,14 +690,8 @@ export class StepEditor extends LitElement {
|
|
|
702
690
|
if (this.state[attribute] === undefined) {
|
|
703
691
|
return;
|
|
704
692
|
}
|
|
705
|
-
switch (attribute) {
|
|
706
|
-
case 'properties':
|
|
707
|
-
Host.userMetrics.recordingAssertion(Host.UserMetrics.RecordingAssertion.PROPERTY_ASSERTION_EDITED);
|
|
708
|
-
break;
|
|
709
|
-
}
|
|
710
693
|
return {[attribute]: value};
|
|
711
694
|
},
|
|
712
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
713
695
|
})}
|
|
714
696
|
></devtools-suggestion-input>
|
|
715
697
|
${this.#renderDeleteButton(attribute)}
|
|
@@ -748,7 +730,6 @@ export class StepEditor extends LitElement {
|
|
|
748
730
|
frame: new ArrayAssignments({ [index]: value }),
|
|
749
731
|
};
|
|
750
732
|
},
|
|
751
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
752
733
|
})}
|
|
753
734
|
></devtools-suggestion-input>
|
|
754
735
|
${this.#renderInlineButton({
|
|
@@ -764,7 +745,6 @@ export class StepEditor extends LitElement {
|
|
|
764
745
|
}),
|
|
765
746
|
},
|
|
766
747
|
`devtools-suggestion-input[data-path="frame.${index + 1}"]`,
|
|
767
|
-
Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
768
748
|
),
|
|
769
749
|
})}
|
|
770
750
|
${this.#renderInlineButton({
|
|
@@ -779,7 +759,6 @@ export class StepEditor extends LitElement {
|
|
|
779
759
|
index,
|
|
780
760
|
frames.length - 2,
|
|
781
761
|
)}"]`,
|
|
782
|
-
Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
783
762
|
),
|
|
784
763
|
})}
|
|
785
764
|
</div>
|
|
@@ -824,7 +803,6 @@ export class StepEditor extends LitElement {
|
|
|
824
803
|
}),
|
|
825
804
|
},
|
|
826
805
|
`devtools-suggestion-input[data-path="selectors.${index + 1}.0"]`,
|
|
827
|
-
Host.UserMetrics.RecordingEdited.SELECTOR_ADDED,
|
|
828
806
|
),
|
|
829
807
|
})}
|
|
830
808
|
${this.#renderInlineButton({
|
|
@@ -837,7 +815,6 @@ export class StepEditor extends LitElement {
|
|
|
837
815
|
index,
|
|
838
816
|
selectors.length - 2,
|
|
839
817
|
)}.0"]`,
|
|
840
|
-
Host.UserMetrics.RecordingEdited.SELECTOR_REMOVED,
|
|
841
818
|
),
|
|
842
819
|
})}
|
|
843
820
|
</div>
|
|
@@ -868,7 +845,6 @@ export class StepEditor extends LitElement {
|
|
|
868
845
|
}),
|
|
869
846
|
};
|
|
870
847
|
},
|
|
871
|
-
metric: Host.UserMetrics.RecordingEdited.SELECTOR_PART_EDITED,
|
|
872
848
|
})}
|
|
873
849
|
></devtools-suggestion-input>
|
|
874
850
|
${this.#renderInlineButton({
|
|
@@ -888,7 +864,6 @@ export class StepEditor extends LitElement {
|
|
|
888
864
|
`devtools-suggestion-input[data-path="selectors.${index}.${
|
|
889
865
|
partIndex + 1
|
|
890
866
|
}"]`,
|
|
891
|
-
Host.UserMetrics.RecordingEdited.SELECTOR_PART_ADDED,
|
|
892
867
|
),
|
|
893
868
|
})}
|
|
894
869
|
${this.#renderInlineButton({
|
|
@@ -907,7 +882,6 @@ export class StepEditor extends LitElement {
|
|
|
907
882
|
partIndex,
|
|
908
883
|
parts.length - 2,
|
|
909
884
|
)}"]`,
|
|
910
|
-
Host.UserMetrics.RecordingEdited.SELECTOR_PART_REMOVED,
|
|
911
885
|
),
|
|
912
886
|
})}
|
|
913
887
|
</div>`;
|
|
@@ -952,7 +926,6 @@ export class StepEditor extends LitElement {
|
|
|
952
926
|
}),
|
|
953
927
|
};
|
|
954
928
|
},
|
|
955
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
956
929
|
})}
|
|
957
930
|
></devtools-suggestion-input>
|
|
958
931
|
</div>
|
|
@@ -975,7 +948,6 @@ export class StepEditor extends LitElement {
|
|
|
975
948
|
}),
|
|
976
949
|
};
|
|
977
950
|
},
|
|
978
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
979
951
|
})}
|
|
980
952
|
></devtools-suggestion-input>
|
|
981
953
|
</div>`;
|
|
@@ -1009,14 +981,10 @@ export class StepEditor extends LitElement {
|
|
|
1009
981
|
if (this.state.attributes?.[index]?.name === undefined) {
|
|
1010
982
|
return;
|
|
1011
983
|
}
|
|
1012
|
-
Host.userMetrics.recordingAssertion(
|
|
1013
|
-
Host.UserMetrics.RecordingAssertion.ATTRIBUTE_ASSERTION_EDITED,
|
|
1014
|
-
);
|
|
1015
984
|
return {
|
|
1016
985
|
attributes: new ArrayAssignments({ [index]: { name } }),
|
|
1017
986
|
};
|
|
1018
987
|
},
|
|
1019
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
1020
988
|
})}
|
|
1021
989
|
></devtools-suggestion-input>
|
|
1022
990
|
<span class="separator">:</span>
|
|
@@ -1031,14 +999,10 @@ export class StepEditor extends LitElement {
|
|
|
1031
999
|
if (this.state.attributes?.[index]?.value === undefined) {
|
|
1032
1000
|
return;
|
|
1033
1001
|
}
|
|
1034
|
-
Host.userMetrics.recordingAssertion(
|
|
1035
|
-
Host.UserMetrics.RecordingAssertion.ATTRIBUTE_ASSERTION_EDITED,
|
|
1036
|
-
);
|
|
1037
1002
|
return {
|
|
1038
1003
|
attributes: new ArrayAssignments({ [index]: { value } }),
|
|
1039
1004
|
};
|
|
1040
1005
|
},
|
|
1041
|
-
metric: Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
1042
1006
|
})}
|
|
1043
1007
|
></devtools-suggestion-input>
|
|
1044
1008
|
${this.#renderInlineButton({
|
|
@@ -1071,7 +1035,6 @@ export class StepEditor extends LitElement {
|
|
|
1071
1035
|
`devtools-suggestion-input[data-path="attributes.${
|
|
1072
1036
|
index + 1
|
|
1073
1037
|
}.name"]`,
|
|
1074
|
-
Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
1075
1038
|
),
|
|
1076
1039
|
})}
|
|
1077
1040
|
${this.#renderInlineButton({
|
|
@@ -1084,7 +1047,6 @@ export class StepEditor extends LitElement {
|
|
|
1084
1047
|
index,
|
|
1085
1048
|
attributes.length - 2,
|
|
1086
1049
|
)}.value"]`,
|
|
1087
|
-
Host.UserMetrics.RecordingEdited.OTHER_EDITING,
|
|
1088
1050
|
),
|
|
1089
1051
|
})}
|
|
1090
1052
|
</div>`;
|
|
@@ -129,7 +129,7 @@ devtools-recording-list-view {
|
|
|
129
129
|
margin-right: 4px;
|
|
130
130
|
}
|
|
131
131
|
|
|
132
|
-
.feedback .
|
|
132
|
+
.feedback .devtools-link {
|
|
133
133
|
letter-spacing: 0.03em;
|
|
134
134
|
text-decoration-line: underline;
|
|
135
135
|
font-size: var(--sys-typescale-body4-size);
|
|
@@ -138,8 +138,8 @@ devtools-recording-list-view {
|
|
|
138
138
|
outline-offset: 3px;
|
|
139
139
|
}
|
|
140
140
|
|
|
141
|
-
.feedback .
|
|
142
|
-
.empty-state-description .
|
|
141
|
+
.feedback .devtools-link:focus-visible,
|
|
142
|
+
.empty-state-description .devtools-link:focus-visible {
|
|
143
143
|
outline: -webkit-focus-ring-color auto 1px;
|
|
144
144
|
}
|
|
145
145
|
|
|
@@ -482,26 +482,26 @@ export class CookieReportView extends UI.Widget.VBox {
|
|
|
482
482
|
|
|
483
483
|
switch (insight.type) {
|
|
484
484
|
case Protocol.Audits.InsightType.GitHubResource: {
|
|
485
|
-
const githubLink =
|
|
486
|
-
insight.tableEntryUrl
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
i18nString(UIStrings.guidance), undefined, undefined, 'readiness-list-link');
|
|
485
|
+
const githubLink = html`<devtools-link href=${
|
|
486
|
+
insight.tableEntryUrl ??
|
|
487
|
+
'https://github.com/privacysandbox/privacy-sandbox-dev-support/blob/main/3pc-migration-readiness.md'} .jslogContext=${
|
|
488
|
+
'readiness-list-link'}>${i18nString(UIStrings.guidance)}</devtools-link>`;
|
|
490
489
|
|
|
491
|
-
return html`${uiI18n.
|
|
490
|
+
return html`${uiI18n.getFormatLocalizedStringTemplate(str_, UIStrings.gitHubResource, {
|
|
492
491
|
PH1: githubLink,
|
|
493
492
|
})}`;
|
|
494
493
|
}
|
|
495
494
|
case Protocol.Audits.InsightType.GracePeriod: {
|
|
496
495
|
const url = SDK.TargetManager.TargetManager.instance().primaryPageTarget()?.inspectedURL();
|
|
497
|
-
const gracePeriodLink =
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
496
|
+
const gracePeriodLink = html`<devtools-link
|
|
497
|
+
href=${
|
|
498
|
+
'https://developers.google.com/privacy-sandbox/cookies/dashboard?url=' +
|
|
499
|
+
// The order of the URLs matters - needs to be 1P + 3P.
|
|
500
|
+
(url ? Common.ParsedURL.ParsedURL.fromString(url)?.host + '+' : '') +
|
|
501
|
+
(domain.charAt(0) === '.' ? domain.substring(1) : domain)}
|
|
502
|
+
.jslogContext=${'compatibility-lookup-link'}>${i18nString(UIStrings.reportedIssues)}</devtools-link>`;
|
|
503
|
+
|
|
504
|
+
return html`${uiI18n.getFormatLocalizedStringTemplate(str_, UIStrings.gracePeriod, {
|
|
505
505
|
PH1: gracePeriodLink,
|
|
506
506
|
})}`;
|
|
507
507
|
}
|