fck-honey 0.1.1 → 0.1.2
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/README.md +4 -8
- package/dist/esm/index.js +1 -4
- package/dist/honey-detect.js +1 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -19,6 +19,10 @@ Open source lib for Merchants to detect if an end user has Honey browser extensi
|
|
|
19
19
|
|
|
20
20
|
## Usage (ESM)
|
|
21
21
|
|
|
22
|
+
```sh
|
|
23
|
+
npm install fck-honey
|
|
24
|
+
```
|
|
25
|
+
|
|
22
26
|
```js
|
|
23
27
|
import { listen } from "fck-honey";
|
|
24
28
|
|
|
@@ -28,11 +32,3 @@ listen((el) => {
|
|
|
28
32
|
console.log("Honey overlay detected:", el);
|
|
29
33
|
});
|
|
30
34
|
```
|
|
31
|
-
|
|
32
|
-
## Local Dev
|
|
33
|
-
|
|
34
|
-
```sh
|
|
35
|
-
npm run build
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
Open `example/index.html` in your browser.
|
package/dist/esm/index.js
CHANGED
|
@@ -57,10 +57,7 @@ export function startHoneyOverlayObserver(options) {
|
|
|
57
57
|
var seen = [];
|
|
58
58
|
var zNearMax = (_a = options.zNearMax) !== null && _a !== void 0 ? _a : DEFAULT_Z_NEAR_MAX;
|
|
59
59
|
var uuidGate = (_b = options.uuidGate) !== null && _b !== void 0 ? _b : true;
|
|
60
|
-
var onMatch = (_c = options.onMatch) !== null && _c !== void 0 ? _c : (function (
|
|
61
|
-
// Default: warn only, leaving response up to caller.
|
|
62
|
-
console.warn("[honey-detect] matched near-max z-index div:", el);
|
|
63
|
-
});
|
|
60
|
+
var onMatch = (_c = options.onMatch) !== null && _c !== void 0 ? _c : (function () { });
|
|
64
61
|
var mo = new MutationObserver(function (mutations) {
|
|
65
62
|
for (var _i = 0, mutations_1 = mutations; _i < mutations_1.length; _i++) {
|
|
66
63
|
var m = mutations_1[_i];
|
package/dist/honey-detect.js
CHANGED
|
@@ -58,10 +58,7 @@ function startHoneyOverlayObserver(options) {
|
|
|
58
58
|
var seen = [];
|
|
59
59
|
var zNearMax = (_a = options.zNearMax) !== null && _a !== void 0 ? _a : DEFAULT_Z_NEAR_MAX;
|
|
60
60
|
var uuidGate = (_b = options.uuidGate) !== null && _b !== void 0 ? _b : true;
|
|
61
|
-
var onMatch = (_c = options.onMatch) !== null && _c !== void 0 ? _c : (function (
|
|
62
|
-
// Default: warn only, leaving response up to caller.
|
|
63
|
-
console.warn("[honey-detect] matched near-max z-index div:", el);
|
|
64
|
-
});
|
|
61
|
+
var onMatch = (_c = options.onMatch) !== null && _c !== void 0 ? _c : (function () { });
|
|
65
62
|
var mo = new MutationObserver(function (mutations) {
|
|
66
63
|
for (var _i = 0, mutations_1 = mutations; _i < mutations_1.length; _i++) {
|
|
67
64
|
var m = mutations_1[_i];
|