forked from OctoWoW/OctoLauncher
OctoLauncher 1.3.1
Manifest-based CDN updater and mod manager for the OctoWoW 1.12.1 client: launcher-owned realmlist, torrent-backed content sync with bundled aria2c, antivirus and Defender exclusion handling, hardware-aware render distance, optional client tweaks and mods, and the in-launcher news feed.
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
import AddonsTab from './tabs/AddonsTab';
|
||||
import ModsTab from './tabs/ModsTab';
|
||||
import NewsTab from './tabs/NewsTab';
|
||||
import TweaksTab from './tabs/TweaksTab';
|
||||
import TabErrorBoundary from './TabErrorBoundary';
|
||||
|
||||
const Tabs = {
|
||||
news: NewsTab,
|
||||
tweaks: TweaksTab,
|
||||
addons: AddonsTab,
|
||||
mods: ModsTab
|
||||
} as const;
|
||||
|
||||
export const TabNames = Object.keys(Tabs) as TabType[];
|
||||
|
||||
export type TabType = keyof typeof Tabs;
|
||||
|
||||
type Props = { activeTab?: TabType };
|
||||
|
||||
const TabsPanel = ({ activeTab }: Props) => {
|
||||
const tab: TabType = activeTab ?? 'news';
|
||||
const Component = Tabs[tab];
|
||||
return (
|
||||
<TabErrorBoundary key={tab} tabName={tab}>
|
||||
<Component />
|
||||
</TabErrorBoundary>
|
||||
);
|
||||
};
|
||||
|
||||
export default TabsPanel;
|
||||
Reference in New Issue
Block a user