From e6970a779709cfaf22232fe88c348baf6807f5b3 Mon Sep 17 00:00:00 2001 From: SHEN <1014628363@qq.com> Date: Mon, 23 Dec 2024 11:21:55 +0800 Subject: [PATCH] rename --- hello-world/next/README.md | 4 ++-- hello-world/next/components/ImageCapture/ImageCapture.tsx | 4 ++-- hello-world/react-hooks/README.md | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hello-world/next/README.md b/hello-world/next/README.md index 6449cf5e..7cf56700 100644 --- a/hello-world/next/README.md +++ b/hello-world/next/README.md @@ -259,7 +259,7 @@ function ImageCapture() { let pCvRouter: MutableRefObject | null> = useRef(null); let isDestroyed = useRef(false); - const decodeImg = useCallback(async (e: React.ChangeEvent) => { + const captureImage = useCallback(async (e: React.ChangeEvent) => { let files = [...(e.target.files as any as File[])]; e.target.value = ""; // reset input resultsContainer.current!.innerText = ""; @@ -314,7 +314,7 @@ function ImageCapture() { return (
- +
diff --git a/hello-world/next/components/ImageCapture/ImageCapture.tsx b/hello-world/next/components/ImageCapture/ImageCapture.tsx index d8b5b097..02ff1701 100644 --- a/hello-world/next/components/ImageCapture/ImageCapture.tsx +++ b/hello-world/next/components/ImageCapture/ImageCapture.tsx @@ -11,7 +11,7 @@ function ImageCapture() { let pCvRouter: MutableRefObject | null> = useRef(null); let isDestroyed = useRef(false); - const decodeImg = useCallback(async (e: React.ChangeEvent) => { + const captureImage = useCallback(async (e: React.ChangeEvent) => { let files = [...(e.target.files as any as File[])]; e.target.value = ""; // reset input let _resultText = ""; @@ -68,7 +68,7 @@ function ImageCapture() { return (
- +
{resultText}
diff --git a/hello-world/react-hooks/README.md b/hello-world/react-hooks/README.md index 3bf8d43a..8e1b6f31 100644 --- a/hello-world/react-hooks/README.md +++ b/hello-world/react-hooks/README.md @@ -236,7 +236,7 @@ function ImageCapture() { let pCvRouter: MutableRefObject | null> = useRef(null); let isDestroyed = useRef(false); - const decodeImg = useCallback(async (e: React.ChangeEvent) => { + const captureImage = useCallback(async (e: React.ChangeEvent) => { let files = [...(e.target.files as any as File[])]; e.target.value = ""; // reset input resultsContainer.current!.innerText = ""; @@ -291,7 +291,7 @@ function ImageCapture() { return (
- +