/*!
 *
 * carbon-angular v0.0.7 | hamburger.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, Output, EventEmitter, Input } from "@angular/core";
import { I18n } from "../../i18n/i18n.module";
/**
 * A toggle for the side navigation
 */
var Hamburger = /** @class */ (function () {
    function Hamburger(i18n) {
        this.i18n = i18n;
        /**
         * Controls the active/selected state for the `Hamburger` menu.
         */
        this.active = false;
        /**
         * `EventEmitter` to notify parent components of menu click events.
         */
        this.selected = new EventEmitter();
    }
    /**
     * Emit the Hamburger click event upwards.
     */
    Hamburger.prototype.doClick = function () {
        this.selected.emit(this.active);
    };
    Hamburger.decorators = [
        { type: Component, args: [{
                    selector: "ibm-hamburger",
                    template: "\n\t\t<button\n\t\t\ttype=\"button\"\n\t\t\t(click)=\"doClick()\"\n\t\t\t[ngClass]=\"{'bx--header__action--active': active}\"\n\t\t\tclass=\"bx--header__menu-trigger bx--header__action bx--header__menu-toggle\"\n\t\t\t[attr.aria-label]=\"i18n.get('UI_SHELL.HEADER.MENU') | async\"\n\t\t\t[attr.title]=\"i18n.get('UI_SHELL.HEADER.MENU') | async\">\n\n\t\t\t<svg *ngIf=\"!active\" aria-hidden=\"true\" width=\"20\" height=\"20\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 32 32\">\n\t\t\t\t<path d=\"M4 6h24v2H4zm0 18h24v2H4zm0-9h24v2H4z\" />\n\t\t\t</svg>\n\n\t\t\t<svg *ngIf=\"active\" aria-hidden=\"true\" height=\"20\" width=\"20\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 32 32\">\n\t\t\t\t<path d=\"M24 9.4L22.6 8 16 14.6 9.4 8 8 9.4l6.6 6.6L8 22.6 9.4 24l6.6-6.6 6.6 6.6 1.4-1.4-6.6-6.6L24 9.4z\" />\n\t\t\t</svg>\n\t\t</button>\n\t"
                },] },
    ];
    /** @nocollapse */
    Hamburger.ctorParameters = function () { return [
        { type: I18n }
    ]; };
    Hamburger.propDecorators = {
        active: [{ type: Input }],
        selected: [{ type: Output }]
    };
    return Hamburger;
}());
export { Hamburger };
//# sourceMappingURL=hamburger.component.js.map