Skip to content

Commit a77f297

Browse files
ofriwclaude
andcommitted
Implement fixed layout structure for consistent slide positioning
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent bc38dc6 commit a77f297

File tree

1 file changed

+82
-18
lines changed

1 file changed

+82
-18
lines changed

website/src/components/PresentationMode/RevealSlideshow.module.css

Lines changed: 82 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,14 @@
4343
}
4444

4545
.objectives {
46-
margin-top: 2em;
46+
margin-top: 0;
4747
text-align: left;
4848
max-width: 90%;
4949
margin-left: auto;
5050
margin-right: auto;
51+
display: flex;
52+
flex-direction: column;
53+
justify-content: center;
5154
}
5255

5356
.objectives h3 {
@@ -79,10 +82,13 @@
7982
text-align: left;
8083
font-size: clamp(1rem, 2vw, 1.2em);
8184
line-height: 1.6;
82-
margin: 1em 0;
85+
margin: 0;
8386
max-width: 90%;
8487
margin-left: auto;
8588
margin-right: auto;
89+
display: flex;
90+
flex-direction: column;
91+
justify-content: center;
8692
}
8793

8894
.bulletList li {
@@ -92,30 +98,38 @@
9298
.codeBlock {
9399
font-size: 0.8em;
94100
line-height: 1.4;
95-
margin: 1em 0;
101+
margin: 0;
96102
border-radius: 8px;
97103
background: #1e1e1e;
98104
padding: 1em;
99105
text-align: left;
106+
overflow: auto;
107+
height: 100%;
108+
display: flex;
109+
align-items: center;
100110
}
101111

102112
.codeBlock code {
103113
font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
104114
}
105115

106116
.caption {
107-
font-size: 0.9em;
108-
color: #999;
109-
margin-top: 1em;
117+
font-size: clamp(0.8rem, 1.5vw, 0.95em);
118+
line-height: 1.4;
119+
color: #e0e0e0;
120+
margin-top: 0.5em;
110121
font-style: italic;
122+
font-weight: 500;
111123
}
112124

113125
.comparison {
114126
display: grid;
115127
grid-template-columns: 1fr 1fr;
116128
gap: clamp(1em, 2vw, 1.5em);
117-
margin: 1em 0;
118-
max-height: 400px;
129+
margin: 1.5em 0 0.5em 0;
130+
flex: 1;
131+
min-height: 0;
132+
max-height: none;
119133
}
120134

121135
.comparisonLeft,
@@ -151,13 +165,13 @@
151165

152166
.comparison ul {
153167
text-align: left;
154-
font-size: clamp(0.65rem, 1.3vw, 0.75em);
168+
font-size: clamp(0.85rem, 1.6vw, 0.95em);
155169
list-style: none;
156170
padding: 0;
157171
}
158172

159173
.comparison li {
160-
margin: 0.35em 0;
174+
margin: 0.45em 0;
161175
padding-left: 1.2em;
162176
position: relative;
163177
line-height: 1.4;
@@ -182,8 +196,9 @@
182196
display: grid;
183197
grid-template-columns: 1fr 1fr;
184198
gap: clamp(1em, 2vw, 1.5em);
185-
margin: 1em 0;
186-
max-height: 400px;
199+
margin: 0;
200+
height: 100%;
201+
max-height: none;
187202
}
188203

189204
.metaphorColumn,
@@ -241,22 +256,33 @@
241256
}
242257

243258
.visualContainer {
244-
margin: 2em 0;
245259
display: flex;
246260
justify-content: center;
247261
align-items: center;
262+
overflow: visible;
263+
width: 100%;
264+
height: 85%;
265+
transform: scale(1.5);
266+
transform-origin: center center;
267+
}
268+
269+
.visualContainer > * {
270+
object-fit: contain;
248271
}
249272

250273
.takeawayList {
251274
text-align: left;
252275
font-size: clamp(0.9rem, 1.8vw, 1.1em);
253276
line-height: 1.6;
254-
margin: 1em 0;
277+
margin: 0;
255278
list-style: none;
256279
padding: 0;
257280
max-width: 90%;
258281
margin-left: auto;
259282
margin-right: auto;
283+
display: flex;
284+
flex-direction: column;
285+
justify-content: center;
260286
}
261287

262288
.takeawayList li {
@@ -277,9 +303,9 @@
277303
.executionFlow {
278304
text-align: left;
279305
max-width: 90%;
280-
margin: 1em auto;
306+
margin: 0 auto;
281307
padding: 0.5em;
282-
max-height: 450px;
308+
height: 100%;
283309
overflow-y: auto;
284310
}
285311

@@ -427,7 +453,7 @@
427453
}
428454

429455
:global(.reveal h1) {
430-
font-size: clamp(1.8rem, 3.5vw, 2.2em);
456+
font-size: clamp(2.5rem, 4.5vw, 3.0em);
431457
color: var(--ifm-color-primary);
432458
max-width: 90%;
433459
margin-left: auto;
@@ -464,11 +490,49 @@
464490
background: var(--ifm-color-primary);
465491
}
466492

467-
/* Ensure slide content fits within viewport */
493+
/* Fixed layout structure for consistent positioning across slides */
468494
:global(.reveal .slides section) {
469495
max-width: 95%;
470496
margin-left: auto;
471497
margin-right: auto;
498+
height: 100%;
499+
display: flex;
500+
flex-direction: column;
501+
justify-content: flex-start;
502+
padding: 1em 0 2.5em 0;
503+
box-sizing: border-box;
504+
}
505+
506+
/* Title area - fixed height and position */
507+
:global(.reveal .slides section > h2) {
508+
margin-top: 0;
509+
margin-bottom: 0.5em;
510+
flex-shrink: 0;
511+
}
512+
513+
/* Title slides have h1 instead */
514+
:global(.reveal .slides section > h1) {
515+
margin-top: 2em;
516+
margin-bottom: 1em;
517+
flex-shrink: 0;
518+
}
519+
520+
/* Content area - fills remaining space */
521+
:global(.reveal .slides section) > *:not(h1):not(h2):not(.slideCaption):not(.comparison):not(.marketingReality) {
522+
flex-grow: 1;
523+
display: flex;
524+
flex-direction: column;
525+
justify-content: center;
526+
min-height: 0;
527+
}
528+
529+
/* Caption area - fixed at bottom when present */
530+
.slideCaption {
531+
margin-top: auto;
532+
margin-bottom: 0;
533+
flex-shrink: 0;
534+
padding-top: 0.5em;
535+
padding-bottom: 0;
472536
}
473537

474538
:global(.reveal p),

0 commit comments

Comments
 (0)