-
-
+
)}
diff --git a/src/components/Table.stories.tsx b/src/components/Table.stories.tsx
new file mode 100644
index 00000000..85212f82
--- /dev/null
+++ b/src/components/Table.stories.tsx
@@ -0,0 +1,68 @@
+import React from 'react';
+
+import {ComponentStory, ComponentMeta} from '@storybook/react';
+import {Table, TableColumn, TableRow} from "./Table";
+import {cn} from "../utils/util";
+
+const mockTableColumns: TableColumn[] = [
+ {field: "name", headerName: "TASK NAME", className: "font-mono text-white"},
+ {field: "start", headerName: "CREATED"},
+ {field: "finish", headerName: "FINISHED"},
+ {field: "pId", headerName: "PROCESS ID"},
+]
+
+const mockTableRows: TableRow[] = [
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+ {name: "Hello.js", start: "Jan 4 2023, 09:37", finish: "Jan 4 2023, 09:37", pId: 1234567890},
+]
+
+export default {
+ title: 'library/Table',
+ component: Table,
+} as ComponentMeta
;
+
+const Template: ComponentStory = (args) =>
+ (
+
+ )
+const TemplateDiv: ComponentStory = (args) =>
+ (
+
+ )
+
+export const Primary = Template.bind({});
+export const Minimal = Template.bind({});
+export const Clip = TemplateDiv.bind({});
+
+
+Primary.args = {
+ columns: mockTableColumns,
+ rows: mockTableRows.slice(0, 5),
+ className: "w-[600px]",
+}
+Minimal.args = {
+ columns: mockTableColumns,
+ rows: mockTableRows.slice(0, 5),
+ className: "w-full",
+}
+Clip.args = {
+ columns: mockTableColumns,
+ rows: mockTableRows,
+ className: "w-96 h-96",
+}
\ No newline at end of file
diff --git a/src/components/Table.tsx b/src/components/Table.tsx
new file mode 100644
index 00000000..2c0818c0
--- /dev/null
+++ b/src/components/Table.tsx
@@ -0,0 +1,79 @@
+import ButtonMenu from './ButtonMenu';
+import { ButtonMenuConfig } from './ButtonMenu';
+
+import clsx from "clsx";
+
+export interface TableColumn {
+ field: string;
+ headerName: string;
+ element?: (rows: TableRow[], rowIndex: number) => React.ReactElement;
+ className?: string;
+}
+
+export interface TableRow {
+ [key: string]: React.ReactNode;
+}
+
+interface TableProps {
+ rows: TableRow[];
+ columns: TableColumn[];
+ alignment?: 'even' | 'left';
+ menuOptions?: ButtonMenuConfig;
+ className?: string;
+}
+
+export function Table({rows, columns, alignment = 'even', menuOptions, className}: TableProps) {
+
+ // If menuOptions is truthy, add an extra column for the menu buttons
+ // Add a unique index for each ButtonMenu created to control respective rows
+ // If alignment === 'left', add 'w-full' to className of last column
+ const modifiedColumns = menuOptions
+ ? [...columns, {
+ field: 'menu',
+ headerName: '',
+ element: (rows: TableRow[], rowIndex: number) => (
+
+ ),
+ className: `text-end ${alignment === 'left' ? 'w-full' : ''}`,
+ }]
+ : alignment == 'left'
+ ? columns.map((column, index, array) =>
+ index === array.length - 1 ? { ...column, className: 'w-full' } : column
+ )
+ : columns;
+
+ // Code currently uses arbitrary values for min and max width when alignment is set to left
+ return (
+
+
+
+ {modifiedColumns.map((column, cIndex) => (
+
+ {column.headerName}
+ |
+ ))}
+
+
+
+ {rows.map((row, indexRow) => (
+
+ {modifiedColumns.map((column, indexColumn) => (
+
+ {column.element ? column.element(rows, indexRow) : row[column.field]}
+ |
+ ))}
+
+ ))}
+
+
+ );
+}
diff --git a/src/components/UserBox.stories.tsx b/src/components/UserBox.stories.tsx
new file mode 100644
index 00000000..97dce387
--- /dev/null
+++ b/src/components/UserBox.stories.tsx
@@ -0,0 +1,47 @@
+import React from 'react';
+
+import { ComponentStory, ComponentMeta } from '@storybook/react';
+import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
+import UserBox from './UserBox';
+
+export default {
+ title: 'library/UserBox',
+ component: UserBox,
+} as ComponentMeta;
+
+const Template: ComponentStory = (args) => (
+
+
+
+);
+
+export const Primary = Template.bind({});
+
+Primary.args = {
+ user: {
+ uid: '123',
+ username: 'John Doe',
+ is_owner: true,
+ is_admin: true,
+ permissions: {
+ can_view_instance: [],
+ can_start_instance: [],
+ can_stop_instance: [],
+ can_access_instance_console: [],
+ can_access_instance_setting: [],
+ can_read_instance_resource: [],
+ can_write_instance_resource: [],
+ can_access_instance_macro: [],
+ can_read_instance_file: [],
+ can_write_instance_file: [],
+ can_create_instance: false,
+ can_delete_instance: false,
+ can_read_global_file: false,
+ can_write_global_file: false,
+ can_manage_permission: false,
+ },
+ },
+ onClick: () => {
+ console.log('clicked');
+ },
+};
diff --git a/src/components/UserBox.tsx b/src/components/UserBox.tsx
index e4236bf9..7a42bcc9 100644
--- a/src/components/UserBox.tsx
+++ b/src/components/UserBox.tsx
@@ -40,12 +40,10 @@ export default function UserBox({
return (
-
+
{user.username}
{/* this text is bigger then the one in inputbox on purpose */}
diff --git a/src/components/UserMenu.tsx b/src/components/UserMenu.tsx
index 5148c325..1bb39526 100644
--- a/src/components/UserMenu.tsx
+++ b/src/components/UserMenu.tsx
@@ -120,7 +120,7 @@ const UserMenu = () => {
icon={faCog}
onClick={() => {
localStorage.setItem('lastVisitedRoute', location.pathname);
- setPathname('/settings');
+ setPathname('/settings/general');
}}
/>
diff --git a/src/data/ConsoleStream.ts b/src/data/ConsoleStream.ts
index 528a4792..36c123f1 100644
--- a/src/data/ConsoleStream.ts
+++ b/src/data/ConsoleStream.ts
@@ -75,7 +75,7 @@ const toConsoleEvent = (event: ClientEvent): ConsoleEvent => {
*/
export const useConsoleStream = (uuid: string) => {
const { core, token } = useContext(LodestoneContext);
- const { address, port, apiVersion } = core;
+ const { address, port, apiVersion, protocol } = core;
const [consoleLog, setConsoleLog] = useState([]);
const [status, setStatusInner] = useState('loading'); //callbacks should use statusRef.current instead of status
const statusRef = useRef('loading');
@@ -118,7 +118,7 @@ export const useConsoleStream = (uuid: string) => {
try {
const websocket = new WebSocket(
- `ws://${address}:${
+ `${protocol === 'https' ? 'wss' : 'ws'}://${address}:${
port ?? LODESTONE_PORT
}/api/${apiVersion}/instance/${uuid}/console/stream?token=Bearer ${token}`
);
diff --git a/src/data/EventStream.ts b/src/data/EventStream.ts
index f1998573..ce461e78 100644
--- a/src/data/EventStream.ts
+++ b/src/data/EventStream.ts
@@ -400,10 +400,11 @@ export const useEventStream = () => {
if (!token) return;
const connectWebsocket = () => {
- const wsAddress = `ws://${core.address}:${core.port ?? LODESTONE_PORT
- }/api/${core.apiVersion}/events/all/stream?filter=${JSON.stringify(
- eventQuery
- )}`;
+ const wsAddress = `${core.protocol === 'https' ? 'wss' : 'ws'}://${core.address}:${
+ core.port ?? LODESTONE_PORT
+ }/api/${core.apiVersion}/events/all/stream?filter=${JSON.stringify(
+ eventQuery
+ )}`;
if (wsRef.current) wsRef.current.close();
diff --git a/src/data/GameInstanceContext.tsx b/src/data/GameInstanceContext.tsx
new file mode 100644
index 00000000..e5e2968c
--- /dev/null
+++ b/src/data/GameInstanceContext.tsx
@@ -0,0 +1,32 @@
+import { GenericHandlerGameType } from 'components/Instance/InstanceCreateForm';
+import { createContext } from 'react';
+
+type GameInstanceContextValue = {
+ gameType: GenericHandlerGameType;
+ setGameType: (gameType: GenericHandlerGameType) => void;
+ urlValid: boolean;
+ setUrlValid: (value: boolean) => void;
+ url: string;
+ setUrl: (value: string) => void;
+ genericFetchReady: boolean;
+ setGenericFetchReady: (value: boolean) => void;
+};
+
+export const GameInstanceContext = createContext({
+ gameType: 'Generic',
+ setGameType: () => {
+ throw new Error('CreateGameInstanceContext not initialized');
+ },
+ urlValid: false,
+ setUrlValid: () => {
+ throw new Error('CreateGameInstanceContext not initialized');
+ },
+ url: '',
+ setUrl: () => {
+ throw new Error('CreateGameInstanceContext not initialized');
+ },
+ genericFetchReady: false,
+ setGenericFetchReady: () => {
+ throw new Error('CreateGameInstanceContext not initialized');
+ },
+});
diff --git a/src/data/GameTypeMappings.tsx b/src/data/GameTypeMappings.tsx
index 10cd29b0..24d5bfe5 100644
--- a/src/data/GameTypeMappings.tsx
+++ b/src/data/GameTypeMappings.tsx
@@ -4,6 +4,9 @@ import FileViewer from 'components/FileViewer';
import DashboardCard from 'components/DashboardCard';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import InstanceOverview from 'components/Instance/InstanceOverview';
+import { match, otherwise } from 'variant';
+
+const unknown_icon = '/assets/minecraft-missing-texture.svg';
import {
faChartLine,
@@ -14,6 +17,7 @@ import {
faServer,
} from '@fortawesome/free-solid-svg-icons';
import { HandlerGameType } from 'bindings/HandlerGameType';
+import { Game } from 'bindings/Game';
type InstanceTab = {
title: string;
@@ -24,125 +28,78 @@ type InstanceTab = {
content: JSX.Element;
};
-export const gameIcons: { [key: string]: { [key: string]: string } } = {
- MinecraftJava: {
- Vanilla: '/assets/minecraft-vanilla.png',
- Fabric: '/assets/minecraft-fabric.png',
- Forge: '/assets/minecraft-forge.png',
- Paper: '/assets/minecraft-paper.png',
- },
-};
+export const game_to_game_icon = (game: Game) =>
+ match(game, {
+ MinecraftJava: ({ variant }) =>
+ match(
+ variant,
+ otherwise(
+ {
+ Vanilla: () => '/assets/minecraft-vanilla.png',
+ Fabric: () => '/assets/minecraft-fabric.png',
+ Forge: () => '/assets/minecraft-forge.png',
+ Paper: () => '/assets/minecraft-paper.png',
+ },
+ () => unknown_icon
+ )
+ ),
+ Generic: () => '/assets/GenericIcon.svg',
+ });
+
+export const game_to_game_title = (game: Game) =>
+ match(game, {
+ MinecraftJava: ({ variant }) =>
+ match(variant, {
+ Vanilla: () => 'Minecraft',
+ Forge: () => 'Forge (Minecraft)',
+ Fabric: () => 'Fabric (Minecraft)',
+ Paper: () => 'Paper (Minecraft)',
+ Spigot: () => 'Spigot (Minecraft)',
+ Other: ({ name }) => `${name} (Minecraft)`,
+ }),
+ Generic: ({ game_name }) => `${game_name} (Generic)`,
+ });
+
+export const game_to_description = (game: Game) =>
+ match(game, {
+ MinecraftJava: ({ variant }) =>
+ match(variant, {
+ Vanilla: () => 'Standard vanilla Minecraft server from Mojang.',
+ Forge: () =>
+ 'Modding framework that allows you to install mods and customize your Minecraft experience.',
+ Fabric: () => 'Lightweight modding toolchain for Minecraft.',
+ Paper: () =>
+ 'High-performance Spigot fork that aims to fix gameplay and mechanics inconsistencies.',
+ Spigot: () =>
+ 'Modified Minecraft server software that supports plugins, offering enhanced performance and customization options.',
+ Other: ({ name }) => `Unknown Minecraft variant: ${name}`,
+ }),
+ Generic: ({ game_name }) => `Unknown game: ${game_name}`,
+ });
-export const gameTypeInfoFromHandlerType: Record = {
+export const HandlerGameType_to_Game: Record = {
MinecraftJavaVanilla: {
- title: 'Minecraft',
- description: 'Standard vanilla Minecraft server from Mojang.',
- game_type: { MinecraftJava: { variant: 'Vanilla' } },
+ type: 'MinecraftJava',
+ variant: {
+ type: 'Vanilla',
+ },
},
MinecraftFabric: {
- title: 'Fabric (Minecraft)',
- description: 'Lightweight modding toolchain for Minecraft.',
- game_type: { MinecraftJava: { variant: 'Fabric' } },
+ type: 'MinecraftJava',
+ variant: {
+ type: 'Fabric',
+ },
},
MinecraftForge: {
- title: 'Forge (Minecraft)',
- description:
- 'Modding framework that allows you to install mods and customize your Minecraft experience.',
- game_type: { MinecraftJava: { variant: 'Forge' } },
+ type: 'MinecraftJava',
+ variant: {
+ type: 'Forge',
+ },
},
MinecraftPaper: {
- title: 'Paper (Minecraft)',
- description: 'High-performance Spigot fork that aims to fix gameplay and mechanics inconsistencies.',
- game_type: { MinecraftJava: { variant: 'Paper' } },
- },
-};
-
-export const spanMap: { [key: string]: { [key: string]: string } } = {
- MinecraftJava: {
- Vanilla: 'Minecraft Vanilla',
- Fabric: 'Minecraft Fabric',
- Forge: 'Minecraft Forge',
- Paper: 'Minecraft Paper',
- },
-};
-
-export const InstanceTabListMap: Record = {
- MinecraftJava: [
- {
- title: 'Overview',
- displayTitle: null,
- path: 'overview',
- width: 'max-w-4xl',
- icon: ,
- content: ,
- },
- {
- title: 'Settings',
- displayTitle: 'Settings',
- path: 'settings',
- width: 'max-w-2xl',
- icon: ,
- content: (
-
-
-
- ),
- },
- {
- title: 'Console',
- displayTitle: 'Console',
- path: 'console',
- width: 'max-w-6xl',
- icon: ,
- content: ,
+ type: 'MinecraftJava',
+ variant: {
+ type: 'Paper',
},
- {
- title: 'Files',
- displayTitle: 'Files',
- path: 'files',
- width: 'max-w-6xl',
- icon: ,
- content: ,
- },
- {
- title: 'Tasks',
- displayTitle: 'Tasks',
- path: 'tasks',
- width: 'max-w-4xl',
- icon: ,
- content: (
-
-
-
- Coming soon to a dashboard near you!
-
-
- ),
- },
- {
- title: 'Event Logs',
- displayTitle: 'Event Logs',
- path: 'logs',
- width: 'max-w-4xl',
- icon: ,
- content: (
-
-
-
- Coming soon to a dashboard near you!
-
-
- ),
- },
- ],
+ },
};
diff --git a/src/data/InstanceGameTypes.ts b/src/data/InstanceGameTypes.ts
index 074e4793..2f4b9f5c 100644
--- a/src/data/InstanceGameTypes.ts
+++ b/src/data/InstanceGameTypes.ts
@@ -1,18 +1,40 @@
import { HandlerGameType } from 'bindings/HandlerGameType';
import { useQuery } from '@tanstack/react-query';
import axios, { AxiosError } from 'axios';
-import { ConfigurableManifest } from 'components/Instance/Create/form';
-
+import { SetupManifest } from 'bindings/SetupManifest';
+import { GenericHandlerGameType } from 'components/Instance/InstanceCreateForm';
export const InstanceGameTypes = () =>
- useQuery(['games'], () =>
- axios.get('/games').then((res) => res.data)
- );
+ useQuery(['games'], async () => {
+ const response = await axios.get('/games');
+ return response.data;
+ });
-export const SetupInstanceManifest = (game_type: HandlerGameType) =>
- useQuery(
+export const SetupInstanceManifest = (game_type: HandlerGameType) => {
+ return useQuery(
['setup_manifest', game_type],
- () =>
- axios
- .get(`/setup_manifest/${game_type}`)
- .then((res) => res.data)
+ async () => {
+ const response = await axios.get(
+ `/setup_manifest/${game_type}`
+ );
+ return response.data;
+ }
+ );
+};
+
+export const SetupGenericInstanceManifest = (
+ game_type: GenericHandlerGameType,
+ generic_instance_url: string,
+ url_is_ready: boolean
+) => {
+ return useQuery(
+ ['generic_setup_manifest', game_type],
+ async () => {
+ const response = await axios.put(
+ `/generic_setup_manifest`,
+ { url: generic_instance_url }
+ );
+ return response.data;
+ },
+ { enabled: url_is_ready, cacheTime: 0, retry: false }
);
+};
diff --git a/src/data/InstanceManifest.ts b/src/data/InstanceManifest.ts
index c0d58a80..78c00729 100644
--- a/src/data/InstanceManifest.ts
+++ b/src/data/InstanceManifest.ts
@@ -1,6 +1,6 @@
import { useQuery } from '@tanstack/react-query';
import axios, { AxiosError } from 'axios';
-import { ConfigurableManifest } from 'components/Instance/Create/form';
+import { ConfigurableManifest } from 'bindings/ConfigurableManifest';
export const useInstanceManifest = (uuid: string) => {
return useQuery(
diff --git a/src/data/PerformanceStream.ts b/src/data/PerformanceStream.ts
index ed4c8250..5875be54 100644
--- a/src/data/PerformanceStream.ts
+++ b/src/data/PerformanceStream.ts
@@ -27,7 +27,7 @@ export const usePerformanceStream = (uuid: string) => {
const [latency_s, setLatency_s] = useState(0);
const [counter, setCounter] = useState(-1);
const { core } = useContext(LodestoneContext);
- const { address, port, apiVersion } = core;
+ const { address, port, apiVersion, protocol } = core;
useInterval(() => {
setLatency_s((Date.now() - lastPing) / 1000);
@@ -36,7 +36,7 @@ export const usePerformanceStream = (uuid: string) => {
useEffect(() => {
try {
const websocket = new WebSocket(
- `ws://${address}:${
+ `${protocol === 'https' ? 'wss' : 'ws'}://${address}:${
port ?? LODESTONE_PORT
}/api/${apiVersion}/monitor/${uuid}`
);
diff --git a/src/data/SettingsContext.ts b/src/data/SettingsContext.ts
index 1ad9df36..fbf2d7a5 100644
--- a/src/data/SettingsContext.ts
+++ b/src/data/SettingsContext.ts
@@ -3,8 +3,8 @@ import { PublicUser } from '../bindings/PublicUser';
interface SettingsContextType {
userList: { [uuid: string]: PublicUser };
- selectedUser?: PublicUser;
- selectUser: (user?: PublicUser) => void;
+ selectedUser?: PublicUser | null;
+ selectUser: (user: PublicUser|null) => void;
tabIndex: number;
setTabIndex: (index: number) => void;
}
diff --git a/src/globals.css b/src/globals.css
index 4bd7ea47..fbad658e 100644
--- a/src/globals.css
+++ b/src/globals.css
@@ -151,6 +151,30 @@ main {
.gutter-both-stable {
scrollbar-gutter: both-edges stable;
}
+
+ .generic-gametype-hover{
+ border: double 2px transparent;
+ border-radius: 0.375rem;
+ background-image: linear-gradient(#2B2D32, #2B2D32), radial-gradient(circle at top right, #2AF588, #334675);
+ background-origin: border-box;
+ background-clip: padding-box, border-box;
+ }
+
+ .generic-gametype-selected {
+ border: double 2px transparent;
+ border-radius: 0.375rem;
+ background-image: linear-gradient(#303338, #303338), radial-gradient(circle at top right, #2AF588, #334675);
+ background-origin: border-box;
+ background-clip: padding-box, border-box;
+ }
+
+ .generic-gametype-unselected{
+ border: double 2px transparent;
+ border-radius: 0.375rem;
+ background-image: linear-gradient( #2B2D32, #2B2D32), radial-gradient(circle at top right, #2B2D32, #2B2D32);
+ background-origin: border-box;
+ background-clip: padding-box, border-box;
+ }
}
/* Some libraries don't like class name */
@@ -274,3 +298,7 @@ main {
.Toastify--animate {
animation-duration: 0.1s !important;
}
+
+::-ms-reveal {
+ display: none;
+}
\ No newline at end of file
diff --git a/src/pages/InstanceTabs/InstanceTabs.tsx b/src/pages/InstanceTabs/InstanceTabs.tsx
index a6502b8d..dbb1fbb8 100644
--- a/src/pages/InstanceTabs/InstanceTabs.tsx
+++ b/src/pages/InstanceTabs/InstanceTabs.tsx
@@ -2,12 +2,103 @@ import { useContext, useEffect, useState } from 'react';
import { InstanceContext } from 'data/InstanceContext';
import { useDocumentTitle } from 'usehooks-ts';
import { useLocation } from 'react-router-dom';
-import { InstanceTabListMap, spanMap } from '../../data/GameTypeMappings';
import Label from 'components/Atoms/Label';
import { cn, stateToLabelColor } from 'utils/util';
import Spinner from 'components/DashboardLayout/Spinner';
import { CommandHistoryContextProvider } from 'data/CommandHistoryContext';
-import { Games } from 'bindings/InstanceInfo';
+import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
+import InstanceOverview from 'components/Instance/InstanceOverview';
+import {
+ faChartLine,
+ faCodeCompare,
+ faCog,
+ faFolder,
+ faInbox,
+ faServer,
+} from '@fortawesome/free-solid-svg-icons';
+import GameConsole from 'components/GameConsole';
+import FileViewer from 'components/FileViewer';
+import DashboardCard from 'components/DashboardCard';
+import { InstanceSettingCard } from 'components/Instance';
+
+export const tabs = [
+ {
+ title: 'Overview',
+ displayTitle: null,
+ path: 'overview',
+ width: 'max-w-4xl',
+ icon: ,
+ content: ,
+ },
+ {
+ title: 'Settings',
+ displayTitle: 'Settings',
+ path: 'settings',
+ width: 'max-w-2xl',
+ icon: ,
+ content: (
+
+
+
+ ),
+ },
+ {
+ title: 'Console',
+ displayTitle: 'Console',
+ path: 'console',
+ width: 'max-w-6xl',
+ icon: ,
+ content: ,
+ },
+ {
+ title: 'Files',
+ displayTitle: 'Files',
+ path: 'files',
+ width: 'max-w-6xl',
+ icon: ,
+ content: ,
+ },
+ {
+ title: 'Tasks',
+ displayTitle: 'Tasks',
+ path: 'tasks',
+ width: 'max-w-4xl',
+ icon: ,
+ content: (
+
+
+
+ Coming soon to a dashboard near you!
+
+
+ ),
+ },
+ {
+ title: 'Event Logs',
+ displayTitle: 'Event Logs',
+ path: 'logs',
+ width: 'max-w-4xl',
+ icon: ,
+ content: (
+
+
+
+ Coming soon to a dashboard near you!
+
+
+ ),
+ },
+];
const InstanceTabs = () => {
useDocumentTitle('Dashboard - Lodestone');
@@ -47,26 +138,6 @@ const InstanceTabs = () => {
);
}
}
- const game = Object.keys(instance.game_type)[0] as Games;
- const variant = instance.game_type[game]['variant'];
- const tabs = InstanceTabListMap[game];
-
- if (!tabs) {
- return (
-
-
-
-
- Unknown game type {spanMap[game][variant]}
-
-
-
-
- );
- }
const tab = tabs.find((tab) => tab.path === path);
if (!tab) {
@@ -78,7 +149,7 @@ const InstanceTabs = () => {
- Unknown tab {path}
+ {path} not found
diff --git a/src/pages/login/CoreConnect.tsx b/src/pages/login/CoreConnect.tsx
index 446a46f8..86a14090 100644
--- a/src/pages/login/CoreConnect.tsx
+++ b/src/pages/login/CoreConnect.tsx
@@ -72,19 +72,7 @@ const CoreConnect = () => {
Add a new core
-
- You may need to adjust your network and browser settings.{' '}
-
- Learn more.
-
-
-
-
+
You may need to adjust your network and browser settings.{' '}
{
+
+