]> BookStack Code Mirror - bookstack/blob - resources/assets/sass/_lists.scss
Fixed some design issues and improved page export styling
[bookstack] / resources / assets / sass / _lists.scss
1 .page-list {
2   h3 {
3     margin: $-l 0 $-m 0;
4   }
5   a.chapter {
6     color: $color-chapter;
7   }
8   .inset-list {
9     display: none;
10     overflow: hidden;
11     // padding-left: $-m;
12     margin-bottom: $-l;
13   }
14   h4 {
15     display: block;
16     margin: $-s 0 0 0;
17     border-left: 5px solid $color-page;
18     padding: $-xs 0 $-xs $-m;
19   }
20   hr {
21     margin-top: 0;
22   }
23   .page, .chapter, .book {
24     padding-left: $-l;
25   }
26   .page {
27     border-left: 5px solid $color-page;
28   }
29   .chapter {
30     border-left: 5px solid $color-chapter;
31   }
32   .book {
33     border-left: 5px solid $color-book;
34   }
35   .meta {
36     margin-top: -$-m;
37     font-size: 0.95em;
38   }
39   .meta span {
40     margin-right: $-s;
41   }
42 }
43 .chapter-toggle {
44   cursor: pointer;
45   margin: 0 0 $-l 0;
46   transition: all ease-in-out 180ms;
47   user-select: none;
48   i.zmdi-caret-right {
49     transition: all ease-in-out 180ms;
50     transform: rotate(0deg);
51     transform-origin: 25% 50%;
52   }
53   &.open {
54     margin-bottom: 0;
55   }
56   &.open i.zmdi-caret-right {
57     transform: rotate(90deg);
58   }
59 }
60
61 .page-nav-list {
62   $nav-indent: $-s;
63   margin-left: 2px;
64   list-style: none;
65   li {
66     //border-left: 1px solid rgba(0, 0, 0, 0.1);
67     padding-left: $-xs;
68     border-left: 2px solid #888;
69     margin-bottom: 4px;
70   }
71   li a {
72     color: #555;
73   }
74   .nav-H2 {
75     margin-left: $nav-indent;
76     font-size: 0.95em;
77   }
78   .nav-H3 {
79     margin-left: $nav-indent*2;
80     font-size: 0.90em
81   }
82   .nav-H4 {
83     margin-left: $nav-indent*3;
84     font-size: 0.85em
85   }
86   .nav-H5 {
87     margin-left: $nav-indent*4;
88     font-size: 0.80em
89   }
90   .nav-H6 {
91     margin-left: $nav-indent*5;
92     font-size: 0.75em
93   }
94 }
95
96 // Sidebar list
97 .book-tree {
98   margin-top: $-xl;
99 }
100 .book-tree h4 {
101   padding: $-m $-s 0 $-s;
102   i {
103     padding-right: $-s;
104   }
105 }
106 .book-tree .sidebar-page-list {
107   list-style: none;
108   margin: $-xs 0 0;
109   padding-left: 0;
110   border-left: 5px solid $color-book;
111   li a {
112     display: block;
113     border-bottom: none;
114     padding-left: $-s;
115     padding: $-xs 0 $-xs $-s;
116     &:hover {
117       background-color: rgba(255, 255, 255, 0.2);
118       text-decoration: none;
119     }
120   }
121   li a i {
122     padding-right: $-xs + 2px;
123   }
124   li, a {
125     display: block;
126   }
127   a.bold {
128     color: #EEE !important;
129   }
130   ul {
131     list-style: none;
132     margin: 0;
133   }
134   .book {
135     color: $color-book !important;
136     &.selected {
137       background-color: rgba($color-book, 0.29);
138     }
139   }
140   .chapter {
141     color: $color-chapter !important;
142     &.selected {
143       background-color: rgba($color-chapter, 0.12);
144     }
145   }
146   .chapter-toggle {
147     padding-left: $-s;
148   }
149   .list-item-chapter {
150     border-left: 5px solid $color-chapter;
151     margin: 10px 10px;
152     display: block;
153   }
154   .list-item-page {
155     border-bottom: none;
156     border-left: 5px solid $color-page;
157     margin: 10px 10px;
158   }
159   .page {
160     color: $color-page !important;
161     border-bottom: none;
162     &.selected {
163       background-color: rgba($color-page, 0.1);
164     }
165   }
166   .sub-menu {
167     display: none;
168   }
169   .sub-menu.open {
170     display: block;
171   }
172 }
173
174 // Sortable Lists
175 .sortable-page-list, .sortable-page-list ul {
176   list-style: none;
177   background-color: #FFF;
178 }
179 .sort-box {
180   margin-bottom: $-m;
181   padding: 0 $-l 0 $-l;
182   border-left: 4px solid $color-book;
183 }
184 .sortable-page-list {
185   margin-left: 0;
186   > ul {
187     margin-left: 0;
188   }
189   ul {
190     margin-bottom: 0;
191     margin-top: 0;
192     box-shadow: 0 0 1px 0 rgba(0, 0, 0, 0.1);
193   }
194   li {
195     border: 1px solid #DDD;
196     padding: $-xs $-s;
197     margin-top: -1px;
198     min-height: 38px;
199     &.text-chapter {
200       border-left: 2px solid $color-chapter;
201     }
202     &.text-page {
203       border-left: 2px solid $color-page;
204     }
205   }
206   li:first-child {
207     margin-top: $-xs;
208   }
209 }
210 .sortable-page-list li.placeholder {
211   position: relative;
212 }
213 .sortable-page-list li.placeholder:before {
214   position: absolute;
215 }
216
217
218 .activity-list-item {
219   padding: $-s 0;
220   color: #888;
221   border-bottom: 1px solid #EEE;
222   font-size: 0.9em;
223   .left {
224     float: left;
225   }
226   .left + .right {
227     margin-left: 30px + $-s;
228   }
229 }
230
231 ul.pagination {
232   display: inline-block;
233   list-style: none;
234   margin: $-m 0;
235   li {
236     float: left;
237   }
238   li:first-child {
239     a, span {
240       border-radius: 3px 0 0 3px;
241     }
242   }
243   li:last-child {
244     a, span {
245       border-radius: 0 3px 3px 0;
246     }
247   }
248   a, span {
249     display: block;
250     padding: $-xxs $-s;
251     border: 1px solid #CCC;
252     margin-left: -1px;
253     color: #888;
254     user-select: none;
255     &.disabled {
256       cursor: not-allowed;
257     }
258   }
259   li.active span {
260     background-color: rgba($primary, 0.8);
261     color: #EEE;
262     border-color: rgba($primary, 0.8);
263   }
264   a {
265     color: $primary;
266   }
267 }