]> BookStack Code Mirror - bookstack/blob - resources/assets/sass/styles.scss
Added experimental breadcrumb traversal
[bookstack] / resources / assets / sass / styles.scss
1 @import "reset";
2 @import "variables";
3 @import "mixins";
4 @import "html";
5 @import "text";
6 @import "colors";
7 @import "grid";
8 @import "blocks";
9 @import "buttons";
10 @import "tables";
11 @import "forms";
12 @import "animations";
13 @import "tinymce";
14 @import "codemirror";
15 @import "components";
16 @import "header";
17 @import "lists";
18 @import "pages";
19
20 [v-cloak] {
21   display: none; opacity: 0;
22   animation-name: none !important;
23 }
24
25 // Jquery Sortable Styles
26 .dragged {
27   position: absolute;
28   opacity: 0.5;
29   z-index: 2000;
30 }
31 body.dragging, body.dragging * {
32   cursor: move !important;
33 }
34
35 // User Avatar Images
36 .avatar {
37   border-radius: 100%;
38   background-color: #EEE;
39   width: 30px;
40   height: 30px;
41   &.med {
42     width: 40px;
43     height: 40px;
44   }
45   &.large {
46     width: 80px;
47     height: 80px;
48   }
49   &.huge {
50     width: 120px;
51     height: 120px;
52   }
53   &.square {
54     border-radius: 3px;
55   }
56 }
57
58 // Loading icon
59 $loadingSize: 10px;
60 .loading-container {
61   position: relative;
62   display: block;
63   margin: $-xl auto;
64   > div {
65     width: $loadingSize;
66     height: $loadingSize;
67     border-radius: $loadingSize;
68     display: inline-block;
69     vertical-align: top;
70     transform: translate3d(-10px, 0, 0);
71     margin-top: $-xs;
72     animation-name: loadingBob;
73     animation-duration: 1.4s;
74     animation-iteration-count: infinite;
75     animation-timing-function: cubic-bezier(.62, .28, .23, .99);
76     margin-right: 4px;
77     background-color: $color-page;
78     animation-delay: 0.3s;
79   }
80   > div:first-child {
81       left: -($loadingSize+$-xs);
82       background-color: $color-book;
83       animation-delay: 0s;
84   }
85   > div:last-of-type {
86     left: $loadingSize+$-xs;
87     background-color: $color-chapter;
88     animation-delay: 0.6s;
89   }
90   > span {
91     margin-left: $-s;
92     font-style: italic;
93     color: #888;
94     vertical-align: top;
95   }
96 }
97
98
99 // Search results
100 .search-results > h3 a {
101   font-size: 0.66em;
102   color: $primary;
103   padding-left: $-m;
104   i {
105     padding-right: $-s;
106   }
107 }
108
109 // Back to top link
110 $btt-size: 40px;
111 [back-to-top] {
112   background-color: $primary;
113   position: fixed;
114   bottom: $-m;
115   right: $-l;
116   padding: 5px 7px;
117   cursor: pointer;
118   color: #FFF;
119   fill: #FFF;
120   svg {
121     width: $btt-size / 1.5;
122     height: $btt-size / 1.5;
123     margin-right: 4px;
124   }
125   width: $btt-size;
126   height: $btt-size;
127   border-radius: $btt-size;
128   transition: all ease-in-out 180ms;
129   opacity: 0;
130   z-index: 999;
131   overflow: hidden;
132   &:hover {
133     width: $btt-size*3.4;
134     opacity: 1 !important;
135   }
136   .inner {
137     width: $btt-size*3.4;
138   }
139   span {
140     position: relative;
141     vertical-align: top;
142     line-height: 2;
143   }
144 }
145
146 .contained-search-box {
147   display: flex;
148   input, button {
149     border-radius: 0;
150     border: 1px solid #DDD;
151     margin-left: -1px;
152   }
153   input {
154     flex: 5;
155     padding: $-xs $-s;
156     &:focus, &:active {
157       outline: 0;
158     }
159   }
160   button {
161     width: 60px;
162   }
163   button i {
164     padding: 0;
165   }
166   button.cancel.active {
167     background-color: $negative;
168     color: #EEE;
169   }
170 }
171
172 .entity-selector {
173   border: 1px solid #DDD;
174   border-radius: 3px;
175   overflow: hidden;
176   font-size: 0.8em;
177   input[type="text"] {
178     width: 100%;
179     display: block;
180     border-radius: 0;
181     border: 0;
182     border-bottom: 1px solid #DDD;
183     font-size: 16px;
184     padding: $-s $-m;
185   }
186   .entity-list {
187     overflow-y: scroll;
188     height: 400px;
189     background-color: #EEEEEE;
190   }
191   .loading {
192     height: 400px;
193     padding-top: $-l;
194   }
195   .entity-list > p {
196     text-align: center;
197     padding-top: $-l;
198     font-size: 1.333em;
199   }
200   .entity-list > div {
201     padding-left: $-m;
202     padding-right: $-m;
203     background-color: #FFF;
204     transition: all ease-in-out 120ms;
205     cursor: pointer;
206   }
207   &.compact {
208     font-size: 10px;
209     .entity-item-snippet {
210       display: none;
211     }
212   }
213 }
214
215 .entity-list-item.selected {
216   h3, i, p ,a, span {
217     color: #EEE;
218   }
219 }
220
221 .scroll-box {
222   max-height: 250px;
223   overflow-y: scroll;
224   border: 1px solid #DDD;
225   border-radius: 3px;
226   .scroll-box-item {
227     padding: $-xs $-m;
228     border-bottom: 1px solid #DDD;
229     &:last-child {
230       border-bottom: 0;
231     }
232   }
233 }
234
235 .center-box {
236   margin: $-xxl auto 0 auto;
237   width: 420px;
238   max-width: 100%;
239   display: inline-block;
240   text-align: left;
241   vertical-align: top;
242   input {
243     width: 100%;
244   }
245 }
246
247 .fullscreen {
248   border:0;
249   position:fixed;
250   top:0;
251   left:0;
252   right:0;
253   bottom:0;
254   width:100%;
255   height:100%;
256   z-index: 150;
257 }
258
259 .list-sort-container {
260   display: inline-block;
261   form {
262     display: inline-block;
263   }
264   .list-sort {
265     display: inline-grid;
266     margin-left: $-s;
267     grid-template-columns: 120px 40px;
268     border: 2px solid #DDD;
269     border-radius: 4px;
270   }
271   .list-sort-label {
272     font-weight: bold;
273     display: inline-block;
274     color: #888;
275   }
276   .list-sort-type {
277     text-align: left;
278   }
279   .list-sort-type, .list-sort-dir {
280     padding: $-xs $-s;
281     cursor: pointer;
282   }
283   .list-sort-dir {
284     border-left: 2px solid #DDD;
285     fill: #888;
286     .svg-icon {
287       transition: transform ease-in-out 120ms;
288     }
289     &:hover .svg-icon {
290       transform: rotate(180deg);
291     }
292   }
293 }