Hello everyone. New to the community as well as learning html for it. I was building an image generator purely from html css and js.
I have a div with some text inside it. This is not a textarea, just a div with text dynamically updated.
How can I use this text as Prompt?
I saw another generator without a framework that uses this, but on a textarea.
<textarea oninput="promptData.prompt=this.value"placeholder="prompt"></textarea>
while i want to set value from this div as prompt
<div id="positivePrompt" class="prompt-text">
${patterns.positive}
</div>
Please guide or point me somewhere. Thanks
Is this what you need?
No. I mean how to use the text inside a div as an image generation prompt.
I think I understand, try -> https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/contenteditable
<div contenteditable="true"> some starter text </div>