-
-
Notifications
You must be signed in to change notification settings - Fork 576
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
Issues when terminal is inside SVG #744
Comments
There are two types of issues.
|
jQuery closed the issue, there are two problems here:
The solution is to get the pixel density of HTML inside SVG. <div class="pixel" style="width: 1px; height: 1px"></div> var pixel = self.find('.pixel').get(0).getBoundingClientRect(); on Codpen demo the pixel is 3px in size. |
Working demo: https://terminal.jcubic.pl/laptop/ |
Issue summary
Pixel calculations are way off when inside SVG
Expected behavior
There should be an easy way to use jQuery Terminal inside SVG
Actual behavior
padding, margins, scrollbar, character size are way too big
Steps to reproduce
Aditional findings (after fix)
Links have very big underlines (they need to be created by hand).(Google Chrome bug)terminal-scroll-marker
element is way to big (have 20px but scaled).Spacing between the lines.Browser bugThe text was updated successfully, but these errors were encountered: