Skip to content

Commit

Permalink
feat: iOS PWA
Browse files Browse the repository at this point in the history
  • Loading branch information
lideming committed Jan 20, 2025
1 parent 90ad47f commit 6213520
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 3 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width,user-scalable=0" />
<meta name="viewport" content="width=device-width,user-scalable=0,viewport-fit=cover" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<meta name="mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
<meta id="meta-theme-color" name="theme-color" content="" />
<link rel="manifest" href="resources/manifest.json" />
<link rel="icon" href="resources/app_icon.svg" type="image/svg+xml" />
<link rel="apple-touch-icon" href="resources/app_icon.svg" />
<title>Music Cloud</title>
<!-- Preload style -->
<style>
Expand Down
2 changes: 1 addition & 1 deletion resources/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "MusicCloud",
"short_name": "MusicCloud",
"start_url": "..",
"display": "minimal-ui",
"display": "standalone",
"background_color": "#fff",
"description": "MusicCloud for Web",
"icons": [
Expand Down
6 changes: 4 additions & 2 deletions style.less
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ body {
background: var(--color-bg);
color: var(--color-text);
--bottombar-height: 70px;
--page-padding-bottom: 0;
--page-padding-bottom: env(safe-area-inset-bottom);
height: 100%;
overflow: hidden;
}
Expand Down Expand Up @@ -208,7 +210,7 @@ a {
}
}
#main-container {
height: calc(100% - var(--bottombar-height));
height: calc(100% - var(--bottombar-height) - var(--page-padding-bottom));
position: relative;
contain: strict;
&::after {
Expand Down Expand Up @@ -725,7 +727,7 @@ a {
}
.bottombar {
position: fixed;
bottom: 0;
bottom: var(--page-padding-bottom);
width: 100%;
display: flex;
height: var(--bottombar-height);
Expand Down

0 comments on commit 6213520

Please sign in to comment.