import { IErrorEventHandler } from './dev'; import { MenuItem } from './components'; import { PushNotificationConfig } from './hooks/usePushNotifications'; import { ThemeConfig } from './components/Layout/ThemeProvider'; import { default as React } from 'react'; import { AdminProps, AuthProvider, DataProvider, I18nProvider } from 'react-admin'; import { QueryClient } from 'react-query'; /** * Define a basic super cool application based on React Admin, Mantis Theme and our style. */ declare function ApplicaAdmin({ theme, themeConfig, apiUrl, defaultLocale, development, logoMain, logoIcon, loginPage, menu, name, copy, version, dataProvider, authProvider, i18nProvider: _i18nProvider, errorHandler, error, enableNotification, enableRegistration, enablePasswordRecover, enableThemeToggler, enableLocaleSwitcher, oauth, queryClient, background, notificationAPI, pushNotifications, ...props }: ApplicaAdminProps): JSX.Element; type ApplicaAdminProps = AdminProps & { /** * Optional: Push notification configuration for enabling FCM notifications. * If provided, enables foreground push notification listening and triggers notification panel refresh on new messages. */ pushNotifications?: PushNotificationConfig; /** * Optionally, a custom theme to use in the application. * @remarks This theme is based on Mantis Theme (https://mantisdashboard.io/) * * @see https://marmelab.com/react-admin/Theming.html * @see https://material-ui.com/customization/theming/ */ theme: any; /** * Optionally, a custom theme configuration to use in the application. * Have fun with caution to modify theme configuration variables, if you make a mess Marco Colucci could use the fire extinguisher (I said everything). */ themeConfig: ThemeConfig; /** * The URL of the API to use in the application. * Although a default dataProvider and authProvider are already defined, it is possible that the app * uses the specified apiUrl for further operations (e.g. handling notifications). */ apiUrl: string; /** * The default language to use in the application (default: en). */ defaultLocale: string; /** * If set to true, the application works in development mode. * Development mode is useful for testing and debugging and performs activities that are not * recommended in production (e.g. capturing and forwarding non-localized messages). */ development: boolean; /** * The main logo to display in the sidebar when the menu is expanded laterally. */ logoMain: any; /** * The icon to display in the sidebar when the menu is collapsed laterally. */ logoIcon: any; /** * Configured menu to display in the application. */ menu: MenuItem[]; /** * The name of the application to display in the header. */ name: string; /** * Text to display in the footer. Default: '© Applica Software Guru for'. */ copy: string; /** * Application version to display in the footer. */ version: string; /** * The data provider to use in the application. */ dataProvider: DataProvider; /** * The auth provider to use in the application. */ authProvider: AuthProvider; /** * The i18n provider activation function. * If not specified, the default i18n provider is used. */ i18nProvider?: Promise; /** * Indicates the handler to use for error management. * By default, a PUT /api/ui/error call is made with the error message "error". * You can implement your own handler to manage errors differently. */ errorHandler?: IErrorEventHandler | undefined; /** * Indicates the component to display in case of error. */ error: React.Component; /** * Indicates the name of the REST resource to use for notification management. * The REST resource must be compatible with standard CRUD operations. * @default "entities/notification" * @example * // In this case, notifications will be managed through the "entities/notification" resource * */ notificationAPI: string; /** * Indicates whether notifications should be disabled. * If notifications are enabled, an icon will automatically appear in the top right of the header. * * @example * */ enableNotification: boolean; /** * Indicates whether the registration screen should be disabled. * If enabled, it is necessary to register a page, in the routes, that points to /register * * @example * // Basic page made by Applica * import { RegisterPage } from "@applica-software-guru/react-admin"; * * * */ enableRegistration: boolean; /** * Indicates whether the password recovery screen should be disabled. * If enabled, it is necessary to register a page, in the routes, that points to /recover * * @example * // Basic page made by Applica * import { RecoverPage } from "@applica-software-guru/react-admin"; * * * */ enablePasswordRecover: boolean; /** * The query client instance to use in the application. */ queryClient: QueryClient; /** * Background image to display in login, recover, and register pages. * This image must be a component with absolute positioning. */ background?: React.ReactNode; /** * Indicates whether the theme toggler should be displayed. */ enableThemeToggler: boolean; /** * Indicates whether the locale switcher should be displayed. */ enableLocaleSwitcher: boolean; /** * Indicates which OAuth providers to enable and configurations. */ oauth: { google?: { clientId: string; }; }; }; export { ApplicaAdmin }; export type { ApplicaAdminProps }; //# sourceMappingURL=ApplicaAdmin.d.ts.map