Skip to content

Commit

Permalink
Hide shortcuts when using a touch screen
Browse files Browse the repository at this point in the history
  • Loading branch information
rosslh committed Jan 20, 2025
1 parent e8faaf2 commit 978a272
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 17 deletions.
38 changes: 25 additions & 13 deletions client/css/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -128,24 +128,36 @@ html.fractal-root {
padding-top: 0;
flex-direction: column;

.shortcut-hint {
text-decoration: underline;
}
#shortcuts {
.shortcut-hint {
text-decoration: underline;
}

.checkbox-wrapper {
display: flex;
align-items: center;
gap: var(--space-4);
}
.checkbox-wrapper {
display: flex;
align-items: center;
gap: var(--space-4);
}

.shortcut-wrapper {
display: flex;
align-items: center;
gap: var(--space-8);
.shortcut-wrapper {
display: flex;
align-items: center;
gap: var(--space-8);

#macShortcut {
#macShortcut {
display: none;
}
}
}

@media (pointer: coarse) {
#shortcuts {
display: none;
}

#shortcuts + details {
border-top: none;
}
}

.iteration-buttons {
Expand Down
2 changes: 1 addition & 1 deletion client/html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ <h1 class="nav-heading">
</div>
</div>
<div id="inputsWrapper" class="overlay">
<details open class="mobile-hidden">
<details open class="mobile-hidden" id="shortcuts">
<summary><span>Shortcuts</span></summary>
<div class="details-content">
<div class="shortcut-wrapper">
Expand Down
5 changes: 2 additions & 3 deletions client/static/site.webmanifest
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"categories": ["education", "entertainment", "games"],
"description": "Explore the infinite complexity of the Mandelbrot Set with this online fractal viewer. Zoom in and generate high resolution images.",
"dir": "ltr",
"display": "standalone",
"display": "minimal-ui",
"icons": [
{
"purpose": "maskable",
Expand All @@ -29,6 +29,5 @@
"name": "Mandelbrot Set Explorer",
"orientation": "any",
"short_name": "Mandelbrot.site",
"start_url": "/",
"theme_color": "#000000"
"start_url": "/"
}

0 comments on commit 978a272

Please sign in to comment.