Set Features
Set Features
InfoRemember to use it after chat was loaded and ready method is already running.
setFeatures turns parts of the widget on or off from your page. Pass an object with one or more of the flags below.
tidioChatApi.setFeatures({
hideChatWithUsOnHome: true,
hideNavigationOnHome: true,
});| Flag | Type | Default | What it does |
|---|---|---|---|
mobileHash | boolean | true | The widget's own URL hash on mobile. See below |
widgetLabelStatus | boolean | false | Shows the label next to the chat bubble. Desktop only |
widgetLabelText | string | '' | Replaces the label text |
prechatSubscriptionCheckboxDefaultValue | boolean | false | Pre-ticks the newsletter checkbox in the pre-chat survey |
hideChatWithUsOnHome | boolean | false | Hides the "Chat with us" block on the home screen |
hideNavigationOnHome | boolean | false | Hides the Home and Chat buttons at the bottom of the home screen |
largeCustomBranding | boolean | false | Shows your branding logo larger on the home screen |
Keys outside this list are ignored. You can call the method more than once, and each call only changes the flags you pass.
tidioChatApi.setFeatures({ widgetLabelStatus: true });
tidioChatApi.setFeatures({ widgetLabelText: 'Need help?' });Sites that use the URL hash
On mobile the widget adds #mobile-widget to the address while the chat is open, and closes the chat when that hash goes away. If your page changes the hash itself, the chat can close right after the visitor opens it. Turn the mechanism off:
(function () {
function onTidioChatApiReady() {
window.tidioChatApi.setFeatures({ mobileHash: false });
}
if (window.tidioChatApi) {
window.tidioChatApi.on('ready', onTidioChatApiReady);
} else {
document.addEventListener('tidioChat-ready', onTidioChatApiReady);
}
})();Updated 2 days ago
Did this page help you?