(function (factory) {
    if (typeof module === "object" && typeof module.exports === "object") {
        var v = factory(require, exports);
        if (v !== undefined) module.exports = v;
    }
    else if (typeof define === "function" && define.amd) {
        define(["require", "exports", "@angular/core"], factory);
    }
})(function (require, exports) {
    "use strict";
    /**
     * @fileoverview added by tsickle
     * Generated from: lib/leaflet-map-camadas-filert.pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    Object.defineProperty(exports, "__esModule", { value: true });
    var core_1 = require("@angular/core");
    var LeafletMapCamadasFilterPipe = /** @class */ (function () {
        function LeafletMapCamadasFilterPipe() {
        }
        /**
         * @param {?} items
         * @param {?} searchText
         * @return {?}
         */
        LeafletMapCamadasFilterPipe.prototype.transform = /**
         * @param {?} items
         * @param {?} searchText
         * @return {?}
         */
        function (items, searchText) {
            if (!items)
                return [];
            if (!searchText)
                return items;
            searchText = searchText.toLowerCase();
            return items.filter((/**
             * @param {?} it
             * @return {?}
             */
            function (it) { return it.name.toLowerCase().includes(searchText); }));
        };
        LeafletMapCamadasFilterPipe.decorators = [
            { type: core_1.Pipe, args: [{
                        name: 'filter'
                    },] }
        ];
        return LeafletMapCamadasFilterPipe;
    }());
    exports.LeafletMapCamadasFilterPipe = LeafletMapCamadasFilterPipe;
});
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGVhZmxldC1tYXAtY2FtYWRhcy1maWxlcnQucGlwZS5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0BjaWFnL2xlYWZsZXQtbWFwLyIsInNvdXJjZXMiOlsibGliL2xlYWZsZXQtbWFwLWNhbWFkYXMtZmlsZXJ0LnBpcGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7OztJQUFBLHNDQUFvRDtJQUNwRDtRQUFBO1FBV0EsQ0FBQzs7Ozs7O1FBUEcsK0NBQVM7Ozs7O1FBQVQsVUFB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