// /// <reference path='../../../typings/commonjs.d.ts' />
"use strict";
var __extends = (this && this.__extends) || function (d, b) {
    for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
    function __() { this.constructor = d; }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
var angular = require("angular");
var button_ng1_1 = require("../button/button.ng1");
exports.moduleName = 'rl.ui.components.buttonLink';
exports.componentName = 'rlButtonLink';
exports.controllerName = 'ButtonLinkController';
var ButtonLinkController = (function (_super) {
    __extends(ButtonLinkController, _super);
    function ButtonLinkController() {
        var _this = _super.call(this) || this;
        _this.target = _this.newTab ? '_blank' : '_self';
        return _this;
    }
    return ButtonLinkController;
}(button_ng1_1.ButtonController));
exports.ButtonLinkController = ButtonLinkController;
var buttonLink = button_ng1_1.buildButton({
    template: require('./buttonLink.ng1.html'),
    bindings: {
        link: '@',
        newTab: '<?',
        action: null,
    },
    controller: exports.controllerName,
});
angular.module(exports.moduleName, [])
    .component(exports.componentName, buttonLink)
    .controller(exports.controllerName, ButtonLinkController);
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYnV0dG9uTGluay5uZzEuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJidXR0b25MaW5rLm5nMS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSwwREFBMEQ7Ozs7Ozs7QUFFMUQsaUNBQW1DO0FBRW5DLG1EQUFxRTtBQUV4RCxRQUFBLFVBQVUsR0FBVyw2QkFBNkIsQ0FBQztBQUNuRCxRQUFBLGFBQWEsR0FBVyxjQUFjLENBQUM7QUFDdkMsUUFBQSxjQUFjLEdBQVcsc0JBQXNCLENBQUM7QUFFN0Q7SUFBMEMsd0NBQWdCO0lBT3pEO1FBQUEsWUFDQyxpQkFBTyxTQUVQO1FBREEsS0FBSSxDQUFDLE1BQU0sR0FBRyxLQUFJLENBQUMsTUFBTSxHQUFHLFFBQVEsR0FBRyxPQUFPLENBQUM7O0lBQ2hELENBQUM7SUFDRiwyQkFBQztBQUFELENBQUMsQUFYRCxDQUEwQyw2QkFBZ0IsR0FXekQ7QUFYWSxvREFBb0I7QUFhakMsSUFBTSxVQUFVLEdBQThCLHdCQUFXLENBQUM7SUFDekQsUUFBUSxFQUFFLE9BQU8sQ0FBQyx1QkFBdUIsQ0FBQztJQUMxQyxRQUFRLEVBQUU7UUFDVCxJQUFJLEVBQUUsR0FBRztRQUNULE1BQU0sRUFBRSxJQUFJO1FBQ1osTUFBTSxFQUFFLElBQUk7S0FDWjtJQUNELFVBQVUsRUFBRSxzQkFBYztDQUMxQixDQUFDLENBQUM7QUFFSCxPQUFPLENBQUMsTUFBTSxDQUFDLGtCQUFVLEVBQUUsRUFBRSxDQUFDO0tBQzVCLFNBQVMsQ0FBQyxxQkFBYSxFQUFFLFVBQVUsQ0FBQztLQUNwQyxVQUFVLENBQUMsc0JBQWMsRUFBRSxvQkFBb0IsQ0FBQyxDQUFDIn0=