Skip to content

Commit

Permalink
kirill feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
horeaporutiu committed Sep 20, 2023
1 parent 2c5e61e commit 17ca2d6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions examples/ai-image-generator/pages/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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";
};

Expand Down

0 comments on commit 17ca2d6

Please sign in to comment.