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
NgbPagination: Size 'md' missing from type #3816
Comments
Pagination doesn't have 'md' sizing in Bootstrap → https://getbootstrap.com/docs/4.5/components/pagination/#sizing However we should do the same we did for the modal (#3541) and convert |
Without a third option other than 'sm' | 'lg' there's no "default" (what I called md). In my use case, I set the size to "default" (what I call md) or "sm" based on a condition. With only sm and lg as valid option for the [size] variable I can't set it to default. I guess |
@softsimon thanks for the clarification, it's a valid point. So what you want is To make it happen we have to either:
|
I let you decide what makes more sense. At least now you know my specific use case 👍
I believe this solution works for me right now, thanks! |
Hi, I'm new here but can I give this a go? |
@niharika412, sure, please open a PR, this should be an easy one. Example from a similar PR → 591426d Just make sure to also add |
Bug description:
Pagination.ts states:
But the default size is actually 'md' which is a supported size.
So I am not allowed to set the [size] to 'md', without getting errors like this:
Type 'string' is not assignable to type '"sm" | "lg"'.
Solution
Add 'md' size to NgbPagination.size type
Versions of Angular, ng-bootstrap and Bootstrap:
Angular: 10
ng-bootstrap: 7
Bootstrap: 4.5
The text was updated successfully, but these errors were encountered: