Files
sorsfonalak/services/frontend/src/google.d.ts
T

34 lines
949 B
TypeScript
Raw Normal View History

// The part of Google Identity Services (accounts.google.com/gsi/client) we use.
interface GoogleCredentialResponse {
credential: string;
}
interface Window {
google?: {
accounts: {
id: {
initialize(options: {
client_id: string;
callback: (response: GoogleCredentialResponse) => void;
ux_mode?: "popup" | "redirect";
auto_select?: boolean;
itp_support?: boolean;
}): void;
renderButton(
parent: HTMLElement,
options: {
type?: "standard" | "icon";
theme?: "outline" | "filled_blue" | "filled_black";
size?: "large" | "medium" | "small";
text?: "signin_with" | "signup_with" | "continue_with" | "signin";
shape?: "rectangular" | "pill";
locale?: string;
width?: number;
},
): void;
disableAutoSelect(): void;
};
};
};
}