new license file version [CI SKIP]
This commit is contained in:
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"1":"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","2":"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 DC EC","132":"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","1090":"fB","1412":"jB","1668":"gB hB iB"},D:{"1":"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","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","2114":"hB"},E:{"1":"L H 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC","2":"I u J E F G GC zB HC IC JC KC","4100":"A B C K 0B qB rB"},F:{"1":"e lB mB nB oB pB P Q R wB S T U V W X Y Z 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 OC PC QC RC qB 9B SC rB","8196":"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"},G:{"1":"kC lC mC 2B 3B 4B 5B sB 6B 7B 8B","2":"F zB TC AC UC VC WC XC","4100":"YC ZC aC bC cC dC eC fC gC hC iC jC"},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:{"16388":"D"},M:{"16388":"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:5,C:"Picture-in-Picture"};
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"1":"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 o p q r s D t","2":"C K L"},C:{"1":"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","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 DC EC"},D:{"1":"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","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"},E:{"1":"A B C K L H 0B qB rB 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC","2":"I u J E F G GC zB HC IC JC KC"},F:{"1":"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","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 OC PC QC RC qB 9B SC rB"},G:{"1":"aC bC cC dC eC fC gC hC iC jC kC lC mC 2B 3B 4B 5B sB 6B 7B 8B","2":"F zB TC AC UC VC WC XC YC ZC"},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:{"1":"uC"},P:{"1":"xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C","2":"I vC wC"},Q:{"1":"1B"},R:{"1":"8C"},S:{"1":"9C"}},B:6,C:"String.prototype.padStart(), String.prototype.padEnd()"};
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"1":"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","2":"C K L H M N O"},C:{"1":"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","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 DC EC"},D:{"1":"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","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"},E:{"1":"K L H 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC","2":"I u J E F G A B C GC zB HC IC JC KC 0B qB rB"},F:{"1":"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","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 OC PC QC RC qB 9B SC rB"},G:{"1":"gC hC iC jC kC lC mC 2B 3B 4B 5B sB 6B 7B 8B","2":"F zB TC AC UC VC WC XC YC ZC aC bC cC dC eC fC"},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:{"1":"uC"},P:{"1":"xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C","2":"I vC wC"},Q:{"1":"1B"},R:{"1":"8C"},S:{"2":"9C"}},B:4,C:"display: flow-root"};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"mergeMapTo.js","sources":["../../src/add/operator/mergeMapTo.ts"],"names":[],"mappings":";;AAAA,+CAA6C"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"bufferTime.js","sources":["../src/operators/bufferTime.ts"],"names":[],"mappings":";;;;;AAAA,sDAAiD"}
|
||||
@@ -0,0 +1,12 @@
|
||||
|
||||
// IE8 compat mode aka Fake IE7
|
||||
// by Erich Ocean
|
||||
|
||||
// In this case, IE8 will be acting as IE7. You may choose to remove features in this case.
|
||||
|
||||
// related:
|
||||
// james.padolsey.com/javascript/detect-ie-in-js-using-conditional-comments/
|
||||
|
||||
Modernizr.addTest('ie8compat',function(){
|
||||
return (!window.addEventListener && document.documentMode && document.documentMode === 7);
|
||||
});
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={C:{"52":0.04744,"55":0.01581,"57":0.02767,"68":0.00791,"78":0.01186,"82":0.00395,"87":0.23718,"91":0.03162,"99":0.01186,"102":0.2609,"103":0.00395,"104":0.00791,"105":0.01186,"106":0.01581,"107":0.04744,"108":1.0515,"109":0.6562,_:"2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 53 54 56 58 59 60 61 62 63 64 65 66 67 69 70 71 72 73 74 75 76 77 79 80 81 83 84 85 86 88 89 90 92 93 94 95 96 97 98 100 101 110 111 3.5","3.6":0.0593},D:{"49":0.08301,"51":0.01581,"53":0.01186,"56":0.01581,"67":0.01186,"70":0.00395,"71":0.01186,"72":0.00791,"73":0.00395,"74":0.00395,"75":0.00791,"76":0.01186,"79":0.04744,"80":0.17393,"81":0.01977,"83":0.00791,"84":0.01186,"85":0.07906,"86":0.04348,"87":0.02372,"88":0.02372,"89":0.01581,"90":0.01977,"91":0.00791,"92":0.02372,"94":0.00791,"95":0.02767,"96":0.07115,"97":0.06325,"98":0.04744,"99":0.03558,"100":0.07511,"101":0.0593,"102":0.17789,"103":0.07511,"104":0.13836,"105":0.08697,"106":0.12254,"107":0.26485,"108":12.68518,"109":13.25836,"110":0.00791,"111":0.01186,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 50 52 54 55 57 58 59 60 61 62 63 64 65 66 68 69 77 78 93 112"},F:{"70":0.00791,"79":0.02372,"85":0.05534,"87":0.00791,"93":0.589,"94":2.103,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 60 62 63 64 65 66 67 68 69 71 72 73 74 75 76 77 78 80 81 82 83 84 86 88 89 90 91 92 9.5-9.6 10.5 10.6 11.1 11.5 11.6 12.1","10.0-10.1":0},B:{"18":0.00791,"92":0.00791,"107":0.03162,"108":0.81037,"109":0.76688,_:"12 13 14 15 16 17 79 80 81 83 84 85 86 87 88 89 90 91 93 94 95 96 97 98 99 100 101 102 103 104 105 106"},E:{"4":0,"8":0.00791,"13":0.00395,"14":0.03162,"15":0.00791,_:"0 5 6 7 9 10 11 12 3.1 3.2 6.1 7.1 10.1","5.1":0.00395,"9.1":0.00395,"11.1":0.00395,"12.1":0.00791,"13.1":0.03558,"14.1":0.14231,"15.1":0.02372,"15.2-15.3":0.01581,"15.4":0.03953,"15.5":0.0593,"15.6":0.22927,"16.0":0.04348,"16.1":0.13045,"16.2":0.25299,"16.3":0.01977},G:{"8":0.00137,"3.2":0,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0,"6.0-6.1":0,"7.0-7.1":0.00274,"8.1-8.4":0,"9.0-9.2":0,"9.3":0.01919,"10.0-10.2":0,"10.3":0.01782,"11.0-11.2":0.00685,"11.3-11.4":0.00685,"12.0-12.1":0.00823,"12.2-12.5":0.21523,"13.0-13.1":0.00685,"13.2":0.0096,"13.3":0.01508,"13.4-13.7":0.05758,"14.0-14.4":0.18096,"14.5-14.8":0.44281,"15.0-15.1":0.11516,"15.2-15.3":0.15903,"15.4":0.20564,"15.5":0.48119,"15.6":1.34213,"16.0":2.54854,"16.1":3.68367,"16.2":2.92006,"16.3":0.27418},P:{"4":0.09322,"5.0-5.4":0,"6.2-6.4":0,"7.2-7.4":0.04143,"8.2":0,"9.2":0,"10.1":0,"11.1-11.2":0.04143,"12.0":0,"13.0":0.02072,"14.0":0.02072,"15.0":0.03107,"16.0":0.06215,"17.0":0.07251,"18.0":0.09322,"19.0":2.19587},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0,"4.2-4.3":0.01008,"4.4":0,"4.4.3-4.4.4":0.02015},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"8":0.00791,"11":0.22137,_:"6 7 9 10 5.5"},J:{"7":0,"10":0},N:{"10":0,"11":0},R:{_:"0"},M:{"0":0.18743},Q:{"13.1":0},O:{"0":0.04837},H:{"0":0.21751},L:{"0":45.8928},S:{"2.5":0}};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"ObjectUnsubscribedError.js","sources":["../../../src/internal/util/ObjectUnsubscribedError.ts"],"names":[],"mappings":"AAOA,IAAM,2BAA2B,GAAG,CAAC;IACnC,SAAS,2BAA2B;QAClC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACjB,IAAI,CAAC,OAAO,GAAG,qBAAqB,CAAC;QACrC,IAAI,CAAC,IAAI,GAAG,yBAAyB,CAAC;QACtC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,2BAA2B,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;IAEvE,OAAO,2BAA2B,CAAC;AACrC,CAAC,CAAC,EAAE,CAAC;AAWL,MAAM,CAAC,IAAM,uBAAuB,GAAgC,2BAAkC,CAAC"}
|
||||
@@ -0,0 +1,174 @@
|
||||
import { Operator } from '../Operator';
|
||||
import { Observable } from '../Observable';
|
||||
import { Subscriber } from '../Subscriber';
|
||||
import { Subscription } from '../Subscription';
|
||||
|
||||
import { Observer, OperatorFunction } from '../types';
|
||||
|
||||
/**
|
||||
* Compares all values of two observables in sequence using an optional comparator function
|
||||
* and returns an observable of a single boolean value representing whether or not the two sequences
|
||||
* are equal.
|
||||
*
|
||||
* <span class="informal">Checks to see of all values emitted by both observables are equal, in order.</span>
|
||||
*
|
||||
* 
|
||||
*
|
||||
* `sequenceEqual` subscribes to two observables and buffers incoming values from each observable. Whenever either
|
||||
* observable emits a value, the value is buffered and the buffers are shifted and compared from the bottom
|
||||
* up; If any value pair doesn't match, the returned observable will emit `false` and complete. If one of the
|
||||
* observables completes, the operator will wait for the other observable to complete; If the other
|
||||
* observable emits before completing, the returned observable will emit `false` and complete. If one observable never
|
||||
* completes or emits after the other complets, the returned observable will never complete.
|
||||
*
|
||||
* ## Example
|
||||
* figure out if the Konami code matches
|
||||
* ```ts
|
||||
* import { from, fromEvent } from 'rxjs';
|
||||
* import { sequenceEqual, bufferCount, mergeMap, map } from 'rxjs/operators';
|
||||
*
|
||||
* const codes = from([
|
||||
* 'ArrowUp',
|
||||
* 'ArrowUp',
|
||||
* 'ArrowDown',
|
||||
* 'ArrowDown',
|
||||
* 'ArrowLeft',
|
||||
* 'ArrowRight',
|
||||
* 'ArrowLeft',
|
||||
* 'ArrowRight',
|
||||
* 'KeyB',
|
||||
* 'KeyA',
|
||||
* 'Enter', // no start key, clearly.
|
||||
* ]);
|
||||
*
|
||||
* const keys = fromEvent(document, 'keyup').pipe(map(e => e.code));
|
||||
* const matches = keys.pipe(
|
||||
* bufferCount(11, 1),
|
||||
* mergeMap(
|
||||
* last11 => from(last11).pipe(sequenceEqual(codes)),
|
||||
* ),
|
||||
* );
|
||||
* matches.subscribe(matched => console.log('Successful cheat at Contra? ', matched));
|
||||
* ```
|
||||
*
|
||||
* @see {@link combineLatest}
|
||||
* @see {@link zip}
|
||||
* @see {@link withLatestFrom}
|
||||
*
|
||||
* @param {Observable} compareTo The observable sequence to compare the source sequence to.
|
||||
* @param {function} [comparator] An optional function to compare each value pair
|
||||
* @return {Observable} An Observable of a single boolean value representing whether or not
|
||||
* the values emitted by both observables were equal in sequence.
|
||||
* @method sequenceEqual
|
||||
* @owner Observable
|
||||
*/
|
||||
export function sequenceEqual<T>(compareTo: Observable<T>,
|
||||
comparator?: (a: T, b: T) => boolean): OperatorFunction<T, boolean> {
|
||||
return (source: Observable<T>) => source.lift(new SequenceEqualOperator(compareTo, comparator));
|
||||
}
|
||||
|
||||
export class SequenceEqualOperator<T> implements Operator<T, boolean> {
|
||||
constructor(private compareTo: Observable<T>,
|
||||
private comparator: (a: T, b: T) => boolean) {
|
||||
}
|
||||
|
||||
call(subscriber: Subscriber<boolean>, source: any): any {
|
||||
return source.subscribe(new SequenceEqualSubscriber(subscriber, this.compareTo, this.comparator));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* We need this JSDoc comment for affecting ESDoc.
|
||||
* @ignore
|
||||
* @extends {Ignored}
|
||||
*/
|
||||
export class SequenceEqualSubscriber<T, R> extends Subscriber<T> {
|
||||
private _a: T[] = [];
|
||||
private _b: T[] = [];
|
||||
private _oneComplete = false;
|
||||
|
||||
constructor(destination: Observer<R>,
|
||||
private compareTo: Observable<T>,
|
||||
private comparator: (a: T, b: T) => boolean) {
|
||||
super(destination);
|
||||
(this.destination as Subscription).add(compareTo.subscribe(new SequenceEqualCompareToSubscriber(destination, this)));
|
||||
}
|
||||
|
||||
protected _next(value: T): void {
|
||||
if (this._oneComplete && this._b.length === 0) {
|
||||
this.emit(false);
|
||||
} else {
|
||||
this._a.push(value);
|
||||
this.checkValues();
|
||||
}
|
||||
}
|
||||
|
||||
public _complete(): void {
|
||||
if (this._oneComplete) {
|
||||
this.emit(this._a.length === 0 && this._b.length === 0);
|
||||
} else {
|
||||
this._oneComplete = true;
|
||||
}
|
||||
this.unsubscribe();
|
||||
}
|
||||
|
||||
checkValues() {
|
||||
const { _a, _b, comparator } = this;
|
||||
while (_a.length > 0 && _b.length > 0) {
|
||||
let a = _a.shift();
|
||||
let b = _b.shift();
|
||||
let areEqual = false;
|
||||
try {
|
||||
areEqual = comparator ? comparator(a, b) : a === b;
|
||||
} catch (e) {
|
||||
this.destination.error(e);
|
||||
}
|
||||
if (!areEqual) {
|
||||
this.emit(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
emit(value: boolean) {
|
||||
const { destination } = this;
|
||||
destination.next(value);
|
||||
destination.complete();
|
||||
}
|
||||
|
||||
nextB(value: T) {
|
||||
if (this._oneComplete && this._a.length === 0) {
|
||||
this.emit(false);
|
||||
} else {
|
||||
this._b.push(value);
|
||||
this.checkValues();
|
||||
}
|
||||
}
|
||||
|
||||
completeB() {
|
||||
if (this._oneComplete) {
|
||||
this.emit(this._a.length === 0 && this._b.length === 0);
|
||||
} else {
|
||||
this._oneComplete = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class SequenceEqualCompareToSubscriber<T, R> extends Subscriber<T> {
|
||||
constructor(destination: Observer<R>, private parent: SequenceEqualSubscriber<T, R>) {
|
||||
super(destination);
|
||||
}
|
||||
|
||||
protected _next(value: T): void {
|
||||
this.parent.nextB(value);
|
||||
}
|
||||
|
||||
protected _error(err: any): void {
|
||||
this.parent.error(err);
|
||||
this.unsubscribe();
|
||||
}
|
||||
|
||||
protected _complete(): void {
|
||||
this.parent.completeB();
|
||||
this.unsubscribe();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"BC","8":"J E F G A B"},B:{"1":"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","8":"C K L H M N O"},C:{"1":"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 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","8":"CC tB DC EC"},D:{"1":"0 1 2 3 4 5 6 7 8 9 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","4":"I"},E:{"1":"J E F G A B C K L H IC JC KC 0B qB rB 1B LC MC 2B 3B 4B 5B sB 6B 7B 8B NC","8":"GC zB","132":"I u HC"},F:{"1":"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:{"1":"F 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","132":"zB TC AC UC"},H:{"2":"nC"},I:{"1":"tB I D rC AC sC tC","2":"oC pC qC"},J:{"1":"E A"},K:{"1":"A B C e qB 9B rB"},L:{"1":"D"},M:{"1":"D"},N:{"8":"A B"},O:{"1":"uC"},P:{"1":"I vC wC xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C"},Q:{"1":"1B"},R:{"1":"8C"},S:{"1":"9C"}},B:2,C:"SVG SMIL animation"};
|
||||
@@ -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/operator/subscribeOn"));
|
||||
//# sourceMappingURL=subscribeOn.js.map
|
||||
@@ -0,0 +1,5 @@
|
||||
export declare type DnsLookupIpVersion = 'auto' | 'ipv4' | 'ipv6';
|
||||
declare type DnsIpFamily = 0 | 4 | 6;
|
||||
export declare const isDnsLookupIpVersion: (value: any) => boolean;
|
||||
export declare const dnsLookupIpVersionToFamily: (dnsLookupIpVersion: DnsLookupIpVersion) => DnsIpFamily;
|
||||
export {};
|
||||
@@ -0,0 +1,32 @@
|
||||
'use strict';
|
||||
|
||||
// We define these manually to ensure they're always copied
|
||||
// even if they would move up the prototype chain
|
||||
// https://nodejs.org/api/http.html#http_class_http_incomingmessage
|
||||
const knownProps = [
|
||||
'destroy',
|
||||
'setTimeout',
|
||||
'socket',
|
||||
'headers',
|
||||
'trailers',
|
||||
'rawHeaders',
|
||||
'statusCode',
|
||||
'httpVersion',
|
||||
'httpVersionMinor',
|
||||
'httpVersionMajor',
|
||||
'rawTrailers',
|
||||
'statusMessage'
|
||||
];
|
||||
|
||||
module.exports = (fromStream, toStream) => {
|
||||
const fromProps = new Set(Object.keys(fromStream).concat(knownProps));
|
||||
|
||||
for (const prop of fromProps) {
|
||||
// Don't overwrite existing properties
|
||||
if (prop in toStream) {
|
||||
continue;
|
||||
}
|
||||
|
||||
toStream[prop] = typeof fromStream[prop] === 'function' ? fromStream[prop].bind(fromStream) : fromStream[prop];
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,13 @@
|
||||
import { Octokit as Core } from "@octokit/core";
|
||||
export { RestEndpointMethodTypes } from "@octokit/plugin-rest-endpoint-methods";
|
||||
export declare const Octokit: (new (...args: any[]) => {
|
||||
[x: string]: any;
|
||||
}) & {
|
||||
new (...args: any[]): {
|
||||
[x: string]: any;
|
||||
};
|
||||
plugins: any[];
|
||||
} & typeof Core & import("@octokit/core/dist-types/types").Constructor<void & {
|
||||
paginate: import("@octokit/plugin-paginate-rest").PaginateInterface;
|
||||
} & import("@octokit/plugin-rest-endpoint-methods/dist-types/generated/method-types").RestEndpointMethods & import("@octokit/plugin-rest-endpoint-methods/dist-types/types").Api>;
|
||||
export declare type Octokit = InstanceType<typeof Octokit>;
|
||||
@@ -0,0 +1 @@
|
||||
module.exports={A:{A:{"2":"J E F G A B BC"},B:{"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 o p q r s D t"},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:{"1":"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","2":"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:{"1":"0 1 2 3 4 5 6 7 8 9 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","2":"G B C 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:{"1":"D","2":"tB I 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:{"2":"A B"},O:{"2":"uC"},P:{"1":"vC wC xC yC zC 0B 0C 1C 2C 3C 4C sB 5C 6C 7C","2":"I"},Q:{"2":"1B"},R:{"2":"8C"},S:{"2":"9C"}},B:6,C:"SDCH Accept-Encoding/Content-Encoding"};
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"ignoreElements.js","sources":["../../src/internal/operators/ignoreElements.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAEA,4CAA2C;AA8B3C,SAAgB,cAAc;IAC5B,OAAO,SAAS,8BAA8B,CAAC,MAAuB;QACpE,OAAO,MAAM,CAAC,IAAI,CAAC,IAAI,sBAAsB,EAAE,CAAC,CAAC;IACnD,CAAC,CAAC;AACJ,CAAC;AAJD,wCAIC;AAED;IAAA;IAIA,CAAC;IAHC,qCAAI,GAAJ,UAAK,UAAyB,EAAE,MAAW;QACzC,OAAO,MAAM,CAAC,SAAS,CAAC,IAAI,wBAAwB,CAAC,UAAU,CAAC,CAAC,CAAC;IACpE,CAAC;IACH,6BAAC;AAAD,CAAC,AAJD,IAIC;AAOD;IAA0C,4CAAa;IAAvD;;IAIA,CAAC;IAHW,wCAAK,GAAf,UAAgB,MAAS;IAEzB,CAAC;IACH,+BAAC;AAAD,CAAC,AAJD,CAA0C,uBAAU,GAInD"}
|
||||
@@ -0,0 +1,83 @@
|
||||
{
|
||||
"name": "cliui",
|
||||
"version": "7.0.4",
|
||||
"description": "easily create complex multi-column command-line-interfaces",
|
||||
"main": "build/index.cjs",
|
||||
"exports": {
|
||||
".": [
|
||||
{
|
||||
"import": "./index.mjs",
|
||||
"require": "./build/index.cjs"
|
||||
},
|
||||
"./build/index.cjs"
|
||||
]
|
||||
},
|
||||
"type": "module",
|
||||
"module": "./index.mjs",
|
||||
"scripts": {
|
||||
"check": "standardx '**/*.ts' && standardx '**/*.js' && standardx '**/*.cjs'",
|
||||
"fix": "standardx --fix '**/*.ts' && standardx --fix '**/*.js' && standardx --fix '**/*.cjs'",
|
||||
"pretest": "rimraf build && tsc -p tsconfig.test.json && cross-env NODE_ENV=test npm run build:cjs",
|
||||
"test": "c8 mocha ./test/*.cjs",
|
||||
"test:esm": "c8 mocha ./test/esm/cliui-test.mjs",
|
||||
"postest": "check",
|
||||
"coverage": "c8 report --check-coverage",
|
||||
"precompile": "rimraf build",
|
||||
"compile": "tsc",
|
||||
"postcompile": "npm run build:cjs",
|
||||
"build:cjs": "rollup -c",
|
||||
"prepare": "npm run compile"
|
||||
},
|
||||
"repository": "yargs/cliui",
|
||||
"standard": {
|
||||
"ignore": [
|
||||
"**/example/**"
|
||||
],
|
||||
"globals": [
|
||||
"it"
|
||||
]
|
||||
},
|
||||
"keywords": [
|
||||
"cli",
|
||||
"command-line",
|
||||
"layout",
|
||||
"design",
|
||||
"console",
|
||||
"wrap",
|
||||
"table"
|
||||
],
|
||||
"author": "Ben Coe <ben@npmjs.com>",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"string-width": "^4.2.0",
|
||||
"strip-ansi": "^6.0.0",
|
||||
"wrap-ansi": "^7.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "^14.0.27",
|
||||
"@typescript-eslint/eslint-plugin": "^4.0.0",
|
||||
"@typescript-eslint/parser": "^4.0.0",
|
||||
"@wessberg/rollup-plugin-ts": "^1.3.2",
|
||||
"c8": "^7.3.0",
|
||||
"chai": "^4.2.0",
|
||||
"chalk": "^4.1.0",
|
||||
"cross-env": "^7.0.2",
|
||||
"eslint": "^7.6.0",
|
||||
"eslint-plugin-import": "^2.22.0",
|
||||
"eslint-plugin-node": "^11.1.0",
|
||||
"gts": "^3.0.0",
|
||||
"mocha": "^8.1.1",
|
||||
"rimraf": "^3.0.2",
|
||||
"rollup": "^2.23.1",
|
||||
"standardx": "^7.0.0",
|
||||
"typescript": "^4.0.0"
|
||||
},
|
||||
"files": [
|
||||
"build",
|
||||
"index.mjs",
|
||||
"!*.d.ts"
|
||||
],
|
||||
"engine": {
|
||||
"node": ">=10"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,155 @@
|
||||
import { Operator } from '../Operator';
|
||||
import { Subscriber } from '../Subscriber';
|
||||
import { Observable } from '../Observable';
|
||||
import { OuterSubscriber } from '../OuterSubscriber';
|
||||
import { InnerSubscriber } from '../InnerSubscriber';
|
||||
import { subscribeToResult } from '../util/subscribeToResult';
|
||||
import { ObservableInput, OperatorFunction, ObservedValueOf } from '../types';
|
||||
|
||||
/* tslint:disable:max-line-length */
|
||||
export function withLatestFrom<T, R>(project: (v1: T) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, R>(source2: O2, project: (v1: T, v2: ObservedValueOf<O2>) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, R>(v2: O2, v3: O3, project: (v1: T, v2: ObservedValueOf<O2>, v3: ObservedValueOf<O3>) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>, R>(v2: O2, v3: O3, v4: O4, project: (v1: T, v2: ObservedValueOf<O2>, v3: ObservedValueOf<O3>, v4: ObservedValueOf<O4>) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>, O5 extends ObservableInput<any>, R>(v2: O2, v3: O3, v4: O4, v5: O5, project: (v1: T, v2: ObservedValueOf<O2>, v3: ObservedValueOf<O3>, v4: ObservedValueOf<O4>, v5: ObservedValueOf<O5>) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>, O5 extends ObservableInput<any>, O6 extends ObservableInput<any>, R>(v2: O2, v3: O3, v4: O4, v5: O5, v6: O6, project: (v1: T, v2: ObservedValueOf<O2>, v3: ObservedValueOf<O3>, v4: ObservedValueOf<O4>, v5: ObservedValueOf<O5>, v6: ObservedValueOf<O6>) => R): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>>(source2: O2): OperatorFunction<T, [T, ObservedValueOf<O2>]>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>>(v2: O2, v3: O3): OperatorFunction<T, [T, ObservedValueOf<O2>, ObservedValueOf<O3>]>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>>(v2: O2, v3: O3, v4: O4): OperatorFunction<T, [T, ObservedValueOf<O2>, ObservedValueOf<O3>, ObservedValueOf<O4>]>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>, O5 extends ObservableInput<any>>(v2: O2, v3: O3, v4: O4, v5: O5): OperatorFunction<T, [T, ObservedValueOf<O2>, ObservedValueOf<O3>, ObservedValueOf<O4>, ObservedValueOf<O5>]>;
|
||||
export function withLatestFrom<T, O2 extends ObservableInput<any>, O3 extends ObservableInput<any>, O4 extends ObservableInput<any>, O5 extends ObservableInput<any>, O6 extends ObservableInput<any>>(v2: O2, v3: O3, v4: O4, v5: O5, v6: O6): OperatorFunction<T, [T, ObservedValueOf<O2>, ObservedValueOf<O3>, ObservedValueOf<O4>, ObservedValueOf<O5>, ObservedValueOf<O6>]>;
|
||||
export function withLatestFrom<T, R>(...observables: Array<ObservableInput<any> | ((...values: Array<any>) => R)>): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, R>(array: ObservableInput<any>[]): OperatorFunction<T, R>;
|
||||
export function withLatestFrom<T, R>(array: ObservableInput<any>[], project: (...values: Array<any>) => R): OperatorFunction<T, R>;
|
||||
|
||||
/* tslint:enable:max-line-length */
|
||||
|
||||
/**
|
||||
* Combines the source Observable with other Observables to create an Observable
|
||||
* whose values are calculated from the latest values of each, only when the
|
||||
* source emits.
|
||||
*
|
||||
* <span class="informal">Whenever the source Observable emits a value, it
|
||||
* computes a formula using that value plus the latest values from other input
|
||||
* Observables, then emits the output of that formula.</span>
|
||||
*
|
||||
* 
|
||||
*
|
||||
* `withLatestFrom` combines each value from the source Observable (the
|
||||
* instance) with the latest values from the other input Observables only when
|
||||
* the source emits a value, optionally using a `project` function to determine
|
||||
* the value to be emitted on the output Observable. All input Observables must
|
||||
* emit at least one value before the output Observable will emit a value.
|
||||
*
|
||||
* ## Example
|
||||
* On every click event, emit an array with the latest timer event plus the click event
|
||||
* ```ts
|
||||
* import { fromEvent, interval } from 'rxjs';
|
||||
* import { withLatestFrom } from 'rxjs/operators';
|
||||
*
|
||||
* const clicks = fromEvent(document, 'click');
|
||||
* const timer = interval(1000);
|
||||
* const result = clicks.pipe(withLatestFrom(timer));
|
||||
* result.subscribe(x => console.log(x));
|
||||
* ```
|
||||
*
|
||||
* @see {@link combineLatest}
|
||||
*
|
||||
* @param {ObservableInput} other An input Observable to combine with the source
|
||||
* Observable. More than one input Observables may be given as argument.
|
||||
* @param {Function} [project] Projection function for combining values
|
||||
* together. Receives all values in order of the Observables passed, where the
|
||||
* first parameter is a value from the source Observable. (e.g.
|
||||
* `a.pipe(withLatestFrom(b, c), map(([a1, b1, c1]) => a1 + b1 + c1))`). If this is not
|
||||
* passed, arrays will be emitted on the output Observable.
|
||||
* @return {Observable} An Observable of projected values from the most recent
|
||||
* values from each input Observable, or an array of the most recent values from
|
||||
* each input Observable.
|
||||
* @method withLatestFrom
|
||||
* @owner Observable
|
||||
*/
|
||||
export function withLatestFrom<T, R>(...args: Array<ObservableInput<any> | ((...values: Array<any>) => R)>): OperatorFunction<T, R> {
|
||||
return (source: Observable<T>) => {
|
||||
let project: any;
|
||||
if (typeof args[args.length - 1] === 'function') {
|
||||
project = args.pop();
|
||||
}
|
||||
const observables = <Observable<any>[]>args;
|
||||
return source.lift(new WithLatestFromOperator(observables, project));
|
||||
};
|
||||
}
|
||||
|
||||
class WithLatestFromOperator<T, R> implements Operator<T, R> {
|
||||
constructor(private observables: Observable<any>[],
|
||||
private project?: (...values: any[]) => Observable<R>) {
|
||||
}
|
||||
|
||||
call(subscriber: Subscriber<R>, source: any): any {
|
||||
return source.subscribe(new WithLatestFromSubscriber(subscriber, this.observables, this.project));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* We need this JSDoc comment for affecting ESDoc.
|
||||
* @ignore
|
||||
* @extends {Ignored}
|
||||
*/
|
||||
class WithLatestFromSubscriber<T, R> extends OuterSubscriber<T, R> {
|
||||
private values: any[];
|
||||
private toRespond: number[] = [];
|
||||
|
||||
constructor(destination: Subscriber<R>,
|
||||
private observables: Observable<any>[],
|
||||
private project?: (...values: any[]) => Observable<R>) {
|
||||
super(destination);
|
||||
const len = observables.length;
|
||||
this.values = new Array(len);
|
||||
|
||||
for (let i = 0; i < len; i++) {
|
||||
this.toRespond.push(i);
|
||||
}
|
||||
|
||||
for (let i = 0; i < len; i++) {
|
||||
let observable = observables[i];
|
||||
this.add(subscribeToResult<T, R>(this, observable, undefined, i));
|
||||
}
|
||||
}
|
||||
|
||||
notifyNext(_outerValue: T, innerValue: R,
|
||||
outerIndex: number): void {
|
||||
this.values[outerIndex] = innerValue;
|
||||
const toRespond = this.toRespond;
|
||||
if (toRespond.length > 0) {
|
||||
const found = toRespond.indexOf(outerIndex);
|
||||
if (found !== -1) {
|
||||
toRespond.splice(found, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
notifyComplete() {
|
||||
// noop
|
||||
}
|
||||
|
||||
protected _next(value: T) {
|
||||
if (this.toRespond.length === 0) {
|
||||
const args = [value, ...this.values];
|
||||
if (this.project) {
|
||||
this._tryProject(args);
|
||||
} else {
|
||||
this.destination.next!(args);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private _tryProject(args: any[]) {
|
||||
let result: any;
|
||||
try {
|
||||
result = this.project!.apply(this, args);
|
||||
} catch (err) {
|
||||
this.destination.error!(err);
|
||||
return;
|
||||
}
|
||||
this.destination.next!(result);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,108 @@
|
||||
# ci-info
|
||||
|
||||
Get details about the current Continuous Integration environment.
|
||||
|
||||
Please [open an
|
||||
issue](https://github.com/watson/ci-info/issues/new?template=ci-server-not-detected.md)
|
||||
if your CI server isn't properly detected :)
|
||||
|
||||
[](https://www.npmjs.com/package/ci-info)
|
||||
[](https://travis-ci.org/watson/ci-info)
|
||||
[](https://github.com/feross/standard)
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
npm install ci-info --save
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
var ci = require('ci-info')
|
||||
|
||||
if (ci.isCI) {
|
||||
console.log('The name of the CI server is:', ci.name)
|
||||
} else {
|
||||
console.log('This program is not running on a CI server')
|
||||
}
|
||||
```
|
||||
|
||||
## Supported CI tools
|
||||
|
||||
Officially supported CI servers:
|
||||
|
||||
| Name | Constant | isPR |
|
||||
|------|----------|------|
|
||||
| [AWS CodeBuild](https://aws.amazon.com/codebuild/) | `ci.CODEBUILD` | 🚫 |
|
||||
| [AppVeyor](http://www.appveyor.com) | `ci.APPVEYOR` | ✅ |
|
||||
| [Azure Pipelines](https://azure.microsoft.com/en-us/services/devops/pipelines/) | `ci.AZURE_PIPELINES` | ✅ |
|
||||
| [Bamboo](https://www.atlassian.com/software/bamboo) by Atlassian | `ci.BAMBOO` | 🚫 |
|
||||
| [Bitbucket Pipelines](https://bitbucket.org/product/features/pipelines) | `ci.BITBUCKET` | ✅ |
|
||||
| [Bitrise](https://www.bitrise.io/) | `ci.BITRISE` | ✅ |
|
||||
| [Buddy](https://buddy.works/) | `ci.BUDDY` | ✅ |
|
||||
| [Buildkite](https://buildkite.com) | `ci.BUILDKITE` | ✅ |
|
||||
| [CircleCI](http://circleci.com) | `ci.CIRCLE` | ✅ |
|
||||
| [Cirrus CI](https://cirrus-ci.org) | `ci.CIRRUS` | ✅ |
|
||||
| [Codeship](https://codeship.com) | `ci.CODESHIP` | 🚫 |
|
||||
| [Drone](https://drone.io) | `ci.DRONE` | ✅ |
|
||||
| [dsari](https://github.com/rfinnie/dsari) | `ci.DSARI` | 🚫 |
|
||||
| [GitLab CI](https://about.gitlab.com/gitlab-ci/) | `ci.GITLAB` | 🚫 |
|
||||
| [GoCD](https://www.go.cd/) | `ci.GOCD` | 🚫 |
|
||||
| [Hudson](http://hudson-ci.org) | `ci.HUDSON` | 🚫 |
|
||||
| [Jenkins CI](https://jenkins-ci.org) | `ci.JENKINS` | ✅ |
|
||||
| [Magnum CI](https://magnum-ci.com) | `ci.MAGNUM` | 🚫 |
|
||||
| [Netlify CI](https://www.netlify.com/) | `ci.NETLIFY` | ✅ |
|
||||
| [Sail CI](https://sail.ci/) | `ci.SAIL` | ✅ |
|
||||
| [Semaphore](https://semaphoreci.com) | `ci.SEMAPHORE` | ✅ |
|
||||
| [Shippable](https://www.shippable.com/) | `ci.SHIPPABLE` | ✅ |
|
||||
| [Solano CI](https://www.solanolabs.com/) | `ci.SOLANO` | ✅ |
|
||||
| [Strider CD](https://strider-cd.github.io/) | `ci.STRIDER` | 🚫 |
|
||||
| [TaskCluster](http://docs.taskcluster.net) | `ci.TASKCLUSTER` | 🚫 |
|
||||
| [TeamCity](https://www.jetbrains.com/teamcity/) by JetBrains | `ci.TEAMCITY` | 🚫 |
|
||||
| [Travis CI](http://travis-ci.org) | `ci.TRAVIS` | ✅ |
|
||||
|
||||
## API
|
||||
|
||||
### `ci.name`
|
||||
|
||||
Returns a string containing name of the CI server the code is running on.
|
||||
If CI server is not detected, it returns `null`.
|
||||
|
||||
Don't depend on the value of this string not to change for a specific
|
||||
vendor. If you find your self writing `ci.name === 'Travis CI'`, you
|
||||
most likely want to use `ci.TRAVIS` instead.
|
||||
|
||||
### `ci.isCI`
|
||||
|
||||
Returns a boolean. Will be `true` if the code is running on a CI server,
|
||||
otherwise `false`.
|
||||
|
||||
Some CI servers not listed here might still trigger the `ci.isCI`
|
||||
boolean to be set to `true` if they use certain vendor neutral
|
||||
environment variables. In those cases `ci.name` will be `null` and no
|
||||
vendor specific boolean will be set to `true`.
|
||||
|
||||
### `ci.isPR`
|
||||
|
||||
Returns a boolean if PR detection is supported for the current CI server. Will
|
||||
be `true` if a PR is being tested, otherwise `false`. If PR detection is
|
||||
not supported for the current CI server, the value will be `null`.
|
||||
|
||||
### `ci.<VENDOR-CONSTANT>`
|
||||
|
||||
A vendor specific boolean constant is exposed for each support CI
|
||||
vendor. A constant will be `true` if the code is determined to run on
|
||||
the given CI server, otherwise `false`.
|
||||
|
||||
Examples of vendor constants are `ci.TRAVIS` or `ci.APPVEYOR`. For a
|
||||
complete list, see the support table above.
|
||||
|
||||
Deprecated vendor constants that will be removed in the next major
|
||||
release:
|
||||
|
||||
- `ci.TDDIUM` (Solano CI) This have been renamed `ci.SOLANO`
|
||||
|
||||
## License
|
||||
|
||||
[MIT](LICENSE)
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"isEmpty.js","sources":["../../src/internal/operators/isEmpty.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AACA,4CAA2C;AAgE3C,SAAgB,OAAO;IACrB,OAAO,UAAC,MAAqB,IAAK,OAAA,MAAM,CAAC,IAAI,CAAC,IAAI,eAAe,EAAE,CAAC,EAAlC,CAAkC,CAAC;AACvE,CAAC;AAFD,0BAEC;AAED;IAAA;IAIA,CAAC;IAHC,8BAAI,GAAJ,UAAM,QAA6B,EAAE,MAAW;QAC9C,OAAO,MAAM,CAAC,SAAS,CAAC,IAAI,iBAAiB,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC3D,CAAC;IACH,sBAAC;AAAD,CAAC,AAJD,IAIC;AAOD;IAAgC,qCAAe;IAC7C,2BAAY,WAAgC;eAC1C,kBAAM,WAAW,CAAC;IACpB,CAAC;IAEO,0CAAc,GAAtB,UAAuB,OAAgB;QACrC,IAAM,WAAW,GAAG,IAAI,CAAC,WAAW,CAAC;QAErC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAC1B,WAAW,CAAC,QAAQ,EAAE,CAAC;IACzB,CAAC;IAES,iCAAK,GAAf,UAAgB,KAAc;QAC5B,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;IAC7B,CAAC;IAES,qCAAS,GAAnB;QACE,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;IAC5B,CAAC;IACH,wBAAC;AAAD,CAAC,AAnBD,CAAgC,uBAAU,GAmBzC"}
|
||||
@@ -0,0 +1,8 @@
|
||||
'use strict';
|
||||
|
||||
module.exports = {
|
||||
info: 'ℹ️',
|
||||
success: '✅',
|
||||
warning: '⚠️',
|
||||
error: '❌️'
|
||||
};
|
||||
@@ -0,0 +1,54 @@
|
||||
import { Observable } from '../Observable';
|
||||
import { Operator } from '../Operator';
|
||||
import { Subscriber } from '../Subscriber';
|
||||
import { EmptyError } from '../util/EmptyError';
|
||||
import { OperatorFunction } from '../../internal/types';
|
||||
import { filter } from './filter';
|
||||
import { takeLast } from './takeLast';
|
||||
import { throwIfEmpty } from './throwIfEmpty';
|
||||
import { defaultIfEmpty } from './defaultIfEmpty';
|
||||
import { identity } from '../util/identity';
|
||||
|
||||
/* tslint:disable:max-line-length */
|
||||
export function last<T, D = T>(
|
||||
predicate?: null,
|
||||
defaultValue?: D
|
||||
): OperatorFunction<T, T | D>;
|
||||
export function last<T, S extends T>(
|
||||
predicate: (value: T, index: number, source: Observable<T>) => value is S,
|
||||
defaultValue?: S
|
||||
): OperatorFunction<T, S>;
|
||||
export function last<T, D = T>(
|
||||
predicate: (value: T, index: number, source: Observable<T>) => boolean,
|
||||
defaultValue?: D
|
||||
): OperatorFunction<T, T | D>;
|
||||
/* tslint:enable:max-line-length */
|
||||
|
||||
/**
|
||||
* Returns an Observable that emits only the last item emitted by the source Observable.
|
||||
* It optionally takes a predicate function as a parameter, in which case, rather than emitting
|
||||
* the last item from the source Observable, the resulting Observable will emit the last item
|
||||
* from the source Observable that satisfies the predicate.
|
||||
*
|
||||
* 
|
||||
*
|
||||
* @throws {EmptyError} Delivers an EmptyError to the Observer's `error`
|
||||
* callback if the Observable completes before any `next` notification was sent.
|
||||
* @param {function} [predicate] - The condition any source emitted item has to satisfy.
|
||||
* @param {any} [defaultValue] - An optional default value to provide if last
|
||||
* predicate isn't met or no values were emitted.
|
||||
* @return {Observable} An Observable that emits only the last item satisfying the given condition
|
||||
* from the source, or an NoSuchElementException if no such items are emitted.
|
||||
* @throws - Throws if no items that match the predicate are emitted by the source Observable.
|
||||
*/
|
||||
export function last<T, D>(
|
||||
predicate?: ((value: T, index: number, source: Observable<T>) => boolean) | null,
|
||||
defaultValue?: D
|
||||
): OperatorFunction<T, T | D> {
|
||||
const hasDefaultValue = arguments.length >= 2;
|
||||
return (source: Observable<T>) => source.pipe(
|
||||
predicate ? filter((v, i) => predicate(v, i, source)) : identity,
|
||||
takeLast(1),
|
||||
hasDefaultValue ? defaultIfEmpty<T | D>(defaultValue) : throwIfEmpty(() => new EmptyError()),
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"SubjectSubscription.js","sources":["../../src/internal/SubjectSubscription.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAO9C;IAA4C,+CAAY;IAGtD,6BAAmB,OAAmB,EAAS,UAAuB;QAAtE,YACE,iBAAO,SACR;QAFkB,aAAO,GAAP,OAAO,CAAY;QAAS,gBAAU,GAAV,UAAU,CAAa;QAFtE,YAAM,GAAY,KAAK,CAAC;;IAIxB,CAAC;IAED,yCAAW,GAAX;QACE,IAAI,IAAI,CAAC,MAAM,EAAE;YACf,OAAO;SACR;QAED,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QAEnB,IAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC;QAC7B,IAAM,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC;QAEpC,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QAEpB,IAAI,CAAC,SAAS,IAAI,SAAS,CAAC,MAAM,KAAK,CAAC,IAAI,OAAO,CAAC,SAAS,IAAI,OAAO,CAAC,MAAM,EAAE;YAC/E,OAAO;SACR;QAED,IAAM,eAAe,GAAG,SAAS,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAE3D,IAAI,eAAe,KAAK,CAAC,CAAC,EAAE;YAC1B,SAAS,CAAC,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC,CAAC;SACtC;IACH,CAAC;IACH,0BAAC;AAAD,CAAC,AA7BD,CAA4C,YAAY,GA6BvD"}
|
||||
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"delay.js","sources":["../../src/add/operator/delay.ts"],"names":[],"mappings":";;AAAA,0CAAwC"}
|
||||
Reference in New Issue
Block a user