cloudcommerce 0.0.81 → 0.0.83
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/package.json +6 -6
- package/packages/api/package.json +1 -1
- package/packages/apps/correios/package.json +1 -1
- package/packages/apps/custom-shipping/package.json +1 -1
- package/packages/apps/discounts/package.json +1 -1
- package/packages/apps/frenet/package.json +1 -1
- package/packages/apps/tiny-erp/package.json +1 -1
- package/packages/cli/package.json +1 -1
- package/packages/config/package.json +1 -1
- package/packages/events/package.json +1 -1
- package/packages/firebase/package.json +2 -2
- package/packages/modules/package.json +1 -1
- package/packages/passport/package.json +1 -1
- package/packages/ssr/package.json +1 -1
- package/packages/storefront/astro.config.mjs +125 -4
- package/packages/storefront/client.d.ts +27 -0
- package/packages/storefront/dist/client/admin/config.json +1 -0
- package/packages/storefront/dist/client/assets/cms-preview.css +274 -0
- package/packages/storefront/dist/client/assets/cms.css +114 -0
- package/packages/storefront/dist/client/assets/cvv.png +0 -0
- package/packages/storefront/dist/client/assets/icons/bootstrap-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/dist/client/assets/icons/feather-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/dist/client/assets/icons/font-awesome/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/dist/client/assets/icons/line-awesome/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/dist/client/assets/icons/tabler-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/dist/client/assets/img-placeholder.png +0 -0
- package/packages/storefront/dist/client/assets/payments.png +0 -0
- package/packages/storefront/dist/client/assets/ssl-safe.png +0 -0
- package/packages/storefront/dist/client/chunks/workbox-window.prod.es5.4b654ae6.js +2 -0
- package/packages/storefront/dist/client/{hoisted.31e23ac0.js → hoisted.46e058d2.js} +18 -18
- package/packages/storefront/dist/client/img/icon.png +0 -0
- package/packages/storefront/dist/client/img/large-icon.png +0 -0
- package/packages/storefront/dist/client/img/uploads/banner1.png +0 -0
- package/packages/storefront/dist/client/img/uploads/banner2.png +0 -0
- package/packages/storefront/dist/client/img/uploads/banner2.webp +0 -0
- package/packages/storefront/dist/client/img/uploads/favicon.png +0 -0
- package/packages/storefront/dist/client/img/uploads/headless.png +0 -0
- package/packages/storefront/dist/client/img/uploads/headphone.png +0 -0
- package/packages/storefront/dist/client/img/uploads/headphone.webp +0 -0
- package/packages/storefront/dist/client/img/uploads/icon.png +0 -0
- package/packages/storefront/dist/client/img/uploads/large-icon.png +0 -0
- package/packages/storefront/dist/client/img/uploads/logo.png +0 -0
- package/packages/storefront/dist/client/img/uploads/logo.webp +0 -0
- package/packages/storefront/dist/client/img/uploads/og-image.png +0 -0
- package/packages/storefront/dist/client/img/uploads/passion.png +0 -0
- package/packages/storefront/dist/client/img/uploads/passion.webp +0 -0
- package/packages/storefront/dist/client/img/uploads/pwa-reliable.png +0 -0
- package/packages/storefront/dist/client/img/uploads/rect8589.png +0 -0
- package/packages/storefront/dist/client/img/uploads/rect859.png +0 -0
- package/packages/storefront/dist/client/img/uploads/rect89.png +0 -0
- package/packages/storefront/dist/client/img/uploads/rect89.webp +0 -0
- package/packages/storefront/dist/client/img/uploads/ssl-safe.png +0 -0
- package/packages/storefront/dist/client/manifest.webmanifest +1 -0
- package/packages/storefront/dist/client/robots.txt +8 -0
- package/packages/storefront/dist/client/sw.js +1 -0
- package/packages/storefront/dist/client/workbox-8b24c3ff.js +1 -0
- package/packages/storefront/dist/server/entry.mjs +5 -3
- package/packages/storefront/dist/server/manifest.webmanifest +1 -0
- package/packages/storefront/dist/server/registerSW.js +1 -0
- package/packages/storefront/package.json +6 -6
- package/packages/storefront/public/admin/config.json +1 -0
- package/packages/storefront/public/assets/cms-preview.css +274 -0
- package/packages/storefront/public/assets/cms.css +114 -0
- package/packages/storefront/public/assets/cvv.png +0 -0
- package/packages/storefront/public/assets/icons/bootstrap-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/public/assets/icons/feather-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/public/assets/icons/font-awesome/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/public/assets/icons/line-awesome/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/public/assets/icons/tabler-icons/font/storefront-icons.woff2 +0 -0
- package/packages/storefront/public/assets/img-placeholder.png +0 -0
- package/packages/storefront/public/assets/payments.png +0 -0
- package/packages/storefront/public/assets/ssl-safe.png +0 -0
- package/packages/storefront/public/img/icon.png +0 -0
- package/packages/storefront/public/img/large-icon.png +0 -0
- package/packages/storefront/public/img/uploads/banner1.png +0 -0
- package/packages/storefront/public/img/uploads/banner2.png +0 -0
- package/packages/storefront/public/img/uploads/banner2.webp +0 -0
- package/packages/storefront/public/img/uploads/favicon.png +0 -0
- package/packages/storefront/public/img/uploads/headless.png +0 -0
- package/packages/storefront/public/img/uploads/headphone.png +0 -0
- package/packages/storefront/public/img/uploads/headphone.webp +0 -0
- package/packages/storefront/public/img/uploads/icon.png +0 -0
- package/packages/storefront/public/img/uploads/large-icon.png +0 -0
- package/packages/storefront/public/img/uploads/logo.png +0 -0
- package/packages/storefront/public/img/uploads/logo.webp +0 -0
- package/packages/storefront/public/img/uploads/og-image.png +0 -0
- package/packages/storefront/public/img/uploads/passion.png +0 -0
- package/packages/storefront/public/img/uploads/passion.webp +0 -0
- package/packages/storefront/public/img/uploads/pwa-reliable.png +0 -0
- package/packages/storefront/public/img/uploads/rect8589.png +0 -0
- package/packages/storefront/public/img/uploads/rect859.png +0 -0
- package/packages/storefront/public/img/uploads/rect89.png +0 -0
- package/packages/storefront/public/img/uploads/rect89.webp +0 -0
- package/packages/storefront/public/img/uploads/ssl-safe.png +0 -0
- package/packages/storefront/public/robots.txt +8 -0
- package/packages/storefront/scripts/prepare-monorepo.sh +4 -0
- package/packages/storefront/scripts/prerelease.sh +4 -0
- package/packages/storefront/src/env.d.ts +2 -0
- package/packages/storefront/src/lib/components/LoginModal.vue +0 -1
- package/packages/storefront/src/lib/layouts/Base.astro +2 -1
- package/packages/storefront/src/lib/layouts/meta/Head.astro +1 -0
- package/packages/storefront/src/lib/ssr-context.ts +1 -1
- package/packages/types/package.json +1 -1
- package/packages/storefront/dist/client/favicon.ico +0 -0
- package/packages/storefront/public/favicon.ico +0 -0
- package/packages/storefront/src/assets/firebaseui.css +0 -648
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
.loading {
|
|
2
|
+
position: fixed;
|
|
3
|
+
z-index: 9999;
|
|
4
|
+
height: 2em;
|
|
5
|
+
width: 2em;
|
|
6
|
+
overflow: show;
|
|
7
|
+
margin: auto;
|
|
8
|
+
top: 0;
|
|
9
|
+
left: 0;
|
|
10
|
+
bottom: 0;
|
|
11
|
+
right: 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.loading:before {
|
|
15
|
+
content: '';
|
|
16
|
+
display: block;
|
|
17
|
+
position: fixed;
|
|
18
|
+
top: 0;
|
|
19
|
+
left: 0;
|
|
20
|
+
width: 100%;
|
|
21
|
+
height: 100%;
|
|
22
|
+
background: radial-gradient(rgba(20, 20, 20,.8), rgba(0, 0, 0, .8));
|
|
23
|
+
background: -webkit-radial-gradient(rgba(20, 20, 20,.8), rgba(0, 0, 0,.8));
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.loading:not(:required) {
|
|
27
|
+
font: 0/0 a;
|
|
28
|
+
color: transparent;
|
|
29
|
+
text-shadow: none;
|
|
30
|
+
background-color: transparent;
|
|
31
|
+
border: 0;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.loading:not(:required):after {
|
|
35
|
+
content: '';
|
|
36
|
+
display: block;
|
|
37
|
+
font-size: 10px;
|
|
38
|
+
width: 1em;
|
|
39
|
+
height: 1em;
|
|
40
|
+
margin-top: -0.5em;
|
|
41
|
+
-webkit-animation: spinner 150ms infinite linear;
|
|
42
|
+
-moz-animation: spinner 150ms infinite linear;
|
|
43
|
+
-ms-animation: spinner 150ms infinite linear;
|
|
44
|
+
-o-animation: spinner 150ms infinite linear;
|
|
45
|
+
animation: spinner 150ms infinite linear;
|
|
46
|
+
border-radius: 0.5em;
|
|
47
|
+
-webkit-box-shadow: rgba(255,255,255, 0.75) 1.5em 0 0 0, rgba(255,255,255, 0.75) 1.1em 1.1em 0 0, rgba(255,255,255, 0.75) 0 1.5em 0 0, rgba(255,255,255, 0.75) -1.1em 1.1em 0 0, rgba(255,255,255, 0.75) -1.5em 0 0 0, rgba(255,255,255, 0.75) -1.1em -1.1em 0 0, rgba(255,255,255, 0.75) 0 -1.5em 0 0, rgba(255,255,255, 0.75) 1.1em -1.1em 0 0;
|
|
48
|
+
box-shadow: rgba(255,255,255, 0.75) 1.5em 0 0 0, rgba(255,255,255, 0.75) 1.1em 1.1em 0 0, rgba(255,255,255, 0.75) 0 1.5em 0 0, rgba(255,255,255, 0.75) -1.1em 1.1em 0 0, rgba(255,255,255, 0.75) -1.5em 0 0 0, rgba(255,255,255, 0.75) -1.1em -1.1em 0 0, rgba(255,255,255, 0.75) 0 -1.5em 0 0, rgba(255,255,255, 0.75) 1.1em -1.1em 0 0;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@-webkit-keyframes spinner {
|
|
52
|
+
0% {
|
|
53
|
+
-webkit-transform: rotate(0deg);
|
|
54
|
+
-moz-transform: rotate(0deg);
|
|
55
|
+
-ms-transform: rotate(0deg);
|
|
56
|
+
-o-transform: rotate(0deg);
|
|
57
|
+
transform: rotate(0deg);
|
|
58
|
+
}
|
|
59
|
+
100% {
|
|
60
|
+
-webkit-transform: rotate(360deg);
|
|
61
|
+
-moz-transform: rotate(360deg);
|
|
62
|
+
-ms-transform: rotate(360deg);
|
|
63
|
+
-o-transform: rotate(360deg);
|
|
64
|
+
transform: rotate(360deg);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
@-moz-keyframes spinner {
|
|
68
|
+
0% {
|
|
69
|
+
-webkit-transform: rotate(0deg);
|
|
70
|
+
-moz-transform: rotate(0deg);
|
|
71
|
+
-ms-transform: rotate(0deg);
|
|
72
|
+
-o-transform: rotate(0deg);
|
|
73
|
+
transform: rotate(0deg);
|
|
74
|
+
}
|
|
75
|
+
100% {
|
|
76
|
+
-webkit-transform: rotate(360deg);
|
|
77
|
+
-moz-transform: rotate(360deg);
|
|
78
|
+
-ms-transform: rotate(360deg);
|
|
79
|
+
-o-transform: rotate(360deg);
|
|
80
|
+
transform: rotate(360deg);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
@-o-keyframes spinner {
|
|
84
|
+
0% {
|
|
85
|
+
-webkit-transform: rotate(0deg);
|
|
86
|
+
-moz-transform: rotate(0deg);
|
|
87
|
+
-ms-transform: rotate(0deg);
|
|
88
|
+
-o-transform: rotate(0deg);
|
|
89
|
+
transform: rotate(0deg);
|
|
90
|
+
}
|
|
91
|
+
100% {
|
|
92
|
+
-webkit-transform: rotate(360deg);
|
|
93
|
+
-moz-transform: rotate(360deg);
|
|
94
|
+
-ms-transform: rotate(360deg);
|
|
95
|
+
-o-transform: rotate(360deg);
|
|
96
|
+
transform: rotate(360deg);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
@keyframes spinner {
|
|
100
|
+
0% {
|
|
101
|
+
-webkit-transform: rotate(0deg);
|
|
102
|
+
-moz-transform: rotate(0deg);
|
|
103
|
+
-ms-transform: rotate(0deg);
|
|
104
|
+
-o-transform: rotate(0deg);
|
|
105
|
+
transform: rotate(0deg);
|
|
106
|
+
}
|
|
107
|
+
100% {
|
|
108
|
+
-webkit-transform: rotate(360deg);
|
|
109
|
+
-moz-transform: rotate(360deg);
|
|
110
|
+
-ms-transform: rotate(360deg);
|
|
111
|
+
-o-transform: rotate(360deg);
|
|
112
|
+
transform: rotate(360deg);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
Binary file
|
package/packages/storefront/dist/client/assets/icons/bootstrap-icons/font/storefront-icons.woff2
ADDED
|
Binary file
|
package/packages/storefront/dist/client/assets/icons/feather-icons/font/storefront-icons.woff2
ADDED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
try{self["workbox:window:6.5.3"]&&_()}catch{}function S(t,r){return new Promise(function(e){var i=new MessageChannel;i.port1.onmessage=function(f){e(f.data)},t.postMessage(r,[i.port2])})}function W(t,r){for(var e=0;e<r.length;e++){var i=r[e];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function E(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function k(t,r){var e;if(typeof Symbol>"u"||t[Symbol.iterator]==null){if(Array.isArray(t)||(e=function(f,d){if(f){if(typeof f=="string")return E(f,d);var h=Object.prototype.toString.call(f).slice(8,-1);return h==="Object"&&f.constructor&&(h=f.constructor.name),h==="Map"||h==="Set"?Array.from(f):h==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(h)?E(f,d):void 0}}(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0;return function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
2
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}return(e=t[Symbol.iterator]()).next.bind(e)}try{self["workbox:core:6.5.3"]&&_()}catch{}var y=function(){var t=this;this.promise=new Promise(function(r,e){t.resolve=r,t.reject=e})};function b(t,r){var e=location.href;return new URL(t,e).href===new URL(r,e).href}var g=function(t,r){this.type=t,Object.assign(this,r)};function p(t,r,e){return e?r?r(t):t:(t&&t.then||(t=Promise.resolve(t)),r?t.then(r):t)}function L(){}var j={type:"SKIP_WAITING"};function P(t,r){if(!r)return t&&t.then?t.then(L):Promise.resolve()}var x=function(t){var r,e;function i(v,c){var n,o;return c===void 0&&(c={}),(n=t.call(this)||this).nn={},n.tn=0,n.rn=new y,n.en=new y,n.on=new y,n.un=0,n.an=new Set,n.cn=function(){var s=n.fn,a=s.installing;n.tn>0||!b(a.scriptURL,n.sn.toString())||performance.now()>n.un+6e4?(n.vn=a,s.removeEventListener("updatefound",n.cn)):(n.hn=a,n.an.add(a),n.rn.resolve(a)),++n.tn,a.addEventListener("statechange",n.ln)},n.ln=function(s){var a=n.fn,u=s.target,l=u.state,m=u===n.vn,w={sw:u,isExternal:m,originalEvent:s};!m&&n.mn&&(w.isUpdate=!0),n.dispatchEvent(new g(l,w)),l==="installed"?n.wn=self.setTimeout(function(){l==="installed"&&a.waiting===u&&n.dispatchEvent(new g("waiting",w))},200):l==="activating"&&(clearTimeout(n.wn),m||n.en.resolve(u))},n.dn=function(s){var a=n.hn,u=a!==navigator.serviceWorker.controller;n.dispatchEvent(new g("controlling",{isExternal:u,originalEvent:s,sw:a,isUpdate:n.mn})),u||n.on.resolve(a)},n.gn=(o=function(s){var a=s.data,u=s.ports,l=s.source;return p(n.getSW(),function(){n.an.has(l)&&n.dispatchEvent(new g("message",{data:a,originalEvent:s,ports:u,sw:l}))})},function(){for(var s=[],a=0;a<arguments.length;a++)s[a]=arguments[a];try{return Promise.resolve(o.apply(this,s))}catch(u){return Promise.reject(u)}}),n.sn=v,n.nn=c,navigator.serviceWorker.addEventListener("message",n.gn),n}e=t,(r=i).prototype=Object.create(e.prototype),r.prototype.constructor=r,r.__proto__=e;var f,d,h=i.prototype;return h.register=function(v){var c=(v===void 0?{}:v).immediate,n=c!==void 0&&c;try{var o=this;return function(s,a){var u=s();return u&&u.then?u.then(a):a(u)}(function(){if(!n&&document.readyState!=="complete")return P(new Promise(function(s){return window.addEventListener("load",s)}))},function(){return o.mn=Boolean(navigator.serviceWorker.controller),o.yn=o.pn(),p(o.bn(),function(s){o.fn=s,o.yn&&(o.hn=o.yn,o.en.resolve(o.yn),o.on.resolve(o.yn),o.yn.addEventListener("statechange",o.ln,{once:!0}));var a=o.fn.waiting;return a&&b(a.scriptURL,o.sn.toString())&&(o.hn=a,Promise.resolve().then(function(){o.dispatchEvent(new g("waiting",{sw:a,wasWaitingBeforeRegister:!0}))}).then(function(){})),o.hn&&(o.rn.resolve(o.hn),o.an.add(o.hn)),o.fn.addEventListener("updatefound",o.cn),navigator.serviceWorker.addEventListener("controllerchange",o.dn),o.fn})})}catch(s){return Promise.reject(s)}},h.update=function(){try{return this.fn?P(this.fn.update()):void 0}catch(v){return Promise.reject(v)}},h.getSW=function(){return this.hn!==void 0?Promise.resolve(this.hn):this.rn.promise},h.messageSW=function(v){try{return p(this.getSW(),function(c){return S(c,v)})}catch(c){return Promise.reject(c)}},h.messageSkipWaiting=function(){this.fn&&this.fn.waiting&&S(this.fn.waiting,j)},h.pn=function(){var v=navigator.serviceWorker.controller;return v&&b(v.scriptURL,this.sn.toString())?v:void 0},h.bn=function(){try{var v=this;return function(c,n){try{var o=c()}catch(s){return n(s)}return o&&o.then?o.then(void 0,n):o}(function(){return p(navigator.serviceWorker.register(v.sn,v.nn),function(c){return v.un=performance.now(),c})},function(c){throw c})}catch(c){return Promise.reject(c)}},f=i,(d=[{key:"active",get:function(){return this.en.promise}},{key:"controlling",get:function(){return this.on.promise}}])&&W(f.prototype,d),i}(function(){function t(){this.Pn=new Map}var r=t.prototype;return r.addEventListener=function(e,i){this.Sn(e).add(i)},r.removeEventListener=function(e,i){this.Sn(e).delete(i)},r.dispatchEvent=function(e){e.target=this;for(var i,f=k(this.Sn(e.type));!(i=f()).done;)(0,i.value)(e)},r.Sn=function(e){return this.Pn.has(e)||this.Pn.set(e,new Set),this.Pn.get(e)},t}());export{x as Workbox,g as WorkboxEvent,S as messageSW};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/**
|
|
1
|
+
const q="modulepreload",Q=function(t){return"/"+t},P={},ee=function(e,n,s){return!n||n.length===0?e():Promise.all(n.map(r=>{if(r=Q(r),r in P)return;P[r]=!0;const a=r.endsWith(".css"),i=a?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${r}"]${i}`))return;const o=document.createElement("link");if(o.rel=a?"stylesheet":q,a||(o.as="script",o.crossOrigin=""),o.href=r,document.head.appendChild(o),a)return new Promise((h,l)=>{o.addEventListener("load",h),o.addEventListener("error",()=>l(new Error(`Unable to preload CSS for ${r}`)))})})).then(()=>e())};function te(t={}){const{immediate:e=!1,onNeedRefresh:n,onOfflineReady:s,onRegistered:r,onRegisteredSW:a,onRegisterError:i}=t;let o,h;const l=async(f=!0)=>{await h};async function _(){if("serviceWorker"in navigator){const{Workbox:f,messageSW:b}=await ee(()=>import("./chunks/workbox-window.prod.es5.4b654ae6.js"),[]);o=new f("/sw.js",{scope:"/",type:"classic"}),o.addEventListener("activated",d=>{d.isUpdate?window.location.reload():s?.()}),o.register({immediate:e}).then(d=>{a?a("/sw.js",d):r?.(d)}).catch(d=>{i?.(d)})}}return h=_(),l}/**
|
|
2
2
|
* @license
|
|
3
3
|
* Copyright 2017 Google LLC
|
|
4
4
|
*
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
29
29
|
* See the License for the specific language governing permissions and
|
|
30
30
|
* limitations under the License.
|
|
31
|
-
*/const
|
|
31
|
+
*/const W=function(t){const e=[];let n=0;for(let s=0;s<t.length;s++){let r=t.charCodeAt(s);r<128?e[n++]=r:r<2048?(e[n++]=r>>6|192,e[n++]=r&63|128):(r&64512)===55296&&s+1<t.length&&(t.charCodeAt(s+1)&64512)===56320?(r=65536+((r&1023)<<10)+(t.charCodeAt(++s)&1023),e[n++]=r>>18|240,e[n++]=r>>12&63|128,e[n++]=r>>6&63|128,e[n++]=r&63|128):(e[n++]=r>>12|224,e[n++]=r>>6&63|128,e[n++]=r&63|128)}return e},ne=function(t){const e=[];let n=0,s=0;for(;n<t.length;){const r=t[n++];if(r<128)e[s++]=String.fromCharCode(r);else if(r>191&&r<224){const a=t[n++];e[s++]=String.fromCharCode((r&31)<<6|a&63)}else if(r>239&&r<365){const a=t[n++],i=t[n++],o=t[n++],h=((r&7)<<18|(a&63)<<12|(i&63)<<6|o&63)-65536;e[s++]=String.fromCharCode(55296+(h>>10)),e[s++]=String.fromCharCode(56320+(h&1023))}else{const a=t[n++],i=t[n++];e[s++]=String.fromCharCode((r&15)<<12|(a&63)<<6|i&63)}}return e.join("")},re={byteToCharMap_:null,charToByteMap_:null,byteToCharMapWebSafe_:null,charToByteMapWebSafe_:null,ENCODED_VALS_BASE:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",get ENCODED_VALS(){return this.ENCODED_VALS_BASE+"+/="},get ENCODED_VALS_WEBSAFE(){return this.ENCODED_VALS_BASE+"-_."},HAS_NATIVE_SUPPORT:typeof atob=="function",encodeByteArray(t,e){if(!Array.isArray(t))throw Error("encodeByteArray takes an array as a parameter");this.init_();const n=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,s=[];for(let r=0;r<t.length;r+=3){const a=t[r],i=r+1<t.length,o=i?t[r+1]:0,h=r+2<t.length,l=h?t[r+2]:0,_=a>>2,f=(a&3)<<4|o>>4;let b=(o&15)<<2|l>>6,d=l&63;h||(d=64,i||(b=64)),s.push(n[_],n[f],n[b],n[d])}return s.join("")},encodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(t):this.encodeByteArray(W(t),e)},decodeString(t,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(t):ne(this.decodeStringToByteArray(t,e))},decodeStringToByteArray(t,e){this.init_();const n=e?this.charToByteMapWebSafe_:this.charToByteMap_,s=[];for(let r=0;r<t.length;){const a=n[t.charAt(r++)],o=r<t.length?n[t.charAt(r)]:0;++r;const l=r<t.length?n[t.charAt(r)]:64;++r;const f=r<t.length?n[t.charAt(r)]:64;if(++r,a==null||o==null||l==null||f==null)throw Error();const b=a<<2|o>>4;if(s.push(b),l!==64){const d=o<<4&240|l>>2;if(s.push(d),f!==64){const Z=l<<6&192|f;s.push(Z)}}}return s},init_(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(let t=0;t<this.ENCODED_VALS.length;t++)this.byteToCharMap_[t]=this.ENCODED_VALS.charAt(t),this.charToByteMap_[this.byteToCharMap_[t]]=t,this.byteToCharMapWebSafe_[t]=this.ENCODED_VALS_WEBSAFE.charAt(t),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[t]]=t,t>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(t)]=t,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(t)]=t)}}},se=function(t){const e=W(t);return re.encodeByteArray(e,!0)},U=function(t){return se(t).replace(/\./g,"")};/**
|
|
32
32
|
* @license
|
|
33
33
|
* Copyright 2017 Google LLC
|
|
34
34
|
*
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
44
44
|
* See the License for the specific language governing permissions and
|
|
45
45
|
* limitations under the License.
|
|
46
|
-
*/class
|
|
46
|
+
*/class ae{constructor(){this.reject=()=>{},this.resolve=()=>{},this.promise=new Promise((e,n)=>{this.resolve=e,this.reject=n})}wrapCallback(e){return(n,s)=>{n?this.reject(n):this.resolve(s),typeof e=="function"&&(this.promise.catch(()=>{}),e.length===1?e(n):e(n,s))}}}function ie(){return typeof indexedDB=="object"}function oe(){return new Promise((t,e)=>{try{let n=!0;const s="validate-browser-context-for-indexeddb-analytics-module",r=self.indexedDB.open(s);r.onsuccess=()=>{r.result.close(),n||self.indexedDB.deleteDatabase(s),t(!0)},r.onupgradeneeded=()=>{n=!1},r.onerror=()=>{var a;e(((a=r.error)===null||a===void 0?void 0:a.message)||"")}}catch(n){e(n)}})}/**
|
|
47
47
|
* @license
|
|
48
48
|
* Copyright 2017 Google LLC
|
|
49
49
|
*
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
59
59
|
* See the License for the specific language governing permissions and
|
|
60
60
|
* limitations under the License.
|
|
61
|
-
*/const
|
|
61
|
+
*/const ce="FirebaseError";class y extends Error{constructor(e,n,s){super(n),this.code=e,this.customData=s,this.name=ce,Object.setPrototypeOf(this,y.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,G.prototype.create)}}class G{constructor(e,n,s){this.service=e,this.serviceName=n,this.errors=s}create(e,...n){const s=n[0]||{},r=`${this.service}/${e}`,a=this.errors[e],i=a?he(a,s):"Error",o=`${this.serviceName}: ${i} (${r}).`;return new y(r,o,s)}}function he(t,e){return t.replace(le,(n,s)=>{const r=e[s];return r!=null?String(r):`<${s}?>`})}const le=/\{\$([^}]+)}/g;function B(t,e){if(t===e)return!0;const n=Object.keys(t),s=Object.keys(e);for(const r of n){if(!s.includes(r))return!1;const a=t[r],i=e[r];if(L(a)&&L(i)){if(!B(a,i))return!1}else if(a!==i)return!1}for(const r of s)if(!n.includes(r))return!1;return!0}function L(t){return t!==null&&typeof t=="object"}class D{constructor(e,n,s){this.name=e,this.instanceFactory=n,this.type=s,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}setInstantiationMode(e){return this.instantiationMode=e,this}setMultipleInstances(e){return this.multipleInstances=e,this}setServiceProps(e){return this.serviceProps=e,this}setInstanceCreatedCallback(e){return this.onInstanceCreated=e,this}}/**
|
|
62
62
|
* @license
|
|
63
63
|
* Copyright 2019 Google LLC
|
|
64
64
|
*
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
74
74
|
* See the License for the specific language governing permissions and
|
|
75
75
|
* limitations under the License.
|
|
76
|
-
*/const
|
|
76
|
+
*/const p="[DEFAULT]";/**
|
|
77
77
|
* @license
|
|
78
78
|
* Copyright 2019 Google LLC
|
|
79
79
|
*
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
89
89
|
* See the License for the specific language governing permissions and
|
|
90
90
|
* limitations under the License.
|
|
91
|
-
*/class
|
|
91
|
+
*/class de{constructor(e,n){this.name=e,this.container=n,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}get(e){const n=this.normalizeInstanceIdentifier(e);if(!this.instancesDeferred.has(n)){const s=new ae;if(this.instancesDeferred.set(n,s),this.isInitialized(n)||this.shouldAutoInitialize())try{const r=this.getOrInitializeService({instanceIdentifier:n});r&&s.resolve(r)}catch{}}return this.instancesDeferred.get(n).promise}getImmediate(e){var n;const s=this.normalizeInstanceIdentifier(e?.identifier),r=(n=e?.optional)!==null&&n!==void 0?n:!1;if(this.isInitialized(s)||this.shouldAutoInitialize())try{return this.getOrInitializeService({instanceIdentifier:s})}catch(a){if(r)return null;throw a}else{if(r)return null;throw Error(`Service ${this.name} is not available`)}}getComponent(){return this.component}setComponent(e){if(e.name!==this.name)throw Error(`Mismatching Component ${e.name} for Provider ${this.name}.`);if(this.component)throw Error(`Component for ${this.name} has already been provided`);if(this.component=e,!!this.shouldAutoInitialize()){if(ue(e))try{this.getOrInitializeService({instanceIdentifier:p})}catch{}for(const[n,s]of this.instancesDeferred.entries()){const r=this.normalizeInstanceIdentifier(n);try{const a=this.getOrInitializeService({instanceIdentifier:r});s.resolve(a)}catch{}}}}clearInstance(e=p){this.instancesDeferred.delete(e),this.instancesOptions.delete(e),this.instances.delete(e)}async delete(){const e=Array.from(this.instances.values());await Promise.all([...e.filter(n=>"INTERNAL"in n).map(n=>n.INTERNAL.delete()),...e.filter(n=>"_delete"in n).map(n=>n._delete())])}isComponentSet(){return this.component!=null}isInitialized(e=p){return this.instances.has(e)}getOptions(e=p){return this.instancesOptions.get(e)||{}}initialize(e={}){const{options:n={}}=e,s=this.normalizeInstanceIdentifier(e.instanceIdentifier);if(this.isInitialized(s))throw Error(`${this.name}(${s}) has already been initialized`);if(!this.isComponentSet())throw Error(`Component ${this.name} has not been registered yet`);const r=this.getOrInitializeService({instanceIdentifier:s,options:n});for(const[a,i]of this.instancesDeferred.entries()){const o=this.normalizeInstanceIdentifier(a);s===o&&i.resolve(r)}return r}onInit(e,n){var s;const r=this.normalizeInstanceIdentifier(n),a=(s=this.onInitCallbacks.get(r))!==null&&s!==void 0?s:new Set;a.add(e),this.onInitCallbacks.set(r,a);const i=this.instances.get(r);return i&&e(i,r),()=>{a.delete(e)}}invokeOnInitCallbacks(e,n){const s=this.onInitCallbacks.get(n);if(!!s)for(const r of s)try{r(e,n)}catch{}}getOrInitializeService({instanceIdentifier:e,options:n={}}){let s=this.instances.get(e);if(!s&&this.component&&(s=this.component.instanceFactory(this.container,{instanceIdentifier:fe(e),options:n}),this.instances.set(e,s),this.instancesOptions.set(e,n),this.invokeOnInitCallbacks(s,e),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,e,s)}catch{}return s||null}normalizeInstanceIdentifier(e=p){return this.component?this.component.multipleInstances?e:p:e}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}}function fe(t){return t===p?void 0:t}function ue(t){return t.instantiationMode==="EAGER"}/**
|
|
92
92
|
* @license
|
|
93
93
|
* Copyright 2019 Google LLC
|
|
94
94
|
*
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
104
104
|
* See the License for the specific language governing permissions and
|
|
105
105
|
* limitations under the License.
|
|
106
|
-
*/class
|
|
106
|
+
*/class pe{constructor(e){this.name=e,this.providers=new Map}addComponent(e){const n=this.getProvider(e.name);if(n.isComponentSet())throw new Error(`Component ${e.name} has already been registered with ${this.name}`);n.setComponent(e)}addOrOverwriteComponent(e){this.getProvider(e.name).isComponentSet()&&this.providers.delete(e.name),this.addComponent(e)}getProvider(e){if(this.providers.has(e))return this.providers.get(e);const n=new de(e,this);return this.providers.set(e,n),n}getProviders(){return Array.from(this.providers.values())}}/**
|
|
107
107
|
* @license
|
|
108
108
|
* Copyright 2017 Google LLC
|
|
109
109
|
*
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
119
119
|
* See the License for the specific language governing permissions and
|
|
120
120
|
* limitations under the License.
|
|
121
|
-
*/var c;(function(t){t[t.DEBUG=0]="DEBUG",t[t.VERBOSE=1]="VERBOSE",t[t.INFO=2]="INFO",t[t.WARN=3]="WARN",t[t.ERROR=4]="ERROR",t[t.SILENT=5]="SILENT"})(c||(c={}));const
|
|
121
|
+
*/var c;(function(t){t[t.DEBUG=0]="DEBUG",t[t.VERBOSE=1]="VERBOSE",t[t.INFO=2]="INFO",t[t.WARN=3]="WARN",t[t.ERROR=4]="ERROR",t[t.SILENT=5]="SILENT"})(c||(c={}));const me={debug:c.DEBUG,verbose:c.VERBOSE,info:c.INFO,warn:c.WARN,error:c.ERROR,silent:c.SILENT},ge=c.INFO,be={[c.DEBUG]:"log",[c.VERBOSE]:"log",[c.INFO]:"info",[c.WARN]:"warn",[c.ERROR]:"error"},Ee=(t,e,...n)=>{if(e<t.logLevel)return;const s=new Date().toISOString(),r=be[e];if(r)console[r](`[${s}] ${t.name}:`,...n);else throw new Error(`Attempted to log a message with an invalid logType (value: ${e})`)};class ye{constructor(e){this.name=e,this._logLevel=ge,this._logHandler=Ee,this._userLogHandler=null}get logLevel(){return this._logLevel}set logLevel(e){if(!(e in c))throw new TypeError(`Invalid value "${e}" assigned to \`logLevel\``);this._logLevel=e}setLogLevel(e){this._logLevel=typeof e=="string"?me[e]:e}get logHandler(){return this._logHandler}set logHandler(e){if(typeof e!="function")throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=e}get userLogHandler(){return this._userLogHandler}set userLogHandler(e){this._userLogHandler=e}debug(...e){this._userLogHandler&&this._userLogHandler(this,c.DEBUG,...e),this._logHandler(this,c.DEBUG,...e)}log(...e){this._userLogHandler&&this._userLogHandler(this,c.VERBOSE,...e),this._logHandler(this,c.VERBOSE,...e)}info(...e){this._userLogHandler&&this._userLogHandler(this,c.INFO,...e),this._logHandler(this,c.INFO,...e)}warn(...e){this._userLogHandler&&this._userLogHandler(this,c.WARN,...e),this._logHandler(this,c.WARN,...e)}error(...e){this._userLogHandler&&this._userLogHandler(this,c.ERROR,...e),this._logHandler(this,c.ERROR,...e)}}const _e=(t,e)=>e.some(n=>t instanceof n);let x,H;function Ie(){return x||(x=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function De(){return H||(H=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}const K=new WeakMap,A=new WeakMap,Y=new WeakMap,v=new WeakMap,N=new WeakMap;function ve(t){const e=new Promise((n,s)=>{const r=()=>{t.removeEventListener("success",a),t.removeEventListener("error",i)},a=()=>{n(u(t.result)),r()},i=()=>{s(t.error),r()};t.addEventListener("success",a),t.addEventListener("error",i)});return e.then(n=>{n instanceof IDBCursor&&K.set(n,t)}).catch(()=>{}),N.set(e,t),e}function we(t){if(A.has(t))return;const e=new Promise((n,s)=>{const r=()=>{t.removeEventListener("complete",a),t.removeEventListener("error",i),t.removeEventListener("abort",i)},a=()=>{n(),r()},i=()=>{s(t.error||new DOMException("AbortError","AbortError")),r()};t.addEventListener("complete",a),t.addEventListener("error",i),t.addEventListener("abort",i)});A.set(t,e)}let O={get(t,e,n){if(t instanceof IDBTransaction){if(e==="done")return A.get(t);if(e==="objectStoreNames")return t.objectStoreNames||Y.get(t);if(e==="store")return n.objectStoreNames[1]?void 0:n.objectStore(n.objectStoreNames[0])}return u(t[e])},set(t,e,n){return t[e]=n,!0},has(t,e){return t instanceof IDBTransaction&&(e==="done"||e==="store")?!0:e in t}};function Ce(t){O=t(O)}function Se(t){return t===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(e,...n){const s=t.call(w(this),e,...n);return Y.set(s,e.sort?e.sort():[e]),u(s)}:De().includes(t)?function(...e){return t.apply(w(this),e),u(K.get(this))}:function(...e){return u(t.apply(w(this),e))}}function Be(t){return typeof t=="function"?Se(t):(t instanceof IDBTransaction&&we(t),_e(t,Ie())?new Proxy(t,O):t)}function u(t){if(t instanceof IDBRequest)return ve(t);if(v.has(t))return v.get(t);const e=Be(t);return e!==t&&(v.set(t,e),N.set(e,t)),e}const w=t=>N.get(t);function Ae(t,e,{blocked:n,upgrade:s,blocking:r,terminated:a}={}){const i=indexedDB.open(t,e),o=u(i);return s&&i.addEventListener("upgradeneeded",h=>{s(u(i.result),h.oldVersion,h.newVersion,u(i.transaction))}),n&&i.addEventListener("blocked",()=>n()),o.then(h=>{a&&h.addEventListener("close",()=>a()),r&&h.addEventListener("versionchange",()=>r())}).catch(()=>{}),o}const Oe=["get","getKey","getAll","getAllKeys","count"],Te=["put","add","delete","clear"],C=new Map;function k(t,e){if(!(t instanceof IDBDatabase&&!(e in t)&&typeof e=="string"))return;if(C.get(e))return C.get(e);const n=e.replace(/FromIndex$/,""),s=e!==n,r=Te.includes(n);if(!(n in(s?IDBIndex:IDBObjectStore).prototype)||!(r||Oe.includes(n)))return;const a=async function(i,...o){const h=this.transaction(i,r?"readwrite":"readonly");let l=h.store;return s&&(l=l.index(o.shift())),(await Promise.all([l[n](...o),r&&h.done]))[0]};return C.set(e,a),a}Ce(t=>({...t,get:(e,n,s)=>k(e,n)||t.get(e,n,s),has:(e,n)=>!!k(e,n)||t.has(e,n)}));/**
|
|
122
122
|
* @license
|
|
123
123
|
* Copyright 2019 Google LLC
|
|
124
124
|
*
|
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
134
134
|
* See the License for the specific language governing permissions and
|
|
135
135
|
* limitations under the License.
|
|
136
|
-
*/class
|
|
136
|
+
*/class Me{constructor(e){this.container=e}getPlatformInfoString(){return this.container.getProviders().map(n=>{if($e(n)){const s=n.getImmediate();return`${s.library}/${s.version}`}else return null}).filter(n=>n).join(" ")}}function $e(t){const e=t.getComponent();return e?.type==="VERSION"}const T="@firebase/app",j="0.7.33";/**
|
|
137
137
|
* @license
|
|
138
138
|
* Copyright 2019 Google LLC
|
|
139
139
|
*
|
|
@@ -148,7 +148,7 @@
|
|
|
148
148
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
149
149
|
* See the License for the specific language governing permissions and
|
|
150
150
|
* limitations under the License.
|
|
151
|
-
*/const
|
|
151
|
+
*/const m=new ye("@firebase/app"),Re="@firebase/app-compat",Ne="@firebase/analytics-compat",Pe="@firebase/analytics",Le="@firebase/app-check-compat",xe="@firebase/app-check",He="@firebase/auth",ke="@firebase/auth-compat",je="@firebase/database",Fe="@firebase/database-compat",Ve="@firebase/functions",ze="@firebase/functions-compat",We="@firebase/installations",Ue="@firebase/installations-compat",Ge="@firebase/messaging",Ke="@firebase/messaging-compat",Ye="@firebase/performance",Xe="@firebase/performance-compat",Je="@firebase/remote-config",Ze="@firebase/remote-config-compat",qe="@firebase/storage",Qe="@firebase/storage-compat",et="@firebase/firestore",tt="@firebase/firestore-compat",nt="firebase";/**
|
|
152
152
|
* @license
|
|
153
153
|
* Copyright 2019 Google LLC
|
|
154
154
|
*
|
|
@@ -163,7 +163,7 @@
|
|
|
163
163
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
164
164
|
* See the License for the specific language governing permissions and
|
|
165
165
|
* limitations under the License.
|
|
166
|
-
*/const
|
|
166
|
+
*/const rt="[DEFAULT]",st={[T]:"fire-core",[Re]:"fire-core-compat",[Pe]:"fire-analytics",[Ne]:"fire-analytics-compat",[xe]:"fire-app-check",[Le]:"fire-app-check-compat",[He]:"fire-auth",[ke]:"fire-auth-compat",[je]:"fire-rtdb",[Fe]:"fire-rtdb-compat",[Ve]:"fire-fn",[ze]:"fire-fn-compat",[We]:"fire-iid",[Ue]:"fire-iid-compat",[Ge]:"fire-fcm",[Ke]:"fire-fcm-compat",[Ye]:"fire-perf",[Xe]:"fire-perf-compat",[Je]:"fire-rc",[Ze]:"fire-rc-compat",[qe]:"fire-gcs",[Qe]:"fire-gcs-compat",[et]:"fire-fst",[tt]:"fire-fst-compat","fire-js":"fire-js",[nt]:"fire-js-all"};/**
|
|
167
167
|
* @license
|
|
168
168
|
* Copyright 2019 Google LLC
|
|
169
169
|
*
|
|
@@ -178,7 +178,7 @@
|
|
|
178
178
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
179
179
|
* See the License for the specific language governing permissions and
|
|
180
180
|
* limitations under the License.
|
|
181
|
-
*/const
|
|
181
|
+
*/const M=new Map,$=new Map;function at(t,e){try{t.container.addComponent(e)}catch(n){m.debug(`Component ${e.name} failed to register with FirebaseApp ${t.name}`,n)}}function R(t){const e=t.name;if($.has(e))return m.debug(`There were multiple attempts to register component ${e}.`),!1;$.set(e,t);for(const n of M.values())at(n,t);return!0}/**
|
|
182
182
|
* @license
|
|
183
183
|
* Copyright 2019 Google LLC
|
|
184
184
|
*
|
|
@@ -193,7 +193,7 @@
|
|
|
193
193
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
194
194
|
* See the License for the specific language governing permissions and
|
|
195
195
|
* limitations under the License.
|
|
196
|
-
*/const
|
|
196
|
+
*/const it={["no-app"]:"No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",["bad-app-name"]:"Illegal App name: '{$appName}",["duplicate-app"]:"Firebase App named '{$appName}' already exists with different options or config",["app-deleted"]:"Firebase App named '{$appName}' already deleted",["invalid-app-argument"]:"firebase.{$appName}() takes either no argument or a Firebase App instance.",["invalid-log-argument"]:"First argument to `onLog` must be null or a function.",["idb-open"]:"Error thrown when opening IndexedDB. Original error: {$originalErrorMessage}.",["idb-get"]:"Error thrown when reading from IndexedDB. Original error: {$originalErrorMessage}.",["idb-set"]:"Error thrown when writing to IndexedDB. Original error: {$originalErrorMessage}.",["idb-delete"]:"Error thrown when deleting from IndexedDB. Original error: {$originalErrorMessage}."},g=new G("app","Firebase",it);/**
|
|
197
197
|
* @license
|
|
198
198
|
* Copyright 2019 Google LLC
|
|
199
199
|
*
|
|
@@ -208,7 +208,7 @@
|
|
|
208
208
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
209
209
|
* See the License for the specific language governing permissions and
|
|
210
210
|
* limitations under the License.
|
|
211
|
-
*/class
|
|
211
|
+
*/class ot{constructor(e,n,s){this._isDeleted=!1,this._options=Object.assign({},e),this._config=Object.assign({},n),this._name=n.name,this._automaticDataCollectionEnabled=n.automaticDataCollectionEnabled,this._container=s,this.container.addComponent(new D("app",()=>this,"PUBLIC"))}get automaticDataCollectionEnabled(){return this.checkDestroyed(),this._automaticDataCollectionEnabled}set automaticDataCollectionEnabled(e){this.checkDestroyed(),this._automaticDataCollectionEnabled=e}get name(){return this.checkDestroyed(),this._name}get options(){return this.checkDestroyed(),this._options}get config(){return this.checkDestroyed(),this._config}get container(){return this._container}get isDeleted(){return this._isDeleted}set isDeleted(e){this._isDeleted=e}checkDestroyed(){if(this.isDeleted)throw g.create("app-deleted",{appName:this._name})}}function ct(t,e={}){typeof e!="object"&&(e={name:e});const n=Object.assign({name:rt,automaticDataCollectionEnabled:!1},e),s=n.name;if(typeof s!="string"||!s)throw g.create("bad-app-name",{appName:String(s)});const r=M.get(s);if(r){if(B(t,r.options)&&B(n,r.config))return r;throw g.create("duplicate-app",{appName:s})}const a=new pe(s);for(const o of $.values())a.addComponent(o);const i=new ot(t,n,a);return M.set(s,i),i}function I(t,e,n){var s;let r=(s=st[t])!==null&&s!==void 0?s:t;n&&(r+=`-${n}`);const a=r.match(/\s|\//),i=e.match(/\s|\//);if(a||i){const o=[`Unable to register library "${r}" with version "${e}":`];a&&o.push(`library name "${r}" contains illegal characters (whitespace or "/")`),a&&i&&o.push("and"),i&&o.push(`version name "${e}" contains illegal characters (whitespace or "/")`),m.warn(o.join(" "));return}R(new D(`${r}-version`,()=>({library:r,version:e}),"VERSION"))}/**
|
|
212
212
|
* @license
|
|
213
213
|
* Copyright 2021 Google LLC
|
|
214
214
|
*
|
|
@@ -223,7 +223,7 @@
|
|
|
223
223
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
224
224
|
* See the License for the specific language governing permissions and
|
|
225
225
|
* limitations under the License.
|
|
226
|
-
*/const
|
|
226
|
+
*/const ht="firebase-heartbeat-database",lt=1,E="firebase-heartbeat-store";let S=null;function X(){return S||(S=Ae(ht,lt,{upgrade:(t,e)=>{switch(e){case 0:t.createObjectStore(E)}}}).catch(t=>{throw g.create("idb-open",{originalErrorMessage:t.message})})),S}async function dt(t){var e;try{return(await X()).transaction(E).objectStore(E).get(J(t))}catch(n){if(n instanceof y)m.warn(n.message);else{const s=g.create("idb-get",{originalErrorMessage:(e=n)===null||e===void 0?void 0:e.message});m.warn(s.message)}}}async function F(t,e){var n;try{const r=(await X()).transaction(E,"readwrite");return await r.objectStore(E).put(e,J(t)),r.done}catch(s){if(s instanceof y)m.warn(s.message);else{const r=g.create("idb-set",{originalErrorMessage:(n=s)===null||n===void 0?void 0:n.message});m.warn(r.message)}}}function J(t){return`${t.name}!${t.options.appId}`}/**
|
|
227
227
|
* @license
|
|
228
228
|
* Copyright 2021 Google LLC
|
|
229
229
|
*
|
|
@@ -238,7 +238,7 @@
|
|
|
238
238
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
239
239
|
* See the License for the specific language governing permissions and
|
|
240
240
|
* limitations under the License.
|
|
241
|
-
*/const
|
|
241
|
+
*/const ft=1024,ut=30*24*60*60*1e3;class pt{constructor(e){this.container=e,this._heartbeatsCache=null;const n=this.container.getProvider("app").getImmediate();this._storage=new gt(n),this._heartbeatsCachePromise=this._storage.read().then(s=>(this._heartbeatsCache=s,s))}async triggerHeartbeat(){const n=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),s=V();if(this._heartbeatsCache===null&&(this._heartbeatsCache=await this._heartbeatsCachePromise),!(this._heartbeatsCache.lastSentHeartbeatDate===s||this._heartbeatsCache.heartbeats.some(r=>r.date===s)))return this._heartbeatsCache.heartbeats.push({date:s,agent:n}),this._heartbeatsCache.heartbeats=this._heartbeatsCache.heartbeats.filter(r=>{const a=new Date(r.date).valueOf();return Date.now()-a<=ut}),this._storage.overwrite(this._heartbeatsCache)}async getHeartbeatsHeader(){if(this._heartbeatsCache===null&&await this._heartbeatsCachePromise,this._heartbeatsCache===null||this._heartbeatsCache.heartbeats.length===0)return"";const e=V(),{heartbeatsToSend:n,unsentEntries:s}=mt(this._heartbeatsCache.heartbeats),r=U(JSON.stringify({version:2,heartbeats:n}));return this._heartbeatsCache.lastSentHeartbeatDate=e,s.length>0?(this._heartbeatsCache.heartbeats=s,await this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),r}}function V(){return new Date().toISOString().substring(0,10)}function mt(t,e=ft){const n=[];let s=t.slice();for(const r of t){const a=n.find(i=>i.agent===r.agent);if(a){if(a.dates.push(r.date),z(n)>e){a.dates.pop();break}}else if(n.push({agent:r.agent,dates:[r.date]}),z(n)>e){n.pop();break}s=s.slice(1)}return{heartbeatsToSend:n,unsentEntries:s}}class gt{constructor(e){this.app=e,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}async runIndexedDBEnvironmentCheck(){return ie()?oe().then(()=>!0).catch(()=>!1):!1}async read(){return await this._canUseIndexedDBPromise?await dt(this.app)||{heartbeats:[]}:{heartbeats:[]}}async overwrite(e){var n;if(await this._canUseIndexedDBPromise){const r=await this.read();return F(this.app,{lastSentHeartbeatDate:(n=e.lastSentHeartbeatDate)!==null&&n!==void 0?n:r.lastSentHeartbeatDate,heartbeats:e.heartbeats})}else return}async add(e){var n;if(await this._canUseIndexedDBPromise){const r=await this.read();return F(this.app,{lastSentHeartbeatDate:(n=e.lastSentHeartbeatDate)!==null&&n!==void 0?n:r.lastSentHeartbeatDate,heartbeats:[...r.heartbeats,...e.heartbeats]})}else return}}function z(t){return U(JSON.stringify({version:2,heartbeats:t})).length}/**
|
|
242
242
|
* @license
|
|
243
243
|
* Copyright 2019 Google LLC
|
|
244
244
|
*
|
|
@@ -253,7 +253,7 @@
|
|
|
253
253
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
254
254
|
* See the License for the specific language governing permissions and
|
|
255
255
|
* limitations under the License.
|
|
256
|
-
*/function
|
|
256
|
+
*/function bt(t){R(new D("platform-logger",e=>new Me(e),"PRIVATE")),R(new D("heartbeat",e=>new pt(e),"PRIVATE")),I(T,j,t),I(T,j,"esm2017"),I("fire-js","")}bt("");var Et="firebase",yt="9.10.0";/**
|
|
257
257
|
* @license
|
|
258
258
|
* Copyright 2020 Google LLC
|
|
259
259
|
*
|
|
@@ -268,4 +268,4 @@
|
|
|
268
268
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
269
269
|
* See the License for the specific language governing permissions and
|
|
270
270
|
* limitations under the License.
|
|
271
|
-
*/
|
|
271
|
+
*/I(Et,yt,"app");te();const _t=window.firebaseConfig||{apiKey:"AIzaSyCrVzemDgpyp9i6ni7Yc5ZuEVfXYwl-4J0",authDomain:"ecom2-002.firebaseapp.com",projectId:"ecom2-002",storageBucket:"ecom2-002.appspot.com",messagingSenderId:"402807248219",appId:"1:402807248219:web:cf7d57759751e74776367e",measurementId:"G-SC592CE0GB"};ct(_t);
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"name":"My Shop","short_name":"MyShop","start_url":"/","display":"standalone","background_color":"#f5f6fa","lang":"en","scope":"/","description":"My PWA Shop","theme_color":"#20c997","crossorigin":"use-credentials","icons":[{"src":"/img/icon.png","sizes":"192x192","type":"image/png"},{"src":"/img/large-icon.png","sizes":"512x512","type":"image/png"},{"src":"/img/large-icon.png","sizes":"512x512","type":"image/png","purpose":"any maskable"}]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
if(!self.define){let e,s={};const n=(n,i)=>(n=new URL(n+".js",i).href,s[n]||new Promise((s=>{if("document"in self){const e=document.createElement("script");e.src=n,e.onload=s,document.head.appendChild(e)}else e=n,importScripts(n),s()})).then((()=>{let e=s[n];if(!e)throw new Error(`Module ${n} didn’t register its module`);return e})));self.define=(i,o)=>{const r=e||("document"in self?document.currentScript.src:"")||location.href;if(s[r])return;let a={};const t=e=>n(e,r),c={module:{uri:r},exports:a,require:t};s[r]=Promise.all(i.map((e=>c[e]||t(e)))).then((e=>(o(...e),a)))}}define(["./workbox-8b24c3ff"],(function(e){"use strict";self.skipWaiting(),e.clientsClaim(),e.precacheAndRoute([{url:"chunks/workbox-window.prod.es5.4b654ae6.js",revision:null},{url:"client.80baece3.js",revision:null},{url:"hoisted.46e058d2.js",revision:null},{url:"page.3aa82516.js",revision:null},{url:"img/icon.png",revision:"791be7ee6538f26bb57bc31243a6e17e"},{url:"img/large-icon.png",revision:"0b35db516cfa7475b1c2f8c081e8d54d"},{url:"manifest.webmanifest",revision:"f3f24fe1b3d542152ca2f18813168ad6"}],{ignoreURLParametersMatching:[/.*/]}),e.cleanupOutdatedCaches(),e.registerRoute(/^\/$/,new e.NetworkFirst,"GET"),e.registerRoute(/^\/img\/uploads\/logo.webp$/,new e.StaleWhileRevalidate({cacheName:"logo",plugins:[]}),"GET"),e.registerRoute(/\/((?!(?:admin|assets|img)(\/|$))[^.]+)(\.(?!js|css|xml|txt|png|jpg|jpeg|webp|avif|svg|gif)[^.]+)*$/,new e.NetworkFirst({cacheName:"pages",plugins:[new e.ExpirationPlugin({maxEntries:50,purgeOnQuotaError:!0})]}),"GET"),e.registerRoute(/^\/assets\//,new e.StaleWhileRevalidate({cacheName:"assets",plugins:[]}),"GET"),e.registerRoute(/^\/img\/uploads\/.*\.(?:png|jpg|jpeg|webp|avif|svg|gif)$/,new e.StaleWhileRevalidate({cacheName:"cms-images",plugins:[new e.ExpirationPlugin({maxEntries:20,maxAgeSeconds:2592e3,purgeOnQuotaError:!0})]}),"GET"),e.registerRoute(/^https:\/\/ecomplus\.io/,new e.NetworkFirst({cacheName:"store-api",plugins:[new e.ExpirationPlugin({maxEntries:50,purgeOnQuotaError:!0})]}),"GET"),e.registerRoute(/^https:\/\/(((\w+\.)?ecoms\d)|(ecom[\w-]+(\.\w+)*\.digitaloceanspaces))\.com.*\/imgs\/normal\//,new e.CacheFirst({cacheName:"product-thumbnails",plugins:[new e.ExpirationPlugin({maxEntries:100,maxAgeSeconds:2592e3,purgeOnQuotaError:!0})]}),"GET"),e.registerRoute(/^https:\/\/(((\w+\.)?ecoms\d)|(ecom[\w-]+(\.\w+)*\.digitaloceanspaces))\.com.*\/imgs\/big\//,new e.CacheFirst({cacheName:"product-pictures",plugins:[new e.ExpirationPlugin({maxEntries:10,maxAgeSeconds:604800,purgeOnQuotaError:!0})]}),"GET")}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
define(["exports"],(function(t){"use strict";try{self["workbox:core:6.5.3"]&&_()}catch(t){}const e=(t,...e)=>{let s=t;return e.length>0&&(s+=` :: ${JSON.stringify(e)}`),s};class s extends Error{constructor(t,s){super(e(t,s)),this.name=t,this.details=s}}try{self["workbox:routing:6.5.3"]&&_()}catch(t){}const n=t=>t&&"object"==typeof t?t:{handle:t};class i{constructor(t,e,s="GET"){this.handler=n(e),this.match=t,this.method=s}setCatchHandler(t){this.catchHandler=n(t)}}class r extends i{constructor(t,e,s){super((({url:e})=>{const s=t.exec(e.href);if(s&&(e.origin===location.origin||0===s.index))return s.slice(1)}),e,s)}}class a{constructor(){this.t=new Map,this.i=new Map}get routes(){return this.t}addFetchListener(){self.addEventListener("fetch",(t=>{const{request:e}=t,s=this.handleRequest({request:e,event:t});s&&t.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(t=>{if(t.data&&"CACHE_URLS"===t.data.type){const{payload:e}=t.data,s=Promise.all(e.urlsToCache.map((e=>{"string"==typeof e&&(e=[e]);const s=new Request(...e);return this.handleRequest({request:s,event:t})})));t.waitUntil(s),t.ports&&t.ports[0]&&s.then((()=>t.ports[0].postMessage(!0)))}}))}handleRequest({request:t,event:e}){const s=new URL(t.url,location.href);if(!s.protocol.startsWith("http"))return;const n=s.origin===location.origin,{params:i,route:r}=this.findMatchingRoute({event:e,request:t,sameOrigin:n,url:s});let a=r&&r.handler;const o=t.method;if(!a&&this.i.has(o)&&(a=this.i.get(o)),!a)return;let c;try{c=a.handle({url:s,request:t,event:e,params:i})}catch(t){c=Promise.reject(t)}const h=r&&r.catchHandler;return c instanceof Promise&&(this.o||h)&&(c=c.catch((async n=>{if(h)try{return await h.handle({url:s,request:t,event:e,params:i})}catch(t){t instanceof Error&&(n=t)}if(this.o)return this.o.handle({url:s,request:t,event:e});throw n}))),c}findMatchingRoute({url:t,sameOrigin:e,request:s,event:n}){const i=this.t.get(s.method)||[];for(const r of i){let i;const a=r.match({url:t,sameOrigin:e,request:s,event:n});if(a)return i=a,(Array.isArray(i)&&0===i.length||a.constructor===Object&&0===Object.keys(a).length||"boolean"==typeof a)&&(i=void 0),{route:r,params:i}}return{}}setDefaultHandler(t,e="GET"){this.i.set(e,n(t))}setCatchHandler(t){this.o=n(t)}registerRoute(t){this.t.has(t.method)||this.t.set(t.method,[]),this.t.get(t.method).push(t)}unregisterRoute(t){if(!this.t.has(t.method))throw new s("unregister-route-but-not-found-with-method",{method:t.method});const e=this.t.get(t.method).indexOf(t);if(!(e>-1))throw new s("unregister-route-route-not-registered");this.t.get(t.method).splice(e,1)}}let o;const c=()=>(o||(o=new a,o.addFetchListener(),o.addCacheListener()),o);function h(t,e,n){let a;if("string"==typeof t){const s=new URL(t,location.href);a=new i((({url:t})=>t.href===s.href),e,n)}else if(t instanceof RegExp)a=new r(t,e,n);else if("function"==typeof t)a=new i(t,e,n);else{if(!(t instanceof i))throw new s("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});a=t}return c().registerRoute(a),a}try{self["workbox:strategies:6.5.3"]&&_()}catch(t){}const u={cacheWillUpdate:async({response:t})=>200===t.status||0===t.status?t:null},l={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},f=t=>[l.prefix,t,l.suffix].filter((t=>t&&t.length>0)).join("-"),w=t=>t||f(l.precache),d=t=>t||f(l.runtime);function p(t,e){const s=new URL(t);for(const t of e)s.searchParams.delete(t);return s.href}class y{constructor(){this.promise=new Promise(((t,e)=>{this.resolve=t,this.reject=e}))}}const m=new Set;function g(t){return"string"==typeof t?new Request(t):t}class R{constructor(t,e){this.h={},Object.assign(this,e),this.event=e.event,this.u=t,this.l=new y,this.p=[],this.m=[...t.plugins],this.g=new Map;for(const t of this.m)this.g.set(t,{});this.event.waitUntil(this.l.promise)}async fetch(t){const{event:e}=this;let n=g(t);if("navigate"===n.mode&&e instanceof FetchEvent&&e.preloadResponse){const t=await e.preloadResponse;if(t)return t}const i=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const t of this.iterateCallbacks("requestWillFetch"))n=await t({request:n.clone(),event:e})}catch(t){if(t instanceof Error)throw new s("plugin-error-request-will-fetch",{thrownErrorMessage:t.message})}const r=n.clone();try{let t;t=await fetch(n,"navigate"===n.mode?void 0:this.u.fetchOptions);for(const s of this.iterateCallbacks("fetchDidSucceed"))t=await s({event:e,request:r,response:t});return t}catch(t){throw i&&await this.runCallbacks("fetchDidFail",{error:t,event:e,originalRequest:i.clone(),request:r.clone()}),t}}async fetchAndCachePut(t){const e=await this.fetch(t),s=e.clone();return this.waitUntil(this.cachePut(t,s)),e}async cacheMatch(t){const e=g(t);let s;const{cacheName:n,matchOptions:i}=this.u,r=await this.getCacheKey(e,"read"),a=Object.assign(Object.assign({},i),{cacheName:n});s=await caches.match(r,a);for(const t of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await t({cacheName:n,matchOptions:i,cachedResponse:s,request:r,event:this.event})||void 0;return s}async cachePut(t,e){const n=g(t);var i;await(i=0,new Promise((t=>setTimeout(t,i))));const r=await this.getCacheKey(n,"write");if(!e)throw new s("cache-put-with-no-response",{url:(a=r.url,new URL(String(a),location.href).href.replace(new RegExp(`^${location.origin}`),""))});var a;const o=await this.R(e);if(!o)return!1;const{cacheName:c,matchOptions:h}=this.u,u=await self.caches.open(c),l=this.hasCallback("cacheDidUpdate"),f=l?await async function(t,e,s,n){const i=p(e.url,s);if(e.url===i)return t.match(e,n);const r=Object.assign(Object.assign({},n),{ignoreSearch:!0}),a=await t.keys(e,r);for(const e of a)if(i===p(e.url,s))return t.match(e,n)}(u,r.clone(),["__WB_REVISION__"],h):null;try{await u.put(r,l?o.clone():o)}catch(t){if(t instanceof Error)throw"QuotaExceededError"===t.name&&await async function(){for(const t of m)await t()}(),t}for(const t of this.iterateCallbacks("cacheDidUpdate"))await t({cacheName:c,oldResponse:f,newResponse:o.clone(),request:r,event:this.event});return!0}async getCacheKey(t,e){const s=`${t.url} | ${e}`;if(!this.h[s]){let n=t;for(const t of this.iterateCallbacks("cacheKeyWillBeUsed"))n=g(await t({mode:e,request:n,event:this.event,params:this.params}));this.h[s]=n}return this.h[s]}hasCallback(t){for(const e of this.u.plugins)if(t in e)return!0;return!1}async runCallbacks(t,e){for(const s of this.iterateCallbacks(t))await s(e)}*iterateCallbacks(t){for(const e of this.u.plugins)if("function"==typeof e[t]){const s=this.g.get(e),n=n=>{const i=Object.assign(Object.assign({},n),{state:s});return e[t](i)};yield n}}waitUntil(t){return this.p.push(t),t}async doneWaiting(){let t;for(;t=this.p.shift();)await t}destroy(){this.l.resolve(null)}async R(t){let e=t,s=!1;for(const t of this.iterateCallbacks("cacheWillUpdate"))if(e=await t({request:this.request,response:e,event:this.event})||void 0,s=!0,!e)break;return s||e&&200!==e.status&&(e=void 0),e}}class v{constructor(t={}){this.cacheName=d(t.cacheName),this.plugins=t.plugins||[],this.fetchOptions=t.fetchOptions,this.matchOptions=t.matchOptions}handle(t){const[e]=this.handleAll(t);return e}handleAll(t){t instanceof FetchEvent&&(t={event:t,request:t.request});const e=t.event,s="string"==typeof t.request?new Request(t.request):t.request,n="params"in t?t.params:void 0,i=new R(this,{event:e,request:s,params:n}),r=this.v(i,s,e);return[r,this.q(r,i,s,e)]}async v(t,e,n){let i;await t.runCallbacks("handlerWillStart",{event:n,request:e});try{if(i=await this.D(e,t),!i||"error"===i.type)throw new s("no-response",{url:e.url})}catch(s){if(s instanceof Error)for(const r of t.iterateCallbacks("handlerDidError"))if(i=await r({error:s,event:n,request:e}),i)break;if(!i)throw s}for(const s of t.iterateCallbacks("handlerWillRespond"))i=await s({event:n,request:e,response:i});return i}async q(t,e,s,n){let i,r;try{i=await t}catch(r){}try{await e.runCallbacks("handlerDidRespond",{event:n,request:s,response:i}),await e.doneWaiting()}catch(t){t instanceof Error&&(r=t)}if(await e.runCallbacks("handlerDidComplete",{event:n,request:s,response:i,error:r}),e.destroy(),r)throw r}}function b(t){t.then((()=>{}))}function q(){return q=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var s=arguments[e];for(var n in s)Object.prototype.hasOwnProperty.call(s,n)&&(t[n]=s[n])}return t},q.apply(this,arguments)}let D,U;const x=new WeakMap,I=new WeakMap,L=new WeakMap,E=new WeakMap,C=new WeakMap;let N={get(t,e,s){if(t instanceof IDBTransaction){if("done"===e)return I.get(t);if("objectStoreNames"===e)return t.objectStoreNames||L.get(t);if("store"===e)return s.objectStoreNames[1]?void 0:s.objectStore(s.objectStoreNames[0])}return B(t[e])},set:(t,e,s)=>(t[e]=s,!0),has:(t,e)=>t instanceof IDBTransaction&&("done"===e||"store"===e)||e in t};function O(t){return t!==IDBDatabase.prototype.transaction||"objectStoreNames"in IDBTransaction.prototype?(U||(U=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(t)?function(...e){return t.apply(T(this),e),B(x.get(this))}:function(...e){return B(t.apply(T(this),e))}:function(e,...s){const n=t.call(T(this),e,...s);return L.set(n,e.sort?e.sort():[e]),B(n)}}function k(t){return"function"==typeof t?O(t):(t instanceof IDBTransaction&&function(t){if(I.has(t))return;const e=new Promise(((e,s)=>{const n=()=>{t.removeEventListener("complete",i),t.removeEventListener("error",r),t.removeEventListener("abort",r)},i=()=>{e(),n()},r=()=>{s(t.error||new DOMException("AbortError","AbortError")),n()};t.addEventListener("complete",i),t.addEventListener("error",r),t.addEventListener("abort",r)}));I.set(t,e)}(t),e=t,(D||(D=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])).some((t=>e instanceof t))?new Proxy(t,N):t);var e}function B(t){if(t instanceof IDBRequest)return function(t){const e=new Promise(((e,s)=>{const n=()=>{t.removeEventListener("success",i),t.removeEventListener("error",r)},i=()=>{e(B(t.result)),n()},r=()=>{s(t.error),n()};t.addEventListener("success",i),t.addEventListener("error",r)}));return e.then((e=>{e instanceof IDBCursor&&x.set(e,t)})).catch((()=>{})),C.set(e,t),e}(t);if(E.has(t))return E.get(t);const e=k(t);return e!==t&&(E.set(t,e),C.set(e,t)),e}const T=t=>C.get(t);const M=["get","getKey","getAll","getAllKeys","count"],P=["put","add","delete","clear"],W=new Map;function j(t,e){if(!(t instanceof IDBDatabase)||e in t||"string"!=typeof e)return;if(W.get(e))return W.get(e);const s=e.replace(/FromIndex$/,""),n=e!==s,i=P.includes(s);if(!(s in(n?IDBIndex:IDBObjectStore).prototype)||!i&&!M.includes(s))return;const r=async function(t,...e){const r=this.transaction(t,i?"readwrite":"readonly");let a=r.store;return n&&(a=a.index(e.shift())),(await Promise.all([a[s](...e),i&&r.done]))[0]};return W.set(e,r),r}N=(t=>q({},t,{get:(e,s,n)=>j(e,s)||t.get(e,s,n),has:(e,s)=>!!j(e,s)||t.has(e,s)}))(N);try{self["workbox:expiration:6.5.3"]&&_()}catch(t){}const S="cache-entries",K=t=>{const e=new URL(t,location.href);return e.hash="",e.href};class A{constructor(t){this.U=null,this._=t}I(t){const e=t.createObjectStore(S,{keyPath:"id"});e.createIndex("cacheName","cacheName",{unique:!1}),e.createIndex("timestamp","timestamp",{unique:!1})}L(t){this.I(t),this._&&function(t,{blocked:e}={}){const s=indexedDB.deleteDatabase(t);e&&s.addEventListener("blocked",(()=>e())),B(s).then((()=>{}))}(this._)}async setTimestamp(t,e){const s={url:t=K(t),timestamp:e,cacheName:this._,id:this.C(t)},n=(await this.getDb()).transaction(S,"readwrite",{durability:"relaxed"});await n.store.put(s),await n.done}async getTimestamp(t){const e=await this.getDb(),s=await e.get(S,this.C(t));return null==s?void 0:s.timestamp}async expireEntries(t,e){const s=await this.getDb();let n=await s.transaction(S).store.index("timestamp").openCursor(null,"prev");const i=[];let r=0;for(;n;){const s=n.value;s.cacheName===this._&&(t&&s.timestamp<t||e&&r>=e?i.push(n.value):r++),n=await n.continue()}const a=[];for(const t of i)await s.delete(S,t.id),a.push(t.url);return a}C(t){return this._+"|"+K(t)}async getDb(){return this.U||(this.U=await function(t,e,{blocked:s,upgrade:n,blocking:i,terminated:r}={}){const a=indexedDB.open(t,e),o=B(a);return n&&a.addEventListener("upgradeneeded",(t=>{n(B(a.result),t.oldVersion,t.newVersion,B(a.transaction))})),s&&a.addEventListener("blocked",(()=>s())),o.then((t=>{r&&t.addEventListener("close",(()=>r())),i&&t.addEventListener("versionchange",(()=>i()))})).catch((()=>{})),o}("workbox-expiration",1,{upgrade:this.L.bind(this)})),this.U}}class F{constructor(t,e={}){this.N=!1,this.O=!1,this.k=e.maxEntries,this.B=e.maxAgeSeconds,this.T=e.matchOptions,this._=t,this.M=new A(t)}async expireEntries(){if(this.N)return void(this.O=!0);this.N=!0;const t=this.B?Date.now()-1e3*this.B:0,e=await this.M.expireEntries(t,this.k),s=await self.caches.open(this._);for(const t of e)await s.delete(t,this.T);this.N=!1,this.O&&(this.O=!1,b(this.expireEntries()))}async updateTimestamp(t){await this.M.setTimestamp(t,Date.now())}async isURLExpired(t){if(this.B){const e=await this.M.getTimestamp(t),s=Date.now()-1e3*this.B;return void 0===e||e<s}return!1}async delete(){this.O=!1,await this.M.expireEntries(1/0)}}function H(t,e){const s=e();return t.waitUntil(s),s}try{self["workbox:precaching:6.5.3"]&&_()}catch(t){}function $(t){if(!t)throw new s("add-to-cache-list-unexpected-type",{entry:t});if("string"==typeof t){const e=new URL(t,location.href);return{cacheKey:e.href,url:e.href}}const{revision:e,url:n}=t;if(!n)throw new s("add-to-cache-list-unexpected-type",{entry:t});if(!e){const t=new URL(n,location.href);return{cacheKey:t.href,url:t.href}}const i=new URL(n,location.href),r=new URL(n,location.href);return i.searchParams.set("__WB_REVISION__",e),{cacheKey:i.href,url:r.href}}class G{constructor(){this.updatedURLs=[],this.notUpdatedURLs=[],this.handlerWillStart=async({request:t,state:e})=>{e&&(e.originalRequest=t)},this.cachedResponseWillBeUsed=async({event:t,state:e,cachedResponse:s})=>{if("install"===t.type&&e&&e.originalRequest&&e.originalRequest instanceof Request){const t=e.originalRequest.url;s?this.notUpdatedURLs.push(t):this.updatedURLs.push(t)}return s}}}class V{constructor({precacheController:t}){this.cacheKeyWillBeUsed=async({request:t,params:e})=>{const s=(null==e?void 0:e.cacheKey)||this.P.getCacheKeyForURL(t.url);return s?new Request(s,{headers:t.headers}):t},this.P=t}}let J,Q;async function z(t,e){let n=null;if(t.url){n=new URL(t.url).origin}if(n!==self.location.origin)throw new s("cross-origin-copy-response",{origin:n});const i=t.clone(),r={headers:new Headers(i.headers),status:i.status,statusText:i.statusText},a=e?e(r):r,o=function(){if(void 0===J){const t=new Response("");if("body"in t)try{new Response(t.body),J=!0}catch(t){J=!1}J=!1}return J}()?i.body:await i.blob();return new Response(o,a)}class X extends v{constructor(t={}){t.cacheName=w(t.cacheName),super(t),this.W=!1!==t.fallbackToNetwork,this.plugins.push(X.copyRedirectedCacheableResponsesPlugin)}async D(t,e){const s=await e.cacheMatch(t);return s||(e.event&&"install"===e.event.type?await this.j(t,e):await this.S(t,e))}async S(t,e){let n;const i=e.params||{};if(!this.W)throw new s("missing-precache-entry",{cacheName:this.cacheName,url:t.url});{const s=i.integrity,r=t.integrity,a=!r||r===s;n=await e.fetch(new Request(t,{integrity:"no-cors"!==t.mode?r||s:void 0})),s&&a&&"no-cors"!==t.mode&&(this.K(),await e.cachePut(t,n.clone()))}return n}async j(t,e){this.K();const n=await e.fetch(t);if(!await e.cachePut(t,n.clone()))throw new s("bad-precaching-response",{url:t.url,status:n.status});return n}K(){let t=null,e=0;for(const[s,n]of this.plugins.entries())n!==X.copyRedirectedCacheableResponsesPlugin&&(n===X.defaultPrecacheCacheabilityPlugin&&(t=s),n.cacheWillUpdate&&e++);0===e?this.plugins.push(X.defaultPrecacheCacheabilityPlugin):e>1&&null!==t&&this.plugins.splice(t,1)}}X.defaultPrecacheCacheabilityPlugin={cacheWillUpdate:async({response:t})=>!t||t.status>=400?null:t},X.copyRedirectedCacheableResponsesPlugin={cacheWillUpdate:async({response:t})=>t.redirected?await z(t):t};class Y{constructor({cacheName:t,plugins:e=[],fallbackToNetwork:s=!0}={}){this.A=new Map,this.F=new Map,this.H=new Map,this.u=new X({cacheName:w(t),plugins:[...e,new V({precacheController:this})],fallbackToNetwork:s}),this.install=this.install.bind(this),this.activate=this.activate.bind(this)}get strategy(){return this.u}precache(t){this.addToCacheList(t),this.$||(self.addEventListener("install",this.install),self.addEventListener("activate",this.activate),this.$=!0)}addToCacheList(t){const e=[];for(const n of t){"string"==typeof n?e.push(n):n&&void 0===n.revision&&e.push(n.url);const{cacheKey:t,url:i}=$(n),r="string"!=typeof n&&n.revision?"reload":"default";if(this.A.has(i)&&this.A.get(i)!==t)throw new s("add-to-cache-list-conflicting-entries",{firstEntry:this.A.get(i),secondEntry:t});if("string"!=typeof n&&n.integrity){if(this.H.has(t)&&this.H.get(t)!==n.integrity)throw new s("add-to-cache-list-conflicting-integrities",{url:i});this.H.set(t,n.integrity)}if(this.A.set(i,t),this.F.set(i,r),e.length>0){const t=`Workbox is precaching URLs without revision info: ${e.join(", ")}\nThis is generally NOT safe. Learn more at https://bit.ly/wb-precache`;console.warn(t)}}}install(t){return H(t,(async()=>{const e=new G;this.strategy.plugins.push(e);for(const[e,s]of this.A){const n=this.H.get(s),i=this.F.get(e),r=new Request(e,{integrity:n,cache:i,credentials:"same-origin"});await Promise.all(this.strategy.handleAll({params:{cacheKey:s},request:r,event:t}))}const{updatedURLs:s,notUpdatedURLs:n}=e;return{updatedURLs:s,notUpdatedURLs:n}}))}activate(t){return H(t,(async()=>{const t=await self.caches.open(this.strategy.cacheName),e=await t.keys(),s=new Set(this.A.values()),n=[];for(const i of e)s.has(i.url)||(await t.delete(i),n.push(i.url));return{deletedURLs:n}}))}getURLsToCacheKeys(){return this.A}getCachedURLs(){return[...this.A.keys()]}getCacheKeyForURL(t){const e=new URL(t,location.href);return this.A.get(e.href)}getIntegrityForCacheKey(t){return this.H.get(t)}async matchPrecache(t){const e=t instanceof Request?t.url:t,s=this.getCacheKeyForURL(e);if(s){return(await self.caches.open(this.strategy.cacheName)).match(s)}}createHandlerBoundToURL(t){const e=this.getCacheKeyForURL(t);if(!e)throw new s("non-precached-url",{url:t});return s=>(s.request=new Request(t),s.params=Object.assign({cacheKey:e},s.params),this.strategy.handle(s))}}const Z=()=>(Q||(Q=new Y),Q);class tt extends i{constructor(t,e){super((({request:s})=>{const n=t.getURLsToCacheKeys();for(const i of function*(t,{ignoreURLParametersMatching:e=[/^utm_/,/^fbclid$/],directoryIndex:s="index.html",cleanURLs:n=!0,urlManipulation:i}={}){const r=new URL(t,location.href);r.hash="",yield r.href;const a=function(t,e=[]){for(const s of[...t.searchParams.keys()])e.some((t=>t.test(s)))&&t.searchParams.delete(s);return t}(r,e);if(yield a.href,s&&a.pathname.endsWith("/")){const t=new URL(a.href);t.pathname+=s,yield t.href}if(n){const t=new URL(a.href);t.pathname+=".html",yield t.href}if(i){const t=i({url:r});for(const e of t)yield e.href}}(s.url,e)){const e=n.get(i);if(e){return{cacheKey:e,integrity:t.getIntegrityForCacheKey(e)}}}}),t.strategy)}}t.CacheFirst=class extends v{async D(t,e){let n,i=await e.cacheMatch(t);if(!i)try{i=await e.fetchAndCachePut(t)}catch(t){t instanceof Error&&(n=t)}if(!i)throw new s("no-response",{url:t.url,error:n});return i}},t.ExpirationPlugin=class{constructor(t={}){this.cachedResponseWillBeUsed=async({event:t,request:e,cacheName:s,cachedResponse:n})=>{if(!n)return null;const i=this.G(n),r=this.V(s);b(r.expireEntries());const a=r.updateTimestamp(e.url);if(t)try{t.waitUntil(a)}catch(t){}return i?n:null},this.cacheDidUpdate=async({cacheName:t,request:e})=>{const s=this.V(t);await s.updateTimestamp(e.url),await s.expireEntries()},this.J=t,this.B=t.maxAgeSeconds,this.X=new Map,t.purgeOnQuotaError&&function(t){m.add(t)}((()=>this.deleteCacheAndMetadata()))}V(t){if(t===d())throw new s("expire-custom-caches-only");let e=this.X.get(t);return e||(e=new F(t,this.J),this.X.set(t,e)),e}G(t){if(!this.B)return!0;const e=this.Y(t);if(null===e)return!0;return e>=Date.now()-1e3*this.B}Y(t){if(!t.headers.has("date"))return null;const e=t.headers.get("date"),s=new Date(e).getTime();return isNaN(s)?null:s}async deleteCacheAndMetadata(){for(const[t,e]of this.X)await self.caches.delete(t),await e.delete();this.X=new Map}},t.NetworkFirst=class extends v{constructor(t={}){super(t),this.plugins.some((t=>"cacheWillUpdate"in t))||this.plugins.unshift(u),this.Z=t.networkTimeoutSeconds||0}async D(t,e){const n=[],i=[];let r;if(this.Z){const{id:s,promise:a}=this.tt({request:t,logs:n,handler:e});r=s,i.push(a)}const a=this.et({timeoutId:r,request:t,logs:n,handler:e});i.push(a);const o=await e.waitUntil((async()=>await e.waitUntil(Promise.race(i))||await a)());if(!o)throw new s("no-response",{url:t.url});return o}tt({request:t,logs:e,handler:s}){let n;return{promise:new Promise((e=>{n=setTimeout((async()=>{e(await s.cacheMatch(t))}),1e3*this.Z)})),id:n}}async et({timeoutId:t,request:e,logs:s,handler:n}){let i,r;try{r=await n.fetchAndCachePut(e)}catch(t){t instanceof Error&&(i=t)}return t&&clearTimeout(t),!i&&r||(r=await n.cacheMatch(e)),r}},t.StaleWhileRevalidate=class extends v{constructor(t={}){super(t),this.plugins.some((t=>"cacheWillUpdate"in t))||this.plugins.unshift(u)}async D(t,e){const n=e.fetchAndCachePut(t).catch((()=>{}));e.waitUntil(n);let i,r=await e.cacheMatch(t);if(r);else try{r=await n}catch(t){t instanceof Error&&(i=t)}if(!r)throw new s("no-response",{url:t.url,error:i});return r}},t.cleanupOutdatedCaches=function(){self.addEventListener("activate",(t=>{const e=w();t.waitUntil((async(t,e="-precache-")=>{const s=(await self.caches.keys()).filter((s=>s.includes(e)&&s.includes(self.registration.scope)&&s!==t));return await Promise.all(s.map((t=>self.caches.delete(t)))),s})(e).then((t=>{})))}))},t.clientsClaim=function(){self.addEventListener("activate",(()=>self.clients.claim()))},t.precacheAndRoute=function(t,e){!function(t){Z().precache(t)}(t),function(t){const e=Z();h(new tt(e,t))}(e)},t.registerRoute=h}));
|