Blame view

app/bower_components/bootstrap/less/panels.less 6.13 KB
f986e111b   TRUONG   add libs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
  //
  // Panels
  // --------------------------------------------------
  
  
  // Base class
  .panel {
    margin-bottom: @line-height-computed;
    background-color: @panel-bg;
    border: 1px solid transparent;
    border-radius: @panel-border-radius;
    .box-shadow(0 1px 1px rgba(0,0,0,.05));
  }
  
  // Panel contents
  .panel-body {
87c93a029   Dang YoungWorld   add modal
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
    padding: @panel-body-padding;
    &:extend(.clearfix all);
  }
  
  // Optional heading
  .panel-heading {
    padding: @panel-heading-padding;
    border-bottom: 1px solid transparent;
    .border-top-radius((@panel-border-radius - 1));
  
    > .dropdown .dropdown-toggle {
      color: inherit;
    }
  }
  
  // Within heading, strip any `h*` tag of its default margins for spacing.
  .panel-title {
    margin-top: 0;
    margin-bottom: 0;
    font-size: ceil((@font-size-base * 1.125));
    color: inherit;
  
    > a,
    > small,
    > .small,
    > small > a,
    > .small > a {
      color: inherit;
    }
  }
  
  // Optional footer (stays gray in every modifier class)
  .panel-footer {
    padding: @panel-footer-padding;
    background-color: @panel-footer-bg;
    border-top: 1px solid @panel-inner-border;
    .border-bottom-radius((@panel-border-radius - 1));
f986e111b   TRUONG   add libs
54
55
56
57
58
59
60
61
62
  }
  
  
  // List groups in panels
  //
  // By default, space out list group content from panel headings to account for
  // any kind of custom content between the two.
  
  .panel {
87c93a029   Dang YoungWorld   add modal
63
64
    > .list-group,
    > .panel-collapse > .list-group {
f986e111b   TRUONG   add libs
65
66
67
68
      margin-bottom: 0;
  
      .list-group-item {
        border-width: 1px 0;
87c93a029   Dang YoungWorld   add modal
69
70
        border-radius: 0;
      }
f986e111b   TRUONG   add libs
71

87c93a029   Dang YoungWorld   add modal
72
73
74
75
76
      // Add border top radius for first one
      &:first-child {
        .list-group-item:first-child {
          border-top: 0;
          .border-top-radius((@panel-border-radius - 1));
f986e111b   TRUONG   add libs
77
        }
87c93a029   Dang YoungWorld   add modal
78
79
80
81
82
      }
  
      // Add border bottom radius for last one
      &:last-child {
        .list-group-item:last-child {
f986e111b   TRUONG   add libs
83
          border-bottom: 0;
87c93a029   Dang YoungWorld   add modal
84
          .border-bottom-radius((@panel-border-radius - 1));
f986e111b   TRUONG   add libs
85
86
87
        }
      }
    }
87c93a029   Dang YoungWorld   add modal
88
89
90
91
92
    > .panel-heading + .panel-collapse > .list-group {
      .list-group-item:first-child {
        .border-top-radius(0);
      }
    }
f986e111b   TRUONG   add libs
93
94
95
96
97
98
99
  }
  // Collapse space between when there's no additional content.
  .panel-heading + .list-group {
    .list-group-item:first-child {
      border-top-width: 0;
    }
  }
87c93a029   Dang YoungWorld   add modal
100
101
102
  .list-group + .panel-footer {
    border-top-width: 0;
  }
f986e111b   TRUONG   add libs
103
104
105
106
107
108
109
110
  
  // Tables in panels
  //
  // Place a non-bordered `.table` within a panel (not within a `.panel-body`) and
  // watch it go full width.
  
  .panel {
    > .table,
87c93a029   Dang YoungWorld   add modal
111
112
    > .table-responsive > .table,
    > .panel-collapse > .table {
f986e111b   TRUONG   add libs
113
      margin-bottom: 0;
87c93a029   Dang YoungWorld   add modal
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
  
      caption {
        padding-left: @panel-body-padding;
        padding-right: @panel-body-padding;
      }
    }
    // Add border top radius for first one
    > .table:first-child,
    > .table-responsive:first-child > .table:first-child {
      .border-top-radius((@panel-border-radius - 1));
  
      > thead:first-child,
      > tbody:first-child {
        > tr:first-child {
          border-top-left-radius: (@panel-border-radius - 1);
          border-top-right-radius: (@panel-border-radius - 1);
  
          td:first-child,
          th:first-child {
            border-top-left-radius: (@panel-border-radius - 1);
          }
          td:last-child,
          th:last-child {
            border-top-right-radius: (@panel-border-radius - 1);
          }
        }
      }
    }
    // Add border bottom radius for last one
    > .table:last-child,
    > .table-responsive:last-child > .table:last-child {
      .border-bottom-radius((@panel-border-radius - 1));
  
      > tbody:last-child,
      > tfoot:last-child {
        > tr:last-child {
          border-bottom-left-radius: (@panel-border-radius - 1);
          border-bottom-right-radius: (@panel-border-radius - 1);
  
          td:first-child,
          th:first-child {
            border-bottom-left-radius: (@panel-border-radius - 1);
          }
          td:last-child,
          th:last-child {
            border-bottom-right-radius: (@panel-border-radius - 1);
          }
        }
      }
f986e111b   TRUONG   add libs
163
164
    }
    > .panel-body + .table,
87c93a029   Dang YoungWorld   add modal
165
166
167
    > .panel-body + .table-responsive,
    > .table + .panel-body,
    > .table-responsive + .panel-body {
f986e111b   TRUONG   add libs
168
169
      border-top: 1px solid @table-border-color;
    }
87c93a029   Dang YoungWorld   add modal
170
171
    > .table > tbody:first-child > tr:first-child th,
    > .table > tbody:first-child > tr:first-child td {
f986e111b   TRUONG   add libs
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
      border-top: 0;
    }
    > .table-bordered,
    > .table-responsive > .table-bordered {
      border: 0;
      > thead,
      > tbody,
      > tfoot {
        > tr {
          > th:first-child,
          > td:first-child {
            border-left: 0;
          }
          > th:last-child,
          > td:last-child {
            border-right: 0;
          }
87c93a029   Dang YoungWorld   add modal
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
        }
      }
      > thead,
      > tbody {
        > tr:first-child {
          > td,
          > th {
            border-bottom: 0;
          }
        }
      }
      > tbody,
      > tfoot {
        > tr:last-child {
          > td,
          > th {
f986e111b   TRUONG   add libs
205
206
207
208
209
210
211
212
213
214
            border-bottom: 0;
          }
        }
      }
    }
    > .table-responsive {
      border: 0;
      margin-bottom: 0;
    }
  }
87c93a029   Dang YoungWorld   add modal
215
  // Collapsible panels (aka, accordion)
f986e111b   TRUONG   add libs
216
217
218
219
220
  //
  // Wrap a series of panels in `.panel-group` to turn them into an accordion with
  // the help of our collapse JavaScript plugin.
  
  .panel-group {
87c93a029   Dang YoungWorld   add modal
221
    margin-bottom: @line-height-computed;
f986e111b   TRUONG   add libs
222
223
224
225
    // Tighten up margin so it's only between panels
    .panel {
      margin-bottom: 0;
      border-radius: @panel-border-radius;
87c93a029   Dang YoungWorld   add modal
226

f986e111b   TRUONG   add libs
227
228
229
230
231
232
233
      + .panel {
        margin-top: 5px;
      }
    }
  
    .panel-heading {
      border-bottom: 0;
87c93a029   Dang YoungWorld   add modal
234
235
236
  
      + .panel-collapse > .panel-body,
      + .panel-collapse > .list-group {
f986e111b   TRUONG   add libs
237
238
239
        border-top: 1px solid @panel-inner-border;
      }
    }
87c93a029   Dang YoungWorld   add modal
240

f986e111b   TRUONG   add libs
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
    .panel-footer {
      border-top: 0;
      + .panel-collapse .panel-body {
        border-bottom: 1px solid @panel-inner-border;
      }
    }
  }
  
  
  // Contextual variations
  .panel-default {
    .panel-variant(@panel-default-border; @panel-default-text; @panel-default-heading-bg; @panel-default-border);
  }
  .panel-primary {
    .panel-variant(@panel-primary-border; @panel-primary-text; @panel-primary-heading-bg; @panel-primary-border);
  }
  .panel-success {
    .panel-variant(@panel-success-border; @panel-success-text; @panel-success-heading-bg; @panel-success-border);
  }
87c93a029   Dang YoungWorld   add modal
260
261
262
  .panel-info {
    .panel-variant(@panel-info-border; @panel-info-text; @panel-info-heading-bg; @panel-info-border);
  }
f986e111b   TRUONG   add libs
263
264
265
266
267
268
  .panel-warning {
    .panel-variant(@panel-warning-border; @panel-warning-text; @panel-warning-heading-bg; @panel-warning-border);
  }
  .panel-danger {
    .panel-variant(@panel-danger-border; @panel-danger-text; @panel-danger-heading-bg; @panel-danger-border);
  }