mirror of
https://github.com/gnu4cn/ts-learnings.git
synced 2024-12-26 12:50:31 +08:00
Updated.
This commit is contained in:
parent
fda0bb3ec8
commit
2cf7c867ce
84
book.json
84
book.json
@ -2,14 +2,6 @@
|
||||
"author": "Translated by Peng Hailin, laxers@gmail.com",
|
||||
"description": "这是一本TypeScript编程语言手册",
|
||||
"generator": "xfoss.com 网站",
|
||||
"links": {
|
||||
"sharing": {
|
||||
"weibo": null
|
||||
},
|
||||
"sidebar": {
|
||||
"ts.xfoss.com": "https://ts.xfoss.com/"
|
||||
}
|
||||
},
|
||||
"pdf": {
|
||||
"fontSize": 12,
|
||||
"footerTemplate": null,
|
||||
@ -23,33 +15,71 @@
|
||||
"pageNumbers": false,
|
||||
"paperSize": "a4"
|
||||
},
|
||||
"plugins" : [
|
||||
"plugins": [
|
||||
"highlight-code",
|
||||
"livereload",
|
||||
"lunr",
|
||||
"sharing",
|
||||
"fontsettings",
|
||||
"theme-comscore",
|
||||
"qrcode-list"
|
||||
"include-codeblock@^3.0.2",
|
||||
"tbfed-pagefooter@^0.0.1",
|
||||
"sectionx@^3.1.0",
|
||||
"sitemap",
|
||||
"code",
|
||||
"-lunr",
|
||||
"-search",
|
||||
"-sharing",
|
||||
"-fontsettings",
|
||||
"cuav-chapters",
|
||||
"heading-anchors",
|
||||
"splitter",
|
||||
"theme-door",
|
||||
"search-pro-fixed"
|
||||
],
|
||||
"pluginsConfig": {
|
||||
"qrcode-list": {
|
||||
"title": "打尚&联系",
|
||||
"description": "如果您感觉有收获,欢迎给我打赏,以激励我输出更多的优质内容。",
|
||||
"except": ["谢谢你的支持"],
|
||||
"lists": [
|
||||
"variables": {
|
||||
"doorTheme": {
|
||||
"nav": [
|
||||
{
|
||||
"src": "./images/a6x09981lks9yco3b8xcqf0.png",
|
||||
"content": "支付宝",
|
||||
"alt": "支付宝"
|
||||
"url": "https://java-lang.xfoss.com",
|
||||
"target": "_blank",
|
||||
"name": "学习 Java · ☕"
|
||||
},
|
||||
{
|
||||
"src": "./images/wechat-pay.png",
|
||||
"content": "微信支付",
|
||||
"alt": "微信支付"
|
||||
"url": "https://java-lang.xfoss.com",
|
||||
"target": "_blank",
|
||||
"name": "学习 Java · ☕"
|
||||
},
|
||||
{
|
||||
"url": "https://ccna.xfoss.com",
|
||||
"target": "_blank",
|
||||
"name": "学习 “网络通信” 技术 CCNA · 🖧"
|
||||
},
|
||||
{
|
||||
"url": "https://xfoss.com",
|
||||
"target": "_blank",
|
||||
"name": "捐助,donation · 💰"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"pluginsConfig": {
|
||||
"doorTheme": {
|
||||
"search-placeholder": "请输入关键字搜索",
|
||||
"logo": "./images/typescript-logo.png",
|
||||
"favicon": "./docs/images/typescript-fav-icon.png"
|
||||
},
|
||||
"include-codeblock": {
|
||||
"template": "ace",
|
||||
"unindent": true,
|
||||
"edit": true
|
||||
},
|
||||
"tbfed-pagefooter": {
|
||||
"copyright": "Copyleft @ rust.xfoss.com 2022",
|
||||
"modify_label": "该文件修订时间:",
|
||||
"modify_format": "YYYY-MM-DD HH:mm:ss"
|
||||
},
|
||||
"sectionx": {
|
||||
"tag": "b"
|
||||
},
|
||||
"sitemap": {
|
||||
"hostname": "https://ts-lang.xfoss.com/"
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
BIN
images/typescript-fav-ico.png
Normal file
BIN
images/typescript-fav-ico.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
BIN
images/typescript-logo.png
Normal file
BIN
images/typescript-logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 69 KiB |
12727
package-lock.json
generated
12727
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
26
package.json
26
package.json
@ -6,7 +6,10 @@
|
||||
"scripts": {
|
||||
"gulp": "gulp",
|
||||
"start": "live-server dist/",
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
"sl-checkout": "sl pull && sl go main",
|
||||
"sl-push": "sl add . && sl commit -m \"Updated.\" && sl push",
|
||||
"git-push": "git add . && git commit -m \"Updated.\" && git push",
|
||||
"serve": "npx honkit serve --port=10447 --lrport=35713 &"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@ -33,7 +36,24 @@
|
||||
"gulp-typescript": "^5.0.1",
|
||||
"gulp-uglify": "^3.0.2",
|
||||
"live-server": "^1.2.0",
|
||||
"typescript": "^3.6.4"
|
||||
"typescript": "^3.6.4",
|
||||
"gitbook-plugin-back-to-top-button": "^0.1.4",
|
||||
"gitbook-plugin-cuav-chapters": "^1.0.3",
|
||||
"gitbook-plugin-fontsettings": "^2.0.0",
|
||||
"gitbook-plugin-heading-anchors": "^1.0.3",
|
||||
"gitbook-plugin-highlight-code": "^1.0.0",
|
||||
"gitbook-plugin-theme-comscore": "^0.0.3",
|
||||
"honkit": "^4.0.4"
|
||||
},
|
||||
"dependencies": {}
|
||||
"dependencies": {
|
||||
"gitbook-plugin-ace": "^0.3.2",
|
||||
"gitbook-plugin-code": "^0.1.0",
|
||||
"gitbook-plugin-include-codeblock": "^3.2.3",
|
||||
"gitbook-plugin-search-pro-fixed": "^1.0.1",
|
||||
"gitbook-plugin-sectionx": "^3.1.0",
|
||||
"gitbook-plugin-sitemap": "^1.2.0",
|
||||
"gitbook-plugin-splitter": "^0.0.8",
|
||||
"gitbook-plugin-tbfed-pagefooter": "^0.0.1",
|
||||
"gitbook-plugin-theme-door": "^1.0.2"
|
||||
}
|
||||
}
|
||||
|
288
theme-door-style.css
Normal file
288
theme-door-style.css
Normal file
@ -0,0 +1,288 @@
|
||||
body {
|
||||
font-family: "Helvetica Neue", "Hiragino Sans GB", "Microsoft YaHei", "\9ED1\4F53", Arial, sans-serif;
|
||||
letter-spacing: .2px;
|
||||
text-rendering: optimizeLegibility;
|
||||
}
|
||||
|
||||
::-webkit-scrollbar {
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.book-summary {
|
||||
height: 100%;
|
||||
padding-bottom: 20px;
|
||||
}
|
||||
::-webkit-scrollbar-thumb {
|
||||
background: transparent;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
:hover::-webkit-scrollbar-thumb {
|
||||
background: hsla(0, 0%, 53%, 0.4);
|
||||
}
|
||||
|
||||
:hover::-webkit-scrollbar-track {
|
||||
background: hsla(0, 0%, 53%, 0.1);
|
||||
}
|
||||
.markdown-section a{
|
||||
color: #EE8866;
|
||||
}
|
||||
.markdown-section h1,
|
||||
.markdown-section h2,
|
||||
.markdown-section h3,
|
||||
.markdown-section h4,
|
||||
.markdown-section h5,
|
||||
.markdown-section h6 {
|
||||
margin-bottom: .5em;
|
||||
font-weight: bold;
|
||||
}
|
||||
.markdown-section p {
|
||||
line-height: 2;
|
||||
}
|
||||
.markdown-section img {
|
||||
padding: 8px;
|
||||
background: #e4e4e478;
|
||||
transition: all 1s;
|
||||
box-sizing: border-box;
|
||||
box-shadow: 0 0 4px #dcdcdc;
|
||||
margin-left: 10px;
|
||||
margin-right: 10px;
|
||||
max-width: 95%;
|
||||
}
|
||||
.markdown-section img:hover {
|
||||
box-shadow: 0 0 10px #bbb
|
||||
}
|
||||
|
||||
.exc-trigger {
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
.navigation {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.sidebar-nav-space {
|
||||
height: 24px;
|
||||
}
|
||||
.book-summary{
|
||||
bottom: inherit;
|
||||
}
|
||||
.book-summary,
|
||||
.book-body {
|
||||
top: 80px;
|
||||
}
|
||||
|
||||
.book-header {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
left: -10px;
|
||||
top: 40px;
|
||||
}
|
||||
.book-summary ul.summary li.active {
|
||||
border-right: 3px solid #EE8866;
|
||||
background: #f3f1f1;
|
||||
}
|
||||
|
||||
.book-summary ul.summary li.active > a {
|
||||
color: #EE8866;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.book-summary ul.summary li a:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.page-inner {
|
||||
max-width: none;
|
||||
padding: 20px 374px 40px 40px;
|
||||
}
|
||||
|
||||
.header-inner #book-search-input {
|
||||
float: right;
|
||||
width: 300px;
|
||||
margin: 10px 0;
|
||||
padding: 0;
|
||||
border: none;
|
||||
border-radius: .25rem;
|
||||
background: #EE8866;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.header-inner #book-search-input input[type="text"] {
|
||||
width: 80%;
|
||||
background: #f4f5f5;
|
||||
border-top-left-radius: .25rem;
|
||||
border-bottom-left-radius: .25rem;
|
||||
}
|
||||
|
||||
.header-inner #book-search-input #searchBtn {
|
||||
color: #ffffff;
|
||||
margin-left: 10px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.header-inner #book-search-input #searchBtn:hover {
|
||||
color: #eae8e8;
|
||||
}
|
||||
|
||||
.header-inner {
|
||||
width: 100%;
|
||||
padding: 10px 30px;
|
||||
border-bottom: 1px solid #dededede;
|
||||
margin: auto;
|
||||
height: 80px;
|
||||
}
|
||||
|
||||
.header-inner:before,
|
||||
.header-inner:after {
|
||||
content: " ";
|
||||
display: table;
|
||||
line-height: 0;
|
||||
}
|
||||
|
||||
.header-inner:after {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.header-inner .logo {
|
||||
float: left;
|
||||
height: 50px;
|
||||
width: 221px;
|
||||
background: url('./logo.svg');
|
||||
background-size: 221px 50px;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
.header-inner .logo img {
|
||||
display: block;
|
||||
height: inherit;
|
||||
padding: 5px 0;
|
||||
}
|
||||
|
||||
.header-inner .title {
|
||||
float: left;
|
||||
font-size: 20px;
|
||||
line-height: 60px;
|
||||
margin-left: 10px;
|
||||
color: #575656;
|
||||
}
|
||||
|
||||
/* 导航 */
|
||||
.header-inner .header-nav {
|
||||
list-style: none;
|
||||
margin: 10px 20px 0 0;
|
||||
padding: 0;
|
||||
float: right;
|
||||
display: table;
|
||||
}
|
||||
|
||||
.header-inner .header-nav li {
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
min-width: 50px;
|
||||
margin-right: 20px;
|
||||
padding: 8px 10px 8px 10px;
|
||||
}
|
||||
|
||||
.header-inner .header-nav li a {
|
||||
color: #5d6778;
|
||||
font-weight: 500;
|
||||
padding: .5rem;
|
||||
}
|
||||
|
||||
.header-inner .header-nav li a:hover,
|
||||
.header-inner .header-nav li a.active {
|
||||
color: #EE8866;
|
||||
}
|
||||
|
||||
.header-inner .header-nav li a.active:hover {
|
||||
cursor: #EE8866;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.book-summary,
|
||||
.book-body {
|
||||
top: 101px;
|
||||
}
|
||||
.header-inner #book-search-input {
|
||||
clear: both;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.book-anchor {
|
||||
overflow-y: auto;
|
||||
width: 307px;
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
top: 104px;
|
||||
right: 30px;
|
||||
padding: 0 10px 10px 10px;
|
||||
z-index: 999;
|
||||
user-select: none;
|
||||
border-left: 1px solid #ececec;
|
||||
}
|
||||
|
||||
.book-anchor-title {
|
||||
line-height: 38px;
|
||||
font-weight: bold;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.book-anchor a {
|
||||
display: block;
|
||||
line-height: 30px;
|
||||
color: #656565;
|
||||
font-size: 13px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.book-anchor a:hover {
|
||||
color: #EE8866;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.book-anchor .selected {
|
||||
color: #EE8866;
|
||||
text-decoration: none;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.book-anchor .anchor-h1 {}
|
||||
|
||||
.book-anchor .anchor-h2 {
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.fa {
|
||||
color: black;
|
||||
z-index: 999;
|
||||
text-rendering: optimizeLegibility;
|
||||
}
|
||||
|
||||
.book-anchor .anchor-h3{
|
||||
padding-left: 30px;
|
||||
}
|
||||
@media only screen and (max-width: 1020px) {
|
||||
.book-anchor {
|
||||
display: none;
|
||||
}
|
||||
.page-inner {
|
||||
max-width: none;
|
||||
padding: 20px 5px 5px 5px;
|
||||
}
|
||||
.book-body {
|
||||
top: 120px;
|
||||
}
|
||||
.header-nav {
|
||||
display: none;
|
||||
}
|
||||
body-inner {
|
||||
position: absolute;
|
||||
min-height: calc(100% - 50px);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user