about summary refs log tree commit diff
path: root/web
diff options
context:
space:
mode:
authorEric Bailey <git@esb.lol>2024-09-23 15:21:32 -0500
committerGitHub <noreply@github.com>2024-09-23 15:21:32 -0500
commite1ee95a7193501fce13d0bbdee57963901635741 (patch)
treef3c4e8be4a70f8085c00a7c1807f3165b844b3d5 /web
parentb77031a074161f8c6cd7e666db324eea81a38af1 (diff)
downloadvoidsky-e1ee95a7193501fce13d0bbdee57963901635741.tar.zst
Fix web splash (#5456)
* Fix web splash

* Untangle base styles

* Fix id name, remove log
Diffstat (limited to 'web')
-rw-r--r--web/index.html49
1 files changed, 48 insertions, 1 deletions
diff --git a/web/index.html b/web/index.html
index 512178327..71e5ac089 100644
--- a/web/index.html
+++ b/web/index.html
@@ -36,6 +36,53 @@
     <link rel="preload" as="font" type="font/otf" href="/static/media/Inter-Black.66e9a87f1c921e844ed4.otf">
     <link rel="preload" as="font" type="font/otf" href="/static/media/Inter-BlackItalic.27b9f0ad06fd13a7b9da.otf">
     -->
+
+    <style>
+      /**
+       * Minimum styles required to render splash.
+       *
+       * ALL OTHER STYLES BELONG IN `src/style.css`
+       *
+       * THIS NEEDS TO BE DUPLICATED IN `bskyweb/templates/base.html`
+       */
+      html {
+        background-color: white;
+        scrollbar-gutter: stable both-edges;
+      }
+      @media (prefers-color-scheme: dark) {
+        html {
+          background-color: black;
+        }
+      }
+      html,
+      body {
+        margin: 0px;
+        padding: 0px;
+        font-family: 'Inter-Regular', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Liberation Sans', Helvetica, Arial, sans-serif;
+        text-rendering: optimizeLegibility;
+        /* Platform-specific reset */
+        -webkit-overflow-scrolling: touch;
+        -webkit-text-size-adjust: 100%;
+        -webkit-font-smoothing: antialiased;
+        -moz-osx-font-smoothing: grayscale;
+        -ms-overflow-style: scrollbar;
+        font-synthesis-weight: none;
+      }
+      html,
+      body,
+      #root {
+        display: flex;
+        flex: 1 0 auto;
+        min-height: 100%;
+      }
+      #splash {
+        position: fixed;
+        width: 100px;
+        left: 50%;
+        top: 50%;
+        transform: translateX(-50%) translateY(-50%) translateY(-50px);
+      }
+    </style>
   </head>
 
   <body>
@@ -90,7 +137,7 @@
 
     <!-- The root element for your Expo app. -->
     <div id="root">
-      <div id="preload">
+      <div id="splash">
         <!-- Bluesky SVG -->
         <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 360 320"><path fill="#0085ff" d="M180 142c-16.3-31.7-60.7-90.8-102-120C38.5-5.9 23.4-1 13.5 3.4 2.1 8.6 0 26.2 0 36.5c0 10.4 5.7 84.8 9.4 97.2 12.2 41 55.7 55 95.7 50.5-58.7 8.6-110.8 30-42.4 106.1 75.1 77.9 103-16.7 117.3-64.6 14.3 48 30.8 139 116 64.6 64-64.6 17.6-97.5-41.1-106.1 40 4.4 83.5-9.5 95.7-50.5 3.7-12.4 9.4-86.8 9.4-97.2 0-10.3-2-27.9-13.5-33C336.5-1 321.5-6 282 22c-41.3 29.2-85.7 88.3-102 120Z"/></svg>
       </div>