/******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) { /******/ return installedModules[moduleId].exports; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules[moduleId] = { /******/ i: moduleId, /******/ l: false, /******/ exports: {} /******/ }; /******/ /******/ // Execute the module function /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); /******/ /******/ // Flag the module as loaded /******/ module.l = true; /******/ /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ /******/ /******/ // expose the modules object (__webpack_modules__) /******/ __webpack_require__.m = modules; /******/ /******/ // expose the module cache /******/ __webpack_require__.c = installedModules; /******/ /******/ // define getter function for harmony exports /******/ __webpack_require__.d = function(exports, name, getter) { /******/ if(!__webpack_require__.o(exports, name)) { /******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); /******/ } /******/ }; /******/ /******/ // define __esModule on exports /******/ __webpack_require__.r = function(exports) { /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); /******/ } /******/ Object.defineProperty(exports, '__esModule', { value: true }); /******/ }; /******/ /******/ // create a fake namespace object /******/ // mode & 1: value is a module id, require it /******/ // mode & 2: merge all properties of value into the ns /******/ // mode & 4: return value when already ns object /******/ // mode & 8|1: behave like require /******/ __webpack_require__.t = function(value, mode) { /******/ if(mode & 1) value = __webpack_require__(value); /******/ if(mode & 8) return value; /******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; /******/ var ns = Object.create(null); /******/ __webpack_require__.r(ns); /******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); /******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); /******/ return ns; /******/ }; /******/ /******/ // getDefaultExport function for compatibility with non-harmony modules /******/ __webpack_require__.n = function(module) { /******/ var getter = module && module.__esModule ? /******/ function getDefault() { return module['default']; } : /******/ function getModuleExports() { return module; }; /******/ __webpack_require__.d(getter, 'a', getter); /******/ return getter; /******/ }; /******/ /******/ // Object.prototype.hasOwnProperty.call /******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; /******/ /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; /******/ /******/ /******/ // Load entry module and return exports /******/ return __webpack_require__(__webpack_require__.s = 29); /******/ }) /************************************************************************/ /******/ ([ /* 0 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"k\", function() { return isUndefined; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"d\", function() { return isFunction; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"e\", function() { return isNull; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"f\", function() { return isNullOrUndefined; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"o\", function() { return safeParseJSON; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"h\", function() { return isObject; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"c\", function() { return get; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"g\", function() { return isNumber; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"j\", function() { return isString; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"l\", function() { return isValidString; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"p\", function() { return set; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return debounce; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return convertToSnakeCase; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"n\", function() { return resolvePromiseMap; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"m\", function() { return mapValues; });\n/* unused harmony export isObjectLike */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"i\", function() { return isPlainObject; });\nvar __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nfunction isUndefined(val) {\n return typeof val === \"undefined\";\n}\nfunction isFunction(val) {\n return typeof val === \"function\";\n}\nfunction isNull(val) {\n return val === null;\n}\nfunction isNullOrUndefined(val) {\n return isNull(val) || isUndefined(val);\n}\nconst safeParseJSON = (str, defaultValue = {}) => {\n if (Number.isFinite(+str)) {\n return defaultValue;\n }\n try {\n return JSON.parse(str);\n }\n catch (_err) {\n }\n return defaultValue;\n};\nfunction isObject(val) {\n const AsyncFunction = function () {\n return __awaiter(this, void 0, void 0, function* () { });\n }.constructor;\n return (typeof val === \"object\" &&\n !isNull(val) &&\n !Array.isArray(val) &&\n !(val instanceof AsyncFunction) &&\n val.constructor !== \"function\" &&\n Object.prototype.toString.call(val) === \"[object Object]\");\n}\nfunction get(from, selector, defaultValue = undefined) {\n if (isNull(from) || isUndefined(from)) {\n return defaultValue;\n }\n const validSelector = selector !== null && selector !== void 0 ? selector : \"\";\n const value = validSelector\n .replace(/\\[([^[\\]]*)]/g, \".$1.\")\n .split(\".\")\n .filter((t) => t !== \"\")\n .reduce((prev, curr) => prev && prev[curr], from);\n return !isUndefined(value) ? value : defaultValue;\n}\nfunction isNumber(value) {\n return typeof value === \"number\" && Number.isFinite(value);\n}\nfunction isString(value) {\n return typeof value === \"string\";\n}\nfunction isValidString(value) {\n return isString(value) && value.length > 0;\n}\nconst set = (object, path = \"\", value) => {\n const splits = path && path.length > 0 ? path.split(\".\") : [];\n let objectPointer = object;\n splits.slice(0, splits.length - 1).forEach((spilt) => {\n let currentObject = objectPointer[spilt];\n if (isNull(currentObject) || isUndefined(currentObject)) {\n currentObject = {};\n }\n objectPointer[spilt] = currentObject;\n objectPointer = objectPointer[spilt];\n });\n objectPointer[splits.pop()] = value;\n return object;\n};\nfunction debounce(func, timeout = 100) {\n let timer;\n return (...args) => {\n clearTimeout(timer);\n timer = setTimeout(() => {\n func(...args);\n }, timeout);\n };\n}\nconst convertToSnakeCase = (str) => {\n var _a, _b, _c;\n return ((_c = (_b = (_a = str\n .match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g)) === null || _a === void 0 ? void 0 : _a.map((x) => x.toLowerCase())) === null || _b === void 0 ? void 0 : _b.join(\"_\")) !== null && _c !== void 0 ? _c : str);\n};\nconst resolvePromiseMap = (promises) => {\n const keys = Object.keys(promises);\n const promiseArr = [];\n const keyMap = keys.reduce((acc, key, index) => {\n acc[index] = key;\n promiseArr.push(promises[key]);\n return acc;\n }, {});\n return Promise.all(promiseArr).then((respArr) => {\n return respArr.reduce((acc, resp, index) => {\n acc[keyMap[index]] = resp;\n return acc;\n }, {});\n });\n};\nconst mapValues = (obj, func) => {\n let keys;\n try {\n keys = Object.keys(obj);\n }\n catch (ex) {\n throw new Error(\"Unable to extract keys from provided object\");\n }\n return keys.reduce((results, key) => {\n const value = func(obj[key], key);\n const modified = Object.assign({}, results);\n if (!isUndefined(value)) {\n modified[key] = value;\n }\n return modified;\n }, {});\n};\nconst isObjectLike = (val) => typeof val === \"object\" && !isNull(val);\nfunction isPlainObject(val) {\n if (!isObjectLike(val) || val.toString() !== \"[object Object]\") {\n return false;\n }\n if (Object.getPrototypeOf(val) === null) {\n return true;\n }\n let proto = val;\n while (Object.getPrototypeOf(proto) !== null) {\n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lzKHByb21pc2VzKTtcbiAgICBjb25zdCBwcm9taXNlQXJyID0gW107XG4gICAgY29uc3Qga2V5TWFwID0ga2V5cy5yZWR1Y2UoKGFjYywga2V5LCBpbmRleCkgPT4ge1xuICAgICAgICBhY2NbaW5kZXhdID0ga2V5O1xuICAgICAgICBwcm9taXNlQXJyLnB1c2gocHJvbWlzZXNba2V5XSk7XG4gICAgICAgIHJldHVybiBhY2M7XG4gICAgfSwge30pO1xuICAgIHJldHVybiBQcm9taXNlLmFsbChwcm9taXNlQXJyKS50aGVuKChyZXNwQXJyKSA9PiB7XG4gICAgICAgIHJldHVybiByZXNwQXJyLnJlZHVjZSgoYWNjLCByZXNwLCBpbmRleCkgPT4ge1xuICAgICAgICAgICAgYWNjW2tleU1hcFtpbmRleF1dID0gcmVzcDtcbiAgICAgICAgICAgIHJldHVybiBhY2M7XG4gICAgICAgIH0sIHt9KTtcbiAgICB9KTtcbn07XG5leHBvcnQgY29uc3QgbWFwVmFsdWVzID0gKG9iaiwgZnVuYykgPT4ge1xuICAgIGxldCBrZXlzO1xuICAgIHRyeSB7XG4gICAgICAgIGtleXMgPSBPYmplY3Qua2V5cyhvYmopO1xuICAgIH1cbiAgICBjYXRjaCAoZXgpIHtcbiAgICAgICAgdGhyb3cgbmV3IEVycm9yKFwiVW5hYmxlIHRvIGV4dHJhY3Qga2V5cyBmcm9tIHByb3ZpZGVkIG9iamVjdFwiKTtcbiAgICB9XG4gICAgcmV0dXJuIGtleXMucmVkdWNlKChyZXN1bHRzLCBrZXkpID0+IHtcbiAgICAgICAgY29uc3QgdmFsdWUgPSBmdW5jKG9ialtrZXldLCBrZXkpO1xuICAgICAgICBjb25zdCBtb2RpZmllZCA9IE9iamVjdC5hc3NpZ24oe30sIHJlc3VsdHMpO1xuICAgICAgICBpZiAoIWlzVW5kZWZpbmVkKHZhbHVlKSkge1xuICAgICAgICAgICAgbW9kaWZpZWRba2V5XSA9IHZhbHVlO1xuICAgICAgICB9XG4gICAgICAgIHJldHVybiBtb2RpZmllZDtcbiAgICB9LCB7fSk7XG59O1xuZXhwb3J0IGNvbnN0IGlzT2JqZWN0TGlrZSA9ICh2YWwpID0+IHR5cGVvZiB2YWwgPT09IFwib2JqZWN0XCIgJiYgIWlzTnVsbCh2YWwpO1xuZXhwb3J0IGZ1bmN0aW9uIGlzUGxhaW5PYmplY3QodmFsKSB7XG4gICAgaWYgKCFpc09iamVjdExpa2UodmFsKSB8fCB2YWwudG9TdHJpbmcoKSAhPT0gXCJbb2JqZWN0IE9iamVjdF1cIikge1xuICAgICAgICByZXR1cm4gZmFsc2U7XG4gICAgfVxuICAgIGlmIChPYmplY3QuZ2V0UHJvdG90eXBlT2YodmFsKSA9PT0gbnVsbCkge1xuICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICB9XG4gICAgbGV0IHByb3RvID0gdmFsO1xuICAgIHdoaWxlIChPYmplY3QuZ2V0UHJvdG90eXBlT2YocHJvdG8pICE9PSBudWxsKSB7XG4gICAgICAgIHByb3RvID0gT2JqZWN0LmdldFByb3RvdHlwZU9mKHByb3RvKTtcbiAgICB9XG4gICAgcmV0dXJuIE9iamVjdC5nZXRQcm90b3R5cGVPZih2YWwpID09PSBwcm90bztcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///0\n"); /***/ }), /* 1 */ /***/ (function(module, exports, __webpack_require__) { !function(e,t){ true?t(exports):undefined}(this,(function(e){"use strict";var t,i,o,E,T,a,n,d,r,A,_,s,O,l,I;e.AlignValue=void 0,(t=e.AlignValue||(e.AlignValue={})).LEFT="left",t.RIGHT="right",t.CENTER="center",e.AlignPosition=void 0,(i=e.AlignPosition||(e.AlignPosition={})).NATURAL="natural",i.CANVAS="canvas",e.ShapeKind=void 0,(o=e.ShapeKind||(e.ShapeKind={})).CIRCLE="circle",o.RECTANGLE="rectangle",o.POLYGON="polygon",e.ObjectType=void 0,(E=e.ObjectType||(e.ObjectType={})).TEXT="text",E.SHAPE="shape",E.IMAGE="image",E.GROUP="group",e.SizeUnit=void 0,(T=e.SizeUnit||(e.SizeUnit={})).PX="px",T.PERCENT="%",e.LogicalOp=void 0,(a=e.LogicalOp||(e.LogicalOp={})).AND="and",a.OR="or",e.ComparisonOp=void 0,(n=e.ComparisonOp||(e.ComparisonOp={})).GT="gt",n.LT="lt",n.GE="ge",n.LE="le",n.EQ="eq",n.NE="ne",e.ConditionVariable=void 0,(d=e.ConditionVariable||(e.ConditionVariable={})).H="h",d.W="w",d.AR="ar",e.CartUpdateAction=void 0,(r=e.CartUpdateAction||(e.CartUpdateAction={})).ADD_TO_CART="addToCart",r.INCREMENT_QUANTITY="increaseQuantity",r.DECREMENT_QUANTITY="decreaseQuantity",r.UPDATE_QUANTITY="updateQuantity",r.CHANGE_QUANTITY="changeQuantity",r.CHANGE_CART="changeCart",e.WidgetFeature=void 0,(A=e.WidgetFeature||(e.WidgetFeature={})).AUTOMATED_DISCOUNTS="cart_discounts_inclusion",A.MANUAL_DISCOUNT_ALLOCATIONS="allow_manual_discount_allocations",A.DISABLE_COUPON_CODES="disable_coupon_codes",A.PRODUCT_VARIANTS="product_variants",A.EXCLUDE_OOS="exclude_oos",A.TIMER="timer",A.EMBEDDED_PRICE_DROP="embed-price-drop",A.PRODUCT_SELECTION="product_selection",A.RECOMMENDATION_REMINDER="recommendation_reminder",A.QUIZ_TIMER="quiz-timer",A.FS_FLOATING="fullscreen-floating",A.FLOATING_LAUNCHER="floating-launcher",A.SINGLE_SELECTION_DISCOUNT="single_selection_discount",A.EXCLUDE_DOUBLE_SELECTION_DISCOUNT="exclude_double_selection_discount",A.TIERED_DISCOUNT="tiered_discount",A.NO_DEFAULT_SELECTION="no_default_selection",A.PRODUCT_DISCOUNT="product_discount",A.NEW_USER_VIEW="new_user_view",A.TIMED_VIEW="timed_view",A.MOBILE_BOTTOM_DRAWER="mobile_bottom_drawer",A.USER_SPECIFIC="user-specific",A.COD_HIDDEN="cod_hidden",e.WidgetCategory=void 0,(_=e.WidgetCategory||(e.WidgetCategory={})).CUSTOM_QUIZ="custom_recommendation-quiz",_.QUIZ="quiz",_.PRODUCT_BUNDLE="bundle",_.AB_CART="cart",_.SIDE_CART="side-cart",_.FORM="form",_.PRICE_DROP="price-drop",_.NEW_ARRIVALS="newarrivals",_.BESTSELLER="recommended",_.GENERIC="generic",_.FBT="fbt",_.REWARD_QUIZ="reward-quiz",_.BULK_BUY="bulk-buy",_.SPIN_WHEEL="spin-the-wheel",_.STICKY_CART_BUTTON="sticky-cart-button",_.PLAYBOOK="playbook",_.PRODUCT_INFO="info",e.WidgetType=void 0,(s=e.WidgetType||(e.WidgetType={})).STORE_BANNER="store",s.PRODUCT_BANNER="product",s.WIDGET="widget",e.InsertType=void 0,(O=e.InsertType||(e.InsertType={})).ABOVE="above",O.BELOW="below",O.REPLACE_CHILDREN="replaceChildren",O.LAST_CHILD="lastChild",O.FIRST_CHILD="firstChild",O.PAGE_TOP="pageTop",O.PAGE_BOTTOM="pageBottom",O.PAGE_HOVER_TOP="pageHoverTop",O.PAGE_HOVER_BOTTOM="pageHoverBottom",O.FLOATING="floating",O.SLIDE_IN="slideIn",e.WidgetTimingAction=void 0,(l=e.WidgetTimingAction||(e.WidgetTimingAction={})).CLICK="click",l.SCROLL="scroll",l.DELAY="delay",l.AB_CART="abcart",e.TargetType=void 0,(I=e.TargetType||(e.TargetType={})).PAGES="pages",I.PRODUCTS="products",I.COLLECTIONS="collections";var C,p,R,c,D,u,S,N,g,L;e.BreakpointId=void 0,(C=e.BreakpointId||(e.BreakpointId={})).XS="xs",C.M="m",C.L="l",C.XL="xl",e.FloatingPositionTypes=void 0,(p=e.FloatingPositionTypes||(e.FloatingPositionTypes={})).TOP="top",p.RIGHT="right",p.BOTTOM="bottom",p.LEFT="left",e.AddOn=void 0,(R=e.AddOn||(e.AddOn={})).RECOMMENDED="recommended",R.UPSELL="upsell",R.FBT="fbt",R.BXGY="bxgy",e.WidgetEntityState=void 0,(c=e.WidgetEntityState||(e.WidgetEntityState={})).ENABLED="enabled",c.DISABLED="disabled",c.SYSTEM_DISABLED="system_disabled",c.DELETED="deleted",e.ApplyType=void 0,(D=e.ApplyType||(e.ApplyType={})).MANUAL="manual",D.AUTOMATION="automation",e.PublishAs=void 0,(u=e.PublishAs||(e.PublishAs={})).BADGE="badge",u.FEATURE_CARD="feature-card",u.TRUST_BADGE="trust-badges",u.STORE_BANNER="store-banner",u.PRODUCT_BANNER="product-banner",u.STANDALONE="standalone",u.WIDGET="widget",e.AddonStatus=void 0,(S=e.AddonStatus||(e.AddonStatus={})).ENABLED="enabled",S.DISABLED="disabled",e.DiscountType=void 0,(N=e.DiscountType||(e.DiscountType={})).FIXED="fixed_amount",N.PERCENTAGE="percentage",N.TIERED="tiered",N.BXGY_PRODUCTS="bxgy::products",e.ChannelMethod=void 0,(g=e.ChannelMethod||(e.ChannelMethod={})).INITIALIZE="initialize",g.RESIZE="resize",g.TIMER_EXPIRED="timerExpired",g.CART_UPDATE="onCartUpdate",g.ORDER_CREATED="orderCreated",g.DISCOUNT_UPDATION="discountUpdation",g.FETCH_CART="getCart",g.CLOSE="closeWidget",g.CHANGE_VARIANT="onChangeVariant",g.SELECT_PRODUCT="onProductSelect",g.FORM_SUBMIT="onFormSubmit",g.FORM_RESET="onFormReset",g.UPDATE_WIDGET="update",g.URL_CHANGE="urlchange",g.WINDOW_RESIZED="window-resized",g.TIMER_STATE_UPDATE="timer-state-update",g.SPIN_WHEEL_STATE_UPDATE="spin-wheel-state-update",g.QUIZ_STATE_UPDATE="quiz-state-update",g.IN_VIEW="in-view",g.OUT_OF_VIEW="out-of-view",g.GET_QUERY_PARAMS="get-query-params",g.LINK_DATA_UPDATE="link-data-update",g.GET_STOREFRONT_DATA="get-storefront-data",e.CheckoutType=void 0,(L=e.CheckoutType||(e.CheckoutType={})).SWIFT="swift",L.FASTRR="fastrr",L.GOKWIK="gokwik",L.DEFAULT="default";var U,P,y,m;e.ScriptName=void 0,(U=e.ScriptName||(e.ScriptName={})).ANALYTICS="analytics",U.LOADER="loader",U.LOFOODS="lofoods",U.OVERLAY="overlay",U.PREVIEW="preview",U.REPLACE="replace",U.SIDECART="sidecart",U.THANKYOU="thankyou",U.TRUSTBADGES="trustbadges",U.WIDGETS="widgets",U.QUIZ="quiz",e.FeaturesAPIApp=void 0,(P=e.FeaturesAPIApp||(e.FeaturesAPIApp={})).MODEMAGIC="modemagic",P.QUIZ_MASTER="quizmaster",e.CacheEntryVersion=void 0,(y=e.CacheEntryVersion||(e.CacheEntryVersion={})).ONE="1.0",y.TWO="2.0",e.TBAlign=void 0,(m=e.TBAlign||(e.TBAlign={})).CENTER="center",m.RIGHT="right",m.LEFT="left",e.LauncherPositions={BOTTOM_LEFT:"bottomLeft",BOTTOM_RIGHT:"bottomRight"},e.Platforms={SHOPIFY:"shopify",BIGCOMMERCE:"bigcommerce",UNKNOWN:"--unknown--"}})); /***/ }), /* 2 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return console; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return debugLog; });\n/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6);\n\nconst fns = [\n \"info\",\n \"debug\",\n \"error\",\n \"log\",\n \"group\",\n \"groupEnd\",\n];\nconst console = fns.reduce((acc, fn) => {\n acc[fn] = (...args) => {\n if (!_constants__WEBPACK_IMPORTED_MODULE_0__[/* isProduction */ \"b\"]) {\n window.console[fn](...args);\n }\n };\n return acc;\n}, {});\nconst debugLog = (message, data) => {\n if (!_constants__WEBPACK_IMPORTED_MODULE_0__[/* isProduction */ \"b\"]) {\n console.debug(`%c [Scripts] ${message}`, \"background: #222; color: #d97b09\", data !== null && data !== void 0 ? data : \"\");\n }\n};\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly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PyBkYXRhIDogXCJcIik7XG4gICAgfVxufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///2\n"); /***/ }), /* 3 */, /* 4 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"f\", function() { return imageExtensionsRegex; });\n/* unused harmony export shopifyImageFiltersRegex */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"i\", function() { return parseImageUrl; });\n/* unused harmony export trimExtensionAndParams */\n/* unused harmony export matchStrings */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"d\", function() { return getMatchedUrl; });\n/* unused harmony export getFileName */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return getCDNFilePath; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return getCDNOrigin; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"c\", function() { return getCurrentPage; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"h\", function() { return modeMagicSettings; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"g\", function() { return isElementInViewport; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"j\", function() { return proxify; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"e\", function() { return getQueryObject; });\n/* harmony import */ var utils_console__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);\n/* harmony import */ var utils_lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);\n/* harmony import */ var utils_constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6);\n/* harmony import */ var _platform__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);\nvar _a;\n\n\n\n\nconst isTest = ((_a = process === null || process === void 0 ? void 0 : {\"USER_FEATURES_API\":\"https://mm.beta.getmason.io/api/features\",\"APP_URL\":\"https://mm.beta.getmason.io/widgets/view\",\"NODE_ENV\":\"staging\"}) === null || _a === void 0 ? void 0 : _a.NODE_ENV) === \"test\";\nconst imageExtensions = [\n \"ase\",\n \"art\",\n \"bmp\",\n \"blp\",\n \"cd5\",\n \"cit\",\n \"cpt\",\n \"cr2\",\n \"cut\",\n \"dds\",\n \"dib\",\n \"djvu\",\n \"egt\",\n \"exif\",\n \"gif\",\n \"gpl\",\n \"grf\",\n \"icns\",\n \"ico\",\n \"iff\",\n \"jng\",\n \"jpeg\",\n \"jpg\",\n \"jfif\",\n \"jp2\",\n \"jps\",\n \"lbm\",\n \"max\",\n \"miff\",\n \"mng\",\n \"msp\",\n \"nef\",\n \"nitf\",\n \"ota\",\n \"pbm\",\n \"pc1\",\n \"pc2\",\n \"pc3\",\n \"pcf\",\n \"pcx\",\n \"pdn\",\n \"pgm\",\n \"PI1\",\n \"PI2\",\n \"PI3\",\n \"pict\",\n \"pct\",\n \"pnm\",\n \"pns\",\n \"ppm\",\n \"psb\",\n \"psd\",\n \"pdd\",\n \"psp\",\n \"px\",\n \"pxm\",\n \"pxr\",\n \"qfx\",\n \"raw\",\n \"rle\",\n \"sct\",\n \"sgi\",\n \"rgb\",\n \"int\",\n \"bw\",\n \"tga\",\n \"tiff\",\n \"tif\",\n \"vtf\",\n \"xbm\",\n \"xcf\",\n \"xpm\",\n \"3dv\",\n \"amf\",\n \"ai\",\n \"awg\",\n \"cgm\",\n \"cdr\",\n \"cmx\",\n \"dxf\",\n \"e2d\",\n \"egt\",\n \"eps\",\n \"fs\",\n \"gbr\",\n \"odg\",\n \"svg\",\n \"stl\",\n \"vrml\",\n \"x3d\",\n \"sxd\",\n \"v2d\",\n \"vnd\",\n \"wmf\",\n \"emf\",\n \"art\",\n \"xar\",\n \"png\",\n \"webp\",\n \"jxr\",\n \"hdp\",\n \"wdp\",\n \"cur\",\n \"ecw\",\n \"iff\",\n \"lbm\",\n \"liff\",\n \"nrrd\",\n \"pam\",\n \"pcx\",\n \"pgf\",\n \"sgi\",\n \"rgb\",\n \"rgba\",\n \"bw\",\n \"int\",\n \"inta\",\n \"sid\",\n \"ras\",\n \"sun\",\n \"tga\",\n \"heic\",\n \"heif\",\n];\nconst extnSet = new Set(imageExtensions);\nconst imageExtensionsRegex = new RegExp(`((.${imageExtensions.join(\"|.\")})+)$`, \"i\");\nconst urlSizes = [\n \"pico\",\n \"icon\",\n \"thumb\",\n \"small\",\n \"compact\",\n \"medium\",\n \"large\",\n \"grande\",\n \"original\",\n \"master\",\n];\nconst urlCrops = [\"center\", \"top\", \"right\", \"bottom\", \"left\"];\nconst urlScales = [\"progressive\"];\nconst shopifyImageFiltersRegex = new RegExp(`((?:_(?:x|X)?)(?:(?:\\\\d{1,4}(?:x|X)\\\\d{0,4}|(?:x|X)\\\\d{1,4})|(?:${urlSizes.join(\"|\")})))?(_crop_(?:${urlCrops.join(\"|\")}))?(@[23]x)?(.(?:${urlScales.join(\"|\")}))?$`);\nconst removeExtn = (() => {\n let splits = [];\n return (imageUrl) => {\n let replacedUrl = imageUrl\n .replace(/\\.([^.]+?)$/, \"\");\n splits = replacedUrl.split(\".\");\n let stopIndex = -1;\n for (let i = 0; i < splits.length; i += 1) {\n if (extnSet.has(splits[i])) {\n stopIndex = i;\n break;\n }\n }\n replacedUrl = splits\n .slice(0, stopIndex > 0 ? stopIndex : undefined)\n .join(\".\");\n return replacedUrl;\n };\n})();\nconst parseImageUrl = (() => {\n const cache = {};\n return (src) => {\n const result = cache[src];\n if (typeof result === \"string\") {\n return result;\n }\n let parsedSrc = src;\n parsedSrc = parsedSrc.replace(/\\?v=.*/g, \"\");\n const extnRemovedSrc = removeExtn(parsedSrc);\n const match = extnRemovedSrc.match(shopifyImageFiltersRegex);\n if (match) {\n const { index = 0 } = match;\n const firstSplit = parsedSrc.slice(0, index);\n const lastSplit = parsedSrc.slice(index + match[0].length);\n parsedSrc = `${firstSplit}${lastSplit}`;\n }\n cache[src] = parsedSrc;\n return parsedSrc;\n };\n})();\nconst trimExtensionAndParams = (() => {\n const trimCache = {};\n return (url) => {\n let result = trimCache[url];\n if (typeof result === \"string\") {\n return result;\n }\n result = removeExtn(url);\n trimCache[url] = result;\n return result;\n };\n})();\nfunction matchStrings(sourceSrc, src) {\n return trimExtensionAndParams(sourceSrc) === trimExtensionAndParams(src);\n}\nfunction getMatchedUrl(sourceSrc, srcs) {\n return srcs.find((src) => matchStrings(sourceSrc, src)) || \"\";\n}\nfunction getFileName(fileURL) {\n var _a, _b;\n return (_b = (_a = fileURL.split(\"/\").pop()) === null || _a === void 0 ? void 0 : _a.split(\"?\")) === null || _b === void 0 ? void 0 : _b[0];\n}\nconst getCDNFilePath = (() => {\n const map = new Map([]);\n return (url, cdnPath) => {\n var _a;\n if (map.has(url)) {\n return map.get(url);\n }\n const parsedUrl = parseImageUrl(url);\n const extensions = parsedUrl.match(imageExtensionsRegex);\n if (!url.startsWith(\"/\") &&\n Array.isArray(extensions) &&\n extensions.length > 0) {\n const fileName = getFileName(parsedUrl);\n if (typeof fileName === \"string\") {\n const cdnFileURL = `${cdnPath}/${fileName}`;\n map.set(url, cdnFileURL);\n }\n }\n return (_a = map.get(url)) !== null && _a !== void 0 ? _a : url;\n };\n})();\nfunction getCDNOrigin(origin, cdnPrefix = \"/cdn\") {\n return `${origin}${cdnPrefix}`;\n}\nfunction getCurrentPage() {\n const { store } = Object(_platform__WEBPACK_IMPORTED_MODULE_3__[/* getPlatformData */ \"a\"])();\n const currentPath = window.location.pathname;\n if (currentPath.match(/^\\/(?:[a-z]{2})?$/)) {\n return \"home\";\n }\n if (currentPath.match(/\\/products\\/.+?$/)) {\n return \"product\";\n }\n if (currentPath.match(/\\/pages\\/.+?$/)) {\n return \"page\";\n }\n if (currentPath.includes(\"collection\") || currentPath.includes(\"search\")) {\n return \"collection\";\n }\n if (store === \"venustahome\" && currentPath.includes(\"campaign\")) {\n return \"home\";\n }\n return \"_not_supported_\";\n}\nconst modeMagicSettings = window.modeMagicPreviewSettings || window.modeMagicSettings || {};\nconst isElementVisible = (el) => {\n const isVisible = (elmt) => {\n const { visibility, display, opacity } = getComputedStyle(elmt);\n return !((document.hidden ||\n visibility === \"hidden\" ||\n display === \"none\" ||\n +opacity === 0));\n };\n let pointer = el;\n let visible = isVisible(pointer);\n while (visible && !!pointer.parentElement) {\n pointer = pointer.parentElement;\n visible = isVisible(pointer);\n }\n return visible;\n};\nconst isElementInViewport = (el, { areaCheck } = { areaCheck: true }) => {\n if (!isElementVisible(el)) {\n return false;\n }\n const { top, left, bottom, right } = el.getBoundingClientRect();\n const minMap = {\n x: 0,\n y: 0,\n };\n const maxMap = {\n x: window.innerWidth || document.documentElement.clientWidth,\n y: window.innerHeight || document.documentElement.clientHeight,\n };\n const getNormalized = (dim, val) => {\n const min = minMap[dim];\n const max = maxMap[dim];\n if (val < min) {\n return min;\n }\n if (val > max) {\n return max;\n }\n return val;\n };\n const visibleHeight = getNormalized(\"y\", bottom) - getNormalized(\"y\", top);\n const visibleWidth = getNormalized(\"x\", right) - getNormalized(\"x\", left);\n const visibleArea = visibleHeight * visibleWidth;\n return areaCheck ? visibleArea > 0 : visibleHeight > 0 || visibleWidth > 0;\n};\nconst proxify = (obj) => {\n let { logs: logCss } = obj !== null && obj !== void 0 ? obj : {};\n if (!logCss) {\n ({ logs: logCss } = obj === null || obj === void 0 ? void 0 : obj.constructor);\n }\n let cssStrings = [\"\", \"\"];\n if (logCss) {\n cssStrings = [\n Object.keys(logCss).reduce((acc, key) => `${acc}${key}: ${logCss[key]}; `, \"\"),\n \"background-color: rgb(76, 136, 255);color:white;\",\n \"color: rgb(76, 136, 255)\",\n ];\n }\n return utils_constants__WEBPACK_IMPORTED_MODULE_2__[/* isProduction */ \"b\"] || isTest\n ? obj\n : new Proxy(obj, {\n get(target, propKey, receiver) {\n const originalMethod = Reflect.get(target, propKey, receiver);\n if (typeof originalMethod === \"function\") {\n return function (...args) {\n var _a, _b;\n const prefix = `%c[${(_a = obj === null || obj === void 0 ? void 0 : obj.name) !== null && _a !== void 0 ? _a : (_b = obj === null || obj === void 0 ? void 0 : obj.constructor) === null || _b === void 0 ? void 0 : _b.name}]%c[${propKey.toString()}]%c: `;\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].group(prefix, ...cssStrings);\n if (args.length > 0) {\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].debug(`Called with: `, ...args);\n }\n const returns = originalMethod.apply(this, args);\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].debug(`Returning`, returns);\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].groupEnd();\n return returns;\n };\n }\n return originalMethod;\n },\n });\n};\nconst getQueryObject = () => {\n const { search } = window.location;\n if (!Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* isValidString */ \"l\"])(search)) {\n return {};\n }\n return JSON.parse(`{\"${search.slice(1).replace(/&/g, '\",\"').replace(/=/g, '\":\"')}\"}`, (key, value) => (key === \"\" ? value : decodeURIComponent(value)));\n};\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(16)))//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvY29tbW9uLnRzPzQ5NmMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFDd0M7QUFDSztBQUNFO0FBQ0Y7QUFDN0Msd0VBQXdFLDBJQUFXO0FBQ25GO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtB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CJwY2ZcIixcbiAgICBcInBjeFwiLFxuICAgIFwicGRuXCIsXG4gICAgXCJwZ21cIixcbiAgICBcIlBJMVwiLFxuICAgIFwiUEkyXCIsXG4gICAgXCJQSTNcIixcbiAgICBcInBpY3RcIixcbiAgICBcInBjdFwiLFxuICAgIFwicG5tXCIsXG4gICAgXCJwbnNcIixcbiAgICBcInBwbVwiLFxuICAgIFwicHNiXCIsXG4gICAgXCJwc2RcIixcbiAgICBcInBkZFwiLFxuICAgIFwicHNwXCIsXG4gICAgXCJweFwiLFxuICAgIFwicHhtXCIsXG4gICAgXCJweHJcIixcbiAgICBcInFmeFwiLFxuICAgIFwicmF3XCIsXG4gICAgXCJybGVcIixcbiAgICBcInNjdFwiLFxuICAgIFwic2dpXCIsXG4gICAgXCJyZ2JcIixcbiAgICBcImludFwiLFxuICAgIFwiYndcIixcbiAgICBcInRnYVwiLFxuICAgIFwidGlmZlwiLFxuICAgIFwidGlmXCIsXG4gICAgXCJ2dGZcIixcbiAgICBcInhibVwiLFxuICAgIFwieGNmXCIsXG4gICAgXCJ4cG1cIixcbiAgICBcIjNkdlwiLFxuICAgIFwiYW1mXCIsXG4gICAgXCJhaVwiLFxuICAgIFwiYXdnXCIsXG4gICAgXCJjZ21cIixcbiAgICBcImNkclwiLFxuICAgIFwiY214XCIsXG4gICAgXCJkeGZcIixcbiAgICBcImUyZFwiLFxuICAgIFwiZWd0XCIsXG4gICAgXCJlcHNcIixcbiAgICBcImZzXCIsXG4gICAgXCJnYnJcIixcbiAgICBcIm9kZ1wiLFxuICAgIFwic3ZnXCIsXG4gICAgXCJzdGxcIixcbiAgICBcInZybWxcIixcbiAgICBcIngzZFwiLFxuICAgIFwic3hkXCIsXG4gICAgXCJ2MmRcIixcbiAgICBcInZuZFwiLFxuICAgIFwid21mXCIsXG4gICAgXCJlbWZcIixcbiAgICBcImFydFwiLFxuICAgIFwieGFyXCIsXG4gICAgXCJwbmdcIixcbiAgICBcIndlYnBcIixcbiAgICBcImp4clwi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PiBgJHthY2N9JHtrZXl9OiAke2xvZ0Nzc1trZXldfTsgYCwgXCJcIiksXG4gICAgICAgICAgICBcImJhY2tncm91bmQtY29sb3I6IHJnYig3NiwgMTM2LCAyNTUpO2NvbG9yOndoaXRlO1wiLFxuICAgICAgICAgICAgXCJjb2xvcjogcmdiKDc2LCAxMzYsIDI1NSlcIixcbiAgICAgICAgXTtcbiAgICB9XG4gICAgcmV0dXJuIGlzUHJvZHVjdGlvbiB8fCBpc1Rlc3RcbiAgICAgICAgPyBvYmpcbiAgICAgICAgOiBuZXcgUHJveHkob2JqLCB7XG4gICAgICAgICAgICBnZXQodGFyZ2V0LCBwcm9wS2V5LCByZWNlaXZlcikge1xuICAgICAgICAgICAgICAgIGNvbnN0IG9yaWdpbmFsTWV0aG9kID0gUmVmbGVjdC5nZXQodGFyZ2V0LCBwcm9wS2V5LCByZWNlaXZlcik7XG4gICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBvcmlnaW5hbE1ldGhvZCA9PT0gXCJmdW5jdGlvblwiKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBmdW5jdGlvbiAoLi4uYXJncykge1xuICAgICAgICAgICAgICAgICAgICAgICAgdmFyIF9hLCBfYjtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHByZWZpeCA9IGAlY1skeyhfYSA9IG9iaiA9PT0gbnVsbCB8fCBvYmogPT09IHZvaWQgMCA/IHZvaWQgMCA6IG9iai5uYW1lKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiAoX2IgPSBvYmogPT09IG51bGwgfHwgb2JqID09PSB2b2lkIDAgPyB2b2lkIDAgOiBvYmouY29uc3RydWN0b3IpID09PSBudWxsIHx8IF9iID09PSB2b2lkIDAgPyB2b2lkIDAgOiBfYi5uYW1lfV0lY1ske3Byb3BLZXkudG9TdHJpbmcoKX1dJWM6IGA7XG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmdyb3VwKHByZWZpeCwgLi4uY3NzU3RyaW5ncyk7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoYXJncy5sZW5ndGggPiAwKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5kZWJ1ZyhgQ2FsbGVkIHdpdGg6IGAsIC4uLmFyZ3MpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgcmV0dXJucyA9IG9yaWdpbmFsTWV0aG9kLmFwcGx5KHRoaXMsIGFyZ3MpO1xuICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5kZWJ1ZyhgUmV0dXJuaW5nYCwgcmV0dXJucyk7XG4gICAgICAgICAgICAgICAgICAgICAgICBjb25zb2xlLmdyb3VwRW5kKCk7XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gcmV0dXJucztcbiAgICAgICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgcmV0dXJuIG9yaWdpbmFsTWV0aG9kO1xuICAgICAgICAgICAgfSxcbiAgICAgICAgfSk7XG59O1xuZXhwb3J0IGNvbnN0IGdldFF1ZXJ5T2JqZWN0ID0gKCkgPT4ge1xuICAgIGNvbnN0IHsgc2VhcmNoIH0gPSB3aW5kb3cubG9jYXRpb247XG4gICAgaWYgKCFpc1ZhbGlkU3RyaW5nKHNlYXJjaCkpIHtcbiAgICAgICAgcmV0dXJuIHt9O1xuICAgIH1cbiAgICByZXR1cm4gSlNPTi5wYXJzZShge1wiJHtzZWFyY2guc2xpY2UoMSkucmVwbGFjZSgvJi9nLCAnXCIsXCInKS5yZXBsYWNlKC89L2csICdcIjpcIicpfVwifWAsIChrZXksIHZhbHVlKSA9PiAoa2V5ID09PSBcIlwiID8gdmFsdWUgOiBkZWNvZGVVUklDb21wb25lbnQodmFsdWUpKSk7XG59O1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///4\n"); /***/ }), /* 5 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return getPlatformData; });\n/* harmony import */ var _kubric_types__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1);\n/* harmony import */ var _kubric_types__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_kubric_types__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var utils_lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);\n/* harmony import */ var _dataset__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(14);\n\n\n\nconst getPlatformData = () => {\n var _a, _b, _c;\n const defaultContext = {\n cart: null,\n platform: _kubric_types__WEBPACK_IMPORTED_MODULE_0__[\"Platforms\"].UNKNOWN,\n product: \"\",\n store: \"\",\n currency: {\n active_currency_code: \"\",\n active_currency_id: 1,\n },\n settings: {\n store_hash: \"\",\n secure_host: \"\",\n cdn_url: \"\",\n secure_base_url: \"\",\n channel_id: 1,\n },\n customer: null,\n dumps: {},\n urls: {\n home: \"\",\n },\n };\n if (typeof window !== \"undefined\") {\n if (typeof window.__store_context__ === \"undefined\") {\n window.__store_context__ = {};\n }\n Object.assign(window.__store_context__, Object.assign(Object.assign({}, defaultContext), window.__store_context__));\n if (Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* isValidString */ \"l\"])(window.__mmStore)) {\n Object.assign(window.__store_context__, {\n store: window.__mmStore.split(\".\")[0],\n });\n }\n if (Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* isObject */ \"h\"])(window.Shopify)) {\n const dataset = Object(_dataset__WEBPACK_IMPORTED_MODULE_2__[/* getDataset */ \"a\"])();\n const store = window.Shopify.shop.split(\".\")[0];\n Object.assign(window.__store_context__, {\n platform: _kubric_types__WEBPACK_IMPORTED_MODULE_0__[\"Platforms\"].SHOPIFY,\n store,\n dumps: {},\n currency: {\n active_currency_code: (_b = (_a = window.Shopify.currency) === null || _a === void 0 ? void 0 : _a.active) !== null && _b !== void 0 ? _b : \"USD\",\n active_currency_id: 1,\n },\n settings: {\n secure_base_url: `https://${window.Shopify.shop}`,\n secure_host: window.Shopify.shop,\n cdn_url: window.Shopify.cdnHost,\n store_hash: store,\n channel_id: 1,\n },\n cart: null,\n urls: {\n home: (_c = window.Shopify.routes) === null || _c === void 0 ? void 0 : _c.root,\n },\n product: dataset.product,\n });\n }\n return window.__store_context__;\n }\n return defaultContext;\n};\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvcGxhdGZvcm0udHM/NzU3ZiJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQTBDO0FBQ2E7QUFDaEI7QUFDaEM7QUFDUDtBQUNBO0FBQ0E7QUFDQSxrQkFBa0IsdURBQVM7QUFDM0I7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLFNBQVM7QUFDVDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxTQUFTO0FBQ1Q7QUFDQSxpQkFBaUI7QUFDakI7QUFDQTtBQUNBLFNBQVM7QUFDVDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsOEVBQThFO0FBQzlFLFlBQVksMEVBQWE7QUFDekI7QUFDQTtBQUNBLGFBQWE7QUFDYjtBQUNBLFlBQVkscUVBQVE7QUFDcEIsNEJBQTRCLG1FQUFVO0FBQ3RDO0FBQ0E7QUFDQSwwQkFBMEIsdURBQVM7QUFDbkM7QUFDQSx5QkFBeUI7QUFDekI7QUFDQTtBQUNBO0FBQ0EsaUJBQWlCO0FBQ2pCO0FBQ0EsZ0RBQWdELG9CQUFvQjtBQUNwRTtBQUNBO0FBQ0E7QUFDQTtBQUNBLGl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21lOiBcIlwiLFxuICAgICAgICB9LFxuICAgIH07XG4gICAgaWYgKHR5cGVvZiB3aW5kb3cgIT09IFwidW5kZWZpbmVkXCIpIHtcbiAgICAgICAgaWYgKHR5cGVvZiB3aW5kb3cuX19zdG9yZV9jb250ZXh0X18gPT09IFwidW5kZWZpbmVkXCIpIHtcbiAgICAgICAgICAgIHdpbmRvdy5fX3N0b3JlX2NvbnRleHRfXyA9IHt9O1xuICAgICAgICB9XG4gICAgICAgIE9iamVjdC5hc3NpZ24od2luZG93Ll9fc3RvcmVfY29udGV4dF9fLCBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIGRlZmF1bHRDb250ZXh0KSwgd2luZG93Ll9fc3RvcmVfY29udGV4dF9fKSk7XG4gICAgICAgIGlmIChpc1ZhbGlkU3RyaW5nKHdpbmRvdy5fX21tU3RvcmUpKSB7XG4gICAgICAgICAgICBPYmplY3QuYXNzaWduKHdpbmRvdy5fX3N0b3JlX2NvbnRleHRfXywge1xuICAgICAgICAgICAgICAgIHN0b3JlOiB3aW5kb3cuX19tbVN0b3JlLnNwbGl0KFwiLlwiKVswXSxcbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9XG4gICAgICAgIGlmIChpc09iamVjdCh3aW5kb3cuU2hvcGlmeSkpIHtcbiAgICAgICAgICAgIGNvbnN0IGRhdGFzZXQgPSBnZXREYXRhc2V0KCk7XG4gICAgICAgICAgICBjb25zdCBzdG9yZSA9IHdpbmRvdy5TaG9waWZ5LnNob3Auc3BsaXQoXCIuXCIpWzBdO1xuICAgICAgICAgICAgT2JqZWN0LmFzc2lnbih3aW5kb3cuX19zdG9yZV9jb250ZXh0X18sIHtcbiAgICAgICAgICAgICAgICBwbGF0Zm9ybTogUGxhdGZvcm1zLlNIT1BJRlksXG4gICAgICAgICAgICAgICAgc3RvcmUsXG4gICAgICAgICAgICAgICAgZHVtcHM6IHt9LFxuICAgICAgICAgICAgICAgIGN1cnJlbmN5OiB7XG4gICAgICAgICAgICAgICAgICAgIGFjdGl2ZV9jdXJyZW5jeV9jb2RlOiAoX2IgPSAoX2EgPSB3aW5kb3cuU2hvcGlmeS5jdXJyZW5jeSkgPT09IG51bGwgfHwgX2EgPT09IHZvaWQgMCA/IHZvaWQgMCA6IF9hLmFjdGl2ZSkgIT09IG51bGwgJiYgX2IgIT09IHZvaWQgMCA/IF9iIDogXCJVU0RcIixcbiAgICAgICAgICAgICAgICAgICAgYWN0aXZlX2N1cnJlbmN5X2lkOiAxLFxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgc2V0dGluZ3M6IHtcbiAgICAgICAgICAgICAgICAgICAgc2VjdXJlX2Jhc2VfdXJsOiBgaHR0cHM6Ly8ke3dpbmRvdy5TaG9waWZ5LnNob3B9YCxcbiAgICAgICAgICAgICAgICAgICAgc2VjdXJlX2hvc3Q6IHdpbmRvdy5TaG9waWZ5LnNob3AsXG4gICAgICAgICAgICAgICAgICAgIGNkbl91cmw6IHdpbmRvdy5TaG9waWZ5LmNkbkhvc3QsXG4gICAgICAgICAgICAgICAgICAgIHN0b3JlX2hhc2g6IHN0b3JlLFxuICAgICAgICAgICAgICAgICAgICBjaGFubmVsX2lkOiAxLFxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgY2FydDogbnVsbCxcbiAgICAgICAgICAgICAgICB1cmxzOiB7XG4gICAgICAgICAgICAgICAgICAgIGhvbWU6IChfYyA9IHdpbmRvdy5TaG9waWZ5LnJvdXRlcykgPT09IG51bGwgfHwgX2MgPT09IHZvaWQgMCA/IHZvaWQgMCA6IF9jLnJvb3QsXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICBwcm9kdWN0OiBkYXRhc2V0LnByb2R1Y3QsXG4gICAgICAgICAgICB9KTtcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gd2luZG93Ll9fc3RvcmVfY29udGV4dF9fO1xuICAgIH1cbiAgICByZXR1cm4gZGVmYXVsdENvbnRleHQ7XG59O1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///5\n"); /***/ }), /* 6 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* WEBPACK VAR INJECTION */(function(process) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return isProduction; });\n/* unused harmony export isTest */\n/* unused harmony export env */\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return EVENT_API_URL; });\nvar _a, _b, _c, _d;\nconst isProduction = ((_a = process === null || process === void 0 ? void 0 : {\"USER_FEATURES_API\":\"https://mm.beta.getmason.io/api/features\",\"APP_URL\":\"https://mm.beta.getmason.io/widgets/view\",\"NODE_ENV\":\"staging\"}) === null || _a === void 0 ? void 0 : _a.NODE_ENV) === \"production\";\nconst isTest = ((_b = process === null || process === void 0 ? void 0 : {\"USER_FEATURES_API\":\"https://mm.beta.getmason.io/api/features\",\"APP_URL\":\"https://mm.beta.getmason.io/widgets/view\",\"NODE_ENV\":\"staging\"}) === null || _b === void 0 ? void 0 : _b.NODE_ENV) === \"test\";\nconst env = (_d = (_c = process === null || process === void 0 ? void 0 : {\"USER_FEATURES_API\":\"https://mm.beta.getmason.io/api/features\",\"APP_URL\":\"https://mm.beta.getmason.io/widgets/view\",\"NODE_ENV\":\"staging\"}) === null || _c === void 0 ? void 0 : _c.NODE_ENV) !== null && _d !== void 0 ? _d : \"development\";\nconst eventAPI = {\n development: \"https://cf-events-passthrough.kubric-blog.workers.dev\",\n staging: \"https://cf-events-passthrough.kubric-blog.workers.dev\",\n production: \"https://events.getmodemagic.com\",\n};\nconst EVENT_API_URL = eventAPI[env];\n\n/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(16)))//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvY29uc3RhbnRzLnRzPzh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RldlwiLFxuICAgIHN0YWdpbmc6IFwiaHR0cHM6Ly9jZi1ldmVudHMtcGFzc3Rocm91Z2gua3VicmljLWJsb2cud29ya2Vycy5kZXZcIixcbiAgICBwcm9kdWN0aW9uOiBcImh0dHBzOi8vZXZlbnRzLmdldG1vZGVtYWdpYy5jb21cIixcbn07XG5leHBvcnQgY29uc3QgRVZFTlRfQVBJX1VSTCA9IGV2ZW50QVBJW2Vudl07XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///6\n"); /***/ }), /* 7 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; // EXPORTS __webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ EventType; }); __webpack_require__.d(__webpack_exports__, "c", function() { return /* binding */ PerfEntity; }); __webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ CFEvent_instance; }); // EXTERNAL MODULE: ./src/utils/Cache.ts var Cache = __webpack_require__(17); // EXTERNAL MODULE: ./src/utils/constants.ts var constants = __webpack_require__(6); // CONCATENATED MODULE: ./src/types/window.ts const INTERNALS = "__SECRET_INTERNALS_DO_NOT_USE__"; // EXTERNAL MODULE: ./src/utils/common.ts var common = __webpack_require__(4); // EXTERNAL MODULE: ./src/utils/console.ts var console = __webpack_require__(2); // EXTERNAL MODULE: ./src/utils/deviceID.ts var deviceID = __webpack_require__(9); // EXTERNAL MODULE: ./src/utils/lodash.ts var lodash = __webpack_require__(0); // EXTERNAL MODULE: ./src/utils/order.ts var utils_order = __webpack_require__(12); // EXTERNAL MODULE: ./src/features/constants.ts var features_constants = __webpack_require__(19); // EXTERNAL MODULE: ./src/utils/platform.ts var platform = __webpack_require__(5); // CONCATENATED MODULE: ./src/utils/CFEvent.ts var __rest = (undefined && undefined.__rest) || function (s, e) { var t = {}; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p]; if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]]; } return t; }; const enabledTPASet = new Set(Object.keys(utils_order["a" /* enabledTPAs */])); const QUEUE_MAX = 20; var EventType; (function (EventType) { EventType["CLICK"] = "click"; EventType["IMPRESSION"] = "impression"; EventType["VIEW"] = "view"; EventType["CONVERSION"] = "conversion"; EventType["HIDE"] = "hide"; EventType["PAGE_VIEW"] = "page_view"; })(EventType || (EventType = {})); var PerfEntity; (function (PerfEntity) { PerfEntity["PRODUCT_BANNER"] = "product-banner"; PerfEntity["STORE_BANNER"] = "store-banner"; PerfEntity["WIDGET"] = "widget"; PerfEntity["BADGE"] = "badge"; })(PerfEntity || (PerfEntity = {})); const DEFAULT_STATS = { impression: 0, view: 0, click: 0, conversion: 0, hide: 0, page_view: 0, }; const QueueIdentifiers = { ACTIVE_QUEUE: "active_queue", FLUSH_QUEUE: "flush_queue", }; class CFEvent_CFEvent { constructor() { this.impressionsCache = new Set(); this.viewsCache = new Set(); this.stats = DEFAULT_STATS; this.eventQueue = new Cache["a" /* Cache */](true); this.queTimeout = -1; this.queWaitTime = 8 * 1000; this.retryQueTimeout = -1; this.maxRetries = 3; } static getInstance() { if (typeof window !== "undefined") { if (typeof window.mm === "undefined") { window.mm = {}; } if (typeof window.mm[INTERNALS] === "undefined") { window.mm[INTERNALS] = { CFEvent: new CFEvent_CFEvent(), }; } if (typeof window.mm[INTERNALS].CFEvent === "undefined") { window.mm[INTERNALS].CFEvent = new CFEvent_CFEvent(); } return window.mm[INTERNALS].CFEvent; } return new CFEvent_CFEvent(); } init() { const instance = CFEvent_CFEvent.getInstance(); instance.eventQueue.init("mm__analytics"); instance.flushQueue(); window.addEventListener("popstate", () => { console["a" /* console */].debug("MM:Clearing impressions cache"); instance.impressionsCache = new Set(); instance.viewsCache = new Set(); instance.stats = DEFAULT_STATS; }); instance.addOrderCompletionListener(); } addOrderCompletionListener() { window.addEventListener("message", (event) => { const { data } = event; const { messageType, messageData: { actionType } = {} } = data; const source = Object(lodash["c" /* get */])(data, "messageAuth.source", null); const order = Object(lodash["c" /* get */])(data, "messageData.payload.order", null); const { id: orderId, line_items: lineItems = [], cart_token: cartToken = "", email = "", customer, customer_locale: customerLocale = "", } = order !== null && order !== void 0 ? order : {}; const { id: customerId = -1 } = customer !== null && customer !== void 0 ? customer : {}; if (messageType === "MODEMAGIC_CONVERSION_EVENT" && actionType === "ORDER_CREATE" && !Object(lodash["e" /* isNull */])(source) && enabledTPASet.has(source) && !Object(lodash["k" /* isUndefined */])(orderId)) { Object(utils_order["b" /* registerConversionEvent */])({ email, orderId, customerId, cartToken, customerLocale, source: source !== null && source !== void 0 ? source : undefined, lineItems, }); } }); } flushQueue() { var _a, _b, _c; const instance = CFEvent_CFEvent.getInstance(); const previousQueue = instance.eventQueue.get(QueueIdentifiers.FLUSH_QUEUE); if (!Object(lodash["e" /* isNull */])(previousQueue) && !Object(lodash["k" /* isUndefined */])(previousQueue)) { const now = new Date().getTime(); if (now - previousQueue.queued > instance.queWaitTime) { if (previousQueue.counter >= instance.maxRetries) { instance.eventQueue.set(QueueIdentifiers.ACTIVE_QUEUE, [ ...((_a = instance.eventQueue.get(QueueIdentifiers.ACTIVE_QUEUE)) !== null && _a !== void 0 ? _a : []), ...previousQueue.events, ]); instance.eventQueue.set(QueueIdentifiers.FLUSH_QUEUE, undefined); instance.flushQueue(); return; } instance.eventQueue.set(QueueIdentifiers.FLUSH_QUEUE, Object.assign(Object.assign({}, previousQueue), { queued: new Date().getTime(), counter: previousQueue.counter + 1 })); } else { if (instance.retryQueTimeout !== -1) { return; } const nextTimerIn = instance.queWaitTime - (now - previousQueue.queued) + 1000; instance.retryQueTimeout = window.setTimeout(() => { instance.retryQueTimeout = -1; instance.flushQueue(); }, nextTimerIn); return; } } else { const events = (_b = instance.eventQueue.get(QueueIdentifiers.ACTIVE_QUEUE)) !== null && _b !== void 0 ? _b : []; if (Array.isArray(events) && events.length > 0) { instance.eventQueue.set(QueueIdentifiers.ACTIVE_QUEUE, []); instance.eventQueue.set(QueueIdentifiers.FLUSH_QUEUE, { events, queued: new Date().getTime(), counter: 1, }); } } const events = (_c = instance.eventQueue.get(QueueIdentifiers.FLUSH_QUEUE)) === null || _c === void 0 ? void 0 : _c.events; if (Array.isArray(events) && events.length > 0) { const reqBody = JSON.stringify(events); fetch(constants["a" /* EVENT_API_URL */], { method: "POST", body: reqBody, }) .then(() => { instance.eventQueue.set(QueueIdentifiers.FLUSH_QUEUE, undefined); }) .catch(() => { }); } } queueEvent(request) { var _a; const instance = CFEvent_CFEvent.getInstance(); const events = [ ...((_a = instance.eventQueue.get(QueueIdentifiers.ACTIVE_QUEUE)) !== null && _a !== void 0 ? _a : []), request, ]; instance.eventQueue.set(QueueIdentifiers.ACTIVE_QUEUE, events); if (instance.queTimeout > 0) { window.clearTimeout(instance.queTimeout); instance.queTimeout = -1; } if (events.length >= QUEUE_MAX) { instance.flushQueue(); } else { instance.queTimeout = window.setTimeout(() => { instance.flushQueue(); }, 1000); } } raiseEvent(payload) { const { store } = Object(platform["a" /* getPlatformData */])(); const { appName = features_constants["a" /* DEFAULT_APP */], entity, eventType, data, element } = payload; const url = window.location.href; const queryObject = Object(common["e" /* getQueryObject */])(); const _a = data !== null && data !== void 0 ? data : {}, { product, storyboard, template, impressionsData, widgets, playbookId } = _a, restData = __rest(_a, ["product", "storyboard", "template", "impressionsData", "widgets", "playbookId"]); const timeSinceEpoch = new Date().getTime() / 1000; const instance = CFEvent_CFEvent.getInstance(); instance.stats[eventType] += 1; instance.log(entity, eventType, data, element); instance.queueEvent(Object.assign(Object.assign({ app_name: appName, store_id: store, product_id: product, storyboard_id: storyboard, widget_ids: widgets, template_id: template, category: entity, action: eventType, time: timeSinceEpoch, playbook_id: playbookId, device_id: Object(deviceID["a" /* getDeviceID */])(), full_url: url, query: queryObject }, restData), impressionsData)); } log(entity, eventType, data, element) { console["a" /* console */].debug(`MM:${entity}:${eventType}`); if (element) { console["a" /* console */].debug(`src element: `, element); } console["a" /* console */].debug(`data: `, JSON.stringify(data)); console["a" /* console */].debug(`stats: `, JSON.stringify(CFEvent_CFEvent.getInstance().stats)); } click(payload) { const { entity, element, data, appName } = payload; CFEvent_CFEvent.getInstance().raiseEvent({ appName, entity, eventType: EventType.CLICK, data, element, }); } impression(payload) { const { entity, element, data, appName } = payload; const instance = CFEvent_CFEvent.getInstance(); const isCached = instance.impressionsCache.has(element); if (!isCached) { instance.raiseEvent({ appName, entity, eventType: EventType.IMPRESSION, data, element, }); instance.impressionsCache.add(element); } } view(payload) { const { entity, element, data, appName } = payload; const instance = CFEvent_CFEvent.getInstance(); const isCached = instance.viewsCache.has(element); if (!isCached) { instance.raiseEvent({ appName, entity, eventType: EventType.VIEW, data, element, }); instance.viewsCache.add(element); } } hide(payload) { const { entity, element, data, appName } = payload; CFEvent_CFEvent.getInstance().raiseEvent({ appName, entity, eventType: EventType.HIDE, data, element, }); } conversion(payload) { const { data, appName } = payload; CFEvent_CFEvent.getInstance().raiseEvent({ appName, entity: PerfEntity.WIDGET, eventType: EventType.CONVERSION, data, }); } } const CFEvent_instance = CFEvent_CFEvent.getInstance(); /***/ }), /* 8 */, /* 9 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return getDeviceID; });\n/* harmony import */ var _lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);\n\nconst SESSION_KEY = \"mm.userDeviceID\";\nconst getDeviceID = () => {\n const deviceID = window.localStorage.getItem(SESSION_KEY);\n if (Object(_lodash__WEBPACK_IMPORTED_MODULE_0__[/* isNull */ \"e\"])(deviceID)) {\n const newDeviceID = JSON.stringify(performance.now()) +\n Math.random().toString(36).substring(2, 11);\n window.localStorage.setItem(SESSION_KEY, newDeviceID);\n return newDeviceID;\n }\n return deviceID;\n};\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvZGV2aWNlSUQudHM/ZTg1NCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtBQUFBO0FBQWtDO0FBQ2xDO0FBQ087QUFDUDtBQUNBLFFBQVEsOERBQU07QUFDZDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsImZpbGUiOiI5LmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgaXNOdWxsIH0gZnJvbSBcIi4vbG9kYXNoXCI7XG5jb25zdCBTRVNTSU9OX0tFWSA9IFwibW0udXNlckRldmljZUlEXCI7XG5leHBvcnQgY29uc3QgZ2V0RGV2aWNlSUQgPSAoKSA9PiB7XG4gICAgY29uc3QgZGV2aWNlSUQgPSB3aW5kb3cubG9jYWxTdG9yYWdlLmdldEl0ZW0oU0VTU0lPTl9LRVkpO1xuICAgIGlmIChpc051bGwoZGV2aWNlSUQpKSB7XG4gICAgICAgIGNvbnN0IG5ld0RldmljZUlEID0gSlNPTi5zdHJpbmdpZnkocGVyZm9ybWFuY2Uubm93KCkpICtcbiAgICAgICAgICAgIE1hdGgucmFuZG9tKCkudG9TdHJpbmcoMzYpLnN1YnN0cmluZygyLCAxMSk7XG4gICAgICAgIHdpbmRvdy5sb2NhbFN0b3JhZ2Uuc2V0SXRlbShTRVNTSU9OX0tFWSwgbmV3RGV2aWNlSUQpO1xuICAgICAgICByZXR1cm4gbmV3RGV2aWNlSUQ7XG4gICAgfVxuICAgIHJldHVybiBkZXZpY2VJRDtcbn07XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///9\n"); /***/ }), /* 10 */, /* 11 */, /* 12 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return enabledTPAs; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return registerConversionEvent; });\n/* harmony import */ var _CFEvent__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7);\n/* harmony import */ var _lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);\n\n\nconst enabledTPAs = {\n swift: true,\n shopflo: true,\n fastrr: true,\n};\nfunction registerConversionEvent(payload) {\n const { customerLocale, customerId, orderId, lineItems, email, cartToken, source, } = payload;\n const widgetsInOrder = lineItems.reduce((acc, { properties = {} }) => {\n const widgetPropertiesStr = properties.__mmWidget;\n const widgetProperties = Object(_lodash__WEBPACK_IMPORTED_MODULE_1__[/* safeParseJSON */ \"o\"])(widgetPropertiesStr, null);\n if (widgetProperties !== null &&\n !Array.isArray(widgetProperties) &&\n typeof widgetProperties === \"object\") {\n acc.push(widgetProperties);\n }\n return acc;\n }, []);\n _CFEvent__WEBPACK_IMPORTED_MODULE_0__[/* CFEvent */ \"a\"].conversion({\n appName: \"shopify\",\n data: {\n widgets: widgetsInOrder,\n meta: {\n source,\n line_items: lineItems,\n order: orderId,\n cartToken,\n src: window.location.href,\n customer: {\n id: customerId,\n locale: customerLocale,\n email,\n },\n },\n impressionsData: {\n apply_type: \"manual\",\n },\n },\n });\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvb3JkZXIudHM/MmI0NiJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFvQztBQUNLO0FBQ2xDO0FBQ1A7QUFDQTtBQUNBO0FBQ0E7QUFDTztBQUNQLFdBQVcsNEVBQTRFO0FBQ3ZGLG1EQUFtRCxnQkFBZ0IsRUFBRTtBQUNyRTtBQUNBLGlDQUFpQyxxRUFBYTtBQUM5QztBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7Q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zQXJyYXkod2lkZ2V0UHJvcGVydGllcykgJiZcbiAgICAgICAgICAgIHR5cGVvZiB3aWRnZXRQcm9wZXJ0aWVzID09PSBcIm9iamVjdFwiKSB7XG4gICAgICAgICAgICBhY2MucHVzaCh3aWRnZXRQcm9wZXJ0aWVzKTtcbiAgICAgICAgfVxuICAgICAgICByZXR1cm4gYWNjO1xuICAgIH0sIFtdKTtcbiAgICBDRkV2ZW50LmNvbnZlcnNpb24oe1xuICAgICAgICBhcHBOYW1lOiBcInNob3BpZnlcIixcbiAgICAgICAgZGF0YToge1xuICAgICAgICAgICAgd2lkZ2V0czogd2lkZ2V0c0luT3JkZXIsXG4gICAgICAgICAgICBtZXRhOiB7XG4gICAgICAgICAgICAgICAgc291cmNlLFxuICAgICAgICAgICAgICAgIGxpbmVfaXRlbXM6IGxpbmVJdGVtcyxcbiAgICAgICAgICAgICAgICBvcmRlcjogb3JkZXJJZCxcbiAgICAgICAgICAgICAgICBjYXJ0VG9rZW4sXG4gICAgICAgICAgICAgICAgc3JjOiB3aW5kb3cubG9jYXRpb24uaHJlZixcbiAgICAgICAgICAgICAgICBjdXN0b21lcjoge1xuICAgICAgICAgICAgICAgICAgICBpZDogY3VzdG9tZXJJZCxcbiAgICAgICAgICAgICAgICAgICAgbG9jYWxlOiBjdXN0b21lckxvY2FsZSxcbiAgICAgICAgICAgICAgICAgICAgZW1haWwsXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBpbXByZXNzaW9uc0RhdGE6IHtcbiAgICAgICAgICAgICAgICBhcHBseV90eXBlOiBcIm1hbnVhbFwiLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgfSxcbiAgICB9KTtcbn1cbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///12\n"); /***/ }), /* 13 */, /* 14 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return getDataset; });\nconst getDataset = () => {\n const appElements = document.querySelectorAll(\"[data-app='mm']\");\n let dataset = {};\n appElements.forEach((el) => {\n dataset = Object.assign(Object.assign({}, dataset), el.dataset);\n });\n return dataset;\n};\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvZGF0YXNldC50cz9hZWU3Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBO0FBQU87QUFDUDtBQUNBO0FBQ0E7QUFDQSxnREFBZ0Q7QUFDaEQsS0FBSztBQUNMO0FBQ0EiLCJmaWxlIjoiMTQuanMiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgY29uc3QgZ2V0RGF0YXNldCA9ICgpID0+IHtcbiAgICBjb25zdCBhcHBFbGVtZW50cyA9IGRvY3VtZW50LnF1ZXJ5U2VsZWN0b3JBbGwoXCJbZGF0YS1hcHA9J21tJ11cIik7XG4gICAgbGV0IGRhdGFzZXQgPSB7fTtcbiAgICBhcHBFbGVtZW50cy5mb3JFYWNoKChlbCkgPT4ge1xuICAgICAgICBkYXRhc2V0ID0gT2JqZWN0LmFzc2lnbihPYmplY3QuYXNzaWduKHt9LCBkYXRhc2V0KSwgZWwuZGF0YXNldCk7XG4gICAgfSk7XG4gICAgcmV0dXJuIGRhdGFzZXQ7XG59O1xuIl0sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///14\n"); /***/ }), /* 15 */, /* 16 */ /***/ (function(module, exports) { // shim for using process in browser var process = module.exports = {}; // cached from whatever global is present so that test runners that stub it // don't break things. But we need to wrap it in a try catch in case it is // wrapped in strict mode code which doesn't define any globals. It's inside a // function because try/catches deoptimize in certain engines. var cachedSetTimeout; var cachedClearTimeout; function defaultSetTimout() { throw new Error('setTimeout has not been defined'); } function defaultClearTimeout () { throw new Error('clearTimeout has not been defined'); } (function () { try { if (typeof setTimeout === 'function') { cachedSetTimeout = setTimeout; } else { cachedSetTimeout = defaultSetTimout; } } catch (e) { cachedSetTimeout = defaultSetTimout; } try { if (typeof clearTimeout === 'function') { cachedClearTimeout = clearTimeout; } else { cachedClearTimeout = defaultClearTimeout; } } catch (e) { cachedClearTimeout = defaultClearTimeout; } } ()) function runTimeout(fun) { if (cachedSetTimeout === setTimeout) { //normal enviroments in sane situations return setTimeout(fun, 0); } // if setTimeout wasn't available but was latter defined if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { cachedSetTimeout = setTimeout; return setTimeout(fun, 0); } try { // when when somebody has screwed with setTimeout but no I.E. maddness return cachedSetTimeout(fun, 0); } catch(e){ try { // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally return cachedSetTimeout.call(null, fun, 0); } catch(e){ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error return cachedSetTimeout.call(this, fun, 0); } } } function runClearTimeout(marker) { if (cachedClearTimeout === clearTimeout) { //normal enviroments in sane situations return clearTimeout(marker); } // if clearTimeout wasn't available but was latter defined if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { cachedClearTimeout = clearTimeout; return clearTimeout(marker); } try { // when when somebody has screwed with setTimeout but no I.E. maddness return cachedClearTimeout(marker); } catch (e){ try { // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally return cachedClearTimeout.call(null, marker); } catch (e){ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error. // Some versions of I.E. have different rules for clearTimeout vs setTimeout return cachedClearTimeout.call(this, marker); } } } var queue = []; var draining = false; var currentQueue; var queueIndex = -1; function cleanUpNextTick() { if (!draining || !currentQueue) { return; } draining = false; if (currentQueue.length) { queue = currentQueue.concat(queue); } else { queueIndex = -1; } if (queue.length) { drainQueue(); } } function drainQueue() { if (draining) { return; } var timeout = runTimeout(cleanUpNextTick); draining = true; var len = queue.length; while(len) { currentQueue = queue; queue = []; while (++queueIndex < len) { if (currentQueue) { currentQueue[queueIndex].run(); } } queueIndex = -1; len = queue.length; } currentQueue = null; draining = false; runClearTimeout(timeout); } process.nextTick = function (fun) { var args = new Array(arguments.length - 1); if (arguments.length > 1) { for (var i = 1; i < arguments.length; i++) { args[i - 1] = arguments[i]; } } queue.push(new Item(fun, args)); if (queue.length === 1 && !draining) { runTimeout(drainQueue); } }; // v8 likes predictible objects function Item(fun, array) { this.fun = fun; this.array = array; } Item.prototype.run = function () { this.fun.apply(null, this.array); }; process.title = 'browser'; process.browser = true; process.env = {}; process.argv = []; process.version = ''; // empty string to avoid regexp issues process.versions = {}; function noop() {} process.on = noop; process.addListener = noop; process.once = noop; process.off = noop; process.removeListener = noop; process.removeAllListeners = noop; process.emit = noop; process.prependListener = noop; process.prependOnceListener = noop; process.listeners = function (name) { return [] } process.binding = function (name) { throw new Error('process.binding is not supported'); }; process.cwd = function () { return '/' }; process.chdir = function (dir) { throw new Error('process.chdir is not supported'); }; process.umask = function() { return 0; }; /***/ }), /* 17 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return Cache; });\n/* harmony import */ var _lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);\n\nclass Cache {\n constructor(persistent = true) {\n this.sessionKey = \"\";\n this.cache = new Map();\n this.persistent = true;\n this.persistent = !!persistent;\n }\n init(cacheKey) {\n this.sessionKey = `${cacheKey}-cache`;\n this.cache = new Map(Object(_lodash__WEBPACK_IMPORTED_MODULE_0__[/* safeParseJSON */ \"o\"])(this.persistent\n ? window.localStorage.getItem(this.sessionKey)\n : window.sessionStorage.getItem(this.sessionKey), []));\n }\n get(key) {\n return this.cache.get(key);\n }\n set(key, data) {\n this.cache.set(key, data);\n if (this.persistent) {\n window.localStorage.setItem(this.sessionKey, JSON.stringify(Array.from(this.cache.entries())));\n return;\n }\n window.sessionStorage.setItem(this.sessionKey, JSON.stringify(Array.from(this.cache.entries())));\n }\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvdXRpbHMvQ2FjaGUudHM/MTI1NyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtBQUFBO0FBQXlDO0FBQ2xDO0FBQ1A7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSw2QkFBNkIsU0FBUztBQUN0Qyw2QkFBNkIscUVBQWE7QUFDMUM7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBIiwiZmlsZSI6IjE3LmpzIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgc2FmZVBhcnNlSlNPTiB9IGZyb20gXCIuL2xvZGFzaFwiO1xuZXhwb3J0IGNsYXNzIENhY2hlIHtcbiAgICBjb25zdHJ1Y3RvcihwZXJzaXN0ZW50ID0gdHJ1ZSkge1xuICAgICAgICB0aGlzLnNlc3Npb25LZXkgPSBcIlwiO1xuICAgICAgICB0aGlzLmNhY2hlID0gbmV3IE1hcCgpO1xuICAgICAgICB0aGlzLnBlcnNpc3RlbnQgPSB0cnVlO1xuICAgICAgICB0aGlzLnBlcnNpc3RlbnQgPSAhIXBlcnNpc3RlbnQ7XG4gICAgfVxuICAgIGluaXQoY2FjaGVLZXkpIHtcbiAgICAgICAgdGhpcy5zZXNzaW9uS2V5ID0gYCR7Y2FjaGVLZXl9LWNhY2hlYDtcbiAgICAgICAgdGhpcy5jYWNoZSA9IG5ldyBNYXAoc2FmZVBhcnNlSlNPTih0aGlzLnBlcnNpc3RlbnRcbiAgICAgICAgICAgID8gd2luZG93LmxvY2FsU3RvcmFnZS5nZXRJdGVtKHRoaXMuc2Vzc2lvbktleSlcbiAgICAgICAgICAgIDogd2luZG93LnNlc3Npb25TdG9yYWdlLmdldEl0ZW0odGhpcy5zZXNzaW9uS2V5KSwgW10pKTtcbiAgICB9XG4gICAgZ2V0KGtleSkge1xuICAgICAgICByZXR1cm4gdGhpcy5jYWNoZS5nZXQoa2V5KTtcbiAgICB9XG4gICAgc2V0KGtleSwgZGF0YSkge1xuICAgICAgICB0aGlzLmNhY2hlLnNldChrZXksIGRhdGEpO1xuICAgICAgICBpZiAodGhpcy5wZXJzaXN0ZW50KSB7XG4gICAgICAgICAgICB3aW5kb3cubG9jYWxTdG9yYWdlLnNldEl0ZW0odGhpcy5zZXNzaW9uS2V5LCBKU09OLnN0cmluZ2lmeShBcnJheS5mcm9tKHRoaXMuY2FjaGUuZW50cmllcygpKSkpO1xuICAgICAgICAgICAgcmV0dXJuO1xuICAgICAgICB9XG4gICAgICAgIHdpbmRvdy5zZXNzaW9uU3RvcmFnZS5zZXRJdGVtKHRoaXMuc2Vzc2lvbktleSwgSlNPTi5zdHJpbmdpZnkoQXJyYXkuZnJvbSh0aGlzLmNhY2hlLmVudHJpZXMoKSkpKTtcbiAgICB9XG59XG4iXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///17\n"); /***/ }), /* 18 */, /* 19 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return DEFAULT_APP; });\nconst DEFAULT_APP = \"-- empty --\";\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvZmVhdHVyZXMvY29uc3RhbnRzLnRzP2YzN2QiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7QUFBTyIsImZpbGUiOiIxOS5qcyIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBjb25zdCBERUZBVUxUX0FQUCA9IFwiLS0gZW1wdHkgLS1cIjtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///19\n"); /***/ }), /* 20 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return PathChangeListener; });\nclass PathChangeListener {\n static init() {\n window.history.replaceState = new Proxy(window.history.replaceState, {\n apply: (target, thisArg, args) => {\n const [, , url] = args;\n target.apply(thisArg, args);\n PathChangeListener.listeners.forEach((fn) => typeof url === \"string\" && fn(url.split(\"?\")[1] || \"\"));\n },\n });\n }\n static listen(listener) {\n PathChangeListener.unlisten(listener);\n PathChangeListener.listeners.push(listener);\n }\n static unlisten(listener) {\n PathChangeListener.listeners = PathChangeListener.listeners.filter((fn) => fn !== listener);\n }\n}\nPathChangeListener.listeners = [];\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvZmVhdHVyZXMvd2lkZ2V0cy91dGlscy9QYXRoQ2hhbmdlTGlzdGVuZXIudHM/MWI1OCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTtBQUFlO0FBQ2Y7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsYUFBYTtBQUNiLFNBQVM7QUFDVDtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSIsImZpbGUiOiIyMC5qcyIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCBkZWZhdWx0IGNsYXNzIFBhdGhDaGFuZ2VMaXN0ZW5lciB7XG4gICAgc3RhdGljIGluaXQoKSB7XG4gICAgICAgIHdpbmRvdy5oaXN0b3J5LnJlcGxhY2VTdGF0ZSA9IG5ldyBQcm94eSh3aW5kb3cuaGlzdG9yeS5yZXBsYWNlU3RhdGUsIHtcbiAgICAgICAgICAgIGFwcGx5OiAodGFyZ2V0LCB0aGlzQXJnLCBhcmdzKSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3QgWywgLCB1cmxdID0gYXJncztcbiAgICAgICAgICAgICAgICB0YXJnZXQuYXBwbHkodGhpc0FyZywgYXJncyk7XG4gICAgICAgICAgICAgICAgUGF0aENoYW5nZUxpc3RlbmVyLmxpc3RlbmVycy5mb3JFYWNoKChmbikgPT4gdHlwZW9mIHVybCA9PT0gXCJzdHJpbmdcIiAmJiBmbih1cmwuc3BsaXQoXCI/XCIpWzFdIHx8IFwiXCIpKTtcbiAgICAgICAgICAgIH0sXG4gICAgICAgIH0pO1xuICAgIH1cbiAgICBzdGF0aWMgbGlzdGVuKGxpc3RlbmVyKSB7XG4gICAgICAgIFBhdGhDaGFuZ2VMaXN0ZW5lci51bmxpc3RlbihsaXN0ZW5lcik7XG4gICAgICAgIFBhdGhDaGFuZ2VMaXN0ZW5lci5saXN0ZW5lcnMucHVzaChsaXN0ZW5lcik7XG4gICAgfVxuICAgIHN0YXRpYyB1bmxpc3RlbihsaXN0ZW5lcikge1xuICAgICAgICBQYXRoQ2hhbmdlTGlzdGVuZXIubGlzdGVuZXJzID0gUGF0aENoYW5nZUxpc3RlbmVyLmxpc3RlbmVycy5maWx0ZXIoKGZuKSA9PiBmbiAhPT0gbGlzdGVuZXIpO1xuICAgIH1cbn1cblBhdGhDaGFuZ2VMaXN0ZW5lci5saXN0ZW5lcnMgPSBbXTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///20\n"); /***/ }), /* 21 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"c\", function() { return resolveMissingDataSets; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"b\", function() { return getFeaturesAPIParams; });\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"a\", function() { return attachQueryParams; });\n/* harmony import */ var utils_dataset__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(14);\n/* harmony import */ var utils_lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(0);\n/* harmony import */ var _kubric_types__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);\n/* harmony import */ var _kubric_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_kubric_types__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var utils_platform__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);\n/* harmony import */ var utils_deviceID__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(9);\nvar __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\n\n\n\n\n\nconst SHOPFLO_COD_TAG = \"COD\";\nconst getProductId = () => __awaiter(void 0, void 0, void 0, function* () {\n var _a, _b;\n let productId = null;\n try {\n const productPath = window.location.pathname;\n if (productPath.includes(\"/products/\")) {\n const data = yield fetch(`${window.location.pathname}.json`).then((res) => res.json());\n productId = (_b = (_a = data === null || data === void 0 ? void 0 : data.product) === null || _a === void 0 ? void 0 : _a.id) === null || _b === void 0 ? void 0 : _b.toString();\n }\n }\n catch (err) {\n console.debug(err);\n }\n return productId !== null && productId !== void 0 ? productId : null;\n});\nconst resolveMissingDataSets = () => __awaiter(void 0, void 0, void 0, function* () {\n const dataset = Object(utils_dataset__WEBPACK_IMPORTED_MODULE_0__[/* getDataset */ \"a\"])();\n if (!dataset.product && Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* isObject */ \"h\"])(window.Shopify)) {\n const productId = yield getProductId();\n if (typeof productId === \"string\") {\n dataset.product = productId;\n const tag = document.createElement(\"div\");\n tag.setAttribute(\"data-app\", \"mm\");\n tag.setAttribute(\"data-product\", productId);\n document.body.appendChild(tag);\n }\n }\n return Promise.resolve();\n});\nconst isShopfloCODOrder = () => {\n return new Promise((resolve) => {\n const intervalId = setInterval(() => {\n const orderTags = Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* get */ \"c\"])(window, \"Shopflo.order.tags\", \"\")\n .split(\",\")\n .map((s) => s.trim())\n .filter((s) => s.length > 0);\n if (orderTags.length > 0) {\n const tagSet = new Set(orderTags);\n clearInterval(intervalId);\n resolve(tagSet.has(SHOPFLO_COD_TAG) ? \"true\" : \"false\");\n }\n }, 100);\n });\n};\nconst getFeaturesAPIParams = (features = []) => __awaiter(void 0, void 0, void 0, function* () {\n var _c, _d;\n const { store, product } = Object(utils_platform__WEBPACK_IMPORTED_MODULE_3__[/* getPlatformData */ \"a\"])();\n const hasShopflo = !Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* isUndefined */ \"k\"])(window.Shopflo);\n const isThankYouPage = typeof ((_c = window.Shopify) === null || _c === void 0 ? void 0 : _c.checkout) !== \"undefined\" ||\n (hasShopflo &&\n new URLSearchParams(window.location.search).get(\"page\") === \"thank_you\")\n ? \"true\"\n : \"false\";\n let isShopfloCOD = \"false\";\n let cartValue = -1;\n if (isThankYouPage === \"true\") {\n isShopfloCOD = yield isShopfloCODOrder();\n cartValue = (_d = +Object(utils_lodash__WEBPACK_IMPORTED_MODULE_1__[/* get */ \"c\"])(window, \"Shopflo.order.total_price\", \"0\")) !== null && _d !== void 0 ? _d : -1;\n }\n return {\n shop: store,\n path: window.location.pathname,\n domain: window.location.host,\n product,\n app: _kubric_types__WEBPACK_IMPORTED_MODULE_2__[\"FeaturesAPIApp\"].MODEMAGIC,\n hash: window.location.hash,\n device_id: Object(utils_deviceID__WEBPACK_IMPORTED_MODULE_4__[/* getDeviceID */ \"a\"])(),\n thankyou: isThankYouPage,\n shopflo_cod: isShopfloCOD,\n cart_value: `${cartValue}`,\n query: window.encodeURIComponent(window.location.search),\n features,\n };\n});\nconst attachQueryParams = (url, obj) => {\n Object.entries(obj).forEach(([key, value]) => {\n if (value) {\n if (Array.isArray(value)) {\n value.forEach((v) => url.searchParams.set(key, v));\n }\n else {\n url.searchParams.set(key, value);\n }\n }\n });\n};\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvbG9hZGVyL3V0aWxzLnRzP2U3NzIiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUEsaUJBQWlCLFNBQUksSUFBSSxTQUFJO0FBQzdCLDJCQUEyQiwrREFBK0QsZ0JBQWdCLEVBQUUsRUFBRTtBQUM5RztBQUNBLG1DQUFtQyxNQUFNLDZCQUE2QixFQUFFLFlBQVksV0FBVyxFQUFFO0FBQ2pHLGtDQUFrQyxNQUFNLGlDQUFpQyxFQUFFLFlBQVksV0FBVyxFQUFFO0FBQ3BHLCtCQUErQixxRkFBcUY7QUFDcEg7QUFDQSxLQUFLO0FBQ0w7QUFDMkM7QUFDZTtBQUNWO0FBQ0M7QUFDSjtBQUM3QztBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLHdDQUF3Qyx5QkFBeUI7QUFDakU7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxDQUFDO0FBQ007QUFDUCxvQkFBb0Isd0VBQVU7QUFDOUIsNEJBQTRCLHFFQUFRO0FBQ3BDO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ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IH0pO1xufTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///21\n"); /***/ }), /* 22 */, /* 23 */, /* 24 */, /* 25 */, /* 26 */, /* 27 */, /* 28 */, /* 29 */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, \"addFeatureSettings\", function() { return addFeatureSettings; });\n/* harmony import */ var utils_console__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);\n/* harmony import */ var utils_deviceID__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9);\n/* harmony import */ var utils_CFEvent__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7);\n/* harmony import */ var utils_platform__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5);\n/* harmony import */ var utils_constants__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6);\n/* harmony import */ var _features_widgets_utils_PathChangeListener__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(20);\n/* harmony import */ var _utils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(21);\nvar __awaiter = (undefined && undefined.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\n\n\n\n\n\n\n\nfunction addFeatureSettings(feature, settings, app = \"modeMagic\") {\n const settingsPath = `${app}Settings`;\n if (typeof window[settingsPath] === \"undefined\") {\n window[settingsPath] = {};\n }\n if (typeof settings !== \"undefined\") {\n window[settingsPath][feature] = settings;\n }\n}\nfunction loadScripts(scripts) {\n scripts.forEach(({ name, src, data }) => {\n addFeatureSettings(name, data, \"modeMagic\");\n const script = document.createElement(\"script\");\n script.setAttribute(\"data-mm-script\", name);\n script.setAttribute(\"type\", \"text/javascript\");\n script.setAttribute(\"src\", src);\n script.setAttribute(\"fetchPriority\", \"high\");\n document.body.appendChild(script);\n });\n}\nfunction onFeaturesLoaded(req) {\n try {\n const responseJSON = JSON.parse(req.responseText);\n const scripts = responseJSON.data;\n loadScripts(scripts);\n }\n catch (ex) {\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].debug(ex);\n }\n}\nconst triggerPageView = () => {\n const { store, product } = Object(utils_platform__WEBPACK_IMPORTED_MODULE_3__[/* getPlatformData */ \"a\"])();\n const timeSinceEpoch = new Date().getTime() / 1000;\n fetch(utils_constants__WEBPACK_IMPORTED_MODULE_4__[/* EVENT_API_URL */ \"a\"], {\n method: \"POST\",\n body: JSON.stringify({\n device_id: Object(utils_deviceID__WEBPACK_IMPORTED_MODULE_1__[/* getDeviceID */ \"a\"])(),\n meta: {\n url: window.location.href,\n },\n product_id: product !== null && product !== void 0 ? product : \"\",\n action: utils_CFEvent__WEBPACK_IMPORTED_MODULE_2__[/* EventType */ \"b\"].PAGE_VIEW,\n time: timeSinceEpoch,\n store_id: store,\n category: \"price_drop\",\n }),\n });\n};\nfunction load() {\n return __awaiter(this, void 0, void 0, function* () {\n let firstEventTriggered = false;\n const params = yield Object(_utils__WEBPACK_IMPORTED_MODULE_6__[/* getFeaturesAPIParams */ \"b\"])();\n if (!firstEventTriggered) {\n triggerPageView();\n firstEventTriggered = true;\n window === null || window === void 0 ? void 0 : window.addEventListener(\"popstate\", () => {\n if (firstEventTriggered) {\n triggerPageView();\n }\n });\n }\n const url = new URL({\"USER_FEATURES_API\":\"https://mm.beta.getmason.io/api/features\",\"APP_URL\":\"https://mm.beta.getmason.io/widgets/view\",\"NODE_ENV\":\"staging\"}.USER_FEATURES_API);\n Object(_utils__WEBPACK_IMPORTED_MODULE_6__[/* attachQueryParams */ \"a\"])(url, params);\n const http = new XMLHttpRequest();\n http.addEventListener(\"load\", onFeaturesLoaded.bind(null, http));\n if (!(window === null || window === void 0 ? void 0 : window.MMScriptLoaded)) {\n http.open(\"GET\", url.toString(), true);\n http.send();\n window.MMScriptLoaded = true;\n }\n });\n}\nconst init = () => __awaiter(void 0, void 0, void 0, function* () {\n var _a;\n if (!(window === null || window === void 0 ? void 0 : window.MMScriptLoaded)) {\n window.MMScriptLoaded = (_a = window === null || window === void 0 ? void 0 : window.MMScriptLoaded) !== null && _a !== void 0 ? _a : false;\n yield Object(_utils__WEBPACK_IMPORTED_MODULE_6__[/* resolveMissingDataSets */ \"c\"])();\n if (document.readyState === \"loading\") {\n document.addEventListener(\"DOMContentLoaded\", load);\n }\n else {\n yield load();\n }\n }\n});\n(() => {\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].debug(\"[loader] starting initialization\");\n init();\n _features_widgets_utils_PathChangeListener__WEBPACK_IMPORTED_MODULE_5__[/* default */ \"a\"].init();\n _features_widgets_utils_PathChangeListener__WEBPACK_IMPORTED_MODULE_5__[/* default */ \"a\"].listen(() => {\n if (typeof window !== \"undefined\" &&\n window.MMScriptLoaded &&\n typeof window.Shopflo !== \"undefined\" &&\n new URLSearchParams(window.location.search).get(\"page\") === \"thank_you\") {\n utils_console__WEBPACK_IMPORTED_MODULE_0__[/* console */ \"a\"].debug(\"[loader] re-initializing as shopflo integration changed query param in thank you page\");\n window.MMScriptLoaded = false;\n init();\n }\n });\n})();\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvbG9hZGVyL2luZGV4LnRzP2ViM2UiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUEsaUJB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hQYXJhbXMod2luZG93LmxvY2F0aW9uLnNlYXJjaCkuZ2V0KFwicGFnZVwiKSA9PT0gXCJ0aGFua195b3VcIikge1xuICAgICAgICAgICAgY29uc29sZS5kZWJ1ZyhcIltsb2FkZXJdIHJlLWluaXRpYWxpemluZyBhcyBzaG9wZmxvIGludGVncmF0aW9uIGNoYW5nZWQgcXVlcnkgcGFyYW0gaW4gdGhhbmsgeW91IHBhZ2VcIik7XG4gICAgICAgICAgICB3aW5kb3cuTU1TY3JpcHRMb2FkZWQgPSBmYWxzZTtcbiAgICAgICAgICAgIGluaXQoKTtcbiAgICAgICAgfVxuICAgIH0pO1xufSkoKTtcbiJdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///29\n"); /***/ }) /******/ ]);