Skip to content

Commit

Permalink
Update progress example to allow UI to update on progress (#1171)
Browse files Browse the repository at this point in the history
  • Loading branch information
thekevinscott authored Oct 2, 2023
1 parent 5497eab commit d3ea7fa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/progress/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ button.onclick = () => {
.upscale(img, {
patchSize: 2,
padding: 2,
awaitNextFrame: true,
progress: (amount) => {
progressLabel.innerText = `${(amount * 100).toFixed(2)}%`;
},
Expand Down
2 changes: 1 addition & 1 deletion scripts/start-example.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ const getArgs = async (): Promise<Answers> => {
skipUpscalerBuild: { type: 'boolean' },
}).help().argv;

const exampleDirectory = await getString('Which hdf5 model do you want to build?', argv._[0]);
const exampleDirectory = await getString('Which example do you want to start?', argv._[0]);

return { exampleDirectory, skipUpscalerBuild: argv.skipUpscalerBuild };
}
Expand Down

0 comments on commit d3ea7fa

Please sign in to comment.