@versini/ui-fingerprint 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2 -2
- package/dist/index.js +16 -16
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -71,7 +71,7 @@ type FingerprintData = [
|
|
|
71
71
|
ScreenFP,
|
|
72
72
|
SystemFP
|
|
73
73
|
];
|
|
74
|
-
declare const getFingerprintData: (debug
|
|
75
|
-
declare const getFingerprintHash: (debug
|
|
74
|
+
declare const getFingerprintData: (debug?: boolean) => Promise<FingerprintData>;
|
|
75
|
+
declare const getFingerprintHash: (debug?: boolean) => Promise<string>;
|
|
76
76
|
|
|
77
77
|
export { getFingerprintData, getFingerprintHash };
|
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
@versini/ui-fingerprint v1.
|
|
2
|
+
@versini/ui-fingerprint v1.1.0
|
|
3
3
|
© 2024 gizmette.com
|
|
4
4
|
*/
|
|
5
5
|
try {
|
|
6
6
|
window.__VERSINI_UI_FINGERPRINT__ || (window.__VERSINI_UI_FINGERPRINT__ = {
|
|
7
|
-
version: "1.
|
|
8
|
-
buildTime: "
|
|
7
|
+
version: "1.1.0",
|
|
8
|
+
buildTime: "12/18/2024 12:34 PM EST",
|
|
9
9
|
homepage: "https://github.com/aversini/ui-components",
|
|
10
10
|
license: "MIT"
|
|
11
11
|
});
|
|
@@ -56,7 +56,7 @@ const x = {
|
|
|
56
56
|
maxChannels: 0,
|
|
57
57
|
channelCountMode: ""
|
|
58
58
|
}
|
|
59
|
-
},
|
|
59
|
+
}, P = async (t) => new Promise((n) => {
|
|
60
60
|
try {
|
|
61
61
|
const e = new window.OfflineAudioContext(1, 5e3, 44100), o = e.createBufferSource(), r = e.createOscillator();
|
|
62
62
|
r.frequency.value = 1e3;
|
|
@@ -82,7 +82,7 @@ const x = {
|
|
|
82
82
|
}
|
|
83
83
|
});
|
|
84
84
|
}
|
|
85
|
-
}), E = { browser: "" },
|
|
85
|
+
}), E = { browser: "" }, H = async (t) => typeof navigator > "u" ? E : { browser: navigator.userAgent }, C = {
|
|
86
86
|
canvas: {
|
|
87
87
|
data: ""
|
|
88
88
|
}
|
|
@@ -189,16 +189,16 @@ const x = {
|
|
|
189
189
|
for (let i = 0; i < h.length; i++)
|
|
190
190
|
a[h[i]] = p[i].offsetWidth, c[h[i]] = p[i].offsetHeight;
|
|
191
191
|
return w.filter((i) => f(u[i]));
|
|
192
|
-
}),
|
|
192
|
+
}), M = {
|
|
193
193
|
vendor: "",
|
|
194
194
|
vendorUnmasked: "",
|
|
195
195
|
renderer: "",
|
|
196
196
|
rendererUnmasked: "",
|
|
197
197
|
version: "",
|
|
198
198
|
shadingLanguageVersion: ""
|
|
199
|
-
},
|
|
199
|
+
}, b = {
|
|
200
200
|
hardware: {
|
|
201
|
-
videocard:
|
|
201
|
+
videocard: M,
|
|
202
202
|
architecture: 0,
|
|
203
203
|
deviceMemory: "undefined",
|
|
204
204
|
jsHeapSizeLimit: 0
|
|
@@ -217,7 +217,7 @@ function U() {
|
|
|
217
217
|
shadingLanguageVersion: (n.getParameter(n.SHADING_LANGUAGE_VERSION) || "").toString()
|
|
218
218
|
};
|
|
219
219
|
}
|
|
220
|
-
return
|
|
220
|
+
return M;
|
|
221
221
|
}
|
|
222
222
|
function B() {
|
|
223
223
|
const t = new Float32Array(1), n = new Uint8Array(t.buffer);
|
|
@@ -237,7 +237,7 @@ const W = () => navigator.deviceMemory || 0, V = () => window.performance && win
|
|
|
237
237
|
}
|
|
238
238
|
});
|
|
239
239
|
} catch (e) {
|
|
240
|
-
t && (console.error("Error getting hardware data"), console.info(e)), n(
|
|
240
|
+
t && (console.error("Error getting hardware data"), console.info(e)), n(b);
|
|
241
241
|
}
|
|
242
242
|
}), j = {
|
|
243
243
|
locales: {
|
|
@@ -251,7 +251,7 @@ const W = () => navigator.deviceMemory || 0, V = () => window.performance && win
|
|
|
251
251
|
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone
|
|
252
252
|
}
|
|
253
253
|
});
|
|
254
|
-
}),
|
|
254
|
+
}), A = {
|
|
255
255
|
screen: {
|
|
256
256
|
colorDepth: 0,
|
|
257
257
|
pixelDepth: 0,
|
|
@@ -272,7 +272,7 @@ const W = () => navigator.deviceMemory || 0, V = () => window.performance && win
|
|
|
272
272
|
};
|
|
273
273
|
n(o);
|
|
274
274
|
} catch (e) {
|
|
275
|
-
t && (console.error("Error creating screen fingerprint"), console.info(e)), n(
|
|
275
|
+
t && (console.error("Error creating screen fingerprint"), console.info(e)), n(A);
|
|
276
276
|
}
|
|
277
277
|
});
|
|
278
278
|
function J() {
|
|
@@ -326,8 +326,8 @@ const K = async (t) => {
|
|
|
326
326
|
}, Z = async (t) => {
|
|
327
327
|
try {
|
|
328
328
|
return Promise.all([
|
|
329
|
-
|
|
330
|
-
|
|
329
|
+
P(t),
|
|
330
|
+
H(),
|
|
331
331
|
R(t),
|
|
332
332
|
O(),
|
|
333
333
|
z(t),
|
|
@@ -341,9 +341,9 @@ const K = async (t) => {
|
|
|
341
341
|
E,
|
|
342
342
|
C,
|
|
343
343
|
G,
|
|
344
|
-
M,
|
|
345
|
-
j,
|
|
346
344
|
b,
|
|
345
|
+
j,
|
|
346
|
+
A,
|
|
347
347
|
I
|
|
348
348
|
];
|
|
349
349
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@versini/ui-fingerprint",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Arno Versini",
|
|
6
6
|
"publishConfig": {
|
|
@@ -35,5 +35,5 @@
|
|
|
35
35
|
"test:watch": "vitest",
|
|
36
36
|
"test": "vitest run"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "413e5c7cd8228d2f135f54fa897101401207229b"
|
|
39
39
|
}
|