shopify_app 21.6.0 → 21.7.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,10 @@
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("app-bridge",[],t):"object"==typeof exports?exports["app-bridge"]=t():e["app-bridge"]=t()}(window,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=53)}([function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.updateActionFromPayload=t.isValidOptionalString=t.isValidOptionalNumber=t.forEachInEnum=t.getMergedProps=t.findMatchInEnum=t.getEventNameSpace=t.NonSnakeCaseGroup=t.actionWrapper=void 0;var o=r(n(54)),i=n(23),a=n(1);function u(e,t){var n=o.default(e,t);return n||Object.assign(e,t)}t.actionWrapper=function(e){return e},t.NonSnakeCaseGroup=[a.Group.AuthCode,a.Group.Button,a.Group.ButtonGroup,a.Group.Cart,a.Group.Error,a.Group.Features,a.Group.Fullscreen,a.Group.Link,a.Group.Loading,a.Group.Menu,a.Group.Modal,a.Group.Navigation,a.Group.Pos,a.Group.Print,a.Group.ResourcePicker,a.Group.Scanner,a.Group.SessionToken,a.Group.Share,a.Group.TitleBar,a.Group.Toast,a.Group.unstable_Picker],t.getEventNameSpace=function(e,n,r){if(n.startsWith(""+i.PREFIX+i.SEPARATOR))return n;var o=function(e){return t.NonSnakeCaseGroup.includes(e)?e.toUpperCase():(n=e,n.replace(/([A-Z])/g,(function(e,t,n){return(0===n?"":"_")+e[0].toLowerCase()}))).toUpperCase();var n}(e);if(r){var a=r.subgroups,u=r.type;a&&a.length>0&&(o+=o.length>0?i.SEPARATOR:"",a.forEach((function(e,t){o+=""+e.toUpperCase()+(t<a.length-1?i.SEPARATOR:"")}))),u!==e&&u&&(o+=""+(o.length>0?i.SEPARATOR:"")+u.toUpperCase())}return o&&(o+=""+(o.length>0?i.SEPARATOR:"")+n.toUpperCase()),""+i.PREFIX+i.SEPARATOR+o},t.findMatchInEnum=function(e,t){var n=Object.keys(e).find((function(n){return t===e[n]}));return n?e[n]:void 0},t.getMergedProps=u,t.forEachInEnum=function(e,t){Object.keys(e).forEach((function(n){t(e[n])}))},t.isValidOptionalNumber=function(e){return null==e||"number"==typeof e},t.isValidOptionalString=function(e){return null==e||"string"==typeof e},t.updateActionFromPayload=function(e,t){return e.id===t.id&&(Object.assign(e,u(e,t)),!0)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ComponentType=t.Group=void 0,function(e){e.AuthCode="AuthCode",e.Button="Button",e.ButtonGroup="ButtonGroup",e.Cart="Cart",e.Client="Client",e.ContextualSaveBar="ContextualSaveBar",e.Error="Error",e.Features="Features",e.FeedbackModal="FeedbackModal",e.Fullscreen="Fullscreen",e.LeaveConfirmation="LeaveConfirmation",e.Link="Link",e.Loading="Loading",e.Menu="Menu",e.Modal="Modal",e.Navigation="Navigation",e.Performance="Performance",e.Pos="Pos",e.Print="Print",e.ResourcePicker="Resource_Picker",e.unstable_Picker="unstable_Picker",e.Scanner="Scanner",e.SessionToken="SessionToken",e.Share="Share",e.TitleBar="TitleBar",e.Toast="Toast",e.MarketingExternalActivityTopBar="MarketingExternalActivityTopBar",e.WebVitals="WebVitals"}(t.Group||(t.Group={})),function(e){e.Button="Button",e.ButtonGroup="ButtonGroup"}(t.ComponentType||(t.ComponentType={}))},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.unsubscribeActions=t.ActionSetWithChildren=t.ActionSet=void 0;var c=n(6),s=n(14),p=n(5),f=n(1),l=u(n(34)),d=n(0),h=function(){function e(e,t,n,r){var o=this;this.app=e,this.type=t,this.group=n,this.subgroups=[],this.subscriptions=[],e||p.throwError(p.Action.INVALID_ACTION,"Missing required `app`"),this.id=r||l.default(),this.defaultGroup=n;var i=this.set;this.set=function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return o.app.hooks?(e=o.app.hooks).run.apply(e,a([c.LifecycleHook.UpdateAction,i,o],t)):i.apply(o,t)}}return e.prototype.set=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t]},Object.defineProperty(e.prototype,"component",{get:function(){return{id:this.id,subgroups:this.subgroups,type:this.type}},enumerable:!1,configurable:!0}),e.prototype.updateSubscription=function(e,t,n){var r,o=e.eventType,i=e.callback,a=e.component;return(r=this.subscriptions.findIndex((function(t){return t===e})))>=0?this.subscriptions[r].unsubscribe():r=void 0,this.group=t,this.subgroups=n,Object.assign(a,{subgroups:this.subgroups}),this.subscribe(o,i,a,r)},e.prototype.error=function(e){var t=this,n=[];return d.forEachInEnum(p.Action,(function(r){n.push(t.subscriptions.length),t.subscribe(r,e)})),function(){n.map((function(e){return t.subscriptions[e]})).forEach((function(e){s.removeFromCollection(t.subscriptions,e,(function(e){e.unsubscribe()}))}))}},e.prototype.subscribe=function(e,t,n,r){var o,a=this,u=n||this.component,c=e.toUpperCase(),s="number"==typeof r?t:t.bind(this);o=p.isErrorEventName(e)?d.getEventNameSpace(f.Group.Error,e,i(i({},u),{type:""})):d.getEventNameSpace(this.group,e,u);var l=this.app.subscribe(o,s,n?n.id:this.id),h={eventType:c,unsubscribe:l,callback:s,component:u,updateSubscribe:function(e,t){return a.updateSubscription(h,e,t)}};return"number"==typeof r&&r>=0&&r<this.subscriptions.length?this.subscriptions[r]=h:this.subscriptions.push(h),l},e.prototype.unsubscribe=function(e){return void 0===e&&(e=!1),b(this.subscriptions,this.defaultGroup,e),this},e}();t.ActionSet=h;var y=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.children=[],t}return o(t,e),t.prototype.unsubscribe=function(e,n){return void 0===e&&(e=!0),void 0===n&&(n=!1),b(this.subscriptions,this.defaultGroup,n),this.children.forEach((function(n){n instanceof t?n.unsubscribe(e,!e):n.unsubscribe(!e)})),this},t.prototype.getChild=function(e){var t=this.children.findIndex((function(t){return t.id===e}));return t>=0?this.children[t]:void 0},t.prototype.getChildIndex=function(e){return this.children.findIndex((function(t){return t.id===e}))},t.prototype.getChildSubscriptions=function(e,t){return this.subscriptions.filter((function(n){return n.component.id===e&&(!t||t===n.eventType)}))},t.prototype.addChild=function(e,n,r){var o=this,i=e.subscriptions;return this.getChild(e.id)||this.children.push(e),!i||n===e.group&&r===e.subgroups||(i.forEach((function(e){(0,e.updateSubscribe)(n,r)})),Object.assign(e,{group:n,subgroups:r}),e instanceof t&&e.children.forEach((function(e){return o.addChild(e,n,r)}))),this},t.prototype.removeChild=function(e){var t=this;return s.removeFromCollection(this.children,this.getChild(e),(function(){t.subscriptions.filter((function(t){return t.component.id===e})).forEach((function(e){s.removeFromCollection(t.subscriptions,e,(function(e){e.unsubscribe()}))}))})),this},t.prototype.subscribeToChild=function(e,t,n){var r=this,o=n.bind(this);if(t instanceof Array)return t.forEach((function(t){return r.subscribeToChild(e,t,n)})),this;if("string"!=typeof t)return this;var i=t.toUpperCase(),a=this.getChildSubscriptions(e.id,i);if(a.length>0)a.forEach((function(t){return t.updateSubscribe(r.group,e.subgroups)}));else{var u={id:e.id,subgroups:e.subgroups,type:e.type};this.subscribe(i,o,u)}return this},t.prototype.getUpdatedChildActions=function(e,t){if(0!==e.length){for(var n=e.filter((function(e,t,n){return t===n.indexOf(e)})),r=n.map((function(e){return e.id})),o=t.filter((function(e){return r.indexOf(e.id)<0}));o.length>0;){if(!(i=o.pop()))break;this.removeChild(i.id)}return n}for(;t.length>0;){var i;if(!(i=t.pop()))break;this.removeChild(i.id)}},t}(h);function b(e,t,n){void 0===n&&(n=!1),e.forEach((function(e){n?(0,e.updateSubscribe)(t,[]):(0,e.unsubscribe)()})),n||(e.length=0)}t.ActionSetWithChildren=y,t.unsubscribeActions=b},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPackageName=t.getVersion=t.getMergedProps=t.updateActionFromPayload=t.isValidOptionalString=t.isValidOptionalNumber=t.NonSnakeCaseGroup=t.getEventNameSpace=t.forEachInEnum=t.findMatchInEnum=t.actionWrapper=void 0;var r=n(0);Object.defineProperty(t,"actionWrapper",{enumerable:!0,get:function(){return r.actionWrapper}}),Object.defineProperty(t,"findMatchInEnum",{enumerable:!0,get:function(){return r.findMatchInEnum}}),Object.defineProperty(t,"forEachInEnum",{enumerable:!0,get:function(){return r.forEachInEnum}}),Object.defineProperty(t,"getEventNameSpace",{enumerable:!0,get:function(){return r.getEventNameSpace}}),Object.defineProperty(t,"NonSnakeCaseGroup",{enumerable:!0,get:function(){return r.NonSnakeCaseGroup}}),Object.defineProperty(t,"isValidOptionalNumber",{enumerable:!0,get:function(){return r.isValidOptionalNumber}}),Object.defineProperty(t,"isValidOptionalString",{enumerable:!0,get:function(){return r.isValidOptionalString}}),Object.defineProperty(t,"updateActionFromPayload",{enumerable:!0,get:function(){return r.updateActionFromPayload}}),Object.defineProperty(t,"getMergedProps",{enumerable:!0,get:function(){return r.getMergedProps}});var o=n(55);t.getVersion=function(){return o.version},t.getPackageName=function(){return o.name}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ActionSetPayload=t.ComplexDispatch=t.DispatchAction=t.ClickAction=t.ComponentType=t.ActionSetProps=t.ActionSetOptions=t.Dispatch=t.ErrorCallback=t.UpdateSubscribe=t.ActionSubscription=t.ErrorSubscriber=t.UpdateSubscription=t.ActionSetInterface=t.Component=t.Group=t.ClientInterface=t.SimpleDispatch=t.Unsubscribe=t.MetaAction=t.AnyAction=t.ActionCallback=void 0;var r=n(1);Object.defineProperty(t,"ActionCallback",{enumerable:!0,get:function(){return r.ActionCallback}}),Object.defineProperty(t,"AnyAction",{enumerable:!0,get:function(){return r.AnyAction}}),Object.defineProperty(t,"MetaAction",{enumerable:!0,get:function(){return r.MetaAction}}),Object.defineProperty(t,"Unsubscribe",{enumerable:!0,get:function(){return r.Unsubscribe}}),Object.defineProperty(t,"SimpleDispatch",{enumerable:!0,get:function(){return r.SimpleDispatch}}),Object.defineProperty(t,"ClientInterface",{enumerable:!0,get:function(){return r.ClientInterface}}),Object.defineProperty(t,"Group",{enumerable:!0,get:function(){return r.Group}}),Object.defineProperty(t,"Component",{enumerable:!0,get:function(){return r.Component}}),Object.defineProperty(t,"ActionSetInterface",{enumerable:!0,get:function(){return r.ActionSetInterface}}),Object.defineProperty(t,"UpdateSubscription",{enumerable:!0,get:function(){return r.UpdateSubscription}}),Object.defineProperty(t,"ErrorSubscriber",{enumerable:!0,get:function(){return r.ErrorSubscriber}}),Object.defineProperty(t,"ActionSubscription",{enumerable:!0,get:function(){return r.ActionSubscription}}),Object.defineProperty(t,"UpdateSubscribe",{enumerable:!0,get:function(){return r.UpdateSubscribe}}),Object.defineProperty(t,"ErrorCallback",{enumerable:!0,get:function(){return r.ErrorCallback}}),Object.defineProperty(t,"Dispatch",{enumerable:!0,get:function(){return r.Dispatch}}),Object.defineProperty(t,"ActionSetOptions",{enumerable:!0,get:function(){return r.ActionSetOptions}}),Object.defineProperty(t,"ActionSetProps",{enumerable:!0,get:function(){return r.ActionSetProps}}),Object.defineProperty(t,"ComponentType",{enumerable:!0,get:function(){return r.ComponentType}}),Object.defineProperty(t,"ClickAction",{enumerable:!0,get:function(){return r.ClickAction}}),Object.defineProperty(t,"DispatchAction",{enumerable:!0,get:function(){return r.DispatchAction}}),Object.defineProperty(t,"ComplexDispatch",{enumerable:!0,get:function(){return r.ComplexDispatch}}),Object.defineProperty(t,"ActionSetPayload",{enumerable:!0,get:function(){return r.ActionSetPayload}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.permissionAction=t.isErrorEventName=t.throwError=t.invalidOriginAction=t.fromAction=t.AppBridgeError=t.AppActionType=t.Action=void 0;var r,o=n(1),i=n(0);!function(e){e.INVALID_ACTION="APP::ERROR::INVALID_ACTION",e.INVALID_ACTION_TYPE="APP::ERROR::INVALID_ACTION_TYPE",e.INVALID_PAYLOAD="APP::ERROR::INVALID_PAYLOAD",e.INVALID_OPTIONS="APP::ERROR::INVALID_OPTIONS",e.UNEXPECTED_ACTION="APP::ERROR::UNEXPECTED_ACTION",e.PERSISTENCE="APP::ERROR::PERSISTENCE",e.UNSUPPORTED_OPERATION="APP::ERROR::UNSUPPORTED_OPERATION",e.NETWORK="APP::ERROR::NETWORK",e.PERMISSION="APP::ERROR::PERMISSION",e.FAILED_AUTHENTICATION="APP::ERROR::FAILED_AUTHENTICATION",e.INVALID_ORIGIN="APP::ERROR::INVALID_ORIGIN"}(r=t.Action||(t.Action={})),function(e){e.INVALID_CONFIG="APP::ERROR::INVALID_CONFIG",e.MISSING_CONFIG="APP::APP_ERROR::MISSING_CONFIG",e.MISSING_APP_BRIDGE_MIDDLEWARE="APP::APP_ERROR::MISSING_APP_BRIDGE_MIDDLEWARE",e.WINDOW_UNDEFINED="APP::APP_ERROR::WINDOW_UNDEFINED",e.REDUX_REINSTANTIATED="APP::APP_ERROR::REDUX_REINSTANTIATED",e.MISSING_LOCAL_ORIGIN="APP::APP_ERROR::MISSING_LOCAL_ORIGIN",e.MISSING_HOST_PROVIDER="APP::APP_ERROR::MISSING_HOST_PROVIDER",e.MISSING_ROUTER_CONTEXT="APP::APP_ERROR::MISSING_ROUTER_CONTEXT",e.MISSING_HISTORY_BLOCK="APP::APP_ERROR::MISSING_HISTORY_BLOCK"}(t.AppActionType||(t.AppActionType={}));var a=function(e){this.name="AppBridgeError",this.message=e,"function"==typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error(this.message).stack};function u(e,t,n){var r=new a(e?t+": "+e:t);return r.action=n,r.type=t,r}t.AppBridgeError=a,a.prototype=Object.create(Error.prototype),t.fromAction=u,t.invalidOriginAction=function(e){return i.actionWrapper({group:o.Group.Error,payload:{message:e,type:r.INVALID_ORIGIN},type:r.INVALID_ORIGIN})},t.throwError=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n,r,o=e[0];throw"string"==typeof e[1]?n=e[1]:(r=e[1],n=e[2]||""),u(n,o,r)},t.isErrorEventName=function(e){return"string"==typeof i.findMatchInEnum(r,e)},t.permissionAction=function(e,t){return function(e,t,n){var r=t.payload;return i.actionWrapper({type:e,group:o.Group.Error,payload:{action:t,message:n,type:e,id:r&&r.id?r.id:void 0}})}(r.PERMISSION,e,t||"Action is not permitted")}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LifecycleHook=t.PermissionType=t.MessageType=void 0,function(e){e.GetState="getState",e.Dispatch="dispatch",e.Subscribe="subscribe",e.Unsubscribe="unsubscribe"}(t.MessageType||(t.MessageType={})),function(e){e.Dispatch="Dispatch",e.Subscribe="Subscribe"}(t.PermissionType||(t.PermissionType={})),function(e){e.UpdateAction="UpdateAction",e.DispatchAction="DispatchAction"}(t.LifecycleHook||(t.LifecycleHook={}))},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Button=t.update=t.clickButton=t.Style=t.Icon=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e,t,n){var r=t.id,o=u.getEventNameSpace(e,a.CLICK,t),i={id:r,payload:n};return u.actionWrapper({type:o,group:e,payload:i})}function f(e,t,n){var r=t.id,o=n.label,c=u.getEventNameSpace(e,a.UPDATE,t),s=i(i({},n),{id:r,label:o});return u.actionWrapper({type:c,group:e,payload:s})}!function(e){e.CLICK="CLICK",e.UPDATE="UPDATE"}(a=t.Action||(t.Action={})),function(e){e.Print="print"}(t.Icon||(t.Icon={})),function(e){e.Danger="danger"}(t.Style||(t.Style={})),t.clickButton=p,t.update=f;var l=function(e){function t(t,n){var r=e.call(this,t,s.ComponentType.Button,s.Group.Button)||this;return r.disabled=!1,r.loading=!1,r.plain=!1,r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return{disabled:this.disabled,icon:this.icon,label:this.label,style:this.style,loading:this.loading,plain:this.plain}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=u.getMergedProps(this.options,e),r=n.label,o=n.disabled,i=n.icon,c=n.style,s=n.loading,p=n.plain;return this.label=r,this.disabled=Boolean(o),this.icon=i,this.style=c,this.loading=Boolean(s),this.plain=Boolean(p),t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e,t){switch(e){case a.CLICK:this.app.dispatch(p(this.group,this.component,t));break;case a.UPDATE:var n=f(this.group,this.component,this.payload);this.app.dispatch(n)}return this},t}(c.ActionSet);t.Button=l},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(22);o(n(29),t),o(n(22),t),t.default=i.createClientApp},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.networkAction=t.persistenceAction=t.unsupportedOperationAction=t.unexpectedAction=t.invalidAction=t.invalidActionType=t.invalidPayload=t.Message=t.ErrorAction=t.fromAction=t.Action=t.permissionAction=t.isErrorEventName=t.throwError=t.invalidOriginAction=t.AppBridgeError=t.AppActionType=void 0;var r=n(5);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"fromAction",{enumerable:!0,get:function(){return r.fromAction}}),Object.defineProperty(t,"ErrorAction",{enumerable:!0,get:function(){return r.ErrorAction}});var o=n(3),i=n(4),a=n(5);function u(e,t,n){var r=t.payload;return o.actionWrapper({type:e,group:i.Group.Error,payload:{action:t,message:n,type:e,id:r&&r.id?r.id:void 0}})}Object.defineProperty(t,"AppActionType",{enumerable:!0,get:function(){return a.AppActionType}}),Object.defineProperty(t,"AppBridgeError",{enumerable:!0,get:function(){return a.AppBridgeError}}),Object.defineProperty(t,"invalidOriginAction",{enumerable:!0,get:function(){return a.invalidOriginAction}}),Object.defineProperty(t,"throwError",{enumerable:!0,get:function(){return a.throwError}}),Object.defineProperty(t,"isErrorEventName",{enumerable:!0,get:function(){return a.isErrorEventName}}),Object.defineProperty(t,"permissionAction",{enumerable:!0,get:function(){return a.permissionAction}}),function(e){e.MISSING_PAYLOAD="Missing payload",e.INVALID_PAYLOAD_ID="Id in payload is missing or invalid"}(t.Message||(t.Message={})),t.invalidPayload=function(e,t){return u(r.Action.INVALID_PAYLOAD,e,t||"The action's payload is missing required properties or has invalid properties")},t.invalidActionType=function(e,t){return o.actionWrapper({group:i.Group.Error,payload:{action:e,message:t||"The action type is invalid or unsupported",type:r.Action.INVALID_ACTION_TYPE},type:r.Action.INVALID_ACTION_TYPE})},t.invalidAction=function(e,t){return o.actionWrapper({group:i.Group.Error,payload:{action:e,message:t||"The action's has missing/invalid values for `group`, `type` or `version`",type:r.Action.INVALID_ACTION},type:r.Action.INVALID_ACTION})},t.unexpectedAction=function(e,t){return o.actionWrapper({group:i.Group.Error,payload:{action:e,message:t||"Action cannot be called at this time",type:r.Action.UNEXPECTED_ACTION},type:r.Action.UNEXPECTED_ACTION})},t.unsupportedOperationAction=function(e,t){return u(r.Action.UNSUPPORTED_OPERATION,e,t||"The action type is unsupported")},t.persistenceAction=function(e,t){return u(r.Action.PERSISTENCE,e,t||"Action cannot be persisted on server")},t.networkAction=function(e,t){return u(r.Action.NETWORK,e,t||"Network error")}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.ButtonGroup=t.isGroupedButtonPayload=t.isGroupedButton=t.update=t.Action=void 0;var a,u=n(11),c=n(0),s=n(2),p=n(1);function f(e,t,n){return function(e,t,n,r,o){var a=t.id,u=r.label,s=c.getEventNameSpace(e,n,t),p=i(i({},r),{id:a,label:u,payload:o});return c.actionWrapper({type:s,group:e,payload:p})}(e,t,a.UPDATE,n)}!function(e){e.UPDATE="UPDATE"}(a=t.Action||(t.Action={})),t.update=f,t.isGroupedButton=function(e){var t=e;return t.buttons&&t.buttons.length>0&&void 0!==t.label},t.isGroupedButtonPayload=function(e){var t=e;return Array.isArray(t.buttons)&&"string"==typeof t.id&&"string"==typeof t.label};var l=function(e){function t(t,n){var r=e.call(this,t,p.ComponentType.ButtonGroup,p.Group.ButtonGroup)||this;return r.disabled=!1,r.plain=!1,r.buttonsOptions=[],r.buttons=[],r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return{buttons:this.buttonsOptions,disabled:this.disabled,label:this.label,plain:this.plain}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{buttons:this.buttons,id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=c.getMergedProps(this.options,e),r=n.label,o=n.disabled,i=n.buttons,u=n.plain;return this.label=r,this.disabled=Boolean(o),this.buttons=this.getButtons(i),this.plain=Boolean(u),t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.UPDATE:var t=f(this.group,this.component,this.payload);this.app.dispatch(t)}return this},t.prototype.updateButtons=function(e){if(this.buttons&&0!==this.buttons.length){for(var t,n=0,r=this.buttons;n<r.length;n++){var o=r[n];if(t=c.updateActionFromPayload(o,e))break}t&&this.dispatch(a.UPDATE)}},t.prototype.getSingleButton=function(e){return u.getSingleButton(this,e,this.subgroups,this.updateButtons)},t.prototype.getButtons=function(e){var t=this,n=[];return e?(e.forEach((function(e){var r=u.getSingleButton(t,e,t.subgroups,t.updateButtons);n.push(r)})),this.buttonsOptions=e,n):[]},t}(s.ActionSetWithChildren);t.ButtonGroup=l,t.create=function(e,t){return new l(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSingleButton=void 0;var r=n(7);t.getSingleButton=function(e,t,n,o){return e.addChild(t,e.group,n),e.subscribeToChild(t,r.Action.UPDATE,o),t.payload}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.AppLink=t.update=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1),p=n(21);function f(e,t,n){var r=t.id,o=n.label,c=n.destination,s=i(i({},n),{id:r,label:o,destination:c});return u.actionWrapper({group:e,type:u.getEventNameSpace(e,a.UPDATE,t),payload:s})}!function(e){e.UPDATE="UPDATE"}(a=t.Action||(t.Action={})),t.update=f;var l=function(e){function t(t,n){var r=e.call(this,t,s.Group.Link,s.Group.Link)||this;return r.label="",r.destination="",r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return{label:this.label,destination:this.destination,redirectType:p.Action.APP}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){var e=this.options,t=e.label,n=e.destination,r=e.redirectType,o=n;return{id:this.id,label:t,destination:{path:o},redirectType:r}},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=u.getMergedProps(this.options,e),r=n.label,o=n.destination;return this.label=r,this.destination=o,t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.UPDATE:var t=f(this.group,this.component,this.payload);this.app.dispatch(t)}return this},t}(c.ActionSet);t.AppLink=l},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(57),t)},function(e,t,n){"use strict";function r(e,t,n){var r=e.findIndex((function(e){return e===t}));return r>=0&&(e.splice(r,1),n&&n(t),!0)}Object.defineProperty(t,"__esModule",{value:!0}),t.removeFromCollection=t.addAndRemoveFromCollection=void 0,t.addAndRemoveFromCollection=function(e,t,n){return e.push(t),function(){return r(e,t,n)}},t.removeFromCollection=r},function(e,t,n){"use strict";var r,o;Object.defineProperty(t,"__esModule",{value:!0}),t.isUnframed=t.isClient=t.isServer=void 0,t.isServer="undefined"==typeof window,t.isClient=!t.isServer,t.isUnframed=t.isClient&&(null===(o=null===(r=window.navigator)||void 0===r?void 0:r.userAgent)||void 0===o?void 0:o.indexOf("Unframed"))>0},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.isDevelopmentClient=t.isProduction=t.isDevelopment=t.isUnframed=t.isServer=t.isClient=void 0;var r=n(15),o=n(15);Object.defineProperty(t,"isClient",{enumerable:!0,get:function(){return o.isClient}}),Object.defineProperty(t,"isServer",{enumerable:!0,get:function(){return o.isServer}}),Object.defineProperty(t,"isUnframed",{enumerable:!0,get:function(){return o.isUnframed}}),t.isDevelopment=void 0!==e&&e.env&&!1,t.isProduction=!t.isDevelopment,t.isDevelopmentClient=t.isDevelopment&&r.isClient}).call(this,n(59))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isShopifyPing=t.isShopifyPOS=t.isShopifyMobile=t.isShopifyEmbedded=t.isMobile=void 0;var r=n(16);function o(){return"undefined"!=typeof navigator&&navigator.userAgent.indexOf("Shopify Mobile")>=0}function i(){return"undefined"!=typeof navigator&&navigator.userAgent.indexOf("Shopify POS")>=0}function a(){return"undefined"!=typeof navigator&&navigator.userAgent.indexOf("Shopify Ping")>=0}t.isMobile=function(){return o()||i()||a()},t.isShopifyEmbedded=function(){return r.isClient&&window.top!==window.self||r.isUnframed},t.isShopifyMobile=o,t.isShopifyPOS=i,t.isShopifyPing=a},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Toast=t.primaryAction=t.clear=t.show=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return u.actionWrapper({group:s.Group.Toast,payload:e,type:a.SHOW})}function f(e){return u.actionWrapper({payload:e,group:s.Group.Toast,type:a.CLEAR})}function l(e){return u.actionWrapper({payload:e,group:s.Group.Toast,type:a.ACTION})}!function(e){e.SHOW="APP::TOAST::SHOW",e.CLEAR="APP::TOAST::CLEAR",e.ACTION="APP::TOAST::ACTION"}(a=t.Action||(t.Action={})),t.show=p,t.clear=f,t.primaryAction=l;var d=function(e){function t(t,n){var r=e.call(this,t,s.Group.Toast,s.Group.Toast)||this;return r.message="",r.duration=5e3,r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){var e;return{duration:this.duration,isError:this.isError,message:this.message,action:(null===(e=this.action)||void 0===e?void 0:e.content)?{content:this.action.content}:void 0}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),t.prototype.set=function(e){var t=u.getMergedProps(this.options,e),n=t.message,r=t.duration,o=t.isError,i=t.action;return this.message=n,this.duration=r,this.isError=o,this.action=(null==i?void 0:i.content)?{content:i.content||""}:void 0,this},t.prototype.dispatch=function(e){switch(e){case a.SHOW:var t=p(this.payload);this.app.dispatch(t);break;case a.CLEAR:this.app.dispatch(f({id:this.id}));break;case a.ACTION:this.app.dispatch(l({id:this.id}))}return this},t}(c.ActionSet);t.Toast=d},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(75),t),o(n(35),t)},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.ModalIframe=t.ModalMessage=t.Modal=t.isMessageModal=t.isIframeModal=t.data=t.update=t.clickFooterButton=t.updateModalSize=t.closeModal=t.openModal=t.Size=t.Action=void 0;var a,u,c=n(11),s=n(0),p=n(2),f=n(1),l=n(7);!function(e){e.OPEN="APP::MODAL::OPEN",e.CLOSE="APP::MODAL::CLOSE",e.UPDATE="APP::MODAL::UPDATE",e.UPDATE_CONTENT="APP::MODAL::CONTENT::UPDATE",e.FOOTER_BUTTON_CLICK="APP::MODAL::FOOTER::BUTTON::CLICK",e.FOOTER_BUTTON_UPDATE="APP::MODAL::FOOTER::BUTTON::UPDATE",e.UPDATE_SIZE="APP::MODAL::UPDATE_SIZE",e.DATA="APP::MODAL::DATA"}(a=t.Action||(t.Action={})),function(e){e.Small="small",e.Medium="medium",e.Large="large",e.Full="full",e.Auto="auto"}(u=t.Size||(t.Size={}));var d={group:f.Group.Modal,subgroups:["Footer"],type:f.ComponentType.Button};function h(e){return s.actionWrapper({group:f.Group.Modal,payload:e,type:a.OPEN})}function y(e){return s.actionWrapper({group:f.Group.Modal,payload:e,type:a.CLOSE})}function b(e){return s.actionWrapper({payload:e,group:f.Group.Modal,type:a.UPDATE})}function P(e){return s.actionWrapper({payload:e,group:f.Group.Modal,type:a.DATA})}t.openModal=h,t.closeModal=y,t.updateModalSize=function(e){return s.actionWrapper({group:f.Group.Modal,payload:e,type:a.UPDATE_SIZE})},t.clickFooterButton=function(e,t){var n=i({id:e},d);return l.clickButton(f.Group.Modal,n,t)},t.update=b,t.data=P,t.isIframeModal=function(e){return"string"==typeof e.url||"string"==typeof e.path},t.isMessageModal=function(e){return"string"==typeof e.message};var A=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.size=u.Small,t}return o(t,e),Object.defineProperty(t.prototype,"footer",{get:function(){if(this.footerPrimary||this.footerSecondary)return{buttons:{primary:this.footerPrimary,secondary:this.footerSecondary}}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"footerOptions",{get:function(){if(this.footerPrimaryOptions||this.footerSecondaryOptions)return{buttons:{primary:this.footerPrimaryOptions,secondary:this.footerSecondaryOptions}}},enumerable:!1,configurable:!0}),t.prototype.close=function(){this.app.dispatch(y({id:this.id}))},t.prototype.setFooterPrimaryButton=function(e,t){var n=this,r=d.subgroups;this.footerPrimaryOptions=this.getChildButton(e,this.footerPrimaryOptions),this.footerPrimary=this.footerPrimaryOptions?c.getSingleButton(this,this.footerPrimaryOptions,r,(function(e){n.updatePrimaryFooterButton(e,t)})):void 0},t.prototype.setFooterSecondaryButtons=function(e,t){var n=this,r=d.subgroups,o=e||[],i=this.footerOptions&&this.footerOptions.buttons.secondary||[];this.footerSecondaryOptions=this.getUpdatedChildActions(o,i),this.footerSecondary=this.footerSecondaryOptions?this.footerSecondaryOptions.map((function(e){return c.getSingleButton(n,e,r,(function(e){n.updateSecondaryFooterButton(e,t)}))})):void 0},t.prototype.getChildButton=function(e,t){var n=e?[e]:[],r=t?[t]:[],o=this.getUpdatedChildActions(n,r);return o?o[0]:void 0},t.prototype.updatePrimaryFooterButton=function(e,t){this.footer&&this.footer.buttons.primary&&s.updateActionFromPayload(this.footer.buttons.primary,e)&&t()},t.prototype.updateSecondaryFooterButton=function(e,t){if(this.footer&&this.footer.buttons&&this.footer.buttons.secondary){for(var n,r=0,o=this.footer.buttons.secondary;r<o.length;r++){var i=o[r];if(n=s.updateActionFromPayload(i,e))break}n&&t()}},t}(p.ActionSetWithChildren);t.Modal=A;var g=function(e){function t(t,n){var r=e.call(this,t,f.Group.Modal,f.Group.Modal)||this;return r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{footer:this.footer,id:this.id})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){return{footer:this.footerOptions,message:this.message,size:this.size,title:this.title}},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){var n=this;void 0===t&&(t=!0);var r=s.getMergedProps(this.options,e),o=r.title,i=r.footer,u=r.message,c=r.size;return this.title=o,this.message=u,this.size=c,this.setFooterPrimaryButton(i?i.buttons.primary:void 0,(function(){n.dispatch(a.UPDATE)})),this.setFooterSecondaryButtons(i?i.buttons.secondary:void 0,(function(){n.dispatch(a.UPDATE)})),t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.OPEN:this.app.dispatch(h(this.payload));break;case a.CLOSE:this.close();break;case a.UPDATE:this.app.dispatch(b(this.payload))}return this},t}(A);t.ModalMessage=g;var O=function(e){function t(t,n){var r=e.call(this,t,f.Group.Modal,f.Group.Modal)||this;return r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{footer:this.footer,id:this.id})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){return{footer:this.footerOptions,path:this.path,size:this.size,title:this.title,url:this.url,loading:this.loading}},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){var n=this;void 0===t&&(t=!0);var r=s.getMergedProps(this.options,e),o=r.title,i=r.footer,u=r.path,c=r.url,p=r.size,f=r.loading;return this.title=o,this.url=c,this.path=u,this.size=p,this.loading=f,this.setFooterPrimaryButton(i?i.buttons.primary:void 0,(function(){n.dispatch(a.UPDATE)})),this.setFooterSecondaryButtons(i?i.buttons.secondary:void 0,(function(){n.dispatch(a.UPDATE)})),t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e,t){switch(e){case a.OPEN:this.app.dispatch(h(this.payload));break;case a.CLOSE:this.close();break;case a.UPDATE:this.app.dispatch(b(this.payload));break;case a.DATA:this.app.dispatch(P(t||{}))}return this},t}(A);t.ModalIframe=O},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Redirect=t.isProductVariantResourcePayload=t.isCreateResourcePayload=t.isAdminSection=t.isRemotePayload=t.isAdminSectionPayload=t.isAdminPathPayload=t.isAppPayload=t.getRelativePath=t.normalizeUrl=t.getPathWithSearchAndHash=t.toDestination=t.toApp=t.toRemote=t.toAdminSection=t.toAdminPath=t.isResourcePayload=t.ResourceType=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.ADMIN_PATH})}function f(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.ADMIN_SECTION})}function l(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.REMOTE})}function d(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.APP})}function h(e,t,n){switch(e){case a.APP:var r=P(t)?t:{path:t};return d(i({id:n},r));case a.ADMIN_PATH:var o=A(t)?t:{path:t};return p(i({id:n},o));case a.ADMIN_SECTION:var u=g(t)?t:{section:t};return f(i({id:n},u));case a.REMOTE:var c=O(t)?t:{url:t};return l(i({id:n},c))}}function y(e){return""+e.pathname+(e.search||"")+(e.hash||"")}function b(e){if("string"==typeof e)return e.startsWith("/")?e:y(new URL(e));var t=e.search instanceof URLSearchParams?e.search.toString():e.search;return y(i(i({},e),{search:t}))}function P(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"path")}function A(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"path")}function g(e){return"object"==typeof e&&"object"==typeof e.section&&Object.prototype.hasOwnProperty.call(e.section,"name")}function O(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"url")}!function(e){e.ADMIN_SECTION="APP::NAVIGATION::REDIRECT::ADMIN::SECTION",e.ADMIN_PATH="APP::NAVIGATION::REDIRECT::ADMIN::PATH",e.REMOTE="APP::NAVIGATION::REDIRECT::REMOTE",e.APP="APP::NAVIGATION::REDIRECT::APP"}(a=t.Action||(t.Action={})),function(e){e.Product="products",e.Collection="collections",e.Order="orders",e.Customer="customers",e.Discount="discounts"}(t.ResourceType||(t.ResourceType={})),t.isResourcePayload=function(e){return"string"==typeof e.id},t.toAdminPath=p,t.toAdminSection=f,t.toRemote=l,t.toApp=d,t.toDestination=h,t.getPathWithSearchAndHash=y,t.normalizeUrl=function(e){return e instanceof URL?e.toString():"string"==typeof e?e:b(e)},t.getRelativePath=b,t.isAppPayload=P,t.isAdminPathPayload=A,t.isAdminSectionPayload=g,t.isRemotePayload=O,t.isAdminSection=function(e){return"object"==typeof e&&"string"==typeof(null==e?void 0:e.name)},t.isCreateResourcePayload=function(e){return!0===e.create},t.isProductVariantResourcePayload=function(e){var t=e;return void 0!==t.id&&void 0!==t.variant};var m=function(e){function t(t){return e.call(this,t,"Redirect",s.Group.Navigation)||this}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),t.prototype.dispatch=function(e,t){var n=h(e,t,this.payload.id);return this.app.dispatch(n),this},t}(c.ActionSet);t.Redirect=m},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.createApp=t.createAppWrapper=t.createClientApp=t.WINDOW_UNDEFINED_MESSAGE=void 0;var a=n(3),u=n(24),c=n(9),s=n(13),p=n(58),f=n(16),l=n(26),d=n(27),h=n(64),y=n(28),b=n(29),P=i(n(65));t.WINDOW_UNDEFINED_MESSAGE="window is not defined. Running an app outside a browser is not supported";var A=function(e){return function(t){return e(r(r({},t),{version:a.getVersion(),clientInterface:{name:a.getPackageName(),version:a.getVersion()}}))}},g=function(e){e.set(b.LifecycleHook.DispatchAction,A)};function O(e,n,r){if(void 0===r&&(r=[]),!e)throw c.fromAction(t.WINDOW_UNDEFINED_MESSAGE,c.AppActionType.WINDOW_UNDEFINED);var i=y.getLocation(),a=n||i&&i.origin;if(!a)throw c.fromAction("local origin cannot be blank",c.AppActionType.MISSING_LOCAL_ORIGIN);var u=s.fromWindow(e,a);return t.createClientApp(u,o([g],r))}function m(e){var t=y.getWindow();return t&&t.top?O(t.top)(e):p.serverAppBridge}t.createClientApp=function(e,t){void 0===t&&(t=[]);var n=[],i=s.createTransportListener();return e.subscribe((function(e){var t=e.data,r=t.type,o=t.payload;switch(r){case"getState":n.splice(0).forEach((function(e){return e(o)}));break;case"dispatch":if(i.handleMessage(o),i.handleActionDispatch(o))return;var u=a.findMatchInEnum(c.Action,o.type);u&&c.throwError(u,o)}})),function(s){var A=function(e){var t;if(!e.host)throw c.fromAction("host must be provided",c.AppActionType.INVALID_CONFIG);if(!e.apiKey)throw c.fromAction("apiKey must be provided",c.AppActionType.INVALID_CONFIG);try{var n=atob(null===(t=e.host)||void 0===t?void 0:t.replace(/_/g,"/").replace(/-/g,"+"));return r(r({},e),{host:n})}catch(e){throw c.fromAction("not a valid host, please use the value provided by Shopify",c.AppActionType.INVALID_CONFIG)}}(s);if(function(e,t){var n=t.apiKey,r=t.host,o=t.forceRedirect,i=void 0===o?!f.isDevelopmentClient:o,a=y.getLocation();if(f.isUnframed||!a||!n||!r||!i||!y.shouldRedirect(e))return!1;var u="https://"+r+"/apps/"+n+a.pathname+(a.search||"");return y.redirect(u),!0}(e.hostFrame,A))return p.mockAppBridge;var g=function(e,t){return function(n,r){e.dispatch({payload:r,source:t,type:n})}}(e,A),O=i.createSubscribeHandler(g);function m(e){return g(b.MessageType.Dispatch,e),e}g(b.MessageType.Unsubscribe);for(var v=new URL("https://"+A.host).origin,_=new P.default,E={hostOrigin:v,localOrigin:e.localOrigin,hooks:_,dispatch:function(e){return E.hooks?E.hooks.run(b.LifecycleHook.DispatchAction,m,E,e):m(e)},featuresAvailable:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e[0],r=Array.isArray(n)?o([],n):e;return E.getState("features").then((function(e){return r.length?r.reduce((function(t,n){return Object.keys(e).includes(n)&&(t[n]=e[n]),t}),{}):e}))},getState:function(e){return e&&"string"!=typeof e?Promise.resolve(void 0):new Promise((function(e){n.push(e),g(b.MessageType.GetState)})).then((function(t){var n=t;if(e)for(var r=0,o=e.split(".");r<o.length;r++){var i=o[r];if(null==n||"object"!=typeof n||Array.isArray(n)||!Object.keys(n).includes(i))return;n=n[i]}return n}))},subscribe:O,error:function(e,t){var n=[];return a.forEachInEnum(c.Action,(function(r){n.push(O(r,e,t))})),function(){n.forEach((function(e){return e()}))}}},T=0,S=t;T<S.length;T++){(0,S[T])(_,E)}return function(e){e.subscribe(u.Action.APP,h.handleAppPrint),e.dispatch(l.initialize());try{d.initializeWebVitals(e)}catch(e){console.error("App-Bridge failed to initialize web-vitals",e)}}(E),E}},t.createAppWrapper=O,t.createApp=m,t.default=m},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SEPARATOR=t.PREFIX=void 0,t.PREFIX="APP",t.SEPARATOR="::"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.app=t.PrintAction=t.Action=void 0;var r=n(56);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"PrintAction",{enumerable:!0,get:function(){return r.PrintAction}}),Object.defineProperty(t,"app",{enumerable:!0,get:function(){return r.app}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isPermitted=t.getPermissionKey=t.isPerformanceOrWebVitalsAction=t.isAppMessage=t.isAppBridgeAction=void 0;var r=n(6),o=n(23),i=n(0);function a(e){return e.replace(new RegExp("^"+o.PREFIX+o.SEPARATOR+"\\w+"+o.SEPARATOR),"")}t.isAppBridgeAction=function(e){return e instanceof Object&&Object.prototype.hasOwnProperty.call(e,"type")&&e.type.toString().startsWith(o.PREFIX)},t.isAppMessage=function(e){if("object"!=typeof e||!e.data||"object"!=typeof e.data)return!1;var t=e.data;return Object.prototype.hasOwnProperty.call(t,"type")&&void 0!==i.findMatchInEnum(r.MessageType,t.type)},t.isPerformanceOrWebVitalsAction=function(e){return e.type.match(/^APP::(PERFORMANCE|WEB_VITALS)::/)},t.getPermissionKey=a,t.isPermitted=function(e,t,n){var r=t.group,o=t.type;if(!r||!Object.prototype.hasOwnProperty.call(e,r))return!1;var i=e[r];if(!i)return!1;var u=a(o);return!!i[u]&&!0===i[u][n]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initialize=t.Action=void 0;var r=n(60);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}});var o=n(4),i=n(3);t.initialize=function(){return i.actionWrapper({group:o.Group.Client,type:r.Action.INITIALIZE})}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(61),t)},function(e,t,n){"use strict";function r(){return o()?window.location:void 0}function o(){return"undefined"!=typeof window}Object.defineProperty(t,"__esModule",{value:!0}),t.getWindow=t.getLocation=t.redirect=t.shouldRedirect=void 0,t.shouldRedirect=function(e){return e===window},t.redirect=function(e){var t=r();t&&t.assign(e)},t.getLocation=r,t.getWindow=function(){return o()?window:void 0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isV1Config=t.ClientApplication=t.MessageType=t.AppConfigV2=t.FeaturesState=t.FeaturesAvailable=t.TransportSubscription=t.PathValue=t.Path=t.LifecycleHandler=t.DispatchActionHandler=t.DispatchActionHook=t.UpdateActionHandler=t.UpdateActionHook=t.LifecycleHook=t.HooksInterface=t.StateWithoutFeatures=t.PermissionType=t.FeaturePermission=t.FeaturesAction=t.StaffMemberDetails=t.AppBridgeState=t.TransportDispatch=t.Dispatcher=void 0;var r=n(6);Object.defineProperty(t,"AppConfigV2",{enumerable:!0,get:function(){return r.AppConfigV2}}),Object.defineProperty(t,"MessageType",{enumerable:!0,get:function(){return r.MessageType}}),Object.defineProperty(t,"ClientApplication",{enumerable:!0,get:function(){return r.ClientApplication}});var o=n(6);Object.defineProperty(t,"Dispatcher",{enumerable:!0,get:function(){return o.Dispatcher}}),Object.defineProperty(t,"TransportDispatch",{enumerable:!0,get:function(){return o.TransportDispatch}}),Object.defineProperty(t,"AppBridgeState",{enumerable:!0,get:function(){return o.AppBridgeState}}),Object.defineProperty(t,"StaffMemberDetails",{enumerable:!0,get:function(){return o.StaffMemberDetails}}),Object.defineProperty(t,"FeaturesAction",{enumerable:!0,get:function(){return o.FeaturesAction}}),Object.defineProperty(t,"FeaturePermission",{enumerable:!0,get:function(){return o.FeaturePermission}}),Object.defineProperty(t,"PermissionType",{enumerable:!0,get:function(){return o.PermissionType}}),Object.defineProperty(t,"StateWithoutFeatures",{enumerable:!0,get:function(){return o.StateWithoutFeatures}}),Object.defineProperty(t,"HooksInterface",{enumerable:!0,get:function(){return o.HooksInterface}}),Object.defineProperty(t,"LifecycleHook",{enumerable:!0,get:function(){return o.LifecycleHook}}),Object.defineProperty(t,"UpdateActionHook",{enumerable:!0,get:function(){return o.UpdateActionHook}}),Object.defineProperty(t,"UpdateActionHandler",{enumerable:!0,get:function(){return o.UpdateActionHandler}}),Object.defineProperty(t,"DispatchActionHook",{enumerable:!0,get:function(){return o.DispatchActionHook}}),Object.defineProperty(t,"DispatchActionHandler",{enumerable:!0,get:function(){return o.DispatchActionHandler}}),Object.defineProperty(t,"LifecycleHandler",{enumerable:!0,get:function(){return o.LifecycleHandler}}),Object.defineProperty(t,"Path",{enumerable:!0,get:function(){return o.Path}}),Object.defineProperty(t,"PathValue",{enumerable:!0,get:function(){return o.PathValue}}),Object.defineProperty(t,"TransportSubscription",{enumerable:!0,get:function(){return o.TransportSubscription}}),Object.defineProperty(t,"FeaturesAvailable",{enumerable:!0,get:function(){return o.FeaturesAvailable}}),Object.defineProperty(t,"FeaturesState",{enumerable:!0,get:function(){return o.FeaturesState}}),t.isV1Config=function(e){return!e.host}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t},a=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.WebVitals=t.unstable_Picker=t.Performance=t.Pos=t.AppLink=t.ChannelMenu=t.NavigationMenu=t.Share=t.ContextualSaveBar=t.MarketingExternalActivityTopBar=t.TitleBar=t.SessionToken=t.ResourcePicker=t.Redirect=t.Print=t.ModalContent=t.Modal=t.Loading=t.LeaveConfirmation=t.History=t.Toast=t.Fullscreen=t.FeedbackModal=t.Features=t.Flash=t.Error=t.Client=t.Cart=t.Scanner=t.ButtonGroup=t.Button=t.AuthCode=t.isAppBridgeAction=void 0;var u=i(n(31));t.AuthCode=u;var c=i(n(33));t.Button=c;var s=i(n(68));t.ButtonGroup=s;var p=i(n(69));t.Cart=p;var f=i(n(26));t.Client=f;var l=i(n(9));t.Error=l;var d=i(n(71));t.Flash=d;var h=i(n(73));t.Features=h;var y=i(n(77));t.FeedbackModal=y;var b=i(n(79));t.Fullscreen=b;var P=i(n(80));t.LeaveConfirmation=P;var A=i(n(81));t.Loading=A;var g=i(n(39));t.Modal=g;var O=i(n(82));t.ModalContent=O;var m=i(n(83));t.History=m;var v=i(n(84));t.Redirect=v;var _=i(n(24));t.Print=_;var E=i(n(85));t.ResourcePicker=E;var T=i(n(86));t.Scanner=T;var S=i(n(88));t.SessionToken=S;var j=i(n(89));t.TitleBar=j;var C=i(n(91));t.Toast=C;var R=i(n(92));t.ContextualSaveBar=R;var I=i(n(94));t.Share=I;var M=i(n(95));t.NavigationMenu=M;var w=i(n(96));t.ChannelMenu=w;var L=i(n(97));t.AppLink=L;var D=i(n(98));t.Pos=D;var N=i(n(99));t.MarketingExternalActivityTopBar=N;var B=i(n(103));t.Performance=B;var U=i(n(105));t.unstable_Picker=U;var k=i(n(27));t.WebVitals=k;var G=n(106);Object.defineProperty(t,"isAppBridgeAction",{enumerable:!0,get:function(){return G.isAppBridgeAction}}),a(n(4),t)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.request=t.RequestAuthCodeAction=t.Action=t.RespondWithAuthCodeAction=t.ActionBase=t.RequestPayload=t.ResponsePayload=t.FailedResponsePayload=t.ExchangeRequiredPayload=t.respond=void 0;var r=n(32);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"RequestAuthCodeAction",{enumerable:!0,get:function(){return r.RequestAuthCodeAction}});var o=n(3),i=n(4),a=n(32);Object.defineProperty(t,"respond",{enumerable:!0,get:function(){return a.respond}}),Object.defineProperty(t,"ExchangeRequiredPayload",{enumerable:!0,get:function(){return a.ExchangeRequiredPayload}}),Object.defineProperty(t,"FailedResponsePayload",{enumerable:!0,get:function(){return a.FailedResponsePayload}}),Object.defineProperty(t,"ResponsePayload",{enumerable:!0,get:function(){return a.ResponsePayload}}),Object.defineProperty(t,"RequestPayload",{enumerable:!0,get:function(){return a.RequestPayload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return a.ActionBase}}),Object.defineProperty(t,"RespondWithAuthCodeAction",{enumerable:!0,get:function(){return a.RespondWithAuthCodeAction}}),t.request=function(e){return o.actionWrapper({group:i.Group.AuthCode,type:r.Action.REQUEST,payload:{id:e}})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.respond=t.Action=void 0;var r,o=n(0),i=n(1);!function(e){e.REQUEST="APP::AUTH_CODE::REQUEST",e.RESPOND="APP::AUTH_CODE::RESPOND"}(r=t.Action||(t.Action={})),t.respond=function(e){return o.actionWrapper({payload:e,group:i.Group.AuthCode,type:r.RESPOND})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.isValidButtonProps=t.Payload=t.Options=t.Button=t.update=t.Style=t.Presentation=t.Icon=t.ClickPayload=t.clickButton=t.ButtonUpdateAction=t.ButtonAction=t.Action=void 0;var r=n(7);Object.defineProperty(t,"Button",{enumerable:!0,get:function(){return r.Button}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return r.Payload}});var o=n(7);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ButtonAction",{enumerable:!0,get:function(){return o.ButtonAction}}),Object.defineProperty(t,"ButtonUpdateAction",{enumerable:!0,get:function(){return o.ButtonUpdateAction}}),Object.defineProperty(t,"clickButton",{enumerable:!0,get:function(){return o.clickButton}}),Object.defineProperty(t,"ClickPayload",{enumerable:!0,get:function(){return o.ClickPayload}}),Object.defineProperty(t,"Icon",{enumerable:!0,get:function(){return o.Icon}}),Object.defineProperty(t,"Presentation",{enumerable:!0,get:function(){return o.Presentation}}),Object.defineProperty(t,"Style",{enumerable:!0,get:function(){return o.Style}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),t.isValidButtonProps=function(e){return"string"==typeof e.id&&"string"==typeof e.label},t.create=function(e,t){return new r.Button(e,t)}},function(e,t,n){"use strict";function r(e){return Array.from(e).map((function(e){return("00"+e.toString(16)).slice(-2)})).join("")}function o(e){if("function"==typeof Uint8Array&&"object"==typeof window&&window.crypto){var t=new Uint8Array(e),n=window.crypto.getRandomValues(t);if(n)return n}return Array.from(new Array(e),(function(){return 255*Math.random()|0}))}function i(){var e=o(1),t=o(2);return e[0]&=191,t[0]&=79,[r(o(4)),"-",r(o(2)),"-",r(t),"-",r(e),r(o(1)),"-",r(o(6))].join("")}Object.defineProperty(t,"__esModule",{value:!0}),t.generateUuid=void 0,t.generateUuid=i,t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Action=void 0,function(e){e.UPDATE="APP::FEATURES::UPDATE",e.REQUEST="APP::FEATURES::REQUEST",e.REQUEST_UPDATE="APP::FEATURES::REQUEST::UPDATE"}(t.Action||(t.Action={}))},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.Fullscreen=t.exit=t.enter=t.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(e){e.ENTER="APP::FULLSCREEN::ENTER",e.EXIT="APP::FULLSCREEN::EXIT"}(i=t.Action||(t.Action={})),t.enter=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.ENTER})},t.exit=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.EXIT})};var s=function(e){function t(t){return e.call(this,t,c.Group.Fullscreen,c.Group.Fullscreen)||this}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),t.prototype.dispatch=function(e){return this.app.dispatch(a.actionWrapper({group:this.group,type:e,payload:this.payload})),this},t}(u.ActionSet);t.Fullscreen=s},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.LeaveConfirmation=t.confirm=t.disable=t.enable=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return void 0===e&&(e={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:e,type:a.ENABLE})}function f(e){return void 0===e&&(e={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:e,type:a.DISABLE})}function l(e){return void 0===e&&(e={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:e,type:a.CONFIRM})}!function(e){e.ENABLE="APP::LEAVE_CONFIRMATION::ENABLE",e.DISABLE="APP::LEAVE_CONFIRMATION::DISABLE",e.CONFIRM="APP::LEAVE_CONFIRMATION::CONFIRM"}(a=t.Action||(t.Action={})),t.enable=p,t.disable=f,t.confirm=l;var d=function(e){function t(t,n){void 0===n&&(n={});var r=e.call(this,t,s.Group.LeaveConfirmation,s.Group.LeaveConfirmation)||this;return r.options=n,r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),t.prototype.set=function(e){return this.options=u.getMergedProps(this.options,e),this},t.prototype.dispatch=function(e){switch(e){case a.ENABLE:var t=p(this.payload);this.app.dispatch(t);break;case a.DISABLE:var n=f(this.payload);this.app.dispatch(n);break;case a.CONFIRM:var r=l(this.payload);this.app.dispatch(r)}return this},t}(c.ActionSet);t.LeaveConfirmation=d},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.Loading=t.stop=t.start=t.Action=void 0;var i,a=n(0),u=n(2),c=n(1);function s(e){return a.actionWrapper({payload:e,group:c.Group.Loading,type:i.START})}function p(e){return a.actionWrapper({payload:e,group:c.Group.Loading,type:i.STOP})}!function(e){e.START="APP::LOADING::START",e.STOP="APP::LOADING::STOP"}(i=t.Action||(t.Action={})),t.start=s,t.stop=p;var f=function(e){function t(t){return e.call(this,t,c.Group.Loading,c.Group.Loading)||this}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),t.prototype.dispatch=function(e){switch(e){case i.START:this.app.dispatch(s(this.payload));break;case i.STOP:this.app.dispatch(p(this.payload))}return this},t}(u.ActionSet);t.Loading=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Modal=t.isMessageModal=t.data=t.update=t.clickFooterButton=t.updateModalSize=t.closeModal=t.openModal=t.ModalAction=t.UpdateSizeAction=t.CloseAction=t.UpdateAction=t.OpenAction=t.ActionBase=t.ModalDataPayload=t.Footer=t.FooterOptions=t.ClosePayload=t.UpdateSizePayload=t.BasePayload=t.Size=t.Action=t.isIframeModal=t.IframePayload=t.MessagePayload=t.ModalMessage=t.ModalIframe=t.IframeOptions=t.MessageOptions=void 0;var r=n(20);Object.defineProperty(t,"MessageOptions",{enumerable:!0,get:function(){return r.MessageOptions}}),Object.defineProperty(t,"IframeOptions",{enumerable:!0,get:function(){return r.IframeOptions}}),Object.defineProperty(t,"ModalIframe",{enumerable:!0,get:function(){return r.ModalIframe}}),Object.defineProperty(t,"ModalMessage",{enumerable:!0,get:function(){return r.ModalMessage}}),Object.defineProperty(t,"MessagePayload",{enumerable:!0,get:function(){return r.MessagePayload}}),Object.defineProperty(t,"IframePayload",{enumerable:!0,get:function(){return r.IframePayload}}),Object.defineProperty(t,"isIframeModal",{enumerable:!0,get:function(){return r.isIframeModal}});var o=n(20);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Size",{enumerable:!0,get:function(){return o.Size}}),Object.defineProperty(t,"BasePayload",{enumerable:!0,get:function(){return o.BasePayload}}),Object.defineProperty(t,"UpdateSizePayload",{enumerable:!0,get:function(){return o.UpdateSizePayload}}),Object.defineProperty(t,"ClosePayload",{enumerable:!0,get:function(){return o.ClosePayload}}),Object.defineProperty(t,"FooterOptions",{enumerable:!0,get:function(){return o.FooterOptions}}),Object.defineProperty(t,"Footer",{enumerable:!0,get:function(){return o.Footer}}),Object.defineProperty(t,"ModalDataPayload",{enumerable:!0,get:function(){return o.ModalDataPayload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"OpenAction",{enumerable:!0,get:function(){return o.OpenAction}}),Object.defineProperty(t,"UpdateAction",{enumerable:!0,get:function(){return o.UpdateAction}}),Object.defineProperty(t,"CloseAction",{enumerable:!0,get:function(){return o.CloseAction}}),Object.defineProperty(t,"UpdateSizeAction",{enumerable:!0,get:function(){return o.UpdateSizeAction}}),Object.defineProperty(t,"ModalAction",{enumerable:!0,get:function(){return o.ModalAction}}),Object.defineProperty(t,"openModal",{enumerable:!0,get:function(){return o.openModal}}),Object.defineProperty(t,"closeModal",{enumerable:!0,get:function(){return o.closeModal}}),Object.defineProperty(t,"updateModalSize",{enumerable:!0,get:function(){return o.updateModalSize}}),Object.defineProperty(t,"clickFooterButton",{enumerable:!0,get:function(){return o.clickFooterButton}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),Object.defineProperty(t,"data",{enumerable:!0,get:function(){return o.data}}),Object.defineProperty(t,"isMessageModal",{enumerable:!0,get:function(){return o.isMessageModal}}),Object.defineProperty(t,"Modal",{enumerable:!0,get:function(){return o.Modal}});t.create=function(e,t){return r.isIframeModal(t)?new r.ModalIframe(e,t):new r.ModalMessage(e,t)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},u=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.ModalContent=t.Action=void 0;var c,s=n(0),p=n(2),f=n(1),l=n(20);!function(e){e.LOADING="LOADING",e.LOADED="LOADED"}(c=t.Action||(t.Action={}));var d=function(e){function t(t,n){return e.call(this,t,f.Group.Modal,f.Group.Modal,n?n.id:void 0)||this}return o(t,e),t.prototype.loaded=function(){this.dispatch(c.LOADED)},t.prototype.loading=function(){this.dispatch(c.LOADING)},t.prototype.dispatch=function(e){switch(e){case c.LOADED:this.dispatchModalAction(l.Action.UPDATE_CONTENT,{loading:!1});break;case c.LOADING:this.dispatchModalAction(l.Action.UPDATE_CONTENT,{loading:!0})}return this},t.prototype.dispatchModalAction=function(e,t){return a(this,void 0,void 0,(function(){var n;return u(this,(function(r){return n=s.actionWrapper({type:e,group:f.Group.Modal,payload:i({},t)}),this.app.dispatch(n),[2]}))}))},t}(p.ActionSet);t.ModalContent=d},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.History=t.replace=t.push=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.PUSH})}function f(e){return u.actionWrapper({payload:e,group:s.Group.Navigation,type:a.REPLACE})}!function(e){e.PUSH="APP::NAVIGATION::HISTORY::PUSH",e.REPLACE="APP::NAVIGATION::HISTORY::REPLACE"}(a=t.Action||(t.Action={})),t.push=p,t.replace=f;var l=function(e){function t(t){return e.call(this,t,"History",s.Group.Navigation)||this}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),t.prototype.dispatch=function(e,t){var n=i(i({},this.payload),{path:t});switch(e){case a.PUSH:this.app.dispatch(p(n));break;case a.REPLACE:this.app.dispatch(f(n))}return this},t}(c.ActionSet);t.History=l},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.ResourcePicker=t.update=t.close=t.cancel=t.open=t.select=t.ActionVerb=t.ResourceType=t.ProductStatus=t.ProductVariantInventoryManagement=t.ProductVariantInventoryPolicy=t.WeightUnit=t.FulfillmentServiceType=t.CollectionSortOrder=t.Action=void 0;var a,u,c,s=n(0),p=n(2),f=n(1);function l(e){return s.actionWrapper({payload:e,group:f.Group.ResourcePicker,type:a.SELECT})}function d(e){return s.actionWrapper({payload:e,group:f.Group.ResourcePicker,type:a.OPEN})}function h(e){return s.actionWrapper({payload:e,group:f.Group.ResourcePicker,type:a.CANCEL})}function y(e){return s.actionWrapper({payload:e,group:f.Group.ResourcePicker,type:a.UPDATE})}!function(e){e.OPEN="APP::RESOURCE_PICKER::OPEN",e.SELECT="APP::RESOURCE_PICKER::SELECT",e.CLOSE="APP::RESOURCE_PICKER::CLOSE",e.UPDATE="APP::RESOURCE_PICKER::UPDATE",e.CANCEL="APP::RESOURCE_PICKER::CANCEL"}(a=t.Action||(t.Action={})),function(e){e.Manual="MANUAL",e.BestSelling="BEST_SELLING",e.AlphaAsc="ALPHA_ASC",e.AlphaDesc="ALPHA_DESC",e.PriceDesc="PRICE_DESC",e.PriceAsc="PRICE_ASC",e.CreatedDesc="CREATED_DESC",e.Created="CREATED",e.MostRelevant="MOST_RELEVANT"}(t.CollectionSortOrder||(t.CollectionSortOrder={})),function(e){e.GiftCard="GIFT_CARD",e.Manual="MANUAL",e.ThirdParty="THIRD_PARTY"}(t.FulfillmentServiceType||(t.FulfillmentServiceType={})),function(e){e.Kilograms="KILOGRAMS",e.Grams="GRAMS",e.Pounds="POUNDS",e.Ounces="OUNCES"}(t.WeightUnit||(t.WeightUnit={})),function(e){e.Deny="DENY",e.Continue="CONTINUE"}(t.ProductVariantInventoryPolicy||(t.ProductVariantInventoryPolicy={})),function(e){e.Shopify="SHOPIFY",e.NotManaged="NOT_MANAGED",e.FulfillmentService="FULFILLMENT_SERVICE"}(t.ProductVariantInventoryManagement||(t.ProductVariantInventoryManagement={})),function(e){e.Active="ACTIVE",e.Archived="ARCHIVED",e.Draft="DRAFT"}(t.ProductStatus||(t.ProductStatus={})),function(e){e.Product="product",e.ProductVariant="variant",e.Collection="collection"}(u=t.ResourceType||(t.ResourceType={})),function(e){e.Add="add",e.Select="select"}(c=t.ActionVerb||(t.ActionVerb={})),t.select=l,t.open=d,t.cancel=h,t.close=function(e){return s.actionWrapper({payload:e,group:f.Group.ResourcePicker,type:a.CANCEL})},t.update=y;var b=function(e){function t(t,n,r){var o=e.call(this,t,f.Group.ResourcePicker,f.Group.ResourcePicker)||this;return o.initialSelectionIds=[],o.selection=[],o.resourceType=r,o.set(n,!1),o}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{id:this.id,resourceType:this.resourceType})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){var e={initialQuery:this.initialQuery,selectMultiple:this.selectMultiple,initialSelectionIds:this.initialSelectionIds,showHidden:this.showHidden,actionVerb:this.actionVerb};return this.resourceType===u.Product?i(i({},e),{showVariants:this.showVariants,showDraft:this.showDraft,showArchived:this.showArchived,showDraftBadge:this.showDraftBadge,showArchivedBadge:this.showArchivedBadge}):e},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=s.getMergedProps(this.options,e),r=n.initialQuery,o=n.initialSelectionIds,i=void 0===o?[]:o,a=n.showHidden,u=void 0===a||a,p=n.showVariants,f=void 0===p||p,l=n.showDraft,d=void 0===l||l,h=n.showArchived,y=void 0===h||h,b=n.showDraftBadge,P=void 0!==b&&b,A=n.showArchivedBadge,g=void 0!==A&&A,O=n.selectMultiple,m=void 0===O||O,v=n.actionVerb,_=void 0===v?c.Add:v;return this.initialQuery=r,this.initialSelectionIds=i,this.showHidden=u,this.showVariants=f,this.showDraft=d,this.showArchived=y,this.showDraftBadge=P,this.showArchivedBadge=g,this.selectMultiple=m,this.actionVerb=_,t&&this.update(),this},t.prototype.dispatch=function(e,t){return e===a.OPEN?this.open():e===a.UPDATE?this.update():e===a.CLOSE||e===a.CANCEL?this.cancel():e===a.SELECT&&(this.selection=t,this.app.dispatch(l({id:this.id,selection:this.selection}))),this},t.prototype.update=function(){this.app.dispatch(y(this.payload))},t.prototype.open=function(){this.app.dispatch(d(this.payload))},t.prototype.cancel=function(){this.app.dispatch(h({id:this.id}))},t.prototype.close=function(){this.cancel()},t}(p.ActionSet);t.ResourcePicker=b},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.respond=t.request=t.Action=void 0;var r,o=n(0),i=n(1);!function(e){e.REQUEST="APP::SESSION_TOKEN::REQUEST",e.RESPOND="APP::SESSION_TOKEN::RESPOND"}(r=t.Action||(t.Action={})),t.request=function(){return o.actionWrapper({group:i.Group.SessionToken,type:r.REQUEST})},t.respond=function(e){return o.actionWrapper({payload:e,group:i.Group.SessionToken,type:r.RESPOND})}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.TitleBar=t.update=t.clickBreadcrumb=t.clickActionButton=t.Action=void 0;var a,u=n(2),c=n(7),s=n(10),p=n(90),f=n(11),l=n(0),d=n(1);!function(e){e.UPDATE="APP::TITLEBAR::UPDATE",e.BUTTON_CLICK="APP::TITLEBAR::BUTTONS::BUTTON::CLICK",e.BUTTON_UPDATE="APP::TITLEBAR::BUTTONS::BUTTON::UPDATE",e.BUTTON_GROUP_UPDATE="APP::TITLEBAR::BUTTONS::BUTTONGROUP::UPDATE",e.BREADCRUMBS_CLICK="APP::TITLEBAR::BREADCRUMBS::BUTTON::CLICK",e.BREADCRUMBS_UPDATE="APP::TITLEBAR::BREADCRUMBS::BUTTON::UPDATE"}(a=t.Action||(t.Action={}));var h={group:d.Group.TitleBar,subgroups:["Buttons"]},y={group:d.Group.TitleBar,subgroups:["Breadcrumbs"],type:d.ComponentType.Button};function b(e){return l.actionWrapper({payload:e,group:d.Group.TitleBar,type:a.UPDATE})}t.clickActionButton=function(e,t){var n=d.ComponentType.Button,r=i({id:e,type:n},h);return c.clickButton(d.Group.TitleBar,r,t)},t.clickBreadcrumb=function(e,t){var n=i({id:e},y);return c.clickButton(d.Group.TitleBar,n,t)},t.update=b;var P=function(e){function t(t,n){var r=e.call(this,t,d.Group.TitleBar,d.Group.TitleBar)||this;return n.title||n.breadcrumbs||n.buttons?(r.set(n),r):r}return o(t,e),Object.defineProperty(t.prototype,"buttons",{get:function(){if(this.primary||this.secondary)return{primary:this.primary,secondary:this.secondary}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"buttonsOptions",{get:function(){if(this.primaryOptions||this.secondaryOptions)return{primary:this.primaryOptions,secondary:this.secondaryOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){return{breadcrumbs:this.breadcrumbsOption,buttons:this.buttonsOptions,title:this.title}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{breadcrumbs:this.breadcrumb,buttons:this.buttons,id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=l.getMergedProps(this.options,e),r=n.title,o=n.buttons,i=n.breadcrumbs;return this.title=r,this.setBreadcrumbs(i),this.setPrimaryButton(o?o.primary:void 0),this.setSecondaryButton(o?o.secondary:void 0),t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.UPDATE:this.app.dispatch(b(this.payload))}return this},t.prototype.getButton=function(e,t,n){return e instanceof s.ButtonGroup?p.getGroupedButton(this,e,t,n):f.getSingleButton(this,e,t,n)},t.prototype.updatePrimaryButton=function(e){this.primary&&l.updateActionFromPayload(this.primary,e)&&this.dispatch(a.UPDATE)},t.prototype.updateSecondaryButtons=function(e){if(this.secondary){var t=this.secondary.find((function(t){return t.id===e.id}));if(t){(s.isGroupedButtonPayload(e),l.updateActionFromPayload(t,e))&&this.dispatch(a.UPDATE)}}},t.prototype.updateBreadcrumbButton=function(e){this.breadcrumb&&l.updateActionFromPayload(this.breadcrumb,e)&&this.dispatch(a.UPDATE)},t.prototype.setPrimaryButton=function(e){this.primaryOptions=this.getChildButton(e,this.primaryOptions),this.primary=this.primaryOptions?this.getButton(this.primaryOptions,h.subgroups,this.updatePrimaryButton):void 0},t.prototype.setSecondaryButton=function(e){var t=this,n=e||[],r=this.secondaryOptions||[];this.secondaryOptions=this.getUpdatedChildActions(n,r),this.secondary=this.secondaryOptions?this.secondaryOptions.map((function(e){return t.getButton(e,h.subgroups,t.updateSecondaryButtons)})):void 0},t.prototype.setBreadcrumbs=function(e){this.breadcrumbsOption=this.getChildButton(e,this.breadcrumbsOption),this.breadcrumb=this.breadcrumbsOption?this.getButton(this.breadcrumbsOption,y.subgroups,this.updateBreadcrumbButton):void 0},t.prototype.getChildButton=function(e,t){var n=e?[e]:[],r=t?[t]:[],o=this.getUpdatedChildActions(n,r);return o?o[0]:void 0},t}(u.ActionSetWithChildren);t.TitleBar=P},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.close=t.show=t.Share=t.Action=void 0;var a,u=n(1),c=n(0),s=n(2);!function(e){e.SHOW="APP::SHARE::SHOW",e.CLOSE="APP::SHARE::CLOSE"}(a=t.Action||(t.Action={}));var p=function(e){function t(t){return e.call(this,t,u.Group.Share,u.Group.Share)||this}return o(t,e),t.prototype.dispatch=function(e,t){switch(e){case a.SHOW:this.dispatchShareAction(a.SHOW,t);break;case a.CLOSE:this.dispatchShareAction(a.CLOSE,t);break;default:throw new Error("Action: "+e+" not supported")}return this},t.prototype.dispatchShareAction=function(e,t){this.app.dispatch(c.actionWrapper({type:e,group:u.Group.Share,payload:i({id:this.id},t)}))},t}(s.ActionSet);t.Share=p,t.show=function(){return c.actionWrapper({group:u.Group.Share,type:a.SHOW})},t.close=function(e){return c.actionWrapper({group:u.Group.Share,type:a.CLOSE,payload:e})}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.NavigationMenu=t.update=t.Action=void 0;var a,u=n(12),c=n(0),s=n(2),p=n(1),f=["Navigation_Menu"];function l(e){return c.actionWrapper({payload:e,group:p.Group.Menu,type:a.UPDATE})}!function(e){e.UPDATE="APP::MENU::NAVIGATION_MENU::UPDATE",e.LINK_UPDATE="APP::MENU::NAVIGATION_MENU::LINK::UPDATE"}(a=t.Action||(t.Action={})),t.update=l;var d=function(e){function t(t,n){var r=e.call(this,t,"Navigation_Menu",p.Group.Menu)||this;return r.items=[],r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return{items:this.itemsOptions,active:this.activeOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{active:this.active,items:this.items,id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=c.getMergedProps(this.options,e),r=n.items,o=n.active;return this.setItems(r),this.activeOptions=o,this.active=o&&o.id,t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.UPDATE:this.app.dispatch(l(this.payload))}return this},t.prototype.updateItem=function(e){if(this.items){var t=this.items.find((function(t){return t.id===e.id}));t&&c.updateActionFromPayload(t,e)&&this.dispatch(a.UPDATE)}},t.prototype.setItems=function(e){var t=this,n=e||[],r=this.itemsOptions||[];this.itemsOptions=this.getUpdatedChildActions(n,r),this.items=this.itemsOptions?this.itemsOptions.map((function(e){return t.addChild(e,t.group,f),t.subscribeToChild(e,u.Action.UPDATE,t.updateItem),e.payload})):[]},t}(s.ActionSetWithChildren);t.NavigationMenu=d},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.ChannelMenu=t.update=t.Action=void 0;var a,u=n(12),c=n(0),s=n(2),p=n(1),f=["Channel_Menu"];function l(e){return c.actionWrapper({payload:e,group:p.Group.Menu,type:a.UPDATE})}!function(e){e.UPDATE="APP::MENU::CHANNEL_MENU::UPDATE",e.LINK_UPDATE="APP::MENU::CHANNEL_MENU::LINK::UPDATE"}(a=t.Action||(t.Action={})),t.update=l;var d=function(e){function t(t,n){var r=e.call(this,t,"Channel_Menu",p.Group.Menu)||this;return r.items=[],r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return{items:this.itemsOptions,active:this.activeOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{active:this.active,items:this.items,id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=c.getMergedProps(this.options,e),r=n.items,o=n.active;return this.setItems(r),this.activeOptions=o,this.active=o&&o.id,t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.UPDATE:this.app.dispatch(l(this.payload))}return this},t.prototype.updateItem=function(e){if(this.items){var t=this.items.find((function(t){return t.id===e.id}));t&&c.updateActionFromPayload(t,e)&&this.dispatch(a.UPDATE)}},t.prototype.setItems=function(e){var t=this,n=e||[],r=this.itemsOptions||[];this.itemsOptions=this.getUpdatedChildActions(n,r),this.items=this.itemsOptions?this.itemsOptions.map((function(e){return t.addChild(e,t.group,f),t.subscribeToChild(e,u.Action.UPDATE,t.updateItem),e.payload})):[]},t}(s.ActionSetWithChildren);t.ChannelMenu=d},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.Pos=t.close=t.Action=void 0;var i,a=n(0),u=n(2),c=n(1);function s(){return a.actionWrapper({group:c.Group.Pos,type:i.CLOSE})}!function(e){e.CLOSE="APP::POS::CLOSE",e.LOCATION_UPDATE="APP::POS::LOCATION::UPDATE",e.USER_UPDATE="APP::POS::USER::UPDATE",e.DEVICE_UPDATE="APP::POS::DEVICE::UPDATE"}(i=t.Action||(t.Action={})),t.close=s;var p=function(e){function t(t){return e.call(this,t,c.Group.Pos,c.Group.Pos)||this}return o(t,e),t.prototype.dispatch=function(e){switch(e){case i.CLOSE:this.app.dispatch(s())}return this},t}(u.ActionSet);t.Pos=p},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.unstable_Picker=t.loadMore=t.search=t.update=t.cancel=t.open=t.select=t.ALL_RESOURCE_VERTICAL_ALIGNMENT=t.ALL_MEDIA_KINDS=t.ALL_BADGE_STATUSES=t.ALL_BADGE_PROGRESSES=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.SELECT})}function f(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.OPEN})}function l(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.CANCEL})}function d(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.UPDATE})}function h(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.SEARCH})}function y(e){return u.actionWrapper({payload:e,group:s.Group.unstable_Picker,type:a.LOAD_MORE})}!function(e){e.OPEN="APP::PICKER::OPEN",e.SELECT="APP::PICKER::SELECT",e.UPDATE="APP::PICKER::UPDATE",e.CANCEL="APP::PICKER::CANCEL",e.SEARCH="APP::PICKER::SEARCH",e.LOAD_MORE="APP::PICKER::LOAD_MORE"}(a=t.Action||(t.Action={})),t.ALL_BADGE_PROGRESSES=["incomplete","partiallyComplete","complete"],t.ALL_BADGE_STATUSES=["success","info","attention","critical","warning","new"],t.ALL_MEDIA_KINDS=["Avatar","Thumbnail"],t.ALL_RESOURCE_VERTICAL_ALIGNMENT=["leading","trailing","center"],t.select=p,t.open=f,t.cancel=l,t.update=d,t.search=h,t.loadMore=y;var b=function(e){function t(t,n){var r=e.call(this,t,s.Group.unstable_Picker,s.Group.unstable_Picker)||this;return r.items=[],r.selectedItems=[],r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{id:this.id})},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){return{items:this.items,maxSelectable:this.maxSelectable,selectedItems:this.selectedItems,title:this.title,loading:this.loading,searchQuery:this.searchQuery,searchQueryPlaceholder:this.searchQueryPlaceholder,primaryActionLabel:this.primaryActionLabel,secondaryActionLabel:this.secondaryActionLabel,emptySearchLabel:this.emptySearchLabel,canLoadMore:this.canLoadMore,loadingMore:this.loadingMore,verticalAlignment:this.verticalAlignment,allowEmptySelection:this.allowEmptySelection,resourceName:this.resourceName}},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=u.getMergedProps(this.options,e),r=n.selectedItems,o=void 0===r?[]:r,i=n.maxSelectable,a=void 0===i?0:i,c=n.items,s=void 0===c?[]:c,p=n.loading,f=void 0!==p&&p,l=n.title,d=n.searchQuery,h=n.searchQueryPlaceholder,y=n.primaryActionLabel,b=n.secondaryActionLabel,P=n.emptySearchLabel,A=n.canLoadMore,g=void 0!==A&&A,O=n.loadingMore,m=void 0!==O&&O,v=n.verticalAlignment,_=n.allowEmptySelection,E=n.resourceName;return this.title=l,this.items=s,this.selectedItems=o,this.maxSelectable=a,this.loading=f,this.searchQuery=d,this.searchQueryPlaceholder=h,this.primaryActionLabel=y,this.secondaryActionLabel=b,this.emptySearchLabel=P,this.canLoadMore=g,this.loadingMore=m,this.verticalAlignment=v,this.allowEmptySelection=_,this.resourceName=E,t&&this.update(),this},t.prototype.dispatch=function(e,t){return e===a.OPEN?this.open():e===a.UPDATE?this.update():e===a.CANCEL?this.cancel():e===a.SELECT?(this.selectedItems=(null==t?void 0:t.selectedItems)||[],this.app.dispatch(p({id:this.id,selectedItems:this.selectedItems}))):e===a.SEARCH?(this.searchQuery=(null==t?void 0:t.searchQuery)||"",this.app.dispatch(h({id:this.id,searchQuery:this.searchQuery}))):e===a.LOAD_MORE&&this.loadMore(),this},t.prototype.update=function(){this.app.dispatch(d(this.payload))},t.prototype.open=function(){this.app.dispatch(f(this.payload))},t.prototype.cancel=function(){this.app.dispatch(l({id:this.id}))},t.prototype.loadMore=function(){this.app.dispatch(y(this.payload))},t}(c.ActionSet);t.unstable_Picker=b},function(e,t,n){"use strict";(function(e){
2
+ /*!
3
+ * The buffer module from node.js, for the browser.
4
+ *
5
+ * @author Feross Aboukhadijeh <http://feross.org>
6
+ * @license MIT
7
+ */
8
+ var r=n(111),o=n(112),i=n(113);function a(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function u(e,t){if(a()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,n){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return s(this,e,t,n)}function s(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=l(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!c.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|h(t,n),o=(e=u(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(c.isBuffer(t)){var n=0|d(t.length);return 0===(e=u(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?u(e,0):l(e,t);if("Buffer"===t.type&&i(t.data))return l(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function p(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(p(t),e=u(e,t<0?0:0|d(t)),!c.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function l(e,t){var n=t.length<0?0:0|d(t.length);e=u(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function d(e){if(e>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function h(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return x(e).length;default:if(r)return F(e).length;t=(""+t).toLowerCase(),r=!0}}function y(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return R(this,t,n);case"utf8":case"utf-8":return S(this,t,n);case"ascii":return j(this,t,n);case"latin1":case"binary":return C(this,t,n);case"base64":return T(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function b(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function P(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=c.from(t,r)),c.isBuffer(t))return 0===t.length?-1:A(e,t,n,r,o);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):A(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function A(e,t,n,r,o){var i,a=1,u=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,u/=2,c/=2,n/=2}function s(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var p=-1;for(i=n;i<u;i++)if(s(e,i)===s(t,-1===p?0:i-p)){if(-1===p&&(p=i),i-p+1===c)return p*a}else-1!==p&&(i-=i-p),p=-1}else for(n+c>u&&(n=u-c),i=n;i>=0;i--){for(var f=!0,l=0;l<c;l++)if(s(e,i+l)!==s(t,l)){f=!1;break}if(f)return i}return-1}function g(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var a=0;a<r;++a){var u=parseInt(t.substr(2*a,2),16);if(isNaN(u))return a;e[n+a]=u}return a}function O(e,t,n,r){return V(F(t,e.length-n),e,n,r)}function m(e,t,n,r){return V(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function v(e,t,n,r){return m(e,t,n,r)}function _(e,t,n,r){return V(x(t),e,n,r)}function E(e,t,n,r){return V(function(e,t){for(var n,r,o,i=[],a=0;a<e.length&&!((t-=2)<0);++a)n=e.charCodeAt(a),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function T(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function S(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,a,u,c,s=e[o],p=null,f=s>239?4:s>223?3:s>191?2:1;if(o+f<=n)switch(f){case 1:s<128&&(p=s);break;case 2:128==(192&(i=e[o+1]))&&(c=(31&s)<<6|63&i)>127&&(p=c);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&(c=(15&s)<<12|(63&i)<<6|63&a)>2047&&(c<55296||c>57343)&&(p=c);break;case 4:i=e[o+1],a=e[o+2],u=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&u)&&(c=(15&s)<<18|(63&i)<<12|(63&a)<<6|63&u)>65535&&c<1114112&&(p=c)}null===p?(p=65533,f=1):p>65535&&(p-=65536,r.push(p>>>10&1023|55296),p=56320|1023&p),r.push(p),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=a(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,n){return s(null,e,t,n)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,n){return function(e,t,n,r){return p(t),t<=0?u(e,t):void 0!==n?"string"==typeof r?u(e,t).fill(n,r):u(e,t).fill(n):u(e,t)}(null,e,t,n)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=c.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var a=e[n];if(!c.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(r,o),o+=a.length}return r},c.byteLength=h,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)b(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)b(this,t,t+3),b(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)b(this,t,t+7),b(this,t+1,t+6),b(this,t+2,t+5),b(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?S(this,0,e):y.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,n,r,o){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),u=Math.min(i,a),s=this.slice(r,o),p=e.slice(t,n),f=0;f<u;++f)if(s[f]!==p[f]){i=s[f],a=p[f];break}return i<a?-1:a<i?1:0},c.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},c.prototype.indexOf=function(e,t,n){return P(this,e,t,n,!0)},c.prototype.lastIndexOf=function(e,t,n){return P(this,e,t,n,!1)},c.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return g(this,e,t,n);case"utf8":case"utf-8":return O(this,e,t,n);case"ascii":return m(this,e,t,n);case"latin1":case"binary":return v(this,e,t,n);case"base64":return _(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function j(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function C(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function R(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=G(e[i]);return o}function I(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function M(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function w(e,t,n,r,o,i){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function L(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function D(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function N(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function B(e,t,n,r,i){return i||N(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function U(e,t,n,r,i){return i||N(e,0,n,8),o.write(e,t,n,r,52,8),n+8}c.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=c.prototype;else{var o=t-e;n=new c(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},c.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||M(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},c.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||M(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},c.prototype.readUInt8=function(e,t){return t||M(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||M(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||M(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||M(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||M(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||M(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},c.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||M(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},c.prototype.readInt8=function(e,t){return t||M(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||M(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt16BE=function(e,t){t||M(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},c.prototype.readInt32LE=function(e,t){return t||M(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||M(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||M(e,4,this.length),o.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||M(e,4,this.length),o.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||M(e,8,this.length),o.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||M(e,8,this.length),o.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||w(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},c.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||w(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},c.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):L(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):L(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):D(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);w(this,e,t,n,o-1,-o)}var i=0,a=1,u=0;for(this[t]=255&e;++i<n&&(a*=256);)e<0&&0===u&&0!==this[t+i-1]&&(u=1),this[t+i]=(e/a>>0)-u&255;return t+n},c.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);w(this,e,t,n,o-1,-o)}var i=n-1,a=1,u=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)e<0&&0===u&&0!==this[t+i+1]&&(u=1),this[t+i]=(e/a>>0)-u&255;return t+n},c.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):L(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):L(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):D(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||w(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):D(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,n){return B(this,e,t,!0,n)},c.prototype.writeFloatBE=function(e,t,n){return B(this,e,t,!1,n)},c.prototype.writeDoubleLE=function(e,t,n){return U(this,e,t,!0,n)},c.prototype.writeDoubleBE=function(e,t,n){return U(this,e,t,!1,n)},c.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!c.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},c.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!c.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var a=c.isBuffer(e)?e:F(new c(e,r).toString()),u=a.length;for(i=0;i<n-t;++i)this[i+t]=a[i%u]}return this};var k=/[^+\/0-9A-Za-z-_]/g;function G(e){return e<16?"0"+e.toString(16):e.toString(16)}function F(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],a=0;a<r;++a){if((n=e.charCodeAt(a))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function x(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(k,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function V(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(110))},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t},a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},u=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.getSessionToken=void 0;var c=n(5),s=i(n(43));t.getSessionToken=function(e){return a(this,void 0,void 0,(function(){return u(this,(function(t){return[2,new Promise((function(t,n){var r=e.subscribe(s.Action.RESPOND,(function(e){var o=e.sessionToken;o?t(o):n(c.fromAction("Failed to retrieve a session token",c.Action.FAILED_AUTHENTICATION)),r()}));e.dispatch(s.request())}))]}))}))}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t},a=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},u=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}},c=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getAuthorizationCodePayload=void 0;var s=i(n(31)),p=n(9),f=c(n(121));t.getAuthorizationCodePayload=function(e){return a(this,void 0,void 0,(function(){return u(this,(function(t){return[2,new Promise((function(t,n){var r=f.default(),o=e.subscribe(s.Action.RESPOND,(function(e){switch(null==e?void 0:e.status){case"needsExchange":t(e);break;default:n(p.fromAction("Failed to retrieve an authorization code",p.Action.FAILED_AUTHENTICATION))}o()}),r);e.dispatch(s.request(r))}))]}))}))}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)},a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.utilities=t.createApp=t.default=t.actions=void 0;var u=n(8),c=n(67);Object.defineProperty(t,"actions",{enumerable:!0,get:function(){return c.compatibilityActions}});var s=n(107);function p(e){return s.compatibilityCreateApp(e,u.createApp)}i(n(115),t),t.default=p,t.createApp=p,t.utilities=a(n(116))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,n){if(null==n)return n;if(void 0===t||!Object.prototype.isPrototypeOf.call(Object.getPrototypeOf(t),n)||"Object"!==n.constructor.name&&"Array"!==n.constructor.name)return n;var r={};return Object.keys(n).forEach((function(o){Object.prototype.hasOwnProperty.call(t,o)?"object"!=typeof t[o]||Array.isArray(t[o])?r[o]=n[o]:r[o]=e(t[o],n[o]):r[o]=n[o]})),Object.keys(t).forEach((function(e){Object.prototype.hasOwnProperty.call(n,e)||(r[e]=t[e])})),Object.setPrototypeOf(r,Object.getPrototypeOf(t)),r}},function(e){e.exports=JSON.parse('{"name":"@shopify/app-bridge","version":"3.7.8","types":"index.d.ts","main":"index.js","unpkg":"umd/index.js","jsdelivr":"umd/index.js","files":["/actions/","/client/","/umd/","/utilities/","/util/","/validate/","/development.d.ts","/development.js","/index.d.ts","/index.js","/MessageTransport.d.ts","/MessageTransport.js","/production.d.ts","/production.js"],"private":false,"publishConfig":{"access":"public","@shopify:registry":"https://registry.npmjs.org"},"repository":"git@github.com:Shopify/app-bridge.git","homepage":"https://shopify.dev/tools/app-bridge","author":"Shopify Inc.","license":"MIT","scripts":{"build":"yarn build:tsc && yarn build:npm && yarn build:umd","build:tsc":"NODE_ENV=production tsc","build:umd":"NODE_ENV=production webpack -p","build:npm":"shx cp -r ./npm/index.js ./index.js","check":"tsc","clean":"yarn clean:tsc && yarn clean:npm && yarn clean:umd","clean:tsc":"NODE_ENV=production tsc --build --clean","clean:umd":"rm -rf ./umd","clean:npm":"rm -rf ./index.js","pack":"yarn pack","size":"size-limit"},"sideEffects":false,"size-limit":[{"limit":"10.5 KB","path":"production.js"}],"dependencies":{"@shopify/app-bridge-core":"1.0.2","base64url":"^3.0.1","web-vitals":"^3.0.1"},"devDependencies":{"@types/node":"^10.12.5","shx":"^0.3.3"}}')},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.app=t.Action=void 0;var r,o=n(0),i=n(1);!function(e){e.APP="APP::PRINT::APP"}(r=t.Action||(t.Action={})),t.app=function(){return o.actionWrapper({group:i.Group.Print,type:r.APP})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createTransportListener=t.fromWindow=t.fromFrame=t.Context=void 0;var r=n(5),o=n(25),i=n(6),a=n(14),u=n(15);!function(e){e.Modal="Modal",e.Main="Main"}(t.Context||(t.Context={})),t.fromFrame=function(e,t,n){var i=[],c=e.host,s=e.window;if(!c)throw r.fromAction("App frame is undefined",r.AppActionType.WINDOW_UNDEFINED);return u.isUnframed&&window.MobileWebView&&Object.assign(window.MobileWebView,{postMessageToIframe:function(e,t){null==s||s.postMessage(e,t),function(e){return null!==e&&"object"==typeof e&&!Array.isArray(e)&&"dispatch"===e.type&&"object"==typeof e.payload}(e)&&c.postMessage(JSON.stringify(e.payload),location.origin)},updateIframeUrl:function(n){var r=window.location,o=(e.window||{}).location;try{new URL(n).origin===t&&o?o.replace(n):r.href=n}catch(e){}}}),c.addEventListener("message",(function(e){if(e.source!==c&&o.isAppMessage(e))if(e.origin===t)if(u.isUnframed&&window.MobileWebView){p=JSON.stringify({id:"unframed://fromClient",origin:t,data:e.data});window.MobileWebView.postMessage(p)}else for(var n=0,a=i;n<a.length;n++){(0,a[n])(e)}else{var p,f="Message origin '"+e.origin+"' does not match app origin '"+t+"'.",l={type:"dispatch",payload:p=r.invalidOriginAction(f)};null==s||s.postMessage(l,e.origin)}})),{context:n,localOrigin:t,frameWindow:s,hostFrame:c,dispatch:function(e){null==s||s.postMessage(e,t)},subscribe:function(e){return a.addAndRemoveFromCollection(i,e)}}},t.fromWindow=function(e,t){var n=[];return void 0!==typeof window&&window.addEventListener("message",(function(t){if((window!==e||u.isUnframed)&&t.source===e&&(o.isAppBridgeAction(t.data.payload)||o.isAppMessage(t)))for(var r=0,i=n;r<i.length;r++){(0,i[r])(t)}})),{localOrigin:t,hostFrame:e,dispatch:function(n){var r;if(null===(r=n.source)||void 0===r?void 0:r.host)if(u.isUnframed&&window&&window.MobileWebView){var o=JSON.stringify({id:"unframed://fromClient",origin:t,data:n});window.MobileWebView.postMessage(o)}else{var i=new URL("https://"+n.source.host).origin;e.postMessage(n,i)}},subscribe:function(e){return a.addAndRemoveFromCollection(n,e)}}},t.createTransportListener=function(){var e=[],t={};return{createSubscribeHandler:function(n){return function(){if(arguments.length<2)return a.addAndRemoveFromCollection(e,{callback:arguments[0]});var r=Array.from(arguments),o=r[0],u=r[1],c=r[2],s={callback:u,id:c},p={type:o,id:c};return Object.prototype.hasOwnProperty.call(t,o)||(t[o]=[]),n&&n(i.MessageType.Subscribe,p),a.addAndRemoveFromCollection(t[o],s,(function(){n&&n(i.MessageType.Unsubscribe,p)}))}},handleMessage:function(t){e.forEach((function(e){return e.callback(t)}))},handleActionDispatch:function(e){var n=e.type,r=e.payload,o=!1;if(Object.prototype.hasOwnProperty.call(t,n))for(var i=0,a=t[n];i<a.length;i++){var u=a[i],c=u.id,s=u.callback;!(r&&r.id===c)&&c||(s(r),o=!0)}return o}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mockAppBridge=t.serverAppBridge=void 0;var r=n(9),o=function(){},i=new Promise((function(){}));t.serverAppBridge={dispatch:function(){return{}},error:function(){return o},featuresAvailable:function(){return Promise.reject(r.fromAction("Feature detection is only available on the client side.",r.AppActionType.WINDOW_UNDEFINED))},getState:function(){return Promise.reject(r.fromAction("State is only available on the client side.",r.AppActionType.WINDOW_UNDEFINED))},localOrigin:"",hostOrigin:"",subscribe:function(){return o}},t.mockAppBridge={dispatch:function(){return{}},error:function(){return o},featuresAvailable:function(){return i},getState:function(){return i},localOrigin:"",hostOrigin:"",subscribe:function(){return o}}},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var c,s=[],p=!1,f=-1;function l(){p&&c&&(p=!1,c.length?s=c.concat(s):f=-1,s.length&&d())}function d(){if(!p){var e=u(l);p=!0;for(var t=s.length;t;){for(c=s,s=[];++f<t;)c&&c[f].run();f=-1,t=s.length}c=null,p=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function y(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];s.push(new h(e,t)),1!==s.length||p||u(d)},h.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=y,o.addListener=y,o.once=y,o.off=y,o.removeListener=y,o.removeAllListeners=y,o.emit=y,o.prependListener=y,o.prependOnceListener=y,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Action=void 0,function(e){e.INITIALIZE="APP::CLIENT::INITIALIZE"}(t.Action||(t.Action={}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initializeWebVitals=t.interactionToNextPaint=t.timeToFirstByte=t.firstContentfulPaint=t.cumulativeLayoutShift=t.firstInputDelay=t.largestContentfulPaint=t.Action=void 0;var r=n(62),o=n(63);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}});var i=n(16),a=n(4),u=n(3),c=n(17);function s(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.LARGEST_CONTENTFUL_PAINT,payload:e})}function p(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.FIRST_INPUT_DELAY,payload:e})}function f(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.CUMULATIVE_LAYOUT_SHIFT,payload:e})}function l(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.FIRST_CONTENTFUL_PAINT,payload:e})}function d(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.TIME_TO_FIRST_BYTE,payload:e})}function h(e){return u.actionWrapper({group:a.Group.WebVitals,type:o.Action.INTERACTION_TO_NEXT_PAINT,payload:e})}t.largestContentfulPaint=s,t.firstInputDelay=p,t.cumulativeLayoutShift=f,t.firstContentfulPaint=l,t.timeToFirstByte=d,t.interactionToNextPaint=h,t.initializeWebVitals=function(e){function t(t){return function(n){var r=n.id,o=n.name,i=n.value,a=t({id:r,metricName:o,value:i});e.dispatch(a)}}var n=window;i.isServer||i.isClient&&n.__is_web_vitals_initialized__||c.isMobile()||(n.__is_web_vitals_initialized__=!0,r.onLCP(t(s)),r.onFID(t(p)),r.onCLS(t(f)),r.onFCP(t(l)),r.onTTFB(t(d)),r.onINP(t(h)))}},function(e,t,n){"use strict";n.r(t),n.d(t,"getCLS",(function(){return S})),n.d(t,"getFCP",(function(){return T})),n.d(t,"getFID",(function(){return L})),n.d(t,"getINP",(function(){return Y})),n.d(t,"getLCP",(function(){return K})),n.d(t,"getTTFB",(function(){return q})),n.d(t,"onCLS",(function(){return S})),n.d(t,"onFCP",(function(){return T})),n.d(t,"onFID",(function(){return L})),n.d(t,"onINP",(function(){return Y})),n.d(t,"onLCP",(function(){return K})),n.d(t,"onTTFB",(function(){return q}));var r,o,i,a,u,c=-1,s=function(e){addEventListener("pageshow",(function(t){t.persisted&&(c=t.timeStamp,e(t))}),!0)},p=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},f=function(){var e=p();return e&&e.activationStart||0},l=function(e,t){var n=p(),r="navigate";return c>=0?r="back-forward-cache":n&&(r=document.prerendering||f()>0?"prerender":document.wasDiscarded?"restore":n.type.replace(/_/g,"-")),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},d=function(e,t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(e){}},h=function(e,t,n,r){var o,i;return function(a){t.value>=0&&(a||r)&&((i=t.value-(o||0))||void 0===o)&&(o=t.value,t.delta=i,t.rating=function(e,t){return e>t[1]?"poor":e>t[0]?"needs-improvement":"good"}(t.value,n),e(t))}},y=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},b=function(e){var t=function(t){"pagehide"!==t.type&&"hidden"!==document.visibilityState||e(t)};addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0)},P=function(e){var t=!1;return function(n){t||(e(n),t=!0)}},A=-1,g=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},O=function(e){"hidden"===document.visibilityState&&A>-1&&(A="visibilitychange"===e.type?e.timeStamp:0,v())},m=function(){addEventListener("visibilitychange",O,!0),addEventListener("prerenderingchange",O,!0)},v=function(){removeEventListener("visibilitychange",O,!0),removeEventListener("prerenderingchange",O,!0)},_=function(){return A<0&&(A=g(),m(),s((function(){setTimeout((function(){A=g(),m()}),0)}))),{get firstHiddenTime(){return A}}},E=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},T=function(e,t){t=t||{},E((function(){var n,r=[1800,3e3],o=_(),i=l("FCP"),a=d("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(a.disconnect(),e.startTime<o.firstHiddenTime&&(i.value=Math.max(e.startTime-f(),0),i.entries.push(e),n(!0)))}))}));a&&(n=h(e,i,r,t.reportAllChanges),s((function(o){i=l("FCP"),n=h(e,i,r,t.reportAllChanges),y((function(){i.value=performance.now()-o.timeStamp,n(!0)}))})))}))},S=function(e,t){t=t||{},T(P((function(){var n,r=[.1,.25],o=l("CLS",0),i=0,a=[],u=function(e){e.forEach((function(e){if(!e.hadRecentInput){var t=a[0],n=a[a.length-1];i&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(i+=e.value,a.push(e)):(i=e.value,a=[e])}})),i>o.value&&(o.value=i,o.entries=a,n())},c=d("layout-shift",u);c&&(n=h(e,o,r,t.reportAllChanges),b((function(){u(c.takeRecords()),n(!0)})),s((function(){i=0,o=l("CLS",0),n=h(e,o,r,t.reportAllChanges),y((function(){return n()}))})),setTimeout(n,0))})))},j={passive:!0,capture:!0},C=new Date,R=function(e,t){r||(r=t,o=e,i=new Date,w(removeEventListener),I())},I=function(){if(o>=0&&o<i-C){var e={entryType:"first-input",name:r.type,target:r.target,cancelable:r.cancelable,startTime:r.timeStamp,processingStart:r.timeStamp+o};a.forEach((function(t){t(e)})),a=[]}},M=function(e){if(e.cancelable){var t=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,t){var n=function(){R(e,t),o()},r=function(){o()},o=function(){removeEventListener("pointerup",n,j),removeEventListener("pointercancel",r,j)};addEventListener("pointerup",n,j),addEventListener("pointercancel",r,j)}(t,e):R(t,e)}},w=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(t){return e(t,M,j)}))},L=function(e,t){t=t||{},E((function(){var n,i=[100,300],u=_(),c=l("FID"),p=function(e){e.startTime<u.firstHiddenTime&&(c.value=e.processingStart-e.startTime,c.entries.push(e),n(!0))},f=function(e){e.forEach(p)},y=d("first-input",f);n=h(e,c,i,t.reportAllChanges),y&&b(P((function(){f(y.takeRecords()),y.disconnect()}))),y&&s((function(){var u;c=l("FID"),n=h(e,c,i,t.reportAllChanges),a=[],o=-1,r=null,w(addEventListener),u=p,a.push(u),I()}))}))},D=0,N=1/0,B=0,U=function(e){e.forEach((function(e){e.interactionId&&(N=Math.min(N,e.interactionId),B=Math.max(B,e.interactionId),D=B?(B-N)/7+1:0)}))},k=function(){return u?D:performance.interactionCount||0},G=function(){"interactionCount"in performance||u||(u=d("event",U,{type:"event",buffered:!0,durationThreshold:0}))},F=0,x=function(){return k()-F},V=[],W={},H=function(e){var t=V[V.length-1],n=W[e.interactionId];if(n||V.length<10||e.duration>t.latency){if(n)n.entries.push(e),n.latency=Math.max(n.latency,e.duration);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};W[r.id]=r,V.push(r)}V.sort((function(e,t){return t.latency-e.latency})),V.splice(10).forEach((function(e){delete W[e.id]}))}},Y=function(e,t){t=t||{},E((function(){var n=[200,500];G();var r,o=l("INP"),i=function(e){e.forEach((function(e){e.interactionId&&H(e),"first-input"===e.entryType&&!V.some((function(t){return t.entries.some((function(t){return e.duration===t.duration&&e.startTime===t.startTime}))}))&&H(e)}));var t,n=(t=Math.min(V.length-1,Math.floor(x()/50)),V[t]);n&&n.latency!==o.value&&(o.value=n.latency,o.entries=n.entries,r())},a=d("event",i,{durationThreshold:t.durationThreshold||40});r=h(e,o,n,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),b((function(){i(a.takeRecords()),o.value<0&&x()>0&&(o.value=0,o.entries=[]),r(!0)})),s((function(){V=[],F=k(),o=l("INP"),r=h(e,o,n,t.reportAllChanges)})))}))},z={},K=function(e,t){t=t||{},E((function(){var n,r=[2500,4e3],o=_(),i=l("LCP"),a=function(e){var t=e[e.length-1];if(t){var r=Math.max(t.startTime-f(),0);r<o.firstHiddenTime&&(i.value=r,i.entries=[t],n())}},u=d("largest-contentful-paint",a);if(u){n=h(e,i,r,t.reportAllChanges);var c=P((function(){z[i.id]||(a(u.takeRecords()),u.disconnect(),z[i.id]=!0,n(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,c,!0)})),b(c),s((function(o){i=l("LCP"),n=h(e,i,r,t.reportAllChanges),y((function(){i.value=performance.now()-o.timeStamp,z[i.id]=!0,n(!0)}))}))}}))},q=function(e,t){t=t||{};var n=[800,1800],r=l("TTFB"),o=h(e,r,n,t.reportAllChanges);!function e(t){document.prerendering?E((function(){return e(t)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(t)}),!0):setTimeout(t,0)}((function(){var i=p();if(i){var a=i.responseStart;if(a<=0||a>performance.now())return;r.value=Math.max(a-f(),0),r.entries=[i],o(!0),s((function(){r=l("TTFB",0),(o=h(e,r,n,t.reportAllChanges))(!0)}))}}))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Action=void 0,function(e){e.LARGEST_CONTENTFUL_PAINT="APP::WEB_VITALS::LARGEST_CONTENTFUL_PAINT",e.FIRST_INPUT_DELAY="APP::WEB_VITALS::FIRST_INPUT_DELAY",e.CUMULATIVE_LAYOUT_SHIFT="APP::WEB_VITALS::CUMULATIVE_LAYOUT_SHIFT",e.FIRST_CONTENTFUL_PAINT="APP::WEB_VITALS::FIRST_CONTENTFUL_PAINT",e.TIME_TO_FIRST_BYTE="APP::WEB_VITALS::TIME_TO_FIRST_BYTE",e.INTERACTION_TO_NEXT_PAINT="APP::WEB_VITALS::INTERACTION_TO_NEXT_PAINT"}(t.Action||(t.Action={}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.handleAppPrint=void 0;var r=n(28);function o(){var e;null===(e=r.getWindow())||void 0===e||e.print()}function i(){var e=function(){var e=r.getWindow();if(e&&e.document&&e.document.body){var t=e.document.createElement("input");return t.style.display="none",e.document.body.appendChild(t),t}}();e&&(e.select(),o(),e.remove())}t.handleAppPrint=function(){navigator.userAgent.indexOf("iOS")>=0?i():o()}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(66),o=function(){function e(){this.map={}}return e.prototype.set=function(e,t){Object.prototype.hasOwnProperty.call(this.map,e)||(this.map[e]=[]);var n={handler:t,remove:function(){}},o=r.addAndRemoveFromCollection(this.map[e],n);return n={handler:t,remove:o},o},e.prototype.get=function(e){var t=this.map[e];return t?t.map((function(e){return e.handler})):void 0},e.prototype.run=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=0,a=this.get(e)||[];function u(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var o=a[i++];return o?o(u).apply(n,e):t.apply(n,e)}return u.apply(n,r)},e}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeFromCollection=t.addAndRemoveFromCollection=void 0;var r=n(14);Object.defineProperty(t,"addAndRemoveFromCollection",{enumerable:!0,get:function(){return r.addAndRemoveFromCollection}}),Object.defineProperty(t,"removeFromCollection",{enumerable:!0,get:function(){return r.removeFromCollection}})},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.compatibilityActions=void 0;var u=a(n(30));t.compatibilityActions=Object.entries(u).reduce((function(e,t){var n,o,i=t[0],a=t[1];return Object.keys(u.Group).includes(i)?r(r({},e),((o={})[i]=r(r({},a),{ActionType:a.Action}),o)):r(r({},e),((n={})[i]=a,n))}),{})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.ButtonGroup=t.isGroupedButtonPayload=t.isGroupedButton=t.update=t.ButtonGroupAction=t.ButtonGroupUpdateAction=t.Payload=t.Action=void 0;var r=n(10);Object.defineProperty(t,"ButtonGroup",{enumerable:!0,get:function(){return r.ButtonGroup}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(10);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"ButtonGroupUpdateAction",{enumerable:!0,get:function(){return o.ButtonGroupUpdateAction}}),Object.defineProperty(t,"ButtonGroupAction",{enumerable:!0,get:function(){return o.ButtonGroupAction}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),Object.defineProperty(t,"isGroupedButton",{enumerable:!0,get:function(){return o.isGroupedButton}}),Object.defineProperty(t,"isGroupedButtonPayload",{enumerable:!0,get:function(){return o.isGroupedButtonPayload}}),t.create=function(e,t){return new r.ButtonGroup(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.setLineItemProperties=t.removeLineItemDiscount=t.setLineItemDiscount=t.removeLineItem=t.updateLineItem=t.addLineItem=t.removeProperties=t.setProperties=t.setDiscount=t.updateCustomerAddress=t.addCustomerAddress=t.setCustomer=t.update=t.fetch=t.Properties=t.NoteAttributes=t.LineItem=t.Discount=t.DiscountCode=t.DiscountAmount=t.Address=t.CustomerWithAddresses=t.Customer=t.Cart=t.RemoveLineItemPropertiesPayload=t.SetLineItemPropertiesPayload=t.RemoveLineItemDiscountPayload=t.SetLineItemDiscountPayload=t.RemoveLineItemPayload=t.UpdateLineItemPayload=t.UpdateLineItemData=t.RemovePropertiesPayload=t.SetPropertiesPayload=t.SetDiscountPayload=t.UpdateCustomerAddressPayload=t.SetCustomerPayload=t.AddLineItemPayload=t.AddCustomerAddressPayload=t.Options=t.Payload=t.Data=t.Action=void 0;var r=n(70);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"Data",{enumerable:!0,get:function(){return r.Data}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return r.Payload}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"AddCustomerAddressPayload",{enumerable:!0,get:function(){return r.AddCustomerAddressPayload}}),Object.defineProperty(t,"AddLineItemPayload",{enumerable:!0,get:function(){return r.AddLineItemPayload}}),Object.defineProperty(t,"SetCustomerPayload",{enumerable:!0,get:function(){return r.SetCustomerPayload}}),Object.defineProperty(t,"UpdateCustomerAddressPayload",{enumerable:!0,get:function(){return r.UpdateCustomerAddressPayload}}),Object.defineProperty(t,"SetDiscountPayload",{enumerable:!0,get:function(){return r.SetDiscountPayload}}),Object.defineProperty(t,"SetPropertiesPayload",{enumerable:!0,get:function(){return r.SetPropertiesPayload}}),Object.defineProperty(t,"RemovePropertiesPayload",{enumerable:!0,get:function(){return r.RemovePropertiesPayload}}),Object.defineProperty(t,"UpdateLineItemData",{enumerable:!0,get:function(){return r.UpdateLineItemData}}),Object.defineProperty(t,"UpdateLineItemPayload",{enumerable:!0,get:function(){return r.UpdateLineItemPayload}}),Object.defineProperty(t,"RemoveLineItemPayload",{enumerable:!0,get:function(){return r.RemoveLineItemPayload}}),Object.defineProperty(t,"SetLineItemDiscountPayload",{enumerable:!0,get:function(){return r.SetLineItemDiscountPayload}}),Object.defineProperty(t,"RemoveLineItemDiscountPayload",{enumerable:!0,get:function(){return r.RemoveLineItemDiscountPayload}}),Object.defineProperty(t,"SetLineItemPropertiesPayload",{enumerable:!0,get:function(){return r.SetLineItemPropertiesPayload}}),Object.defineProperty(t,"RemoveLineItemPropertiesPayload",{enumerable:!0,get:function(){return r.RemoveLineItemPropertiesPayload}}),Object.defineProperty(t,"Cart",{enumerable:!0,get:function(){return r.Cart}}),Object.defineProperty(t,"Customer",{enumerable:!0,get:function(){return r.Customer}}),Object.defineProperty(t,"CustomerWithAddresses",{enumerable:!0,get:function(){return r.CustomerWithAddresses}}),Object.defineProperty(t,"Address",{enumerable:!0,get:function(){return r.Address}}),Object.defineProperty(t,"DiscountAmount",{enumerable:!0,get:function(){return r.DiscountAmount}}),Object.defineProperty(t,"DiscountCode",{enumerable:!0,get:function(){return r.DiscountCode}}),Object.defineProperty(t,"Discount",{enumerable:!0,get:function(){return r.Discount}}),Object.defineProperty(t,"LineItem",{enumerable:!0,get:function(){return r.LineItem}}),Object.defineProperty(t,"NoteAttributes",{enumerable:!0,get:function(){return r.NoteAttributes}}),Object.defineProperty(t,"Properties",{enumerable:!0,get:function(){return r.Properties}}),Object.defineProperty(t,"fetch",{enumerable:!0,get:function(){return r.fetch}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return r.update}}),Object.defineProperty(t,"setCustomer",{enumerable:!0,get:function(){return r.setCustomer}}),Object.defineProperty(t,"addCustomerAddress",{enumerable:!0,get:function(){return r.addCustomerAddress}}),Object.defineProperty(t,"updateCustomerAddress",{enumerable:!0,get:function(){return r.updateCustomerAddress}}),Object.defineProperty(t,"setDiscount",{enumerable:!0,get:function(){return r.setDiscount}}),Object.defineProperty(t,"setProperties",{enumerable:!0,get:function(){return r.setProperties}}),Object.defineProperty(t,"removeProperties",{enumerable:!0,get:function(){return r.removeProperties}}),Object.defineProperty(t,"addLineItem",{enumerable:!0,get:function(){return r.addLineItem}}),Object.defineProperty(t,"updateLineItem",{enumerable:!0,get:function(){return r.updateLineItem}}),Object.defineProperty(t,"removeLineItem",{enumerable:!0,get:function(){return r.removeLineItem}}),Object.defineProperty(t,"setLineItemDiscount",{enumerable:!0,get:function(){return r.setLineItemDiscount}}),Object.defineProperty(t,"removeLineItemDiscount",{enumerable:!0,get:function(){return r.removeLineItemDiscount}}),Object.defineProperty(t,"setLineItemProperties",{enumerable:!0,get:function(){return r.setLineItemProperties}}),t.create=function(e,t){return new r.Cart(e,t)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Cart=t.setLineItemProperties=t.removeLineItemDiscount=t.setLineItemDiscount=t.removeLineItem=t.updateLineItem=t.addLineItem=t.removeProperties=t.setProperties=t.setDiscount=t.updateCustomerAddress=t.addCustomerAddress=t.setCustomer=t.update=t.fetch=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e,t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.Cart,type:e,payload:t})}!function(e){e.FETCH="APP::CART::FETCH",e.UPDATE="APP::CART::UPDATE",e.SET_CUSTOMER="APP::CART::SET_CUSTOMER",e.REMOVE_CUSTOMER="APP::CART::REMOVE_CUSTOMER",e.ADD_CUSTOMER_ADDRESS="APP::CART::ADD_CUSTOMER_ADDRESS",e.UPDATE_CUSTOMER_ADDRESS="APP::CART::UPDATE_CUSTOMER_ADDRESS",e.SET_DISCOUNT="APP::CART::SET_DISCOUNT",e.REMOVE_DISCOUNT="APP::CART::REMOVE_DISCOUNT",e.SET_PROPERTIES="APP::CART::SET_PROPERTIES",e.REMOVE_PROPERTIES="APP::CART::REMOVE_PROPERTIES",e.CLEAR="APP::CART::CLEAR",e.ADD_LINE_ITEM="APP::CART::ADD_LINE_ITEM",e.UPDATE_LINE_ITEM="APP::CART::UPDATE_LINE_ITEM",e.REMOVE_LINE_ITEM="APP::CART::REMOVE_LINE_ITEM",e.SET_LINE_ITEM_DISCOUNT="APP::CART::SET_LINE_ITEM_DISCOUNT",e.REMOVE_LINE_ITEM_DISCOUNT="APP::CART::REMOVE_LINE_ITEM_DISCOUNT",e.SET_LINE_ITEM_PROPERTIES="APP::CART::SET_LINE_ITEM_PROPERTIES",e.REMOVE_LINE_ITEM_PROPERTIES="APP::CART::REMOVE_LINE_ITEM_PROPERTIES"}(a=t.Action||(t.Action={})),t.fetch=function(){return p(a.FETCH)},t.update=function(e){return p(a.UPDATE,e)},t.setCustomer=function(e){return p(a.SET_CUSTOMER,e)},t.addCustomerAddress=function(e){return p(a.ADD_CUSTOMER_ADDRESS,e)},t.updateCustomerAddress=function(e){return p(a.UPDATE_CUSTOMER_ADDRESS,e)},t.setDiscount=function(e){return p(a.SET_DISCOUNT,e)},t.setProperties=function(e){return p(a.SET_PROPERTIES,e)},t.removeProperties=function(e){return p(a.REMOVE_PROPERTIES,e)},t.addLineItem=function(e){return p(a.ADD_LINE_ITEM,e)},t.updateLineItem=function(e){return p(a.UPDATE_LINE_ITEM,e)},t.removeLineItem=function(e){return p(a.REMOVE_LINE_ITEM,e)},t.setLineItemDiscount=function(e){return p(a.SET_LINE_ITEM_DISCOUNT,e)},t.removeLineItemDiscount=function(e){return p(a.REMOVE_LINE_ITEM_DISCOUNT,e)},t.setLineItemProperties=function(e){return p(a.SET_LINE_ITEM_PROPERTIES,e)};var f=function(e){function t(t,n){return e.call(this,t,s.Group.Cart,s.Group.Cart,n?n.id:void 0)||this}return o(t,e),t.prototype.dispatch=function(e,t){switch(e){case a.FETCH:this.dispatchCartAction(a.FETCH);break;case a.UPDATE:this.dispatchCartAction(a.UPDATE,t);break;case a.SET_CUSTOMER:this.dispatchCartAction(a.SET_CUSTOMER,t);break;case a.REMOVE_CUSTOMER:this.dispatchCartAction(a.REMOVE_CUSTOMER,t);break;case a.ADD_CUSTOMER_ADDRESS:this.dispatchCartAction(a.ADD_CUSTOMER_ADDRESS,t);break;case a.UPDATE_CUSTOMER_ADDRESS:this.dispatchCartAction(a.UPDATE_CUSTOMER_ADDRESS,t);break;case a.SET_DISCOUNT:this.dispatchCartAction(a.SET_DISCOUNT,t);break;case a.REMOVE_DISCOUNT:this.dispatchCartAction(a.REMOVE_DISCOUNT,t);break;case a.SET_PROPERTIES:this.dispatchCartAction(a.SET_PROPERTIES,t);break;case a.REMOVE_PROPERTIES:this.dispatchCartAction(a.REMOVE_PROPERTIES,t);break;case a.CLEAR:this.dispatchCartAction(a.CLEAR,t);break;case a.ADD_LINE_ITEM:this.dispatchCartAction(a.ADD_LINE_ITEM,t);break;case a.UPDATE_LINE_ITEM:this.dispatchCartAction(a.UPDATE_LINE_ITEM,t);break;case a.REMOVE_LINE_ITEM:this.dispatchCartAction(a.REMOVE_LINE_ITEM,t);break;case a.SET_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.SET_LINE_ITEM_DISCOUNT,t);break;case a.REMOVE_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.REMOVE_LINE_ITEM_DISCOUNT,t);break;case a.SET_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.SET_LINE_ITEM_PROPERTIES,t);break;case a.REMOVE_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.REMOVE_LINE_ITEM_PROPERTIES,t)}return this},t.prototype.dispatchCartAction=function(e,t){this.app.dispatch(p(e,i(i({},t),{id:this.id})))},t}(c.ActionSet);t.Cart=f},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(72),t)},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Flash=t.FlashAction=t.ShowAction=t.show=t.ClearAction=t.clear=t.ActionBase=void 0;var i=n(18);Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return i.ActionBase}}),Object.defineProperty(t,"clear",{enumerable:!0,get:function(){return i.clear}}),Object.defineProperty(t,"ClearAction",{enumerable:!0,get:function(){return i.ClearAction}}),Object.defineProperty(t,"show",{enumerable:!0,get:function(){return i.show}}),Object.defineProperty(t,"ShowAction",{enumerable:!0,get:function(){return i.ShowAction}}),Object.defineProperty(t,"FlashAction",{enumerable:!0,get:function(){return i.ToastAction}});var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t}(i.Toast);t.Flash=a,t.create=function(e,t){return new a(e,t)}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(74),t),o(n(76),t)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Features=t.FeaturesAction=void 0;var r=n(19);Object.defineProperty(t,"Features",{enumerable:!0,get:function(){return r.Features}});var o=n(19);Object.defineProperty(t,"FeaturesAction",{enumerable:!0,get:function(){return o.FeaturesAction}}),t.create=function(e,t){return new r.Features(e,t)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Features=void 0;var a=n(0),u=n(2),c=n(1),s=n(35),p=function(e){function t(t,n){return e.call(this,t,c.Group.Features,c.Group.Features,n?n.id:void 0)||this}return o(t,e),t.prototype.dispatch=function(e,t){switch(e){case s.Action.REQUEST:this.dispatchFeaturesAction(s.Action.REQUEST,t)}return this},t.prototype.dispatchFeaturesAction=function(e,t){this.app.dispatch(a.actionWrapper({group:c.Group.Features,type:e,payload:i(i({},t||{}),{id:this.id})}))},t}(u.ActionSet);t.Features=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RequestUpdateOptions=t.RequestOptions=t.Options=t.Action=void 0;var r=n(19);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"RequestOptions",{enumerable:!0,get:function(){return r.RequestOptions}}),Object.defineProperty(t,"RequestUpdateOptions",{enumerable:!0,get:function(){return r.RequestUpdateOptions}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.FeedbackModal=t.close=t.open=t.CloseAction=t.OpenAction=t.ActionBase=t.ClosePayload=t.OpenPayload=t.Options=t.Action=void 0;var r=n(78);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"OpenPayload",{enumerable:!0,get:function(){return r.OpenPayload}}),Object.defineProperty(t,"ClosePayload",{enumerable:!0,get:function(){return r.ClosePayload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return r.ActionBase}}),Object.defineProperty(t,"OpenAction",{enumerable:!0,get:function(){return r.OpenAction}}),Object.defineProperty(t,"CloseAction",{enumerable:!0,get:function(){return r.CloseAction}}),Object.defineProperty(t,"open",{enumerable:!0,get:function(){return r.open}}),Object.defineProperty(t,"close",{enumerable:!0,get:function(){return r.close}}),Object.defineProperty(t,"FeedbackModal",{enumerable:!0,get:function(){return r.FeedbackModal}}),Object.defineProperty(t,"create",{enumerable:!0,get:function(){return r.create}})},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.FeedbackModal=t.close=t.open=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e){return u.actionWrapper({group:s.Group.FeedbackModal,payload:e,type:a.OPEN})}function f(e){return u.actionWrapper({group:s.Group.FeedbackModal,payload:e,type:a.CLOSE})}!function(e){e.OPEN="APP::FEEDBACK_MODAL::OPEN",e.CLOSE="APP::FEEDBACK_MODAL::CLOSE"}(a=t.Action||(t.Action={})),t.open=p,t.close=f;var l=function(e){function t(t,n){var r=e.call(this,t,s.Group.FeedbackModal,s.Group.FeedbackModal)||this;return r.options=n,r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),t.prototype.set=function(e){return this.options=u.getMergedProps(this.options,e),this},t.prototype.dispatch=function(e){switch(e){case a.OPEN:var t=p(this.payload);this.app.dispatch(t);break;case a.CLOSE:var n=f(this.payload);this.app.dispatch(n)}return this},t}(c.ActionSet);t.FeedbackModal=l,t.create=function(e,t){return new l(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Action=t.Fullscreen=t.exit=t.enter=t.FullscreenAction=t.Payload=void 0;var r=n(36);Object.defineProperty(t,"Fullscreen",{enumerable:!0,get:function(){return r.Fullscreen}}),Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}});var o=n(36);Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"FullscreenAction",{enumerable:!0,get:function(){return o.FullscreenAction}}),Object.defineProperty(t,"enter",{enumerable:!0,get:function(){return o.enter}}),Object.defineProperty(t,"exit",{enumerable:!0,get:function(){return o.exit}}),t.create=function(e){return new r.Fullscreen(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.LeaveConfirmation=t.confirm=t.disable=t.enable=t.ConfirmAction=t.DisableAction=t.EnableAction=t.ActionBase=t.Payload=t.Action=void 0;var r=n(37);Object.defineProperty(t,"LeaveConfirmation",{enumerable:!0,get:function(){return r.LeaveConfirmation}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(37);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"EnableAction",{enumerable:!0,get:function(){return o.EnableAction}}),Object.defineProperty(t,"DisableAction",{enumerable:!0,get:function(){return o.DisableAction}}),Object.defineProperty(t,"ConfirmAction",{enumerable:!0,get:function(){return o.ConfirmAction}}),Object.defineProperty(t,"enable",{enumerable:!0,get:function(){return o.enable}}),Object.defineProperty(t,"disable",{enumerable:!0,get:function(){return o.disable}}),Object.defineProperty(t,"confirm",{enumerable:!0,get:function(){return o.confirm}}),t.create=function(e,t){return void 0===t&&(t={}),new r.LeaveConfirmation(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.stop=t.start=t.LoadingAction=t.Payload=t.Action=t.Loading=void 0;var r=n(38);Object.defineProperty(t,"Loading",{enumerable:!0,get:function(){return r.Loading}});var o=n(38);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"LoadingAction",{enumerable:!0,get:function(){return o.LoadingAction}}),Object.defineProperty(t,"start",{enumerable:!0,get:function(){return o.start}}),Object.defineProperty(t,"stop",{enumerable:!0,get:function(){return o.stop}}),t.create=function(e){return new r.Loading(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.ModalContent=t.Options=t.ModalContentPayload=t.Action=void 0;var r=n(40);Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"ModalContent",{enumerable:!0,get:function(){return r.ModalContent}});var o=n(40);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ModalContentPayload",{enumerable:!0,get:function(){return o.ModalContentPayload}}),t.create=function(e,t){return new r.ModalContent(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.replace=t.push=t.HistoryAction=t.Payload=t.Action=t.History=void 0;var r=n(41);Object.defineProperty(t,"History",{enumerable:!0,get:function(){return r.History}});var o=n(41);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"HistoryAction",{enumerable:!0,get:function(){return o.HistoryAction}}),Object.defineProperty(t,"push",{enumerable:!0,get:function(){return o.push}}),Object.defineProperty(t,"replace",{enumerable:!0,get:function(){return o.replace}}),t.create=function(e){return new r.History(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.isProductVariantCreateResourcePayload=t.isProductVariantResourcePayload=t.isCreateResourcePayload=t.isAdminSection=t.isRemotePayload=t.isAdminSectionPayload=t.isAdminPathPayload=t.isAppPayload=t.getRelativePath=t.normalizeUrl=t.getPathWithSearchAndHash=t.toDestination=t.toApp=t.toRemote=t.toAdminSection=t.toAdminPath=t.isResourcePayload=t.Navigate=t.SectionStringName=t.To=t.Options=t.HostOptions=t.AppOptions=t.Location=t.RedirectAction=t.RemoteAction=t.AppAction=t.AdminSectionAction=t.AdminPathAction=t.ActionBase=t.ResourceType=t.Action=t.AdminSectionPayload=t.Section=t.ResourceInfo=t.RemotePayload=t.AdminPathPayload=t.AppPayload=t.BaseAdminPayload=t.BasePayload=t.Redirect=t.ProductVariantResource=t.CreateResource=void 0;var r=n(21);Object.defineProperty(t,"CreateResource",{enumerable:!0,get:function(){return r.CreateResource}}),Object.defineProperty(t,"ProductVariantResource",{enumerable:!0,get:function(){return r.ProductVariantResource}}),Object.defineProperty(t,"Redirect",{enumerable:!0,get:function(){return r.Redirect}}),Object.defineProperty(t,"isCreateResourcePayload",{enumerable:!0,get:function(){return r.isCreateResourcePayload}}),Object.defineProperty(t,"isProductVariantResourcePayload",{enumerable:!0,get:function(){return r.isProductVariantResourcePayload}});var o=n(21);Object.defineProperty(t,"BasePayload",{enumerable:!0,get:function(){return o.BasePayload}}),Object.defineProperty(t,"BaseAdminPayload",{enumerable:!0,get:function(){return o.BaseAdminPayload}}),Object.defineProperty(t,"AppPayload",{enumerable:!0,get:function(){return o.AppPayload}}),Object.defineProperty(t,"AdminPathPayload",{enumerable:!0,get:function(){return o.AdminPathPayload}}),Object.defineProperty(t,"RemotePayload",{enumerable:!0,get:function(){return o.RemotePayload}}),Object.defineProperty(t,"ResourceInfo",{enumerable:!0,get:function(){return o.ResourceInfo}}),Object.defineProperty(t,"Section",{enumerable:!0,get:function(){return o.Section}}),Object.defineProperty(t,"AdminSectionPayload",{enumerable:!0,get:function(){return o.AdminSectionPayload}}),Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ResourceType",{enumerable:!0,get:function(){return o.ResourceType}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"AdminPathAction",{enumerable:!0,get:function(){return o.AdminPathAction}}),Object.defineProperty(t,"AdminSectionAction",{enumerable:!0,get:function(){return o.AdminSectionAction}}),Object.defineProperty(t,"AppAction",{enumerable:!0,get:function(){return o.AppAction}}),Object.defineProperty(t,"RemoteAction",{enumerable:!0,get:function(){return o.RemoteAction}}),Object.defineProperty(t,"RedirectAction",{enumerable:!0,get:function(){return o.RedirectAction}}),Object.defineProperty(t,"Location",{enumerable:!0,get:function(){return o.Location}}),Object.defineProperty(t,"AppOptions",{enumerable:!0,get:function(){return o.AppOptions}}),Object.defineProperty(t,"HostOptions",{enumerable:!0,get:function(){return o.HostOptions}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return o.Options}}),Object.defineProperty(t,"To",{enumerable:!0,get:function(){return o.To}}),Object.defineProperty(t,"SectionStringName",{enumerable:!0,get:function(){return o.SectionStringName}}),Object.defineProperty(t,"Navigate",{enumerable:!0,get:function(){return o.Navigate}}),Object.defineProperty(t,"isResourcePayload",{enumerable:!0,get:function(){return o.isResourcePayload}}),Object.defineProperty(t,"toAdminPath",{enumerable:!0,get:function(){return o.toAdminPath}}),Object.defineProperty(t,"toAdminSection",{enumerable:!0,get:function(){return o.toAdminSection}}),Object.defineProperty(t,"toRemote",{enumerable:!0,get:function(){return o.toRemote}}),Object.defineProperty(t,"toApp",{enumerable:!0,get:function(){return o.toApp}}),Object.defineProperty(t,"toDestination",{enumerable:!0,get:function(){return o.toDestination}}),Object.defineProperty(t,"getPathWithSearchAndHash",{enumerable:!0,get:function(){return o.getPathWithSearchAndHash}}),Object.defineProperty(t,"normalizeUrl",{enumerable:!0,get:function(){return o.normalizeUrl}}),Object.defineProperty(t,"getRelativePath",{enumerable:!0,get:function(){return o.getRelativePath}}),Object.defineProperty(t,"isAppPayload",{enumerable:!0,get:function(){return o.isAppPayload}}),Object.defineProperty(t,"isAdminPathPayload",{enumerable:!0,get:function(){return o.isAdminPathPayload}}),Object.defineProperty(t,"isAdminSectionPayload",{enumerable:!0,get:function(){return o.isAdminSectionPayload}}),Object.defineProperty(t,"isRemotePayload",{enumerable:!0,get:function(){return o.isRemotePayload}}),Object.defineProperty(t,"isAdminSection",{enumerable:!0,get:function(){return o.isAdminSection}}),t.isProductVariantCreateResourcePayload=function(e){return!!r.isProductVariantResourcePayload(e)&&r.isCreateResourcePayload(e.variant)},t.create=function(e){return new r.Redirect(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.BaseOptions=t.ResourcePicker=t.WeightUnit=t.UpdateAction=t.update=t.SelectPayload=t.SelectAction=t.select=t.RuleSet=t.ResourceType=t.ResourceSelection=t.ResourcePickerAction=t.Resource=t.ProductVariantInventoryPolicy=t.ProductVariantInventoryManagement=t.ProductVariant=t.ProductStatus=t.ProductOptions=t.Product=t.Payload=t.Options=t.OpenAction=t.open=t.Money=t.Image=t.FulfillmentServiceType=t.CollectionSortOrder=t.CollectionRule=t.Collection=t.ClosePayload=t.CloseAction=t.close=t.CancelPayload=t.CancelAction=t.cancel=t.BaseResource=t.ActionVerb=t.ActionBase=t.Action=void 0;var r=n(42);Object.defineProperty(t,"ResourcePicker",{enumerable:!0,get:function(){return r.ResourcePicker}}),Object.defineProperty(t,"BaseOptions",{enumerable:!0,get:function(){return r.BaseOptions}});var o=n(42);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"ActionVerb",{enumerable:!0,get:function(){return o.ActionVerb}}),Object.defineProperty(t,"BaseResource",{enumerable:!0,get:function(){return o.BaseResource}}),Object.defineProperty(t,"cancel",{enumerable:!0,get:function(){return o.cancel}}),Object.defineProperty(t,"CancelAction",{enumerable:!0,get:function(){return o.CancelAction}}),Object.defineProperty(t,"CancelPayload",{enumerable:!0,get:function(){return o.CancelPayload}}),Object.defineProperty(t,"close",{enumerable:!0,get:function(){return o.close}}),Object.defineProperty(t,"CloseAction",{enumerable:!0,get:function(){return o.CloseAction}}),Object.defineProperty(t,"ClosePayload",{enumerable:!0,get:function(){return o.ClosePayload}}),Object.defineProperty(t,"Collection",{enumerable:!0,get:function(){return o.Collection}}),Object.defineProperty(t,"CollectionRule",{enumerable:!0,get:function(){return o.CollectionRule}}),Object.defineProperty(t,"CollectionSortOrder",{enumerable:!0,get:function(){return o.CollectionSortOrder}}),Object.defineProperty(t,"FulfillmentServiceType",{enumerable:!0,get:function(){return o.FulfillmentServiceType}}),Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return o.Image}}),Object.defineProperty(t,"Money",{enumerable:!0,get:function(){return o.Money}}),Object.defineProperty(t,"open",{enumerable:!0,get:function(){return o.open}}),Object.defineProperty(t,"OpenAction",{enumerable:!0,get:function(){return o.OpenAction}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return o.Options}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"Product",{enumerable:!0,get:function(){return o.Product}}),Object.defineProperty(t,"ProductOptions",{enumerable:!0,get:function(){return o.ProductOptions}}),Object.defineProperty(t,"ProductStatus",{enumerable:!0,get:function(){return o.ProductStatus}}),Object.defineProperty(t,"ProductVariant",{enumerable:!0,get:function(){return o.ProductVariant}}),Object.defineProperty(t,"ProductVariantInventoryManagement",{enumerable:!0,get:function(){return o.ProductVariantInventoryManagement}}),Object.defineProperty(t,"ProductVariantInventoryPolicy",{enumerable:!0,get:function(){return o.ProductVariantInventoryPolicy}}),Object.defineProperty(t,"Resource",{enumerable:!0,get:function(){return o.Resource}}),Object.defineProperty(t,"ResourcePickerAction",{enumerable:!0,get:function(){return o.ResourcePickerAction}}),Object.defineProperty(t,"ResourceSelection",{enumerable:!0,get:function(){return o.ResourceSelection}}),Object.defineProperty(t,"ResourceType",{enumerable:!0,get:function(){return o.ResourceType}}),Object.defineProperty(t,"RuleSet",{enumerable:!0,get:function(){return o.RuleSet}}),Object.defineProperty(t,"select",{enumerable:!0,get:function(){return o.select}}),Object.defineProperty(t,"SelectAction",{enumerable:!0,get:function(){return o.SelectAction}}),Object.defineProperty(t,"SelectPayload",{enumerable:!0,get:function(){return o.SelectPayload}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),Object.defineProperty(t,"UpdateAction",{enumerable:!0,get:function(){return o.UpdateAction}}),Object.defineProperty(t,"WeightUnit",{enumerable:!0,get:function(){return o.WeightUnit}});t.create=function(e,t){var n=t.resourceType,o=t.options,i=void 0===o?{}:o;return new r.ResourcePicker(e,i,n)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.capture=t.openCamera=t.Scanner=t.Options=t.Payload=t.Data=t.Action=void 0;var r=n(87);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"Data",{enumerable:!0,get:function(){return r.Data}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return r.Payload}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"Scanner",{enumerable:!0,get:function(){return r.Scanner}}),Object.defineProperty(t,"openCamera",{enumerable:!0,get:function(){return r.openCamera}}),Object.defineProperty(t,"capture",{enumerable:!0,get:function(){return r.capture}}),t.create=function(e,t){return new r.Scanner(e,t)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.capture=t.openCamera=t.Scanner=t.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(e){e.OPEN_CAMERA="APP::SCANNER::OPEN::CAMERA",e.CAPTURE="APP::SCANNER::CAPTURE"}(i=t.Action||(t.Action={}));var s=function(e){function t(t,n){return e.call(this,t,c.Group.Scanner,c.Group.Scanner,n?n.id:void 0)||this}return o(t,e),t.prototype.dispatch=function(e){switch(e){case i.OPEN_CAMERA:this.dispatchScannerAction(i.OPEN_CAMERA)}return this},t.prototype.dispatchScannerAction=function(e){this.app.dispatch(a.actionWrapper({type:e,group:c.Group.Scanner,payload:{id:this.id}}))},t}(u.ActionSet);t.Scanner=s,t.openCamera=function(){return a.actionWrapper({group:c.Group.Scanner,type:i.OPEN_CAMERA})},t.capture=function(e){return a.actionWrapper({group:c.Group.Scanner,type:i.CAPTURE,payload:e})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.respond=t.request=t.SessionTokenApi=t.RespondWithSessionTokenAction=t.RequestSessionTokenAction=t.ActionBase=t.Payload=t.Action=void 0;var r=n(43);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return r.Payload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return r.ActionBase}}),Object.defineProperty(t,"RequestSessionTokenAction",{enumerable:!0,get:function(){return r.RequestSessionTokenAction}}),Object.defineProperty(t,"RespondWithSessionTokenAction",{enumerable:!0,get:function(){return r.RespondWithSessionTokenAction}}),Object.defineProperty(t,"SessionTokenApi",{enumerable:!0,get:function(){return r.SessionTokenApi}}),Object.defineProperty(t,"request",{enumerable:!0,get:function(){return r.request}}),Object.defineProperty(t,"respond",{enumerable:!0,get:function(){return r.respond}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.TitleBar=t.Options=t.TitleBarApi=t.UpdatePayload=t.DeepPartial=t.ActionProps=t.Target=t.update=t.clickBreadcrumb=t.clickActionButton=t.TitleBarAction=t.UpdateAction=t.Payload=t.ButtonsPayload=t.ButtonsOptions=t.Breadcrumb=t.Action=void 0;var r=n(44);Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"TitleBar",{enumerable:!0,get:function(){return r.TitleBar}});var o=n(44);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Breadcrumb",{enumerable:!0,get:function(){return o.Breadcrumb}}),Object.defineProperty(t,"ButtonsOptions",{enumerable:!0,get:function(){return o.ButtonsOptions}}),Object.defineProperty(t,"ButtonsPayload",{enumerable:!0,get:function(){return o.ButtonsPayload}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"UpdateAction",{enumerable:!0,get:function(){return o.UpdateAction}}),Object.defineProperty(t,"TitleBarAction",{enumerable:!0,get:function(){return o.TitleBarAction}}),Object.defineProperty(t,"clickActionButton",{enumerable:!0,get:function(){return o.clickActionButton}}),Object.defineProperty(t,"clickBreadcrumb",{enumerable:!0,get:function(){return o.clickBreadcrumb}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),Object.defineProperty(t,"Target",{enumerable:!0,get:function(){return o.Target}}),Object.defineProperty(t,"ActionProps",{enumerable:!0,get:function(){return o.ActionProps}}),Object.defineProperty(t,"DeepPartial",{enumerable:!0,get:function(){return o.DeepPartial}}),Object.defineProperty(t,"UpdatePayload",{enumerable:!0,get:function(){return o.UpdatePayload}}),Object.defineProperty(t,"TitleBarApi",{enumerable:!0,get:function(){return o.TitleBarApi}}),t.create=function(e,t){return new r.TitleBar(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getGroupedButton=void 0;var r=n(10);t.getGroupedButton=function(e,t,n,o){e.addChild(t,e.group,n);var i=t.id,a=t.label,u=t.disabled,c=t.buttons,s=t.plain;return e.subscribeToChild(t,r.Action.UPDATE,o),{id:i,label:a,buttons:c,disabled:u,plain:s}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Toast=t.primaryAction=t.clear=t.show=t.ToastApi=t.ShowPayload=t.ToastAction=t.PrimaryAction=t.ClearAction=t.ShowAction=t.ActionBase=t.Payload=t.ClearPayload=t.Action=void 0;var r=n(18);Object.defineProperty(t,"Toast",{enumerable:!0,get:function(){return r.Toast}});var o=n(18);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ClearPayload",{enumerable:!0,get:function(){return o.ClearPayload}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"ShowAction",{enumerable:!0,get:function(){return o.ShowAction}}),Object.defineProperty(t,"ClearAction",{enumerable:!0,get:function(){return o.ClearAction}}),Object.defineProperty(t,"PrimaryAction",{enumerable:!0,get:function(){return o.PrimaryAction}}),Object.defineProperty(t,"ToastAction",{enumerable:!0,get:function(){return o.ToastAction}}),Object.defineProperty(t,"ShowPayload",{enumerable:!0,get:function(){return o.ShowPayload}}),Object.defineProperty(t,"ToastApi",{enumerable:!0,get:function(){return o.ToastApi}}),Object.defineProperty(t,"show",{enumerable:!0,get:function(){return o.show}}),Object.defineProperty(t,"clear",{enumerable:!0,get:function(){return o.clear}}),Object.defineProperty(t,"primaryAction",{enumerable:!0,get:function(){return o.primaryAction}}),t.create=function(e,t){return new r.Toast(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.ContextualSaveBar=t.update=t.discard=t.save=t.hide=t.show=t.ContextualSaveBarApi=t.DiscardActionOptions=t.SaveActionOptions=t.ShowOptions=t.ContextualSaveBarAction=t.Payload=t.Options=t.DiscardAction=t.ContextAction=t.Action=void 0;var r=n(93);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"ContextAction",{enumerable:!0,get:function(){return r.ContextAction}}),Object.defineProperty(t,"DiscardAction",{enumerable:!0,get:function(){return r.DiscardAction}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return r.Payload}}),Object.defineProperty(t,"ContextualSaveBarAction",{enumerable:!0,get:function(){return r.ContextualSaveBarAction}}),Object.defineProperty(t,"ShowOptions",{enumerable:!0,get:function(){return r.ShowOptions}}),Object.defineProperty(t,"SaveActionOptions",{enumerable:!0,get:function(){return r.SaveActionOptions}}),Object.defineProperty(t,"DiscardActionOptions",{enumerable:!0,get:function(){return r.DiscardActionOptions}}),Object.defineProperty(t,"ContextualSaveBarApi",{enumerable:!0,get:function(){return r.ContextualSaveBarApi}}),Object.defineProperty(t,"show",{enumerable:!0,get:function(){return r.show}}),Object.defineProperty(t,"hide",{enumerable:!0,get:function(){return r.hide}}),Object.defineProperty(t,"save",{enumerable:!0,get:function(){return r.save}}),Object.defineProperty(t,"discard",{enumerable:!0,get:function(){return r.discard}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return r.update}}),Object.defineProperty(t,"ContextualSaveBar",{enumerable:!0,get:function(){return r.ContextualSaveBar}}),t.create=function(e,t){return new r.ContextualSaveBar(e,t)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.ContextualSaveBar=t.update=t.discard=t.save=t.hide=t.show=t.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(e,t){return u.actionWrapper({group:s.Group.ContextualSaveBar,type:e,payload:t})}!function(e){e.DISCARD="APP::CONTEXTUAL_SAVE_BAR::DISCARD",e.SAVE="APP::CONTEXTUAL_SAVE_BAR::SAVE",e.SHOW="APP::CONTEXTUAL_SAVE_BAR::SHOW",e.HIDE="APP::CONTEXTUAL_SAVE_BAR::HIDE",e.UPDATE="APP::CONTEXTUAL_SAVE_BAR::UPDATE"}(a=t.Action||(t.Action={})),t.show=function(e){return p(a.SHOW,e)},t.hide=function(e){return p(a.HIDE,e)},t.save=function(e){return p(a.SAVE,e)},t.discard=function(e){return p(a.DISCARD,e)},t.update=function(e){return p(a.UPDATE,e)};var f=function(e){function t(t,n){void 0===n&&(n={});var r=e.call(this,t,s.Group.ContextualSaveBar,s.Group.ContextualSaveBar)||this;return r.options=n,r.set(n,!1),r}return o(t,e),Object.defineProperty(t.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=u.getMergedProps(this.options,e);return this.options=n,t&&this.dispatch(a.UPDATE),this},t.prototype.dispatch=function(e){return this.app.dispatch(p(e,this.payload)),this},t}(c.ActionSet);t.ContextualSaveBar=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Share=t.close=t.show=t.ShareAction=t.OutputPayload=t.InputPayload=t.UrlPayload=t.TextPayload=t.Action=void 0;var r=n(45);Object.defineProperty(t,"Share",{enumerable:!0,get:function(){return r.Share}});var o=n(45);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"TextPayload",{enumerable:!0,get:function(){return o.TextPayload}}),Object.defineProperty(t,"UrlPayload",{enumerable:!0,get:function(){return o.UrlPayload}}),Object.defineProperty(t,"InputPayload",{enumerable:!0,get:function(){return o.InputPayload}}),Object.defineProperty(t,"OutputPayload",{enumerable:!0,get:function(){return o.OutputPayload}}),Object.defineProperty(t,"ShareAction",{enumerable:!0,get:function(){return o.ShareAction}}),Object.defineProperty(t,"show",{enumerable:!0,get:function(){return o.show}}),Object.defineProperty(t,"close",{enumerable:!0,get:function(){return o.close}}),t.create=function(e){return new r.Share(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.NavigationMenu=t.update=t.NavigationMenuAction=t.MenuAction=t.Payload=t.Action=void 0;var r=n(46);Object.defineProperty(t,"NavigationMenu",{enumerable:!0,get:function(){return r.NavigationMenu}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(46);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"MenuAction",{enumerable:!0,get:function(){return o.MenuAction}}),Object.defineProperty(t,"NavigationMenuAction",{enumerable:!0,get:function(){return o.NavigationMenuAction}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),t.create=function(e,t){return new r.NavigationMenu(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.ChannelMenu=t.update=t.ChannelMenuAction=t.MenuAction=t.Payload=t.Action=void 0;var r=n(47);Object.defineProperty(t,"ChannelMenu",{enumerable:!0,get:function(){return r.ChannelMenu}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(47);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"MenuAction",{enumerable:!0,get:function(){return o.MenuAction}}),Object.defineProperty(t,"ChannelMenuAction",{enumerable:!0,get:function(){return o.ChannelMenuAction}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),t.create=function(e,t){return new r.ChannelMenu(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.AppLink=t.update=t.UpdateAction=t.Payload=t.InternalOptions=t.Action=void 0;var r=n(12);Object.defineProperty(t,"AppLink",{enumerable:!0,get:function(){return r.AppLink}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(12);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"InternalOptions",{enumerable:!0,get:function(){return o.InternalOptions}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"UpdateAction",{enumerable:!0,get:function(){return o.UpdateAction}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),t.create=function(e,t){return new r.AppLink(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Pos=t.close=t.CloseAction=t.Device=t.User=t.Location=t.Action=void 0;var r=n(48);Object.defineProperty(t,"Pos",{enumerable:!0,get:function(){return r.Pos}});var o=n(48);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"Location",{enumerable:!0,get:function(){return o.Location}}),Object.defineProperty(t,"User",{enumerable:!0,get:function(){return o.User}}),Object.defineProperty(t,"Device",{enumerable:!0,get:function(){return o.Device}}),Object.defineProperty(t,"CloseAction",{enumerable:!0,get:function(){return o.CloseAction}}),Object.defineProperty(t,"close",{enumerable:!0,get:function(){return o.close}}),t.create=function(e){return new r.Pos(e)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.MarketingExternalActivityTopBar=t.update=t.clickActionButton=t.MarketingActivityStatusBadgeType=t.Action=void 0;var a=n(100);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return a.Action}});var u=n(33),c=n(101),s=n(3),p=n(102),f=n(4);!function(e){e.Default="DEFAULT",e.Success="SUCCESS",e.Attention="ATTENTION",e.Warning="WARNING",e.Info="INFO"}(t.MarketingActivityStatusBadgeType||(t.MarketingActivityStatusBadgeType={}));var l={group:f.Group.MarketingExternalActivityTopBar,subgroups:["Buttons"]};function d(e){return s.actionWrapper({payload:e,group:f.Group.MarketingExternalActivityTopBar,type:a.Action.UPDATE})}t.clickActionButton=function(e,t){var n=f.ComponentType.Button,r=i({id:e,type:n},l);return u.clickButton(f.Group.MarketingExternalActivityTopBar,r,t)},t.update=d;var h=function(e){function t(t,n){var r=e.call(this,t,f.Group.MarketingExternalActivityTopBar,f.Group.MarketingExternalActivityTopBar)||this;return r.set(n),r}return o(t,e),Object.defineProperty(t.prototype,"buttons",{get:function(){if(this.primary||this.secondary)return{primary:this.primary,secondary:this.secondary}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"buttonsOptions",{get:function(){if(this.primaryOptions||this.secondaryOptions)return{primary:this.primaryOptions,secondary:this.secondaryOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{get:function(){return{title:this.title,status:this.status,saving:this.saving,saved:this.saved,buttons:this.buttonsOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"payload",{get:function(){return i(i({},this.options),{buttons:this.buttons,id:this.id})},enumerable:!1,configurable:!0}),t.prototype.set=function(e,t){void 0===t&&(t=!0);var n=s.getMergedProps(this.options,e),r=n.title,o=n.buttons,i=n.saved,u=n.saving,c=n.status;return this.title=r,this.saving=u,this.saved=i,this.status=c,this.setPrimaryButton(o?o.primary:void 0),this.setSecondaryButtons(o?o.secondary:void 0),t&&this.dispatch(a.Action.UPDATE),this},t.prototype.dispatch=function(e){switch(e){case a.Action.UPDATE:this.app.dispatch(d(this.payload))}return this},t.prototype.getButton=function(e,t,n){return c.getSingleButton(this,e,t,n)},t.prototype.updatePrimaryButton=function(e){this.primary&&s.updateActionFromPayload(this.primary,e)&&this.dispatch(a.Action.UPDATE)},t.prototype.updateSecondaryButtons=function(e){if(this.secondary){var t=this.secondary.find((function(t){return t.id===e.id}));if(t)s.updateActionFromPayload(t,e)&&this.dispatch(a.Action.UPDATE)}},t.prototype.setPrimaryButton=function(e){this.primaryOptions=this.getChildButton(e,this.primaryOptions),this.primary=this.primaryOptions?this.getButton(this.primaryOptions,l.subgroups,this.updatePrimaryButton):void 0},t.prototype.setSecondaryButtons=function(e){var t=this,n=e||[],r=this.secondaryOptions||[];this.secondaryOptions=this.getUpdatedChildActions(n,r),this.secondary=this.secondaryOptions?this.secondaryOptions.map((function(e){return t.getButton(e,l.subgroups,t.updateSecondaryButtons)})):void 0},t.prototype.updateSaving=function(e){this.saving=e,this.dispatch(a.Action.UPDATE)},t.prototype.updateSaved=function(e){this.saved=e,this.dispatch(a.Action.UPDATE)},t.prototype.updateStatus=function(e){this.status=e,this.dispatch(a.Action.UPDATE)},t.prototype.getChildButton=function(e,t){var n=e?[e]:[],r=t?[t]:[],o=this.getUpdatedChildActions(n,r);return o?o[0]:void 0},t}(p.ActionSetWithChildren);t.MarketingExternalActivityTopBar=h,t.create=function(e,t){return new h(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Action=void 0,function(e){e.UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::UPDATE",e.BUTTON_CLICK="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::CLICK",e.BUTTON_UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::UPDATE"}(t.Action||(t.Action={}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSingleButton=void 0;var r=n(11);Object.defineProperty(t,"getSingleButton",{enumerable:!0,get:function(){return r.getSingleButton}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ActionSetChildAction=t.unsubscribeActions=t.ActionSetWithChildren=t.ActionSet=void 0;var r=n(2);Object.defineProperty(t,"ActionSet",{enumerable:!0,get:function(){return r.ActionSet}}),Object.defineProperty(t,"ActionSetWithChildren",{enumerable:!0,get:function(){return r.ActionSetWithChildren}}),Object.defineProperty(t,"unsubscribeActions",{enumerable:!0,get:function(){return r.unsubscribeActions}}),Object.defineProperty(t,"ActionSetChildAction",{enumerable:!0,get:function(){return r.ActionSetChildAction}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.fullPageLoad=t.skeletonPageLoad=t.FullPageLoadAction=t.SkeletonPageLoadAction=t.ActionBase=t.Action=void 0;var r=n(104);Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return r.Action}}),Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return r.ActionBase}}),Object.defineProperty(t,"SkeletonPageLoadAction",{enumerable:!0,get:function(){return r.SkeletonPageLoadAction}}),Object.defineProperty(t,"FullPageLoadAction",{enumerable:!0,get:function(){return r.FullPageLoadAction}}),Object.defineProperty(t,"skeletonPageLoad",{enumerable:!0,get:function(){return r.skeletonPageLoad}}),Object.defineProperty(t,"fullPageLoad",{enumerable:!0,get:function(){return r.fullPageLoad}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.fullPageLoad=t.skeletonPageLoad=t.Action=void 0;var r,o=n(1),i=n(0);!function(e){e.SKELETON_PAGE_LOAD="APP::PERFORMANCE::SKELETON_PAGE_LOAD",e.FULL_PAGE_LOAD="APP::PERFORMANCE::FULL_PAGE_LOAD"}(r=t.Action||(t.Action={})),t.skeletonPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.SKELETON_PAGE_LOAD})},t.fullPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.FULL_PAGE_LOAD})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.create=t.Options=t.unstable_Picker=t.VerticalAlignment=t.UpdateAction=t.update=t.ThumbnailProps=t.SelectPayload=t.SelectEventListener=t.SelectAction=t.select=t.SearchPayload=t.SearchEventListener=t.SearchAction=t.search=t.Resource=t.PickerApi=t.PickerAction=t.Payload=t.OpenAction=t.open=t.MediaKind=t.LoadMorePayload=t.LoadMoreAction=t.loadMore=t.Handlers=t.EventListener=t.EmptySearchLabel=t.CancelPayload=t.CancelAction=t.cancel=t.BaseResource=t.BadgeStatus=t.BadgeProgress=t.Badge=t.AvatarProps=t.ALL_RESOURCE_VERTICAL_ALIGNMENT=t.ALL_MEDIA_KINDS=t.ALL_BADGE_STATUSES=t.ALL_BADGE_PROGRESSES=t.Action=t.ActionBase=void 0;var r=n(49);Object.defineProperty(t,"unstable_Picker",{enumerable:!0,get:function(){return r.unstable_Picker}}),Object.defineProperty(t,"Options",{enumerable:!0,get:function(){return r.Options}});var o=n(49);Object.defineProperty(t,"ActionBase",{enumerable:!0,get:function(){return o.ActionBase}}),Object.defineProperty(t,"Action",{enumerable:!0,get:function(){return o.Action}}),Object.defineProperty(t,"ALL_BADGE_PROGRESSES",{enumerable:!0,get:function(){return o.ALL_BADGE_PROGRESSES}}),Object.defineProperty(t,"ALL_BADGE_STATUSES",{enumerable:!0,get:function(){return o.ALL_BADGE_STATUSES}}),Object.defineProperty(t,"ALL_MEDIA_KINDS",{enumerable:!0,get:function(){return o.ALL_MEDIA_KINDS}}),Object.defineProperty(t,"ALL_RESOURCE_VERTICAL_ALIGNMENT",{enumerable:!0,get:function(){return o.ALL_RESOURCE_VERTICAL_ALIGNMENT}}),Object.defineProperty(t,"AvatarProps",{enumerable:!0,get:function(){return o.AvatarProps}}),Object.defineProperty(t,"Badge",{enumerable:!0,get:function(){return o.Badge}}),Object.defineProperty(t,"BadgeProgress",{enumerable:!0,get:function(){return o.BadgeProgress}}),Object.defineProperty(t,"BadgeStatus",{enumerable:!0,get:function(){return o.BadgeStatus}}),Object.defineProperty(t,"BaseResource",{enumerable:!0,get:function(){return o.BaseResource}}),Object.defineProperty(t,"cancel",{enumerable:!0,get:function(){return o.cancel}}),Object.defineProperty(t,"CancelAction",{enumerable:!0,get:function(){return o.CancelAction}}),Object.defineProperty(t,"CancelPayload",{enumerable:!0,get:function(){return o.CancelPayload}}),Object.defineProperty(t,"EmptySearchLabel",{enumerable:!0,get:function(){return o.EmptySearchLabel}}),Object.defineProperty(t,"EventListener",{enumerable:!0,get:function(){return o.EventListener}}),Object.defineProperty(t,"Handlers",{enumerable:!0,get:function(){return o.Handlers}}),Object.defineProperty(t,"loadMore",{enumerable:!0,get:function(){return o.loadMore}}),Object.defineProperty(t,"LoadMoreAction",{enumerable:!0,get:function(){return o.LoadMoreAction}}),Object.defineProperty(t,"LoadMorePayload",{enumerable:!0,get:function(){return o.LoadMorePayload}}),Object.defineProperty(t,"MediaKind",{enumerable:!0,get:function(){return o.MediaKind}}),Object.defineProperty(t,"open",{enumerable:!0,get:function(){return o.open}}),Object.defineProperty(t,"OpenAction",{enumerable:!0,get:function(){return o.OpenAction}}),Object.defineProperty(t,"Payload",{enumerable:!0,get:function(){return o.Payload}}),Object.defineProperty(t,"PickerAction",{enumerable:!0,get:function(){return o.PickerAction}}),Object.defineProperty(t,"PickerApi",{enumerable:!0,get:function(){return o.PickerApi}}),Object.defineProperty(t,"Resource",{enumerable:!0,get:function(){return o.Resource}}),Object.defineProperty(t,"search",{enumerable:!0,get:function(){return o.search}}),Object.defineProperty(t,"SearchAction",{enumerable:!0,get:function(){return o.SearchAction}}),Object.defineProperty(t,"SearchEventListener",{enumerable:!0,get:function(){return o.SearchEventListener}}),Object.defineProperty(t,"SearchPayload",{enumerable:!0,get:function(){return o.SearchPayload}}),Object.defineProperty(t,"select",{enumerable:!0,get:function(){return o.select}}),Object.defineProperty(t,"SelectAction",{enumerable:!0,get:function(){return o.SelectAction}}),Object.defineProperty(t,"SelectEventListener",{enumerable:!0,get:function(){return o.SelectEventListener}}),Object.defineProperty(t,"SelectPayload",{enumerable:!0,get:function(){return o.SelectPayload}}),Object.defineProperty(t,"ThumbnailProps",{enumerable:!0,get:function(){return o.ThumbnailProps}}),Object.defineProperty(t,"update",{enumerable:!0,get:function(){return o.update}}),Object.defineProperty(t,"UpdateAction",{enumerable:!0,get:function(){return o.UpdateAction}}),Object.defineProperty(t,"VerticalAlignment",{enumerable:!0,get:function(){return o.VerticalAlignment}});t.create=function(e,t){return new r.unstable_Picker(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isFromApp=t.isPerformanceOrWebVitalsAction=t.getPermissionKey=t.isPermitted=t.isAppMessage=t.isAppBridgeAction=void 0;var r=n(25);Object.defineProperty(t,"isAppBridgeAction",{enumerable:!0,get:function(){return r.isAppBridgeAction}}),Object.defineProperty(t,"isAppMessage",{enumerable:!0,get:function(){return r.isAppMessage}}),Object.defineProperty(t,"isPermitted",{enumerable:!0,get:function(){return r.isPermitted}}),Object.defineProperty(t,"getPermissionKey",{enumerable:!0,get:function(){return r.getPermissionKey}}),Object.defineProperty(t,"isPerformanceOrWebVitalsAction",{enumerable:!0,get:function(){return r.isPerformanceOrWebVitalsAction}}),t.isFromApp=function(e){return"object"==typeof e&&"object"==typeof e.source&&"string"==typeof e.source.apiKey}},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.compatibilityCreateApp=t.setClientInterfaceHook=void 0;var o=r(n(108)),i=n(8);t.setClientInterfaceHook=function(e){return function(t){return t.clientInterface.name="@shopify/app-bridge [CDN Compatibility]",e(t)}},t.compatibilityCreateApp=function(e,n){var r=n(i.isV1Config(e)?function(e){var t=e.shopOrigin+"/admin",n=o.default(t);return{apiKey:e.apiKey,host:n,forceRedirect:e.forceRedirect}}(e):e);return i.isV1Config(e)&&r.hooks.set(i.LifecycleHook.DispatchAction,t.setClientInterfaceHook),r}},function(e,t,n){e.exports=n(109).default,e.exports.default=e.exports},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});var r=n(114);function o(t,n){return void 0===n&&(n="utf8"),e.isBuffer(t)?a(t.toString("base64")):a(e.from(t,n).toString("base64"))}function i(e){return e=e.toString(),r.default(e).replace(/\-/g,"+").replace(/_/g,"/")}function a(e){return e.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}var u=o;u.encode=o,u.decode=function(t,n){return void 0===n&&(n="utf8"),e.from(i(t),"base64").toString(n)},u.toBase64=i,u.fromBase64=a,u.toBuffer=function(t){return e.from(i(t),"base64")},t.default=u}).call(this,n(50).Buffer)},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";t.byteLength=function(e){var t=s(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=s(e),a=r[0],u=r[1],c=new i(function(e,t,n){return 3*(t+n)/4-n}(0,a,u)),p=0,f=u>0?a-4:a;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],c[p++]=t>>16&255,c[p++]=t>>8&255,c[p++]=255&t;2===u&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,c[p++]=255&t);1===u&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,c[p++]=t>>8&255,c[p++]=255&t);return c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=0,u=n-o;a<u;a+=16383)i.push(p(e,a,a+16383>u?u:a+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u=0,c=a.length;u<c;++u)r[u]=a[u],o[a.charCodeAt(u)]=u;function s(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function p(e,t,n){for(var o,i,a=[],u=t;u<n;u+=3)o=(e[u]<<16&16711680)+(e[u+1]<<8&65280)+(255&e[u+2]),a.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){
9
+ /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
10
+ t.read=function(e,t,n,r,o){var i,a,u=8*o-r-1,c=(1<<u)-1,s=c>>1,p=-7,f=n?o-1:0,l=n?-1:1,d=e[t+f];for(f+=l,i=d&(1<<-p)-1,d>>=-p,p+=u;p>0;i=256*i+e[t+f],f+=l,p-=8);for(a=i&(1<<-p)-1,i>>=-p,p+=r;p>0;a=256*a+e[t+f],f+=l,p-=8);if(0===i)i=1-s;else{if(i===c)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,r),i-=s}return(d?-1:1)*a*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var a,u,c,s=8*i-o-1,p=(1<<s)-1,f=p>>1,l=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,d=r?0:i-1,h=r?1:-1,y=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(u=isNaN(t)?1:0,a=p):(a=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-a))<1&&(a--,c*=2),(t+=a+f>=1?l/c:l*Math.pow(2,1-f))*c>=2&&(a++,c/=2),a+f>=p?(u=0,a=p):a+f>=1?(u=(t*c-1)*Math.pow(2,o),a+=f):(u=t*Math.pow(2,f-1)*Math.pow(2,o),a=0));o>=8;e[n+d]=255&u,d+=h,u/=256,o-=8);for(a=a<<o|u,s+=o;s>0;e[n+d]=255&a,d+=h,a/=256,s-=8);e[n+d-h]|=128*y}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t){var n=t.length,r=n%4;if(!r)return t;var o=n,i=4-r,a=n+i,u=e.alloc(a);for(u.write(t);i--;)u.write("=",o++);return u.toString()}}).call(this,n(50).Buffer)},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(8);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return i.createApp}}),o(n(13),t),o(n(8),t)},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(117),t),o(n(17),t),o(n(118),t),o(n(120),t)},function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.createMutationObserver=t.setupModalAutoSizing=void 0;var i=n(39),a=n(13),u=n(17),c="app-bridge-utils-modal-auto-size",s=function(){if("undefined"==typeof document)return null;var e=document.createElement("style");return e.type="text/css",e.innerHTML="."+c+" { overflow: hidden; height: auto; min-height: auto; }",e}();function p(e,t){if("undefined"!=typeof document){var n,r=-1,o=new MutationObserver((function(){n&&window.clearTimeout(n);n=window.setTimeout(a,16)}));return o.observe(document,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}),a(),o}function a(){var n=document.body.scrollHeight;n!==r&&(r=n,e.dispatch(i.updateModalSize({id:t,height:String(n)})))}}t.setupModalAutoSizing=function(e){return r(this,void 0,void 0,(function(){function t(){r&&(r(),r=void 0)}function n(n){var o=n.context,i=n.modal.id;return u.isMobile()||o!==a.Context.Modal?(t(),t):(r||(r=function(e,t){if(!s)return function(){};var n=document.getElementsByTagName("head")[0],r=document.body.classList;n.appendChild(s),r.add(c);var o=p(e,t);return function(){r.remove(c),n.contains(s)&&n.removeChild(s),o&&o.disconnect()}}(e,i)),t)}var r;return o(this,(function(r){switch(r.label){case 0:return[4,e.getState().then(n)];case 1:return r.sent(),[2,t]}}))}))},t.createMutationObserver=p},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(51),t),o(n(119),t)},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},i=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.authenticatedFetch=void 0;var a=n(30),u=n(51);t.authenticatedFetch=function(e,t){var n=this;return void 0===t&&(t=void 0),function(c,s){return void 0===s&&(s={}),o(n,void 0,void 0,(function(){var n,o,p,f,l,d,h,y;return i(this,(function(i){switch(i.label){case 0:return[4,u.getSessionToken(e)];case 1:return n=i.sent(),(o=new Headers(s.headers)).append("Authorization","Bearer "+n),o.append("X-Requested-With","XMLHttpRequest"),p={},o.forEach((function(e,t){p[t]=e})),f="object"==typeof t?t:void 0,[4,("function"==typeof t?t:null!==(y=null==f?void 0:f.fetchOperation)&&void 0!==y?y:fetch)(c,r(r({},s),{headers:p}))];case 2:return l=i.sent(),f&&(d=f.reauthorizeUrl,h=f.requestFailureReauthorizeUrlHeader,l.headers.forEach((function(t,n){if(h.toLowerCase()===n.toLowerCase()){var r=new URL(d||t,location.href).href,o=a.Redirect.create(e);r?o.dispatch(a.Redirect.Action.REMOTE,r):console.warn("Couldn't find a fallback auth path to redirect to.")}}))),[2,l]}}))}))}}},function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),o(n(52),t),o(n(122),t)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateUuid=void 0;var r=n(34);Object.defineProperty(t,"generateUuid",{enumerable:!0,get:function(){return r.generateUuid}}),t.default=r.generateUuid},function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function u(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,u)}c((r=r.apply(e,t||[])).next())}))},o=this&&this.__generator||function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}};Object.defineProperty(t,"__esModule",{value:!0}),t.userAuthorizedFetch=void 0;var i=n(52);function a(e){var t=e.headers.get("X-Shopify-API-Request-Failure-Unauthorized");return!!t&&"true"===t.toLowerCase()}t.userAuthorizedFetch=function(e){var t=this,n=e.app,u=e.callbackUri,c=void 0===u?"auth/shopify/callback":u,s=e.isAuthorizationCodeRequired,p=void 0===s?a:s,f=e.fetchOperation;return function(e,a){return r(t,void 0,void 0,(function(){var t,r,u,s,l,d,h;return o(this,(function(o){switch(o.label){case 0:return[4,f(e,a)];case 1:return t=o.sent(),p(t)?[4,i.getAuthorizationCodePayload(n)]:[2,t];case 2:return r=o.sent(),u=r.code,s=r.hmac,l=r.shop,d=r.timestamp,h=encodeURI("https://"+window.location.hostname+"/"+c+"?code="+u+"&hmac="+s+"&shop="+l+"&timestamp="+d),[4,f(h,{})];case 3:if(!o.sent().ok)throw new Error("Failed to authorize request.");return[2,f(e,a)]}}))}))}}}])}));
@@ -1,4 +1,4 @@
1
- //= require ./app_bridge_3.1.1.js
1
+ //= require ./app_bridge_3.7.8.js
2
2
 
3
3
  (function(window) {
4
4
  function appBridgeRedirect(url) {
@@ -19,4 +19,4 @@
19
19
  }
20
20
 
21
21
  window.appBridgeRedirect = appBridgeRedirect;
22
- })(window);
22
+ })(window);
@@ -1,5 +1,4 @@
1
1
  //= require ./app_bridge_redirect.js
2
- //= require ./app_bridge_utils_3.1.1.js
3
2
 
4
3
  (function () {
5
4
  function redirect() {
@@ -11,7 +10,7 @@
11
10
 
12
11
  var targetInfo = JSON.parse(redirectTargetElement.dataset.target);
13
12
 
14
- var appBridgeUtils = window['app-bridge-utils'];
13
+ var appBridgeUtils = window['app-bridge']['utilities'];
15
14
 
16
15
  if (appBridgeUtils.isShopifyEmbedded()) {
17
16
  window.appBridgeRedirect(targetInfo.url);