Hi,
I am developing my own custom widget for use in WAB. I have this button:
Solved! Go to Solution.
I have a function to enable my buttons that applies a jimu css class
_enableBtn(btn, isEnable) {
if (btn) {
if (isEnable) {
html.removeClass(btn, "jimu-state-disabled");
} else {
html.addClass(btn, "jimu-state-disabled");
}
}
}
Here's how I have a button set up in my html file:
<div data-dojo-attach-point="btnApplyCoins" id="coinsbtn" class="jimu-btn apply"
data-dojo-attach-event="onclick:applyEdits" style="margin-top: 10px">
${nls.applyCoins}
</div>
And here's how I call the enable function
this._enableBtn(this.btnApplyCoins, isEnable);
I have a function to enable my buttons that applies a jimu css class
_enableBtn(btn, isEnable) {
if (btn) {
if (isEnable) {
html.removeClass(btn, "jimu-state-disabled");
} else {
html.addClass(btn, "jimu-state-disabled");
}
}
}
Here's how I have a button set up in my html file:
<div data-dojo-attach-point="btnApplyCoins" id="coinsbtn" class="jimu-btn apply"
data-dojo-attach-event="onclick:applyEdits" style="margin-top: 10px">
${nls.applyCoins}
</div>
And here's how I call the enable function
this._enableBtn(this.btnApplyCoins, isEnable);
Hi @KenBuja ,
This was exactly what i needed! Only thing that missed was to add the module