new license file version [CI SKIP]
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
Copyright (c) 2017 Luke Childs
|
||||
|
||||
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,60 @@
|
||||
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 clicks = fromEvent(document, 'click');
|
||||
* const parts = clicks.pipe(partition(ev => ev.target.tagName === 'DIV'));
|
||||
* const clicksOnDivs = parts[0];
|
||||
* const clicksElsewhere = parts[1];
|
||||
* 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 {[Observable<T>, Observable<T>]} An array with two Observables: one
|
||||
* with values that passed the predicate, and another with values that did not
|
||||
* pass the predicate.
|
||||
* @method partition
|
||||
* @owner Observable
|
||||
* @deprecated use `partition` static creation function instead
|
||||
*/
|
||||
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) as any)(source)
|
||||
] as [Observable<T>, Observable<T>];
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"defer.js","sources":["../../src/add/observable/defer.ts"],"names":[],"mappings":";;AAAA,4CAA0C"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"expand.js","sources":["../../../src/internal/operators/expand.ts"],"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AAC,MAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SAC1B;IACH,CAAC;IAEO,qBAAqB,CAAC,MAAW,EAAE,KAAQ,EAAE,KAAa;QAChE,IAAI,CAAC,MAAM,EAAE,CAAC;QACd,MAAM,WAAW,GAAG,IAAI,CAAC,WAA2B,CAAC;QACrD,WAAW,CAAC,GAAG,CAAC,cAAc,CAAC,MAAM,EAAE,IAAI,qBAAqB,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAC3E,CAAC;IAES,SAAS;QACjB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC;QACzB,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;YAC1C,IAAI,CAAC,WAAW,CAAC,QAAS,EAAE,CAAC;SAC9B;QACD,IAAI,CAAC,WAAW,EAAE,CAAC;IACrB,CAAC;IAED,UAAU,CAAC,UAAa;QACtB,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;IACzB,CAAC;IAED,cAAc;QACZ,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;QAC3B,IAAI,CAAC,MAAM,EAAE,CAAC;QACd,IAAI,MAAM,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE;YAC/B,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC;SAC5B;QACD,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;YAC1C,IAAI,CAAC,WAAW,CAAC,QAAS,EAAE,CAAC;SAC9B;IACH,CAAC;CACF"}
|
||||
@@ -0,0 +1,53 @@
|
||||
var pump = require('./index')
|
||||
|
||||
var rs = require('fs').createReadStream('/dev/random')
|
||||
var ws = require('fs').createWriteStream('/dev/null')
|
||||
|
||||
var toHex = function () {
|
||||
var reverse = new (require('stream').Transform)()
|
||||
|
||||
reverse._transform = function (chunk, enc, callback) {
|
||||
reverse.push(chunk.toString('hex'))
|
||||
callback()
|
||||
}
|
||||
|
||||
return reverse
|
||||
}
|
||||
|
||||
var wsClosed = false
|
||||
var rsClosed = false
|
||||
var callbackCalled = false
|
||||
|
||||
var check = function () {
|
||||
if (wsClosed && rsClosed && callbackCalled) {
|
||||
console.log('test-node.js passes')
|
||||
clearTimeout(timeout)
|
||||
}
|
||||
}
|
||||
|
||||
ws.on('close', function () {
|
||||
wsClosed = true
|
||||
check()
|
||||
})
|
||||
|
||||
rs.on('close', function () {
|
||||
rsClosed = true
|
||||
check()
|
||||
})
|
||||
|
||||
var res = pump(rs, toHex(), toHex(), toHex(), ws, function () {
|
||||
callbackCalled = true
|
||||
check()
|
||||
})
|
||||
|
||||
if (res !== ws) {
|
||||
throw new Error('should return last stream')
|
||||
}
|
||||
|
||||
setTimeout(function () {
|
||||
rs.destroy()
|
||||
}, 1000)
|
||||
|
||||
var timeout = setTimeout(function () {
|
||||
throw new Error('timeout')
|
||||
}, 5000)
|
||||
@@ -0,0 +1 @@
|
||||
import 'rxjs-compat/add/operator/do';
|
||||
@@ -0,0 +1,50 @@
|
||||
"use strict";
|
||||
var __extends = (this && this.__extends) || (function () {
|
||||
var extendStatics = function (d, b) {
|
||||
extendStatics = Object.setPrototypeOf ||
|
||||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
||||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
||||
return extendStatics(d, b);
|
||||
}
|
||||
return function (d, b) {
|
||||
extendStatics(d, b);
|
||||
function __() { this.constructor = d; }
|
||||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
||||
};
|
||||
})();
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var AsyncAction_1 = require("./AsyncAction");
|
||||
var QueueAction = (function (_super) {
|
||||
__extends(QueueAction, _super);
|
||||
function QueueAction(scheduler, work) {
|
||||
var _this = _super.call(this, scheduler, work) || this;
|
||||
_this.scheduler = scheduler;
|
||||
_this.work = work;
|
||||
return _this;
|
||||
}
|
||||
QueueAction.prototype.schedule = function (state, delay) {
|
||||
if (delay === void 0) { delay = 0; }
|
||||
if (delay > 0) {
|
||||
return _super.prototype.schedule.call(this, state, delay);
|
||||
}
|
||||
this.delay = delay;
|
||||
this.state = state;
|
||||
this.scheduler.flush(this);
|
||||
return this;
|
||||
};
|
||||
QueueAction.prototype.execute = function (state, delay) {
|
||||
return (delay > 0 || this.closed) ?
|
||||
_super.prototype.execute.call(this, state, delay) :
|
||||
this._execute(state, delay);
|
||||
};
|
||||
QueueAction.prototype.requestAsyncId = function (scheduler, id, delay) {
|
||||
if (delay === void 0) { delay = 0; }
|
||||
if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) {
|
||||
return _super.prototype.requestAsyncId.call(this, scheduler, id, delay);
|
||||
}
|
||||
return scheduler.flush(this);
|
||||
};
|
||||
return QueueAction;
|
||||
}(AsyncAction_1.AsyncAction));
|
||||
exports.QueueAction = QueueAction;
|
||||
//# sourceMappingURL=QueueAction.js.map
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E BC","161":"F G A B"},B:{"2":"P Q R S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t","161":"C K L H M N O"},C:{"2":"0 1 2 3 4 5 6 7 8 9 CC tB I u J E F G A B C K L H M N O v w 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 e lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t xB yB DC EC"},D:{"2":"0 1 2 3 4 5 6 7 8 9 I u J E F G A B C K L H M N O v w 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 e lB mB nB oB pB P Q R S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t xB yB FC"},E:{"2":"I u J E F G A B C K L H GC zB HC IC JC KC 0B qB rB 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC"},F:{"2":"0 1 2 3 4 5 6 7 8 9 G B C H M N O v w 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 e lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d OC PC QC RC qB 9B SC rB"},G:{"2":"F zB TC AC UC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC 2B 3B 4B 5B sB 6B 7B 8B"},H:{"2":"nC"},I:{"2":"tB I D oC pC qC rC AC sC tC"},J:{"2":"E A"},K:{"2":"A B C e qB 9B rB"},L:{"2":"D"},M:{"2":"D"},N:{"16":"A B"},O:{"2":"uC"},P:{"2":"I vC wC xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C"},Q:{"2":"1B"},R:{"2":"8C"},S:{"2":"9C"}},B:5,C:"CSS Text 4 text-spacing"};
|
||||
@@ -0,0 +1 @@
|
||||
export * from 'rxjs-compat/operator/throttle';
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1 @@
|
||||
{"name":"is-npm","version":"5.0.0","files":{"license":{"checkedAt":1678887829613,"integrity":"sha512-0fM2/ycrxrltyaBKfQ748Ck23VlPUUBgNAR47ldf4B1V/HoXTfWBSk+vcshGKwEpmOynu4mOP5o+hyBfuRNa8g==","mode":420,"size":1117},"index.js":{"checkedAt":1678887830280,"integrity":"sha512-mOyGPsstdk7ALhbVskzCGZtynksDm4aCt4nAM6Z4vqHSl3hmFweYF5ZS/7izsnTIGSA+ogLLXj4G4+lPcg7+fQ==","mode":420,"size":456},"package.json":{"checkedAt":1678887830280,"integrity":"sha512-+jcirYoiuatUwa6ziZLcW1CK0RQSJru5UkYGQrUzZ2Qj30UMxvjVaey/fPvm/AJ9e/hMnfco9MQpDQNRa88tqA==","mode":420,"size":664},"index.d.ts":{"checkedAt":1678887830282,"integrity":"sha512-jFhtNEMzG+fx70C8Vs6s9RgKl/o2jWDTFWtYG3gqad5ZirZarC/D2GSOtCKghclivo9WR0kjBzWq/pUf4bAv4g==","mode":420,"size":780},"readme.md":{"checkedAt":1678887830280,"integrity":"sha512-1gcAe5a0xEgTMxXhGPLQ7KZClxkFeTiZO5hSpl8hswZEw1kzhKRxgbEa44odpi73zyBw15Uzz+e4PGtSIa3YcQ==","mode":420,"size":2087}}}
|
||||
@@ -0,0 +1,7 @@
|
||||
"use strict";
|
||||
function __export(m) {
|
||||
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
|
||||
}
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
__export(require("rxjs-compat/operators/toArray"));
|
||||
//# sourceMappingURL=toArray.js.map
|
||||
@@ -0,0 +1,4 @@
|
||||
'use strict';
|
||||
const is = require('@sindresorhus/is');
|
||||
|
||||
module.exports = body => is.nodeStream(body) && is.function(body.getBoundary);
|
||||
@@ -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,"52":0.01733,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0.00347,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0.00347,"67":0,"68":0.00347,"69":0,"70":0,"71":0,"72":0,"73":0.00347,"74":0,"75":0,"76":0,"77":0,"78":0.00693,"79":0,"80":0.00347,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0.00693,"87":0,"88":0.0104,"89":0.00347,"90":0.00347,"91":0.04506,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0.00693,"100":0,"101":0.00347,"102":0.00693,"103":0.00347,"104":0.0104,"105":0.00693,"106":0.00693,"107":0.0104,"108":0.27381,"109":0.1629,"110":0,"111":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.00347,"35":0,"36":0,"37":0,"38":0.00693,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0.06239,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0.00347,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0.01733,"67":0,"68":0,"69":0,"70":0.00347,"71":0,"72":0.00347,"73":0,"74":0.00347,"75":0.00347,"76":0.00347,"77":0.00347,"78":0.00347,"79":0.01386,"80":0.00347,"81":0.01386,"83":0.00347,"84":0.00347,"85":0.00693,"86":0.00693,"87":0.00693,"88":0.00347,"89":0.00347,"90":0.00347,"91":0.0104,"92":0.0104,"93":0.00693,"94":0.00693,"95":0.00693,"96":0.01733,"97":0.0104,"98":0.0104,"99":0.0208,"100":0.01386,"101":0.0104,"102":0.01386,"103":0.04852,"104":0.02426,"105":0.03466,"106":0.03466,"107":0.07972,"108":4.3533,"109":4.3117,"110":0,"111":0,"112":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.00347,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0.00347,"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,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"60":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0.00347,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0.00347,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0.42285,"94":0.30501,"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.00347,"16":0,"17":0.00347,"18":0.00347,"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.00347,"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.00347,"106":0.00347,"107":0.0104,"108":0.33274,"109":0.32927},E:{"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0.00693,"15":0.00347,_:"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.00347,"12.1":0,"13.1":0.00693,"14.1":0.01733,"15.1":0.00347,"15.2-15.3":0.00347,"15.4":0.00347,"15.5":0.0104,"15.6":0.05546,"16.0":0.00693,"16.1":0.02773,"16.2":0.04506,"16.3":0.00347},G:{"8":0,"3.2":0.00139,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0.01458,"6.0-6.1":0.00069,"7.0-7.1":0.00208,"8.1-8.4":0.00139,"9.0-9.2":0,"9.3":0.02569,"10.0-10.2":0,"10.3":0.01944,"11.0-11.2":0.00278,"11.3-11.4":0.07359,"12.0-12.1":0.00208,"12.2-12.5":0.16246,"13.0-13.1":0.00625,"13.2":0.00139,"13.3":0.00972,"13.4-13.7":0.02985,"14.0-14.4":0.06457,"14.5-14.8":0.19578,"15.0-15.1":0.04096,"15.2-15.3":0.04721,"15.4":0.08053,"15.5":0.1576,"15.6":0.73245,"16.0":0.68385,"16.1":2.39451,"16.2":1.32465,"16.3":0.09859},P:{"4":0.12229,"5.0-5.4":0,"6.2-6.4":0,"7.2-7.4":0.2344,"8.2":0.01019,"9.2":0.01019,"10.1":0,"11.1-11.2":0.03057,"12.0":0.01019,"13.0":0.04076,"14.0":0.03057,"15.0":0.02038,"16.0":0.07134,"17.0":0.17325,"18.0":0.12229,"19.0":1.85478},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0.00723,"4.2-4.3":0.00482,"4.4":0,"4.4.3-4.4.4":0.06262},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"6":0,"7":0,"8":0,"9":0,"10":0,"11":0.02426,"5.5":0},J:{"7":0,"10":0},N:{"10":0,"11":0},R:{_:"0"},M:{"0":0.10454},Q:{"13.1":0},O:{"0":0.0196},H:{"0":0.16702},L:{"0":77.82762},S:{"2.5":0}};
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"1":"o p q r s D t","2":"C K L H M N O P Q R S T U V W X Y Z a b c d f g h i j k l m n"},C:{"1":"bB cB dB eB fB gB hB iB jB kB e lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d f g h i j k l m n o p q r s D t xB yB","2":"0 1 2 3 4 5 6 7 8 9 CC tB I u J E F G A B C K L H M N O v w 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 DC EC"},D:{"1":"o p q r s D t xB yB FC","2":"0 1 2 3 4 5 6 7 8 9 I u J E F G A B C K L H M N O v w 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 e lB mB nB oB pB P Q R S T U V W X Y Z a b c d f g h i j k l m n"},E:{"1":"NC","2":"I u J E F G A B C K L H GC zB HC IC JC KC 0B qB rB 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B"},F:{"1":"a b c d","2":"0 1 2 3 4 5 6 7 8 9 G B C H M N O v w 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 e lB mB nB oB pB P Q R wB S T U V W X Y Z OC PC QC RC qB 9B SC rB"},G:{"2":"F zB TC AC UC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC 2B 3B 4B 5B sB 6B 7B 8B"},H:{"2":"nC"},I:{"1":"D","2":"tB I oC pC qC rC AC sC tC"},J:{"2":"E A"},K:{"1":"e","2":"A B C qB 9B rB"},L:{"1":"D"},M:{"1":"D"},N:{"2":"A B"},O:{"2":"uC"},P:{"2":"I vC wC xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C"},Q:{"2":"1B"},R:{"2":"8C"},S:{"2":"9C"}},B:4,C:"Media Queries: Range Syntax"};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"skipUntil.js","sources":["../../../src/internal/operators/skipUntil.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAyCjG,MAAM,UAAU,SAAS,CAAI,QAAyB;IACpD,OAAO,CAAC,MAAqB,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,iBAAiB,CAAC,QAAQ,CAAC,CAAC,CAAC;AACjF,CAAC;AAED,MAAM,iBAAiB;IACrB,YAAoB,QAAyB;QAAzB,aAAQ,GAAR,QAAQ,CAAiB;IAC7C,CAAC;IAED,IAAI,CAAC,WAA0B,EAAE,MAAW;QAC1C,OAAO,MAAM,CAAC,SAAS,CAAC,IAAI,mBAAmB,CAAC,WAAW,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC/E,CAAC;CACF;AAOD,MAAM,mBAA0B,SAAQ,qBAA2B;IAKjE,YAAY,WAA0B,EAAE,QAA8B;QACpE,KAAK,CAAC,WAAW,CAAC,CAAC;QAJb,aAAQ,GAAY,KAAK,CAAC;QAKhC,MAAM,eAAe,GAAG,IAAI,qBAAqB,CAAC,IAAI,CAAC,CAAC;QACxD,IAAI,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC;QAC1B,IAAI,CAAC,iBAAiB,GAAG,eAAe,CAAC;QACzC,MAAM,iBAAiB,GAAG,cAAc,CAAC,QAAQ,EAAE,eAAe,CAAC,CAAC;QAIpE,IAAI,iBAAiB,KAAK,eAAe,EAAE;YACzC,IAAI,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;YAC5B,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;SAC5C;IACH,CAAC;IAES,KAAK,CAAC,KAAQ;QACtB,IAAI,IAAI,CAAC,QAAQ,EAAE;YACjB,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;SACpB;IACH,CAAC;IAED,UAAU;QACR,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;QACrB,IAAI,IAAI,CAAC,iBAAiB,EAAE;YAC1B,IAAI,CAAC,iBAAiB,CAAC,WAAW,EAAE,CAAC;SACtC;IACH,CAAC;IAED,cAAc;IAEd,CAAC;CACF"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"publishLast.js","sources":["../../../src/internal/operators/publishLast.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AA8DxC,MAAM,UAAU,WAAW;IACzB,OAAO,UAAC,MAAqB,IAAK,OAAA,SAAS,CAAC,IAAI,YAAY,EAAK,CAAC,CAAC,MAAM,CAAC,EAAxC,CAAwC,CAAC;AAC7E,CAAC"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"distinctUntilChanged.js","sources":["../../../src/internal/operators/distinctUntilChanged.ts"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C,GAAG,CAAC,CAAC;SACpC;QACD,IAAI,MAAM,GAAG,KAAK,CAAC;QACnB,IAAI,IAAI,CAAC,MAAM,EAAE;YACf,IAAI;gBACM,IAAA,sBAAO,CAAU;gBACzB,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;aACjC;YAAC,OAAO,GAAG,EAAE;gBACZ,OAAO,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;aACpC;SACF;aAAM;YACL,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;SACpB;QACD,IAAI,CAAC,MAAM,EAAE;YACX,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;YACf,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SAC9B;IACH,CAAC;IACH,qCAAC;AAAD,CAAC,AAzCD,CAAmD,UAAU,GAyC5D"}
|
||||
@@ -0,0 +1,18 @@
|
||||
declare interface ParsedUrl {
|
||||
protocols: string[];
|
||||
protocol: string;
|
||||
port?: string;
|
||||
resource: string;
|
||||
user: string;
|
||||
pathname: string;
|
||||
hash: string;
|
||||
search: string;
|
||||
href: string;
|
||||
query: {
|
||||
[key: string]: any;
|
||||
}
|
||||
}
|
||||
|
||||
declare function parseUrl(url: string, normalize?: boolean | Object): ParsedUrl;
|
||||
|
||||
export default parseUrl
|
||||
@@ -0,0 +1,70 @@
|
||||
import { Observable } from '../Observable';
|
||||
import { map } from './map';
|
||||
import { OperatorFunction } from '../types';
|
||||
|
||||
/* tslint:disable:max-line-length */
|
||||
export function pluck<T, K1 extends keyof T>(k1: K1): OperatorFunction<T, T[K1]>;
|
||||
export function pluck<T, K1 extends keyof T, K2 extends keyof T[K1]>(k1: K1, k2: K2): OperatorFunction<T, T[K1][K2]>;
|
||||
export function pluck<T, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2]>(k1: K1, k2: K2, k3: K3): OperatorFunction<T, T[K1][K2][K3]>;
|
||||
export function pluck<T, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3]>(k1: K1, k2: K2, k3: K3, k4: K4): OperatorFunction<T, T[K1][K2][K3][K4]>;
|
||||
export function pluck<T, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3], K5 extends keyof T[K1][K2][K3][K4]>(k1: K1, k2: K2, k3: K3, k4: K4, k5: K5): OperatorFunction<T, T[K1][K2][K3][K4][K5]>;
|
||||
export function pluck<T, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3], K5 extends keyof T[K1][K2][K3][K4], K6 extends keyof T[K1][K2][K3][K4][K5]>(k1: K1, k2: K2, k3: K3, k4: K4, k5: K5, k6: K6): OperatorFunction<T, T[K1][K2][K3][K4][K5][K6]>;
|
||||
export function pluck<T, R>(...properties: string[]): OperatorFunction<T, R>;
|
||||
/* tslint:enable:max-line-length */
|
||||
|
||||
/**
|
||||
* Maps each source value (an object) to its specified nested property.
|
||||
*
|
||||
* <span class="informal">Like {@link map}, but meant only for picking one of
|
||||
* the nested properties of every emitted object.</span>
|
||||
*
|
||||
* 
|
||||
*
|
||||
* Given a list of strings describing a path to an object property, retrieves
|
||||
* the value of a specified nested property from all values in the source
|
||||
* Observable. If a property can't be resolved, it will return `undefined` for
|
||||
* that value.
|
||||
*
|
||||
* ## Example
|
||||
* Map every click to the tagName of the clicked target element
|
||||
* ```ts
|
||||
* import { fromEvent } from 'rxjs';
|
||||
* import { pluck } from 'rxjs/operators';
|
||||
*
|
||||
* const clicks = fromEvent(document, 'click');
|
||||
* const tagNames = clicks.pipe(pluck('target', 'tagName'));
|
||||
* tagNames.subscribe(x => console.log(x));
|
||||
* ```
|
||||
*
|
||||
* @see {@link map}
|
||||
*
|
||||
* @param {...string} properties The nested properties to pluck from each source
|
||||
* value (an object).
|
||||
* @return {Observable} A new Observable of property values from the source values.
|
||||
* @method pluck
|
||||
* @owner Observable
|
||||
*/
|
||||
export function pluck<T, R>(...properties: string[]): OperatorFunction<T, R> {
|
||||
const length = properties.length;
|
||||
if (length === 0) {
|
||||
throw new Error('list of properties cannot be empty.');
|
||||
}
|
||||
return (source: Observable<T>) => map(plucker(properties, length))(source as any);
|
||||
}
|
||||
|
||||
function plucker(props: string[], length: number): (x: string) => any {
|
||||
const mapper = (x: string) => {
|
||||
let currentProp = x;
|
||||
for (let i = 0; i < length; i++) {
|
||||
const p = currentProp != null ? currentProp[props[i]] : undefined;
|
||||
if (p !== void 0) {
|
||||
currentProp = p;
|
||||
} else {
|
||||
return undefined;
|
||||
}
|
||||
}
|
||||
return currentProp;
|
||||
};
|
||||
|
||||
return mapper;
|
||||
}
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
import 'rxjs-compat/add/operator/exhaust';
|
||||
@@ -0,0 +1,25 @@
|
||||
import { AsyncScheduler } from './AsyncScheduler';
|
||||
export class AnimationFrameScheduler extends AsyncScheduler {
|
||||
flush(action) {
|
||||
this.active = true;
|
||||
this.scheduled = undefined;
|
||||
const { actions } = this;
|
||||
let error;
|
||||
let index = -1;
|
||||
let count = actions.length;
|
||||
action = action || actions.shift();
|
||||
do {
|
||||
if (error = action.execute(action.state, action.delay)) {
|
||||
break;
|
||||
}
|
||||
} while (++index < count && (action = actions.shift()));
|
||||
this.active = false;
|
||||
if (error) {
|
||||
while (++index < count && (action = actions.shift())) {
|
||||
action.unsubscribe();
|
||||
}
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=AnimationFrameScheduler.js.map
|
||||
@@ -0,0 +1 @@
|
||||
export * from 'rxjs-compat/operators/zip';
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"catch.js","sources":["../src/operator/catch.ts"],"names":[],"mappings":";;;;;AAAA,gDAA2C"}
|
||||
Reference in New Issue
Block a user