AzraelH commited on
Commit
fb25ff5
·
1 Parent(s): 40ba97e

Fix HF Space layout stability

Browse files
Files changed (1) hide show
  1. server/app.py +32 -6
server/app.py CHANGED
@@ -44,11 +44,18 @@ WEB_CSS = dedent(
44
  --meeting: #f5c76a;
45
  --empty: rgba(255, 255, 255, 0.06);
46
  --danger: #ff8d8d;
 
 
 
47
  }
48
  * { box-sizing: border-box; }
 
 
 
 
49
  body {
50
  margin: 0;
51
- min-height: 100vh;
52
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
53
  color: var(--text);
54
  background:
@@ -56,7 +63,7 @@ WEB_CSS = dedent(
56
  linear-gradient(180deg, #09111d 0%, #07111f 100%);
57
  }
58
  .shell {
59
- max-width: 1180px;
60
  margin: 0 auto;
61
  padding: 32px 20px 40px;
62
  }
@@ -87,7 +94,8 @@ WEB_CSS = dedent(
87
  }
88
  .grid {
89
  display: grid;
90
- grid-template-columns: 300px minmax(0, 1fr);
 
91
  gap: 18px;
92
  margin-top: 18px;
93
  }
@@ -191,14 +199,32 @@ WEB_CSS = dedent(
191
  max-height: 260px;
192
  color: #d7e6ff;
193
  }
 
 
 
 
 
 
194
  .status {
195
  margin-top: 12px;
196
  min-height: 24px;
197
  color: var(--muted);
198
  }
199
  .status.error { color: var(--danger); }
200
- @media (max-width: 920px) {
201
- .grid, .metrics { grid-template-columns: 1fr; }
 
 
 
 
 
 
 
 
 
 
 
 
202
  .actions { grid-template-columns: 1fr; }
203
  .actions button[data-op="0"] { grid-column: span 1; }
204
  }
@@ -360,7 +386,7 @@ WEB_PAGE = dedent(
360
  <h2 class="section-title">Timeline</h2>
361
  <div id="timeline" class="timeline"></div>
362
 
363
- <div style="display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:16px;">
364
  <section>
365
  <h2 class="section-title">Task Buffer</h2>
366
  <ul id="tasks" class="task-list"></ul>
 
44
  --meeting: #f5c76a;
45
  --empty: rgba(255, 255, 255, 0.06);
46
  --danger: #ff8d8d;
47
+ --shell-max: 1180px;
48
+ --sidebar-width: 300px;
49
+ --content-min: 620px;
50
  }
51
  * { box-sizing: border-box; }
52
+ html {
53
+ min-height: 100%;
54
+ background: #07111f;
55
+ }
56
  body {
57
  margin: 0;
58
+ min-height: 100%;
59
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
60
  color: var(--text);
61
  background:
 
63
  linear-gradient(180deg, #09111d 0%, #07111f 100%);
64
  }
65
  .shell {
66
+ width: min(100%, var(--shell-max));
67
  margin: 0 auto;
68
  padding: 32px 20px 40px;
69
  }
 
94
  }
95
  .grid {
96
  display: grid;
97
+ grid-template-columns: minmax(260px, var(--sidebar-width)) minmax(var(--content-min), 1fr);
98
+ align-items: start;
99
  gap: 18px;
100
  margin-top: 18px;
101
  }
 
199
  max-height: 260px;
200
  color: #d7e6ff;
201
  }
202
+ .details-grid {
203
+ display: grid;
204
+ grid-template-columns: repeat(2, minmax(0, 1fr));
205
+ gap: 16px;
206
+ margin-top: 16px;
207
+ }
208
  .status {
209
  margin-top: 12px;
210
  min-height: 24px;
211
  color: var(--muted);
212
  }
213
  .status.error { color: var(--danger); }
214
+ @media (max-width: 1040px) {
215
+ :root {
216
+ --content-min: 0px;
217
+ }
218
+ .metrics {
219
+ grid-template-columns: repeat(2, minmax(0, 1fr));
220
+ }
221
+ }
222
+ @media (max-width: 760px) {
223
+ .grid,
224
+ .metrics,
225
+ .details-grid {
226
+ grid-template-columns: 1fr;
227
+ }
228
  .actions { grid-template-columns: 1fr; }
229
  .actions button[data-op="0"] { grid-column: span 1; }
230
  }
 
386
  <h2 class="section-title">Timeline</h2>
387
  <div id="timeline" class="timeline"></div>
388
 
389
+ <div class="details-grid">
390
  <section>
391
  <h2 class="section-title">Task Buffer</h2>
392
  <ul id="tasks" class="task-list"></ul>