-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathreader.html
More file actions
119 lines (107 loc) · 3.65 KB
/
Copy pathreader.html
File metadata and controls
119 lines (107 loc) · 3.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width" />
<meta name="theme-color" content="cyan" />
<meta name="author" content="M A Eyler, Istanbul, 2019" />
<meta name="description" content="Reader for the Quran" />
<link rel="stylesheet" href="code/reader.css" media="all">
<!-- <link rel="manifest" href="manifest.json"> -->
<link rel="icon" href="image/icon.png">
<title>Iqra</title>
</head>
<body>
<div id=div3>
<b id=title></b>
<select id=sureS title='Sure seçin (liste mushaf sırasında)'></select>
<button id=pageS title='Sayfa no girin veya yıldızlı sayfayı seçin'>
Sayfa <span id=sayfa></span>
</button>
<button id=starB title='Bu sayfaya yıldız koy/kaldır'> </button>
<button id=trans title='Meal sayfasını göster/gizle'> </button>
<button id=zoomB title='Sayfayı geçici olarak büyüt'> </button>
<button id=linkB title='Sayfa menüsü'> </button>
</div>
<div id=div2>
<div id=text class=hiddenNarrow>Türkçe meal yükleniyor</div>
<div id=html readonly>Kuran metni yükleniyor</div>
<div id=div0></div>
</div>
<div id=div1>
<div id=leftB title='Önceki sayfa'></div>
<input id=slider type=range min=1 max=604 value=1
title='Aranan sayfaya geçmek için slider'>
<span id=infoS></span>
<div id=rightB title='Sonraki sayfa'></div>
</div>
<span id=bilgi>tooltip for each word and each verse</span>
<div id=menuS class=menu>
Sayfa <input id=pgNum type=number min=1 max=604 value=1>
<hr> <span id=starred>star menu</span>
</div>
<div id=menuC class=menu>
<span class="menuC">Kopyala</span>
<span class="menuC">Mucem</span>
<span class="menuC">Finder</span>
<!--span class="menuC">Benzer</span-->
</div>
<div id=menuK class=menu>
<span class="menuK">quran.com</span>
<span class="menuK">corpus.quran.com</span>
<span class="menuK">kuranmeali.com</span>
<span class="menuK">acikkuran.com</span>
<hr><div id=version></div>
<span class="menuK">Dokümanlar -- F1</span>
<span class="menuK">Yer işaretleri</span>
<span class="menuK" id=add2hs hidden
title='Web sayfasını uygulama olarak aç'>Install PWA</span>
<!-- display property overrides the hidden attribute -->
</div>
<div id=menuV class=menu>
<span class="menuK">quran.com</span>
<span class="menuK">corpus.quran.com</span>
<span class="menuK">kuranmeali.com</span>
<span class="menuK">acikkuran.com</span>
</div>
<script src="code/buckwalter.js"></script>
<script src="code/common.js"></script>
<script src="code/model.js"></script>
<script src="code/utilities.js"></script>
<script src="code/submitForm.js"></script>
<script src="code/reader.js"></script>
<script> //type="module">
// import * as Q from "./code/reader.js"
// console.log(Q)
if (navigator.serviceWorker) {
navigator.serviceWorker.register('sw.js')
.then(reg => { console.log('Service worker', reg.scope) })
.catch(alert)
}
//initReader()
/**
* BeforeInstallPromptEvent saved for later use
*/
var pevt
/**
* Prevent Chrome from showing the InstallPrompt
* from https://love2dev.com/blog/beforeinstallprompt/
*
* @param {BeforeInstallPromptEvent} e
*/
function beforeinstallCB(e) {
function addToHomeScreen() {
pevt.prompt() //ask user
pevt.userChoice.then(console.log)
add2hs.style.display = 'none'
pevt = null; hideMenus()
}
e.preventDefault(); pevt = e
add2hs.style.display = '' //show button
add2hs.onclick = addToHomeScreen
}
window.onbeforeinstallprompt = beforeinstallCB
add2hs.style.display = 'none' //hide button at start
</script>
</body>
</html>