Skip to content
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

Chat window not opening when click on bubble #310

Open
viraj-glide opened this issue Jun 11, 2022 · 3 comments
Open

Chat window not opening when click on bubble #310

viraj-glide opened this issue Jun 11, 2022 · 3 comments

Comments

@viraj-glide
Copy link

import { Widget } from "react-chat-widget";
import "react-chat-widget/lib/styles.css";

export default function App() {
return (

<Widget />

);
}

@viraj-glide viraj-glide changed the title window not opening when click on bubble Chat window not opening when click on bubble Jun 11, 2022
@movvav
Copy link

movvav commented Jun 21, 2022

Check you react version. It didn't work for me w React 18.
After downgrading to React 17, I was able to get it working

@MrFarhan
Copy link

Right, it doesn't work with React 18 but works with previous versions.

@integratedpartners
Copy link

integratedpartners commented Jan 2, 2023

Is this package still maintained? React 18 version would be very helpful. As a workaround, you can control it manually like this:

  import { React, useEffect, useState } from "react";
  const [chatWindowOpen, setChatWindowOpen] = useState(true);

  const handleToggle = (chatWindowOpen) => {
    setChatWindowOpen(!chatWindowOpen);
  };

  <Widget
  handleNewUserMessage={handleNewUserMessage}
  handleToggle={handleToggle}
/>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants