import { Component, Input, HostBinding, Output, EventEmitter } from '@angular/core';
export class RAlertComponent {
    constructor() {
        /**
         * Alert size, available sizes:
         * `tiny`, `small`, `medium`, `large`, `giant`
         * Unset by default.
         */
        this.size = '';
        /**
         * Alert status (adds specific styles):
         * `basic` (default), `primary`, `success`, `info`, `warning`, `danger`, `control`.
         */
        this.status = 'basic';
        /**
         * Alert accent (color of the top border):
         * `basic`, `primary`, `success`, `info`, `warning`, `danger`, `control`.
         * Unset by default.
         */
        this.accent = '';
        /**
         * Alert outline (color of the border):
         * `basic`, `primary`, `success`, `info`, `warning`, `danger`, `control`.
         * Unset by default.
         */
        this.outline = '';
        this._closable = false;
        /**
         * Emits when chip is removed
         * @type EventEmitter<any>
         */
        this.close = new EventEmitter();
    }
    /**
     * Shows `close` icon
     */
    get closable() {
        return this._closable;
    }
    set closable(value) {
        this._closable = !!value;
    }
    /**
     * Emits the removed chip event
     */
    onClose() {
        this.close.emit();
    }
    get tiny() {
        return this.size === 'tiny';
    }
    get small() {
        return this.size === 'small';
    }
    get medium() {
        return this.size === 'medium';
    }
    get large() {
        return this.size === 'large';
    }
    get giant() {
        return this.size === 'giant';
    }
    get primary() {
        return this.status === 'primary';
    }
    get success() {
        return this.status === 'success';
    }
    get info() {
        return this.status === 'info';
    }
    get warning() {
        return this.status === 'warning';
    }
    get danger() {
        return this.status === 'danger';
    }
    get basic() {
        return this.status === 'basic';
    }
    get control() {
        return this.status === 'control';
    }
    get primaryAccent() {
        return this.accent === 'primary';
    }
    get successAccent() {
        return this.accent === 'success';
    }
    get infoAccent() {
        return this.accent === 'info';
    }
    get warningAccent() {
        return this.accent === 'warning';
    }
    get dangerAccent() {
        return this.accent === 'danger';
    }
    get basicAccent() {
        return this.accent === 'basic';
    }
    get controlAccent() {
        return this.accent === 'control';
    }
    get primaryOutline() {
        return this.outline === 'primary';
    }
    get successOutline() {
        return this.outline === 'success';
    }
    get infoOutline() {
        return this.outline === 'info';
    }
    get warningOutline() {
        return this.outline === 'warning';
    }
    get dangerOutline() {
        return this.outline === 'danger';
    }
    get basicOutline() {
        return this.outline === 'basic';
    }
    get controlOutline() {
        return this.outline === 'control';
    }
}
RAlertComponent.decorators = [
    { type: Component, args: [{
                selector: 'r-alert',
                template: `
    <button *ngIf="closable" type="button" class="close" aria-label="Close" (click)="onClose()">
      <span aria-hidden="true">&times;</span>
    </button>
    <ng-content></ng-content>
  `,
                styles: [":host{display:flex;flex-direction:column;position:relative}[dir=ltr] :host .close{right:0}[dir=rtl] :host .close{left:0}.close{position:absolute;top:0;color:inherit;background-color:transparent;border:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}"]
            },] }
];
RAlertComponent.propDecorators = {
    size: [{ type: Input }],
    status: [{ type: Input }],
    accent: [{ type: Input }],
    outline: [{ type: Input }],
    closable: [{ type: Input }, { type: HostBinding, args: ['class.closable',] }],
    close: [{ type: Output }],
    tiny: [{ type: HostBinding, args: ['class.size-tiny',] }],
    small: [{ type: HostBinding, args: ['class.size-small',] }],
    medium: [{ type: HostBinding, args: ['class.size-medium',] }],
    large: [{ type: HostBinding, args: ['class.size-large',] }],
    giant: [{ type: HostBinding, args: ['class.size-giant',] }],
    primary: [{ type: HostBinding, args: ['class.status-primary',] }],
    success: [{ type: HostBinding, args: ['class.status-success',] }],
    info: [{ type: HostBinding, args: ['class.status-info',] }],
    warning: [{ type: HostBinding, args: ['class.status-warning',] }],
    danger: [{ type: HostBinding, args: ['class.status-danger',] }],
    basic: [{ type: HostBinding, args: ['class.status-basic',] }],
    control: [{ type: HostBinding, args: ['class.status-control',] }],
    primaryAccent: [{ type: HostBinding, args: ['class.accent-primary',] }],
    successAccent: [{ type: HostBinding, args: ['class.accent-success',] }],
    infoAccent: [{ type: HostBinding, args: ['class.accent-info',] }],
    warningAccent: [{ type: HostBinding, args: ['class.accent-warning',] }],
    dangerAccent: [{ type: HostBinding, args: ['class.accent-danger',] }],
    basicAccent: [{ type: HostBinding, args: ['class.accent-basic',] }],
    controlAccent: [{ type: HostBinding, args: ['class.accent-control',] }],
    primaryOutline: [{ type: HostBinding, args: ['class.outline-primary',] }],
    successOutline: [{ type: HostBinding, args: ['class.outline-success',] }],
    infoOutline: [{ type: HostBinding, args: ['class.outline-info',] }],
    warningOutline: [{ type: HostBinding, args: ['class.outline-warning',] }],
    dangerOutline: [{ type: HostBinding, args: ['class.outline-danger',] }],
    basicOutline: [{ type: HostBinding, args: ['class.outline-basic',] }],
    controlOutline: [{ type: HostBinding, args: ['class.outline-control',] }]
};
//# sourceMappingURL=alert.component.js.map