Switch to Axios, Panel component test

This commit is contained in:
Adrian Rumpold
2025-04-29 07:33:01 +02:00
parent 3e5d465356
commit f113c72c10
9 changed files with 226 additions and 76 deletions

View File

@@ -4,7 +4,6 @@ import ArticleSelector from "./components/ArticleSelector/ArticleSelector";
import Panel from "./components/Panel/Panel";
import TOC from "./components/TOC/TOC";
import useNavState from "./store/navStore";
import useUIStore from "./store/uiStore";
import styles from "./App.module.css";
@@ -13,7 +12,6 @@ import { useTOC } from "./hooks/toc";
function App() {
const { numPanels, addPanel } = useUIStore();
const { celexId, articleId } = useNavState();
const { data: toc, isPending, error } = useTOC();
if (isPending) {
@@ -35,11 +33,9 @@ function App() {
{Array.from({ length: numPanels }, (_, index) => (
<Panel
key={index}
celexId={celexId!}
language={
Object.values(Language)[index % Object.values(Language).length]
}
articleId={articleId!}
/>
))}
</div>