Skip to content

Commit 7261dd8

Browse files
committed
chore(prettier): ran prettier
1 parent c95953a commit 7261dd8

File tree

2 files changed

+28
-35
lines changed

2 files changed

+28
-35
lines changed

public/assets/js/analytics.js

Lines changed: 27 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,46 @@
1-
(function() {
2-
'use strict';
3-
1+
(() => {
42
const _0x1a2b = {
5-
a: 'dataLayer',
6-
b: 'push',
7-
c: 'js',
8-
d: 'config',
9-
e: 'script',
10-
f: 'src',
11-
g: 'async',
12-
h: 'head'
3+
a: "dataLayer",
4+
b: "push",
5+
c: "js",
6+
d: "config",
7+
e: "script",
8+
f: "src",
9+
g: "async",
10+
h: "head",
1311
};
14-
15-
const _tid = atob('Ry1XS0pRNVFIUVRK');
16-
17-
const _urls = [
18-
atob('aHR0cHM6Ly93d3cu'),
19-
atob('Z29vZ2xldGFnbWFuYWdlci5jb20='),
20-
atob('L2d0YWcvanM=')
21-
];
22-
12+
13+
const _tid = atob("Ry1XS0pRNVFIUVRK");
14+
15+
const _baseUrl = atob("aHR0cHM6Ly93d3cuZ29vZ2xldGFnbWFuYWdlci5jb20vZ3RhZy9qcw==");
16+
2317
const _init = () => {
2418
window[_0x1a2b.a] = window[_0x1a2b.a] || [];
25-
19+
2620
const _fn = (...args) => window[_0x1a2b.a][_0x1a2b.b](args);
27-
21+
2822
_fn(_0x1a2b.c, new Date());
2923
_fn(_0x1a2b.d, _tid);
30-
24+
3125
const _script = document.createElement(_0x1a2b.e);
32-
_script[_0x1a2b.f] = _urls.join('') + '?id=' + _tid;
26+
_script[_0x1a2b.f] = `${_baseUrl}?id=${_tid}`;
3327
_script[_0x1a2b.g] = true;
3428
document[_0x1a2b.h].appendChild(_script);
35-
29+
3630
window._track = _fn;
3731
};
38-
39-
if (document.readyState === 'loading') {
40-
document.addEventListener('DOMContentLoaded', _init);
32+
33+
if (document.readyState === "loading") {
34+
document.addEventListener("DOMContentLoaded", _init);
4135
} else {
4236
_init();
4337
}
44-
38+
4539
const _protect = () => {
46-
let devtools = {open: false, orientation: null};
40+
const devtools = { open: false, orientation: null };
4741
const threshold = 160;
4842
setInterval(() => {
49-
if (window.outerHeight - window.innerHeight > threshold ||
50-
window.outerWidth - window.innerWidth > threshold) {
43+
if (window.outerHeight - window.innerHeight > threshold || window.outerWidth - window.innerWidth > threshold) {
5144
if (!devtools.open) {
5245
devtools.open = true;
5346
}
@@ -56,6 +49,6 @@
5649
}
5750
}, 500);
5851
};
59-
52+
6053
_protect();
61-
})();
54+
})();

src/layouts/Layout.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ import { ViewTransitions } from "astro:transitions";
3131
<body>
3232
<slot />
3333
</body>
34-
</html>
34+
</html>

0 commit comments

Comments
 (0)