Merged
Conversation
add method observeChanges()
mvorisek
reviewed
Oct 2, 2022
| */ | ||
| public function observeChanges() | ||
| { | ||
| $this->setOptions(['observeChanges' => true]); |
Member
There was a problem hiding this comment.
Hello @lubber-de, when is observeChanges: false helpful? Are there any negative performance/functional implications when set observeChanges: true by default?
the only related discussion I found: fomantic/Fomantic-UI#564
There was a problem hiding this comment.
observeChanges is also helpful if your code possibly changes input fields (adding/removing) to make sure focus trap will remain working. fomantic/Fomantic-UI#2036
If setting this to true by default might has a signifant performance impact depends on how complex your code/Dom is.
https://stackoverflow.com/questions/31659567/performance-of-mutationobserver-to-detect-nodes-in-entire-dom
This was referenced Oct 2, 2022
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New method Modal::observeChanges()
Shortcut method to add observeChanges setting in semantic-ui modal.
observesChange setting allow for re positioning when DOM content changes in modal.
See example in issue: #324