import type { IPlugin, IPluginDesc } from './interfaces'; import type { IUser } from '../security'; export const EP_PHOVEA_CORE_LOGIN = 'epPhoveaCoreLogin'; export const EP_PHOVEA_CORE_LOGOUT = 'epPhoveaCoreLogout'; export const EP_PHOVEA_CORE_LOCALE = 'epPhoveaCoreLocale'; export const EXTENSION_POINT_VISYN_VIEW = 'visynView'; export interface ILoginExtensionPoint { /** * @param user {IUser} The user object that was logged in */ factory(user: IUser): void; } export interface ILoginExtensionPointDesc extends IPluginDesc { load(): Promise; } export interface ILogoutEP { factory(): void; } export interface ILogoutEPDesc extends IPluginDesc { load(): Promise; } export interface ILocaleEPDesc extends IPluginDesc { /** * Locale namespace that usually matches the resource filename (e.g., `phovea` and `phovea.json`) */ ns?: string; /** * Language following the [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag) (e.g., `en` or `en-US`) * Default value is `en`. */ lng?: string; /** * Order of the locales, if two locales with the same namespace and language are found. * Locales with a higher the order number override the locales with lower order numbers. * Default value is `0`. */ order?: number; }