Make step to center dynamically when steps are modal with different sizes #89
-
I have a scenario to display some modals as steps in between. And those modals are of different width and heights. So I need these steps (modals) displayed in the middle of the screen. It is not working with the below CSS: .centered-tour-element { The above one might work only for one size. But we have many modals with each modal having different sizes. I have tried various ways, but I want to make this generic. I have seen that the modal element is updated with the inline style (justifyContent: 'flex-start'). This has to be centered and those styles are not getting updated by using the following code this.tourService. stepShow $.subscribe(() => But the above code is not updating the inline style of the modal. I tried to append the class to the classList. But it only works for the first modal and does not apply to the second modal. I think the library should provide a way to override the inline style or should be able to add a class as a property while initializing the service for each step. Please provide this feature. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
Instead of |
Beta Was this translation helpful? Give feedback.
-
From the developer tools, I have updated align-items as 'center' to the modal and it is working fine then. I think if we give a provision to the user to provide the align-item as a property, |
Beta Was this translation helpful? Give feedback.
-
You can try sth like |
Beta Was this translation helpful? Give feedback.
You can try sth like
setTimeout(() => this.centerStep(), 20)
.Anyway, I don't have any plans to implement tour step centering in this library and prefer the step positioning to be handled by 3rd party component library.