piral-cli 0.14.0-unstable.3096 → 0.14.1-beta.3244
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/README.md +5 -2
- package/lib/apps/build-pilet.d.ts +11 -0
- package/lib/apps/build-pilet.js +8 -1
- package/lib/apps/build-pilet.js.map +1 -1
- package/lib/apps/build-piral.d.ts +13 -0
- package/lib/apps/build-piral.js +16 -5
- package/lib/apps/build-piral.js.map +1 -1
- package/lib/apps/debug-pilet.d.ts +11 -0
- package/lib/apps/debug-pilet.js +15 -3
- package/lib/apps/debug-pilet.js.map +1 -1
- package/lib/apps/debug-piral.d.ts +11 -0
- package/lib/apps/debug-piral.js +11 -1
- package/lib/apps/debug-piral.js.map +1 -1
- package/lib/apps/new-pilet.d.ts +1 -1
- package/lib/apps/new-pilet.js +11 -7
- package/lib/apps/new-pilet.js.map +1 -1
- package/lib/apps/new-piral.d.ts +1 -1
- package/lib/apps/new-piral.js +4 -3
- package/lib/apps/new-piral.js.map +1 -1
- package/lib/apps/pack-pilet.js +1 -1
- package/lib/apps/publish-pilet.d.ts +1 -1
- package/lib/apps/publish-pilet.js +1 -1
- package/lib/apps/upgrade-pilet.d.ts +6 -2
- package/lib/apps/upgrade-pilet.js +9 -6
- package/lib/apps/upgrade-pilet.js.map +1 -1
- package/lib/apps/upgrade-piral.d.ts +2 -2
- package/lib/apps/upgrade-piral.js +1 -1
- package/lib/build/bundler-calls.d.ts +3 -0
- package/lib/build/bundler-calls.js +107 -0
- package/lib/build/bundler-calls.js.map +1 -0
- package/lib/build/run-build-pilet.d.ts +1 -0
- package/lib/build/run-build-pilet.js +65 -0
- package/lib/build/run-build-pilet.js.map +1 -0
- package/lib/build/run-build-piral.d.ts +1 -0
- package/lib/build/run-build-piral.js +66 -0
- package/lib/build/run-build-piral.js.map +1 -0
- package/lib/build/run-debug-mono-piral.d.ts +1 -0
- package/lib/build/run-debug-mono-piral.js +71 -0
- package/lib/build/run-debug-mono-piral.js.map +1 -0
- package/lib/build/run-debug-pilet.d.ts +1 -0
- package/lib/build/run-debug-pilet.js +90 -0
- package/lib/build/run-debug-pilet.js.map +1 -0
- package/lib/build/run-debug-piral.d.ts +1 -0
- package/lib/build/run-debug-piral.js +86 -0
- package/lib/build/run-debug-piral.js.map +1 -0
- package/lib/bundler.js +50 -13
- package/lib/bundler.js.map +1 -1
- package/lib/commands.js +12 -8
- package/lib/commands.js.map +1 -1
- package/lib/common/clients/npm.js +10 -10
- package/lib/common/constants.d.ts +1 -1
- package/lib/common/constants.js +2 -2
- package/lib/common/constants.js.map +1 -1
- package/lib/common/emulator.js +5 -2
- package/lib/common/emulator.js.map +1 -1
- package/lib/common/log.js +7 -4
- package/lib/common/log.js.map +1 -1
- package/lib/common/npm.d.ts +3 -1
- package/lib/common/npm.js +31 -11
- package/lib/common/npm.js.map +1 -1
- package/lib/common/package.d.ts +5 -5
- package/lib/common/package.js +43 -24
- package/lib/common/package.js.map +1 -1
- package/lib/common/scaffold.d.ts +14 -2
- package/lib/common/scaffold.js +19 -7
- package/lib/common/scaffold.js.map +1 -1
- package/lib/common/template.d.ts +1 -0
- package/lib/common/template.js +29 -2
- package/lib/common/template.js.map +1 -1
- package/lib/external/index.js +119 -155
- package/lib/helpers.js +1 -1
- package/lib/helpers.js.map +1 -1
- package/lib/injectors/piral.d.ts +4 -2
- package/lib/injectors/piral.js +16 -1
- package/lib/injectors/piral.js.map +1 -1
- package/lib/messages.d.ts +25 -21
- package/lib/messages.js +30 -22
- package/lib/messages.js.map +1 -1
- package/lib/types/common.d.ts +1 -0
- package/lib/types/public.d.ts +63 -11
- package/package.json +3 -3
- package/src/apps/build-pilet.ts +22 -0
- package/src/apps/build-piral.ts +38 -4
- package/src/apps/debug-pilet.ts +29 -6
- package/src/apps/debug-piral.ts +24 -0
- package/src/apps/new-pilet.ts +13 -8
- package/src/apps/new-piral.ts +7 -5
- package/src/apps/pack-pilet.test.ts +2 -2
- package/src/apps/pack-pilet.ts +1 -1
- package/src/apps/publish-pilet.ts +2 -2
- package/src/apps/upgrade-pilet.ts +18 -7
- package/src/apps/upgrade-piral.ts +3 -3
- package/src/build/bundler-calls.ts +121 -0
- package/src/build/run-build-pilet.ts +89 -0
- package/src/build/run-build-piral.ts +88 -0
- package/src/build/run-debug-mono-piral.ts +87 -0
- package/src/build/run-debug-pilet.ts +114 -0
- package/src/build/run-debug-piral.ts +106 -0
- package/src/bundler.test.ts +65 -46
- package/src/bundler.ts +53 -13
- package/src/commands.ts +20 -10
- package/src/common/clients/npm.ts +10 -10
- package/src/common/constants.ts +1 -1
- package/src/common/emulator.ts +5 -2
- package/src/common/log.ts +9 -4
- package/src/common/npm.test.ts +18 -18
- package/src/common/npm.ts +27 -8
- package/src/common/package.ts +53 -17
- package/src/common/scaffold.ts +36 -20
- package/src/common/template.ts +24 -1
- package/src/helpers.ts +1 -1
- package/src/injectors/piral.test.ts +6 -5
- package/src/injectors/piral.ts +21 -2
- package/src/messages.ts +43 -35
- package/src/types/common.ts +1 -0
- package/src/types/public.ts +68 -20
package/lib/external/index.js
CHANGED
|
@@ -1590,7 +1590,79 @@ module.exports = CheckboxPrompt;
|
|
|
1590
1590
|
|
|
1591
1591
|
/***/ }),
|
|
1592
1592
|
/* 28 */,
|
|
1593
|
-
/* 29
|
|
1593
|
+
/* 29 */
|
|
1594
|
+
/***/ (function(__unusedmodule, exports, __webpack_require__) {
|
|
1595
|
+
|
|
1596
|
+
"use strict";
|
|
1597
|
+
|
|
1598
|
+
var __extends = (this && this.__extends) || (function () {
|
|
1599
|
+
var extendStatics = function (d, b) {
|
|
1600
|
+
extendStatics = Object.setPrototypeOf ||
|
|
1601
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
1602
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
1603
|
+
return extendStatics(d, b);
|
|
1604
|
+
}
|
|
1605
|
+
return function (d, b) {
|
|
1606
|
+
extendStatics(d, b);
|
|
1607
|
+
function __() { this.constructor = d; }
|
|
1608
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
1609
|
+
};
|
|
1610
|
+
})();
|
|
1611
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1612
|
+
var Scheduler_1 = __webpack_require__(628);
|
|
1613
|
+
var AsyncScheduler = (function (_super) {
|
|
1614
|
+
__extends(AsyncScheduler, _super);
|
|
1615
|
+
function AsyncScheduler(SchedulerAction, now) {
|
|
1616
|
+
if (now === void 0) { now = Scheduler_1.Scheduler.now; }
|
|
1617
|
+
var _this = _super.call(this, SchedulerAction, function () {
|
|
1618
|
+
if (AsyncScheduler.delegate && AsyncScheduler.delegate !== _this) {
|
|
1619
|
+
return AsyncScheduler.delegate.now();
|
|
1620
|
+
}
|
|
1621
|
+
else {
|
|
1622
|
+
return now();
|
|
1623
|
+
}
|
|
1624
|
+
}) || this;
|
|
1625
|
+
_this.actions = [];
|
|
1626
|
+
_this.active = false;
|
|
1627
|
+
_this.scheduled = undefined;
|
|
1628
|
+
return _this;
|
|
1629
|
+
}
|
|
1630
|
+
AsyncScheduler.prototype.schedule = function (work, delay, state) {
|
|
1631
|
+
if (delay === void 0) { delay = 0; }
|
|
1632
|
+
if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) {
|
|
1633
|
+
return AsyncScheduler.delegate.schedule(work, delay, state);
|
|
1634
|
+
}
|
|
1635
|
+
else {
|
|
1636
|
+
return _super.prototype.schedule.call(this, work, delay, state);
|
|
1637
|
+
}
|
|
1638
|
+
};
|
|
1639
|
+
AsyncScheduler.prototype.flush = function (action) {
|
|
1640
|
+
var actions = this.actions;
|
|
1641
|
+
if (this.active) {
|
|
1642
|
+
actions.push(action);
|
|
1643
|
+
return;
|
|
1644
|
+
}
|
|
1645
|
+
var error;
|
|
1646
|
+
this.active = true;
|
|
1647
|
+
do {
|
|
1648
|
+
if (error = action.execute(action.state, action.delay)) {
|
|
1649
|
+
break;
|
|
1650
|
+
}
|
|
1651
|
+
} while (action = actions.shift());
|
|
1652
|
+
this.active = false;
|
|
1653
|
+
if (error) {
|
|
1654
|
+
while (action = actions.shift()) {
|
|
1655
|
+
action.unsubscribe();
|
|
1656
|
+
}
|
|
1657
|
+
throw error;
|
|
1658
|
+
}
|
|
1659
|
+
};
|
|
1660
|
+
return AsyncScheduler;
|
|
1661
|
+
}(Scheduler_1.Scheduler));
|
|
1662
|
+
exports.AsyncScheduler = AsyncScheduler;
|
|
1663
|
+
//# sourceMappingURL=AsyncScheduler.js.map
|
|
1664
|
+
|
|
1665
|
+
/***/ }),
|
|
1594
1666
|
/* 30 */
|
|
1595
1667
|
/***/ (function(module) {
|
|
1596
1668
|
|
|
@@ -1604,7 +1676,7 @@ module.exports = require("tty");
|
|
|
1604
1676
|
|
|
1605
1677
|
"use strict";
|
|
1606
1678
|
|
|
1607
|
-
const ansiRegex = __webpack_require__(
|
|
1679
|
+
const ansiRegex = __webpack_require__(367);
|
|
1608
1680
|
|
|
1609
1681
|
const stripAnsi = string => typeof string === 'string' ? string.replace(ansiRegex(), '') : string;
|
|
1610
1682
|
|
|
@@ -1821,7 +1893,7 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
1821
1893
|
};
|
|
1822
1894
|
})();
|
|
1823
1895
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1824
|
-
var AsyncScheduler_1 = __webpack_require__(
|
|
1896
|
+
var AsyncScheduler_1 = __webpack_require__(29);
|
|
1825
1897
|
var AsapScheduler = (function (_super) {
|
|
1826
1898
|
__extends(AsapScheduler, _super);
|
|
1827
1899
|
function AsapScheduler() {
|
|
@@ -1989,7 +2061,7 @@ var EmptyError_1 = __webpack_require__(194);
|
|
|
1989
2061
|
exports.EmptyError = EmptyError_1.EmptyError;
|
|
1990
2062
|
var ObjectUnsubscribedError_1 = __webpack_require__(407);
|
|
1991
2063
|
exports.ObjectUnsubscribedError = ObjectUnsubscribedError_1.ObjectUnsubscribedError;
|
|
1992
|
-
var UnsubscriptionError_1 = __webpack_require__(
|
|
2064
|
+
var UnsubscriptionError_1 = __webpack_require__(294);
|
|
1993
2065
|
exports.UnsubscriptionError = UnsubscriptionError_1.UnsubscriptionError;
|
|
1994
2066
|
var TimeoutError_1 = __webpack_require__(432);
|
|
1995
2067
|
exports.TimeoutError = TimeoutError_1.TimeoutError;
|
|
@@ -21145,7 +21217,7 @@ module.exports = convert;
|
|
|
21145
21217
|
|
|
21146
21218
|
|
|
21147
21219
|
|
|
21148
|
-
var buffer = __webpack_require__(
|
|
21220
|
+
var buffer = __webpack_require__(293)
|
|
21149
21221
|
var Buffer = buffer.Buffer
|
|
21150
21222
|
|
|
21151
21223
|
var safer = {}
|
|
@@ -23774,7 +23846,7 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
23774
23846
|
})();
|
|
23775
23847
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23776
23848
|
var AsyncAction_1 = __webpack_require__(986);
|
|
23777
|
-
var AsyncScheduler_1 = __webpack_require__(
|
|
23849
|
+
var AsyncScheduler_1 = __webpack_require__(29);
|
|
23778
23850
|
var VirtualTimeScheduler = (function (_super) {
|
|
23779
23851
|
__extends(VirtualTimeScheduler, _super);
|
|
23780
23852
|
function VirtualTimeScheduler(SchedulerAction, maxFrames) {
|
|
@@ -25155,7 +25227,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
25155
25227
|
var isArray_1 = __webpack_require__(321);
|
|
25156
25228
|
var isObject_1 = __webpack_require__(306);
|
|
25157
25229
|
var isFunction_1 = __webpack_require__(817);
|
|
25158
|
-
var UnsubscriptionError_1 = __webpack_require__(
|
|
25230
|
+
var UnsubscriptionError_1 = __webpack_require__(294);
|
|
25159
25231
|
var Subscription = (function () {
|
|
25160
25232
|
function Subscription(unsubscribe) {
|
|
25161
25233
|
this.closed = false;
|
|
@@ -27940,7 +28012,7 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
27940
28012
|
};
|
|
27941
28013
|
})();
|
|
27942
28014
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27943
|
-
var AsyncScheduler_1 = __webpack_require__(
|
|
28015
|
+
var AsyncScheduler_1 = __webpack_require__(29);
|
|
27944
28016
|
var AnimationFrameScheduler = (function (_super) {
|
|
27945
28017
|
__extends(AnimationFrameScheduler, _super);
|
|
27946
28018
|
function AnimationFrameScheduler() {
|
|
@@ -30911,91 +30983,29 @@ util.inherits(module.exports.ISO_8859_7, sbcs);
|
|
|
30911
30983
|
/* 293 */
|
|
30912
30984
|
/***/ (function(module) {
|
|
30913
30985
|
|
|
30914
|
-
|
|
30915
|
-
|
|
30916
|
-
|
|
30917
|
-
module.exports = () => {
|
|
30918
|
-
const pattern = [
|
|
30919
|
-
'[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)',
|
|
30920
|
-
'(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))'
|
|
30921
|
-
].join('|');
|
|
30922
|
-
|
|
30923
|
-
return new RegExp(pattern, 'g');
|
|
30924
|
-
};
|
|
30925
|
-
|
|
30986
|
+
module.exports = require("buffer");
|
|
30926
30987
|
|
|
30927
30988
|
/***/ }),
|
|
30928
30989
|
/* 294 */
|
|
30929
|
-
/***/ (function(__unusedmodule, exports
|
|
30990
|
+
/***/ (function(__unusedmodule, exports) {
|
|
30930
30991
|
|
|
30931
30992
|
"use strict";
|
|
30932
30993
|
|
|
30933
|
-
var __extends = (this && this.__extends) || (function () {
|
|
30934
|
-
var extendStatics = function (d, b) {
|
|
30935
|
-
extendStatics = Object.setPrototypeOf ||
|
|
30936
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
30937
|
-
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
30938
|
-
return extendStatics(d, b);
|
|
30939
|
-
}
|
|
30940
|
-
return function (d, b) {
|
|
30941
|
-
extendStatics(d, b);
|
|
30942
|
-
function __() { this.constructor = d; }
|
|
30943
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
30944
|
-
};
|
|
30945
|
-
})();
|
|
30946
30994
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30947
|
-
var
|
|
30948
|
-
|
|
30949
|
-
|
|
30950
|
-
|
|
30951
|
-
|
|
30952
|
-
|
|
30953
|
-
|
|
30954
|
-
|
|
30955
|
-
}
|
|
30956
|
-
else {
|
|
30957
|
-
return now();
|
|
30958
|
-
}
|
|
30959
|
-
}) || this;
|
|
30960
|
-
_this.actions = [];
|
|
30961
|
-
_this.active = false;
|
|
30962
|
-
_this.scheduled = undefined;
|
|
30963
|
-
return _this;
|
|
30995
|
+
var UnsubscriptionErrorImpl = (function () {
|
|
30996
|
+
function UnsubscriptionErrorImpl(errors) {
|
|
30997
|
+
Error.call(this);
|
|
30998
|
+
this.message = errors ?
|
|
30999
|
+
errors.length + " errors occurred during unsubscription:\n" + errors.map(function (err, i) { return i + 1 + ") " + err.toString(); }).join('\n ') : '';
|
|
31000
|
+
this.name = 'UnsubscriptionError';
|
|
31001
|
+
this.errors = errors;
|
|
31002
|
+
return this;
|
|
30964
31003
|
}
|
|
30965
|
-
|
|
30966
|
-
|
|
30967
|
-
|
|
30968
|
-
|
|
30969
|
-
|
|
30970
|
-
else {
|
|
30971
|
-
return _super.prototype.schedule.call(this, work, delay, state);
|
|
30972
|
-
}
|
|
30973
|
-
};
|
|
30974
|
-
AsyncScheduler.prototype.flush = function (action) {
|
|
30975
|
-
var actions = this.actions;
|
|
30976
|
-
if (this.active) {
|
|
30977
|
-
actions.push(action);
|
|
30978
|
-
return;
|
|
30979
|
-
}
|
|
30980
|
-
var error;
|
|
30981
|
-
this.active = true;
|
|
30982
|
-
do {
|
|
30983
|
-
if (error = action.execute(action.state, action.delay)) {
|
|
30984
|
-
break;
|
|
30985
|
-
}
|
|
30986
|
-
} while (action = actions.shift());
|
|
30987
|
-
this.active = false;
|
|
30988
|
-
if (error) {
|
|
30989
|
-
while (action = actions.shift()) {
|
|
30990
|
-
action.unsubscribe();
|
|
30991
|
-
}
|
|
30992
|
-
throw error;
|
|
30993
|
-
}
|
|
30994
|
-
};
|
|
30995
|
-
return AsyncScheduler;
|
|
30996
|
-
}(Scheduler_1.Scheduler));
|
|
30997
|
-
exports.AsyncScheduler = AsyncScheduler;
|
|
30998
|
-
//# sourceMappingURL=AsyncScheduler.js.map
|
|
31004
|
+
UnsubscriptionErrorImpl.prototype = Object.create(Error.prototype);
|
|
31005
|
+
return UnsubscriptionErrorImpl;
|
|
31006
|
+
})();
|
|
31007
|
+
exports.UnsubscriptionError = UnsubscriptionErrorImpl;
|
|
31008
|
+
//# sourceMappingURL=UnsubscriptionError.js.map
|
|
30999
31009
|
|
|
31000
31010
|
/***/ }),
|
|
31001
31011
|
/* 295 */
|
|
@@ -31209,7 +31219,7 @@ if (process.platform === 'linux') {
|
|
|
31209
31219
|
|
|
31210
31220
|
"use strict";
|
|
31211
31221
|
|
|
31212
|
-
const ansiRegex = __webpack_require__(
|
|
31222
|
+
const ansiRegex = __webpack_require__(367);
|
|
31213
31223
|
|
|
31214
31224
|
module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input;
|
|
31215
31225
|
|
|
@@ -32774,7 +32784,7 @@ exports.empty = {
|
|
|
32774
32784
|
|
|
32775
32785
|
"use strict";
|
|
32776
32786
|
|
|
32777
|
-
var Buffer = __webpack_require__(
|
|
32787
|
+
var Buffer = __webpack_require__(293).Buffer;
|
|
32778
32788
|
// Note: not polyfilled with safer-buffer on a purpose, as overrides Buffer
|
|
32779
32789
|
|
|
32780
32790
|
// == Extend Node primitives to use iconv-lite =================================
|
|
@@ -32807,7 +32817,7 @@ module.exports = function (iconv) {
|
|
|
32807
32817
|
}
|
|
32808
32818
|
|
|
32809
32819
|
// -- SlowBuffer -----------------------------------------------------------
|
|
32810
|
-
var SlowBuffer = __webpack_require__(
|
|
32820
|
+
var SlowBuffer = __webpack_require__(293).SlowBuffer;
|
|
32811
32821
|
|
|
32812
32822
|
original.SlowBufferToString = SlowBuffer.prototype.toString;
|
|
32813
32823
|
SlowBuffer.prototype.toString = function(encoding, start, end) {
|
|
@@ -32970,7 +32980,7 @@ module.exports = function (iconv) {
|
|
|
32970
32980
|
|
|
32971
32981
|
delete Buffer.isNativeEncoding;
|
|
32972
32982
|
|
|
32973
|
-
var SlowBuffer = __webpack_require__(
|
|
32983
|
+
var SlowBuffer = __webpack_require__(293).SlowBuffer;
|
|
32974
32984
|
|
|
32975
32985
|
SlowBuffer.prototype.toString = original.SlowBufferToString;
|
|
32976
32986
|
SlowBuffer.prototype.write = original.SlowBufferWrite;
|
|
@@ -33209,25 +33219,20 @@ exports.defer = defer;
|
|
|
33209
33219
|
/* 365 */,
|
|
33210
33220
|
/* 366 */,
|
|
33211
33221
|
/* 367 */
|
|
33212
|
-
/***/ (function(
|
|
33222
|
+
/***/ (function(module) {
|
|
33213
33223
|
|
|
33214
33224
|
"use strict";
|
|
33215
33225
|
|
|
33216
|
-
|
|
33217
|
-
|
|
33218
|
-
|
|
33219
|
-
|
|
33220
|
-
|
|
33221
|
-
|
|
33222
|
-
|
|
33223
|
-
|
|
33224
|
-
|
|
33225
|
-
|
|
33226
|
-
UnsubscriptionErrorImpl.prototype = Object.create(Error.prototype);
|
|
33227
|
-
return UnsubscriptionErrorImpl;
|
|
33228
|
-
})();
|
|
33229
|
-
exports.UnsubscriptionError = UnsubscriptionErrorImpl;
|
|
33230
|
-
//# sourceMappingURL=UnsubscriptionError.js.map
|
|
33226
|
+
|
|
33227
|
+
module.exports = ({onlyFirst = false} = {}) => {
|
|
33228
|
+
const pattern = [
|
|
33229
|
+
'[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)',
|
|
33230
|
+
'(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))'
|
|
33231
|
+
].join('|');
|
|
33232
|
+
|
|
33233
|
+
return new RegExp(pattern, onlyFirst ? undefined : 'g');
|
|
33234
|
+
};
|
|
33235
|
+
|
|
33231
33236
|
|
|
33232
33237
|
/***/ }),
|
|
33233
33238
|
/* 368 */
|
|
@@ -35901,23 +35906,7 @@ exports.schedulePromise = schedulePromise;
|
|
|
35901
35906
|
//# sourceMappingURL=schedulePromise.js.map
|
|
35902
35907
|
|
|
35903
35908
|
/***/ }),
|
|
35904
|
-
/* 415
|
|
35905
|
-
/***/ (function(module) {
|
|
35906
|
-
|
|
35907
|
-
"use strict";
|
|
35908
|
-
|
|
35909
|
-
|
|
35910
|
-
module.exports = () => {
|
|
35911
|
-
const pattern = [
|
|
35912
|
-
'[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)',
|
|
35913
|
-
'(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))'
|
|
35914
|
-
].join('|');
|
|
35915
|
-
|
|
35916
|
-
return new RegExp(pattern, 'g');
|
|
35917
|
-
};
|
|
35918
|
-
|
|
35919
|
-
|
|
35920
|
-
/***/ }),
|
|
35909
|
+
/* 415 */,
|
|
35921
35910
|
/* 416 */
|
|
35922
35911
|
/***/ (function(__unusedmodule, exports, __webpack_require__) {
|
|
35923
35912
|
|
|
@@ -37586,7 +37575,7 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
37586
37575
|
};
|
|
37587
37576
|
})();
|
|
37588
37577
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37589
|
-
var AsyncScheduler_1 = __webpack_require__(
|
|
37578
|
+
var AsyncScheduler_1 = __webpack_require__(29);
|
|
37590
37579
|
var QueueScheduler = (function (_super) {
|
|
37591
37580
|
__extends(QueueScheduler, _super);
|
|
37592
37581
|
function QueueScheduler() {
|
|
@@ -39961,7 +39950,7 @@ module.exports = function dispatchRequest(config) {
|
|
|
39961
39950
|
"use strict";
|
|
39962
39951
|
|
|
39963
39952
|
|
|
39964
|
-
var Buffer = __webpack_require__(
|
|
39953
|
+
var Buffer = __webpack_require__(293).Buffer,
|
|
39965
39954
|
Transform = __webpack_require__(413).Transform;
|
|
39966
39955
|
|
|
39967
39956
|
|
|
@@ -45947,12 +45936,7 @@ module.exports = function (Yallist) {
|
|
|
45947
45936
|
module.exports = require("util");
|
|
45948
45937
|
|
|
45949
45938
|
/***/ }),
|
|
45950
|
-
/* 670
|
|
45951
|
-
/***/ (function(module) {
|
|
45952
|
-
|
|
45953
|
-
module.exports = require("buffer");
|
|
45954
|
-
|
|
45955
|
-
/***/ }),
|
|
45939
|
+
/* 670 */,
|
|
45956
45940
|
/* 671 */,
|
|
45957
45941
|
/* 672 */
|
|
45958
45942
|
/***/ (function(module, __unusedexports, __webpack_require__) {
|
|
@@ -48366,7 +48350,7 @@ module.exports = Axios;
|
|
|
48366
48350
|
|
|
48367
48351
|
|
|
48368
48352
|
const assert = __webpack_require__(357)
|
|
48369
|
-
const Buffer = __webpack_require__(
|
|
48353
|
+
const Buffer = __webpack_require__(293).Buffer
|
|
48370
48354
|
const realZlib = __webpack_require__(761)
|
|
48371
48355
|
|
|
48372
48356
|
const constants = exports.constants = __webpack_require__(980)
|
|
@@ -51513,27 +51497,7 @@ exports.TestTools = {
|
|
|
51513
51497
|
|
|
51514
51498
|
/***/ }),
|
|
51515
51499
|
/* 798 */,
|
|
51516
|
-
/* 799
|
|
51517
|
-
/***/ (function(module) {
|
|
51518
|
-
|
|
51519
|
-
"use strict";
|
|
51520
|
-
|
|
51521
|
-
|
|
51522
|
-
module.exports = options => {
|
|
51523
|
-
options = Object.assign({
|
|
51524
|
-
onlyFirst: false
|
|
51525
|
-
}, options);
|
|
51526
|
-
|
|
51527
|
-
const pattern = [
|
|
51528
|
-
'[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)',
|
|
51529
|
-
'(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))'
|
|
51530
|
-
].join('|');
|
|
51531
|
-
|
|
51532
|
-
return new RegExp(pattern, options.onlyFirst ? undefined : 'g');
|
|
51533
|
-
};
|
|
51534
|
-
|
|
51535
|
-
|
|
51536
|
-
/***/ }),
|
|
51500
|
+
/* 799 */,
|
|
51537
51501
|
/* 800 */,
|
|
51538
51502
|
/* 801 */
|
|
51539
51503
|
/***/ (function(module, __unusedexports, __webpack_require__) {
|
|
@@ -54186,7 +54150,7 @@ module.exports = {
|
|
|
54186
54150
|
|
|
54187
54151
|
"use strict";
|
|
54188
54152
|
|
|
54189
|
-
const ansiRegex = __webpack_require__(
|
|
54153
|
+
const ansiRegex = __webpack_require__(367);
|
|
54190
54154
|
|
|
54191
54155
|
module.exports = input => typeof input === 'string' ? input.replace(ansiRegex(), '') : input;
|
|
54192
54156
|
|
|
@@ -57164,7 +57128,7 @@ exports.subscribeToArray = function (array) { return function (subscriber) {
|
|
|
57164
57128
|
|
|
57165
57129
|
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
57166
57130
|
/* eslint-disable node/no-deprecated-api */
|
|
57167
|
-
var buffer = __webpack_require__(
|
|
57131
|
+
var buffer = __webpack_require__(293)
|
|
57168
57132
|
var Buffer = buffer.Buffer
|
|
57169
57133
|
|
|
57170
57134
|
// alternative to using Object.keys for old browsers
|
|
@@ -60744,7 +60708,7 @@ function detectEncoding(buf, defaultEncoding) {
|
|
|
60744
60708
|
|
|
60745
60709
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
60746
60710
|
var AsyncAction_1 = __webpack_require__(986);
|
|
60747
|
-
var AsyncScheduler_1 = __webpack_require__(
|
|
60711
|
+
var AsyncScheduler_1 = __webpack_require__(29);
|
|
60748
60712
|
exports.asyncScheduler = new AsyncScheduler_1.AsyncScheduler(AsyncAction_1.AsyncAction);
|
|
60749
60713
|
exports.async = exports.asyncScheduler;
|
|
60750
60714
|
//# sourceMappingURL=async.js.map
|
package/lib/helpers.js
CHANGED
|
@@ -6,7 +6,7 @@ exports.schemaKeys = ['v0', 'v1', 'v2', 'none'];
|
|
|
6
6
|
exports.fromKeys = ['local', 'remote', 'npm'];
|
|
7
7
|
exports.buildTypeKeys = ['all', 'release', 'emulator', 'emulator-sources'];
|
|
8
8
|
exports.clientTypeKeys = ['npm', 'pnpm', 'yarn'];
|
|
9
|
-
exports.bundlerKeys = ['none', 'parcel', 'webpack', 'webpack5'];
|
|
9
|
+
exports.bundlerKeys = ['none', 'parcel', 'webpack', 'webpack5', 'esbuild'];
|
|
10
10
|
exports.availableBundlers = [];
|
|
11
11
|
exports.availableReleaseProviders = [];
|
|
12
12
|
exports.frameworkKeys = ['piral', 'piral-core', 'piral-base'];
|
package/lib/helpers.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../src/helpers.ts"],"names":[],"mappings":";;;AAAA,0CAAgE;AAGnD,QAAA,UAAU,GAA8B,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC;AACnE,QAAA,QAAQ,GAA8B,CAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,CAAC,CAAC;AACjE,QAAA,aAAa,GAA0B,CAAC,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,kBAAkB,CAAC,CAAC;AAC1F,QAAA,cAAc,GAAyB,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;AAC/D,QAAA,WAAW,GAAkB,CAAC,MAAM,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../src/helpers.ts"],"names":[],"mappings":";;;AA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AC;AARD,kDAQC;AAEY,QAAA,iBAAiB,GAAG,MAAM,CAAC,IAAI,CAAC,sBAAc,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,sBAAc,CAAC,CAAC,CAAC,KAAK,QAAQ,CAAC,CAAC;AAElH,SAAgB,oBAAoB,CAAC,GAAW;IAC9C,KAAK,MAAM,gBAAgB,IAAI,yBAAiB,EAAE;QAChD,IAAI,gBAAgB,KAAK,GAAG,EAAE;YAC5B,OAAO,sBAAc,CAAC,gBAAgB,CAAC,CAAC;SACzC;KACF;IAED,OAAO,sBAAc,CAAC,EAAE,CAAC;AAC3B,CAAC;AARD,oDAQC;AAED,SAAgB,kBAAkB,CAAC,KAAqB;IACtD,KAAK,MAAM,gBAAgB,IAAI,yBAAiB,EAAE;QAChD,IAAI,sBAAc,CAAC,gBAAgB,CAAC,KAAK,KAAK,EAAE;YAC9C,OAAO,gBAAgB,CAAC;SACzB;KACF;IAED,OAAO,yBAAiB,CAAC,CAAC,CAAC,CAAC;AAC9B,CAAC;AARD,gDAQC"}
|
package/lib/injectors/piral.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { EventEmitter } from 'events';
|
|
3
|
+
import { KrasInjector, KrasResponse, KrasRequest, KrasInjectorConfig, KrasConfiguration } from 'kras';
|
|
2
4
|
import { Bundler } from '../types';
|
|
3
5
|
export interface PiralInjectorConfig extends KrasInjectorConfig {
|
|
4
6
|
bundler: Bundler;
|
|
5
7
|
}
|
|
6
8
|
export default class PiralInjector implements KrasInjector {
|
|
7
9
|
config: PiralInjectorConfig;
|
|
8
|
-
constructor(options: PiralInjectorConfig);
|
|
10
|
+
constructor(options: PiralInjectorConfig, _config: KrasConfiguration, core: EventEmitter);
|
|
9
11
|
get active(): boolean;
|
|
10
12
|
set active(value: boolean);
|
|
11
13
|
get name(): string;
|
package/lib/injectors/piral.js
CHANGED
|
@@ -8,8 +8,23 @@ const external_1 = require("../external");
|
|
|
8
8
|
*/
|
|
9
9
|
const maxRetrySendResponse = 4;
|
|
10
10
|
class PiralInjector {
|
|
11
|
-
constructor(options) {
|
|
11
|
+
constructor(options, _config, core) {
|
|
12
12
|
this.config = options;
|
|
13
|
+
const api = '/$events';
|
|
14
|
+
const cbs = {};
|
|
15
|
+
core.on('user-connected', (e) => {
|
|
16
|
+
if (e.target === '*' && e.url === api.substr(1)) {
|
|
17
|
+
cbs[e.id] = (msg) => e.ws.send(msg);
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
core.on('user-disconnected', (e) => {
|
|
21
|
+
delete cbs[e.id];
|
|
22
|
+
});
|
|
23
|
+
this.config.bundler.on((args) => {
|
|
24
|
+
for (const id of Object.keys(cbs)) {
|
|
25
|
+
cbs[id](JSON.stringify(args));
|
|
26
|
+
}
|
|
27
|
+
});
|
|
13
28
|
}
|
|
14
29
|
get active() {
|
|
15
30
|
return this.config.active;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"piral.js","sourceRoot":"","sources":["../../src/injectors/piral.ts"],"names":[],"mappings":";;AAAA,+BAA4B;
|
|
1
|
+
{"version":3,"file":"piral.js","sourceRoot":"","sources":["../../src/injectors/piral.ts"],"names":[],"mappings":";;AAAA,+BAA4B;AAE5B,2BAAwD;AAExD,0CAAmC;AAGnC;;GAEG;AACH,MAAM,oBAAoB,GAAG,CAAC,CAAC;AAM/B,MAAqB,aAAa;IAGhC,YAAY,OAA4B,EAAE,OAA0B,EAAE,IAAkB;QACtF,IAAI,CAAC,MAAM,GAAG,OAAO,CAAC;QACtB,MAAM,GAAG,GAAG,UAAU,CAAC;QACvB,MAAM,GAAG,GAAG,EAAE,CAAC;QAEf,IAAI,CAAC,EAAE,CAAC,gBAAgB,EAAE,CAAC,CAAC,EAAE,EAAE;YAC9B,IAAI,CAAC,CAAC,MAAM,KAAK,GAAG,IAAI,CAAC,CAAC,GAAG,KAAK,GAAG,CA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