buzzcasting-storage 2.16.16 → 2.16.17
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/dist/buzzcasting-storage.esm.js +108 -107
- package/package.json +1 -1
|
@@ -2,7 +2,7 @@ var xi = Object.defineProperty;
|
|
|
2
2
|
var ki = (f, r, c) => r in f ? xi(f, r, { enumerable: !0, configurable: !0, writable: !0, value: c }) : f[r] = c;
|
|
3
3
|
var D = (f, r, c) => ki(f, typeof r != "symbol" ? r + "" : r, c);
|
|
4
4
|
var M = /* @__PURE__ */ ((f) => (f.MESSAGES = "messages", f.CLOUD = "cloud", f.SERIES = "series", f.TOPICS = "topics", f.WIDGET = "widget", f.WIDGETS = "widgets", f.SLIDE = "slide", f))(M || {}), _ = /* @__PURE__ */ ((f) => (f.API = "color:white;background-color:grey;padding:0 4px 0 4px;border-radius:5px;", f.APP = "color:white;background-color:navy;padding:0 4px 0 4px;border-radius:5px;", f.BROADCAST = "color:white;background-color:orange;padding:0 4px 0 4px;border-radius:5px;", f.DATA = "color:grey;background-color:lightskyblue;padding:0 4px 0 4px;border-radius:5px;", f.CLOUD = "color:grey;background-color:mistyrose;padding:0 4px 0 4px;border-radius:5px;", f.GET_DATA = "color:black;background-color:lime;padding:0 4px 0 4px;border-radius:5px;", f.HIDE = "color:white;background-color:red;padding:0 4px 0 4px;border-radius:5px;", f.MESSAGES = "color:grey;background-color:tan;padding:0 4px 0 4px;border-radius:5px;", f.NO_UPDATES = "color:grey;border:1px solid grey;padding:0 4px 0 4px;border-radius:5px;", f.NONE = "color:transparent;background-color:transparent;", f.PRESENTATION = "color:white;background-color:darkred;padding:0 4px 0 4px;border-radius:5px;", f.SERIES = "color:grey;background-color:thistle;padding:0 4px 0 4px;border-radius:5px;", f.SLIDE = "color:black;background-color:yellow;padding:0 4px 0 4px;border-radius:5px;", f.STORAGE = "color:black;background-color:cyan;padding:0 4px 0 4px;border-radius:5px;", f.SUBSCRIBE = "color:white;background-color:dodgerblue;padding:0 4px 0 4px;border-radius:5px;", f.WIDGET = "color:gret;background-color:lemonchiffon;padding:0 4px 0 4px;border-radius:5px;", f.WS = "color:white;background-color:green;padding:0 4px 0 4px;border-radius:5px;", f))(_ || {}), re = /* @__PURE__ */ ((f) => (f.ADD_SLIDE = "addSlide", f.APP_READY = "appReady", f.API_UPDATE = "apiUpdate", f.APPROVE_MESSAGE = "approveMessage", f.CHANNEL = "channel", f.CLEAN_MESSAGES = "cleanMessages", f.CLOSE_MODAL = "closeModal", f.ERROR = "error", f.HIDE_MESSAGE = "hideMessage", f.HIDE_LABELS = "hideLabels", f.PAUSE_PRESENTATION = "pausePresentation", f.PRESENTATION_READY = "presentationReady", f.PREV_SLIDE = "prevSlide", f.RELOAD_PRESENTATION = "reloadPresentation", f.SHOW_MODAL = "showModal", f.STAR_MESSAGE = "starMessage", f.GOTO_SLIDE = "gotoSlide", f.NEXT_SLIDE = "nextSlide", f.SLIDE_DID_LOAD = "slideDidLoad", f.SLIDE_GOTO = "slideGoto", f.SLIDE_READY = "slideReady", f.SLIDE_LOAD = "loadSlide", f.SLIDE_STORE = "storeSlide", f.SLIDE_TRANSITIONER = "slideTransitioner", f.START_TRANSITIONER = "startTransitioner", f.STORAGE_INIT = "storageInit", f.SUBSCRIBE = "subscribe", f.REMOVE_CLOUD = "removeCloud", f.UPDATE = "update", f.VERSION = "version", f.WIDGET_UPDATE = "widgetUpdate", f))(re || {}), Zt = /* @__PURE__ */ ((f) => (f.APPROVED = "approved", f.BEFORE = "before", f.DELAYED = "delayed", f.NONE = "none", f.REALTIME = "realtime", f))(Zt || {}), ge = /* @__PURE__ */ ((f) => (f.KEYVAL = "keyval", f.LOCAL = "local", f.SESSION = "session", f.DEXIE = "dexie", f.WINDOW = "window", f))(ge || {});
|
|
5
|
-
const Ai = "2.16.
|
|
5
|
+
const Ai = "2.16.16";
|
|
6
6
|
class Di {
|
|
7
7
|
constructor(r) {
|
|
8
8
|
D(this, "options");
|
|
@@ -163,15 +163,15 @@ var jr = { exports: {} };
|
|
|
163
163
|
return e.concat(i || Array.prototype.slice.call(t));
|
|
164
164
|
}
|
|
165
165
|
var k = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : Rr, N = Object.keys, B = Array.isArray;
|
|
166
|
-
function
|
|
166
|
+
function V(e, t) {
|
|
167
167
|
return typeof t != "object" || N(t).forEach(function(n) {
|
|
168
168
|
e[n] = t[n];
|
|
169
169
|
}), e;
|
|
170
170
|
}
|
|
171
171
|
typeof Promise > "u" || k.Promise || (k.Promise = Promise);
|
|
172
|
-
var q = Object.getPrototypeOf,
|
|
172
|
+
var q = Object.getPrototypeOf, oe = {}.hasOwnProperty;
|
|
173
173
|
function ne(e, t) {
|
|
174
|
-
return
|
|
174
|
+
return oe.call(e, t);
|
|
175
175
|
}
|
|
176
176
|
function xe(e, t) {
|
|
177
177
|
typeof t == "function" && (t = t(q(e))), (typeof Reflect > "u" ? N : Reflect.ownKeys)(t).forEach(function(n) {
|
|
@@ -180,7 +180,7 @@ var jr = { exports: {} };
|
|
|
180
180
|
}
|
|
181
181
|
var zn = Object.defineProperty;
|
|
182
182
|
function ke(e, t, n, i) {
|
|
183
|
-
zn(e, t,
|
|
183
|
+
zn(e, t, V(n && ne(n, "get") && typeof n.get == "function" ? { get: n.get, set: n.set, configurable: !0 } : { value: n, configurable: !0, writable: !0 }, i));
|
|
184
184
|
}
|
|
185
185
|
function ze(e) {
|
|
186
186
|
return { from: function(t) {
|
|
@@ -368,9 +368,9 @@ var jr = { exports: {} };
|
|
|
368
368
|
function Zr(e, t) {
|
|
369
369
|
return e === Q ? t : function(n) {
|
|
370
370
|
var i = e.apply(this, arguments);
|
|
371
|
-
|
|
371
|
+
V(n, i);
|
|
372
372
|
var a = this.onsuccess, o = this.onerror;
|
|
373
|
-
return this.onsuccess = null, this.onerror = null, n = t.apply(this, arguments), a && (this.onsuccess = this.onsuccess ? Ke(a, this.onsuccess) : a), o && (this.onerror = this.onerror ? Ke(o, this.onerror) : o), i === void 0 ? n === void 0 ? void 0 : n :
|
|
373
|
+
return this.onsuccess = null, this.onerror = null, n = t.apply(this, arguments), a && (this.onsuccess = this.onsuccess ? Ke(a, this.onsuccess) : a), o && (this.onerror = this.onerror ? Ke(o, this.onerror) : o), i === void 0 ? n === void 0 ? void 0 : n : V(i, n);
|
|
374
374
|
};
|
|
375
375
|
}
|
|
376
376
|
function qr(e, t) {
|
|
@@ -634,7 +634,7 @@ var jr = { exports: {} };
|
|
|
634
634
|
var ie = { awaits: 0, echoes: 0, id: 0 }, ni = 0, Pt = [], It = 0, Ct = 0, ri = 0;
|
|
635
635
|
function De(e, t, n, i) {
|
|
636
636
|
var a = L, o = Object.create(a);
|
|
637
|
-
return o.parent = a, o.ref = 0, o.global = !1, o.id = ++ri, Ae.env, o.env = an ? { Promise: K, PromiseProp: { value: K, configurable: !0, writable: !0 }, all: K.all, race: K.race, allSettled: K.allSettled, any: K.any, resolve: K.resolve, reject: K.reject } : {}, t &&
|
|
637
|
+
return o.parent = a, o.ref = 0, o.global = !1, o.id = ++ri, Ae.env, o.env = an ? { Promise: K, PromiseProp: { value: K, configurable: !0, writable: !0 }, all: K.all, race: K.race, allSettled: K.allSettled, any: K.any, resolve: K.resolve, reject: K.reject } : {}, t && V(o, t), ++a.ref, o.finalize = function() {
|
|
638
638
|
--this.parent.ref || this.parent.finalize();
|
|
639
639
|
}, i = Le(o, e, n, i), o.ref === 0 && o.finalize(), i;
|
|
640
640
|
}
|
|
@@ -739,7 +739,7 @@ var jr = { exports: {} };
|
|
|
739
739
|
function ur(e) {
|
|
740
740
|
return e instanceof Uint8Array ? e : ArrayBuffer.isView(e) ? new Uint8Array(e.buffer, e.byteOffset, e.byteLength) : new Uint8Array(e);
|
|
741
741
|
}
|
|
742
|
-
var lr = (
|
|
742
|
+
var lr = (J.prototype._trans = function(e, t, n) {
|
|
743
743
|
var i = this._tx || L.trans, a = this.name, o = ye && typeof console < "u" && console.createTask && console.createTask("Dexie: ".concat(e === "readonly" ? "read" : "write", " ").concat(this.name));
|
|
744
744
|
function s(h, b, d) {
|
|
745
745
|
if (!d.schema[a]) throw new G.NotFound("Table " + a + " not part of transaction");
|
|
@@ -788,14 +788,14 @@ var jr = { exports: {} };
|
|
|
788
788
|
} finally {
|
|
789
789
|
u && Ve();
|
|
790
790
|
}
|
|
791
|
-
},
|
|
791
|
+
}, J.prototype.get = function(e, t) {
|
|
792
792
|
var n = this;
|
|
793
793
|
return e && e.constructor === Object ? this.where(e).first(t) : e == null ? ee(new G.Type("Invalid argument to Table.get()")) : this._trans("readonly", function(i) {
|
|
794
794
|
return n.core.get({ trans: i, key: e }).then(function(a) {
|
|
795
795
|
return n.hook.reading.fire(a);
|
|
796
796
|
});
|
|
797
797
|
}).then(t);
|
|
798
|
-
},
|
|
798
|
+
}, J.prototype.where = function(e) {
|
|
799
799
|
if (typeof e == "string") return new this.db.WhereClause(this, e);
|
|
800
800
|
if (B(e)) return new this.db.WhereClause(this, "[".concat(e.join("+"), "]"));
|
|
801
801
|
var t = N(e);
|
|
@@ -833,25 +833,25 @@ var jr = { exports: {} };
|
|
|
833
833
|
}) : d];
|
|
834
834
|
}, [null, null]), s = u[0], u = u[1];
|
|
835
835
|
return s ? this.where(s.name).equals(e[s.keyPath]).filter(u) : n ? this.filter(u) : this.where(t).equals("");
|
|
836
|
-
},
|
|
836
|
+
}, J.prototype.filter = function(e) {
|
|
837
837
|
return this.toCollection().and(e);
|
|
838
|
-
},
|
|
838
|
+
}, J.prototype.count = function(e) {
|
|
839
839
|
return this.toCollection().count(e);
|
|
840
|
-
},
|
|
840
|
+
}, J.prototype.offset = function(e) {
|
|
841
841
|
return this.toCollection().offset(e);
|
|
842
|
-
},
|
|
842
|
+
}, J.prototype.limit = function(e) {
|
|
843
843
|
return this.toCollection().limit(e);
|
|
844
|
-
},
|
|
844
|
+
}, J.prototype.each = function(e) {
|
|
845
845
|
return this.toCollection().each(e);
|
|
846
|
-
},
|
|
846
|
+
}, J.prototype.toArray = function(e) {
|
|
847
847
|
return this.toCollection().toArray(e);
|
|
848
|
-
},
|
|
848
|
+
}, J.prototype.toCollection = function() {
|
|
849
849
|
return new this.db.Collection(new this.db.WhereClause(this));
|
|
850
|
-
},
|
|
850
|
+
}, J.prototype.orderBy = function(e) {
|
|
851
851
|
return new this.db.Collection(new this.db.WhereClause(this, B(e) ? "[".concat(e.join("+"), "]") : e));
|
|
852
|
-
},
|
|
852
|
+
}, J.prototype.reverse = function() {
|
|
853
853
|
return this.toCollection().reverse();
|
|
854
|
-
},
|
|
854
|
+
}, J.prototype.mapToClass = function(e) {
|
|
855
855
|
var t, n = this.db, i = this.name;
|
|
856
856
|
function a() {
|
|
857
857
|
return t !== null && t.apply(this, arguments) || this;
|
|
@@ -880,11 +880,11 @@ var jr = { exports: {} };
|
|
|
880
880
|
return b;
|
|
881
881
|
}
|
|
882
882
|
return this.schema.readHook && this.hook.reading.unsubscribe(this.schema.readHook), this.schema.readHook = u, this.hook("reading", u), e;
|
|
883
|
-
},
|
|
883
|
+
}, J.prototype.defineClass = function() {
|
|
884
884
|
return this.mapToClass(function(e) {
|
|
885
|
-
|
|
885
|
+
V(this, e);
|
|
886
886
|
});
|
|
887
|
-
},
|
|
887
|
+
}, J.prototype.add = function(e, t) {
|
|
888
888
|
var n = this, i = this.schema.primKey, a = i.auto, o = i.keyPath, s = e;
|
|
889
889
|
return o && a && (s = jt(o)(e)), this._trans("readwrite", function(u) {
|
|
890
890
|
return n.core.mutate({ trans: u, type: "add", keys: t != null ? [t] : null, values: [s] });
|
|
@@ -897,9 +897,9 @@ var jr = { exports: {} };
|
|
|
897
897
|
}
|
|
898
898
|
return u;
|
|
899
899
|
});
|
|
900
|
-
},
|
|
900
|
+
}, J.prototype.update = function(e, t) {
|
|
901
901
|
return typeof e != "object" || B(e) ? this.where(":id").equals(e).modify(t) : (e = ve(e, this.schema.primKey.keyPath), e === void 0 ? ee(new G.InvalidArgument("Given object does not contain its primary key")) : this.where(":id").equals(e).modify(t));
|
|
902
|
-
},
|
|
902
|
+
}, J.prototype.put = function(e, t) {
|
|
903
903
|
var n = this, i = this.schema.primKey, a = i.auto, o = i.keyPath, s = e;
|
|
904
904
|
return o && a && (s = jt(o)(e)), this._trans("readwrite", function(u) {
|
|
905
905
|
return n.core.mutate({ trans: u, type: "put", values: [s], keys: t != null ? [t] : null });
|
|
@@ -912,21 +912,21 @@ var jr = { exports: {} };
|
|
|
912
912
|
}
|
|
913
913
|
return u;
|
|
914
914
|
});
|
|
915
|
-
},
|
|
915
|
+
}, J.prototype.delete = function(e) {
|
|
916
916
|
var t = this;
|
|
917
917
|
return this._trans("readwrite", function(n) {
|
|
918
918
|
return t.core.mutate({ trans: n, type: "delete", keys: [e] });
|
|
919
919
|
}).then(function(n) {
|
|
920
920
|
return n.numFailures ? K.reject(n.failures[0]) : void 0;
|
|
921
921
|
});
|
|
922
|
-
},
|
|
922
|
+
}, J.prototype.clear = function() {
|
|
923
923
|
var e = this;
|
|
924
924
|
return this._trans("readwrite", function(t) {
|
|
925
925
|
return e.core.mutate({ trans: t, type: "deleteRange", range: or });
|
|
926
926
|
}).then(function(t) {
|
|
927
927
|
return t.numFailures ? K.reject(t.failures[0]) : void 0;
|
|
928
928
|
});
|
|
929
|
-
},
|
|
929
|
+
}, J.prototype.bulkGet = function(e) {
|
|
930
930
|
var t = this;
|
|
931
931
|
return this._trans("readonly", function(n) {
|
|
932
932
|
return t.core.getMany({ keys: e, trans: n }).then(function(i) {
|
|
@@ -935,7 +935,7 @@ var jr = { exports: {} };
|
|
|
935
935
|
});
|
|
936
936
|
});
|
|
937
937
|
});
|
|
938
|
-
},
|
|
938
|
+
}, J.prototype.bulkAdd = function(e, t, n) {
|
|
939
939
|
var i = this, a = Array.isArray(t) ? t : void 0, o = (n = n || (a ? void 0 : t)) ? n.allKeys : void 0;
|
|
940
940
|
return this._trans("readwrite", function(s) {
|
|
941
941
|
var h = i.schema.primKey, u = h.auto, h = h.keyPath;
|
|
@@ -948,7 +948,7 @@ var jr = { exports: {} };
|
|
|
948
948
|
throw new Qe("".concat(i.name, ".bulkAdd(): ").concat(d, " of ").concat(g, " operations failed"), m);
|
|
949
949
|
});
|
|
950
950
|
});
|
|
951
|
-
},
|
|
951
|
+
}, J.prototype.bulkPut = function(e, t, n) {
|
|
952
952
|
var i = this, a = Array.isArray(t) ? t : void 0, o = (n = n || (a ? void 0 : t)) ? n.allKeys : void 0;
|
|
953
953
|
return this._trans("readwrite", function(s) {
|
|
954
954
|
var h = i.schema.primKey, u = h.auto, h = h.keyPath;
|
|
@@ -961,7 +961,7 @@ var jr = { exports: {} };
|
|
|
961
961
|
throw new Qe("".concat(i.name, ".bulkPut(): ").concat(d, " of ").concat(g, " operations failed"), m);
|
|
962
962
|
});
|
|
963
963
|
});
|
|
964
|
-
},
|
|
964
|
+
}, J.prototype.bulkUpdate = function(e) {
|
|
965
965
|
var t = this, n = this.core, i = e.map(function(s) {
|
|
966
966
|
return s.key;
|
|
967
967
|
}), a = e.map(function(s) {
|
|
@@ -994,7 +994,7 @@ var jr = { exports: {} };
|
|
|
994
994
|
});
|
|
995
995
|
});
|
|
996
996
|
});
|
|
997
|
-
},
|
|
997
|
+
}, J.prototype.bulkDelete = function(e) {
|
|
998
998
|
var t = this, n = e.length;
|
|
999
999
|
return this._trans("readwrite", function(i) {
|
|
1000
1000
|
return t.core.mutate({ trans: i, type: "delete", keys: e });
|
|
@@ -1003,8 +1003,8 @@ var jr = { exports: {} };
|
|
|
1003
1003
|
if (a === 0) return o;
|
|
1004
1004
|
throw new Qe("".concat(t.name, ".bulkDelete(): ").concat(a, " of ").concat(n, " operations failed"), s);
|
|
1005
1005
|
});
|
|
1006
|
-
},
|
|
1007
|
-
function
|
|
1006
|
+
}, J);
|
|
1007
|
+
function J() {
|
|
1008
1008
|
}
|
|
1009
1009
|
function dt(e) {
|
|
1010
1010
|
function t(s, u) {
|
|
@@ -1152,7 +1152,7 @@ var jr = { exports: {} };
|
|
|
1152
1152
|
return Kt(this._ctx, e, t, this._ctx.table.core);
|
|
1153
1153
|
}, Y.prototype.clone = function(e) {
|
|
1154
1154
|
var t = Object.create(this.constructor.prototype), n = Object.create(this._ctx);
|
|
1155
|
-
return e &&
|
|
1155
|
+
return e && V(n, e), t._ctx = n, t;
|
|
1156
1156
|
}, Y.prototype.raw = function() {
|
|
1157
1157
|
return this._ctx.valueMapper = null, this;
|
|
1158
1158
|
}, Y.prototype.each = function(e) {
|
|
@@ -1742,27 +1742,27 @@ var jr = { exports: {} };
|
|
|
1742
1742
|
var P, $ = (E || O || { length: 1 }).length;
|
|
1743
1743
|
if (E && O && E.length !== O.length) throw new Error("Given keys array must have same length as given values array.");
|
|
1744
1744
|
if ($ === 0) return I({ numFailures: 0, failures: {}, results: [], lastResult: void 0 });
|
|
1745
|
-
function F(
|
|
1746
|
-
++pe, pt(
|
|
1745
|
+
function F(le) {
|
|
1746
|
+
++pe, pt(le);
|
|
1747
1747
|
}
|
|
1748
1748
|
var z = [], U = [], pe = 0;
|
|
1749
1749
|
if (S === "deleteRange") {
|
|
1750
1750
|
if (x.type === 4) return I({ numFailures: pe, failures: U, results: [], lastResult: void 0 });
|
|
1751
1751
|
x.type === 3 ? z.push(P = C.clear()) : z.push(P = C.delete(i(x)));
|
|
1752
1752
|
} else {
|
|
1753
|
-
var R = j ? R ? [O, E] : [O, null] : [E, null], W = R[0],
|
|
1754
|
-
if (j) for (var
|
|
1755
|
-
else for (
|
|
1753
|
+
var R = j ? R ? [O, E] : [O, null] : [E, null], W = R[0], se = R[1];
|
|
1754
|
+
if (j) for (var ce = 0; ce < $; ++ce) z.push(P = se && se[ce] !== void 0 ? C[S](W[ce], se[ce]) : C[S](W[ce])), P.onerror = F;
|
|
1755
|
+
else for (ce = 0; ce < $; ++ce) z.push(P = C[S](W[ce])), P.onerror = F;
|
|
1756
1756
|
}
|
|
1757
|
-
function Vt(
|
|
1758
|
-
|
|
1757
|
+
function Vt(le) {
|
|
1758
|
+
le = le.target.result, z.forEach(function(We, Ln) {
|
|
1759
1759
|
return We.error != null && (U[Ln] = We.error);
|
|
1760
1760
|
}), I({ numFailures: pe, failures: U, results: S === "delete" ? E : z.map(function(We) {
|
|
1761
1761
|
return We.result;
|
|
1762
|
-
}), lastResult:
|
|
1762
|
+
}), lastResult: le });
|
|
1763
1763
|
}
|
|
1764
|
-
P.onerror = function(
|
|
1765
|
-
F(
|
|
1764
|
+
P.onerror = function(le) {
|
|
1765
|
+
F(le), Vt(le);
|
|
1766
1766
|
}, P.onsuccess = Vt;
|
|
1767
1767
|
});
|
|
1768
1768
|
}, getMany: function(w) {
|
|
@@ -1807,31 +1807,31 @@ var jr = { exports: {} };
|
|
|
1807
1807
|
}, W.trans = y, W.stop = W.continue = W.continuePrimaryKey = W.advance = function() {
|
|
1808
1808
|
throw new Error("Cursor not started");
|
|
1809
1809
|
}, W.fail = Z(T), W.next = function() {
|
|
1810
|
-
var
|
|
1810
|
+
var se = this, ce = 1;
|
|
1811
1811
|
return this.start(function() {
|
|
1812
|
-
return
|
|
1812
|
+
return ce-- ? se.continue() : se.stop();
|
|
1813
1813
|
}).then(function() {
|
|
1814
|
-
return
|
|
1814
|
+
return se;
|
|
1815
1815
|
});
|
|
1816
|
-
}, W.start = function(
|
|
1817
|
-
function
|
|
1816
|
+
}, W.start = function(se) {
|
|
1817
|
+
function ce() {
|
|
1818
1818
|
if (P.result) try {
|
|
1819
|
-
|
|
1820
|
-
} catch (
|
|
1821
|
-
W.fail(
|
|
1819
|
+
se();
|
|
1820
|
+
} catch (le) {
|
|
1821
|
+
W.fail(le);
|
|
1822
1822
|
}
|
|
1823
1823
|
else W.done = !0, W.start = function() {
|
|
1824
1824
|
throw new Error("Cursor behind last entry");
|
|
1825
1825
|
}, W.stop();
|
|
1826
1826
|
}
|
|
1827
|
-
var Vt = new Promise(function(
|
|
1828
|
-
|
|
1829
|
-
W.stop = W.continue = W.continuePrimaryKey = W.advance = pe,
|
|
1827
|
+
var Vt = new Promise(function(le, We) {
|
|
1828
|
+
le = Z(le), P.onerror = me(We), W.fail = We, W.stop = function(Ln) {
|
|
1829
|
+
W.stop = W.continue = W.continuePrimaryKey = W.advance = pe, le(Ln);
|
|
1830
1830
|
};
|
|
1831
1831
|
});
|
|
1832
|
-
return P.onsuccess = Z(function(
|
|
1833
|
-
P.onsuccess =
|
|
1834
|
-
}), W.continue = F, W.continuePrimaryKey = z, W.advance = U,
|
|
1832
|
+
return P.onsuccess = Z(function(le) {
|
|
1833
|
+
P.onsuccess = ce, ce();
|
|
1834
|
+
}), W.continue = F, W.continuePrimaryKey = z, W.advance = U, ce(), Vt;
|
|
1835
1835
|
}, I(W)) : I(null);
|
|
1836
1836
|
}, T);
|
|
1837
1837
|
});
|
|
@@ -2062,10 +2062,10 @@ var jr = { exports: {} };
|
|
|
2062
2062
|
});
|
|
2063
2063
|
}, Ut.prototype.stores = function(n) {
|
|
2064
2064
|
var t = this.db;
|
|
2065
|
-
this._cfg.storesSource = this._cfg.storesSource ?
|
|
2065
|
+
this._cfg.storesSource = this._cfg.storesSource ? V(this._cfg.storesSource, n) : n;
|
|
2066
2066
|
var n = t._versions, i = {}, a = {};
|
|
2067
2067
|
return n.forEach(function(o) {
|
|
2068
|
-
|
|
2068
|
+
V(i, o._cfg.storesSource), a = o._cfg.dbschema = {}, o._parseStoresSpec(i, a);
|
|
2069
2069
|
}), t._dbSchema = a, Sn(t, [t._allTables, t, t.Transaction.prototype]), Lt(t, [t._allTables, t, t.Transaction.prototype, this._cfg.tables], N(a), a), t._storeNames = N(a), this;
|
|
2070
2070
|
}, Ut.prototype.upgrade = function(e) {
|
|
2071
2071
|
return this._cfg.contentUpgrade = rn(this._cfg.contentUpgrade || Q, e), this;
|
|
@@ -2087,18 +2087,18 @@ var jr = { exports: {} };
|
|
|
2087
2087
|
function Dn(e) {
|
|
2088
2088
|
return !("from" in e);
|
|
2089
2089
|
}
|
|
2090
|
-
var
|
|
2090
|
+
var ue = function(e, t) {
|
|
2091
2091
|
if (!this) {
|
|
2092
|
-
var n = new
|
|
2093
|
-
return e && "d" in e &&
|
|
2092
|
+
var n = new ue();
|
|
2093
|
+
return e && "d" in e && V(n, e), n;
|
|
2094
2094
|
}
|
|
2095
|
-
|
|
2095
|
+
V(this, arguments.length ? { d: 1, from: e, to: 1 < arguments.length ? t : e } : { d: 0 });
|
|
2096
2096
|
};
|
|
2097
2097
|
function bt(e, t, n) {
|
|
2098
2098
|
var i = H(t, n);
|
|
2099
2099
|
if (!isNaN(i)) {
|
|
2100
2100
|
if (0 < i) throw RangeError();
|
|
2101
|
-
if (Dn(e)) return
|
|
2101
|
+
if (Dn(e)) return V(e, { from: t, to: n, d: 1 });
|
|
2102
2102
|
var a = e.l, i = e.r;
|
|
2103
2103
|
if (H(n, e.from) < 0) return a ? bt(a, t, n) : e.l = { from: t, to: n, d: 1, l: null, r: null }, _r(e);
|
|
2104
2104
|
if (0 < H(t, e.to)) return i ? bt(i, t, n) : e.r = { from: t, to: n, d: 1, l: null, r: null }, _r(e);
|
|
@@ -2162,7 +2162,7 @@ var jr = { exports: {} };
|
|
|
2162
2162
|
return t[n] && wr(t[n], e[n]);
|
|
2163
2163
|
});
|
|
2164
2164
|
}
|
|
2165
|
-
xe(
|
|
2165
|
+
xe(ue.prototype, ((he = { add: function(e) {
|
|
2166
2166
|
return vt(this, e), this;
|
|
2167
2167
|
}, addKey: function(e) {
|
|
2168
2168
|
return bt(this, e, e), this;
|
|
@@ -2293,8 +2293,8 @@ var jr = { exports: {} };
|
|
|
2293
2293
|
var v;
|
|
2294
2294
|
return d && (v = {}, e.tables.forEach(function(p) {
|
|
2295
2295
|
p.schema.indexes.forEach(function(m) {
|
|
2296
|
-
m.name && (v["idb://".concat(e.name, "/").concat(p.name, "/").concat(m.name)] = new
|
|
2297
|
-
}), v["idb://".concat(e.name, "/").concat(p.name, "/")] = v["idb://".concat(e.name, "/").concat(p.name, "/:dels")] = new
|
|
2296
|
+
m.name && (v["idb://".concat(e.name, "/").concat(p.name, "/").concat(m.name)] = new ue(-1 / 0, [[[]]]));
|
|
2297
|
+
}), v["idb://".concat(e.name, "/").concat(p.name, "/")] = v["idb://".concat(e.name, "/").concat(p.name, "/:dels")] = new ue(-1 / 0, [[[]]]);
|
|
2298
2298
|
}), Re(gt).fire(v), Rn(v, !0)), e;
|
|
2299
2299
|
});
|
|
2300
2300
|
}
|
|
@@ -2473,7 +2473,7 @@ var jr = { exports: {} };
|
|
|
2473
2473
|
}
|
|
2474
2474
|
}
|
|
2475
2475
|
var wi = { stack: "dbcore", level: 0, name: "Observability", create: function(e) {
|
|
2476
|
-
var t = e.schema.name, n = new
|
|
2476
|
+
var t = e.schema.name, n = new ue(e.MIN_KEY, e.MAX_KEY);
|
|
2477
2477
|
return l(l({}, e), { transaction: function(i, a, o) {
|
|
2478
2478
|
if (L.subscr && a !== "readonly") throw new G.ReadOnly("Readwrite transaction in liveQuery context. Querier source: ".concat(L.querier));
|
|
2479
2479
|
return e.transaction(i, a, o);
|
|
@@ -2482,7 +2482,7 @@ var jr = { exports: {} };
|
|
|
2482
2482
|
return p.compound && p.keyPath.includes(s.keyPath);
|
|
2483
2483
|
}), b = l(l({}, a), { mutate: function(p) {
|
|
2484
2484
|
function m(P) {
|
|
2485
|
-
return P = "idb://".concat(t, "/").concat(i, "/").concat(P), O[P] || (O[P] = new
|
|
2485
|
+
return P = "idb://".concat(t, "/").concat(i, "/").concat(P), O[P] || (O[P] = new ue());
|
|
2486
2486
|
}
|
|
2487
2487
|
var w, y, S, E = p.trans, O = p.mutatedParts || (p.mutatedParts = {}), x = m(""), I = m(":dels"), T = p.type, j = p.type === "deleteRange" ? [p.range] : p.type === "delete" ? [p.keys] : p.values.length < 50 ? [Mn(s, p).filter(function(P) {
|
|
2488
2488
|
return P;
|
|
@@ -2497,9 +2497,9 @@ var jr = { exports: {} };
|
|
|
2497
2497
|
return $.addKey(pe);
|
|
2498
2498
|
}) : $.addKey(U);
|
|
2499
2499
|
}
|
|
2500
|
-
(y || S).forEach(function(U,
|
|
2501
|
-
var W = y && F(y[
|
|
2502
|
-
H(W,
|
|
2500
|
+
(y || S).forEach(function(U, se) {
|
|
2501
|
+
var W = y && F(y[se]), se = S && F(S[se]);
|
|
2502
|
+
H(W, se) !== 0 && (W != null && z(W), se != null && z(se));
|
|
2503
2503
|
});
|
|
2504
2504
|
}))) : C ? (R = { from: C.lower, to: C.upper }, I.add(R), x.add(R)) : (x.add(n), I.add(n), o.indexes.forEach(function(P) {
|
|
2505
2505
|
return m(P.name).add(n);
|
|
@@ -2517,18 +2517,18 @@ var jr = { exports: {} };
|
|
|
2517
2517
|
});
|
|
2518
2518
|
} }), d = function(m) {
|
|
2519
2519
|
var w = m.query, m = w.index, w = w.range;
|
|
2520
|
-
return [m, new
|
|
2520
|
+
return [m, new ue((m = w.lower) !== null && m !== void 0 ? m : e.MIN_KEY, (w = w.upper) !== null && w !== void 0 ? w : e.MAX_KEY)];
|
|
2521
2521
|
}, v = { get: function(p) {
|
|
2522
|
-
return [s, new
|
|
2522
|
+
return [s, new ue(p.key)];
|
|
2523
2523
|
}, getMany: function(p) {
|
|
2524
|
-
return [s, new
|
|
2524
|
+
return [s, new ue().addKeys(p.keys)];
|
|
2525
2525
|
}, count: d, query: d, openCursor: d };
|
|
2526
2526
|
return N(v).forEach(function(p) {
|
|
2527
2527
|
b[p] = function(m) {
|
|
2528
2528
|
var w = L.subscr, y = !!w, S = xr(L, a) && kr(p, m) ? m.obsSet = {} : w;
|
|
2529
2529
|
if (y) {
|
|
2530
2530
|
var E = function(R) {
|
|
2531
|
-
return R = "idb://".concat(t, "/").concat(i, "/").concat(R), S[R] || (S[R] = new
|
|
2531
|
+
return R = "idb://".concat(t, "/").concat(i, "/").concat(R), S[R] || (S[R] = new ue());
|
|
2532
2532
|
}, O = E(""), x = E(":dels"), w = v[p](m), y = w[0], w = w[1];
|
|
2533
2533
|
if ((p === "query" && y.isPrimaryKey && !m.values ? x : E(y.name || "")).add(w), !y.isPrimaryKey) {
|
|
2534
2534
|
if (p !== "count") {
|
|
@@ -2580,7 +2580,7 @@ var jr = { exports: {} };
|
|
|
2580
2580
|
if (!v || v.length === 0) return e;
|
|
2581
2581
|
var s = t.query.index, u = s.multiEntry, g = t.query.range, h = i.schema.primaryKey.extractKey, b = s.extractKey, d = (s.lowLevelIndex || s).extractKey, v = v.reduce(function(p, m) {
|
|
2582
2582
|
var w = p, y = [];
|
|
2583
|
-
if (m.type === "add" || m.type === "put") for (var S = new
|
|
2583
|
+
if (m.type === "add" || m.type === "put") for (var S = new ue(), E = m.values.length - 1; 0 <= E; --E) {
|
|
2584
2584
|
var O, x = m.values[E], I = h(x);
|
|
2585
2585
|
S.hasKey(I) || (O = b(x), (u && B(O) ? O.some(function(j) {
|
|
2586
2586
|
return Kn(j, g);
|
|
@@ -2593,7 +2593,7 @@ var jr = { exports: {} };
|
|
|
2593
2593
|
}));
|
|
2594
2594
|
break;
|
|
2595
2595
|
case "put":
|
|
2596
|
-
var T = new
|
|
2596
|
+
var T = new ue().addKeys(m.values.map(function(P) {
|
|
2597
2597
|
return h(P);
|
|
2598
2598
|
})), w = p.filter(function(P) {
|
|
2599
2599
|
return !T.hasKey(t.values ? h(P) : P);
|
|
@@ -2602,7 +2602,7 @@ var jr = { exports: {} };
|
|
|
2602
2602
|
}));
|
|
2603
2603
|
break;
|
|
2604
2604
|
case "delete":
|
|
2605
|
-
var C = new
|
|
2605
|
+
var C = new ue().addKeys(m.keys);
|
|
2606
2606
|
w = p.filter(function(P) {
|
|
2607
2607
|
return !C.hasKey(t.values ? h(P) : P);
|
|
2608
2608
|
});
|
|
@@ -3073,7 +3073,7 @@ var jr = { exports: {} };
|
|
|
3073
3073
|
var t, n;
|
|
3074
3074
|
}, defineClass: function() {
|
|
3075
3075
|
return function(e) {
|
|
3076
|
-
|
|
3076
|
+
V(this, e);
|
|
3077
3077
|
};
|
|
3078
3078
|
}, ignoreTransaction: function(e) {
|
|
3079
3079
|
return L.trans ? Le(L.transless, e) : e();
|
|
@@ -3101,7 +3101,7 @@ var jr = { exports: {} };
|
|
|
3101
3101
|
return ye;
|
|
3102
3102
|
}, set: function(e) {
|
|
3103
3103
|
qn(e);
|
|
3104
|
-
} }, derive: ze, extend:
|
|
3104
|
+
} }, derive: ze, extend: V, props: xe, override: Hn, Events: dt, on: Re, liveQuery: Ir, extendObservabilitySet: zt, getByKeyPath: ve, setByKeyPath: de, delByKeyPath: function(e, t) {
|
|
3105
3105
|
typeof t == "string" ? de(e, t, void 0) : "length" in t && [].map.call(t, function(n) {
|
|
3106
3106
|
de(e, n, void 0);
|
|
3107
3107
|
});
|
|
@@ -3128,7 +3128,7 @@ var jr = { exports: {} };
|
|
|
3128
3128
|
for (var t = 0, n = Ze; t < n.length; t++) n[t].close({ disableAutoOpen: !1 });
|
|
3129
3129
|
}
|
|
3130
3130
|
}), addEventListener("pageshow", function(e) {
|
|
3131
|
-
!Ee.disableBfCache && e.persisted && (ye && console.debug("Dexie: handling persisted pageshow"), Cr(), Bn({ all: new
|
|
3131
|
+
!Ee.disableBfCache && e.persisted && (ye && console.debug("Dexie: handling persisted pageshow"), Cr(), Bn({ all: new ue(-1 / 0, [[]]) }));
|
|
3132
3132
|
})), K.rejectionMapper = function(e, t) {
|
|
3133
3133
|
return !e || e instanceof Ye || e instanceof TypeError || e instanceof SyntaxError || !e.name || !Zn[e.name] ? e : (t = new Zn[e.name](t || e.message, e), "stack" in e && ke(t, "stack", { get: function() {
|
|
3134
3134
|
return this.inner.stack;
|
|
@@ -3139,7 +3139,7 @@ var jr = { exports: {} };
|
|
|
3139
3139
|
return new ht({ add: e });
|
|
3140
3140
|
}, remove: function(e) {
|
|
3141
3141
|
return new ht({ remove: e });
|
|
3142
|
-
}, default: Ee, RangeSet:
|
|
3142
|
+
}, default: Ee, RangeSet: ue, mergeRanges: vt, rangesOverlap: wr }), { default: Ee }), Ee;
|
|
3143
3143
|
});
|
|
3144
3144
|
})(jr);
|
|
3145
3145
|
var Ii = jr.exports;
|
|
@@ -3238,9 +3238,9 @@ class Mr {
|
|
|
3238
3238
|
if (k.length === 0)
|
|
3239
3239
|
return { data: null, message: "No Messages error", success: !1 };
|
|
3240
3240
|
const N = k[0] ? k[0].title : "No title", B = k.map(
|
|
3241
|
-
(
|
|
3242
|
-
), q = (await this.db.table(M.MESSAGES).where("id").anyOf(B).toArray().then((
|
|
3243
|
-
(
|
|
3241
|
+
(oe) => oe.message_id
|
|
3242
|
+
), q = (await this.db.table(M.MESSAGES).where("id").anyOf(B).toArray().then((oe) => oe.sort((ne, xe) => xe.utc - ne.utc))).map(
|
|
3243
|
+
(oe) => oe.data
|
|
3244
3244
|
);
|
|
3245
3245
|
return {
|
|
3246
3246
|
data: {
|
|
@@ -3292,20 +3292,20 @@ class Mr {
|
|
|
3292
3292
|
const l = c.data.title;
|
|
3293
3293
|
let A = 0;
|
|
3294
3294
|
return c.data.messages.forEach(async (k) => {
|
|
3295
|
-
var N, B,
|
|
3295
|
+
var N, B, V, q;
|
|
3296
3296
|
k.id !== null && (await this.db.table(M.MESSAGES).put({
|
|
3297
3297
|
id: k.id,
|
|
3298
3298
|
utc: k.utc,
|
|
3299
3299
|
data: k,
|
|
3300
3300
|
expires: k.expires
|
|
3301
|
-
}).catch((
|
|
3301
|
+
}).catch((oe) => {
|
|
3302
3302
|
A++, console.error(
|
|
3303
3303
|
"%cstorage",
|
|
3304
3304
|
_.STORAGE,
|
|
3305
3305
|
"set message",
|
|
3306
3306
|
`title: ${l}`,
|
|
3307
3307
|
k,
|
|
3308
|
-
|
|
3308
|
+
oe.message
|
|
3309
3309
|
);
|
|
3310
3310
|
}), await this.db.table(M.TOPICS).put({
|
|
3311
3311
|
widget_id: r.widget,
|
|
@@ -3314,29 +3314,30 @@ class Mr {
|
|
|
3314
3314
|
title: l,
|
|
3315
3315
|
engagement: (N = k.dynamics) == null ? void 0 : N.engagement,
|
|
3316
3316
|
impressions: (B = k.dynamics) == null ? void 0 : B.semrush_visits,
|
|
3317
|
-
reach: (
|
|
3317
|
+
reach: (V = k.dynamics) == null ? void 0 : V.potential_reach,
|
|
3318
3318
|
sentiment: ((q = k.topics[0]) == null ? void 0 : q.sentiment) || 0,
|
|
3319
3319
|
utc: k.utc,
|
|
3320
3320
|
expires: k.expires
|
|
3321
|
-
}).catch((
|
|
3321
|
+
}).catch((oe) => {
|
|
3322
3322
|
A++, console.error(
|
|
3323
3323
|
"%cstorage",
|
|
3324
3324
|
_.STORAGE,
|
|
3325
3325
|
"set topic",
|
|
3326
3326
|
`title: ${l}`,
|
|
3327
3327
|
k,
|
|
3328
|
-
|
|
3328
|
+
oe.message
|
|
3329
3329
|
);
|
|
3330
3330
|
}));
|
|
3331
3331
|
}), c.data.topics.forEach(async (k) => {
|
|
3332
|
-
|
|
3332
|
+
const N = k.messsage_id, B = k.visible ? 1 : 0, V = k.title, q = k.topic;
|
|
3333
|
+
await this.db.table(M.TOPICS).where("message_id").equals(N).modify({ visible: B }).catch((oe) => {
|
|
3333
3334
|
A++, console.error(
|
|
3334
3335
|
"%cstorage",
|
|
3335
3336
|
_.STORAGE,
|
|
3336
3337
|
"update message visibility",
|
|
3337
|
-
`title: ${
|
|
3338
|
-
|
|
3339
|
-
|
|
3338
|
+
`title: ${V}`,
|
|
3339
|
+
q,
|
|
3340
|
+
oe.message
|
|
3340
3341
|
);
|
|
3341
3342
|
});
|
|
3342
3343
|
}), A === 0 ? 201 : 400;
|
|
@@ -4199,13 +4200,13 @@ class Ji {
|
|
|
4199
4200
|
if (this.sm === null)
|
|
4200
4201
|
return 400;
|
|
4201
4202
|
if (B.success === !0) {
|
|
4202
|
-
const
|
|
4203
|
+
const V = this.sm.subscribers.filter(
|
|
4203
4204
|
(ne) => ne.widget === B.query.widget
|
|
4204
4205
|
)[0];
|
|
4205
|
-
let q = "",
|
|
4206
|
+
let q = "", oe;
|
|
4206
4207
|
switch (B.query.type) {
|
|
4207
4208
|
case M.MESSAGES:
|
|
4208
|
-
if (
|
|
4209
|
+
if (oe = B.data.messages.filter((ne) => ne.id !== null), B.data.messages = oe, q = $n(B.data.messages), V.hash === q)
|
|
4209
4210
|
return console.debug(
|
|
4210
4211
|
"%capi%c %cno updates",
|
|
4211
4212
|
_.API,
|
|
@@ -4215,10 +4216,10 @@ class Ji {
|
|
|
4215
4216
|
B.query.slide,
|
|
4216
4217
|
B.query.widget
|
|
4217
4218
|
), 204;
|
|
4218
|
-
|
|
4219
|
+
V.hash = q, N = await this.sm.setMessages(B.query, B);
|
|
4219
4220
|
break;
|
|
4220
4221
|
case M.CLOUD:
|
|
4221
|
-
q = $n(B.data),
|
|
4222
|
+
q = $n(B.data), V.hash === q ? (console.debug(
|
|
4222
4223
|
"%capi%c %cno updates",
|
|
4223
4224
|
_.API,
|
|
4224
4225
|
_.NONE,
|
|
@@ -4226,10 +4227,10 @@ class Ji {
|
|
|
4226
4227
|
M.CLOUD,
|
|
4227
4228
|
B.query.slide,
|
|
4228
4229
|
B.query.widget
|
|
4229
|
-
), N = 204) : (
|
|
4230
|
+
), N = 204) : (V.hash = q, N = await this.sm.setCloud(B.query, B));
|
|
4230
4231
|
break;
|
|
4231
4232
|
case M.SERIES:
|
|
4232
|
-
q = $n(B.data),
|
|
4233
|
+
q = $n(B.data), V.hash === q ? (console.debug(
|
|
4233
4234
|
"%capi%c %cno updates",
|
|
4234
4235
|
_.API,
|
|
4235
4236
|
_.NONE,
|
|
@@ -4237,7 +4238,7 @@ class Ji {
|
|
|
4237
4238
|
M.SERIES,
|
|
4238
4239
|
B.query.slide,
|
|
4239
4240
|
B.query.widget
|
|
4240
|
-
), N = 204) : (
|
|
4241
|
+
), N = 204) : (V.hash = q, N = await this.sm.setSeries(B.query, B));
|
|
4241
4242
|
break;
|
|
4242
4243
|
default:
|
|
4243
4244
|
console.warn(
|