Merge pull request #81 from zero01101/testing
Simple Index 0 image count fix and test if internal pulls still work
This commit is contained in:
commit
9af58c7ee6
2 changed files with 7 additions and 7 deletions
4
.github/workflows/autoformat.yml
vendored
4
.github/workflows/autoformat.yml
vendored
|
@ -13,9 +13,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
ref: ${{ github.head_ref }}
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- name: Prettify
|
||||
uses: creyD/prettier_action@v4.2
|
||||
with:
|
||||
|
|
|
@ -222,7 +222,7 @@ const _generate = async (
|
|||
at--;
|
||||
if (at < 0) at = images.length - 1;
|
||||
|
||||
imageindextxt.textContent = `${at}/${images.length}`;
|
||||
imageindextxt.textContent = `${at}/${images.length - 1}`;
|
||||
redraw();
|
||||
};
|
||||
|
||||
|
@ -230,7 +230,7 @@ const _generate = async (
|
|||
at++;
|
||||
if (at >= images.length) at = 0;
|
||||
|
||||
imageindextxt.textContent = `${at}/${images.length}`;
|
||||
imageindextxt.textContent = `${at}/${images.length - 1}`;
|
||||
redraw();
|
||||
};
|
||||
|
||||
|
@ -256,7 +256,7 @@ const _generate = async (
|
|||
interruptButton.disabled = false;
|
||||
imageCollection.inputElement.appendChild(interruptButton);
|
||||
images.push(...(await _dream(endpoint, requestCopy)));
|
||||
imageindextxt.textContent = `${at}/${images.length}`;
|
||||
imageindextxt.textContent = `${at}/${images.length - 1}`;
|
||||
} catch (e) {
|
||||
alert(
|
||||
`Error generating images. Please try again or see consolde for more details`
|
||||
|
@ -330,11 +330,11 @@ const _generate = async (
|
|||
imageSelectMenu = makeElement("div", bb.x, bb.y + bb.h);
|
||||
|
||||
const imageindextxt = document.createElement("button");
|
||||
imageindextxt.textContent = `${at}/${images.length}`;
|
||||
imageindextxt.textContent = `${at}/${images.length - 1}`;
|
||||
imageindextxt.addEventListener("click", () => {
|
||||
at = 0;
|
||||
|
||||
imageindextxt.textContent = `${at}/${images.length}`;
|
||||
imageindextxt.textContent = `${at}/${images.length - 1}`;
|
||||
redraw();
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue