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

feat: support custom widget button rendering #97

Merged
merged 1 commit into from
Feb 27, 2024
Merged

Conversation

AhyoungRyu
Copy link
Collaborator

Added renderWidgetToggleButton prop to enable custom widget toggle button rendering. The usage would be like

<ChatAiWidget
   renderWidgetToggleButton={(props) => (
     <div className="chatbot-button-area">
       <button
         onClick={props.onClick}
         className={`chatbot-icon ${props.isOpen ? 'on' : 'off'}`}
       >
          <span className="chatbot-icon-content">
           {props.isOpen ? 'CLOSE' : 'OPEN'}
          </span>
       </button>
      </div>
    )}
/>

@AhyoungRyu
Copy link
Collaborator Author

Let me update the README in the following PR.

@AhyoungRyu AhyoungRyu mentioned this pull request Feb 27, 2024
@AhyoungRyu AhyoungRyu merged commit 50191f2 into develop Feb 27, 2024
@AhyoungRyu AhyoungRyu deleted the feat/AC-1504 branch February 27, 2024 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants