summaryrefslogtreecommitdiffstats
path: root/assets/sass/@primer/css/navigation/underline-nav.scss
blob: 7b9309d1b9499e1a75cd8ada7a56c3cf1a56b023 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
.UnderlineNav {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  border-bottom: $border;
  justify-content: space-between;
}

.UnderlineNav-body {
  display: flex;
}

.UnderlineNav-item {
  padding: $spacer-3 $spacer-2;
  margin-right: $spacer-3;
  font-size: $body-font-size;
  line-height: $lh-default;
  color: $text-gray;
  text-align: center;
  white-space: nowrap;
  background-color: transparent;
  border: 0;
  // stylelint-disable-next-line primer/borders
  border-bottom: 2px $border-style transparent;

  &:hover,
  &:focus {
    color: $text-gray-dark;
    text-decoration: none;
    border-bottom-color: $border-gray-dark;
    transition: 0.2s ease;

    .UnderlineNav-octicon {
      color: $text-gray-light;
    }
  }

  &.selected,
  &[role=tab][aria-selected=true],
  &[aria-current] {
    font-weight: $font-weight-bold;
    color: $text-gray-dark;
    // stylelint-disable-next-line primer/borders
    border-bottom-color: $orange-600;

    .UnderlineNav-octicon {
      color: $text-gray-light;
    }
  }
}

.UnderlineNav--right {
  justify-content: flex-end;

  .UnderlineNav-item {
    margin-right: 0;
    margin-left: $spacer-3;
  }

  .UnderlineNav-actions {
    flex: 1 1 auto;
  }
}

.UnderlineNav-actions {
  align-self: center;
}

.UnderlineNav--full {
  display: block;
}

.UnderlineNav-octicon {
  // stylelint-disable-next-line primer/colors
  color: $gray-400;
}

.UnderlineNav-container {
  display: flex;
  justify-content: space-between;
}