UNPKG

chrome-devtools-frontend

Version:
45 lines (40 loc) 1.48 kB
// Copyright 2026 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. import type * as Common from '../../core/common/common.js'; import type * as Host from '../../core/host/host.js'; import type * as Platform from '../../core/platform/platform.js'; export type CategoryId = 'performance'|'accessibility'|'best-practices'|'seo'; export type RunMode = 'navigation'|'timespan'|'snapshot'; export interface Preset { setting: Common.Settings.Setting<boolean>; configID: CategoryId; title: () => Common.UIString.LocalizedString; description: () => Common.UIString.LocalizedString; supportedModes: string[]; userMetric: Host.UserMetrics.LighthouseCategoryUsed; } export interface RuntimeSetting { setting: Common.Settings.Setting<string|boolean>; description: () => Common.UIString.LocalizedString; setFlags: (flags: Flags, value: string|boolean) => void; options?: Array<{ label: () => Common.UIString.LocalizedString, value: string, tooltip?: () => Common.UIString.LocalizedString, }>; title?: () => Common.UIString.LocalizedString; learnMore?: Platform.DevToolsPath.UrlString; } export interface Flags { additionalTraceCategories?: string; disableStorageReset?: boolean; throttlingMethod?: string; formFactor?: string|boolean; mode?: RunMode; } export interface RunOverrides { categoryIds?: CategoryId[]; mode?: RunMode; isAIControlled?: boolean; }