# Cách bật chế độ tối trên widget live chat?

> Tami · Cập nhật lần cuối ngày 10 thg 4, 2024

Các trang web hiện đại cho phép người dùng chuyển đổi giữa chế độ sáng và tối. Do đó, live chat hoạt động với cả hai giao diện là rất quan trọng. Hướng dẫn này giúp bạn thiết lập chế độ tối cho widget live chat SquareHub trên trang web của bạn.

Để bật chế độ tối trên widget SquareHub, sử dụng tham số `darkMode` cùng với [squarehubSettings](https://docs.squareomni.com/docs/product/channels/live-chat/sdk/setup).

`darkMode` parameter supports two values.

1.  `light` - Enable only light mode. This is the default value.
    
2.  `auto` - Enable dark mode based on the operating system preference.
    

```
window.squarehubSettings = {
  //... other Settings
  darkMode: "auto",
};
```

Note: `dark` only is not supported now. We will add the support in future releases.
