When browser window is resized (reduced) and when content is reached (width of menu links (no media queries)) , menu links div should go below header (and then menu div should have width=100%)…
HTML structure should not be changed because of keyboard tabbing (or if changed - tabbing should go from LOGOTYPE to MENU LINKS and then to ICONS)… Maybe flex is not solution? Please no javascript, no tables…
Mr. Coothead I really appreciate your effort and I would not like to be ungrateful, but I mentioned that this should be achieved without media queries … Maybe that note did not turn out to be the clearest? My english is poor.
Thanks a lot for the help.
Also, I forgot to mention that the wrapper must have a max-width.
My first thoughts are that you won’t be able to do this without changing the order of the html which means you’d have to set the tabbing order manually.
If you change the order of the html then you can do something like this.
However you would still need a media query when you get down to 400px wide so that you can break the menu into smaller pieces.
There are probably other ways using the re-arranged html but that was my first try.
I don’t believe you can achieve what you want without using media queries and even if it can be done it will require some trickery and magic number fixes that will most likely render it fragile.
I’d probably stick with something like @coothead has already shown.
Thax PaulOB, that’s what I was hoping could be achieved.
As for media queries, this is just part of the menu functionality I making and applies to large viewport devices … For small viewport devices I use media queries for the hamburger menu.
When I complete the code, I will post a link on the forum so that you can rate it and give suggestions for improvements.
Now, I still have to find a solution for re-arranged HTML. As far as I have read tabindex positive value is not recommended.
Once again, I apologize for the insufficiently explained question.
Flex can re-order how content appears, which won’t change the order that the elements are actually in, in the document, so should not change the tab order. Though you will need a query to trigger a change for different screens.
Just for fun and if you don’t mind nesting the logo in a div then you can achieve the effect without needing to directly set the tab order as the html will be in logical tabbing order.
I’m not seeing any other solution that doesn’t involve changing the order of the html or using media queries. There indeed may be a solution but I’m just not seeing it
Yes I find it funny that even in 2021 we are using tricks from 2001 to achieve layouts that grid and flexbox still can’t do. Grid and flexbox are great but they are still rigid and block orientated. More thought should have gone into the behaviour that people want and use (e.g. selecting which item should wrap when the page is squeezed). Some of the simplest things are still impossible to achieve in a cross browser way.
I am very grateful to you PaulOB, Erik_J, SamA74, coothead, you helped me find a solution that I would never have been able to do on my own (and I have been looking for it for days). I hope that your efforts will also benefit to other forum visitors …
The solution that fits into the navigation menu I am making is the following: