diagram.scss 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. .srd-node {
  2. width: 200px;
  3. }
  4. .srd-node--selected {
  5. .input-port-border {
  6. border-color: rgb(0, 192, 255) !important;
  7. }
  8. .output-port-border {
  9. border-color: rgb(0, 192, 255) !important;
  10. }
  11. }
  12. .srd-default-link--path-selected {
  13. animation: 0s !important;
  14. }
  15. .srd-port {
  16. grid-column: 1;
  17. grid-row: 1;
  18. background: #2796B2;
  19. border-radius: 10px;
  20. transform: scale(1);
  21. &.connected {
  22. background: #CAB422;
  23. }
  24. &:hover {
  25. background: greenyellow !important;
  26. }
  27. }
  28. .diagramBlock {
  29. background: white;
  30. width: 100%;
  31. border: 4px solid black;
  32. border-radius: 20px;
  33. display: grid;
  34. grid-template-rows: 30px auto;
  35. grid-template-columns: 50% 50%;
  36. &.input {
  37. background: #40866E;
  38. color:white;
  39. .value {
  40. grid-row: 2;
  41. }
  42. .outputs {
  43. transform: translateY(5px);
  44. }
  45. }
  46. &.attribute {
  47. background: #40866E;
  48. }
  49. &.output {
  50. background: blue;
  51. color:white;
  52. .inputs {
  53. color:white;
  54. }
  55. }
  56. .header {
  57. grid-row: 1;
  58. grid-column: 1 / span 2;
  59. border: 4px solid black;
  60. border-top-right-radius: 16px;
  61. border-top-left-radius: 16px;
  62. font-size: 16px;
  63. text-align: center;
  64. margin: -1px;
  65. white-space: nowrap;
  66. text-overflow: ellipsis;
  67. overflow: hidden;
  68. background: black;
  69. color: white;
  70. }
  71. .value {
  72. grid-row: 3;
  73. grid-column: 1 / span 2;
  74. height: 34px;
  75. text-align: center;
  76. font-size: 18px;
  77. font-weight: bold;
  78. margin: 0 10px;
  79. .value-text {
  80. white-space: nowrap;
  81. text-overflow: ellipsis;
  82. overflow: hidden;
  83. }
  84. }
  85. .preview {
  86. border-bottom-left-radius: 16px;
  87. border: black 4px solid;
  88. border-left: 0px;
  89. border-bottom: 0px;
  90. }
  91. .inputs {
  92. grid-row: 2;
  93. grid-column: 1;
  94. padding-bottom: 8px;
  95. .input-port {
  96. display: grid;
  97. grid-template-columns: 10px calc(100% - 10px);
  98. grid-template-rows: 100%;
  99. .input-port-plug {
  100. grid-column: 1;
  101. grid-row: 1;
  102. display: grid;
  103. align-content: center;
  104. margin-left: -8px;
  105. position: relative;
  106. &:hover {
  107. .input-port-connection {
  108. background: greenyellow !important;
  109. }
  110. }
  111. .input-port-connection {
  112. pointer-events: none;
  113. grid-column: 1;
  114. grid-row: 1;
  115. background: #2796B2;
  116. border-radius: 10px;
  117. }
  118. .input-port-type {
  119. width: 15px;
  120. pointer-events: none;
  121. grid-column: 1;
  122. grid-row: 1;
  123. display: grid;
  124. align-items: center;
  125. justify-items: center;
  126. transform: scale(1);
  127. img {
  128. width: 12px;
  129. }
  130. }
  131. .input-port-border {
  132. pointer-events: none;
  133. grid-column: 1;
  134. grid-row: 1;
  135. border: 4px solid black;
  136. width: 4px;
  137. height: 7px;
  138. border-right: 0;
  139. position: absolute;
  140. border-bottom-left-radius: 10px;
  141. border-top-left-radius: 10px;
  142. transform: translateX(-2px) scale(1.2);
  143. }
  144. }
  145. .input-port-label {
  146. grid-column: 2;
  147. grid-row: 1;
  148. margin-bottom: 2px;
  149. overflow: hidden;
  150. white-space: nowrap;
  151. text-overflow: ellipsis;
  152. }
  153. }
  154. }
  155. .outputs {
  156. grid-row: 2;
  157. grid-column: 2;
  158. padding-bottom: 8px;
  159. .output-port {
  160. display: grid;
  161. grid-template-columns: calc(100% - 10px) 10px;
  162. grid-template-rows: 100%;
  163. .output-port-plug {
  164. grid-column: 2;
  165. grid-row: 1;
  166. display: grid;
  167. align-content: center;
  168. position: relative;
  169. margin-left: 3px;
  170. &:hover {
  171. .output-port-connection {
  172. background: greenyellow !important;
  173. }
  174. }
  175. .output-port-connection {
  176. pointer-events: none;
  177. grid-column: 1;
  178. grid-row: 1;
  179. background: #2796B2;
  180. border-radius: 10px;
  181. }
  182. .output-port-type {
  183. pointer-events: none;
  184. grid-column: 1;
  185. grid-row: 1;
  186. display: grid;
  187. align-items: center;
  188. justify-items: center;
  189. transform: scale(1);
  190. img {
  191. width: 12px;
  192. }
  193. }
  194. .output-port-border {
  195. pointer-events: none;
  196. grid-column: 1;
  197. grid-row: 1;
  198. border: 4px solid black;
  199. width: 4px;
  200. border-left: 0;
  201. border-left: 0;
  202. transform: translateX(9px) scale(1.2);
  203. border-bottom-right-radius: 10px;
  204. border-top-right-radius: 10px;
  205. }
  206. }
  207. .output-port-label {
  208. text-align: right;
  209. grid-column: 1;
  210. grid-row: 1;
  211. margin-bottom: 2px;
  212. overflow: hidden;
  213. white-space: nowrap;
  214. text-overflow: ellipsis;
  215. }
  216. }
  217. }
  218. &.texture-block {
  219. display: grid;
  220. grid-template-rows: 30px auto 1fr;
  221. grid-template-columns: calc(100% - 60px) 60px;
  222. .inputs {
  223. grid-column: 1;
  224. grid-row: 2;
  225. }
  226. .outputs {
  227. grid-column: 2;
  228. grid-row: 2 / span 2;
  229. }
  230. .textureLine {
  231. height: 140px;
  232. grid-column: 1;
  233. grid-row: 3;
  234. canvas {
  235. width: 100%;
  236. height: 100%;
  237. }
  238. }
  239. }
  240. }