header.less 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223
  1. .ui-grid-top-panel-background {
  2. .gradient(@headerBackgroundColor, @headerGradientStart, @headerGradientStop);
  3. }
  4. @topPanelRadius: @gridBorderRadius - @gridBorderWidth;
  5. .ui-grid-header {
  6. border-bottom: 1px solid @borderColor;
  7. box-sizing: border-box;
  8. }
  9. .ui-grid-top-panel {
  10. position: relative;
  11. // border-bottom: 1px solid @borderColor; // #D4D4D4
  12. overflow: hidden; // Disable so menus show up
  13. font-weight: bold;
  14. // .gradient(@headerBackgroundColor, @headerGradientStart, @headerGradientStop);
  15. .ui-grid-top-panel-background;
  16. .border-radius(@topPanelRadius, 0, 0, @topPanelRadius);
  17. }
  18. .ui-grid-header-viewport {
  19. overflow: hidden; // Disable so menus show up
  20. }
  21. .ui-grid-header-canvas {
  22. // Clearfix for floating header cells
  23. &:before, &:after {
  24. content: "";
  25. display: table;
  26. line-height: 0;
  27. }
  28. &:after {
  29. clear:both;
  30. }
  31. // .border-radius(@gridBorderRadius, 0, 0, @gridBorderRadius);
  32. }
  33. .ui-grid-header-cell-wrapper {
  34. position: relative;
  35. display: table;
  36. box-sizing: border-box;
  37. height: 100%;
  38. }
  39. .ui-grid-header-cell-row {
  40. display: table-row;
  41. position: relative
  42. }
  43. .ui-grid-header-cell {
  44. position: relative;
  45. box-sizing: border-box;
  46. background-color: inherit;
  47. border-right: @gridBorderWidth solid;
  48. border-color: @headerVerticalBarColor;
  49. display: table-cell;
  50. &:last-child {
  51. border-right: 0;
  52. }
  53. .user-select(none);
  54. // Default to width 0 so header height can calculate right. Otherwise
  55. // the header cells will flow onto the next line of the header container
  56. // and cause the header height to be calculated as twice the height
  57. // it should be. The column widths are calculated dynamically
  58. width: 0;
  59. .sortable {
  60. cursor: pointer;
  61. }
  62. }
  63. // Make vertical bar in header row fill the height of the cell completely
  64. .ui-grid-header .ui-grid-vertical-bar {
  65. top: 0;
  66. bottom: 0;
  67. }
  68. .ui-grid-column-menu-button {
  69. position: absolute;
  70. right: @gridBorderWidth; // So it doesn't overlay the vertical bar
  71. top: 0;
  72. // bottom: 0;
  73. // .ui-grid-top-panel-background;
  74. .ui-grid-icon-angle-down {
  75. vertical-align: sub;
  76. }
  77. }
  78. .ui-grid-column-menu-button-last-col {
  79. margin-right: 25px;
  80. }
  81. .ui-grid-column-menu {
  82. position: absolute;
  83. }
  84. /* Slide up/down animations */
  85. .ui-grid-column-menu .ui-grid-menu .ui-grid-menu-mid {
  86. &.ng-hide-add, &.ng-hide-remove {
  87. .transition(all, 0.05s, linear);
  88. display: block !important;
  89. }
  90. &.ng-hide-add.ng-hide-add-active,
  91. &.ng-hide-remove {
  92. .transform(translateY(-100%));
  93. }
  94. &.ng-hide-add,
  95. &.ng-hide-remove.ng-hide-remove-active {
  96. .transform(translateY(0));
  97. }
  98. }
  99. /* Slide up/down animations */
  100. .ui-grid-menu-button .ui-grid-menu .ui-grid-menu-mid {
  101. &.ng-hide-add, &.ng-hide-remove {
  102. .transition(all, 0.05s, linear);
  103. display: block !important;
  104. }
  105. &.ng-hide-add.ng-hide-add-active,
  106. &.ng-hide-remove {
  107. .transform(translateY(-100%));
  108. }
  109. &.ng-hide-add,
  110. &.ng-hide-remove.ng-hide-remove-active {
  111. .transform(translateY(0));
  112. }
  113. }
  114. .ui-grid-filter-container {
  115. padding: 4px 10px;
  116. position: relative;
  117. .ui-grid-filter-button {
  118. position: absolute;
  119. top: 0;
  120. bottom: 0;
  121. right: 0;
  122. [class^="ui-grid-icon"] {
  123. position: absolute;
  124. top: 50%;
  125. line-height: 32px;
  126. margin-top: -16px;
  127. right: 10px;
  128. opacity: 0.66;
  129. &:hover {
  130. opacity: 1;
  131. }
  132. }
  133. }
  134. .ui-grid-filter-button-select {
  135. position: absolute;
  136. top: 0;
  137. bottom: 0;
  138. right: 0;
  139. [class^="ui-grid-icon"] {
  140. position: absolute;
  141. top: 50%;
  142. line-height: 32px;
  143. margin-top: -16px;
  144. right: 0px;
  145. opacity: 0.66;
  146. &:hover {
  147. opacity: 1;
  148. }
  149. }
  150. }
  151. }
  152. input[type="text"].ui-grid-filter-input {
  153. padding: 0;
  154. margin: 0;
  155. border: 0;
  156. width: 100%;
  157. border: @gridBorderWidth solid @borderColor;
  158. .border-radius(@gridBorderRadius);
  159. &:hover {
  160. border: @gridBorderWidth solid @borderColor;
  161. }
  162. }
  163. select.ui-grid-filter-select {
  164. padding: 0;
  165. margin: 0;
  166. border: 0;
  167. width: 90%;
  168. border: @gridBorderWidth solid @borderColor;
  169. .border-radius(@gridBorderRadius);
  170. &:hover {
  171. border: @gridBorderWidth solid @borderColor;
  172. }
  173. .ui-grid-filter-cancel-button-hidden & {
  174. width: 100%;
  175. }
  176. }