@jsb188/css 1.1.10 → 1.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/css/layout.css CHANGED
@@ -1,274 +1,428 @@
1
-
2
1
  /* Route based styles */
3
2
 
4
3
  body.p_auth {
5
- background-color: rgb(var(--color-bg-alt));
4
+ background-color: rgb(var(--color-bg-alt));
6
5
  }
7
6
 
8
7
  /* Content & Modal wrapper */
9
8
 
10
- .cw, .mw {
11
- width: 100%;
9
+ .cw,
10
+ .mw {
11
+ width: 100%;
12
12
  }
13
13
 
14
- .cw, .mw, .mx_auto {
15
- margin-left: auto;
16
- margin-right: auto;
14
+ .cw,
15
+ .mw,
16
+ .mx_auto {
17
+ margin-left: auto;
18
+ margin-right: auto;
17
19
  }
18
20
 
19
21
  .mw {
20
- --toolbar-ht: 50px;
22
+ --toolbar-ht: 50px;
21
23
 
22
- max-height: calc(100vh - var(--toolbar-ht));
23
- /* max-height: calc(100vh - var(--rem-medium) - var(--rem-medium)); */
24
+ max-height: calc(100vh - var(--toolbar-ht));
25
+ /* max-height: calc(100vh - var(--rem-medium) - var(--rem-medium)); */
24
26
  }
25
27
 
26
28
  .mw .scr_area {
27
- max-height: calc(100vh - var(--toolbar-ht) - var(--toolbar-ht));
28
- /* max-height: calc(100vh - var(--rem-medium) - var(--rem-medium) - 45px); */
29
+ max-height: calc(100vh - var(--toolbar-ht) - var(--toolbar-ht));
30
+ /* max-height: calc(100vh - var(--rem-medium) - var(--rem-medium) - 45px); */
31
+ }
32
+
33
+ .mw .scr_area.sm {
34
+ max-height: min(640px, 75vh);
35
+ }
36
+
37
+ .mw .scr_area.xs {
38
+ max-height: min(530px, 64vh);
39
+ }
40
+
41
+ /* "Almost" full, centered modal page */
42
+
43
+ .mw.centered_big {
44
+ flex: 1;
45
+ max-height: 900px;
46
+ max-width: 1440px;
47
+ }
48
+
49
+ /* Medium, centered modal page */
50
+
51
+ .mw.centered_medium_wide {
52
+ flex: 1;
53
+ max-height: 600px;
54
+ max-width: 1060px;
55
+ }
56
+
57
+ .mw.centered_medium_tall {
58
+ flex: 1;
59
+ max-height: 900px;
60
+ max-width: 1060px;
61
+ }
62
+
63
+ /* Small, centered modal page */
64
+
65
+ .mw.centered_small_tall {
66
+ flex: 1;
67
+ max-height: 900px;
68
+ max-width: 780px;
29
69
  }
30
70
 
31
71
  /* Top-fixed position modal content wrappers */
32
72
 
33
73
  .mw_page {
34
- padding-top: 6vh;
74
+ padding-top: 6vh;
35
75
  }
36
76
 
37
77
  .mw_page .modal_main_content {
38
- max-height: calc(94vh + 10px);
78
+ max-height: calc(94vh + 10px);
79
+ }
80
+
81
+ .mw_page .modal_fit_content {
82
+ height: calc(88vh - var(--toolbar-ht));
39
83
  }
40
84
 
41
85
  /* Special sizing for mobile */
42
86
 
43
- .max_h_extend_bottom { max-height: 87.5vh; }
44
- .mw_page .max_h_extend_bottom { max-height: calc(94vh - var(--toolbar-ht) + 10); padding-bottom: 10px; }
87
+ .max_h_extend_bottom {
88
+ max-height: 87.5vh;
89
+ }
90
+ .mw_page .max_h_extend_bottom {
91
+ max-height: calc(94vh - var(--toolbar-ht) + 10);
92
+ padding-bottom: 10px;
93
+ }
45
94
 
46
95
  @media (max-height: 1140px) {
47
- /* Designed for modal wrapper layout content while accounting for mobile header area */
48
- .max_h_extend_bottom { max-height: 85vh; }
96
+ /* Designed for modal wrapper layout content while accounting for mobile header area */
97
+ .max_h_extend_bottom {
98
+ max-height: 85vh;
99
+ }
49
100
  }
50
101
 
51
102
  @media (max-height: 1024px) {
52
- /* Designed for modal wrapper layout content while accounting for mobile header area */
53
- .max_h_extend_bottom { max-height: 82.5vh; }
54
-
55
- /* .mw_page responsive design */
56
- .mw_page { padding-top: 7.5vh; }
57
- .mw_page .modal_main_content { max-height: calc(92.5vh + 10px); }
58
- .mw_page .max_h_extend_bottom { max-height: calc(92.5vh - var(--toolbar-ht) + 10); }
103
+ /* Designed for modal wrapper layout content while accounting for mobile header area */
104
+ .max_h_extend_bottom {
105
+ max-height: 82.5vh;
106
+ }
107
+
108
+ /* .mw_page responsive design */
109
+ .mw_page {
110
+ padding-top: 7.5vh;
111
+ }
112
+ .mw_page .modal_main_content {
113
+ max-height: calc(92.5vh + 10px);
114
+ }
115
+ .mw_page .max_h_extend_bottom {
116
+ max-height: calc(92.5vh - var(--toolbar-ht) + 10);
117
+ }
59
118
  }
60
119
 
61
120
  @media (max-height: 768px) {
62
- /* Designed for modal wrapper layout content while accounting for mobile header area */
63
- .max_h_extend_bottom { max-height: 80vh; }
121
+ /* Designed for modal wrapper layout content while accounting for mobile header area */
122
+ .max_h_extend_bottom {
123
+ max-height: 80vh;
124
+ }
64
125
  }
65
126
 
66
127
  @media (max-height: 640px) {
67
- /* Designed for modal wrapper layout content while accounting for mobile header area */
68
- .max_h_extend_bottom { max-height: 75vh; }
128
+ /* Designed for modal wrapper layout content while accounting for mobile header area */
129
+ .max_h_extend_bottom {
130
+ max-height: 75vh;
131
+ }
69
132
  }
70
133
 
71
134
  /* Common, standardized content wrapper sizes */
72
135
 
73
- .cw.tn, .mw.tn {
74
- /* was .tiny */
75
- max-width: 380px;
136
+ .cw.tn,
137
+ .mw.tn {
138
+ /* was .tiny */
139
+ max-width: 380px;
76
140
  }
77
141
 
78
- .cw.xs, .mw.xs {
79
- max-width: 425px;
142
+ .cw.xs,
143
+ .mw.xs {
144
+ max-width: 425px;
80
145
  }
81
146
 
82
- .cw.sm, .mw.sm {
83
- /* was .default_alt */
84
- max-width: 640px;
147
+ .cw.sm,
148
+ .mw.sm {
149
+ /* was .default_alt */
150
+ max-width: 640px;
85
151
  }
86
152
 
87
- .cw.df, .mw.df {
88
- max-width: 780px;
153
+ .cw.df,
154
+ .mw.df {
155
+ max-width: 780px;
89
156
  }
90
157
 
91
- .cw.md, .mw.md {
92
- max-width: 1140px;
158
+ .cw.md,
159
+ .mw.md {
160
+ max-width: 1140px;
93
161
  }
94
162
 
95
- .cw.lg, .mw.lg {
96
- max-width: 1280px;
163
+ .cw.lg,
164
+ .mw.lg {
165
+ max-width: 1280px;
97
166
  }
98
167
 
99
- .cw.xl, .mw.xl {
100
- max-width: 1440px;
168
+ .cw.xl,
169
+ .mw.xl {
170
+ max-width: 1440px;
101
171
  }
102
172
 
103
- .cw.full, .mw.full, .mw.max {
104
- flex: 1;
105
- max-height: 100%;
173
+ .cw.full,
174
+ .mw.full,
175
+ .mw.max {
176
+ flex: 1;
177
+ max-height: 100%;
106
178
  }
107
179
 
108
- .cw.full .cw, .mw.full .cw, .mw.max .cw {
109
- max-height: 100%;
180
+ .cw.full .cw,
181
+ .mw.full .cw,
182
+ .mw.max .cw {
183
+ max-height: 100%;
110
184
  }
111
185
 
112
- /* Max size modals */
186
+ /* Toolbar */
113
187
 
114
- .mw.max {
115
- background: radial-gradient(ellipse at center, rgba(var(--color-bg-alt), .7) 50%, rgba(var(--color-bg-alt), 0) 100%);
116
- /* background: radial-gradient(ellipse at center, rgba(var(--color-bg-active), .9) 50%, rgba(var(--color-bg-active), 0) 100%); */
117
- /* background: radial-gradient(ellipse at center, rgba(var(--color-bg-medium), .9) 50%, rgba(var(--color-bg-medium), 0) 100%); */
118
- /* background: radial-gradient(ellipse at center, rgba(var(--color-bg-strong), .9) 50%, rgba(var(--color-bg-strong), 0) 100%); */
188
+ .toolbar_input_click:hover:before,
189
+ .toolbar_input_click.editing:before {
190
+ content: "";
191
+ inset: -3px -9px -1px -8px;
192
+ border-radius: 100vmax;
193
+ pointer-events: none;
194
+ position: absolute;
119
195
  }
120
196
 
121
- /* Sidebar */
197
+ .toolbar_input_click:hover:before {
198
+ outline: 3px dashed rgba(var(--color-main), 0.75);
199
+ }
122
200
 
123
- .w_lsidebar {
124
- padding-right: var(--sidebar-wt);
201
+ .toolbar_input_click.editing:before,
202
+ .toolbar_input_click.editing:hover:before {
203
+ outline: 3px dashed rgb(var(--color-main));
125
204
  }
126
205
 
206
+ /* Sidebar */
207
+
127
208
  /* Content with right <aside /> sticky sidebar */
128
209
 
129
210
  .w_app_side {
130
- margin-right: var(--aside-wt);
211
+ padding-right: var(--aside-wt);
131
212
  }
132
213
 
133
214
  .app_aside {
134
- max-height: 100vh;
135
- top: 0; right: 0;
136
- padding-top: var(--toolbar-ht);
215
+ max-height: 100vh;
216
+ top: 0;
217
+ right: 0;
218
+ padding-top: var(--toolbar-ht);
219
+ }
220
+
221
+ /* Account for the toolbar's additional 40px filters row. */
222
+ .app_aside.with_toolbar_filters {
223
+ padding-top: calc(var(--toolbar-ht) + 40px);
224
+ }
225
+
226
+ @media (--gte-mobile-landscape) {
227
+ .app_aside:not(.without_scrollbar) {
228
+ right: var(--app-scrollbar-size);
229
+ }
137
230
  }
138
231
 
139
232
  /* Floating message */
140
233
 
141
234
  .floating_msg_cnt {
142
- transition: transform .2s ease-in-out, opacity .2s ease-in-out;
143
- transform: translateY(0);
235
+ pointer-events: none;
236
+ transition:
237
+ transform 0.2s ease-in-out,
238
+ opacity 0.2s ease-in-out;
239
+ width: max-content;
240
+ max-width: calc(100vw - 40px);
241
+ }
242
+
243
+ .floating_msg {
244
+ pointer-events: auto;
144
245
  }
145
246
 
146
247
  /* Helpers, to work with layout variables */
147
248
 
148
249
  .min_h_toolbar_screen {
149
- min-height: calc(100vh - var(--toolbar-ht));
250
+ min-height: calc(100vh - var(--toolbar-ht));
150
251
  }
151
252
 
152
253
  .max_h_toolbar_screen {
153
- max-height: calc(100vh - var(--toolbar-ht));
254
+ max-height: calc(100vh - var(--toolbar-ht));
154
255
  }
155
256
 
156
257
  /* App layout; account nav */
157
258
 
158
259
  #app_toolbar_right {
159
- position: absolute;
160
- top: 0; right: 0; z-index: 50;
161
- height: var(--toolbar-ht);
260
+ position: absolute;
261
+ top: 0;
262
+ right: 0;
263
+ z-index: 50;
264
+ height: var(--toolbar-ht);
162
265
  }
163
266
 
164
267
  /* App layout; sidebar */
165
268
 
269
+ .app_sidebar_edge_reveal {
270
+ background: linear-gradient(
271
+ 90deg,
272
+ rgba(var(--color-main), 0.125),
273
+ rgba(0, 0, 0, 0)
274
+ );
275
+ }
276
+
166
277
  #app_sidebar {
167
- position: relative;
168
- width: 0;
169
- overflow: hidden;
170
- transition: width ease .2s;
278
+ position: relative;
279
+ width: 0;
280
+ overflow: hidden;
281
+ transition: width ease 0.2s;
171
282
  }
172
283
 
173
284
  .open #app_sidebar {
174
- width: var(--sidebar-wt);
285
+ width: var(--sidebar-wt);
286
+ }
287
+
288
+ .overlayed #app_sidebar {
289
+ position: fixed;
290
+ z-index: 50;
291
+ top: 25px;
292
+ bottom: 25px;
293
+ left: 0;
294
+ width: 0;
295
+ overflow: visible;
175
296
  }
176
297
 
177
298
  .app_sidebar_inside {
178
- position: absolute;
179
- top: 0;
180
- left: calc(var(--sidebar-wt) * -1);
181
- bottom: 0;
182
- width: var(--sidebar-wt);
183
- transition: left ease .2s;
299
+ position: absolute;
300
+ top: 0;
301
+ left: calc(var(--sidebar-wt) * -1);
302
+ bottom: 0;
303
+ width: var(--sidebar-wt);
304
+ transition: left ease 0.2s;
184
305
  }
185
306
 
186
307
  .open .app_sidebar_inside {
187
- left: 0;
308
+ left: 0;
309
+ }
310
+
311
+ .overlayed .app_sidebar_inside {
312
+ left: 0;
313
+ border-top-right-radius: var(--radius-default);
314
+ border-bottom-right-radius: var(--radius-default);
315
+ background-color: rgb(var(--color-bg));
316
+ box-shadow:
317
+ var(--shadow-line),
318
+ 0 0 0 1px rgba(0, 0, 0, 0.05),
319
+ 10px 0 20px rgba(0, 0, 0, 0.05);
320
+ }
321
+
322
+ .overlayed.overlay_closing .app_sidebar_inside {
323
+ left: calc(var(--sidebar-wt) * -1);
188
324
  }
189
325
 
190
326
  .app_sidebar_inside_width {
191
- width: calc(var(--sidebar-wt) - 23px);
327
+ width: calc(var(--sidebar-wt) - 23px);
192
328
  }
193
329
 
194
330
  /* App layout; sidebar mobile responsive design */
195
331
 
196
332
  @media (--responsive-mobile-portrait) {
197
- #app_sidebar {
198
- width: 0;
199
- }
333
+ #app_sidebar {
334
+ width: 0;
335
+ }
200
336
  }
201
337
 
202
338
  /* App layout; main content (scroll area) */
203
339
 
204
340
  .app_scr {
205
- /* position: relative; */
206
- overflow-x: hidden;
207
- overflow-y: scroll;
341
+ --app-scrollbar-size: 19px;
342
+
343
+ /* position: relative; */
344
+ overflow-x: hidden;
345
+ overflow-y: scroll;
346
+ }
347
+
348
+ .app_scr.auto_y {
349
+ overflow-y: auto;
208
350
  }
209
351
 
210
352
  .app_scr.of_x {
211
- overflow-x: scroll;
353
+ overflow-x: scroll;
354
+ }
355
+
356
+ .app_scr.auto_x {
357
+ overflow-x: auto;
358
+ }
359
+
360
+ .app_scr.hide_y {
361
+ overflow-x: scroll;
362
+ overflow-y: hidden;
212
363
  }
213
364
 
214
365
  @media (--gte-mobile-portrait) {
215
- .app_scr {
216
- -webkit-overflow-scrolling: touch;
217
- /* scroll-behavior: smooth; */
218
- /* After a recent update, this no longer works in Chrome */
219
- /* overflow-y: overlay; */
220
- scrollbar-gutter: auto;
221
- /* In "new" Google Chrome, this will make the scrollbar invisible, so we must turn it off. */
222
- /* scrollbar-width: thin; */
223
-
224
- /* This is for bottom-up chat style virtualized list */
225
- overflow-anchor: none;
226
- }
227
-
228
- .app_scr::-webkit-scrollbar {
229
- width: 18px;
230
- height: 18px;
231
- /* background-color: rgb(var(--color-bg-active)); */
232
- background-color: rgb(var(--color-bg));
233
- /* border: solid 1px red; */
234
- }
235
-
236
- .app_scr::-webkit-scrollbar:vertical {
237
- border-left: solid 1px rgb(var(--color-bg-active));
238
- }
239
-
240
- .app_scr::-webkit-scrollbar:horizontal {
241
- border-top: solid 1px rgb(var(--color-bg-active));
242
- }
243
-
244
- .app_scr::-webkit-scrollbar-track {
245
- /* box-shadow: inset 0 0 0 5px rgb(var(--color-bg)); */
246
- border-radius: 9px;
247
- }
248
-
249
- .app_scr::-webkit-scrollbar-thumb {
250
- z-index: -1;
251
- /* Use this for invisible style */
252
- /* background-color: rgb(var(--color-bg-active)); */
253
- background-color: transparent;
254
- box-shadow: inset 0 0 0 5px rgb(var(--color-bg));
255
- /* transform: scale(.5); */
256
- border-radius: 9px;
257
- min-height: 100px;
258
- }
259
-
260
- .app_scr::-webkit-scrollbar-thumb {
261
- background-color: rgb(var(--color-bg-medium));
262
- /* background-color: rgb(var(--color-bg-active)); */
263
- }
264
-
265
- .app_scr:hover::-webkit-scrollbar-thumb {
266
- background-color: rgb(var(--color-bg-medium));
267
- /* background-color: rgb(var(--color-bg-active)); */
268
- }
269
-
270
- .app_scr::-webkit-scrollbar-thumb:active {
271
- background-color: rgb(var(--color-bg-strong));
272
- /* background-color: rgb(var(--color-bg-active)); */
273
- }
366
+ .app_scr {
367
+ -webkit-overflow-scrolling: touch;
368
+ /* After a recent update, this no longer works in Chrome */
369
+ /* overflow-y: overlay; */
370
+ scrollbar-gutter: auto;
371
+ /* In "new" Google Chrome, this will make the scrollbar invisible, so we must turn it off. */
372
+ /* scrollbar-width: thin; */
373
+
374
+ /* This is for bottom-up chat style virtualized list */
375
+ overflow-anchor: none;
376
+ }
377
+
378
+ .app_scr::-webkit-scrollbar {
379
+ /* This size must match SHEET_CANVAS_APP_SCROLLBAR_SIZE in @jsb188:sheet/src/modules/Sheet-Controller.tsx. */
380
+ width: var(--app-scrollbar-size);
381
+ height: var(--app-scrollbar-size);
382
+ background-color: rgb(var(--color-bg));
383
+ }
384
+
385
+ .app_scr::-webkit-scrollbar:vertical {
386
+ border-left: solid 1px rgb(var(--color-bg-active));
387
+ }
388
+
389
+ .app_scr::-webkit-scrollbar:horizontal {
390
+ border-top: solid 1px rgb(var(--color-bg-active));
391
+ }
392
+
393
+ .app_scr::-webkit-scrollbar-thumb:vertical {
394
+ border-left: solid 1px transparent;
395
+ }
396
+
397
+ .app_scr::-webkit-scrollbar-thumb:horizontal {
398
+ border-top: solid 1px transparent;
399
+ }
400
+
401
+ .app_scr::-webkit-scrollbar-thumb {
402
+ z-index: -1;
403
+ /* transform: scale(.5); */
404
+ border-radius: 10px;
405
+ min-height: 100px;
406
+ background-clip: padding-box;
407
+ background-color: rgb(var(--color-bg-active));
408
+ box-shadow: inset 0 0 0 5px rgb(var(--color-bg));
409
+ }
410
+
411
+ .app_scr:hover::-webkit-scrollbar-thumb {
412
+ /* background-color: rgb(var(--color-bg-medium)); */
413
+ background-color: rgb(var(--color-bg-active));
414
+ }
415
+
416
+ .app_scr::-webkit-scrollbar-thumb:active {
417
+ /* background-color: rgb(var(--color-bg-strong)); */
418
+ background-color: rgb(var(--color-bg-medium));
419
+ /* background-color: rgb(var(--color-bg-active)); */
420
+ }
421
+
422
+ .app_scr::-webkit-scrollbar-corner {
423
+ background-color: rgb(var(--color-bg));
424
+ border-top: solid 1px rgb(var(--color-bg-active));
425
+ border-left: solid 1px rgb(var(--color-bg-active));
426
+ box-shadow: 0 0 10px rgb(0, 0, 0, 0.125) inset;
427
+ }
274
428
  }