/**
 * @fileoverview added by tsickle
 * Generated from: lib/notifications-list/notifications-list.component.ts
 * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
 */
import * as tslib_1 from "tslib";
import { NotificationsData } from '../notifications.interfaces';
import { ChangeDetectionStrategy, Component, HostBinding, ViewEncapsulation } from '@angular/core';
import { notificationAnimation } from '../notifications.animations';
var BbNotificationsList = /** @class */ (function () {
    function BbNotificationsList(data) {
        this.data = data;
        // Data.
        this.position = null;
        // Track by function.
        this.trackByFn = (/**
         * @param {?} _
         * @param {?} item
         * @return {?}
         */
        function (_, item) { return item.id; });
    }
    Object.defineProperty(BbNotificationsList.prototype, "horizontalPosition", {
        get: /**
         * @return {?}
         */
        function () {
            return this.location.horizontal;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(BbNotificationsList.prototype, "verticalPosition", {
        get: /**
         * @return {?}
         */
        function () {
            return this.location.vertical;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(BbNotificationsList.prototype, "animation", {
        get: /**
         * @return {?}
         */
        function () {
            /** @type {?} */
            var to = this.horizontalPosition === 'flex-start'
                ? -50
                : 50;
            return { to: to };
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(BbNotificationsList.prototype, "location", {
        get: /**
         * @private
         * @return {?}
         */
        function () {
            var _a = tslib_1.__read((this.data.position || '').split('|'), 2), y = _a[0], x = _a[1];
            return { vertical: y || null, horizontal: x || null };
        },
        enumerable: true,
        configurable: true
    });
    BbNotificationsList.decorators = [
        { type: Component, args: [{
                    selector: 'bb-notifications-list',
                    template: "<!--\r\n    The notifications list.\r\n\r\n    The list provides the animation effect for the\r\n    incoming notifications.\r\n-->\r\n<div *ngIf=\"data?.data | async as notifications\"\r\n     [@notificationListAnimation]=\"{value: notifications?.length, params: animation}\"\r\n     class=\"notifications-list-wrapper\">\r\n    <!--\r\n        The loop for the notifications.\r\n\r\n        All notifications will be displayed here. They\r\n        are wrapped within a wrapper which separates them.\r\n    -->\r\n    <div *ngFor=\"let notification of notifications; trackBy: trackByFn\"\r\n         class=\"notifications-item-wrapper\">\r\n        <bb-notifications-item [notification]=\"notification\"\r\n                               [dismissButtonText]=\"data?.dismissText\">\r\n        </bb-notifications-item>\r\n    </div>\r\n</div>\r\n",
                    animations: [notificationAnimation],
                    changeDetection: ChangeDetectionStrategy.OnPush,
                    encapsulation: ViewEncapsulation.None,
                    preserveWhitespaces: false,
                    host: {
                        'class': 'bb-notifications-list',
                        'role': 'list'
                    },
                    styles: [".bb-notifications-list{top:0;left:0;right:0;bottom:0;z-index:1100;padding:10px;display:-ms-flexbox;display:flex;position:fixed;pointer-events:none}.notifications-list-wrapper{width:100%;display:block;max-width:400px;position:relative}.notifications-item-wrapper{padding:0;margin:0 0 10px;pointer-events:all}"]
                }] }
    ];
    /** @nocollapse */
    BbNotificationsList.ctorParameters = function () { return [
        { type: NotificationsData }
    ]; };
    BbNotificationsList.propDecorators = {
        horizontalPosition: [{ type: HostBinding, args: ['style.justify-content',] }],
        verticalPosition: [{ type: HostBinding, args: ['style.align-items',] }]
    };
    return BbNotificationsList;
}());
export { BbNotificationsList };
if (false) {
    /** @type {?} */
    BbNotificationsList.prototype.position;
    /** @type {?} */
    BbNotificationsList.prototype.trackByFn;
    /** @type {?} */
    BbNotificationsList.prototype.data;
}
//# sourceMappingURL=data:application/json;base64, 