dropdown.less 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. @import '../../style/themes/index';
  2. @import '../../style/mixins/index';
  3. @tab-prefix-cls: ~'@{ant-prefix}-tabs';
  4. .@{tab-prefix-cls}-dropdown {
  5. .reset-component();
  6. position: absolute;
  7. top: -9999px;
  8. left: -9999px;
  9. z-index: @zindex-dropdown;
  10. display: block;
  11. &-hidden {
  12. display: none;
  13. }
  14. &-menu {
  15. max-height: 200px;
  16. margin: 0;
  17. padding: @dropdown-edge-child-vertical-padding 0;
  18. overflow-x: hidden;
  19. overflow-y: auto;
  20. text-align: left;
  21. list-style-type: none;
  22. background-color: @dropdown-menu-bg;
  23. background-clip: padding-box;
  24. border-radius: @border-radius-base;
  25. outline: none;
  26. box-shadow: @box-shadow-base;
  27. &-item {
  28. display: flex;
  29. align-items: center;
  30. min-width: 120px;
  31. margin: 0;
  32. padding: @dropdown-vertical-padding @control-padding-horizontal;
  33. overflow: hidden;
  34. color: @text-color;
  35. font-weight: normal;
  36. font-size: @dropdown-font-size;
  37. line-height: @dropdown-line-height;
  38. white-space: nowrap;
  39. text-overflow: ellipsis;
  40. cursor: pointer;
  41. transition: all 0.3s;
  42. > span {
  43. flex: 1;
  44. white-space: nowrap;
  45. }
  46. &-remove {
  47. flex: none;
  48. margin-left: @margin-sm;
  49. color: @text-color-secondary;
  50. font-size: @font-size-sm;
  51. background: transparent;
  52. border: 0;
  53. cursor: pointer;
  54. &:hover {
  55. color: @tabs-hover-color;
  56. }
  57. }
  58. &:hover {
  59. background: @item-hover-bg;
  60. }
  61. &-disabled {
  62. &,
  63. &:hover {
  64. color: @disabled-color;
  65. background: transparent;
  66. cursor: not-allowed;
  67. }
  68. }
  69. }
  70. }
  71. }