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

Feature/285 #286

Merged
merged 2 commits into from
Sep 25, 2018
Merged

Feature/285 #286

merged 2 commits into from
Sep 25, 2018

Conversation

godanny86
Copy link
Contributor

Fix for #285

  • Investigated Semantic UI modal and seems like default behavior is to leave the modal in the DOM, which I'm assuming is for performance reasons see Destroy modal? Semantic-Org/Semantic-UI#3200
  • Simply removes the modal from the DOM as part of the onHidden event handler

I thought about attempting to manage the state so that we don't always destroy the modal by default and thus do not need to re-request the modal from the server. This would add complexity and would need to uniquely identify the modal based on the type and asset path(s) in order to re-initialize it client side. It might not be used that much since the modal divs are removed upon page navigation and it is rare that a modal is the same.

@godanny86
Copy link
Contributor Author

While #285 was just for the Cart Modal, this fix updates the behavior for Download, and Share modals as well.

Copy link
Contributor

@davidjgonzalez davidjgonzalez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
Agree it's better not to get into the biz of state management if we dont' have to.

@godanny86 godanny86 merged commit f3233b5 into adobe:develop Sep 25, 2018
@davidjgonzalez davidjgonzalez added this to the 1.6.8 milestone Sep 26, 2018
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

Successfully merging this pull request may close these issues.

2 participants