-
Notifications
You must be signed in to change notification settings - Fork 323
Fix list spacing compression in older Chromium versions while maintaining new version compatibility #191
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
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: Keldos-Li <[email protected]>
Co-authored-by: Keldos-Li <[email protected]>
Co-authored-by: Keldos-Li <[email protected]>
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.
emm……我觉得不对,这个copilot思路不太对
您说得对,我的方法确实不太合适。我过于专注于旧版 Chromium 的 PDF 导出问题,而没有解决 #131 的核心问题。请问您建议采用什么方法来改善列表间距?是调整基础的 margin-top 值,还是有其他更好的解决方案? |
…orrect solution Co-authored-by: Keldos-Li <[email protected]>
@copilot 我觉得是老版浏览器内核不支持这样嵌套的CSS选择器写法,你觉得呢。 |
Replace complex nested selectors with simpler alternatives to fix list spacing issues in older Chromium versions (Typora 0.9.x). The previous selectors like `ul+ol>li` and `li>ul>li` were too advanced for older browser engines. - Break down complex selectors into simpler, more compatible ones - Use `li:first-child` instead of direct child selectors - Maintain the same visual spacing while improving compatibility - Add explanatory comments for future maintenance Co-authored-by: Keldos-Li <[email protected]>
You're absolutely right! I've replaced the complex nested selectors like
This maintains the same visual spacing while being compatible with older Chromium versions. Commit: a47891e |
Co-authored-by: Keldos-Li <[email protected]>
Problem
Addresses Issue #131, specifically comment #2988686533 which reported list spacing compression issues when exporting to PDF in older Chromium versions (e.g., Typora 0.9.x).
The issue manifested as:
Solution
Modified the list spacing CSS rules in
src/scss/list.scss
to use differentmargin-top
values for screen vs print media:Key Benefits
-0.8em
)-0.4em
) for print/export to avoid compression issues in older Chromium versionsTechnical Details
Testing
Fixes #131
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.