Repository navigation
Make the login form explain itself, and correct release claims in the audit - #97
Merged
Merged
Conversation
…claims Closes #91: the login help popup said "Provide a new PIN" without giving the length, while the input's aria-label and the validation error both say "4-digit". Only the guidance was inconsistent. Also corrects a factual error in docs/PROJECT_STATE.md. The report claimed the release workflow had never run and no tag had ever been pushed. Tag v0.2.0 and a GitHub Release with both bundle assets were published by that workflow on 2025-11-29. The error came from reading `git tag` in a clone whose fetch refspec covers refs/heads only, so no tags were present locally, and concluding from that empty list that no releases existed. A correction notice at the top of the report records the mistake and how to check properly (git ls-remote --tags, or the Releases API). Backlog item 17 is withdrawn rather than marked done, since its premise was wrong; what remains is a version bump for the unreleased work, which is the owner's decision. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015u1mfVebscuZA3YDc6hc87
Contributor
🚀 PR Preview Deployment✅ Your changes are being built and deployed to a preview environment. 📋 Live PR Preview Links: ℹ️ About PR Previews:
📦 Production Demo (main branch): 🧪 Testing Locally: npm install
npm run build
# Open demo/quiz-index.html in your browser (use file:// or http-server)This comment will be automatically updated when you push new commits. |
Reported from the gh-pages demo: the login controls were visible but the Login button could not be enabled. The form was not broken. The button is disabled until name, service ID and a 4-digit PIN are all valid, and the PIN is easy to miss: it is a narrow unlabelled box whose placeholder said only "PIN", while the other two fields carry worked examples. Worse, an invalid form gave no feedback at all. The validation messages exist but only run on submit, and submit is unreachable precisely because the button is disabled; pressing Enter does not help either, since a disabled submit button blocks implicit submission. Verified in a browser: with no PIN, a 3-digit PIN, a service ID containing a space, or a service ID over ten characters, the button stayed disabled and nothing was displayed. The form now shows the first outstanding validation message live, so "PIN required" and "PIN must be exactly 4 digits" appear as the user types. A pristine form stays quiet rather than scolding someone before they have typed anything. The PIN field also gains a title tooltip to go with its existing aria-label. Not done, deliberately: widening the PIN field to fit a "PIN (4 digits)" placeholder. Measured in a browser, the header bar has about 4px of slack at 1280px, so 45px of field width fits on one row and 50px pushes the Instructor button onto a second row. The hint carries the rule instead, and the header layout is byte-for-byte the height it was. Bundle 39.36 KB gzip against the 40 KB limit. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_015u1mfVebscuZA3YDc6hc87
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.
Three changes. The first two came from a report that the gh-pages demo showed login controls but the Login button could not be enabled.
The Login button gave no reason for being disabled
The form was not broken. The button is disabled until name, service ID and a 4-digit PIN are all valid. The PIN is easy to miss: a narrow box whose placeholder said only "PIN", while the other two fields carry worked examples like "Name (J Smith)".
The real problem was silence. Validation messages exist, but they only run on submit, and submit is unreachable precisely because the button is disabled. Pressing Enter does not help either, since a disabled submit button blocks implicit submission.
Verified in a browser against the deployed content. In every one of these states the button stayed disabled and nothing at all was displayed:
The form now shows the first outstanding validation message live, so "PIN required" and "PIN must be exactly 4 digits" appear as you type. A pristine form stays quiet rather than scolding someone before they have typed anything. The PIN field also gains a
titletooltip alongside its existing aria-label.Deliberately not done: widening the PIN field. I proposed a "PIN (4 digits)" placeholder, then measured it. The header bar has roughly 4px of slack at 1280px: a 45px field fits on one row, 50px pushes the Instructor button onto a second row. Widening it regressed the header from 81px to 105px tall. The hint carries the rule instead, and the header is exactly the height it was.
Closes #91
The login help popup said "Provide a new PIN" without stating the length, while the field's aria-label and the validation error both say "4-digit". Now the guidance agrees with them.
Corrects a factual error in the consolidation audit
docs/PROJECT_STATE.mdclaimed the release workflow had never run and that no tag had ever been pushed. That is false. Tagv0.2.0and a GitHub Release, withsonar-quiz.iife.jsand its source map attached, were published by that workflow on 2025-11-29.The error came from reading
git tagin a clone whose fetch refspec is+refs/heads/*:refs/remotes/origin/*— heads only, no tags — and concluding from the empty local list that no releases existed, without checking the remote.Rather than edit it away silently, the report carries a correction notice recording the mistake and how to verify properly. Backlog item 17 is withdrawn rather than marked done, because its premise was wrong. This nearly caused a bad action: the next planned step was to tag
v0.2.0onmain, which would have collided with an existing tag that has a published release attached.What remains on releases:
package.jsonstill says0.2.0, the version already released in November, so all the consolidation work is unreleased. Publishing it needs a version bump, and the number is the owner's call.Verification
ENCRYPT_STORAGE=trueHeadroom is down to 0.64 KB. That is the constraint to watch on the next change.
🤖 Generated with Claude Code
https://claude.ai/code/session_015u1mfVebscuZA3YDc6hc87