Explorar o código

Added more loading messages

n1474335 %!s(int64=8) %!d(string=hai) anos
pai
achega
ab1c9e27dc
Modificáronse 2 ficheiros con 12 adicións e 7 borrados
  1. 10 5
      src/web/html/index.html
  2. 2 2
      src/web/stylesheets/preloader.css

+ 10 - 5
src/web/html/index.html

@@ -48,10 +48,15 @@
                 "Initialising Skynet...",
                 "[REDACTED]",
                 "Downloading more RAM...",
-                "Loading more loading messages...",
                 "Ordering 1s and 0s...",
                 "Navigating neural network...",
-                "Importing machine learning..."
+                "Importing machine learning...",
+                "Issuing Alice and Bob one-time pads...",
+                "Mining bitcoin cash...",
+                "Generating key material by trying to escape vim...",
+                "for i in range(additional): Pylon()",
+                "(creating unresolved tension...",
+                "Symlinking emacs and vim to ed...",
             ];
 
             // Shuffle array using Durstenfeld algorithm
@@ -62,19 +67,19 @@
                 loadingMsgs[j] = temp;
             }
 
-            // Show next loading message then move it to the end of the array
+            // Show next loading message and move it to the end of the array
             function changeLoadingMsg() {
                 const msg = loadingMsgs.shift();
+                loadingMsgs.push(msg);
                 try {
                     const el = document.getElementById("preloader-msg");
                     el.className = "loading"; // Causes CSS transition on first message
                     el.innerHTML = msg;
                 } catch (err) {} // Ignore errors if DOM not yet ready
-                loadingMsgs.push(msg);
             }
 
             changeLoadingMsg();
-            window.loadingMsgsInt = setInterval(changeLoadingMsg, (Math.random() * 1000) + 1000);
+            window.loadingMsgsInt = setInterval(changeLoadingMsg, (Math.random() * 2000) + 1500);
         </script>
         <% if (!htmlWebpackPlugin.options.inline) { %>
             <script type="application/ld+json">

+ 2 - 2
src/web/stylesheets/preloader.css

@@ -62,8 +62,8 @@
 #preloader-msg {
     display: block;
     position: relative;
-    width: 300px;
-    left: calc(50% - 150px);
+    width: 400px;
+    left: calc(50% - 200px);
     top: calc(50% + 50px);
     text-align: center;
     margin-top: 50px;