Skip to content

Commit 2aa6bfd

Browse files
committed
Working noscript message
1 parent 9a156db commit 2aa6bfd

File tree

3 files changed

+7
-16
lines changed

3 files changed

+7
-16
lines changed

src/index.html

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,12 @@
2020
<link href="/css/bootstrap.min.css" rel="stylesheet">
2121
</head>
2222

23-
<body class="h-100">
23+
<body class="h-100 w-100 d-flex">
2424
<script type="module" src="./index.ts"></script>
25-
<div class="scriptonly" id="loading">
25+
<div class="h-100 w-100 align-items-center justify-content-center scriptonly" id="loading">
2626
<img src="/images/spinner.gif" alt="Loading..." />
2727
</div>
28-
<div id="emojitable" style="display:none">
29-
</div>
28+
<div id="emojitable" class="d-none w-100 h-100"></div>
3029
<div id="errdiv" class="d-none d-flex flex-column justify-content-center align-items-center w-100 h-100">
3130
<div class="alert alert-danger m-3" role="alert">
3231
<img class="pe-2" src="/images/stop.svg" alt="Error" width="100" height="100" />
@@ -37,7 +36,7 @@
3736
<div class="d-flex flex-column justify-content-center align-items-center w-100 h-100">
3837
<div class="d-flex flex-row align-items-center alert alert-danger m-3" role="alert">
3938
<img class="pe-2" src="/images/stop.svg" alt="Error" width="100" height="100" />
40-
<span class="fs-4">EmojiSearch requires JavaScript. Try <a href="https://www.fileformat.info/info/emoji/">FileFormat.Info</a> to search without Javascript.</span>
39+
<span class="fs-4">EmojiSearch requires JavaScript. Try <a href="https://www.fileformat.info/info/emoji/list.htm">FileFormat.Info</a> to search without Javascript.</span>
4140
</div>
4241
</div>
4342
</noscript>

src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,8 @@ async function main() {
452452
}
453453
});
454454

455-
document.getElementById("loading")!.style.display = "none";
456-
document.getElementById("emojitable")!.style.display = "block";
455+
document.getElementById("loading")!.classList.add("d-none");
456+
document.getElementById("emojitable")!.classList.remove("d-none");
457457
}
458458

459459
main();

src/styles.css

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,9 @@ html, body {
77
}
88

99
body {
10-
background-color: #f0f0f0;
1110
font-family: sans-serif;
1211
}
1312

14-
div#loading {
15-
width: 100%;
16-
height: 100%;
17-
display: flex;
18-
justify-content: center;
19-
align-items: center;
20-
background-color: white;
21-
}
13+
2214

2315

0 commit comments

Comments
 (0)