UNPKG

@syncfusion/react-base

Version:

A common package of core React base, methods and class definitions

80 lines (79 loc) 2.2 kB
export declare const componentList: string[]; export declare const pdfViewerSDKComponents: string[]; export declare const spreadsheetEditorSDKComponents: string[]; export declare const wordEditorSDKComponents: string[]; export type ILicenseValidator = { isLicensed: boolean; version: string; platform: RegExp; errors: IErrorType; validate: (component: string) => boolean; getDecryptedData: (key: string) => string; getInfoFromKey: () => IValidator[]; }; /** * License validation module * * @private * @param {string} key - License key to validate * @returns {LicenseValidator} License validator object * @private */ export declare function LicenseValidator(key?: string): ILicenseValidator; /** * Converts the given number to characters. * * @private * @param {number} cArr - Specifies the license key as number. * @returns {string} ? */ export declare function convertToChar(cArr: number[]): string; /** * To set license key. * * @param {string} key - license key * @returns {void} */ export declare function registerLicense(key: string): void; /** * Validates the license key. * * @private * @param {string} component - Specifies the component name. * @param {string} [key] - Optional license key to validate * @returns {boolean} Returns true if license is valid, false otherwise */ export declare function validateLicense(component: string, key?: string): boolean; /** * Gets the version information from the license validator. * * @private * @returns {string} The version string from the license validator */ export declare function getVersion(): string; /** * Method for create overlay over the sample * * @private * @returns {void} */ export declare function createLicenseOverlay(): void; interface IValidator { prefixRegex?: string; incorrectPlatform?: string; version?: string; expiryDate?: string; platform?: string; invalidPlatform?: boolean; lastValue?: number; minVersion?: number; } interface IErrorType { noLicense: string; trailExpired: string; versionMismatched: string; platformMismatched: string; invalidKey: string; componentRestricted: string; } export {};