This document explains the questions about JavaScript SDK(”SDK” below).
How to distinguish a member and a non-member
The SDK distinguishes a member user and an unknown user(non-member) based on whether to set memberId to boot option when boot.
See boot for more details.
How to set a user’s profile without a user’s behavior
See the boot code for a member user in boot.
An error occurs when opening chat on webview.
A chat is opened in a new tab by default.
So when the permission on opening a new tab is not set properly, an error can occur.
To use the SDK on webview, see Quickstart(webview).
If you have trouble setting permission on opening a new tab, you can use mobileMessengerMode of boot option instead.
If you set
mobileMessengerMode
to‘iframe’
, a chat is opened in the iframe of the same tab.
How to set the position of a channel button
Set the position of a channel button at Channel settings > General > Manage Plug-in > Web Plugin Setting of the desk.
How to change the image of a channel button
Set the image of a channel button at Channel settings > General > Manage Plug-in > Web Plugin Setting of the desk.
How to use the HTML elements as the channel button
See how to customize channel button.
How to select HTML elements in SDK by CSS Selector
The SDK doesn’t provide CSS selectors to select the HTML elements like the channel button, the messenger, etc.
Don’t use the id and class of the HTML elements of SDK as the CSS selector.
These values are subject to change without a notice.
channel buttons, messengers, etc. are hidden behind certain elements of the website
By setting zIndex of boot option, you can change z-index of the HTML elements.
Updated 5 months ago