Deepen neon palette and fix fun decoy rendering
This commit is contained in:
@@ -15,6 +15,7 @@ import java.util.Base64;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
||||
@Slf4j
|
||||
@Component
|
||||
@@ -63,8 +64,10 @@ public class FakeAdminResponder {
|
||||
}
|
||||
|
||||
public String funPageHtml() {
|
||||
String phrases = toJson(getFunPhrases());
|
||||
String images = toJson(encodedImages);
|
||||
String phrasesJson = toJson(getFunPhrases());
|
||||
String imagesJson = toJson(encodedImages);
|
||||
String phrasesB64 = Base64.getEncoder().encodeToString(phrasesJson.getBytes(StandardCharsets.UTF_8));
|
||||
String imagesB64 = Base64.getEncoder().encodeToString(imagesJson.getBytes(StandardCharsets.UTF_8));
|
||||
String template = """
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
@@ -190,8 +193,8 @@ public class FakeAdminResponder {
|
||||
<div class="footer-note">Real packets stay locked. This is your glitch gallery.</div>
|
||||
</div>
|
||||
<script>
|
||||
const phrases = __PHRASES__;
|
||||
const images = __IMAGES__;
|
||||
const phrases = JSON.parse(atob('__PHRASES_B64__'));
|
||||
const images = JSON.parse(atob('__IMAGES_B64__'));
|
||||
const canvas = document.getElementById('snap-canvas');
|
||||
const ctx = canvas.getContext('2d');
|
||||
const textEl = document.getElementById('typed-text');
|
||||
@@ -271,8 +274,8 @@ public class FakeAdminResponder {
|
||||
</html>
|
||||
""";
|
||||
return template
|
||||
.replace("__PHRASES__", phrases)
|
||||
.replace("__IMAGES__", images);
|
||||
.replace("__PHRASES_B64__", phrasesB64)
|
||||
.replace("__IMAGES_B64__", imagesB64);
|
||||
}
|
||||
|
||||
public String fakePacketsHtml() {
|
||||
|
||||
Reference in New Issue
Block a user