editor.less 9.1 KB

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