-
Hi,
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
The spacing utilities support breakpoints for when the utility should be used. In your case you'd add I haven't used Bootstrap 5 yet, but perhaps there's a smarter way to add spacing between columns when they collapse in v5, but the above should be the answer to your question. |
Beta Was this translation helpful? Give feedback.
-
Hi, I just want to say that it's not working for xs so we need to use This is a bit confusing, but this is working fine |
Beta Was this translation helpful? Give feedback.
The spacing utilities support breakpoints for when the utility should be used.
https://getbootstrap.com/docs/5.0/utilities/spacing/#notation
In your case you'd add
mt-md-3
to add a top margin when on the md breakpoint.The issue is that this will also be valid on the
lg
breakpoint, which is why you'll also need to addmt-lg-0
to set the margin back to 0.I haven't used Bootstrap 5 yet, but perhaps there's a smarter way to add spacing between columns when they collapse in v5, but the above should be the answer to your question.