Font Family Analysis Report
Current Font Settings
1. Main Body Font (body-main-styles.scss)
Location: assets/_scss/default/body-main-styles.scss (line 35)
font-family: "Roboto", sans-serif;
Applied to: The main body element of the website
2. Content/Markdown Font (markdown-style.scss)
Location: assets/_scss/common/markdown-style.scss
Multiple declarations using the same font stack:
font-family: Helvetica, Tahoma, Arial, STXihei, "华文细黑", "Microsoft YaHei", "微软雅黑", sans-serif;
Applied to:
- Table cells and headers (line 27)
- Paragraphs, lists, and list items (line 49)
- Blockquotes (line 85)
- Code blocks and highlights (line 135)
3. Bootstrap Default Font
Location: assets/css/bootstrap.min.css
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
Applied to: Bootstrap components (body default, tooltips, popovers, etc.)
Analysis
Current Issues
- Inconsistent Font Families
- Body uses “Roboto” (Google Font)
- Content uses a Chinese-English hybrid stack starting with Helvetica
- This creates visual inconsistency between different sections
- Missing Font Loading
- Roboto is declared but I don’t see a clear @import or for Google Fonts
- This could cause fallback to generic sans-serif
- Mixed Language Support
- The content font stack includes Chinese fonts (STXihei, 华文细黑, Microsoft YaHei)
- This is good for bilingual support but creates a complex fallback chain
- Outdated Font Stack
- Using older fonts like Tahoma and Arial as primary choices
- Not leveraging modern, more readable web fonts
Recommendations
Option 1: Modern, Clean Approach (Recommended)
Best for: Professional, modern look with excellent readability
Body Font:
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
Content Font:
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Noto Sans SC", "Microsoft YaHei", sans-serif;
Advantages:
- Uses system fonts for optimal performance (no external font loading)
- Native look and feel on each platform
- Excellent Chinese character support with Noto Sans SC
- Zero latency (fonts are already on user’s device)
- Better accessibility
Option 2: Google Fonts Approach
Best for: Distinctive brand identity with custom typography
Body Font (elegant serif for headings):
font-family: "Playfair Display", Georgia, serif;
Content Font (clean sans-serif for body):
font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans SC", "Microsoft YaHei", sans-serif;
Advantages:
- Professional, designer-curated fonts
- Excellent readability
- Inter is specifically optimized for UI
- Would need to add Google Fonts import
Option 3: Enhanced Current Setup
Best for: Minimal changes while improving current setup
Body Font:
font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
Content Font:
font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans SC", "Microsoft YaHei", "微软雅黑", sans-serif;
Advantages:
- Maintains consistency between body and content
- Improves fallback chain with modern system fonts
- Keeps current Roboto choice
- Better Chinese font support
Implementation Priorities
High Priority
- Ensure font consistency - Use the same base font family for body and content
- Add proper fallback chain - Include system fonts for better performance
- Verify font loading - If using Roboto, ensure it’s properly loaded via Google Fonts
Medium Priority
- Improve Chinese font support - Consider Noto Sans SC or Source Han Sans
- Optimize code font - Use a proper monospace font stack for code blocks
- Test across devices - Verify appearance on Windows, Mac, iOS, Android
Low Priority
- Consider variable fonts - For better weight control and performance
- Add font display strategy - Use
font-display: swapto avoid FOIT - Subset fonts - If using web fonts, only load required characters
Recommended Action Plan
Step 1: Quick Win (5 minutes)
Update both locations to use a unified, modern font stack:
File: assets/_scss/default/body-main-styles.scss
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
File: assets/_scss/common/markdown-style.scss (4 locations)
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", "Microsoft YaHei", sans-serif;
Step 2: If Using Custom Fonts (Optional)
If you want to use Google Fonts (Roboto or Inter), add to your HTML head:
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap" rel="stylesheet">
Step 3: Code Font Enhancement (Already Implemented)
Our implementation uses a proper monospace stack:
font-family: "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, "Courier New", monospace;
This provides excellent monospace rendering on all platforms:
- macOS/iOS: SF Mono
- Windows: Cascadia Code (Windows Terminal font) or Consolas
- Android: Roboto Mono
- Universal fallback: Courier New
Typography Best Practices
- Line Height: Your current 2.7rem (line 52 in markdown-style.scss) is excellent for readability
- Font Size: Current base of 1.5rem for content is good
- Font Weight: Using 300 for body text is good for modern fonts, but may be too light for some users
- Consider: Adding font-weight: 400 for better readability
Browser Support
All recommended fonts have excellent support:
- System fonts: 100% (native to OS)
- Google Fonts: 99%+ (with proper fallbacks)
- Chinese fonts: 95%+ on Chinese systems
Performance Impact
Current Setup
- If Roboto loads: ~15-30KB per weight
- If falls back to system: 0KB
Recommended (System Fonts Only)
- Download size: 0KB
- Load time: Instant
- Performance: Optimal
Google Fonts Approach
- Download size: ~30-100KB (depending on weights)
- Load time: 100-300ms
- Performance: Good with preconnect
Conclusion
My recommendation is Option 1 (Modern, Clean Approach) because:
- ✅ Zero performance impact
- ✅ Native look on all platforms
- ✅ Excellent Chinese support
- ✅ Future-proof
- ✅ Accessibility-friendly
- ✅ No external dependencies
This would make your site feel fast, modern, and native on every device while maintaining excellent readability for both English and Chinese content.