global.less 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. @import '~antd/es/style/themes/default.less';
  2. html,
  3. body,
  4. #root {
  5. height: 100%;
  6. // 变成灰色
  7. //-webkit-filter: grayscale(.95);
  8. }
  9. .colorWeak {
  10. filter: invert(80%);
  11. }
  12. .ant-layout {
  13. min-height: 100vh;
  14. }
  15. .ant-pro-sider.ant-layout-sider.ant-pro-sider-fixed {
  16. left: unset;
  17. }
  18. canvas {
  19. display: block;
  20. }
  21. body {
  22. text-rendering: optimizeLegibility;
  23. -webkit-font-smoothing: antialiased;
  24. -moz-osx-font-smoothing: grayscale;
  25. }
  26. ul,
  27. ol {
  28. list-style: none;
  29. }
  30. // 菜单图标
  31. .ant-pro-menu-item {
  32. display: flex;
  33. align-items: center;
  34. img {
  35. width: 20px;
  36. height: 20px;
  37. }
  38. }
  39. @media (max-width: @screen-xs) {
  40. .ant-table {
  41. width: 100%;
  42. overflow-x: auto;
  43. &-thead > tr,
  44. &-tbody > tr {
  45. > th,
  46. > td {
  47. white-space: pre;
  48. > span {
  49. display: block;
  50. }
  51. }
  52. }
  53. }
  54. }
  55. // Compatible with IE11
  56. @media screen and(-ms-high-contrast: active), (-ms-high-contrast: none) {
  57. body .ant-design-pro > .ant-layout {
  58. min-height: 100vh;
  59. }
  60. }
  61. .ant-pro-top-nav-header-logo {
  62. display: flex;
  63. justify-content: center;
  64. }
  65. .ant-form-item-required {
  66. &::before {
  67. position: absolute;
  68. right: -12px;
  69. }
  70. }
  71. .ant-formily-item-label-content {
  72. position: relative;
  73. padding-bottom: 8px;
  74. overflow: unset;
  75. .ant-formily-item-asterisk {
  76. float: right;
  77. margin-right: 0;
  78. //position: absolute;
  79. //right: -8px;
  80. }
  81. }
  82. .ant-formily-item-colon {
  83. display: none;
  84. }
  85. .ant-formily-item-label-tooltip-icon {
  86. align-items: flex-start;
  87. padding-top: 5px;
  88. }
  89. .ant-page-header-heading {
  90. display: none;
  91. }
  92. .page-title-show {
  93. .ant-page-header-heading {
  94. display: flex;
  95. }
  96. }
  97. .tabs-full-active {
  98. .ant-tabs-tab-active {
  99. background-color: @primary-1;
  100. }
  101. }
  102. .ellipsis {
  103. width: 100%;
  104. overflow: hidden;
  105. white-space: nowrap;
  106. text-align: left;
  107. text-overflow: ellipsis;
  108. }
  109. .ellipsisFn(@num: 1, @width: 100%) {
  110. display: -webkit-box;
  111. max-width: @width;
  112. overflow: hidden;
  113. -webkit-box-orient: vertical;
  114. -webkit-line-clamp: @num;
  115. }
  116. .ellipsis-70 {
  117. width: 70%;
  118. overflow: hidden;
  119. white-space: nowrap;
  120. text-align: left;
  121. text-overflow: ellipsis;
  122. }
  123. // fuck chrome
  124. input[type='text'],
  125. input[type='password'],
  126. input[type='number'],
  127. input[type='tel'] {
  128. &:not([disabled]) {
  129. box-shadow: inset 0 0 0 100vw white !important;
  130. }
  131. }
  132. //引导遮罩
  133. #driver-page-overlay {
  134. opacity: 0.35 !important;
  135. }
  136. .ant-pagination-mini .ant-pagination-jump-prev,
  137. .ant-pagination-mini .ant-pagination-jump-next {
  138. display: none;
  139. }
  140. .ant-popover-buttons {
  141. display: flex;
  142. justify-content: flex-end;
  143. }