[GH-ISSUE #1511] [FEAT]: HTML Embeds - Please add a way to give the generated div a specific class name or ID? #970

Closed
opened 2026-02-22 18:22:28 -05:00 by yindo · 7 comments
Owner

Originally created by @atljoseph on GitHub (May 23, 2024).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1511

What would you like to see?

When I use the html chat embedding feature, it works, but at some points we would like to manipulate the div position or visibility or existence of the div that is generated by the embed js script. It turns out that the div doesn’t have a class name or other identifying features. Was able to write a script to go a few layers deep and find one class named anything-LLM-chat, but it’s kind of a hacky thing to do. Would be nice to have a configuration for the outputted div. Thanks for the other configurations that are there. Just looking for one more :)

Originally created by @atljoseph on GitHub (May 23, 2024). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1511 ### What would you like to see? When I use the html chat embedding feature, it works, but at some points we would like to manipulate the div position or visibility or existence of the div that is generated by the embed js script. It turns out that the div doesn’t have a class name or other identifying features. Was able to write a script to go a few layers deep and find one class named anything-LLM-chat, but it’s kind of a hacky thing to do. Would be nice to have a configuration for the outputted div. Thanks for the other configurations that are there. Just looking for one more :)
yindo added the enhancement label 2026-02-22 18:22:28 -05:00
yindo closed this issue 2026-02-22 18:22:28 -05:00
Author
Owner

@atljoseph commented on GitHub (May 23, 2024):

Even if the config set a tag’s id attribute, that’d be awesome too.

@atljoseph commented on GitHub (May 23, 2024): Even if the config set a tag’s id attribute, that’d be awesome too.
Author
Owner

@timothycarambat commented on GitHub (May 23, 2024):

Which element? The toggle to open the window or the window itself?
The window has a tag:
https://github.com/Mintplex-Labs/anything-llm/blob/acbad2f2cf7c13e03e0a0dc1067041ba4c59930c/embed/src/App.jsx#L43

@timothycarambat commented on GitHub (May 23, 2024): Which element? The toggle to open the window or the window itself? The window has a tag: https://github.com/Mintplex-Labs/anything-llm/blob/acbad2f2cf7c13e03e0a0dc1067041ba4c59930c/embed/src/App.jsx#L43
Author
Owner

@atljoseph commented on GitHub (May 23, 2024):

Was looking at the top level document body div it makes. I guess we could just do a remove for that selector

@atljoseph commented on GitHub (May 23, 2024): Was looking at the top level document body div it makes. I guess we could just do a remove for that selector
Author
Owner

@timothycarambat commented on GitHub (May 23, 2024):

I think if anything we can add one to the floating button as well, that should be there as well

@timothycarambat commented on GitHub (May 23, 2024): I think if anything we can add one to the floating button as well, that should be there as well
Author
Owner

@atljoseph commented on GitHub (May 25, 2024):

One more curiosity.

(1) Is there a way we can refer to the sessionID in any of the inputs? Example:

  • Allow us to set data-sponsor-link="https://something.com?chat_session_id=SESSION_ID".
  • Have the script fill in the sessionID.
    Would you be willing to do that?
  • RE: README.md

(2) Would be really useful to be able to search embed chat history by sessionID.

  • Also, can't really see the whole sessionID.
    image

(3) Is there a way to customize the message that shows up when the quota for the embed session has been surpassed?

  • To a customer, it might appear like we didn't pay our bill, and we want to let them know in a diplomatic way that their number of chats are limited... while also not appearing inept.
    image

Our support team would be very pleased with these small improvements :)
❤️

@atljoseph commented on GitHub (May 25, 2024): One more curiosity. (1) Is there a way we can refer to the sessionID in any of the inputs? Example: - Allow us to set `data-sponsor-link="https://something.com?chat_session_id=SESSION_ID"`. - Have the script fill in the sessionID. Would you be willing to do that? - RE: [README.md](https://github.com/Mintplex-Labs/anything-llm/blob/master/embed/README.md#script-customization-options) (2) Would be really useful to be able to search embed chat history by sessionID. - Also, can't really see the whole sessionID. ![image](https://github.com/Mintplex-Labs/anything-llm/assets/25017621/ea7290e7-da83-45c2-88dc-6f50ace1a349) (3) Is there a way to customize the message that shows up when the quota for the embed session has been surpassed? - To a customer, it might appear like we didn't pay our bill, and we want to let them know in a diplomatic way that their number of chats are limited... while also not appearing inept. ![image](https://github.com/Mintplex-Labs/anything-llm/assets/25017621/22104047-604b-4635-ad1b-993066a6db46) Our support team would be very pleased with these small improvements :) ❤️
Author
Owner

@timothycarambat commented on GitHub (May 25, 2024):

@atljoseph lets make that a new issue for feature request - it will get lost in a closed comment thread

@timothycarambat commented on GitHub (May 25, 2024): @atljoseph lets make that a new issue for feature request - it will get lost in a closed comment thread
Author
Owner

@atljoseph commented on GitHub (May 26, 2024):

Moved to https://github.com/Mintplex-Labs/anything-llm/issues/1544

@atljoseph commented on GitHub (May 26, 2024): Moved to https://github.com/Mintplex-Labs/anything-llm/issues/1544
yindo changed title from [FEAT]: HTML Embeds - Please add a way to give the generated div a specific class name or ID? to [GH-ISSUE #1511] [FEAT]: HTML Embeds - Please add a way to give the generated div a specific class name or ID? 2026-06-05 14:38:13 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#970