So, I introduced a pesky line break into a Navigation section. I can see it in the HTML, and that area does not let me delete it. In the work area of Bootstrap Studio, it deletes the first link on the following line.
Ideas - I see this was discussed in the forum in 2021 (Windows issue?) I should be able to delete a Shft-Enter during the creation process.
Sorry - I probably should have started the conversation with this:
I am trying to control a series of links in a navigation (paragraph with link items) bar so that when it is seen at XS or SM the paragraph has two lines to control the layout of the links. And then on a single line for all other sizes.
How is this done - Media Query seems to not allow this, or does it? Or is there a better component for this?
You can use a single list and leverage Bootstrap’s grid or flex utilities to adjust the layout based on screen size.
For example, if your goal is to display two links per row on small screens and four links in one row on larger screens, you can do something like this:
Bootstrap’s grid system is based on 12 columns, so the idea is to divide 12 by the number of items you want per row. In the example above with 4 links, we used col-md-3 since 12 ÷ 4 = 3.
For 6 Links
One Row on Larger Screens:
If you want all 6 links in a single row on medium screens and up, each link should take up 12 ÷ 6 = 2 columns. For example:
Thank you for this solution - I am going to give it a try. I will report back either way, works or I hit a wall. BTW math is not my favorite thing in the world, Photoshop, now that is more my jam!
Is it possible to use this same technique for two lines of text on a smaller screen that becomes a single line on larger screens? I have a notice that is breaking at an inappropriate location on the phone sized screen. If so, quick comment as to process?
Block-level elements, such as the <h1>–<h6> elements or <p>, will span two or more lines when their content does not fit within the parent element. Therefore, no additional technique is required.