Merge branch 'front' of https://git.sitenevis.com/Reza_ashrafi/danovin into front
commit
f9594a8109
3 changed files with 86 additions and 72 deletions
@ -1,76 +1,85 @@ |
|||||||
<!DOCTYPE html> |
<!DOCTYPE html> |
||||||
<html lang="en"> |
<html lang="en"> |
||||||
|
<head> |
||||||
|
<meta charset="utf-8" /> |
||||||
|
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" /> |
||||||
|
<meta |
||||||
|
name="viewport" |
||||||
|
content="width=device-width, initial-scale=1" |
||||||
|
user-scalable="false" |
||||||
|
/> |
||||||
|
<meta name="theme-color" content="#000000" /> |
||||||
|
<meta name="description" content="دانوین" /> |
||||||
|
<link |
||||||
|
href="https://api.mapbox.com/mapbox-gl-js/v1.10.1/mapbox-gl.css" |
||||||
|
rel="stylesheet" |
||||||
|
/> |
||||||
|
<meta name="mobile-web-app-capable" content="yes" /> |
||||||
|
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" /> |
||||||
|
<meta name="apple-mobile-web-app-capable" content="yes" /> |
||||||
|
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" /> |
||||||
|
|
||||||
<head> |
<title>دانوین</title> |
||||||
<meta charset="utf-8" /> |
<!-- Google Tag Manager --> |
||||||
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" /> |
<script src="ar.js"></script> |
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="false" /> |
<script src="en.js"></script> |
||||||
<meta name="theme-color" content="#000000" /> |
<script> |
||||||
<meta name="description" content="دانوین" /> |
const lang = localStorage.getItem("language"); |
||||||
<link href="https://api.mapbox.com/mapbox-gl-js/v1.10.1/mapbox-gl.css" rel="stylesheet" /> |
window.ar = ar; |
||||||
<meta name="mobile-web-app-capable" content="yes" /> |
window.en = en; |
||||||
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" /> |
function t(val) { |
||||||
<meta name="apple-mobile-web-app-capable" content="yes" /> |
const lang_ = window[lang]; |
||||||
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" /> |
if (!lang_) return val; |
||||||
|
if (!lang_[val]) console.error(val); |
||||||
|
return lang_[val] || "*" + val; |
||||||
|
} |
||||||
|
|
||||||
<title>دانوین</title> |
(function (w, d, s, l, i) { |
||||||
<!-- Google Tag Manager --> |
w[l] = w[l] || []; |
||||||
<script src="ar.js"></script> |
w[l].push({ |
||||||
<script src="en.js"></script> |
"gtm.start": new Date().getTime(), |
||||||
<script> |
event: "gtm.js", |
||||||
const lang = localStorage.getItem("language"); |
}); |
||||||
window.ar = ar; |
var f = d.getElementsByTagName(s)[0], |
||||||
window.en = en |
j = d.createElement(s), |
||||||
function t(val) { |
dl = l != "dataLayer" ? "&l=" + l : ""; |
||||||
|
j.async = true; |
||||||
|
j.src = "https://www.googletagmanager.com/gtm.js?id=" + i + dl; |
||||||
|
f.parentNode.insertBefore(j, f); |
||||||
|
})(window, document, "script", "dataLayer", "GTM-WVV8H9L"); |
||||||
|
</script> |
||||||
|
<!-- End Google Tag Manager --> |
||||||
|
</head> |
||||||
|
|
||||||
const lang_ = window[lang] |
<body> |
||||||
if (!lang_) return val; |
<!-- Google Tag Manager (noscript) --> |
||||||
if (!lang_[val]) console.error(val) |
<noscript |
||||||
return lang_[val] || ("*" + val); |
><iframe |
||||||
} |
src="https://www.googletagmanager.com/ns.html?id=GTM-WVV8H9L" |
||||||
|
height="0" |
||||||
(function (w, d, s, l, i) { |
width="0" |
||||||
w[l] = w[l] || []; |
style="display: none; visibility: hidden" |
||||||
w[l].push({ |
></iframe |
||||||
"gtm.start": new Date().getTime(), |
></noscript> |
||||||
event: "gtm.js", |
<!-- End Google Tag Manager (noscript) --> |
||||||
}); |
<div id="root"></div> |
||||||
var f = d.getElementsByTagName(s)[0], |
<script> |
||||||
j = d.createElement(s), |
if ("serviceWorker" in navigator) { |
||||||
dl = l != "dataLayer" ? "&l=" + l : ""; |
window.addEventListener("load", function () { |
||||||
j.async = true; |
navigator.serviceWorker |
||||||
j.src = "https://www.googletagmanager.com/gtm.js?id=" + i + dl; |
.register("./serviceworker.js") |
||||||
f.parentNode.insertBefore(j, f); |
.then((registration) => { |
||||||
})(window, document, "script", "dataLayer", "GTM-WVV8H9L"); |
// Registration was successful |
||||||
</script> |
console.log( |
||||||
<!-- End Google Tag Manager --> |
"ServiceWorker registration successful with scope: ", |
||||||
</head> |
registration.scope |
||||||
|
); |
||||||
<body> |
}) |
||||||
<!-- Google Tag Manager (noscript) --> |
.catch((err) => { |
||||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-WVV8H9L" height="0" width="0" |
console.log(err); |
||||||
style="display: none; visibility: hidden"></iframe></noscript> |
}); |
||||||
<!-- End Google Tag Manager (noscript) --> |
}); |
||||||
<div id="root"></div> |
} |
||||||
<script> |
</script> |
||||||
if ("serviceWorker" in navigator) { |
</body> |
||||||
window.addEventListener("load", function () { |
</html> |
||||||
navigator.serviceWorker |
|
||||||
.register("./serviceworker.js") |
|
||||||
.then((registration) => { |
|
||||||
// Registration was successful |
|
||||||
console.log( |
|
||||||
"ServiceWorker registration successful with scope: ", |
|
||||||
registration.scope |
|
||||||
); |
|
||||||
}) |
|
||||||
.catch((err) => { |
|
||||||
console.log(err); |
|
||||||
}); |
|
||||||
}); |
|
||||||
} |
|
||||||
|
|
||||||
</script> |
|
||||||
</body> |
|
||||||
|
|
||||||
</html> |
|
||||||
|
Loading…
Reference in new issue