From 1573eb7abbcebdb3402b97cc112af953cf6d4f6e Mon Sep 17 00:00:00 2001 From: horeaporutiu Date: Wed, 20 Sep 2023 13:39:30 +0200 Subject: [PATCH] add same function style --- examples/ai-image-generator/pages/index.jsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/ai-image-generator/pages/index.jsx b/examples/ai-image-generator/pages/index.jsx index c69693b03..93a29e265 100644 --- a/examples/ai-image-generator/pages/index.jsx +++ b/examples/ai-image-generator/pages/index.jsx @@ -59,16 +59,16 @@ export default function Main({ boards, authUrl }) { }; // Shows spinner while API calls are in progress / image is being dragged & dropped - async function showSpinner() { + const showSpinner = async () => { let spinner = await document.getElementById("spinner"); spinner.style.visibility = "visible"; - } + }; // Removes spinner when API calls are finished and data is returned / image has been dropped - async function removeSpinner() { + const removeSpinner = async () => { let spinner = await document.getElementById("spinner"); spinner.style.visibility = "hidden"; - } + }; const handleButtonClick = async () => { //setting the image source to be a transparent color, otherwise we have a border which looks bad