buzzcasting-storage 3.15.8 → 3.15.10
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 +39 -40
- package/package.json +2 -2
|
@@ -118,11 +118,10 @@ const Ra = new Blob(
|
|
|
118
118
|
}`
|
|
119
119
|
],
|
|
120
120
|
{ type: "text/javascript" }
|
|
121
|
-
)
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
window.__bc.logger.postMessage({ action: "log", level: f, message: t });
|
|
121
|
+
), xa = new Worker(window.URL.createObjectURL(Ra), {
|
|
122
|
+
name: "logger"
|
|
123
|
+
}), j = async (f = 0, t) => {
|
|
124
|
+
xa.postMessage({ action: "log", level: f, message: t });
|
|
126
125
|
}, wt = (f) => {
|
|
127
126
|
switch (f?.type) {
|
|
128
127
|
case S.MESSAGES:
|
|
@@ -139,7 +138,7 @@ function Y(f) {
|
|
|
139
138
|
let t = `${f.type}.${f.topics}`;
|
|
140
139
|
return f.order && (t += `.${f.order}`), f.period && (t += `.${f.period}`), t;
|
|
141
140
|
}
|
|
142
|
-
function
|
|
141
|
+
function ka(f) {
|
|
143
142
|
if (f.widget === void 0) {
|
|
144
143
|
const t = f.topics?.split("-");
|
|
145
144
|
t && t.length > 1 ? (f.dashboard = t ? t[0] : "", f.widget = t ? t[1] : "") : (f.widget = f.topics, f.dashboard = f.slide);
|
|
@@ -163,8 +162,8 @@ function Ot(f, t) {
|
|
|
163
162
|
}
|
|
164
163
|
return t;
|
|
165
164
|
}
|
|
166
|
-
const
|
|
167
|
-
async function*
|
|
165
|
+
const Ca = "3.15.9";
|
|
166
|
+
async function* $a(f) {
|
|
168
167
|
const t = f.pipeThrough(new TextDecoderStream("utf-8")).getReader();
|
|
169
168
|
let o = "";
|
|
170
169
|
for (; ; ) {
|
|
@@ -178,7 +177,7 @@ async function* Ca(f) {
|
|
|
178
177
|
}
|
|
179
178
|
}
|
|
180
179
|
}
|
|
181
|
-
class
|
|
180
|
+
class ja {
|
|
182
181
|
options;
|
|
183
182
|
url;
|
|
184
183
|
constructor(t) {
|
|
@@ -257,7 +256,7 @@ class $a {
|
|
|
257
256
|
method: "post"
|
|
258
257
|
}
|
|
259
258
|
);
|
|
260
|
-
for await (const y of
|
|
259
|
+
for await (const y of $a(g.body))
|
|
261
260
|
console.log("Received", y);
|
|
262
261
|
}
|
|
263
262
|
async hideMessage(t) {
|
|
@@ -521,16 +520,16 @@ class $a {
|
|
|
521
520
|
}).then((y) => y.json()).catch((y) => ({ succes: !1, message: y, data: [] }));
|
|
522
521
|
}
|
|
523
522
|
}
|
|
524
|
-
var
|
|
525
|
-
function
|
|
523
|
+
var Ga = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
524
|
+
function Ma(f) {
|
|
526
525
|
return f && f.__esModule && Object.prototype.hasOwnProperty.call(f, "default") ? f.default : f;
|
|
527
526
|
}
|
|
528
|
-
var tr = { exports: {} },
|
|
529
|
-
function
|
|
527
|
+
var tr = { exports: {} }, Ka = tr.exports, Cn;
|
|
528
|
+
function La() {
|
|
530
529
|
return Cn || (Cn = 1, function(f, t) {
|
|
531
530
|
(function(o, u) {
|
|
532
531
|
f.exports = u();
|
|
533
|
-
})(
|
|
532
|
+
})(Ka, function() {
|
|
534
533
|
var o = function(e, r) {
|
|
535
534
|
return (o = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, a) {
|
|
536
535
|
n.__proto__ = a;
|
|
@@ -547,7 +546,7 @@ function Ka() {
|
|
|
547
546
|
for (var a, s = 0, c = r.length; s < c; s++) !a && s in r || ((a = a || Array.prototype.slice.call(r, 0, s))[s] = r[s]);
|
|
548
547
|
return e.concat(a || Array.prototype.slice.call(r));
|
|
549
548
|
}
|
|
550
|
-
var y = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window :
|
|
549
|
+
var y = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : Ga, I = Object.keys, M = Array.isArray;
|
|
551
550
|
function te(e, r) {
|
|
552
551
|
return typeof r != "object" || I(r).forEach(function(n) {
|
|
553
552
|
e[n] = r[n];
|
|
@@ -3536,21 +3535,21 @@ function Ka() {
|
|
|
3536
3535
|
});
|
|
3537
3536
|
}(tr)), tr.exports;
|
|
3538
3537
|
}
|
|
3539
|
-
var
|
|
3540
|
-
const Fr = /* @__PURE__ */
|
|
3538
|
+
var Ba = La();
|
|
3539
|
+
const Fr = /* @__PURE__ */ Ma(Ba), $n = Symbol.for("Dexie"), St = globalThis[$n] || (globalThis[$n] = Fr);
|
|
3541
3540
|
if (Fr.semVer !== St.semVer)
|
|
3542
3541
|
throw new Error(`Two different versions of Dexie loaded in the same app: ${Fr.semVer} and ${St.semVer}`);
|
|
3543
3542
|
const {
|
|
3544
|
-
liveQuery:
|
|
3545
|
-
mergeRanges:
|
|
3546
|
-
rangesOverlap:
|
|
3547
|
-
RangeSet:
|
|
3548
|
-
cmp:
|
|
3549
|
-
Entity:
|
|
3550
|
-
PropModification:
|
|
3551
|
-
replacePrefix:
|
|
3552
|
-
add:
|
|
3553
|
-
remove:
|
|
3543
|
+
liveQuery: Fa,
|
|
3544
|
+
mergeRanges: Ha,
|
|
3545
|
+
rangesOverlap: Va,
|
|
3546
|
+
RangeSet: za,
|
|
3547
|
+
cmp: Ya,
|
|
3548
|
+
Entity: Xa,
|
|
3549
|
+
PropModification: Qa,
|
|
3550
|
+
replacePrefix: Ja,
|
|
3551
|
+
add: Za,
|
|
3552
|
+
remove: qa
|
|
3554
3553
|
} = St;
|
|
3555
3554
|
class Gn {
|
|
3556
3555
|
db;
|
|
@@ -4095,7 +4094,7 @@ class Gn {
|
|
|
4095
4094
|
* @param query IQuery
|
|
4096
4095
|
* @returns null
|
|
4097
4096
|
*/
|
|
4098
|
-
subscribe = (t) => (t =
|
|
4097
|
+
subscribe = (t) => (t = ka(t), this.subscribers.filter(
|
|
4099
4098
|
(u) => u.widget === t.widget
|
|
4100
4099
|
).length > 0 || (t.type === S.MESSAGES && (t = Ot(this.options, t)), console.info(
|
|
4101
4100
|
"%cstorage%c %csubscribe",
|
|
@@ -4363,7 +4362,7 @@ function Hr(f) {
|
|
|
4363
4362
|
f.oncomplete = f.onsuccess = () => t(f.result), f.onabort = f.onerror = () => o(f.error);
|
|
4364
4363
|
});
|
|
4365
4364
|
}
|
|
4366
|
-
function
|
|
4365
|
+
function Ua(f, t) {
|
|
4367
4366
|
let o;
|
|
4368
4367
|
const u = () => {
|
|
4369
4368
|
if (o)
|
|
@@ -4378,7 +4377,7 @@ function Ba(f, t) {
|
|
|
4378
4377
|
}
|
|
4379
4378
|
let Wr;
|
|
4380
4379
|
function Mn() {
|
|
4381
|
-
return Wr || (Wr =
|
|
4380
|
+
return Wr || (Wr = Ua("keyval-store", "keyval")), Wr;
|
|
4382
4381
|
}
|
|
4383
4382
|
function _e(f, t = Mn()) {
|
|
4384
4383
|
return t("readonly", (o) => Hr(o.get(f)));
|
|
@@ -5700,7 +5699,7 @@ class Un {
|
|
|
5700
5699
|
success: !1
|
|
5701
5700
|
});
|
|
5702
5701
|
}
|
|
5703
|
-
class
|
|
5702
|
+
class es {
|
|
5704
5703
|
sm;
|
|
5705
5704
|
api;
|
|
5706
5705
|
bc;
|
|
@@ -5713,8 +5712,8 @@ class qa {
|
|
|
5713
5712
|
i.PRESENTATION,
|
|
5714
5713
|
t.presentation,
|
|
5715
5714
|
Q.VERSION,
|
|
5716
|
-
|
|
5717
|
-
]), this.options = t, this.sm = null, this.bc = new BroadcastChannel(this.options.presentation), this.api = new
|
|
5715
|
+
Ca
|
|
5716
|
+
]), this.options = t, this.sm = null, this.bc = new BroadcastChannel(this.options.presentation), this.api = new ja(t), t.storage) {
|
|
5718
5717
|
case pe.DEXIE:
|
|
5719
5718
|
this.sm = new Gn(t);
|
|
5720
5719
|
break;
|
|
@@ -6005,7 +6004,7 @@ class qa {
|
|
|
6005
6004
|
getHash = async (t, o) => await this.sm?.getHash(t, o);
|
|
6006
6005
|
setHash = async (t, o) => await this.sm?.setHash(t, o) ?? 400;
|
|
6007
6006
|
}
|
|
6008
|
-
class
|
|
6007
|
+
class Wa {
|
|
6009
6008
|
sm;
|
|
6010
6009
|
constructor(t) {
|
|
6011
6010
|
switch (this.sm = null, t.storage) {
|
|
@@ -6087,7 +6086,7 @@ class Ua {
|
|
|
6087
6086
|
success: !1
|
|
6088
6087
|
}) : await this.sm?.getSeries(t);
|
|
6089
6088
|
}
|
|
6090
|
-
class
|
|
6089
|
+
class ts {
|
|
6091
6090
|
storageReader;
|
|
6092
6091
|
broadcastChannel;
|
|
6093
6092
|
element;
|
|
@@ -6105,7 +6104,7 @@ class es {
|
|
|
6105
6104
|
const g = { ...t.dataset };
|
|
6106
6105
|
delete g.hmr;
|
|
6107
6106
|
const y = window.__bc.opts;
|
|
6108
|
-
g.presentation = y?.presentation ?? `${u} not found`, this.query = g, Na(t), this.storageReader = new
|
|
6107
|
+
g.presentation = y?.presentation ?? `${u} not found`, this.query = g, Na(t), this.storageReader = new Wa(y), this.broadcastChannel = new BroadcastChannel(g.presentation), this.broadcastListener();
|
|
6109
6108
|
}
|
|
6110
6109
|
addCallbackListener(t) {
|
|
6111
6110
|
this.callbacks.push(t);
|
|
@@ -6308,7 +6307,7 @@ class es {
|
|
|
6308
6307
|
}
|
|
6309
6308
|
}
|
|
6310
6309
|
export {
|
|
6311
|
-
|
|
6312
|
-
|
|
6313
|
-
|
|
6310
|
+
es as BuzzcastingStorageManager,
|
|
6311
|
+
Wa as BuzzcastingStorageReader,
|
|
6312
|
+
ts as Widget
|
|
6314
6313
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "buzzcasting-storage",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "3.15.
|
|
4
|
+
"version": "3.15.10",
|
|
5
5
|
"private": false,
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Mark Tamis, TouchFlows SAS",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"@typescript-eslint/eslint-plugin": "^8.46.2",
|
|
44
44
|
"@typescript-eslint/parser": "^8.46.2",
|
|
45
45
|
"@vitest/coverage-v8": "^4.0.1",
|
|
46
|
-
"buzzcasting-utils": "^1.9.
|
|
46
|
+
"buzzcasting-utils": "^1.9.5",
|
|
47
47
|
"camelcase": "^8.0.0",
|
|
48
48
|
"changelogen": "^0.6.2",
|
|
49
49
|
"eslint": "^9.38.0",
|