44 lines
1.5 KiB
TypeScript
44 lines
1.5 KiB
TypeScript
import { LoaderFunctionArgs, MetaFunction } from "react-router";
|
|
import { Link } from "react-router";
|
|
import { useTranslation } from "react-i18next";
|
|
import EditPageLayout from "~/components/ui/layouts/EditPageLayout";
|
|
import { getTranslations } from "~/locale/i18next.server";
|
|
import { adminPath } from "~/utils/app/CanonicalUrlUtils";
|
|
|
|
export const loader = async ({ request }: LoaderFunctionArgs) => {
|
|
const { t } = await getTranslations(request);
|
|
return {
|
|
metadata: [{ title: `${t("models.tenant.plural")} | ${process.env.APP_NAME}` }],
|
|
};
|
|
};
|
|
|
|
export const meta: MetaFunction<typeof loader> = ({ data }) => data?.metadata || [];
|
|
|
|
export default function () {
|
|
const { t } = useTranslation();
|
|
|
|
return (
|
|
<EditPageLayout
|
|
title={t("settings.admin.tenants.settingsTitle")}
|
|
withHome={false}
|
|
menu={[
|
|
{
|
|
title: t("settings.admin.tenants.settingsTitle"),
|
|
routePath: adminPath("settings/accounts", { mode: "host-aware" }),
|
|
},
|
|
]}
|
|
>
|
|
<div className="space-y-3">
|
|
<div className="space-y-2">
|
|
<Link
|
|
to={`types`}
|
|
className="focus:ring-ring border-border hover:border-border relative block w-full rounded-lg border-2 border-dashed p-4 text-center focus:outline-hidden focus:ring-2 focus:ring-offset-2"
|
|
>
|
|
<span className="text-foreground mt-2 block text-sm font-medium">{t("settings.admin.tenants.types.title")}</span>
|
|
</Link>
|
|
</div>
|
|
</div>
|
|
</EditPageLayout>
|
|
);
|
|
}
|