thirdparty-nestable.less 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290
  1. .enable_plugin_nestable_list() when(@enable-plugin-nestable-list = true) {
  2. .dd {
  3. position: relative;
  4. display: block;
  5. margin: 0; padding: 0;
  6. max-width: 600px;
  7. list-style: none;
  8. line-height: 20px;
  9. }
  10. .dd-list {
  11. display: block;
  12. position: relative;
  13. margin: 0; padding: 0; list-style: none;
  14. .dd-list {
  15. padding-left: 30px;
  16. }
  17. .dd-collapsed & {
  18. display: none;
  19. }
  20. }
  21. .dd-item,
  22. .dd-empty,
  23. .dd-placeholder {
  24. display: block;
  25. position: relative;
  26. margin: 0;
  27. padding: 0;
  28. min-height: 20px;
  29. line-height: 20px;
  30. }
  31. .dd-handle , .dd2-content {
  32. display: block;
  33. min-height: 38px;
  34. margin: 5px 0;
  35. padding: 8px 12px;
  36. background: #F8FAFF;
  37. border: 1px solid #DAE2EA;
  38. color: #7C9EB2;
  39. text-decoration: none;
  40. font-weight: bold;
  41. .box-sizing(border-box);
  42. &:hover {
  43. color: #438EB9;
  44. background: #F4F6F7;
  45. border-color:#DCE2E8;
  46. }
  47. &[class*="btn-"] {
  48. color:#FFF;
  49. border:none;
  50. padding: 9px 12px;
  51. &:hover {
  52. opacity:0.85;
  53. color:#FFF;
  54. }
  55. }
  56. }
  57. .dd2-handle + .dd2-content,
  58. .dd2-handle + .dd2-content[class*="btn-"]
  59. {
  60. padding-left:44px;
  61. }
  62. .dd-handle[class*="btn-"]:hover , .dd2-content[class*="btn-"]
  63. .dd2-handle[class*="btn-"]:hover + .dd2-content[class*="btn-"] {
  64. //opacity:0.85;
  65. color:#FFF;
  66. }
  67. .dd-item > button:hover {
  68. ~ .dd-handle , ~ .dd2-content {
  69. color: #438EB9;
  70. background: #F4F6F7;
  71. border-color:#DCE2E8;
  72. }
  73. ~ .dd-handle[class*="btn-"] , ~ .dd2-content[class*="btn-"] {
  74. opacity:0.85;
  75. color:#FFF;
  76. }
  77. }
  78. .dd2-handle:hover {
  79. ~ .dd2-content {
  80. color: #438EB9;
  81. background: #F4F6F7;
  82. border-color:#DCE2E8;
  83. }
  84. ~ .dd2-content[class*="btn-"] {
  85. opacity:0.85;
  86. color:#FFF;
  87. }
  88. }
  89. .dd2-item.dd-item > button {
  90. margin-left:34px;
  91. }
  92. .dd-item > button {
  93. display: block;
  94. position: relative; z-index:1;
  95. cursor: pointer;
  96. float: left;
  97. width: 25px;
  98. height: 20px;
  99. margin: 5px 1px 5px 5px;
  100. padding: 0;
  101. text-indent: 100%;
  102. white-space: nowrap;
  103. overflow: hidden;
  104. border: 0;
  105. background: transparent;
  106. font-size: @base-font-size - 1;
  107. line-height: 1;
  108. text-align: center;
  109. font-weight: bold;
  110. top:4px;
  111. left:1px;
  112. color:#707070;
  113. }
  114. .dd-item > button:before {
  115. font-family: FontAwesome;
  116. content: '\f067';
  117. display: block;
  118. position: absolute;
  119. width: 100%;
  120. text-align: center;
  121. text-indent: 0;
  122. font-weight: normal;
  123. font-size: @base-font-size + 1;
  124. }
  125. .dd-item > button[data-action="collapse"]:before {
  126. content: '\f068';
  127. }
  128. .dd-item > button:hover {
  129. color:#707070;
  130. }
  131. .dd-item.dd-colored > button , .dd-item.dd-colored > button:hover {
  132. color:#EEE;
  133. }
  134. .dd-placeholder,
  135. .dd-empty {
  136. margin: 5px 0;
  137. padding: 0;
  138. min-height: 30px;
  139. background: #F0F9FF;
  140. border: 2px dashed #BED2DB;
  141. .box-sizing(border-box);
  142. }
  143. .dd-empty {
  144. border-color:#AAA;
  145. border-style:solid;
  146. background-color: #e5e5e5;
  147. }
  148. .dd-dragel {
  149. position: absolute;
  150. pointer-events: none;
  151. z-index: 999;
  152. opacity:0.8;
  153. > li > .dd-handle {
  154. color:#4B92BE;
  155. background:#F1F5FA;
  156. border-color:#D6E1EA;
  157. //opacity:0.85;
  158. border-left:2px solid #777;
  159. position:relative;
  160. &[class*="btn-"] {
  161. color:#FFF;
  162. }
  163. }
  164. }
  165. .dd-dragel > .dd-item > .dd-handle {
  166. margin-top: 0;
  167. }
  168. .dd-list > li[class*="item-"] {
  169. border-width:0;padding:0;
  170. > .dd-handle {
  171. border-left:2px solid;
  172. border-left-color:inherit;
  173. }
  174. }
  175. .dd-list > li > .dd-handle .sticker {
  176. position:absolute;
  177. right:0;
  178. top:0;
  179. }
  180. .dd2-handle , .dd-dragel > li > .dd2-handle {
  181. position:absolute;
  182. left:0; top:0;
  183. width:36px;
  184. margin:0;
  185. border-width:1px 1px 0 0;
  186. text-align:center;
  187. padding:0 !important;
  188. line-height:38px;
  189. height:38px;
  190. background: #EBEDF2;
  191. border: 1px solid #DEE4EA;
  192. cursor: pointer;
  193. overflow: hidden;
  194. position: absolute;
  195. z-index:1;
  196. }
  197. .dd2-handle:hover , .dd-dragel > li > .dd2-handle{
  198. background:#E3E8ED;
  199. }
  200. .dd2-content[class*="btn-"] {
  201. text-shadow:none !important;
  202. }
  203. .dd2-handle[class*="btn-"] {
  204. text-shadow:none !important;
  205. background:rgba(0,0,0,0.1) !important;
  206. border-right:1px solid #EEE;
  207. }
  208. .dd2-handle[class*="btn-"]:hover {
  209. background:rgba(0,0,0,0.08) !important;
  210. }
  211. .dd-dragel .dd2-handle[class*="btn-"] {
  212. border-color:transparent;
  213. border-right-color:#EEE;
  214. }
  215. .dd2-handle.btn-yellow {
  216. text-shadow:none !important;
  217. background:rgba(0,0,0,0.05) !important;
  218. border-right:1px solid #FFF;
  219. }
  220. .dd2-handle.btn-yellow:hover {
  221. background:rgba(0,0,0,0.08) !important;
  222. }
  223. .dd-dragel .dd2-handle.btn-yellow {
  224. border-color:transparent;
  225. border-right-color:#FFF;
  226. }
  227. .dd-item > .dd2-handle .drag-icon {
  228. display:none;
  229. }
  230. .dd-dragel > .dd-item > .dd2-handle .drag-icon {
  231. display:inline;
  232. }
  233. .dd-dragel > .dd-item > .dd2-handle .normal-icon {
  234. display:none;
  235. }
  236. }
  237. .enable_plugin_nestable_list();