/*!
 *
 * carbon-angular v0.0.5 | switcher-list-item.component.js
 *
 * Copyright 2014, 2019 IBM
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0

 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */


import { Component, Input } from "@angular/core";
import { DomSanitizer } from "@angular/platform-browser";
/**
 * Represents an item in a switcher list.
 *
 * **Note:** `ibm-product-x` selectors and components are deprecated and will be removed in the next major version
 */
var SwitcherListItem = /** @class */ (function () {
    function SwitcherListItem(domSanitizer) {
        this.domSanitizer = domSanitizer;
        /**
         * Enables the "active" state for an item. Commonly used to indicate the current page or selection.
         */
        this.active = false;
        this._href = "javascript:void(0)";
    }
    Object.defineProperty(SwitcherListItem.prototype, "href", {
        get: function () {
            return this.domSanitizer.bypassSecurityTrustUrl(this._href);
        },
        /**
         * Optional link for the underlying anchor.
         */
        set: function (value) {
            this._href = value;
        },
        enumerable: true,
        configurable: true
    });
    SwitcherListItem.decorators = [
        { type: Component, args: [{
                    selector: "ibm-switcher-list-item, ibm-product-switcher-list-item, ibm-product-switcher-item",
                    template: "\n\t\t<a\n\t\t\tclass=\"bx--switcher__item-link\"\n\t\t\t[ngClass]=\"{\n\t\t\t\t'bx--switcher__item-link--selected': active\n\t\t\t}\"\n\t\t\t[href]=\"href\">\n\t\t\t<ng-content></ng-content>\n\t\t</a>\n\t"
                },] },
    ];
    /** @nocollapse */
    SwitcherListItem.ctorParameters = function () { return [
        { type: DomSanitizer }
    ]; };
    SwitcherListItem.propDecorators = {
        active: [{ type: Input }],
        href: [{ type: Input }]
    };
    return SwitcherListItem;
}());
export { SwitcherListItem };
//# sourceMappingURL=switcher-list-item.component.js.map