Skip to content

Commit 289a9b9

Browse files
committed
add ToS page
1 parent 75457bc commit 289a9b9

File tree

4 files changed

+619
-19
lines changed

4 files changed

+619
-19
lines changed

src/api/index.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,17 @@ async function init(prettyPrint: boolean = false) {
106106
title: "ACM @ UIUC Core API",
107107
description: "ACM @ UIUC Core Management Platform",
108108
version: "1.0.0",
109+
contact: {
110+
name: "ACM @ UIUC Infrastructure Team",
111+
112+
url: "infra.acm.illinois.edu",
113+
},
114+
license: {
115+
name: "BSD 3-Clause",
116+
identifier: "BSD-3-Clause",
117+
url: "https://github.com/acm-uiuc/core/blob/main/LICENSE",
118+
},
119+
termsOfService: "https://core.acm.illinois.edu/tos",
109120
},
110121
servers: [
111122
{
@@ -164,7 +175,7 @@ async function init(prettyPrint: boolean = false) {
164175
"Creating room reservation requests for ACM @ UIUC within University buildings.",
165176
},
166177
],
167-
openapi: "3.0.3" satisfies ZodOpenApiVersion, // If this is not specified, it will default to 3.1.0
178+
openapi: "3.1.0" satisfies ZodOpenApiVersion, // If this is not specified, it will default to 3.1.0
168179
components: {
169180
securitySchemes: {
170181
bearerAuth: {

src/ui/Router.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import { ManageStripeLinksPage } from './pages/stripe/ViewLinks.page';
2323
import { ManageRoomRequestsPage } from './pages/roomRequest/RoomRequestLanding.page';
2424
import { ViewRoomRequest } from './pages/roomRequest/ViewRoomRequest.page';
2525
import { ViewLogsPage } from './pages/logs/ViewLogs.page';
26+
import { TermsOfService } from './pages/tos/TermsOfService.page';
2627

2728
const ProfileRediect: React.FC = () => {
2829
const location = useLocation();
@@ -82,6 +83,10 @@ const commonRoutes = [
8283
path: '/auth/callback',
8384
element: <AuthCallback />,
8485
},
86+
{
87+
path: '/tos',
88+
element: <TermsOfService />,
89+
},
8590
];
8691

8792
const profileRouter = createBrowserRouter([

src/ui/pages/Error404.page.tsx

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,16 @@
11
import { Container, Title, Text, Anchor } from '@mantine/core';
22
import React from 'react';
3+
import { AcmAppShell } from '@ui/components/AppShell';
34

4-
import { HeaderNavbar } from '@ui/components/Navbar';
5-
6-
export const Error404Page: React.FC<{ showNavbar?: boolean }> = ({ showNavbar }) => {
7-
const realStuff = (
8-
<>
9-
<Title>Page Not Found</Title>
10-
<Text>
11-
Perhaps you would like to <Anchor href="/">go home</Anchor>?
12-
</Text>
13-
</>
14-
);
15-
if (!showNavbar) {
16-
return realStuff;
17-
}
5+
export const Error404Page: React.FC = () => {
186
return (
19-
<>
20-
<HeaderNavbar />
21-
<Container>{realStuff}</Container>
22-
</>
7+
<AcmAppShell showSidebar={false}>
8+
<Container>
9+
<Title>Page Not Found</Title>
10+
<Text>
11+
Perhaps you would like to <Anchor href="/">go home</Anchor>?
12+
</Text>
13+
</Container>
14+
</AcmAppShell>
2315
);
2416
};

0 commit comments

Comments
 (0)