Skip to content

[otp field] Align slot callbacks and aria label API - #49936

Open
adityajai119 wants to merge 18 commits into
mui:masterfrom
adityajai119:fix/w45-bug
Open

adityajai119 wants to merge 18 commits into
mui:masterfrom
adityajai119:fix/w45-bug

Conversation

@adityajai119

Copy link
Copy Markdown
Contributor

Stacked on the commits from #49875, which are still unmerged, so this branch can be reviewed and tested independently.

Implements the API consistency points from the review:

  • slotProps.group callbacks, including className and style, receive Material ownerState. Base UI state stays available through render and data attributes.
  • Renames getInputAriaLabel to getAriaLabel, matching Slider's getAriaLabel, across props, locale defaults, generated API docs, and tests.
  • Removes Base UI references from the OTP Field documentation (data-attributes section, Anatomy, and slot descriptions).

Narrow OTPField unit tests, ESLint, Prettier, pnpm typescript, pnpm proptypes, and pnpm docs:api pass.

Needs a maintainer decision: theme keys for the exported OTPFieldInput/OTPFieldSeparator parts, visual parity with OutlinedInput and whether variant is in scope, MuiTextField default-prop inheritance, and whether to drop render from the Material-only label and formHelperText slots.

@code-infra-dashboard

code-infra-dashboard Bot commented Nov 27, 2026 •

Copy link
Copy Markdown

Deploy preview

Bundle size

Bundle Parsed size Gzip size
@mui/material 🔺+28KB(+4.91%) 🔺+10.1KB(+6.18%)
@mui/lab 0B(0.00%) 0B(0.00%)
@mui/private-theming 0B(0.00%) 0B(0.00%)
@mui/system 0B(0.00%) 0B(0.00%)
@mui/utils 0B(0.00%) 0B(0.00%)

Details of bundle changes

Performance

No regressions in 32 benchmarks · precise to ±8.7% (±15.5% at worst) · ran 4m 09s · details


Check out the code infra dashboard for more information about this PR.

This branch has not been deployed

No deployments
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