Use prettier for SCSS (#3895)
[GitHub/WoltLab/WCF.git] / wcfsetup / install / files / style / ui / tabMenu.scss
CommitLineData
f2b50825 1/* main tabs */
552853f5
AE
2.tabMenu,
3.menu {
4 > ul {
5 @include inlineList;
8a52619a 6
552853f5
AE
7 > li {
8 position: relative;
8a52619a 9
552853f5
AE
10 &:not(:last-child) {
11 margin-right: 20px;
12 }
8a52619a 13
552853f5
AE
14 &::before {
15 border-top: 1px solid $wcfContentLink;
16 bottom: 0;
17 content: "";
18 left: 50%;
19 position: absolute;
20 width: 0;
21 }
8a52619a
TD
22
23 &.active {
e94ff25c
AE
24 // this causes the item to stand above the fade-effect caused
25 // by the overflow overlays
a2f67626 26 z-index: 60;
8a52619a 27
e94ff25c
AE
28 &::before {
29 left: 0;
8a52619a 30 transition: left 0.12s linear, width 0.12s linear;
e94ff25c
AE
31 width: 100%;
32 }
8a52619a 33
e94ff25c
AE
34 > a {
35 cursor: default;
36 }
552853f5 37 }
8a52619a 38
552853f5
AE
39 > a {
40 display: block;
41 padding: 5px 0;
f2b50825
AE
42 }
43 }
44 }
8a52619a 45
f216765b 46 @include screen-sm-down {
552853f5
AE
47 padding-left: 15px;
48 padding-right: 15px;
49 position: relative;
8a52619a 50
552853f5
AE
51 &::before {
52 display: none;
53 }
8a52619a 54
a9815b6d 55 > ul {
552853f5
AE
56 flex-wrap: nowrap;
57 overflow: auto;
58 -webkit-overflow-scrolling: touch;
8a52619a 59
552853f5
AE
60 > li {
61 flex-shrink: 0;
62 white-space: nowrap;
a9815b6d 63 }
8a52619a 64
552853f5 65 &.enableAnimation {
8a52619a
TD
66 transition: padding-left 0.24s linear;
67
552853f5 68 > li:first-child {
8a52619a 69 transition: margin-left 0.24s linear;
a9815b6d
AE
70 }
71 }
72 }
552853f5 73 }
8a52619a 74
552853f5
AE
75 @include screen-md-up {
76 > ul {
77 border-bottom: 1px solid $wcfContentBorderInner;
8a52619a 78
552853f5
AE
79 > li::before {
80 bottom: -1px;
81 }
a9815b6d 82 }
f2b50825
AE
83 }
84}
85
552853f5
AE
86.tabMenu {
87 > ul > li > a {
88 @include wcfFontSection;
929f7e47 89 }
929f7e47
MW
90}
91
f2b50825
AE
92/* sub tabs */
93.menu {
95961bdf 94 margin-top: 10px;
8a52619a 95
bea00af0 96 @include screen-md-up {
552853f5
AE
97 > ul > li > a {
98 @include wcfFontHeadline;
bea00af0 99 }
f2b50825 100 }
8a52619a 101
f8d43a84
AE
102 & + .tabMenuContent {
103 margin-top: 20px;
104 }
f2b50825 105}
552853f5
AE
106
107.tabMenuOverlayLeft,
108.tabMenuOverlayRight {
109 align-items: center;
110 bottom: 0;
111 display: flex;
112 height: 100%;
113 opacity: 0;
114 position: absolute;
115 top: 0;
8a52619a 116 transition: opacity 0.24s linear, visibility 0s linear 0.24s;
552853f5 117 visibility: hidden;
e94ff25c 118 width: 30px;
552853f5 119 z-index: 50;
8a52619a 120
552853f5
AE
121 &.active {
122 opacity: 1;
123 transition-delay: 0s;
124 visibility: visible;
125 }
8a52619a 126
552853f5
AE
127 &::before {
128 color: $wcfContentDimmedText;
129 }
130}
131
132.tabMenuOverlayLeft {
e94ff25c 133 background: linear-gradient(to left, transparentize($wcfContentBackground, 100%) 0%, $wcfContentBackground 50%);
552853f5
AE
134 left: 0;
135}
136
137.tabMenuOverlayRight {
8a52619a
TD
138 background: linear-gradient(
139 to right,
140 transparentize($wcfContentBackground, 100%) 0%,
141 $wcfContentBackground 50%
142 );
552853f5
AE
143 justify-content: flex-end;
144 right: 0;
145}
146
147.tabMenuContent.hidden {
148 display: none;
149}
150
151.tabMenuContent {
152 // remove upper border if containerList is the first child
153 > .containerList:first-child > li:first-child {
154 border-top-width: 0;
155 }
156}