Repository navigation
feat(play): a framing page that saves files is handed the package by Download (#98) - #99
Merged
Merged
Conversation
…Download (#98) Inside a chat's card the page's own Download saved nothing: the chat lets the frame save no file, and drops the press unsaid. The card can ask the chat to save one. So a framing page says it saves files, with the most it takes ({ type: 'saves', max }), and Download hands it the package ({ type: 'save', file }) where the page would have saved it; the framing page says how it went ({ type: 'saved', ok }), which the row under the stage says: saving, saved, or not saved, with the build page to open. No word in a minute is taken as not saved. A package above max is not handed over, and a video that would make one is not fetched for it where the framing page gave its size (sizes, beside links): the row says the size and offers the build page, where the person chooses the file and downloads as anywhere. With no 'saves', everything is as it was.
…he build again (#98)
There was a problem hiding this comment.
All reported issues were addressed across 3 files
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
…e handed is taken (#98)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #98. Part of missing-elements/h5p-toolkit#210.
Inside a chat's card the play page's Download did nothing: the chat lets the frame save no file. The card can ask the chat to save one. Now a framing page that saves files says so, and Download hands it the package.
For the page that frames this one
All optional. With no
saves, the page saves as before.{ type: 'saves', max }maxis the most bytes it takes; none means any size.{ type: 'save', id, file }idnumbers the save. Sent where the page would have saved it: at once for a package with its files in it, and after the bytes are brought and the package built for one whose video plays from the chat.{ type: 'saved', id, ok }idwent,oka boolean. Only word on the last package handed is taken. No word in a minute is taken as not saved; a yes that comes later is still said.sizes, besidelinks{ 'clip.mp4': bytes }: what the file at each address weighs. A video that would make a package abovemaxis then not fetched for it.What a person sees
saves: as before.Testing
By hand, as this repository has no page tests: the built site served locally and framed by a page of another origin acting as a card that saves files, with a store on a third origin.
max64 MB, the card answers yes (light and dark at 720 px, light at 360 px)savewith the 882 kB package; the browser saves nothingok/h5p/build/with the sourcemaxsavesaveswater.h5p, no row: as beforemax(720 and 360 px)needs-bytes, nothing fetchedmaxneeds-bytes, the package built, onesavewith the 6.3 MB package, "Saved…"max, no size givensavesaves: unchanged (one browser save for one press, onebuilt, no restart).pnpm buildandpnpm typecheckpass. Screenshots of the rows looked at.Not verified
savesand answersavewith the chat's own save first, the next step of h5p-toolkit#210.Summary by cubic
The play page's Download now hands a package to a framing page that saves files, where before it could not save anything inside a chat's card.
{ type: 'saves', max }to say it saves files itself; Download sends{ type: 'save', file, id }and expects{ type: 'saved', id, ok }back, where only the word on the last one handed counts, and a minute of silence is taken as not saved.maxis not handed over, and a video that would make one is not fetched when the frame gave its size (sizesbesidelinks); the too-big row offers the build page instead.savesmessage, behavior is unchanged.Written for commit 0785753. Summary will update on new commits.