Files
sign/apps/web/src/app/(dashboard)/admin/site-settings/page.tsx

36 lines
1023 B
TypeScript
Raw Normal View History

2024-08-27 20:34:39 +09:00
import { msg } from '@lingui/macro';
import { useLingui } from '@lingui/react';
import { setupI18nSSR } from '@documenso/lib/client-only/providers/i18n.server';
2024-02-23 10:47:01 +00:00
import { getSiteSettings } from '@documenso/lib/server-only/site-settings/get-site-settings';
import { SITE_SETTINGS_BANNER_ID } from '@documenso/lib/server-only/site-settings/schemas/banner';
import { SettingsHeader } from '~/components/(dashboard)/settings/layout/header';
import { BannerForm } from './banner-form';
// import { BannerForm } from './banner-form';
export default async function AdminBannerPage() {
await setupI18nSSR();
2024-08-27 20:34:39 +09:00
const { _ } = useLingui();
2024-02-23 10:47:01 +00:00
const banner = await getSiteSettings().then((settings) =>
settings.find((setting) => setting.id === SITE_SETTINGS_BANNER_ID),
);
return (
<div>
2024-08-27 20:34:39 +09:00
<SettingsHeader
title={_(msg`Site Settings`)}
subtitle={_(msg`Manage your site settings here`)}
/>
2024-02-23 10:47:01 +00:00
<div className="mt-8">
<BannerForm banner={banner} />
</div>
</div>
);
}