main.css 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717
  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. }
  31. textarea.success {
  32. border-color: #8b8 !important;
  33. }
  34. textarea.fail {
  35. border-color: #f00 !important;
  36. background-color: rgba(255,0,0,0.05);
  37. }
  38. textarea, input { outline: none; } /* osx */
  39. .Panel {
  40. -moz-user-select: none;
  41. -webkit-user-select: none;
  42. -ms-user-select: none;
  43. /* No support for these yet */
  44. -o-user-select: none;
  45. user-select: none;
  46. }
  47. .TabbedPanel {
  48. -moz-user-select: none;
  49. -webkit-user-select: none;
  50. -ms-user-select: none;
  51. /* No support for these yet */
  52. -o-user-select: none;
  53. user-select: none;
  54. position: relative;
  55. display: block;
  56. width: 100%;
  57. min-width: 335px;
  58. }
  59. .TabbedPanel .Tabs {
  60. position: relative;
  61. display: block;
  62. width: 100%;
  63. }
  64. .TabbedPanel .Tabs .Tab {
  65. padding: 10px 9px;
  66. text-transform: uppercase;
  67. }
  68. .TabbedPanel .Panels {
  69. position: relative;
  70. display: block;
  71. width: 100%;
  72. }
  73. /* Listbox */
  74. .Listbox {
  75. color: #444;
  76. background-color: #fff;
  77. padding: 0;
  78. width: 100%;
  79. min-height: 180px;
  80. font-size: 12px;
  81. cursor: default;
  82. overflow: auto;
  83. }
  84. .Listbox .ListboxItem {
  85. padding: 6px;
  86. color: #666;
  87. white-space: nowrap;
  88. }
  89. .Listbox .ListboxItem.active {
  90. background-color: rgba(0, 0, 0, 0.04);
  91. }
  92. /* CodeMirror */
  93. .CodeMirror {
  94. position: absolute !important;
  95. top: 37px;
  96. width: 100% !important;
  97. height: calc(100% - 37px) !important;
  98. }
  99. .CodeMirror .errorLine {
  100. background: rgba(255,0,0,0.25);
  101. }
  102. .CodeMirror .esprima-error {
  103. color: #f00;
  104. text-align: right;
  105. padding: 0 20px;
  106. }
  107. /* outliner */
  108. #outliner .opener {
  109. display: inline-block;
  110. width: 14px;
  111. height: 14px;
  112. margin: 0px 4px;
  113. vertical-align: top;
  114. text-align: center;
  115. }
  116. #outliner .opener.open:after {
  117. content: '−';
  118. }
  119. #outliner .opener.closed:after {
  120. content: '+';
  121. }
  122. #outliner .option {
  123. border: 1px solid transparent;
  124. }
  125. #outliner .option.drag {
  126. border: 1px dashed #999;
  127. }
  128. #outliner .option.dragTop {
  129. border-top: 1px dashed #999;
  130. }
  131. #outliner .option.dragBottom {
  132. border-bottom: 1px dashed #999;
  133. }
  134. #outliner .type {
  135. display: inline-block;
  136. width: 14px;
  137. height: 14px;
  138. color: #ddd;
  139. text-align: center;
  140. }
  141. #outliner .type:after {
  142. content: '●';
  143. }
  144. /* */
  145. #outliner .Scene {
  146. color: #8888dd;
  147. }
  148. #outliner .Camera {
  149. color: #dd8888;
  150. }
  151. #outliner .Light {
  152. color: #dddd88;
  153. }
  154. /* */
  155. #outliner .Object3D {
  156. color: #aaaaee;
  157. }
  158. #outliner .Mesh {
  159. color: #8888ee;
  160. }
  161. #outliner .Line {
  162. color: #88ee88;
  163. }
  164. #outliner .LineSegments {
  165. color: #88ee88;
  166. }
  167. #outliner .Points {
  168. color: #ee8888;
  169. }
  170. /* */
  171. #outliner .Geometry {
  172. color: #aaeeaa;
  173. }
  174. #outliner .Material {
  175. color: #eeaaee;
  176. }
  177. /* */
  178. #outliner .Script:after {
  179. content: '◎'
  180. }
  181. /* */
  182. button {
  183. color: #555;
  184. background-color: #ddd;
  185. border: 0px;
  186. margin: 0px; /* GNOME Web */
  187. padding: 5px 8px;
  188. font-size: 12px;
  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: 345px;
  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: 350px;
  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: 350px;
  246. bottom: 0;
  247. opacity: 0.9;
  248. }
  249. #player {
  250. position: absolute;
  251. top: 32px;
  252. left: 0;
  253. right: 350px;
  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. /* VisionOS */
  297. #menubar .menu:active .options {
  298. display: block;
  299. }
  300. #menubar .menu .options hr {
  301. border-color: #ddd;
  302. }
  303. #menubar .menu .options .option {
  304. color: #666;
  305. background-color: transparent;
  306. padding: 5px 10px;
  307. margin: 0 !important;
  308. }
  309. #menubar .menu .options .option:hover {
  310. color: #fff;
  311. background-color: #08f;
  312. }
  313. #menubar .menu .options .option:active {
  314. color: #666;
  315. background: transparent;
  316. }
  317. #menubar .menu .options .inactive {
  318. color: #bbb;
  319. background-color: transparent;
  320. padding: 5px 10px;
  321. margin: 0 !important;
  322. }
  323. #sidebar {
  324. position: absolute;
  325. right: 0;
  326. top: 32px;
  327. bottom: 0;
  328. width: 350px;
  329. background: #eee;
  330. overflow: auto;
  331. }
  332. #sidebar .Panel {
  333. color: #888;
  334. padding: 10px;
  335. border-top: 1px solid #ccc;
  336. }
  337. #sidebar .Panel.collapsed {
  338. margin-bottom: 0;
  339. }
  340. #sidebar .Row {
  341. display: flex;
  342. align-items: center;
  343. min-height: 24px;
  344. margin-bottom: 10px;
  345. }
  346. #sidebar .Row .Label {
  347. width: 120px;
  348. }
  349. #tabs {
  350. background-color: #ddd;
  351. border-top: 1px solid #ccc;
  352. }
  353. #tabs span {
  354. color: #aaa;
  355. border-right: 1px solid #ccc;
  356. padding: 10px;
  357. }
  358. #tabs span.selected {
  359. color: #888;
  360. background-color: #eee;
  361. }
  362. #toolbar {
  363. position: absolute;
  364. left: 10px;
  365. top: 42px;
  366. width: 32px;
  367. background: #eee;
  368. text-align: center;
  369. }
  370. #toolbar button, #toolbar input {
  371. height: 32px;
  372. }
  373. #toolbar button img {
  374. width: 16px;
  375. opacity: 0.5;
  376. }
  377. .Outliner {
  378. color: #444;
  379. background-color: #fff;
  380. padding: 0;
  381. width: 100%;
  382. height: 180px;
  383. font-size: 12px;
  384. cursor: default;
  385. overflow: auto;
  386. resize: vertical;
  387. outline: none !important;
  388. }
  389. .Outliner .option {
  390. padding: 4px;
  391. color: #666;
  392. white-space: nowrap;
  393. }
  394. .Outliner .option:hover {
  395. background-color: rgba(0,0,0,0.02);
  396. }
  397. .Outliner .option.active {
  398. background-color: rgba(0,0,0,0.04);
  399. }
  400. .TabbedPanel .Tabs {
  401. background-color: #ddd;
  402. border-top: 1px solid #ccc;
  403. }
  404. .TabbedPanel .Tab {
  405. color: #aaa;
  406. border-right: 1px solid #ccc;
  407. }
  408. .TabbedPanel .Tab.selected {
  409. color: #888;
  410. background-color: #eee;
  411. }
  412. .Listbox {
  413. color: #444;
  414. background-color: #fff;
  415. }
  416. .Panel {
  417. color: #888;
  418. }
  419. /* */
  420. @media all and ( max-width: 600px ) {
  421. #resizer {
  422. display: none;
  423. }
  424. #menubar .menu .options {
  425. max-height: calc(100% - 372px);
  426. }
  427. #menubar .menu.right {
  428. display: none;
  429. }
  430. #viewport {
  431. left: 0;
  432. right: 0;
  433. top: 32px;
  434. height: calc(100% - 352px);
  435. }
  436. #script {
  437. left: 0;
  438. right: 0;
  439. top: 32px;
  440. height: calc(100% - 352px);
  441. }
  442. #player {
  443. left: 0;
  444. right: 0;
  445. top: 32px;
  446. height: calc(100% - 352px);
  447. }
  448. #sidebar {
  449. left: 0;
  450. width: 100%;
  451. top: calc(100% - 320px);
  452. bottom: 0;
  453. }
  454. }
  455. /* DARK MODE */
  456. @media ( prefers-color-scheme: dark ) {
  457. button {
  458. color: #aaa;
  459. background-color: #222;
  460. }
  461. button:hover {
  462. color: #ccc;
  463. background-color: #444;
  464. }
  465. button.selected {
  466. color: #fff;
  467. background-color: #08f;
  468. }
  469. input, textarea {
  470. background-color: #222;
  471. border: 1px solid transparent;
  472. color: #888;
  473. }
  474. select {
  475. color: #aaa;
  476. background-color: #222;
  477. }
  478. select:hover {
  479. color: #ccc;
  480. background-color: #444;
  481. }
  482. /* UI */
  483. #menubar {
  484. background: #111;
  485. }
  486. #menubar .menu .options {
  487. background: #111;
  488. }
  489. #menubar .menu .options hr {
  490. border-color: #222;
  491. }
  492. #menubar .menu .options .option {
  493. color: #888;
  494. }
  495. #menubar .menu .options .inactive {
  496. color: #444;
  497. }
  498. #sidebar {
  499. background-color: #111;
  500. }
  501. #sidebar .Panel {
  502. border-top: 1px solid #222;
  503. }
  504. #sidebar .Panel.Material canvas {
  505. border: solid 1px #5A5A5A;
  506. }
  507. #tabs {
  508. background-color: #1b1b1b;
  509. border-top: 1px solid #222;
  510. }
  511. #tabs span {
  512. color: #555;
  513. border-right: 1px solid #222;
  514. }
  515. #tabs span.selected {
  516. background-color: #111;
  517. }
  518. #toolbar {
  519. background-color: #111;
  520. }
  521. #toolbar img {
  522. filter: invert(1);
  523. }
  524. .Outliner {
  525. color: #888;
  526. background: #222;
  527. }
  528. .Outliner .option:hover {
  529. background-color: rgba(21,60,94,0.5);
  530. }
  531. .Outliner .option.active {
  532. background-color: rgba(21,60,94,1);
  533. }
  534. .TabbedPanel .Tabs {
  535. background-color: #1b1b1b;
  536. border-top: 1px solid #222;
  537. }
  538. .TabbedPanel .Tab {
  539. color: #555;
  540. border-right: 1px solid #222;
  541. }
  542. .TabbedPanel .Tab.selected {
  543. color: #888;
  544. background-color: #111;
  545. }
  546. .Listbox {
  547. color: #888;
  548. background: #222;
  549. }
  550. .Listbox .ListboxItem:hover {
  551. background-color: rgba(21,60,94,0.5);
  552. }
  553. .Listbox .ListboxItem.active {
  554. background-color: rgba(21,60,94,1);
  555. }
  556. }
  557. /* Temporary Chrome fix (#24794) */
  558. [draggable="true"] {
  559. transform: translate(0, 0);
  560. z-index: 0;
  561. }