##// END OF EJS Templates
ux: fix: last navigation menu's submenu was going off page to right
dan -
r301:7dab65bc default
parent child Browse files
Show More
@@ -1,623 +1,628 b''
1 1 // navigation.less
2 2 // For use in RhodeCode applications;
3 3 // see style guide documentation for guidelines.
4 4
5 5 // HEADER NAVIGATION
6 6
7 7 .horizontal-list {
8 8 float: right;
9 9 display: block;
10 10 margin: 0;
11 11 padding: 0;
12 12 -webkit-padding-start: 0;
13 13 text-align: left;
14 14 font-size: @navigation-fontsize;
15 15 color: @grey6;
16 16 z-index:10;
17 17
18 18 li {
19 19 line-height: 1em;
20 20 list-style-type: none;
21 21
22 22 a {
23 23 padding: 0 .5em;
24 24
25 25 &.menu_link_notifications {
26 26 .pill(7px,@rcblue);
27 27 display: inline;
28 28 margin: 0 7px 0 .7em;
29 29 font-size: @basefontsize;
30 30 color: white;
31
31
32 32 &.empty {
33 33 background-color: @grey4;
34 34 }
35 35
36 36 &:hover {
37 37 background-color: @rcdarkblue;
38 38 }
39 39 }
40 40 }
41 41 .pill_container {
42 42 margin: 1.25em 0px 0px 0px;
43 43 float: right;
44 44 }
45 45
46 46 &#quick_login_li {
47 47 &:hover {
48 48 color: @grey5;
49 49 }
50 50
51 51 a.menu_link_notifications {
52 52 color: white;
53 53 }
54 54
55 55 .user {
56 56 padding-bottom: 10px;
57 57 }
58 58
59 59 &.open {
60 60 .user {
61 61 border-bottom: 5px solid @rcblue;
62 62 }
63 63 }
64 64 }
65 65
66 66 &:before { content: none; }
67 67
68 68 &:last-child {
69 69 .menulabel {
70 70 padding-right: 0;
71 71 border-right: none;
72 72
73 73 .show_more {
74 74 padding-right: 0;
75 75 }
76 76 }
77 77
78 78 &> a {
79 79 border-bottom: none;
80 80 }
81 81 }
82 82
83 83 &.active {
84 84 border-bottom: 5px solid @rcblue;
85 85 }
86 86
87 87 &.open {
88 88
89 89 a {
90 90 color: white;
91 91 }
92 92 }
93 93
94 94 &:focus {
95 95 outline: none;
96 96 }
97
97
98 98 ul li {
99 99 display: block;
100 100
101 101 &:last-child> a {
102 102 border-bottom: none;
103 103 }
104 104
105 105 ul li:last-child a {
106 106 /* we don't expect more then 3 levels of submenu and the third
107 107 level can have different html structure */
108 108 border-bottom: none;
109 109 }
110 110 }
111 111 }
112 112
113 113 > li {
114 114 float: left;
115 115 display: block;
116 116 padding: 0;
117 117
118 118 > a,
119 119 &.has_select2 a {
120 120 display: block;
121 121 padding: 10px 0 2px;
122 122
123 123 .show_more {
124 124 margin-top: -4px;
125 125 padding-right: .5em;
126 126 }
127 127 }
128 128
129 129 .menulabel {
130 130 padding: 0 .5em;
131 131 line-height: 1em;
132 132 // for this specifically we do not use a variable
133 133 border-right: 1px solid @grey4;
134 134 }
135 135
136 136 .pr_notifications {
137 137 padding-left: .5em;
138 138 }
139 139
140 140 .pr_notifications + .menulabel {
141 141 display:inline;
142 142 padding-left: 0;
143 143 }
144 144
145 145 &:hover,
146 146 &.open,
147 147 &.active {
148 a {
148 a {
149 149 color: @grey1;
150 150 }
151 151 }
152 152 }
153 153
154 154 pre {
155 155 margin: 0;
156 156 padding: 0;
157 157 }
158 158
159 159 .select2-container,
160 160 .menulink.childs {
161 161 position: relative;
162 162 }
163 163
164 164 #quick_login {
165 165
166 166 li a {
167 167 padding: .5em 0;
168 168 border-bottom: none;
169 169 color: @grey2;
170 170
171 171 &:hover { color: @grey1; }
172 172 }
173 173
174 174 .show_more {
175 175 padding-left: .5em;
176 176 }
177 177 }
178 178
179 179 #quick_login_link {
180 180 display: inline-block;
181 181
182 182 .gravatar {
183 183 border: 1px solid @grey2;
184 184 }
185 185
186 186 .gravatar-login {
187 187 height: 20px;
188 188 width: 20px;
189 189 margin: -8px 0;
190 190 padding: 0;
191 191 }
192 192
193 193 &:hover .user {
194 194 color: @grey6;
195 195 }
196 196 }
197 197 }
198 198 .header .horizontal-list {
199 199
200 200 li {
201 201
202 202 &#quick_login_li {
203 203 padding-left: .5em;
204 204
205 205 &:hover #quick_login_link {
206 206 color: inherit;
207 207 }
208 208 }
209 209
210 210 &:before { content: none; }
211 211 }
212 212
213 213 > li {
214 214
215 215 a {
216 216 padding: 18px 0 12px 0;
217 217 color: @nav-grey;
218 218
219 219 &.menu_link_notifications {
220 220 padding: 1px 8px;
221 221 }
222 222 }
223 223
224 224 &:hover,
225 225 &.open,
226 226 &.active {
227 227 .pill_container a {
228 228 // don't select text for the pill container, it has it' own
229 229 // hover behaviour
230 230 color: @nav-grey;
231 231 }
232 232 }
233 233
234 234 &:hover,
235 235 &.open,
236 236 &.active {
237 237 a {
238 238 color: @grey6;
239 239 }
240 240 }
241 241
242 242 .select2-dropdown-open a {
243 243 color: @grey6;
244 244 }
245 245
246 246 .repo-switcher {
247 247 padding-left: 0;
248 248
249 249 .menulabel {
250 250 padding-left: 0;
251 251 }
252 252 }
253 253 }
254 254
255 255 li ul li {
256 256 background-color:@grey2;
257 257
258 258 a {
259 259 padding: .5em 0;
260 260 border-bottom: @border-thickness solid @border-default-color;
261 261 color: @grey6;
262 262 }
263 263
264 264 &:last-child a, &.last a{
265 265 border-bottom: none;
266 266 }
267 267
268 268 &:hover {
269 269 background-color: @grey3;
270 270 }
271 271 }
272 272
273 273 .submenu {
274 274 margin-top: 5px;
275 275 }
276 276 }
277 277
278 278 // SUBMENUS
279 279 .navigation .submenu {
280 280 display: none;
281 281 }
282 282
283 283 .navigation li.open {
284 284
285 285 .submenu,
286 286 .repo_switcher {
287 287 display: block;
288 288 }
289 289 }
290 290
291 .navigation li:last-child .submenu {
292 right: -20px;
293 left: auto;
294 }
295
291 296 .submenu {
292 297 position: absolute;
293 298 top: 100%;
294 299 left: 0;
295 300 min-width: 150px;
296 301 margin: 6px 0 0;
297 302 padding: 0;
298 303 text-align: left;
299 304 font-family: @text-light;
300 305 border-radius: @border-radius;
301 306 z-index: 20;
302 307
303 308 li {
304 309 display: block;
305 310 margin: 0;
306 311 padding: 0 .5em;
307 312 line-height: 1em;
308 313 color: @grey3;
309 314 background-color: @grey6;
310 315
311 316 &:before { content: none; }
312 317
313 318 a {
314 319 display: block;
315 320 width: 100%;
316 321 padding: .5em 0;
317 322 border-right: none;
318 323 border-bottom: @border-thickness solid white;
319 324 color: @grey3;
320 325 }
321 326
322 327 ul {
323 328 display: none;
324 329 position: absolute;
325 330 top: 0;
326 331 right: 100%;
327 332 padding: 0;
328 333 z-index: 30;
329 334 }
330 335 &:hover {
331 336 background-color: @grey5;
332 337 -webkit-transition: background .3s;
333 338 -moz-transition: background .3s;
334 339 -o-transition: background .3s;
335 340 transition: background .3s;
336
341
337 342 ul {
338 343 display: block;
339 344 }
340 345 }
341 346 }
342 347 }
343 348
344 349
345 350
346 351
347 352 // repo dropdown
348 353 .quick_repo_menu {
349 354 width: 15px;
350 355 text-align: center;
351 356 position: relative;
352 357 cursor: pointer;
353 358
354 359 div {
355 360 overflow: visible !important;
356 361 }
357 362
358 363 &.sorting {
359 364 cursor: auto;
360 365 }
361 366
362 367 &:hover {
363 368 .menu_items_container {
364 369 position: absolute;
365 370 display: block;
366 371 }
367 372 .menu_items {
368 373 display: block;
369 374 }
370 375 }
371 376
372 377 i {
373 378 margin: 0;
374 379 color: @grey4;
375 380 }
376 381
377 382 .menu_items_container {
378 383 position: absolute;
379 384 top: 0;
380 385 left: 100%;
381 386 margin: 0;
382 387 padding: 0;
383 388 list-style: none;
384 389 background-color: @grey6;
385 390 z-index: 999;
386 391 text-align: left;
387 392
388 393 a {
389 394 color: @grey2;
390 395 }
391 396
392 397 ul.menu_items {
393 398 margin: 0;
394 399 padding: 0;
395 400 }
396 401
397 402 li {
398 403 margin: 0;
399 404 padding: 0;
400 405 line-height: 1em;
401 406 list-style-type: none;
402 407
403 408 &:before { content: none; }
404 409
405 410 a {
406 411 display: block;
407 412 height: 16px;
408 413 padding: 8px; //must add up to td height (28px)
409 414
410 415 &:hover {
411 416 background-color: @grey5;
412 417 -webkit-transition: background .3s;
413 418 -moz-transition: background .3s;
414 419 -o-transition: background .3s;
415 420 transition: background .3s;
416 421 }
417 422 }
418 423 }
419 424 }
420 425 }
421 426
422 427 // Header Repository Switcher
423 428 // Select2 Dropdown
424 429 #select2-drop.select2-drop.repo-switcher-dropdown {
425 430 width: auto !important;
426 431 margin-top: 5px;
427 432 padding: 1em 0;
428 433 text-align: left;
429 434 .border-radius-bottom(@border-radius);
430 435 border-color: transparent;
431 436 color: @grey6;
432 437 background-color: @grey2;
433 438
434 439 input {
435 440 min-width: 90%;
436 441 }
437 442
438 443 ul.select2-result-sub {
439 444
440 445 li {
441 446 line-height: 1em;
442 447
443 448 &:hover,
444 449 &.select2-highlighted {
445 450 background-color: @grey3;
446 451 }
447 452 }
448 453
449 454 &:before { content: none; }
450 455 }
451 456
452 457 ul.select2-results {
453 458 min-width: 200px;
454 459 margin: 0;
455 460 padding: 0;
456 461 list-style-type: none;
457 462 overflow-x: visible;
458 463 overflow-y: scroll;
459 464
460 465 li {
461 466 padding: 0 8px;
462 467 line-height: 1em;
463 468 color: @grey6;
464 469
465 470 &:before { content: none; }
466 471
467 472 &>.select2-result-label {
468 473 padding: 8px 0;
469 474 border-bottom: @border-thickness solid @grey3;
470 475 white-space: nowrap;
471 476 color: @grey5;
472 477 cursor: pointer;
473 478 }
474 479
475 480 &.select2-result-with-children {
476 481 margin: 0;
477 482 padding: 0;
478 483 }
479 484
480 485 &.select2-result-unselectable > .select2-result-label {
481 486 margin: 0 8px;
482 487 }
483
488
484 489 }
485 490 }
486 491
487 492 ul.select2-result-sub {
488 493 margin: 0;
489 494 padding: 0;
490 495
491 496 li {
492 497 display: block;
493 498 margin: 0;
494 499 border-right: none;
495 500 line-height: 1em;
496 501 font-family: @text-light;
497 502 color: @grey2;
498 503
499 504 &:before { content: none; }
500 505
501 506 &:hover {
502 507 background-color: @grey3;
503 508 }
504 509 }
505 510 }
506 511 }
507 512
508 513
509 514 #context-bar {
510 515 display: block;
511 516 margin: 0 auto;
512 517 padding: 0 @header-padding;
513 518 background-color: @grey6;
514 519 border-bottom: @border-thickness solid @grey5;
515 520
516 521 .clear {
517 522 clear: both;
518 523 }
519 524 }
520 525
521 526 ul#context-pages {
522 527 li {
523 528 line-height: 1em;
524 529
525 530 &:before { content: none; }
526 531
527 532 a {
528 533 color: @grey3;
529 534 }
530 535
531 536 &.active {
532 537 // special case, non-variable color
533 538 border-bottom: 4px solid @nav-grey;
534 539
535 540 a {
536 541 color: @grey1;
537 542 }
538 543 }
539 544 }
540 545 }
541 546
542 547 // PAGINATION
543 548
544 549 .pagination {
545 550 border: @border-thickness solid @rcblue;
546 551 color: @rcblue;
547 552
548 553 .current {
549 554 color: @grey4;
550 555 }
551 556 }
552 557
553 558 .dataTables_paginate, .pagination-wh {
554 559 text-align: left;
555 560 display: inline-block;
556 561 border-left: 1px solid @rcblue;
557 562 float: none;
558 563 overflow: hidden;
559 564
560 565 .paginate_button, .pager_curpage,
561 566 .pager_link, .pg-previous, .pg-next, .pager_dotdot {
562 567 display: inline-block;
563 568 padding: @menupadding/4 @menupadding;
564 569 border: 1px solid @rcblue;
565 570 border-left: 0;
566 571 color: @rcblue;
567 572 cursor: pointer;
568 573 float: left;
569 574 }
570 575
571 576 .pager_curpage, .pager_dotdot,
572 577 .paginate_button.current, .paginate_button.disabled,
573 578 .disabled {
574 579 color: @grey3;
575 580 cursor: default;
576 581 }
577 582 }
578 583
579 584 // SIDEBAR
580 585
581 586 .sidebar {
582 587 .block-left;
583 588 clear: left;
584 589 max-width: @sidebar-width;
585 590 margin-right: @sidebarpadding;
586 591 padding-right: @sidebarpadding;
587 592 font-family: @text-regular;
588 593 color: @grey1;
589 594
590 595 &#graph_nodes {
591 596 clear:both;
592 597 width: auto;
593 598 margin-left: -100px;
594 599 padding: 0;
595 600 border: none;
596 601 }
597
602
598 603 .nav-pills {
599 604 margin: 0;
600 605 }
601 606
602 607 .nav {
603 608 list-style: none;
604 609 padding: 0;
605 610
606 611 li {
607 612 padding-bottom: @menupadding;
608 613 line-height: 1em;
609 614 color: @grey4;
610 615
611 616 &.active a {
612 617 color: @grey2;
613 618 }
614 619
615 620 a {
616 621 color: @grey4;
617 622 }
618 623
619 624 &:before { content: none; }
620 625 }
621 626
622 627 }
623 628 }
General Comments 0
You need to be logged in to leave comments. Login now