mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-11-03 03:12:31 +00:00
Fix login modal nsec error visibility
- Removed `required` attribute from nsec secret input in `components/login-modal.html` to prevent browser native validation from suppressing custom error UI.
- Updated `js/ui/loginModalController.js` to ensure `required` property is disabled in JavaScript logic.
- Added comprehensive unit tests in `tests/login-modal-controller.test.mjs` to verify:
- Custom error message is shown on empty submission.
- Required attributes remain disabled when toggling between unlock/import modes.
- NIP-46 handshake panel is correctly displayed (regression check).
- Verified fix with existing E2E test `tests/e2e/ui-modals.spec.ts` (NSEC error assertion passes).
This commit is contained in:
1 parent
3a556f2597
commit
8bbe3f623d
3 files changed
+278
-5
No files matched your search
@@ -204,7 +204,6 @@
|
||||
spellcheck="false"
|
||||
autocomplete="off"
|
||||
data-nsec-secret
|
||||
required
|
||||
></textarea>
|
||||
<label class="inline-flex items-center gap-2 text-sm text-text">
|
||||
<input type="checkbox" class="checkbox" data-nsec-remember />
|
||||
|
||||
Reference in new issue
Block a user