import { NgModule, Component, ElementRef, Input } from "@angular/core";
import { getAttributes } from "@carbon/icon-helpers";
var Light32 = /** @class */ (function () {
    function Light32(elementRef) {
        this.elementRef = elementRef;
    }
    Light32.prototype.ngAfterViewInit = function () {
        var svg = this.elementRef.nativeElement.querySelector("svg");
        var attributes = getAttributes({
            width: 32,
            height: 32,
            viewBox: "0 0 32 32",
            title: this.title,
            "aria-label": this.ariaLabel,
            "aria-labelledby": this.ariaLabelledby,
            "aria-hidden": this.ariaHidden,
            focusable: this.focusable
        });
        var attrKeys = Object.keys(attributes);
        for (var i = 0; i < attrKeys.length; i++) {
            var key = attrKeys[i];
            var value = attributes[key];
            if (key === "title") {
                continue;
            }
            if (value) {
                svg.setAttribute(key, value);
            }
        }
        if (attributes.title) {
            var title = document.createElement("title");
            title.textContent = attributes.title;
            Light32.titleIdCounter++;
            title.setAttribute("id", "light32-" + Light32.titleIdCounter);
            svg.appendChild(title);
            svg.setAttribute("aria-labelledby", "light32-" + Light32.titleIdCounter);
        }
    };
    Light32.titleIdCounter = 0;
    Light32.decorators = [
        { type: Component, args: [{
                    selector: "ibm-icon-light32",
                    template: "<svg focusable=\"false\" preserveAspectRatio=\"xMidYMid meet\" style=\"will-change: transform;\" xmlns=\"http://www.w3.org/2000/svg\" width=\"32\" height=\"32\" viewBox=\"0 0 32 32\" aria-hidden=\"true\"><path d=\"M15 2h2v4.96h-2zm6.687 6.89l3.507-3.506 1.414 1.414-3.507 3.507zM25.04 15H30v2h-4.96zm-3.347 8.104l1.414-1.414 3.507 3.507L25.2 26.61zM15 25.04h2V30h-2zm-9.604.162l3.508-3.507 1.414 1.414-3.507 3.507zM2 15h4.96v2H2zm3.39-8.197l1.415-1.414 3.507 3.507-1.414 1.414zM16 12a4 4 0 1 1-4 4 4 4 0 0 1 4-4m0-2a6 6 0 1 0 6 6 6 6 0 0 0-6-6z\"></path></svg>"
                },] },
    ];
    /** @nocollapse */
    Light32.ctorParameters = function () { return [
        { type: ElementRef }
    ]; };
    Light32.propDecorators = {
        ariaLabel: [{ type: Input }],
        ariaLabelledby: [{ type: Input }],
        ariaHidden: [{ type: Input }],
        title: [{ type: Input }],
        focusable: [{ type: Input }]
    };
    return Light32;
}());
export { Light32 };
var Light32Module = /** @class */ (function () {
    function Light32Module() {
    }
    Light32Module.decorators = [
        { type: NgModule, args: [{
                    declarations: [
                        Light32
                    ],
                    exports: [
                        Light32
                    ]
                },] },
    ];
    return Light32Module;
}());
export { Light32Module };
//# sourceMappingURL=32.js.map