index.scss 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. .picture-editor-wrap_layer.layer-panel {
  2. position: fixed;
  3. top: 85px;
  4. left: 0;
  5. width: 280px;
  6. height: 410px;
  7. background: #ffffff;
  8. color: #222;
  9. padding: 8px 10px;
  10. box-sizing: border-box;
  11. overflow: hidden;
  12. display: flex;
  13. flex-direction: column;
  14. z-index: 12;
  15. .layer-panel__header {
  16. display: flex;
  17. align-items: baseline;
  18. justify-content: space-between;
  19. padding: 4px 2px 8px;
  20. border-bottom: 1px solid #f0f0f0;
  21. }
  22. .layer-panel__title {
  23. font-size: 13px;
  24. font-weight: 600;
  25. }
  26. .layer-panel__sub {
  27. font-size: 11px;
  28. color: #999;
  29. }
  30. .layer-panel__list {
  31. flex: 1;
  32. overflow: auto;
  33. padding: 6px 0;
  34. }
  35. .layer-item {
  36. display: flex;
  37. align-items: center;
  38. padding: 6px;
  39. border-radius: 4px;
  40. background: #fff;
  41. border: 1px solid transparent;
  42. margin-bottom: 6px;
  43. cursor: pointer;
  44. transition: all .15s ease;
  45. }
  46. .layer-item:hover {
  47. border-color: #dcdcdc;
  48. background: #fafafa;
  49. }
  50. .layer-item.active {
  51. border-color: $primary1;
  52. box-shadow: 0 0 0 1px rgba($primary1,0.35);
  53. background: #f5fbff;
  54. }
  55. .layer-item__preview {
  56. width: 28px;
  57. height: 28px;
  58. border-radius: 4px;
  59. background: #f5f5f5;
  60. border: 1px solid #eee;
  61. display: flex;
  62. align-items: center;
  63. justify-content: center;
  64. overflow: hidden;
  65. margin-right: 5px;
  66. }
  67. .layer-item__preview img {
  68. width: 100%;
  69. height: 100%;
  70. object-fit: contain;
  71. }
  72. .layer-item__meta {
  73. flex: 1;
  74. display: flex;
  75. flex-direction: column;
  76. gap: 4px;
  77. }
  78. .layer-item__name {
  79. width: 100%;
  80. background: #fafafa;
  81. border: 1px solid #e2e2e2;
  82. border-radius: 4px;
  83. color: #333;
  84. padding: 5px 6px;
  85. outline: none;
  86. font-size: 12px;
  87. }
  88. .layer-item__name:focus {
  89. border-color: $primary1;
  90. box-shadow: 0 0 0 1px rgba($primary1,0.25);
  91. }
  92. .layer-item__ops {
  93. display: flex;
  94. align-items: center;
  95. gap: 6px;
  96. position: relative;
  97. }
  98. .op-text {
  99. font-size: 12px;
  100. color: #666;
  101. cursor: pointer;
  102. }
  103. .op-text:hover {
  104. color: $primary1;
  105. }
  106. .op-btn.more {
  107. min-width: 32px;
  108. height: 24px;
  109. padding: 0 6px;
  110. border-radius: 4px;
  111. border: 1px solid #e2e2e2;
  112. background: #fff;
  113. color: #444;
  114. font-size: 14px;
  115. line-height: 22px;
  116. cursor: pointer;
  117. }
  118. .op-btn.more:hover {
  119. border-color: $primary1;
  120. color: $primary1;
  121. }
  122. .layer-item__menu {
  123. position: absolute;
  124. top: 26px;
  125. right: 0;
  126. min-width: 120px;
  127. background: #fff;
  128. border: 1px solid #e2e2e2;
  129. border-radius: 4px;
  130. box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  131. padding: 4px 0;
  132. z-index: 20;
  133. }
  134. .menu-item {
  135. padding: 6px 12px;
  136. font-size: 12px;
  137. color: #444;
  138. cursor: pointer;
  139. white-space: nowrap;
  140. }
  141. .menu-item:hover {
  142. background: #f5f5f5;
  143. color: $primary1;
  144. }
  145. .menu-item.danger {
  146. color: #e24b4b;
  147. }
  148. .menu-item.danger:hover {
  149. background: #fff3f3;
  150. color: #e24b4b;
  151. }
  152. .layer-panel__empty {
  153. flex: 1;
  154. color: #888;
  155. font-size: 12px;
  156. display: flex;
  157. align-items: center;
  158. justify-content: center;
  159. }
  160. }