Repository navigation
feat(verify): a Download button on the preview page - #82
Merged
Merged
Conversation
The preview showed the package's name and nothing to take the file away with, so whoever reviewed a package there had to find the folder the command ran in; in the h5p-author skill's flow, an agent chose it. The bar now has a Download button beside the name, which saves the .h5p under its own name. The link takes the address the page already parsed and checked for the player's src, http or https only, from the parsed URL's href (#71). It hides once the presence stream fails, when the page says the preview has ended, since the server it downloads from has gone. A test clicks it in a browser and compares the saved file with the package byte for byte, then ends the preview and waits for the link to go: it times out on the old page, and passes. Closes #81. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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 #81.
h5p-verify --previewshowed the package's name and nothing to take the file away with. Whoever reviewed a package there had to find the folder the command ran in, and in the h5p-author skill's flow an agent chose that folder. The preview's bar now has a Download button beside the name. One click saves the.h5punder its own name, and the content plays as before.Changes
lib/preview.html: a Download link in the bar.src:httporhttpsonly, from the parsed URL'shref(A package address reaches src as text, and CodeQL files the same alerts after every change #71), never the settings text.aria-describedbynames the file.tests/preview.test.ts: a browser clicks Download and compares the saved file with the package byte for byte. It then ends the preview and waits for the link to go.docs/verify.mdand the--previewentry in AGENTS.md. The skills are left alone until the release, because they're installed frommain.Testing
typecheckpasses.Not verified: Firefox and Safari's download handling, and Windows.
Release
A minor for
@missing-elements/h5p-verify: 1.3.0. Nothing else changes. Once it's on npm, the h5p-verify and h5p-author skills can tell the reviewer about the button.🤖 Generated with Claude Code