fix(nds): hide help button on smaller devices
All checks were successful
Build and Push Docker Image / build (push) Successful in 2m7s
All checks were successful
Build and Push Docker Image / build (push) Successful in 2m7s
This commit is contained in:
@@ -28,13 +28,17 @@ const isTouchDevice = () =>
|
||||
|
||||
const windowSize = useWindowSize();
|
||||
|
||||
const isLargeEnough = computed(
|
||||
() => windowSize.width.value / windowSize.height.value > 614 / 667,
|
||||
);
|
||||
|
||||
watch([windowSize.width, windowSize.height], ([width, height]) => {
|
||||
if (width / height > 614 / 667) {
|
||||
if (app.booted) app.allowHints();
|
||||
} else {
|
||||
app.disallowHints();
|
||||
}
|
||||
});
|
||||
}, { immediate: true });
|
||||
|
||||
const helpButton = useTemplateRef("helpButton");
|
||||
let helpAnimation: gsap.core.Timeline | null = null;
|
||||
|
||||
@@ -61,7 +61,9 @@ export const useIntroStore = defineStore("intro", {
|
||||
)
|
||||
.call(() => {
|
||||
const app = useAppStore();
|
||||
if (window.innerWidth / window.innerHeight > 614 / 667) {
|
||||
app.allowHints();
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user