]> BookStack Code Mirror - bookstack/blobdiff - resources/sass/_pages.scss
added routes for zip export
[bookstack] / resources / sass / _pages.scss
index bc36c93ddd155203b7377c8c8c7a660d53c1ef15..45e58ffc865030098c45067e01a876778d896a99 100755 (executable)
@@ -1,13 +1,16 @@
+@use "mixins";
+@use "vars";
+
 .page-editor {
   display: flex;
   flex-direction: column;
   align-items: stretch;
-  overflow: hidden;
 
   .edit-area {
     flex: 1;
     flex-direction: column;
     z-index: 10;
+    border-radius: 0 0 8px 8px;
   }
 
   .mce-tinymce {
@@ -22,8 +25,9 @@
 .page-editor-page-area {
   width: 100%;
   border-radius: 8px;
-  box-shadow: $bs-card;
-  @include lightDark(background-color, #FFF, #333)
+  box-shadow: vars.$bs-card;
+  min-width: 300px;
+  @include mixins.lightDark(background-color, #FFF, #333)
 }
 
 .page-edit-toolbar {
   align-items: center;
 }
 
-@include larger-than($xxl) {
+@include mixins.larger-than(vars.$bp-xxl) {
+  .page-editor-wysiwyg2024 .page-edit-toolbar,
+  .page-editor-wysiwyg2024 .page-editor-page-area,
   .page-editor-wysiwyg .page-edit-toolbar,
   .page-editor-wysiwyg .page-editor-page-area {
     max-width: 1140px;
   }
 
-  .page-editor-wysiwyg .floating-toolbox {
+  .page-editor-wysiwyg .floating-toolbox,
+  .page-editor-wysiwyg2024 .floating-toolbox {
     position: absolute;
   }
 }
 
-@include smaller-than($m) {
+@include mixins.smaller-than(vars.$bp-m) {
   .page-edit-toolbar {
     display: flex;
     flex-direction: row;
     display: block;
     width: 100%;
     font-size: 20px;
-    border-radius: 4px;
+    border-radius: 8px;
   }
   input[type="text"]:focus {
     position: relative;
     outline-offset: -1px;
     outline: 1px dashed var(--color-primary);
-    box-shadow: $bs-card;
+    box-shadow: vars.$bs-card;
     z-index: 50;
   }
 }
@@ -93,7 +100,7 @@ body.tox-fullscreen, body.markdown-fullscreen {
   }
 }
 
-@include smaller-than($s) {
+@include mixins.smaller-than(vars.$bp-s) {
   .page-edit-toolbar {
     overflow-x: scroll;
     overflow-y: visible;
@@ -113,9 +120,9 @@ body.tox-fullscreen, body.markdown-fullscreen {
   width: 52px;
   height: 52px;
   font-size: 26px;
-  right: $-xs;
-  bottom: $-s;
-  box-shadow: $bs-hover;
+  inset-inline-end: vars.$xs;
+  bottom: vars.$s;
+  box-shadow: vars.$bs-hover;
   background-color: currentColor;
   text-align: center;
   svg {
@@ -147,10 +154,10 @@ body.tox-fullscreen, body.markdown-fullscreen {
 }
 .pointer {
   border: 1px solid #CCC;
-  @include lightDark(border-color, #ccc, #000);
+  @include mixins.lightDark(border-color, #ccc, #000);
   border-radius: 4px;
   box-shadow: 0 0 12px 1px rgba(0, 0, 0, 0.1);
-  @include lightDark(background-color, #fff, #333);
+  @include mixins.lightDark(background-color, #fff, #333);
   width: 275px;
 
   &.is-page-editable {
@@ -168,11 +175,11 @@ body.tox-fullscreen, body.markdown-fullscreen {
     display: block;
     transform: rotate(45deg);
     transform-origin: 50% 50%;
-    border-block-end: 1px solid #CCC;
-    border-inline-end: 1px solid #CCC;
+    border-right: 1px solid #CCC;
+    border-bottom: 1px solid #CCC;
     z-index: 56;
-    @include lightDark(background-color, #fff, #333);
-    @include lightDark(border-color, #ccc, #000);
+    @include mixins.lightDark(background-color, #fff, #333);
+    @include mixins.lightDark(border-color, #ccc, #000);
   }
   input, button, a {
     position: relative;
@@ -185,14 +192,14 @@ body.tox-fullscreen, body.markdown-fullscreen {
   input {
     background-color: #FFF;
     border: 1px solid #DDD;
-    @include lightDark(border-color, #ddd, #000);
+    @include mixins.lightDark(border-color, #ddd, #000);
     color: #666;
     width: 160px;
     z-index: 40;
     padding: 5px 10px;
   }
   .text-button {
-    @include lightDark(color, #444, #AAA);
+    @include mixins.lightDark(color, #444, #AAA);
   }
   .input-group .button {
     line-height: 1;
@@ -207,22 +214,22 @@ body.tox-fullscreen, body.markdown-fullscreen {
     height: 1.2em;
   }
   .button {
-    @include lightDark(border-color, #ddd, #000);
+    @include mixins.lightDark(border-color, #ddd, #000);
   }
 }
 
 // Page editor sidebar toolbox
 .floating-toolbox {
-  @include lightDark(background-color, #FFF, #222);
+  @include mixins.lightDark(background-color, #FFF, #222);
   overflow: hidden;
   align-items: stretch;
   flex-direction: row;
   display: flex;
   max-height: 100%;
   border-radius: 8px;
-  box-shadow: $bs-card;
+  box-shadow: vars.$bs-card;
   margin-bottom: auto;
-  margin-left: $-l;
+  margin-inline-start: vars.$l;
   position: relative;
   &.open {
     position: relative;
@@ -250,39 +257,50 @@ body.tox-fullscreen, body.markdown-fullscreen {
     position: relative;
   }
   .tabs {
-    border-right: 1px solid #DDD;
-    @include lightDark(border-right-color, #DDD, #000);
+    border-inline-end: 1px solid #DDD;
+    @include mixins.lightDark(border-inline-end-color, #DDD, #000);
     width: 40px;
     flex: 0 1 auto;
-    margin-right: -1px;
+    margin-inline-end: -1px;
   }
   .tabs-inner {
-    @include lightDark(background-color, #FFFFFF, #222);
+    @include mixins.lightDark(background-color, #FFFFFF, #222);
   }
   .tabs svg {
     padding: 0;
     margin: 0;
   }
   .tabs-inner > button {
-    @include lightDark(color, rgba(0, 0, 0, 0.7), rgba(255, 255, 255, 0.5));
+    @include mixins.lightDark(color, rgba(0, 0, 0, 0.7), rgba(255, 255, 255, 0.5));
     display: block;
     cursor: pointer;
-    padding: 10px $-xs;
+    padding: 10px vars.$xs;
     font-size: 18px;
     line-height: 1.6;
   }
   .tabs-inner > button:hover,  &.open .tabs-inner > button.active {
-    background-color: var(--color-primary-light);
-    color: var(--color-primary);
+    color: var(--color-link) !important;
+    position: relative;
+    &:after {
+      content: '';
+      display: block;
+      position: absolute;
+      left: 0;
+      width: 100%;
+      top: 0;
+      height: 100%;
+      background-color: currentColor;
+      opacity: .075;
+    }
   }
   &.open .tabs-inner > button.active {
-    border-inline-end: 1px solid var(--color-primary);
+    border-inline-end: 1px solid var(--color-link);
     margin-inline-end: -1px;
   }
   h4 {
     font-size: 24px;
-    margin: $-m 0 0 0;
-    padding: 0 $-l $-s $-l;
+    margin: vars.$m 0 0 0;
+    padding: 0 vars.$l vars.$s vars.$l;
   }
   .tags input {
     max-width: 100%;
@@ -290,8 +308,8 @@ body.tox-fullscreen, body.markdown-fullscreen {
     min-width: 50px;
   }
   .tags td, .inline-start-table > div > div > div {
-    padding-inline-end: $-s;
-    padding-top: $-s;
+    padding-inline-end: vars.$s;
+    padding-top: vars.$s;
     position: relative;
   }
   .handle {
@@ -310,18 +328,18 @@ body.tox-fullscreen, body.markdown-fullscreen {
   }
 }
 
-@include smaller-than($xxl) {
+@include mixins.smaller-than(vars.$bp-xxl) {
   .floating-toolbox {
-    margin-left: $-s;
+    margin-inline-start: vars.$s;
   }
 }
 
-@include smaller-than($s) {
+@include mixins.smaller-than(vars.$bp-s) {
   .page-editor-page-area-wrap {
     margin: 4px !important;
   }
   .floating-toolbox {
-    margin-left: 4px;
+    margin-inline-start: 4px;
   }
   .floating-toolbox .tabs {
     width: 32px;
@@ -415,7 +433,7 @@ body.tox-fullscreen, body.markdown-fullscreen {
   border-radius: 3px;
   position: relative;
   overflow: hidden;
-  padding: $-xs $-s;
+  padding: vars.$xs vars.$s;
   fill: currentColor;
   opacity: 0.85;
   transition: opacity ease-in-out 120ms;