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.
High-level description of change
Fixes #738
When the HTML editor is drag-resized by the user, the height always returns to 400. This PR attempts to fix that by setting the default height to the current height if it exists when resizing.
Are there performance implications for this change?
No. This is a very small change.
Have you added tests to cover this new/updated code?
No. No intended functionality was changed.
Risks involved
This change shouldn't carry any risks as long as the editor height is always either falsey or a number, or a height is passed to the function. From what I can tell, the only time the height isn't passed to the function is when the user resizes it.
Are there any dependencies or blockers for merging this?
No.
How can we verify that this change works?
I can't verify that this doesn't break anything on page load because the horizontal resize code appears to be in a different repo, but I tested the updated function in production by pasting it into the Javascript console on any resized webpage program, then resizing it.