|
|
@ -1,3 +1,4 @@
|
|
|
|
|
|
|
|
import { faSadCry as fasSadCry } from "@fortawesome/free-regular-svg-icons";
|
|
|
|
import { faExclamationTriangle } from "@fortawesome/free-solid-svg-icons";
|
|
|
|
import { faExclamationTriangle } from "@fortawesome/free-solid-svg-icons";
|
|
|
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
|
|
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
|
|
|
import React, {
|
|
|
|
import React, {
|
|
|
@ -64,21 +65,39 @@ const App: FunctionComponent<Props> = () => {
|
|
|
|
} else if (typeof initialized === "string") {
|
|
|
|
} else if (typeof initialized === "string") {
|
|
|
|
return <InitializationErrorView>{initialized}</InitializationErrorView>;
|
|
|
|
return <InitializationErrorView>{initialized}</InitializationErrorView>;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
try {
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<SidebarToggleContext.Provider value={toggleSidebar}>
|
|
|
|
<SidebarToggleContext.Provider value={toggleSidebar}>
|
|
|
|
<Row noGutters className="header-container">
|
|
|
|
<Row noGutters className="header-container">
|
|
|
|
<Header></Header>
|
|
|
|
<Header></Header>
|
|
|
|
</Row>
|
|
|
|
</Row>
|
|
|
|
<Row noGutters className="flex-nowrap">
|
|
|
|
<Row noGutters className="flex-nowrap">
|
|
|
|
<Sidebar open={sidebar}></Sidebar>
|
|
|
|
<Sidebar open={sidebar}></Sidebar>
|
|
|
|
<ModalProvider>
|
|
|
|
<ModalProvider>
|
|
|
|
<Router className="d-flex flex-row flex-grow-1 main-router"></Router>
|
|
|
|
<Router className="d-flex flex-row flex-grow-1 main-router"></Router>
|
|
|
|
</ModalProvider>
|
|
|
|
</ModalProvider>
|
|
|
|
</Row>
|
|
|
|
</Row>
|
|
|
|
<NotificationContainer></NotificationContainer>
|
|
|
|
<NotificationContainer></NotificationContainer>
|
|
|
|
</SidebarToggleContext.Provider>
|
|
|
|
</SidebarToggleContext.Provider>
|
|
|
|
);
|
|
|
|
);
|
|
|
|
|
|
|
|
} catch (error) {
|
|
|
|
|
|
|
|
// TODO: Extract me!
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
|
|
|
<Container className="d-flex flex-column align-items-center my-5">
|
|
|
|
|
|
|
|
<h1>
|
|
|
|
|
|
|
|
<FontAwesomeIcon className="mr-2" icon={fasSadCry}></FontAwesomeIcon>
|
|
|
|
|
|
|
|
Ouch! UI is crashed!
|
|
|
|
|
|
|
|
</h1>
|
|
|
|
|
|
|
|
<Button
|
|
|
|
|
|
|
|
href="https://github.com/morpheus65535/bazarr/issues/new/choose"
|
|
|
|
|
|
|
|
target="_blank"
|
|
|
|
|
|
|
|
variant="light"
|
|
|
|
|
|
|
|
>
|
|
|
|
|
|
|
|
Report Issue
|
|
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
|
|
</Container>
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
const InitializationErrorView: FunctionComponent<{
|
|
|
|
const InitializationErrorView: FunctionComponent<{
|
|
|
|