@nil-/xit 0.1.12 → 0.1.13
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/assets/bundler.js +3 -3
- package/assets/index.js +195 -191
- package/package.json +1 -1
package/assets/index.js
CHANGED
|
@@ -108,8 +108,8 @@ function asPromise$1(i, e) {
|
|
|
108
108
|
if (u = !1, l)
|
|
109
109
|
o(l);
|
|
110
110
|
else {
|
|
111
|
-
for (var d = new Array(arguments.length - 1),
|
|
112
|
-
d[
|
|
111
|
+
for (var d = new Array(arguments.length - 1), c = 0; c < d.length; )
|
|
112
|
+
d[c++] = arguments[c];
|
|
113
113
|
s.apply(null, d);
|
|
114
114
|
}
|
|
115
115
|
};
|
|
@@ -134,43 +134,43 @@ var base64$1 = {};
|
|
|
134
134
|
for (var n = new Array(64), a = new Array(123), f = 0; f < 64; )
|
|
135
135
|
a[n[f] = f < 26 ? f + 65 : f < 52 ? f + 71 : f < 62 ? f - 4 : f - 59 | 43] = f++;
|
|
136
136
|
e.encode = function(s, o, r) {
|
|
137
|
-
for (var l = null, d = [],
|
|
137
|
+
for (var l = null, d = [], c = 0, h = 0, p; o < r; ) {
|
|
138
138
|
var m = s[o++];
|
|
139
|
-
switch (
|
|
139
|
+
switch (h) {
|
|
140
140
|
case 0:
|
|
141
|
-
d[
|
|
141
|
+
d[c++] = n[m >> 2], p = (m & 3) << 4, h = 1;
|
|
142
142
|
break;
|
|
143
143
|
case 1:
|
|
144
|
-
d[
|
|
144
|
+
d[c++] = n[p | m >> 4], p = (m & 15) << 2, h = 2;
|
|
145
145
|
break;
|
|
146
146
|
case 2:
|
|
147
|
-
d[
|
|
147
|
+
d[c++] = n[p | m >> 6], d[c++] = n[m & 63], h = 0;
|
|
148
148
|
break;
|
|
149
149
|
}
|
|
150
|
-
|
|
150
|
+
c > 8191 && ((l || (l = [])).push(String.fromCharCode.apply(String, d)), c = 0);
|
|
151
151
|
}
|
|
152
|
-
return
|
|
152
|
+
return h && (d[c++] = n[p], d[c++] = 61, h === 1 && (d[c++] = 61)), l ? (c && l.push(String.fromCharCode.apply(String, d.slice(0, c))), l.join("")) : String.fromCharCode.apply(String, d.slice(0, c));
|
|
153
153
|
};
|
|
154
154
|
var u = "invalid encoding";
|
|
155
155
|
e.decode = function(s, o, r) {
|
|
156
|
-
for (var l = r, d = 0,
|
|
157
|
-
var p = s.charCodeAt(
|
|
156
|
+
for (var l = r, d = 0, c, h = 0; h < s.length; ) {
|
|
157
|
+
var p = s.charCodeAt(h++);
|
|
158
158
|
if (p === 61 && d > 1)
|
|
159
159
|
break;
|
|
160
160
|
if ((p = a[p]) === void 0)
|
|
161
161
|
throw Error(u);
|
|
162
162
|
switch (d) {
|
|
163
163
|
case 0:
|
|
164
|
-
|
|
164
|
+
c = p, d = 1;
|
|
165
165
|
break;
|
|
166
166
|
case 1:
|
|
167
|
-
o[r++] =
|
|
167
|
+
o[r++] = c << 2 | (p & 48) >> 4, c = p, d = 2;
|
|
168
168
|
break;
|
|
169
169
|
case 2:
|
|
170
|
-
o[r++] = (
|
|
170
|
+
o[r++] = (c & 15) << 4 | (p & 60) >> 2, c = p, d = 3;
|
|
171
171
|
break;
|
|
172
172
|
case 3:
|
|
173
|
-
o[r++] = (
|
|
173
|
+
o[r++] = (c & 3) << 6 | p, d = 0;
|
|
174
174
|
break;
|
|
175
175
|
}
|
|
176
176
|
}
|
|
@@ -300,8 +300,8 @@ function factory(i) {
|
|
|
300
300
|
}
|
|
301
301
|
i.writeDoubleLE = e.bind(null, writeUintLE, 0, 4), i.writeDoubleBE = e.bind(null, writeUintBE, 4, 0);
|
|
302
302
|
function n(a, f, u, t, s) {
|
|
303
|
-
var o = a(t, s + f), r = a(t, s + u), l = (r >> 31) * 2 + 1, d = r >>> 20 & 2047,
|
|
304
|
-
return d === 2047 ?
|
|
303
|
+
var o = a(t, s + f), r = a(t, s + u), l = (r >> 31) * 2 + 1, d = r >>> 20 & 2047, c = 4294967296 * (r & 1048575) + o;
|
|
304
|
+
return d === 2047 ? c ? NaN : l * (1 / 0) : d === 0 ? l * 5e-324 * c : l * Math.pow(2, d - 1075) * (c + 4503599627370496);
|
|
305
305
|
}
|
|
306
306
|
i.readDoubleLE = n.bind(null, readUintLE, 0, 4), i.readDoubleBE = n.bind(null, readUintBE, 4, 0);
|
|
307
307
|
}(), i;
|
|
@@ -986,10 +986,10 @@ function codegen(i, e) {
|
|
|
986
986
|
}
|
|
987
987
|
return Function(t)();
|
|
988
988
|
}
|
|
989
|
-
for (var d = new Array(arguments.length - 1),
|
|
990
|
-
d[
|
|
991
|
-
if (
|
|
992
|
-
var b = d[
|
|
989
|
+
for (var d = new Array(arguments.length - 1), c = 0; c < d.length; )
|
|
990
|
+
d[c] = arguments[++c];
|
|
991
|
+
if (c = 0, u = u.replace(/%([%dfijs])/g, function(p, m) {
|
|
992
|
+
var b = d[c++];
|
|
993
993
|
switch (m) {
|
|
994
994
|
case "d":
|
|
995
995
|
case "f":
|
|
@@ -1002,7 +1002,7 @@ function codegen(i, e) {
|
|
|
1002
1002
|
return String(b);
|
|
1003
1003
|
}
|
|
1004
1004
|
return "%";
|
|
1005
|
-
}),
|
|
1005
|
+
}), c !== d.length)
|
|
1006
1006
|
throw Error("parameter count mismatch");
|
|
1007
1007
|
return n.push(u), a;
|
|
1008
1008
|
}
|
|
@@ -1250,8 +1250,8 @@ function requireField() {
|
|
|
1250
1250
|
t.fromJSON = function(o, r) {
|
|
1251
1251
|
return new t(o, r.id, r.type, r.rule, r.extend, r.options, r.comment);
|
|
1252
1252
|
};
|
|
1253
|
-
function t(s, o, r, l, d,
|
|
1254
|
-
if (a.isObject(l) ? (
|
|
1253
|
+
function t(s, o, r, l, d, c, h) {
|
|
1254
|
+
if (a.isObject(l) ? (h = d, c = l, l = d = void 0) : a.isObject(d) && (h = c, c = d, d = void 0), i.call(this, s, c), !a.isInteger(o) || o < 0)
|
|
1255
1255
|
throw TypeError("id must be a non-negative integer");
|
|
1256
1256
|
if (!a.isString(r))
|
|
1257
1257
|
throw TypeError("type must be a string");
|
|
@@ -1262,7 +1262,7 @@ function requireField() {
|
|
|
1262
1262
|
l === "proto3_optional" && (l = "optional"), this.rule = l && l !== "optional" ? l : void 0, this.type = r, this.id = o, this.extend = d || void 0, this.required = l === "required", this.optional = !this.required, this.repeated = l === "repeated", this.map = !1, this.message = null, this.partOf = null, this.typeDefault = null, this.defaultValue = null, this.long = a.Long ? n.long[r] !== void 0 : (
|
|
1263
1263
|
/* istanbul ignore next */
|
|
1264
1264
|
!1
|
|
1265
|
-
), this.bytes = r === "bytes", this.resolvedType = null, this.extensionField = null, this.declaringField = null, this._packed = null, this.comment =
|
|
1265
|
+
), this.bytes = r === "bytes", this.resolvedType = null, this.extensionField = null, this.declaringField = null, this._packed = null, this.comment = h;
|
|
1266
1266
|
}
|
|
1267
1267
|
return Object.defineProperty(t.prototype, "packed", {
|
|
1268
1268
|
get: function() {
|
|
@@ -1297,8 +1297,8 @@ function requireField() {
|
|
|
1297
1297
|
}
|
|
1298
1298
|
return this.map ? this.defaultValue = a.emptyObject : this.repeated ? this.defaultValue = a.emptyArray : this.defaultValue = this.typeDefault, this.parent instanceof f && (this.parent.ctor.prototype[this.name] = this.defaultValue), i.prototype.resolve.call(this);
|
|
1299
1299
|
}, t.d = function(o, r, l, d) {
|
|
1300
|
-
return typeof r == "function" ? r = a.decorateType(r).name : r && typeof r == "object" && (r = a.decorateEnum(r).name), function(
|
|
1301
|
-
a.decorateType(
|
|
1300
|
+
return typeof r == "function" ? r = a.decorateType(r).name : r && typeof r == "object" && (r = a.decorateEnum(r).name), function(h, p) {
|
|
1301
|
+
a.decorateType(h.constructor).add(new t(p, o, r, l, { default: d }));
|
|
1302
1302
|
};
|
|
1303
1303
|
}, t._configure = function(o) {
|
|
1304
1304
|
f = o;
|
|
@@ -1374,27 +1374,27 @@ function requireNamespace() {
|
|
|
1374
1374
|
var i = requireObject();
|
|
1375
1375
|
((o.prototype = Object.create(i.prototype)).constructor = o).className = "Namespace";
|
|
1376
1376
|
var e = requireField(), n = requireUtil(), a = requireOneof(), f, u, t;
|
|
1377
|
-
o.fromJSON = function(d,
|
|
1378
|
-
return new o(d,
|
|
1377
|
+
o.fromJSON = function(d, c) {
|
|
1378
|
+
return new o(d, c.options).addJSON(c.nested);
|
|
1379
1379
|
};
|
|
1380
1380
|
function s(l, d) {
|
|
1381
1381
|
if (l && l.length) {
|
|
1382
|
-
for (var
|
|
1383
|
-
|
|
1384
|
-
return
|
|
1382
|
+
for (var c = {}, h = 0; h < l.length; ++h)
|
|
1383
|
+
c[l[h].name] = l[h].toJSON(d);
|
|
1384
|
+
return c;
|
|
1385
1385
|
}
|
|
1386
1386
|
}
|
|
1387
|
-
o.arrayToJSON = s, o.isReservedId = function(d,
|
|
1387
|
+
o.arrayToJSON = s, o.isReservedId = function(d, c) {
|
|
1388
1388
|
if (d) {
|
|
1389
|
-
for (var
|
|
1390
|
-
if (typeof d[
|
|
1389
|
+
for (var h = 0; h < d.length; ++h)
|
|
1390
|
+
if (typeof d[h] != "string" && d[h][0] <= c && d[h][1] > c)
|
|
1391
1391
|
return !0;
|
|
1392
1392
|
}
|
|
1393
1393
|
return !1;
|
|
1394
|
-
}, o.isReservedName = function(d,
|
|
1394
|
+
}, o.isReservedName = function(d, c) {
|
|
1395
1395
|
if (d) {
|
|
1396
|
-
for (var
|
|
1397
|
-
if (d[
|
|
1396
|
+
for (var h = 0; h < d.length; ++h)
|
|
1397
|
+
if (d[h] === c)
|
|
1398
1398
|
return !0;
|
|
1399
1399
|
}
|
|
1400
1400
|
return !1;
|
|
@@ -1417,12 +1417,12 @@ function requireNamespace() {
|
|
|
1417
1417
|
s(this.nestedArray, d)
|
|
1418
1418
|
]);
|
|
1419
1419
|
}, o.prototype.addJSON = function(d) {
|
|
1420
|
-
var
|
|
1420
|
+
var c = this;
|
|
1421
1421
|
if (d)
|
|
1422
|
-
for (var
|
|
1423
|
-
m = d[
|
|
1422
|
+
for (var h = Object.keys(d), p = 0, m; p < h.length; ++p)
|
|
1423
|
+
m = d[h[p]], c.add(
|
|
1424
1424
|
// most to least likely
|
|
1425
|
-
(m.fields !== void 0 ? f.fromJSON : m.values !== void 0 ? t.fromJSON : m.methods !== void 0 ? u.fromJSON : m.id !== void 0 ? e.fromJSON : o.fromJSON)(
|
|
1425
|
+
(m.fields !== void 0 ? f.fromJSON : m.values !== void 0 ? t.fromJSON : m.methods !== void 0 ? u.fromJSON : m.id !== void 0 ? e.fromJSON : o.fromJSON)(h[p], m)
|
|
1426
1426
|
);
|
|
1427
1427
|
return this;
|
|
1428
1428
|
}, o.prototype.get = function(d) {
|
|
@@ -1437,12 +1437,12 @@ function requireNamespace() {
|
|
|
1437
1437
|
if (!this.nested)
|
|
1438
1438
|
this.nested = {};
|
|
1439
1439
|
else {
|
|
1440
|
-
var
|
|
1441
|
-
if (
|
|
1442
|
-
if (
|
|
1443
|
-
for (var
|
|
1444
|
-
d.add(
|
|
1445
|
-
this.remove(
|
|
1440
|
+
var c = this.get(d.name);
|
|
1441
|
+
if (c)
|
|
1442
|
+
if (c instanceof o && d instanceof o && !(c instanceof f || c instanceof u)) {
|
|
1443
|
+
for (var h = c.nestedArray, p = 0; p < h.length; ++p)
|
|
1444
|
+
d.add(h[p]);
|
|
1445
|
+
this.remove(c), this.nested || (this.nested = {}), d.setOptions(c.options, !0);
|
|
1446
1446
|
} else
|
|
1447
1447
|
throw Error("duplicate name '" + d.name + "' in " + this);
|
|
1448
1448
|
}
|
|
@@ -1453,69 +1453,69 @@ function requireNamespace() {
|
|
|
1453
1453
|
if (d.parent !== this)
|
|
1454
1454
|
throw Error(d + " is not a member of " + this);
|
|
1455
1455
|
return delete this.nested[d.name], Object.keys(this.nested).length || (this.nested = void 0), d.onRemove(this), r(this);
|
|
1456
|
-
}, o.prototype.define = function(d,
|
|
1456
|
+
}, o.prototype.define = function(d, c) {
|
|
1457
1457
|
if (n.isString(d))
|
|
1458
1458
|
d = d.split(".");
|
|
1459
1459
|
else if (!Array.isArray(d))
|
|
1460
1460
|
throw TypeError("illegal path");
|
|
1461
1461
|
if (d && d.length && d[0] === "")
|
|
1462
1462
|
throw Error("path must be relative");
|
|
1463
|
-
for (var
|
|
1463
|
+
for (var h = this; d.length > 0; ) {
|
|
1464
1464
|
var p = d.shift();
|
|
1465
|
-
if (
|
|
1466
|
-
if (
|
|
1465
|
+
if (h.nested && h.nested[p]) {
|
|
1466
|
+
if (h = h.nested[p], !(h instanceof o))
|
|
1467
1467
|
throw Error("path conflicts with non-namespace objects");
|
|
1468
1468
|
} else
|
|
1469
|
-
|
|
1469
|
+
h.add(h = new o(p));
|
|
1470
1470
|
}
|
|
1471
|
-
return
|
|
1471
|
+
return c && h.addJSON(c), h;
|
|
1472
1472
|
}, o.prototype.resolveAll = function() {
|
|
1473
|
-
for (var d = this.nestedArray,
|
|
1474
|
-
d[
|
|
1473
|
+
for (var d = this.nestedArray, c = 0; c < d.length; )
|
|
1474
|
+
d[c] instanceof o ? d[c++].resolveAll() : d[c++].resolve();
|
|
1475
1475
|
return this.resolve();
|
|
1476
|
-
}, o.prototype.lookup = function(d,
|
|
1477
|
-
if (typeof
|
|
1476
|
+
}, o.prototype.lookup = function(d, c, h) {
|
|
1477
|
+
if (typeof c == "boolean" ? (h = c, c = void 0) : c && !Array.isArray(c) && (c = [c]), n.isString(d) && d.length) {
|
|
1478
1478
|
if (d === ".")
|
|
1479
1479
|
return this.root;
|
|
1480
1480
|
d = d.split(".");
|
|
1481
1481
|
} else if (!d.length)
|
|
1482
1482
|
return this;
|
|
1483
1483
|
if (d[0] === "")
|
|
1484
|
-
return this.root.lookup(d.slice(1),
|
|
1484
|
+
return this.root.lookup(d.slice(1), c);
|
|
1485
1485
|
var p = this.get(d[0]);
|
|
1486
1486
|
if (p) {
|
|
1487
1487
|
if (d.length === 1) {
|
|
1488
|
-
if (!
|
|
1488
|
+
if (!c || c.indexOf(p.constructor) > -1)
|
|
1489
1489
|
return p;
|
|
1490
|
-
} else if (p instanceof o && (p = p.lookup(d.slice(1),
|
|
1490
|
+
} else if (p instanceof o && (p = p.lookup(d.slice(1), c, !0)))
|
|
1491
1491
|
return p;
|
|
1492
1492
|
} else
|
|
1493
1493
|
for (var m = 0; m < this.nestedArray.length; ++m)
|
|
1494
|
-
if (this._nestedArray[m] instanceof o && (p = this._nestedArray[m].lookup(d,
|
|
1494
|
+
if (this._nestedArray[m] instanceof o && (p = this._nestedArray[m].lookup(d, c, !0)))
|
|
1495
1495
|
return p;
|
|
1496
|
-
return this.parent === null ||
|
|
1496
|
+
return this.parent === null || h ? null : this.parent.lookup(d, c);
|
|
1497
1497
|
}, o.prototype.lookupType = function(d) {
|
|
1498
|
-
var
|
|
1499
|
-
if (!
|
|
1498
|
+
var c = this.lookup(d, [f]);
|
|
1499
|
+
if (!c)
|
|
1500
1500
|
throw Error("no such type: " + d);
|
|
1501
|
-
return
|
|
1501
|
+
return c;
|
|
1502
1502
|
}, o.prototype.lookupEnum = function(d) {
|
|
1503
|
-
var
|
|
1504
|
-
if (!
|
|
1503
|
+
var c = this.lookup(d, [t]);
|
|
1504
|
+
if (!c)
|
|
1505
1505
|
throw Error("no such Enum '" + d + "' in " + this);
|
|
1506
|
-
return
|
|
1506
|
+
return c;
|
|
1507
1507
|
}, o.prototype.lookupTypeOrEnum = function(d) {
|
|
1508
|
-
var
|
|
1509
|
-
if (!
|
|
1508
|
+
var c = this.lookup(d, [f, t]);
|
|
1509
|
+
if (!c)
|
|
1510
1510
|
throw Error("no such Type or Enum '" + d + "' in " + this);
|
|
1511
|
-
return
|
|
1511
|
+
return c;
|
|
1512
1512
|
}, o.prototype.lookupService = function(d) {
|
|
1513
|
-
var
|
|
1514
|
-
if (!
|
|
1513
|
+
var c = this.lookup(d, [u]);
|
|
1514
|
+
if (!c)
|
|
1515
1515
|
throw Error("no such Service '" + d + "' in " + this);
|
|
1516
|
-
return
|
|
1517
|
-
}, o._configure = function(l, d,
|
|
1518
|
-
f = l, u = d, t =
|
|
1516
|
+
return c;
|
|
1517
|
+
}, o._configure = function(l, d, c) {
|
|
1518
|
+
f = l, u = d, t = c;
|
|
1519
1519
|
}, namespace;
|
|
1520
1520
|
}
|
|
1521
1521
|
var mapfield, hasRequiredMapfield;
|
|
@@ -1658,13 +1658,13 @@ function requireService() {
|
|
|
1658
1658
|
}
|
|
1659
1659
|
return i.prototype.remove.call(this, s);
|
|
1660
1660
|
}, f.prototype.create = function(s, o, r) {
|
|
1661
|
-
for (var l = new a.Service(s, o, r), d = 0,
|
|
1661
|
+
for (var l = new a.Service(s, o, r), d = 0, c; d < /* initializes */
|
|
1662
1662
|
this.methodsArray.length; ++d) {
|
|
1663
|
-
var
|
|
1664
|
-
l[
|
|
1665
|
-
m:
|
|
1666
|
-
q:
|
|
1667
|
-
s:
|
|
1663
|
+
var h = n.lcFirst((c = this._methodsArray[d]).resolve().name).replace(/[^$\w_]/g, "");
|
|
1664
|
+
l[h] = n.codegen(["r", "c"], n.isReserved(h) ? h + "_" : h)("return this.rpcCall(m,q,s,r,c)")({
|
|
1665
|
+
m: c,
|
|
1666
|
+
q: c.resolvedRequestType.ctor,
|
|
1667
|
+
s: c.resolvedResponseType.ctor
|
|
1668
1668
|
});
|
|
1669
1669
|
}
|
|
1670
1670
|
return l;
|
|
@@ -1712,8 +1712,8 @@ function requireDecoder() {
|
|
|
1712
1712
|
return "missing required '" + u.name + "'";
|
|
1713
1713
|
}
|
|
1714
1714
|
function f(u) {
|
|
1715
|
-
var t = n.codegen(["r", "l"], u.name + "$decode")("if(!(r instanceof Reader))")("r=Reader.create(r)")("var c=l===undefined?r.len:r.pos+l,m=new this.ctor" + (u.fieldsArray.filter(function(
|
|
1716
|
-
return
|
|
1715
|
+
var t = n.codegen(["r", "l"], u.name + "$decode")("if(!(r instanceof Reader))")("r=Reader.create(r)")("var c=l===undefined?r.len:r.pos+l,m=new this.ctor" + (u.fieldsArray.filter(function(c) {
|
|
1716
|
+
return c.map;
|
|
1717
1717
|
}).length ? ",k,value" : ""))("while(r.pos<c){")("var t=r.uint32()");
|
|
1718
1718
|
u.group && t("if((t&7)===4)")("break"), t("switch(t>>>3){");
|
|
1719
1719
|
for (var s = 0; s < /* initializes */
|
|
@@ -1804,17 +1804,17 @@ function requireVerifier() {
|
|
|
1804
1804
|
o.length && s("var p={}");
|
|
1805
1805
|
for (var l = 0; l < /* initializes */
|
|
1806
1806
|
t.fieldsArray.length; ++l) {
|
|
1807
|
-
var d = t._fieldsArray[l].resolve(),
|
|
1808
|
-
if (d.optional && s("if(%s!=null&&m.hasOwnProperty(%j)){",
|
|
1809
|
-
s("if(!util.isObject(%s))",
|
|
1807
|
+
var d = t._fieldsArray[l].resolve(), c = "m" + e.safeProp(d.name);
|
|
1808
|
+
if (d.optional && s("if(%s!=null&&m.hasOwnProperty(%j)){", c, d.name), d.map)
|
|
1809
|
+
s("if(!util.isObject(%s))", c)("return%j", n(d, "object"))("var k=Object.keys(%s)", c)("for(var i=0;i<k.length;++i){"), f(s, d, "k[i]"), a(s, d, l, c + "[k[i]]")("}");
|
|
1810
1810
|
else if (d.repeated)
|
|
1811
|
-
s("if(!Array.isArray(%s))",
|
|
1811
|
+
s("if(!Array.isArray(%s))", c)("return%j", n(d, "array"))("for(var i=0;i<%s.length;++i){", c), a(s, d, l, c + "[i]")("}");
|
|
1812
1812
|
else {
|
|
1813
1813
|
if (d.partOf) {
|
|
1814
|
-
var
|
|
1815
|
-
r[d.partOf.name] === 1 && s("if(p%s===1)",
|
|
1814
|
+
var h = e.safeProp(d.partOf.name);
|
|
1815
|
+
r[d.partOf.name] === 1 && s("if(p%s===1)", h)("return%j", d.partOf.name + ": multiple values"), r[d.partOf.name] = 1, s("p%s=1", h);
|
|
1816
1816
|
}
|
|
1817
|
-
a(s, d, l,
|
|
1817
|
+
a(s, d, l, c);
|
|
1818
1818
|
}
|
|
1819
1819
|
d.optional && s("}");
|
|
1820
1820
|
}
|
|
@@ -1831,8 +1831,8 @@ function requireConverter() {
|
|
|
1831
1831
|
if (s.resolvedType)
|
|
1832
1832
|
if (s.resolvedType instanceof n) {
|
|
1833
1833
|
t("switch(d%s){", r);
|
|
1834
|
-
for (var d = s.resolvedType.values,
|
|
1835
|
-
d[h
|
|
1834
|
+
for (var d = s.resolvedType.values, c = Object.keys(d), h = 0; h < c.length; ++h)
|
|
1835
|
+
d[c[h]] === s.typeDefault && !l && (t("default:")('if(typeof(d%s)==="number"){m%s=d%s;break}', r, r, r), s.repeated || t("break"), l = !0), t("case%j:", c[h])("case %i:", d[c[h]])("m%s=%j", r, d[c[h]])("break");
|
|
1836
1836
|
t("}");
|
|
1837
1837
|
} else t('if(typeof d%s!=="object")', r)("throw TypeError(%j)", s.fullName + ": object expected")("m%s=types[%i].fromObject(d%s)", r, o, r);
|
|
1838
1838
|
else {
|
|
@@ -1877,25 +1877,25 @@ function requireConverter() {
|
|
|
1877
1877
|
if (!o.length) return r("return new this.ctor");
|
|
1878
1878
|
r("var m=new this.ctor");
|
|
1879
1879
|
for (var l = 0; l < o.length; ++l) {
|
|
1880
|
-
var d = o[l].resolve(),
|
|
1881
|
-
d.map ? (r("if(d%s){",
|
|
1880
|
+
var d = o[l].resolve(), c = a.safeProp(d.name);
|
|
1881
|
+
d.map ? (r("if(d%s){", c)('if(typeof d%s!=="object")', c)("throw TypeError(%j)", d.fullName + ": object expected")("m%s={}", c)("for(var ks=Object.keys(d%s),i=0;i<ks.length;++i){", c), f(
|
|
1882
1882
|
r,
|
|
1883
1883
|
d,
|
|
1884
1884
|
/* not sorted */
|
|
1885
1885
|
l,
|
|
1886
|
-
|
|
1887
|
-
)("}")("}")) : d.repeated ? (r("if(d%s){",
|
|
1886
|
+
c + "[ks[i]]"
|
|
1887
|
+
)("}")("}")) : d.repeated ? (r("if(d%s){", c)("if(!Array.isArray(d%s))", c)("throw TypeError(%j)", d.fullName + ": array expected")("m%s=[]", c)("for(var i=0;i<d%s.length;++i){", c), f(
|
|
1888
1888
|
r,
|
|
1889
1889
|
d,
|
|
1890
1890
|
/* not sorted */
|
|
1891
1891
|
l,
|
|
1892
|
-
|
|
1893
|
-
)("}")("}")) : (d.resolvedType instanceof n || r("if(d%s!=null){",
|
|
1892
|
+
c + "[i]"
|
|
1893
|
+
)("}")("}")) : (d.resolvedType instanceof n || r("if(d%s!=null){", c), f(
|
|
1894
1894
|
r,
|
|
1895
1895
|
d,
|
|
1896
1896
|
/* not sorted */
|
|
1897
1897
|
l,
|
|
1898
|
-
|
|
1898
|
+
c
|
|
1899
1899
|
), d.resolvedType instanceof n || r("}"));
|
|
1900
1900
|
}
|
|
1901
1901
|
return r("return m");
|
|
@@ -1932,19 +1932,19 @@ function requireConverter() {
|
|
|
1932
1932
|
var o = s.fieldsArray.slice().sort(a.compareFieldsById);
|
|
1933
1933
|
if (!o.length)
|
|
1934
1934
|
return a.codegen()("return {}");
|
|
1935
|
-
for (var r = a.codegen(["m", "o"], s.name + "$toObject")("if(!o)")("o={}")("var d={}"), l = [], d = [],
|
|
1936
|
-
o[
|
|
1935
|
+
for (var r = a.codegen(["m", "o"], s.name + "$toObject")("if(!o)")("o={}")("var d={}"), l = [], d = [], c = [], h = 0; h < o.length; ++h)
|
|
1936
|
+
o[h].partOf || (o[h].resolve().repeated ? l : o[h].map ? d : c).push(o[h]);
|
|
1937
1937
|
if (l.length) {
|
|
1938
|
-
for (r("if(o.arrays||o.defaults){"),
|
|
1938
|
+
for (r("if(o.arrays||o.defaults){"), h = 0; h < l.length; ++h) r("d%s=[]", a.safeProp(l[h].name));
|
|
1939
1939
|
r("}");
|
|
1940
1940
|
}
|
|
1941
1941
|
if (d.length) {
|
|
1942
|
-
for (r("if(o.objects||o.defaults){"),
|
|
1942
|
+
for (r("if(o.objects||o.defaults){"), h = 0; h < d.length; ++h) r("d%s={}", a.safeProp(d[h].name));
|
|
1943
1943
|
r("}");
|
|
1944
1944
|
}
|
|
1945
|
-
if (
|
|
1946
|
-
for (r("if(o.defaults){"),
|
|
1947
|
-
var p = h
|
|
1945
|
+
if (c.length) {
|
|
1946
|
+
for (r("if(o.defaults){"), h = 0; h < c.length; ++h) {
|
|
1947
|
+
var p = c[h], m = a.safeProp(p.name);
|
|
1948
1948
|
if (p.resolvedType instanceof n) r("d%s=o.enums===String?%j:%j", m, p.resolvedType.valuesById[p.typeDefault], p.typeDefault);
|
|
1949
1949
|
else if (p.long) r("if(util.Long){")("var n=new util.Long(%i,%i,%j)", p.typeDefault.low, p.typeDefault.high, p.typeDefault.unsigned)("d%s=o.longs===String?n.toString():o.longs===Number?n.toNumber():n", m)("}else")("d%s=o.longs===String?%j:%i", m, p.typeDefault.toString(), p.typeDefault.toNumber());
|
|
1950
1950
|
else if (p.bytes) {
|
|
@@ -1955,8 +1955,8 @@ function requireConverter() {
|
|
|
1955
1955
|
r("}");
|
|
1956
1956
|
}
|
|
1957
1957
|
var v = !1;
|
|
1958
|
-
for (
|
|
1959
|
-
var p = o[
|
|
1958
|
+
for (h = 0; h < o.length; ++h) {
|
|
1959
|
+
var p = o[h], y = s._fieldsArray.indexOf(p), m = a.safeProp(p.name);
|
|
1960
1960
|
p.map ? (v || (v = !0, r("var ks2")), r("if(m%s&&(ks2=Object.keys(m%s)).length){", m, m)("d%s={}", m)("for(var j=0;j<ks2.length;++j){"), u(
|
|
1961
1961
|
r,
|
|
1962
1962
|
p,
|
|
@@ -2019,7 +2019,7 @@ function requireType() {
|
|
|
2019
2019
|
hasRequiredType = 1, type = m;
|
|
2020
2020
|
var i = requireNamespace();
|
|
2021
2021
|
((m.prototype = Object.create(i.prototype)).constructor = m).className = "Type";
|
|
2022
|
-
var e = require_enum(), n = requireOneof(), a = requireField(), f = requireMapfield(), u = requireService(), t = message, s = reader, o = writer, r = requireUtil(), l = requireEncoder(), d = requireDecoder(),
|
|
2022
|
+
var e = require_enum(), n = requireOneof(), a = requireField(), f = requireMapfield(), u = requireService(), t = message, s = reader, o = writer, r = requireUtil(), l = requireEncoder(), d = requireDecoder(), c = requireVerifier(), h = requireConverter(), p = wrappers;
|
|
2023
2023
|
function m(v, y) {
|
|
2024
2024
|
i.call(this, v, y), this.fields = {}, this.oneofs = void 0, this.extensions = void 0, this.reserved = void 0, this.group = void 0, this._fieldsById = null, this._fieldsArray = null, this._oneofsArray = null, this._ctor = null;
|
|
2025
2025
|
}
|
|
@@ -2196,13 +2196,13 @@ function requireType() {
|
|
|
2196
2196
|
Reader: s,
|
|
2197
2197
|
types: g,
|
|
2198
2198
|
util: r
|
|
2199
|
-
}), this.verify =
|
|
2199
|
+
}), this.verify = c(this)({
|
|
2200
2200
|
types: g,
|
|
2201
2201
|
util: r
|
|
2202
|
-
}), this.fromObject =
|
|
2202
|
+
}), this.fromObject = h.fromObject(this)({
|
|
2203
2203
|
types: g,
|
|
2204
2204
|
util: r
|
|
2205
|
-
}), this.toObject =
|
|
2205
|
+
}), this.toObject = h.toObject(this)({
|
|
2206
2206
|
types: g,
|
|
2207
2207
|
util: r
|
|
2208
2208
|
});
|
|
@@ -2239,19 +2239,19 @@ function requireRoot() {
|
|
|
2239
2239
|
var i = requireNamespace();
|
|
2240
2240
|
((o.prototype = Object.create(i.prototype)).constructor = o).className = "Root";
|
|
2241
2241
|
var e = requireField(), n = require_enum(), a = requireOneof(), f = requireUtil(), u, t, s;
|
|
2242
|
-
function o(
|
|
2243
|
-
i.call(this, "",
|
|
2242
|
+
function o(c) {
|
|
2243
|
+
i.call(this, "", c), this.deferred = [], this.files = [];
|
|
2244
2244
|
}
|
|
2245
|
-
o.fromJSON = function(
|
|
2246
|
-
return p || (p = new o()),
|
|
2245
|
+
o.fromJSON = function(h, p) {
|
|
2246
|
+
return p || (p = new o()), h.options && p.setOptions(h.options), p.addJSON(h.nested);
|
|
2247
2247
|
}, o.prototype.resolvePath = f.path.resolve, o.prototype.fetch = f.fetch;
|
|
2248
2248
|
function r() {
|
|
2249
2249
|
}
|
|
2250
|
-
o.prototype.load = function h
|
|
2250
|
+
o.prototype.load = function c(h, p, m) {
|
|
2251
2251
|
typeof p == "function" && (m = p, p = void 0);
|
|
2252
2252
|
var b = this;
|
|
2253
2253
|
if (!m)
|
|
2254
|
-
return f.asPromise(
|
|
2254
|
+
return f.asPromise(c, b, h, p);
|
|
2255
2255
|
var v = m === r;
|
|
2256
2256
|
function y(q, A) {
|
|
2257
2257
|
if (m) {
|
|
@@ -2318,73 +2318,73 @@ function requireRoot() {
|
|
|
2318
2318
|
}
|
|
2319
2319
|
}
|
|
2320
2320
|
var O = 0;
|
|
2321
|
-
f.isString(
|
|
2322
|
-
for (var T = 0, J; T <
|
|
2323
|
-
(J = b.resolvePath("",
|
|
2321
|
+
f.isString(h) && (h = [h]);
|
|
2322
|
+
for (var T = 0, J; T < h.length; ++T)
|
|
2323
|
+
(J = b.resolvePath("", h[T])) && R(J);
|
|
2324
2324
|
if (v)
|
|
2325
2325
|
return b;
|
|
2326
2326
|
O || y(null, b);
|
|
2327
|
-
}, o.prototype.loadSync = function(
|
|
2327
|
+
}, o.prototype.loadSync = function(h, p) {
|
|
2328
2328
|
if (!f.isNode)
|
|
2329
2329
|
throw Error("not supported");
|
|
2330
|
-
return this.load(
|
|
2330
|
+
return this.load(h, p, r);
|
|
2331
2331
|
}, o.prototype.resolveAll = function() {
|
|
2332
2332
|
if (this.deferred.length)
|
|
2333
|
-
throw Error("unresolvable extensions: " + this.deferred.map(function(
|
|
2334
|
-
return "'extend " +
|
|
2333
|
+
throw Error("unresolvable extensions: " + this.deferred.map(function(h) {
|
|
2334
|
+
return "'extend " + h.extend + "' in " + h.parent.fullName;
|
|
2335
2335
|
}).join(", "));
|
|
2336
2336
|
return i.prototype.resolveAll.call(this);
|
|
2337
2337
|
};
|
|
2338
2338
|
var l = /^[A-Z]/;
|
|
2339
|
-
function d(
|
|
2340
|
-
var p =
|
|
2339
|
+
function d(c, h) {
|
|
2340
|
+
var p = h.parent.lookup(h.extend);
|
|
2341
2341
|
if (p) {
|
|
2342
|
-
var m = new e(
|
|
2343
|
-
return p.get(m.name) || (m.declaringField =
|
|
2342
|
+
var m = new e(h.fullName, h.id, h.type, h.rule, void 0, h.options);
|
|
2343
|
+
return p.get(m.name) || (m.declaringField = h, h.extensionField = m, p.add(m)), !0;
|
|
2344
2344
|
}
|
|
2345
2345
|
return !1;
|
|
2346
2346
|
}
|
|
2347
|
-
return o.prototype._handleAdd = function(
|
|
2348
|
-
if (
|
|
2347
|
+
return o.prototype._handleAdd = function(h) {
|
|
2348
|
+
if (h instanceof e)
|
|
2349
2349
|
/* an extension field (implies not part of a oneof) */
|
|
2350
|
-
|
|
2351
|
-
!
|
|
2352
|
-
else if (
|
|
2353
|
-
l.test(
|
|
2354
|
-
else if (!(
|
|
2355
|
-
if (
|
|
2350
|
+
h.extend !== void 0 && /* not already handled */
|
|
2351
|
+
!h.extensionField && (d(this, h) || this.deferred.push(h));
|
|
2352
|
+
else if (h instanceof n)
|
|
2353
|
+
l.test(h.name) && (h.parent[h.name] = h.values);
|
|
2354
|
+
else if (!(h instanceof a)) {
|
|
2355
|
+
if (h instanceof u)
|
|
2356
2356
|
for (var p = 0; p < this.deferred.length; )
|
|
2357
2357
|
d(this, this.deferred[p]) ? this.deferred.splice(p, 1) : ++p;
|
|
2358
2358
|
for (var m = 0; m < /* initializes */
|
|
2359
|
-
|
|
2360
|
-
this._handleAdd(
|
|
2361
|
-
l.test(
|
|
2359
|
+
h.nestedArray.length; ++m)
|
|
2360
|
+
this._handleAdd(h._nestedArray[m]);
|
|
2361
|
+
l.test(h.name) && (h.parent[h.name] = h);
|
|
2362
2362
|
}
|
|
2363
|
-
}, o.prototype._handleRemove = function(
|
|
2364
|
-
if (
|
|
2363
|
+
}, o.prototype._handleRemove = function(h) {
|
|
2364
|
+
if (h instanceof e) {
|
|
2365
2365
|
if (
|
|
2366
2366
|
/* an extension field */
|
|
2367
|
-
|
|
2367
|
+
h.extend !== void 0
|
|
2368
2368
|
)
|
|
2369
2369
|
if (
|
|
2370
2370
|
/* already handled */
|
|
2371
|
-
|
|
2371
|
+
h.extensionField
|
|
2372
2372
|
)
|
|
2373
|
-
|
|
2373
|
+
h.extensionField.parent.remove(h.extensionField), h.extensionField = null;
|
|
2374
2374
|
else {
|
|
2375
|
-
var p = this.deferred.indexOf(
|
|
2375
|
+
var p = this.deferred.indexOf(h);
|
|
2376
2376
|
p > -1 && this.deferred.splice(p, 1);
|
|
2377
2377
|
}
|
|
2378
|
-
} else if (
|
|
2379
|
-
l.test(
|
|
2380
|
-
else if (
|
|
2378
|
+
} else if (h instanceof n)
|
|
2379
|
+
l.test(h.name) && delete h.parent[h.name];
|
|
2380
|
+
else if (h instanceof i) {
|
|
2381
2381
|
for (var m = 0; m < /* initializes */
|
|
2382
|
-
|
|
2383
|
-
this._handleRemove(
|
|
2384
|
-
l.test(
|
|
2382
|
+
h.nestedArray.length; ++m)
|
|
2383
|
+
this._handleRemove(h._nestedArray[m]);
|
|
2384
|
+
l.test(h.name) && delete h.parent[h.name];
|
|
2385
2385
|
}
|
|
2386
|
-
}, o._configure = function(
|
|
2387
|
-
u =
|
|
2386
|
+
}, o._configure = function(c, h, p) {
|
|
2387
|
+
u = c, t = h, s = p;
|
|
2388
2388
|
}, root;
|
|
2389
2389
|
}
|
|
2390
2390
|
var hasRequiredUtil;
|
|
@@ -2394,15 +2394,15 @@ function requireUtil() {
|
|
|
2394
2394
|
var i = util$1.exports = requireMinimal(), e = roots, n, a;
|
|
2395
2395
|
i.codegen = codegen_1, i.fetch = fetch_1, i.path = path, i.fs = i.inquire("fs"), i.toArray = function(r) {
|
|
2396
2396
|
if (r) {
|
|
2397
|
-
for (var l = Object.keys(r), d = new Array(l.length),
|
|
2398
|
-
d[
|
|
2397
|
+
for (var l = Object.keys(r), d = new Array(l.length), c = 0; c < l.length; )
|
|
2398
|
+
d[c] = r[l[c++]];
|
|
2399
2399
|
return d;
|
|
2400
2400
|
}
|
|
2401
2401
|
return [];
|
|
2402
2402
|
}, i.toObject = function(r) {
|
|
2403
2403
|
for (var l = {}, d = 0; d < r.length; ) {
|
|
2404
|
-
var
|
|
2405
|
-
|
|
2404
|
+
var c = r[d++], h = r[d++];
|
|
2405
|
+
h !== void 0 && (l[c] = h);
|
|
2406
2406
|
}
|
|
2407
2407
|
return l;
|
|
2408
2408
|
};
|
|
@@ -2436,23 +2436,23 @@ function requireUtil() {
|
|
|
2436
2436
|
var l = new a("Enum" + s++, r);
|
|
2437
2437
|
return i.decorateRoot.add(l), Object.defineProperty(r, "$type", { value: l, enumerable: !1 }), l;
|
|
2438
2438
|
}, i.setProperty = function(r, l, d) {
|
|
2439
|
-
function h
|
|
2439
|
+
function c(h, p, m) {
|
|
2440
2440
|
var b = p.shift();
|
|
2441
2441
|
if (b === "__proto__" || b === "prototype")
|
|
2442
|
-
return
|
|
2442
|
+
return h;
|
|
2443
2443
|
if (p.length > 0)
|
|
2444
|
-
|
|
2444
|
+
h[b] = c(h[b] || {}, p, m);
|
|
2445
2445
|
else {
|
|
2446
|
-
var v =
|
|
2447
|
-
v && (m = [].concat(v).concat(m)),
|
|
2446
|
+
var v = h[b];
|
|
2447
|
+
v && (m = [].concat(v).concat(m)), h[b] = m;
|
|
2448
2448
|
}
|
|
2449
|
-
return
|
|
2449
|
+
return h;
|
|
2450
2450
|
}
|
|
2451
2451
|
if (typeof r != "object")
|
|
2452
2452
|
throw TypeError("dst must be an object");
|
|
2453
2453
|
if (!l)
|
|
2454
2454
|
throw TypeError("path must be specified");
|
|
2455
|
-
return l = l.split("."),
|
|
2455
|
+
return l = l.split("."), c(r, l, d);
|
|
2456
2456
|
}, Object.defineProperty(i, "decorateRoot", {
|
|
2457
2457
|
get: function() {
|
|
2458
2458
|
return e.decorated || (e.decorated = new (requireRoot())());
|
|
@@ -2621,8 +2621,8 @@ function requireEncoder() {
|
|
|
2621
2621
|
/* initializes */
|
|
2622
2622
|
u.fieldsArray.slice().sort(n.compareFieldsById)
|
|
2623
2623
|
), s = 0; s < r.length; ++s) {
|
|
2624
|
-
var l = r[s].resolve(), d = u._fieldsArray.indexOf(l),
|
|
2625
|
-
o = "m" + n.safeProp(l.name), l.map ? (t("if(%s!=null&&Object.hasOwnProperty.call(m,%j)){", o, l.name)("for(var ks=Object.keys(%s),i=0;i<ks.length;++i){", o)("w.uint32(%i).fork().uint32(%i).%s(ks[i])", (l.id << 3 | 2) >>> 0, 8 | e.mapKey[l.keyType], l.keyType),
|
|
2624
|
+
var l = r[s].resolve(), d = u._fieldsArray.indexOf(l), c = l.resolvedType instanceof i ? "int32" : l.type, h = e.basic[c];
|
|
2625
|
+
o = "m" + n.safeProp(l.name), l.map ? (t("if(%s!=null&&Object.hasOwnProperty.call(m,%j)){", o, l.name)("for(var ks=Object.keys(%s),i=0;i<ks.length;++i){", o)("w.uint32(%i).fork().uint32(%i).%s(ks[i])", (l.id << 3 | 2) >>> 0, 8 | e.mapKey[l.keyType], l.keyType), h === void 0 ? t("types[%i].encode(%s[ks[i]],w.uint32(18).fork()).ldelim().ldelim()", d, o) : t(".uint32(%i).%s(%s[ks[i]]).ldelim()", 16 | h, c, o), t("}")("}")) : l.repeated ? (t("if(%s!=null&&%s.length){", o, o), l.packed && e.packed[c] !== void 0 ? t("w.uint32(%i).fork()", (l.id << 3 | 2) >>> 0)("for(var i=0;i<%s.length;++i)", o)("w.%s(%s[i])", c, o)("w.ldelim()") : (t("for(var i=0;i<%s.length;++i)", o), h === void 0 ? a(t, l, d, o + "[i]") : t("w.uint32(%i).%s(%s[i])", (l.id << 3 | h) >>> 0, c, o)), t("}")) : (l.optional && t("if(%s!=null&&Object.hasOwnProperty.call(m,%j))", o, l.name), h === void 0 ? a(t, l, d, o) : t("w.uint32(%i).%s(%s)", (l.id << 3 | h) >>> 0, c, o));
|
|
2626
2626
|
}
|
|
2627
2627
|
return t("return w");
|
|
2628
2628
|
}
|
|
@@ -2661,7 +2661,7 @@ protobuf.Namespace._configure(protobuf.Type, protobuf.Service, protobuf.Enum);
|
|
|
2661
2661
|
protobuf.Root._configure(protobuf.Type);
|
|
2662
2662
|
protobuf.Field._configure(protobuf.Type);
|
|
2663
2663
|
var indexLightExports = indexLight.exports, light = indexLightExports;
|
|
2664
|
-
const protobufjs = /* @__PURE__ */ getDefaultExportFromCjs(light), proto_data = { options: { syntax: "proto3", optimize_for: "LITE_RUNTIME" }, nested: { nil: { nested: { xit: { nested: { proto: { nested: { MessageType: { values: { MessageType_FrameRequest: 0, MessageType_FrameResponse: 1, MessageType_FrameCache: 2,
|
|
2664
|
+
const protobufjs = /* @__PURE__ */ getDefaultExportFromCjs(light), proto_data = { options: { syntax: "proto3", optimize_for: "LITE_RUNTIME" }, nested: { nil: { nested: { xit: { nested: { proto: { nested: { MessageType: { values: { MessageType_FrameRequest: 0, MessageType_FrameResponse: 1, MessageType_FrameCache: 2, MessageType_FrameLoaded: 3, MessageType_ValueRequest: 4, MessageType_ValueResponse: 5, MessageType_ValueUpdate: 6, MessageType_SignalRequest: 7, MessageType_SignalResponse: 8, MessageType_SignalNotify: 9, MessageType_FileRequest: 10, MessageType_FileResponse: 11 } }, FrameRequest: { fields: { id: { type: "string", id: 1 } } }, FrameResponse: { oneofs: { value: { oneof: ["file", "content"] } }, fields: { id: { type: "string", id: 1 }, file: { type: "string", id: 2 }, content: { type: "string", id: 3 } } }, FrameCache: { fields: { id: { type: "string", id: 1 }, content: { type: "string", id: 2 }, files: { rule: "repeated", type: "FileInfo", id: 3 } } }, FrameLoaded: { oneofs: { _tag: { oneof: ["tag"] } }, fields: { id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } } } }, Value: { oneofs: { value: { oneof: ["value_boolean", "value_number", "value_double", "value_string", "value_buffer"] } }, fields: { id: { type: "string", id: 1 }, value_boolean: { type: "bool", id: 2 }, value_number: { type: "int64", id: 3 }, value_double: { type: "double", id: 4 }, value_string: { type: "string", id: 5 }, value_buffer: { type: "bytes", id: 6 } } }, ValueRequest: { oneofs: { _tag: { oneof: ["tag"] } }, fields: { id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } } } }, ValueResponse: { oneofs: { _tag: { oneof: ["tag"] } }, fields: { id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } }, values: { rule: "repeated", type: "Value", id: 3 } } }, ValueUpdate: { oneofs: { _tag: { oneof: ["tag"] } }, fields: { id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } }, value: { type: "Value", id: 3 } } }, SignalRequest: { fields: { id: { type: "string", id: 1 } } }, Signal: { oneofs: { _type: { oneof: ["type"] } }, fields: { id: { type: "string", id: 1 }, type: { type: "string", id: 2, options: { proto3_optional: !0 } } } }, SignalResponse: { oneofs: { _tag: { oneof: ["tag"] } }, fields: { id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } }, signals: { rule: "repeated", type: "Signal", id: 3 } } }, SignalNotify: { oneofs: { _tag: { oneof: ["tag"] }, arg: { oneof: ["arg_boolean", "arg_number", "arg_double", "arg_string", "arg_buffer"] } }, fields: { frame_id: { type: "string", id: 1 }, tag: { type: "string", id: 2, options: { proto3_optional: !0 } }, signal_id: { type: "string", id: 3 }, arg_boolean: { type: "bool", id: 4 }, arg_number: { type: "int64", id: 5 }, arg_double: { type: "double", id: 6 }, arg_string: { type: "string", id: 7 }, arg_buffer: { type: "bytes", id: 8 } } }, FileRequest: { fields: { target: { type: "string", id: 1 } } }, FileResponse: { fields: { target: { type: "string", id: 1 }, content: { type: "string", id: 2 }, metadata: { type: "bytes", id: 3 } } }, FileInfo: { fields: { target: { type: "string", id: 1 }, metadata: { type: "bytes", id: 2 } } } } } } } } } } }, nil_xit_proto = protobufjs.Root.fromJSON(proto_data).lookup(
|
|
2665
2665
|
"nil.xit.proto"
|
|
2666
2666
|
), bundle = async (i) => new Promise((e, n) => {
|
|
2667
2667
|
const a = new WorkerWrapper();
|
|
@@ -2716,11 +2716,11 @@ const protobufjs = /* @__PURE__ */ getDefaultExportFromCjs(light), proto_data =
|
|
|
2716
2716
|
for (const t of f) {
|
|
2717
2717
|
const s = t.id, o = t.value, r = writable(t[o]);
|
|
2718
2718
|
r.subscribe((l) => {
|
|
2719
|
-
const d = { id: s, [o]: l, value: o },
|
|
2719
|
+
const d = { id: s, [o]: l, value: o }, c = { id: i, tag: e, value: d };
|
|
2720
2720
|
a.publish(
|
|
2721
2721
|
concat([
|
|
2722
2722
|
header(nil_xit_proto.MessageType.MessageType_ValueUpdate),
|
|
2723
|
-
nil_xit_proto.ValueUpdate.encode(
|
|
2723
|
+
nil_xit_proto.ValueUpdate.encode(c).finish()
|
|
2724
2724
|
])
|
|
2725
2725
|
);
|
|
2726
2726
|
}), u[o].set(s, r);
|
|
@@ -2731,8 +2731,8 @@ const protobufjs = /* @__PURE__ */ getDefaultExportFromCjs(light), proto_data =
|
|
|
2731
2731
|
if (o === nil_xit_proto.MessageType.MessageType_ValueUpdate) {
|
|
2732
2732
|
const d = nil_xit_proto.ValueUpdate.decode(r);
|
|
2733
2733
|
if (d.id === i && e === d.tag) {
|
|
2734
|
-
const
|
|
2735
|
-
|
|
2734
|
+
const c = d.value.value, h = (l = u[c]) == null ? void 0 : l.get(d.value.id);
|
|
2735
|
+
h == null || h.set(d.value[c]);
|
|
2736
2736
|
}
|
|
2737
2737
|
}
|
|
2738
2738
|
}), u;
|
|
@@ -2823,34 +2823,38 @@ const protobufjs = /* @__PURE__ */ getDefaultExportFromCjs(light), proto_data =
|
|
|
2823
2823
|
},
|
|
2824
2824
|
loader: n
|
|
2825
2825
|
}), create_app = async (i, e, n, a, f) => {
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2826
|
+
const u = { host: i };
|
|
2827
|
+
await test_connection(u);
|
|
2828
|
+
const t = new Service$1(u), [s, o, { nil_xit_fn: r }] = await Promise.all([
|
|
2829
|
+
make_values({ id: e, tag: n, host: i, service: t }),
|
|
2830
|
+
make_signals({ id: e, tag: n, host: i, service: t }),
|
|
2830
2831
|
bundle({ host: i, cdn_url: a, id: e })
|
|
2831
|
-
]),
|
|
2832
|
-
svelte: () => import("./svelte/index.js").then((
|
|
2833
|
-
"svelte/store": () => import("./svelte/store.js").then((
|
|
2832
|
+
]), l = {
|
|
2833
|
+
svelte: () => import("./svelte/index.js").then((p) => p.bT),
|
|
2834
|
+
"svelte/store": () => import("./svelte/store.js").then((p) => p.i),
|
|
2834
2835
|
"svelte/animate": () => import("./svelte/animate.js"),
|
|
2835
2836
|
"svelte/easing": () => import("./svelte/easing.js"),
|
|
2836
2837
|
"svelte/events": () => import("./svelte/events.js"),
|
|
2837
|
-
"svelte/motion": () => import("./svelte/motion.js").then((
|
|
2838
|
+
"svelte/motion": () => import("./svelte/motion.js").then((p) => p.i),
|
|
2838
2839
|
"svelte/transition": () => import("./svelte/transition.js"),
|
|
2839
2840
|
// @ts-ignore
|
|
2840
2841
|
"svelte/internal/disclose-version": () => import("./svelte/internal/disclose-version.js"),
|
|
2841
2842
|
// @ts-ignore
|
|
2842
2843
|
"svelte/internal/client": () => import("./svelte/internal/client.js")
|
|
2843
|
-
},
|
|
2844
|
+
}, d = (p) => p in l ? l[p]() : import(
|
|
2844
2845
|
/* @vite-ignore */
|
|
2845
|
-
|
|
2846
|
-
), { action:
|
|
2847
|
-
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2846
|
+
p
|
|
2847
|
+
), { action: c } = await r(d), h = concat([
|
|
2848
|
+
header(nil_xit_proto.MessageType.MessageType_FrameLoaded),
|
|
2849
|
+
nil_xit_proto.FrameLoaded.encode({ id: e, tag: n }).finish()
|
|
2850
|
+
]);
|
|
2851
|
+
return t.start(), service_publish(u, h), (p) => {
|
|
2852
|
+
const m = /* @__PURE__ */ new Map();
|
|
2853
|
+
m.set("nil.xit", create_context(s, o, f));
|
|
2854
|
+
const { destroy: b } = c(p, m);
|
|
2855
|
+
return {
|
|
2852
2856
|
destroy: () => {
|
|
2853
|
-
|
|
2857
|
+
t.stop(), b();
|
|
2854
2858
|
}
|
|
2855
2859
|
};
|
|
2856
2860
|
};
|