Path: blob/master/webroot/rsrc/js/phuix/PHUIXIconView.js
12241 views
/**1* @provides phuix-icon-view2* @requires javelin-install3* javelin-dom4*/56JX.install('PHUIXIconView', {78members: {9_node: null,10_icon: null,11_color: null,1213setIcon: function(icon) {14var node = this.getNode();15if (this._icon) {16JX.DOM.alterClass(node, this._icon, false);17}18this._icon = icon;19JX.DOM.alterClass(node, this._icon, true);20return this;21},2223setColor: function(color) {24var node = this.getNode();25if (this._color) {26JX.DOM.alterClass(node, this._color, false);27}28this._color = color;29JX.DOM.alterClass(node, this._color, true);30return this;31},3233getNode: function() {34if (!this._node) {35var attrs = {36className: 'phui-icon-view phui-font-fa'37};3839this._node = JX.$N('span', attrs);40}4142return this._node;43}44}4546});474849