style.less 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267
  1. .cost-ant-table-wrapper {
  2. border-radius: 4px !important;
  3. table {
  4. border-radius: 4px !important;
  5. }
  6. .cost-ant-table-container {
  7. border-start-start-radius: 4px !important;
  8. border-start-end-radius: 4px !important;
  9. }
  10. // 移除空规则,避免linter警告
  11. }
  12. .cost-ant-table .cost-ant-table-header {
  13. border-radius: 4px !important;
  14. }
  15. .cost-ant-pro-table .cost-ant-pro-card .cost-ant-pro-card-body {
  16. padding-inline: 0 !important;
  17. }
  18. .cost-ant-table-thead > tr > th {
  19. padding: 8px 8px !important;
  20. background: #eef3fa !important;
  21. &::before {
  22. display: none !important;
  23. }
  24. }
  25. .cost-ant-table-wrapper .cost-ant-table-pagination.cost-ant-pagination {
  26. padding-right: 16px;
  27. }
  28. .cost-ant-table-wrapper
  29. .cost-ant-table.cost-ant-table-bordered
  30. > .cost-ant-table-container
  31. > .cost-ant-table-body
  32. > table
  33. > tbody
  34. > tr
  35. > td {
  36. //#dae2f2
  37. border-inline-end: 1px solid #dae2f2 !important;
  38. }
  39. .KCIMTable {
  40. .cost-ant-table {
  41. .cost-ant-space-align-center {
  42. gap: 0 !important;
  43. }
  44. .cost-ant-table-thead {
  45. .cost-ant-table-cell {
  46. padding: 8px 8px !important;
  47. background: rgb(238 243 250 / 100%) !important;
  48. // 表头允许换行
  49. white-space: normal !important;
  50. word-break: break-word !important;
  51. overflow-wrap: anywhere;
  52. // 多层级表头边框
  53. border-bottom: 1px solid #dae2f2 !important;
  54. border-right: 1px solid #dae2f2 !important;
  55. }
  56. // 首列左边框
  57. > tr > th:first-child {
  58. border-left: 1px solid #dae2f2 !important;
  59. }
  60. a {
  61. color: #3376fe;
  62. }
  63. .cost-ant-table-selection {
  64. .cost-ant-table-selection-extra {
  65. top: 5px;
  66. }
  67. }
  68. &::before {
  69. display: none;
  70. }
  71. &:hover {
  72. background: rgb(238 243 250 / 100%) !important;
  73. }
  74. // 不再去掉最后一个表头格子的右边框,保持分隔
  75. }
  76. .cost-ant-table-tbody {
  77. & > tr {
  78. &.cost-ant-table-measure-row {
  79. border: none !important;
  80. & > td {
  81. border-inline-end: none !important;
  82. }
  83. }
  84. &.cost-ant-table-row {
  85. .cost-ant-table-cell {
  86. font-size: 14px;
  87. font-family: SourceHanSansCN-Medium, SourceHanSansCN;
  88. justify-content: flex-start !important;
  89. color: #17181a;
  90. padding: 8px 8px !important;
  91. border-bottom: none !important;
  92. border-top: 1px solid rgb(218 226 242) !important;
  93. &.cost-ant-table-cell-with-append {
  94. .cost-ant-table-row-expand-icon {
  95. border-radius: 4px !important;
  96. border: 1px solid #dae2f2 !important;
  97. &:hover {
  98. color: #3377ff;
  99. border: 1px solid #3377ff !important;
  100. }
  101. }
  102. }
  103. & > .cost-ant-typography {
  104. line-height: unset;
  105. }
  106. // 移除空规则,避免linter警告
  107. // &:hover {
  108. // border-radius: 0 !important;
  109. // background: #FAFBFC !important;
  110. // }
  111. }
  112. }
  113. &.cost-ant-table-row-selected {
  114. .cost-ant-table-cell {
  115. border-radius: 0 !important;
  116. }
  117. &:hover {
  118. background: #bae0ff !important;
  119. }
  120. }
  121. &:last-child > td {
  122. border-bottom: none !important;
  123. }
  124. }
  125. }
  126. .cost-ant-table-summary {
  127. & > tr > td {
  128. // 不强制对齐,让各列按照 Summary.Cell 的 align 与列配置对齐
  129. padding: 8px 8px !important; // 与tbody行保持一致高度
  130. border-top: 1px solid #dae2f2 !important;
  131. }
  132. }
  133. &.cost-ant-table-bordered {
  134. .cost-ant-table-container {
  135. border-left: none !important;
  136. .cost-ant-table-thead {
  137. & > tr {
  138. & > th {
  139. border-right: 1px solid #dae2f2 !important;
  140. border-bottom: 1px solid #dae2f2 !important;
  141. border-top: none !important;
  142. &.cost-ant-table-cell-scrollbar {
  143. border: none !important;
  144. }
  145. &::after {
  146. border: none !important;
  147. }
  148. }
  149. &:last-child {
  150. & > th {
  151. border-top: none !important;
  152. }
  153. }
  154. }
  155. }
  156. .cost-ant-table-tbody {
  157. tr > td {
  158. border-right: 1px solid #dae2f2 !important;
  159. &::after {
  160. border: none !important;
  161. }
  162. }
  163. }
  164. }
  165. }
  166. }
  167. .cost-ant-pagination {
  168. padding: 7px 0;
  169. margin: 0 !important;
  170. border-top: 1px solid #dae2f2 !important;
  171. .cost-ant-pagination-item-active {
  172. font-weight: 600;
  173. background-color: #37f !important;
  174. border-color: #37f !important;
  175. }
  176. }
  177. .cost-ant-pagination .cost-ant-pagination-item-active a {
  178. color: #fff !important;
  179. }
  180. }
  181. .cost-ant-table-wrapper
  182. .cost-ant-table-container
  183. table
  184. > thead
  185. > tr:first-child
  186. th:first-child {
  187. border-start-start-radius: 4px !important;
  188. }
  189. .cost-ant-table-wrapper
  190. .cost-ant-table-container
  191. table
  192. > thead
  193. > tr:first-child
  194. th:last-child {
  195. border-start-end-radius: 4px !important;
  196. }
  197. .cost-ant-empty-normal {
  198. margin-block: 80px !important;
  199. color: rgb(0 0 0 / 25%);
  200. }
  201. // 小计行高亮背景样式
  202. .subtotal-row {
  203. background: #f2f8ff !important;
  204. font-weight: 600; // 小计行加粗
  205. }
  206. // 兼容固定列:为固定列的单元格也着色
  207. .KCIMTable {
  208. .cost-ant-table {
  209. .cost-ant-table-tbody {
  210. tr.subtotal-row > td,
  211. tr.subtotal-row > td.cost-ant-table-cell-fix-left,
  212. tr.subtotal-row > td.cost-ant-table-cell-fix-right,
  213. tr.subtotal-row > td.cost-ant-table-cell-fix-left-last,
  214. tr.subtotal-row > td.cost-ant-table-cell-fix-right-first {
  215. background: #f2f8ff !important;
  216. position: relative;
  217. font-weight: 600; // 与整行一致加粗
  218. }
  219. // 去掉固定列的阴影遮罩,避免覆盖行背景
  220. tr.subtotal-row > td.cost-ant-table-cell-fix-left::after,
  221. tr.subtotal-row > td.cost-ant-table-cell-fix-left-last::after,
  222. tr.subtotal-row > td.cost-ant-table-cell-fix-right::after,
  223. tr.subtotal-row > td.cost-ant-table-cell-fix-right-first::after {
  224. box-shadow: none !important;
  225. background: transparent !important;
  226. }
  227. }
  228. }
  229. }