import { DisposableStore } from "../../../../../base/common/lifecycle.js"; import { IObservable } from "../../../../../base/common/observable.js"; import { ICommandService } from "../../../../../platform/commands/common/commands.service.js"; import { IConfigurationService } from "../../../../../platform/configuration/common/configuration.service.js"; import { IDefaultAccountService } from "../../../../../platform/defaultAccount/common/defaultAccount.service.js"; import { ITelemetryService } from "../../../../../platform/telemetry/common/telemetry.service.js"; import { IChatEntitlementService } from "../../../../services/chat/common/chatEntitlementService.service.js"; export interface IAgentsBannerResult { readonly element: HTMLElement; readonly disposables: DisposableStore; /** Whether the banner is shown, see {@link canShowAgentsBanner}. */ readonly visible: IObservable; } /** Returns whether the desktop Agents window is available and agent mode and AI features are enabled. */ export declare function canShowAgentsBanner(chatEntitlementService: IChatEntitlementService, configurationService: IConfigurationService): boolean; export interface IAgentsBannerOptions { /** Dot-separated CSS classes for the banner container (e.g. 'my-banner' or 'foo.bar'). */ readonly cssClass: string; /** Identifies where the banner is displayed (e.g. 'welcomePage', 'agentSessionsWelcome'). */ readonly source: "welcomePage" | "agentSessionsWelcome"; /** Override the default button label. */ readonly label?: string; /** Optional callback invoked when the banner opens the Agents window. */ readonly onButtonClick?: () => void; /** * Shows the experimental graphic selected by {@link ChatConfiguration.WelcomePageAgentsWindowGraphic} * above the button, so that it hides together with the button. The setting's experiment trigger is * logged in every experiment arm once the banner is visible while `isExposed` is true, that is, when * the user could see the graphic. * * The trigger of {@link ChatConfiguration.WelcomePageAgentsWindowSectionStyle} is logged in the same * moment once `shownDesign` has a value, since that style only applies while a graphic is shown. It * doesn't wait for the page to decide whether the graphic fits, because the style changes that decision. */ readonly graphic?: { readonly element: HTMLElement; readonly shownDesign: IObservable; readonly isExposed: IObservable; }; } /** * Creates a button that opens the Agents window, or offers GitHub sign-in when enabled and an account service is provided. */ export declare function createAgentsBanner(options: IAgentsBannerOptions, commandService: ICommandService, telemetryService: ITelemetryService, configurationService: IConfigurationService, chatEntitlementService: IChatEntitlementService, defaultAccountService?: IDefaultAccountService): IAgentsBannerResult;