-
Notifications
You must be signed in to change notification settings - Fork 86
Closed
Description
Goal
Configuration UI
Issue
I would like to add input event to the input element, but it didn't work and didn't log any thing. The code in the file configure.phtml:
<script defer="defer" async="async">
'use strict'
console.log('load the openai extension configure page');
(function() {
console.log('add output event');
function _addOutputEvent(element) {
console.log('element:', element);
if (element === null) return;
element.addEventListener('input', function() {
this.nextElementSibling.value = this.value;
console.log(this.id, this.value);
});
}
_addOutputEvent(document.getElementById('max_tokens'));
_addOutputEvent(document.getElementById('temperature'));
})();
</script>
Appreciate for any help.
Metadata
Metadata
Assignees
Labels
No labels

