-
-
Notifications
You must be signed in to change notification settings - Fork 186
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
Add move-in animation #511
base: main
Are you sure you want to change the base?
Conversation
@byOsta I appreciate this has been almost a year, but if you would be happy to resolve the conflicts we can get this merged. |
Resolved conflicts @chrissainty :). This PR also fixes @0ptim PRs #558 by setting the default |
<div> | ||
<CascadingValue Value="this" IsFixed="true"> | ||
@Content | ||
</CascadingValue> | ||
</div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is the div
tag needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing it doesn't seem to effect anything
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is needed for the css to be applied to CustomLayouts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In what way? Just when it's removed everything looks to continue working as it did before and there doesn't seem to be any references to this element in the CSS, unless I've missed it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
About the div...
This is without the div:
https://github.com/Blazored/Modal/assets/8792259/b1a629dd-fad1-4f51-9284-cc8765527ad1
This is with the div
https://github.com/Blazored/Modal/assets/8792259/4d12827a-e820-425f-bb6d-7191d8bcb945
Why does this happen?
Because of the Blazor CSS isolation
Without this change the custom layout that we have for the modals wont have the custom BlazoredModalInstance.razor.css
styles applied...
I also had to add the following selectors on the BlazoredModalInstance.razor.css
:
While testing I noticed that the move out animation doesn't seem to work. The move-in part works fine, but when dismissing the modal it just fades out a bit rather than sliding up. |
Regarding this, yeah I noticed that too. I'm trying to debug it because it was working with the PR that I raised a year ago jajaja |
Whatever has changed has effected all the other animations as well, they all just fade out now rather than animate out. |
After reviewing what breaks it is this commit |
With this commit it's fixed. |
<div> | ||
<CascadingValue Value="this" IsFixed="true"> | ||
@Content | ||
</CascadingValue> | ||
</div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In what way? Just when it's removed everything looks to continue working as it did before and there doesn't seem to be any references to this element in the CSS, unless I've missed it?
Add following animations:
The move animations are a copy from the bootstrap ones.
Also add compatibility with animations on CustomLayouts if needed by adding the
OverlayAnimationClass
andModalAnimationClass
e74640a6cb22bc29d24cd4ed628a37a4.mp4