index.less 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. @import '../../app.less';
  2. .tabs {
  3. height: 44px;
  4. line-height: 44px;
  5. }
  6. .tabs.small {
  7. height: 32px;
  8. line-height: 32px;
  9. }
  10. .tabs.border {
  11. border-bottom: 1px solid #eee;
  12. }
  13. .tabs.line {
  14. text-align: center;
  15. background: #fff;
  16. .tab {
  17. display: inline-block;
  18. position: relative;
  19. text-align: center;
  20. color: @base_color;
  21. width: 120px;
  22. margin: 0 30px;
  23. cursor: pointer;
  24. }
  25. .tab::after {
  26. content: '';
  27. width: 0;
  28. height: 4px;
  29. background: @theme_color;
  30. transform: translateX(-50%);
  31. transition: all 0.25s;
  32. position: absolute;
  33. bottom: 0;
  34. left: 50%;
  35. }
  36. .tab:hover,
  37. .tab.active {
  38. color: @theme_color;
  39. }
  40. .tab:hover::after,
  41. .tab.active::after {
  42. width: 100%;
  43. }
  44. }
  45. .tabs.line.small {
  46. .tab {
  47. margin: 0;
  48. }
  49. .tab::after {
  50. height: 3px;
  51. }
  52. }
  53. .tabs.card {
  54. text-align: center;
  55. background: @theme_bg_color;
  56. .tabs-warpper {
  57. display: flex;
  58. a {
  59. display: inline-block;
  60. flex: 1;
  61. }
  62. }
  63. .tab {
  64. width: 100%;
  65. display: inline-block;
  66. position: relative;
  67. text-align: center;
  68. color: @base_color;
  69. cursor: pointer;
  70. }
  71. .tab::after {
  72. content: '';
  73. width: 0;
  74. height: 4px;
  75. background: @theme_color;
  76. transform: translateX(-50%);
  77. position: absolute;
  78. top: 0;
  79. left: 50%;
  80. }
  81. .tab:hover,
  82. .tab.active {
  83. color: @theme_color;
  84. background: #fff;
  85. }
  86. .tab:hover::after,
  87. .tab.active::after {
  88. width: 100%;
  89. }
  90. }
  91. .tabs.tag {
  92. line-height: 24px;
  93. .tabs-warpper {
  94. a {
  95. display: inline-block;
  96. }
  97. }
  98. .tab {
  99. padding: 0 20px;
  100. display: inline-block;
  101. position: relative;
  102. text-align: center;
  103. color: #fff;
  104. cursor: pointer;
  105. background: #B9C1C9;
  106. border-radius: 12px;
  107. }
  108. .tab:hover,
  109. .tab.active {
  110. background: @theme_color;
  111. }
  112. }
  113. .tabs.tag.white {
  114. .tab {
  115. background: #fff;
  116. color: #8897A8;
  117. border: 1px solid #8897A8;
  118. }
  119. .tab:hover,
  120. .tab.active {
  121. background: @theme_color;
  122. border: 1px solid @theme_color;
  123. color: #fff;
  124. }
  125. }
  126. .tabs.tag.small {
  127. height: 40px;
  128. overflow: hidden;
  129. .tabs-warpper {
  130. padding: 8px 0;
  131. }
  132. .tab {
  133. line-height: 22px;
  134. font-size: 12px;
  135. padding: 0 5px;
  136. }
  137. }
  138. .tabs.text {
  139. padding-left: 44px;
  140. background: #fff;
  141. .tab {
  142. display: inline-block;
  143. position: relative;
  144. text-align: center;
  145. color: @base_color;
  146. margin: 0 13px;
  147. cursor: pointer;
  148. }
  149. .tab::after {
  150. content: '';
  151. width: 1px;
  152. height: 20px;
  153. background: @line_color;
  154. position: absolute;
  155. top: 12px;
  156. right: -13px;
  157. }
  158. .tab:hover,
  159. .tab.active {
  160. color: @theme_color;
  161. }
  162. a:nth-last-child(1) {
  163. .tab::after {
  164. display: none;
  165. }
  166. }
  167. }
  168. .tabs.division {
  169. text-align: center;
  170. .tabs-warpper {
  171. display: flex;
  172. }
  173. a {
  174. display: inline-block;
  175. flex: 1;
  176. width: 100%;
  177. padding: 0 5px;
  178. }
  179. .tab {
  180. width: 100%;
  181. display: inline-block;
  182. position: relative;
  183. text-align: center;
  184. color: @base_color;
  185. cursor: pointer;
  186. background: #E5E8EE;
  187. border-radius: 4px 4px 0px 0px;
  188. overflow: hidden;
  189. }
  190. .tab::after {
  191. content: '';
  192. width: 0;
  193. height: 4px;
  194. background: @theme_color;
  195. transform: translateX(-50%);
  196. position: absolute;
  197. top: 0;
  198. left: 50%;
  199. }
  200. .tab:hover,
  201. .tab.active {
  202. color: @theme_color;
  203. background: #fff;
  204. }
  205. .tab:hover::after,
  206. .tab.active::after {
  207. width: 100%;
  208. }
  209. }
  210. .tabs.division.theme {
  211. .tab {
  212. color: #A7A7B7;
  213. background: #ECEDEE;
  214. }
  215. .tab::after {
  216. display: none;
  217. }
  218. .tab:hover,
  219. .tab.active {
  220. color: #fff;
  221. background: @theme_color;
  222. }
  223. }
  224. .tabs.division.gray {
  225. .tab {
  226. color: #A7A7B7;
  227. background: #ECEDEE;
  228. }
  229. .tab::after {
  230. display: none;
  231. }
  232. .tab:hover,
  233. .tab.active {
  234. color: #fff;
  235. background: #989FC1;
  236. }
  237. }