Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 1 | @charset "utf-8"; |
| 2 | @import "choose"; |
| 3 | @import "lengths"; |
| 4 | @import "icons"; |
| 5 | |
| 6 | /** |
| 7 | * Definitions for menu design. |
| 8 | */ |
| 9 | |
| 10 | ul.menu { |
| 11 | position: absolute; |
| 12 | padding: 0; |
| 13 | margin: 0; |
| 14 | text-indent: 0; |
| 15 | |
| 16 | opacity: 0; |
| 17 | &.visible { |
| 18 | opacity: 1; |
| 19 | } |
| 20 | |
| 21 | list-style: { |
| 22 | type: none; |
| 23 | position: outside; |
| 24 | } |
| 25 | |
| 26 | &, |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 27 | > span.non-item:not(:empty) { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 28 | box-sizing: border-box; |
| 29 | text-shadow: none; |
| 30 | font-weight: normal; |
| 31 | z-index: 120; |
| 32 | } |
| 33 | |
| 34 | > li, |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 35 | > span.non-item:not(.active) { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 36 | @include choose-item; |
| 37 | } |
| 38 | |
| 39 | > li, |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 40 | > span.non-item:not(:empty) { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 41 | @include choose-item; |
| 42 | box-shadow: $choose-box-shadow; |
| 43 | cursor: pointer; |
| 44 | padding: $item-padding; |
| 45 | white-space: normal; |
| 46 | border: { |
| 47 | width: $border-size; |
| 48 | bottom-width: 0px; |
| 49 | top-width: 0px; |
| 50 | style: solid; |
| 51 | } |
| 52 | } |
| 53 | span.desc { |
| 54 | display: block; |
| 55 | font-size: 75%; |
| 56 | } |
| 57 | |
| 58 | div.lengthField { |
| 59 | border: { |
| 60 | color: transparent; |
| 61 | width: $border-size; |
| 62 | } |
Akron | dadd1d1 | 2021-11-12 16:20:28 +0100 | [diff] [blame^] | 63 | overflow: hidden; |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 64 | padding: $item-padding; |
| 65 | padding-top: 0; |
| 66 | padding-bottom: 0; |
| 67 | span { |
| 68 | display: block !important; |
| 69 | line-height: 0; |
| 70 | color: transparent; |
| 71 | } |
| 72 | } |
| 73 | |
| 74 | /** |
| 75 | * Ruler |
| 76 | */ |
| 77 | > div.ruler { |
| 78 | position: absolute; |
| 79 | right: 0px; |
| 80 | margin-right: -14px; |
| 81 | background-color: transparent; |
| 82 | width: 14px; |
| 83 | height: 100%; |
| 84 | opacity: 0; |
| 85 | cursor: pointer; |
| 86 | transition: opacity .5s ease 1s; |
| 87 | |
| 88 | > span { |
| 89 | @include choose-active; |
| 90 | position: absolute; |
| 91 | display: block; |
| 92 | right: 0; |
| 93 | width: 10px; |
| 94 | z-index: 115; |
| 95 | border: { |
| 96 | radius: 4px; |
| 97 | width: 2px; |
| 98 | style: solid; |
| 99 | } |
| 100 | } |
| 101 | |
| 102 | &.active > span { |
| 103 | @include choose-hover; |
| 104 | } |
| 105 | |
| 106 | > div { |
| 107 | @include choose-item; |
| 108 | box-shadow: $choose-box-shadow; |
| 109 | position: absolute; |
| 110 | right: 0; |
| 111 | width: 10px; |
| 112 | height: 100%; |
| 113 | border: { |
| 114 | radius: 4px; |
| 115 | width: 2px; |
| 116 | style: solid; |
| 117 | } |
| 118 | } |
| 119 | } |
| 120 | |
| 121 | &:active > div.ruler, |
| 122 | &:hover > div.ruler, |
| 123 | > div.ruler.active { |
| 124 | transition: opacity .1s ease; |
| 125 | opacity: 1; |
| 126 | } |
| 127 | |
| 128 | |
| 129 | /** |
| 130 | * List items |
| 131 | */ |
| 132 | > li, |
| 133 | div.lengthField { |
| 134 | padding-right: 1.6em; |
| 135 | } |
| 136 | |
| 137 | > li { |
| 138 | &:first-of-type { |
| 139 | border-top: { |
| 140 | width: $border-size; |
| 141 | left-radius: $standard-border-radius; |
| 142 | right-radius: $standard-border-radius; |
| 143 | } |
| 144 | } |
| 145 | |
| 146 | &:last-of-type { |
| 147 | border-bottom: { |
| 148 | width: $border-size; |
| 149 | left-radius: $standard-border-radius; |
| 150 | right-radius: $standard-border-radius; |
| 151 | } |
| 152 | } |
| 153 | mark { |
| 154 | text-decoration: underline; |
| 155 | background-color: transparent; |
| 156 | color: inherit; |
| 157 | font-weight: bold; |
| 158 | } |
| 159 | } |
| 160 | |
| 161 | > li.active, |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 162 | span.non-item.active { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 163 | @include choose-active; |
| 164 | } |
| 165 | |
| 166 | > li:hover, |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 167 | span.non-item:hover { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 168 | @include choose-hover; |
| 169 | } |
| 170 | |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 171 | span.non-item { |
| 172 | border: { |
| 173 | radius: $standard-border-radius; |
| 174 | width: $border-size !important; |
| 175 | } |
| 176 | } |
| 177 | |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 178 | /** |
| 179 | * Default prefix view |
| 180 | */ |
Akron | f21bf74 | 2021-05-19 13:30:38 +0200 | [diff] [blame] | 181 | span.pref:not(:empty) { |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 182 | position: absolute; |
| 183 | min-width: 5px; |
| 184 | font-size: 80%; |
| 185 | left: 0; |
| 186 | bottom: 0; |
| 187 | display: block; |
| 188 | margin-bottom: -2.1em; |
| 189 | padding: 2px 6px; |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 190 | } |
marcrusian | 235a23a | 2021-05-26 14:28:11 +0200 | [diff] [blame] | 191 | /** |
| 192 | * Default entry view |
| 193 | */ |
| 194 | span.entry:not(:empty) { |
| 195 | position: absolute; |
| 196 | min-width: 5px; |
| 197 | font-size: 80%; |
| 198 | left: 0; |
| 199 | bottom: 0; |
| 200 | display: block; |
| 201 | margin-bottom: -2.1em; |
| 202 | padding: 2px 6px; |
| 203 | } |
| 204 | span.pref:not(:empty) ~ span.entry:not(:empty){ |
| 205 | bottom: -27px; |
| 206 | } |
Akron | 7e5afce | 2020-08-25 15:50:19 +0200 | [diff] [blame] | 207 | } |
| 208 | |
| 209 | |
| 210 | /** |
| 211 | * Rolling menu |
| 212 | */ |
| 213 | ul.menu.roll { |
| 214 | > li:first-of-type { |
| 215 | &:not(.no-more):before { |
| 216 | position: absolute; |
| 217 | font-family: "FontAwesome"; |
| 218 | content: $fa-up; |
| 219 | right: .5em; |
| 220 | top: .4em; |
| 221 | } |
| 222 | } |
| 223 | > li:last-of-type { |
| 224 | &:not(.no-more):before { |
| 225 | position: absolute; |
| 226 | font-family: "FontAwesome"; |
| 227 | content: $fa-down; |
| 228 | right: .5em; |
| 229 | bottom: .4em; |
| 230 | } |
| 231 | } |
| 232 | &:not(.visible) { |
| 233 | height: 0; |
| 234 | } |
| 235 | } |
| 236 | |
| 237 | |
| 238 | /** |
| 239 | * Sorting menu |
| 240 | */ |
| 241 | ul.menu.sort { |
| 242 | position: relative; |
| 243 | display: inline-block; |
| 244 | > li::before { |
| 245 | content: ''; |
| 246 | } |
| 247 | > li.active:hover { |
| 248 | @include choose-remove; |
| 249 | } |
| 250 | } |
| 251 | |
| 252 | |
| 253 | /** |
| 254 | * select menu |
| 255 | */ |
| 256 | span.menu.select { |
| 257 | > span { |
| 258 | z-index: 105; |
| 259 | } |
| 260 | > ul.menu.roll { |
| 261 | display: none; |
| 262 | z-index: -100; |
| 263 | &.visible { |
| 264 | display: block; |
| 265 | z-index: 110; |
| 266 | } |
| 267 | } |
| 268 | } |
Akron | 766f152 | 2021-07-21 10:55:55 +0200 | [diff] [blame] | 269 | |
| 270 | /** |
| 271 | * container menu |
| 272 | */ |
| 273 | ul.containermenu > ul.menu.container { |
| 274 | bottom: 0; |
| 275 | transform: translateY(100%); |
| 276 | margin-bottom: -.3em; |
| 277 | } |