From 17ca2d68d50b26d1e85fc73fc16de42143842c25 Mon Sep 17 00:00:00 2001 From: horeaporutiu Date: Wed, 20 Sep 2023 14:28:20 +0200 Subject: [PATCH] kirill feedback --- examples/ai-image-generator/pages/index.jsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/ai-image-generator/pages/index.jsx b/examples/ai-image-generator/pages/index.jsx index 93a29e265..7e1fda3a2 100644 --- a/examples/ai-image-generator/pages/index.jsx +++ b/examples/ai-image-generator/pages/index.jsx @@ -19,7 +19,7 @@ export const getServerSideProps = async function getServerSideProps({ req }) { }; }; -export default function Main({ boards, authUrl }) { +export default function Main({ authUrl }) { useEffect(() => { removeSpinner(); // Opens the panel for our app UI when we click on icon in the left sidebar @@ -59,14 +59,14 @@ export default function Main({ boards, authUrl }) { }; // Shows spinner while API calls are in progress / image is being dragged & dropped - const showSpinner = async () => { - let spinner = await document.getElementById("spinner"); + const showSpinner = () => { + const spinner = document.getElementById("spinner"); spinner.style.visibility = "visible"; }; // Removes spinner when API calls are finished and data is returned / image has been dropped - const removeSpinner = async () => { - let spinner = await document.getElementById("spinner"); + const removeSpinner = () => { + const spinner = document.getElementById("spinner"); spinner.style.visibility = "hidden"; };