mirror of
https://github.com/changkun/modern-cpp-tutorial.git
synced 2025-12-17 12:44:40 +03:00
see #12: support english website
This commit is contained in:
@@ -1,11 +1,28 @@
|
||||
<div class="sidebar">
|
||||
<div class="sidebar-inner">
|
||||
<ul class="main-menu">
|
||||
<%- partial('partials/main_menu', { context: 'sidebar' }) %>
|
||||
<% if (page.type == 'book-en-us') { %>
|
||||
<%- partial('partials/main_menu_en', { context: 'nav' }) %>
|
||||
<% } else {%>
|
||||
<%- partial('partials/main_menu', { context: 'nav' }) %>
|
||||
<% } %>
|
||||
</ul>
|
||||
<div class="list">
|
||||
<h2>
|
||||
<%-
|
||||
<% if (page.type == 'book-en-us') { %>
|
||||
<%-
|
||||
type === 'exercises'
|
||||
? 'Exercises'
|
||||
: type === 'book-zh-cn'
|
||||
? 'Main'
|
||||
: type === 'answers'
|
||||
? 'Reference Answers'
|
||||
: type === 'about'
|
||||
? 'About'
|
||||
: (type.charAt(0).toUpperCase() + type.slice(1))
|
||||
%>
|
||||
<% } else {%>
|
||||
<%-
|
||||
type === 'exercises'
|
||||
? '习题'
|
||||
: type === 'book-zh-cn'
|
||||
@@ -15,7 +32,8 @@
|
||||
: type === 'about'
|
||||
? '关于'
|
||||
: (type.charAt(0).toUpperCase() + type.slice(1))
|
||||
%>
|
||||
%>
|
||||
<% } %>
|
||||
</h2>
|
||||
<%- partial('partials/toc', { type: type }) %>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user