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

Making the disconnect message editable by the endpoint configuration #38

Open
ymanav opened this issue Nov 5, 2024 · 0 comments
Open

Comments

@ymanav
Copy link

ymanav commented Nov 5, 2024

The overlay that is presented when the user is disconnected during the conversation is coded in a static manner, so it is always in English. When we are serving customers that does not understand English, it distracts customer from the conversation. Is it possible to make it variable based so that it can be edited from the endpoint transformers.

const DisconnectOverlay = ({ isPermanent, onClose, onConnect }) => {
return (
<Wrapper>
<Dialog>
{isPermanent ? (
<>
<DialogHeader>Connection lost</DialogHeader>
{navigator.onLine ? (
<Button onClick={onConnect} color="primary" style={{ margin: "auto" }}>
Reconnect
</Button>
) : (
<div>No network connection</div>
)}
</>
) : (
<div>
<DialogHeader>Connection lost</DialogHeader>
<div>Reconnecting...</div>
</div>
)}
</Dialog>
<HeaderIconButton
data-disconnect-overlay-close-button
onClick={onClose}
className="webchat-header-close-button"
aria-label="Close Warning"
>
<CloseIcon />
</HeaderIconButton>
</Wrapper>
);
};

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

1 participant