{"version":3,"file":"cdk-coercion.umd.js","sources":["cdk/coercion.es5.js"],"sourcesContent":["/**\n * @license\n * Copyright Google Inc. All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n/**\n * Coerces a data-bound value (typically a string) to a boolean.\n * @param {?} value\n * @return {?}\n */\nfunction coerceBooleanProperty(value) {\n return value != null && \"\" + value !== 'false';\n}\n\n/**\n * Coerces a data-bound value (typically a string) to a number.\n * @param {?} value\n * @param {?=} fallbackValue\n * @return {?}\n */\nfunction coerceNumberProperty(value, fallbackValue) {\n if (fallbackValue === void 0) { fallbackValue = 0; }\n // parseFloat(value) handles most of the cases we're interested in (it treats null, empty string,\n // and other non-number values as NaN, where Number just uses 0) but it considers the string\n // '123hello' to be a valid number. Therefore we also check if Number(value) is NaN.\n return isNaN(parseFloat(/** @type {?} */ (value))) || isNaN(Number(value)) ? fallbackValue : Number(value);\n}\n\n/**\n * Wraps the provided value in an array, unless the provided value is an array.\n * @template T\n * @param {?} value\n * @return {?}\n */\nfunction coerceArray(value) {\n return Array.isArray(value) ? value : [value];\n}\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { coerceBooleanProperty, coerceNumberProperty, coerceArray };\n//# sourceMappingURL=coercion.es5.js.map\n"],"names":[],"mappings":";;;;;;;;;;;;;AAOA;;;;;AAKA,SAAS,qBAAqB,CAAC,KAAK,EAAE;IAClC,OAAO,KAAK,IAAI,IAAI,IAAI,EAAE,GAAG,KAAK,KAAK,OAAO,CAAC;CAClD;;;;;;;;AAQD,SAAS,oBAAoB,CAAC,KAAK,EAAE,aAAa,EAAE;IAChD,IAAI,aAAa,KAAK,KAAK,CAAC,EAAE,EAAE,aAAa,GAAG,CAAC,CAAC,EAAE;;;;IAIpD,OAAO,KAAK,CAAC,UAAU,mBAAmB,KAAK,EAAE,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,GAAG,aAAa,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;CAC9G;;;;;;;;AAQD,SAAS,WAAW,CAAC,KAAK,EAAE;IACxB,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,GAAG,KAAK,GAAG,CAAC,KAAK,CAAC,CAAC;CACjD,AAED,AAIoE,AACpE,AAAwC;;;;;;;;"}