* Return the AutoNumeric object that manages the given DOM element. * This function also accepts a selector string. * * @param {HTMLElement|string} domElementOrSelector Accepts either directly a DOM element to test, or a string selector (that will return one and only one element, if a
(domElementOrSelector)
| 4675 | * @returns {null|AutoNumeric} |
| 4676 | */ |
| 4677 | static getAutoNumericElement(domElementOrSelector) { |
| 4678 | const domElement = AutoNumericHelper.domElement(domElementOrSelector); |
| 4679 | |
| 4680 | if (!this.isManagedByAutoNumeric(domElement)) { |
| 4681 | return null; |
| 4682 | } |
| 4683 | |
| 4684 | return this._getFromGlobalList(domElement); |
| 4685 | } |
| 4686 | |
| 4687 | /** |
| 4688 | * Set the given element value, and format it immediately. |