main.css 9.2 KB

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