import * as _angular_core from '@angular/core'; import { Type, InjectionToken } from '@angular/core'; import { TooltipPosition } from '@angular/material/tooltip'; import { Document } from '@contentful/rich-text-types'; import { ValidatorFn, AbstractControl, ValidationErrors } from '@angular/forms'; type Brand = K & { __brand: T; }; type Permission = Brand; type Resource = Brand; type Domain = Brand; type FieldName = Brand; type Method = Brand; type UserPermissionCollection = Record>>; type RolePermissionCollection = Partial>; interface PermissionScope { resource: Resource | Method; permission: Permission; domain: Domain; } declare const ReadPermission: Permission; declare const UpdatePermission: Permission; type ValidDisplayTypes = 'boolean' | 'nullboolean' | 'number' | 'string' | 'date' | 'enumerated' | 'link' | 'uuid' | 'civildate' | 'string[]' | 'customtypes.attachment[]' | 'customtypes.contentfuldocument'; type ValidRPCTypes = ValidDisplayTypes | `${Exclude}[]`; interface RPCFieldMeta { fieldName: string; displayType: ValidRPCTypes; enumeratedResource?: Resource; } interface MethodMeta { route: string; fields: RPCFieldMeta[]; } interface FieldMeta { fieldName: string; /** Indicates whether the field is required and only applies during resource creation. * Use the validators config parameter in all other contexts */ required: boolean; primaryKey?: { ordinalPosition: number; }; displayType: ValidDisplayTypes; enumeratedResource?: Resource; isIndex: boolean; } interface ResourceMeta { route: string; consolidatedRoute?: string; listDisabled?: boolean; readDisabled?: boolean; createDisabled?: boolean; updateDisabled?: boolean; deleteDisabled?: boolean; substringSearchParameter?: string; fields: FieldMeta[]; } type Meta = MethodMeta | ResourceMeta; declare namespace CustomTypes { interface Attachment { title: string; url: string; contentType: string; } type ContentfulDocument = Document; } declare const defaultEmptyFieldValue = "-"; type NullBoolean = null | true | false; type ConcatFn = 'space-concat' | 'hyphen-concat' | 'space-hyphen-concat' | 'hyphen-space-concat'; declare const validatorsPresent: (control: AbstractControl, validators: ValidatorFn[], previousValidatorCount: number) => boolean; declare const requiredIf: (predicate: () => boolean, validator: ValidatorFn) => (formControl: AbstractControl) => ValidationErrors | null; declare const __singletonValidatorBrand: unique symbol; type ResourceValidatorFn = ValidatorFn & { readonly [__singletonValidatorBrand]: true; }; declare function createResourceValidator(validator: ValidatorFn): ResourceValidatorFn; type ResourceMap = Record; interface FieldPointer { field: FieldName; } interface MenuItem { label: string; route?: string[]; children?: MenuItem[]; } interface RouteResourceData { config: RootConfig; } type DataType = string | number | number[] | string[] | boolean | undefined | Date; type RecordData = Record; type RPCDataType = string | number | string[] | number[] | boolean | Date; type RPCRecordData = Record; type RpcMethod = Record; type ParentResourceConfig = ListViewConfig | ViewConfig | ArrayConfig; type ChildResourceConfig = ListViewConfig | ViewConfig | ComponentConfig | ArrayConfig; type ActionType = 'function' | 'link'; type ListConcatFn = 'space-concat' | 'hyphen-concat' | 'space-hyphen-concat' | 'hyphen-space-concat' | 'no-space-concat'; type ConfigType = ChildResourceConfig; type FormatType = 'simpleSlashDateFormat'; type RPCPlacement = 'inline' | 'end'; type ColumnConfig = SingleColumnConfig | MultiColumnConfig; interface ActionButtonConfig { label: string; icon: string; action?: (resource: { id: string; }) => void; viewRoute?: string; actionType?: ActionType; color?: string; disabledLabel?: string; } interface ActionButtonConfigOptions { label: string; icon: string; action?: (resource: { id: string; }) => void; viewRoute?: string; actionType?: ActionType; color?: string; disabledLabel?: string; } declare function actionButtonConfig(config: ActionButtonConfigOptions): ActionButtonConfig; declare const actionButtonConfigDefaults: { label: string; icon: string; actionType: ActionType; color: string; disabledLabel: string; }; interface ColumnIconConfig { icon: (row: RecordData) => string | null | undefined; tooltip?: (row: RecordData) => string; } interface SingleColumnConfig { id: FieldName; header?: string; width?: number; resizable?: boolean; valueGetter?: (data: any) => string; valueFormatter?: (data: any) => string; tooltipPosition?: TooltipPosition; viewRoute?: Resource; buttonConfig?: ActionButtonConfig; iconConfig?: ColumnIconConfig; actionType?: ActionType; formatType?: FormatType | string; hidden?: boolean; emptyDataValue?: DataType; filterable?: boolean; hideHeader?: boolean; } interface SingleColumnConfigOptions { id: FieldName; header?: string; width?: number; resizable?: boolean; valueGetter?: (data: any) => string; valueFormatter?: (data: any) => string; tooltipPosition?: TooltipPosition; viewRoute?: Resource; buttonConfig?: ActionButtonConfig; iconConfig?: ColumnIconConfig; actionType?: ActionType; formatType?: FormatType | string; hidden?: boolean; emptyDataValue?: DataType; filterable?: boolean; hideHeader?: boolean; } declare function singleColumnConfig(config: SingleColumnConfigOptions): SingleColumnConfig; declare const singleColumnConfigDefaults: { id: FieldName; header: string; resizable: true; actionType: ActionType; hidden: false; filterable: true; hideHeader: false; }; interface MultiColumnConfig extends SingleColumnConfig { additionalIds: AdditionalResourceConfig[]; concatFn: ListConcatFn; } interface MultiColumnConfigOptions extends SingleColumnConfigOptions { additionalIds: AdditionalResourceConfig[]; concatFn: ListConcatFn; } declare function multiColumnConfig(config: MultiColumnConfigOptions): MultiColumnConfig; declare const multiColumnConfigDefaults: { additionalIds: AdditionalResourceConfig[]; concatFn: ListConcatFn; id: FieldName; header: string; resizable: true; actionType: ActionType; hidden: false; filterable: true; hideHeader: false; }; interface AdditionalResourceConfig { resource?: Resource; id: FieldName; field?: FieldName; hidden?: boolean; } interface AdditionalResourceConfigOptions { id: FieldName; resource?: Resource; field?: FieldName; hidden?: boolean; } declare function additionalResourceConfig(config: AdditionalResourceConfigOptions): AdditionalResourceConfig; declare const additionalResourceConfigDefaults: { id: FieldName; resource: Resource; field: FieldName; hidden: false; }; interface FieldSort { field: FieldName; direction: 'asc' | 'desc'; } interface FieldSortOptions { field: FieldName; direction?: 'asc' | 'desc'; } declare function fieldSort(config: FieldSortOptions): FieldSort; declare const fieldSortDefaults: { field: FieldName; direction: "asc" | "desc"; }; interface EnumeratedConfigOptions { overrideResource?: Resource; filter?: (resource: any) => string; /** * Set disableCacheForFilterPii to `true` to promote the GET to a POST when PII is used in the filter * POST requests cannot be cached */ disableCacheForFilterPii?: boolean; /** * Specifies which resource data to pass to the filter function: * - 'rootResource': Pass in the root resource data * - 'parentResource': Pass in the parent resource data * @default 'parentResource' */ filterType?: FilterType; sorts?: FieldSort[]; listDisplay?: FieldName[]; viewDisplay: FieldName[]; viewConcatFn?: ConcatFn; listConcatFn?: ConcatFn; viewDetails?: boolean; searchable?: boolean; /** * The maximum number of options fetched for this enumerated field. * @default 10000 */ limit?: number; } type FilterType = 'parentResource' | 'rootResource'; interface EnumeratedConfig { overrideResource: Resource; filter: (resource: any) => string; disableCacheForFilterPii: boolean; filterType: FilterType; sorts: FieldSort[]; listDisplay: FieldName[]; viewDisplay: FieldName[]; viewConcatFn: ConcatFn; listConcatFn: ConcatFn; viewDetails: boolean; searchable: boolean; limit: number; } declare function enumeratedConfig(config: EnumeratedConfigOptions): EnumeratedConfig; declare const enumeratedFieldDefaultLimit = 10000; declare const enumeratedConfigDefaults: { overrideResource: Resource; filter: () => string; disableCacheForFilterPii: boolean; filterType: FilterType; sorts: FieldSort[]; listDisplay: FieldName[]; viewDisplay: FieldName[]; viewConcatFn: ConcatFn; listConcatFn: ConcatFn; viewDetails: boolean; searchable: boolean; limit: number; }; type FieldDefault = ForeignKeyDefault | StaticDefault | null; interface NullBooleanConfigOptions { displayValues?: Record<'null' | 'true' | 'false', { label: string; value: NullBoolean; }>; } interface NullBooleanConfig { /** This property maps the three possible values for this * nullboolean field with the display values users will see * on the screen for each */ displayValues: Record<'null' | 'true' | 'false', { label: string; value: NullBoolean; }>; } declare function nullBooleanConfig(config: NullBooleanConfigOptions): NullBooleanConfig; declare const nullBooleanConfigDefaults: { displayValues: Readonly<{ null: { label: string; value: null; }; true: { label: string; value: boolean; }; false: { label: string; value: boolean; }; }>; }; interface ForeignKeyDefaultOptions { parentId: FieldName; } interface ForeignKeyDefault { type: 'foreignKey'; parentId: FieldName; } declare function foreignKeyDefault(config: ForeignKeyDefaultOptions): ForeignKeyDefault; declare const foreignKeyDefaultDefaults: { type: "foreignKey"; parentId: FieldName; }; interface StaticDefault { type: 'static'; value: string | boolean; } interface staticDefaultOptions { value: string | boolean; } declare function staticDefault(config: staticDefaultOptions): StaticDefault; declare const staticDefaultDefaults: { type: "static"; value: string; }; type Affix = string | remoteData | parentData; interface remoteData { resource: Resource; id: FieldName; field: FieldName; } interface parentData { field: FieldName; } type ConfigElement = FieldElement | SectionElement | ComputedDisplayFieldElement | PaddingElement; type ColSize = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12; interface ComputedDisplayFieldElementOptions { label?: string; class?: string; cols?: ColSize; calculatedValue?: (data: any) => string; shouldRender?: ((data: any) => boolean) | boolean; } interface ComputedDisplayFieldElement { type: 'computedDisplayField'; label: string; class: string; cols: ColSize; calculatedValue: (data: any) => string; shouldRender: ((data: any) => boolean) | boolean; } declare function computedDisplayField(config: ComputedDisplayFieldElementOptions): ComputedDisplayFieldElement; declare const computedDisplayFieldElementDefaults: { type: "computedDisplayField"; label: string; class: string; cols: 6; calculatedValue: () => string; shouldRender: true; }; interface PaddingElementOptions { cols?: ColSize; shouldRender?: ((data: any) => boolean) | boolean; } interface PaddingElement { type: 'padding'; cols: ColSize; /** Determines whether the padding is shown */ shouldRender: ((data: any) => boolean) | boolean; } declare function padding(config?: PaddingElementOptions): PaddingElement; declare const paddingElementDefaults: { type: "padding"; cols: 12; shouldRender: true; }; interface SectionElementOptions { label?: string; class?: string; cols?: ColSize; shouldRender?: ((data: any) => boolean) | boolean; nullAllChildrenIfConditionallyHidden?: boolean; children?: ConfigElement[]; } interface SectionElement { type: 'section'; label: string; class: string; cols: ColSize; /** * shouldRender is used to determine if the section should be * displayed to users. * When assigning shouldRender a function, the first argument * is the current state of the resource being displayed * Hides the layout AND all of its children */ shouldRender: ((data: any) => boolean) | boolean; /** If shouldRender is NOT a function, this property does nothing * If shouldRender is a function, this property * sets children's values to null if shouldRender hides it (returns false) * within the resource-layout.component */ nullAllChildrenIfConditionallyHidden: boolean; children: ConfigElement[]; } declare function section(config: SectionElementOptions): SectionElement; declare const sectionElementDefaults: { type: "section"; label: string; class: string; cols: 12; shouldRender: true; nullAllChildrenIfConditionallyHidden: false; children: never[]; }; interface FieldElementOptions { name: FieldName; label?: string; cols?: ColSize; class?: string; enumeratedConfig?: EnumeratedConfig; default?: FieldDefault; nullBooleanConfig?: NullBooleanConfig; validators?: ((data: any) => ResourceValidatorFn[]) | ResourceValidatorFn[]; readOnly?: boolean; prefixes?: Affix[]; suffixes?: Affix[]; shouldRender?: ((data: any) => boolean) | boolean; nullIfConditionallyHidden?: boolean; } interface FieldElement { type: 'field'; name: string; label: string; cols: ColSize; class: string; enumeratedConfig: EnumeratedConfig; default: FieldDefault; nullBooleanConfig: NullBooleanConfig; /** * A list of validators that must pass to allow a field to be submitted. * Utilize existing validators in the resourceValidators object, and * add any new or custom validators to it */ validators: ((data: any) => ResourceValidatorFn[]) | ResourceValidatorFn[]; readOnly: boolean; prefixes: Affix[]; suffixes: Affix[]; /** * shouldRender is used to determine if the element should be * displayed to users. * When assigning shouldRender a function, the first argument * is the current state of the resource being displayed */ shouldRender: ((data: any) => boolean) | boolean; /** If shouldRender is NOT a function, this property does nothing * If shouldRender is a function, this property * determines whether the form control associated * with this config element should have its value * set to null if shouldRender hides it (returns false) */ nullIfConditionallyHidden: boolean; } declare function field(config: FieldElementOptions): FieldElement; declare const fieldElementDefaults: { type: "field"; name: string; label: string; cols: 6; class: string; enumeratedConfig: { overrideResource: Resource; filter: () => string; disableCacheForFilterPii: boolean; filterType: FilterType; sorts: FieldSort[]; listDisplay: FieldName[]; viewDisplay: FieldName[]; viewConcatFn: ConcatFn; listConcatFn: ConcatFn; viewDetails: boolean; searchable: boolean; limit: number; }; default: null; validators: never[]; nullBooleanConfig: { displayValues: Readonly<{ null: { label: string; value: null; }; true: { label: string; value: boolean; }; false: { label: string; value: boolean; }; }>; }; readOnly: false; prefixes: never[]; suffixes: never[]; shouldRender: true; nullIfConditionallyHidden: false; }; /** * RouteData is used to define the route for a config * route: the route for the config * hasViewRoute: when true, a route will be created for route/:uuid */ interface RootRouteData { route?: string; hasViewRoute?: boolean; } interface RPCConfigOptions { label: string; afterMethodRedirect?: string; conditions: { field: FieldName; matchValues: string[]; }[]; methodBodyTemplate?: any; successMessage?: string; elements?: ConfigElement[]; placement?: RPCPlacement; method: Method; customComponent?: ComponentConfig; refreshResources?: Resource[]; defaultModalWidth?: string; shouldRender?: () => boolean; } interface RPCConfig { label: string; afterMethodRedirect: string | string[]; conditions: { field: FieldName; matchValues: string[]; }[]; methodBodyTemplate: any; method: Method; successMessage: string; elements: ConfigElement[]; placement: RPCPlacement; customComponent: ComponentConfig; refreshResources: Resource[]; defaultModalWidth: string; shouldRender: () => boolean; } declare function rpcConfig(config: RPCConfigOptions): RPCConfig; declare const rpcConfigDefaults: { label: string; afterMethodRedirect: string; conditions: { field: FieldName; matchValues: string[]; }[]; methodBodyTemplate: any; successMessage: string; elements: ConfigElement[]; placement: RPCPlacement; method: Method; customComponent: ComponentConfig; refreshResources: Resource[]; defaultModalWidth: string; shouldRender: () => boolean; }; interface RPCBaseFormData { elements: FieldElement[]; label: string; method: Method; } interface RootConfigOptions { routeData?: RootRouteData; nav?: { navItem: MenuItem; group?: string; }; parentConfig: ParentResourceConfig; relatedConfigs?: ChildResourceConfig[]; rpcConfigs?: RPCConfig[]; } interface RootConfig { routeData: RootRouteData; nav: { navItem: MenuItem; group?: string; }; parentConfig: ParentResourceConfig; relatedConfigs: ChildResourceConfig[]; rpcConfigs?: RPCConfig[]; } declare const rootConfigDefaults: { routeData: RootRouteData; nav: { navItem: MenuItem; }; parentConfig: ParentResourceConfig; relatedConfigs: ChildResourceConfig[]; rpcConfigs: RPCConfig[]; }; declare function rootConfig(config: RootConfigOptions): RootConfig; interface BaseConfigOptions { title?: string; createTitle?: string; createButtonLabel?: string; primaryResource: Resource; parentClass?: string; fieldClass?: string; elements: ConfigElement[]; createConfig?: ConfigType; parentRelation?: { parentKey: FieldName; childKey: FieldName; }; showBackButton?: boolean; createNavigation?: string[]; } interface BaseConfig { title: string; createTitle: string; createButtonLabel: string; primaryResource: Resource; parentClass: string; fieldClass: string; elements: ConfigElement[]; createConfig: ConfigType; parentRelation: { parentKey: FieldName; childKey: FieldName; }; showBackButton: boolean; createNavigation: string[]; } declare abstract class CustomConfigComponent { uuid: _angular_core.InputSignal; parentData: _angular_core.InputSignal; config: _angular_core.InputSignal; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } type ConfigParam = SwitchConfigParam; interface ComponentConfigOptions { primaryResource: Resource; component: Type | 'SwitchResolver'; params?: ConfigParam; relatedConfig?: ParentResourceConfig[]; shouldRenderActions?: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; } interface ComponentConfig { type: 'Component'; primaryResource: Resource; component: Type | 'SwitchResolver'; params: ConfigParam; relatedConfig: ParentResourceConfig[]; shouldRenderActions: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; } declare function componentConfig(config: ComponentConfigOptions): ComponentConfig; declare const componentConfigDefaults: { type: "Component"; primaryResource: Resource; component: "SwitchResolver"; params: { cases: never[]; }; relatedConfig: ParentResourceConfig[]; shouldRenderActions: { create: () => boolean; edit: () => boolean; delete: () => boolean; }; }; interface switchCase { caseId: string; parentField: string; childId: string; config: ChildResourceConfig; } interface SwitchConfigParamOptions { cases: switchCase[]; } interface SwitchConfigParam { cases: switchCase[]; } declare function switchParams(config: SwitchConfigParamOptions): SwitchConfigParam; declare const switchParamsDefaults: { cases: switchCase[]; }; interface ListViewConfigOptions extends BaseConfigOptions { showViewButton?: boolean; loadCreatedResource?: boolean; collapsible?: boolean; overrideResource?: Resource; searchable?: boolean; enableRowExpansion?: boolean; rowExpansionConfig?: ChildResourceConfig; requireSearchToDisplayResults?: boolean; listColumns: ColumnConfig[]; relatedConfigs?: ChildResourceConfig[]; viewResource?: Resource | string; actionType?: ActionType; filter?: (parentResource: any) => string; disableCacheForFilterPii?: boolean; rpcConfigs?: RPCConfig[]; sorts?: FieldSort[]; limit?: number; shouldRenderActions?: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; showRowCount?: boolean; pageSize?: number; } interface ListViewConfig extends BaseConfig { type: 'ListView'; showViewButton: boolean; loadCreatedResource: boolean; collapsible: boolean; overrideResource: Resource; searchable: boolean; enableRowExpansion: boolean; rowExpansionConfig: ChildResourceConfig; requireSearchToDisplayResults: boolean; listColumns: ColumnConfig[]; relatedConfigs: ChildResourceConfig[]; viewResource: Resource | string; actionType: ActionType; filter: (parentResource: any) => string; disableCacheForFilterPii: boolean; rpcConfigs?: RPCConfig[]; sorts: FieldSort[]; limit?: number; shouldRenderActions: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; showRowCount: boolean; pageSize?: number; } declare function listViewConfig(config: ListViewConfigOptions): ListViewConfig; declare const listViewConfigDefaults: { title: string; primaryResource: Resource; type: "ListView"; createTitle: string; createButtonLabel: string; loadCreatedResource: false; showViewButton: true; collapsible: false; listColumns: never[]; elements: never[]; parentClass: string; fieldClass: string; createConfig: ListViewConfig; createNavigation: never[]; relatedConfigs: never[]; parentRelation: { parentKey: FieldName; childKey: FieldName; }; overrideResource: Resource; searchable: false; enableRowExpansion: false; rowExpansionConfig: ChildResourceConfig; requireSearchToDisplayResults: false; showBackButton: true; filter: () => string; disableCacheForFilterPii: false; sorts: FieldSort[]; limit: undefined; viewResource: Resource; actionType: ActionType; rpcConfigs: never[]; shouldRenderActions: { create: () => boolean; edit: () => boolean; delete: () => boolean; }; showRowCount: true; }; type ViewType = 'OneToOne' | 'OneToMany'; interface ViewConfigOptions extends BaseConfigOptions { collapsible?: boolean; connectorResource?: Resource; relatedConfigs?: ChildResourceConfig[]; rpcConfigs?: RPCConfig[]; shouldRenderActions?: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; } interface ViewConfig extends BaseConfig { type: 'View'; collapsible: boolean; connectorResource: Resource; rpcConfigs?: RPCConfig[]; relatedConfigs: ChildResourceConfig[]; /** A set of functions that allows for * conditional display of non-RPC * actions based on the pristine state of the resource * (if such a state is applicable. Creation for example won't * have such data) * This is separate from ABAC control which takes * precedence and is based on a user's attributes */ shouldRenderActions: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; } declare function viewConfig(config: ViewConfigOptions): ViewConfig; declare const viewConfigDefaults: { title: string; primaryResource: Resource; type: "View"; createTitle: string; createButtonLabel: string; parentClass: string; fieldClass: string; elements: never[]; collapsible: true; connectorResource: Resource; relatedConfigs: never[]; createConfig: ViewConfig; shouldRenderActions: { create: () => boolean; edit: () => boolean; delete: () => boolean; }; createNavigation: never[]; parentRelation: { parentKey: FieldName; childKey: FieldName; }; showBackButton: true; rpcConfigs: never[]; }; interface arrayConfigOptions { iteratedConfig: ChildResourceConfig; viewType?: ViewType; collapsible?: boolean; createConfig?: ConfigType; connectorResource?: Resource; connectorField?: FieldName; primaryResource: Resource; listFilter: (parentResource: any) => string; disableCacheForFilterPii?: boolean; sorts?: FieldSort[]; title?: string; createButtonLabel?: string; limit?: number; shouldRenderActions?: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; } interface ArrayConfig { type: 'Array'; iteratedConfig: ChildResourceConfig; viewType: ViewType; collapsible: boolean; createConfig: ConfigType; connectorResource: Resource; connectorField: FieldName; primaryResource: Resource; listFilter: (parentResource: any) => string; disableCacheForFilterPii: boolean; sorts: FieldSort[]; title: string; createButtonLabel: string; shouldRenderActions: Record<'edit' | 'delete' | 'create', (data: any) => boolean>; limit: number; } declare function arrayConfig(config: arrayConfigOptions): ArrayConfig; declare const arrayConfigDefaults: { type: "Array"; iteratedConfig: ChildResourceConfig; viewType: ViewType; collapsible: true; createConfig: ViewConfig; connectorResource: Resource; connectorField: FieldName; primaryResource: Resource; listFilter: () => string; disableCacheForFilterPii: false; sorts: FieldSort[]; title: string; createButtonLabel: string; limit: number; shouldRenderActions: { create: () => boolean; edit: () => boolean; delete: () => boolean; }; }; declare enum AlertType { ERROR = "warn", IDLE = "idle", INFO = "accent", SUCCESS = "success" } interface CreateNotificationMessage { duration?: number; message: string; link: string; type: AlertType; } interface NotificationMessage { id: number; duration?: number; message: string; link: string; type: AlertType; } /** * Session Information for a logged in user */ interface SessionInfo { authenticated: boolean; username: string; permissions: UserPermissionCollection; additionalData?: TAdditional; } interface AdditionalSessionData { permissions: RolePermissionCollection | UserPermissionCollection; } /** * The base URL for API requests (e.g., 'https://api.example.com/'). * @defaultValue '/' */ declare const BASE_URL: InjectionToken; /** * The path to the frontend login page (e.g., '/login'). * @defaultValue '/login' */ declare const FRONTEND_LOGIN_PATH: InjectionToken; /** * The path to the session endpoint (e.g., 'user/session'). * @defaultValue 'user/session' */ declare const SESSION_PATH: InjectionToken; /** * The base URL for API requests (e.g., '/api'). * @defaultValue '/api' */ declare const API_URL: InjectionToken; /** * The URL for additional session data requests (e.g., 'user/session/custom-data'). * Optional token */ declare const ADDITIONAL_SESSION_DATA_PATH: InjectionToken; /** * A function to determine if a specific permission is required for a given resource. * @defaultValue a function that always returns false */ declare const PERMISSION_REQUIRED: InjectionToken<(resource: Resource, permission: Permission) => boolean>; /** * The available permissions in the system. * @defaultValue an empty array */ declare const AVAILABLE_PERMISSIONS: InjectionToken<{ Create: Permission; Delete: Permission; List: Permission; Read: Permission; Update: Permission; }>; declare const AVAILABLE_DOMAINS: InjectionToken[]>; /** * The generated resourceMeta from the output of the [ccc package](https://github.com/cccteam/ccc) typescript generator * Required to work with generated routes and resource metadata * @defaultValue a no-op function that returns an empty object */ declare const RESOURCE_META: InjectionToken<(resource: Resource) => ResourceMeta>; /** * The generated methodMeta from the output of the [ccc package](https://github.com/cccteam/ccc) typescript generator * Required to work with generated method data * @defaultValue a no-op function that returns an empty object */ declare const METHOD_META: InjectionToken<(method: string) => MethodMeta>; /** * The duration in seconds for the session to be considered idle. * @defaultValue 300 seconds */ declare const IDLE_SESSION_DURATION: InjectionToken; /** * The duration in seconds for the warning to be shown to the user before the session times out due to inactivity. * @defaultValue 60 seconds */ declare const IDLE_WARNING_DURATION: InjectionToken; /** * The duration in seconds for the keepalive ping to be sent to the server to keep the session alive. * @defaultValue 30 seconds */ declare const IDLE_KEEPALIVE_DURATION: InjectionToken; /** * A function to be called when the user logs out. * @defaultValue a no-op function that returns 0 */ declare const LOGOUT_ACTION: InjectionToken<() => void>; /** * A function to be called when the user is logged out due to inactivity. * @defaultValue a no-op function that returns 0 */ declare const IDLE_LOGOUT_ACTION: InjectionToken<() => void>; /** * When true, user activity (mouse movement, keypress, etc.) will NOT reset the idle timer once the warning is shown. * The user must explicitly call `stayLoggedIn()` (e.g. via a modal button) to reset the timer. * When false (default), any activity resets the idle timer as usual. * @defaultValue false */ declare const IDLE_TIMEOUT_REQUIRE_CONFIRMATION: InjectionToken; export { ADDITIONAL_SESSION_DATA_PATH, API_URL, AVAILABLE_DOMAINS, AVAILABLE_PERMISSIONS, AlertType, BASE_URL, CustomConfigComponent, CustomTypes, FRONTEND_LOGIN_PATH, IDLE_KEEPALIVE_DURATION, IDLE_LOGOUT_ACTION, IDLE_SESSION_DURATION, IDLE_TIMEOUT_REQUIRE_CONFIRMATION, IDLE_WARNING_DURATION, LOGOUT_ACTION, METHOD_META, PERMISSION_REQUIRED, RESOURCE_META, ReadPermission, SESSION_PATH, UpdatePermission, actionButtonConfig, actionButtonConfigDefaults, additionalResourceConfig, additionalResourceConfigDefaults, arrayConfig, arrayConfigDefaults, componentConfig, componentConfigDefaults, computedDisplayField, computedDisplayFieldElementDefaults, createResourceValidator, defaultEmptyFieldValue, enumeratedConfig, enumeratedConfigDefaults, enumeratedFieldDefaultLimit, field, fieldElementDefaults, fieldSort, fieldSortDefaults, foreignKeyDefault, foreignKeyDefaultDefaults, listViewConfig, listViewConfigDefaults, multiColumnConfig, multiColumnConfigDefaults, nullBooleanConfig, nullBooleanConfigDefaults, padding, paddingElementDefaults, requiredIf, rootConfig, rootConfigDefaults, rpcConfig, rpcConfigDefaults, section, sectionElementDefaults, singleColumnConfig, singleColumnConfigDefaults, staticDefault, staticDefaultDefaults, switchParams, switchParamsDefaults, validatorsPresent, viewConfig, viewConfigDefaults }; export type { ActionButtonConfig, ActionButtonConfigOptions, ActionType, AdditionalResourceConfig, AdditionalResourceConfigOptions, AdditionalSessionData, Affix, ArrayConfig, BaseConfig, BaseConfigOptions, ChildResourceConfig, ColSize, ColumnConfig, ColumnIconConfig, ComponentConfig, ComponentConfigOptions, ComputedDisplayFieldElement, ComputedDisplayFieldElementOptions, ConcatFn, ConfigElement, ConfigParam, ConfigType, CreateNotificationMessage, DataType, Domain, EnumeratedConfig, EnumeratedConfigOptions, FieldDefault, FieldElement, FieldElementOptions, FieldMeta, FieldName, FieldPointer, FieldSort, FieldSortOptions, ForeignKeyDefault, ForeignKeyDefaultOptions, FormatType, ListConcatFn, ListViewConfig, ListViewConfigOptions, MenuItem, Meta, Method, MethodMeta, MultiColumnConfig, MultiColumnConfigOptions, NotificationMessage, NullBoolean, NullBooleanConfig, NullBooleanConfigOptions, PaddingElement, PaddingElementOptions, ParentResourceConfig, Permission, PermissionScope, RPCBaseFormData, RPCConfig, RPCConfigOptions, RPCDataType, RPCFieldMeta, RPCPlacement, RPCRecordData, RecordData, Resource, ResourceMap, ResourceMeta, ResourceValidatorFn, RolePermissionCollection, RootConfig, RootConfigOptions, RootRouteData, RouteResourceData, RpcMethod, SectionElement, SectionElementOptions, SessionInfo, SingleColumnConfig, SingleColumnConfigOptions, StaticDefault, SwitchConfigParam, SwitchConfigParamOptions, UserPermissionCollection, ValidDisplayTypes, ValidRPCTypes, ViewConfig, ViewConfigOptions, ViewType, arrayConfigOptions, staticDefaultOptions, switchCase };