Skip to content

Render managed auth field input modes - #29

Merged
masnwilliams merged 5 commits into
mainfrom
hypeship/render-field-input-mode
Sep 15, 2026
Merged

masnwilliams merged 5 commits into
mainfrom
hypeship/render-field-input-mode

Conversation

@masnwilliams

@masnwilliams masnwilliams commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

summary

  • preserve optional canonical field input_mode values in the existing UI model
  • apply the hint through React’s inputMode prop while keeping identifier inputs as type="text"
  • retain compatibility with API events that omit the new field

dependencies

  • depends on Render generic identifiers as text inputs #28, which keeps canonical identifiers free of browser-native format validation
  • merge after kernel/kernel#3693 is deployed; older API responses remain compatible but do not carry input modes
  • kernel/managed-auth-agent#87 begins emitting host-observed hints

testing

  • bun test
  • bun run build
  • bun run typecheck
  • bun run format:check

Note

Low Risk
UI and autofill hinting only; behavior is covered by new unit tests and remains backward compatible when API omits input_mode.

Overview
Adds optional canonical input_mode (text | email | tel | numeric) on managed-auth fields, carries it through session normalization into DiscoveredField, and wires it to React inputMode on UnifiedAuthForm inputs while identifier fields stay type="text" so browsers do not apply email/tel format validation.

getAutocomplete now uses input_mode for dedicated email/tel autofill, keeps one-time-code ahead of tel hints on code fields, and avoids inferring email autofill when a mixed identifier uses input_mode: "text". InputMode is exported from the package; a patch changeset documents the behavior.

Reviewed by Cursor Bugbot for commit a5b00b0. Bugbot is set up for automated code reviews on this repo. Configure here.

@vercel

vercel Bot commented Aug 31, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
managed-auth-react-demo Ready Ready Preview Sep 15, 2026 12:23am UTC

@masnwilliams
masnwilliams changed the base branch from hypeship/render-identifiers-as-text to main August 31, 2026 22:16
@masnwilliams
masnwilliams changed the base branch from main to hypeship/render-identifiers-as-text August 31, 2026 22:16
@masnwilliams masnwilliams changed the title hypeship/render field input mode Render managed auth field input modes Aug 31, 2026
@masnwilliams
masnwilliams changed the base branch from hypeship/render-identifiers-as-text to main August 31, 2026 22:39
Comment thread packages/managed-auth-react/src/session/state.ts Outdated

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0770c2a. Configure here.

Comment thread packages/managed-auth-react/src/components/UnifiedAuthForm.tsx Outdated

@akxue akxue left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reviewed — lgtm, approve. two non-blockers:

  • packages/managed-auth-react/src/components/UnifiedAuthForm.test.ts — worth adding a test pinning the ordering: input_mode should take precedence over the ref-based username heuristic (e.g. ref: "username" + input_mode: "email""email"), so the precedence is deliberate rather than emergent
  • packages/managed-auth-react/src/session/state.ts:68 — nit: ...(field.input_mode ? { input_mode: field.input_mode } : {}) can just be input_mode: field.input_mode since the prop is already optional

@masnwilliams
masnwilliams force-pushed the hypeship/render-field-input-mode branch from a157e0b to a5b00b0 Compare September 15, 2026 00:23
@masnwilliams
masnwilliams merged commit 8eadd7a into main Sep 15, 2026
4 checks passed
@masnwilliams
masnwilliams deleted the hypeship/render-field-input-mode branch September 15, 2026 00:30
@github-actions github-actions Bot mentioned this pull request Sep 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants