(function (global, factory) {
    typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/common'), require('@angular/core'), require('@angular/cdk/coercion')) :
    typeof define === 'function' && define.amd ? define('@ng-tangram/components/button', ['exports', '@angular/common', '@angular/core', '@angular/cdk/coercion'], factory) :
    (global = global || self, factory((global.nt = global.nt || {}, global.nt.components = global.nt.components || {}, global.nt.components.button = {}), global.ng.common, global.ng.core, global.ng.cdk.coercion));
}(this, (function (exports, common, core, coercion) { 'use strict';

    var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
        var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
        if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
        else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
        return c > 3 && r && Object.defineProperty(target, key, r), r;
    };
    var NtButtonGroupComponent = (function () {
        function NtButtonGroupComponent() {
            this._expanded = false;
            this.class = '';
            this.color = '';
            this.size = '';
        }
        Object.defineProperty(NtButtonGroupComponent.prototype, "expanded", {
            get: function () { return this._expanded; },
            set: function (value) { this._expanded = coercion.coerceBooleanProperty(value); },
            enumerable: true,
            configurable: true
        });
        __decorate([
            core.Input()
        ], NtButtonGroupComponent.prototype, "class", void 0);
        __decorate([
            core.Input()
        ], NtButtonGroupComponent.prototype, "color", void 0);
        __decorate([
            core.Input()
        ], NtButtonGroupComponent.prototype, "size", void 0);
        __decorate([
            core.Input()
        ], NtButtonGroupComponent.prototype, "expanded", null);
        NtButtonGroupComponent = __decorate([
            core.Component({
                selector: 'nt-button-group, [nt-button-group]',
                template: "<ng-content></ng-content>",
                encapsulation: core.ViewEncapsulation.None,
                host: {
                    '[class]': '["button-group", color, size, class].join(" ")',
                    '[class.expanded]': 'expanded'
                }
            })
        ], NtButtonGroupComponent);
        return NtButtonGroupComponent;
    }());

    var __decorate$1 = (this && this.__decorate) || function (decorators, target, key, desc) {
        var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
        if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
        else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
        return c > 3 && r && Object.defineProperty(target, key, r), r;
    };
    var NtButtonComponent = (function () {
        function NtButtonComponent() {
            this._style = '';
            this._expanded = false;
            this.class = '';
            this.color = '';
            this.size = '';
        }
        Object.defineProperty(NtButtonComponent.prototype, "button", {
            set: function (value) {
                if (this._validStyle(value)) {
                    this._style = value;
                }
            },
            enumerable: true,
            configurable: true
        });
        Object.defineProperty(NtButtonComponent.prototype, "style", {
            get: function () { return this._style; },
            set: function (value) { this._style = value; },
            enumerable: true,
            configurable: true
        });
        Object.defineProperty(NtButtonComponent.prototype, "expanded", {
            get: function () { return this._expanded; },
            set: function (value) { this._expanded = coercion.coerceBooleanProperty(value); },
            enumerable: true,
            configurable: true
        });
        NtButtonComponent.prototype._validStyle = function (value) {
            return ['', 'hollow', 'clear'].indexOf(value) > -1;
        };
        __decorate$1([
            core.Input()
        ], NtButtonComponent.prototype, "class", void 0);
        __decorate$1([
            core.Input()
        ], NtButtonComponent.prototype, "color", void 0);
        __decorate$1([
            core.Input()
        ], NtButtonComponent.prototype, "size", void 0);
        __decorate$1([
            core.Input('nt-button')
        ], NtButtonComponent.prototype, "button", null);
        __decorate$1([
            core.Input()
        ], NtButtonComponent.prototype, "style", null);
        __decorate$1([
            core.Input()
        ], NtButtonComponent.prototype, "expanded", null);
        NtButtonComponent = __decorate$1([
            core.Component({
                selector: '[nt-button]',
                template: "<ng-content></ng-content>",
                encapsulation: core.ViewEncapsulation.None,
                host: {
                    '[class]': '["button", color, style, size, class].join(" ")',
                    '[class.expanded]': 'expanded'
                }
            })
        ], NtButtonComponent);
        return NtButtonComponent;
    }());

    var __decorate$2 = (this && this.__decorate) || function (decorators, target, key, desc) {
        var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
        if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
        else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
        return c > 3 && r && Object.defineProperty(target, key, r), r;
    };
    var NtButtonModule = (function () {
        function NtButtonModule() {
        }
        NtButtonModule = __decorate$2([
            core.NgModule({
                imports: [common.CommonModule],
                exports: [NtButtonComponent, NtButtonGroupComponent],
                declarations: [NtButtonComponent, NtButtonGroupComponent],
            })
        ], NtButtonModule);
        return NtButtonModule;
    }());

    exports.NtButtonComponent = NtButtonComponent;
    exports.NtButtonGroupComponent = NtButtonGroupComponent;
    exports.NtButtonModule = NtButtonModule;

    Object.defineProperty(exports, '__esModule', { value: true });

})));
//# sourceMappingURL=button.umd.js.map
