@@ -41,30 +54,29 @@ export default function HomePage() {
>}
-
+
Ankündigungen
-
+
, to: "/chat/announcements"},
+ {title: "Chat", icon:
, to: "/chat"},
+ ]}/>
+
+
+
+ >}
+
+
StuVe Events
+ , to: "/events/entries"},
+ {title: "Events", icon: , to: "/events"},
+ ]}/>
+
>
diff --git a/src/pages/test/DebugPage.tsx b/src/pages/test/DebugPage.tsx
new file mode 100644
index 0000000..0aeeaa4
--- /dev/null
+++ b/src/pages/test/DebugPage.tsx
@@ -0,0 +1,102 @@
+import {useShowDebug} from "@/components/ShowDebug.tsx";
+import {ActionIcon, Alert, Group, LoadingOverlay, Text, TextInput, Title} from "@mantine/core";
+import {useForm} from "@mantine/form";
+import {useQuery} from "@tanstack/react-query";
+import {PocketBaseErrorAlert, usePB} from "@/lib/pocketbase.tsx";
+import {CodeHighlight} from "@mantine/code-highlight";
+import {IconRefresh} from "@tabler/icons-react";
+
+export default function DebugPage() {
+
+
+ const {showDebug} = useShowDebug()
+
+ const {pb} = usePB()
+
+ const formValues = useForm({
+ initialValues: {
+ collectionName: "",
+ filter: "",
+ sort: "",
+ expand: "",
+ }
+ })
+
+ const debugQuery = useQuery({
+ queryKey: ["debug", formValues.values.collectionName, formValues.values.filter, formValues.values.sort, formValues.values.expand],
+ queryFn: async () => {
+ return await pb.collection(formValues.values.collectionName).getList(1, 10, {
+ filter: formValues.values.filter,
+ sort: formValues.values.sort,
+ expand: formValues.values.expand
+ })
+ },
+ enabled: formValues.values.collectionName !== ""
+ })
+
+ if (!showDebug) return (
+
+
+ Der Debug Modus ist deaktiviert. Bitte aktiviere ihn in den Einstellungen um diese Seite zu sehen.
+
+
)
+
+ return <>
+
+
Debug
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {debugQuery.data &&
+
+
+ {debugQuery.data.totalItems} Ergebniss(e)
+
+
+
+ {debugQuery.data.page}/{debugQuery.data.totalPages} Seiten
+
+
+ debugQuery.refetch()}
+ color={"orange"}
+ variant={"transparent"}
+ size={"sm"}
+ aria-label={"Refetch"}
+ disabled={debugQuery.isLoading}
+ >
+
+
+
+
+
+
}
+
+ >
+}
\ No newline at end of file
diff --git a/src/style/global.css b/src/style/global.css
index 957fc41..c6eadab 100644
--- a/src/style/global.css
+++ b/src/style/global.css
@@ -17,6 +17,10 @@
stroke-width: 1.5;
}
+.scrollable {
+ overflow-y: auto;
+}
+
.scrollbar {
scrollbar-color: var(--mantine-color-blue-5) var(--mantine-color-body);
scrollbar-width: thin;
@@ -46,6 +50,10 @@
}
}
+.overflow-hidden {
+ overflow: hidden;
+}
+
.no-scrollbar {
/* Hide scrollbar for WebKit (Safari, Chrome) */
diff --git a/tsconfig.json b/tsconfig.json
index 1c47655..f6a6370 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -26,6 +26,9 @@
"paths": {
"@/*": [
"src/*"
+ ],
+ "~/*": [
+ "public/*"
]
},
"types": [
diff --git a/vite.config.ts b/vite.config.ts
index d6ed935..d54cb4c 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -8,8 +8,8 @@ export default defineConfig({
plugins: [react(), svgr()],
resolve: {
alias: {
- // Add aliases @ for src directory
"@": path.resolve(__dirname, "src"),
- }
+ "~": path.resolve(__dirname, "public"),
+ },
}
})
\ No newline at end of file
diff --git a/yarn.lock b/yarn.lock
index 3a54afd..f01d26d 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -880,6 +880,11 @@
resolved "https://registry.yarnpkg.com/@tiptap/extension-list-item/-/extension-list-item-2.3.0.tgz#7f0af465c1af160648ace586100ff3f8e612e9bf"
integrity sha512-mHU+IuRa56OT6YCtxf5Z7OSUrbWdKhGCEX7RTrteDVs5oMB6W3oF9j88M5qQmZ1WDcxvQhAOoXctnMt6eX9zcA==
+"@tiptap/extension-mention@^2.4.0":
+ version "2.4.0"
+ resolved "https://registry.yarnpkg.com/@tiptap/extension-mention/-/extension-mention-2.4.0.tgz#35f13d71e207280cafe5b00e76f17b4c372fbe8b"
+ integrity sha512-7BqCNfqF1Mv9IrtdlHADwXMFo968UNmthf/TepVXC7EX2Ke6/Y4vvxmpYVNZc55FdswFwpVyZ2VeXBj3AC2JcA==
+
"@tiptap/extension-ordered-list@^2.3.0":
version "2.3.0"
resolved "https://registry.yarnpkg.com/@tiptap/extension-ordered-list/-/extension-ordered-list-2.3.0.tgz#75f7f668201a4cd3ec507c78d2229ec670e3e707"
@@ -967,6 +972,11 @@
"@tiptap/extension-strike" "^2.3.0"
"@tiptap/extension-text" "^2.3.0"
+"@tiptap/suggestion@^2.4.0":
+ version "2.4.0"
+ resolved "https://registry.yarnpkg.com/@tiptap/suggestion/-/suggestion-2.4.0.tgz#1926cde5f197d116baf7794f55bd971245540e5c"
+ integrity sha512-6dCkjbL8vIzcLWtS6RCBx0jlYPKf2Beuyq5nNLrDDZZuyJow5qJAY0eGu6Xomp9z0WDK/BYOxT4hHNoGMDkoAg==
+
"@types/date-arithmetic@*":
version "4.1.4"
resolved "https://registry.yarnpkg.com/@types/date-arithmetic/-/date-arithmetic-4.1.4.tgz#bdb441f61a916f11af1874a8c2cf787f77ffcb94"
@@ -3230,6 +3240,18 @@ react-dropzone@^14.2.3:
file-selector "^0.6.0"
prop-types "^15.8.1"
+react-infinite-scroll-component@^6.1.0:
+ version "6.1.0"
+ resolved "https://registry.yarnpkg.com/react-infinite-scroll-component/-/react-infinite-scroll-component-6.1.0.tgz#7e511e7aa0f728ac3e51f64a38a6079ac522407f"
+ integrity sha512-SQu5nCqy8DxQWpnUVLx7V7b7LcA37aM7tvoWjTLZp1dk6EJibM5/4EJKzOnl07/BsM1Y40sKLuqjCwwH/xV0TQ==
+ dependencies:
+ throttle-debounce "^2.1.0"
+
+react-intersection-observer@^9.10.2:
+ version "9.10.2"
+ resolved "https://registry.yarnpkg.com/react-intersection-observer/-/react-intersection-observer-9.10.2.tgz#d5b14f80c9a6bed525becc228db7dccac5d0ec1c"
+ integrity sha512-j2hGADK2hCbAlfaq6L3tVLb4iqngoN7B1fT16MwJ4J16YW/vWLcmAIinLsw0lgpZeMi4UDUWtHC9QDde0/P1yQ==
+
react-is@^16.13.1, react-is@^16.7.0:
version "16.13.1"
resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4"
@@ -3608,6 +3630,11 @@ text-table@^0.2.0:
resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4"
integrity sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==
+throttle-debounce@^2.1.0:
+ version "2.3.0"
+ resolved "https://registry.yarnpkg.com/throttle-debounce/-/throttle-debounce-2.3.0.tgz#fd31865e66502071e411817e241465b3e9c372e2"
+ integrity sha512-H7oLPV0P7+jgvrk+6mwwwBDmxTaxnu9HMXmloNLXwnNO0ZxZ31Orah2n8lU1eMPvsaowP2CX+USCgyovXfdOFQ==
+
tiny-invariant@^1.0.6:
version "1.3.3"
resolved "https://registry.yarnpkg.com/tiny-invariant/-/tiny-invariant-1.3.3.tgz#46680b7a873a0d5d10005995eb90a70d74d60127"