Im creating a twitter bot to make comments for me on twitter. I've got it to login and everything but to make a comment the attribute for the text box is a <br>
.
This is the html attribute for the comment field
<br data-text="true">
this is the full HTML for the <div>
that the <br>
is in
<div class="r-1niwhzg r-17gur6a r-1yadl64 r-deolkf r-homxoj r-poiln3 r-7cikom r-1ny4l3l r-t60dpp r-1ttztb7" style="max-height: 720px; min-height: 24px;">
<div class="DraftEditor-root">
<div class="public-DraftEditorPlaceholder-root">
<div class="public-DraftEditorPlaceholder-inner" id="placeholder-227pg" style="white-space: pre-wrap;">Tweet your reply
</div>
</div>
<div class="DraftEditor-editorContainer">
<div aria-activedescendant="typeaheadFocus-0.9783065535277462" aria-autocomplete="list" aria-controls="typeaheadDropdownWrapped-0" aria-describedby="placeholder-227pg" aria-label="Tweet text" aria-multiline="true" class="notranslate public-DraftEditor-content" contenteditable="true" data-testid="tweetTextarea_0" role="textbox" spellcheck="true" tabindex="0" no-focuscontainer-refocus="true" style="outline: none; user-select: text; white-space: pre-wrap; overflow-wrap: break-word;">
<div data-contents="true">
<div class="" data-block="true" data-editor="227pg" data-offset-key="1d4tg-0-0">
<div data-offset-key="1d4tg-0-0" class="public-DraftStyleDefault-block public-DraftStyleDefault-ltr">
<span data-offset-key="1d4tg-0-0">
<br data-text="true">
</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
I've tried coping the Xpath but that didn't work. Also copying xpath for me hasn't been working when trying to login so I had to find element by name but I still don't know how to do this. I also couldn't find any information online.