-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tag base element #2
Comments
OK create a PR so I know what you mean |
(ChatGPT Widescreen uses get button with class containing bottom in form) |
like this: // Use the added functions to get the elements
const submitButton = chatgpt.getSubmitButton();
const textarea = chatgpt.getTextarea();
const regenerateButton = chatgpt.getRegenerateButton();
const stopGeneratingButton = chatgpt.getStopGeneratingButton();
const newChatButton = chatgpt.getNewChatButton();
// Assign reasonable IDs to the elements
submitButton.id = 'chatgpt-submit-button';
textarea.id = 'chatgpt-textarea';
regenerateButton.id = 'chatgpt-regenerate-button';
stopGeneratingButton.id = 'chatgpt-stop-generating-button';
newChatButton.id = 'chatgpt-new-chat-button'; |
or make it an init method? Seems not good if adding runtime to a package |
I like your first idea, also using |
Rojojun
added a commit
to Rojojun/chatgpt.js
that referenced
this issue
Jul 14, 2023
Rojojun
added a commit
to Rojojun/chatgpt.js
that referenced
this issue
Jul 14, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Cause ChatGPT web is using Tailwind, if we pre-tag elements with id, it will make other scripts' development easier.
Such as, I used to get sendButton by the last button in the form, but after installing the wide-screen mode script, that function actually returned the wrong button.
this should not be much work, cause can use the function defined in #1
The text was updated successfully, but these errors were encountered: