main.css 9.1 KB

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