index.less 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. @import "../styles/mixins/index.less";
  2. @import "../styles/themes/index.less";
  3. .@{wux-prefix}-popup {
  4. position: fixed;
  5. z-index: @z-index-popup;
  6. width: @popup-width;
  7. max-width: @popup-max-width;
  8. &__content {
  9. position: relative;
  10. background-color: @popup-content-bg;
  11. border: 0;
  12. background-clip: padding-box;
  13. height: 100%;
  14. text-align: center;
  15. overflow: hidden;
  16. }
  17. &__title {
  18. font-weight: 400;
  19. font-size: @popup-title-font-size;
  20. color: @heading-color;
  21. }
  22. &__bd {
  23. min-height: 40px;
  24. font-size: @popup-bd-font-size;
  25. line-height: 1.3;
  26. word-wrap: break-word;
  27. word-break: break-all;
  28. color: @text-color-secondary;
  29. }
  30. &__ft {
  31. position: relative;
  32. line-height: 48px;
  33. font-size: @popup-title-font-size;
  34. display: flex;
  35. }
  36. &__close {
  37. border: 0;
  38. padding: 3px;
  39. background-color: transparent;
  40. outline: none;
  41. position: absolute;
  42. top: 6px;
  43. right: 6px;
  44. height: 21px;
  45. width: 21px;
  46. display: flex;
  47. justify-content: center;
  48. align-items: center;
  49. }
  50. &__close-x {
  51. display: inline-block;
  52. width: 15px;
  53. height: 15px;
  54. background-repeat: no-repeat;
  55. background-size: cover;
  56. .encoded-svg-background(delete);
  57. }
  58. &-position&-position--center {
  59. .@{wux-prefix}-popup {
  60. top: 50%;
  61. left: 50%;
  62. transform: translate(-50%, -50%);
  63. }
  64. .@{wux-prefix}-popup__content {
  65. border-radius: @border-radius-base;
  66. }
  67. .@{wux-prefix}-popup__hd {
  68. padding: @popup-hd-padding;
  69. }
  70. .@{wux-prefix}-popup__bd {
  71. padding: @popup-bd-padding;
  72. }
  73. .@{wux-prefix}-popup__ft::after {
  74. .setTopLine(@border-color-split);
  75. }
  76. }
  77. &-position&-position--top {
  78. .@{wux-prefix}-popup {
  79. position: fixed;
  80. left: 0;
  81. top: 0;
  82. width: 100%;
  83. max-width: 100%;
  84. &__close {
  85. top: unset;
  86. bottom: 6px;
  87. }
  88. }
  89. }
  90. &-position&-position--right {
  91. .@{wux-prefix}-popup {
  92. position: fixed;
  93. top: 0;
  94. right: 0;
  95. width: @popup-width;
  96. max-width: 100%;
  97. height: 100%;
  98. max-height: 100%;
  99. &__close {
  100. right: unset;
  101. left: 6px;
  102. }
  103. }
  104. }
  105. &-position&-position--bottom {
  106. .@{wux-prefix}-popup {
  107. position: fixed;
  108. left: 0;
  109. bottom: 0;
  110. width: 100%;
  111. max-width: 100%;
  112. }
  113. }
  114. &-position&-position--left {
  115. .@{wux-prefix}-popup {
  116. position: fixed;
  117. left: 0;
  118. top: 0;
  119. width: @popup-width;
  120. max-width: 100%;
  121. height: 100%;
  122. max-height: 100%;
  123. }
  124. }
  125. }