controls.scss 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431
  1. .msp-row {
  2. position: relative;
  3. height: $row-height;
  4. background: $default-background;
  5. margin-top: 1px;
  6. select, button, input[type=text] {
  7. @extend .msp-form-control;
  8. }
  9. button {
  10. @extend .msp-btn;
  11. @extend .msp-btn-block;
  12. }
  13. }
  14. .msp-control-row {
  15. position: relative;
  16. height: $row-height;
  17. background: $default-background;
  18. margin-top: 1px;
  19. > span:first-child, > button.msp-control-button-label {
  20. line-height: $row-height;
  21. display: block;
  22. width: $control-label-width + $control-spacing;
  23. text-align: right;
  24. padding: 0 $control-spacing;
  25. color: color-lower-contrast($font-color, 15%);
  26. overflow: hidden;
  27. text-overflow: ellipsis;
  28. white-space: nowrap;
  29. position: relative;
  30. @include non-selectable;
  31. }
  32. > button.msp-control-button-label {
  33. background: $default-background;
  34. cursor: pointer;
  35. }
  36. select, button, input[type=text] {
  37. @extend .msp-form-control;
  38. }
  39. button {
  40. @extend .msp-btn;
  41. @extend .msp-btn-block;
  42. }
  43. .msp-control-current {
  44. background: $default-background;
  45. }
  46. > div:nth-child(2) {
  47. position: absolute;
  48. left: $control-label-width + $control-spacing;
  49. top: 0;
  50. right: 0;
  51. bottom: 0;
  52. }
  53. > div {
  54. background: $msp-form-control-background;
  55. }
  56. > .msp-select-row {
  57. background: $default-background;
  58. }
  59. }
  60. .msp-control-label-short {
  61. > span {
  62. width: $control-label-short-width + $control-spacing;
  63. }
  64. > div:nth-child(2) {
  65. left: $control-label-short-width + $control-spacing;
  66. }
  67. }
  68. .msp-control-col-2 {
  69. float: left;
  70. width: 50%;
  71. }
  72. .msp-control-group {
  73. position: relative;
  74. }
  75. .msp-toggle-button {
  76. .msp-icon {
  77. display: inline-block;
  78. margin-right: 6px;
  79. }
  80. > div > button:hover {
  81. border-color: color-increase-contrast($msp-form-control-background, 5%) !important;
  82. border: none;
  83. outline-offset: -1px !important;
  84. outline: 1px solid color-increase-contrast($msp-form-control-background, 20%) !important;
  85. }
  86. }
  87. .msp-slider {
  88. > div:first-child {
  89. position: absolute;
  90. top: 0;
  91. left: 18px;
  92. bottom: 0;
  93. right: 62px;
  94. display: grid;
  95. }
  96. > div:last-child {
  97. position: absolute;
  98. height: $row-height;
  99. line-height: $row-height;
  100. text-align: center;
  101. right: 0;
  102. width: 50px;
  103. top: 0;
  104. bottom: 0;
  105. }
  106. input[type=text] {
  107. padding-right: 6px;
  108. padding-left: 4px;
  109. font-size: 80%;
  110. text-align: right;
  111. }
  112. // input[type=range] {
  113. // width: 100%;
  114. // }
  115. }
  116. .msp-slider2 {
  117. > div:first-child {
  118. position: absolute;
  119. height: $row-height;
  120. line-height: $row-height;
  121. text-align: center;
  122. left: 0;
  123. width: 25px;
  124. top: 0;
  125. bottom: 0;
  126. font-size: 80%;
  127. }
  128. > div:nth-child(2) {
  129. position: absolute;
  130. top: 0;
  131. left: 35px;
  132. bottom: 0;
  133. right: 37px;
  134. display: grid;
  135. }
  136. > div:last-child {
  137. position: absolute;
  138. height: $row-height;
  139. line-height: $row-height;
  140. text-align: center;
  141. right: 0;
  142. width: 25px;
  143. top: 0;
  144. bottom: 0;
  145. font-size: 80%;
  146. }
  147. input[type=text] {
  148. padding-right: 4px;
  149. padding-left: 4px;
  150. font-size: 80%;
  151. text-align: center;
  152. }
  153. // input[type=range] {
  154. // width: 100%;
  155. // }
  156. }
  157. .msp-toggle-color-picker {
  158. button {
  159. border: $control-spacing solid $msp-form-control-background !important;
  160. margin: 0;
  161. text-align: center;
  162. padding-right: $control-spacing;
  163. padding-left: $control-spacing;
  164. &:hover {
  165. border-color: color-increase-contrast($msp-form-control-background, 5%) !important;
  166. border: none;
  167. outline-offset: -1px !important;
  168. outline: 1px solid color-increase-contrast($msp-form-control-background, 20%) !important;
  169. }
  170. }
  171. .msp-color-picker {
  172. position: absolute;
  173. z-index: 100000;
  174. background: $default-background;
  175. border-top: 1px solid $default-background;
  176. padding-bottom: $control-spacing / 2;
  177. width: 100%;
  178. // input[type=text] {
  179. // background: $msp-form-control-background !important;
  180. // }
  181. }
  182. }
  183. .msp-toggle-color-picker-above {
  184. .msp-color-picker {
  185. top: -2 * 32px - 16px - $control-spacing / 2;
  186. height: 2 * 32px + 16px + $control-spacing / 2;
  187. }
  188. }
  189. .msp-toggle-color-picker-below {
  190. .msp-color-picker {
  191. top: $row-height;
  192. height: 2 * 32px + 16px;
  193. }
  194. }
  195. .msp-control-offset {
  196. // border-left-width: $control-spacing / 2;
  197. // border-left-style: solid;
  198. // border-left-color: color-increase-contrast($default-background, 10%);
  199. // padding-left: 1px;
  200. padding-left: $control-spacing;
  201. }
  202. .msp-accent-offset {
  203. padding-left: 1px;
  204. margin-left: $control-spacing - 2;
  205. border-left: 2px solid $entity-color-Group;
  206. }
  207. .msp-control-group-wrapper {
  208. //border-left-width: $control-spacing / 2;
  209. //border-left-style: solid;
  210. //border-left-color: color-increase-contrast($default-background, 10%);
  211. margin-bottom: 0px;
  212. margin-top: 1px;
  213. }
  214. // TODO : get rid of the important
  215. .msp-control-group-header {
  216. background: $default-background;
  217. > button {
  218. padding-left: 4px; // $control-spacing / 2 !important;
  219. text-align: left;
  220. height: 24px !important; // 2 * $row-height / 3 !important;
  221. line-height: 24px !important; // 2 * $row-height / 3 !important;
  222. font-size: 85% !important;
  223. background: $default-background !important;
  224. color: color-lower-contrast($font-color, 15%);
  225. }
  226. .msp-icon {
  227. height: 24px !important;
  228. line-height: 24px !important;
  229. }
  230. > span {
  231. padding-left: $control-spacing / 2;
  232. line-height: 2 * $row-height / 3;
  233. font-size: 70%;
  234. background: $default-background;
  235. color: color-lower-contrast($font-color, 15%);
  236. }
  237. }
  238. .msp-control-current {
  239. background: $default-background;
  240. }
  241. .msp-control-group-footer {
  242. background: color-increase-contrast($default-background, 5%);
  243. height: $control-spacing / 2;
  244. font-size: 1px;
  245. margin-top: 1px;
  246. }
  247. .msp-control-subgroup {
  248. margin-top: 1px;
  249. .msp-control-row {
  250. margin-left: $control-spacing !important;
  251. > span {
  252. width: $control-label-width !important;
  253. }
  254. > div:nth-child(2) {
  255. left: $control-label-width !important;
  256. }
  257. }
  258. }
  259. .msp-control-group-expander {
  260. display: block;
  261. position: absolute;
  262. line-height: $row-height;
  263. padding: 0;
  264. left: 0;
  265. top: 0;
  266. width: $control-label-width + $control-spacing;
  267. text-align: left;
  268. background: transparent;
  269. .msp-icon {
  270. line-height: $row-height - 3;
  271. width: $row-height - 1;
  272. text-align: center;
  273. // display: inline-block;
  274. font-size: 100%;
  275. }
  276. }
  277. .msp-plugin-layout_controls {
  278. position: absolute;
  279. left: $control-spacing;
  280. top: $control-spacing;
  281. }
  282. .msp-plugin-layout_controls > button:first-child {
  283. margin-right: 6px;
  284. }
  285. .msp-empty-control {
  286. display: none;
  287. }
  288. .msp-control .msp-btn-block {
  289. margin-bottom: 0px;
  290. margin-top: 0px;
  291. }
  292. .msp-row-text {
  293. > div {
  294. line-height: $row-height;
  295. text-align: center;
  296. color: color-lower-contrast($font-color, 15%);
  297. }
  298. }
  299. .msp-help span {
  300. display: none;
  301. }
  302. .msp-help:hover span {
  303. display: inline-block;
  304. background: linear-gradient($default-background, change-color($default-background, $alpha: 0.8));
  305. }
  306. .msp-help-text {
  307. height: auto !important;
  308. > div {
  309. padding: ($control-spacing / 2) $control-spacing;
  310. text-align: left;
  311. color: color-lower-contrast($font-color, 15%);
  312. }
  313. }
  314. .msp-help-description {
  315. font-style: italic;
  316. }
  317. .msp-help-legend {
  318. padding-top: $control-spacing;
  319. }
  320. .msp-scale-legend {
  321. > div {
  322. width: 100%;
  323. height: $control-spacing * 3;
  324. > span {
  325. padding: $control-spacing / 2;
  326. color: white;
  327. font-weight: bold;
  328. background-color: rgba(0, 0, 0, 0.2);
  329. }
  330. }
  331. }
  332. .msp-table-legend {
  333. > div {
  334. // min-width: 60px;
  335. margin-right: $control-spacing / 2;
  336. display: inline-flex;
  337. .msp-table-legend-color {
  338. width: $control-spacing * 3;
  339. height: $control-spacing * 2;
  340. }
  341. .msp-table-legend-text {
  342. margin: 0 ($control-spacing / 2);
  343. }
  344. }
  345. }
  346. .msp-image-preview {
  347. position: relative;
  348. background: $default-background;
  349. margin-top: 1px;
  350. text-align: center;
  351. padding: $control-spacing;
  352. img {
  353. max-height: 180px;
  354. max-width: 100%;
  355. display: 'block';
  356. background-color: $default-background;
  357. background-image: linear-gradient(45deg, lightgrey 25%, transparent 25%, transparent 75%, lightgrey 75%, lightgrey),
  358. linear-gradient(45deg, lightgrey 25%, transparent 25%, transparent 75%, lightgrey 75%, lightgrey);
  359. background-size: 30px 30px;
  360. background-position: 0 0, 15px 15px;
  361. }
  362. > span {
  363. margin-top: 6px;
  364. display: block;
  365. text-align: center;
  366. font-size: 80%;
  367. }
  368. }