You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 9771190
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ The site of the [missing-elements](https://github.com/missing-elements) web comp
9
9
|`/`| The project list, the tools (the build page first, with its how-to), and a footer of links |[src/index.njk](src/index.njk); the lists are in [src/_data/site.js](src/_data/site.js)|
10
10
|`/pdfjs-viewer/`| The docs of `<pdfjs-viewer-element>`, with a live preview |[src/pdfjs-viewer/](src/pdfjs-viewer/)|
11
11
|`/h5p/build/`| The build page, for people: what it makes, a sample that plays, and the build of a chat's source into a `.h5p`, in the visitor's browser |[src/h5p/build/](src/h5p/build/)|
12
-
| `/h5p/play/` | The play page, for a chat app to show in its reply (h5p-toolkit#210); no page links to it. It builds the activity in a link's `#source=` in the visitor's browser, as the build page does, and plays it with nothing beside it but its download and a link to the build page. A file of the visitor's own that the source names is chosen there or given by the page that frames it. A video or a recording can be given as its address: it plays from there at once and is fetched whole only for the download. A framing page that saves files itself is handed the download. A package bigger than that page saves stays behind the Download link, and the page says how to save it from such a frame. A framing page that opens links itself is handed the link to the build page. A link to the page may also carry the files' addresses and a wish to save (`&links=`, `&save=1`): in a tab of its own the page then draws no player: it fetches the files itself, builds the package and tries to save it with no press. Saved, it counts five seconds while it is looked at and then tries to close the tab; a tab the browser keeps open says to press Download where nothing was saved. That is how a framing page that opens links gets a package saved that it cannot save itself. | [src/h5p/play/](src/h5p/play/) |
12
+
| `/h5p/play/` | The play page, for a chat app to show in its reply (h5p-toolkit#210); no page links to it. It builds the activity in a link's `#source=` in the visitor's browser, as the build page does, and plays it with nothing beside it but its download and a link to the build page. A file of the visitor's own that the source names is chosen there or given by the page that frames it. A video or a recording can be given as its address: it plays from there at once and is fetched whole only for the download. A framing page that could not bring a file it was asked for says so, and the page asks the visitor for it. A framing page that saves files itself is handed the download. A package bigger than that page saves stays behind the Download link, and the page says how to save it from such a frame. A framing page that opens links itself is handed the link to the build page. A link to the page may also carry the files' addresses and a wish to save (`&links=`, `&save=1`): in a tab of its own the page then draws no player: it fetches the files itself, builds the package and tries to save it with no press. Saved, it counts five seconds while it is looked at and then tries to close the tab; a tab the browser keeps open says to press Download where nothing was saved. That is how a framing page that opens links gets a package saved that it cannot save itself. | [src/h5p/play/](src/h5p/play/) |
13
13
|`/h5p/create-with-ai/`| The how-to, for people: installing the skill, asking a chat, the prompts to start from, the types, and what to do when something goes wrong |[src/h5p/create-with-ai/](src/h5p/create-with-ai/)|
14
14
|`/h5p/skill/`| The skill as zips to install: `h5p-author.zip`, installed once in a chat's place for skills, or attached to the message in each new chat where it has none, and `h5p-author-chatgpt.zip`, the same skill laid out as a plugin; and a page that lists them and the bundles' addresses, each in full, which no page links to |[src/h5p/skill/](src/h5p/skill/); the zips written by [vite.config.ts](vite.config.ts)|
15
15
|`/h5p/bundles/`| The skill's build tool and a library bundle per content type, for a chat that runs Node but cannot reach npm; and `h5p-author-build.tar.gz`, the tool and every library in one archive, for a person to attach to a chat whose code can download nothing | written by [vite.config.ts](vite.config.ts)|
Copy file name to clipboardExpand all lines: src/h5p/play/play-page.ts
+33-9Lines changed: 33 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -453,17 +453,40 @@ async function fetchFiles(): Promise<void> {
453
453
}catch(error){
454
454
// Stopped for a file the person chose: that one is built from.
455
455
if(stop.signal.aborted)return
456
-
bringing=false
457
-
consttext=`Your ${previewedAs()} could not be fetched from the chat (${errorinstanceofError ? error.message : String(error)}): its address may have run out. Choose it from your computer instead.`
/** The files for a download did not come, to this page or to the parent that was asked for them: said under the stage, with the way on. */
461
+
functionnotBrought(why=''): void{
462
+
bringing=false
463
+
consttext=`Your ${previewedAs()} could not be fetched from the chat${why ? ` (${why})` : ''}: its address may have run out. Choose it from your computer instead.`
464
+
keepInstead.hidden=false
465
+
keepProgress.hidden=true
466
+
keepLabel.textContent=text
467
+
download.removeAttribute('aria-disabled')
468
+
downloadLabel.textContent='Try again'
469
+
announce(text)
470
+
}
471
+
472
+
/**
473
+
* The parent says a file it was asked for did not come (#106). For a download, that is said
474
+
* under the stage. For a file the activity is waiting to be built with, the person is asked for
475
+
* it, with the reason: while it is shown coming, while the question is held back a moment for
476
+
* the parent's answer, and where the question is shown already. At any other time it says
askText.textContent=`Your ${one ? called(missing[0]!) : 'files'} could not be fetched from the chat. Choose ${one ? 'it' : 'them'} from your computer; ${one ? 'it stays' : 'they stay'} in your browser.`
488
+
}
489
+
467
490
/**
468
491
* In a tab that only saves: the files fetched from the addresses the link carried, shown coming in
469
492
* the stage, and then built from. One that cannot be fetched is asked for, as where none was given.
0 commit comments