editor.less 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507
  1. @import "./editor/file-tree.less";
  2. @import "./editor/history.less";
  3. @import "./editor/toolbar.less";
  4. @import "./editor/left-menu.less";
  5. @import "./editor/pdf.less";
  6. @import "./editor/enago.less";
  7. @import "./editor/share.less";
  8. @import "./editor/chat.less";
  9. @import "./editor/binary-file.less";
  10. @import "./editor/search.less";
  11. @import "./editor/publish-template.less";
  12. @import "./editor/online-users.less";
  13. @import "./editor/hotkeys.less";
  14. @import "./editor/review-panel.less";
  15. @import "./editor/feature-onboarding.less";
  16. @keyframes blink {
  17. 0% {
  18. opacity: 0.2;
  19. }
  20. 20% {
  21. opacity: 1;
  22. }
  23. 100% {
  24. opacity: 0.2;
  25. }
  26. }
  27. .full-size {
  28. position: absolute;
  29. top: 0;
  30. bottom: 0;
  31. left: 0;
  32. right: 0;
  33. }
  34. .global-alerts {
  35. height: 0;
  36. margin-top: 2px;
  37. text-align: center;
  38. .alert {
  39. display: inline-block;
  40. text-align: left;
  41. min-width: 400px;
  42. padding: (@line-height-computed / 4);
  43. font-size: 14px;
  44. margin-bottom: (@line-height-computed / 4);
  45. position: relative;
  46. z-index: 20;
  47. }
  48. }
  49. #try-reconnect-now-button {
  50. margin-left: 20px;
  51. }
  52. #ide-body {
  53. .full-size;
  54. top: 40px;
  55. }
  56. #editor {
  57. .full-size;
  58. }
  59. .loading-screen {
  60. display: flex;
  61. flex-direction: column;
  62. justify-content: center;
  63. align-items: center;
  64. width: 100%;
  65. height: 100%;
  66. background-color: #FFF;
  67. }
  68. .loading-screen-brand-container {
  69. width: 15%;
  70. min-width: 200px;
  71. text-align: center;
  72. }
  73. .loading-screen-brand {
  74. position: relative;
  75. width: 100%;
  76. padding-top: @editor-loading-logo-padding-top;
  77. height: 0;
  78. background: @editor-loading-logo-background-url no-repeat bottom / 100%;
  79. &::after {
  80. content: '';
  81. position: absolute;
  82. height: inherit;
  83. right: 0;
  84. bottom: 0;
  85. left: 0;
  86. background: @editor-loading-logo-foreground-url no-repeat bottom / 100%;
  87. transition: height .5s;
  88. }
  89. }
  90. .loading-screen-label {
  91. margin: 0;
  92. padding-top: 1em;
  93. font-size: 2em;
  94. color: @gray-dark;
  95. }
  96. .loading-screen-ellip {
  97. animation: blink 1.4s both infinite;
  98. &:nth-child(2) {
  99. animation-delay: 0.2s;
  100. }
  101. &:nth-child(3) {
  102. animation-delay: 0.4s;
  103. }
  104. }
  105. .loading-screen-error {
  106. margin: 0;
  107. padding-top: 1em;
  108. color: @state-danger-text;
  109. }
  110. .loading-panel {
  111. .full-size;
  112. padding-top: 10rem;
  113. font-family: @font-family-serif;
  114. text-align: center;
  115. background-color: #fafafa;
  116. }
  117. .error-panel {
  118. .full-size;
  119. padding: @line-height-computed;
  120. background-color: #fafafa;
  121. .alert {
  122. max-width: 400px;
  123. margin: auto;
  124. }
  125. }
  126. .project-name {
  127. .name {
  128. display: inline-block;
  129. max-width: 250px;
  130. overflow: hidden;
  131. text-overflow: ellipsis;
  132. vertical-align: top;
  133. padding: 6px;
  134. color: @gray;
  135. font-weight: 700;
  136. white-space: nowrap;
  137. }
  138. input {
  139. height: 30px;
  140. margin-top: 4px;
  141. text-align: center;
  142. padding: 6px;
  143. font-weight: 700;
  144. }
  145. a.rename {
  146. visibility: hidden;
  147. display: inline-block;
  148. color: @gray-light;
  149. padding: 5px;
  150. border-radius: @border-radius-small;
  151. &:hover {
  152. text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
  153. color: @gray-dark;
  154. text-decoration: none;
  155. }
  156. }
  157. &:hover {
  158. a.rename {
  159. visibility: visible;
  160. }
  161. }
  162. }
  163. // The internal components of the aceEditor directive
  164. .ace-editor-wrapper {
  165. .full-size;
  166. .undo-conflict-warning {
  167. position: absolute;
  168. top: 0;
  169. right: 0;
  170. left: 0;
  171. z-index: 10;
  172. }
  173. .ace-editor-body {
  174. width: 100%;
  175. height: 100%;
  176. }
  177. .spelling-highlight {
  178. position: absolute;
  179. background-image: url(/img/spellcheck-underline.png);
  180. @media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  181. background-image: url(/img/spellcheck-underline@2x.png);
  182. background-size: 5px 4px;
  183. }
  184. background-repeat: repeat-x;
  185. background-position: bottom left;
  186. }
  187. .remote-cursor {
  188. position: absolute;
  189. border-left: 2px solid transparent;
  190. .nubbin {
  191. height: 5px;
  192. width: 5px;
  193. position: absolute;
  194. left: -2px;
  195. }
  196. }
  197. .annotation-label {
  198. padding: (@line-height-computed / 4) (@line-height-computed / 2);
  199. font-size: 0.8rem;
  200. z-index: 100;
  201. font-family: @font-family-sans-serif;
  202. color: white;
  203. font-weight: 700;
  204. white-space: nowrap;
  205. }
  206. .annotation {
  207. position: absolute;
  208. z-index: 2;
  209. }
  210. .highlights-before-label, .highlights-after-label {
  211. position: absolute;
  212. right: @line-height-computed;
  213. z-index: 1;
  214. }
  215. .highlights-before-label {
  216. top: @line-height-computed / 2;
  217. }
  218. .highlights-after-label {
  219. bottom: @line-height-computed / 2;
  220. }
  221. }
  222. // Hack to solve an issue where scrollbars aren't visible in Safari.
  223. // Safari seems to clip part of the scrollbar element. By giving the
  224. // element a background, we're telling Safari that it *really* needs to
  225. // paint the whole area. See https://github.com/ajaxorg/ace/issues/2872
  226. .ace_scrollbar-inner {
  227. background-color: #FFF;
  228. opacity: 0.01;
  229. .ace_dark & {
  230. background-color: #000;
  231. }
  232. }
  233. .ui-layout-resizer {
  234. width: 6px;
  235. background-color: #f4f4f4;
  236. border-left: 1px solid @toolbar-border-color;
  237. border-right: 1px solid @toolbar-border-color;
  238. .ui-layout-toggler {
  239. color: #999;
  240. font-family: FontAwesome;
  241. font-style: normal;
  242. font-weight: normal;
  243. line-height: 1;
  244. -webkit-font-smoothing: antialiased;
  245. -moz-osx-font-smoothing: grayscale;
  246. font-size: 16px !important;
  247. line-height: 50px;
  248. &:hover {
  249. background-color: #ddd;
  250. color: #333;
  251. }
  252. }
  253. }
  254. .ui-layout-resizer-west.ui-layout-resizer-open, .ui-layout-resizer-east.ui-layout-resizer-closed {
  255. .ui-layout-toggler {
  256. &:before {
  257. content: "\f104"
  258. }
  259. }
  260. }
  261. .ui-layout-resizer-east.ui-layout-resizer-open, .ui-layout-resizer-west.ui-layout-resizer-closed {
  262. .ui-layout-toggler {
  263. &:before {
  264. content: "\f105"
  265. }
  266. }
  267. }
  268. .ui-layout-resizer-dragging {
  269. background-color: #ddd;
  270. }
  271. .context-menu {
  272. position: fixed;
  273. z-index: 100;
  274. }
  275. .editor-dark {
  276. color: @gray-lighter;
  277. background-color: @editor-dark-background-color;
  278. .ui-layout-resizer {
  279. background-color: darken(@editor-dark-background-color, 10%);
  280. border: none;
  281. }
  282. .btn-default {
  283. color: white;
  284. background-color: @gray;
  285. border-color: darken(@gray-dark, 10%);
  286. &:hover {
  287. background-color: darken(@gray, 5%);
  288. border-color: darken(@gray-dark, 20%);
  289. }
  290. }
  291. }
  292. .modal-alert {
  293. margin-top:10px;
  294. margin-bottom:0px;
  295. }
  296. // vertically centre the "connection down" modal so it does not hide
  297. // the reconnecting indicator
  298. .modal.lock-editor-modal {
  299. display: flex !important;
  300. .modal-dialog {
  301. margin: auto;
  302. }
  303. }
  304. .sl_references_search_hint-varDefault {
  305. position: absolute;
  306. bottom: -22px;
  307. left: -1px;
  308. right: 0px;
  309. text-align: center;
  310. padding: 2px;
  311. background: rgb(202, 214, 250);
  312. border: 1px solid lightgray;
  313. box-shadow: 3px 3px 5px rgba(0,0,0,.2);
  314. span {
  315. color: black;
  316. }
  317. }
  318. .sl_references_search_hint-varButton {
  319. position: absolute;
  320. bottom: -65px;
  321. left: -1px;
  322. right: 0px;
  323. padding: 0 6px 6px;
  324. text-align: center;
  325. background: #fbfbfb;
  326. color: #FFF;
  327. box-shadow: 3px 3px 5px rgba(0,0,0,.2);
  328. border-left: 1px solid lightgray;
  329. font-family: @font-family-sans-serif;
  330. font-size: 13px;
  331. font-weight: 600;
  332. hr {
  333. margin: 6px -6px;
  334. }
  335. button {
  336. width: 100%;
  337. font-size: inherit;
  338. line-height: 1.4;
  339. }
  340. span {
  341. padding-left: 10px;
  342. }
  343. kbd {
  344. display: block;
  345. font-family: inherit;
  346. font-size: 12px;
  347. font-weight: normal;
  348. }
  349. }
  350. // -- References Search Modal --
  351. .references-search-modal-backdrop {
  352. // don't grey out the editor when the
  353. // modal is active
  354. background-color: transparent;
  355. }
  356. .references-search-modal {
  357. // upgrade prompt
  358. .references-search-upgrade-prompt {
  359. padding: 24px;
  360. padding-bottom: 48px;
  361. .upgrade-prompt {
  362. text-align: center;
  363. width: 400px;
  364. padding-top: 14px;
  365. padding-bottom: 14px;
  366. padding-left: 38px;
  367. padding-right: 38px;
  368. margin: auto;
  369. background: white;
  370. opacity: 0.95;
  371. border-radius: 8px;
  372. .message {
  373. margin-top: 15px;
  374. &.call-to-action {
  375. font-weight: bold;
  376. }
  377. ul.list-unstyled {
  378. text-align: left;
  379. }
  380. }
  381. a.btn {
  382. opacity: 1.0;
  383. }
  384. }
  385. }
  386. .search-form {
  387. // position the spinner inside the input element
  388. i.fa-spinner {
  389. margin-top: -30px;
  390. }
  391. }
  392. .alert-danger {
  393. margin-top: 12px;
  394. margin-bottom: 0px;
  395. }
  396. // search result items list
  397. .search-results {
  398. font-size: 12px;
  399. .no-results-message {
  400. font-size: 16px;
  401. }
  402. .search-result-hit {
  403. &:hover {
  404. cursor: pointer;
  405. }
  406. border-bottom: 1px solid #ddd;
  407. padding: 8px;
  408. &:last-child {
  409. border-bottom: 1px solid transparent;
  410. }
  411. border-left: 4px solid transparent;
  412. &.selected-search-result-hit {
  413. background-color: @red;
  414. color: white;
  415. .hit-year.small {
  416. color: white;
  417. }
  418. .hit-journal.small {
  419. color: white;
  420. }
  421. }
  422. .hit-title {
  423. font-size: 1.3em;
  424. font-style: italic;
  425. }
  426. }
  427. }
  428. }
  429. .referencesImportModal {
  430. .referencesImportPreview {
  431. margin-top: 15px;
  432. .referencesImportPreviewScroller {
  433. font-family: monospace;
  434. font-size: 0.8em;
  435. max-height: 360px;
  436. overflow: scroll;
  437. white-space: pre;
  438. padding: 8px 12px;
  439. margin-bottom: 15px;
  440. border: 1px solid @gray-lighter;
  441. background-color: @gray-lightest;
  442. }
  443. }
  444. }
  445. .teaser-title,
  446. .dropbox-teaser-title {
  447. margin-top: 0;
  448. text-align: center;
  449. }
  450. .teaser-img,
  451. .dropbox-teaser-img {
  452. .img-responsive;
  453. margin-bottom: 5px;
  454. }
  455. .teaser-video-container,
  456. .dropbox-teaser-video-container {
  457. margin-top: -@modal-inner-padding;
  458. margin-left: -@modal-inner-padding;
  459. margin-right: -@modal-inner-padding;
  460. margin-bottom: 5px;
  461. overflow: hidden;
  462. }
  463. .teaser-video,
  464. .dropbox-teaser-video {
  465. width: 100%;
  466. height: auto;
  467. border-bottom: 1px solid @modal-header-border-color;
  468. }