Compare commits

..
3 Commits
Author SHA1 Message Date
LionTion 6b3e3fd8ca fixed fullscreen underscroll 2026-10-24 04:12:11 +02:00
LionTion 15ce86d6f3 few textfield improvements 2026-10-23 22:58:01 +02:00
LionTion 0e65b8c446 small changes 2026-10-23 22:04:35 +02:00
6 changed files with 36 additions and 10 deletions

No files matched your search

+1
View File
@@ -11,6 +11,7 @@ export const metadata: Metadata = {
export default function RootLayout({ children }: LayoutProps<"/">) {
return (
<html lang="en" dir="ltr" className={clsx("eisenkraft-regular")}>
<meta name="viewport" content="width=device-width, initial-scale=1.0, interactive-widget=resizes-visual" />
<meta name="apple-mobile-web-app-title" content="Excalibur Outdoor Tour" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta httpEquiv="ScreenOrientation" content="autoRotate:disabled" />
+18 -2
View File
@@ -25,8 +25,8 @@ export default function Main() {
const step = Number.parseInt(stepStr) || 0;
useEffect(() => {
return;
if (!hasAttachedListerner && step > 0) {
setHasAttachedListener(true);
const doFullscreen = () => {
if (screenfull.isEnabled) {
screenfull.request();
@@ -35,7 +35,23 @@ export default function Main() {
window.addEventListener("click", () => {
doFullscreen();
});
setHasAttachedListener(true);
if (window.visualViewport) {
const handleResize = () => {
const keyboardHeight = window.innerHeight - window.visualViewport.height;
const appContainer = document.querySelector('#app');
if (appContainer) {
appContainer.style.paddingBottom = keyboardHeight > 0 ? `${keyboardHeight}px` : '0px';
}
if (document.activeElement && keyboardHeight > 0) {
document.activeElement.scrollIntoView({ behavior: 'smooth', block: 'center' });
}
};
window.visualViewport.addEventListener('resize', handleResize);
window.visualViewport.addEventListener('scroll', handleResize);
}
doFullscreen();
}
}, [step, hasAttachedListerner, setHasAttachedListener]);
+14 -6
View File
@@ -35,13 +35,21 @@ export default function Riddle_7_AR_View({
const arSystem = sceneEl.systems['mindar-image-system'];
const handleRenderStart = () => {
const startAR = () => {
if (arSystem) {
try {
arSystem.start();
} catch (error) {
console.warn('AR System start error:', error);
}
}
};
sceneEl.addEventListener('renderstart', handleRenderStart);
if (sceneEl.hasLoaded) {
startAR();
} else {
sceneEl.addEventListener('loaded', startAR, { once: true });
}
targetsRef.current.forEach((targetEl, index) => {
if (!targetEl) return;
@@ -51,7 +59,7 @@ export default function Riddle_7_AR_View({
const targetConfig = TARGET_CONFIG.find((t) => t.targetIndex === index);
if (targetConfig) {
setShowNextButton(false);
setShowNextButton?.(false);
setActiveVideo(targetConfig);
}
};
@@ -66,7 +74,7 @@ export default function Riddle_7_AR_View({
return () => {
if (sceneEl) {
sceneEl.removeEventListener('renderstart', handleRenderStart);
sceneEl.removeEventListener('loaded', startAR);
}
if (arSystem) {
try {
@@ -125,8 +133,8 @@ export default function Riddle_7_AR_View({
position: 'fixed',
top: 0,
left: 0,
width: '100vw',
height: '100vh',
width: '100dvw',
height: '100dvh',
backgroundColor: '#000',
zIndex: 9999,
display: 'flex',
+1
View File
@@ -14,6 +14,7 @@
.content {
height: 100%;
max-height: 50dvh;
padding-bottom: 15dvh;
p {
font-size: 1.3rem;
margin-bottom: 1rem;
+1 -1
View File
@@ -3,7 +3,7 @@
flex-direction: column;
height: 100dvh;
width: 100%;
overflow: hidden;
overflow: auto;
}
.top-bar {
position: absolute;
+1 -1
View File
@@ -16,4 +16,4 @@ const isDev = process.env.NODE_ENV === "development";
export const HTTP_SCHEME = isDev ? "http" : "https";
export const WS_SCHEME = isDev ? "ws" : "wss";
export const API_PREFIX = isDev ? "10.8.0.23:8080" : "api.excaliburs-erben.de";
export const API_PREFIX = isDev ? "192.168.0.110:8080" : "api.excaliburs-erben.de";