Skip to content
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

feat(menu): add tab overflow scrolling and shadows #2776

Draft
wants to merge 2 commits into
base: develop
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 78 additions & 0 deletions src/definitions/collections/menu.less
Original file line number Diff line number Diff line change
Expand Up @@ -1923,6 +1923,84 @@ Floated Menu / Item
margin-right: 0;
width: 100%;
}

.ui.top.attached.tabular.scroll {
display: flex;
position: relative;
overflow-x: auto;
overflow-y: hidden;
overscroll-behavior: contain;
}

.ui.top.attached.tabular.scroll::-webkit-scrollbar {
display: none;
width: 0;
background: transparent;
}

.ui.top.attached.tabular.menu > .item.active {
border-bottom: 1px solid #fff;
Copy link
Member

@lubber-de lubber-de May 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use a LESS variable instead of hardcoding the value

}

.ui.top.attached.tabular.menu {
overflow: visible;
width: 100%;
min-width: fit-content !important;
Copy link
Member

@lubber-de lubber-de May 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dont use !important, use repeating classnames to increase specificity instead

}

.ui.bottom.attached.tab.segment {
border-top: none !important;
}

.ui.top.attached.tab.segment {
border-bottom: none !important;
}

.ui.bottom.attached.tabular.menu {
overflow: visible;
width: 100% !important;
min-width: fit-content !important;
}

.ui.attached.tabular.shadow-hider {
border: black 1px;
margin-right: 1rem;
position: absolute;
height: 100%;
width: 1em;
background-color: white;
z-index: 2;
}

.ui.attached.tabular.top.shadow-hider-start {
border-bottom: 1px solid #d4d4d5 !important;
}

.ui.attached.tabular.shadow-hider-end {
height: 100%;
position: sticky;
margin-left: -1rem;
flex: 0 0 1rem;
left: calc(100% - 2rem);
}

.ui.attached.tabular.shadow {
position: sticky;
z-index: 1;
flex: 0 0 1rem;
}

.ui.attached.tabular.shadow-start {
left: 0;
background-image: linear-gradient(90deg, #0004, transparent);
}

.ui.attached.tabular.shadow-end {
right: 0;
background-image: linear-gradient(90deg, transparent, #0004);
width: 1rem;
left: calc(100% - 2.1rem);
}
}
}

Expand Down