@shopify/app-bridge-react 3.5.1-alpha.0 → 3.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +2 -2
  2. package/umd/index.js +1 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shopify/app-bridge-react",
3
- "version": "3.5.1-alpha.0",
3
+ "version": "3.5.1",
4
4
  "types": "index.d.ts",
5
5
  "main": "index.js",
6
6
  "unpkg": "umd/index.js",
@@ -45,7 +45,7 @@
45
45
  }
46
46
  ],
47
47
  "dependencies": {
48
- "@shopify/app-bridge": "^3.5.1-alpha.0"
48
+ "@shopify/app-bridge": "^3.5.1"
49
49
  },
50
50
  "devDependencies": {
51
51
  "@shopify/react-testing": "^4.1.1",
package/umd/index.js CHANGED
@@ -7,4 +7,4 @@
7
7
  *
8
8
  * This source code is licensed under the MIT license found in the
9
9
  * LICENSE file in the root directory of this source tree.
10
- */var r=Symbol.for("react.element"),o=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),s=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),h=Symbol.iterator;var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,A={};function b(t,e,n){this.props=t,this.context=e,this.refs=A,this.updater=n||y}function _(){}function P(t,e,n){this.props=t,this.context=e,this.refs=A,this.updater=n||y}b.prototype.isReactComponent={},b.prototype.setState=function(t,e){if("object"!=typeof t&&"function"!=typeof t&&null!=t)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")},b.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")},_.prototype=b.prototype;var O=P.prototype=new _;O.constructor=P,v(O,b.prototype),O.isPureReactComponent=!0;var E=Array.isArray,g=Object.prototype.hasOwnProperty,T={current:null},m={key:!0,ref:!0,__self:!0,__source:!0};function S(t,e,n){var o,i={},a=null,u=null;if(null!=e)for(o in void 0!==e.ref&&(u=e.ref),void 0!==e.key&&(a=""+e.key),e)g.call(e,o)&&!m.hasOwnProperty(o)&&(i[o]=e[o]);var c=arguments.length-2;if(1===c)i.children=n;else if(1<c){for(var s=Array(c),p=0;p<c;p++)s[p]=arguments[p+2];i.children=s}if(t&&t.defaultProps)for(o in c=t.defaultProps)void 0===i[o]&&(i[o]=c[o]);return{$$typeof:r,type:t,key:a,ref:u,props:i,_owner:T.current}}function C(t){return"object"==typeof t&&null!==t&&t.$$typeof===r}var I=/\/+/g;function R(t,e){return"object"==typeof t&&null!==t&&null!=t.key?function(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,(function(t){return e[t]}))}(""+t.key):e.toString(36)}function M(t,e,n,i,a){var u=typeof t;"undefined"!==u&&"boolean"!==u||(t=null);var c=!1;if(null===t)c=!0;else switch(u){case"string":case"number":c=!0;break;case"object":switch(t.$$typeof){case r:case o:c=!0}}if(c)return a=a(c=t),t=""===i?"."+R(c,0):i,E(a)?(n="",null!=t&&(n=t.replace(I,"$&/")+"/"),M(a,e,n,"",(function(t){return t}))):null!=a&&(C(a)&&(a=function(t,e){return{$$typeof:r,type:t.type,key:e,ref:t.ref,props:t.props,_owner:t._owner}}(a,n+(!a.key||c&&c.key===a.key?"":(""+a.key).replace(I,"$&/")+"/")+t)),e.push(a)),1;if(c=0,i=""===i?".":i+":",E(t))for(var s=0;s<t.length;s++){var p=i+R(u=t[s],s);c+=M(u,e,n,p,a)}else if("function"==typeof(p=function(t){return null===t||"object"!=typeof t?null:"function"==typeof(t=h&&t[h]||t["@@iterator"])?t:null}(t)))for(t=p.call(t),s=0;!(u=t.next()).done;)c+=M(u=u.value,e,n,p=i+R(u,s++),a);else if("object"===u)throw e=String(t),Error("Objects are not valid as a React child (found: "+("[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.");return c}function N(t,e,n){if(null==t)return t;var r=[],o=0;return M(t,r,"","",(function(t){return e.call(n,t,o++)})),r}function j(t){if(-1===t._status){var e=t._result;(e=e()).then((function(e){0!==t._status&&-1!==t._status||(t._status=1,t._result=e)}),(function(e){0!==t._status&&-1!==t._status||(t._status=2,t._result=e)})),-1===t._status&&(t._status=0,t._result=e)}if(1===t._status)return t._result.default;throw t._result}var w={current:null},D={transition:null},L={ReactCurrentDispatcher:w,ReactCurrentBatchConfig:D,ReactCurrentOwner:T};e.Children={map:N,forEach:function(t,e,n){N(t,(function(){e.apply(this,arguments)}),n)},count:function(t){var e=0;return N(t,(function(){e++})),e},toArray:function(t){return N(t,(function(t){return t}))||[]},only:function(t){if(!C(t))throw Error("React.Children.only expected to receive a single React element child.");return t}},e.Component=b,e.Fragment=i,e.Profiler=u,e.PureComponent=P,e.StrictMode=a,e.Suspense=l,e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=L,e.cloneElement=function(t,e,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=v({},t.props),i=t.key,a=t.ref,u=t._owner;if(null!=e){if(void 0!==e.ref&&(a=e.ref,u=T.current),void 0!==e.key&&(i=""+e.key),t.type&&t.type.defaultProps)var c=t.type.defaultProps;for(s in e)g.call(e,s)&&!m.hasOwnProperty(s)&&(o[s]=void 0===e[s]&&void 0!==c?c[s]:e[s])}var s=arguments.length-2;if(1===s)o.children=n;else if(1<s){c=Array(s);for(var p=0;p<s;p++)c[p]=arguments[p+2];o.children=c}return{$$typeof:r,type:t.type,key:i,ref:a,props:o,_owner:u}},e.createContext=function(t){return(t={$$typeof:s,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:c,_context:t},t.Consumer=t},e.createElement=S,e.createFactory=function(t){var e=S.bind(null,t);return e.type=t,e},e.createRef=function(){return{current:null}},e.forwardRef=function(t){return{$$typeof:p,render:t}},e.isValidElement=C,e.lazy=function(t){return{$$typeof:d,_payload:{_status:-1,_result:t},_init:j}},e.memo=function(t,e){return{$$typeof:f,type:t,compare:void 0===e?null:e}},e.startTransition=function(t){var e=D.transition;D.transition={};try{t()}finally{D.transition=e}},e.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},e.useCallback=function(t,e){return w.current.useCallback(t,e)},e.useContext=function(t){return w.current.useContext(t)},e.useDebugValue=function(){},e.useDeferredValue=function(t){return w.current.useDeferredValue(t)},e.useEffect=function(t,e){return w.current.useEffect(t,e)},e.useId=function(){return w.current.useId()},e.useImperativeHandle=function(t,e,n){return w.current.useImperativeHandle(t,e,n)},e.useInsertionEffect=function(t,e){return w.current.useInsertionEffect(t,e)},e.useLayoutEffect=function(t,e){return w.current.useLayoutEffect(t,e)},e.useMemo=function(t,e){return w.current.useMemo(t,e)},e.useReducer=function(t,e,n){return w.current.useReducer(t,e,n)},e.useRef=function(t){return w.current.useRef(t)},e.useState=function(t){return w.current.useState(t)},e.useSyncExternalStore=function(t,e,n){return w.current.useSyncExternalStore(t,e,n)},e.useTransition=function(){return w.current.useTransition()},e.version="18.2.0"},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)},i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.unstable_Picker=e.ToastProps=e.Toast=e.TitleBar=e.ResourcePickerProps=e.ResourcePicker=e.ProviderProps=e.Provider=e.NavigationMenuProps=e.NavigationMenu=e.ModalContent=e.ModalProps=e.Modal=e.Loading=e.ContextualSaveBarProps=e.ContextualSaveBar=void 0;var a=n(53);Object.defineProperty(e,"ContextualSaveBar",{enumerable:!0,get:function(){return i(a).default}}),Object.defineProperty(e,"ContextualSaveBarProps",{enumerable:!0,get:function(){return a.Props}});var u=n(93);Object.defineProperty(e,"Loading",{enumerable:!0,get:function(){return i(u).default}});var c=n(95);Object.defineProperty(e,"Modal",{enumerable:!0,get:function(){return i(c).default}}),Object.defineProperty(e,"ModalProps",{enumerable:!0,get:function(){return c.Props}}),Object.defineProperty(e,"ModalContent",{enumerable:!0,get:function(){return c.ModalContent}});var s=n(98);Object.defineProperty(e,"NavigationMenu",{enumerable:!0,get:function(){return i(s).default}}),Object.defineProperty(e,"NavigationMenuProps",{enumerable:!0,get:function(){return s.Props}});var p=n(99);Object.defineProperty(e,"Provider",{enumerable:!0,get:function(){return i(p).default}}),Object.defineProperty(e,"ProviderProps",{enumerable:!0,get:function(){return p.Props}});var l=n(111);Object.defineProperty(e,"ResourcePicker",{enumerable:!0,get:function(){return i(l).default}}),Object.defineProperty(e,"ResourcePickerProps",{enumerable:!0,get:function(){return l.Props}});var f=n(112);Object.defineProperty(e,"TitleBar",{enumerable:!0,get:function(){return i(f).default}});var d=n(113);Object.defineProperty(e,"Toast",{enumerable:!0,get:function(){return i(d).default}}),Object.defineProperty(e,"ToastProps",{enumerable:!0,get:function(){return d.Props}});var h=n(114);Object.defineProperty(e,"unstable_Picker",{enumerable:!0,get:function(){return i(h).default}}),o(n(45),e),o(n(44),e)},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),i=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&r(e,t,n);return o(e,t),e};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var a=i(n(54));Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return a.Props}}),e.default=a.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(22);e.default=function(t){var e=t.discardAction,n=void 0===e?{}:e,i=t.saveAction,a=void 0===i?{}:i,u=t.fullWidth,c=t.leaveConfirmationDisable,s=t.visible,p=o.useContextualSaveBar(),l=p.show,f=p.hide,d=p.saveAction.setOptions,h=p.discardAction.setOptions;return r.useEffect((function(){d(a)}),[a]),r.useEffect((function(){h(n)}),[n]),r.useEffect((function(){s?l({fullWidth:u,leaveConfirmationDisable:c}):f()}),[u,c,s]),null}},function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},o=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.useAppBridgeState=void 0;var i=n(3),a=n(4);e.useAppBridgeState=function(t){var e=a.useAppBridge(),n=i.useState(),u=n[0],c=n[1],s=i.useRef(!1),p=i.useCallback((function(){return r(void 0,void 0,void 0,(function(){var n,r;return o(this,(function(o){switch(o.label){case 0:return t?[4,e.getState(t)]:[3,2];case 1:return r=o.sent(),[3,4];case 2:return[4,e.getState()];case 3:r=o.sent(),o.label=4;case 4:return n=r,s.current?[2]:(c((function(t){return JSON.stringify(n)===JSON.stringify(t)?t:n})),[2])}}))}))}),[e,t]);return i.useEffect((function(){return p(),e.subscribe((function(){p()}))}),[e,p]),i.useEffect((function(){return function(){s.current=!0}}),[e]),u}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useContextualSaveBar=void 0;var r=n(57);Object.defineProperty(e,"useContextualSaveBar",{enumerable:!0,get:function(){return r.useContextualSaveBar}})},function(t,e,n){"use strict";var r=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n};Object.defineProperty(e,"__esModule",{value:!0}),e.useContextualSaveBar=void 0;var o=n(3),i=n(24),a=n(4);e.useContextualSaveBar=function(){var t=a.useAppBridge(),e=o.useRef(!1),n=o.useState(),u=n[0],c=n[1],s=o.useState(),p=s[0],l=s[1],f=o.useMemo((function(){return i.create(t)}),[t]),d=o.useCallback((function(t){t&&f.set(t,!1),f.dispatch(i.Action.SHOW),e.current=!0}),[f]),h=o.useCallback((function(){f.dispatch(i.Action.HIDE),e.current=!1}),[f]),y=o.useMemo((function(){return{setOptions:function(t){var n=t.onAction,o=r(t,["onAction"]),i=JSON.stringify(f.options.saveAction)!==JSON.stringify(o)&&e.current;c((function(){return n})),f.set({saveAction:o},i)}}}),[f]),v=o.useMemo((function(){return{setOptions:function(t){var n=t.onAction,o=r(t,["onAction"]),i=JSON.stringify(f.options.discardAction)!==JSON.stringify(o)&&e.current;l((function(){return n})),f.set({discardAction:o},i)}}}),[f]);return o.useEffect((function(){return function(){e.current&&h()}}),[]),o.useEffect((function(){return f.subscribe(i.Action.DISCARD,(function(){f.dispatch(i.Action.HIDE),null==p||p()}))}),[f,p]),o.useEffect((function(){return f.subscribe(i.Action.SAVE,(function(){f.dispatch(i.Action.HIDE),null==u||u()}))}),[f,u]),{show:d,hide:h,saveAction:y,discardAction:v}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function t(e,n){if(null==n)return n;if(void 0===e||!Object.prototype.isPrototypeOf.call(Object.getPrototypeOf(e),n)||"Object"!==n.constructor.name&&"Array"!==n.constructor.name)return n;var r={};return Object.keys(n).forEach((function(o){Object.prototype.hasOwnProperty.call(e,o)?"object"!=typeof e[o]||Array.isArray(e[o])?r[o]=n[o]:r[o]=t(e[o],n[o]):r[o]=n[o]})),Object.keys(e).forEach((function(t){Object.prototype.hasOwnProperty.call(n,t)||(r[t]=e[t])})),Object.setPrototypeOf(r,Object.getPrototypeOf(e)),r}},function(t){t.exports=JSON.parse('{"name":"@shopify/app-bridge","version":"3.5.1-alpha.0","types":"index.d.ts","main":"index.js","unpkg":"umd/index.js","jsdelivr":"umd/index.js","files":["/actions/","/client/","/umd/","/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":"cat package.json | node -pe \\"JSON.parse(require(\'fs\').readFileSync(\'/dev/stdin\').toString()).files.map(f => \'./\'+f).join(\' \')\\" | xargs rm -rf","pack":"yarn pack","size":"size-limit"},"sideEffects":false,"size-limit":[{"limit":"10 KB","path":"production.js"}],"dependencies":{"base64url":"^3.0.1","web-vitals":"^3.0.1"},"devDependencies":{"@types/node":"^10.12.5","shx":"^0.3.3"}}')},function(t,e,n){"use strict";function r(t){return Array.from(t).map((function(t){return("00"+t.toString(16)).slice(-2)})).join("")}function o(t){if("function"==typeof Uint8Array&&"object"==typeof window&&window.crypto){var e=new Uint8Array(t),n=window.crypto.getRandomValues(e);if(n)return n}return Array.from(new Array(t),(function(){return 255*Math.random()|0}))}function i(){var t=o(1),e=o(2);return t[0]&=191,e[0]&=79,[r(o(4)),"-",r(o(2)),"-",r(e),"-",r(t),r(o(1)),"-",r(o(6))].join("")}Object.defineProperty(e,"__esModule",{value:!0}),e.generateUuid=void 0,e.generateUuid=i,e.default=i},function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},o=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.useFeaturesAvailable=void 0;var i=n(3),a=n(16),u=n(4);e.useFeaturesAvailable=function(){for(var t=this,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var c=u.useAppBridge(),s=i.useState(),p=s[0],l=s[1],f=i.useRef([]),d=i.useCallback((function(){var e=!1;return r(t,void 0,void 0,(function(){var t;return o(this,(function(n){switch(n.label){case 0:return[4,c.featuresAvailable.apply(c,f.current)];case 1:return t=n.sent(),e||l((function(e){return JSON.stringify(e)===JSON.stringify(t)?e:t})),[2]}}))})),function(){e=!0}}),[c]);return i.useEffect((function(){return f.current=e,d()}),[JSON.stringify(e)]),i.useEffect((function(){var t,e=c.subscribe(a.Action.UPDATE,(function(){t=d()}));return function(){e(),null==t||t()}}),[c,d]),p}},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),o(n(63),e)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useFeatureRequest=void 0;var r=n(3),o=n(27),i=n(4),a=n(26);e.useFeatureRequest=function(t,e){var n=i.useAppBridge(),u=a.useFeaturesAvailable(),c=r.useState(),s=c[0],p=c[1],l=r.useCallback((function(n){var r=null==n?void 0:n[t];if(e&&(null==r?void 0:r[e])){var o=null==r?void 0:r[e];p((function(t){return JSON.stringify(o)!==JSON.stringify(t)?o:t}))}else p((function(t){return JSON.stringify(r)!==JSON.stringify(t)?r:t}))}),[t,e]);return r.useEffect((function(){o.create(n).dispatch(o.Action.REQUEST,{feature:t,action:e})}),[n,t,e]),r.useEffect((function(){l(u)}),[u,l]),s}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Features=void 0;var a=n(0),u=n(2),c=n(1),s=n(16),p=function(t){function e(e,n){return t.call(this,e,c.Group.Features,c.Group.Features,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case s.Action.REQUEST:this.dispatchFeaturesAction(s.Action.REQUEST,e)}return this},e.prototype.dispatchFeaturesAction=function(t,e){this.app.dispatch(a.actionWrapper({group:c.Group.Features,type:t,payload:i(i({},e||{}),{id:this.id})}))},e}(u.ActionSet);e.Features=p,e.create=function(t,e){return new p(t,e)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useLocale=void 0;var r=n(66);Object.defineProperty(e,"useLocale",{enumerable:!0,get:function(){return r.useLocale}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useLocale=void 0;var r=n(23);e.useLocale=function(){return r.useAppBridgeState("staffMember.locale")}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigate=void 0;var r=n(68);Object.defineProperty(e,"useNavigate",{enumerable:!0,get:function(){return r.useNavigate}})},function(t,e,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigate=void 0;var o=n(3),i=n(11),a=n(4),u=n(28);e.useNavigate=function(){var t=a.useAppBridge(),e=u.useNavigationHistory(),n=o.useMemo((function(){return i.create(t)}),[t]),c=o.useCallback((function(r,o){var a=i.normalizeUrl(r),u=a.startsWith(t.localOrigin),c=a.startsWith(t.hostOrigin),s=a.startsWith("/");if(u||c||s){var p=i.getRelativePath(a);return c||"new"===(null==o?void 0:o.target)||"host"===(null==o?void 0:o.target)?void n.dispatch(i.Action.ADMIN_PATH,{path:p.replace(/^\/admin/,""),newContext:"new"===(null==o?void 0:o.target)}):"self"!==(null==o?void 0:o.target)&&(null==o?void 0:o.target)||!(null==o?void 0:o.replace)?void n.dispatch(i.Action.APP,p):void e.replace({pathname:p})}n.dispatch(i.Action.REMOTE,{url:a,newContext:"new"===(null==o?void 0:o.target)})}),[n,e]);return o.useCallback((function(t,e){if(i.isAdminSection(t)){var o=r(r({},t),{name:i.ResourceType[t.name]});n.dispatch(i.Action.ADMIN_SECTION,{section:o,newContext:"new"===(null==e?void 0:e.target)})}else c(t,e)}),[c,n])}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigationHistory=void 0;var r=n(3),o=n(7),i=n(4);e.useNavigationHistory=function(){var t=i.useAppBridge();return r.useMemo((function(){var e=o.History.create(t);return{push:function(t){e.dispatch(o.History.Action.PUSH,t.pathname)},replace:function(t){e.dispatch(o.History.Action.REPLACE,t.pathname)}}}),[])}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.respond=e.request=e.Action=void 0;var r,o=n(0),i=n(1);!function(t){t.REQUEST="APP::AUTH_CODE::REQUEST",t.RESPOND="APP::AUTH_CODE::RESPOND"}(r=e.Action||(e.Action={})),e.request=function(t){return o.actionWrapper({group:i.Group.AuthCode,type:r.REQUEST,payload:{id:t}})},e.respond=function(t){return o.actionWrapper({payload:t,group:i.Group.AuthCode,type:r.RESPOND})}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Cart=e.setLineItemProperties=e.removeLineItemDiscount=e.setLineItemDiscount=e.removeLineItem=e.updateLineItem=e.addLineItem=e.removeProperties=e.setProperties=e.setDiscount=e.updateCustomerAddress=e.addCustomerAddress=e.setCustomer=e.update=e.fetch=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t,e){return void 0===e&&(e={}),u.actionWrapper({group:s.Group.Cart,type:t,payload:e})}!function(t){t.FETCH="APP::CART::FETCH",t.UPDATE="APP::CART::UPDATE",t.SET_CUSTOMER="APP::CART::SET_CUSTOMER",t.REMOVE_CUSTOMER="APP::CART::REMOVE_CUSTOMER",t.ADD_CUSTOMER_ADDRESS="APP::CART::ADD_CUSTOMER_ADDRESS",t.UPDATE_CUSTOMER_ADDRESS="APP::CART::UPDATE_CUSTOMER_ADDRESS",t.SET_DISCOUNT="APP::CART::SET_DISCOUNT",t.REMOVE_DISCOUNT="APP::CART::REMOVE_DISCOUNT",t.SET_PROPERTIES="APP::CART::SET_PROPERTIES",t.REMOVE_PROPERTIES="APP::CART::REMOVE_PROPERTIES",t.CLEAR="APP::CART::CLEAR",t.ADD_LINE_ITEM="APP::CART::ADD_LINE_ITEM",t.UPDATE_LINE_ITEM="APP::CART::UPDATE_LINE_ITEM",t.REMOVE_LINE_ITEM="APP::CART::REMOVE_LINE_ITEM",t.SET_LINE_ITEM_DISCOUNT="APP::CART::SET_LINE_ITEM_DISCOUNT",t.REMOVE_LINE_ITEM_DISCOUNT="APP::CART::REMOVE_LINE_ITEM_DISCOUNT",t.SET_LINE_ITEM_PROPERTIES="APP::CART::SET_LINE_ITEM_PROPERTIES",t.REMOVE_LINE_ITEM_PROPERTIES="APP::CART::REMOVE_LINE_ITEM_PROPERTIES"}(a=e.Action||(e.Action={})),e.fetch=function(){return p(a.FETCH)},e.update=function(t){return p(a.UPDATE,t)},e.setCustomer=function(t){return p(a.SET_CUSTOMER,t)},e.addCustomerAddress=function(t){return p(a.ADD_CUSTOMER_ADDRESS,t)},e.updateCustomerAddress=function(t){return p(a.UPDATE_CUSTOMER_ADDRESS,t)},e.setDiscount=function(t){return p(a.SET_DISCOUNT,t)},e.setProperties=function(t){return p(a.SET_PROPERTIES,t)},e.removeProperties=function(t){return p(a.REMOVE_PROPERTIES,t)},e.addLineItem=function(t){return p(a.ADD_LINE_ITEM,t)},e.updateLineItem=function(t){return p(a.UPDATE_LINE_ITEM,t)},e.removeLineItem=function(t){return p(a.REMOVE_LINE_ITEM,t)},e.setLineItemDiscount=function(t){return p(a.SET_LINE_ITEM_DISCOUNT,t)},e.removeLineItemDiscount=function(t){return p(a.REMOVE_LINE_ITEM_DISCOUNT,t)},e.setLineItemProperties=function(t){return p(a.SET_LINE_ITEM_PROPERTIES,t)};var l=function(t){function e(e,n){return t.call(this,e,s.Group.Cart,s.Group.Cart,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case a.FETCH:this.dispatchCartAction(a.FETCH);break;case a.UPDATE:this.dispatchCartAction(a.UPDATE,e);break;case a.SET_CUSTOMER:this.dispatchCartAction(a.SET_CUSTOMER,e);break;case a.REMOVE_CUSTOMER:this.dispatchCartAction(a.REMOVE_CUSTOMER,e);break;case a.ADD_CUSTOMER_ADDRESS:this.dispatchCartAction(a.ADD_CUSTOMER_ADDRESS,e);break;case a.UPDATE_CUSTOMER_ADDRESS:this.dispatchCartAction(a.UPDATE_CUSTOMER_ADDRESS,e);break;case a.SET_DISCOUNT:this.dispatchCartAction(a.SET_DISCOUNT,e);break;case a.REMOVE_DISCOUNT:this.dispatchCartAction(a.REMOVE_DISCOUNT,e);break;case a.SET_PROPERTIES:this.dispatchCartAction(a.SET_PROPERTIES,e);break;case a.REMOVE_PROPERTIES:this.dispatchCartAction(a.REMOVE_PROPERTIES,e);break;case a.CLEAR:this.dispatchCartAction(a.CLEAR,e);break;case a.ADD_LINE_ITEM:this.dispatchCartAction(a.ADD_LINE_ITEM,e);break;case a.UPDATE_LINE_ITEM:this.dispatchCartAction(a.UPDATE_LINE_ITEM,e);break;case a.REMOVE_LINE_ITEM:this.dispatchCartAction(a.REMOVE_LINE_ITEM,e);break;case a.SET_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.SET_LINE_ITEM_DISCOUNT,e);break;case a.REMOVE_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.REMOVE_LINE_ITEM_DISCOUNT,e);break;case a.SET_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.SET_LINE_ITEM_PROPERTIES,e);break;case a.REMOVE_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.REMOVE_LINE_ITEM_PROPERTIES,e)}return this},e.prototype.dispatchCartAction=function(t,e){this.app.dispatch(p(t,i(i({},e),{id:this.id})))},e}(c.ActionSet);e.Cart=l,e.create=function(t,e){return new l(t,e)}},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),o(n(73),e)},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Flash=e.show=e.clear=void 0;var i=n(13),a=n(13);Object.defineProperty(e,"clear",{enumerable:!0,get:function(){return a.clear}}),Object.defineProperty(e,"show",{enumerable:!0,get:function(){return a.show}});var u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e}(i.Toast);e.Flash=u,e.create=function(t,e){return new u(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.FeedbackModal=e.close=e.open=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return u.actionWrapper({group:s.Group.FeedbackModal,payload:t,type:a.OPEN})}function l(t){return u.actionWrapper({group:s.Group.FeedbackModal,payload:t,type:a.CLOSE})}!function(t){t.OPEN="APP::FEEDBACK_MODAL::OPEN",t.CLOSE="APP::FEEDBACK_MODAL::CLOSE"}(a=e.Action||(e.Action={})),e.open=p,e.close=l;var f=function(t){function e(e,n){var r=t.call(this,e,s.Group.FeedbackModal,s.Group.FeedbackModal)||this;return r.options=n,r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),e.prototype.set=function(t){return this.options=u.getMergedProps(this.options,t),this},e.prototype.dispatch=function(t){switch(t){case a.OPEN:var e=p(this.payload);this.app.dispatch(e);break;case a.CLOSE:var n=l(this.payload);this.app.dispatch(n)}return this},e}(c.ActionSet);e.FeedbackModal=f,e.create=function(t,e){return new f(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Fullscreen=e.exit=e.enter=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(t){t.ENTER="APP::FULLSCREEN::ENTER",t.EXIT="APP::FULLSCREEN::EXIT"}(i=e.Action||(e.Action={})),e.enter=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.ENTER})},e.exit=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.EXIT})};var s=function(t){function e(e){return t.call(this,e,c.Group.Fullscreen,c.Group.Fullscreen)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t){return this.app.dispatch(a.actionWrapper({group:this.group,type:t,payload:this.payload})),this},e}(u.ActionSet);e.Fullscreen=s,e.create=function(t){return new s(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.LeaveConfirmation=e.confirm=e.disable=e.enable=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.ENABLE})}function l(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.DISABLE})}function f(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.CONFIRM})}!function(t){t.ENABLE="APP::LEAVE_CONFIRMATION::ENABLE",t.DISABLE="APP::LEAVE_CONFIRMATION::DISABLE",t.CONFIRM="APP::LEAVE_CONFIRMATION::CONFIRM"}(a=e.Action||(e.Action={})),e.enable=p,e.disable=l,e.confirm=f;var d=function(t){function e(e,n){void 0===n&&(n={});var r=t.call(this,e,s.Group.LeaveConfirmation,s.Group.LeaveConfirmation)||this;return r.options=n,r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),e.prototype.set=function(t){return this.options=u.getMergedProps(this.options,t),this},e.prototype.dispatch=function(t){switch(t){case a.ENABLE:var e=p(this.payload);this.app.dispatch(e);break;case a.DISABLE:var n=l(this.payload);this.app.dispatch(n);break;case a.CONFIRM:var r=f(this.payload);this.app.dispatch(r)}return this},e}(c.ActionSet);e.LeaveConfirmation=d,e.create=function(t,e){return void 0===e&&(e={}),new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Loading=e.stop=e.start=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);function s(t){return a.actionWrapper({payload:t,group:c.Group.Loading,type:i.START})}function p(t){return a.actionWrapper({payload:t,group:c.Group.Loading,type:i.STOP})}!function(t){t.START="APP::LOADING::START",t.STOP="APP::LOADING::STOP"}(i=e.Action||(e.Action={})),e.start=s,e.stop=p;var l=function(t){function e(e){return t.call(this,e,c.Group.Loading,c.Group.Loading)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t){switch(t){case i.START:this.app.dispatch(s(this.payload));break;case i.STOP:this.app.dispatch(p(this.payload))}return this},e}(u.ActionSet);e.Loading=l,e.create=function(t){return new l(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},a=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},u=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.create=e.ModalContent=e.Action=void 0;var c,s=n(0),p=n(2),l=n(1),f=n(17);!function(t){t.LOADING="LOADING",t.LOADED="LOADED"}(c=e.Action||(e.Action={}));var d=function(t){function e(e,n){return t.call(this,e,l.Group.Modal,l.Group.Modal,n?n.id:void 0)||this}return o(e,t),e.prototype.loaded=function(){this.dispatch(c.LOADED)},e.prototype.loading=function(){this.dispatch(c.LOADING)},e.prototype.dispatch=function(t){switch(t){case c.LOADED:this.dispatchModalAction(f.Action.UPDATE_CONTENT,{loading:!1});break;case c.LOADING:this.dispatchModalAction(f.Action.UPDATE_CONTENT,{loading:!0})}return this},e.prototype.dispatchModalAction=function(t,e){return a(this,void 0,void 0,(function(){var n;return u(this,(function(r){return n=s.actionWrapper({type:t,group:l.Group.Modal,payload:i({},e)}),this.app.dispatch(n),[2]}))}))},e}(p.ActionSet);e.ModalContent=d,e.create=function(t,e){return new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.History=e.replace=e.push=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return u.actionWrapper({payload:t,group:s.Group.Navigation,type:a.PUSH})}function l(t){return u.actionWrapper({payload:t,group:s.Group.Navigation,type:a.REPLACE})}!function(t){t.PUSH="APP::NAVIGATION::HISTORY::PUSH",t.REPLACE="APP::NAVIGATION::HISTORY::REPLACE"}(a=e.Action||(e.Action={})),e.push=p,e.replace=l;var f=function(t){function e(e){return t.call(this,e,"History",s.Group.Navigation)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t,e){var n=i(i({},this.payload),{path:e});switch(t){case a.PUSH:this.app.dispatch(p(n));break;case a.REPLACE:this.app.dispatch(l(n))}return this},e}(c.ActionSet);e.History=f,e.create=function(t){return new f(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.capture=e.openCamera=e.create=e.Scanner=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(t){t.OPEN_CAMERA="APP::SCANNER::OPEN::CAMERA",t.CAPTURE="APP::SCANNER::CAPTURE"}(i=e.Action||(e.Action={}));var s=function(t){function e(e,n){return t.call(this,e,c.Group.Scanner,c.Group.Scanner,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t){switch(t){case i.OPEN_CAMERA:this.dispatchScannerAction(i.OPEN_CAMERA)}return this},e.prototype.dispatchScannerAction=function(t){this.app.dispatch(a.actionWrapper({type:t,group:c.Group.Scanner,payload:{id:this.id}}))},e}(u.ActionSet);e.Scanner=s,e.create=function(t,e){return new s(t,e)},e.openCamera=function(){return a.actionWrapper({group:c.Group.Scanner,type:i.OPEN_CAMERA})},e.capture=function(t){return a.actionWrapper({group:c.Group.Scanner,type:i.CAPTURE,payload:t})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.respond=e.request=e.Action=void 0;var r,o=n(0),i=n(1);!function(t){t.REQUEST="APP::SESSION_TOKEN::REQUEST",t.RESPOND="APP::SESSION_TOKEN::RESPOND"}(r=e.Action||(e.Action={})),e.request=function(){return o.actionWrapper({group:i.Group.SessionToken,type:r.REQUEST})},e.respond=function(t){return o.actionWrapper({payload:t,group:i.Group.SessionToken,type:r.RESPOND})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getGroupedButton=void 0;var r=n(10);e.getGroupedButton=function(t,e,n,o){t.addChild(e,t.group,n);var i=e.id,a=e.label,u=e.disabled,c=e.buttons,s=e.plain;return t.subscribeToChild(e,r.Action.UPDATE,o),{id:i,label:a,buttons:c,disabled:u,plain:s}}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.close=e.show=e.create=e.Share=e.Action=void 0;var a,u=n(1),c=n(0),s=n(2);!function(t){t.SHOW="APP::SHARE::SHOW",t.CLOSE="APP::SHARE::CLOSE"}(a=e.Action||(e.Action={}));var p=function(t){function e(e){return t.call(this,e,u.Group.Share,u.Group.Share)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case a.SHOW:this.dispatchShareAction(a.SHOW,e);break;case a.CLOSE:this.dispatchShareAction(a.CLOSE,e);break;default:throw new Error("Action: "+t+" not supported")}return this},e.prototype.dispatchShareAction=function(t,e){this.app.dispatch(c.actionWrapper({type:t,group:u.Group.Share,payload:i({id:this.id},e)}))},e}(s.ActionSet);e.Share=p,e.create=function(t){return new p(t)},e.show=function(){return c.actionWrapper({group:u.Group.Share,type:a.SHOW})},e.close=function(t){return c.actionWrapper({group:u.Group.Share,type:a.CLOSE,payload:t})}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.ChannelMenu=e.update=e.Action=void 0;var a,u=n(14),c=n(0),s=n(2),p=n(1),l=["Channel_Menu"];function f(t){return c.actionWrapper({payload:t,group:p.Group.Menu,type:a.UPDATE})}!function(t){t.UPDATE="APP::MENU::CHANNEL_MENU::UPDATE",t.LINK_UPDATE="APP::MENU::CHANNEL_MENU::LINK::UPDATE"}(a=e.Action||(e.Action={})),e.update=f;var d=function(t){function e(e,n){var r=t.call(this,e,"Channel_Menu",p.Group.Menu)||this;return r.items=[],r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"options",{get:function(){return{items:this.itemsOptions,active:this.activeOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"payload",{get:function(){return i(i({},this.options),{active:this.active,items:this.items,id:this.id})},enumerable:!1,configurable:!0}),e.prototype.set=function(t,e){void 0===e&&(e=!0);var n=c.getMergedProps(this.options,t),r=n.items,o=n.active;return this.setItems(r),this.activeOptions=o,this.active=o&&o.id,e&&this.dispatch(a.UPDATE),this},e.prototype.dispatch=function(t){switch(t){case a.UPDATE:this.app.dispatch(f(this.payload))}return this},e.prototype.updateItem=function(t){if(this.items){var e=this.items.find((function(e){return e.id===t.id}));e&&c.updateActionFromPayload(e,t)&&this.dispatch(a.UPDATE)}},e.prototype.setItems=function(t){var e=this,n=t||[],r=this.itemsOptions||[];this.itemsOptions=this.getUpdatedChildActions(n,r),this.items=this.itemsOptions?this.itemsOptions.map((function(t){return e.addChild(t,e.group,l),e.subscribeToChild(t,u.Action.UPDATE,e.updateItem),t.payload})):[]},e}(s.ActionSetWithChildren);e.ChannelMenu=d,e.create=function(t,e){return new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Pos=e.close=e.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(t){t.CLOSE="APP::POS::CLOSE",t.LOCATION_UPDATE="APP::POS::LOCATION::UPDATE",t.USER_UPDATE="APP::POS::USER::UPDATE",t.DEVICE_UPDATE="APP::POS::DEVICE::UPDATE"}(i=e.Action||(e.Action={})),e.close=s;var p=function(t){function e(e){return t.call(this,e,c.Group.Pos,c.Group.Pos)||this}return o(e,t),e.prototype.dispatch=function(t){switch(t){case i.CLOSE:this.app.dispatch(s())}return this},e}(u.ActionSet);e.Pos=p,e.create=function(t){return new p(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.MarketingExternalActivityTopBar=e.update=e.clickActionButton=e.MarketingActivityStatusBadgeType=e.Action=void 0;var a,u=n(6),c=n(12),s=n(0),p=n(2),l=n(1);!function(t){t.UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::UPDATE",t.BUTTON_CLICK="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::CLICK",t.BUTTON_UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::UPDATE"}(a=e.Action||(e.Action={})),function(t){t.Default="DEFAULT",t.Success="SUCCESS",t.Attention="ATTENTION",t.Warning="WARNING",t.Info="INFO"}(e.MarketingActivityStatusBadgeType||(e.MarketingActivityStatusBadgeType={}));var f={group:l.Group.MarketingExternalActivityTopBar,subgroups:["Buttons"]};function d(t){return s.actionWrapper({payload:t,group:l.Group.MarketingExternalActivityTopBar,type:a.UPDATE})}e.clickActionButton=function(t,e){var n=l.ComponentType.Button,r=i({id:t,type:n},f);return u.clickButton(l.Group.MarketingExternalActivityTopBar,r,e)},e.update=d;var h=function(t){function e(e,n){var r=t.call(this,e,l.Group.MarketingExternalActivityTopBar,l.Group.MarketingExternalActivityTopBar)||this;return r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"buttons",{get:function(){if(this.primary||this.secondary)return{primary:this.primary,secondary:this.secondary}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"buttonsOptions",{get:function(){if(this.primaryOptions||this.secondaryOptions)return{primary:this.primaryOptions,secondary:this.secondaryOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(e.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(e.prototype,"payload",{get:function(){return i(i({},this.options),{buttons:this.buttons,id:this.id})},enumerable:!1,configurable:!0}),e.prototype.set=function(t,e){void 0===e&&(e=!0);var n=s.getMergedProps(this.options,t),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),e&&this.dispatch(a.UPDATE),this},e.prototype.dispatch=function(t){switch(t){case a.UPDATE:this.app.dispatch(d(this.payload))}return this},e.prototype.getButton=function(t,e,n){return c.getSingleButton(this,t,e,n)},e.prototype.updatePrimaryButton=function(t){this.primary&&s.updateActionFromPayload(this.primary,t)&&this.dispatch(a.UPDATE)},e.prototype.updateSecondaryButtons=function(t){if(this.secondary){var e=this.secondary.find((function(e){return e.id===t.id}));if(e)s.updateActionFromPayload(e,t)&&this.dispatch(a.UPDATE)}},e.prototype.setPrimaryButton=function(t){this.primaryOptions=this.getChildButton(t,this.primaryOptions),this.primary=this.primaryOptions?this.getButton(this.primaryOptions,f.subgroups,this.updatePrimaryButton):void 0},e.prototype.setSecondaryButtons=function(t){var e=this,n=t||[],r=this.secondaryOptions||[];this.secondaryOptions=this.getUpdatedChildActions(n,r),this.secondary=this.secondaryOptions?this.secondaryOptions.map((function(t){return e.getButton(t,f.subgroups,e.updateSecondaryButtons)})):void 0},e.prototype.updateSaving=function(t){this.saving=t,this.dispatch(a.UPDATE)},e.prototype.updateSaved=function(t){this.saved=t,this.dispatch(a.UPDATE)},e.prototype.updateStatus=function(t){this.status=t,this.dispatch(a.UPDATE)},e.prototype.getChildButton=function(t,e){var n=t?[t]:[],r=e?[e]:[],o=this.getUpdatedChildActions(n,r);return o?o[0]:void 0},e}(p.ActionSetWithChildren);e.MarketingExternalActivityTopBar=h,e.create=function(t,e){return new h(t,e)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.fullPageLoad=e.skeletonPageLoad=e.Action=void 0;var r,o=n(1),i=n(0);!function(t){t.SKELETON_PAGE_LOAD="APP::PERFORMANCE::SKELETON_PAGE_LOAD",t.FULL_PAGE_LOAD="APP::PERFORMANCE::FULL_PAGE_LOAD"}(r=e.Action||(e.Action={})),e.skeletonPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.SKELETON_PAGE_LOAD})},e.fullPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.FULL_PAGE_LOAD})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.initializeWebVitals=e.interactionToNextPaint=e.timeToFirstByte=e.firstContentfulPaint=e.cumulativeLayoutShift=e.firstInputDelay=e.largestContentfulPaint=e.Action=void 0;var r,o=n(89),i=n(18),a=n(1),u=n(0);function c(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.LARGEST_CONTENTFUL_PAINT,payload:t})}function s(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.FIRST_INPUT_DELAY,payload:t})}function p(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.CUMULATIVE_LAYOUT_SHIFT,payload:t})}function l(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.FIRST_CONTENTFUL_PAINT,payload:t})}function f(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.TIME_TO_FIRST_BYTE,payload:t})}function d(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.INTERACTION_TO_NEXT_PAINT,payload:t})}!function(t){t.LARGEST_CONTENTFUL_PAINT="APP::WEB_VITALS::LARGEST_CONTENTFUL_PAINT",t.FIRST_INPUT_DELAY="APP::WEB_VITALS::FIRST_INPUT_DELAY",t.CUMULATIVE_LAYOUT_SHIFT="APP::WEB_VITALS::CUMULATIVE_LAYOUT_SHIFT",t.FIRST_CONTENTFUL_PAINT="APP::WEB_VITALS::FIRST_CONTENTFUL_PAINT",t.TIME_TO_FIRST_BYTE="APP::WEB_VITALS::TIME_TO_FIRST_BYTE",t.INTERACTION_TO_NEXT_PAINT="APP::WEB_VITALS::INTERACTION_TO_NEXT_PAINT"}(r=e.Action||(e.Action={})),e.largestContentfulPaint=c,e.firstInputDelay=s,e.cumulativeLayoutShift=p,e.firstContentfulPaint=l,e.timeToFirstByte=f,e.interactionToNextPaint=d,e.initializeWebVitals=function(t){function e(e){return function(n){var r=n.id,o=n.name,i=n.value,a=e({id:r,metricName:o,value:i});t.dispatch(a)}}var n=window,r="undefined"!=typeof navigator&&(navigator.userAgent.indexOf("Shopify Mobile")>=0||navigator.userAgent.indexOf("Shopify POS")>=0||navigator.userAgent.indexOf("Shopify Ping")>=0);i.isServer||i.isClient&&n.__is_web_vitals_initialized__||r||(n.__is_web_vitals_initialized__=!0,o.onLCP(e(c)),o.onFID(e(s)),o.onCLS(e(p)),o.onFCP(e(l)),o.onTTFB(e(f)),o.onINP(e(d)))}},function(t,e,n){"use strict";n.r(e),n.d(e,"getCLS",(function(){return g})),n.d(e,"getFCP",(function(){return P})),n.d(e,"getFID",(function(){return M})),n.d(e,"getINP",(function(){return W})),n.d(e,"getLCP",(function(){return H})),n.d(e,"getTTFB",(function(){return K})),n.d(e,"onCLS",(function(){return g})),n.d(e,"onFCP",(function(){return P})),n.d(e,"onFID",(function(){return M})),n.d(e,"onINP",(function(){return W})),n.d(e,"onLCP",(function(){return H})),n.d(e,"onTTFB",(function(){return K}));var r,o,i,a,u,c=-1,s=function(t){addEventListener("pageshow",(function(e){e.persisted&&(c=e.timeStamp,t(e))}),!0)},p=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},l=function(){var t=p();return t&&t.activationStart||0},f=function(t,e){var n=p(),r="navigate";return c>=0?r="back-forward-cache":n&&(r=document.prerendering||l()>0?"prerender":n.type.replace(/_/g,"-")),{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},d=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){e(t.getEntries())}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},h=function(t,e){var n=function n(r){"pagehide"!==r.type&&"hidden"!==document.visibilityState||(t(r),e&&(removeEventListener("visibilitychange",n,!0),removeEventListener("pagehide",n,!0)))};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},y=function(t,e,n,r){var o,i;return function(a){e.value>=0&&(a||r)&&((i=e.value-(o||0))||void 0===o)&&(o=e.value,e.delta=i,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},v=-1,A=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},b=function(){h((function(t){var e=t.timeStamp;v=e}),!0)},_=function(){return v<0&&(v=A(),b(),s((function(){setTimeout((function(){v=A(),b()}),0)}))),{get firstHiddenTime(){return v}}},P=function(t,e){e=e||{};var n,r=[1800,3e3],o=_(),i=f("FCP"),a=function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(c&&c.disconnect(),t.startTime<o.firstHiddenTime&&(i.value=t.startTime-l(),i.entries.push(t),n(!0)))}))},u=window.performance&&window.performance.getEntriesByName&&window.performance.getEntriesByName("first-contentful-paint")[0],c=u?null:d("paint",a);(u||c)&&(n=y(t,i,r,e.reportAllChanges),u&&a([u]),s((function(o){i=f("FCP"),n=y(t,i,r,e.reportAllChanges),requestAnimationFrame((function(){requestAnimationFrame((function(){i.value=performance.now()-o.timeStamp,n(!0)}))}))})))},O=!1,E=-1,g=function(t,e){e=e||{};var n=[.1,.25];O||(P((function(t){E=t.value})),O=!0);var r,o=function(e){E>-1&&t(e)},i=f("CLS",0),a=0,u=[],c=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=u[0],n=u[u.length-1];a&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(a+=t.value,u.push(t)):(a=t.value,u=[t]),a>i.value&&(i.value=a,i.entries=u,r())}}))},p=d("layout-shift",c);p&&(r=y(o,i,n,e.reportAllChanges),h((function(){c(p.takeRecords()),r(!0)})),s((function(){a=0,E=-1,i=f("CLS",0),r=y(o,i,n,e.reportAllChanges)})))},T={passive:!0,capture:!0},m=new Date,S=function(t,e){r||(r=e,o=t,i=new Date,R(removeEventListener),C())},C=function(){if(o>=0&&o<i-m){var t={entryType:"first-input",name:r.type,target:r.target,cancelable:r.cancelable,startTime:r.timeStamp,processingStart:r.timeStamp+o};a.forEach((function(e){e(t)})),a=[]}},I=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){S(t,e),o()},r=function(){o()},o=function(){removeEventListener("pointerup",n,T),removeEventListener("pointercancel",r,T)};addEventListener("pointerup",n,T),addEventListener("pointercancel",r,T)}(e,t):S(e,t)}},R=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,I,T)}))},M=function(t,e){e=e||{};var n,i=[100,300],u=_(),c=f("FID"),p=function(t){t.startTime<u.firstHiddenTime&&(c.value=t.processingStart-t.startTime,c.entries.push(t),n(!0))},l=function(t){t.forEach(p)},v=d("first-input",l);n=y(t,c,i,e.reportAllChanges),v&&h((function(){l(v.takeRecords()),v.disconnect()}),!0),v&&s((function(){var u;c=f("FID"),n=y(t,c,i,e.reportAllChanges),a=[],o=-1,r=null,R(addEventListener),u=p,a.push(u),C()}))},N=0,j=1/0,w=0,D=function(t){t.forEach((function(t){t.interactionId&&(j=Math.min(j,t.interactionId),w=Math.max(w,t.interactionId),N=w?(w-j)/7+1:0)}))},L=function(){return u?N:performance.interactionCount||0},U=function(){"interactionCount"in performance||u||(u=d("event",D,{type:"event",buffered:!0,durationThreshold:0}))},B=0,G=function(){return L()-B},x=[],k={},F=function(t){var e=x[x.length-1],n=k[t.interactionId];if(n||x.length<10||t.duration>e.latency){if(n)n.entries.push(t),n.latency=Math.max(n.latency,t.duration);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};k[r.id]=r,x.push(r)}x.sort((function(t,e){return e.latency-t.latency})),x.splice(10).forEach((function(t){delete k[t.id]}))}},W=function(t,e){e=e||{};var n=[200,500];U();var r,o=f("INP"),i=function(t){t.forEach((function(t){t.interactionId&&F(t),"first-input"===t.entryType&&!x.some((function(e){return e.entries.some((function(e){return t.duration===e.duration&&t.startTime===e.startTime}))}))&&F(t)}));var e,n=(e=Math.min(x.length-1,Math.floor(G()/50)),x[e]);n&&n.latency!==o.value&&(o.value=n.latency,o.entries=n.entries,r())},a=d("event",i,{durationThreshold:e.durationThreshold||40});r=y(t,o,n,e.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),h((function(){i(a.takeRecords()),o.value<0&&G()>0&&(o.value=0,o.entries=[]),r(!0)})),s((function(){x=[],B=L(),o=f("INP"),r=y(t,o,n,e.reportAllChanges)})))},V={},H=function(t,e){e=e||{};var n,r=[2500,4e3],o=_(),i=f("LCP"),a=function(t){var e=t[t.length-1];if(e){var r=e.startTime-l();r<o.firstHiddenTime&&(i.value=r,i.entries=[e],n())}},u=d("largest-contentful-paint",a);if(u){n=y(t,i,r,e.reportAllChanges);var c=function(){V[i.id]||(a(u.takeRecords()),u.disconnect(),V[i.id]=!0,n(!0))};["keydown","click"].forEach((function(t){addEventListener(t,c,{once:!0,capture:!0})})),h(c,!0),s((function(o){i=f("LCP"),n=y(t,i,r,e.reportAllChanges),requestAnimationFrame((function(){requestAnimationFrame((function(){i.value=performance.now()-o.timeStamp,V[i.id]=!0,n(!0)}))}))}))}},K=function(t,e){e=e||{};var n=[800,1800],r=f("TTFB"),o=y(t,r,n,e.reportAllChanges);!function t(e){document.prerendering?addEventListener("prerenderingchange",(function(){return t(e)}),!0):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)}((function(){var i=p();if(i){if(r.value=Math.max(i.responseStart-l(),0),r.value<0||r.value>performance.now())return;r.entries=[i],o(!0),s((function(){r=f("TTFB",0),(o=y(t,r,n,e.reportAllChanges))(!0)}))}}))}},function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(t){r=a}}();var c,s=[],p=!1,l=-1;function f(){p&&c&&(p=!1,c.length?s=c.concat(s):l=-1,s.length&&d())}function d(){if(!p){var t=u(f);p=!0;for(var e=s.length;e;){for(c=s,s=[];++l<e;)c&&c[l].run();l=-1,e=s.length}c=null,p=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function y(){}o.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];s.push(new h(t,e)),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(t){return[]},o.binding=function(t){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(t){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useToast=void 0;var r=n(92);Object.defineProperty(e,"useToast",{enumerable:!0,get:function(){return r.useToast}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useToast=e.DEFAULT_TOAST_DURATION=void 0;var r=n(3),o=n(13),i=n(4);e.DEFAULT_TOAST_DURATION=5e3,e.useToast=function(){var t=i.useAppBridge(),n=r.useRef([]),a=r.useCallback((function(r,i){var a=o.create(t,{message:r,isError:null==i?void 0:i.isError,duration:(null==i?void 0:i.duration)||e.DEFAULT_TOAST_DURATION,action:null==i?void 0:i.action});a.dispatch(o.Action.SHOW),n.current.push(a),a.subscribe(o.Action.CLEAR,(function(){var t;null===(t=null==i?void 0:i.onDismiss)||void 0===t||t.call(i),n.current.splice(n.current.indexOf(a),1),a.unsubscribe()})),a.subscribe(o.Action.ACTION,(function(){var t,e;null===(e=null===(t=null==i?void 0:i.action)||void 0===t?void 0:t.onAction)||void 0===e||e.call(t)}))}),[t]);return r.useEffect((function(){return function(){n.current.forEach((function(t){return null==t?void 0:t.unsubscribe()}))}}),[]),{show:a}}},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=r(n(94));e.default=o.default},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(7),c=n(5),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.context;this.loading=u.Loading.create(t),null!=this.loading&&this.loading.dispatch(u.Loading.Action.START)},e.prototype.componentWillUnmount=function(){null!=this.loading&&this.loading.dispatch(u.Loading.Action.STOP)},e.prototype.render=function(){return null},e.contextType=c.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=e.ModalContent=void 0;var o=r(n(37)),i=n(96);Object.defineProperty(e,"ModalContent",{enumerable:!0,get:function(){return r(i).default}});var a=n(37);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return a.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=r(n(97));e.default=o.default},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(7),c=n(5),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.context;this.modalContent=u.ModalContent.create(t),this.syncLoadingStatus()},e.prototype.componentDidUpdate=function(){this.syncLoadingStatus()},e.prototype.syncLoadingStatus=function(){this.modalContent&&(this.props.loading?this.modalContent.loading():this.modalContent.loaded())},e.prototype.render=function(){return null},e.contextType=c.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(39)),i=n(39);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(40)),i=n(40);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){t.exports=n(101)},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n(41);Object.defineProperty(e,"default",{enumerable:!0,get:function(){return i.createApp}}),o(n(19),e),o(n(41),e)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.mockAppBridge=e.serverAppBridge=void 0;var r=n(9),o=function(){},i=new Promise((function(){}));e.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}},e.mockAppBridge={dispatch:function(){return{}},error:function(){return o},featuresAvailable:function(){return i},getState:function(){return i},localOrigin:"",hostOrigin:"",subscribe:function(){return o}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.handleAppPrint=void 0;var r=n(43);function o(){var t;null===(t=r.getWindow())||void 0===t||t.print()}function i(){var t=function(){var t=r.getWindow();if(t&&t.document&&t.document.body){var e=t.document.createElement("input");return e.style.display="none",t.document.body.appendChild(e),e}}();t&&(t.select(),o(),t.remove())}e.handleAppPrint=function(){navigator.userAgent.indexOf("iOS")>=0?i():o()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(15),o=function(){function t(){this.map={}}return t.prototype.set=function(t,e){Object.prototype.hasOwnProperty.call(this.map,t)||(this.map[t]=[]);var n={handler:e,remove:function(){}},o=r.addAndRemoveFromCollection(this.map[t],n);return n={handler:e,remove:o},o},t.prototype.get=function(t){var e=this.map[t];return e?e.map((function(t){return t.handler})):void 0},t.prototype.run=function(t,e,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=0,a=this.get(t)||[];function u(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var o=a[i++];return o?o(u).apply(n,t):e.apply(n,t)}return u.apply(n,r)},t}();e.default=o},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(5),c=n(20),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.props.history;this.unsubscribe=c.handleRouteChange(this.context,t)},e.prototype.componentWillUnmount=function(){this.unsubscribe&&this.unsubscribe()},e.prototype.render=function(){return null},e.contextType=u.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(4),i=n(20);e.default=function(t){var e=o.useAppBridge();r.useEffect((function(){return i.handleRouteChange(e,t)}),[e,t])}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(5),c=n(21),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.props.location;c.updateHistory(this.context,t)},e.prototype.componentDidUpdate=function(t){var e=t.location,n=this.props.location;n!==e&&c.updateHistory(this.context,n)},e.prototype.render=function(){return null},e.contextType=u.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getOrigin=e.getTopWindow=e.getSelfWindow=void 0,e.getSelfWindow=function(){return window.self},e.getTopWindow=function(){return window.top},e.getOrigin=function(){return location.origin}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(4),i=n(21);e.default=function(t){var e=o.useAppBridge();r.useEffect((function(){i.updateHistory(e,t)}),[e,t])}},function(t){t.exports=JSON.parse('{"name":"@shopify/app-bridge-react","version":"3.5.1-alpha.0","types":"index.d.ts","main":"index.js","unpkg":"umd/index.js","jsdelivr":"umd/index.js","files":["/components/","/umd/","/hooks/","/utilities/","/context.d.ts","/context.js","/index.d.ts","/index.js","/types.d.ts","/types.js","/useAppBridge.d.ts","/useAppBridge.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/react-components","author":"Shopify Inc.","license":"MIT","scripts":{"build":"yarn build:tsc && yarn build:umd","build:tsc":"NODE_ENV=production tsc","build:umd":"NODE_ENV=production webpack -p","check":"tsc","clean":"cat package.json | node -pe \\"JSON.parse(require(\'fs\').readFileSync(\'/dev/stdin\').toString()).files.map(f => \'./\'+f).join(\' \')\\" | xargs rm -rf","pack":"yarn pack","size":"size-limit"},"sideEffects":false,"size-limit":[{"limit":"30 KB","path":"index.js"}],"dependencies":{"@shopify/app-bridge":"^3.5.1-alpha.0"},"devDependencies":{"@shopify/react-testing":"^4.1.1","@types/react":"^18.0.2","react-dom":"^18.2.0"},"peerDependencies":{"react":"^16.0.0 || ^17.0.0 || ^18.0.0"}}')},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(46)),i=n(46);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(47)),i=n(47);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(48)),i=n(48);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(49)),i=n(49);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default}])}));
10
+ */var r=Symbol.for("react.element"),o=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),s=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),h=Symbol.iterator;var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,A={};function b(t,e,n){this.props=t,this.context=e,this.refs=A,this.updater=n||y}function _(){}function P(t,e,n){this.props=t,this.context=e,this.refs=A,this.updater=n||y}b.prototype.isReactComponent={},b.prototype.setState=function(t,e){if("object"!=typeof t&&"function"!=typeof t&&null!=t)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")},b.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")},_.prototype=b.prototype;var O=P.prototype=new _;O.constructor=P,v(O,b.prototype),O.isPureReactComponent=!0;var E=Array.isArray,g=Object.prototype.hasOwnProperty,T={current:null},m={key:!0,ref:!0,__self:!0,__source:!0};function S(t,e,n){var o,i={},a=null,u=null;if(null!=e)for(o in void 0!==e.ref&&(u=e.ref),void 0!==e.key&&(a=""+e.key),e)g.call(e,o)&&!m.hasOwnProperty(o)&&(i[o]=e[o]);var c=arguments.length-2;if(1===c)i.children=n;else if(1<c){for(var s=Array(c),p=0;p<c;p++)s[p]=arguments[p+2];i.children=s}if(t&&t.defaultProps)for(o in c=t.defaultProps)void 0===i[o]&&(i[o]=c[o]);return{$$typeof:r,type:t,key:a,ref:u,props:i,_owner:T.current}}function C(t){return"object"==typeof t&&null!==t&&t.$$typeof===r}var I=/\/+/g;function R(t,e){return"object"==typeof t&&null!==t&&null!=t.key?function(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,(function(t){return e[t]}))}(""+t.key):e.toString(36)}function M(t,e,n,i,a){var u=typeof t;"undefined"!==u&&"boolean"!==u||(t=null);var c=!1;if(null===t)c=!0;else switch(u){case"string":case"number":c=!0;break;case"object":switch(t.$$typeof){case r:case o:c=!0}}if(c)return a=a(c=t),t=""===i?"."+R(c,0):i,E(a)?(n="",null!=t&&(n=t.replace(I,"$&/")+"/"),M(a,e,n,"",(function(t){return t}))):null!=a&&(C(a)&&(a=function(t,e){return{$$typeof:r,type:t.type,key:e,ref:t.ref,props:t.props,_owner:t._owner}}(a,n+(!a.key||c&&c.key===a.key?"":(""+a.key).replace(I,"$&/")+"/")+t)),e.push(a)),1;if(c=0,i=""===i?".":i+":",E(t))for(var s=0;s<t.length;s++){var p=i+R(u=t[s],s);c+=M(u,e,n,p,a)}else if("function"==typeof(p=function(t){return null===t||"object"!=typeof t?null:"function"==typeof(t=h&&t[h]||t["@@iterator"])?t:null}(t)))for(t=p.call(t),s=0;!(u=t.next()).done;)c+=M(u=u.value,e,n,p=i+R(u,s++),a);else if("object"===u)throw e=String(t),Error("Objects are not valid as a React child (found: "+("[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.");return c}function N(t,e,n){if(null==t)return t;var r=[],o=0;return M(t,r,"","",(function(t){return e.call(n,t,o++)})),r}function j(t){if(-1===t._status){var e=t._result;(e=e()).then((function(e){0!==t._status&&-1!==t._status||(t._status=1,t._result=e)}),(function(e){0!==t._status&&-1!==t._status||(t._status=2,t._result=e)})),-1===t._status&&(t._status=0,t._result=e)}if(1===t._status)return t._result.default;throw t._result}var w={current:null},D={transition:null},L={ReactCurrentDispatcher:w,ReactCurrentBatchConfig:D,ReactCurrentOwner:T};e.Children={map:N,forEach:function(t,e,n){N(t,(function(){e.apply(this,arguments)}),n)},count:function(t){var e=0;return N(t,(function(){e++})),e},toArray:function(t){return N(t,(function(t){return t}))||[]},only:function(t){if(!C(t))throw Error("React.Children.only expected to receive a single React element child.");return t}},e.Component=b,e.Fragment=i,e.Profiler=u,e.PureComponent=P,e.StrictMode=a,e.Suspense=l,e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=L,e.cloneElement=function(t,e,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=v({},t.props),i=t.key,a=t.ref,u=t._owner;if(null!=e){if(void 0!==e.ref&&(a=e.ref,u=T.current),void 0!==e.key&&(i=""+e.key),t.type&&t.type.defaultProps)var c=t.type.defaultProps;for(s in e)g.call(e,s)&&!m.hasOwnProperty(s)&&(o[s]=void 0===e[s]&&void 0!==c?c[s]:e[s])}var s=arguments.length-2;if(1===s)o.children=n;else if(1<s){c=Array(s);for(var p=0;p<s;p++)c[p]=arguments[p+2];o.children=c}return{$$typeof:r,type:t.type,key:i,ref:a,props:o,_owner:u}},e.createContext=function(t){return(t={$$typeof:s,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:c,_context:t},t.Consumer=t},e.createElement=S,e.createFactory=function(t){var e=S.bind(null,t);return e.type=t,e},e.createRef=function(){return{current:null}},e.forwardRef=function(t){return{$$typeof:p,render:t}},e.isValidElement=C,e.lazy=function(t){return{$$typeof:d,_payload:{_status:-1,_result:t},_init:j}},e.memo=function(t,e){return{$$typeof:f,type:t,compare:void 0===e?null:e}},e.startTransition=function(t){var e=D.transition;D.transition={};try{t()}finally{D.transition=e}},e.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},e.useCallback=function(t,e){return w.current.useCallback(t,e)},e.useContext=function(t){return w.current.useContext(t)},e.useDebugValue=function(){},e.useDeferredValue=function(t){return w.current.useDeferredValue(t)},e.useEffect=function(t,e){return w.current.useEffect(t,e)},e.useId=function(){return w.current.useId()},e.useImperativeHandle=function(t,e,n){return w.current.useImperativeHandle(t,e,n)},e.useInsertionEffect=function(t,e){return w.current.useInsertionEffect(t,e)},e.useLayoutEffect=function(t,e){return w.current.useLayoutEffect(t,e)},e.useMemo=function(t,e){return w.current.useMemo(t,e)},e.useReducer=function(t,e,n){return w.current.useReducer(t,e,n)},e.useRef=function(t){return w.current.useRef(t)},e.useState=function(t){return w.current.useState(t)},e.useSyncExternalStore=function(t,e,n){return w.current.useSyncExternalStore(t,e,n)},e.useTransition=function(){return w.current.useTransition()},e.version="18.2.0"},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)},i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.unstable_Picker=e.ToastProps=e.Toast=e.TitleBar=e.ResourcePickerProps=e.ResourcePicker=e.ProviderProps=e.Provider=e.NavigationMenuProps=e.NavigationMenu=e.ModalContent=e.ModalProps=e.Modal=e.Loading=e.ContextualSaveBarProps=e.ContextualSaveBar=void 0;var a=n(53);Object.defineProperty(e,"ContextualSaveBar",{enumerable:!0,get:function(){return i(a).default}}),Object.defineProperty(e,"ContextualSaveBarProps",{enumerable:!0,get:function(){return a.Props}});var u=n(93);Object.defineProperty(e,"Loading",{enumerable:!0,get:function(){return i(u).default}});var c=n(95);Object.defineProperty(e,"Modal",{enumerable:!0,get:function(){return i(c).default}}),Object.defineProperty(e,"ModalProps",{enumerable:!0,get:function(){return c.Props}}),Object.defineProperty(e,"ModalContent",{enumerable:!0,get:function(){return c.ModalContent}});var s=n(98);Object.defineProperty(e,"NavigationMenu",{enumerable:!0,get:function(){return i(s).default}}),Object.defineProperty(e,"NavigationMenuProps",{enumerable:!0,get:function(){return s.Props}});var p=n(99);Object.defineProperty(e,"Provider",{enumerable:!0,get:function(){return i(p).default}}),Object.defineProperty(e,"ProviderProps",{enumerable:!0,get:function(){return p.Props}});var l=n(111);Object.defineProperty(e,"ResourcePicker",{enumerable:!0,get:function(){return i(l).default}}),Object.defineProperty(e,"ResourcePickerProps",{enumerable:!0,get:function(){return l.Props}});var f=n(112);Object.defineProperty(e,"TitleBar",{enumerable:!0,get:function(){return i(f).default}});var d=n(113);Object.defineProperty(e,"Toast",{enumerable:!0,get:function(){return i(d).default}}),Object.defineProperty(e,"ToastProps",{enumerable:!0,get:function(){return d.Props}});var h=n(114);Object.defineProperty(e,"unstable_Picker",{enumerable:!0,get:function(){return i(h).default}}),o(n(45),e),o(n(44),e)},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),i=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&r(e,t,n);return o(e,t),e};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var a=i(n(54));Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return a.Props}}),e.default=a.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(22);e.default=function(t){var e=t.discardAction,n=void 0===e?{}:e,i=t.saveAction,a=void 0===i?{}:i,u=t.fullWidth,c=t.leaveConfirmationDisable,s=t.visible,p=o.useContextualSaveBar(),l=p.show,f=p.hide,d=p.saveAction.setOptions,h=p.discardAction.setOptions;return r.useEffect((function(){d(a)}),[a]),r.useEffect((function(){h(n)}),[n]),r.useEffect((function(){s?l({fullWidth:u,leaveConfirmationDisable:c}):f()}),[u,c,s]),null}},function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},o=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.useAppBridgeState=void 0;var i=n(3),a=n(4);e.useAppBridgeState=function(t){var e=a.useAppBridge(),n=i.useState(),u=n[0],c=n[1],s=i.useRef(!1),p=i.useCallback((function(){return r(void 0,void 0,void 0,(function(){var n,r;return o(this,(function(o){switch(o.label){case 0:return t?[4,e.getState(t)]:[3,2];case 1:return r=o.sent(),[3,4];case 2:return[4,e.getState()];case 3:r=o.sent(),o.label=4;case 4:return n=r,s.current?[2]:(c((function(t){return JSON.stringify(n)===JSON.stringify(t)?t:n})),[2])}}))}))}),[e,t]);return i.useEffect((function(){return p(),e.subscribe((function(){p()}))}),[e,p]),i.useEffect((function(){return function(){s.current=!0}}),[e]),u}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useContextualSaveBar=void 0;var r=n(57);Object.defineProperty(e,"useContextualSaveBar",{enumerable:!0,get:function(){return r.useContextualSaveBar}})},function(t,e,n){"use strict";var r=this&&this.__rest||function(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n};Object.defineProperty(e,"__esModule",{value:!0}),e.useContextualSaveBar=void 0;var o=n(3),i=n(24),a=n(4);e.useContextualSaveBar=function(){var t=a.useAppBridge(),e=o.useRef(!1),n=o.useState(),u=n[0],c=n[1],s=o.useState(),p=s[0],l=s[1],f=o.useMemo((function(){return i.create(t)}),[t]),d=o.useCallback((function(t){t&&f.set(t,!1),f.dispatch(i.Action.SHOW),e.current=!0}),[f]),h=o.useCallback((function(){f.dispatch(i.Action.HIDE),e.current=!1}),[f]),y=o.useMemo((function(){return{setOptions:function(t){var n=t.onAction,o=r(t,["onAction"]),i=JSON.stringify(f.options.saveAction)!==JSON.stringify(o)&&e.current;c((function(){return n})),f.set({saveAction:o},i)}}}),[f]),v=o.useMemo((function(){return{setOptions:function(t){var n=t.onAction,o=r(t,["onAction"]),i=JSON.stringify(f.options.discardAction)!==JSON.stringify(o)&&e.current;l((function(){return n})),f.set({discardAction:o},i)}}}),[f]);return o.useEffect((function(){return function(){e.current&&h()}}),[]),o.useEffect((function(){return f.subscribe(i.Action.DISCARD,(function(){f.dispatch(i.Action.HIDE),null==p||p()}))}),[f,p]),o.useEffect((function(){return f.subscribe(i.Action.SAVE,(function(){f.dispatch(i.Action.HIDE),null==u||u()}))}),[f,u]),{show:d,hide:h,saveAction:y,discardAction:v}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function t(e,n){if(null==n)return n;if(void 0===e||!Object.prototype.isPrototypeOf.call(Object.getPrototypeOf(e),n)||"Object"!==n.constructor.name&&"Array"!==n.constructor.name)return n;var r={};return Object.keys(n).forEach((function(o){Object.prototype.hasOwnProperty.call(e,o)?"object"!=typeof e[o]||Array.isArray(e[o])?r[o]=n[o]:r[o]=t(e[o],n[o]):r[o]=n[o]})),Object.keys(e).forEach((function(t){Object.prototype.hasOwnProperty.call(n,t)||(r[t]=e[t])})),Object.setPrototypeOf(r,Object.getPrototypeOf(e)),r}},function(t){t.exports=JSON.parse('{"name":"@shopify/app-bridge","version":"3.5.1","types":"index.d.ts","main":"index.js","unpkg":"umd/index.js","jsdelivr":"umd/index.js","files":["/actions/","/client/","/umd/","/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":"cat package.json | node -pe \\"JSON.parse(require(\'fs\').readFileSync(\'/dev/stdin\').toString()).files.map(f => \'./\'+f).join(\' \')\\" | xargs rm -rf","pack":"yarn pack","size":"size-limit"},"sideEffects":false,"size-limit":[{"limit":"10 KB","path":"production.js"}],"dependencies":{"base64url":"^3.0.1","web-vitals":"^3.0.1"},"devDependencies":{"@types/node":"^10.12.5","shx":"^0.3.3"}}')},function(t,e,n){"use strict";function r(t){return Array.from(t).map((function(t){return("00"+t.toString(16)).slice(-2)})).join("")}function o(t){if("function"==typeof Uint8Array&&"object"==typeof window&&window.crypto){var e=new Uint8Array(t),n=window.crypto.getRandomValues(e);if(n)return n}return Array.from(new Array(t),(function(){return 255*Math.random()|0}))}function i(){var t=o(1),e=o(2);return t[0]&=191,e[0]&=79,[r(o(4)),"-",r(o(2)),"-",r(e),"-",r(t),r(o(1)),"-",r(o(6))].join("")}Object.defineProperty(e,"__esModule",{value:!0}),e.generateUuid=void 0,e.generateUuid=i,e.default=i},function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},o=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.useFeaturesAvailable=void 0;var i=n(3),a=n(16),u=n(4);e.useFeaturesAvailable=function(){for(var t=this,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];var c=u.useAppBridge(),s=i.useState(),p=s[0],l=s[1],f=i.useRef([]),d=i.useCallback((function(){var e=!1;return r(t,void 0,void 0,(function(){var t;return o(this,(function(n){switch(n.label){case 0:return[4,c.featuresAvailable.apply(c,f.current)];case 1:return t=n.sent(),e||l((function(e){return JSON.stringify(e)===JSON.stringify(t)?e:t})),[2]}}))})),function(){e=!0}}),[c]);return i.useEffect((function(){return f.current=e,d()}),[JSON.stringify(e)]),i.useEffect((function(){var t,e=c.subscribe(a.Action.UPDATE,(function(){t=d()}));return function(){e(),null==t||t()}}),[c,d]),p}},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),o(n(63),e)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useFeatureRequest=void 0;var r=n(3),o=n(27),i=n(4),a=n(26);e.useFeatureRequest=function(t,e){var n=i.useAppBridge(),u=a.useFeaturesAvailable(),c=r.useState(),s=c[0],p=c[1],l=r.useCallback((function(n){var r=null==n?void 0:n[t];if(e&&(null==r?void 0:r[e])){var o=null==r?void 0:r[e];p((function(t){return JSON.stringify(o)!==JSON.stringify(t)?o:t}))}else p((function(t){return JSON.stringify(r)!==JSON.stringify(t)?r:t}))}),[t,e]);return r.useEffect((function(){o.create(n).dispatch(o.Action.REQUEST,{feature:t,action:e})}),[n,t,e]),r.useEffect((function(){l(u)}),[u,l]),s}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Features=void 0;var a=n(0),u=n(2),c=n(1),s=n(16),p=function(t){function e(e,n){return t.call(this,e,c.Group.Features,c.Group.Features,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case s.Action.REQUEST:this.dispatchFeaturesAction(s.Action.REQUEST,e)}return this},e.prototype.dispatchFeaturesAction=function(t,e){this.app.dispatch(a.actionWrapper({group:c.Group.Features,type:t,payload:i(i({},e||{}),{id:this.id})}))},e}(u.ActionSet);e.Features=p,e.create=function(t,e){return new p(t,e)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useLocale=void 0;var r=n(66);Object.defineProperty(e,"useLocale",{enumerable:!0,get:function(){return r.useLocale}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useLocale=void 0;var r=n(23);e.useLocale=function(){return r.useAppBridgeState("staffMember.locale")}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigate=void 0;var r=n(68);Object.defineProperty(e,"useNavigate",{enumerable:!0,get:function(){return r.useNavigate}})},function(t,e,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigate=void 0;var o=n(3),i=n(11),a=n(4),u=n(28);e.useNavigate=function(){var t=a.useAppBridge(),e=u.useNavigationHistory(),n=o.useMemo((function(){return i.create(t)}),[t]),c=o.useCallback((function(r,o){var a=i.normalizeUrl(r),u=a.startsWith(t.localOrigin),c=a.startsWith(t.hostOrigin),s=a.startsWith("/");if(u||c||s){var p=i.getRelativePath(a);return c||"new"===(null==o?void 0:o.target)||"host"===(null==o?void 0:o.target)?void n.dispatch(i.Action.ADMIN_PATH,{path:p.replace(/^\/admin/,""),newContext:"new"===(null==o?void 0:o.target)}):"self"!==(null==o?void 0:o.target)&&(null==o?void 0:o.target)||!(null==o?void 0:o.replace)?void n.dispatch(i.Action.APP,p):void e.replace({pathname:p})}n.dispatch(i.Action.REMOTE,{url:a,newContext:"new"===(null==o?void 0:o.target)})}),[n,e]);return o.useCallback((function(t,e){if(i.isAdminSection(t)){var o=r(r({},t),{name:i.ResourceType[t.name]});n.dispatch(i.Action.ADMIN_SECTION,{section:o,newContext:"new"===(null==e?void 0:e.target)})}else c(t,e)}),[c,n])}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useNavigationHistory=void 0;var r=n(3),o=n(7),i=n(4);e.useNavigationHistory=function(){var t=i.useAppBridge();return r.useMemo((function(){var e=o.History.create(t);return{push:function(t){e.dispatch(o.History.Action.PUSH,t.pathname)},replace:function(t){e.dispatch(o.History.Action.REPLACE,t.pathname)}}}),[])}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.respond=e.request=e.Action=void 0;var r,o=n(0),i=n(1);!function(t){t.REQUEST="APP::AUTH_CODE::REQUEST",t.RESPOND="APP::AUTH_CODE::RESPOND"}(r=e.Action||(e.Action={})),e.request=function(t){return o.actionWrapper({group:i.Group.AuthCode,type:r.REQUEST,payload:{id:t}})},e.respond=function(t){return o.actionWrapper({payload:t,group:i.Group.AuthCode,type:r.RESPOND})}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Cart=e.setLineItemProperties=e.removeLineItemDiscount=e.setLineItemDiscount=e.removeLineItem=e.updateLineItem=e.addLineItem=e.removeProperties=e.setProperties=e.setDiscount=e.updateCustomerAddress=e.addCustomerAddress=e.setCustomer=e.update=e.fetch=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t,e){return void 0===e&&(e={}),u.actionWrapper({group:s.Group.Cart,type:t,payload:e})}!function(t){t.FETCH="APP::CART::FETCH",t.UPDATE="APP::CART::UPDATE",t.SET_CUSTOMER="APP::CART::SET_CUSTOMER",t.REMOVE_CUSTOMER="APP::CART::REMOVE_CUSTOMER",t.ADD_CUSTOMER_ADDRESS="APP::CART::ADD_CUSTOMER_ADDRESS",t.UPDATE_CUSTOMER_ADDRESS="APP::CART::UPDATE_CUSTOMER_ADDRESS",t.SET_DISCOUNT="APP::CART::SET_DISCOUNT",t.REMOVE_DISCOUNT="APP::CART::REMOVE_DISCOUNT",t.SET_PROPERTIES="APP::CART::SET_PROPERTIES",t.REMOVE_PROPERTIES="APP::CART::REMOVE_PROPERTIES",t.CLEAR="APP::CART::CLEAR",t.ADD_LINE_ITEM="APP::CART::ADD_LINE_ITEM",t.UPDATE_LINE_ITEM="APP::CART::UPDATE_LINE_ITEM",t.REMOVE_LINE_ITEM="APP::CART::REMOVE_LINE_ITEM",t.SET_LINE_ITEM_DISCOUNT="APP::CART::SET_LINE_ITEM_DISCOUNT",t.REMOVE_LINE_ITEM_DISCOUNT="APP::CART::REMOVE_LINE_ITEM_DISCOUNT",t.SET_LINE_ITEM_PROPERTIES="APP::CART::SET_LINE_ITEM_PROPERTIES",t.REMOVE_LINE_ITEM_PROPERTIES="APP::CART::REMOVE_LINE_ITEM_PROPERTIES"}(a=e.Action||(e.Action={})),e.fetch=function(){return p(a.FETCH)},e.update=function(t){return p(a.UPDATE,t)},e.setCustomer=function(t){return p(a.SET_CUSTOMER,t)},e.addCustomerAddress=function(t){return p(a.ADD_CUSTOMER_ADDRESS,t)},e.updateCustomerAddress=function(t){return p(a.UPDATE_CUSTOMER_ADDRESS,t)},e.setDiscount=function(t){return p(a.SET_DISCOUNT,t)},e.setProperties=function(t){return p(a.SET_PROPERTIES,t)},e.removeProperties=function(t){return p(a.REMOVE_PROPERTIES,t)},e.addLineItem=function(t){return p(a.ADD_LINE_ITEM,t)},e.updateLineItem=function(t){return p(a.UPDATE_LINE_ITEM,t)},e.removeLineItem=function(t){return p(a.REMOVE_LINE_ITEM,t)},e.setLineItemDiscount=function(t){return p(a.SET_LINE_ITEM_DISCOUNT,t)},e.removeLineItemDiscount=function(t){return p(a.REMOVE_LINE_ITEM_DISCOUNT,t)},e.setLineItemProperties=function(t){return p(a.SET_LINE_ITEM_PROPERTIES,t)};var l=function(t){function e(e,n){return t.call(this,e,s.Group.Cart,s.Group.Cart,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case a.FETCH:this.dispatchCartAction(a.FETCH);break;case a.UPDATE:this.dispatchCartAction(a.UPDATE,e);break;case a.SET_CUSTOMER:this.dispatchCartAction(a.SET_CUSTOMER,e);break;case a.REMOVE_CUSTOMER:this.dispatchCartAction(a.REMOVE_CUSTOMER,e);break;case a.ADD_CUSTOMER_ADDRESS:this.dispatchCartAction(a.ADD_CUSTOMER_ADDRESS,e);break;case a.UPDATE_CUSTOMER_ADDRESS:this.dispatchCartAction(a.UPDATE_CUSTOMER_ADDRESS,e);break;case a.SET_DISCOUNT:this.dispatchCartAction(a.SET_DISCOUNT,e);break;case a.REMOVE_DISCOUNT:this.dispatchCartAction(a.REMOVE_DISCOUNT,e);break;case a.SET_PROPERTIES:this.dispatchCartAction(a.SET_PROPERTIES,e);break;case a.REMOVE_PROPERTIES:this.dispatchCartAction(a.REMOVE_PROPERTIES,e);break;case a.CLEAR:this.dispatchCartAction(a.CLEAR,e);break;case a.ADD_LINE_ITEM:this.dispatchCartAction(a.ADD_LINE_ITEM,e);break;case a.UPDATE_LINE_ITEM:this.dispatchCartAction(a.UPDATE_LINE_ITEM,e);break;case a.REMOVE_LINE_ITEM:this.dispatchCartAction(a.REMOVE_LINE_ITEM,e);break;case a.SET_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.SET_LINE_ITEM_DISCOUNT,e);break;case a.REMOVE_LINE_ITEM_DISCOUNT:this.dispatchCartAction(a.REMOVE_LINE_ITEM_DISCOUNT,e);break;case a.SET_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.SET_LINE_ITEM_PROPERTIES,e);break;case a.REMOVE_LINE_ITEM_PROPERTIES:this.dispatchCartAction(a.REMOVE_LINE_ITEM_PROPERTIES,e)}return this},e.prototype.dispatchCartAction=function(t,e){this.app.dispatch(p(t,i(i({},e),{id:this.id})))},e}(c.ActionSet);e.Cart=l,e.create=function(t,e){return new l(t,e)}},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),o(n(73),e)},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Flash=e.show=e.clear=void 0;var i=n(13),a=n(13);Object.defineProperty(e,"clear",{enumerable:!0,get:function(){return a.clear}}),Object.defineProperty(e,"show",{enumerable:!0,get:function(){return a.show}});var u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e}(i.Toast);e.Flash=u,e.create=function(t,e){return new u(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.FeedbackModal=e.close=e.open=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return u.actionWrapper({group:s.Group.FeedbackModal,payload:t,type:a.OPEN})}function l(t){return u.actionWrapper({group:s.Group.FeedbackModal,payload:t,type:a.CLOSE})}!function(t){t.OPEN="APP::FEEDBACK_MODAL::OPEN",t.CLOSE="APP::FEEDBACK_MODAL::CLOSE"}(a=e.Action||(e.Action={})),e.open=p,e.close=l;var f=function(t){function e(e,n){var r=t.call(this,e,s.Group.FeedbackModal,s.Group.FeedbackModal)||this;return r.options=n,r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),e.prototype.set=function(t){return this.options=u.getMergedProps(this.options,t),this},e.prototype.dispatch=function(t){switch(t){case a.OPEN:var e=p(this.payload);this.app.dispatch(e);break;case a.CLOSE:var n=l(this.payload);this.app.dispatch(n)}return this},e}(c.ActionSet);e.FeedbackModal=f,e.create=function(t,e){return new f(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Fullscreen=e.exit=e.enter=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(t){t.ENTER="APP::FULLSCREEN::ENTER",t.EXIT="APP::FULLSCREEN::EXIT"}(i=e.Action||(e.Action={})),e.enter=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.ENTER})},e.exit=function(){return a.actionWrapper({group:c.Group.Fullscreen,type:i.EXIT})};var s=function(t){function e(e){return t.call(this,e,c.Group.Fullscreen,c.Group.Fullscreen)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t){return this.app.dispatch(a.actionWrapper({group:this.group,type:t,payload:this.payload})),this},e}(u.ActionSet);e.Fullscreen=s,e.create=function(t){return new s(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.LeaveConfirmation=e.confirm=e.disable=e.enable=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.ENABLE})}function l(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.DISABLE})}function f(t){return void 0===t&&(t={}),u.actionWrapper({group:s.Group.LeaveConfirmation,payload:t,type:a.CONFIRM})}!function(t){t.ENABLE="APP::LEAVE_CONFIRMATION::ENABLE",t.DISABLE="APP::LEAVE_CONFIRMATION::DISABLE",t.CONFIRM="APP::LEAVE_CONFIRMATION::CONFIRM"}(a=e.Action||(e.Action={})),e.enable=p,e.disable=l,e.confirm=f;var d=function(t){function e(e,n){void 0===n&&(n={});var r=t.call(this,e,s.Group.LeaveConfirmation,s.Group.LeaveConfirmation)||this;return r.options=n,r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return i({id:this.id},this.options)},enumerable:!1,configurable:!0}),e.prototype.set=function(t){return this.options=u.getMergedProps(this.options,t),this},e.prototype.dispatch=function(t){switch(t){case a.ENABLE:var e=p(this.payload);this.app.dispatch(e);break;case a.DISABLE:var n=l(this.payload);this.app.dispatch(n);break;case a.CONFIRM:var r=f(this.payload);this.app.dispatch(r)}return this},e}(c.ActionSet);e.LeaveConfirmation=d,e.create=function(t,e){return void 0===e&&(e={}),new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Loading=e.stop=e.start=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);function s(t){return a.actionWrapper({payload:t,group:c.Group.Loading,type:i.START})}function p(t){return a.actionWrapper({payload:t,group:c.Group.Loading,type:i.STOP})}!function(t){t.START="APP::LOADING::START",t.STOP="APP::LOADING::STOP"}(i=e.Action||(e.Action={})),e.start=s,e.stop=p;var l=function(t){function e(e){return t.call(this,e,c.Group.Loading,c.Group.Loading)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t){switch(t){case i.START:this.app.dispatch(s(this.payload));break;case i.STOP:this.app.dispatch(p(this.payload))}return this},e}(u.ActionSet);e.Loading=l,e.create=function(t){return new l(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)},a=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))((function(o,i){function a(t){try{c(r.next(t))}catch(t){i(t)}}function u(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}c((r=r.apply(t,e||[])).next())}))},u=this&&this.__generator||function(t,e){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=e.call(t,a)}catch(t){i=[6,t],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(e,"__esModule",{value:!0}),e.create=e.ModalContent=e.Action=void 0;var c,s=n(0),p=n(2),l=n(1),f=n(17);!function(t){t.LOADING="LOADING",t.LOADED="LOADED"}(c=e.Action||(e.Action={}));var d=function(t){function e(e,n){return t.call(this,e,l.Group.Modal,l.Group.Modal,n?n.id:void 0)||this}return o(e,t),e.prototype.loaded=function(){this.dispatch(c.LOADED)},e.prototype.loading=function(){this.dispatch(c.LOADING)},e.prototype.dispatch=function(t){switch(t){case c.LOADED:this.dispatchModalAction(f.Action.UPDATE_CONTENT,{loading:!1});break;case c.LOADING:this.dispatchModalAction(f.Action.UPDATE_CONTENT,{loading:!0})}return this},e.prototype.dispatchModalAction=function(t,e){return a(this,void 0,void 0,(function(){var n;return u(this,(function(r){return n=s.actionWrapper({type:t,group:l.Group.Modal,payload:i({},e)}),this.app.dispatch(n),[2]}))}))},e}(p.ActionSet);e.ModalContent=d,e.create=function(t,e){return new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.History=e.replace=e.push=e.Action=void 0;var a,u=n(0),c=n(2),s=n(1);function p(t){return u.actionWrapper({payload:t,group:s.Group.Navigation,type:a.PUSH})}function l(t){return u.actionWrapper({payload:t,group:s.Group.Navigation,type:a.REPLACE})}!function(t){t.PUSH="APP::NAVIGATION::HISTORY::PUSH",t.REPLACE="APP::NAVIGATION::HISTORY::REPLACE"}(a=e.Action||(e.Action={})),e.push=p,e.replace=l;var f=function(t){function e(e){return t.call(this,e,"History",s.Group.Navigation)||this}return o(e,t),Object.defineProperty(e.prototype,"payload",{get:function(){return{id:this.id}},enumerable:!1,configurable:!0}),e.prototype.dispatch=function(t,e){var n=i(i({},this.payload),{path:e});switch(t){case a.PUSH:this.app.dispatch(p(n));break;case a.REPLACE:this.app.dispatch(l(n))}return this},e}(c.ActionSet);e.History=f,e.create=function(t){return new f(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.capture=e.openCamera=e.create=e.Scanner=e.Action=void 0;var i,a=n(0),u=n(2),c=n(1);!function(t){t.OPEN_CAMERA="APP::SCANNER::OPEN::CAMERA",t.CAPTURE="APP::SCANNER::CAPTURE"}(i=e.Action||(e.Action={}));var s=function(t){function e(e,n){return t.call(this,e,c.Group.Scanner,c.Group.Scanner,n?n.id:void 0)||this}return o(e,t),e.prototype.dispatch=function(t){switch(t){case i.OPEN_CAMERA:this.dispatchScannerAction(i.OPEN_CAMERA)}return this},e.prototype.dispatchScannerAction=function(t){this.app.dispatch(a.actionWrapper({type:t,group:c.Group.Scanner,payload:{id:this.id}}))},e}(u.ActionSet);e.Scanner=s,e.create=function(t,e){return new s(t,e)},e.openCamera=function(){return a.actionWrapper({group:c.Group.Scanner,type:i.OPEN_CAMERA})},e.capture=function(t){return a.actionWrapper({group:c.Group.Scanner,type:i.CAPTURE,payload:t})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.respond=e.request=e.Action=void 0;var r,o=n(0),i=n(1);!function(t){t.REQUEST="APP::SESSION_TOKEN::REQUEST",t.RESPOND="APP::SESSION_TOKEN::RESPOND"}(r=e.Action||(e.Action={})),e.request=function(){return o.actionWrapper({group:i.Group.SessionToken,type:r.REQUEST})},e.respond=function(t){return o.actionWrapper({payload:t,group:i.Group.SessionToken,type:r.RESPOND})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getGroupedButton=void 0;var r=n(10);e.getGroupedButton=function(t,e,n,o){t.addChild(e,t.group,n);var i=e.id,a=e.label,u=e.disabled,c=e.buttons,s=e.plain;return t.subscribeToChild(e,r.Action.UPDATE,o),{id:i,label:a,buttons:c,disabled:u,plain:s}}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.close=e.show=e.create=e.Share=e.Action=void 0;var a,u=n(1),c=n(0),s=n(2);!function(t){t.SHOW="APP::SHARE::SHOW",t.CLOSE="APP::SHARE::CLOSE"}(a=e.Action||(e.Action={}));var p=function(t){function e(e){return t.call(this,e,u.Group.Share,u.Group.Share)||this}return o(e,t),e.prototype.dispatch=function(t,e){switch(t){case a.SHOW:this.dispatchShareAction(a.SHOW,e);break;case a.CLOSE:this.dispatchShareAction(a.CLOSE,e);break;default:throw new Error("Action: "+t+" not supported")}return this},e.prototype.dispatchShareAction=function(t,e){this.app.dispatch(c.actionWrapper({type:t,group:u.Group.Share,payload:i({id:this.id},e)}))},e}(s.ActionSet);e.Share=p,e.create=function(t){return new p(t)},e.show=function(){return c.actionWrapper({group:u.Group.Share,type:a.SHOW})},e.close=function(t){return c.actionWrapper({group:u.Group.Share,type:a.CLOSE,payload:t})}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.ChannelMenu=e.update=e.Action=void 0;var a,u=n(14),c=n(0),s=n(2),p=n(1),l=["Channel_Menu"];function f(t){return c.actionWrapper({payload:t,group:p.Group.Menu,type:a.UPDATE})}!function(t){t.UPDATE="APP::MENU::CHANNEL_MENU::UPDATE",t.LINK_UPDATE="APP::MENU::CHANNEL_MENU::LINK::UPDATE"}(a=e.Action||(e.Action={})),e.update=f;var d=function(t){function e(e,n){var r=t.call(this,e,"Channel_Menu",p.Group.Menu)||this;return r.items=[],r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"options",{get:function(){return{items:this.itemsOptions,active:this.activeOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"payload",{get:function(){return i(i({},this.options),{active:this.active,items:this.items,id:this.id})},enumerable:!1,configurable:!0}),e.prototype.set=function(t,e){void 0===e&&(e=!0);var n=c.getMergedProps(this.options,t),r=n.items,o=n.active;return this.setItems(r),this.activeOptions=o,this.active=o&&o.id,e&&this.dispatch(a.UPDATE),this},e.prototype.dispatch=function(t){switch(t){case a.UPDATE:this.app.dispatch(f(this.payload))}return this},e.prototype.updateItem=function(t){if(this.items){var e=this.items.find((function(e){return e.id===t.id}));e&&c.updateActionFromPayload(e,t)&&this.dispatch(a.UPDATE)}},e.prototype.setItems=function(t){var e=this,n=t||[],r=this.itemsOptions||[];this.itemsOptions=this.getUpdatedChildActions(n,r),this.items=this.itemsOptions?this.itemsOptions.map((function(t){return e.addChild(t,e.group,l),e.subscribeToChild(t,u.Action.UPDATE,e.updateItem),t.payload})):[]},e}(s.ActionSetWithChildren);e.ChannelMenu=d,e.create=function(t,e){return new d(t,e)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.Pos=e.close=e.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(t){t.CLOSE="APP::POS::CLOSE",t.LOCATION_UPDATE="APP::POS::LOCATION::UPDATE",t.USER_UPDATE="APP::POS::USER::UPDATE",t.DEVICE_UPDATE="APP::POS::DEVICE::UPDATE"}(i=e.Action||(e.Action={})),e.close=s;var p=function(t){function e(e){return t.call(this,e,c.Group.Pos,c.Group.Pos)||this}return o(e,t),e.prototype.dispatch=function(t){switch(t){case i.CLOSE:this.app.dispatch(s())}return this},e}(u.ActionSet);e.Pos=p,e.create=function(t){return new p(t)}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__assign||function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.create=e.MarketingExternalActivityTopBar=e.update=e.clickActionButton=e.MarketingActivityStatusBadgeType=e.Action=void 0;var a,u=n(6),c=n(12),s=n(0),p=n(2),l=n(1);!function(t){t.UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::UPDATE",t.BUTTON_CLICK="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::CLICK",t.BUTTON_UPDATE="APP::MARKETING_EXTERNAL_ACTIVITY_TOP_BAR::BUTTONS::BUTTON::UPDATE"}(a=e.Action||(e.Action={})),function(t){t.Default="DEFAULT",t.Success="SUCCESS",t.Attention="ATTENTION",t.Warning="WARNING",t.Info="INFO"}(e.MarketingActivityStatusBadgeType||(e.MarketingActivityStatusBadgeType={}));var f={group:l.Group.MarketingExternalActivityTopBar,subgroups:["Buttons"]};function d(t){return s.actionWrapper({payload:t,group:l.Group.MarketingExternalActivityTopBar,type:a.UPDATE})}e.clickActionButton=function(t,e){var n=l.ComponentType.Button,r=i({id:t,type:n},f);return u.clickButton(l.Group.MarketingExternalActivityTopBar,r,e)},e.update=d;var h=function(t){function e(e,n){var r=t.call(this,e,l.Group.MarketingExternalActivityTopBar,l.Group.MarketingExternalActivityTopBar)||this;return r.set(n),r}return o(e,t),Object.defineProperty(e.prototype,"buttons",{get:function(){if(this.primary||this.secondary)return{primary:this.primary,secondary:this.secondary}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"buttonsOptions",{get:function(){if(this.primaryOptions||this.secondaryOptions)return{primary:this.primaryOptions,secondary:this.secondaryOptions}},enumerable:!1,configurable:!0}),Object.defineProperty(e.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(e.prototype,"payload",{get:function(){return i(i({},this.options),{buttons:this.buttons,id:this.id})},enumerable:!1,configurable:!0}),e.prototype.set=function(t,e){void 0===e&&(e=!0);var n=s.getMergedProps(this.options,t),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),e&&this.dispatch(a.UPDATE),this},e.prototype.dispatch=function(t){switch(t){case a.UPDATE:this.app.dispatch(d(this.payload))}return this},e.prototype.getButton=function(t,e,n){return c.getSingleButton(this,t,e,n)},e.prototype.updatePrimaryButton=function(t){this.primary&&s.updateActionFromPayload(this.primary,t)&&this.dispatch(a.UPDATE)},e.prototype.updateSecondaryButtons=function(t){if(this.secondary){var e=this.secondary.find((function(e){return e.id===t.id}));if(e)s.updateActionFromPayload(e,t)&&this.dispatch(a.UPDATE)}},e.prototype.setPrimaryButton=function(t){this.primaryOptions=this.getChildButton(t,this.primaryOptions),this.primary=this.primaryOptions?this.getButton(this.primaryOptions,f.subgroups,this.updatePrimaryButton):void 0},e.prototype.setSecondaryButtons=function(t){var e=this,n=t||[],r=this.secondaryOptions||[];this.secondaryOptions=this.getUpdatedChildActions(n,r),this.secondary=this.secondaryOptions?this.secondaryOptions.map((function(t){return e.getButton(t,f.subgroups,e.updateSecondaryButtons)})):void 0},e.prototype.updateSaving=function(t){this.saving=t,this.dispatch(a.UPDATE)},e.prototype.updateSaved=function(t){this.saved=t,this.dispatch(a.UPDATE)},e.prototype.updateStatus=function(t){this.status=t,this.dispatch(a.UPDATE)},e.prototype.getChildButton=function(t,e){var n=t?[t]:[],r=e?[e]:[],o=this.getUpdatedChildActions(n,r);return o?o[0]:void 0},e}(p.ActionSetWithChildren);e.MarketingExternalActivityTopBar=h,e.create=function(t,e){return new h(t,e)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.fullPageLoad=e.skeletonPageLoad=e.Action=void 0;var r,o=n(1),i=n(0);!function(t){t.SKELETON_PAGE_LOAD="APP::PERFORMANCE::SKELETON_PAGE_LOAD",t.FULL_PAGE_LOAD="APP::PERFORMANCE::FULL_PAGE_LOAD"}(r=e.Action||(e.Action={})),e.skeletonPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.SKELETON_PAGE_LOAD})},e.fullPageLoad=function(){return i.actionWrapper({group:o.Group.Performance,type:r.FULL_PAGE_LOAD})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.initializeWebVitals=e.interactionToNextPaint=e.timeToFirstByte=e.firstContentfulPaint=e.cumulativeLayoutShift=e.firstInputDelay=e.largestContentfulPaint=e.Action=void 0;var r,o=n(89),i=n(18),a=n(1),u=n(0);function c(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.LARGEST_CONTENTFUL_PAINT,payload:t})}function s(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.FIRST_INPUT_DELAY,payload:t})}function p(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.CUMULATIVE_LAYOUT_SHIFT,payload:t})}function l(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.FIRST_CONTENTFUL_PAINT,payload:t})}function f(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.TIME_TO_FIRST_BYTE,payload:t})}function d(t){return u.actionWrapper({group:a.Group.WebVitals,type:r.INTERACTION_TO_NEXT_PAINT,payload:t})}!function(t){t.LARGEST_CONTENTFUL_PAINT="APP::WEB_VITALS::LARGEST_CONTENTFUL_PAINT",t.FIRST_INPUT_DELAY="APP::WEB_VITALS::FIRST_INPUT_DELAY",t.CUMULATIVE_LAYOUT_SHIFT="APP::WEB_VITALS::CUMULATIVE_LAYOUT_SHIFT",t.FIRST_CONTENTFUL_PAINT="APP::WEB_VITALS::FIRST_CONTENTFUL_PAINT",t.TIME_TO_FIRST_BYTE="APP::WEB_VITALS::TIME_TO_FIRST_BYTE",t.INTERACTION_TO_NEXT_PAINT="APP::WEB_VITALS::INTERACTION_TO_NEXT_PAINT"}(r=e.Action||(e.Action={})),e.largestContentfulPaint=c,e.firstInputDelay=s,e.cumulativeLayoutShift=p,e.firstContentfulPaint=l,e.timeToFirstByte=f,e.interactionToNextPaint=d,e.initializeWebVitals=function(t){function e(e){return function(n){var r=n.id,o=n.name,i=n.value,a=e({id:r,metricName:o,value:i});t.dispatch(a)}}var n=window,r="undefined"!=typeof navigator&&(navigator.userAgent.indexOf("Shopify Mobile")>=0||navigator.userAgent.indexOf("Shopify POS")>=0||navigator.userAgent.indexOf("Shopify Ping")>=0);i.isServer||i.isClient&&n.__is_web_vitals_initialized__||r||(n.__is_web_vitals_initialized__=!0,o.onLCP(e(c)),o.onFID(e(s)),o.onCLS(e(p)),o.onFCP(e(l)),o.onTTFB(e(f)),o.onINP(e(d)))}},function(t,e,n){"use strict";n.r(e),n.d(e,"getCLS",(function(){return g})),n.d(e,"getFCP",(function(){return P})),n.d(e,"getFID",(function(){return M})),n.d(e,"getINP",(function(){return W})),n.d(e,"getLCP",(function(){return H})),n.d(e,"getTTFB",(function(){return K})),n.d(e,"onCLS",(function(){return g})),n.d(e,"onFCP",(function(){return P})),n.d(e,"onFID",(function(){return M})),n.d(e,"onINP",(function(){return W})),n.d(e,"onLCP",(function(){return H})),n.d(e,"onTTFB",(function(){return K}));var r,o,i,a,u,c=-1,s=function(t){addEventListener("pageshow",(function(e){e.persisted&&(c=e.timeStamp,t(e))}),!0)},p=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},l=function(){var t=p();return t&&t.activationStart||0},f=function(t,e){var n=p(),r="navigate";return c>=0?r="back-forward-cache":n&&(r=document.prerendering||l()>0?"prerender":n.type.replace(/_/g,"-")),{name:t,value:void 0===e?-1:e,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},d=function(t,e,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){e(t.getEntries())}));return r.observe(Object.assign({type:t,buffered:!0},n||{})),r}}catch(t){}},h=function(t,e){var n=function n(r){"pagehide"!==r.type&&"hidden"!==document.visibilityState||(t(r),e&&(removeEventListener("visibilitychange",n,!0),removeEventListener("pagehide",n,!0)))};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},y=function(t,e,n,r){var o,i;return function(a){e.value>=0&&(a||r)&&((i=e.value-(o||0))||void 0===o)&&(o=e.value,e.delta=i,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e))}},v=-1,A=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},b=function(){h((function(t){var e=t.timeStamp;v=e}),!0)},_=function(){return v<0&&(v=A(),b(),s((function(){setTimeout((function(){v=A(),b()}),0)}))),{get firstHiddenTime(){return v}}},P=function(t,e){e=e||{};var n,r=[1800,3e3],o=_(),i=f("FCP"),a=function(t){t.forEach((function(t){"first-contentful-paint"===t.name&&(c&&c.disconnect(),t.startTime<o.firstHiddenTime&&(i.value=t.startTime-l(),i.entries.push(t),n(!0)))}))},u=window.performance&&window.performance.getEntriesByName&&window.performance.getEntriesByName("first-contentful-paint")[0],c=u?null:d("paint",a);(u||c)&&(n=y(t,i,r,e.reportAllChanges),u&&a([u]),s((function(o){i=f("FCP"),n=y(t,i,r,e.reportAllChanges),requestAnimationFrame((function(){requestAnimationFrame((function(){i.value=performance.now()-o.timeStamp,n(!0)}))}))})))},O=!1,E=-1,g=function(t,e){e=e||{};var n=[.1,.25];O||(P((function(t){E=t.value})),O=!0);var r,o=function(e){E>-1&&t(e)},i=f("CLS",0),a=0,u=[],c=function(t){t.forEach((function(t){if(!t.hadRecentInput){var e=u[0],n=u[u.length-1];a&&t.startTime-n.startTime<1e3&&t.startTime-e.startTime<5e3?(a+=t.value,u.push(t)):(a=t.value,u=[t]),a>i.value&&(i.value=a,i.entries=u,r())}}))},p=d("layout-shift",c);p&&(r=y(o,i,n,e.reportAllChanges),h((function(){c(p.takeRecords()),r(!0)})),s((function(){a=0,E=-1,i=f("CLS",0),r=y(o,i,n,e.reportAllChanges)})))},T={passive:!0,capture:!0},m=new Date,S=function(t,e){r||(r=e,o=t,i=new Date,R(removeEventListener),C())},C=function(){if(o>=0&&o<i-m){var t={entryType:"first-input",name:r.type,target:r.target,cancelable:r.cancelable,startTime:r.timeStamp,processingStart:r.timeStamp+o};a.forEach((function(e){e(t)})),a=[]}},I=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){S(t,e),o()},r=function(){o()},o=function(){removeEventListener("pointerup",n,T),removeEventListener("pointercancel",r,T)};addEventListener("pointerup",n,T),addEventListener("pointercancel",r,T)}(e,t):S(e,t)}},R=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,I,T)}))},M=function(t,e){e=e||{};var n,i=[100,300],u=_(),c=f("FID"),p=function(t){t.startTime<u.firstHiddenTime&&(c.value=t.processingStart-t.startTime,c.entries.push(t),n(!0))},l=function(t){t.forEach(p)},v=d("first-input",l);n=y(t,c,i,e.reportAllChanges),v&&h((function(){l(v.takeRecords()),v.disconnect()}),!0),v&&s((function(){var u;c=f("FID"),n=y(t,c,i,e.reportAllChanges),a=[],o=-1,r=null,R(addEventListener),u=p,a.push(u),C()}))},N=0,j=1/0,w=0,D=function(t){t.forEach((function(t){t.interactionId&&(j=Math.min(j,t.interactionId),w=Math.max(w,t.interactionId),N=w?(w-j)/7+1:0)}))},L=function(){return u?N:performance.interactionCount||0},U=function(){"interactionCount"in performance||u||(u=d("event",D,{type:"event",buffered:!0,durationThreshold:0}))},B=0,G=function(){return L()-B},x=[],k={},F=function(t){var e=x[x.length-1],n=k[t.interactionId];if(n||x.length<10||t.duration>e.latency){if(n)n.entries.push(t),n.latency=Math.max(n.latency,t.duration);else{var r={id:t.interactionId,latency:t.duration,entries:[t]};k[r.id]=r,x.push(r)}x.sort((function(t,e){return e.latency-t.latency})),x.splice(10).forEach((function(t){delete k[t.id]}))}},W=function(t,e){e=e||{};var n=[200,500];U();var r,o=f("INP"),i=function(t){t.forEach((function(t){t.interactionId&&F(t),"first-input"===t.entryType&&!x.some((function(e){return e.entries.some((function(e){return t.duration===e.duration&&t.startTime===e.startTime}))}))&&F(t)}));var e,n=(e=Math.min(x.length-1,Math.floor(G()/50)),x[e]);n&&n.latency!==o.value&&(o.value=n.latency,o.entries=n.entries,r())},a=d("event",i,{durationThreshold:e.durationThreshold||40});r=y(t,o,n,e.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),h((function(){i(a.takeRecords()),o.value<0&&G()>0&&(o.value=0,o.entries=[]),r(!0)})),s((function(){x=[],B=L(),o=f("INP"),r=y(t,o,n,e.reportAllChanges)})))},V={},H=function(t,e){e=e||{};var n,r=[2500,4e3],o=_(),i=f("LCP"),a=function(t){var e=t[t.length-1];if(e){var r=e.startTime-l();r<o.firstHiddenTime&&(i.value=r,i.entries=[e],n())}},u=d("largest-contentful-paint",a);if(u){n=y(t,i,r,e.reportAllChanges);var c=function(){V[i.id]||(a(u.takeRecords()),u.disconnect(),V[i.id]=!0,n(!0))};["keydown","click"].forEach((function(t){addEventListener(t,c,{once:!0,capture:!0})})),h(c,!0),s((function(o){i=f("LCP"),n=y(t,i,r,e.reportAllChanges),requestAnimationFrame((function(){requestAnimationFrame((function(){i.value=performance.now()-o.timeStamp,V[i.id]=!0,n(!0)}))}))}))}},K=function(t,e){e=e||{};var n=[800,1800],r=f("TTFB"),o=y(t,r,n,e.reportAllChanges);!function t(e){document.prerendering?addEventListener("prerenderingchange",(function(){return t(e)}),!0):"complete"!==document.readyState?addEventListener("load",(function(){return t(e)}),!0):setTimeout(e,0)}((function(){var i=p();if(i){if(r.value=Math.max(i.responseStart-l(),0),r.value<0||r.value>performance.now())return;r.entries=[i],o(!0),s((function(){r=f("TTFB",0),(o=y(t,r,n,e.reportAllChanges))(!0)}))}}))}},function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(t){r=a}}();var c,s=[],p=!1,l=-1;function f(){p&&c&&(p=!1,c.length?s=c.concat(s):l=-1,s.length&&d())}function d(){if(!p){var t=u(f);p=!0;for(var e=s.length;e;){for(c=s,s=[];++l<e;)c&&c[l].run();l=-1,e=s.length}c=null,p=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function y(){}o.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];s.push(new h(t,e)),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(t){return[]},o.binding=function(t){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(t){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useToast=void 0;var r=n(92);Object.defineProperty(e,"useToast",{enumerable:!0,get:function(){return r.useToast}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.useToast=e.DEFAULT_TOAST_DURATION=void 0;var r=n(3),o=n(13),i=n(4);e.DEFAULT_TOAST_DURATION=5e3,e.useToast=function(){var t=i.useAppBridge(),n=r.useRef([]),a=r.useCallback((function(r,i){var a=o.create(t,{message:r,isError:null==i?void 0:i.isError,duration:(null==i?void 0:i.duration)||e.DEFAULT_TOAST_DURATION,action:null==i?void 0:i.action});a.dispatch(o.Action.SHOW),n.current.push(a),a.subscribe(o.Action.CLEAR,(function(){var t;null===(t=null==i?void 0:i.onDismiss)||void 0===t||t.call(i),n.current.splice(n.current.indexOf(a),1),a.unsubscribe()})),a.subscribe(o.Action.ACTION,(function(){var t,e;null===(e=null===(t=null==i?void 0:i.action)||void 0===t?void 0:t.onAction)||void 0===e||e.call(t)}))}),[t]);return r.useEffect((function(){return function(){n.current.forEach((function(t){return null==t?void 0:t.unsubscribe()}))}}),[]),{show:a}}},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=r(n(94));e.default=o.default},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(7),c=n(5),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.context;this.loading=u.Loading.create(t),null!=this.loading&&this.loading.dispatch(u.Loading.Action.START)},e.prototype.componentWillUnmount=function(){null!=this.loading&&this.loading.dispatch(u.Loading.Action.STOP)},e.prototype.render=function(){return null},e.contextType=c.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=e.ModalContent=void 0;var o=r(n(37)),i=n(96);Object.defineProperty(e,"ModalContent",{enumerable:!0,get:function(){return r(i).default}});var a=n(37);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return a.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var o=r(n(97));e.default=o.default},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(7),c=n(5),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.context;this.modalContent=u.ModalContent.create(t),this.syncLoadingStatus()},e.prototype.componentDidUpdate=function(){this.syncLoadingStatus()},e.prototype.syncLoadingStatus=function(){this.modalContent&&(this.props.loading?this.modalContent.loading():this.modalContent.loaded())},e.prototype.render=function(){return null},e.contextType=c.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(39)),i=n(39);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(40)),i=n(40);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){t.exports=n(101)},function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),o=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n(41);Object.defineProperty(e,"default",{enumerable:!0,get:function(){return i.createApp}}),o(n(19),e),o(n(41),e)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.mockAppBridge=e.serverAppBridge=void 0;var r=n(9),o=function(){},i=new Promise((function(){}));e.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}},e.mockAppBridge={dispatch:function(){return{}},error:function(){return o},featuresAvailable:function(){return i},getState:function(){return i},localOrigin:"",hostOrigin:"",subscribe:function(){return o}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.handleAppPrint=void 0;var r=n(43);function o(){var t;null===(t=r.getWindow())||void 0===t||t.print()}function i(){var t=function(){var t=r.getWindow();if(t&&t.document&&t.document.body){var e=t.document.createElement("input");return e.style.display="none",t.document.body.appendChild(e),e}}();t&&(t.select(),o(),t.remove())}e.handleAppPrint=function(){navigator.userAgent.indexOf("iOS")>=0?i():o()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(15),o=function(){function t(){this.map={}}return t.prototype.set=function(t,e){Object.prototype.hasOwnProperty.call(this.map,t)||(this.map[t]=[]);var n={handler:e,remove:function(){}},o=r.addAndRemoveFromCollection(this.map[t],n);return n={handler:e,remove:o},o},t.prototype.get=function(t){var e=this.map[t];return e?e.map((function(t){return t.handler})):void 0},t.prototype.run=function(t,e,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=0,a=this.get(t)||[];function u(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var o=a[i++];return o?o(u).apply(n,t):e.apply(n,t)}return u.apply(n,r)},t}();e.default=o},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(5),c=n(20),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.props.history;this.unsubscribe=c.handleRouteChange(this.context,t)},e.prototype.componentWillUnmount=function(){this.unsubscribe&&this.unsubscribe()},e.prototype.render=function(){return null},e.contextType=u.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(4),i=n(20);e.default=function(t){var e=o.useAppBridge();r.useEffect((function(){return i.handleRouteChange(e,t)}),[e,t])}},function(t,e,n){"use strict";var r,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var a=i(n(3)),u=n(5),c=n(21),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.prototype.componentDidMount=function(){var t=this.props.location;c.updateHistory(this.context,t)},e.prototype.componentDidUpdate=function(t){var e=t.location,n=this.props.location;n!==e&&c.updateHistory(this.context,n)},e.prototype.render=function(){return null},e.contextType=u.AppBridgeContext,e}(a.default.Component);e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getOrigin=e.getTopWindow=e.getSelfWindow=void 0,e.getSelfWindow=function(){return window.self},e.getTopWindow=function(){return window.top},e.getOrigin=function(){return location.origin}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(4),i=n(21);e.default=function(t){var e=o.useAppBridge();r.useEffect((function(){i.updateHistory(e,t)}),[e,t])}},function(t){t.exports=JSON.parse('{"name":"@shopify/app-bridge-react","version":"3.5.1","types":"index.d.ts","main":"index.js","unpkg":"umd/index.js","jsdelivr":"umd/index.js","files":["/components/","/umd/","/hooks/","/utilities/","/context.d.ts","/context.js","/index.d.ts","/index.js","/types.d.ts","/types.js","/useAppBridge.d.ts","/useAppBridge.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/react-components","author":"Shopify Inc.","license":"MIT","scripts":{"build":"yarn build:tsc && yarn build:umd","build:tsc":"NODE_ENV=production tsc","build:umd":"NODE_ENV=production webpack -p","check":"tsc","clean":"cat package.json | node -pe \\"JSON.parse(require(\'fs\').readFileSync(\'/dev/stdin\').toString()).files.map(f => \'./\'+f).join(\' \')\\" | xargs rm -rf","pack":"yarn pack","size":"size-limit"},"sideEffects":false,"size-limit":[{"limit":"30 KB","path":"index.js"}],"dependencies":{"@shopify/app-bridge":"^3.5.1"},"devDependencies":{"@shopify/react-testing":"^4.1.1","@types/react":"^18.0.2","react-dom":"^18.2.0"},"peerDependencies":{"react":"^16.0.0 || ^17.0.0 || ^18.0.0"}}')},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(46)),i=n(46);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(47)),i=n(47);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(48)),i=n(48);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default},function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Props=void 0;var o=r(n(49)),i=n(49);Object.defineProperty(e,"Props",{enumerable:!0,get:function(){return i.Props}}),e.default=o.default}])}));