main.css 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701
  1. :root {
  2. color-scheme: light dark;
  3. }
  4. body {
  5. font-family: Helvetica, Arial, sans-serif;
  6. font-size: 14px;
  7. margin: 0;
  8. overflow: hidden;
  9. }
  10. hr {
  11. border: 0;
  12. border-top: 1px solid #ccc;
  13. }
  14. button {
  15. position: relative;
  16. }
  17. input {
  18. vertical-align: middle;
  19. }
  20. input[type="color"]::-webkit-color-swatch-wrapper {
  21. padding: 0;
  22. }
  23. input[type="color"]::-webkit-color-swatch {
  24. border: none;
  25. }
  26. textarea {
  27. tab-size: 4;
  28. white-space: pre;
  29. word-wrap: normal;
  30. vertical-align: middle;
  31. }
  32. textarea.success {
  33. border-color: #8b8 !important;
  34. }
  35. textarea.fail {
  36. border-color: #f00 !important;
  37. background-color: rgba(255,0,0,0.05);
  38. }
  39. textarea, input { outline: none; } /* osx */
  40. .Panel {
  41. -moz-user-select: none;
  42. -webkit-user-select: none;
  43. -ms-user-select: none;
  44. /* No support for these yet */
  45. -o-user-select: none;
  46. user-select: none;
  47. }
  48. .TabbedPanel {
  49. -moz-user-select: none;
  50. -webkit-user-select: none;
  51. -ms-user-select: none;
  52. /* No support for these yet */
  53. -o-user-select: none;
  54. user-select: none;
  55. position: relative;
  56. display: block;
  57. width: 100%;
  58. }
  59. .TabbedPanel .Tabs {
  60. position: relative;
  61. display: block;
  62. width: 100%;
  63. }
  64. .TabbedPanel .Tabs .Tab {
  65. padding: 10px;
  66. vertical-align: middle;
  67. text-transform: uppercase;
  68. }
  69. .TabbedPanel .Tabs .Panels {
  70. position: relative;
  71. display: block;
  72. width: 100%;
  73. height: 100%;
  74. }
  75. /* Listbox */
  76. .Listbox {
  77. color: #444;
  78. background-color: #fff;
  79. padding: 0;
  80. width: 100%;
  81. min-height: 140px;
  82. font-size: 12px;
  83. cursor: default;
  84. overflow: auto;
  85. }
  86. .Listbox .ListboxItem {
  87. padding: 6px;
  88. color: #666;
  89. white-space: nowrap;
  90. }
  91. .Listbox .ListboxItem.active {
  92. background-color: rgba(0, 0, 0, 0.04);
  93. }
  94. /* CodeMirror */
  95. .CodeMirror {
  96. position: absolute !important;
  97. top: 37px;
  98. width: 100% !important;
  99. height: calc(100% - 37px) !important;
  100. }
  101. .CodeMirror .errorLine {
  102. background: rgba(255,0,0,0.25);
  103. }
  104. .CodeMirror .esprima-error {
  105. color: #f00;
  106. text-align: right;
  107. padding: 0 20px;
  108. }
  109. /* outliner */
  110. #outliner .opener {
  111. display: inline-block;
  112. width: 14px;
  113. height: 14px;
  114. margin: 0px 4px;
  115. vertical-align: top;
  116. text-align: center;
  117. }
  118. #outliner .opener.open:after {
  119. content: '−';
  120. }
  121. #outliner .opener.closed:after {
  122. content: '+';
  123. }
  124. #outliner .option {
  125. border: 1px solid transparent;
  126. }
  127. #outliner .option.drag {
  128. border: 1px dashed #999;
  129. }
  130. #outliner .option.dragTop {
  131. border-top: 1px dashed #999;
  132. }
  133. #outliner .option.dragBottom {
  134. border-bottom: 1px dashed #999;
  135. }
  136. #outliner .type {
  137. display: inline-block;
  138. width: 14px;
  139. height: 14px;
  140. color: #ddd;
  141. text-align: center;
  142. }
  143. #outliner .type:after {
  144. content: '●';
  145. }
  146. /* */
  147. #outliner .Scene {
  148. color: #8888dd;
  149. }
  150. #outliner .Camera {
  151. color: #dd8888;
  152. }
  153. #outliner .Light {
  154. color: #dddd88;
  155. }
  156. /* */
  157. #outliner .Object3D {
  158. color: #aaaaee;
  159. }
  160. #outliner .Mesh {
  161. color: #8888ee;
  162. }
  163. #outliner .Line {
  164. color: #88ee88;
  165. }
  166. #outliner .LineSegments {
  167. color: #88ee88;
  168. }
  169. #outliner .Points {
  170. color: #ee8888;
  171. }
  172. /* */
  173. #outliner .Geometry {
  174. color: #aaeeaa;
  175. }
  176. #outliner .Material {
  177. color: #eeaaee;
  178. }
  179. /* */
  180. #outliner .Script:after {
  181. content: '{...}' /* ❮/❯ */
  182. }
  183. /* */
  184. button {
  185. color: #555;
  186. background-color: #ddd;
  187. border: 0px;
  188. margin: 0px; /* GNOME Web */
  189. padding: 5px 8px;
  190. text-transform: uppercase;
  191. cursor: pointer;
  192. outline: none;
  193. }
  194. button:hover {
  195. background-color: #fff;
  196. }
  197. button.selected {
  198. background-color: #fff;
  199. }
  200. input, textarea {
  201. border: 1px solid transparent;
  202. color: #444;
  203. }
  204. input.Number {
  205. color: #08f!important;
  206. font-size: 12px;
  207. border: 0px;
  208. padding: 2px;
  209. }
  210. select {
  211. color: #666;
  212. background-color: #ddd;
  213. border: 0px;
  214. text-transform: uppercase;
  215. cursor: pointer;
  216. outline: none;
  217. }
  218. select:hover {
  219. background-color: #fff;
  220. }
  221. /* UI */
  222. #resizer {
  223. position: absolute;
  224. top: 32px;
  225. right: 295px;
  226. width: 5px;
  227. bottom: 0px;
  228. /* background-color: rgba(255,0,0,0.5); */
  229. cursor: col-resize;
  230. }
  231. #viewport {
  232. position: absolute;
  233. top: 32px;
  234. left: 0;
  235. right: 300px;
  236. bottom: 0;
  237. }
  238. #viewport #info {
  239. text-shadow: 1px 1px 0 rgba(0,0,0,0.25);
  240. pointer-events: none;
  241. }
  242. #script {
  243. position: absolute;
  244. top: 32px;
  245. left: 0;
  246. right: 300px;
  247. bottom: 0;
  248. opacity: 0.9;
  249. }
  250. #player {
  251. position: absolute;
  252. top: 32px;
  253. left: 0;
  254. right: 300px;
  255. bottom: 0;
  256. }
  257. #menubar {
  258. position: absolute;
  259. width: 100%;
  260. height: 32px;
  261. background: #eee;
  262. padding: 0;
  263. margin: 0;
  264. right: 0;
  265. top: 0;
  266. }
  267. #menubar .menu {
  268. float: left;
  269. cursor: pointer;
  270. padding-right: 8px;
  271. }
  272. #menubar .menu.right {
  273. float: right;
  274. cursor: auto;
  275. padding-right: 0;
  276. text-align: right;
  277. }
  278. #menubar .menu .title {
  279. display: inline-block;
  280. color: #888;
  281. margin: 0;
  282. padding: 8px;
  283. line-height: 16px;
  284. }
  285. #menubar .menu .options {
  286. position: fixed;
  287. display: none;
  288. padding: 5px 0;
  289. background: #eee;
  290. width: 150px;
  291. max-height: calc(100% - 80px);
  292. overflow: auto;
  293. }
  294. #menubar .menu:hover .options {
  295. display: block;
  296. }
  297. #menubar .menu .options hr {
  298. border-color: #ddd;
  299. }
  300. #menubar .menu .options .option {
  301. color: #666;
  302. background-color: transparent;
  303. padding: 5px 10px;
  304. margin: 0 !important;
  305. }
  306. #menubar .menu .options .option:hover {
  307. color: #fff;
  308. background-color: #08f;
  309. }
  310. #menubar .menu .options .option:active {
  311. color: #666;
  312. background: transparent;
  313. }
  314. #menubar .menu .options .inactive {
  315. color: #bbb;
  316. background-color: transparent;
  317. padding: 5px 10px;
  318. margin: 0 !important;
  319. }
  320. #sidebar {
  321. position: absolute;
  322. right: 0;
  323. top: 32px;
  324. bottom: 0;
  325. width: 300px;
  326. background: #eee;
  327. overflow: auto;
  328. }
  329. #sidebar .Panel {
  330. color: #888;
  331. padding: 10px;
  332. border-top: 1px solid #ccc;
  333. }
  334. #sidebar .Panel.collapsed {
  335. margin-bottom: 0;
  336. }
  337. #sidebar .Row {
  338. min-height: 20px;
  339. margin-bottom: 10px;
  340. }
  341. #sidebar canvas {
  342. vertical-align: middle;
  343. }
  344. #tabs {
  345. background-color: #ddd;
  346. border-top: 1px solid #ccc;
  347. }
  348. #tabs span {
  349. color: #aaa;
  350. border-right: 1px solid #ccc;
  351. padding: 10px;
  352. }
  353. #tabs span.selected {
  354. color: #888;
  355. background-color: #eee;
  356. }
  357. #toolbar {
  358. position: absolute;
  359. left: 10px;
  360. top: 42px;
  361. width: 32px;
  362. background: #eee;
  363. text-align: center;
  364. }
  365. #toolbar button, #toolbar input {
  366. height: 32px;
  367. }
  368. #toolbar button img {
  369. width: 16px;
  370. opacity: 0.5;
  371. }
  372. .Outliner {
  373. color: #444;
  374. background-color: #fff;
  375. padding: 0;
  376. width: 100%;
  377. height: 140px;
  378. font-size: 12px;
  379. cursor: default;
  380. overflow: auto;
  381. resize: vertical;
  382. outline: none !important;
  383. }
  384. .Outliner .option {
  385. padding: 4px;
  386. color: #666;
  387. white-space: nowrap;
  388. }
  389. .Outliner .option:hover {
  390. background-color: rgba(0,0,0,0.02);
  391. }
  392. .Outliner .option.active {
  393. background-color: rgba(0,0,0,0.04);
  394. }
  395. .TabbedPanel .Tabs {
  396. background-color: #ddd;
  397. border-top: 1px solid #ccc;
  398. }
  399. .TabbedPanel .Tab {
  400. color: #aaa;
  401. border-right: 1px solid #ccc;
  402. }
  403. .TabbedPanel .Tab.selected {
  404. color: #888;
  405. background-color: #eee;
  406. }
  407. .Listbox {
  408. color: #444;
  409. background-color: #fff;
  410. }
  411. .Panel {
  412. color: #888;
  413. }
  414. /* */
  415. @media all and ( max-width: 600px ) {
  416. #resizer {
  417. display: none;
  418. }
  419. #menubar .menu .options {
  420. max-height: calc(100% - 372px);
  421. }
  422. #menubar .menu.right {
  423. display: none;
  424. }
  425. #viewport {
  426. left: 0;
  427. right: 0;
  428. top: 32px;
  429. height: calc(100% - 352px);
  430. }
  431. #script {
  432. left: 0;
  433. right: 0;
  434. top: 32px;
  435. height: calc(100% - 352px);
  436. }
  437. #player {
  438. left: 0;
  439. right: 0;
  440. top: 32px;
  441. height: calc(100% - 352px);
  442. }
  443. #sidebar {
  444. left: 0;
  445. width: 100%;
  446. top: calc(100% - 320px);
  447. bottom: 0;
  448. }
  449. }
  450. /* DARK MODE */
  451. @media ( prefers-color-scheme: dark ) {
  452. button {
  453. color: #aaa;
  454. background-color: #222;
  455. }
  456. button:hover {
  457. color: #ccc;
  458. background-color: #444;
  459. }
  460. button.selected {
  461. color: #fff;
  462. background-color: #08f;
  463. }
  464. input, textarea {
  465. background-color: #222;
  466. border: 1px solid transparent;
  467. color: #888;
  468. }
  469. select {
  470. color: #aaa;
  471. background-color: #222;
  472. }
  473. select:hover {
  474. color: #ccc;
  475. background-color: #444;
  476. }
  477. /* UI */
  478. #menubar {
  479. background: #111;
  480. }
  481. #menubar .menu .options {
  482. background: #111;
  483. }
  484. #menubar .menu .options hr {
  485. border-color: #222;
  486. }
  487. #menubar .menu .options .option {
  488. color: #888;
  489. }
  490. #menubar .menu .options .inactive {
  491. color: #444;
  492. }
  493. #sidebar {
  494. background-color: #111;
  495. }
  496. #sidebar .Panel {
  497. border-top: 1px solid #222;
  498. }
  499. #sidebar .Panel.Material canvas {
  500. border: solid 1px #5A5A5A;
  501. }
  502. #tabs {
  503. background-color: #1b1b1b;
  504. border-top: 1px solid #222;
  505. }
  506. #tabs span {
  507. color: #555;
  508. border-right: 1px solid #222;
  509. }
  510. #tabs span.selected {
  511. background-color: #111;
  512. }
  513. #toolbar {
  514. background-color: #111;
  515. }
  516. #toolbar img {
  517. filter: invert(1);
  518. }
  519. .Outliner {
  520. color: #888;
  521. background: #222;
  522. }
  523. .Outliner .option:hover {
  524. background-color: rgba(21,60,94,0.5);
  525. }
  526. .Outliner .option.active {
  527. background-color: rgba(21,60,94,1);
  528. }
  529. .TabbedPanel .Tabs {
  530. background-color: #1b1b1b;
  531. border-top: 1px solid #222;
  532. }
  533. .TabbedPanel .Tab {
  534. color: #555;
  535. border-right: 1px solid #222;
  536. }
  537. .TabbedPanel .Tab.selected {
  538. color: #888;
  539. background-color: #111;
  540. }
  541. .Listbox {
  542. color: #888;
  543. background: #222;
  544. }
  545. .Listbox .ListboxItem:hover {
  546. background-color: rgba(21,60,94,0.5);
  547. }
  548. .Listbox .ListboxItem.active {
  549. background-color: rgba(21,60,94,1);
  550. }
  551. }