Make each admin page specify is own layout. Closes #2584

This commit is contained in:
Gabe Kangas
2023-01-15 23:11:44 -08:00
parent 3b232f31e1
commit 2853752937
24 changed files with 167 additions and 37 deletions

View File

@@ -13,10 +13,12 @@ import {
Tooltip,
} from 'antd';
import dynamic from 'next/dynamic';
import React, { useEffect, useState } from 'react';
import React, { ReactElement, useEffect, useState } from 'react';
import { CREATE_WEBHOOK, DELETE_WEBHOOK, fetchData, WEBHOOKS } from '../../utils/apis';
import { isValidUrl, DEFAULT_TEXTFIELD_URL_PATTERN } from '../../utils/urls';
import { AdminLayout } from '../../components/layouts/AdminLayout';
const { Title, Paragraph } = Typography;
// Lazy loaded components
@@ -254,4 +256,9 @@ const Webhooks = () => {
</div>
);
};
Webhooks.getLayout = function getLayout(page: ReactElement) {
return <AdminLayout page={page} />;
};
export default Webhooks;