thirdparty-dataTables.less 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287
  1. .enable_plugin_datatables() when(@enable-plugin-datatables = true) {
  2. //dataTables
  3. .dataTables_length {
  4. //margin-left:8px;
  5. select {
  6. width: 70px;
  7. height: 25px;
  8. padding: 2px 3px;
  9. }
  10. label {
  11. font-weight:normal;
  12. }
  13. }
  14. .dataTables_filter {
  15. // margin-right:8px;
  16. text-align:right;
  17. input[type=text], input[type=search] {
  18. width: 125px;
  19. height: 18px;
  20. line-height: 18px;
  21. .box-sizing(content-box);
  22. padding: 4px 6px;
  23. }
  24. label {
  25. font-weight:normal;
  26. }
  27. }
  28. .dataTables_info {
  29. // margin:0 0 0 12px;
  30. font-size: @base-font-size + 1;
  31. }
  32. .dataTables_paginate {
  33. text-align: right;
  34. .pagination {
  35. margin: 0 12px;
  36. }
  37. }
  38. .dataTables_wrapper {
  39. label {
  40. display: inline-block;
  41. font-size: @base-font-size;
  42. }
  43. input[type=text] , input[type=search], select {
  44. margin-bottom: 0 !important;
  45. margin: 0 4px;
  46. }
  47. .row {
  48. margin: 0 !important;//to override .rtl's
  49. &:first-child {
  50. padding-top: 12px;
  51. padding-bottom: 12px;
  52. background-color: #EFF3F8;
  53. + .dataTable {
  54. border-top: 1px solid @table-border-color;
  55. border-bottom: 1px solid @table-border-color;
  56. }
  57. }
  58. &:last-child {
  59. border-bottom: 1px solid lighten(@table-border-color , 1%);
  60. padding-top: 12px;
  61. padding-bottom: 12px;
  62. background-color: #EFF3F8;
  63. }
  64. }
  65. .dataTables_scroll + .row {
  66. border-top: 1px solid lighten(@table-border-color , 1%);
  67. }
  68. }
  69. .dataTable {
  70. margin-bottom:0;
  71. > thead > tr > th {
  72. &[class*=sort] {
  73. cursor:pointer;
  74. &:after {
  75. float: right;
  76. display: inline;
  77. content: "\f0dc";
  78. font-family: FontAwesome;
  79. font-size: @base-font-size;
  80. font-weight: normal;
  81. color: #555;
  82. }
  83. &:hover {
  84. color:@table-sort-hover;
  85. }
  86. }
  87. &[class*=sorting_] {
  88. color:@table-sort-active;
  89. }
  90. &.sorting_desc , &.sorting_asc {
  91. #gradient > .vertical(#EFF3F8 , #E3E7ED);
  92. }
  93. &.sorting_desc:after {
  94. content:"\f0dd";
  95. top:-6px;
  96. color:@table-sort-active;
  97. }
  98. &.sorting_asc:after {
  99. content:"\f0de";
  100. top:4px;
  101. color:@table-sort-active;
  102. }
  103. &.sorting_disabled {
  104. cursor:inherit;
  105. &:after { display:none; }
  106. }
  107. }
  108. }
  109. //scrollable dataTable
  110. .dataTables_scrollHead + .dataTables_scrollBody > .dataTable > thead > tr > th:after {
  111. display: none;
  112. }
  113. .dataTables_scrollHeadInner {
  114. width: auto !important;
  115. }
  116. .dataTables_scrollHeadInner > .dataTable > thead > tr > th {
  117. border-bottom-width: 0 !important;
  118. }
  119. //some extra border because of scrolling horizontally
  120. .dataTables_borderWrap {
  121. .dataTables_scrollBody , .dataTables_scrollHead {
  122. border: 1px solid @table-border-color !important;
  123. border-width: 0 1px !important;
  124. .table-bordered {
  125. border-left-width: 0;
  126. border-right-width: 0;
  127. > thead > tr > th:first-child,
  128. > tbody > tr > td:first-child {
  129. border-left-width: 0;
  130. }
  131. > thead > tr > th:last-child,
  132. > tbody > tr > td:last-child {
  133. border-right-width: 0;
  134. }
  135. }
  136. }
  137. }
  138. //some extra from
  139. //https://github.com/DataTables/Plugins/tree/master/integration/bootstrap/3
  140. table.dataTable {
  141. clear: both;
  142. max-width: none !important;
  143. }
  144. table.dataTable th:active {
  145. outline: none;
  146. }
  147. //Scrolling
  148. div.dataTables_scrollHead table {
  149. margin-bottom: 0 !important;
  150. border-bottom-left-radius: 0;
  151. border-bottom-right-radius: 0;
  152. }
  153. div.dataTables_scrollHead table thead tr:last-child th:first-child,
  154. div.dataTables_scrollHead table thead tr:last-child td:first-child {
  155. border-bottom-left-radius: 0 !important;
  156. border-bottom-right-radius: 0 !important;
  157. }
  158. div.dataTables_scrollBody table {
  159. border-top: none;
  160. margin-top: 0 !important;
  161. margin-bottom: 0 !important;
  162. }
  163. div.dataTables_scrollBody tbody tr:first-child th,
  164. div.dataTables_scrollBody tbody tr:first-child td {
  165. border-top: none;
  166. }
  167. div.dataTables_scrollFoot table {
  168. margin-top: 0 !important;
  169. border-top: none;
  170. }
  171. ///
  172. //for tableTools printing
  173. .DTTT_Print .main-content {
  174. margin-left: 0 !important;
  175. margin-right: 0 !important;
  176. }
  177. .DTTT_Print .navbar-fixed-top + .main-container {
  178. padding-top: 0;
  179. }
  180. //table Tools extension
  181. .tableTools-container {
  182. margin-bottom: 8px;
  183. }
  184. .tableTools-alert.gritter-item-wrapper {
  185. padding: 12px 11px 8px;
  186. z-index: 1999;
  187. }
  188. //ColVis extension
  189. ul.ColVis_collection {
  190. z-index: 2002;
  191. > li > a {
  192. padding: 0;
  193. &:focus {
  194. outline: none;
  195. }
  196. }
  197. > li.ColVis_Special {
  198. border-top: 1px solid #DDD;
  199. > a {
  200. padding: 6px 11px 7px;
  201. text-align: center;
  202. }
  203. }
  204. label {
  205. margin: auto;
  206. padding: 6px 11px 7px;
  207. display: block;
  208. cursor: pointer;
  209. }
  210. }
  211. div.ColVis_catcher {
  212. position: absolute;
  213. z-index: 1101;
  214. }
  215. div.ColVis_collectionBackground {
  216. position: fixed;
  217. top: 0;
  218. left: 0;
  219. height: 100%;
  220. width: 100%;
  221. background-color: black;
  222. z-index: 1100;
  223. }
  224. }
  225. .enable_plugin_datatables();