new license file version [CI SKIP]
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
"use strict";
|
||||
|
||||
module.exports = {
|
||||
acosh: require("./acosh"),
|
||||
asinh: require("./asinh"),
|
||||
atanh: require("./atanh"),
|
||||
cbrt: require("./cbrt"),
|
||||
ceil10: require("./ceil-10"),
|
||||
clz32: require("./clz32"),
|
||||
cosh: require("./cosh"),
|
||||
expm1: require("./expm1"),
|
||||
floor10: require("./floor-10"),
|
||||
fround: require("./fround"),
|
||||
hypot: require("./hypot"),
|
||||
imul: require("./imul"),
|
||||
log10: require("./log10"),
|
||||
log2: require("./log2"),
|
||||
log1p: require("./log1p"),
|
||||
round10: require("./round-10"),
|
||||
sign: require("./sign"),
|
||||
sinh: require("./sinh"),
|
||||
tanh: require("./tanh"),
|
||||
trunc: require("./trunc")
|
||||
};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":";;AACA,mCAAgC;AAEhC;;GAEG;AACH,MAAM,MAAM,GAAG;IACb,gBAAgB,EAAE,kGAAkG;IACpH,wBAAwB,EAAE,wEAAwE;IAClG,0BAA0B,EAAE,gDAAgD;IAC5E,0BAA0B,EAAE,2FAA2F;IACvH,cAAc,EAAE,uCAAuC;IACvD,yBAAyB,EAAE,oEAAoE;IAC/F,cAAc,EAAE,uCAAuC;IACvD,yBAAyB,EAAE,oEAAoE;IAC/F,qBAAqB,EAAE,sEAAsE;IAC7F,qBAAqB,EAAE,yFAAyF;IAChH,0BAA0B,EAAE,0DAA0D;IACtF,2BAA2B,EAAE,2DAA2D;CACzF,CAAC;AAuGA,wBAAM;AArGR;;;;GAIG;AACH,SAAS,aAAa,CAAC,QAAwB;IAC7C,IAAI,CAAC,eAAM,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE;QAChC,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC;KAC1C;AACH,CAAC;AA4F0B,sCAAa;AA1FxC;;;;GAIG;AACH,SAAS,eAAe,CAAC,KAAa;IACpC,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK,CAAC,CAAC;AAC1E,CAAC;AAmFS,0CAAe;AAjFzB;;;;;GAKG;AACH,SAAS,wBAAwB,CAAC,KAAU,EAAE,MAAe;IAC3D,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC7B,oCAAoC;QACpC,IAAI,CAAC,eAAe,CAAC,KAAK,CAAC,IAAI,KAAK,GAAG,CAAC,EAAE;YACxC,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;SACzE;KACF;SAAM;QACL,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,yBAAyB,CAAC,CAAC,CAAC,MAAM,CAAC,yBAAyB,CAAC,CAAC;KAC/F;AACH,CAAC;AAED;;;;GAIG;AACH,SAAS,gBAAgB,CAAC,MAAW;IACnC,wBAAwB,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;AAC1C,CAAC;AA0DC,4CAAgB;AAxDlB;;;;GAIG;AACH,SAAS,gBAAgB,CAAC,MAAW;IACnC,wBAAwB,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;AACzC,CAAC;AAgDyC,4CAAgB;AA9C1D;;;;;GAKG;AACH,SAAS,iBAAiB,CAAC,MAAc,EAAE,IAAiB;IAC1D,IAAI,MAAM,GAAG,CAAC,IAAI,MAAM,GAAG,IAAI,CAAC,MAAM,EAAE;QACtC,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC,qBAAqB,CAAC,CAAC;KAC/C;AACH,CAAC;AAqCmB,8CAAiB;AAnCrC;;;GAGG;AACH,SAAS,SAAS,CAAC,KAAa;IAC9B,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,KAAK,CAAC;AACrF,CAAC;AAcD;;GAEG;AACH,SAAS,yBAAyB,CAAC,YAA0B;IAC3D,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE;QACjC,MAAM,IAAI,KAAK,CAAC,2CAA2C,CAAC,CAAC;KAC9D;IAED,IAAI,OAAO,eAAM,CAAC,SAAS,CAAC,YAAY,CAAC,KAAK,WAAW,EAAE;QACzD,MAAM,IAAI,KAAK,CAAC,8CAA8C,YAAY,GAAG,CAAC,CAAC;KAChF;AACH,CAAC;AAIsC,8DAAyB"}
|
||||
@@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2016-2021 Thomas Watson Steen
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"es6-iterator","version":"2.0.3","files":{"package.json":{"checkedAt":1678883668460,"integrity":"sha512-TsDRkoBPOra9N5UBhzpT0lhSLfITDWRFUx+ZfGCaSvQnwpoT6aGKkDs2yeDo4x829ben3L/hpsPKZ2GPueFj2w==","mode":420,"size":889},".npmignore":{"checkedAt":1678883668460,"integrity":"sha512-FzpXBFKE+RGti3gtVfg/A4WgOHbDjv/Qat6Q3PHlx2rvoIC5RnYJXHyn2N1tJ6tS3EW+R95ji/Zr3R54MUtzIA==","mode":420,"size":140},"LICENSE":{"checkedAt":1678883668460,"integrity":"sha512-lChBOZKSzJ7H7anQ2MS9vS0OqPC9trwPYDxoPjsAKvFCOSj3uCITI+gN7aDWRJUeUVNnBIdD3mqMaZyqylTA4g==","mode":420,"size":1103},"valid-iterable.js":{"checkedAt":1678883668460,"integrity":"sha512-t8shcM/YvPOYt3F0EcZkPaXg6pwczvwVpEdbim5B3uI/6VR9vEk1Nc28Imfb/5Um3ioPqeEm1hc+DdeOV5wafA==","mode":420,"size":187},"array.js":{"checkedAt":1678883668460,"integrity":"sha512-PFFEylToTBmcJ7pqi+mmMSF/LJOxOr0KcrvxXSsFF0muBZBoWq6T//9HW994QGcUSGH0bniEwlquDL899ziEMg==","mode":420,"size":1198},"README.md":{"checkedAt":1678883668460,"integrity":"sha512-N0aPacsl7BiEqoqOMEzbpR3mF6M25dNb8ZF0a0a+PirsM5/mV4SLJ6J/XqZ39UKph1WmICWU3nY8cmcStY8R8Q==","mode":420,"size":4274},"get.js":{"checkedAt":1678883668460,"integrity":"sha512-sCXptkWD+KTsQYD7CIqrlTF2BFwJXNr39OveS3Qk+dDGyXJf8HXbQgn+nD19Wz3E25gHaVqCukW8PawOjxc/HA==","mode":420,"size":581},"is-iterable.js":{"checkedAt":1678883668475,"integrity":"sha512-PZ/C5WswmUVQ8rbdPF+CDzkO7dOUQt6p3/49TRi3BCzA0ygZ6I9vAXkf1+GadXVj8nJ1NWsR6PHMuEqA2GME+Q==","mode":420,"size":507},"string.js":{"checkedAt":1678883668475,"integrity":"sha512-Fs/O8xL6a7DM9xROqkNXBBSFHTAKpS22E+U0t1a8yXhSpcg/lHZ0/8Umz2+r27vEB9DBEK61Hk0HG4HOzbe5Lw==","mode":420,"size":1379},"for-of.js":{"checkedAt":1678883668475,"integrity":"sha512-pc1h4a6e1nRJX1Lg7eixZfUZzukW2xBRaZ2bp60v6nzshkokmgCwQTsHwdHghekQ5eEpgaR9X+TkMirgQXARyw==","mode":420,"size":1281},"CHANGELOG.md":{"checkedAt":1678883668475,"integrity":"sha512-hRqck8N6bKa7oXQ8mi4RpPt5yqrVHTs7CVVQE88V2qOPIuEPIaFMXHotYnk1JFupyuL+QAEB9WjOmmBZXg2Mow==","mode":420,"size":978},"CHANGES":{"checkedAt":1678883668475,"integrity":"sha512-Sm1nUdQbHBkB+vdjsDZJHFMwHEGxynWAQVHpmSzxx7sfM3M4hc3gApOqvW6sxxhKC2zfPXoKaXs2IyOKt2FwiQ==","mode":420,"size":1257},"#/chain.js":{"checkedAt":1678883668475,"integrity":"sha512-d40+POLQeqFwu2BvB+D5ffi+0XSH+34qhd7RyZbd2594hs+c9EisfYINTR2RJpfh7k3SpMsotckO0AiRoOSdyw==","mode":420,"size":1118},".editorconfig":{"checkedAt":1678883668475,"integrity":"sha512-jmYvr9NhcYKI7yMGT+E1to3XJ2T2hCqVcUZ9R/J/7dvqB3/X7QyqBIFVb9dxVAmSUhEu1y20fCjN9FfExMFvjQ==","mode":420,"size":272},"index.js":{"checkedAt":1678883668475,"integrity":"sha512-K/bO3jv5/B/6yLSH3YOiAb8HeJP78dtJ6EAPx7MsDM7pLlc+6nUAibg7kFUy1R3cjcht6vBgrjWWWh22mmD7wA==","mode":420,"size":2964},"test/for-of.js":{"checkedAt":1678883668482,"integrity":"sha512-WhOCxj/xdGiDaauV5o2jjgphCM0L891xBgrmDHEanoBkT4Q/XY/WeDY7Pj1vLeMx6/KzWK/pOW1m0+ctqICELw==","mode":420,"size":1202},"test/array.js":{"checkedAt":1678883668482,"integrity":"sha512-Q5f+E4VAZMZ4JtmUfG4WxdlKD7Dfa39lDbKCDOQmmGYCfp/kQMu/Y43GE3gPD3QMzXeWt+14RLFbxShFp3zbeA==","mode":420,"size":2587},"test/get.js":{"checkedAt":1678883668482,"integrity":"sha512-EoeZZ65a5Zpc68cBaRrO206LjJqYcE9EW8s7Iii2VaYv/SRmwwV8yFSctFVdEiOlEC9+jOPajXvDqb/cOa1PGg==","mode":420,"size":698},"test/string.js":{"checkedAt":1678883668482,"integrity":"sha512-HN9PyWSf692QZ6nXLkvllH3fufuv3PyWhj7SDkiRgiI0mTr8MAqx+a+ql72FZmGeB3bVfNa4yvh8efgngWwapA==","mode":420,"size":848},"test/index.js":{"checkedAt":1678883668482,"integrity":"sha512-py1/Yzt3hsBai8LZFhu29Hj+vaJ9db/DALDcQG4dnWMTFlhOjL4w/+ij8yFwia4aQFo72GqLJbuJYELzd7+stA==","mode":420,"size":3509},"test/is-iterable.js":{"checkedAt":1678883668482,"integrity":"sha512-wu8AyAlpfC1/ma48Ot7mw+OCANvRod50gofThmJ+SZ4MD5Ojaqc0i9NS/rigaRFe/9ROQTENZffWYIOKyBK9rw==","mode":420,"size":568},"test/.eslintrc.json":{"checkedAt":1678883668482,"integrity":"sha512-wVmSm94YtF7EwaAc8SUiswtkuZk2j4m369hda8MGKWF0WaSAvJixeCy71p+KMuaSe929ys/UusXOBxNUCfcGaA==","mode":420,"size":44},"test/valid-iterable.js":{"checkedAt":1678883668482,"integrity":"sha512-HkBC2QvzpYz+EF0tE6gWRTOHSPBSKeoxfBjcWr4fyqEvVmvRPP6Vp5OZqAPIzdQS6sTLuA8cyGpYbrSeC5ihUQ==","mode":420,"size":566},"test/#/chain.js":{"checkedAt":1678883668482,"integrity":"sha512-x7zZu5lOKe5+dfHalyDWH35rbaCrFjXnWdD81CbG4s9eeyZrhXCqUyLDP/G1MfqOShQFaAnfdMZirWTijaRnDg==","mode":420,"size":1019},"appveyor.yml":{"checkedAt":1678883668519,"integrity":"sha512-2Y/TpZp9CQKfIpvC5oDCHd1ytiaSpciCKYIWD0947rOve5JDZX05/dUyyHwhJT2c0x7uTdJZsffeiuiEuu8wiA==","mode":420,"size":577}}}
|
||||
@@ -0,0 +1,3 @@
|
||||
"name","age"
|
||||
"joe","20"
|
||||
"sam","30"
|
||||
@@ -0,0 +1,9 @@
|
||||
import { OperatorFunction, ObservedValueOf, ObservableInput } from '../types';
|
||||
/** @deprecated Will be removed in v9. Use {@link mergeMap} instead: `mergeMap(() => result)` */
|
||||
export declare function mergeMapTo<O extends ObservableInput<unknown>>(innerObservable: O, concurrent?: number): OperatorFunction<unknown, ObservedValueOf<O>>;
|
||||
/**
|
||||
* @deprecated The `resultSelector` parameter will be removed in v8. Use an inner `map` instead.
|
||||
* Details: https://rxjs.dev/deprecations/resultSelector
|
||||
*/
|
||||
export declare function mergeMapTo<T, R, O extends ObservableInput<unknown>>(innerObservable: O, resultSelector: (outerValue: T, innerValue: ObservedValueOf<O>, outerIndex: number, innerIndex: number) => R, concurrent?: number): OperatorFunction<T, R>;
|
||||
//# sourceMappingURL=mergeMapTo.d.ts.map
|
||||
@@ -0,0 +1,3 @@
|
||||
'use strict';
|
||||
|
||||
module.exports = require('./async').someLimit;
|
||||
@@ -0,0 +1,60 @@
|
||||
# promise.allsettled <sup>[![Version Badge][npm-version-svg]][package-url]</sup>
|
||||
|
||||
[![github actions][actions-image]][actions-url]
|
||||
[![coverage][codecov-image]][codecov-url]
|
||||
[![dependency status][deps-svg]][deps-url]
|
||||
[![dev dependency status][dev-deps-svg]][dev-deps-url]
|
||||
[![License][license-image]][license-url]
|
||||
[![Downloads][downloads-image]][downloads-url]
|
||||
|
||||
[![npm badge][npm-badge-png]][package-url]
|
||||
|
||||
ES Proposal spec-compliant shim for Promise.allSettled. Invoke its "shim" method to shim `Promise.allSettled` if it is unavailable or noncompliant. **Note**: a global `Promise` must already exist: the [es6-shim](https://github.com/es-shims/es6-shim) is recommended.
|
||||
|
||||
This package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment that has `Promise` available globally, and complies with the [proposed spec](https://github.com/tc39/proposal-promise-allSettled).
|
||||
|
||||
Most common usage:
|
||||
```js
|
||||
var assert = require('assert');
|
||||
var allSettled = require('promise.allsettled');
|
||||
|
||||
var resolved = Promise.resolve(42);
|
||||
var rejected = Promise.reject(-1);
|
||||
|
||||
allSettled([resolved, rejected]).then(function (results) {
|
||||
assert.deepEqual(results, [
|
||||
{ status: 'fulfilled', value: 42 },
|
||||
{ status: 'rejected', reason: -1 }
|
||||
]);
|
||||
});
|
||||
|
||||
allSettled.shim(); // will be a no-op if not needed
|
||||
|
||||
Promise.allSettled([resolved, rejected]).then(function (results) {
|
||||
assert.deepEqual(results, [
|
||||
{ status: 'fulfilled', value: 42 },
|
||||
{ status: 'rejected', reason: -1 }
|
||||
]);
|
||||
});
|
||||
```
|
||||
|
||||
## Tests
|
||||
Simply clone the repo, `npm install`, and run `npm test`
|
||||
|
||||
[package-url]: https://npmjs.com/package/promise.allsettled
|
||||
[npm-version-svg]: http://versionbadg.es/es-shims/Promise.allSettled.svg
|
||||
[travis-svg]: https://travis-ci.org/es-shims/Promise.allSettled.svg
|
||||
[travis-url]: https://travis-ci.org/es-shims/Promise.allSettled
|
||||
[deps-svg]: https://david-dm.org/es-shims/Promise.allSettled.svg
|
||||
[deps-url]: https://david-dm.org/es-shims/Promise.allSettled
|
||||
[dev-deps-svg]: https://david-dm.org/es-shims/Promise.allSettled/dev-status.svg
|
||||
[dev-deps-url]: https://david-dm.org/es-shims/Promise.allSettled#info=devDependencies
|
||||
[npm-badge-png]: https://nodei.co/npm/promise.allsettled.png?downloads=true&stars=true
|
||||
[license-image]: http://img.shields.io/npm/l/promise.allsettled.svg
|
||||
[license-url]: LICENSE
|
||||
[downloads-image]: http://img.shields.io/npm/dm/promise.allsettled.svg
|
||||
[downloads-url]: http://npm-stat.com/charts.html?package=promise.allsettled
|
||||
[codecov-image]: https://codecov.io/gh/es-shims/Promise.allSettled/branch/main/graphs/badge.svg
|
||||
[codecov-url]: https://app.codecov.io/gh/es-shims/Promise.allSettled/
|
||||
[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/es-shims/Promise.allSettled
|
||||
[actions-url]: https://github.com/es-shims/Promise.allSettled/actions
|
||||
@@ -0,0 +1,9 @@
|
||||
'use strict';
|
||||
|
||||
var $DateGetTime = require('call-bind/callBound')('Date.prototype.getTime');
|
||||
|
||||
// https://262.ecma-international.org/6.0/#sec-properties-of-the-date-prototype-object
|
||||
|
||||
module.exports = function thisTimeValue(value) {
|
||||
return $DateGetTime(value);
|
||||
};
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"all": true,
|
||||
"check-coverage": false,
|
||||
"reporter": ["text-summary", "text", "html", "json"],
|
||||
"lines": 86,
|
||||
"statements": 85.93,
|
||||
"functions": 82.43,
|
||||
"branches": 76.06,
|
||||
"exclude": [
|
||||
"coverage",
|
||||
"example",
|
||||
"test"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
export type DonationNotFoundError = {
|
||||
name: string;
|
||||
message: string;
|
||||
};
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"is-fullwidth-code-point","version":"3.0.0","files":{"license":{"checkedAt":1678883669272,"integrity":"sha512-nIst73auX/5NY2Fmv5Y116vWnNrEv4GaIUX3lpZG05rpXJY2S8EX+fpUS5hRjClCM0VdT2Za9DDHXXB5jdSrEw==","mode":420,"size":1109},"package.json":{"checkedAt":1678883669276,"integrity":"sha512-xyB3x7+DHvgA+Wuv5Cs+JTT3HM7yENlYIxVjmNk8N8op5/PsVHt6n4/sDJS0JkeqX+M1luBnGitPmFI2yiNsOA==","mode":420,"size":737},"index.js":{"checkedAt":1678883669276,"integrity":"sha512-tozMz77t8FloCEmMAEri5pyXOYMNkvnIbUsafyNPeaf02/PwgZkyVuDGFkpZBEckIMvHxzT6tU8TcgNr5B11Wg==","mode":420,"size":1756},"index.d.ts":{"checkedAt":1678883669276,"integrity":"sha512-fHwEYWUcTAwtW0gJ3vSzB50uqH/t/KdcT5tKa7am3MZgdAoUwiKKQiXJdMnNwz1Yk8nOFiFRxH6/q8IbWXfBuA==","mode":420,"size":549},"readme.md":{"checkedAt":1678883669276,"integrity":"sha512-ryRepI/uv2OTRCsXqsu1FEAGtejATQl0ssLVwMLWilGZKT76wPFvqvGf7CAXZLPYUvqmfJ2CsUMV7xdXjplRAQ==","mode":420,"size":843}}}
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"human-signals","version":"4.3.0","files":{"LICENSE":{"checkedAt":1678883670719,"integrity":"sha512-GkKGzYRPS68ql+tWbIOS/+e5TfE1+ju2awg6AH/0SShsb7YGxfq42Dh11iDycc8kskEth3fd6QwGOHID8tKhcA==","mode":420,"size":11357},"build/src/core.js":{"checkedAt":1678883670719,"integrity":"sha512-m/a5o/BsW+tICnCtt/7Om3iSSKUUA4vDWC30wZKk5f7CDi/WN8nzt01Q6CvZD012YCw/cj/66expOh2ZJk/Dlg==","mode":420,"size":4158},"build/src/realtime.js":{"checkedAt":1678883670719,"integrity":"sha512-oyTM2xX2A7KJhG5SPWYZ3WttE6+8YE1yYTCTE9D/PyTeuNWJFmLNL1y4cKntrcNrGAoT1m4gmljFU3YoCcz0ZA==","mode":420,"size":411},"build/src/main.js":{"checkedAt":1678883670719,"integrity":"sha512-Azum6k53oeGCdAWKWBKrVZusHb1cdpRmO8xL5HnV57ckHY89n8DJmnA/L15GiOY2HsoD7g2SC6WivZVM/ZHUvw==","mode":420,"size":1291},"package.json":{"checkedAt":1678883670719,"integrity":"sha512-mPbU0j5gvdYKtbzVdhtB/qnU0v4o/hoa4fUrmSoJXNrA8PUdiut3HGU4is4xYLs/8F1foB88h9gzdrnOkIN+7Q==","mode":420,"size":1265},"build/types/main.d.ts":{"checkedAt":1678883670719,"integrity":"sha512-CcrLiKK5LpjmhSeW553iM8vIkWOpkXaUlWRCGbolqB8MdEW++uahkwgVnel18Cityhg67J09sn9LdsBng07xUQ==","mode":420,"size":1803},"build/src/signals.js":{"checkedAt":1678883670719,"integrity":"sha512-LjYkIBcZiqiehY67wfIaG9vI3G83LVuZm8vQtbVnBVcqzFhl30gBHJ7Wh76avnX5nJtgDVeVG6+tWow4J2zrTQ==","mode":420,"size":651},"README.md":{"checkedAt":1678883670719,"integrity":"sha512-VYpdV8v6uNfMn8no7FUvm63hLK7RneWNYaWuIlmj61j65kzZ9c7c6C2jZdspLiafbdGCbx6s9JTBG4sSkVZI6A==","mode":420,"size":5087}}}
|
||||
@@ -0,0 +1,28 @@
|
||||
var LazyWrapper = require('./_LazyWrapper'),
|
||||
getData = require('./_getData'),
|
||||
getFuncName = require('./_getFuncName'),
|
||||
lodash = require('./wrapperLodash');
|
||||
|
||||
/**
|
||||
* Checks if `func` has a lazy counterpart.
|
||||
*
|
||||
* @private
|
||||
* @param {Function} func The function to check.
|
||||
* @returns {boolean} Returns `true` if `func` has a lazy counterpart,
|
||||
* else `false`.
|
||||
*/
|
||||
function isLaziable(func) {
|
||||
var funcName = getFuncName(func),
|
||||
other = lodash[funcName];
|
||||
|
||||
if (typeof other != 'function' || !(funcName in LazyWrapper.prototype)) {
|
||||
return false;
|
||||
}
|
||||
if (func === other) {
|
||||
return true;
|
||||
}
|
||||
var data = getData(other);
|
||||
return !!data && func === data[0];
|
||||
}
|
||||
|
||||
module.exports = isLaziable;
|
||||
@@ -0,0 +1,343 @@
|
||||
"use strict";;
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var tslib_1 = require("tslib");
|
||||
var types_1 = tslib_1.__importDefault(require("./types"));
|
||||
var node_path_1 = tslib_1.__importDefault(require("./node-path"));
|
||||
var hasOwn = Object.prototype.hasOwnProperty;
|
||||
function pathVisitorPlugin(fork) {
|
||||
var types = fork.use(types_1.default);
|
||||
var NodePath = fork.use(node_path_1.default);
|
||||
var isArray = types.builtInTypes.array;
|
||||
var isObject = types.builtInTypes.object;
|
||||
var isFunction = types.builtInTypes.function;
|
||||
var undefined;
|
||||
var PathVisitor = function PathVisitor() {
|
||||
if (!(this instanceof PathVisitor)) {
|
||||
throw new Error("PathVisitor constructor cannot be invoked without 'new'");
|
||||
}
|
||||
// Permanent state.
|
||||
this._reusableContextStack = [];
|
||||
this._methodNameTable = computeMethodNameTable(this);
|
||||
this._shouldVisitComments =
|
||||
hasOwn.call(this._methodNameTable, "Block") ||
|
||||
hasOwn.call(this._methodNameTable, "Line");
|
||||
this.Context = makeContextConstructor(this);
|
||||
// State reset every time PathVisitor.prototype.visit is called.
|
||||
this._visiting = false;
|
||||
this._changeReported = false;
|
||||
};
|
||||
function computeMethodNameTable(visitor) {
|
||||
var typeNames = Object.create(null);
|
||||
for (var methodName in visitor) {
|
||||
if (/^visit[A-Z]/.test(methodName)) {
|
||||
typeNames[methodName.slice("visit".length)] = true;
|
||||
}
|
||||
}
|
||||
var supertypeTable = types.computeSupertypeLookupTable(typeNames);
|
||||
var methodNameTable = Object.create(null);
|
||||
var typeNameKeys = Object.keys(supertypeTable);
|
||||
var typeNameCount = typeNameKeys.length;
|
||||
for (var i = 0; i < typeNameCount; ++i) {
|
||||
var typeName = typeNameKeys[i];
|
||||
methodName = "visit" + supertypeTable[typeName];
|
||||
if (isFunction.check(visitor[methodName])) {
|
||||
methodNameTable[typeName] = methodName;
|
||||
}
|
||||
}
|
||||
return methodNameTable;
|
||||
}
|
||||
PathVisitor.fromMethodsObject = function fromMethodsObject(methods) {
|
||||
if (methods instanceof PathVisitor) {
|
||||
return methods;
|
||||
}
|
||||
if (!isObject.check(methods)) {
|
||||
// An empty visitor?
|
||||
return new PathVisitor;
|
||||
}
|
||||
var Visitor = function Visitor() {
|
||||
if (!(this instanceof Visitor)) {
|
||||
throw new Error("Visitor constructor cannot be invoked without 'new'");
|
||||
}
|
||||
PathVisitor.call(this);
|
||||
};
|
||||
var Vp = Visitor.prototype = Object.create(PVp);
|
||||
Vp.constructor = Visitor;
|
||||
extend(Vp, methods);
|
||||
extend(Visitor, PathVisitor);
|
||||
isFunction.assert(Visitor.fromMethodsObject);
|
||||
isFunction.assert(Visitor.visit);
|
||||
return new Visitor;
|
||||
};
|
||||
function extend(target, source) {
|
||||
for (var property in source) {
|
||||
if (hasOwn.call(source, property)) {
|
||||
target[property] = source[property];
|
||||
}
|
||||
}
|
||||
return target;
|
||||
}
|
||||
PathVisitor.visit = function visit(node, methods) {
|
||||
return PathVisitor.fromMethodsObject(methods).visit(node);
|
||||
};
|
||||
var PVp = PathVisitor.prototype;
|
||||
PVp.visit = function () {
|
||||
if (this._visiting) {
|
||||
throw new Error("Recursively calling visitor.visit(path) resets visitor state. " +
|
||||
"Try this.visit(path) or this.traverse(path) instead.");
|
||||
}
|
||||
// Private state that needs to be reset before every traversal.
|
||||
this._visiting = true;
|
||||
this._changeReported = false;
|
||||
this._abortRequested = false;
|
||||
var argc = arguments.length;
|
||||
var args = new Array(argc);
|
||||
for (var i = 0; i < argc; ++i) {
|
||||
args[i] = arguments[i];
|
||||
}
|
||||
if (!(args[0] instanceof NodePath)) {
|
||||
args[0] = new NodePath({ root: args[0] }).get("root");
|
||||
}
|
||||
// Called with the same arguments as .visit.
|
||||
this.reset.apply(this, args);
|
||||
var didNotThrow;
|
||||
try {
|
||||
var root = this.visitWithoutReset(args[0]);
|
||||
didNotThrow = true;
|
||||
}
|
||||
finally {
|
||||
this._visiting = false;
|
||||
if (!didNotThrow && this._abortRequested) {
|
||||
// If this.visitWithoutReset threw an exception and
|
||||
// this._abortRequested was set to true, return the root of
|
||||
// the AST instead of letting the exception propagate, so that
|
||||
// client code does not have to provide a try-catch block to
|
||||
// intercept the AbortRequest exception. Other kinds of
|
||||
// exceptions will propagate without being intercepted and
|
||||
// rethrown by a catch block, so their stacks will accurately
|
||||
// reflect the original throwing context.
|
||||
return args[0].value;
|
||||
}
|
||||
}
|
||||
return root;
|
||||
};
|
||||
PVp.AbortRequest = function AbortRequest() { };
|
||||
PVp.abort = function () {
|
||||
var visitor = this;
|
||||
visitor._abortRequested = true;
|
||||
var request = new visitor.AbortRequest();
|
||||
// If you decide to catch this exception and stop it from propagating,
|
||||
// make sure to call its cancel method to avoid silencing other
|
||||
// exceptions that might be thrown later in the traversal.
|
||||
request.cancel = function () {
|
||||
visitor._abortRequested = false;
|
||||
};
|
||||
throw request;
|
||||
};
|
||||
PVp.reset = function (_path /*, additional arguments */) {
|
||||
// Empty stub; may be reassigned or overridden by subclasses.
|
||||
};
|
||||
PVp.visitWithoutReset = function (path) {
|
||||
if (this instanceof this.Context) {
|
||||
// Since this.Context.prototype === this, there's a chance we
|
||||
// might accidentally call context.visitWithoutReset. If that
|
||||
// happens, re-invoke the method against context.visitor.
|
||||
return this.visitor.visitWithoutReset(path);
|
||||
}
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
var value = path.value;
|
||||
var methodName = value &&
|
||||
typeof value === "object" &&
|
||||
typeof value.type === "string" &&
|
||||
this._methodNameTable[value.type];
|
||||
if (methodName) {
|
||||
var context = this.acquireContext(path);
|
||||
try {
|
||||
return context.invokeVisitorMethod(methodName);
|
||||
}
|
||||
finally {
|
||||
this.releaseContext(context);
|
||||
}
|
||||
}
|
||||
else {
|
||||
// If there was no visitor method to call, visit the children of
|
||||
// this node generically.
|
||||
return visitChildren(path, this);
|
||||
}
|
||||
};
|
||||
function visitChildren(path, visitor) {
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(visitor instanceof PathVisitor)) {
|
||||
throw new Error("");
|
||||
}
|
||||
var value = path.value;
|
||||
if (isArray.check(value)) {
|
||||
path.each(visitor.visitWithoutReset, visitor);
|
||||
}
|
||||
else if (!isObject.check(value)) {
|
||||
// No children to visit.
|
||||
}
|
||||
else {
|
||||
var childNames = types.getFieldNames(value);
|
||||
// The .comments field of the Node type is hidden, so we only
|
||||
// visit it if the visitor defines visitBlock or visitLine, and
|
||||
// value.comments is defined.
|
||||
if (visitor._shouldVisitComments &&
|
||||
value.comments &&
|
||||
childNames.indexOf("comments") < 0) {
|
||||
childNames.push("comments");
|
||||
}
|
||||
var childCount = childNames.length;
|
||||
var childPaths = [];
|
||||
for (var i = 0; i < childCount; ++i) {
|
||||
var childName = childNames[i];
|
||||
if (!hasOwn.call(value, childName)) {
|
||||
value[childName] = types.getFieldValue(value, childName);
|
||||
}
|
||||
childPaths.push(path.get(childName));
|
||||
}
|
||||
for (var i = 0; i < childCount; ++i) {
|
||||
visitor.visitWithoutReset(childPaths[i]);
|
||||
}
|
||||
}
|
||||
return path.value;
|
||||
}
|
||||
PVp.acquireContext = function (path) {
|
||||
if (this._reusableContextStack.length === 0) {
|
||||
return new this.Context(path);
|
||||
}
|
||||
return this._reusableContextStack.pop().reset(path);
|
||||
};
|
||||
PVp.releaseContext = function (context) {
|
||||
if (!(context instanceof this.Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
this._reusableContextStack.push(context);
|
||||
context.currentPath = null;
|
||||
};
|
||||
PVp.reportChanged = function () {
|
||||
this._changeReported = true;
|
||||
};
|
||||
PVp.wasChangeReported = function () {
|
||||
return this._changeReported;
|
||||
};
|
||||
function makeContextConstructor(visitor) {
|
||||
function Context(path) {
|
||||
if (!(this instanceof Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(this instanceof PathVisitor)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
Object.defineProperty(this, "visitor", {
|
||||
value: visitor,
|
||||
writable: false,
|
||||
enumerable: true,
|
||||
configurable: false
|
||||
});
|
||||
this.currentPath = path;
|
||||
this.needToCallTraverse = true;
|
||||
Object.seal(this);
|
||||
}
|
||||
if (!(visitor instanceof PathVisitor)) {
|
||||
throw new Error("");
|
||||
}
|
||||
// Note that the visitor object is the prototype of Context.prototype,
|
||||
// so all visitor methods are inherited by context objects.
|
||||
var Cp = Context.prototype = Object.create(visitor);
|
||||
Cp.constructor = Context;
|
||||
extend(Cp, sharedContextProtoMethods);
|
||||
return Context;
|
||||
}
|
||||
// Every PathVisitor has a different this.Context constructor and
|
||||
// this.Context.prototype object, but those prototypes can all use the
|
||||
// same reset, invokeVisitorMethod, and traverse function objects.
|
||||
var sharedContextProtoMethods = Object.create(null);
|
||||
sharedContextProtoMethods.reset =
|
||||
function reset(path) {
|
||||
if (!(this instanceof this.Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
this.currentPath = path;
|
||||
this.needToCallTraverse = true;
|
||||
return this;
|
||||
};
|
||||
sharedContextProtoMethods.invokeVisitorMethod =
|
||||
function invokeVisitorMethod(methodName) {
|
||||
if (!(this instanceof this.Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(this.currentPath instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
var result = this.visitor[methodName].call(this, this.currentPath);
|
||||
if (result === false) {
|
||||
// Visitor methods return false to indicate that they have handled
|
||||
// their own traversal needs, and we should not complain if
|
||||
// this.needToCallTraverse is still true.
|
||||
this.needToCallTraverse = false;
|
||||
}
|
||||
else if (result !== undefined) {
|
||||
// Any other non-undefined value returned from the visitor method
|
||||
// is interpreted as a replacement value.
|
||||
this.currentPath = this.currentPath.replace(result)[0];
|
||||
if (this.needToCallTraverse) {
|
||||
// If this.traverse still hasn't been called, visit the
|
||||
// children of the replacement node.
|
||||
this.traverse(this.currentPath);
|
||||
}
|
||||
}
|
||||
if (this.needToCallTraverse !== false) {
|
||||
throw new Error("Must either call this.traverse or return false in " + methodName);
|
||||
}
|
||||
var path = this.currentPath;
|
||||
return path && path.value;
|
||||
};
|
||||
sharedContextProtoMethods.traverse =
|
||||
function traverse(path, newVisitor) {
|
||||
if (!(this instanceof this.Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(this.currentPath instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
this.needToCallTraverse = false;
|
||||
return visitChildren(path, PathVisitor.fromMethodsObject(newVisitor || this.visitor));
|
||||
};
|
||||
sharedContextProtoMethods.visit =
|
||||
function visit(path, newVisitor) {
|
||||
if (!(this instanceof this.Context)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(path instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
if (!(this.currentPath instanceof NodePath)) {
|
||||
throw new Error("");
|
||||
}
|
||||
this.needToCallTraverse = false;
|
||||
return PathVisitor.fromMethodsObject(newVisitor || this.visitor).visitWithoutReset(path);
|
||||
};
|
||||
sharedContextProtoMethods.reportChanged = function reportChanged() {
|
||||
this.visitor.reportChanged();
|
||||
};
|
||||
sharedContextProtoMethods.abort = function abort() {
|
||||
this.needToCallTraverse = false;
|
||||
this.visitor.abort();
|
||||
};
|
||||
return PathVisitor;
|
||||
}
|
||||
exports.default = pathVisitorPlugin;
|
||||
module.exports = exports["default"];
|
||||
@@ -0,0 +1,35 @@
|
||||
import type {Except} from './except';
|
||||
import type {Simplify} from './simplify';
|
||||
|
||||
/**
|
||||
Create a type that makes the given keys non-nullable. The remaining keys are kept as is.
|
||||
|
||||
Use-case: You want to define a single model where the only thing that changes is whether or not some of the keys are non-nullable.
|
||||
|
||||
@example
|
||||
```
|
||||
import type {SetNonNullable} from 'type-fest';
|
||||
|
||||
type Foo = {
|
||||
a: number;
|
||||
b: string | undefined;
|
||||
c?: boolean | null;
|
||||
}
|
||||
|
||||
type SomeNonNullable = SetNonNullable<Foo, 'b' | 'c'>;
|
||||
// type SomeNonNullable = {
|
||||
// a: number;
|
||||
// b: string; // Can no longer be undefined.
|
||||
// c?: boolean; // Can no longer be null, but is still optional.
|
||||
// }
|
||||
```
|
||||
|
||||
@category Object
|
||||
*/
|
||||
export type SetNonNullable<BaseType, Keys extends keyof BaseType> =
|
||||
Simplify<
|
||||
// Pick just the keys that are readonly from the base type.
|
||||
Except<BaseType, Keys> &
|
||||
// Pick the keys that should be non-nullable from the base type and make them non-nullable.
|
||||
{[Key in Keys]: NonNullable<BaseType[Key]>}
|
||||
>;
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J D E CC","260":"F A B"},B:{"132":"P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H","260":"C K L G M N O"},C:{"2":"DC tB I v EC FC","260":"0 1 2 3 4 5 6 7 8 9 J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB"},D:{"16":"I v J D E F A B C K L","132":"0 1 2 3 4 5 6 7 8 9 G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"16":"HC zB","132":"I v J D E F A B C K L G IC JC KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC"},F:{"1":"C TC rB","2":"F PC QC RC SC","16":"B qB AC","132":"0 1 2 3 4 5 6 7 8 9 G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e"},G:{"16":"zB UC","132":"E BC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B"},H:{"2":"oC"},I:{"16":"pC qC","132":"tB I f rC sC BC tC uC"},J:{"132":"D A"},K:{"1":"C rB","2":"A","16":"B qB AC","132":"h"},L:{"132":"H"},M:{"260":"H"},N:{"260":"A B"},O:{"132":"vC"},P:{"132":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"132":"1B"},R:{"132":"9C"},S:{"260":"AD BD"}},B:5,C:"Mutation events"};
|
||||
@@ -0,0 +1,5 @@
|
||||
import { mergeAll } from './mergeAll';
|
||||
export function concatAll() {
|
||||
return mergeAll(1);
|
||||
}
|
||||
//# sourceMappingURL=concatAll.js.map
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"is-arrayish","version":"0.2.1","files":{"LICENSE":{"checkedAt":1678883670620,"integrity":"sha512-7//vjzFp/wJ0sSGuB7OHvBEobTIGDrplJXQkJHgmBrhYemDVNbwRqio5YQyr3GUNvnOPswiWp34Lnzyv09n6rg==","mode":420,"size":1077},".npmignore":{"checkedAt":1678883670649,"integrity":"sha512-6zB0Jjysd0S4UibjCQxMLMhIkBJ8sFpswPF0/jz3R4letMrKPoJ3GJQfnTNcC9xICN+x2I26BWGGttBTzDIumw==","mode":420,"size":52},"package.json":{"checkedAt":1678883670649,"integrity":"sha512-l9ZO6aNxBv5bCW223VzUBufcALTicmcwzqQ4st14PCPb669fTK6MA2c3szrx5q5TdoD5peMzlbqj5SQfSPYTdw==","mode":420,"size":705},"README.md":{"checkedAt":1678883670650,"integrity":"sha512-i+pJiwVe6seM8ZUs/Vgx7XnkDBDyp59+MbQNKX3EGD0V6mbY/hhQj2AWxyWsgy070asAZjEJUT8zL/dkdiwTgQ==","mode":420,"size":704},"index.js":{"checkedAt":1678883670650,"integrity":"sha512-8kSan8ppWcrq2wbHo9ARIOvTM0mnNLmmwB+OnlZ4p+RAu5SdGuxbaTi02vaU9tuKq2+FqM8osX+Be2RQlnpF3g==","mode":420,"size":204},".istanbul.yml":{"checkedAt":1678883670650,"integrity":"sha512-Av5QyT5sSJEUP1gwDZeMKRm7mFYCnomZDd9LXg2U9d1Q+pwzlxJiN9xJfTygnDC2xxFA00Gl2eeNvNHRGklg2w==","mode":420,"size":59},".editorconfig":{"checkedAt":1678883670650,"integrity":"sha512-rMrAbUD0z/d014LUZ463Ez4+h6bV9owN2r/y+LUZlUpYVHndRsWiAmV0kg6JpvVPfPQocV4AFazf/6oWx0cphw==","mode":420,"size":264},".travis.yml":{"checkedAt":1678883670650,"integrity":"sha512-jONVWlgxja40VxwPUcFt+UoaqSqnzZyjCegf/0OnmBgYZApWaj/ZT9U+K9/lCtmLA1uD4S6yKksncz9OpgCwGw==","mode":420,"size":988}}}
|
||||
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [ "es5" ],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": false,
|
||||
"baseUrl": ".",
|
||||
"paths": { "crc-32": ["."] },
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
var DataView = require('./_DataView'),
|
||||
Map = require('./_Map'),
|
||||
Promise = require('./_Promise'),
|
||||
Set = require('./_Set'),
|
||||
WeakMap = require('./_WeakMap'),
|
||||
baseGetTag = require('./_baseGetTag'),
|
||||
toSource = require('./_toSource');
|
||||
|
||||
/** `Object#toString` result references. */
|
||||
var mapTag = '[object Map]',
|
||||
objectTag = '[object Object]',
|
||||
promiseTag = '[object Promise]',
|
||||
setTag = '[object Set]',
|
||||
weakMapTag = '[object WeakMap]';
|
||||
|
||||
var dataViewTag = '[object DataView]';
|
||||
|
||||
/** Used to detect maps, sets, and weakmaps. */
|
||||
var dataViewCtorString = toSource(DataView),
|
||||
mapCtorString = toSource(Map),
|
||||
promiseCtorString = toSource(Promise),
|
||||
setCtorString = toSource(Set),
|
||||
weakMapCtorString = toSource(WeakMap);
|
||||
|
||||
/**
|
||||
* Gets the `toStringTag` of `value`.
|
||||
*
|
||||
* @private
|
||||
* @param {*} value The value to query.
|
||||
* @returns {string} Returns the `toStringTag`.
|
||||
*/
|
||||
var getTag = baseGetTag;
|
||||
|
||||
// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
|
||||
if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||
|
||||
(Map && getTag(new Map) != mapTag) ||
|
||||
(Promise && getTag(Promise.resolve()) != promiseTag) ||
|
||||
(Set && getTag(new Set) != setTag) ||
|
||||
(WeakMap && getTag(new WeakMap) != weakMapTag)) {
|
||||
getTag = function(value) {
|
||||
var result = baseGetTag(value),
|
||||
Ctor = result == objectTag ? value.constructor : undefined,
|
||||
ctorString = Ctor ? toSource(Ctor) : '';
|
||||
|
||||
if (ctorString) {
|
||||
switch (ctorString) {
|
||||
case dataViewCtorString: return dataViewTag;
|
||||
case mapCtorString: return mapTag;
|
||||
case promiseCtorString: return promiseTag;
|
||||
case setCtorString: return setTag;
|
||||
case weakMapCtorString: return weakMapTag;
|
||||
}
|
||||
}
|
||||
return result;
|
||||
};
|
||||
}
|
||||
|
||||
module.exports = getTag;
|
||||
@@ -0,0 +1,37 @@
|
||||
"use strict";
|
||||
var __read = (this && this.__read) || function (o, n) {
|
||||
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
||||
if (!m) return o;
|
||||
var i = m.call(o), r, ar = [], e;
|
||||
try {
|
||||
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
||||
}
|
||||
catch (error) { e = { error: error }; }
|
||||
finally {
|
||||
try {
|
||||
if (r && !r.done && (m = i["return"])) m.call(i);
|
||||
}
|
||||
finally { if (e) throw e.error; }
|
||||
}
|
||||
return ar;
|
||||
};
|
||||
var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
||||
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
||||
to[j] = from[i];
|
||||
return to;
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.onErrorResumeNext = exports.onErrorResumeNextWith = void 0;
|
||||
var argsOrArgArray_1 = require("../util/argsOrArgArray");
|
||||
var onErrorResumeNext_1 = require("../observable/onErrorResumeNext");
|
||||
function onErrorResumeNextWith() {
|
||||
var sources = [];
|
||||
for (var _i = 0; _i < arguments.length; _i++) {
|
||||
sources[_i] = arguments[_i];
|
||||
}
|
||||
var nextSources = argsOrArgArray_1.argsOrArgArray(sources);
|
||||
return function (source) { return onErrorResumeNext_1.onErrorResumeNext.apply(void 0, __spreadArray([source], __read(nextSources))); };
|
||||
}
|
||||
exports.onErrorResumeNextWith = onErrorResumeNextWith;
|
||||
exports.onErrorResumeNext = onErrorResumeNextWith;
|
||||
//# sourceMappingURL=onErrorResumeNextWith.js.map
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"mimic-response","version":"3.1.0","files":{"license":{"checkedAt":1678883669302,"integrity":"sha512-0fM2/ycrxrltyaBKfQ748Ck23VlPUUBgNAR47ldf4B1V/HoXTfWBSk+vcshGKwEpmOynu4mOP5o+hyBfuRNa8g==","mode":420,"size":1117},"index.js":{"checkedAt":1678883671072,"integrity":"sha512-M5Q8qOBbyyG8naZK5zjSXgK9PlNqVQFhEj3bayj51JqLrjyXjBZPKlOgYDLYxW3MKcZwdDauwlmjnAfDi/OyBw==","mode":420,"size":1581},"package.json":{"checkedAt":1678883671072,"integrity":"sha512-tdj/aCVhs1FREB/5hmB94cIPaeOhqvN1YZvfrdurNUHiR3xov86DWaX4VxY6VZYP+3DG/r6aOXhuL5P4I0gBbg==","mode":420,"size":768},"index.d.ts":{"checkedAt":1678883671072,"integrity":"sha512-mXxafh8l50M7abLyUmtZ2ckXZEtGZXktq+ZvfUPNtIiTd1gIxl7mi95D2L4SvA4hCK9D88ebJIirzopYQY4F2g==","mode":420,"size":599},"readme.md":{"checkedAt":1678883671072,"integrity":"sha512-vA1QV9lV5pG9fIzJ4qs8p2MwG9wwcSvKL6HRy7tcGFut9eKeVcEv/oBsW9hm0CVc2+WKGWaOklzgt7wADcZaXw==","mode":420,"size":1938}}}
|
||||
@@ -0,0 +1,5 @@
|
||||
import { NumberFormatInternal, NumberFormatPart } from '../types/number';
|
||||
export declare function FormatNumericToParts(nf: Intl.NumberFormat, x: number, implDetails: {
|
||||
getInternalSlots(nf: Intl.NumberFormat): NumberFormatInternal;
|
||||
}): NumberFormatPart[];
|
||||
//# sourceMappingURL=FormatNumericToParts.d.ts.map
|
||||
@@ -0,0 +1,10 @@
|
||||
export type UpdateDonor = {
|
||||
id: number;
|
||||
receiptNeeded?: boolean;
|
||||
firstname: string;
|
||||
middlename?: string;
|
||||
lastname: string;
|
||||
phone?: string;
|
||||
email?: string;
|
||||
address?: any;
|
||||
};
|
||||
@@ -0,0 +1,17 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.mergeMapTo = void 0;
|
||||
var mergeMap_1 = require("./mergeMap");
|
||||
var isFunction_1 = require("../util/isFunction");
|
||||
function mergeMapTo(innerObservable, resultSelector, concurrent) {
|
||||
if (concurrent === void 0) { concurrent = Infinity; }
|
||||
if (isFunction_1.isFunction(resultSelector)) {
|
||||
return mergeMap_1.mergeMap(function () { return innerObservable; }, resultSelector, concurrent);
|
||||
}
|
||||
if (typeof resultSelector === 'number') {
|
||||
concurrent = resultSelector;
|
||||
}
|
||||
return mergeMap_1.mergeMap(function () { return innerObservable; }, concurrent);
|
||||
}
|
||||
exports.mergeMapTo = mergeMapTo;
|
||||
//# sourceMappingURL=mergeMapTo.js.map
|
||||
@@ -0,0 +1,14 @@
|
||||
'use strict';
|
||||
|
||||
var GetIntrinsic = require('get-intrinsic');
|
||||
|
||||
var $TypeError = GetIntrinsic('%TypeError%');
|
||||
|
||||
// https://262.ecma-international.org/11.0/#sec-binaryor
|
||||
|
||||
module.exports = function BinaryOr(x, y) {
|
||||
if ((x !== 0 && x !== 1) || (y !== 0 && y !== 1)) {
|
||||
throw new $TypeError('Assertion failed: `x` and `y` must be either 0 or 1');
|
||||
}
|
||||
return x | y;
|
||||
};
|
||||
@@ -0,0 +1,28 @@
|
||||
'use strict';
|
||||
|
||||
var test = require('tape');
|
||||
var isNegativeZero = require('../');
|
||||
|
||||
test('not negative zero', function (t) {
|
||||
t.notOk(isNegativeZero(), 'undefined is not negative zero');
|
||||
t.notOk(isNegativeZero(null), 'null is not negative zero');
|
||||
t.notOk(isNegativeZero(false), 'false is not negative zero');
|
||||
t.notOk(isNegativeZero(true), 'true is not negative zero');
|
||||
t.notOk(isNegativeZero(0), 'positive zero is not negative zero');
|
||||
t.notOk(isNegativeZero(Infinity), 'Infinity is not negative zero');
|
||||
t.notOk(isNegativeZero(-Infinity), '-Infinity is not negative zero');
|
||||
t.notOk(isNegativeZero(NaN), 'NaN is not negative zero');
|
||||
t.notOk(isNegativeZero('foo'), 'string is not negative zero');
|
||||
t.notOk(isNegativeZero([]), 'array is not negative zero');
|
||||
t.notOk(isNegativeZero({}), 'object is not negative zero');
|
||||
t.notOk(isNegativeZero(function () {}), 'function is not negative zero');
|
||||
t.notOk(isNegativeZero(-1), '-1 is not negative zero');
|
||||
|
||||
t.end();
|
||||
});
|
||||
|
||||
test('negative zero', function (t) {
|
||||
t.ok(isNegativeZero(-0), 'negative zero is negative zero');
|
||||
t.end();
|
||||
});
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
if (parseInt(process.versions.node.split('.')[0]) < 6) throw new Error('vm2 requires Node.js version 6 or newer.');
|
||||
|
||||
module.exports = require('./lib/main');
|
||||
@@ -0,0 +1,24 @@
|
||||
'use strict';
|
||||
|
||||
var GetIntrinsic = require('get-intrinsic');
|
||||
|
||||
var $TypeError = GetIntrinsic('%TypeError%');
|
||||
|
||||
var isNaN = require('../../helpers/isNaN');
|
||||
|
||||
var Type = require('../Type');
|
||||
|
||||
// https://262.ecma-international.org/11.0/#sec-numeric-types-number-sameValueZero
|
||||
|
||||
module.exports = function NumberSameValueZero(x, y) {
|
||||
if (Type(x) !== 'Number' || Type(y) !== 'Number') {
|
||||
throw new $TypeError('Assertion failed: `x` and `y` arguments must be Numbers');
|
||||
}
|
||||
|
||||
var xNaN = isNaN(x);
|
||||
var yNaN = isNaN(y);
|
||||
if (xNaN || yNaN) {
|
||||
return xNaN === yNaN;
|
||||
}
|
||||
return x === y;
|
||||
};
|
||||
@@ -0,0 +1,38 @@
|
||||
import process from 'node:process';
|
||||
import path from 'node:path';
|
||||
import url from 'node:url';
|
||||
import pathKey from 'path-key';
|
||||
|
||||
export function npmRunPath(options = {}) {
|
||||
const {
|
||||
cwd = process.cwd(),
|
||||
path: path_ = process.env[pathKey()],
|
||||
execPath = process.execPath,
|
||||
} = options;
|
||||
|
||||
let previous;
|
||||
const cwdString = cwd instanceof URL ? url.fileURLToPath(cwd) : cwd;
|
||||
let cwdPath = path.resolve(cwdString);
|
||||
const result = [];
|
||||
|
||||
while (previous !== cwdPath) {
|
||||
result.push(path.join(cwdPath, 'node_modules/.bin'));
|
||||
previous = cwdPath;
|
||||
cwdPath = path.resolve(cwdPath, '..');
|
||||
}
|
||||
|
||||
// Ensure the running `node` binary is used.
|
||||
result.push(path.resolve(cwdString, execPath, '..'));
|
||||
|
||||
return [...result, path_].join(path.delimiter);
|
||||
}
|
||||
|
||||
export function npmRunPathEnv({env = process.env, ...options} = {}) {
|
||||
env = {...env};
|
||||
|
||||
const path = pathKey({env});
|
||||
options.path = env[path];
|
||||
env[path] = npmRunPath(options);
|
||||
|
||||
return env;
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
export type UpdateRunner = {
|
||||
id: number;
|
||||
group: number;
|
||||
firstname: string;
|
||||
middlename?: string;
|
||||
lastname: string;
|
||||
phone?: string;
|
||||
email?: string;
|
||||
address?: any;
|
||||
};
|
||||
@@ -0,0 +1 @@
|
||||
{"name":"deepmerge","version":"4.3.0","files":{".editorconfig":{"checkedAt":1678883668609,"integrity":"sha512-i8Gr/3AJXK5eTeigVmQux/pOqupEnEMXmH3CRd9A0E8vAlmcJqg7yb7HD4mafzabMvfIU5OvDXciTfYYnaVdxQ==","mode":420,"size":113},"dist/cjs.js":{"checkedAt":1678883668609,"integrity":"sha512-4wYhfon4cYGKg/QIV3WIkLc2NGOVvOiNHB0ARF1tk3tjmTPvUd7kh/l70+Rqwuk2lOVldhloGVsQnpatoRhEYQ==","mode":420,"size":4048},"index.js":{"checkedAt":1678883668609,"integrity":"sha512-nW8pslVdZAla+hYnlLS9l6yP8j7na5/H7gRYyNHCjEplgUrI5qEYhR86zdt252yeozi+NVRWZS0uTAO7q6rZBA==","mode":420,"size":3293},"rollup.config.js":{"checkedAt":1678883668609,"integrity":"sha512-VduH5qi7vd8S5qN6nECYNO0wiPpT9ojI0XS7fHli4B3xdJGN5oxxWYfPGY8jOLfaZgPiEj5M569wQJRxd1/a8Q==","mode":420,"size":343},"dist/umd.js":{"checkedAt":1678883668611,"integrity":"sha512-TZvhWeN2tMqLJjTpgr3vTEfQULe14ru1d9L4i+W/mS99FAxm2YYiXzxJvgUYXKNGiycy9z5MnlWDqu30n/NfpQ==","mode":420,"size":4420},"package.json":{"checkedAt":1678883668618,"integrity":"sha512-P26H9WtZYnVl4mtRDAjSIzYsY9miZNkAOj/oXX8lvCenxXxGN9pn/RKFSIBcup9CUXV6h8UVgkm+8BKK3vFykw==","mode":420,"size":1174},"changelog.md":{"checkedAt":1678883668618,"integrity":"sha512-8/b3OLDwMpNdLRSaknwlvb58gNxwnC5bBB9QLVPcbKeqTggbt5xgonx8w7wlmsgpnEQZjHCCHLliADyjhGF/rw==","mode":420,"size":9610},"readme.md":{"checkedAt":1678883668625,"integrity":"sha512-+/nQNY5VrHWayR28tmO6zwFCOswCz1F2FbvkPmMA6pFYkkNALK1KW2D28f7vLH19vjAAKgKtG0QDuzY21DkxFQ==","mode":420,"size":5678},"index.d.ts":{"checkedAt":1678883668625,"integrity":"sha512-bwV//oHtqELq3hOeWTV1VgQ4X+0MGPUocP6zi14wYPTNF3L+syqnGZxtdBwA/d3osBdmIqV4djxJb600EUZwbA==","mode":420,"size":652},"license.txt":{"checkedAt":1678883668625,"integrity":"sha512-T6VKDhvxWrCKRH/kJDl06Ur3yyPyHiESBV0AjUE0MaXP07adXVnWpS9SaeaARS7F/Wkpcnd5YNyngZlTH44o7w==","mode":420,"size":1116}}}
|
||||
@@ -0,0 +1,118 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.SHA2 = void 0;
|
||||
const _assert_js_1 = require("./_assert.js");
|
||||
const utils_js_1 = require("./utils.js");
|
||||
// Polyfill for Safari 14
|
||||
function setBigUint64(view, byteOffset, value, isLE) {
|
||||
if (typeof view.setBigUint64 === 'function')
|
||||
return view.setBigUint64(byteOffset, value, isLE);
|
||||
const _32n = BigInt(32);
|
||||
const _u32_max = BigInt(0xffffffff);
|
||||
const wh = Number((value >> _32n) & _u32_max);
|
||||
const wl = Number(value & _u32_max);
|
||||
const h = isLE ? 4 : 0;
|
||||
const l = isLE ? 0 : 4;
|
||||
view.setUint32(byteOffset + h, wh, isLE);
|
||||
view.setUint32(byteOffset + l, wl, isLE);
|
||||
}
|
||||
// Base SHA2 class (RFC 6234)
|
||||
class SHA2 extends utils_js_1.Hash {
|
||||
constructor(blockLen, outputLen, padOffset, isLE) {
|
||||
super();
|
||||
this.blockLen = blockLen;
|
||||
this.outputLen = outputLen;
|
||||
this.padOffset = padOffset;
|
||||
this.isLE = isLE;
|
||||
this.finished = false;
|
||||
this.length = 0;
|
||||
this.pos = 0;
|
||||
this.destroyed = false;
|
||||
this.buffer = new Uint8Array(blockLen);
|
||||
this.view = (0, utils_js_1.createView)(this.buffer);
|
||||
}
|
||||
update(data) {
|
||||
_assert_js_1.default.exists(this);
|
||||
const { view, buffer, blockLen } = this;
|
||||
data = (0, utils_js_1.toBytes)(data);
|
||||
const len = data.length;
|
||||
for (let pos = 0; pos < len;) {
|
||||
const take = Math.min(blockLen - this.pos, len - pos);
|
||||
// Fast path: we have at least one block in input, cast it to view and process
|
||||
if (take === blockLen) {
|
||||
const dataView = (0, utils_js_1.createView)(data);
|
||||
for (; blockLen <= len - pos; pos += blockLen)
|
||||
this.process(dataView, pos);
|
||||
continue;
|
||||
}
|
||||
buffer.set(data.subarray(pos, pos + take), this.pos);
|
||||
this.pos += take;
|
||||
pos += take;
|
||||
if (this.pos === blockLen) {
|
||||
this.process(view, 0);
|
||||
this.pos = 0;
|
||||
}
|
||||
}
|
||||
this.length += data.length;
|
||||
this.roundClean();
|
||||
return this;
|
||||
}
|
||||
digestInto(out) {
|
||||
_assert_js_1.default.exists(this);
|
||||
_assert_js_1.default.output(out, this);
|
||||
this.finished = true;
|
||||
// Padding
|
||||
// We can avoid allocation of buffer for padding completely if it
|
||||
// was previously not allocated here. But it won't change performance.
|
||||
const { buffer, view, blockLen, isLE } = this;
|
||||
let { pos } = this;
|
||||
// append the bit '1' to the message
|
||||
buffer[pos++] = 0b10000000;
|
||||
this.buffer.subarray(pos).fill(0);
|
||||
// we have less than padOffset left in buffer, so we cannot put length in current block, need process it and pad again
|
||||
if (this.padOffset > blockLen - pos) {
|
||||
this.process(view, 0);
|
||||
pos = 0;
|
||||
}
|
||||
// Pad until full block byte with zeros
|
||||
for (let i = pos; i < blockLen; i++)
|
||||
buffer[i] = 0;
|
||||
// Note: sha512 requires length to be 128bit integer, but length in JS will overflow before that
|
||||
// You need to write around 2 exabytes (u64_max / 8 / (1024**6)) for this to happen.
|
||||
// So we just write lowest 64 bits of that value.
|
||||
setBigUint64(view, blockLen - 8, BigInt(this.length * 8), isLE);
|
||||
this.process(view, 0);
|
||||
const oview = (0, utils_js_1.createView)(out);
|
||||
const len = this.outputLen;
|
||||
// NOTE: we do division by 4 later, which should be fused in single op with modulo by JIT
|
||||
if (len % 4)
|
||||
throw new Error('_sha2: outputLen should be aligned to 32bit');
|
||||
const outLen = len / 4;
|
||||
const state = this.get();
|
||||
if (outLen > state.length)
|
||||
throw new Error('_sha2: outputLen bigger than state');
|
||||
for (let i = 0; i < outLen; i++)
|
||||
oview.setUint32(4 * i, state[i], isLE);
|
||||
}
|
||||
digest() {
|
||||
const { buffer, outputLen } = this;
|
||||
this.digestInto(buffer);
|
||||
const res = buffer.slice(0, outputLen);
|
||||
this.destroy();
|
||||
return res;
|
||||
}
|
||||
_cloneInto(to) {
|
||||
to || (to = new this.constructor());
|
||||
to.set(...this.get());
|
||||
const { blockLen, buffer, length, finished, destroyed, pos } = this;
|
||||
to.length = length;
|
||||
to.pos = pos;
|
||||
to.finished = finished;
|
||||
to.destroyed = destroyed;
|
||||
if (length % blockLen)
|
||||
to.buffer.set(buffer);
|
||||
return to;
|
||||
}
|
||||
}
|
||||
exports.SHA2 = SHA2;
|
||||
//# sourceMappingURL=_sha2.js.map
|
||||
@@ -0,0 +1,5 @@
|
||||
var convert = require('./convert'),
|
||||
func = convert('zip', require('../zip'));
|
||||
|
||||
func.placeholder = require('./placeholder');
|
||||
module.exports = func;
|
||||
@@ -0,0 +1,2 @@
|
||||
if(typeof cptable === 'undefined') cptable = {};
|
||||
cptable[20107] = (function(){ var d = "<22><>\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#¤%&'()*+,-./0123456789:;<=>?ÉABCDEFGHIJKLMNOPQRSTUVWXYZÄÖÅÜ_éabcdefghijklmnopqrstuvwxyzäöåü<C3BC><7F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>", D = [], e = {}; for(var i=0;i!=d.length;++i) { if(d.charCodeAt(i) !== 0xFFFD) e[d.charAt(i)] = i; D[i] = d.charAt(i); } return {"enc": e, "dec": D }; })();
|
||||
@@ -0,0 +1,34 @@
|
||||
# shebang-command [](https://travis-ci.org/kevva/shebang-command)
|
||||
|
||||
> Get the command from a shebang
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install shebang-command
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
const shebangCommand = require('shebang-command');
|
||||
|
||||
shebangCommand('#!/usr/bin/env node');
|
||||
//=> 'node'
|
||||
|
||||
shebangCommand('#!/bin/bash');
|
||||
//=> 'bash'
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### shebangCommand(string)
|
||||
|
||||
#### string
|
||||
|
||||
Type: `string`
|
||||
|
||||
String containing a shebang.
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"1":"F A B","2":"J D CC","129":"E"},B:{"1":"C K L G M N O P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"1":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB EC FC","2":"DC tB"},D:{"1":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"1":"I v J D E F A B C K L G IC JC KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC","2":"HC zB"},F:{"1":"0 1 2 3 4 5 6 7 8 9 B C G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e RC SC qB AC TC rB","2":"F PC QC"},G:{"1":"E UC BC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B","2":"zB"},H:{"1":"oC"},I:{"1":"tB I f pC qC rC sC BC tC uC"},J:{"1":"D A"},K:{"1":"A B C h qB AC rB"},L:{"1":"H"},M:{"1":"H"},N:{"1":"A B"},O:{"1":"vC"},P:{"1":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"1":"1B"},R:{"1":"9C"},S:{"1":"AD BD"}},B:6,C:"JSON parsing"};
|
||||
@@ -0,0 +1,63 @@
|
||||
import { not } from '../util/not';
|
||||
import { filter } from './filter';
|
||||
import { Observable } from '../Observable';
|
||||
import { UnaryFunction } from '../types';
|
||||
|
||||
/**
|
||||
* Splits the source Observable into two, one with values that satisfy a
|
||||
* predicate, and another with values that don't satisfy the predicate.
|
||||
*
|
||||
* <span class="informal">It's like {@link filter}, but returns two Observables:
|
||||
* one like the output of {@link filter}, and the other with values that did not
|
||||
* pass the condition.</span>
|
||||
*
|
||||
* 
|
||||
*
|
||||
* `partition` outputs an array with two Observables that partition the values
|
||||
* from the source Observable through the given `predicate` function. The first
|
||||
* Observable in that array emits source values for which the predicate argument
|
||||
* returns true. The second Observable emits source values for which the
|
||||
* predicate returns false. The first behaves like {@link filter} and the second
|
||||
* behaves like {@link filter} with the predicate negated.
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* Partition click events into those on DIV elements and those elsewhere
|
||||
*
|
||||
* ```ts
|
||||
* import { fromEvent } from 'rxjs';
|
||||
* import { partition } from 'rxjs/operators';
|
||||
*
|
||||
* const div = document.createElement('div');
|
||||
* div.style.cssText = 'width: 200px; height: 200px; background: #09c;';
|
||||
* document.body.appendChild(div);
|
||||
*
|
||||
* const clicks = fromEvent(document, 'click');
|
||||
* const [clicksOnDivs, clicksElsewhere] = clicks.pipe(partition(ev => (<HTMLElement>ev.target).tagName === 'DIV'));
|
||||
*
|
||||
* clicksOnDivs.subscribe(x => console.log('DIV clicked: ', x));
|
||||
* clicksElsewhere.subscribe(x => console.log('Other clicked: ', x));
|
||||
* ```
|
||||
*
|
||||
* @see {@link filter}
|
||||
*
|
||||
* @param {function(value: T, index: number): boolean} predicate A function that
|
||||
* evaluates each value emitted by the source Observable. If it returns `true`,
|
||||
* the value is emitted on the first Observable in the returned array, if
|
||||
* `false` the value is emitted on the second Observable in the array. The
|
||||
* `index` parameter is the number `i` for the i-th source emission that has
|
||||
* happened since the subscription, starting from the number `0`.
|
||||
* @param {any} [thisArg] An optional argument to determine the value of `this`
|
||||
* in the `predicate` function.
|
||||
* @return A function that returns an array with two Observables: one with
|
||||
* values that passed the predicate, and another with values that did not pass
|
||||
* the predicate.
|
||||
* @deprecated Replaced with the `partition` static creation function. Will be removed in v8.
|
||||
*/
|
||||
export function partition<T>(
|
||||
predicate: (value: T, index: number) => boolean,
|
||||
thisArg?: any
|
||||
): UnaryFunction<Observable<T>, [Observable<T>, Observable<T>]> {
|
||||
return (source: Observable<T>) =>
|
||||
[filter(predicate, thisArg)(source), filter(not(predicate, thisArg))(source)] as [Observable<T>, Observable<T>];
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J D E F A B CC"},B:{"2":"C K L G M N O P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"1":"eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB","2":"0 1 2 3 4 5 6 7 8 9 DC tB I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB EC FC"},D:{"2":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"1":"sB 6B 7B 8B 9B OC","2":"I v J D E F A B C K L G HC zB IC JC KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B"},F:{"2":"0 1 2 3 4 5 6 7 8 9 F B C G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e PC QC RC SC qB AC TC rB"},G:{"1":"sB 6B 7B 8B 9B","2":"E zB UC BC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B"},H:{"2":"oC"},I:{"2":"tB I f pC qC rC sC BC tC uC"},J:{"2":"D A"},K:{"2":"A B C h qB AC rB"},L:{"2":"H"},M:{"1":"H"},N:{"2":"A B"},O:{"2":"vC"},P:{"2":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"2":"1B"},R:{"2":"9C"},S:{"1":"BD","2":"AD"}},B:4,C:"CSS Grid animation"};
|
||||
@@ -0,0 +1,2 @@
|
||||
let defaultTheme = require('./lib/public/default-theme')
|
||||
module.exports = (defaultTheme.__esModule ? defaultTheme : { default: defaultTheme }).default
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"observeOn.js","sourceRoot":"","sources":["../../../../src/internal/operators/observeOn.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAsDhE,MAAM,UAAU,SAAS,CAAI,SAAwB,EAAE,KAAS;IAAT,sBAAA,EAAA,SAAS;IAC9D,OAAO,OAAO,CAAC,UAAC,MAAM,EAAE,UAAU;QAChC,MAAM,CAAC,SAAS,CACd,wBAAwB,CACtB,UAAU,EACV,UAAC,KAAK,IAAK,OAAA,eAAe,CAAC,UAAU,EAAE,SAAS,EAAE,cAAM,OAAA,UAAU,CAAC,IAAI,CAAC,KAAK,CAAC,EAAtB,CAAsB,EAAE,KAAK,CAAC,EAA3E,CAA2E,EACtF,cAAM,OAAA,eAAe,CAAC,UAAU,EAAE,SAAS,EAAE,cAAM,OAAA,UAAU,CAAC,QAAQ,EAAE,EAArB,CAAqB,EAAE,KAAK,CAAC,EAA1E,CAA0E,EAChF,UAAC,GAAG,IAAK,OAAA,eAAe,CAAC,UAAU,EAAE,SAAS,EAAE,cAAM,OAAA,UAAU,CAAC,KAAK,CAAC,GAAG,CAAC,EAArB,CAAqB,EAAE,KAAK,CAAC,EAA1E,CAA0E,CACpF,CACF,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC"}
|
||||
@@ -0,0 +1,10 @@
|
||||
"use strict";
|
||||
|
||||
if (!require("./is-implemented")()) {
|
||||
Object.defineProperty(Math, "asinh", {
|
||||
value: require("./shim"),
|
||||
configurable: true,
|
||||
enumerable: false,
|
||||
writable: true
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
# `dlv(obj, keypath)` [](https://npmjs.com/package/dlv) [](https://travis-ci.org/developit/dlv)
|
||||
|
||||
> Safely get a dot-notated path within a nested object, with ability to return a default if the full key path does not exist or the value is undefined
|
||||
|
||||
|
||||
### Why?
|
||||
|
||||
Smallest possible implementation: only **130 bytes.**
|
||||
|
||||
You could write this yourself, but then you'd have to write [tests].
|
||||
|
||||
Supports ES Modules, CommonJS and globals.
|
||||
|
||||
|
||||
### Installation
|
||||
|
||||
`npm install --save dlv`
|
||||
|
||||
|
||||
### Usage
|
||||
|
||||
`delve(object, keypath, [default])`
|
||||
|
||||
```js
|
||||
import delve from 'dlv';
|
||||
|
||||
let obj = {
|
||||
a: {
|
||||
b: {
|
||||
c: 1,
|
||||
d: undefined,
|
||||
e: null
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
//use string dot notation for keys
|
||||
delve(obj, 'a.b.c') === 1;
|
||||
|
||||
//or use an array key
|
||||
delve(obj, ['a', 'b', 'c']) === 1;
|
||||
|
||||
delve(obj, 'a.b') === obj.a.b;
|
||||
|
||||
//returns undefined if the full key path does not exist and no default is specified
|
||||
delve(obj, 'a.b.f') === undefined;
|
||||
|
||||
//optional third parameter for default if the full key in path is missing
|
||||
delve(obj, 'a.b.f', 'foo') === 'foo';
|
||||
|
||||
//or if the key exists but the value is undefined
|
||||
delve(obj, 'a.b.d', 'foo') === 'foo';
|
||||
|
||||
//Non-truthy defined values are still returned if they exist at the full keypath
|
||||
delve(obj, 'a.b.e', 'foo') === null;
|
||||
|
||||
//undefined obj or key returns undefined, unless a default is supplied
|
||||
delve(undefined, 'a.b.c') === undefined;
|
||||
delve(undefined, 'a.b.c', 'foo') === 'foo';
|
||||
delve(obj, undefined, 'foo') === 'foo';
|
||||
```
|
||||
|
||||
|
||||
### Setter Counterparts
|
||||
|
||||
- [dset](https://github.com/lukeed/dset) by [@lukeed](https://github.com/lukeed) is the spiritual "set" counterpart of `dlv` and very fast.
|
||||
- [bury](https://github.com/kalmbach/bury) by [@kalmbach](https://github.com/kalmbach) does the opposite of `dlv` and is implemented in a very similar manner.
|
||||
|
||||
|
||||
### License
|
||||
|
||||
[MIT](https://oss.ninja/mit/developit/)
|
||||
|
||||
|
||||
[preact]: https://github.com/developit/preact
|
||||
[tests]: https://github.com/developit/dlv/blob/master/test.js
|
||||
@@ -0,0 +1,14 @@
|
||||
## Documentation
|
||||
|
||||
You can see below the API reference of this module.
|
||||
|
||||
### `isSsh(input)`
|
||||
Checks if an input value is a ssh url or not.
|
||||
|
||||
#### Params
|
||||
|
||||
- **String|Array** `input`: The input url or an array of protocols.
|
||||
|
||||
#### Return
|
||||
- **Boolean** `true` if the input is a ssh url, `false` otherwise.
|
||||
|
||||
@@ -0,0 +1,182 @@
|
||||
const { MAX_SAFE_COMPONENT_LENGTH } = require('./constants')
|
||||
const debug = require('./debug')
|
||||
exports = module.exports = {}
|
||||
|
||||
// The actual regexps go on exports.re
|
||||
const re = exports.re = []
|
||||
const src = exports.src = []
|
||||
const t = exports.t = {}
|
||||
let R = 0
|
||||
|
||||
const createToken = (name, value, isGlobal) => {
|
||||
const index = R++
|
||||
debug(index, value)
|
||||
t[name] = index
|
||||
src[index] = value
|
||||
re[index] = new RegExp(value, isGlobal ? 'g' : undefined)
|
||||
}
|
||||
|
||||
// The following Regular Expressions can be used for tokenizing,
|
||||
// validating, and parsing SemVer version strings.
|
||||
|
||||
// ## Numeric Identifier
|
||||
// A single `0`, or a non-zero digit followed by zero or more digits.
|
||||
|
||||
createToken('NUMERICIDENTIFIER', '0|[1-9]\\d*')
|
||||
createToken('NUMERICIDENTIFIERLOOSE', '[0-9]+')
|
||||
|
||||
// ## Non-numeric Identifier
|
||||
// Zero or more digits, followed by a letter or hyphen, and then zero or
|
||||
// more letters, digits, or hyphens.
|
||||
|
||||
createToken('NONNUMERICIDENTIFIER', '\\d*[a-zA-Z-][a-zA-Z0-9-]*')
|
||||
|
||||
// ## Main Version
|
||||
// Three dot-separated numeric identifiers.
|
||||
|
||||
createToken('MAINVERSION', `(${src[t.NUMERICIDENTIFIER]})\\.` +
|
||||
`(${src[t.NUMERICIDENTIFIER]})\\.` +
|
||||
`(${src[t.NUMERICIDENTIFIER]})`)
|
||||
|
||||
createToken('MAINVERSIONLOOSE', `(${src[t.NUMERICIDENTIFIERLOOSE]})\\.` +
|
||||
`(${src[t.NUMERICIDENTIFIERLOOSE]})\\.` +
|
||||
`(${src[t.NUMERICIDENTIFIERLOOSE]})`)
|
||||
|
||||
// ## Pre-release Version Identifier
|
||||
// A numeric identifier, or a non-numeric identifier.
|
||||
|
||||
createToken('PRERELEASEIDENTIFIER', `(?:${src[t.NUMERICIDENTIFIER]
|
||||
}|${src[t.NONNUMERICIDENTIFIER]})`)
|
||||
|
||||
createToken('PRERELEASEIDENTIFIERLOOSE', `(?:${src[t.NUMERICIDENTIFIERLOOSE]
|
||||
}|${src[t.NONNUMERICIDENTIFIER]})`)
|
||||
|
||||
// ## Pre-release Version
|
||||
// Hyphen, followed by one or more dot-separated pre-release version
|
||||
// identifiers.
|
||||
|
||||
createToken('PRERELEASE', `(?:-(${src[t.PRERELEASEIDENTIFIER]
|
||||
}(?:\\.${src[t.PRERELEASEIDENTIFIER]})*))`)
|
||||
|
||||
createToken('PRERELEASELOOSE', `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]
|
||||
}(?:\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`)
|
||||
|
||||
// ## Build Metadata Identifier
|
||||
// Any combination of digits, letters, or hyphens.
|
||||
|
||||
createToken('BUILDIDENTIFIER', '[0-9A-Za-z-]+')
|
||||
|
||||
// ## Build Metadata
|
||||
// Plus sign, followed by one or more period-separated build metadata
|
||||
// identifiers.
|
||||
|
||||
createToken('BUILD', `(?:\\+(${src[t.BUILDIDENTIFIER]
|
||||
}(?:\\.${src[t.BUILDIDENTIFIER]})*))`)
|
||||
|
||||
// ## Full Version String
|
||||
// A main version, followed optionally by a pre-release version and
|
||||
// build metadata.
|
||||
|
||||
// Note that the only major, minor, patch, and pre-release sections of
|
||||
// the version string are capturing groups. The build metadata is not a
|
||||
// capturing group, because it should not ever be used in version
|
||||
// comparison.
|
||||
|
||||
createToken('FULLPLAIN', `v?${src[t.MAINVERSION]
|
||||
}${src[t.PRERELEASE]}?${
|
||||
src[t.BUILD]}?`)
|
||||
|
||||
createToken('FULL', `^${src[t.FULLPLAIN]}$`)
|
||||
|
||||
// like full, but allows v1.2.3 and =1.2.3, which people do sometimes.
|
||||
// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty
|
||||
// common in the npm registry.
|
||||
createToken('LOOSEPLAIN', `[v=\\s]*${src[t.MAINVERSIONLOOSE]
|
||||
}${src[t.PRERELEASELOOSE]}?${
|
||||
src[t.BUILD]}?`)
|
||||
|
||||
createToken('LOOSE', `^${src[t.LOOSEPLAIN]}$`)
|
||||
|
||||
createToken('GTLT', '((?:<|>)?=?)')
|
||||
|
||||
// Something like "2.*" or "1.2.x".
|
||||
// Note that "x.x" is a valid xRange identifer, meaning "any version"
|
||||
// Only the first item is strictly required.
|
||||
createToken('XRANGEIDENTIFIERLOOSE', `${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`)
|
||||
createToken('XRANGEIDENTIFIER', `${src[t.NUMERICIDENTIFIER]}|x|X|\\*`)
|
||||
|
||||
createToken('XRANGEPLAIN', `[v=\\s]*(${src[t.XRANGEIDENTIFIER]})` +
|
||||
`(?:\\.(${src[t.XRANGEIDENTIFIER]})` +
|
||||
`(?:\\.(${src[t.XRANGEIDENTIFIER]})` +
|
||||
`(?:${src[t.PRERELEASE]})?${
|
||||
src[t.BUILD]}?` +
|
||||
`)?)?`)
|
||||
|
||||
createToken('XRANGEPLAINLOOSE', `[v=\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})` +
|
||||
`(?:\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +
|
||||
`(?:\\.(${src[t.XRANGEIDENTIFIERLOOSE]})` +
|
||||
`(?:${src[t.PRERELEASELOOSE]})?${
|
||||
src[t.BUILD]}?` +
|
||||
`)?)?`)
|
||||
|
||||
createToken('XRANGE', `^${src[t.GTLT]}\\s*${src[t.XRANGEPLAIN]}$`)
|
||||
createToken('XRANGELOOSE', `^${src[t.GTLT]}\\s*${src[t.XRANGEPLAINLOOSE]}$`)
|
||||
|
||||
// Coercion.
|
||||
// Extract anything that could conceivably be a part of a valid semver
|
||||
createToken('COERCE', `${'(^|[^\\d])' +
|
||||
'(\\d{1,'}${MAX_SAFE_COMPONENT_LENGTH}})` +
|
||||
`(?:\\.(\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?` +
|
||||
`(?:\\.(\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?` +
|
||||
`(?:$|[^\\d])`)
|
||||
createToken('COERCERTL', src[t.COERCE], true)
|
||||
|
||||
// Tilde ranges.
|
||||
// Meaning is "reasonably at or greater than"
|
||||
createToken('LONETILDE', '(?:~>?)')
|
||||
|
||||
createToken('TILDETRIM', `(\\s*)${src[t.LONETILDE]}\\s+`, true)
|
||||
exports.tildeTrimReplace = '$1~'
|
||||
|
||||
createToken('TILDE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`)
|
||||
createToken('TILDELOOSE', `^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`)
|
||||
|
||||
// Caret ranges.
|
||||
// Meaning is "at least and backwards compatible with"
|
||||
createToken('LONECARET', '(?:\\^)')
|
||||
|
||||
createToken('CARETTRIM', `(\\s*)${src[t.LONECARET]}\\s+`, true)
|
||||
exports.caretTrimReplace = '$1^'
|
||||
|
||||
createToken('CARET', `^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`)
|
||||
createToken('CARETLOOSE', `^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`)
|
||||
|
||||
// A simple gt/lt/eq thing, or just "" to indicate "any version"
|
||||
createToken('COMPARATORLOOSE', `^${src[t.GTLT]}\\s*(${src[t.LOOSEPLAIN]})$|^$`)
|
||||
createToken('COMPARATOR', `^${src[t.GTLT]}\\s*(${src[t.FULLPLAIN]})$|^$`)
|
||||
|
||||
// An expression to strip any whitespace between the gtlt and the thing
|
||||
// it modifies, so that `> 1.2.3` ==> `>1.2.3`
|
||||
createToken('COMPARATORTRIM', `(\\s*)${src[t.GTLT]
|
||||
}\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`, true)
|
||||
exports.comparatorTrimReplace = '$1$2$3'
|
||||
|
||||
// Something like `1.2.3 - 1.2.4`
|
||||
// Note that these all use the loose form, because they'll be
|
||||
// checked against either the strict or loose comparator form
|
||||
// later.
|
||||
createToken('HYPHENRANGE', `^\\s*(${src[t.XRANGEPLAIN]})` +
|
||||
`\\s+-\\s+` +
|
||||
`(${src[t.XRANGEPLAIN]})` +
|
||||
`\\s*$`)
|
||||
|
||||
createToken('HYPHENRANGELOOSE', `^\\s*(${src[t.XRANGEPLAINLOOSE]})` +
|
||||
`\\s+-\\s+` +
|
||||
`(${src[t.XRANGEPLAINLOOSE]})` +
|
||||
`\\s*$`)
|
||||
|
||||
// Star ranges basically just allow anything at all.
|
||||
createToken('STAR', '(<|>)?=?\\s*\\*')
|
||||
// >=0.0.0 is like a star
|
||||
createToken('GTE0', '^\\s*>=\\s*0\.0\.0\\s*$')
|
||||
createToken('GTE0PRE', '^\\s*>=\\s*0\.0\.0-0\\s*$')
|
||||
@@ -0,0 +1,5 @@
|
||||
'use strict';
|
||||
|
||||
// http://262.ecma-international.org/5.1/#sec-9.11
|
||||
|
||||
module.exports = require('is-callable');
|
||||
@@ -0,0 +1,5 @@
|
||||
import assertString from './util/assertString';
|
||||
export default function escape(str) {
|
||||
assertString(str);
|
||||
return str.replace(/&/g, '&').replace(/"/g, '"').replace(/'/g, ''').replace(/</g, '<').replace(/>/g, '>').replace(/\//g, '/').replace(/\\/g, '\').replace(/`/g, '`');
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
// Based on: https://github.com/mathiasbynens/String.prototype.codePointAt
|
||||
// Thanks @mathiasbynens !
|
||||
|
||||
"use strict";
|
||||
|
||||
var toInteger = require("../../../number/to-integer")
|
||||
, validValue = require("../../../object/valid-value");
|
||||
|
||||
module.exports = function (pos) {
|
||||
var str = String(validValue(this)), length = str.length, first, second;
|
||||
pos = toInteger(pos);
|
||||
|
||||
// Account for out-of-bounds indices:
|
||||
if (pos < 0 || pos >= length) return undefined;
|
||||
|
||||
// Get the first code unit
|
||||
first = str.charCodeAt(pos);
|
||||
if (first >= 0xd800 && first <= 0xdbff && length > pos + 1) {
|
||||
second = str.charCodeAt(pos + 1);
|
||||
if (second >= 0xdc00 && second <= 0xdfff) {
|
||||
// http://mathiasbynens.be/notes/javascript-encoding#surrogate-formulae
|
||||
return (first - 0xd800) * 0x400 + second - 0xdc00 + 0x10000;
|
||||
}
|
||||
}
|
||||
return first;
|
||||
};
|
||||
@@ -0,0 +1,27 @@
|
||||
# Promise
|
||||
|
||||
_Promise_ instance
|
||||
|
||||
## `promise/is`
|
||||
|
||||
Confirms if given object is a native _promise_
|
||||
|
||||
```javascript
|
||||
const isPromise = require("type/promise/is");
|
||||
|
||||
isPromise(Promise.resolve()); // true
|
||||
isPromise({ then: () => {} }); // false
|
||||
isPromise({}); // false
|
||||
```
|
||||
|
||||
## `promise/ensure`
|
||||
|
||||
If given argument is a promise, it is returned back. Otherwise `TypeError` is thrown.
|
||||
|
||||
```javascript
|
||||
const ensurePromise = require("type/promise/ensure");
|
||||
|
||||
const promise = Promise.resolve();
|
||||
ensurePromise(promise); // promise
|
||||
eensurePromise({}); // Thrown TypeError: [object Object] is not a promise
|
||||
```
|
||||
@@ -0,0 +1,97 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.getLanguage = exports.isAliasOf = exports.getLanguageFromAlias = exports.addLanguageAlias = exports.getLanguageDefaults = exports.SOURCE_MAP_PROP_MAP = exports.ALIAS_MAP = void 0;
|
||||
const path_1 = require("path");
|
||||
const utils_1 = require("./utils");
|
||||
const LANGUAGE_DEFAULTS = {
|
||||
sass: {
|
||||
indentedSyntax: true,
|
||||
stripIndent: true,
|
||||
},
|
||||
pug: {
|
||||
stripIndent: true,
|
||||
},
|
||||
coffeescript: {
|
||||
stripIndent: true,
|
||||
},
|
||||
stylus: {
|
||||
stripIndent: true,
|
||||
},
|
||||
// We need to defer this require to make sugarss an optional dependency.
|
||||
sugarss: () => ({
|
||||
stripIndent: true,
|
||||
// eslint-disable-next-line @typescript-eslint/no-require-imports, node/global-require
|
||||
parser: require('sugarss'),
|
||||
}),
|
||||
};
|
||||
exports.ALIAS_MAP = new Map([
|
||||
['pcss', 'css'],
|
||||
['postcss', 'css'],
|
||||
['sugarss', 'css'],
|
||||
['sass', 'scss'],
|
||||
['styl', 'stylus'],
|
||||
['js', 'javascript'],
|
||||
['coffee', 'coffeescript'],
|
||||
['ts', 'typescript'],
|
||||
]);
|
||||
exports.SOURCE_MAP_PROP_MAP = {
|
||||
babel: [['sourceMaps'], true],
|
||||
typescript: [['compilerOptions', 'sourceMap'], true],
|
||||
scss: [['sourceMap'], true],
|
||||
less: [['sourceMap'], {}],
|
||||
stylus: [['sourcemap'], true],
|
||||
postcss: [['map'], true],
|
||||
coffeescript: [['sourceMap'], true],
|
||||
globalStyle: [['sourceMap'], true],
|
||||
};
|
||||
function getLanguageDefaults(lang) {
|
||||
const defaults = LANGUAGE_DEFAULTS[lang];
|
||||
if (!defaults)
|
||||
return null;
|
||||
if (typeof defaults === 'function') {
|
||||
return defaults();
|
||||
}
|
||||
return defaults;
|
||||
}
|
||||
exports.getLanguageDefaults = getLanguageDefaults;
|
||||
function addLanguageAlias(entries) {
|
||||
return entries.forEach((entry) => exports.ALIAS_MAP.set(...entry));
|
||||
}
|
||||
exports.addLanguageAlias = addLanguageAlias;
|
||||
function getLanguageFromAlias(alias) {
|
||||
return exports.ALIAS_MAP.get(alias) || alias;
|
||||
}
|
||||
exports.getLanguageFromAlias = getLanguageFromAlias;
|
||||
function isAliasOf(alias, lang) {
|
||||
return lang !== alias && getLanguageFromAlias(alias) === lang;
|
||||
}
|
||||
exports.isAliasOf = isAliasOf;
|
||||
const getLanguage = (attributes) => {
|
||||
let alias = null;
|
||||
if (attributes.lang) {
|
||||
// istanbul ignore if
|
||||
if (typeof attributes.lang !== 'string') {
|
||||
throw new Error('lang attribute must be string');
|
||||
}
|
||||
alias = attributes.lang;
|
||||
}
|
||||
else if (attributes.type) {
|
||||
// istanbul ignore if
|
||||
if (typeof attributes.type !== 'string') {
|
||||
throw new Error('type attribute must be string');
|
||||
}
|
||||
alias = attributes.type.replace(/^(text|application)\/(.*)$/, '$2');
|
||||
}
|
||||
else if (typeof attributes.src === 'string' &&
|
||||
utils_1.isValidLocalPath(attributes.src)) {
|
||||
const parts = path_1.basename(attributes.src).split('.');
|
||||
if (parts.length > 1) {
|
||||
alias = parts.pop();
|
||||
}
|
||||
}
|
||||
return {
|
||||
lang: getLanguageFromAlias(alias),
|
||||
alias,
|
||||
};
|
||||
};
|
||||
exports.getLanguage = getLanguage;
|
||||
@@ -0,0 +1,214 @@
|
||||
import stringWidth from 'string-width';
|
||||
import stripAnsi from 'strip-ansi';
|
||||
import ansiStyles from 'ansi-styles';
|
||||
|
||||
const ESCAPES = new Set([
|
||||
'\u001B',
|
||||
'\u009B',
|
||||
]);
|
||||
|
||||
const END_CODE = 39;
|
||||
const ANSI_ESCAPE_BELL = '\u0007';
|
||||
const ANSI_CSI = '[';
|
||||
const ANSI_OSC = ']';
|
||||
const ANSI_SGR_TERMINATOR = 'm';
|
||||
const ANSI_ESCAPE_LINK = `${ANSI_OSC}8;;`;
|
||||
|
||||
const wrapAnsiCode = code => `${ESCAPES.values().next().value}${ANSI_CSI}${code}${ANSI_SGR_TERMINATOR}`;
|
||||
const wrapAnsiHyperlink = uri => `${ESCAPES.values().next().value}${ANSI_ESCAPE_LINK}${uri}${ANSI_ESCAPE_BELL}`;
|
||||
|
||||
// Calculate the length of words split on ' ', ignoring
|
||||
// the extra characters added by ansi escape codes
|
||||
const wordLengths = string => string.split(' ').map(character => stringWidth(character));
|
||||
|
||||
// Wrap a long word across multiple rows
|
||||
// Ansi escape codes do not count towards length
|
||||
const wrapWord = (rows, word, columns) => {
|
||||
const characters = [...word];
|
||||
|
||||
let isInsideEscape = false;
|
||||
let isInsideLinkEscape = false;
|
||||
let visible = stringWidth(stripAnsi(rows[rows.length - 1]));
|
||||
|
||||
for (const [index, character] of characters.entries()) {
|
||||
const characterLength = stringWidth(character);
|
||||
|
||||
if (visible + characterLength <= columns) {
|
||||
rows[rows.length - 1] += character;
|
||||
} else {
|
||||
rows.push(character);
|
||||
visible = 0;
|
||||
}
|
||||
|
||||
if (ESCAPES.has(character)) {
|
||||
isInsideEscape = true;
|
||||
isInsideLinkEscape = characters.slice(index + 1).join('').startsWith(ANSI_ESCAPE_LINK);
|
||||
}
|
||||
|
||||
if (isInsideEscape) {
|
||||
if (isInsideLinkEscape) {
|
||||
if (character === ANSI_ESCAPE_BELL) {
|
||||
isInsideEscape = false;
|
||||
isInsideLinkEscape = false;
|
||||
}
|
||||
} else if (character === ANSI_SGR_TERMINATOR) {
|
||||
isInsideEscape = false;
|
||||
}
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
visible += characterLength;
|
||||
|
||||
if (visible === columns && index < characters.length - 1) {
|
||||
rows.push('');
|
||||
visible = 0;
|
||||
}
|
||||
}
|
||||
|
||||
// It's possible that the last row we copy over is only
|
||||
// ansi escape characters, handle this edge-case
|
||||
if (!visible && rows[rows.length - 1].length > 0 && rows.length > 1) {
|
||||
rows[rows.length - 2] += rows.pop();
|
||||
}
|
||||
};
|
||||
|
||||
// Trims spaces from a string ignoring invisible sequences
|
||||
const stringVisibleTrimSpacesRight = string => {
|
||||
const words = string.split(' ');
|
||||
let last = words.length;
|
||||
|
||||
while (last > 0) {
|
||||
if (stringWidth(words[last - 1]) > 0) {
|
||||
break;
|
||||
}
|
||||
|
||||
last--;
|
||||
}
|
||||
|
||||
if (last === words.length) {
|
||||
return string;
|
||||
}
|
||||
|
||||
return words.slice(0, last).join(' ') + words.slice(last).join('');
|
||||
};
|
||||
|
||||
// The wrap-ansi module can be invoked in either 'hard' or 'soft' wrap mode
|
||||
//
|
||||
// 'hard' will never allow a string to take up more than columns characters
|
||||
//
|
||||
// 'soft' allows long words to expand past the column length
|
||||
const exec = (string, columns, options = {}) => {
|
||||
if (options.trim !== false && string.trim() === '') {
|
||||
return '';
|
||||
}
|
||||
|
||||
let returnValue = '';
|
||||
let escapeCode;
|
||||
let escapeUrl;
|
||||
|
||||
const lengths = wordLengths(string);
|
||||
let rows = [''];
|
||||
|
||||
for (const [index, word] of string.split(' ').entries()) {
|
||||
if (options.trim !== false) {
|
||||
rows[rows.length - 1] = rows[rows.length - 1].trimStart();
|
||||
}
|
||||
|
||||
let rowLength = stringWidth(rows[rows.length - 1]);
|
||||
|
||||
if (index !== 0) {
|
||||
if (rowLength >= columns && (options.wordWrap === false || options.trim === false)) {
|
||||
// If we start with a new word but the current row length equals the length of the columns, add a new row
|
||||
rows.push('');
|
||||
rowLength = 0;
|
||||
}
|
||||
|
||||
if (rowLength > 0 || options.trim === false) {
|
||||
rows[rows.length - 1] += ' ';
|
||||
rowLength++;
|
||||
}
|
||||
}
|
||||
|
||||
// In 'hard' wrap mode, the length of a line is never allowed to extend past 'columns'
|
||||
if (options.hard && lengths[index] > columns) {
|
||||
const remainingColumns = (columns - rowLength);
|
||||
const breaksStartingThisLine = 1 + Math.floor((lengths[index] - remainingColumns - 1) / columns);
|
||||
const breaksStartingNextLine = Math.floor((lengths[index] - 1) / columns);
|
||||
if (breaksStartingNextLine < breaksStartingThisLine) {
|
||||
rows.push('');
|
||||
}
|
||||
|
||||
wrapWord(rows, word, columns);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (rowLength + lengths[index] > columns && rowLength > 0 && lengths[index] > 0) {
|
||||
if (options.wordWrap === false && rowLength < columns) {
|
||||
wrapWord(rows, word, columns);
|
||||
continue;
|
||||
}
|
||||
|
||||
rows.push('');
|
||||
}
|
||||
|
||||
if (rowLength + lengths[index] > columns && options.wordWrap === false) {
|
||||
wrapWord(rows, word, columns);
|
||||
continue;
|
||||
}
|
||||
|
||||
rows[rows.length - 1] += word;
|
||||
}
|
||||
|
||||
if (options.trim !== false) {
|
||||
rows = rows.map(row => stringVisibleTrimSpacesRight(row));
|
||||
}
|
||||
|
||||
const pre = [...rows.join('\n')];
|
||||
|
||||
for (const [index, character] of pre.entries()) {
|
||||
returnValue += character;
|
||||
|
||||
if (ESCAPES.has(character)) {
|
||||
const {groups} = new RegExp(`(?:\\${ANSI_CSI}(?<code>\\d+)m|\\${ANSI_ESCAPE_LINK}(?<uri>.*)${ANSI_ESCAPE_BELL})`).exec(pre.slice(index).join('')) || {groups: {}};
|
||||
if (groups.code !== undefined) {
|
||||
const code = Number.parseFloat(groups.code);
|
||||
escapeCode = code === END_CODE ? undefined : code;
|
||||
} else if (groups.uri !== undefined) {
|
||||
escapeUrl = groups.uri.length === 0 ? undefined : groups.uri;
|
||||
}
|
||||
}
|
||||
|
||||
const code = ansiStyles.codes.get(Number(escapeCode));
|
||||
|
||||
if (pre[index + 1] === '\n') {
|
||||
if (escapeUrl) {
|
||||
returnValue += wrapAnsiHyperlink('');
|
||||
}
|
||||
|
||||
if (escapeCode && code) {
|
||||
returnValue += wrapAnsiCode(code);
|
||||
}
|
||||
} else if (character === '\n') {
|
||||
if (escapeCode && code) {
|
||||
returnValue += wrapAnsiCode(escapeCode);
|
||||
}
|
||||
|
||||
if (escapeUrl) {
|
||||
returnValue += wrapAnsiHyperlink(escapeUrl);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return returnValue;
|
||||
};
|
||||
|
||||
// For each newline, invoke the method separately
|
||||
export default function wrapAnsi(string, columns, options) {
|
||||
return String(string)
|
||||
.normalize()
|
||||
.replace(/\r\n/g, '\n')
|
||||
.split('\n')
|
||||
.map(line => exec(line, columns, options))
|
||||
.join('\n');
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
"use strict";
|
||||
|
||||
var forEach = require("./for-each")
|
||||
, isPlainObject = require("./is-plain-object")
|
||||
, ensureValue = require("./valid-value")
|
||||
, isArray = Array.isArray;
|
||||
|
||||
var copyValue = function (value, ancestors, ancestorsCopy) {
|
||||
var mode;
|
||||
if (isPlainObject(value)) mode = "object";
|
||||
else if (isArray(value)) mode = "array";
|
||||
if (!mode) return value;
|
||||
|
||||
var copy = ancestorsCopy[ancestors.indexOf(value)];
|
||||
if (copy) return copy;
|
||||
copy = mode === "object" ? {} : [];
|
||||
|
||||
ancestors.push(value);
|
||||
ancestorsCopy.push(copy);
|
||||
if (mode === "object") {
|
||||
forEach(value, function (item, key) {
|
||||
copy[key] = copyValue(item, ancestors, ancestorsCopy);
|
||||
});
|
||||
} else {
|
||||
value.forEach(function (item, index) {
|
||||
copy[index] = copyValue(item, ancestors, ancestorsCopy);
|
||||
});
|
||||
}
|
||||
ancestors.pop();
|
||||
ancestorsCopy.pop();
|
||||
|
||||
return copy;
|
||||
};
|
||||
|
||||
module.exports = function (source) { return copyValue(ensureValue(source), [], []); };
|
||||
@@ -0,0 +1,3 @@
|
||||
'use strict';
|
||||
|
||||
module.exports = require('./async').times;
|
||||
@@ -0,0 +1,41 @@
|
||||
# get-caller-file
|
||||
|
||||
[](https://travis-ci.org/stefanpenner/get-caller-file)
|
||||
[](https://ci.appveyor.com/project/embercli/get-caller-file/branch/master)
|
||||
|
||||
This is a utility, which allows a function to figure out from which file it was invoked. It does so by inspecting v8's stack trace at the time it is invoked.
|
||||
|
||||
Inspired by http://stackoverflow.com/questions/13227489
|
||||
|
||||
*note: this relies on Node/V8 specific APIs, as such other runtimes may not work*
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
yarn add get-caller-file
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
Given:
|
||||
|
||||
```js
|
||||
// ./foo.js
|
||||
const getCallerFile = require('get-caller-file');
|
||||
|
||||
module.exports = function() {
|
||||
return getCallerFile(); // figures out who called it
|
||||
};
|
||||
```
|
||||
|
||||
```js
|
||||
// index.js
|
||||
const foo = require('./foo');
|
||||
|
||||
foo() // => /full/path/to/this/file/index.js
|
||||
```
|
||||
|
||||
|
||||
## Options:
|
||||
|
||||
* `getCallerFile(position = 2)`: where position is stack frame whos fileName we want.
|
||||
@@ -0,0 +1,60 @@
|
||||
import { Falsy, MonoTypeOperatorFunction, OperatorFunction } from '../types';
|
||||
import { operate } from '../util/lift';
|
||||
import { createOperatorSubscriber } from './OperatorSubscriber';
|
||||
|
||||
export function skipWhile<T>(predicate: BooleanConstructor): OperatorFunction<T, Extract<T, Falsy> extends never ? never : T>;
|
||||
export function skipWhile<T>(predicate: (value: T, index: number) => true): OperatorFunction<T, never>;
|
||||
export function skipWhile<T>(predicate: (value: T, index: number) => boolean): MonoTypeOperatorFunction<T>;
|
||||
|
||||
/**
|
||||
* Returns an Observable that skips all items emitted by the source Observable as long as a specified condition holds
|
||||
* true, but emits all further source items as soon as the condition becomes false.
|
||||
*
|
||||
* 
|
||||
*
|
||||
* Skips all the notifications with a truthy predicate. It will not skip the notifications when the predicate is falsy.
|
||||
* It can also be skipped using index. Once the predicate is true, it will not be called again.
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* Skip some super heroes
|
||||
*
|
||||
* ```ts
|
||||
* import { from, skipWhile } from 'rxjs';
|
||||
*
|
||||
* const source = from(['Green Arrow', 'SuperMan', 'Flash', 'SuperGirl', 'Black Canary'])
|
||||
* // Skip the heroes until SuperGirl
|
||||
* const example = source.pipe(skipWhile(hero => hero !== 'SuperGirl'));
|
||||
* // output: SuperGirl, Black Canary
|
||||
* example.subscribe(femaleHero => console.log(femaleHero));
|
||||
* ```
|
||||
*
|
||||
* Skip values from the array until index 5
|
||||
*
|
||||
* ```ts
|
||||
* import { from, skipWhile } from 'rxjs';
|
||||
*
|
||||
* const source = from([1, 2, 3, 4, 5, 6, 7, 9, 10]);
|
||||
* const example = source.pipe(skipWhile((_, i) => i !== 5));
|
||||
* // output: 6, 7, 9, 10
|
||||
* example.subscribe(value => console.log(value));
|
||||
* ```
|
||||
*
|
||||
* @see {@link last}
|
||||
* @see {@link skip}
|
||||
* @see {@link skipUntil}
|
||||
* @see {@link skipLast}
|
||||
*
|
||||
* @param {Function} predicate - A function to test each item emitted from the source Observable.
|
||||
* @return A function that returns an Observable that begins emitting items
|
||||
* emitted by the source Observable when the specified predicate becomes false.
|
||||
*/
|
||||
export function skipWhile<T>(predicate: (value: T, index: number) => boolean): MonoTypeOperatorFunction<T> {
|
||||
return operate((source, subscriber) => {
|
||||
let taking = false;
|
||||
let index = 0;
|
||||
source.subscribe(
|
||||
createOperatorSubscriber(subscriber, (value) => (taking || (taking = !predicate(value, index++))) && subscriber.next(value))
|
||||
);
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
var convert = require('./convert'),
|
||||
func = convert('filter', require('../filter'));
|
||||
|
||||
func.placeholder = require('./placeholder');
|
||||
module.exports = func;
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0.00401,"52":0.00401,"53":0,"54":0,"55":0,"56":0.04006,"57":0,"58":0,"59":0.00401,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0.00401,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0.00401,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0.00401,"103":0,"104":0.00401,"105":0.00401,"106":0.00401,"107":0.00401,"108":0.00801,"109":0.23235,"110":0.14422,"111":0.00401,"112":0,"3.5":0,"3.6":0},D:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0.00401,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0.00401,"50":0,"51":0,"52":0.00401,"53":0.00401,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0.02404,"67":0,"68":0,"69":0.00401,"70":0.00401,"71":0,"72":0.00401,"73":0.00401,"74":0.00801,"75":0.00401,"76":0.00801,"77":0.00401,"78":0.00801,"79":0.02404,"80":0.00401,"81":0.00801,"83":0.01202,"84":0.00401,"85":0.00801,"86":0.00801,"87":0.01602,"88":0.01202,"89":0.00801,"90":0.00801,"91":0.02804,"92":0.05208,"93":0.03205,"94":0.00801,"95":0.00801,"96":0.01202,"97":0.01202,"98":0.01202,"99":0.01602,"100":0.01602,"101":0.01202,"102":0.02003,"103":0.11617,"104":0.03205,"105":0.03605,"106":0.03605,"107":0.0641,"108":0.28042,"109":5.76463,"110":4.71506,"111":0.01202,"112":0.00401,"113":0},F:{"9":0,"11":0,"12":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0.00801,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0.00401,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0.00401,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0.00401,"62":0,"63":0,"64":0,"65":0,"66":0.00401,"67":0.02404,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0.02804,"94":0.24036,"95":0.08413,"9.5-9.6":0,"10.0-10.1":0,"10.5":0,"10.6":0,"11.1":0,"11.5":0,"11.6":0,"12.1":0},B:{"12":0,"13":0,"14":0,"15":0,"16":0,"17":0.00401,"18":0.00401,"79":0,"80":0,"81":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0.00401,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0,"103":0,"104":0,"105":0.00401,"106":0.00401,"107":0.00801,"108":0.02003,"109":0.49274,"110":0.79319},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0.00401,"14":0.00801,"15":0.00401,_:"0","3.1":0,"3.2":0,"5.1":0,"6.1":0,"7.1":0,"9.1":0,"10.1":0,"11.1":0.00401,"12.1":0.00401,"13.1":0.01202,"14.1":0.02404,"15.1":0.00401,"15.2-15.3":0.00401,"15.4":0.01202,"15.5":0.02003,"15.6":0.08413,"16.0":0.00801,"16.1":0.04006,"16.2":0.08413,"16.3":0.06009,"16.4":0},G:{"8":0,"3.2":0,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0.00527,"6.0-6.1":0,"7.0-7.1":0.01142,"8.1-8.4":0.00176,"9.0-9.2":0.00703,"9.3":0.0984,"10.0-10.2":0.00615,"10.3":0.04481,"11.0-11.2":0.00791,"11.3-11.4":0.04744,"12.0-12.1":0.01318,"12.2-12.5":0.43664,"13.0-13.1":0.00791,"13.2":0.00703,"13.3":0.02636,"13.4-13.7":0.05711,"14.0-14.4":0.1555,"14.5-14.8":0.28465,"15.0-15.1":0.09049,"15.2-15.3":0.11597,"15.4":0.16868,"15.5":0.28729,"15.6":0.68966,"16.0":0.94971,"16.1":1.57524,"16.2":1.66046,"16.3":1.08237,"16.4":0.00439},P:{"4":0.18572,"20":0.27857,"5.0-5.4":0.01032,"6.2-6.4":0,"7.2-7.4":0.02064,"8.2":0,"9.2":0,"10.1":0,"11.1-11.2":0.01032,"12.0":0,"13.0":0.01032,"14.0":0.02064,"15.0":0.01032,"16.0":0.02064,"17.0":0.03095,"18.0":0.05159,"19.0":0.60873},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.02364,"4.4":0,"4.4.3-4.4.4":0.10242},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.79719,"5.5":0},N:{"10":0,"11":0},S:{"2.5":0,_:"3.0-3.1"},J:{"7":0,"10":0},O:{"0":0.43756},H:{"0":0.45398},L:{"0":73.56397},R:{_:"0"},M:{"0":0.07792},Q:{"13.1":0}};
|
||||
@@ -0,0 +1,30 @@
|
||||
"use strict";
|
||||
|
||||
var assert = require("chai").assert
|
||||
, isObject = require("../../object/is");
|
||||
|
||||
describe("object/is", function () {
|
||||
it("Should return true on object", function () { assert.equal(isObject({}), true); });
|
||||
it("Should return true on function", function () {
|
||||
assert.equal(isObject(function () { return true; }), true);
|
||||
});
|
||||
it("Should return true on array", function () { assert.equal(isObject([]), true); });
|
||||
if (typeof Object.create === "function") {
|
||||
it("Should return true on object with no prototype", function () {
|
||||
assert.equal(isObject(Object.create(null)), true);
|
||||
});
|
||||
}
|
||||
it("Should return false on string", function () { assert.equal(isObject("foo"), false); });
|
||||
it("Should return false on empty string", function () { assert.equal(isObject(""), false); });
|
||||
it("Should return false on number", function () { assert.equal(isObject(123), false); });
|
||||
it("Should return false on NaN", function () { assert.equal(isObject(NaN), false); });
|
||||
it("Should return false on boolean", function () { assert.equal(isObject(true), false); });
|
||||
if (typeof Symbol === "function") {
|
||||
it("Should return false on symbol", function () {
|
||||
assert.equal(isObject(Symbol("foo")), false);
|
||||
});
|
||||
}
|
||||
|
||||
it("Should return false on null", function () { assert.equal(isObject(null), false); });
|
||||
it("Should return false on undefined", function () { assert.equal(isObject(void 0), false); });
|
||||
});
|
||||
Reference in New Issue
Block a user