chrome.scss 2.9 KB
Newer Older
1 2 3 4 5 6
// Copyright 2015 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
B
bryk 已提交
7
//     http://www.apache.org/licenses/LICENSE-2.0
8 9 10 11 12 13 14
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

15
@import '../variables';
16

17 18
.kd-toolbar-logo {
  height: 42px;
B
bryk 已提交
19
  margin-right: 1em;
B
bryk 已提交
20
  width: 42px;
21
}
B
bryk 已提交
22

D
Denis Poisson 已提交
23 24 25 26
.kd-middle-ellipsised-link {
  display: block;
}

B
bryk 已提交
27
.kd-toolbar {
28
  box-shadow: $whiteframe-shadow-1dp;
29 30
}

31 32
body,
.kd-app-content {
33
  background-color: $body;
B
bryk 已提交
34
}
35 36

a {
B
bryk 已提交
37
  color: $primary;
38
  text-decoration: inherit;
B
bryk 已提交
39 40 41 42

  &:visited {
    color: $primary;
  }
43
}
44

45 46 47 48 49 50
.md-toolbar-tools {
  a {
    color: $primary;
  }
}

P
Piotr Bryk 已提交
51 52 53 54 55 56 57 58
.kd-success {
  color: $success-color;
}

.kd-error {
  color: $error-color;
}

M
Marcin Maciaszczyk 已提交
59
.kd-toolbar-tools {
60
  margin: auto;
61 62 63
}

.kd-app-content {
64
  background-color: $body;
65 66
  position: relative;
}
B
bryk 已提交
67

B
bryk 已提交
68
.kd-center-fixed {
B
bryk 已提交
69 70 71 72 73 74 75 76 77 78
  align-items: center;
  bottom: 0;
  display: flex;
  flex-direction: row;
  justify-content: center;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
}
B
bryk 已提交
79 80 81 82 83 84 85

.kd-text-icon {
  font-size: inherit;
  height: inherit;
  vertical-align: middle;
}

86
.kd-comma-separated-item {
87
  &:not(:last-child) {
88
    &::after {
89
      content: ',';
90 91
    }
  }
92 93

  display: inline-block;
94
}
95 96 97 98 99

// Disables animation on md-tab switch. Avoids some flickering and is simpler.
[role='tabpanel'] {
  transition: none;
}
100 101 102 103

// Responsive table style.
@media only screen and (max-width: $layout-breakpoint-xs) {
  .kd-responsive-table {
104
    table-layout: fixed;
105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131
    width: 100%;

    // Switches table to blocks.
    thead,
    tbody,
    tr,
    th {
      display: block;
    }

    // Removes table headers.
    thead {
      tr,
      th {
        display: none;
      }
    }

    // Adds border between records.
    tr {
      &:not(:last-child) {
        border-bottom: $baseline-grid / 2 solid $border;
      }
    }

    // Row data style.
    td {
M
Marcin Maciaszczyk 已提交
132 133
      align-items: center;
      display: flex;
134
      height: auto;
M
Marcin Maciaszczyk 已提交
135
      min-height: $table-cell-height - 2 * $baseline-grid;
136
      padding: $baseline-grid $baseline-grid $baseline-grid 12 * $baseline-grid;
137 138
      position: relative;

M
Marcin Maciaszczyk 已提交
139 140 141 142 143
      // Adds border between rows.
      &:not(:last-child) {
        border-bottom: 1px solid $border;
      }

144 145
      // Row title style.
      &::before {
M
Marcin Maciaszczyk 已提交
146 147
        align-items: center;
        bottom: 0;
148
        content: attr(kd-responsive-header);
M
Marcin Maciaszczyk 已提交
149
        display: flex;
150 151 152 153
        font-weight: $bold-font-weight;
        left: $baseline-grid * 2;
        padding-right: $baseline-grid * 2;
        position: absolute;
M
Marcin Maciaszczyk 已提交
154
        top: 0;
155 156 157 158 159
        word-wrap: break-word;
      }
    }
  }
}