Skip to content

Commit 8cc9853

Browse files
authored
Merge pull request #45 from takuma-hmng8/dev
微修正
2 parents 5e17d7b + 34caad6 commit 8cc9853

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

app/domSyncer/DomSyncer.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as THREE from "three";
2-
import { useLayoutEffect, useRef } from "react";
2+
import { useEffect, useLayoutEffect, useRef } from "react";
33
import { useFrame, extend, useThree, useLoader } from "@react-three/fiber";
44
import { FxMaterial, FxMaterialProps } from "@/utils/fxMaterial";
55
import {
@@ -28,6 +28,10 @@ const CONFIG: {
2828
};
2929

3030
export const DomSyncer = ({ state }: { state: number }) => {
31+
useEffect(() => {
32+
document.documentElement.style.overflow = "auto";
33+
});
34+
3135
const mainShaderRef = useRef<FxMaterialProps>();
3236
const resolutionRef = useRef(new THREE.Vector2(0, 0));
3337
const textureRef = useRef(new THREE.Texture());

0 commit comments

Comments
 (0)