styles.scss 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439
  1. @import "./theme.css";
  2. @import "./_variables";
  3. :root {
  4. --sat: env(safe-area-inset-top);
  5. --sab: env(safe-area-inset-bottom);
  6. --sal: env(safe-area-inset-left);
  7. --sar: env(safe-area-inset-right);
  8. }
  9. body {
  10. margin: 0;
  11. --ui-font: BlinkMacSystemFont, -apple-system, Segoe UI, Roboto, Helvetica,
  12. Arial, sans-serif;
  13. font-family: var(--ui-font);
  14. color: var(--text-color-primary);
  15. -webkit-text-size-adjust: 100%;
  16. user-select: none;
  17. }
  18. [contenteditable] {
  19. user-select: auto;
  20. cursor: text;
  21. }
  22. a {
  23. font-weight: 500;
  24. text-decoration: none;
  25. color: #1c7ed6; /* OC Blue 7 */
  26. &:hover {
  27. text-decoration: underline;
  28. }
  29. }
  30. canvas {
  31. touch-action: none;
  32. user-select: none;
  33. // following props improve blurriness at certain devicePixelRatios.
  34. // AFAIK it doesn't affect export (in fact, export seems sharp either way).
  35. image-rendering: pixelated; // chromium
  36. // NOTE: must be declared *after* the above
  37. image-rendering: -moz-crisp-edges; // FF
  38. }
  39. .container {
  40. display: flex;
  41. position: fixed;
  42. top: 0;
  43. bottom: 0;
  44. left: 0;
  45. right: 0;
  46. }
  47. .panelRow {
  48. display: flex;
  49. justify-content: space-between;
  50. }
  51. .panelColumn {
  52. display: flex;
  53. flex-direction: column;
  54. h3,
  55. legend,
  56. .control-label {
  57. margin-top: 0.333rem;
  58. margin-bottom: 0.333rem;
  59. font-size: 0.75rem;
  60. color: var(--text-color-primary);
  61. font-weight: bold;
  62. display: block;
  63. }
  64. .control-label input {
  65. display: block;
  66. width: 100%;
  67. }
  68. h3:first-child,
  69. legend:first-child,
  70. .control-label:first-child {
  71. margin-top: 0;
  72. }
  73. legend {
  74. padding: 0;
  75. }
  76. .buttonList {
  77. flex-wrap: wrap;
  78. label {
  79. margin-right: 0.25rem;
  80. font-size: 0.75rem;
  81. display: inline-block;
  82. }
  83. input[type="radio"] {
  84. opacity: 0;
  85. position: absolute;
  86. pointer-events: none;
  87. }
  88. .ToolIcon {
  89. margin: 0 5px;
  90. }
  91. .ToolIcon__icon {
  92. width: 28px;
  93. height: 28px;
  94. }
  95. }
  96. fieldset {
  97. margin: 0;
  98. margin-top: 0.333rem;
  99. padding: 0;
  100. border: none;
  101. }
  102. }
  103. .divider {
  104. width: 1px;
  105. background-color: #e9ecef;
  106. margin: 1px;
  107. }
  108. .buttonList label:focus-within,
  109. input:focus {
  110. outline: transparent;
  111. box-shadow: 0 0 0 2px #a5d8ff;
  112. }
  113. button,
  114. .buttonList label {
  115. user-select: none;
  116. background-color: #e9ecef;
  117. border: 0;
  118. border-radius: 4px;
  119. margin: 0.125rem 0;
  120. padding: 0.25rem;
  121. white-space: nowrap;
  122. cursor: pointer;
  123. &:focus {
  124. outline: transparent;
  125. box-shadow: 0 0 0 2px #a5d8ff;
  126. }
  127. &:hover {
  128. background-color: #ced4da;
  129. }
  130. &:active {
  131. background-color: #adb5bd;
  132. }
  133. &:disabled {
  134. cursor: not-allowed;
  135. }
  136. }
  137. .active,
  138. .buttonList label.active {
  139. background-color: #ced4da;
  140. &:hover {
  141. background-color: #ced4da;
  142. }
  143. &:active {
  144. background-color: #adb5bd;
  145. }
  146. }
  147. .App-bottom-bar {
  148. position: absolute;
  149. top: 0;
  150. bottom: 0;
  151. left: 0;
  152. right: 0;
  153. --bar-padding: calc(4 * var(--space-factor));
  154. padding-top: #{"max(var(--bar-padding), var(--sat))"};
  155. padding-left: var(--sal);
  156. padding-right: var(--sar);
  157. padding-bottom: var(--sab);
  158. z-index: 4;
  159. display: flex;
  160. align-items: flex-end;
  161. pointer-events: none;
  162. > .Island {
  163. width: 100%;
  164. max-width: 100%;
  165. min-width: 100%;
  166. box-sizing: border-box;
  167. max-height: 100%;
  168. display: flex;
  169. flex-direction: column;
  170. pointer-events: initial;
  171. }
  172. }
  173. .App-toolbar {
  174. width: 100%;
  175. box-sizing: border-box;
  176. }
  177. .App-toolbar-content {
  178. display: flex;
  179. align-items: center;
  180. justify-content: space-between;
  181. }
  182. .App-mobile-menu {
  183. width: 100%;
  184. overflow-x: visible;
  185. overflow-y: auto;
  186. box-sizing: border-box;
  187. margin-bottom: var(--bar-padding);
  188. }
  189. .App-menu {
  190. display: grid;
  191. }
  192. .App-menu_top {
  193. grid-template-columns: 1fr auto 1fr;
  194. grid-gap: 4px;
  195. align-items: flex-start;
  196. cursor: default;
  197. pointer-events: none !important;
  198. }
  199. .App-menu_top > * {
  200. pointer-events: all;
  201. }
  202. .App-menu_top > *:first-child {
  203. justify-self: flex-start;
  204. }
  205. .App-menu_top > *:last-child {
  206. justify-self: flex-end;
  207. }
  208. .App-menu_bottom {
  209. position: fixed;
  210. bottom: 0;
  211. grid-template-columns: 1fr auto 1fr;
  212. grid-gap: 4px;
  213. align-items: flex-start;
  214. cursor: default;
  215. pointer-events: none !important;
  216. }
  217. .App-menu_bottom > * {
  218. pointer-events: all;
  219. }
  220. .App-menu_bottom > *:first-child {
  221. justify-self: flex-start;
  222. }
  223. .App-menu_bottom > *:last-child {
  224. justify-self: flex-end;
  225. }
  226. .App-menu_left {
  227. grid-template-rows: 1fr auto 1fr;
  228. height: 100%;
  229. }
  230. .App-menu_right {
  231. grid-template-rows: 1fr;
  232. height: 100%;
  233. }
  234. .App-menu__left {
  235. overflow-y: auto;
  236. max-height: calc(100vh - 236px);
  237. }
  238. .ErrorSplash {
  239. min-height: 100vh;
  240. padding: 20px 0;
  241. overflow: auto;
  242. display: flex;
  243. align-items: center;
  244. justify-content: center;
  245. user-select: text;
  246. .ErrorSplash-messageContainer {
  247. display: flex;
  248. flex-direction: column;
  249. align-items: center;
  250. justify-content: center;
  251. padding: 40px;
  252. background-color: #fff5f5;
  253. border: 3px solid #c92a2a;
  254. }
  255. .ErrorSplash-paragraph {
  256. margin: 15px 0;
  257. max-width: 600px;
  258. &.align-center {
  259. text-align: center;
  260. }
  261. }
  262. .bigger,
  263. .bigger button {
  264. font-size: 1.1em;
  265. }
  266. .smaller,
  267. .smaller button {
  268. font-size: 0.9em;
  269. }
  270. .ErrorSplash-details {
  271. display: flex;
  272. flex-direction: column;
  273. align-items: flex-start;
  274. textarea {
  275. width: 100%;
  276. margin: 10px 0;
  277. font-family: "Cascadia";
  278. font-size: 0.8em;
  279. }
  280. }
  281. }
  282. .dropdown-select {
  283. height: 1.5rem;
  284. padding: 0;
  285. padding-inline-start: 0.5rem;
  286. padding-inline-end: 1.5rem;
  287. background-color: #e9ecef;
  288. border-radius: var(--space-factor);
  289. border: 1px solid #ced4da;
  290. font-size: 0.8rem;
  291. outline: none;
  292. appearance: none;
  293. background-image: url("https://free-use.s3-us-west-2.amazonaws.com/up-sort.svg");
  294. background-repeat: no-repeat;
  295. background-position: right 0.7rem top 50%, 0 0;
  296. :root[dir="rtl"] & {
  297. background-position: left 0.7rem top 50%, 0 0;
  298. }
  299. background-size: 0.65em auto, 100%;
  300. &:focus {
  301. box-shadow: 0 0 0 2px #a5d8ff;
  302. }
  303. &:hover {
  304. background-color: #ced4da;
  305. }
  306. &:active {
  307. background-color: #ced4da;
  308. }
  309. &.dropdown-select--floating {
  310. position: absolute;
  311. margin: 0.5em;
  312. }
  313. }
  314. .dropdown-select__language.dropdown-select--floating {
  315. bottom: 10px;
  316. :root[dir="ltr"] & {
  317. right: 10px;
  318. }
  319. :root[dir="rtl"] & {
  320. left: 10px;
  321. }
  322. }
  323. .visually-hidden {
  324. position: absolute !important;
  325. height: 1px;
  326. width: 1px;
  327. overflow: hidden;
  328. clip: rect(1px 1px 1px 1px); /* IE6, IE7 */
  329. clip: rect(1px, 1px, 1px, 1px);
  330. white-space: nowrap; /* added line */
  331. }
  332. .zIndexButton {
  333. margin: 0 5px;
  334. padding: 5px;
  335. display: inline-flex;
  336. align-items: center;
  337. justify-content: center;
  338. svg {
  339. width: 18px;
  340. height: 18px;
  341. }
  342. }
  343. .scroll-back-to-content {
  344. position: fixed;
  345. left: 50%;
  346. bottom: 30px;
  347. transform: translateX(-50%);
  348. padding: 10px 20px;
  349. }
  350. @media #{$media-query} {
  351. aside {
  352. display: none;
  353. }
  354. .scroll-back-to-content {
  355. bottom: 80px;
  356. bottom: calc(80px + var(--sab));
  357. z-index: -1;
  358. }
  359. }
  360. .rtl-mirror {
  361. :root[dir="rtl"] & {
  362. transform: scaleX(-1);
  363. }
  364. }
  365. .github-corner {
  366. position: absolute;
  367. top: 0;
  368. :root[dir="ltr"] & {
  369. right: 0;
  370. }
  371. :root[dir="rtl"] & {
  372. left: 0;
  373. }
  374. }