src/surah.html: add title to page

Fix #4
This commit is contained in:
0x1eef 2022-11-01 05:55:44 -03:00 committed by Robert
parent 93c8b110b8
commit e3c794448f
2 changed files with 8 additions and 4 deletions

View file

@ -19,6 +19,9 @@ function TheSurahPage({locale, surahId}: PageProps) {
useEffect(() => {
if (surahIsLoaded) {
document.title = ["Al-Quran:",
surah.transliteratedName,
`(${surah.translatedName})`].join(" ");
setStream([surah.ayat[stream.length]]);
}
}, [surahIsLoaded]);

View file

@ -1,10 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title>Al-Quran: Loading</title>
<link rel="stylesheet" href="/css/surah.css">
</head>
<body>
<div class="surah"></div>
<script src="/js/pages/surah.js"></script>
</body>
<body>
<div class="surah"></div>
<script src="/js/pages/surah.js"></script>
</body>
</html>