Skip to content

Modal Dialog/Prompt Appears in Main Screen Instead of Popout Window #938

Closed Answered by GerardasB
avinash-bsy asked this question in Q&A
Discussion options

You must be logged in to vote

Hey, what APIs exactly are you using, could you try using the iTwinUI Dialog (make sure portal prop is set to true or use the Modal dialog), it should automatically append itself to the correct document based on the portalContainer of a wrapping ThemeProvider.
Alternatively, if you are using UiFramework.dialogs.modal.open() it takes a parentDocument?: Document as a third argument. You could get a ref to one of the HTML elements in your widget and use ownerDocument to specify that arg.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@avinash-bsy
Comment options

@GerardasB
Comment options

Answer selected by GerardasB
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants