Skip to content

Commit 0936d52

Browse files
authored
feat(shadertoy): show fullscreen button only on widget hover, add min-height (#281)
1 parent b78cd74 commit 0936d52

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

examples/shadertoy-server/src/mcp-app.css

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,15 @@ html, body {
22
margin: 0;
33
width: 100%;
44
height: 100%;
5+
min-height: 400px;
56
overflow: hidden;
67
}
78

89
.main {
910
position: relative;
1011
width: 100%;
1112
height: 100%;
13+
min-height: 400px;
1214
}
1315

1416
#canvas {
@@ -33,7 +35,7 @@ html, body {
3335
align-items: center;
3436
justify-content: center;
3537
transition: background 0.2s, opacity 0.2s;
36-
opacity: 0.7;
38+
opacity: 0; /* Initially invisible, shown on widget hover */
3739
z-index: 100;
3840
}
3941

@@ -55,6 +57,11 @@ html, body {
5557
display: flex;
5658
}
5759

60+
/* Show button on widget hover */
61+
.main:hover .fullscreen-btn.available {
62+
opacity: 0.7;
63+
}
64+
5865
/* Fullscreen mode */
5966
.main.fullscreen .fullscreen-btn .expand-icon {
6067
display: none;

0 commit comments

Comments
 (0)