From c7ac009313891fa736c54d008437391e1724315b Mon Sep 17 00:00:00 2001 From: Dan Wilkerson Date: Mon, 16 Oct 2017 10:31:03 -0400 Subject: [PATCH] Adjusted container to use same valeus as 1.X --- luna-scroll-tracking.json | 92 +++++++++++++++++++-------------------- package.json | 2 +- scroll-tracker.js | 2 +- scroll-tracker.min.js | 4 +- 4 files changed, 50 insertions(+), 50 deletions(-) diff --git a/luna-scroll-tracking.json b/luna-scroll-tracking.json index 14ec05a..7e2a9d0 100644 --- a/luna-scroll-tracking.json +++ b/luna-scroll-tracking.json @@ -1,35 +1,35 @@ { "exportFormatVersion": 2, - "exportTime": "2017-09-27 17:01:20", + "exportTime": "2017-10-16 14:28:16", "containerVersion": { - "path": "accounts/263956808/containers/2187445/versions/0", - "accountId": "263956808", - "containerId": "2187445", + "path": "accounts/316270/containers/2058549/versions/0", + "accountId": "316270", + "containerId": "2058549", "containerVersionId": "0", "container": { - "path": "accounts/263956808/containers/2187445", - "accountId": "263956808", - "containerId": "2187445", - "name": "Scroll Tracking", - "publicId": "GTM-NRXSRH", + "path": "accounts/316270/containers/2058549", + "accountId": "316270", + "containerId": "2058549", + "name": "Example Container", + "publicId": "GTM-T72QJV", "usageContext": [ "WEB" ], - "fingerprint": "1504900536606", - "tagManagerUrl": "https://tagmanager.google.com/#/container/accounts/263956808/containers/2187445/workspaces?apiLink=container" + "fingerprint": "1508163882150", + "tagManagerUrl": "https://tagmanager.google.com/#/container/accounts/316270/containers/2058549/workspaces?apiLink=container" }, "tag": [ { - "accountId": "263956808", - "containerId": "2187445", - "tagId": "8", + "accountId": "316270", + "containerId": "2058549", + "tagId": "4", "name": "CU - Scroll Tracking - LunaMetrics Plugin", "type": "html", "parameter": [ { "type": "TEMPLATE", "key": "html", - "value": "" + "value": "" }, { "type": "BOOLEAN", @@ -37,17 +37,17 @@ "value": "false" } ], - "fingerprint": "1506531658532", + "fingerprint": "1508163878195", "firingTriggerId": [ "2147479553" ], - "parentFolderId": "6", + "parentFolderId": "11", "tagFiringOption": "ONCE_PER_EVENT" }, { - "accountId": "263956808", - "containerId": "2187445", - "tagId": "9", + "accountId": "316270", + "containerId": "2058549", + "tagId": "5", "name": "GA - Event - Scroll Tracking", "type": "ua", "parameter": [ @@ -133,19 +133,19 @@ "value": "{{YOUR_GA_TRACKING_ID}}" } ], - "fingerprint": "1504901136050", + "fingerprint": "1508164001751", "firingTriggerId": [ - "7" + "12" ], - "parentFolderId": "6", + "parentFolderId": "11", "tagFiringOption": "ONCE_PER_EVENT" } ], "trigger": [ { - "accountId": "263956808", - "containerId": "2187445", - "triggerId": "7", + "accountId": "316270", + "containerId": "2058549", + "triggerId": "12", "name": "Event - Scroll Tracking", "type": "CUSTOM_EVENT", "customEventFilter": [ @@ -165,15 +165,15 @@ ] } ], - "fingerprint": "1462238385247", - "parentFolderId": "6" + "fingerprint": "1508163750962", + "parentFolderId": "11" } ], "variable": [ { - "accountId": "263956808", - "containerId": "2187445", - "variableId": "5", + "accountId": "316270", + "containerId": "2058549", + "variableId": "12", "name": "DLV - attributes.distance", "type": "v", "parameter": [ @@ -193,13 +193,13 @@ "value": "attributes.distance" } ], - "fingerprint": "1494007112284", - "parentFolderId": "6" + "fingerprint": "1508163750963", + "parentFolderId": "11" }, { - "accountId": "263956808", - "containerId": "2187445", - "variableId": "6", + "accountId": "316270", + "containerId": "2058549", + "variableId": "13", "name": "DLV - attributes.label", "type": "v", "parameter": [ @@ -219,28 +219,28 @@ "value": "attributes.label" } ], - "fingerprint": "1494007112284", - "parentFolderId": "6" + "fingerprint": "1508163750964", + "parentFolderId": "11" } ], "folder": [ { - "accountId": "263956808", - "containerId": "2187445", - "folderId": "6", + "accountId": "316270", + "containerId": "2058549", + "folderId": "11", "name": "LunaMetrics Scroll Tracking Plugin", - "fingerprint": "1462238385246" + "fingerprint": "1508163750961" } ], "builtInVariable": [ { - "accountId": "263956808", - "containerId": "2187445", + "accountId": "316270", + "containerId": "2058549", "type": "DEBUG_MODE", "name": "Debug Mode" } ], "fingerprint": "0", - "tagManagerUrl": "https://tagmanager.google.com/#/versions/accounts/263956808/containers/2187445/versions/0?apiLink=version" + "tagManagerUrl": "https://tagmanager.google.com/#/versions/accounts/316270/containers/2058549/versions/0?apiLink=version" } -} +} \ No newline at end of file diff --git a/package.json b/package.json index 8865f99..b0f8aa6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "scroll-tracking-google-analytics", - "version": "2.0.1", + "version": "2.0.2", "description": "Plug-and-play context-aware scroll tracking with no dependencies.", "main": "Gruntfile.js", "scripts": { diff --git a/scroll-tracker.js b/scroll-tracker.js index 6efc41a..28197a8 100644 --- a/scroll-tracker.js +++ b/scroll-tracker.js @@ -649,7 +649,7 @@ })(this); /* - * v2.0.1 + * v2.0.2 * Created by the Google Analytics consultants at http://www.lunametrics.com/ * Written by @notdanwilkerson * Documentation: https://github.com/lunametrics/gascroll/ diff --git a/scroll-tracker.min.js b/scroll-tracker.min.js index d56fc3a..b53d728 100644 --- a/scroll-tracker.min.js +++ b/scroll-tracker.min.js @@ -1,6 +1,6 @@ -!function(a){"use strict";function b(c){if(!(this instanceof b))return new b(c);c=c||{};var d=c.context||"body";if("string"==typeof d&&(d=m.querySelector(d)),!d)throw new Error("Unable to find context "+d);this._context=d,this.minHeight=c.minHeight||0,this._marks={},this._tracked={},this._config={percentages:{each:{},every:{}},pixels:{each:{},every:{}},elements:{each:{},every:{}}};var f=k(this._checkDepth.bind(this),500),g=this._update.bind(this),h=k(g,500);a.addEventListener("scroll",f,!0),a.addEventListener("resize",h),this._artifacts={timer:e(g),resize:h,scroll:f}}function c(a){return a.handlers.map(function(b){return b.bind(this,{data:{depth:a.depth,label:a.label}})})}function d(a){var b,c=Math.floor(a.numerator/a.n);for(b=1;b<=c;b++)a.callback(b*a.n)}function e(a){var b=f();return setInterval(function(){f()!==b&&(a(),b=f())},500)}function f(){var a=m.body,b=m.documentElement;return Math.max(a.scrollHeight,a.offsetHeight,b.clientHeight,b.scrollHeight,b.offsetHeight)}function g(a){var b=a.offsetHeight,c=h(),d=a.getBoundingClientRect();return Math.max(0,d.top>0?Math.min(b,c-d.top):d.bottom=a&&!this._tracked[a]&&(b[a].forEach(function(a){a()}),this._tracked[a]=!0)},b.prototype.reset=function(){this._tracked={},delete this._marks,this.marks={}},b.prototype._contextHeight=function(){return this._context!==m.body?this._context.scrollHeight-5:this._context.clientHeight-5},b.prototype._currentDepth=function(){var b,c=g(this._context);return this._context.scrollTop?b=this._context.scrollTop+c:(this._context.scrollTop=1,this._context.scrollTop?(this._context.scrollTop=0,b=this._context.scrollTop+c):b=a.pageYOffset||m.documentElement.scrollTop||m.body.scrollTop||0),c?b+c:b>=this._fromTop?b:-1},b.prototype._addMark=function(a){var b=a.depth;this._marks[b]=(this._marks[b]||[]).concat(c(a))},a.ScrollTracker=b}(this); +!function(a){"use strict";function b(c){if(!(this instanceof b))return new b(c);c=c||{};var d=c.context||"body";if("string"==typeof d&&(d=m.querySelector(d)),!d)throw new Error("Unable to find context "+d);this._context=d,this.minHeight=c.minHeight||0,this._marks={},this._tracked={},this._config={percentages:{each:{},every:{}},pixels:{each:{},every:{}},elements:{each:{},every:{}}};var f=k(this._checkDepth.bind(this),500),g=this._update.bind(this),h=k(g,500);a.addEventListener("scroll",f,!0),a.addEventListener("resize",h),this._artifacts={timer:e(g),resize:h,scroll:f}}function c(a){return a.handlers.map(function(b){return b.bind(this,{data:{depth:a.depth,label:a.label}})})}function d(a){var b,c=Math.floor(a.numerator/a.n);for(b=1;b<=c;b++)a.callback(b*a.n)}function e(a){var b=f();return setInterval(function(){f()!==b&&(a(),b=f())},500)}function f(){var a=m.body,b=m.documentElement;return Math.max(a.scrollHeight,a.offsetHeight,b.clientHeight,b.scrollHeight,b.offsetHeight)}function g(a){var b=a.offsetHeight,c=h(),d=a.getBoundingClientRect();return Math.max(0,d.top>0?Math.min(b,c-d.top):d.bottom=a&&!this._tracked[a]&&(b[a].forEach(function(a){a()}),this._tracked[a]=!0)},b.prototype.reset=function(){this._tracked={},delete this._marks,this.marks={}},b.prototype._contextHeight=function(){return this._context!==m.body?this._context.scrollHeight-5:this._context.clientHeight-5},b.prototype._currentDepth=function(){var b,c=g(this._context);return this._context.scrollTop?b=this._context.scrollTop+c:(this._context.scrollTop=1,this._context.scrollTop?(this._context.scrollTop=0,b=this._context.scrollTop+c):b=a.pageYOffset||m.documentElement.scrollTop||m.body.scrollTop||0),c?b+c:b>=this._fromTop?b:-1},b.prototype._addMark=function(a){var b=a.depth;this._marks[b]=(this._marks[b]||[]).concat(c(a))},a.ScrollTracker=b}(this); /* - * v2.0.1 + * v2.0.2 * Created by the Google Analytics consultants at http://www.lunametrics.com/ * Written by @notdanwilkerson * Documentation: https://github.com/lunametrics/gascroll/