Password fields: add generator action and overlay #267

Closed
opened 2026-07-15 13:08:47 +02:00 by zemion · 1 comment
Owner

Context

Several configuration surfaces contain password fields, for example campaign ZIP password configuration and mail/server credential settings. Users should be able to generate strong passwords directly where the password is entered.

Desired behavior

  • Add a small dice/generator button to reusable password input fields.
  • Open a compact overlay/dialog for generated password options and confirmation.
  • Let users copy/use the generated password without accidentally replacing the current value.
  • Make the component reusable from campaign, mail, connector, and admin credential forms.

Acceptance criteria

  • Password fields can opt into a generator action without duplicating logic per module.
  • Generated passwords use a secure browser API when available.
  • The generated value is only written after explicit user confirmation.
  • Keyboard and screen-reader behavior matches the existing dialog/button patterns.
## Context Several configuration surfaces contain password fields, for example campaign ZIP password configuration and mail/server credential settings. Users should be able to generate strong passwords directly where the password is entered. ## Desired behavior - Add a small dice/generator button to reusable password input fields. - Open a compact overlay/dialog for generated password options and confirmation. - Let users copy/use the generated password without accidentally replacing the current value. - Make the component reusable from campaign, mail, connector, and admin credential forms. ## Acceptance criteria - Password fields can opt into a generator action without duplicating logic per module. - Generated passwords use a secure browser API when available. - The generated value is only written after explicit user confirmation. - Keyboard and screen-reader behavior matches the existing dialog/button patterns.
zemion added the area/apicodex/readymodule/core
priority
p2
status
ready
type
feature
labels 2026-07-29 14:15:04 +02:00
Author
Owner

Codex State: done

Summary

  • Implemented the reusable secure password generator in Core PasswordField and enabled it only on credential creation/change surfaces.
  • Generated candidates use crypto.getRandomValues with rejection sampling, fail closed without a secure provider, and do not alter the field until Use password is confirmed.
  • Campaign adopts the control for Mail-owned campaign credentials and password-valued fields; login/current-password fields remain unchanged.

Changed Files

  • govoplan-core@0c9bf67
  • govoplan-campaign@4133de8

Verification

  • npm run test:password-field: passed
  • npm run test:mail-components: passed
  • npm run test:campaign-lifecycle: passed
  • pytest -q tests/test_documentation.py: 19 passed
  • core npm run build: passed with bundle budgets
  • check-manifest-shapes.py: 65/65 passed
## Codex State: done ### Summary - Implemented the reusable secure password generator in Core PasswordField and enabled it only on credential creation/change surfaces. - Generated candidates use crypto.getRandomValues with rejection sampling, fail closed without a secure provider, and do not alter the field until Use password is confirmed. - Campaign adopts the control for Mail-owned campaign credentials and password-valued fields; login/current-password fields remain unchanged. ### Changed Files - `govoplan-core@0c9bf67` - `govoplan-campaign@4133de8` ### Verification - `npm run test:password-field: passed` - `npm run test:mail-components: passed` - `npm run test:campaign-lifecycle: passed` - `pytest -q tests/test_documentation.py: 19 passed` - `core npm run build: passed with bundle budgets` - `check-manifest-shapes.py: 65/65 passed`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: GovOPlaN/govoplan-core#267