27 lines
1.0 KiB
TypeScript
27 lines
1.0 KiB
TypeScript
import { createElement, lazy } from "react";
|
|
import type { PlatformWebModule } from "@govoplan/core-webui";
|
|
import "./styles/calendar.css";
|
|
import { generatedTranslations } from "./i18n/generatedTranslations";
|
|
|
|
const CalendarPage = lazy(() => import("./features/calendar/CalendarPage"));
|
|
|
|
const eventRead = ["calendar:event:read"];
|
|
const translations = {
|
|
en: generatedTranslations.en,
|
|
de: generatedTranslations.de
|
|
};
|
|
|
|
export const calendarModule: PlatformWebModule = {
|
|
id: "calendar",
|
|
label: "i18n:govoplan-calendar.calendar.adab5090",
|
|
version: "1.0.0",
|
|
dependencies: ["access"],
|
|
optionalDependencies: ["mail", "tasks", "scheduling", "appointments", "workflow", "notifications", "dms", "connectors"],
|
|
translations,
|
|
navItems: [{ to: "/calendar", label: "i18n:govoplan-calendar.calendar.adab5090", iconName: "calendar", anyOf: eventRead, order: 55 }],
|
|
routes: [
|
|
{ path: "/calendar", anyOf: eventRead, order: 55, render: ({ settings, auth }) => createElement(CalendarPage, { settings, auth }) }]
|
|
|
|
};
|
|
|
|
export default calendarModule; |