55 lines
2.3 KiB
TypeScript
55 lines
2.3 KiB
TypeScript
/// <reference path="../.astro/types.d.ts" />
|
|
|
|
declare global {
|
|
interface Window {
|
|
themeUtils: {
|
|
initTheme: () => void;
|
|
toggleTheme: () => void;
|
|
getStoredTheme: () => string;
|
|
};
|
|
toolsData: any[];
|
|
showToolDetails: (toolName: string, modalType?: string) => void;
|
|
hideToolDetails: (modalType?: string) => void;
|
|
hideAllToolDetails: () => void;
|
|
matrixShowToolDetails?: (toolName: string, modalType?: string) => void;
|
|
matrixHideToolDetails?: (modalType?: string) => void;
|
|
|
|
toggleKbEntry: (entryId: string) => void;
|
|
toggleDomainAgnosticSection: (sectionId: string) => void;
|
|
restoreAIResults?: () => void;
|
|
switchToAIView?: () => void;
|
|
clearTagFilters?: () => void;
|
|
clearAllFilters?: () => void;
|
|
|
|
createToolSlug: (toolName: string) => string;
|
|
findToolByIdentifier: (tools: any[], identifier: string) => any | undefined;
|
|
isToolHosted: (tool: any) => boolean;
|
|
|
|
checkClientAuth: (context?: 'contributions' | 'ai' | 'general' | 'gatedcontent') => Promise<{authenticated: boolean; authRequired: boolean; expires?: string}>;
|
|
requireClientAuth: (callback?: () => void, returnUrl?: string, context?: 'contributions' | 'ai' | 'general' | 'gatedcontent') => Promise<boolean>;
|
|
showIfAuthenticated: (selector: string, context?: 'contributions' | 'ai' | 'general' | 'gatedcontent') => Promise<void>;
|
|
setupAuthButtons: (selector?: string) => void;
|
|
|
|
scrollToElement: (element: Element | null, options?: ScrollIntoViewOptions) => void;
|
|
scrollToElementById: (elementId: string, options?: ScrollIntoViewOptions) => void;
|
|
scrollToElementBySelector: (selector: string, options?: ScrollIntoViewOptions) => void;
|
|
|
|
applyScenarioSearch?: (scenarioId: string) => void;
|
|
selectPhase?: (phase: string) => void;
|
|
selectApproach?: (approach: string) => void;
|
|
navigateToGrid?: (toolName: string) => void;
|
|
navigateToMatrix?: (toolName: string) => void;
|
|
toggleAllScenarios?: () => void;
|
|
showShareDialog?: (shareButton: Element) => void;
|
|
modalHideInProgress?: boolean;
|
|
|
|
shareArticle: (button: HTMLElement, url: string, title: string) => Promise<void>;
|
|
shareCurrentArticle: (button: HTMLElement) => Promise<void>;
|
|
}
|
|
}
|
|
|
|
declare module 'js-yaml' {
|
|
export function load(str: string): any;
|
|
}
|
|
|
|
export {}; |