ide-react.less 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  1. #ide-root {
  2. height: 100vh; /* for backwards compatibility */
  3. height: 100dvh; /* needed for mobile devices */
  4. .global-alerts {
  5. position: absolute;
  6. top: 0;
  7. left: 0;
  8. right: 0;
  9. display: flex;
  10. flex-direction: column;
  11. align-items: center;
  12. }
  13. .chat {
  14. position: relative;
  15. height: 100%;
  16. }
  17. .review-panel-wrapper {
  18. &.rp-state-overview {
  19. position: sticky;
  20. top: 0;
  21. height: 100%;
  22. }
  23. }
  24. }
  25. .ide-react-main {
  26. height: 100%;
  27. display: flex;
  28. flex-direction: column;
  29. .toolbar.toolbar-header {
  30. position: static;
  31. flex-grow: 0;
  32. color: var(--neutral-20);
  33. }
  34. }
  35. .ide-react-body {
  36. flex-grow: 1;
  37. background-color: @pdf-bg;
  38. overflow-y: hidden;
  39. z-index: 0;
  40. }
  41. .horizontal-resize-handle {
  42. width: @ui-resizer-size !important;
  43. height: 100%;
  44. // Enable ::before and ::after pseudo-elements to position themselves correctly
  45. position: relative;
  46. background-color: @editor-resizer-bg-color;
  47. .custom-toggler {
  48. padding: 0;
  49. border-width: 0;
  50. // Override react-resizable-panels which sets a global * { cursor: ew-resize }
  51. cursor: pointer !important;
  52. }
  53. &.horizontal-resize-handle-enabled {
  54. &::before,
  55. &::after {
  56. // This SVG has the colour hard-coded to the current value of @ol-blue-gray-2, so if we changed @ol-blue-gray-2,
  57. // we'd have to change this SVG too
  58. content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='7' height='18' viewBox='0 0 7 18'%3E%3Cpath d='M2 0h3v3H2zM2 5h3v3H2zM2 10h3v3H2zM2 15h3v3H2z' style='fill:%239da7b7'/%3E%3C/svg%3E");
  59. display: block;
  60. position: absolute;
  61. text-align: center;
  62. left: 0;
  63. width: 7px;
  64. height: 18px;
  65. }
  66. &::before {
  67. top: 25%;
  68. }
  69. &::after {
  70. top: 75%;
  71. }
  72. }
  73. &:not(.horizontal-resize-handle-enabled) {
  74. cursor: default;
  75. }
  76. .synctex-controls {
  77. left: -8px;
  78. margin: 0;
  79. // Ensure that SyncTex controls appear in front of PDF viewer controls and logs pane
  80. z-index: 12;
  81. & .synctex-control .synctex-control-icon {
  82. // Override react-resizable-panels which sets a global * { cursor: ew-resize }
  83. cursor: pointer !important;
  84. }
  85. }
  86. }
  87. .vertical-resize-handle {
  88. height: 6px;
  89. background-color: @vertical-resizable-resizer-bg;
  90. &.vertical-resize-handle-enabled {
  91. &:hover {
  92. background-color: @vertical-resizable-resizer-hover-bg;
  93. }
  94. }
  95. &:not(.vertical-resize-handle-enabled) {
  96. opacity: 0.5;
  97. cursor: default;
  98. }
  99. &::after {
  100. // This SVG has the colour hard-coded to the current value of @ol-blue-gray-2, so if we changed @ol-blue-gray-2,
  101. // we'd have to change this SVG too
  102. content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='6' viewBox='0 0 18 6'%3E%3Cpath d='M0 1.5h3v3H0zM5 1.5h3v3H5zM10 1.5h3v3h-3zM15 1.5h3v3h-3z' style='fill:%239da7b7'/%3E%3C/svg%3E");
  103. display: block;
  104. text-align: center;
  105. line-height: 0;
  106. }
  107. }
  108. .ide-react-editor-sidebar {
  109. height: 100%;
  110. background-color: @file-tree-bg;
  111. color: var(--neutral-20);
  112. position: relative;
  113. }
  114. .ide-react-symbol-palette {
  115. height: 100%;
  116. background-color: @symbol-palette-bg;
  117. color: var(--neutral-20);
  118. }
  119. .ide-react-file-tree-panel {
  120. display: flex;
  121. flex-direction: column;
  122. // Prevent the file tree expanding beyond the boundary of the panel
  123. .file-tree {
  124. width: 100%;
  125. }
  126. }
  127. .ide-react-editor-panel {
  128. display: flex;
  129. flex-direction: column;
  130. }
  131. // Ensure an element with class "full-size", such as the binary file view, stays within the bounds of the panel
  132. .ide-react-panel {
  133. position: relative;
  134. container-type: size;
  135. }
  136. // Styles for placeholder elements that will eventually be replaced
  137. // Unused, not migrated to SCSS
  138. .ide-react-placeholder-chat {
  139. background-color: var(--editor-toolbar-bg);
  140. color: var(--neutral-20);
  141. height: 100%;
  142. }
  143. .ide-panel-group-resizing {
  144. background-color: white;
  145. // Hide panel contents while resizing
  146. .ide-react-editor-content,
  147. .pdf {
  148. display: none !important;
  149. }
  150. }