Socket
Socket
Sign inDemoInstall

@angular/compiler

Package Overview
Dependencies
Maintainers
1
Versions
843
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@angular/compiler - npm Package Compare versions

Comparing version 2.1.0-rc.0 to 2.1.0

6

bundles/compiler-testing.umd.js
/**
* @license Angular v2.1.0-rc.0
* @license Angular v2.1.0
* (c) 2010-2016 Google, Inc. https://angular.io/

@@ -157,3 +157,3 @@ * License: MIT

if (isPresent(providerOverrides)) {
var originalViewProviders = isPresent(metadata.providers) ? metadata.providers : [];
var originalViewProviders = metadata.providers || [];
providers = originalViewProviders.concat(providerOverrides);

@@ -164,3 +164,3 @@ }

if (isPresent(viewProviderOverrides)) {
var originalViewProviders = isPresent(metadata.viewProviders) ? metadata.viewProviders : [];
var originalViewProviders = metadata.viewProviders || [];
viewProviders = originalViewProviders.concat(viewProviderOverrides);

@@ -167,0 +167,0 @@ }

{
"name": "@angular/compiler",
"version": "2.1.0-rc.0",
"version": "2.1.0",
"description": "Angular - the compiler library",

@@ -11,3 +11,3 @@ "main": "bundles/compiler.umd.js",

"peerDependencies": {
"@angular/core": "2.1.0-rc.0"
"@angular/core": "2.1.0"
},

@@ -14,0 +14,0 @@ "repository": {

@@ -59,3 +59,4 @@ /**

ast.styles.forEach(function (entry) {
stylesArr.push(o.literalMap(Object.keys(entry).map(function (key) { return [key, o.literal(entry[key])]; })));
var entries = Object.keys(entry).map(function (key) { return [key, o.literal(entry[key])]; });
stylesArr.push(o.literalMap(entries));
});

@@ -62,0 +63,0 @@ return o.importExpr(resolveIdentifier(Identifiers.AnimationStyles)).instantiate([

@@ -111,7 +111,3 @@ /**

var transitionStates = transitionStateMetadata.stateChangeExpr.split(/\s*,\s*/);
transitionStates.forEach(function (expr) {
_parseAnimationTransitionExpr(expr, errors).forEach(function (transExpr) {
transitionExprs.push(transExpr);
});
});
transitionStates.forEach(function (expr) { transitionExprs.push.apply(transitionExprs, _parseAnimationTransitionExpr(expr, errors)); });
var entry = _normalizeAnimationEntry(transitionStateMetadata.steps);

@@ -316,3 +312,2 @@ var animation = _normalizeStyleSteps(entry, stateStyles, errors);

}
var i;
var firstKeyframe = rawKeyframes[0];

@@ -330,3 +325,3 @@ if (firstKeyframe[0] != _INITIAL_KEYFRAME) {

var lastKeyframeStyles = lastKeyframe[1];
for (i = 1; i <= limit; i++) {
for (var i = 1; i <= limit; i++) {
var entry = rawKeyframes[i];

@@ -340,3 +335,3 @@ var styles = entry[1];

}
var _loop_1 = function() {
var _loop_1 = function(i) {
var entry = rawKeyframes[i];

@@ -350,4 +345,4 @@ var styles = entry[1];

};
for (i = limit - 1; i >= 0; i--) {
_loop_1();
for (var i = limit - 1; i >= 0; i--) {
_loop_1(i);
}

@@ -354,0 +349,0 @@ return rawKeyframes.map(function (entry) { return new AnimationKeyframeAst(entry[0], new AnimationStylesAst([entry[1]])); });

@@ -261,3 +261,3 @@ /**

this.animations = isPresent(animations) ? ListWrapper.flatten(animations) : [];
this.ngContentSelectors = isPresent(ngContentSelectors) ? ngContentSelectors : [];
this.ngContentSelectors = ngContentSelectors || [];
if (isPresent(interpolation) && interpolation.length != 2) {

@@ -453,3 +453,3 @@ throw new Error("'interpolation' should have a start and an end symbol.");

function _normalizeArray(obj) {
return isPresent(obj) ? obj : [];
return obj || [];
}

@@ -456,0 +456,0 @@ export function isStaticSymbol(value) {

@@ -70,2 +70,9 @@ /**

if (hostBinding.hostPropertyName) {
var startWith = hostBinding.hostPropertyName[0];
if (startWith === '(') {
throw new Error("@HostBinding can not bind to events. Use @HostListener instead.");
}
else if (startWith === '[') {
throw new Error("@HostBinding parameter should be a property name, 'class.<name>', or 'attr.<name>'.");
}
host[("[" + hostBinding.hostPropertyName + "]")] = propName;

@@ -72,0 +79,0 @@ }

@@ -10,3 +10,3 @@ /**

import * as chars from '../chars';
import { NumberWrapper, StringJoiner, StringWrapper, isPresent } from '../facade/lang';
import { NumberWrapper, StringJoiner, isPresent } from '../facade/lang';
export var TokenType;

@@ -88,3 +88,3 @@ (function (TokenType) {

function newCharacterToken(index, code) {
return new Token(index, TokenType.Character, code, StringWrapper.fromCharCode(code));
return new Token(index, TokenType.Character, code, String.fromCharCode(code));
}

@@ -119,4 +119,3 @@ function newIdentifierToken(index, text) {

_Scanner.prototype.advance = function () {
this.peek =
++this.index >= this.length ? chars.$EOF : StringWrapper.charCodeAt(this.input, this.index);
this.peek = ++this.index >= this.length ? chars.$EOF : this.input.charCodeAt(this.index);
};

@@ -132,3 +131,3 @@ _Scanner.prototype.scanToken = function () {

else {
peek = StringWrapper.charCodeAt(input, index);
peek = input.charCodeAt(index);
}

@@ -172,3 +171,3 @@ }

case chars.$CARET:
return this.scanOperator(start, StringWrapper.fromCharCode(peek));
return this.scanOperator(start, String.fromCharCode(peek));
case chars.$QUESTION:

@@ -178,6 +177,6 @@ return this.scanComplexOperator(start, '?', chars.$PERIOD, '.');

case chars.$GT:
return this.scanComplexOperator(start, StringWrapper.fromCharCode(peek), chars.$EQ, '=');
return this.scanComplexOperator(start, String.fromCharCode(peek), chars.$EQ, '=');
case chars.$BANG:
case chars.$EQ:
return this.scanComplexOperator(start, StringWrapper.fromCharCode(peek), chars.$EQ, '=', chars.$EQ, '=');
return this.scanComplexOperator(start, String.fromCharCode(peek), chars.$EQ, '=', chars.$EQ, '=');
case chars.$AMPERSAND:

@@ -193,3 +192,3 @@ return this.scanComplexOperator(start, '&', chars.$AMPERSAND, '&');

this.advance();
return this.error("Unexpected character [" + StringWrapper.fromCharCode(peek) + "]", 0);
return this.error("Unexpected character [" + String.fromCharCode(peek) + "]", 0);
};

@@ -294,3 +293,3 @@ _Scanner.prototype.scanCharacter = function (start, code) {

}
buffer.add(StringWrapper.fromCharCode(unescapedCode));
buffer.add(String.fromCharCode(unescapedCode));
marker = this.index;

@@ -297,0 +296,0 @@ }

@@ -7,3 +7,4 @@ import { InterpolationConfig } from '../ml_parser/interpolation_config';

expressions: string[];
constructor(strings: string[], expressions: string[]);
offsets: number[];
constructor(strings: string[], expressions: string[], offsets: number[]);
}

@@ -38,5 +39,7 @@ export declare class TemplateBindingParseResult {

location: any;
tokens: any[];
tokens: Token[];
inputLength: number;
parseAction: boolean;
private errors;
private offset;
private rparensExpected;

@@ -46,3 +49,3 @@ private rbracketsExpected;

index: number;
constructor(input: string, location: any, tokens: any[], parseAction: boolean, errors: ParserError[]);
constructor(input: string, location: any, tokens: Token[], inputLength: number, parseAction: boolean, errors: ParserError[], offset: number);
peek(offset: number): Token;

@@ -49,0 +52,0 @@ next: Token;

@@ -10,3 +10,3 @@ /**

import * as chars from '../chars';
import { StringWrapper, escapeRegExp, isBlank, isPresent } from '../facade/lang';
import { escapeRegExp, isBlank, isPresent } from '../facade/lang';
import { DEFAULT_INTERPOLATION_CONFIG } from '../ml_parser/interpolation_config';

@@ -16,5 +16,6 @@ import { ASTWithSource, Binary, BindingPipe, Chain, Conditional, EmptyExpr, FunctionCall, ImplicitReceiver, Interpolation, KeyedRead, KeyedWrite, LiteralArray, LiteralMap, LiteralPrimitive, MethodCall, ParseSpan, ParserError, PrefixNot, PropertyRead, PropertyWrite, Quote, SafeMethodCall, SafePropertyRead, TemplateBinding } from './ast';

export var SplitInterpolation = (function () {
function SplitInterpolation(strings, expressions) {
function SplitInterpolation(strings, expressions, offsets) {
this.strings = strings;
this.expressions = expressions;
this.offsets = offsets;
}

@@ -43,4 +44,6 @@ return SplitInterpolation;

this._checkNoInterpolation(input, location, interpolationConfig);
var sourceToLex = this._stripComments(input);
var tokens = this._lexer.tokenize(this._stripComments(input));
var ast = new _ParseAST(input, location, tokens, true, this.errors).parseChain();
var ast = new _ParseAST(input, location, tokens, sourceToLex.length, true, this.errors, input.length - sourceToLex.length)
.parseChain();
return new ASTWithSource(ast, input, location, this.errors);

@@ -72,4 +75,6 @@ };

this._checkNoInterpolation(input, location, interpolationConfig);
var tokens = this._lexer.tokenize(this._stripComments(input));
return new _ParseAST(input, location, tokens, false, this.errors).parseChain();
var sourceToLex = this._stripComments(input);
var tokens = this._lexer.tokenize(sourceToLex);
return new _ParseAST(input, location, tokens, sourceToLex.length, false, this.errors, input.length - sourceToLex.length)
.parseChain();
};

@@ -90,3 +95,4 @@ Parser.prototype._parseQuote = function (input, location) {

var tokens = this._lexer.tokenize(input);
return new _ParseAST(input, location, tokens, false, this.errors).parseTemplateBindings();
return new _ParseAST(input, location, tokens, input.length, false, this.errors, 0)
.parseTemplateBindings();
};

@@ -100,4 +106,7 @@ Parser.prototype.parseInterpolation = function (input, location, interpolationConfig) {

for (var i = 0; i < split.expressions.length; ++i) {
var expressionText = split.expressions[i];
var sourceToLex = this._stripComments(expressionText);
var tokens = this._lexer.tokenize(this._stripComments(split.expressions[i]));
var ast = new _ParseAST(input, location, tokens, false, this.errors).parseChain();
var ast = new _ParseAST(input, location, tokens, sourceToLex.length, false, this.errors, split.offsets[i] + (expressionText.length - sourceToLex.length))
.parseChain();
expressions.push(ast);

@@ -110,3 +119,3 @@ }

var regexp = _createInterpolateRegExp(interpolationConfig);
var parts = StringWrapper.split(input, regexp);
var parts = input.split(regexp);
if (parts.length <= 1) {

@@ -117,2 +126,4 @@ return null;

var expressions = [];
var offsets = [];
var offset = 0;
for (var i = 0; i < parts.length; i++) {

@@ -123,5 +134,9 @@ var part = parts[i];

strings.push(part);
offset += part.length;
}
else if (part.trim().length > 0) {
offset += interpolationConfig.start.length;
expressions.push(part);
offsets.push(offset);
offset += part.length + interpolationConfig.end.length;
}

@@ -132,3 +147,3 @@ else {

}
return new SplitInterpolation(strings, expressions);
return new SplitInterpolation(strings, expressions, offsets);
};

@@ -145,4 +160,4 @@ Parser.prototype.wrapLiteralPrimitive = function (input, location) {

for (var i = 0; i < input.length - 1; i++) {
var char = StringWrapper.charCodeAt(input, i);
var nextChar = StringWrapper.charCodeAt(input, i + 1);
var char = input.charCodeAt(i);
var nextChar = input.charCodeAt(i + 1);
if (char === chars.$SLASH && nextChar == chars.$SLASH && isBlank(outerQuote))

@@ -161,3 +176,3 @@ return i;

var regexp = _createInterpolateRegExp(interpolationConfig);
var parts = StringWrapper.split(input, regexp);
var parts = input.split(regexp);
if (parts.length > 1) {

@@ -186,8 +201,10 @@ this._reportError("Got interpolation (" + interpolationConfig.start + interpolationConfig.end + ") where expression was expected", input, "at column " + this._findInterpolationErrorColumn(parts, 1, interpolationConfig) + " in", location);

export var _ParseAST = (function () {
function _ParseAST(input, location, tokens, parseAction, errors) {
function _ParseAST(input, location, tokens, inputLength, parseAction, errors, offset) {
this.input = input;
this.location = location;
this.tokens = tokens;
this.inputLength = inputLength;
this.parseAction = parseAction;
this.errors = errors;
this.offset = offset;
this.rparensExpected = 0;

@@ -209,3 +226,4 @@ this.rbracketsExpected = 0;

get: function () {
return (this.index < this.tokens.length) ? this.next.index : this.input.length;
return (this.index < this.tokens.length) ? this.next.index + this.offset :
this.inputLength + this.offset;
},

@@ -230,3 +248,3 @@ enumerable: true,

return;
this.error("Missing expected " + StringWrapper.fromCharCode(code));
this.error("Missing expected " + String.fromCharCode(code));
};

@@ -300,3 +318,3 @@ _ParseAST.prototype.optionalOperator = function (op) {

}
result = new BindingPipe(this.span(result.span.start), result, name, args);
result = new BindingPipe(this.span(result.span.start - this.offset), result, name, args);
} while (this.optionalOperator('|'));

@@ -303,0 +321,0 @@ }

@@ -47,16 +47,2 @@

export declare function stringify(token: any): string;
export declare class StringWrapper {
static fromCharCode(code: number): string;
static charCodeAt(s: string, index: number): number;
static split(s: string, regExp: RegExp): string[];
static equals(s: string, s2: string): boolean;
static stripLeft(s: string, charVal: string): string;
static stripRight(s: string, charVal: string): string;
static replace(s: string, from: string, replace: string): string;
static replaceAll(s: string, from: RegExp, replace: string): string;
static slice<T>(s: string, from?: number, to?: number): string;
static replaceAllMapped(s: string, from: RegExp, cb: (m: string[]) => string): string;
static contains(s: string, substr: string): boolean;
static compare(a: string, b: string): number;
}
export declare class StringJoiner {

@@ -63,0 +49,0 @@ parts: string[];

@@ -89,70 +89,2 @@ /**

}
export var StringWrapper = (function () {
function StringWrapper() {
}
StringWrapper.fromCharCode = function (code) { return String.fromCharCode(code); };
StringWrapper.charCodeAt = function (s, index) { return s.charCodeAt(index); };
StringWrapper.split = function (s, regExp) { return s.split(regExp); };
StringWrapper.equals = function (s, s2) { return s === s2; };
StringWrapper.stripLeft = function (s, charVal) {
if (s && s.length) {
var pos = 0;
for (var i = 0; i < s.length; i++) {
if (s[i] != charVal)
break;
pos++;
}
s = s.substring(pos);
}
return s;
};
StringWrapper.stripRight = function (s, charVal) {
if (s && s.length) {
var pos = s.length;
for (var i = s.length - 1; i >= 0; i--) {
if (s[i] != charVal)
break;
pos--;
}
s = s.substring(0, pos);
}
return s;
};
StringWrapper.replace = function (s, from, replace) {
return s.replace(from, replace);
};
StringWrapper.replaceAll = function (s, from, replace) {
return s.replace(from, replace);
};
StringWrapper.slice = function (s, from, to) {
if (from === void 0) { from = 0; }
if (to === void 0) { to = null; }
return s.slice(from, to === null ? undefined : to);
};
StringWrapper.replaceAllMapped = function (s, from, cb) {
return s.replace(from, function () {
var matches = [];
for (var _i = 0; _i < arguments.length; _i++) {
matches[_i - 0] = arguments[_i];
}
// Remove offset & string from the result array
matches.splice(-2, 2);
// The callback receives match, p1, ..., pn
return cb(matches);
});
};
StringWrapper.contains = function (s, substr) { return s.indexOf(substr) != -1; };
StringWrapper.compare = function (a, b) {
if (a < b) {
return -1;
}
else if (a > b) {
return 1;
}
else {
return 0;
}
};
return StringWrapper;
}());
export var StringJoiner = (function () {

@@ -159,0 +91,0 @@ function StringJoiner(parts) {

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":61,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBoolean":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":80,"character":9},"right":"boolean"}},"isNumber":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":84,"character":9},"right":"number"}},"isString":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":88,"character":9},"right":"string"}},"isFunction":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":92,"character":9},"right":"function"}},"isType":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isFunction"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":100,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isStringMap"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isArray":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Array"},"member":"isArray"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"RegExp":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":265,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":265,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"getMapKey":{"__symbolic":"function","parameters":["value"],"value":{"__symbolic":"reference","name":"value"}},"normalizeBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":null,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"normalizeBool":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":false,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":283,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":283,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"hasConstructor":{"__symbolic":"function","parameters":["value","type"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"value"},"member":"constructor"},"right":{"__symbolic":"reference","name":"type"}}},"escape":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":367,"character":19}}}}
{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":61,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBoolean":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":80,"character":9},"right":"boolean"}},"isNumber":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":84,"character":9},"right":"number"}},"isString":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":88,"character":9},"right":"string"}},"isFunction":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":92,"character":9},"right":"function"}},"isType":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isFunction"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":100,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isStringMap"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isArray":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Array"},"member":"isArray"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"RegExp":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":198,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":198,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"getMapKey":{"__symbolic":"function","parameters":["value"],"value":{"__symbolic":"reference","name":"value"}},"normalizeBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":null,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"normalizeBool":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":false,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":216,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":216,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"hasConstructor":{"__symbolic":"function","parameters":["value","type"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"value"},"member":"constructor"},"right":{"__symbolic":"reference","name":"type"}}},"escape":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":300,"character":19}}}}

@@ -41,3 +41,4 @@ /**

sourceSpan: ParseSourceSpan;
constructor(name: string, value: string, sourceSpan: ParseSourceSpan);
valueSpan: ParseSourceSpan;
constructor(name: string, value: string, sourceSpan: ParseSourceSpan, valueSpan?: ParseSourceSpan);
visit(visitor: Visitor, context: any): any;

@@ -62,2 +63,3 @@ }

export interface Visitor {
visit?(node: Node, context: any): any;
visitElement(element: Element, context: any): any;

@@ -64,0 +66,0 @@ visitAttribute(attribute: Attribute, context: any): any;

@@ -39,6 +39,7 @@ /**

export var Attribute = (function () {
function Attribute(name, value, sourceSpan) {
function Attribute(name, value, sourceSpan, valueSpan) {
this.name = name;
this.value = value;
this.sourceSpan = sourceSpan;
this.valueSpan = valueSpan;
}

@@ -71,4 +72,7 @@ Attribute.prototype.visit = function (visitor, context) { return visitor.visitAttribute(this, context); };

var result = [];
var visit = visitor.visit ?
function (ast) { return visitor.visit(ast, context) || ast.visit(visitor, context); } :
function (ast) { return ast.visit(visitor, context); };
nodes.forEach(function (ast) {
var astResult = ast.visit(visitor, context);
var astResult = visit(ast);
if (astResult) {

@@ -75,0 +79,0 @@ result.push(astResult);

@@ -294,2 +294,3 @@ /**

var value = '';
var valueSpan;
if (this._peek.type === lex.TokenType.ATTR_VALUE) {

@@ -299,4 +300,5 @@ var valueToken = this._advance();

end = valueToken.sourceSpan.end;
valueSpan = valueToken.sourceSpan;
}
return new html.Attribute(fullName, value, new ParseSourceSpan(attrName.sourceSpan.start, end));
return new html.Attribute(fullName, value, new ParseSourceSpan(attrName.sourceSpan.start, end), valueSpan);
};

@@ -303,0 +305,0 @@ _TreeBuilder.prototype._getParentElement = function () {

@@ -132,3 +132,3 @@ /**

else if (isPresent(provider.useFactory)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
var deps = provider.deps || provider.useFactory.diDeps;
var depsExpr = deps.map(function (dep) { return _this._getDependency(dep); });

@@ -138,3 +138,3 @@ result = o.importExpr(provider.useFactory).callFn(depsExpr);

else if (isPresent(provider.useClass)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
var deps = provider.deps || provider.useClass.diDeps;
var depsExpr = deps.map(function (dep) { return _this._getDependency(dep); });

@@ -141,0 +141,0 @@ result =

@@ -16,4 +16,6 @@ import { CompileNgModuleMetadata, StaticSymbol } from './compile_metadata';

ngModuleByComponent: Map<StaticSymbol, CompileNgModuleMetadata>;
constructor(ngModuleByComponent: Map<StaticSymbol, CompileNgModuleMetadata>);
ngModules: CompileNgModuleMetadata[];
constructor(ngModuleByComponent: Map<StaticSymbol, CompileNgModuleMetadata>, ngModules: CompileNgModuleMetadata[]);
}
export declare function analyzeModules(ngModules: StaticSymbol[], metadataResolver: CompileMetadataResolver): NgModulesSummary;
export declare class OfflineCompiler {

@@ -20,0 +22,0 @@ private _metadataResolver;

@@ -22,7 +22,22 @@ /**

export var NgModulesSummary = (function () {
function NgModulesSummary(ngModuleByComponent) {
function NgModulesSummary(ngModuleByComponent, ngModules) {
this.ngModuleByComponent = ngModuleByComponent;
this.ngModules = ngModules;
}
return NgModulesSummary;
}());
export function analyzeModules(ngModules, metadataResolver) {
var ngModuleByComponent = new Map();
var modules = [];
ngModules.forEach(function (ngModule) {
var ngModuleMeta = metadataResolver.getNgModuleMetadata(ngModule);
modules.push(ngModuleMeta);
ngModuleMeta.declaredDirectives.forEach(function (dirMeta) {
if (dirMeta.isComponent) {
ngModuleByComponent.set(dirMeta.type.reference, ngModuleMeta);
}
});
});
return new NgModulesSummary(ngModuleByComponent, modules);
}
export var OfflineCompiler = (function () {

@@ -43,13 +58,3 @@ function OfflineCompiler(_metadataResolver, _directiveNormalizer, _templateParser, _styleCompiler, _viewCompiler, _ngModuleCompiler, _outputEmitter, _localeId, _translationFormat) {

OfflineCompiler.prototype.analyzeModules = function (ngModules) {
var _this = this;
var ngModuleByComponent = new Map();
ngModules.forEach(function (ngModule) {
var ngModuleMeta = _this._metadataResolver.getNgModuleMetadata(ngModule);
ngModuleMeta.declaredDirectives.forEach(function (dirMeta) {
if (dirMeta.isComponent) {
ngModuleByComponent.set(dirMeta.type.reference, ngModuleMeta);
}
});
});
return new NgModulesSummary(ngModuleByComponent);
return analyzeModules(ngModules, this._metadataResolver);
};

@@ -56,0 +61,0 @@ OfflineCompiler.prototype.clearCache = function () {

@@ -59,5 +59,5 @@ import * as o from './output_ast';

visitAllExpressions(expressions: o.Expression[], ctx: EmitterVisitorContext, separator: string, newLine?: boolean): void;
visitAllObjects(handler: Function, expressions: any, ctx: EmitterVisitorContext, separator: string, newLine?: boolean): void;
visitAllObjects<T>(handler: (t: T) => void, expressions: T[], ctx: EmitterVisitorContext, separator: string, newLine?: boolean): void;
visitAllStatements(statements: o.Statement[], ctx: EmitterVisitorContext): void;
}
export declare function escapeIdentifier(input: string, escapeDollar: boolean, alwaysQuote?: boolean): any;

@@ -8,3 +8,3 @@ /**

*/
import { StringWrapper, isBlank, isPresent, isString } from '../facade/lang';
import { isBlank, isPresent, isString } from '../facade/lang';
import * as o from './output_ast';

@@ -356,3 +356,3 @@ var _SINGLE_QUOTE_ESCAPE_STRING_RE = /'|\\|\n|\r|\$/g;

ctx.incIndent();
this.visitAllObjects(function (entry /** TODO #9100 */) {
this.visitAllObjects(function (entry) {
ctx.print(escapeIdentifier(entry[0], _this._escapeDollarInStrings, false) + ": ");

@@ -368,3 +368,3 @@ entry[1].visitExpression(_this, ctx);

if (newLine === void 0) { newLine = false; }
this.visitAllObjects(function (expr /** TODO #9100 */) { return expr.visitExpression(_this, ctx); }, expressions, ctx, separator, newLine);
this.visitAllObjects(function (expr) { return expr.visitExpression(_this, ctx); }, expressions, ctx, separator, newLine);
};

@@ -394,3 +394,7 @@ AbstractEmitterVisitor.prototype.visitAllObjects = function (handler, expressions, ctx, separator, newLine) {

}
var body = StringWrapper.replaceAllMapped(input, _SINGLE_QUOTE_ESCAPE_STRING_RE, function (match /** TODO #9100 */) {
var body = input.replace(_SINGLE_QUOTE_ESCAPE_STRING_RE, function () {
var match = [];
for (var _i = 0; _i < arguments.length; _i++) {
match[_i - 0] = arguments[_i];
}
if (match[0] == '$') {

@@ -397,0 +401,0 @@ return escapeDollar ? '\\$' : '$';

@@ -147,3 +147,3 @@ /**

AbstractJsEmitterVisitor.prototype._visitParams = function (params, ctx) {
this.visitAllObjects(function (param /** TODO #9100 */) { return ctx.print(param.name); }, params, ctx, ',');
this.visitAllObjects(function (param) { return ctx.print(param.name); }, params, ctx, ',');
};

@@ -150,0 +150,0 @@ AbstractJsEmitterVisitor.prototype.getBuiltinMethodName = function (method) {

@@ -231,5 +231,5 @@ /**

export declare class LiteralMapExpr extends Expression {
entries: Array<Array<string | Expression>>;
entries: [string, Expression][];
valueType: Type;
constructor(entries: Array<Array<string | Expression>>, type?: MapType);
constructor(entries: [string, Expression][], type?: MapType);
visitExpression(visitor: ExpressionVisitor, context: any): any;

@@ -430,5 +430,5 @@ }

export declare function literalArr(values: Expression[], type?: Type): LiteralArrayExpr;
export declare function literalMap(values: Array<Array<string | Expression>>, type?: MapType): LiteralMapExpr;
export declare function literalMap(values: [string, Expression][], type?: MapType): LiteralMapExpr;
export declare function not(expr: Expression): NotExpr;
export declare function fn(params: FnParam[], body: Statement[], type?: Type): FunctionExpr;
export declare function literal(value: any, type?: Type): LiteralExpr;

@@ -217,3 +217,3 @@ /**

if (type === void 0) { type = null; }
_super.call(this, isPresent(type) ? type : value.type);
_super.call(this, type || value.type);
this.name = name;

@@ -236,3 +236,3 @@ this.value = value;

if (type === void 0) { type = null; }
_super.call(this, isPresent(type) ? type : value.type);
_super.call(this, type || value.type);
this.receiver = receiver;

@@ -251,3 +251,3 @@ this.index = index;

if (type === void 0) { type = null; }
_super.call(this, isPresent(type) ? type : value.type);
_super.call(this, type || value.type);
this.receiver = receiver;

@@ -345,3 +345,3 @@ this.name = name;

if (type === void 0) { type = null; }
_super.call(this, isPresent(type) ? type : trueCase.type);
_super.call(this, type || trueCase.type);
this.condition = condition;

@@ -407,3 +407,3 @@ this.falseCase = falseCase;

if (type === void 0) { type = null; }
_super.call(this, isPresent(type) ? type : lhs.type);
_super.call(this, type || lhs.type);
this.operator = operator;

@@ -508,3 +508,3 @@ this.rhs = rhs;

this.value = value;
this.type = isPresent(type) ? type : value.type;
this.type = type || value.type;
}

@@ -678,3 +678,3 @@ DeclareVarStmt.prototype.visitStatement = function (visitor, context) {

ExpressionTransformer.prototype.visitInvokeMethodExpr = function (ast, context) {
var method = isPresent(ast.builtin) ? ast.builtin : ast.name;
var method = ast.builtin || ast.name;
return new InvokeMethodExpr(ast.receiver.visitExpression(this, context), method, this.visitAllExpressions(ast.args, context), ast.type);

@@ -717,3 +717,4 @@ };

var _this = this;
return new LiteralMapExpr(ast.entries.map(function (entry) { return [entry[0], entry[1].visitExpression(_this, context)]; }));
var entries = ast.entries.map(function (entry) { return [entry[0], entry[1].visitExpression(_this, context),]; });
return new LiteralMapExpr(entries);
};

@@ -720,0 +721,0 @@ ExpressionTransformer.prototype.visitAllExpressions = function (exprs, context) {

@@ -298,3 +298,3 @@ /**

var _this = this;
this.visitAllObjects(function (param /** TODO #9100 */) {
this.visitAllObjects(function (param) {
ctx.print(param.name);

@@ -328,3 +328,3 @@ ctx.print(':');

ctx.print("<");
this.visitAllObjects(function (type /** TODO #9100 */) { return type.visitType(_this, ctx); }, typeParams, ctx, ',');
this.visitAllObjects(function (type) { return type.visitType(_this, ctx); }, typeParams, ctx, ',');
ctx.print(">");

@@ -331,0 +331,0 @@ }

@@ -107,3 +107,3 @@ /**

this._getQueriesFor(token).forEach(function (query) {
var queryReadToken = isPresent(query.read) ? query.read : token;
var queryReadToken = query.read || token;
if (isBlank(queryReadTokens.get(queryReadToken.reference))) {

@@ -170,3 +170,3 @@ queryReadTokens.set(queryReadToken.reference, true);

else if (isPresent(provider.useFactory)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
var deps = provider.deps || provider.useFactory.diDeps;
transformedDeps =

@@ -176,3 +176,3 @@ deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep, eager); });

else if (isPresent(provider.useClass)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
var deps = provider.deps || provider.useClass.diDeps;
transformedDeps =

@@ -327,3 +327,3 @@ deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep, eager); });

else if (isPresent(provider.useFactory)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
var deps = provider.deps || provider.useFactory.diDeps;
transformedDeps =

@@ -333,3 +333,3 @@ deps.map(function (dep) { return _this._getDependency(dep, eager, resolvedProvider.sourceSpan); });

else if (isPresent(provider.useClass)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
var deps = provider.deps || provider.useClass.diDeps;
transformedDeps =

@@ -336,0 +336,0 @@ deps.map(function (dep) { return _this._getDependency(dep, eager, resolvedProvider.sourceSpan); });

@@ -378,3 +378,4 @@ /**

var replaceBy_1 = this.strictStyling ? "[" + hostSelector + "]" : scopeSelector;
return selector.replace(_polyfillHostNoCombinatorRe, function (hnc, selector) { return selector + replaceBy_1; })
return selector
.replace(_polyfillHostNoCombinatorRe, function (hnc, selector) { return selector[0] === ':' ? replaceBy_1 + selector : selector + replaceBy_1; })
.replace(_polyfillHostRe, replaceBy_1 + ' ');

@@ -381,0 +382,0 @@ }

@@ -8,3 +8,3 @@ /**

*/
import { StringWrapper, isBlank, isPresent } from './facade/lang';
import { isBlank } from './facade/lang';
export var StyleWithImports = (function () {

@@ -29,4 +29,8 @@ function StyleWithImports(style, styleUrls) {

var foundUrls = [];
var modifiedCssText = StringWrapper.replaceAllMapped(cssText, _cssImportRe, function (m) {
var url = isPresent(m[1]) ? m[1] : m[2];
var modifiedCssText = cssText.replace(_cssImportRe, function () {
var m = [];
for (var _i = 0; _i < arguments.length; _i++) {
m[_i - 0] = arguments[_i];
}
var url = m[1] || m[2];
if (!isStyleUrlResolvable(url)) {

@@ -33,0 +37,0 @@ // Do not attempt to resolve non-package absolute URLs with URI scheme

@@ -121,3 +121,4 @@ /**

sourceSpan: ParseSourceSpan;
constructor(name: string, attrs: AttrAst[], inputs: BoundElementPropertyAst[], outputs: BoundEventAst[], references: ReferenceAst[], directives: DirectiveAst[], providers: ProviderAst[], hasViewContainer: boolean, children: TemplateAst[], ngContentIndex: number, sourceSpan: ParseSourceSpan);
endSourceSpan: ParseSourceSpan;
constructor(name: string, attrs: AttrAst[], inputs: BoundElementPropertyAst[], outputs: BoundEventAst[], references: ReferenceAst[], directives: DirectiveAst[], providers: ProviderAst[], hasViewContainer: boolean, children: TemplateAst[], ngContentIndex: number, sourceSpan: ParseSourceSpan, endSourceSpan: ParseSourceSpan);
visit(visitor: TemplateAstVisitor, context: any): any;

@@ -225,2 +226,3 @@ }

export interface TemplateAstVisitor {
visit?(ast: TemplateAst, context: any): any;
visitNgContent(ast: NgContentAst, context: any): any;

@@ -227,0 +229,0 @@ visitEmbeddedTemplate(ast: EmbeddedTemplateAst, context: any): any;

@@ -8,3 +8,2 @@ /**

*/
import { isPresent } from '../facade/lang';
/**

@@ -88,3 +87,3 @@ * A segment of text within the template.

get: function () {
if (isPresent(this.target)) {
if (this.target) {
return this.target + ":" + this.name;

@@ -138,3 +137,3 @@ }

export var ElementAst = (function () {
function ElementAst(name, attrs, inputs, outputs, references, directives, providers, hasViewContainer, children, ngContentIndex, sourceSpan) {
function ElementAst(name, attrs, inputs, outputs, references, directives, providers, hasViewContainer, children, ngContentIndex, sourceSpan, endSourceSpan) {
this.name = name;

@@ -151,2 +150,3 @@ this.attrs = attrs;

this.sourceSpan = sourceSpan;
this.endSourceSpan = endSourceSpan;
}

@@ -283,5 +283,8 @@ ElementAst.prototype.visit = function (visitor, context) {

var result = [];
var visit = visitor.visit ?
function (ast) { return visitor.visit(ast, context) || ast.visit(visitor, context); } :
function (ast) { return ast.visit(visitor, context); };
asts.forEach(function (ast) {
var astResult = ast.visit(visitor, context);
if (isPresent(astResult)) {
var astResult = visit(ast);
if (astResult) {
result.push(astResult);

@@ -288,0 +291,0 @@ }

@@ -13,2 +13,4 @@ /**

import { I18NHtmlParser } from '../i18n/i18n_html_parser';
import { ParseTreeResult } from '../ml_parser/html_parser';
import { InterpolationConfig } from '../ml_parser/interpolation_config';
import { ParseError, ParseErrorLevel, ParseSourceSpan } from '../parse_util';

@@ -43,2 +45,5 @@ import { Console } from '../private_import_core';

tryParse(component: CompileDirectiveMetadata, template: string, directives: CompileDirectiveMetadata[], pipes: CompilePipeMetadata[], schemas: SchemaMetadata[], templateUrl: string): TemplateParseResult;
tryParseHtml(htmlAstWithErrors: ParseTreeResult, component: CompileDirectiveMetadata, template: string, directives: CompileDirectiveMetadata[], pipes: CompilePipeMetadata[], schemas: SchemaMetadata[], templateUrl: string): TemplateParseResult;
expandHtml(htmlAstWithErrors: ParseTreeResult, forced?: boolean): ParseTreeResult;
getInterpolationConfig(component: CompileDirectiveMetadata): InterpolationConfig;
}

@@ -45,0 +50,0 @@ export declare function splitClasses(classAttrValue: string): string[];

@@ -109,15 +109,7 @@ /**

TemplateParser.prototype.tryParse = function (component, template, directives, pipes, schemas, templateUrl) {
var interpolationConfig;
if (component.template) {
interpolationConfig = InterpolationConfig.fromArray(component.template.interpolation);
}
var htmlAstWithErrors = this._htmlParser.parse(template, templateUrl, true, interpolationConfig);
return this.tryParseHtml(this.expandHtml(this._htmlParser.parse(template, templateUrl, true, this.getInterpolationConfig(component))), component, template, directives, pipes, schemas, templateUrl);
};
TemplateParser.prototype.tryParseHtml = function (htmlAstWithErrors, component, template, directives, pipes, schemas, templateUrl) {
var result;
var errors = htmlAstWithErrors.errors;
var result;
if (errors.length == 0) {
// Transform ICU messages to angular directives
var expandedHtmlAst = expandNodes(htmlAstWithErrors.rootNodes);
errors.push.apply(errors, expandedHtmlAst.errors);
htmlAstWithErrors = new ParseTreeResult(expandedHtmlAst.nodes, errors);
}
if (htmlAstWithErrors.rootNodes.length > 0) {

@@ -143,2 +135,18 @@ var uniqDirectives = removeIdentifierDuplicates(directives);

};
TemplateParser.prototype.expandHtml = function (htmlAstWithErrors, forced) {
if (forced === void 0) { forced = false; }
var errors = htmlAstWithErrors.errors;
if (errors.length == 0 || forced) {
// Transform ICU messages to angular directives
var expandedHtmlAst = expandNodes(htmlAstWithErrors.rootNodes);
errors.push.apply(errors, expandedHtmlAst.errors);
htmlAstWithErrors = new ParseTreeResult(expandedHtmlAst.nodes, errors);
}
return htmlAstWithErrors;
};
TemplateParser.prototype.getInterpolationConfig = function (component) {
if (component.template) {
return InterpolationConfig.fromArray(component.template.interpolation);
}
};
/** @internal */

@@ -368,4 +376,4 @@ TemplateParser.prototype._assertNoReferenceDuplicationOnTemplate = function (result, errors) {

if (preparsedElement.type === PreparsedElementType.NG_CONTENT) {
if (isPresent(element.children) && element.children.length > 0) {
this._reportError("<ng-content> element cannot have content. <ng-content> must be immediately followed by </ng-content>", element.sourceSpan);
if (element.children && !element.children.every(_isEmptyTextNode)) {
this._reportError("<ng-content> element cannot have content.", element.sourceSpan);
}

@@ -383,3 +391,3 @@ parsedElement = new NgContentAst(this.ngContentCount++, hasInlineTemplates ? null : ngContentIndex, element.sourceSpan);

var ngContentIndex_1 = hasInlineTemplates ? null : parent.findNgContentIndex(projectionSelector);
parsedElement = new ElementAst(nodeName, attrs, elementProps, events, references, providerContext.transformedDirectiveAsts, providerContext.transformProviders, providerContext.transformedHasViewContainer, children, hasInlineTemplates ? null : ngContentIndex_1, element.sourceSpan);
parsedElement = new ElementAst(nodeName, attrs, elementProps, events, references, providerContext.transformedDirectiveAsts, providerContext.transformProviders, providerContext.transformedHasViewContainer, children, hasInlineTemplates ? null : ngContentIndex_1, element.sourceSpan, element.endSourceSpan);
this._findComponentDirectives(directiveAsts)

@@ -878,3 +886,3 @@ .forEach(function (componentDirectiveAst) { return _this._validateElementAnimationInputOutputs(componentDirectiveAst.hostProperties, componentDirectiveAst.hostEvents, componentDirectiveAst.directive.template); });

var children = html.visitAll(this, ast.children, EMPTY_ELEMENT_CONTEXT);
return new ElementAst(ast.name, html.visitAll(this, ast.attrs), [], [], [], [], [], false, children, ngContentIndex, ast.sourceSpan);
return new ElementAst(ast.name, html.visitAll(this, ast.attrs), [], [], [], [], [], false, children, ngContentIndex, ast.sourceSpan, ast.endSourceSpan);
};

@@ -984,2 +992,5 @@ NonBindableVisitor.prototype.visitComment = function (comment, context) { return null; };

}
function _isEmptyTextNode(node) {
return node instanceof html.Text && node.value.trim().length == 0;
}
//# sourceMappingURL=template_parser.js.map

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":1,"metadata":{"TEMPLATE_TRANSFORMS":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"OpaqueToken"},"arguments":["TemplateTransforms"]},"TemplateParser":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Optional"}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject"},"arguments":[{"__symbolic":"reference","name":"TEMPLATE_TRANSFORMS"}]}]],"parameters":[{"__symbolic":"reference","module":"../expression_parser/parser","name":"Parser"},{"__symbolic":"reference","module":"../schema/element_schema_registry","name":"ElementSchemaRegistry"},{"__symbolic":"reference","module":"../i18n/i18n_html_parser","name":"I18NHtmlParser"},{"__symbolic":"reference","module":"../private_import_core","name":"Console"},{"__symbolic":"reference","name":"Array","arguments":[{"__symbolic":"reference","module":"./template_ast","name":"TemplateAstVisitor"}]}]}],"parse":[{"__symbolic":"method"}],"tryParse":[{"__symbolic":"method"}],"_assertNoReferenceDuplicationOnTemplate":[{"__symbolic":"method"}]}},"splitClasses":{"__symbolic":"function","parameters":["classAttrValue"],"value":{"__symbolic":"error","message":"Expression form not supported","line":1114,"character":37}}}}
{"__symbolic":"module","version":1,"metadata":{"TEMPLATE_TRANSFORMS":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"OpaqueToken"},"arguments":["TemplateTransforms"]},"TemplateParser":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Optional"}},{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject"},"arguments":[{"__symbolic":"reference","name":"TEMPLATE_TRANSFORMS"}]}]],"parameters":[{"__symbolic":"reference","module":"../expression_parser/parser","name":"Parser"},{"__symbolic":"reference","module":"../schema/element_schema_registry","name":"ElementSchemaRegistry"},{"__symbolic":"reference","module":"../i18n/i18n_html_parser","name":"I18NHtmlParser"},{"__symbolic":"reference","module":"../private_import_core","name":"Console"},{"__symbolic":"reference","name":"Array","arguments":[{"__symbolic":"reference","module":"./template_ast","name":"TemplateAstVisitor"}]}]}],"parse":[{"__symbolic":"method"}],"tryParse":[{"__symbolic":"method"}],"tryParseHtml":[{"__symbolic":"method"}],"expandHtml":[{"__symbolic":"method"}],"getInterpolationConfig":[{"__symbolic":"method"}],"_assertNoReferenceDuplicationOnTemplate":[{"__symbolic":"method"}]}},"splitClasses":{"__symbolic":"function","parameters":["classAttrValue"],"value":{"__symbolic":"error","message":"Expression form not supported","line":1125,"character":37}}}}

@@ -9,3 +9,3 @@ /**

import { Inject, Injectable, PACKAGE_ROOT_URL } from '@angular/core';
import { StringWrapper, isBlank, isPresent } from './facade/lang';
import { isBlank, isPresent } from './facade/lang';
var _ASSET_SCHEME = 'asset:';

@@ -72,4 +72,4 @@ /**

else {
prefix = StringWrapper.stripRight(prefix, '/');
path = StringWrapper.stripLeft(path, '/');
prefix = prefix.replace(/\/+$/, '');
path = path.replace(/^\/+/, '');
return prefix + "/" + path;

@@ -76,0 +76,0 @@ }

@@ -8,3 +8,3 @@ /**

*/
import { StringWrapper, isArray, isBlank, isPresent, isPrimitive, isStrictStringMap } from './facade/lang';
import { isArray, isBlank, isPresent, isPrimitive, isStrictStringMap } from './facade/lang';
import * as o from './output/output_ast';

@@ -14,3 +14,9 @@ export var MODULE_SUFFIX = '';

export function camelCaseToDashCase(input) {
return StringWrapper.replaceAllMapped(input, CAMEL_CASE_REGEXP, function (m) { return '-' + m[1].toLowerCase(); });
return input.replace(CAMEL_CASE_REGEXP, function () {
var m = [];
for (var _i = 0; _i < arguments.length; _i++) {
m[_i - 0] = arguments[_i];
}
return '-' + m[1].toLowerCase();
});
}

@@ -30,3 +36,3 @@ export function splitAtColon(input, defaultValues) {

export function sanitizeIdentifier(name) {
return StringWrapper.replaceAll(name, /\W/g, '_');
return name.replace(/\W/g, '_');
}

@@ -33,0 +39,0 @@ export function visitValue(value, visitor, context) {

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":1,"metadata":{"MODULE_SUFFIX":"","camelCaseToDashCase":{"__symbolic":"function","parameters":["input"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":14,"character":4,"context":{"name":"CAMEL_CASE_REGEXP"}}},"splitAtColon":{"__symbolic":"function","parameters":["input","defaultValues"],"value":{"__symbolic":"error","message":"Reference to a non-exported function","line":29,"character":9,"context":{"name":"_splitAt"}}},"splitAtPeriod":{"__symbolic":"function","parameters":["input","defaultValues"],"value":{"__symbolic":"error","message":"Reference to a non-exported function","line":29,"character":9,"context":{"name":"_splitAt"}}},"sanitizeIdentifier":{"__symbolic":"function","parameters":["name"],"value":{"__symbolic":"error","message":"Expression form not supported","line":36,"character":40}}}}
{"__symbolic":"module","version":1,"metadata":{"MODULE_SUFFIX":"","camelCaseToDashCase":{"__symbolic":"function","parameters":["input"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":14,"character":4,"context":{"name":"CAMEL_CASE_REGEXP"}}},"splitAtColon":{"__symbolic":"function","parameters":["input","defaultValues"],"value":{"__symbolic":"error","message":"Reference to a non-exported function","line":28,"character":9,"context":{"name":"_splitAt"}}},"splitAtPeriod":{"__symbolic":"function","parameters":["input","defaultValues"],"value":{"__symbolic":"error","message":"Reference to a non-exported function","line":28,"character":9,"context":{"name":"_splitAt"}}},"sanitizeIdentifier":{"__symbolic":"function","parameters":["name"],"value":{"__symbolic":"error","message":"Expression form not supported","line":35,"character":22}}}}

@@ -136,3 +136,3 @@ /**

else if (isPresent(provider.useFactory)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
var deps = provider.deps || provider.useFactory.diDeps;
var depsExpr = deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep); });

@@ -142,3 +142,3 @@ return o.importExpr(provider.useFactory).callFn(depsExpr);

else if (isPresent(provider.useClass)) {
var deps = isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
var deps = provider.deps || provider.useClass.diDeps;
var depsExpr = deps.map(function (dep) { return _this._getDependency(resolvedProvider.providerType, dep); });

@@ -375,3 +375,3 @@ return o.importExpr(provider.useClass)

this.query = query;
this.read = isPresent(query.meta.read) ? query.meta.read : match;
this.read = query.meta.read || match;
}

@@ -378,0 +378,0 @@ return _QueryWithRead;

@@ -52,3 +52,3 @@ /**

var res = this._updateDebugContext(new _DebugState(nodeIndex, templateAst));
return isPresent(res) ? res : o.NULL_EXPR;
return res || o.NULL_EXPR;
};

@@ -55,0 +55,0 @@ CompileMethod.prototype.resetDebugInfo = function (nodeIndex, templateAst) {

@@ -21,5 +21,5 @@ /**

private _isStatic();
afterChildren(targetStaticMethod: any, targetDynamicMethod: CompileMethod): void;
afterChildren(targetStaticMethod: CompileMethod, targetDynamicMethod: CompileMethod): void;
}
export declare function createQueryList(query: CompileQueryMetadata, directiveInstance: o.Expression, propertyName: string, compileView: CompileView): o.Expression;
export declare function addQueryToTokenMap(map: Map<any, CompileQuery[]>, query: CompileQuery): void;

@@ -57,3 +57,3 @@ /**

};
CompileQuery.prototype.afterChildren = function (targetStaticMethod /** TODO #9100 */, targetDynamicMethod) {
CompileQuery.prototype.afterChildren = function (targetStaticMethod, targetDynamicMethod) {
var values = createQueryValues(this._values);

@@ -60,0 +60,0 @@ var updateStmts = [this.queryList.callMethod('reset', [o.literalArr(values)]).toStmt()];

@@ -66,4 +66,4 @@ /**

createLiteralArray(values: o.Expression[]): o.Expression;
createLiteralMap(entries: Array<Array<string | o.Expression>>): o.Expression;
createLiteralMap(entries: [string, o.Expression][]): o.Expression;
afterNodes(): void;
}

@@ -8,3 +8,3 @@ /**

*/
import { StringWrapper, isPresent } from '../facade/lang';
import { isPresent } from '../facade/lang';
import { identifierToken } from '../identifiers';

@@ -26,3 +26,3 @@ import * as o from '../output/output_ast';

this._methodName =
"_handle_" + santitizeEventName(eventName) + "_" + compileElement.nodeIndex + "_" + listenerIndex;
"_handle_" + sanitizeEventName(eventName) + "_" + compileElement.nodeIndex + "_" + listenerIndex;
this._eventParam = new o.FnParam(EventHandlerVars.event.name, o.importType(this.compileElement.view.genConfig.renderTypes.renderEvent));

@@ -49,4 +49,3 @@ }

this._method.resetDebugInfo(this.compileElement.nodeIndex, hostEvent);
var context = isPresent(directiveInstance) ? directiveInstance :
this.compileElement.view.componentContext;
var context = directiveInstance || this.compileElement.view.componentContext;
var actionStmts = convertCdStatementToIr(this.compileElement.view, context, hostEvent.handler, this.compileElement.nodeIndex);

@@ -162,5 +161,5 @@ var lastIndex = actionStmts.length - 1;

}
function santitizeEventName(name) {
return StringWrapper.replaceAll(name, /[^a-zA-Z_]/g, '_');
function sanitizeEventName(name) {
return name.replace(/[^a-zA-Z_]/g, '_');
}
//# sourceMappingURL=event_binder.js.map

@@ -72,3 +72,2 @@ /**

var currValExpr = createCurrValueExpr(bindingIndex);
var renderMethod;
var oldRenderValue = sanitizedValue(boundProp, fieldExpr);

@@ -75,0 +74,0 @@ var renderValue = sanitizedValue(boundProp, currValExpr);

@@ -11,3 +11,3 @@ /**

import { ListWrapper } from '../facade/collection';
import { StringWrapper, isPresent } from '../facade/lang';
import { isPresent } from '../facade/lang';
import { Identifiers, identifierToken, resolveIdentifier } from '../identifiers';

@@ -71,7 +71,7 @@ import * as o from '../output/output_ast';

if (this.view.viewType !== ViewType.COMPONENT) {
this.view.rootNodesOrAppElements.push(isPresent(vcAppEl) ? vcAppEl : node.renderNode);
this.view.rootNodesOrAppElements.push(vcAppEl || node.renderNode);
}
}
else if (isPresent(parent.component) && isPresent(ngContentIndex)) {
parent.addContentNode(ngContentIndex, isPresent(vcAppEl) ? vcAppEl : node.renderNode);
parent.addContentNode(ngContentIndex, vcAppEl || node.renderNode);
}

@@ -315,3 +315,3 @@ };

// for tests and for caching generated artifacts...
ListWrapper.sort(entryArray, function (entry1, entry2) { return StringWrapper.compare(entry1[0], entry2[0]); });
ListWrapper.sort(entryArray);
return entryArray;

@@ -408,3 +408,5 @@ }

var animationsExpr = o.literalMap(view.animations.map(function (entry) { return [entry.name, entry.fnExp]; }));
initRenderCompTypeStmts = [new o.IfStmt(renderCompTypeVar.identical(o.NULL_EXPR), [renderCompTypeVar
initRenderCompTypeStmts = [
new o.IfStmt(renderCompTypeVar.identical(o.NULL_EXPR), [
renderCompTypeVar
.set(ViewConstructorVars.viewUtils.callMethod('createRenderComponentType', [

@@ -417,7 +419,11 @@ view.genConfig.genDebugInfo ? o.literal(templateUrlInfo) : o.literal(''),

]))
.toStmt()])];
.toStmt(),
]),
];
}
return o
.fn(viewFactoryArgs, initRenderCompTypeStmts.concat([new o.ReturnStatement(o.variable(viewClass.name)
.instantiate(viewClass.constructorMethod.params.map(function (param) { return o.variable(param.name); })))]), o.importType(resolveIdentifier(Identifiers.AppView), [getContextType(view)]))
.fn(viewFactoryArgs, initRenderCompTypeStmts.concat([
new o.ReturnStatement(o.variable(viewClass.name)
.instantiate(viewClass.constructorMethod.params.map(function (param) { return o.variable(param.name); }))),
]), o.importType(resolveIdentifier(Identifiers.AppView), [getContextType(view)]))
.toDeclStmt(view.viewFactory.name, [o.StmtModifier.Final]);

@@ -424,0 +430,0 @@ }

@@ -44,3 +44,3 @@ var __extends = (this && this.__extends) || function (d, b) {

if (isPresent(providerOverrides)) {
var originalViewProviders = isPresent(metadata.providers) ? metadata.providers : [];
var originalViewProviders = metadata.providers || [];
providers = originalViewProviders.concat(providerOverrides);

@@ -51,3 +51,3 @@ }

if (isPresent(viewProviderOverrides)) {
var originalViewProviders = isPresent(metadata.viewProviders) ? metadata.viewProviders : [];
var originalViewProviders = metadata.viewProviders || [];
viewProviders = originalViewProviders.concat(viewProviderOverrides);

@@ -54,0 +54,0 @@ }

@@ -47,16 +47,2 @@

export declare function stringify(token: any): string;
export declare class StringWrapper {
static fromCharCode(code: number): string;
static charCodeAt(s: string, index: number): number;
static split(s: string, regExp: RegExp): string[];
static equals(s: string, s2: string): boolean;
static stripLeft(s: string, charVal: string): string;
static stripRight(s: string, charVal: string): string;
static replace(s: string, from: string, replace: string): string;
static replaceAll(s: string, from: RegExp, replace: string): string;
static slice<T>(s: string, from?: number, to?: number): string;
static replaceAllMapped(s: string, from: RegExp, cb: (m: string[]) => string): string;
static contains(s: string, substr: string): boolean;
static compare(a: string, b: string): number;
}
export declare class StringJoiner {

@@ -63,0 +49,0 @@ parts: string[];

@@ -89,70 +89,2 @@ /**

}
export var StringWrapper = (function () {
function StringWrapper() {
}
StringWrapper.fromCharCode = function (code) { return String.fromCharCode(code); };
StringWrapper.charCodeAt = function (s, index) { return s.charCodeAt(index); };
StringWrapper.split = function (s, regExp) { return s.split(regExp); };
StringWrapper.equals = function (s, s2) { return s === s2; };
StringWrapper.stripLeft = function (s, charVal) {
if (s && s.length) {
var pos = 0;
for (var i = 0; i < s.length; i++) {
if (s[i] != charVal)
break;
pos++;
}
s = s.substring(pos);
}
return s;
};
StringWrapper.stripRight = function (s, charVal) {
if (s && s.length) {
var pos = s.length;
for (var i = s.length - 1; i >= 0; i--) {
if (s[i] != charVal)
break;
pos--;
}
s = s.substring(0, pos);
}
return s;
};
StringWrapper.replace = function (s, from, replace) {
return s.replace(from, replace);
};
StringWrapper.replaceAll = function (s, from, replace) {
return s.replace(from, replace);
};
StringWrapper.slice = function (s, from, to) {
if (from === void 0) { from = 0; }
if (to === void 0) { to = null; }
return s.slice(from, to === null ? undefined : to);
};
StringWrapper.replaceAllMapped = function (s, from, cb) {
return s.replace(from, function () {
var matches = [];
for (var _i = 0; _i < arguments.length; _i++) {
matches[_i - 0] = arguments[_i];
}
// Remove offset & string from the result array
matches.splice(-2, 2);
// The callback receives match, p1, ..., pn
return cb(matches);
});
};
StringWrapper.contains = function (s, substr) { return s.indexOf(substr) != -1; };
StringWrapper.compare = function (a, b) {
if (a < b) {
return -1;
}
else if (a > b) {
return 1;
}
else {
return 0;
}
};
return StringWrapper;
}());
export var StringJoiner = (function () {

@@ -159,0 +91,0 @@ function StringJoiner(parts) {

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":61,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBoolean":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":80,"character":9},"right":"boolean"}},"isNumber":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":84,"character":9},"right":"number"}},"isString":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":88,"character":9},"right":"string"}},"isFunction":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":92,"character":9},"right":"function"}},"isType":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isFunction"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":100,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isStringMap"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isArray":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Array"},"member":"isArray"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"RegExp":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":265,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":265,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"getMapKey":{"__symbolic":"function","parameters":["value"],"value":{"__symbolic":"reference","name":"value"}},"normalizeBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":null,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"normalizeBool":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":false,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":283,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":283,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"hasConstructor":{"__symbolic":"function","parameters":["value","type"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"value"},"member":"constructor"},"right":{"__symbolic":"reference","name":"type"}}},"escape":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":367,"character":19}}}}
{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":61,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBoolean":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":80,"character":9},"right":"boolean"}},"isNumber":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":84,"character":9},"right":"number"}},"isString":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":88,"character":9},"right":"string"}},"isFunction":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":92,"character":9},"right":"function"}},"isType":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isFunction"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":100,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isStringMap"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isArray":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Array"},"member":"isArray"},"arguments":[{"__symbolic":"reference","name":"obj"}]}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"RegExp":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":198,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":198,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"getMapKey":{"__symbolic":"function","parameters":["value"],"value":{"__symbolic":"reference","name":"value"}},"normalizeBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":null,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"normalizeBool":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":false,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":216,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":216,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"hasConstructor":{"__symbolic":"function","parameters":["value","type"],"value":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"value"},"member":"constructor"},"right":{"__symbolic":"reference","name":"type"}}},"escape":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Reference to a local symbol","line":55,"character":4,"context":{"name":"_global"}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":300,"character":19}}}}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc