feat: Overlay nicht über die Seite sondern nur über den KÜ Slot wenn ein Event kommt
This commit is contained in:
@@ -14,6 +14,7 @@ import { store } from "@/redux/store";
|
||||
import Script from "next/script";
|
||||
import DeviceEventsBridge from "@/components/common/DeviceEventsBridge";
|
||||
import GlobalActivityOverlay from "@/components/common/GlobalActivityOverlay";
|
||||
import { usePathname } from "next/navigation";
|
||||
|
||||
// Thunks importieren
|
||||
import { getKueDataThunk } from "@/redux/thunks/getKueDataThunk";
|
||||
@@ -67,6 +68,7 @@ function AppContent({
|
||||
pageProps: AppProps["pageProps"];
|
||||
}): JSX.Element {
|
||||
const dispatch = useAppDispatch();
|
||||
const pathnameHook = usePathname();
|
||||
const [sessionExpired] = useState(false);
|
||||
const mode = "DIA0"; // oder aus Router oder Session
|
||||
const type = 0; // Beispiel: 0 für "loop", 1 für "iso" (bitte ggf. anpassen)
|
||||
@@ -160,7 +162,10 @@ function AppContent({
|
||||
)}
|
||||
<Component {...pageProps} />
|
||||
<ToastContainer position="top-right" autoClose={3000} />
|
||||
<GlobalActivityOverlay />
|
||||
{/* Hide global overlay on kabelueberwachung page so only per-slot overlays show */}
|
||||
{pathnameHook?.includes("kabelueberwachung") ? null : (
|
||||
<GlobalActivityOverlay />
|
||||
)}
|
||||
</main>
|
||||
</div>
|
||||
<Footer />
|
||||
|
||||
Reference in New Issue
Block a user