UNPKG

react-antd-admin-panel

Version:

Easy prototyping admin panel using React and Antd

44 lines 1.66 kB
import Default from "./Default"; export default class Button extends Default { constructor() { var _a; super('Button'); this._trigger = false; this.setLoading = () => { }; this.tsxSetType = () => { }; this.tsxSetStyle = () => { }; this._loadable = false; this._link = false; this._danger = false; this._block = false; this._ignoreClear = false; this._primary = false; this._menu = false; this.env = JSON.parse((_a = window.localStorage.getItem('env')) !== null && _a !== void 0 ? _a : '{}'); this.middle(); } trigger() { this._trigger = true; return this; } round() { this.shape('round'); return this; } small() { this.sizeString('small'); return this; } middle() { this.sizeString('middle'); return this; } loadable(v) { this._loadable = v; return this; } icon(v) { this._icon = v; return this; } fontawesome(v) { this._fontawesome = v; return this; } shape(value) { this._shape = value; return this; } link(value) { this._link = (!value) ? true : value; return this; } danger(value) { this._danger = (!value) ? true : value; return this; } block(value) { this._block = (!value) ? true : value; return this; } ignoreClear(value) { this._ignoreClear = (!value) ? true : value; return this; } primary(value) { this._primary = (!value) ? true : value; return this; } menu(value) { this._menu = (!value) ? true : value; return this; } } //# sourceMappingURL=Button.js.map