I've built a web menu that mimics a Windows98 start menu. That menu has one key feature - it has fixed height and column width. If the number of items overflows the available space, a new column is created beside previous one. Perfect job for flexbox.
I need borders for every column of items. No problem for left/right borders. However the top/bottom borders overflows actual columns.
How can this be solved? Is using flexbox for this task correct?
.w98smenu {
align-content: flex-start;
border-top: 1px solid silver;
border-bottom: 1px solid silver;
border-left: 1px solid silver;
display: flex;
flex-direction: column;
flex-wrap: wrap;
margin: 1rem 0;
max-height: 33rem;
padding: 0;
}
.w98smenu li {
border-right: 1px solid silver;
cursor: pointer;
display: block;
list-style: none;
margin: 0;
padding: 0.15rem 0.5rem;
width: 15rem;
}
.w98smenu li:last-child {
border-bottom: 1px solid silver;
}