-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[AC-3505] fix: add root element to full screen component for modal (#329
) ## Changes - Fixed a crash when opening a modal in the full-screen widget (root element for React portal not found). ticket: [AC-3505] [AC-3505]: https://sendbird.atlassian.net/browse/AC-3505?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
- Loading branch information
Showing
3 changed files
with
24 additions
and
18 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import Chat from './Chat'; | ||
import { ChatAiWidgetProps } from './ChatAiWidget'; | ||
import ProviderContainer from './ProviderContainer'; | ||
import { elementIds } from '../../const'; | ||
|
||
/** | ||
* NOTE: External purpose only. | ||
* Do not use this component directly. Use Chat instead for internal use. | ||
*/ | ||
function WidgetWindowFullScreen(props: ChatAiWidgetProps) { | ||
return ( | ||
<ProviderContainer {...props}> | ||
<div | ||
id={elementIds.widgetWindow} | ||
style={{ position: 'fixed', left: 0, top: 0, width: '100%', height: '100%', transform: 'scale(1)' }} | ||
> | ||
<Chat /> | ||
</div> | ||
</ProviderContainer> | ||
); | ||
} | ||
|
||
export default WidgetWindowFullScreen; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters