Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Tab] Add explicit return type to useTab #36046

Merged
merged 3 commits into from
Feb 10, 2023
Merged

Conversation

sai6855
Copy link
Contributor

@sai6855 sai6855 commented Feb 4, 2023

UseTab return value interface

closes: useTab in #35933

preview: https://deploy-preview-36046--material-ui.netlify.app/base/api/use-tab/#return-value

@sai6855 sai6855 marked this pull request as draft February 4, 2023 06:24
@mui-bot
Copy link

mui-bot commented Feb 4, 2023

Messages
📖 Netlify deploy preview: https://deploy-preview-36046--material-ui.netlify.app/

No bundle size changes

Generated by 🚫 dangerJS against f56b7ef

@sai6855 sai6855 marked this pull request as ready for review February 4, 2023 06:40
@zannager zannager added the component: tabs This is the name of the generic UI component, not the React module! label Feb 6, 2023

export interface UseTabReturnValue {
/**
* If `true`, the tab is disabled.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* If `true`, the tab is disabled.
* If `true`, the component will be selected.

*/
selected: boolean;
/**
* If `true`, the tab's focus is visible.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* If `true`, the tab's focus is visible.
* If `true`, the tab's focus will be visible.

*/
setFocusVisible: React.Dispatch<React.SetStateAction<boolean>>;
/**
* If `true`, the tab is disabled.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* If `true`, the tab is disabled.
* If `true`, the component will be disabled.

*/
disabled: boolean;
/**
* If `true`, the tab is active.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* If `true`, the tab is active.
* If `true`, the component will be active.

@sai6855 sai6855 requested a review from mnajdova February 8, 2023 17:20
Copy link
Member

@mnajdova mnajdova left a comment

Choose a reason for hiding this comment

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

Thanks. I noticed that the description for the getRootProps when generating the json is not complete. I will need to figure out why this is the case.

@mnajdova mnajdova merged commit 16a8adb into mui:master Feb 10, 2023
@oliviertassinari oliviertassinari added typescript package: base-ui Specific to @mui/base docs Improvements or additions to the documentation labels Feb 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: tabs This is the name of the generic UI component, not the React module! docs Improvements or additions to the documentation package: base-ui Specific to @mui/base typescript
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants