Skip to content

Commit

Permalink
support dark mode
Browse files Browse the repository at this point in the history
  • Loading branch information
cocomeow committed Nov 14, 2021
1 parent ac282d5 commit a2159de
Show file tree
Hide file tree
Showing 6 changed files with 49 additions and 19 deletions.
2 changes: 1 addition & 1 deletion FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Please check if there is a `config.json` file in the working directory, because
The system tray widget will be loaded asynchronously along with the panel, and the application will be opened before them. The following is an example user service of start after `5s` delay.

```ini
```systemd
# ~/.config/systemd/user/across.service
[Unit]
Expand Down
4 changes: 2 additions & 2 deletions _navbar.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
* [En](/)
* [中文](/zh_cn/)
- [En](/)
- [中文](/zh_cn/)
52 changes: 45 additions & 7 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,11 @@
name="viewport"
content="width=device-width, initial-scale=1.0, minimum-scale=1.0"
/>
<link
rel="stylesheet"
href="//cdn.jsdelivr.net/npm/docsify@4/lib/themes/vue.css"
<link
rel="stylesheet"
href="//cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/dist/style.min.css"
title="docsify-darklight-theme"
type="text/css"
/>
<link rel="stylesheet" href="main.css" />
</head>
Expand All @@ -20,23 +22,59 @@
<script>
window.$docsify = {
name: "ACross",
nameLink: "/",
repo: "https://github.com/ArkToria/ACross",
loadSidebar: true,
alias: {
"/*/_sidebar.md": "/_sidebar.md",
},
loadNavbar: true,
subMaxLevel: 4,
logo: "/_media/logo.svg",
coverpage: {
"/": "_coverpage.md",
"/zh_cn/": "_coverpage.md",
},
search: {
paths: "auto",
placeholder: {
"/zh-cn/": "搜索",
"/": "Type to search",
},
noData: {
"/zh-cn/": "找不到结果",
"/": "No Results",
},
depth: 3,
hideOtherSidebarContent: true,
pathNamespaces: ["/zh-cn"],
},
darklightTheme: {
defaultTheme : 'light',
bodyFontSize : '1.2em',
dark: {
background: "#2E3440",
textColor: "#ECEFF4",
highlightColor: "#42B983",
codeBackgroundColor: "#3B4252"
}
}
};
</script>
<!-- Docsify v4 -->
<script src="//cdn.jsdelivr.net/npm/docsify@4"></script>
<script type="module" src="/index.js">
</script>
<script src="//cdn.jsdelivr.net/npm/docsify/lib/docsify.min.js"></script>
<!-- Plugins -->
<script src="//cdn.jsdelivr.net/npm/docsify/lib/plugins/search.min.js"></script>
<script type="module" src="/index.js"></script>
<script src="//cdn.jsdelivr.net/npm/docsify/lib/plugins/zoom-image.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/docsify-pagination/dist/docsify-pagination.min.js"></script>
<!-- Highlighter -->
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-bash.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-powershell.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-cmake.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-git.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-systemd.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/prismjs@1/components/prism-protobuf.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/docsify-darklight-theme@latest/dist/index.min.js">
</script>
</body>
</html>
4 changes: 0 additions & 4 deletions main.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion main.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 0 additions & 4 deletions main.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
p {
font-size: 1.2em !important;
}

.cover-main {
img {
max-width: 15vw;
Expand Down

0 comments on commit a2159de

Please sign in to comment.