_editor.scss 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. /* stylelint-disable selector-class-pattern */
  2. @use '@growi/core-styles/scss/bootstrap/init' as bs;
  3. @use './variables' as var;
  4. @import './organisms/wiki-custom-sidebar';
  5. :root {
  6. --grw-codemirror-editor-content-font-family: var(--font-family-monospace);
  7. }
  8. // global imported
  9. .layout-root.editing {
  10. overflow: hidden !important;
  11. .page-wrapper{
  12. height: 100vh;
  13. }
  14. // show
  15. .d-edit-block {
  16. display: block !important;
  17. }
  18. // hide unnecessary elements
  19. .d-edit-none {
  20. display: none !important;
  21. }
  22. /*****************
  23. * Expand Editor
  24. *****************/
  25. .dynamic-layout-root {
  26. @extend .flex-expand-vh-100;
  27. }
  28. &.builtin-editor {
  29. /*****************
  30. * Editor styles
  31. *****************/
  32. .page-editor-editor-container {
  33. border-right: 1px solid transparent;
  34. // add icon on cursor
  35. .markdown-table-activated,
  36. .markdown-link-activated {
  37. .CodeMirror-cursor {
  38. &::after {
  39. position: relative;
  40. top: -1.1em;
  41. left: 0.3em;
  42. display: block;
  43. width: 1em;
  44. height: 1em;
  45. content: ' ';
  46. background-repeat: no-repeat;
  47. background-size: 1em;
  48. }
  49. }
  50. }
  51. .markdown-table-activated .CodeMirror-cursor {
  52. &::after {
  53. background-image: url('/images/icons/editor/table.svg');
  54. }
  55. }
  56. .markdown-link-activated .CodeMirror-cursor {
  57. &::after {
  58. background-image: url('/images/icons/editor/link.svg');
  59. }
  60. }
  61. }
  62. // .page-editor-preview-container {
  63. // }
  64. .page-editor-preview-body {
  65. flex-grow: 1;
  66. padding: 18px 15px 0;
  67. overflow-y: scroll;
  68. }
  69. // editing /Sidebar
  70. .page-editor-preview-body.preview-sidebar {
  71. flex-grow: 0;
  72. width: 320px;
  73. margin-right: auto;
  74. margin-left: auto;
  75. .wiki {
  76. @extend %grw-custom-sidebar-content;
  77. }
  78. }
  79. }
  80. // .builtin-editor .tab-pane#edit
  81. /*****************
  82. * Toastr
  83. *****************/
  84. .Toastify .Toastify__toast-container {
  85. top: 4.5em;
  86. }
  87. }
  88. // TODO: Never used this id class
  89. #tag-edit-button-tooltip {
  90. .tooltip-inner {
  91. color: black;
  92. background-color: white;
  93. border: 1px solid bs.$gray-300;
  94. }
  95. .tooltip-arrow {
  96. border-bottom: 5px solid bs.$gray-300;
  97. }
  98. }