ci: move public-api goldens to goldens directory (#35768)
Moves the public api .d.ts files from tools/public_api_guard to goldens/public-api. Additionally, provides a README in the goldens directory and a script assist in testing the current state of the repo against the goldens as well as a command for accepting all changes to the goldens in a single command. PR Close #35768
This commit is contained in:

committed by
Matias Niemelä

parent
19cfaf7f4c
commit
15f8afa4bf
59
goldens/public-api/service-worker/service-worker.d.ts
vendored
Normal file
59
goldens/public-api/service-worker/service-worker.d.ts
vendored
Normal file
@ -0,0 +1,59 @@
|
||||
export declare class ServiceWorkerModule {
|
||||
static register(script: string, opts?: SwRegistrationOptions): ModuleWithProviders<ServiceWorkerModule>;
|
||||
}
|
||||
|
||||
export declare class SwPush {
|
||||
get isEnabled(): boolean;
|
||||
readonly messages: Observable<object>;
|
||||
readonly notificationClicks: Observable<{
|
||||
action: string;
|
||||
notification: NotificationOptions & {
|
||||
title: string;
|
||||
};
|
||||
}>;
|
||||
readonly subscription: Observable<PushSubscription | null>;
|
||||
constructor(sw: ɵangular_packages_service_worker_service_worker_a);
|
||||
requestSubscription(options: {
|
||||
serverPublicKey: string;
|
||||
}): Promise<PushSubscription>;
|
||||
unsubscribe(): Promise<void>;
|
||||
}
|
||||
|
||||
export declare abstract class SwRegistrationOptions {
|
||||
enabled?: boolean;
|
||||
registrationStrategy?: string | (() => Observable<unknown>);
|
||||
scope?: string;
|
||||
}
|
||||
|
||||
export declare class SwUpdate {
|
||||
readonly activated: Observable<UpdateActivatedEvent>;
|
||||
readonly available: Observable<UpdateAvailableEvent>;
|
||||
get isEnabled(): boolean;
|
||||
constructor(sw: ɵangular_packages_service_worker_service_worker_a);
|
||||
activateUpdate(): Promise<void>;
|
||||
checkForUpdate(): Promise<void>;
|
||||
}
|
||||
|
||||
export declare interface UpdateActivatedEvent {
|
||||
current: {
|
||||
hash: string;
|
||||
appData?: Object;
|
||||
};
|
||||
previous?: {
|
||||
hash: string;
|
||||
appData?: Object;
|
||||
};
|
||||
type: 'UPDATE_ACTIVATED';
|
||||
}
|
||||
|
||||
export declare interface UpdateAvailableEvent {
|
||||
available: {
|
||||
hash: string;
|
||||
appData?: Object;
|
||||
};
|
||||
current: {
|
||||
hash: string;
|
||||
appData?: Object;
|
||||
};
|
||||
type: 'UPDATE_AVAILABLE';
|
||||
}
|
Reference in New Issue
Block a user