saltfish
Version:
An interactive video-guided tour system for web applications
23 lines • 1.16 kB
TypeScript
import type { UrlRequirement } from '../types';
/**
* Removes the saltfish-share-id parameter from a URL
* Share IDs should not affect URL matching since they're metadata for starting playlists
* @param url - The URL to clean
* @returns The URL without the saltfish-share-id parameter
*/
export declare function stripShareIdFromUrl(url: string): string;
/**
* Validates if the current URL matches a URL requirement
* @param urlRequirement - The URL requirement to validate against
* @returns true if URL matches, false otherwise
*/
export declare function validateUrlRequirement(urlRequirement: UrlRequirement): boolean;
/**
* Validates URL requirement with retry logic for SPA navigation
* @param urlRequirement - The URL requirement to validate
* @param maxRetries - Maximum number of retry attempts (default: 20)
* @param retryDelay - Delay between retries in ms (default: 100)
* @returns Promise<boolean> - true if validation passes, false otherwise
*/
export declare function validateUrlRequirementWithRetry(urlRequirement: UrlRequirement, maxRetries?: number, retryDelay?: number): Promise<boolean>;
//# sourceMappingURL=urlValidation.d.ts.map