-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Not possible to disable Pagination pagesize input #6055
Comments
If you set prop |
@nictownsend Thanks for your reply. That would indeed prevent the user from selecting a new page size, but it doesn't actually disable the input. It would look like this where the user could still interact with the input: |
True - semantically then I think this is a feature request, as the component has behaved that way consistently. Out of interest, what's the use case for disabling it - is it because changing it might cause a new request from browser you want to stop? |
I'm working with the carbon-addons-iot-react team on a new feature and we need the Pagination to be completely disabled when editing a table (one reason is the one you mentioned). The pagination component does have a |
@bjornalm @nictownsend @carbon-design-system/design Would you expect the Trying to determine if we need to
I think option 3 would be the easiest, but I'm unsure if there are use cases where we need to leave some items enabled. |
Personally, option 3 works for me - if you're stopping people changing pages, it seems sensible to stop them changing page size too, as it somewhat equates to a pagination action (go from one page of 10 to showing 10 pages of 10). I'd say it depends on the use case for disabled in general - I'm personally struggling to see why you would stop a user changing page, but allow them to change the page size. |
In my particular case option 3 would work fine, and I think that would make most sense from an API/design perspective but perhaps there is a solid use case for keeping them separated that I can't think of. |
Title line template: [Title]: Brief description
There is no prop to disable selection of a new page size.
What package(s) are you using?
carbon-components
carbon-components-react
Detailed description
The bug is in the Pagination component. There is no prop to disable selection of a new page size. The
pageInputDisabled
prop only disables the input for selecting a predefined page, it does not disable the input for defining/selecting a new page size, hence it is not possible to completely disable the Pagination component.Steps to reproduce the issue
pageInputDisabled
and the general propdisabled
to be true.The text was updated successfully, but these errors were encountered: