igniteui-angular-inputs
Version:
Ignite UI Angular input components for building rich data visualizations for modern web apps.
1,540 lines • 108 kB
JavaScript
import { Output, TemplateRef, EventEmitter, Component, ViewContainerRef, ViewChild, Input, ChangeDetectionStrategy, HostBinding } from '@angular/core';
import { XButton } from "./XButton";
import { ensureEnum, brushToString, stringToBrush, ensureBool, toSpinal, initializePropertiesFromCss, NamePatcher } from "igniteui-angular-core";
import { FontInfo } from "igniteui-angular-core";
import { AngularRenderer, PortalManager } from "igniteui-angular-core";
import { delegateCombine } from "igniteui-angular-core";
import { CornerRadius } from "igniteui-angular-core";
import { ButtonDisplayStyle_$type } from './ButtonDisplayStyle';
import { IgxButtonClickEventArgs } from './igx-button-click-event-args';
import { TypeRegistrar } from "igniteui-angular-core";
import { ControlDisplayDensity_$type } from "igniteui-angular-core";
import { ElevationMode_$type } from "igniteui-angular-core";
import { BaseControlTheme_$type } from "igniteui-angular-core";
import { HorizontalAlignment_$type } from "igniteui-angular-core";
import { VerticalAlignment_$type } from "igniteui-angular-core";
import { IgxFocusEventArgs } from "igniteui-angular-core";
import * as i0 from "@angular/core";
var IgxXButtonComponent = /** @class */ /*@__PURE__*/ (function () {
function IgxXButtonComponent(renderer, _elRef, ngZone, injector, componentFactoryResolver) {
this.renderer = renderer;
this._elRef = _elRef;
this.ngZone = ngZone;
this.injector = injector;
this.componentFactoryResolver = componentFactoryResolver;
this._wrapper = null;
this._portalManager = null;
this._root = null;
this.__p = null;
this._hasUserValues = new Set();
this._stylingContainer = null;
this._stylingParent = null;
this._inStyling = false;
this._clicked = null;
this._gotFocus = null;
this._lostFocus = null;
this._zoneRunner = null;
if (this._styling) {
NamePatcher.ensureStylablePatched(Object.getPrototypeOf(this));
}
this._implementation = this.createImplementation();
this._implementation.externalObject = this;
if (renderer) {
this.container = renderer.createElement("div");
renderer.appendChild(_elRef.element.nativeElement, this.container);
renderer.setStyle(this.container, "display", "inline-block");
}
var root;
root = this.container;
if (this.container != null) {
root = this.container;
}
if (root && root.nativeElement) {
root = root.nativeElement;
}
this._root = root;
var button = this.i;
this._button = button;
if (renderer) {
this._portalManager = new PortalManager("buttonContent", componentFactoryResolver);
var ren = new AngularRenderer(root, this.renderer, window.document, this.ngZone, true, {}, this._portalManager);
this._wrapper = ren;
button.provideContainer(ren);
}
}
// supports angular themes or custom properties set in CSS
IgxXButtonComponent.prototype.updateStyle = function () {
this._styling(this._root, this);
};
IgxXButtonComponent.prototype.ngOnDestroy = function () {
this._button.destroy();
this._wrapper.destroy();
};
IgxXButtonComponent.prototype.ngAfterViewInit = function () {
this._portalManager.dynamicContent = this._dynamicContent;
this._portalManager.onChildContentChanged(this._childTemplateRef);
this._styling(this._root, this);
this.updateStyle();
};
IgxXButtonComponent.prototype.createImplementation = function () {
return new XButton();
};
Object.defineProperty(IgxXButtonComponent.prototype, "i", {
/**
* @hidden
*/
get: function () {
return this._implementation;
} /**
* @hidden
*/,
enumerable: false,
configurable: true
});
IgxXButtonComponent._createFromInternal = function (internal) {
if (!internal) {
return null;
}
if (!internal.$type) {
return null;
}
var name = internal.$type.name;
var externalName = "Igx" + name + "Component";
if (!TypeRegistrar.isRegistered(externalName)) {
return null;
}
return TypeRegistrar.create(externalName);
};
Object.defineProperty(IgxXButtonComponent.prototype, "minWidth", {
/**
* Gets or sets the min width to use for the button.
*/
get: function () {
return this.i.by;
},
set: function (v) {
this.i.by = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "minHeight", {
/**
* Gets or sets the min height to use for the button.
*/
get: function () {
return this.i.bx;
},
set: function (v) {
this.i.bx = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "displayType", {
/**
* Gets or sets the display style to use for the button.
*/
get: function () {
return this.i.e;
},
set: function (v) {
this.i.e = ensureEnum(ButtonDisplayStyle_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "density", {
/**
* Gets or sets the display density to use for the button.
*/
get: function () {
return this.i.r;
},
set: function (v) {
this.i.r = ensureEnum(ControlDisplayDensity_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "baseTheme", {
/**
* Gets or sets the base built in theme to use for the button.
*/
get: function () {
return this.i.n;
},
set: function (v) {
this.i.n = ensureEnum(BaseControlTheme_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualDensity", {
/**
* Gets the actual display density to use for the label.
*/
get: function () {
return this.i.q;
},
set: function (v) {
this.i.q = ensureEnum(ControlDisplayDensity_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualBorderColor", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return brushToString(this.i.np);
},
set: function (v) {
this.i.np = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualUmbraShadowColor", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return brushToString(this.i.n0);
},
set: function (v) {
this.i.n0 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualPenumbraShadowColor", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return brushToString(this.i.nx);
},
set: function (v) {
this.i.nx = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualAmbientShadowColor", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return brushToString(this.i.nn);
},
set: function (v) {
this.i.nn = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualRestingElevation", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return this.i.cx;
},
set: function (v) {
this.i.cx = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualFocusElevation", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return this.i.cv;
},
set: function (v) {
this.i.cv = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualHoverElevation", {
/**
* Gets or sets the color to use for the check mark when the checkbox is checked.
*/
get: function () {
return this.i.cw;
},
set: function (v) {
this.i.cw = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualRippleColor", {
/**
* Gets or sets the color to use for the ripple when the button is pressed.
*/
get: function () {
return brushToString(this.i.ny);
},
set: function (v) {
this.i.ny = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualCornerRadiusBottomRight", {
get: function () {
return this.i.kz ? this.i.kz.c : NaN;
},
set: function (v) {
this.ensureActualCornerRadius();
this.i.kz.c = +v;
this.i.kz = this.i.kz;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualCornerRadiusBottomLeft", {
get: function () {
return this.i.kz ? this.i.kz.b : NaN;
},
set: function (v) {
this.ensureActualCornerRadius();
this.i.kz.b = +v;
this.i.kz = this.i.kz;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualCornerRadiusTopLeft", {
get: function () {
return this.i.kz ? this.i.kz.d : NaN;
},
set: function (v) {
this.ensureActualCornerRadius();
this.i.kz.d = +v;
this.i.kz = this.i.kz;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualCornerRadiusTopRight", {
get: function () {
return this.i.kz ? this.i.kz.e : NaN;
},
set: function (v) {
this.ensureActualCornerRadius();
this.i.kz.e = +v;
this.i.kz = this.i.kz;
},
enumerable: false,
configurable: true
});
IgxXButtonComponent.prototype.ensureActualCornerRadius = function () {
if (this.i.kz) {
return;
}
this.i.kz = new CornerRadius(2);
};
Object.defineProperty(IgxXButtonComponent.prototype, "actualBackgroundColor", {
/**
* Gets the color to use for the actual background.
*/
get: function () {
return brushToString(this.i.no);
},
set: function (v) {
this.i.no = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualDisabledBackgroundColor", {
/**
* Gets the actual color to use for the disabled background of the button.
*/
get: function () {
return brushToString(this.i.nq);
},
set: function (v) {
this.i.nq = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualDisabledBorderColor", {
/**
* Gets the actual color to use for the disabled border of the button.
*/
get: function () {
return brushToString(this.i.nr);
},
set: function (v) {
this.i.nr = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualDisabledTextColor", {
/**
* Gets the actual color to use for the disabled text of the button.
*/
get: function () {
return brushToString(this.i.ns);
},
set: function (v) {
this.i.ns = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualDisabledElevation", {
/**
* Gets the actual disabled elevation to use for the button.
*/
get: function () {
return this.i.cu;
},
set: function (v) {
this.i.cu = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualElevationMode", {
/**
* Gets the actual disabled elevation to use for the button.
*/
get: function () {
return this.i.u;
},
set: function (v) {
this.i.u = ensureEnum(ElevationMode_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualTextColor", {
/**
* Gets the color to use for the actual background.
*/
get: function () {
return brushToString(this.i.nz);
},
set: function (v) {
this.i.nz = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualHoverTextColor", {
/**
* Gets the color to use for the actual background.
*/
get: function () {
return brushToString(this.i.nw);
},
set: function (v) {
this.i.nw = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualFocusBackgroundColor", {
/**
* Gets the color to use for the actual background.
*/
get: function () {
return brushToString(this.i.nt);
},
set: function (v) {
this.i.nt = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualFocusTextColor", {
/**
* Gets the actual color to use for the focused text.
*/
get: function () {
return brushToString(this.i.nu);
},
set: function (v) {
this.i.nu = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualHoverBackgroundColor", {
/**
* Gets the hover color to use for the actual background.
*/
get: function () {
return brushToString(this.i.nv);
},
set: function (v) {
this.i.nv = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "actualBorderWidth", {
/**
* Gets or sets the Width to use for the check mark when the checkbox is checked.
*/
get: function () {
return this.i.bj;
},
set: function (v) {
this.i.bj = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedBackgroundColor", {
/**
* Gets or sets the color to use for the background of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.q4);
},
set: function (v) {
this.i.q4 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedDisabledBackgroundColor", {
/**
* Gets or sets the color to use for the disabled background of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.q6);
},
set: function (v) {
this.i.q6 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedDisabledBorderColor", {
/**
* Gets or sets the color to use for the disabled border of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.q7);
},
set: function (v) {
this.i.q7 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedDisabledTextColor", {
/**
* Gets or sets the color to use for the disabled text of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.q8);
},
set: function (v) {
this.i.q8 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedDisabledElevation", {
/**
* Gets or sets the disabled elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.d2;
},
set: function (v) {
this.i.d2 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedHoverBackgroundColor", {
/**
* Gets or sets the hover color to use for the background of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.rb);
},
set: function (v) {
this.i.rb = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedBorderColor", {
/**
* Gets or sets the border color to use for the button when the type is raised.
*/
get: function () {
return brushToString(this.i.q5);
},
set: function (v) {
this.i.q5 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedRestingElevation", {
/**
* Gets or sets the elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.d5;
},
set: function (v) {
this.i.d5 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedHoverElevation", {
/**
* Gets or sets the hover elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.d4;
},
set: function (v) {
this.i.d4 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedFocusElevation", {
/**
* Gets or sets the focus elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.d3;
},
set: function (v) {
this.i.d3 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedBorderWidth", {
/**
* Gets or sets the width to use for the button border when the type is raised.
*/
get: function () {
return this.i.b0;
},
set: function (v) {
this.i.b0 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedCornerRadiusBottomRight", {
get: function () {
return this.i.lc ? this.i.lc.c : NaN;
},
set: function (v) {
this.ensureRaisedCornerRadius();
this.i.lc.c = +v;
this.i.lc = this.i.lc;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedCornerRadiusBottomLeft", {
get: function () {
return this.i.lc ? this.i.lc.b : NaN;
},
set: function (v) {
this.ensureRaisedCornerRadius();
this.i.lc.b = +v;
this.i.lc = this.i.lc;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedCornerRadiusTopLeft", {
get: function () {
return this.i.lc ? this.i.lc.d : NaN;
},
set: function (v) {
this.ensureRaisedCornerRadius();
this.i.lc.d = +v;
this.i.lc = this.i.lc;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedCornerRadiusTopRight", {
get: function () {
return this.i.lc ? this.i.lc.e : NaN;
},
set: function (v) {
this.ensureRaisedCornerRadius();
this.i.lc.e = +v;
this.i.lc = this.i.lc;
},
enumerable: false,
configurable: true
});
IgxXButtonComponent.prototype.ensureRaisedCornerRadius = function () {
if (this.i.lc) {
return;
}
this.i.lc = new CornerRadius(2);
};
Object.defineProperty(IgxXButtonComponent.prototype, "raisedRippleColor", {
/**
* Gets or sets the color to use for the background when the button is pressed and the type is floating action button.
*/
get: function () {
return brushToString(this.i.rd);
},
set: function (v) {
this.i.rd = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatBackgroundColor", {
/**
* Gets or sets the color to use for the background of the button when the type is flat.
*/
get: function () {
return brushToString(this.i.p3);
},
set: function (v) {
this.i.p3 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatDisabledBackgroundColor", {
/**
* Gets or sets the color to use for the disabled background of the button when the type is flat.
*/
get: function () {
return brushToString(this.i.p5);
},
set: function (v) {
this.i.p5 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatDisabledBorderColor", {
/**
* Gets or sets the color to use for the disabled border of the button when the type is flat.
*/
get: function () {
return brushToString(this.i.p6);
},
set: function (v) {
this.i.p6 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatDisabledTextColor", {
/**
* Gets or sets the color to use for the disabled text of the button when the type is flat.
*/
get: function () {
return brushToString(this.i.p7);
},
set: function (v) {
this.i.p7 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatDisabledElevation", {
/**
* Gets or sets the disabled elevation to use for the button when the type is flat.
*/
get: function () {
return this.i.dn;
},
set: function (v) {
this.i.dn = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatHoverBackgroundColor", {
/**
* Gets or sets the hover color to use for the background of the button when the type is flat.
*/
get: function () {
return brushToString(this.i.qa);
},
set: function (v) {
this.i.qa = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatBorderColor", {
/**
* Gets or sets the border color to use for the button when the type is flat.
*/
get: function () {
return brushToString(this.i.p4);
},
set: function (v) {
this.i.p4 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatRestingElevation", {
/**
* Gets or sets the elevation to use for the button when the type is flat.
*/
get: function () {
return this.i.dr;
},
set: function (v) {
this.i.dr = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatHoverElevation", {
/**
* Gets or sets the hover elevation to use for the button when the type is flat.
*/
get: function () {
return this.i.dq;
},
set: function (v) {
this.i.dq = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatFocusElevation", {
/**
* Gets or sets the focus elevation to use for the button when the type is flat.
*/
get: function () {
return this.i.dp;
},
set: function (v) {
this.i.dp = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatRippleColor", {
/**
* Gets or sets the color to use for the background when the button is pressed and the type is floating action button.
*/
get: function () {
return brushToString(this.i.qc);
},
set: function (v) {
this.i.qc = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatTextColor", {
/**
* Gets or sets the color to use for the text of the button when type is flat.
*/
get: function () {
return brushToString(this.i.qd);
},
set: function (v) {
this.i.qd = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatHoverTextColor", {
/**
* Gets or sets the color to use for the hovered text of the button when type is flat.
*/
get: function () {
return brushToString(this.i.qb);
},
set: function (v) {
this.i.qb = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatFocusBackgroundColor", {
/**
* Gets or sets the color to use for the backround the button when it is focused and flat.
*/
get: function () {
return brushToString(this.i.p8);
},
set: function (v) {
this.i.p8 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatFocusTextColor", {
/**
* Gets or sets the color to use for the text the button when it is focused and flat.
*/
get: function () {
return brushToString(this.i.p9);
},
set: function (v) {
this.i.p9 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatBorderWidth", {
/**
* Gets or sets the width to use for the button border when the type is flat.
*/
get: function () {
return this.i.bv;
},
set: function (v) {
this.i.bv = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatCornerRadiusBottomRight", {
get: function () {
return this.i.k8 ? this.i.k8.c : NaN;
},
set: function (v) {
this.ensureFlatCornerRadius();
this.i.k8.c = +v;
this.i.k8 = this.i.k8;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatCornerRadiusBottomLeft", {
get: function () {
return this.i.k8 ? this.i.k8.b : NaN;
},
set: function (v) {
this.ensureFlatCornerRadius();
this.i.k8.b = +v;
this.i.k8 = this.i.k8;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatCornerRadiusTopLeft", {
get: function () {
return this.i.k8 ? this.i.k8.d : NaN;
},
set: function (v) {
this.ensureFlatCornerRadius();
this.i.k8.d = +v;
this.i.k8 = this.i.k8;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "flatCornerRadiusTopRight", {
get: function () {
return this.i.k8 ? this.i.k8.e : NaN;
},
set: function (v) {
this.ensureFlatCornerRadius();
this.i.k8.e = +v;
this.i.k8 = this.i.k8;
},
enumerable: false,
configurable: true
});
IgxXButtonComponent.prototype.ensureFlatCornerRadius = function () {
if (this.i.k8) {
return;
}
this.i.k8 = new CornerRadius(2);
};
Object.defineProperty(IgxXButtonComponent.prototype, "backgroundColor", {
/**
* Gets or sets the color to use for the background when the button regardless of type.
*/
get: function () {
return brushToString(this.i.n1);
},
set: function (v) {
this.i.n1 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "disabledBackgroundColor", {
/**
* Gets or sets the color to use for the disabled background of the button when the type is disabled.
*/
get: function () {
return brushToString(this.i.pp);
},
set: function (v) {
this.i.pp = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "disabledBorderColor", {
/**
* Gets or sets the color to use for the disabled border of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.pq);
},
set: function (v) {
this.i.pq = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "disabledTextColor", {
/**
* Gets or sets the color to use for the disabled text of the button when the type is raised.
*/
get: function () {
return brushToString(this.i.pr);
},
set: function (v) {
this.i.pr = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "disabledElevation", {
/**
* Gets or sets the disabled elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.di;
},
set: function (v) {
this.i.di = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "elevationMode", {
/**
* Gets or sets the disabled elevation to use for the button when the type is raised.
*/
get: function () {
return this.i.w;
},
set: function (v) {
this.i.w = ensureEnum(ElevationMode_$type, v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "hoverBackgroundColor", {
/**
* Gets or sets the hover color to use for the background of the button when the type is hovered.
*/
get: function () {
return brushToString(this.i.qg);
},
set: function (v) {
this.i.qg = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "borderColor", {
/**
* Gets or sets the border color to use for the button regardless of type.
*/
get: function () {
return brushToString(this.i.n2);
},
set: function (v) {
this.i.n2 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "restingElevation", {
/**
* Gets or sets the elevation to use for the button regardless of type.
*/
get: function () {
return this.i.d6;
},
set: function (v) {
this.i.d6 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "hoverElevation", {
/**
* Gets or sets the hover elevation to use for the button regardless of type.
*/
get: function () {
return this.i.dt;
},
set: function (v) {
this.i.dt = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "focusElevation", {
/**
* Gets or sets the focus elevation to use for the button regardless of type.
*/
get: function () {
return this.i.ds;
},
set: function (v) {
this.i.ds = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "textStyle", {
/**
* Gets or sets the use for the button.
*/
get: function () {
if (this.i.aa == null) {
return null;
}
return this.i.aa.fontString;
},
set: function (v) {
var fi = new FontInfo();
fi.fontString = v;
this.i.aa = fi;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "textColor", {
/**
* Gets or sets the color to use for the text of the button regardless of type.
*/
get: function () {
return brushToString(this.i.rg);
},
set: function (v) {
this.i.rg = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "hoverTextColor", {
/**
* Gets or sets the color to use for the hovered text of the button regardless of type.
*/
get: function () {
return brushToString(this.i.qh);
},
set: function (v) {
this.i.qh = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "rippleColor", {
/**
* Gets or sets the color to use for the background of the button regardless of type.
*/
get: function () {
return brushToString(this.i.rf);
},
set: function (v) {
this.i.rf = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedTextColor", {
/**
* Gets or sets the color to use for the text of the button when type is raised.
*/
get: function () {
return brushToString(this.i.re);
},
set: function (v) {
this.i.re = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedHoverTextColor", {
/**
* Gets or sets the color to use for the hovered text of the button when type is raised.
*/
get: function () {
return brushToString(this.i.rc);
},
set: function (v) {
this.i.rc = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedFocusBackgroundColor", {
/**
* Gets or sets the color to use for the backround the button when it is focused and raised.
*/
get: function () {
return brushToString(this.i.q9);
},
set: function (v) {
this.i.q9 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "raisedFocusTextColor", {
/**
* Gets or sets the color to use for the text the button when it is focused and raised.
*/
get: function () {
return brushToString(this.i.ra);
},
set: function (v) {
this.i.ra = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "focusBackgroundColor", {
/**
* Gets or sets the color to use for the backround the button when it is focused.
*/
get: function () {
return brushToString(this.i.qe);
},
set: function (v) {
this.i.qe = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "focusTextColor", {
/**
* Gets or sets the color to use for the text of the button when it is focused.
*/
get: function () {
return brushToString(this.i.qf);
},
set: function (v) {
this.i.qf = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "borderWidth", {
/**
* Gets or sets the width to use for the button border regardless of type.
*/
get: function () {
return this.i.bk;
},
set: function (v) {
this.i.bk = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "cornerRadiusBottomRight", {
get: function () {
return this.i.k1 ? this.i.k1.c : NaN;
},
set: function (v) {
this.ensureCornerRadius();
this.i.k1.c = +v;
this.i.k1 = this.i.k1;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "cornerRadiusBottomLeft", {
get: function () {
return this.i.k1 ? this.i.k1.b : NaN;
},
set: function (v) {
this.ensureCornerRadius();
this.i.k1.b = +v;
this.i.k1 = this.i.k1;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "cornerRadiusTopLeft", {
get: function () {
return this.i.k1 ? this.i.k1.d : NaN;
},
set: function (v) {
this.ensureCornerRadius();
this.i.k1.d = +v;
this.i.k1 = this.i.k1;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "cornerRadiusTopRight", {
get: function () {
return this.i.k1 ? this.i.k1.e : NaN;
},
set: function (v) {
this.ensureCornerRadius();
this.i.k1.e = +v;
this.i.k1 = this.i.k1;
},
enumerable: false,
configurable: true
});
IgxXButtonComponent.prototype.ensureCornerRadius = function () {
if (this.i.k1) {
return;
}
this.i.k1 = new CornerRadius(2);
};
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedBackgroundColor", {
/**
* Gets or sets the color to use for the background of the button when the type is outlined.
*/
get: function () {
return brushToString(this.i.qt);
},
set: function (v) {
this.i.qt = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedDisabledBackgroundColor", {
/**
* Gets or sets the color to use for the disabled background of the button when the type is outlined.
*/
get: function () {
return brushToString(this.i.qv);
},
set: function (v) {
this.i.qv = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedDisabledBorderColor", {
/**
* Gets or sets the color to use for the disabled border of the button when the type is outlined.
*/
get: function () {
return brushToString(this.i.qw);
},
set: function (v) {
this.i.qw = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedDisabledTextColor", {
/**
* Gets or sets the color to use for the disabled text of the button when the type is outlined.
*/
get: function () {
return brushToString(this.i.qx);
},
set: function (v) {
this.i.qx = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedDisabledElevation", {
/**
* Gets or sets the disabled elevation to use for the button when the type is outlined.
*/
get: function () {
return this.i.dy;
},
set: function (v) {
this.i.dy = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedHoverBackgroundColor", {
/**
* Gets or sets the hover color to use for the background of the button when the type is hoveredOutlined.
*/
get: function () {
return brushToString(this.i.q0);
},
set: function (v) {
this.i.q0 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedBorderColor", {
/**
* Gets or sets the border color to use for the button when the type is outlined.
*/
get: function () {
return brushToString(this.i.qu);
},
set: function (v) {
this.i.qu = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedRestingElevation", {
/**
* Gets or sets the elevation to use for the button when the type is outlined.
*/
get: function () {
return this.i.d1;
},
set: function (v) {
this.i.d1 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedHoverElevation", {
/**
* Gets or sets the hover elevation to use for the button when the type is outlined.
*/
get: function () {
return this.i.d0;
},
set: function (v) {
this.i.d0 = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedFocusElevation", {
/**
* Gets or sets the focus elevation to use for the button when the type is outlined.
*/
get: function () {
return this.i.dz;
},
set: function (v) {
this.i.dz = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedBorderWidth", {
/**
* Gets or sets the width to use for the button border when the type is outlined.
*/
get: function () {
return this.i.bz;
},
set: function (v) {
this.i.bz = +v;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedCornerRadiusBottomRight", {
get: function () {
return this.i.lb ? this.i.lb.c : NaN;
},
set: function (v) {
this.ensureOutlinedCornerRadius();
this.i.lb.c = +v;
this.i.lb = this.i.lb;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedCornerRadiusBottomLeft", {
get: function () {
return this.i.lb ? this.i.lb.b : NaN;
},
set: function (v) {
this.ensureOutlinedCornerRadius();
this.i.lb.b = +v;
this.i.lb = this.i.lb;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedCornerRadiusTopLeft", {
get: function () {
return this.i.lb ? this.i.lb.d : NaN;
},
set: function (v) {
this.ensureOutlinedCornerRadius();
this.i.lb.d = +v;
this.i.lb = this.i.lb;
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedCornerRadiusTopRight", {
get: function () {
return this.i.lb ? this.i.lb.e : NaN;
},
set: function (v) {
this.ensureOutlinedCornerRadius();
this.i.lb.e = +v;
this.i.lb = this.i.lb;
},
enumerable: false,
configurable: true
});
IgxXButtonComponent.prototype.ensureOutlinedCornerRadius = function () {
if (this.i.lb) {
return;
}
this.i.lb = new CornerRadius(2);
};
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedRippleColor", {
/**
* Gets or sets the color to use for the background when the button is pressed and the type is floating action button.
*/
get: function () {
return brushToString(this.i.q2);
},
set: function (v) {
this.i.q2 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXButtonComponent.prototype, "outlinedTextColor", {
/**
* Gets or sets the color to use for the text of the button when type is outlined.
*/
get: function () {
return brushToString(this.i.q3);
},
set: function (v) {
this.i.q3 = stringToBrush(v);
},
enumerable: false,
configurable: true
});
Object.defineProperty(IgxXBu