├── .babelrc
├── .gitattributes
├── .gitignore
├── .istanbul.yml
├── .jshintrc
├── .travis.yml
├── Gruntfile.js
├── LICENSE
├── README.md
├── booksForTest
├── book1
│ ├── C#
│ │ └── X.md
│ ├── C+++++++++++++++++++++++
│ │ ├── page1.md
│ │ └── page2.md
│ ├── CSS
│ │ └── 9.md
│ ├── Chapter
│ │ └── Page.md
│ ├── FPGA
│ │ ├── -0809i.md
│ │ ├── 0.md
│ │ ├── 000.md
│ │ └── 789.md
│ ├── HTML
│ │ ├── 222.md
│ │ ├── 333.md
│ │ ├── 3455.md
│ │ └── 6.md
│ ├── LLLLISPPPPPP
│ │ └── zxxx.md
│ ├── MAC Linux Windows
│ │ └── 4.md
│ ├── Node
│ │ └── 5.md
│ ├── Python
│ │ ├── page2.md
│ │ ├── page3.md
│ │ └── page4.md
│ ├── VHDL
│ │ ├── 1.md
│ │ └── undefined.md
│ ├── VerilogHDL
│ │ └── 1.md
│ ├── hahahahahhahahahaha
│ │ ├── 3.md
│ │ └── 4.md
│ ├── 哈哈哈哈哈哈哈哈哈
│ │ ├── -=\.md
│ │ ├── 0.md
│ │ ├── 0009.md
│ │ ├── 1.md
│ │ └── undefined.md
│ └── 妈的智障智障智障智障
│ │ └── 2.md
├── book2
│ ├── 111333
│ │ └── 11.md
│ ├── 1111111
│ │ └── 111.md
│ ├── 1111122233
│ │ └── 22.md
│ └── test
│ │ └── test.md
└── book3
│ └── Chapter
│ ├── Page.md
│ └── page1.md
├── config.js
├── doc
├── .gitignore
├── en
│ ├── Development-Components.md
│ ├── Development-Cores.md
│ ├── Development-Environment.md
│ ├── Development-Tasks.md
│ ├── Development-UnitTests.md
│ ├── QuickStart.md
│ ├── README.md
│ ├── Thanks.md
│ ├── Theme-Advance.md
│ └── Theme-PreDefine.md
├── logo.png
├── preview-books-marked.jpg
├── preview-books.jpg
├── preview-export.jpg
├── preview-main-marked.jpg
├── preview-main.jpg
├── theme-lolita-books.jpg
├── theme-lolita-main.jpg
├── theme-nature-books.jpg
├── theme-nature-main.jpg
├── theme-night-books.jpg
├── theme-night-main.jpg
├── theme-sakura-books.jpg
├── theme-sakura-main.jpg
├── theme-snow-books.jpg
├── theme-snow-main.jpg
├── unit-test.jpg
└── zh
│ ├── Development-Components.md
│ ├── Development-Cores.md
│ ├── Development-Environment.md
│ ├── Development-Tasks.md
│ ├── Development-UnitTests.md
│ ├── QuickStart.md
│ ├── README.md
│ ├── Thanks.md
│ ├── Theme-Advance.md
│ └── Theme-PreDefine.md
├── init.js
├── logo.icns
├── logo.ico
├── logo.png
├── mainDev.js
├── mainRelease.js
├── package.json
├── reports
└── coverage
│ ├── cobertura-coverage.xml
│ ├── coverage.json
│ ├── lcov-report
│ ├── base.css
│ ├── index.html
│ ├── prettify.css
│ ├── prettify.js
│ ├── sort-arrow-sprite.png
│ ├── sorter.js
│ └── src
│ │ ├── book-item.js.html
│ │ ├── config-manager-zhizhang.js.html
│ │ ├── config-manager.js.html
│ │ ├── config.js.html
│ │ ├── config11.js.html
│ │ ├── configManager.js.html
│ │ ├── configManager1.js.html
│ │ ├── configManager2.js.html
│ │ ├── configManagerZhiZhang.js.html
│ │ ├── index.html
│ │ ├── parser.js.html
│ │ ├── storage-book.js.html
│ │ ├── storage-top.js.html
│ │ ├── storage.js.html
│ │ └── utils.js.html
│ └── lcov.info
├── spec
├── parser.spec.js
├── storage-book.spec.js
├── storage-top.spec.js
├── support
│ └── jasmine.json
├── test-parser.md
├── testcase-parser.js
├── testcase-storage-book.js
├── testcase-storage-top.js
├── utils.js
└── utils.spec.js
├── src
├── components
│ ├── book-item.js
│ ├── book-list.js
│ ├── book-picker.js
│ ├── chapter-list.js
│ ├── context-menu.js
│ ├── editor-theme.js
│ ├── editor.js
│ ├── file-exporter.js
│ ├── notify.js
│ ├── page-list.js
│ ├── page.js
│ ├── sortable-item.js
│ ├── sortable-list.js
│ └── toolbar.js
├── cores
│ ├── config-manager-zhizhang.js
│ ├── config-manager.js
│ ├── parser.js
│ ├── storage-book.js
│ ├── storage-top.js
│ ├── storage.js
│ └── utils.js
├── index.html
├── index.js
└── theme
│ ├── config
│ ├── .now
│ ├── lolita
│ │ ├── config.css
│ │ ├── config.json
│ │ └── editor.css
│ ├── nature
│ │ ├── config.css
│ │ ├── config.json
│ │ └── editor.css
│ ├── night
│ │ ├── config.css
│ │ ├── config.json
│ │ └── editor.css
│ ├── sakura
│ │ ├── config.css
│ │ ├── config.json
│ │ └── editor.css
│ └── snow
│ │ ├── config.css
│ │ ├── config.json
│ │ └── editor.css
│ ├── export
│ ├── dark.css
│ └── light.css
│ ├── fonts
│ ├── hack
│ │ ├── eot
│ │ │ ├── hack-bold-webfont.eot
│ │ │ ├── hack-bolditalic-webfont.eot
│ │ │ ├── hack-italic-webfont.eot
│ │ │ ├── hack-regular-webfont.eot
│ │ │ └── latin
│ │ │ │ ├── hack-bold-latin-webfont.eot
│ │ │ │ ├── hack-bolditalic-latin-webfont.eot
│ │ │ │ ├── hack-italic-latin-webfont.eot
│ │ │ │ └── hack-regular-latin-webfont.eot
│ │ ├── web-ttf
│ │ │ ├── hack-bold-webfont.ttf
│ │ │ ├── hack-bolditalic-webfont.ttf
│ │ │ ├── hack-italic-webfont.ttf
│ │ │ ├── hack-regular-webfont.ttf
│ │ │ └── latin
│ │ │ │ ├── hack-bold-latin-webfont.ttf
│ │ │ │ ├── hack-bolditalic-latin-webfont.ttf
│ │ │ │ ├── hack-italic-latin-webfont.ttf
│ │ │ │ └── hack-regular-latin-webfont.ttf
│ │ ├── woff
│ │ │ ├── hack-bold-webfont.woff
│ │ │ ├── hack-bolditalic-webfont.woff
│ │ │ ├── hack-italic-webfont.woff
│ │ │ ├── hack-regular-webfont.woff
│ │ │ └── latin
│ │ │ │ ├── hack-bold-latin-webfont.woff
│ │ │ │ ├── hack-bolditalic-latin-webfont.woff
│ │ │ │ ├── hack-italic-latin-webfont.woff
│ │ │ │ └── hack-regular-latin-webfont.woff
│ │ └── woff2
│ │ │ ├── hack-bold-webfont.woff2
│ │ │ ├── hack-bolditalic-webfont.woff2
│ │ │ ├── hack-italic-webfont.woff2
│ │ │ ├── hack-regular-webfont.woff2
│ │ │ └── latin
│ │ │ ├── hack-bold-latin-webfont.woff2
│ │ │ ├── hack-bolditalic-latin-webfont.woff2
│ │ │ ├── hack-italic-latin-webfont.woff2
│ │ │ └── hack-regular-latin-webfont.woff2
│ ├── icomoon.eot
│ ├── icomoon.svg
│ ├── icomoon.ttf
│ ├── icomoon.woff
│ └── katex
│ │ ├── KaTeX_AMS-Regular.eot
│ │ ├── KaTeX_AMS-Regular.ttf
│ │ ├── KaTeX_AMS-Regular.woff
│ │ ├── KaTeX_AMS-Regular.woff2
│ │ ├── KaTeX_Caligraphic-Bold.eot
│ │ ├── KaTeX_Caligraphic-Bold.ttf
│ │ ├── KaTeX_Caligraphic-Bold.woff
│ │ ├── KaTeX_Caligraphic-Bold.woff2
│ │ ├── KaTeX_Caligraphic-Regular.eot
│ │ ├── KaTeX_Caligraphic-Regular.ttf
│ │ ├── KaTeX_Caligraphic-Regular.woff
│ │ ├── KaTeX_Caligraphic-Regular.woff2
│ │ ├── KaTeX_Fraktur-Bold.eot
│ │ ├── KaTeX_Fraktur-Bold.ttf
│ │ ├── KaTeX_Fraktur-Bold.woff
│ │ ├── KaTeX_Fraktur-Bold.woff2
│ │ ├── KaTeX_Fraktur-Regular.eot
│ │ ├── KaTeX_Fraktur-Regular.ttf
│ │ ├── KaTeX_Fraktur-Regular.woff
│ │ ├── KaTeX_Fraktur-Regular.woff2
│ │ ├── KaTeX_Main-Bold.eot
│ │ ├── KaTeX_Main-Bold.ttf
│ │ ├── KaTeX_Main-Bold.woff
│ │ ├── KaTeX_Main-Bold.woff2
│ │ ├── KaTeX_Main-Italic.eot
│ │ ├── KaTeX_Main-Italic.ttf
│ │ ├── KaTeX_Main-Italic.woff
│ │ ├── KaTeX_Main-Italic.woff2
│ │ ├── KaTeX_Main-Regular.eot
│ │ ├── KaTeX_Main-Regular.ttf
│ │ ├── KaTeX_Main-Regular.woff
│ │ ├── KaTeX_Main-Regular.woff2
│ │ ├── KaTeX_Math-BoldItalic.eot
│ │ ├── KaTeX_Math-BoldItalic.ttf
│ │ ├── KaTeX_Math-BoldItalic.woff
│ │ ├── KaTeX_Math-BoldItalic.woff2
│ │ ├── KaTeX_Math-Italic.eot
│ │ ├── KaTeX_Math-Italic.ttf
│ │ ├── KaTeX_Math-Italic.woff
│ │ ├── KaTeX_Math-Italic.woff2
│ │ ├── KaTeX_Math-Regular.eot
│ │ ├── KaTeX_Math-Regular.ttf
│ │ ├── KaTeX_Math-Regular.woff
│ │ ├── KaTeX_Math-Regular.woff2
│ │ ├── KaTeX_SansSerif-Bold.eot
│ │ ├── KaTeX_SansSerif-Bold.ttf
│ │ ├── KaTeX_SansSerif-Bold.woff
│ │ ├── KaTeX_SansSerif-Bold.woff2
│ │ ├── KaTeX_SansSerif-Italic.eot
│ │ ├── KaTeX_SansSerif-Italic.ttf
│ │ ├── KaTeX_SansSerif-Italic.woff
│ │ ├── KaTeX_SansSerif-Italic.woff2
│ │ ├── KaTeX_SansSerif-Regular.eot
│ │ ├── KaTeX_SansSerif-Regular.ttf
│ │ ├── KaTeX_SansSerif-Regular.woff
│ │ ├── KaTeX_SansSerif-Regular.woff2
│ │ ├── KaTeX_Script-Regular.eot
│ │ ├── KaTeX_Script-Regular.ttf
│ │ ├── KaTeX_Script-Regular.woff
│ │ ├── KaTeX_Script-Regular.woff2
│ │ ├── KaTeX_Size1-Regular.eot
│ │ ├── KaTeX_Size1-Regular.ttf
│ │ ├── KaTeX_Size1-Regular.woff
│ │ ├── KaTeX_Size1-Regular.woff2
│ │ ├── KaTeX_Size2-Regular.eot
│ │ ├── KaTeX_Size2-Regular.ttf
│ │ ├── KaTeX_Size2-Regular.woff
│ │ ├── KaTeX_Size2-Regular.woff2
│ │ ├── KaTeX_Size3-Regular.eot
│ │ ├── KaTeX_Size3-Regular.ttf
│ │ ├── KaTeX_Size3-Regular.woff
│ │ ├── KaTeX_Size3-Regular.woff2
│ │ ├── KaTeX_Size4-Regular.eot
│ │ ├── KaTeX_Size4-Regular.ttf
│ │ ├── KaTeX_Size4-Regular.woff
│ │ ├── KaTeX_Size4-Regular.woff2
│ │ ├── KaTeX_Typewriter-Regular.eot
│ │ ├── KaTeX_Typewriter-Regular.ttf
│ │ ├── KaTeX_Typewriter-Regular.woff
│ │ └── KaTeX_Typewriter-Regular.woff2
│ ├── images
│ ├── about.png
│ ├── book-button-edit.png
│ ├── book-button-remove.png
│ ├── chapter-list-button.png
│ ├── export.png
│ ├── lolita
│ │ ├── body.jpg
│ │ ├── book-list.png
│ │ ├── book-pre.png
│ │ ├── error-head.png
│ │ ├── export-head.png
│ │ ├── info-background.png
│ │ ├── menu-background.png
│ │ ├── sys-info-head.png
│ │ └── warn-head.png
│ ├── nature
│ │ ├── body.png
│ │ ├── book-list.png
│ │ ├── book-pre.png
│ │ ├── error-head.png
│ │ ├── export-head.png
│ │ ├── info-background.png
│ │ ├── menu-background.png
│ │ ├── sys-info-head.png
│ │ └── warn-head.png
│ ├── night
│ │ ├── body.png
│ │ ├── book-list.png
│ │ ├── book-pre.png
│ │ ├── error-head.png
│ │ ├── export-head.png
│ │ ├── info-background.png
│ │ ├── menu-background.png
│ │ ├── sys-info-head.png
│ │ └── warn-head.png
│ ├── page-list-button.png
│ ├── reload.png
│ ├── sakura
│ │ ├── body.png
│ │ ├── book-list.png
│ │ ├── book-pre.png
│ │ ├── error-head.png
│ │ ├── export-head.png
│ │ ├── info-background.png
│ │ ├── menu-background.png
│ │ ├── sys-info-head.png
│ │ └── warn-head.png
│ └── snow
│ │ ├── body.png
│ │ ├── book-list.png
│ │ ├── book-pre.png
│ │ ├── error-head.png
│ │ ├── export-head.png
│ │ ├── info-background.png
│ │ ├── menu-background.png
│ │ ├── sys-info-head.png
│ │ └── warn-head.png
│ └── styles
│ ├── article.css
│ ├── books.css
│ ├── context-menu.css
│ ├── katex.css
│ ├── notify.css
│ ├── sky.css
│ └── sortable.css
├── webpack.config.js
└── webpack.dist.config.js
/.babelrc:
--------------------------------------------------------------------------------
1 | { "presets": ["es2015", "react"] }
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | *.psd
2 | *.png
3 | *.jpg
4 | *.jpeg
5 | *.ico
6 | #.tiff
7 | *.tga
8 | *.svg
9 | *.bmp
10 | *.hdr
11 | *.dxp
12 | *.fbx
13 | *.stl
14 | *.3ds
15 | *.exr
16 | *.avi
17 | *.mp3
18 | *.ogg
19 | *.acc
20 | *.m4a
21 | *.flac
22 | *.ape
23 | *.wav
24 | *.wma
25 | *.alac
26 | *.mp4
27 | *.mkv
28 | *.mpv
29 | *.avi
30 | *.rmb
31 | *.mov
32 | *.rar
33 | *.zip
34 | *.tar.gz
35 | *.tar
36 | *.uasset
37 | *.blend
38 | *.data
39 | *.csf
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .idea
2 | node_modules
3 | .DS_Store
4 | dist
5 | release
6 | .tree
7 | error.log
8 | design
--------------------------------------------------------------------------------
/.istanbul.yml:
--------------------------------------------------------------------------------
1 | verbose: false
2 | instrumentation:
3 | root: ./src
4 | default-excludes: true
5 | excludes: []
6 | embed-source: false
7 | variable: __coverage__
8 | compact: true
9 | preserve-comments: false
10 | complete-copy: false
11 | save-baseline: false
12 | baseline-file: ./reports/coverage/coverage-baseline.json
13 | reporting:
14 | print: summary
15 | reports:
16 | - lcov
17 | - cobertura
18 | dir: ./reports/coverage
19 | watermarks:
20 | statements: [50, 80]
21 | lines: [50, 80]
22 | functions: [50, 80]
23 | branches: [50, 80]
--------------------------------------------------------------------------------
/.jshintrc:
--------------------------------------------------------------------------------
1 | {
2 | "node": true,
3 | "jquery":true,
4 | "browser": true,
5 | "esnext": true,
6 | "bitwise": true,
7 | "camelcase": false,
8 | "curly": true,
9 | "eqeqeq": true,
10 | "immed": true,
11 | "indent": 4,
12 | "latedef": true,
13 | "noarg": true,
14 | "quotmark": "false",
15 | "regexp": true,
16 | "undef": true,
17 | "unused": false,
18 | "strict": false,
19 | "trailing": true,
20 | "smarttabs": true,
21 | "white": true,
22 | "newcap": false,
23 | "loopfunc": true,
24 | "globals": {
25 | "React": true,
26 | "d3" : true,
27 | "nv" : true,
28 | "BMap":false,
29 | "BMap_Symbol_SHAPE_CIRCLE":false,
30 | "BMAP_ANIMATION_BOUNCE":false,
31 | "BMAP_ANCHOR_TOP_RIGHT":false,
32 | "BMAP_ANCHOR_BOTTOM_RIGHT":false,
33 | "BMAP_ANCHOR_BOTTOM_LEFT": false
34 | }
35 | }
36 |
37 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | os: osx
2 | osx_image: xcode7.3
3 |
4 | language: node_js
5 |
6 | sudo: false
7 |
8 | node_js:
9 | - '5.9.0'
10 |
11 | before_install:
12 | - brew update
13 |
14 | install:
15 | - npm install grunt-cli -g
16 | - npm install electron-prebuilt@0.37.2 -g
17 | - npm install
18 |
19 | script:
20 | - grunt release-osx
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # MoeNotes
2 |
3 |
4 | 
5 |
6 | [Documents](http://moe-notes.dtysky.moe/en)
7 | [文档](http://moe-notes.dtysky.moe)
8 |
9 | [Video Demo](https://youtu.be/UhnbvLA0SMo)
10 | [视屏演示](http://www.bilibili.com/video/av4703145/)
11 |
12 | [下载](https://github.com/dtysky/MoeNotes/releases)
13 | [Download](https://github.com/dtysky/MoeNotes/releases)
14 |
15 | [](https://travis-ci.org/dtysky/MoeNotes)
16 |
17 | MoeNotes is a dairy software, unlike Onenote, Leanote, it's running locally, and the problem is solved is "local demonstration", used to provide a Onenote like experience at manage your dairy categories. THe app uses markdown is it's editing language, all notes will be saved as .md file locally instead of database, user can choose how these files are synchronized independent of platforms. It supports sorting articles by dragging them around. Besides, it has 'live preview', 'read' and 'write' three modes, exporting to pdf or html file, and themes can be switched or customized. Since it's based on web, it can be easily extended.
18 |
19 | MoeNotes是一个简单的日记写作软件(当然,我也用其写一些不是特别复杂的小说和文章),不同于印象笔记、Onenote、Leanote等,本软件没有这么大的野心,它所要解决的问题仅仅是“本地展示”,也就是在本地管理你的日志文件,并提供一个类似于Onenote的分类体验。
20 | 本软件使用Markdown作为笔记编写语言,适配GFM语法并增加语法高亮和数学公式,每一篇日记都会以.md文件的形式保存到本地而不是数据库中,用户可以自行选择如何同步这些文章以及将它们同步到多少地方,完全不依赖于平台,这也是我编写本软件而不使用现成日记软件的一个主要的原因。当然,对文章和分类进行拖动排序也是被支持的。除此之外,本软件还支持“即写即看”,“专注写作”和“专注阅读”三种模式,也可以进行主题的切换和自定义,还支持PDF和HTML的导出,由于是基于web进行得开发,所以扩展起来也十分方便和简单。
21 |
22 |
23 | 
24 | 
25 | 
26 |
27 |
28 | ## License
29 |
30 | Copyright © 2015, 戴天宇, Tianyu Dai (dtysky < dtysky@outlook.com >). All Rights Reserved.
31 | This project is free software and released under the **[GNU General Public License (GPL V3)](http://www.gnu.org/licenses/gpl.html)**.
--------------------------------------------------------------------------------
/booksForTest/book1/C#/X.md:
--------------------------------------------------------------------------------
1 | # HAHA
2 |
3 |
--------------------------------------------------------------------------------
/booksForTest/book1/C+++++++++++++++++++++++/page1.md:
--------------------------------------------------------------------------------
1 | Here is page1 in cp2.
--------------------------------------------------------------------------------
/booksForTest/book1/C+++++++++++++++++++++++/page2.md:
--------------------------------------------------------------------------------
1 | Here is page2 in cp2.
--------------------------------------------------------------------------------
/booksForTest/book1/CSS/9.md:
--------------------------------------------------------------------------------
1 | #
2 |
--------------------------------------------------------------------------------
/booksForTest/book1/Chapter/Page.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/FPGA/-0809i.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/FPGA/0.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/FPGA/000.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/FPGA/789.md:
--------------------------------------------------------------------------------
1 | # ghiAHSKAhslaKJSLKA
2 | asda
3 | 就安静安静
4 |
5 | \_"xxx"_
6 |
7 | niubility!
--------------------------------------------------------------------------------
/booksForTest/book1/HTML/222.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/HTML/333.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/HTML/3455.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/HTML/6.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/LLLLISPPPPPP/zxxx.md:
--------------------------------------------------------------------------------
1 | # x
2 |
3 | 13413411112
--------------------------------------------------------------------------------
/booksForTest/book1/MAC Linux Windows/4.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/Node/5.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/Python/page2.md:
--------------------------------------------------------------------------------
1 | Title: 【诗】我是一个行者
2 | Tags: 诗,原创,行者,孤独
3 | Date: 2014.05.18,21:44:44
4 | Authors: 命月天宇
5 | Summary: 孤独是一种浪漫。就像一场旅行。我,是一个行者。路过了一片花田。花儿望着空中的太阳。静静地承受着我的目光。似乎,要为我开放天堂。
6 |
7 |
8 |
9 |
10 |
11 |
我是一个行者
12 |
13 |
14 |
15 | 孤独是一种浪漫。
16 | 就像一场旅行。
17 | 我,是一个行者。
18 | 路过了一片花田。
19 | 花儿望着空中的太阳。
20 | 静静地承受着我的目光。
21 | 似乎,要为我开放天堂。
22 |
23 | 我是一个孤独的行者。
24 | 下一个方向,是大海。
25 | 大海很遥远。
26 | 只有不停拖动着脚步。
27 | 风在身边吹拂。
28 | 它撕扯着我破烂的躯壳。
29 |
30 | 我是一个走向大海的行者。
31 | 没有人知道我的期待。
32 | 虚无要将我吞噬。
33 | 只有将微笑当作唯一的信念。
34 | 麻木。
35 | 我不去反驳,只是微笑。
36 | 麻木的微笑,也同样是微笑。
37 |
38 | 我是一个微笑着的行者。
39 | 终于到达了大海。
40 | 它接纳了我变为粉末的身躯。
41 | 化其为养料,滋养着下一次花儿的盛放。
42 | 啊,如此就好。
43 | 我只是一个行者。
44 | 即使身躯消失,灵魂也只能前行。
45 |
46 | 我是一个行者。
47 | 再说一遍。
48 | 我是一个行者。
49 | 我无法到达天堂,
50 | 我只能一直前行。
51 |
52 | 我,是一个行者。
53 | 一个孤独的行者。
54 | 永远,孤独的行者。
55 |
56 |
57 |
58 |
59 |
60 |
--------------------------------------------------------------------------------
/booksForTest/book1/Python/page3.md:
--------------------------------------------------------------------------------
1 | An h1 header
2 | ============
3 |
4 | Paragraphs are separated by a blank line.
5 |
6 | 2nd paragraph. *Italic*, **bold**, and `monospace`. Itemized lists
7 | look like:
8 |
9 | * this one
10 | * that one
11 | * the other one
12 |
13 | Note that --- not considering the asterisk --- thex actual text
14 | content starts at 4-columns in.
15 |
16 | > Block quotes are
17 | > written like so.
18 | >
19 | > They can span multiple paragraphs,
20 | > if you like.
21 |
22 | Use 3 dashes for an em-dash. Use 2 dashes for ranges (ex., "it's all
23 | in chapters 12--14"). Three dots ... will be converted to an ellipsis.
24 | Unicode is supported. ☺
25 |
26 |
27 |
28 | An h2 header
29 | ------------
30 |
31 | Here's a numbered list:
32 |
33 | 1. first item
34 | 2. second item
35 | 3. third item
36 |
37 | Note again how the actual text starts at 4 columns in (4 characters
38 | from the left side). Here's a code sample:
39 |
40 |
41 | # Let me re-iterate ...
42 | signal count:std_logic_vector(3 downto 0) := 0;
43 | begin
44 | Count:process(clk, rst_n)
45 | if rise_edge(clk) then
46 | if rst_n == '0' then
47 | count <= 0;
48 | elsif count == 15 then
49 | count <= 0;
50 | else
51 | count <= count + 1;
52 | end if;
53 | end process;
54 | end
55 |
56 |
57 | As you probably guessed, indented 4 spaces. By the way, instead of
58 | indenting the block, you can use delimited blocks, if you like:
59 |
60 | ~~~
61 | :::js
62 | function foobar() {
63 | console.log("Welcome to flavor country!");
64 | }
65 | ~~~
66 |
67 | (which makes copying & pasting easier).
68 | You can optionally mark the delimited block for Pygments to syntax highlight it:
69 |
70 | :::python
71 | import time
72 | # Quick, count to ten!
73 | for i in range(10):
74 | # (but not *too* quick)
75 | time.sleep(0.5)
76 | print i
77 |
78 |
79 |
80 | ### An h3 header ###
81 |
82 | Now a nested list:
83 |
84 | 1. First, get these ingredients:
85 |
86 | * carrots
87 | * celery
88 | * lentils
89 |
90 | 2. Boil some water.
91 |
92 | 3. Dump everything in the pot and follow
93 | this algorithm:
94 |
95 | find wooden spoon
96 | uncover pot
97 | stir
98 | cover pot
99 | balance wooden spoon precariously on pot handle
100 | wait 10 minutes
101 | goto first step (or shut off burner when done)
102 |
103 | Do not bump wooden spoon or it will fall.
104 |
105 | Notice again how text always lines up on 4-space indents (including
106 | that last line which continues item 3 above).
107 |
108 | Here's a link to [a website](http://foo.bar), to a [local
109 | doc](local-doc.html), and to a [section heading in the current
110 | doc](#an-h2-header). Here's a footnote [^1].
111 |
112 | [^1]: Footnote text goes here.
113 |
114 | Tables can look like this:
115 |
116 | |size | material | color |
117 | |---- |:------------:| -----------:|
118 | |9 | leather | brown |
119 | |10 | hemp canvas | natural |
120 | |11 | glass | transparent |
121 |
122 | Table: Shoes, their sizes, and what they're made of
123 |
124 | A horizontal rule follows.
125 |
126 | ***
127 |
128 | Here's a definition list:
129 |
130 | apples
131 | : Good for making applesauce.
132 | oranges
133 | : Citrus!
134 | tomatoes
135 | : There's no "e" in tomatoe.
136 |
137 | Again, text is indented 4 spaces. (Put a blank line between each
138 | term/definition pair to spread things out more.)
139 |
140 | Here's a "line block":
141 |
142 | | Line one
143 | | Line too
144 | | Line tree
145 |
146 | and images can be specified like so:
147 |
148 | 
149 |
150 | Inline math equations go in like so: $\omega = d\phi / dt$. Display
151 | math should get its own line and be put in in double-dollarsigns:
152 |
153 | $$I = \int \rho R^{2} dV$$
154 |
155 |
156 | And note that you can backslash-escape any punctuation characters
157 | which you wish to be displayed literally, ex.: \`foo\`, \*bar\*, etc.
--------------------------------------------------------------------------------
/booksForTest/book1/Python/page4.md:
--------------------------------------------------------------------------------
1 | # α-2
2 |
3 | 第二天是周六,TY像往常一样和同事在公司在项目中愉快得玩耍并由衷地“享受”着这种玩耍。在被故意调低了亮度的显示器上是一个运行着的终端,终端被tmux分为了四个工作区,光标停留在右下角的那个区域——此区域的工作目录名为“NotesLife”,此目录中存的是一些被他作为日记的文档,每个文档都以`YYYY-MM-DD`形式格的日期作为文件名。日记本身使用markdown进行编写,简洁又不失丰富。
4 |
5 | 他用vim打开了一篇日记。这种行为对他而言是非常自然的,得益于过去的习惯,他几乎每天都会记上那个几个琐事在日记里然后同步到Github。虽然这一年来每篇日记中的平均字数越来越少,他的确还是在记录着。然而和以往不同,现在的他做出了和惯性完全相悖的行为——此时正在编辑的日记文件名并非今日,而是六天前,也就是上一个周日。此行为的反常在于他在半年前做出的那个决定——绝对不会再修改以前的日记,也不允许翻看。虽然这个行为看起来没有任何的道理,但他还是一如既往得由于自己的原则性遵守着,直到刚才。
6 |
7 | “你小子在干什么,活干完没就在这摸鱼。”在盯着日记发呆的时候,一个沉稳的男声从方无的后脑勺之上传来,随后,仿佛是膝跳反射一般,他迅速地按下了快捷键,切换了屏幕上的工作区。
8 |
9 | “不要随便窥视别人的隐私,明明都中年了连这点scene都没有么。”TY的声音一如既往的小,这种小声和他的身躯融合起来,显得有些弱气。但与这种表面上的感觉相反,他说的话却是毫不留情,让人感到十分不舒服。
10 |
11 | “你这小子,一直都这样说话?”中年男人离开了方无身后,一步就走到了他的侧面。“怪不得没有女朋友。”
12 |
13 | “我没女朋友吃你家大米啦。”他的眼睛没有离开屏幕,手也没有离开键盘。刚才的情绪波动并没有对他在现实中的身体产生任何影响。
14 |
15 | “怎么,有什么害羞的事情?”中年男人社会经验十分丰富,并没有对他眼中的这个小屁孩的话语产生任何情绪反应。
16 |
17 | “你在搞笑么,我什么时候会害羞。”TY的反驳没有丝毫迟疑。
18 |
19 | “是吗,那你有什么必要这么遮遮挡挡的?”中年男人体态虽然比较丰满,但却十分敏捷,趁TY不注意,他已经凭借丰富的工作经验在转眼之间就将屏幕切回了方才的终端。
20 |
21 | “......”二者看着终端上的日记,同时陷入了沉默。
22 |
23 | >\# YYYY年MM月DD日
24 | ......
25 | \## 黄昏
26 | 他们拉我去聚会,但其实我TM一点也不想去。不过这次领导也在场,所以不去也不太好——这样来几次这公司就没我的容身之处了。虽然对于完全看不到未来的的我而言,换个公司、频繁跳槽也不是什么事,不过由于最近那种额外的疲惫所以暂时还不想去准备面试跑来跑去的。
27 |
28 | >聚会过程没有任何的意外,无非就是吃吃喝喝闲聊,我对他们的话题没有任何兴趣——即便是有兴趣也懒得发言。当然,我并非一开始就是如此的,过去我也曾尝试过加入这些讨论,然而当我发现我的严肃认真的发言在他们看来不过是狗屎之后便打消了这种念头,他们要的只是消费以及被消费的谈资而已,这毫无意义。我也没有喝酒,因为我觉得那玩意很TM难喝,无法带来任何快感,所以即便是领导表示出了些许的不满,我也没有任何妥协的迹象。总之就在这种无聊刷手机的过程中,时间最终非常明智得放过了我,聚会就这么结束了。
29 |
30 | >按照以往的经验,这样的一次活动基本就毁了我的整个周末——虽然我周末也只是在发呆而已,但我认为即便是发呆也比这种行为有价值。然而这次却不同,因为我在归程发现了她——虽然感觉整体的设计和装束华丽得过于浮夸,非常不符合我的审美习惯,但她的那双眼睛中似乎有着什么东西在吸引着我。在假装离开众人回家之后,我立马返回了她所在的那个展览柜,看着她的眼睛,不知不觉中在那呆呆站了许久,或许是一个小时,又或许是两个小时,也或许更长。我最终是被这家商场的员工赶走的,那家店的名字叫做“MagicDoll”......
31 |
32 | “年轻人,看来你的想法很多啊。”中年男人早已将手早已离开了键盘,并放在了TY的一个肩膀上。“这个社会,没你想的这么简单。”接下来的语气与方才的豪爽不同,分贝小了几度的同时也显得有些沉重,同时将TY肩膀上的手移开了。
33 |
34 | “你是想说你曾经与我一样,但最后还是无可避免得成为了无聊的中年人么?”TY并没有被这忽然严肃的氛围吓到,尽管他的心里的确有些不适,但这并没有体现在身体上。
35 |
36 | “......”中年男人顿了顿,“或许吧,你说的没错。”他没有反驳,但很快便恢复了刚才的轻松状态——他丰富的社会经验告诉他,生活和工作不能走得太近,不能把所有的同事都当做是朋友。“看起来你对那个娃娃很感兴趣?”他紧接着转移了话题。
37 |
38 | “不是娃娃,是人偶,它很明显不是你们所想的那种东西。而且就算是那种东西,使用起来也很麻烦好么?不要想得这么简单。”
39 | “看起来你在某些方面的经验也很丰富。”
40 | “我只是对任何东西都很严肃而已。”
41 |
42 | 几句交锋之间,话题已经被成功转移了,按照既定的惯性,这个中年男人应该返回他的工位,继续着他尚未完成的工作,然后大家各自回家——回家前可能还会一起去吃顿饭。但他并没有这么做,而是再次陷入了沉默,在这种沉默的气氛中,大约过了五分钟,中年男人再次说话了。
43 |
44 | “小子,有想法是不错,但要注意保护自己。即使你现在觉得自己一无所有,但最终还是要承担责任的。在这个过程中,要务必保持清醒,不要迷失自己。”他站在了一个长者的立场,说着这些明知会被TY厌恶的话。
45 |
46 | “......”而TY却少有地没有作出反驳。
47 |
48 | “她的眼睛的确很漂亮。”中年男人慢慢转过了身,走向了自己的工位。“对了,还有一句忠告。”然后在半路停下来。
49 | “结婚前,要务必考虑清楚。婚姻为你带来脱离空虚的价值后,可能会顺便毁了你的一切。”
--------------------------------------------------------------------------------
/booksForTest/book1/VHDL/1.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/VHDL/undefined.md:
--------------------------------------------------------------------------------
1 | undefined
2 |
3 | 111
--------------------------------------------------------------------------------
/booksForTest/book1/VerilogHDL/1.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/hahahahahhahahahaha/3.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/hahahahahhahahahaha/4.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/哈哈哈哈哈哈哈哈哈/-=\.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/哈哈哈哈哈哈哈哈哈/0.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/哈哈哈哈哈哈哈哈哈/0009.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/哈哈哈哈哈哈哈哈哈/1.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book1/哈哈哈哈哈哈哈哈哈/undefined.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book1/妈的智障智障智障智障/2.md:
--------------------------------------------------------------------------------
1 | undefined
--------------------------------------------------------------------------------
/booksForTest/book2/1111111/111.md:
--------------------------------------------------------------------------------
1 | sahsaljs;aghj
--------------------------------------------------------------------------------
/booksForTest/book2/1111122233/22.md:
--------------------------------------------------------------------------------
1 | # 花
2 |
3 | 境界线,这是一场战争
--------------------------------------------------------------------------------
/booksForTest/book2/111333/11.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/booksForTest/book2/test/test.md:
--------------------------------------------------------------------------------
1 | # test1
2 |
3 |
--------------------------------------------------------------------------------
/booksForTest/book3/Chapter/Page.md:
--------------------------------------------------------------------------------
1 | # 89
2 |
3 | zheshi一个故事
--------------------------------------------------------------------------------
/booksForTest/book3/Chapter/page1.md:
--------------------------------------------------------------------------------
1 | #
--------------------------------------------------------------------------------
/config.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/18
4 | * Description: Configure.
5 | */
6 |
7 | const path = require('path');
8 |
9 | const rootPath = path.resolve(__dirname, './');
10 | var paths = {
11 | rootPath: rootPath,
12 | srcPath: path.join(rootPath, 'src'),
13 | distPath: path.join(rootPath, "dist"),
14 | urlPath: "http://localhost:8000",
15 | debugPort: 8000,
16 | releasePath: path.join(rootPath, 'release'),
17 | realPath: "file://" + path.join(rootPath, "index.html")
18 | };
19 |
20 | module.exports = {
21 | paths: paths
22 | };
--------------------------------------------------------------------------------
/doc/.gitignore:
--------------------------------------------------------------------------------
1 | *.psd
--------------------------------------------------------------------------------
/doc/en/Development-Components.md:
--------------------------------------------------------------------------------
1 | # React component
2 |
3 | Besides the core library are the UI components, all the rendering and interaction logics are packed inside these components as React Framework.
4 |
5 | ## book-item && book-list
6 |
7 | book-item contains the logic to interate with each book component. book-list uses mulitple book-item to construct a list.
8 |
9 | ## sortable-item && sortable-list
10 |
11 | Since these two components are designed as the parent class of category list and note list, so there are some vaguenesses.
12 | Mainly the 'props.layoutMode' and 'props.addButtonLocation', the previous one has 'horizontal' and 'vertical', it decides whether the list is rendered horizontally or vertically; the later one has 'front' and 'end',
13 | depends you want to 'add' button after or before the list.
14 | And one more thing, any components that inherites from 'sortable-list' should call 'this.initState(name, indexes)' at initialization phase.
15 |
16 | ## chapter-list && page-list
17 |
18 | These two components inherites from 'sortable-list' and responsible for displaying and managing the categories of current notebook/dairy list.
19 |
20 | ## editor
21 |
22 | This component acts as the viewer of the editor, just by wrapping the ace editor like other react compoents.
23 |
24 | ## page
25 |
26 | This component is used to display the content of the notes, including editor and preview. To change the writing modes means the style of this component will be changed.
27 |
28 | ## toolbar
29 |
30 | The toolbar at top-right corner with buttons and selecting box, the detail has already be introduced in previous charpter. Attention, 'props.styleItem' only works on buttons, and will be applied to all buttons.
31 |
32 | ## context-menu
33 |
34 | The context-menu is binded to every sortable elements. Currently only create, rename remove and copy functions are supported.
35 |
36 | ## notify
37 |
38 | The component of notification system, used to poping out warning message or hint message at top-right corner( currently only 'save succed' message ).
39 | The core of this component is 'show' method, when use it you the reference of the component need to be get first then the 'show' method can be invoked.
40 |
41 | :::javascript
42 | function show(type, message, callbacks)
43 |
44 | ### type
45 |
46 | strings, 'warn' 'error' 'sysInfo' and 'info' 4 types are supported, the first 3 are modal and the last one is popup, each mode can received a 'message' string to be displayed and a collection of callbacks 'callbacks'.
47 |
48 | ### callbacks
49 |
50 | Callback collections, a typical 'callbacks' looks like below:
51 |
52 | :::js
53 | callbacks = {
54 | onHide: {
55 | fun: this.onHide,
56 | param: []
57 | },
58 | onOk: {
59 | fun: this.onOk,
60 | param: []
61 | },
62 | onCancel: {
63 | fun: this.onCancel,
64 | param: []
65 | }
66 | }
67 |
68 | Every callback should provide at least one 'fun' property used to invoke the call back function, param is optional and can be used to pass arguments to call back function.
69 | ohHide is optional for every type and it will disappear after trigged by modal or popup.
70 | onOk is only optional for 'warn' 'error' and 'sysInfo', it will be trigged after the user clicked the 'OK' button.
71 | onCancel is only optional for 'warn', and will be trigged after the user clicked 'Cancel'.
--------------------------------------------------------------------------------
/doc/en/Development-Cores.md:
--------------------------------------------------------------------------------
1 | # core-lib
2 |
3 | The project consists of two parts, core-lib and components, one for maintaining the essential logics one for view.
4 | Core-lib has following parts:
5 |
6 | ## storage-book
7 |
8 | The storage-book, which responsible for creating and managing notebooks. Each time a notebook is loaded such a new instance of this class will be created.
9 | When creating such instance it will check if .tree file exists under the folder, if not or parse failed a new .tree file will be created. Otherwise, the
10 | instance will check if the parsed the file tree match with the existing one and correct it.
11 | Be aware, not all property values are checked, so you should do it at upper layer. (e.g when invoking 'change' method, it will not check if it do need to change category/notebook).
12 | Besides, almost all methos has two way to be called, like 'getNow', when argument 'chapter' exists, it will return the index of current note, otherwise the index of current category is returned.
13 |
14 | ## storage-top
15 |
16 | Managing all notebooks via .tree file under user folder. Within the life cycle of the application only one instance will be created, and .tree file will be loaded/created depending on situation.
17 | Be aware like the class above, it will not check the validity of the properties and the check should be done on upper layers.
18 |
19 | ## config-manager
20 |
21 | This class is used to manage the configurations of the application, mainly loading/swithing themes.
22 | An instance will be created after launch the application, it will retrive a list of folders under the theme folder and get the last used theme(saved in .now folder). User can use 'refresh(theme)' to change theme. (still need external refresh, and usually need to restart the whole application to make it work)
23 |
24 | ## parser
25 |
26 | This class provides a method to convert markdown into html.
27 | Be aware in unit test use "config-manager-zhizhang" due a potential bug in babel-istanbul, otherwise the unit test will give a wrong hint that something is undefined in configManager.
28 |
29 | ## editor-theme
30 |
31 | Only one method is provided which is used to load theme of the editor. This method is saved into global, under the current theme's style editor file, and generated from brace standard.
32 |
33 | ## book-picker
34 |
35 | This is a singleton class, it provides two important methods 'create' and 'open' which both accepts a callback handler as argument, when executing a native folder selector will be opened. After user opened the selected folder, this method will get the absolute path of the folder and pass it to the registered callback handler.
36 |
37 | ## utils
38 |
39 | Provides some useul method.
40 |
41 | ### getFiles(dp)
42 |
43 | Retrive all the .md files under dp folder, the returned array has already removed '.md' , e.g "1.md" will be "1".
44 |
45 | ### arrayAreSimilar(a1, a2)
46 |
47 | Check if two arrays are similar (elements are same but orders doesn't matter):
48 |
49 | :::js
50 | arrayIsLike([1, 2, 3], [2, 1, 3]) //ture
51 | arrayIsLike([1, 2, 3, 4], [2, 1, 3]) //false
52 |
53 | ### stringToColor(string, colorConstraints)
54 |
55 | This method is used to convert a string into RGBA color, details will be elaborated in "Theme-advanced" chapter.
56 |
57 | ### bindTryCatchWrapper(self, methods, handler)
58 |
59 | This method will warp all methods of self with errorHandler. After invoked this method, if any error happens, it will be passed to the registered handler.
60 |
61 | ### logError(file)
62 |
63 | Error log method, used to dump log to fil, the returned function can be used as a handler of bindTryCatchWrapper or other simlilar methods.
64 |
65 | ### bindFunctions(self, methods, tryCatchHandler)
66 |
67 | Bind all methods to self, if tryCatchHandler is provided then bindTryCatchWrapper will be applied also.
68 |
69 | ### createObjectWithErrorHandler(obj, handler)
70 |
71 | Create error handler for all methods of a certain object.
--------------------------------------------------------------------------------
/doc/en/Development-Environment.md:
--------------------------------------------------------------------------------
1 | # Development Environment
2 |
3 | ## Platform
4 |
5 | This app is developed on Node.js , Version 5.9.0.
6 |
7 | ## Framework
8 |
9 | Electron is used as the development frame, version 0.37.2, it's installed globally and thus not contained in 'package.json', you need to install it:
10 |
11 | :::bash
12 | npm install electron-prebuilt@0.37.2 -g
13 |
14 | At web side, this app uses React.js, so you need some basics understandings of react components.
15 |
16 | ## Build Tool
17 |
18 | This app uses Grunt and Webpack as building tool and be aware, Grunt also need to be installed gloablly:
19 |
20 | :::bash
21 | npm install grunt-cil -g
22 |
23 | ## Others
24 |
25 | Cross-platform deploying might need some extra lib dependency, and you need to fix it yourself.
26 |
27 | ## Quick Start
28 |
29 | After node, npm, electron and grunt are all installed, clode this project to local and execute:
30 |
31 | :::bash
32 | npm install
33 |
34 | After all dependencies are installed, run:
35 |
36 | :::bash
37 | grunt
38 |
39 | Compile the code and start the debugging server. run:
40 |
41 | :::bash
42 | electron mainDev.js
43 |
44 | The app is now ready for debugging.
45 | Under the BooksForTest there are three notebook used for debugging, you can also open the docs under doc folder.
--------------------------------------------------------------------------------
/doc/en/Development-Tasks.md:
--------------------------------------------------------------------------------
1 | # Grunt task
2 |
3 | This app uses Grunt as building tool, I have predfined lots of grunt tasks to help developing, to use it just run 'grunt '
4 |
5 | ## Task list
6 |
7 | ### debug
8 |
9 | This task will compile the code and start a debugging server, usually used together with 'electron mainDev' for developing purpose.
10 |
11 | ### test
12 |
13 | This task is used for unit tests and details will be explained in later chapters.
14 |
15 | ### build-pre
16 |
17 | THis task is used for distribution, use webpack to pack everything into dist folder and prepare for final release.
18 |
19 | ### build-xxx series
20 |
21 | This series of tasks contain 'build-osx' 'build-linux' 'build-windows' 'build-all', which are used to deploy this app to different platforms, should run after 'build-pre'.
22 | And it will be stored inside release folder.
23 |
24 | ### release-xxx series
25 |
26 | This series of tasks contain 'build-pre' and 'build-xxx', use for release.
--------------------------------------------------------------------------------
/doc/en/Development-UnitTests.md:
--------------------------------------------------------------------------------
1 | # Unit Tests
2 |
3 | Due to the complexity fo the viewing part, only the core lib is tested. But the test frame is already established(including Node api), you can test it if you want.
4 |
5 | ## Test procedures and results
6 |
7 | jasmine is used as unit test frame, instanbul is used to collect coverage ratio, so the tests need to be write under jasmine standards.
8 | All the test files are under spec folder, your work is:
9 |
10 | 1. Create a test file under spec folder named like "[name].spec.js".
11 | 2. Use [jasmine standards] to write teat cases, be aware, 'mock-fs' lib is imported to generate virtual folders and files and used in 'stronge-book' 'storage-top' libs' test cases.
12 | 3. run'grunt test' to start to unit test.
13 | 4. Use browser to open 'reports/coverage/lcov-report/index.html' to check coverage ratio result.
14 |
15 | 
--------------------------------------------------------------------------------
/doc/en/QuickStart.md:
--------------------------------------------------------------------------------
1 | # Quick Start
2 |
3 | ## First Use
4 |
5 | When the app is first runned a dialog will pop out, and just select a empty folder and open it, your first note is then created.
6 |
7 | ## File Structure
8 |
9 | The notebook file structure is shown below:
10 |
11 | book
12 | ├──.tree
13 | ├──chapter1
14 | | ├──page1
15 | | └──age2
16 | |
17 | ├──chapter2
18 | ├──page1
19 | └──page2
20 | ......
21 |
22 | The content of the notebook is save at two levels, folders as category, notes are saved under category. .tree file is used to store some essential information for managing the notes.
23 |
24 | ## UI
25 |
26 | As shown below, the UI can be divided into several regions:
27 |
28 | 
29 | 
30 |
31 | ### 1. BOOK Button
32 |
33 | After clicking the button the listwill be opened, as shown the image above.
34 |
35 | ### 2. Category List
36 |
37 | A horizontal list, showing all categories within it. The last button is used to add a new category at the end, you can also use the Create in ⑦ menu to create/delete/rename. The order of the categories can be changed by just drag and move.
38 |
39 | ### 3. Artical List
40 |
41 | A vertical list, showing the content of the opened notebook, the first button is used to add a new note, and like category you can use ⑦ menu to create/delete/rename too.
42 |
43 | ### 4. Editor
44 |
45 | THe editor used here is ACE editor without context menu, shortcuts are the same as system shortcuts (like Home+F to open search in MAC)
46 | THe edit language is enhanced Markdown, combined with math formulas and tables.
47 | It follows the standard of [Github Flavored Markdown](https://guides.github.com/features/mastering-markdown/).
48 | Math part follows the standard of [Tex](https://www.mathjax.org/).
49 | If you want to add codes, you need to specify the language like '::lang', for intance:
50 |
51 | :::python
52 | print "x"
53 |
54 | ### 5. Preview
55 |
56 | Preview the result of markdown lively.
57 |
58 | ### 6. Toolbar
59 |
60 | From left to right:
61 |
62 | 1. Mode select: normal, writing and view
63 | 2. Theme select: switch themes
64 | 3. Export:export to pdf or html file
65 | 4. Refresh: reload the application
66 | 5. About: some info about this app
67 |
68 | ### 7. Context menu
69 |
70 | Right click on category or notebook list:
71 |
72 | 1. Remove:Delete the selected category or notebook (from hard drive).
73 | 2. Rename:Rename the selected category or notebook (files/folders will be renamed)
74 | 3. Create:Create a new category or notebook.
75 | 4. Copy:Not implemented.
76 |
77 | ### 8. Notebook
78 |
79 | Each notebook consists of the icon,name at left and the buttons at top-right corner:
80 |
81 | 1. Icon:Click to switch to the selected notebook.
82 | 2. Name: After rename is clicked you can edit it.
83 | 3. Buttons:Rename and delete. Notice the rename of notebooks will not have effect on real files on hard drive.
84 |
85 | ### 9. Create and load notebook
86 |
87 | Create and Load button can open a system dialog, the difference is Create allows you to create new folders. After a folder is selected, if matches the standard the notes will be loaded otherwise a default category and note will be created.
--------------------------------------------------------------------------------
/doc/en/README.md:
--------------------------------------------------------------------------------
1 | # Overview
2 |
3 | 
4 |
5 | Chinese documents:
6 | [Overview](../zh)
7 |
8 | Demo:
9 | [Demo Video](https://youtu.be/UhnbvLA0SMo)
10 |
11 | Github:
12 | [MoeNotes](https://github.com/dtysky/MoeNotes)
13 |
14 | Download:
15 | [Download](https://github.com/dtysky/MoeNotes/releases)
16 |
17 | # Introduction
18 |
19 | MoeNotes is a dairy software, unlike Onenote, Leanote, it's running locally, and the problem is solved is "local demonstration", used to provide a Onenote like experience at manage your dairy categories.
20 | THe app uses markdown is it's editing language, all notes will be saved as .md file locally instead of database, user can choose how these files are synchronized independent of platforms. It supports sorting articles by dragging them around. Besides, it has 'live preview', 'read' and 'write' three modes, exporting to pdf or html file, and themes can be switched or customized. Since it's based on web, it can be easily extended.
21 |
22 | 
23 | 
24 | 
25 |
26 | ## Folder
27 |
28 | Normal user
29 | - [Quick Start](./QuickStart.md)
30 | - [Theme PreDefined](./Theme-PreDefine.md)
31 |
32 | Advanced user
33 | - [Customize Theme](./Theme-Advance.md)
34 |
35 | Developer
36 | - [Environment](./Development-Environment.md)
37 | - [Grunt Tasks](./Development-Tasks.md)
38 | - [Core Libs](./Development-Cores.md)
39 | - [React Components](./Development-Components.md)
40 | - [Unit Test](./Development-UnitTests.md)
41 |
42 | Thanks
43 | - [Used tool and materials](./Thanks.md)
44 |
45 | ## License
46 |
47 | Copyright © 2015, 戴天宇, Tianyu Dai (dtysky). All Rights Reserved. This project is free software and released under the GNU General Public License (GPL V3).
--------------------------------------------------------------------------------
/doc/en/Thanks.md:
--------------------------------------------------------------------------------
1 | # Thanks
2 |
3 | The development of this app depends on Open Source and Free Materials, thanks to the Authors&Developers&Artists.
4 |
5 | ## My firends
6 |
7 | Document Translation - [npk48](https://github.com/npk48)
8 | Logo Design - [七七](http://www.pixiv.net/member.php?id=5673800)
9 |
10 | ## Open Source
11 |
12 | [electron](https://github.com/electron/electron)
13 | [react](https://github.com/facebook/react)
14 | [babel](https://github.com/babel/babel)
15 | [grunt](https://github.com/gruntjs/grunt)
16 | [webpack](https://github.com/webpack/webpack)
17 | [jasmine](https://github.com/jasmine/jasmine)
18 | [istanbul](https://github.com/gotwarlost/istanbul)
19 | [jshint](https://github.com/jshint/jshint)
20 | [mock-fs](https://github.com/tschaub/mock-fs)
21 | [boron](https://github.com/yuanyan/boron)
22 | [brace](https://github.com/thlorenz/brace)
23 | [react-burger-menu](https://github.com/negomi/react-burger-menu)
24 | [react-contextmenu](https://github.com/vkbansal/react-contextmenu)
25 | [react-notification-system](https://github.com/igorprado/react-notification-system)
26 | [color-space](https://github.com/scijs/color-space)
27 | [hightlight.js](https://highlightjs.org/)
28 | [katex](https://github.com/Khan/KaTeX)
29 | [loadsh](https://lodash.com/)
30 | [marked](https://github.com/chjj/marked)
31 | [moment](https://github.com/moment/moment)
32 | [rimraf](https://github.com/isaacs/rimraf)
33 | [string-hash](https://github.com/darkskyapp/string-hash)
34 | [string-width](https://github.com/sindresorhus/string-width)
35 | [deepcopy](https://github.com/sasaplus1/deepcopy.js)
36 | [wkhtmltopdf](http://wkhtmltopdf.org/)
37 |
38 |
39 | ## Materials
40 |
41 | [春琴抄](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=49550201)
42 | [素材集:桜吹雪](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=24422575)
43 | [【フリー素材】桜](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=42592676)
44 | [【フリー素材】星屑のゆりかご](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=40073300)
45 | [Pixiv投稿用小説扉・星](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=43952785)
46 | [素材】3分で星空が作れる素材詰め合わせ](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=20132776)
47 | [森](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=55943633)
48 | [【素材】Texture7-ゴシック【印刷】](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=19640104)
49 | [緑の葉](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=47585010)
50 | [背景素材】I ・ 雪片](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=19074808)
51 | [White&Ash Winter images10(おまけ付き)](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=22993385)
52 | [【素材】Texture18-冬](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=47632547)
53 | [フリー素材 ふわキラ](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=16956648)
--------------------------------------------------------------------------------
/doc/en/Theme-Advance.md:
--------------------------------------------------------------------------------
1 | # Theme-Advance
2 |
3 | If you understand how CSS works you can follow the steps below to create your own theme:
4 |
5 | ## 1. Find the configuration folder
6 |
7 | **For mac users**
8 |
9 | Find the application package, right click and select 'show package content'. then enter the 'Contents/Resources/app' folder.
10 |
11 | **For Linux and Windows users**
12 |
13 | Find the application folder and enter 'resources/app' folder.
14 |
15 | Then enter 'theme/config' folder and you will see those predefined themes.
16 |
17 | ## 2. Create new theme
18 |
19 | You can copy a pre defined theme as template or start in a new folder, but keep in mind the following three files are essential:
20 |
21 | ### 1. config.css
22 |
23 | This is the main configuration file of theme, you can use it to overwrite almost all styles, but not recommended. Use it to define things like background images or background color.
24 |
25 | ### 2. config.json
26 |
27 | :::js
28 | {
29 | //default syntax highlight language
30 | "defaultHighlight": "VHDL",
31 | //default variable ,hue、saturation and lightness
32 | "CDCMode": "hue",
33 | //default range for varying parameter
34 | "CDCRange": [260, 380],
35 | //current chapter's background color
36 | "chapterNowBackCSC": [50, 60, 1],
37 | //current chapter's border color
38 | "chapterNowBorderCSC": [50, 60, 1],
39 | //current chapter's font color
40 | "chapterNowFontCSC": [100, 100, 1],
41 | //default chapter's background color
42 | "chapterNormalBackCSC": [40, 70, 0.6],
43 | //default chapter's border color
44 | "chapterNormalBorderCSC": [40, 50, 1],
45 | //default chapter's font color
46 | "chapterNormalFontCSC": [100, 25, 1],
47 | //page-list's background color for current chapter
48 | "pageListBackCSC": [20, 40, 0.5],
49 | //adding-page-button's background color for current chapter
50 | "pageButtonBackCSC": [30, 50, 0.6],
51 | //adding-page-button's font color for current chapter
52 | "pageButtonFontCSC": [100, 20, 1],
53 | //current page's background color
54 | "pageNowBackCSC": [100, 100, 1],
55 | //current page's font color
56 | "pageNowFontCSC": [100, 30, 1],
57 | //default page's background color
58 | "pageNormalBackCSC": [0, 0, 0],
59 | //default page's font color
60 | "pageNormalFontCSC": [100, 30, 1],
61 | //head's background color for current book
62 | "headBackCSC": [50, 80, 0.6],
63 | //book's background color
64 | "bookBackCSC": [50, 80, 0.8],
65 | //book's font and shape color
66 | "bookFontCSC": [80, 50, 0.8],
67 | //book's button color
68 | "bookShapeCSC": [50, 50, 0.8],
69 | //toobar's background color for current book
70 | "toolbarCSC": [60, 50, 0.7],
71 | //dialog's drop background color
72 | "notifyDropBack": "rgba(100,100,100,0.6)",
73 | //warnning dialog's background image
74 | "notifyWarnBack": "",
75 | //error dialog's background image
76 | "notifyErrorBack": "",
77 | //system information dialog's background image
78 | "notifySysInfoBack": "",
79 | //notifiction's background image
80 | "notifyInfoBack": "rgba(239, 194, 212, 0.9)"
81 | }
82 |
83 | Note the "XXXCSC":
84 |
85 | 1. [0, 0, 0]: In this mode, the varying parameter is determined for `CDCMode`,and the range is determined for `CDCRange`.
86 | 2. [0, 0, 0, "hue"]: In this mode, the varying parameter is determined for the fourth parameter,and the range is determined for `CDCRange`.
87 | 3. [0, 0, 0, [0, 100]]: In this mode, the varying parameter is determined for `CDCMode`,and the range is determined for the fourth parameter.
88 | 4. [0, 0, 0, "hue", [0, 100]]: In this mode, the varying parameter is determined for the fourth parameter,and the range is determined for the fifth parameter.
89 |
90 | ### 3. editor.json
91 |
92 | Theme of the editor. Details can be found on ace editor official site.
--------------------------------------------------------------------------------
/doc/en/Theme-PreDefine.md:
--------------------------------------------------------------------------------
1 | # Theme-Predefine
2 |
3 | Below is predefined themes, user can choose to use according to their preference:
4 |
5 | ## Sakura
6 |
7 | 
8 | 
9 |
10 | ## Night
11 |
12 | 
13 | 
14 |
15 | ## Snow
16 |
17 | 
18 | 
19 |
20 | ## Nature
21 |
22 | 
23 | 
24 |
25 | ## Lolita
26 |
27 | 
28 | 
--------------------------------------------------------------------------------
/doc/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/logo.png
--------------------------------------------------------------------------------
/doc/preview-books-marked.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/preview-books-marked.jpg
--------------------------------------------------------------------------------
/doc/preview-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/preview-books.jpg
--------------------------------------------------------------------------------
/doc/preview-export.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/preview-export.jpg
--------------------------------------------------------------------------------
/doc/preview-main-marked.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/preview-main-marked.jpg
--------------------------------------------------------------------------------
/doc/preview-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/preview-main.jpg
--------------------------------------------------------------------------------
/doc/theme-lolita-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-lolita-books.jpg
--------------------------------------------------------------------------------
/doc/theme-lolita-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-lolita-main.jpg
--------------------------------------------------------------------------------
/doc/theme-nature-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-nature-books.jpg
--------------------------------------------------------------------------------
/doc/theme-nature-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-nature-main.jpg
--------------------------------------------------------------------------------
/doc/theme-night-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-night-books.jpg
--------------------------------------------------------------------------------
/doc/theme-night-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-night-main.jpg
--------------------------------------------------------------------------------
/doc/theme-sakura-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-sakura-books.jpg
--------------------------------------------------------------------------------
/doc/theme-sakura-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-sakura-main.jpg
--------------------------------------------------------------------------------
/doc/theme-snow-books.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-snow-books.jpg
--------------------------------------------------------------------------------
/doc/theme-snow-main.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/theme-snow-main.jpg
--------------------------------------------------------------------------------
/doc/unit-test.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/doc/unit-test.jpg
--------------------------------------------------------------------------------
/doc/zh/Development-Components.md:
--------------------------------------------------------------------------------
1 | # React组件
2 |
3 | 核心库之外的就是视图组件了,所有的显示和交互逻辑都在这些组件之中,我在此处使用的是React这个框架,它的优点不再赘述,以下会简单介绍一下各个组件,在可能有坑的地方做一下重点提示。
4 |
5 | ## book-item && book-list
6 |
7 | 笔记本组件,`book-item`负责提供每一个笔记本控件的交互逻辑,`book-list`利用`book-item`构成笔记本的列表。没什么特别的坑。
8 |
9 | ## sortable-item && sortable-list
10 |
11 | 可排序列表的元素和列表组件,由于是作为分类列表和笔记列表两个组件的父类来设计的,所以有一些地方有坑(像是class和style的定义之类的不算坑,看render方法里的布局代码很清晰)。
12 | 坑主要是在`props.layoutMode`和`props.addButtonLocation`这两个属性,前者可选`horizontal`或者`vertical`,它决定了排序列表是水平还是竖直布局;后者可选`front`和`end`,它决定了“添加”按钮在列表前还是列表后。
13 | 除此之外,对于继承自`sortable-list`的组件,应当在初始化的时候调用`this.initState(name, indexes)`方法,来对组件进行初始化。
14 |
15 | ## chapter-list && page-list
16 |
17 | 这两个组件继承自`sortable-list`,分别负责显示和管理当前笔记本的分类列表与当前分类的日记列表。也没什么特别的坑。
18 |
19 | ## editor
20 |
21 | 这个组件是编辑器的视图,在ace editor外面封装了一层作为react组件,也没什么坑。
22 |
23 | ## page
24 |
25 | 这个组件用于展示笔记正文,里面包括了editor和preview两个部分,在改变“专注写作”等模式的时候实际上修改的就是此组件的样式。
26 |
27 | ## toobar
28 |
29 | 右上角的工具栏组件,几个按钮和选择框,在前面的章节已经介绍过功能。要注意的,`props.styleItem`只对按钮生效,并且对所有按钮都会生效。
30 |
31 | ## context-menu
32 |
33 | 上下文菜单组件,此组件被绑定到了每一个可排序元素上,暂时只有三种半的功能(create、rename、remove和copy)。
34 |
35 | ## notify
36 |
37 | 通知系统组件,用于弹出警告框等或者弹出右上角的提示信息框(目前只有与提示保存成功),此组件的坑相对复杂,值得一说。
38 | 组件的核心是一个名为`show`的方法,使用的时候也是先由组件的ref取得组件的引用,而后调用这个`show`方法。
39 |
40 | :::javascript
41 | function show(type, message, callbacks)
42 |
43 | ### type
44 |
45 | 字符串,有`warn`、`error`、`sysInfo`和`info`四种,前三者是modal,最后一个是popup,每种模式都可以接收一个用于显示的`message`字符串和一个回调函数集合`callbacks`。
46 |
47 | ### callbacks
48 |
49 | 回调函数集合,一个典型的`callbacks`例子如下:
50 |
51 | :::js
52 | callbacks = {
53 | onHide: {
54 | fun: this.onHide,
55 | param: []
56 | },
57 | onOk: {
58 | fun: this.onOk,
59 | param: []
60 | },
61 | onCancel: {
62 | fun: this.onCancel,
63 | param: []
64 | }
65 | }
66 |
67 | 每个回调都至少提供一个`fun`属性,作为将被执行的回调函数,而param是可选的,作为回调函数的参数。
68 | onHide对于所有type都是可选的,它在modal或者popup消失后触发。
69 | onOk只对`warn`、`error`和`sysInfo`可选,它在用户点击“OK”按钮后触发。
70 | onCancel只对`warn`可选,在用户点击“Cancel”后触发。
--------------------------------------------------------------------------------
/doc/zh/Development-Cores.md:
--------------------------------------------------------------------------------
1 | # 核心库
2 |
3 | 源代码分为核心库和组件两部分,前者负责核心逻辑,后者负责视图层。
4 | 负责核心逻辑的文件有:
5 |
6 | ## storage-book
7 |
8 | 笔记本管理,负责通过文件夹创建和管理笔记本。每当加载一个笔记本时便会创建一个改类的新实例,该实例构造时首先检查文件夹下是否存在.tree文件,如果不存在或者.tree文件解析有误则创建一个全新的.tree文件。如果存在正确的.tree文件,该实例还会检查解析后的文件树和实际存在的文件树是否对应,如果不对应则会进行修正。
9 | 此类的方法明明十分规范用途不再赘述,但需要注意的是此类自身**没有错误检查**,并不能保证操作后文件树中每一个属性的值都正确对应(比如调用`change`方法的时候并不会主动检查是否真的存在需要切换到的分类/笔记),所有的检查应该在上层自行完成。
10 | 除此之外,几乎所有的方法都拥有两种调用方法,比如`getNow`方法,在拥有参数`chapter`的时候,该方法返回的是当前的笔记index,没有的时候,返回的是当前分类的index。所有具有这种特性的方法都具有`chapter`参数,并且都是最后一个参数。
11 |
12 | ## storage-top
13 |
14 | 管理所有笔记本,通过用户目录下的.tree文件管理所有笔记本。在应用运行的生命周期中只会创建一个实例,实例构造时会检查用户目录下的.tree文件,根据具体情况进行创建或者加载。
15 | 和上面同样,此类也**没有错误检查**,方法名字十分清楚,不再赘述。
16 |
17 | ## config-manager
18 |
19 | 此类用于管理软件配置,主要是管理各个主题的加载和切换。
20 | 程序启动时将会创建一个此类的实例,它从主题配置文件夹下读取一个由所有文件夹构成的列表,并获取上一次所使用的主题(被曝存在“.now”文件中)。
21 | 可以使用它的`refresh(theme)`来更换主题(不过还需要外部的刷新、并通常需要重载整个应用才能让切换生效)。
22 |
23 | ## parser
24 |
25 | 提供一个方法,用于将markdown转换为html,此处有一个坑,就是在单元测试中,我并没有直接使用`config-manager`来提供配置而`config-manager-zhizhang`,顾名思义,妈的智障,这应该是我用于收集测试覆盖率的babel-istanbul工具的一个bug,如果按照正常方法使用,将会在单元测试的时候提示某处configManager是undefined,为了暂时找过这个错误,我暂时只能这么做了。
26 |
27 | ## editor-theme
28 |
29 | 里面只有一个方法,用于加载编辑器的主题,这在某种意义上其实是一种hack...不过为了功能暂时也只能如此了。此方法读入已经被存到全局变量中的、当前主题下的编辑器样式文件,并按照brace的规范生成样式。
30 |
31 | ## book-picker
32 |
33 | 这是一个类,在软件运行时以单例的形式存在,它有两个重要方法`create`和`open`,两者都接受一个回调函数作为参数,执行时都会打开一个系统原生的目录选择器,不过前者可以创建新文件夹,后者不可。当用户选择一个文件夹并打开后,此方法会获取改文件夹的绝对路径,并将其作为参数传给接收到的回调函数,并调用这个回调。
34 |
35 | ## utils
36 |
37 | 提供了一些有用的辅助方法,有几个是需要特别注意的:
38 |
39 | ### getFiles(dp)
40 |
41 | 该方法获取dp这个目录下的所有.md文件,但其返回的数组中所有的文件名已经去掉了扩展名,比如"1.md"这个文件实际最终返回的是"1"。
42 |
43 | ### arrayAreSimilar(a1, a2)
44 |
45 | 判断两个数组是否相似,所谓相似是指元素一样但顺序不一定一样:
46 |
47 | :::js
48 | arrayIsLike([1, 2, 3], [2, 1, 3]) //ture
49 | arrayIsLike([1, 2, 3, 4], [2, 1, 3]) //false
50 |
51 | ### stringToColor(string, colorConstraints)
52 |
53 | 此方法用于将一个字符串转换为RGBA色彩,具体使用可以看前面的“主题-进阶”这一章。
54 |
55 | ### bindTryCatchWrapper(self, methods, handler)
56 |
57 | 此方法将self中methods中所包含的所有方法加一层带有errorHandler的warpper,也就是说,通过此方法的处理,所有methods中的方法都会被包上一层,处理后,如果再调用这些方法中的某个,程序首先会尝试去直接执行这个方法,如果出错,将会把引发错误后产生的error对象传递给已经注册的handler,由handler去处理这个错误。
58 | 在本软件中,我选择将这个错误的stack log到一个文件中,便于bug后的改进。
59 |
60 | ### logError(file)
61 |
62 | 错误处理函数,将错误log到file中,其返回的函数可以作为bindTryCatchWrapper的一个handler,也可以作为其他有此种功能的方法的参数。
63 |
64 | ### bindFunctions(self, methods, tryCatchHandler)
65 |
66 | 将methods中的方法们绑定到self上,如果tryCatchHandler被提供,则同时会实现bindTryCatchWrapper方法的功能。
67 |
68 | ### createObjectWithErrorHandler(obj, handler)
69 |
70 | 直接给某个对象的所有方法加上错误处理。
--------------------------------------------------------------------------------
/doc/zh/Development-Environment.md:
--------------------------------------------------------------------------------
1 | # 开发环境
2 |
3 | ## 平台
4 |
5 | 本软件的开发平台是Node.js,版本是5.9.0。
6 |
7 | ## 框架
8 |
9 | 使用Electron作为本软件的开发框架,版本是0.37.2,在本软件开发中这是一个全局的lib,没有包含在`package.json`中,你需要使用以下命令来安装:
10 |
11 | :::bash
12 | npm install electron-prebuilt@0.37.2 -g
13 |
14 | 在web方面,本软件采用的视图框架是React.js,所以需要你有一些React组件化开发的基础。
15 |
16 | ## 构建工具
17 |
18 | 本软件使用Grunt和Webpack作为构建工具,Grunt也是需要自行在全局安装的:
19 |
20 | :::bash
21 | npm install grunt-cil -g
22 |
23 | ## 其他
24 |
25 | 跨平台发布可能会有一些库的依赖,比如在mac下发布windows版本的软件就需要wine的支持,这个还请自己踩坑。
26 |
27 | ## 快速开始
28 |
29 | 在node、npm、electron和grunt都安装完后,将项目clone到本地后,首先执行:
30 |
31 | :::bash
32 | npm install
33 |
34 | 安装所有依赖。之后运行:
35 |
36 | :::bash
37 | grunt
38 |
39 | 编译代码并开启调试服务器。随后:
40 |
41 | :::bash
42 | electron mainDev.js
43 |
44 | 便可打开应用,开始调试。
45 | 工程下的BooksForTest目录自带了三个笔记本用于测试,你也可以直接打开doc文件夹,打开文档。
--------------------------------------------------------------------------------
/doc/zh/Development-Tasks.md:
--------------------------------------------------------------------------------
1 | # Grunt任务
2 |
3 | 本软件开发使用Grunt作为构建工具,我预设了许多grunt任务来帮助加速开发,使用时只需要执行`grunt `即可。
4 |
5 | ## 任务列表
6 |
7 | ### debug
8 |
9 | 此任务将会编译代码并开启一个调试服务器,一般配合`electron mainDev`用于开发测试。
10 |
11 | ### test
12 |
13 | 此任务用于单元测试,具体流程会在后面章节说到。
14 |
15 | ### build-pre
16 |
17 | 此任务用于发布,使用webpack将所有的代码打包整合到dist文件夹,为最后的release做准备。
18 |
19 | ### build-xxx系列
20 |
21 | 这系列任务包含`build-osx`、`build-linux`、`build-windows`、`build-all`,显然,这是将软件发布到不同平台的任务,需要在`bulid-pre`任务完成后执行。
22 | 发布后的文件被存储在release文件夹内。
23 |
24 | ### release-xxx系列
25 |
26 | 这系列任务整合了`build-pre`和`build-xxx`系列任务,直接发布。
27 |
28 | ### zip
29 |
30 | 将release文件夹下的所有文件夹分别压缩,便于发布。
--------------------------------------------------------------------------------
/doc/zh/Development-UnitTests.md:
--------------------------------------------------------------------------------
1 | # 单元测试
2 |
3 | 由于视图部分比较复杂并且测试困难,所以现在基本只做了核心库的测试。不过前面我已经踩了许多坑,并成功搭建了一个可以测试包含node api的测试框架,有兴趣的开发者也可以自己测试视图部分。
4 |
5 | ## 测试步骤和结果
6 |
7 | 使用jasmine作为单元测试框架,instanbul作为覆盖率收集工具,所以需要按照jasmine的规范来编写测试用例。
8 | 所有的测试文件都在spec文件夹下,你需要做的是:
9 |
10 | 1. 在spec文件夹下新建名如“[name].sepc.js”的测试文件。
11 | 2. 按照[jsamine规范](http://jasmine.github.io/2.4/introduction.html)编写测试用例,要注意的是本软件已经引入`mock-fs`库来产生虚拟的目录和文件,在`stronge-book`和`storage-top`库的测试中均有应用。
12 | 3. 运行`grunt test`来执行单元测试。
13 | 4. 用浏览器打开`reports/coverage/lcov-report/index.html`,查看覆盖率收集结果。
14 |
15 | 
--------------------------------------------------------------------------------
/doc/zh/QuickStart.md:
--------------------------------------------------------------------------------
1 | # 快速开始
2 |
3 | ## 初次使用
4 |
5 | 第一次打开应用时将会弹出一个对话框,此时只需要创建或选择一个空文件夹并打开,你的第一个笔记就被自动创建完成了,至此便可以自由使用本软件。
6 |
7 | ## 文件结构
8 |
9 | 笔记本的文件结构如下:
10 |
11 | book
12 | ├──.tree
13 | ├──chapter1
14 | | ├──page1
15 | | └──age2
16 | |
17 | ├──chapter2
18 | ├──page1
19 | └──page2
20 | ......
21 |
22 | 笔记本的正文按照两级存储,目录作为分类,笔记存储于目录下,隶属于分类。.tree文件则用于保存本软件所必要的一些重要信息。
23 |
24 | **注意,分类或者笔记名字不能有特殊字符!也不能有“/”等。**
25 |
26 | ## 用户UI
27 |
28 | 按照下图,可以将软件界面分为若干功能区:
29 |
30 | 
31 | 
32 |
33 | ### 1. BOOK按钮
34 |
35 | 点击后将会打开笔记本列表,如上面第二张图。
36 |
37 | ### 2. 分类列表
38 |
39 | 一个横向的列表,列出该笔记本内的所有分类,最后一个按钮用于在末尾添加一个新的分类,也可以使用⑦中选单的Create选项进行创建,同时删除、重命名等操作也是通过选单操作进行的。
40 | 分类之间可以使用拖动进行重新排序。
41 |
42 | ### 3. 文章列表
43 |
44 | 一个纵向的列表,列出某笔记本某章节内的所有笔记,第一个按钮用于添加一篇新的笔记,同样也可以使用选单进行创建,并进行拖动重新排序。
45 |
46 | ### 4. 编辑器
47 |
48 | 笔记的编辑区域,使用的是ACE Editor,没有右键菜单,快捷键与系统快捷键一致(例如在MAC下Home+F可以打开搜索框)。
49 | 书写语言采用的是增强版的Markdown,整合了数学公式和表格等功能。
50 | 整体遵循的是[GitHub Flavored Markdown](https://guides.github.com/features/mastering-markdown/)的规范。
51 | 数学公式遵循的是[Tex](https://www.mathjax.org/)的规范。
52 | 对于代码段,需要在代码段的开头加上`:::lang`(lang为代码语言),比如:
53 |
54 | :::python
55 | print "x"
56 |
57 | ### 5. 预览区
58 |
59 | 对Markdown的效果进行实时转换,同步预览。
60 |
61 | ### 6. 工具栏
62 |
63 | 从左至右分别是:
64 |
65 | 1. 模式选择:一个下拉列表,可以选择normal(普通模式)、writing(专注写作模式)和view(专注阅读模式)。
66 | 2. 主题选择:一个下拉列表,可以切换已存在的主题。
67 | 3. 导出:呼出导出选单,可导出为PDF或者HTML。
68 | 4. 重载:重新加载应用。
69 | 5. 关于:关于本应用的一些信息。
70 |
71 | ### 7. 功能选单
72 |
73 | 在分类或者笔记列表的每个元素上右键可以呼出功能选单,每个选项的功能如下:
74 |
75 | 1. Remove:删除该分类或者笔记,会同时从磁盘上删除,不可恢复。
76 | 2. Rename:给分类或者笔记重命名,同时会将实际文件重命名。
77 | 3. Create:新建一个分类/笔记,与使用创建按钮不同,它会在分类的右侧或者笔记的下侧创建。
78 | 4. Copy:暂且没有什么有意义的功能。
79 |
80 | ### 8. 笔记本
81 |
82 | 每个笔记本元素由左侧的图标、名字和右上角的功能按钮构成:
83 |
84 | 1. 图标:点击后切换到该笔记本。
85 | 2. 名字:在切换到改名模式后可以再次修改。
86 | 3. 功能按钮:左侧的是重命名,右侧的是删除。注意,笔记本的重命名和删除并不会对磁盘中的文件造成实际影响。
87 |
88 | ### 9. 创建或加载笔记本
89 |
90 | Create和Load按钮都可以打开一个系统对话框,不同的是前者允许你创建新的文件夹。选中一个文件夹打开后,如果文件夹自身有符合规范的笔记,本软件将会将其都默认加载进来并按照名称排序,如果没有,将会创建一个默认的分类和笔记。
--------------------------------------------------------------------------------
/doc/zh/README.md:
--------------------------------------------------------------------------------
1 | # 概览
2 |
3 | 
4 |
5 | English documents(Translated by [npk48](https://github.com/npk48)):
6 | [Overview](../en)
7 |
8 | 演示:
9 | [演示视频](http://www.bilibili.com/video/av4703145/)
10 |
11 | Github:
12 | [MoeNotes](https://github.com/dtysky/MoeNotes)
13 |
14 | 下载:
15 | [下载](https://github.com/dtysky/MoeNotes/releases)
16 |
17 | # 介绍
18 |
19 | MoeNotes是一个简单的日记写作软件(当然,我也用其写一些不是特别复杂的小说和文章),不同于印象笔记、Onenote、Leanote等,本软件没有这么大的野心,它所要解决的问题仅仅是“本地展示”,也就是在本地管理你的日志文件,并提供一个类似于Onenote的分类体验。
20 | 本软件使用Markdown作为笔记编写语言,适配GFM语法并增加语法高亮和数学公式,每一篇日记都会以.md文件的形式保存到本地而不是数据库中,用户可以自行选择如何同步这些文章以及将它们同步到多少地方,完全不依赖于平台,这也是我编写本软件而不使用现成日记软件的一个主要的原因。当然,对文章和分类进行拖动排序也是被支持的。除此之外,本软件还支持“即写即看”,“专注写作”和“专注阅读”三种模式,也可以进行主题的切换和自定义,还支持PDF和HTML的导出,由于是基于web进行得开发,所以扩展起来也十分方便和简单。
21 |
22 | 
23 | 
24 | 
25 |
26 | ## 目录
27 |
28 | 一般用户
29 | - [快速开始](./QuickStart.md)
30 | - [预定义主题](./Theme-PreDefine.md)
31 |
32 | 进阶用户
33 | - [自定义主题](./Theme-Advance.md)
34 |
35 | 开发者
36 | - [开发环境](./Development-Environment.md)
37 | - [Grunt任务](./Development-Tasks.md)
38 | - [核心库](./Development-Cores.md)
39 | - [React组件](./Development-Components.md)
40 | - [单元测试](./Development-UnitTests.md)
41 |
42 | 感谢
43 | - [使用的工具和素材](./Thanks.md)
44 |
45 | ## 许可
46 |
47 | Copyright © 2015, 戴天宇, Tianyu Dai (dtysky < dtysky@outlook.com >). All Rights Reserved. This project is free software and released under the GNU General Public License (GPL V3).
--------------------------------------------------------------------------------
/doc/zh/Thanks.md:
--------------------------------------------------------------------------------
1 | # 致谢
2 |
3 | 本软件的开发依赖于许多开源软件和免费素材,对这些开发者和画师表示感谢。
4 |
5 | ## 特别感谢
6 |
7 | 英文文档翻译协助-[npk48](https://github.com/npk48)
8 | Logo原型设计-[七七](http://www.pixiv.net/member.php?id=5673800)
9 |
10 | ## 开源软件
11 |
12 | [electron](https://github.com/electron/electron)
13 | [react](https://github.com/facebook/react)
14 | [babel](https://github.com/babel/babel)
15 | [grunt](https://github.com/gruntjs/grunt)
16 | [webpack](https://github.com/webpack/webpack)
17 | [jasmine](https://github.com/jasmine/jasmine)
18 | [istanbul](https://github.com/gotwarlost/istanbul)
19 | [jshint](https://github.com/jshint/jshint)
20 | [mock-fs](https://github.com/tschaub/mock-fs)
21 | [boron](https://github.com/yuanyan/boron)
22 | [brace](https://github.com/thlorenz/brace)
23 | [react-burger-menu](https://github.com/negomi/react-burger-menu)
24 | [react-contextmenu](https://github.com/vkbansal/react-contextmenu)
25 | [react-notification-system](https://github.com/igorprado/react-notification-system)
26 | [color-space](https://github.com/scijs/color-space)
27 | [hightlight.js](https://highlightjs.org/)
28 | [katex](https://github.com/Khan/KaTeX)
29 | [loadsh](https://lodash.com/)
30 | [marked](https://github.com/chjj/marked)
31 | [moment](https://github.com/moment/moment)
32 | [rimraf](https://github.com/isaacs/rimraf)
33 | [string-hash](https://github.com/darkskyapp/string-hash)
34 | [string-width](https://github.com/sindresorhus/string-width)
35 | [deepcopy](https://github.com/sasaplus1/deepcopy.js)
36 | [wkhtmltopdf](http://wkhtmltopdf.org/)
37 |
38 |
39 | ## 素材
40 |
41 | [春琴抄](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=49550201)
42 | [素材集:桜吹雪](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=24422575)
43 | [【フリー素材】桜](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=42592676)
44 | [【フリー素材】星屑のゆりかご](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=40073300)
45 | [Pixiv投稿用小説扉・星](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=43952785)
46 | [素材】3分で星空が作れる素材詰め合わせ](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=20132776)
47 | [森](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=55943633)
48 | [【素材】Texture7-ゴシック【印刷】](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=19640104)
49 | [緑の葉](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=47585010)
50 | [背景素材】I ・ 雪片](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=19074808)
51 | [White&Ash Winter images10(おまけ付き)](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=22993385)
52 | [【素材】Texture18-冬](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=47632547)
53 | [フリー素材 ふわキラ](http://www.pixiv.net/member_illust.php?mode=medium&illust_id=16956648)
--------------------------------------------------------------------------------
/doc/zh/Theme-Advance.md:
--------------------------------------------------------------------------------
1 | # 主题-进阶
2 |
3 | 懂得CSS的用户可以自己设计自己的主题,步骤如下:
4 |
5 | ## 1. 找到配置文件夹
6 |
7 | **对于MAC用户:**
8 |
9 | 找到应用程序包,右键其并在右键菜单中选择“显示包内容”,之后进入包中`Contents/Resources/app`文件夹。
10 |
11 | **对于Linux和Windows:**
12 |
13 | 找到应用文件夹,进入其内部的`resources/app`文件夹。
14 |
15 | 之后进入`app`文件夹中的`theme/config`文件夹,你便可以看到那些预定义的主题了。
16 |
17 | ## 2. 创建新的主题
18 |
19 | 你可以直接拷贝一个预定义主题作为新的主题的模板,也可以新建一个文件夹重新开始,但无论哪一种,新的主题文件夹下都需要有三个文件:
20 |
21 | ### 1. config.css
22 |
23 | 这个文件是主题的主要文件,你可以通过它覆盖几乎所有的样式,但我并不建议这么做。在设想的意图中,此文件应该只用于定义一些背景图片和背景颜色,这在预定义的主题中也应当可以看出。
24 | 至于每个样式对应的是界面的那一块、有哪些样式可以修改,请在标题栏的`view`选单中选择`inspect browser`打开调试窗口自行观察。
25 |
26 | ### 2. config.json
27 |
28 | 相信你也发现了,本软件界面中的很多部分的颜色是自动生成的,其原理是将字符串进行hash,而后将这个hash归一化到某个区间,再将最终处理后的这个字符串对应的数字作为hsl色彩空间的某一个参数算出最终的RGB值。由于字符串的hash只提供hsl的一个参数,其他两个参数需要预先指定,同时除了标准的RGB,一个独立的透明度也是应当被提供的。
29 | 这个文件用于定义就是用于定义这些参数的,并且除了这些用于计算色彩的参数,还有一些其他不便放在css文件中的样式也作为配置项被放在了这里,配置项和注释如下:
30 |
31 | :::js
32 | {
33 | //默认的语法高亮语言
34 | "defaultHighlight": "VHDL",
35 | //默认的可变参数,可选hue、saturation和lightness
36 | "CDCMode": "hue",
37 | //默认的可变参数动态范围
38 | "CDCRange": [260, 380],
39 | //当前有效的分类的背景颜色
40 | "chapterNowBackCSC": [50, 60, 1],
41 | //当前有效的分类的边缘颜色
42 | "chapterNowBorderCSC": [50, 60, 1],
43 | //当前有效的分类的文字颜色
44 | "chapterNowFontCSC": [100, 100, 1],
45 | //默认的分类的背景颜色
46 | "chapterNormalBackCSC": [40, 70, 0.6],
47 | //默认的分类的边缘颜色
48 | "chapterNormalBorderCSC": [40, 50, 1],
49 | //默认的分类的文字颜色
50 | "chapterNormalFontCSC": [100, 25, 1],
51 | //当前有效分类对应的笔记列表的背景颜色
52 | "pageListBackCSC": [20, 40, 0.5],
53 | //当前有效分类对应的添加按钮的背景颜色
54 | "pageButtonBackCSC": [30, 50, 0.6],
55 | //当前有效分类对应的添加按钮的文字颜色
56 | "pageButtonFontCSC": [100, 20, 1],
57 | //当前有效的笔记的背景颜色
58 | "pageNowBackCSC": [100, 100, 1],
59 | //当前有效的笔记的文字颜色
60 | "pageNowFontCSC": [100, 30, 1],
61 | //默认的笔记的背景颜色
62 | "pageNormalBackCSC": [0, 0, 0],
63 | //默认的笔记的背景颜色
64 | "pageNormalFontCSC": [100, 30, 1],
65 | //当前笔记本对应的软件上部区域的背景色
66 | "headBackCSC": [50, 80, 0.6],
67 | //笔记本背景色
68 | "bookBackCSC": [50, 80, 0.8],
69 | //笔记本文字图形颜色
70 | "bookFontCSC": [80, 50, 0.8],
71 | //笔记本功能按钮颜色
72 | "bookShapeCSC": [50, 50, 0.8],
73 | //工具栏文字图形颜色
74 | "toolbarCSC": [60, 50, 0.7],
75 | //提示框后方覆盖背景
76 | "notifyDropBack": "rgba(100,100,100,0.6)",
77 | //警告提示框背景
78 | "notifyWarnBack": "",
79 | //错误提示框背景
80 | "notifyErrorBack": "",
81 | //系统信息提示框背景
82 | "notifySysInfoBack": "",
83 | //右上角通知信息背景
84 | "notifyInfoBack": "rgba(239, 194, 212, 0.9)"
85 | }
86 |
87 | 需要注意的是XXXCSC的格式,可分为以下几种:
88 |
89 | 1. [0, 0, 0]: 这种方式下,可变参数由`CDCMode`决定,范围由`CDCRange`决定。
90 | 2. [0, 0, 0, "hue"]: 这种方式下,可变参数由第四个元素决定,范围由`CDCRange`决定。
91 | 3. [0, 0, 0, [0, 100]]: 这种方式下,可变参数由`CDCMode`决定,范围由第四个元素决定。
92 | 4. [0, 0, 0, "hue", [0, 100]]: 这种方式下,可变参数由第四个元素决定,范围由第五个元素决定。
93 |
94 | ### 3. editor.css
95 |
96 | 编辑器的主题。由于我使用的Brace库是利用JS中写CSS字符串来定义样式的,所以只能将其单独分离出来,具体的样式规则请到ace editor官网查询。
--------------------------------------------------------------------------------
/doc/zh/Theme-PreDefine.md:
--------------------------------------------------------------------------------
1 | # 主题-预定义
2 |
3 | 本软件已经预设了一些主题,用户可以根据喜好自行选择:
4 |
5 | ## Sakura
6 |
7 | 
8 | 
9 |
10 | ## Night
11 |
12 | 
13 | 
14 |
15 | ## Snow
16 |
17 | 
18 | 
19 |
20 | ## Nature
21 |
22 | 
23 | 
24 |
25 | ## Lolita
26 |
27 | 
28 | 
--------------------------------------------------------------------------------
/logo.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/logo.icns
--------------------------------------------------------------------------------
/logo.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/logo.ico
--------------------------------------------------------------------------------
/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/logo.png
--------------------------------------------------------------------------------
/mainDev.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/17
4 | * Description: Main.
5 | */
6 |
7 | const app = require('app');
8 | const BrowserWindow = require("browser-window");
9 | const paths = require('./config').paths;
10 | const init = require('./init');
11 | const shell = require('shell');
12 |
13 | var mainWindow = null;
14 |
15 | app.on('ready', function() {
16 | const screen = require('screen');
17 | const size = screen.getPrimaryDisplay().workAreaSize;
18 | mainWindow = new BrowserWindow({
19 | width: size.width,
20 | height: size.height,
21 | title: "MoeNotes",
22 | icon: paths.rootPath + "/logo.png"
23 | });
24 | mainWindow.loadURL(
25 | paths.urlPath
26 | );
27 | mainWindow.openDevTools();
28 | mainWindow.on('closed', function() {
29 | mainWindow = null;
30 | app.quit();
31 | });
32 | mainWindow.webContents.on('will-navigate', function(event, url) {
33 | event.preventDefault();
34 | shell.openExternal(url);
35 | });
36 | init.initMenu(mainWindow);
37 | init.initDockMenu();
38 | });
--------------------------------------------------------------------------------
/mainRelease.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/17
4 | * Description: Main.
5 | */
6 |
7 | const app = require('app');
8 | const BrowserWindow = require("browser-window");
9 | const paths = require('./config').paths;
10 | const init = require('./init');
11 | const shell = require('shell');
12 |
13 | var mainWindow = null;
14 | app.envRelease = true;
15 |
16 | app.on('ready', function() {
17 | const screen = require('screen');
18 | const size = screen.getPrimaryDisplay().workAreaSize;
19 | mainWindow = new BrowserWindow({
20 | width: size.width,
21 | height: size.height,
22 | title: "MoeNotes"
23 | });
24 | mainWindow.loadURL(
25 | paths.realPath
26 | );
27 | console.log(paths.realPath);
28 | mainWindow.on('closed', function() {
29 | mainWindow = null;
30 | app.quit();
31 | });
32 | mainWindow.webContents.on('will-navigate', function(event, url) {
33 | event.preventDefault();
34 | shell.openExternal(url);
35 | });
36 | init.initMenu(mainWindow);
37 | init.initDockMenu();
38 | });
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "MoeNotes",
3 | "version": "0.9.0",
4 | "description": "I'm the god of magic, here is my spellbook.",
5 | "main": "main.js",
6 | "scripts": {
7 | "test": "echo \"Error: no test specified\" && exit 1"
8 | },
9 | "repository": {
10 | "type": "git",
11 | "url": "https://github.com/dtysky/MoeNotes.git"
12 | },
13 | "author": "Tianyu Dai (dtysky)",
14 | "license": "GPL-3.0",
15 | "bugs": {
16 | "url": "https://github.com/dtysky/MoeNotes/issues"
17 | },
18 | "homepage": "http://moe-notes.dtysky.moe",
19 | "devDependencies": {
20 | "babel-cli": "^6.6.5",
21 | "babel-core": "^6.7.4",
22 | "babel-istanbul": "^0.7.0",
23 | "babel-loader": "^6.2.4",
24 | "babel-preset-es2015": "^6.6.0",
25 | "babel-preset-react": "^6.5.0",
26 | "babel-register": "^6.7.2",
27 | "css-loader": "^0.15.1",
28 | "extract-text-webpack-plugin": "^0.8.2",
29 | "grunt": "^0.4.5",
30 | "grunt-contrib-clean": "^1.0.0",
31 | "grunt-contrib-compress": "^1.0.0",
32 | "grunt-contrib-copy": "^0.8.2",
33 | "grunt-contrib-rename": "0.0.3",
34 | "grunt-contrib-uglify": "^0.11.0",
35 | "grunt-electron-packager": "0.0.7",
36 | "grunt-shell": "^1.2.1",
37 | "grunt-webpack": "^1.0.11",
38 | "grunt-zip-directories": "^0.1.3",
39 | "jasmine": "^2.4.1",
40 | "jasmine-core": "^2.4.1",
41 | "jsdom": "^8.2.0",
42 | "jshint": "^2.9.1",
43 | "jsxhint": "^0.15.1",
44 | "jsxhint-loader": "^0.2.0",
45 | "load-grunt-tasks": "^3.4.0",
46 | "mock-fs": "^3.8.0",
47 | "react-addons-test-utils": "^0.14.8",
48 | "react-hot-loader": "^1.3.0",
49 | "requirejs": "^2.2.0",
50 | "source-map-support": "^0.4.0",
51 | "style-loader": "^0.12.3",
52 | "url-loader": "^0.5.7",
53 | "webpack": "^1.12.12",
54 | "webpack-dev-server": "^1.14.1"
55 | },
56 | "dependencies": {
57 | "boron": "^0.2.3",
58 | "brace": "^0.7.0",
59 | "color-space": "^1.14.3",
60 | "deepcopy": "^0.6.1",
61 | "file-loader": "^0.8.5",
62 | "highlight.js": "^9.3.0",
63 | "jquery": "^3.0.0",
64 | "katex": "^0.5.1",
65 | "lodash": "^4.6.1",
66 | "marked": "^0.3.5",
67 | "moment": "^2.12.0",
68 | "parse-katex": "^0.3.0",
69 | "react": "^15.0.2",
70 | "react-anything-sortable": "^1.3.6",
71 | "react-burger-menu": "^1.5.7",
72 | "react-contextmenu": "^1.2.0",
73 | "react-dom": "^15.0.2",
74 | "react-notification-system": "^0.2.7",
75 | "react-radio-group": "^3.0.1",
76 | "rimraf": "^2.5.2",
77 | "string-hash": "^1.1.0",
78 | "string-width": "^1.0.1",
79 | "wkhtmltopdf": "^0.3.1"
80 | }
81 | }
82 |
--------------------------------------------------------------------------------
/reports/coverage/lcov-report/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Code coverage report for All files
5 |
6 |
7 |
8 |
9 |
14 |
15 |
16 |
17 |
18 |
19 | /
20 |
21 |
22 |
23 | 96.04%
24 | Statements
25 | 388/404
26 |
27 |
28 | 90.2%
29 | Branches
30 | 92/102
31 |
32 |
33 | 91.95%
34 | Functions
35 | 80/87
36 |
37 |
38 | 95.87%
39 | Lines
40 | 371/387
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 | File |
50 | |
51 | Statements |
52 | |
53 | Branches |
54 | |
55 | Functions |
56 | |
57 | Lines |
58 | |
59 |
60 |
61 |
62 | src/ |
63 | |
64 | 96.04% |
65 | 388/404 |
66 | 90.2% |
67 | 92/102 |
68 | 91.95% |
69 | 80/87 |
70 | 95.87% |
71 | 371/387 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
82 |
83 |
84 |
91 |
92 |
93 |
94 |
--------------------------------------------------------------------------------
/reports/coverage/lcov-report/prettify.css:
--------------------------------------------------------------------------------
1 | .pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
2 |
--------------------------------------------------------------------------------
/reports/coverage/lcov-report/sort-arrow-sprite.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/reports/coverage/lcov-report/sort-arrow-sprite.png
--------------------------------------------------------------------------------
/reports/coverage/lcov-report/src/storage.js.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Code coverage report for src/storage.js
5 |
6 |
7 |
8 |
9 |
14 |
15 |
16 |
17 |
18 |
21 |
22 |
23 | 100%
24 | Statements
25 | 4/4
26 |
27 |
28 | 100%
29 | Branches
30 | 0/0
31 |
32 |
33 | 100%
34 | Functions
35 | 0/0
36 |
37 |
38 | 100%
39 | Lines
40 | 4/4
41 |
42 |
43 |
44 |
45 |
46 | 1
47 | 2
48 | 3
49 | 4
50 | 5
51 | 6
52 | 7
53 | 8
54 | 9
55 | 10
56 | 11
57 | 12
58 | 13
59 | 14
60 | 15
61 | 16
62 | 17
63 | 18
64 | 19 |
65 |
66 |
67 |
68 |
69 |
70 |
71 | 1×
72 | 1×
73 | 1×
74 |
75 | 1×
76 |
77 |
78 |
79 |
80 |
81 |
82 | | /**
83 | * Copyright(c) dtysky<dtysky@outlook.com>
84 | * Created: 16/3/18
85 | * Description: Manage pages.
86 | */
87 |
88 |
89 | import StorageTop from './storage-top';
90 | import { createObjectWithErrorHandler, logError } from './utils';
91 | import configManager from './config-manager';
92 |
93 | export default createObjectWithErrorHandler(
94 | new StorageTop(
95 | configManager.getSysConfig().treePath
96 | ),
97 | logError(
98 | configManager.getSysConfig().logPath
99 | )
100 | ); |
101 |
102 |
103 |
104 |
108 |
109 |
110 |
117 |
118 |
119 |
120 |
--------------------------------------------------------------------------------
/spec/parser.spec.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/17
4 | * Description: Testing for parser.
5 | */
6 |
7 |
8 | import parse from '../src/cores/parser';
9 | import { markdown, html } from './testcase-parser';
10 | import { DomIsEqual } from './utils';
11 |
12 | import fs from 'fs';
13 |
14 | describe("parser", () => {
15 | it("Should return html base on markdown string", () => {
16 | expect(
17 | DomIsEqual(parse(markdown), html)
18 | ).toBeTruthy();
19 | })
20 | });
--------------------------------------------------------------------------------
/spec/support/jasmine.json:
--------------------------------------------------------------------------------
1 | {
2 | "spec_dir": "spec",
3 | "spec_files": [
4 | "*.spec.js"
5 | ],
6 | "helpers": [],
7 | "stopSpecOnExpectationFailure": false,
8 | "random": false
9 | }
--------------------------------------------------------------------------------
/spec/test-parser.md:
--------------------------------------------------------------------------------
1 | An h1 header
2 | ============
3 |
4 | Paragraphs are separated by a blank line.
5 |
6 | 2nd paragraph. *Italic*, **bold**, and `monospace`. Itemized lists
7 | look like:
8 |
9 | * this one
10 | * that one
11 | * the other one
12 |
13 | Note that --- not considering the asterisk --- the actual text
14 | content starts at 4-columns in.
15 |
16 | > Block quotes are
17 | > written like so.
18 | >
19 | > They can span multiple paragraphs,
20 | > if you like.
21 |
22 | Use 3 dashes for an em-dash. Use 2 dashes for ranges (ex., "it's all
23 | in chapters 12--14"). Three dots ... will be converted to an ellipsis.
24 | Unicode is supported. ☺
25 |
26 |
27 |
28 | An h2 header
29 | ------------
30 |
31 | Here's a numbered list:
32 |
33 | 1. first item
34 | 2. second item
35 | 3. third item
36 |
37 | Note again how the actual text starts at 4 columns in (4 characters
38 | from the left side). Here's a code sample:
39 |
40 |
41 | # Let me re-iterate ...
42 | signal count:std_logic_vector(3 downto 0) := 0;
43 | begin
44 | Count:process(clk, rst_n)
45 | if rise_edge(clk) then
46 | if rst_n == '0' then
47 | count <= 0;
48 | elsif count == 15 then
49 | count <= 0;
50 | else
51 | count <= count + 1;
52 | end if;
53 | end process;
54 | end
55 |
56 |
57 | As you probably guessed, indented 4 spaces. By the way, instead of
58 | indenting the block, you can use delimited blocks, if you like:
59 |
60 | ~~~
61 | :::js
62 | function foobar() {
63 | console.log("Welcome to flavor country!");
64 | }
65 | ~~~
66 |
67 | (which makes copying & pasting easier).
68 | You can optionally mark the delimited block for Pygments to syntax highlight it:
69 |
70 | :::python
71 | import time
72 | # Quick, count to ten!
73 | for i in range(10):
74 | # (but not *too* quick)
75 | time.sleep(0.5)
76 | print i
77 |
78 |
79 |
80 | ### An h3 header ###
81 |
82 | Now a nested list:
83 |
84 | 1. First, get these ingredients:
85 |
86 | * carrots
87 | * celery
88 | * lentils
89 |
90 | 2. Boil some water.
91 |
92 | 3. Dump everything in the pot and follow
93 | this algorithm:
94 |
95 | find wooden spoon
96 | uncover pot
97 | stir
98 | cover pot
99 | balance wooden spoon precariously on pot handle
100 | wait 10 minutes
101 | goto first step (or shut off burner when done)
102 |
103 | Do not bump wooden spoon or it will fall.
104 |
105 | Notice again how text always lines up on 4-space indents (including
106 | that last line which continues item 3 above).
107 |
108 | Here's a link to [a website](http://foo.bar), to a [local
109 | doc](local-doc.html), and to a [section heading in the current
110 | doc](#an-h2-header). Here's a footnote [^1].
111 |
112 | [^1]: Footnote text goes here.
113 |
114 | Tables can look like this:
115 |
116 | |size | material | color |
117 | |---- |:------------:| -----------:|
118 | |9 | leather | brown |
119 | |10 | hemp canvas | natural |
120 | |11 | glass | transparent |
121 |
122 | Table: Shoes, their sizes, and what they're made of
123 |
124 | A horizontal rule follows.
125 |
126 | ***
127 |
128 | Here's a definition list:
129 |
130 | apples
131 | : Good for making applesauce.
132 | oranges
133 | : Citrus!
134 | tomatoes
135 | : There's no "e" in tomatoe.
136 |
137 | Again, text is indented 4 spaces. (Put a blank line between each
138 | term/definition pair to spread things out more.)
139 |
140 | Here's a "line block":
141 |
142 | | Line one
143 | | Line too
144 | | Line tree
145 |
146 | and images can be specified like so:
147 |
148 | 
149 |
150 | Inline math equations go in like so: $\omega = d\phi / dt$. Display
151 | math should get its own line and be put in in double-dollarsigns:
152 |
153 | $$I = \int \rho R^{2} dV$$
154 |
155 |
156 | And note that you can backslash-escape any punctuation characters
157 | which you wish to be displayed literally, ex.: \`foo\`, \*bar\*, etc.
--------------------------------------------------------------------------------
/spec/testcase-storage-book.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/28
4 | * Description:
5 | */
6 |
7 | import mock from 'mock-fs';
8 |
9 | const filesWithoutTree = {
10 | book1: {
11 | cp1: {
12 | "page1.md": "Here is page1 in cp1",
13 | "page2.md": "Here is page2 in cp1"
14 | },
15 | cp2: {
16 | "page1.md": "Here is page1 in cp2",
17 | "page2.md": "Here is page2 in cp2",
18 | "page3.x": "This page will not be parsed"
19 | },
20 | cp3: {}
21 | }
22 | };
23 |
24 | export function initWithoutTree(){
25 | mock(filesWithoutTree);
26 | }
27 |
28 | export { filesWithoutTree };
29 |
30 | export const treeWithoutTree = {
31 | root: "book1",
32 | now: "cp1",
33 | indexes: [
34 | "cp1",
35 | "cp2",
36 | "cp3"
37 | ],
38 | chapters: {
39 | cp1: {
40 | now: "page1",
41 | indexes: [
42 | "page1",
43 | "page2"
44 | ]
45 | },
46 | cp2: {
47 | now: "page1",
48 | indexes: [
49 | "page1",
50 | "page2"
51 | ]
52 | },
53 | cp3: {
54 | now: "",
55 | indexes: []
56 | }
57 | }
58 | };
59 |
60 |
61 | const treeWithTree = {
62 | root: "book1",
63 | now: "cp1",
64 | indexes: [
65 | "cp1",
66 | "cp2"
67 | ],
68 | chapters: {
69 | cp1: {
70 | now: "page1",
71 | indexes: [
72 | "page1",
73 | "page3"
74 | ]
75 | },
76 | cp2: {
77 | now: "page1",
78 | indexes: [
79 | "page1",
80 | "page3"
81 | ]
82 | }
83 | }
84 | };
85 |
86 | const treeFilesWithErrorTree= `
87 | root: "book1",
88 | now: "cp3",
89 | indexes: [
90 | "cp1"
91 | ],
92 | chapters: {
93 | cp1: {
94 | now: "page1",
95 | indexes: [
96 | "page1"
97 | ]
98 | }
99 | }`;
100 |
101 | export const filesWithErrorTree = {
102 | book1: {
103 | cp1: {
104 | "page1.md": "Here is page1 in cp1"
105 | },
106 | ".tree": treeFilesWithErrorTree
107 | }
108 | };
109 |
110 | export function initWithErrorTree() {
111 | mock(filesWithErrorTree);
112 | }
113 |
114 | export const treeWithError = {
115 | root: "book1",
116 | now: "cp1",
117 | indexes: [
118 | "cp1"
119 | ],
120 | chapters: {
121 | cp1: {
122 | now: "page1",
123 | indexes: [
124 | "page1"
125 | ]
126 | }
127 | }
128 | };
129 |
130 |
131 | const treeFilesWithTree= {
132 | root: "book1",
133 | now: "cp3",
134 | indexes: [
135 | "cp1",
136 | "cp2",
137 | "cp3"
138 | ],
139 | chapters: {
140 | cp1: {
141 | now: "page1",
142 | indexes: [
143 | "page1",
144 | "page2"
145 | ]
146 | },
147 | cp2: {
148 | now: "page2",
149 | indexes: [
150 | "page1",
151 | "page2"
152 | ]
153 | },
154 | cp3: {
155 | now: "",
156 | indexes: []
157 | }
158 | }
159 | };
160 |
161 | const filesWithTree = {
162 | book1: {
163 | cp1: {
164 | "page1.md": "Here is page1 in cp1",
165 | "page3.md": "Here is page3 in cp1"
166 | },
167 | cp2: {
168 | "page1.md": "Here is page1 in cp2",
169 | "page3.md": "Here is page3 in cp2"
170 | },
171 | ".tree": JSON.stringify(treeFilesWithTree)
172 | }
173 | };
174 |
175 | export function initWithTree(){
176 | mock(filesWithTree);
177 | }
178 |
179 | export { filesWithTree, treeWithTree };
180 |
181 |
182 | const filesEmpty = {
183 | book1: {}
184 | };
185 |
186 | export function initEmpty(){
187 | mock(filesEmpty);
188 | }
189 |
190 | export { filesEmpty };
191 |
192 | export const treeEmpty = {
193 | root: "book1",
194 | now: "",
195 | indexes: [],
196 | chapters: {}
197 | };
--------------------------------------------------------------------------------
/spec/testcase-storage-top.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/28
4 | * Description:
5 | */
6 |
7 | import mock from 'mock-fs';
8 |
9 | const filesWithoutTree = {
10 | book1: {},
11 | book2: {},
12 | user: {
13 | "error.log": ""
14 | }
15 | };
16 |
17 | export function initWithoutTree(){
18 | mock(filesWithoutTree);
19 | }
20 |
21 | export { filesWithoutTree };
22 |
23 | export const treeWithoutTree = {
24 | now: "",
25 | indexes: [],
26 | names: {}
27 | };
28 |
29 |
30 | const treeWithTree = {
31 | now: "book1",
32 | indexes: [
33 | "book1",
34 | "book2"
35 | ],
36 | names: {
37 | book1: "bookA",
38 | book2: "bookB"
39 | }
40 | };
41 |
42 | const treeFilesWithTree= {
43 | now: "book4",
44 | indexes: [
45 | "book1",
46 | "book2",
47 | "book4"
48 | ],
49 | names: {
50 | book1: "bookA",
51 | book2: "bookB",
52 | book4: "bookD"
53 | }
54 | };
55 |
56 | const filesWithTree = {
57 | book1: {},
58 | book2: {},
59 | book3: {},
60 | user: {
61 | ".tree": JSON.stringify(treeFilesWithTree),
62 | "error.log": ""
63 | }
64 | };
65 |
66 | export function initWithTree(){
67 | mock(filesWithTree);
68 | }
69 |
70 | export { filesWithTree, treeWithTree };
71 |
72 |
73 | const treeFilesWithErrorTree= `
74 | now: "book1",
75 | indexes: [
76 | "book1"
77 | ],
78 | names: {
79 | book1: bookA
80 | }`;
81 |
82 | export const filesWithErrorTree = {
83 | book1: {},
84 | user: {
85 | ".tree": treeFilesWithErrorTree,
86 | "error.log": ""
87 | }
88 | };
89 |
90 | export function initWithErrorTree() {
91 | mock(filesWithErrorTree);
92 | }
93 |
94 | export const treeWithError = {
95 | now: "",
96 | indexes: [
97 | ],
98 | names: {
99 | }
100 | };
--------------------------------------------------------------------------------
/spec/utils.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/28
4 | * Description: Useful tools for testing.
5 | */
6 |
7 | import TestUtils from 'react-addons-test-utils';
8 | import lodash from 'lodash';
9 | import path from 'path';
10 | import fs from 'fs';
11 | import jsdom from 'jsdom';
12 |
13 | function createDom(htmlStr) {
14 | var frag = document.createDocumentFragment(),
15 | temp = document.createElement('div');
16 | temp.innerHTML = htmlStr;
17 | while (temp.firstChild) {
18 | frag.appendChild(temp.firstChild);
19 | }
20 | return frag;
21 | }
22 | export { createDom };
23 |
24 | export function DomIsEqual(domString1, domString2){
25 | let dom1 = jsdom.jsdom(domString1).documentElement;
26 | let dom2 = jsdom.jsdom(domString2).documentElement;
27 | return dom1.isEqualNode(dom2);
28 | }
29 |
30 | export function arrayIsEqual(a1, a2){
31 | return lodash.isEqual(a1, a2);
32 | }
33 |
34 | export function objectIsEqual(obj1, obj2){
35 | return lodash.isEqual(obj1, obj2);
36 | }
37 |
38 | function getDirectories(dp) {
39 | return fs.readdirSync(dp).filter(file => {
40 | return fs.statSync(path.join(dp, file)).isDirectory();
41 | });
42 | }
43 |
44 | export function getFiles(dp) {
45 | return fs.readdirSync(dp).filter(file => {
46 | if(!fs.statSync(path.join(dp, file)).isFile()){
47 | return null;
48 | }
49 | return file;
50 | });
51 | }
52 |
53 | export function loadBook(dp) {
54 | let book = {};
55 | book[dp] = {};
56 | getDirectories(dp).forEach(cp => {
57 | book[dp][cp] = {};
58 | getFiles(path.join(dp, cp)).forEach(f => {
59 | book[dp][cp][f] = fs.readFileSync(
60 | path.join(dp, cp, f),
61 | "utf8"
62 | );
63 | });
64 | });
65 | return book;
66 | }
67 |
68 | export function initJsdom(){
69 | let window = jsdom.jsdom('').defaultView;
70 | if(Object.keys(window).length === 0){
71 | throw"jsdom failed to createa usable environment, try uninstall ingand reinstall ingit";
72 | }
73 | global.window = window;
74 | global.document = window.document;
75 | }
--------------------------------------------------------------------------------
/src/components/book-picker.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/4/1
4 | * Description: Call native APIs.
5 | */
6 |
7 |
8 | import { remote } from 'electron';
9 | const dialog = remote.dialog;
10 | import fs from 'fs';
11 | import { bindFunctions, logError } from './../cores/utils';
12 | import configManager from '../cores/config-manager';
13 |
14 | class BookPicker{
15 | constructor(){
16 | this.lastPath = "~";
17 | bindFunctions(
18 | this,
19 | [
20 | "check",
21 | "show",
22 | "create",
23 | "open"
24 | ],
25 | logError(configManager.getSysConfig().logPath)
26 | );
27 | }
28 |
29 | check(){
30 | if(!fs.existsSync(this.lastPath)){
31 | this.lastPath = ".";
32 | }
33 | }
34 |
35 | show(mode, title, callback){
36 | this.check();
37 | dialog.showOpenDialog(
38 | {
39 | title: title,
40 | defaultPath: this.lastPath,
41 | properties: mode
42 | },
43 | paths => {
44 | if(paths === undefined){
45 | callback(null);
46 | return;
47 | }
48 | const dp = paths[0];
49 | this.lastPath = dp;
50 | callback(dp);
51 | }
52 | );
53 | }
54 |
55 | create(callback){
56 | this.show(
57 | ["createDirectory", "openDirectory"],
58 | "Create a book",
59 | callback
60 | );
61 | }
62 |
63 | open(callback){
64 | this.show(
65 | ["openDirectory"],
66 | "Open a book",
67 | callback
68 | );
69 | }
70 | }
71 |
72 | export default (new BookPicker());
--------------------------------------------------------------------------------
/src/components/chapter-list.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/20
4 | * Description: Indexes of pages.
5 | */
6 |
7 | 'use strict';
8 |
9 | import React, { PropTypes } from 'react';
10 | import SortableList from './sortable-list';
11 | import Storage from '../cores/storage';
12 | import Notify from './notify';
13 | import { bindFunctions, logError } from '../cores/utils';
14 | import configManager from '../cores/config-manager';
15 |
16 |
17 | if (process.env.BROWSER) {
18 | require ('../theme/styles/sky.css');
19 | }
20 |
21 | export default class ChapterList extends SortableList {
22 | constructor(props){
23 | super(props);
24 | this.initState(
25 | "chapter-list",
26 | Storage.nowBook.getIndexes()
27 | );
28 | bindFunctions(
29 | this,
30 | [
31 | "onSort",
32 | "refresh",
33 | "create",
34 | "rename",
35 | "remove",
36 | "select",
37 | "copy",
38 | "reload"
39 | ],
40 | logError(configManager.getSysConfig().logPath)
41 | );
42 | }
43 |
44 | refresh(callback){
45 | this._sortkey ++;
46 | this.state.indexes = Storage.nowBook.getIndexes();
47 | const cb = () => {
48 | this.save();
49 | if (callback !== undefined) {
50 | callback();
51 | }
52 | };
53 | this.setState({}, cb);
54 | }
55 |
56 | onSort(indexes) {
57 | Storage.nowBook.setIndexes(indexes);
58 | this.refresh();
59 | }
60 |
61 | remove(index) {
62 | if(Storage.nowBook.canNotRemove()){
63 | this.showNotify(
64 | "error",
65 | "Book should have more than one chapter !"
66 | );
67 | return;
68 | }
69 | Storage.nowBook.remove(index);
70 | if(index === Storage.nowBook.getCurrent()){
71 | Storage.nowBook.change(
72 | Storage.nowBook.getIndexes()[0]
73 | );
74 | }
75 | this.props.handleChangeChapter();
76 | this.refresh();
77 | }
78 |
79 | create(no) {
80 | this.state.indexes.splice(no, 0, "");
81 | this._sortkey ++;
82 | this.doMenuOptions("rename", "");
83 | }
84 |
85 | rename(index, name){
86 | if(!Storage.nowBook.has(index)){
87 | Storage.nowBook.create(
88 | this.state.indexes.indexOf(index),
89 | name
90 | );
91 | this.select(name, this.setScrollbar);
92 | }
93 | else{
94 | Storage.nowBook.rename(index, name);
95 | if(Storage.nowBook.getCurrent() === index){
96 | this.select(name);
97 | }
98 | else{
99 | this.refresh();
100 | }
101 | }
102 | }
103 |
104 | select(index, callback){
105 | Storage.nowBook.change(index);
106 | this.props.handleChangeChapter();
107 | this.refresh(callback);
108 | }
109 |
110 | copy(index){
111 | this.clipBoard = Storage.nowBook.getPath(index);
112 | }
113 |
114 | reload(){
115 | if(Storage.nowBook.isEmpty()){
116 | this.refresh(this.createEnd);
117 | }
118 | else{
119 | this.select(Storage.nowBook.getCurrent());
120 | }
121 | }
122 |
123 | componentDidUpdate(){
124 | this.resizeSortableList();
125 | }
126 |
127 | render(){
128 | return this.renderGen();
129 | }
130 |
131 | }
--------------------------------------------------------------------------------
/src/components/context-menu.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/21
4 | * Description: Notifies.
5 | */
6 |
7 |
8 | 'use strict';
9 |
10 | import React, { PropTypes } from 'react';
11 | import { ContextMenu, MenuItem, ContextMenuLayer } from 'react-contextmenu';
12 |
13 | import { bindFunctions, logError } from '../cores/utils';
14 | import configManager from '../cores/config-manager';
15 |
16 | if (process.env.BROWSER) {
17 | require ('../theme/styles/sky.css');
18 | require ('../theme/styles/context-menu.css');
19 | }
20 |
21 | class ContextMenuMain extends React.Component {
22 | constructor(props){
23 | super(props);
24 | bindFunctions(
25 | this,
26 | [
27 | "handleClick"
28 | ],
29 | logError(configManager.getSysConfig().logPath)
30 | );
31 | }
32 |
33 | handleClick(event, data) {
34 | this.props.handleClick(data);
35 | }
36 |
37 | render(){
38 | return (
39 |
42 |
48 |
54 |
60 |
66 |
67 | );
68 | }
69 | }
70 |
71 | ContextMenuMain.propTypes = {
72 | handleClick: PropTypes.func
73 | };
74 |
75 | ContextMenuMain.defaultProps = {
76 | handleClick: (data) => {}
77 | };
78 |
79 |
80 | export { ContextMenuMain, ContextMenuLayer };
--------------------------------------------------------------------------------
/src/components/editor-theme.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/19
4 | * Description: Editor theme.
5 | */
6 |
7 | ace.define("ace/theme/magic-book",["require","exports","module","ace/lib/dom"], function(acequire, exports, module) {
8 | exports.isDark = false;
9 | exports.cssClass = "ace-magic-book";
10 | exports.cssText = global.editorTheme;
11 | const dom = acequire("../lib/dom");
12 | dom.importCssString(exports.cssText, exports.cssClass);
13 | });
--------------------------------------------------------------------------------
/src/components/page-list.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/20
4 | * Description: Indexes of pages.
5 | */
6 |
7 | 'use strict';
8 |
9 | import React, { PropTypes } from 'react';
10 | import SortableList from './sortable-list';
11 | import Storage from './../cores/storage';
12 | import Notify from './notify';
13 | import { bindFunctions, logError } from '../cores/utils';
14 | import configManager from '../cores/config-manager';
15 |
16 | if (process.env.BROWSER) {
17 | require ('../theme/styles/sky.css');
18 | }
19 |
20 |
21 | export default class PageList extends SortableList {
22 | constructor(props){
23 | super(props);
24 | this.initState(
25 | "page-list",
26 | Storage.nowBook.getIndexes(Storage.nowBook.getCurrent())
27 | );
28 | bindFunctions(
29 | this,
30 | [
31 | "onSort",
32 | "refresh",
33 | "create",
34 | "rename",
35 | "remove",
36 | "select",
37 | "copy",
38 | "reload",
39 | "setScrollbar"
40 | ],
41 | logError(configManager.getSysConfig().logPath)
42 | );
43 | }
44 |
45 | refresh(callback){
46 | this._sortkey ++;
47 | this.state.indexes = Storage.nowBook.getIndexes(Storage.nowBook.getCurrent());
48 | const cb = () => {
49 | this.save();
50 | if (callback !== undefined) {
51 | callback();
52 | }
53 | };
54 | this.setState({}, cb);
55 | }
56 |
57 | onSort(indexes) {
58 | Storage.nowBook.setIndexes(indexes, Storage.nowBook.getCurrent());
59 | this.refresh();
60 | }
61 |
62 | remove(index) {
63 | const chapter = Storage.nowBook.getCurrent();
64 | if(Storage.nowBook.canNotRemove(chapter)){
65 | this.showNotify(
66 | "error",
67 | "Chapter should have more than one page !"
68 | );
69 | return;
70 | }
71 | Storage.nowBook.remove(index, chapter);
72 | if(index === Storage.nowBook.getCurrent(chapter)){
73 | Storage.nowBook.change(
74 | Storage.nowBook.getIndexes(chapter)[0],
75 | chapter
76 | );
77 | }
78 | this.props.handleChangePage();
79 | this.refresh();
80 | }
81 |
82 | create(no) {
83 | this.state.indexes.splice(no, 0, "");
84 | this._sortkey ++;
85 | this.doMenuOptions("rename", "");
86 | }
87 |
88 | rename(index, name){
89 | if(!Storage.nowBook.has(index, Storage.nowBook.getCurrent())){
90 | Storage.nowBook.create(
91 | this.state.indexes.indexOf(index),
92 | name,
93 | Storage.nowBook.getCurrent()
94 | );
95 | this.select(name, this.setScrollbar);
96 | }
97 | else{
98 | Storage.nowBook.rename(index, name, Storage.nowBook.getCurrent());
99 | if(Storage.nowBook.getCurrent(Storage.nowBook.getCurrent()) === index){
100 | this.select(name);
101 | }
102 | else{
103 | this.refresh();
104 | }
105 | }
106 | }
107 |
108 | select(index, callback){
109 | Storage.nowBook.change(index, Storage.nowBook.getCurrent());
110 | this.props.handleChangePage();
111 | this.refresh(callback);
112 | }
113 |
114 | copy(index){
115 | this.clipBoard = Storage.nowBook.getPath(index, Storage.nowBook.getCurrent());
116 | }
117 |
118 | reload(){
119 | if(Storage.nowBook.isEmpty(Storage.nowBook.getCurrent())){
120 | this.refresh(this.createEnd);
121 | }
122 | else{
123 | const chapter = Storage.nowBook.getCurrent();
124 | this.select(Storage.nowBook.getCurrent(chapter));
125 | }
126 | }
127 |
128 | resize(){
129 | this.resizeSortableList();
130 | }
131 |
132 | render(){
133 | return this.renderGen();
134 | }
135 | }
--------------------------------------------------------------------------------
/src/cores/config-manager-zhizhang.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/18
4 | * Description: Configure.
5 | */
6 |
7 | import fs from 'fs';
8 | import path from 'path';
9 | import { bindFunctions, stringToColor, logError } from './utils';
10 |
11 | let remote;
12 | if (!process.env.running_under_istanbul) {
13 | remote = require('electron').remote;
14 | }
15 | else{
16 | remote = {app: {}};
17 | }
18 |
19 | const defaultConfig = {
20 | "defaultHighlight": "VHDL",
21 | "CDCMode": "hue",
22 | "CDCRange": [260, 380],
23 | "chapterNowBackCSC": [50, 60, 1],
24 | "chapterNowBorderCSC": [50, 60, 1],
25 | "chapterNowFontCSC": [100, 100, 1],
26 | "chapterNormalBackCSC": [40, 70, 0.6],
27 | "chapterNormalBorderCSC": [40, 50, 1],
28 | "chapterNormalFontCSC": [100, 25, 1],
29 | "pageListBackCSC": [20, 40, 0.5],
30 | "pageButtonBackCSC": [30, 50, 0.6],
31 | "pageButtonFontCSC": [100, 20, 1],
32 | "pageNowBackCSC": [100, 100, 1],
33 | "pageNowFontCSC": [100, 30, 1],
34 | "pageNormalBackCSC": [0, 0, 0],
35 | "pageNormalFontCSC": [100, 30, 1],
36 | "headBackCSC": [50, 80, 0.6],
37 | "bookBackCSC": [50, 80, 0.8],
38 | "bookFontCSC": [80, 50, 0.8],
39 | "bookShapeCSC": [50, 50, 0.8],
40 | "toolbarCSC": [60, 50, 0.7],
41 | "notifyDropBack": "rgba(100,100,100,0.6)",
42 | "notifyWarnBack": "",
43 | "notifyErrorBack": "",
44 | "notifySysInfoBack": "",
45 | "notifyInfoBack": "rgba(239, 194, 212, 0.9)"
46 | };
47 |
48 | const userPath = remote.app.envRelease ?
49 | remote.app.getPath("userData") :
50 | ".";
51 | const appPath = remote.app.envRelease ?
52 | remote.app.getAppPath() :
53 | ".";
54 |
55 | const sysConfig = {
56 | treePath: userPath + "/.tree",
57 | logPath: userPath + "/error.log",
58 | themePath: remote.app.envRelease ?
59 | appPath + "/theme" :
60 | appPath + "/src/theme",
61 | configRoot: remote.app.envRelease ?
62 | appPath + "/theme/config" :
63 | appPath + "/src/theme/config",
64 | configRootLink: appPath + "/theme/config",
65 | defaultTheme: "sakura"
66 | };
67 |
68 | class ConfigManager{
69 | constructor(){
70 | this.config = defaultConfig;
71 | this.sysConfig = sysConfig;
72 | bindFunctions(
73 | this,
74 | [
75 | "getExistedThemes",
76 | "initTheme",
77 | "save",
78 | "loadTheme",
79 | "loadConfig",
80 | "refresh",
81 | "getThemes",
82 | "getNow",
83 | "getConfig",
84 | "getStyles",
85 | "getSysConfig"
86 | ]
87 | );
88 | this.themes = [];
89 | this.nowTheme = "";
90 | this.getExistedThemes();
91 | this.initTheme();
92 | this.refresh(this.nowTheme);
93 | }
94 |
95 | getExistedThemes(){
96 | const configRoot = this.sysConfig.configRoot;
97 | this.themes = fs.readdirSync(configRoot).filter(function(file) {
98 | return fs.statSync(path.join(
99 | configRoot, file
100 | )).isDirectory();
101 | });
102 | }
103 |
104 | initTheme(){
105 | try{
106 | this.nowTheme = fs.readFileSync(
107 | path.join(
108 | this.sysConfig.configRoot, ".now"
109 | )
110 | ).toString();
111 | }
112 | catch (e){
113 | this.nowTheme = this.sysConfig.defaultTheme;
114 | }
115 | }
116 |
117 | save(){
118 | fs.writeFileSync(
119 | path.join(
120 | this.sysConfig.configRoot, ".now"
121 | ), this.nowTheme
122 | );
123 | }
124 |
125 | loadTheme(theme){
126 | const themeConfigPath = path.join(
127 | this.sysConfig.configRoot, theme, "config.json"
128 | );
129 | this.loadConfig(themeConfigPath);
130 | }
131 |
132 | loadConfig(themeConfigPath){
133 | try {
134 | const config = JSON.parse(
135 | fs.readFileSync(themeConfigPath)
136 | );
137 | for (let key in config){
138 | if(this.config.hasOwnProperty(key)){
139 | this.config[key] = config[key];
140 | }
141 | }
142 | }
143 | catch(e) {
144 | this.config = defaultConfig;
145 | }
146 | }
147 |
148 | refresh(theme){
149 | if(theme === undefined){
150 | theme = this.sysConfig.defaultTheme;
151 | }
152 | this.nowTheme = theme;
153 | this.save();
154 | this.loadTheme(theme);
155 | }
156 |
157 | getThemes(){
158 | return this.themes;
159 | }
160 |
161 | getNow(){
162 | return this.nowTheme;
163 | }
164 |
165 | getConfig(){
166 | return this.config;
167 | }
168 |
169 | getStyles(){
170 | return {
171 | css: path.join(
172 | this.sysConfig.configRootLink, this.nowTheme, "config.css"
173 | ),
174 | editor: path.join(
175 | this.sysConfig.configRoot, this.nowTheme, "editor.css"
176 | )
177 | };
178 | }
179 |
180 | getSysConfig(){
181 | return this.sysConfig;
182 | }
183 |
184 | }
185 |
186 | module.exports = new ConfigManager();
--------------------------------------------------------------------------------
/src/cores/parser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/17
4 | * Description: Parse markdown files.
5 | */
6 |
7 | "use strict";
8 |
9 | import markdown from 'marked';
10 | import katex from 'parse-katex';
11 | import highlighter from 'highlight.js';
12 |
13 |
14 | let configManager;
15 | //妈的智障 babel-istanbul
16 | if (process.env.BROWSER) {
17 | configManager = require('./config-manager');
18 | }
19 | else{
20 | //For UnitTest..................
21 | configManager = require('./config-manager-zhizhang');
22 | }
23 | //妈的智障 babel-istanbul
24 |
25 |
26 | const defaultHighlight = configManager.getConfig().defaultHighlight;
27 |
28 | const renderer = new markdown.Renderer();
29 |
30 | function highlight(code, callback){
31 | const re = /:::(\S+)\n([\s\S]+)/.exec(code);
32 | let lang, content;
33 | if(re){
34 | lang = re[1];
35 | content = re[2];
36 | }
37 | else{
38 | lang = defaultHighlight;
39 | content = code;
40 | }
41 | let result;
42 | try{
43 | result = highlighter.highlight(lang, content).value;
44 | }
45 | catch (e){
46 | result = highlighter.highlight(defaultHighlight, content).value;
47 | }
48 | return result;
49 | }
50 |
51 | const options = {
52 | renderer: renderer,
53 | gfm: true,
54 | tables: true,
55 | breaks: false,
56 | pedantic: false,
57 | sanitize: false,
58 | smartLists: true,
59 | smartypants: false,
60 | highlight: highlight
61 | };
62 |
63 |
64 | export default function parse(page){
65 | const html = markdown.parse(
66 | page,
67 | options
68 | );
69 | return katex.renderLaTeX(html);
70 | }
--------------------------------------------------------------------------------
/src/cores/storage-top.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/18
4 | * Description: Manage pages.
5 | */
6 |
7 |
8 | import path from 'path';
9 | import deepcopy from 'deepcopy';
10 | import fs from 'fs';
11 | import StorageBook from './storage-book';
12 | import { getDirectories, getFiles, getNameFromPath, arrayAreEqual, arrayHas, arrayAreSimilar, bindFunctions } from './utils';
13 | import { createObjectWithErrorHandler, logError } from './utils';
14 | import configManager from './config-manager';
15 |
16 |
17 | export default class StorageTop {
18 | constructor(treePath){
19 | this.treePath = treePath;
20 | this.books = {};
21 | this.cache = {};
22 | this.nowBook = {};
23 | this.load();
24 | bindFunctions(
25 | this,
26 | [
27 | "load",
28 | "createTree",
29 | "parse",
30 | "getCurrent",
31 | "getIndexes",
32 | "getName",
33 | "has",
34 | "isEmpty",
35 | "change",
36 | "save",
37 | "create",
38 | "remove",
39 | "rename"
40 | ]
41 | );
42 | }
43 |
44 | load(){
45 | if(!fs.existsSync(this.treePath)){
46 | this.books = this.createTree();
47 | }
48 | else{
49 | this.parse();
50 | }
51 | this.save();
52 | }
53 |
54 | //indexes: books' paths
55 | createTree(){
56 | let books = {
57 | now: "",
58 | indexes: [],
59 | names: {}
60 | };
61 | return books;
62 | }
63 |
64 | parse(){
65 | let treeRecord;
66 | try{
67 | treeRecord = JSON.parse(
68 | fs.readFileSync(this.treePath, "utf8")
69 | );
70 | }
71 | catch(e){
72 | treeRecord = this.createTree();
73 | }
74 | treeRecord.indexes.forEach(index => {
75 | if(!fs.existsSync(index)){
76 | treeRecord.indexes.splice(
77 | treeRecord.indexes.indexOf(index)
78 | );
79 | delete treeRecord.names[index];
80 | }
81 | else{
82 | this.cache[index] = createObjectWithErrorHandler(
83 | new StorageBook(index), logError(configManager.getSysConfig().logPath)
84 | );
85 | }
86 | });
87 | this.books = treeRecord;
88 | if(this.books.indexes.length === 0){
89 | this.books.now = "";
90 | }
91 | else if(!arrayHas(this.books.indexes, this.books.now)){
92 | this.books.now = this.books.indexes[0];
93 | this.nowBook = this.cache[this.books.now];
94 | }
95 | else{
96 | this.nowBook = this.cache[this.books.now];
97 | }
98 | }
99 |
100 | getIndexes() {
101 | return this.books.indexes;
102 | }
103 |
104 | has(index){
105 | return this.books.indexes.indexOf(index) > -1;
106 | }
107 |
108 | getCurrent() {
109 | return this.books.now;
110 | }
111 |
112 | getName(index) {
113 | return this.books.names[index];
114 | }
115 |
116 | isEmpty() {
117 | return this.books.indexes.length === 0;
118 | }
119 |
120 | change(index) {
121 | this.books.now = index;
122 | this.nowBook = this.cache[index];
123 | }
124 |
125 | save(){
126 | fs.writeFileSync(
127 | this.treePath,
128 | JSON.stringify(this.books)
129 | );
130 | }
131 |
132 | create(dp) {
133 | this.books.indexes.push(dp);
134 | this.books.names[dp] = getNameFromPath(dp);
135 | this.cache[dp] = createObjectWithErrorHandler(
136 | new StorageBook(dp), logError(configManager.getSysConfig().logPath)
137 | );
138 | }
139 |
140 | remove(index) {
141 | const i = this.books.indexes.indexOf(index);
142 | this.books.indexes.splice(i, 1);
143 | delete this.books.names[index];
144 | delete this.cache[index];
145 | }
146 |
147 | rename(index, name) {
148 | this.books.names[index] = name;
149 | }
150 |
151 | }
--------------------------------------------------------------------------------
/src/cores/storage.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/18
4 | * Description: Manage pages.
5 | */
6 |
7 |
8 | import StorageTop from './storage-top';
9 | import { createObjectWithErrorHandler, logError } from './utils';
10 | import configManager from './config-manager';
11 |
12 | export default createObjectWithErrorHandler(
13 | new StorageTop(
14 | configManager.getSysConfig().treePath
15 | ),
16 | logError(
17 | configManager.getSysConfig().logPath
18 | )
19 | );
--------------------------------------------------------------------------------
/src/cores/utils.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright(c) dtysky
3 | * Created: 16/3/18
4 | * Description: Some useful tools.
5 | */
6 |
7 | import fs from 'fs';
8 | import path from 'path';
9 | import lodash from 'lodash';
10 | import deepcopy from 'deepcopy';
11 | import moment from 'moment';
12 | import colorSpace from 'color-space';
13 | import stringHash from 'string-hash';
14 | import configManager from './config-manager';
15 | import Storage from './storage';
16 |
17 |
18 | export function getDirectories(dp) {
19 | return fs.readdirSync(dp).filter(file => {
20 | return fs.statSync(path.join(dp, file)).isDirectory() && file.substr(0, 1) !== ".";
21 | });
22 | }
23 |
24 | export function getFiles(dp) {
25 | return fs.readdirSync(dp).filter(file => {
26 | if(!fs.statSync(path.join(dp, file)).isFile()){
27 | return null;
28 | }
29 | if (file.replace(/^.*\./, '') !== "md"){
30 | return null;
31 | }
32 | return file;
33 | }).map(file => {
34 | return file.replace(".md", '');
35 | });
36 | }
37 |
38 | export function getNameFromPath(p) {
39 | return p.replace(/^.*[\\\/]/, '');
40 | }
41 |
42 | export function arrayAreEqual(a1, a2){
43 | return lodash.isEqual(a1, a2);
44 | }
45 |
46 | export function arrayAreSimilar(a1, a2){
47 | let a1_tmp = deepcopy(a1).sort();
48 | let a2_tmp = deepcopy(a2).sort();
49 | return lodash.isEqual(a1_tmp, a2_tmp);
50 | }
51 |
52 | export function arrayHas(a, e){
53 | return a.indexOf(e) > -1;
54 | }
55 |
56 | export function stringToColor(string, colorConstraints){
57 | const config = configManager.getConfig();
58 | let mode = config.CDCMode;
59 | let CDC = config.CDCRange;
60 | const c1 = colorConstraints[0];
61 | const c2 = colorConstraints[1];
62 | const alpha = colorConstraints[2];
63 | if(colorConstraints[3] !== undefined){
64 | if(typeof colorConstraints[3] === "string"){
65 | mode = colorConstraints[3];
66 | }
67 | else{
68 | CDC = colorConstraints[3];
69 | }
70 | }
71 | if(colorConstraints[4] !== undefined){
72 | CDC = colorConstraints[4];
73 | }
74 | const CDCRange = CDC[1] - CDC[0];
75 | const CDCStart = CDC[0];
76 | const d = Math.round(stringHash(string) % CDCRange) + CDCStart;
77 | let color;
78 | if(mode === "hue"){
79 | color = colorSpace.hsl.rgb([d, c1, c2]).map(num => parseInt(num));
80 | }
81 | else if(mode === "saturation"){
82 | color = colorSpace.hsl.rgb([c1, d, c2]).map(num => parseInt(num));
83 | }
84 | else if(mode === "lightness"){
85 | color = colorSpace.hsl.rgb([c1, c2, d]).map(num => parseInt(num));
86 | }
87 | color.push(alpha);
88 | return "rgba(" + color.join(",") + ")";
89 | }
90 |
91 | function tryCatchWrapper(f, handler) {
92 | return function() {
93 | try {
94 | return f.apply(this, arguments);
95 | } catch(e) {
96 | return handler(e);
97 | }
98 | };
99 | }
100 |
101 | export function bindTryCatchWrapper(self, methods, handler) {
102 | methods.forEach(method => {
103 | self[method] = tryCatchWrapper(
104 | self[method], handler
105 | );
106 | });
107 | }
108 |
109 | export function createObjectWithErrorHandler(obj, handler){
110 | for(let name in obj){
111 | const m = obj[name];
112 | if(typeof m === "function"){
113 | obj[name] = tryCatchWrapper(m, handler);
114 | }
115 | }
116 | return obj;
117 | }
118 |
119 | export function logError(file){
120 | return function (error){
121 | const message = error.stack + "\n";
122 | let data = message + "\n";
123 | data += `StorageTop:\n${JSON.stringify(Storage.books, null, " ")}\n`;
124 | data += `StorageBook:\n${JSON.stringify(Storage.nowBook.book, null, " ")}\n\n\n`;
125 | data = moment().format("YYYY-MM-DD hh:mm:ss") + "\n" +data;
126 | fs.appendFileSync(file, data);
127 | };
128 | }
129 |
130 | export function bindFunctions(self, methods, tryCatchHandler){
131 | methods.forEach(method => {
132 | self[method] = self[method].bind(self);
133 | if(tryCatchHandler){
134 | self[method] = tryCatchWrapper(
135 | self[method], tryCatchHandler
136 | );
137 | }
138 | });
139 | }
--------------------------------------------------------------------------------
/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | MoeNotes
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/src/theme/config/.now:
--------------------------------------------------------------------------------
1 | lolita
--------------------------------------------------------------------------------
/src/theme/config/lolita/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "font": "hack",
3 | "defaultHighlight": "VHDL",
4 | "CDCMode": "hue",
5 | "CDCRange": [0, 360],
6 | "chapterNowBackCSC": [30, 60, 1],
7 | "chapterNowBorderCSC": [50, 60, 1],
8 | "chapterNowFontCSC": [100, 100, 1],
9 | "chapterNormalBackCSC": [50, 80, 0.8],
10 | "chapterNormalBorderCSC": [40, 40, 1],
11 | "chapterNormalFontCSC": [100, 30, 1],
12 | "pageListBackCSC": [20, 70, 0.3],
13 | "pageButtonBackCSC": [20, 60, 0.7],
14 | "pageButtonFontCSC": [60, 40, 1],
15 | "pageNowBackCSC": [100, 100, 1],
16 | "pageNowFontCSC": [100, 30, 1],
17 | "pageNormalBackCSC": [0, 0, 0],
18 | "pageNormalFontCSC": [80, 30, 1],
19 | "headBackCSC": [50, 90, 0.9, [10, 10], "saturation"],
20 | "bookBackCSC": [50, 80, 0.8],
21 | "bookFontCSC": [50, 50, 0.9],
22 | "bookShapeCSC": [50, 50, 0.8],
23 | "toolbarCSC": [20, 50, 0.9],
24 | "notifyDropBack": "rgba(100,100,100,0.6)",
25 | "notifyWarnBack": "",
26 | "notifyErrorBack": "",
27 | "notifyInfoBack": "rgba(216, 216, 216, 0.9)"
28 | }
--------------------------------------------------------------------------------
/src/theme/config/lolita/editor.css:
--------------------------------------------------------------------------------
1 | .ace-magic-book .ace_text-layer {
2 | }
3 |
4 | .ace-magic-book .ace_cjk {
5 | font-family: Microsoft YaHei, Arial, sans-serif ! important;
6 | font-size: 16px
7 | }
8 |
9 | .ace-magic-book .ace_constant {
10 | color: #beb79c
11 | }
12 |
13 | .ace-magic-book .ace_heading {
14 | bold: border;
15 | color: #979b7d
16 | }
17 |
18 | .ace-magic-book .ace_heading .ace_cjk {
19 | bold: border;
20 | color: #979b7d
21 | }
22 |
23 | .ace-magic-book .ace_gutter {
24 | background: #e8e8e8;
25 | color: #333
26 | }
27 |
28 | .ace-magic-book .ace_print-margin {
29 | width: 1px;
30 | background: #e8e8e8
31 | }
32 |
33 | .ace-magic-book {
34 | color: #333333;
35 | }
36 |
37 | .ace-magic-book .ace_cursor {
38 | color: #b1b593
39 | }
40 |
41 | .ace-magic-book .ace_marker-layer .ace_selection {
42 | background: #dddddd
43 | }
44 |
45 | .ace-magic-book.ace_multiselect .ace_selection.ace_start {
46 | box-shadow: 0 0 3px 0px #FFFFFF;
47 | }
48 |
49 | .ace-magic-book .ace_marker-layer .ace_step {
50 | background: rgb(198, 219, 174)
51 | }
52 |
53 | .ace-magic-book .ace_marker-layer .ace_bracket {
54 | margin: -1px 0 0 -1px;
55 | border: 1px solid #BFBFBF
56 | }
57 |
58 | .ace-magic-book .ace_marker-layer .ace_active-line {
59 | background: rgba(200, 202, 182, 0.3)
60 | }
61 |
62 | .ace-magic-book .ace_gutter-active-line {
63 | background-color: rgba(0, 0, 0, 0.071)
64 | }
65 |
66 | .ace-magic-book .ace_marker-layer .ace_selected-word {
67 | border: 1px solid #B5D5FF
68 | }
69 |
70 | .ace-magic-book .ace_constant.ace_language,
71 | .ace-magic-book .ace_keyword,
72 | .ace-magic-book .ace_meta,
73 | .ace-magic-book .ace_variable.ace_language {
74 | color: #b9b391
75 | }
76 |
77 | .ace-magic-book .ace_invisible {
78 | color: #BFBFBF
79 | }
80 |
81 | .ace-magic-book .ace_constant.ace_character,
82 | .ace-magic-book .ace_constant.ace_other {
83 | color: #275A5E
84 | }
85 |
86 | .ace-magic-book .ace_constant.ace_numeric {
87 | color: #3A00DC
88 | }
89 |
90 | .ace-magic-book .ace_entity.ace_other.ace_attribute-name,
91 | .ace-magic-book .ace_support.ace_constant,
92 | .ace-magic-book .ace_support.ace_function {
93 | color: #7394b4
94 | }
95 |
96 | .ace-magic-book .ace_fold {
97 | background-color: #c5c8a4;
98 | border-color: #000000
99 | }
100 |
101 | .ace-magic-book .ace_entity.ace_name.ace_tag,
102 | .ace-magic-book .ace_support.ace_class,
103 | .ace-magic-book .ace_support.ace_type {
104 | color: #790EAD
105 | }
106 |
107 | .ace-magic-book .ace_storage {
108 | color: #c9c6ac
109 | }
110 |
111 | .ace-magic-book .ace_string {
112 | color: #008a1e
113 | }
114 |
115 | .ace-magic-book .ace_blockquote {
116 | color: #798488
117 | }
118 |
119 | .ace-magic-book .ace_comment {
120 | color: #245d98
121 | }
122 |
123 | .ace-magic-book .ace_indent-guide {
124 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y
125 | }
--------------------------------------------------------------------------------
/src/theme/config/nature/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "font": "hack",
3 | "defaultHighlight": "VHDL",
4 | "CDCRange": [90, 190],
5 | "chapterNowBackCSC": [50, 50, 1],
6 | "chapterNowBorderCSC": [50, 50, 1],
7 | "chapterNowFontCSC": [100, 100, 1],
8 | "chapterNormalBackCSC": [40, 60, 0.6],
9 | "chapterNormalBorderCSC": [40, 40, 1],
10 | "chapterNormalFontCSC": [100, 25, 1],
11 | "pageListBackCSC": [20, 60, 0.7],
12 | "pageButtonBackCSC": [30, 40, 0.6],
13 | "pageButtonFontCSC": [100, 20, 1],
14 | "pageNowBackCSC": [100, 100, 1],
15 | "pageNowFontCSC": [100, 30, 1],
16 | "pageNormalBackCSC": [0, 0, 0],
17 | "pageNormalFontCSC": [80, 20, 1],
18 | "headBackCSC": [30, 80, 0.8],
19 | "bookBackCSC": [40, 80, 0.8],
20 | "bookFontCSC": [60, 50, 0.8],
21 | "bookShapeCSC": [50, 40, 0.8],
22 | "toolbarCSC": [50, 35, 0.7],
23 | "notifyDropBack": "rgba(100,100,100,0.6)",
24 | "notifyWarnBack": "",
25 | "notifyErrorBack": "",
26 | "notifyInfoBack": "rgba(117, 191, 160, 0.9)"
27 | }
--------------------------------------------------------------------------------
/src/theme/config/nature/editor.css:
--------------------------------------------------------------------------------
1 | .ace-magic-book .ace_text-layer {
2 | }
3 |
4 | .ace-magic-book .ace_cjk {
5 | font-family: Microsoft YaHei, Arial, sans-serif ! important;
6 | font-size: 16px
7 | }
8 |
9 | .ace-magic-book .ace_constant {
10 | color: #9ffbcc
11 | }
12 |
13 | .ace-magic-book .ace_heading {
14 | bold: border;
15 | color: #349b5d
16 | }
17 |
18 | .ace-magic-book .ace_heading .ace_cjk {
19 | bold: border;
20 | color: #349b5d
21 | }
22 |
23 | .ace-magic-book .ace_gutter {
24 | background: #e8e8e8;
25 | color: #333
26 | }
27 |
28 | .ace-magic-book .ace_print-margin {
29 | width: 1px;
30 | background: #e8e8e8
31 | }
32 |
33 | .ace-magic-book {
34 | color: #333333;
35 | }
36 |
37 | .ace-magic-book .ace_cursor {
38 | color: #38d17d
39 | }
40 |
41 | .ace-magic-book .ace_marker-layer .ace_selection {
42 | background: #c1eacd
43 | }
44 |
45 | .ace-magic-book.ace_multiselect .ace_selection.ace_start {
46 | box-shadow: 0 0 3px 0px #FFFFFF;
47 | }
48 |
49 | .ace-magic-book .ace_marker-layer .ace_step {
50 | background: rgb(198, 219, 174)
51 | }
52 |
53 | .ace-magic-book .ace_marker-layer .ace_bracket {
54 | margin: -1px 0 0 -1px;
55 | border: 1px solid #BFBFBF
56 | }
57 |
58 | .ace-magic-book .ace_marker-layer .ace_active-line {
59 | background: rgba(141, 224, 170, 0.25)
60 | }
61 |
62 | .ace-magic-book .ace_gutter-active-line {
63 | background-color: rgba(0, 0, 0, 0.071)
64 | }
65 |
66 | .ace-magic-book .ace_marker-layer .ace_selected-word {
67 | border: 1px solid #B5D5FF
68 | }
69 |
70 | .ace-magic-book .ace_constant.ace_language,
71 | .ace-magic-book .ace_keyword,
72 | .ace-magic-book .ace_meta,
73 | .ace-magic-book .ace_variable.ace_language {
74 | color: #0ac800
75 | }
76 |
77 | .ace-magic-book .ace_invisible {
78 | color: #BFBFBF
79 | }
80 |
81 | .ace-magic-book .ace_constant.ace_character,
82 | .ace-magic-book .ace_constant.ace_other {
83 | color: #275A5E
84 | }
85 |
86 | .ace-magic-book .ace_constant.ace_numeric {
87 | color: #3A00DC
88 | }
89 |
90 | .ace-magic-book .ace_entity.ace_other.ace_attribute-name,
91 | .ace-magic-book .ace_support.ace_constant,
92 | .ace-magic-book .ace_support.ace_function {
93 | color: #7394b4
94 | }
95 |
96 | .ace-magic-book .ace_fold {
97 | background-color: #0ac800;
98 | border-color: #000000
99 | }
100 |
101 | .ace-magic-book .ace_entity.ace_name.ace_tag,
102 | .ace-magic-book .ace_support.ace_class,
103 | .ace-magic-book .ace_support.ace_type {
104 | color: #790EAD
105 | }
106 |
107 | .ace-magic-book .ace_storage {
108 | color: #00c988
109 | }
110 |
111 | .ace-magic-book .ace_string {
112 | color: #008a1e
113 | }
114 |
115 | .ace-magic-book .ace_blockquote {
116 | color: #798488
117 | }
118 |
119 | .ace-magic-book .ace_comment {
120 | color: #245d98
121 | }
122 |
123 | .ace-magic-book .ace_indent-guide {
124 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y
125 | }
--------------------------------------------------------------------------------
/src/theme/config/night/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "font": "hack",
3 | "defaultHighlight": "VHDL",
4 | "CDCMode": "lightness",
5 | "CDCRange": [40, 80],
6 | "chapterNowBackCSC": [240, 0, 1, [10, 50]],
7 | "chapterNowBorderCSC": [240, 0, 1, [0, 40]],
8 | "chapterNowFontCSC": [60, 100, 1, "saturation"],
9 | "chapterNormalBackCSC": [240, 0, 0.7, [20, 60]],
10 | "chapterNormalBorderCSC": [240, 0, 1, [0, 40]],
11 | "chapterNormalFontCSC": [60, 0, 1, [60, 100]],
12 | "pageListBackCSC": [240, 5, 0.5, [0, 40]],
13 | "pageButtonBackCSC": [240, 5, 0.6, [20, 60]],
14 | "pageButtonFontCSC": [80, 100, 1, "saturation"],
15 | "pageNowBackCSC": [240, 0, 0.8, [10, 30]],
16 | "pageNowFontCSC": [200, 100, 1, "saturation"],
17 | "pageNormalBackCSC": [0, 0, 0],
18 | "pageNormalFontCSC": [240, 5, 1, [60, 100]],
19 | "headBackCSC": [240, 5, 0.6, [0, 40]],
20 | "bookBackCSC": [240, 30, 0.7],
21 | "bookFontCSC": [60, 90, 0.9, "saturation"],
22 | "bookShapeCSC": [60, 90, 0.9, "saturation"],
23 | "toolbarCSC": [60, 10, 0.8, [60, 100]],
24 | "notifyDropBack": "rgba(100,100,100,0.6)",
25 | "notifyWarnBack": "",
26 | "notifyErrorBack": "",
27 | "notifyInfoBack": "rgba(150, 150, 150, 0.9)"
28 | }
--------------------------------------------------------------------------------
/src/theme/config/night/editor.css:
--------------------------------------------------------------------------------
1 | .ace-magic-book .ace_text-layer {
2 | color: floralwhite;
3 | }
4 |
5 | .ace-magic-book .ace_cjk {
6 | font-family: Microsoft YaHei, Arial, sans-serif ! important;
7 | font-size: 16px
8 | }
9 |
10 | .ace-magic-book .ace_constant {
11 | color: #e8937c
12 | }
13 |
14 | .ace-magic-book .ace_heading {
15 | bold: border;
16 | color: #e8937c
17 | }
18 |
19 | .ace-magic-book .ace_heading .ace_cjk {
20 | bold: border;
21 | color: #e8937c
22 | }
23 |
24 | .ace-magic-book .ace_gutter {
25 | background: #e8e8e8;
26 | color: #333
27 | }
28 |
29 | .ace-magic-book .ace_print-margin {
30 | width: 1px;
31 | background: #cae2e8
32 | }
33 |
34 | .ace-magic-book {
35 | color: #333333;
36 | }
37 |
38 | .ace-magic-book .ace_cursor {
39 | color: #FFFFFF
40 | }
41 |
42 | .ace-magic-book .ace_marker-layer .ace_selection {
43 | background: #9aa1ac
44 | }
45 |
46 | .ace-magic-book.ace_multiselect .ace_selection.ace_start {
47 | box-shadow: 0 0 3px 0px #FFFFFF;
48 | }
49 |
50 | .ace-magic-book .ace_marker-layer .ace_step {
51 | background: rgb(198, 219, 174)
52 | }
53 |
54 | .ace-magic-book .ace_marker-layer .ace_bracket {
55 | margin: -1px 0 0 -1px;
56 | border: 1px solid #BFBFBF
57 | }
58 |
59 | .ace-magic-book .ace_marker-layer .ace_active-line {
60 | background: rgba(142, 147, 173, 0.25)
61 | }
62 |
63 | .ace-magic-book .ace_gutter-active-line {
64 | background-color: rgba(0, 0, 0, 0.071)
65 | }
66 |
67 | .ace-magic-book .ace_marker-layer .ace_selected-word {
68 | border: 1px solid #B5D5FF
69 | }
70 |
71 | .ace-magic-book .ace_constant.ace_language,
72 | .ace-magic-book .ace_keyword,
73 | .ace-magic-book .ace_meta,
74 | .ace-magic-book .ace_variable.ace_language {
75 | color: #56ab67
76 | }
77 |
78 | .ace-magic-book .ace_invisible {
79 | color: #BFBFBF
80 | }
81 |
82 | .ace-magic-book .ace_constant.ace_character,
83 | .ace-magic-book .ace_constant.ace_other {
84 | color: #275A5E
85 | }
86 |
87 | .ace-magic-book .ace_constant.ace_numeric {
88 | color: #3A00DC
89 | }
90 |
91 | .ace-magic-book .ace_entity.ace_other.ace_attribute-name,
92 | .ace-magic-book .ace_support.ace_constant,
93 | .ace-magic-book .ace_support.ace_function {
94 | color: #b4c5d3
95 | }
96 |
97 | .ace-magic-book .ace_fold {
98 | background-color: #7c8dc8;
99 | border-color: #ffffff
100 | }
101 |
102 | .ace-magic-book .ace_entity.ace_name.ace_tag,
103 | .ace-magic-book .ace_support.ace_class,
104 | .ace-magic-book .ace_support.ace_type {
105 | color: #790EAD
106 | }
107 |
108 | .ace-magic-book .ace_storage {
109 | color: #C900A4
110 | }
111 |
112 | .ace-magic-book .ace_string {
113 | color: #7cb8b1
114 | }
115 |
116 | .ace-magic-book .ace_blockquote {
117 | color: #c6ccd0
118 | }
119 |
120 | .ace-magic-book .ace_comment {
121 | color: #4c7b98
122 | }
123 |
124 | .ace-magic-book .ace_indent-guide {
125 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y
126 | }
--------------------------------------------------------------------------------
/src/theme/config/sakura/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "font": "hack",
3 | "defaultHighlight": "VHDL",
4 | "CDCRange": [260, 380],
5 | "chapterNowBackCSC": [50, 60, 1],
6 | "chapterNowBorderCSC": [50, 60, 1],
7 | "chapterNowFontCSC": [100, 100, 1],
8 | "chapterNormalBackCSC": [40, 70, 0.6],
9 | "chapterNormalBorderCSC": [40, 50, 1],
10 | "chapterNormalFontCSC": [100, 25, 1],
11 | "pageListBackCSC": [20, 50, 0.6],
12 | "pageButtonBackCSC": [30, 50, 0.6],
13 | "pageButtonFontCSC": [100, 20, 1],
14 | "pageNowBackCSC": [100, 100, 1],
15 | "pageNowFontCSC": [100, 30, 1],
16 | "pageNormalBackCSC": [0, 0, 0],
17 | "pageNormalFontCSC": [100, 30, 1],
18 | "headBackCSC": [50, 80, 0.6],
19 | "bookBackCSC": [50, 80, 0.8],
20 | "bookFontCSC": [80, 50, 0.8],
21 | "bookShapeCSC": [50, 50, 0.8],
22 | "toolbarCSC": [60, 50, 0.7],
23 | "notifyDropBack": "rgba(100,100,100,0.6)",
24 | "notifyWarnBack": "",
25 | "notifyErrorBack": "",
26 | "notifyInfoBack": "rgba(239, 194, 212, 0.9)"
27 | }
--------------------------------------------------------------------------------
/src/theme/config/sakura/editor.css:
--------------------------------------------------------------------------------
1 | .ace-magic-book .ace_text-layer {
2 | }
3 |
4 | .ace-magic-book .ace_cjk {
5 | font-family: Microsoft YaHei, Arial, sans-serif ! important;
6 | font-size: 16px
7 | }
8 |
9 | .ace-magic-book .ace_constant {
10 | color: #FB83A4
11 | }
12 |
13 | .ace-magic-book .ace_heading {
14 | bold: border;
15 | color: #E85B82
16 | }
17 |
18 | .ace-magic-book .ace_heading .ace_cjk {
19 | bold: border;
20 | color: #E85B82
21 | }
22 |
23 | .ace-magic-book .ace_gutter {
24 | background: #e8e8e8;
25 | color: #333
26 | }
27 |
28 | .ace-magic-book .ace_print-margin {
29 | width: 1px;
30 | background: #e8e8e8
31 | }
32 |
33 | .ace-magic-book {
34 | color: #333333;
35 | }
36 |
37 | .ace-magic-book .ace_cursor {
38 | color: #C35774
39 | }
40 |
41 | .ace-magic-book .ace_marker-layer .ace_selection {
42 | background: #EAC9D2
43 | }
44 |
45 | .ace-magic-book.ace_multiselect .ace_selection.ace_start {
46 | box-shadow: 0 0 3px 0px #FFFFFF;
47 | }
48 |
49 | .ace-magic-book .ace_marker-layer .ace_step {
50 | background: rgb(198, 219, 174)
51 | }
52 |
53 | .ace-magic-book .ace_marker-layer .ace_bracket {
54 | margin: -1px 0 0 -1px;
55 | border: 1px solid #BFBFBF
56 | }
57 |
58 | .ace-magic-book .ace_marker-layer .ace_active-line {
59 | background: rgba(224, 141, 170, 0.15)
60 | }
61 |
62 | .ace-magic-book .ace_gutter-active-line {
63 | background-color: rgba(0, 0, 0, 0.071)
64 | }
65 |
66 | .ace-magic-book .ace_marker-layer .ace_selected-word {
67 | border: 1px solid #B5D5FF
68 | }
69 |
70 | .ace-magic-book .ace_constant.ace_language,
71 | .ace-magic-book .ace_keyword,
72 | .ace-magic-book .ace_meta,
73 | .ace-magic-book .ace_variable.ace_language {
74 | color: #C800A4
75 | }
76 |
77 | .ace-magic-book .ace_invisible {
78 | color: #BFBFBF
79 | }
80 |
81 | .ace-magic-book .ace_constant.ace_character,
82 | .ace-magic-book .ace_constant.ace_other {
83 | color: #275A5E
84 | }
85 |
86 | .ace-magic-book .ace_constant.ace_numeric {
87 | color: #3A00DC
88 | }
89 |
90 | .ace-magic-book .ace_entity.ace_other.ace_attribute-name,
91 | .ace-magic-book .ace_support.ace_constant,
92 | .ace-magic-book .ace_support.ace_function {
93 | color: #7394b4
94 | }
95 |
96 | .ace-magic-book .ace_fold {
97 | background-color: #C800A4;
98 | border-color: #000000
99 | }
100 |
101 | .ace-magic-book .ace_entity.ace_name.ace_tag,
102 | .ace-magic-book .ace_support.ace_class,
103 | .ace-magic-book .ace_support.ace_type {
104 | color: #790EAD
105 | }
106 |
107 | .ace-magic-book .ace_storage {
108 | color: #C900A4
109 | }
110 |
111 | .ace-magic-book .ace_string {
112 | color: #008a1e
113 | }
114 |
115 | .ace-magic-book .ace_blockquote {
116 | color: #798488
117 | }
118 |
119 | .ace-magic-book .ace_comment {
120 | color: #245d98
121 | }
122 |
123 | .ace-magic-book .ace_indent-guide {
124 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y
125 | }
--------------------------------------------------------------------------------
/src/theme/config/snow/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "font": "hack",
3 | "defaultHighlight": "VHDL",
4 | "CDCRange": [190, 270],
5 | "chapterNowBackCSC": [50, 60, 1],
6 | "chapterNowBorderCSC": [50, 60, 1],
7 | "chapterNowFontCSC": [100, 100, 1],
8 | "chapterNormalBackCSC": [40, 70, 0.6],
9 | "chapterNormalBorderCSC": [40, 50, 1],
10 | "chapterNormalFontCSC": [100, 25, 1],
11 | "pageListBackCSC": [20, 40, 0.5],
12 | "pageButtonBackCSC": [30, 50, 0.6],
13 | "pageButtonFontCSC": [100, 20, 1],
14 | "pageNowBackCSC": [100, 100, 1],
15 | "pageNowFontCSC": [100, 30, 1],
16 | "pageNormalBackCSC": [0, 0, 0],
17 | "pageNormalFontCSC": [100, 30, 1],
18 | "headBackCSC": [50, 80, 0.6],
19 | "bookBackCSC": [50, 80, 0.8],
20 | "bookFontCSC": [80, 50, 0.8],
21 | "bookShapeCSC": [50, 50, 0.8],
22 | "toolbarCSC": [60, 50, 0.7],
23 | "notifyDropBack": "rgba(100,100,100,0.6)",
24 | "notifyWarnBack": "",
25 | "notifyErrorBack": "",
26 | "notifyInfoBack": "rgba(175, 192, 239, 0.9)"
27 | }
--------------------------------------------------------------------------------
/src/theme/config/snow/editor.css:
--------------------------------------------------------------------------------
1 | .ace-magic-book .ace_text-layer {
2 | }
3 |
4 | .ace-magic-book .ace_cjk {
5 | font-family: Microsoft YaHei, Arial, sans-serif ! important;
6 | font-size: 16px
7 | }
8 |
9 | .ace-magic-book .ace_constant {
10 | color: #829ffb
11 | }
12 |
13 | .ace-magic-book .ace_heading {
14 | bold: border;
15 | color: #6e8ae8
16 | }
17 |
18 | .ace-magic-book .ace_heading .ace_cjk {
19 | bold: border;
20 | color: #6e8ae8
21 | }
22 |
23 | .ace-magic-book .ace_gutter {
24 | background: #e8e8e8;
25 | color: #333
26 | }
27 |
28 | .ace-magic-book .ace_print-margin {
29 | width: 1px;
30 | background: #e8e8e8
31 | }
32 |
33 | .ace-magic-book {
34 | color: #333333;
35 | }
36 |
37 | .ace-magic-book .ace_cursor {
38 | color: #4379c3
39 | }
40 |
41 | .ace-magic-book .ace_marker-layer .ace_selection {
42 | background: #abc2ea
43 | }
44 |
45 | .ace-magic-book.ace_multiselect .ace_selection.ace_start {
46 | box-shadow: 0 0 3px 0px #FFFFFF;
47 | }
48 |
49 | .ace-magic-book .ace_marker-layer .ace_step {
50 | background: rgb(198, 219, 174)
51 | }
52 |
53 | .ace-magic-book .ace_marker-layer .ace_bracket {
54 | margin: -1px 0 0 -1px;
55 | border: 1px solid #BFBFBF
56 | }
57 |
58 | .ace-magic-book .ace_marker-layer .ace_active-line {
59 | background: rgba(96, 135, 224, 0.15)
60 | }
61 |
62 | .ace-magic-book .ace_gutter-active-line {
63 | background-color: rgba(0, 0, 0, 0.071)
64 | }
65 |
66 | .ace-magic-book .ace_marker-layer .ace_selected-word {
67 | border: 1px solid #B5D5FF
68 | }
69 |
70 | .ace-magic-book .ace_constant.ace_language,
71 | .ace-magic-book .ace_keyword,
72 | .ace-magic-book .ace_meta,
73 | .ace-magic-book .ace_variable.ace_language {
74 | color: #0055c8
75 | }
76 |
77 | .ace-magic-book .ace_invisible {
78 | color: #BFBFBF
79 | }
80 |
81 | .ace-magic-book .ace_constant.ace_character,
82 | .ace-magic-book .ace_constant.ace_other {
83 | color: #275A5E
84 | }
85 |
86 | .ace-magic-book .ace_constant.ace_numeric {
87 | color: #00dc87
88 | }
89 |
90 | .ace-magic-book .ace_entity.ace_other.ace_attribute-name,
91 | .ace-magic-book .ace_support.ace_constant,
92 | .ace-magic-book .ace_support.ace_function {
93 | color: #7394b4
94 | }
95 |
96 | .ace-magic-book .ace_fold {
97 | background-color: #003ac8;
98 | border-color: #000000
99 | }
100 |
101 | .ace-magic-book .ace_entity.ace_name.ace_tag,
102 | .ace-magic-book .ace_support.ace_class,
103 | .ace-magic-book .ace_support.ace_type {
104 | color: #790EAD
105 | }
106 |
107 | .ace-magic-book .ace_storage {
108 | color: #2000c9
109 | }
110 |
111 | .ace-magic-book .ace_string {
112 | color: #008a1e
113 | }
114 |
115 | .ace-magic-book .ace_blockquote {
116 | color: #798488
117 | }
118 |
119 | .ace-magic-book .ace_comment {
120 | color: #245d98
121 | }
122 |
123 | .ace-magic-book .ace_indent-guide {
124 | background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y
125 | }
--------------------------------------------------------------------------------
/src/theme/export/dark.css:
--------------------------------------------------------------------------------
1 | body{
2 | color: white;
3 | font-size: 16px;
4 | font-family: Helvetica, arial, sans-serif;
5 | background-color: #282a36;
6 | }
7 |
8 | @media screen and (min-width: 914px) {
9 | body {
10 | width: 854px;
11 | margin:10px auto;
12 | }
13 | }
14 |
15 | @media screen and (max-width: 914px) {
16 | .content{
17 | padding-left: 10%;
18 | width: 80%;
19 | }
20 | }
21 |
22 | .content {
23 | padding-top: 20px;
24 | }
25 |
26 | h1,h2,h3,h4,h5,h6,p,a{
27 | word-break: break-word;
28 | }
29 |
30 | h1 {
31 | padding-bottom: 0.3em;
32 | border-bottom: 1px solid #444;
33 | }
34 |
35 | h2 {
36 | padding-bottom: 0.3em;
37 | border-bottom: 1px solid #444;
38 | }
39 |
40 | blockquote{
41 | background-color: rgba(178, 180, 183, 0.6);
42 | }
43 |
44 | pre{
45 | background-color: rgba(127, 127, 127, 0.6);
46 | }
47 |
48 | code{
49 | background-color: rgba(141, 142, 146, 0.8);
50 | }
51 |
52 | h1{
53 | font-size: 1.8em;
54 | margin-top: 1em;
55 | margin-bottom: 1em;
56 | }
57 |
58 | h2{
59 | font-size: 1.6em;
60 | margin-top: 1em;
61 | margin-bottom: 1em;
62 | }
63 |
64 | h3{
65 | font-size: 1.4em;
66 | margin-top: 1em;
67 | margin-bottom: 1em;
68 | }
69 |
70 | h4{
71 | font-size: 1.3em;
72 | margin-top: 1em;
73 | margin-bottom: 1em;
74 | }
75 |
76 | h5,h6{
77 | font-size: 1.2em;
78 | margin-top: 1em;
79 | margin-bottom: 1em;
80 | }
81 |
82 | p,a{
83 | font-size: 1em;
84 | line-height: 1.5em;
85 | }
86 |
87 | p{
88 | margin-bottom: 1em;
89 | margin-top: 1em;
90 | text-align: left;
91 | display: block;
92 | }
93 |
94 | a{
95 | text-decoration: none;
96 | font-weight: bolder;
97 | color: #444444;
98 | }
99 |
100 | a{
101 | word-break: break-all;
102 | color: #c0c0c0;
103 | }
104 |
105 | a {
106 | background-color: transparent;
107 | -webkit-text-decoration-skip: objects;
108 | }
109 |
110 | a:active,
111 | a:hover {
112 | outline-width: 0;
113 | color: white;
114 | }
115 |
116 |
117 | blockquote{
118 | width: 90%;
119 | padding-left: 5%;
120 | padding-right: 5%;
121 | padding-top: 10px;
122 | padding-bottom: 10px;
123 | margin-left: 0;
124 | margin-right: 0;
125 | }
126 |
127 | pre{
128 | width: 90%;
129 | padding-left: 5%;
130 | padding-right: 5%;
131 | padding-top: 10px;
132 | padding-bottom: 10px;
133 | overflow: auto;
134 | }
135 |
136 | pre code{
137 | background-color: rgba(0,0,0,0);
138 | }
139 |
140 | pre::-webkit-scrollbar{
141 | display: none;
142 | }
143 |
144 | .highlight{
145 | margin-top: 4px;
146 | margin-bottom: 4px;
147 | padding-top: 5px;
148 | padding-bottom: 5px;
149 | padding-left: 12px;
150 | }
151 |
152 | img {
153 | max-width: 100%;
154 | max-height: 100%;
155 | }
156 |
157 | center {
158 | margin-top: 1em;
159 | margin-bottom: 1em;
160 | }
161 |
162 | table{
163 | border-top-width: 1px;
164 | border-right-width: 1px;
165 | border-bottom-width: 1px;
166 | border-left-width: 1px;
167 | border-spacing: 0;
168 | padding: 0;
169 | margin: 10px;
170 | }
171 |
172 | tr{
173 | text-align: center;
174 | }
175 |
176 | th{
177 | padding: 10px;
178 | }
179 |
180 | td{
181 | padding: 10px;
182 | }
183 |
184 | table, th, td {
185 | border: 1px solid;
186 | border-color: rgba(255, 255, 255, 0.8);
187 | }
188 |
189 | th{
190 | background-color: rgba(101, 101, 101, 0.8);
191 | }
192 |
193 | code{
194 | padding: 2px;
195 | }
196 |
197 | /*Hightlight style*/
198 | .hljs {
199 | display: block;
200 | overflow-x: auto;
201 | padding: 0.5em;
202 | background: #272822; color: #ddd;
203 | }
204 |
205 | .hljs-tag,
206 | .hljs-keyword,
207 | .hljs-selector-tag,
208 | .hljs-literal,
209 | .hljs-strong,
210 | .hljs-name {
211 | color: #f92672;
212 | }
213 |
214 | .hljs-code {
215 | color: #66d9ef;
216 | }
217 |
218 | .hljs-class .hljs-title {
219 | color: white;
220 | }
221 |
222 | .hljs-attribute,
223 | .hljs-symbol,
224 | .hljs-regexp,
225 | .hljs-link {
226 | color: #bf79db;
227 | }
228 |
229 | .hljs-string,
230 | .hljs-bullet,
231 | .hljs-subst,
232 | .hljs-title,
233 | .hljs-section,
234 | .hljs-emphasis,
235 | .hljs-type,
236 | .hljs-built_in,
237 | .hljs-builtin-name,
238 | .hljs-selector-attr,
239 | .hljs-selector-pseudo,
240 | .hljs-addition,
241 | .hljs-variable,
242 | .hljs-template-tag,
243 | .hljs-template-variable {
244 | color: #a6e22e;
245 | }
246 |
247 | .hljs-comment,
248 | .hljs-quote,
249 | .hljs-deletion,
250 | .hljs-meta {
251 | color: #a4a4a2;
252 | }
253 |
254 | .hljs-keyword,
255 | .hljs-selector-tag,
256 | .hljs-literal,
257 | .hljs-doctag,
258 | .hljs-title,
259 | .hljs-section,
260 | .hljs-type,
261 | .hljs-selector-id {
262 | }
263 |
264 | .hljs-number{
265 | color: #af9dff;
266 | }
--------------------------------------------------------------------------------
/src/theme/export/light.css:
--------------------------------------------------------------------------------
1 | body{
2 | font-size: 16px;
3 | font-family: Helvetica, arial, sans-serif;
4 | background-color: white;
5 | }
6 |
7 | @media screen and (min-width: 914px) {
8 | body {
9 | width: 854px;
10 | margin:10px auto;
11 | }
12 | }
13 |
14 | h1,h2,h3,h4,h5,h6,p,a{
15 | word-break: break-word;
16 | }
17 |
18 | h1 {
19 | padding-bottom: 0.3em;
20 | border-bottom: 1px solid #eee;
21 | }
22 |
23 | h2 {
24 | padding-bottom: 0.3em;
25 | border-bottom: 1px solid #eee;
26 | }
27 |
28 | blockquote{
29 | background-color: whitesmoke;
30 | }
31 |
32 | pre{
33 | background-color: whitesmoke;
34 | }
35 |
36 | code{
37 | background-color: rgba(255, 255, 255, 0.7);
38 | }
39 |
40 | h1{
41 | font-size: 1.8em;
42 | margin-top: 1em;
43 | margin-bottom: 1em;
44 | }
45 |
46 | h2{
47 | font-size: 1.6em;
48 | margin-top: 1em;
49 | margin-bottom: 1em;
50 | }
51 |
52 | h3{
53 | font-size: 1.4em;
54 | margin-top: 1em;
55 | margin-bottom: 1em;
56 | }
57 |
58 | h4{
59 | font-size: 1.3em;
60 | margin-top: 1em;
61 | margin-bottom: 1em;
62 | }
63 |
64 | h5,h6{
65 | font-size: 1.2em;
66 | margin-top: 1em;
67 | margin-bottom: 1em;
68 | }
69 |
70 | p,a{
71 | font-size: 1em;
72 | line-height: 1.5em;
73 | }
74 |
75 | p{
76 | margin-bottom: 1em;
77 | margin-top: 1em;
78 | text-align: left;
79 | display: block;
80 | }
81 |
82 | a{
83 | text-decoration: none;
84 | font-weight: bolder;
85 | color: #444444;
86 | }
87 |
88 | a{
89 | word-break: break-all;
90 | color: #444444;
91 | }
92 |
93 | a {
94 | background-color: transparent;
95 | -webkit-text-decoration-skip: objects;
96 | }
97 |
98 | a:active,
99 | a:hover {
100 | outline-width: 0;
101 | color: black;
102 | }
103 |
104 |
105 | blockquote{
106 | width: 90%;
107 | padding-left: 5%;
108 | padding-right: 5%;
109 | padding-top: 10px;
110 | padding-bottom: 10px;
111 | margin-left: 0;
112 | margin-right: 0;
113 | }
114 |
115 | pre{
116 | width: 90%;
117 | padding-left: 5%;
118 | padding-right: 5%;
119 | padding-top: 10px;
120 | padding-bottom: 10px;
121 | overflow: auto;
122 | }
123 |
124 | pre code{
125 | background-color: rgba(0,0,0,0);
126 | }
127 |
128 | pre::-webkit-scrollbar{
129 | display: none;
130 | }
131 |
132 | .highlight{
133 | margin-top: 4px;
134 | margin-bottom: 4px;
135 | padding-top: 5px;
136 | padding-bottom: 5px;
137 | padding-left: 12px;
138 | }
139 |
140 | img {
141 | max-width: 100%;
142 | max-height: 100%;
143 | }
144 |
145 | center {
146 | margin-top: 1em;
147 | margin-bottom: 1em;
148 | }
149 |
150 | table{
151 | border-top-width: 1px;
152 | border-right-width: 1px;
153 | border-bottom-width: 1px;
154 | border-left-width: 1px;
155 | border-spacing: 0;
156 | padding: 0;
157 | margin: 10px;
158 | }
159 |
160 | tr{
161 | text-align: center;
162 | }
163 |
164 | th{
165 | padding: 10px;
166 | }
167 |
168 | td{
169 | padding: 10px;
170 | }
171 |
172 | table, th, td {
173 | border: 1px solid;
174 | border-color: rgba(20, 20, 20,0.8);
175 | }
176 |
177 | th{
178 | background-color: rgba(160, 160, 160, 0.8);
179 | }
180 |
181 | code{
182 | padding: 2px;
183 | }
184 |
185 | /*Hightlight style*/
186 | .hljs {
187 | display: block;
188 | overflow-x: auto;
189 | padding: 0.5em;
190 | background: #272822; color: #ddd;
191 | }
192 |
193 | .hljs-tag,
194 | .hljs-keyword,
195 | .hljs-selector-tag,
196 | .hljs-literal,
197 | .hljs-strong,
198 | .hljs-name {
199 | color: #f92672;
200 | }
201 |
202 | .hljs-code {
203 | color: #66d9ef;
204 | }
205 |
206 | .hljs-class .hljs-title {
207 | color: white;
208 | }
209 |
210 | .hljs-attribute,
211 | .hljs-symbol,
212 | .hljs-regexp,
213 | .hljs-link {
214 | color: #bf79db;
215 | }
216 |
217 | .hljs-string,
218 | .hljs-bullet,
219 | .hljs-subst,
220 | .hljs-title,
221 | .hljs-section,
222 | .hljs-emphasis,
223 | .hljs-type,
224 | .hljs-built_in,
225 | .hljs-builtin-name,
226 | .hljs-selector-attr,
227 | .hljs-selector-pseudo,
228 | .hljs-addition,
229 | .hljs-variable,
230 | .hljs-template-tag,
231 | .hljs-template-variable {
232 | color: #61ab4a;
233 | }
234 |
235 | .hljs-comment,
236 | .hljs-quote,
237 | .hljs-deletion,
238 | .hljs-meta {
239 | color: #75715e;
240 | }
241 |
242 | .hljs-keyword,
243 | .hljs-selector-tag,
244 | .hljs-literal,
245 | .hljs-doctag,
246 | .hljs-title,
247 | .hljs-section,
248 | .hljs-type,
249 | .hljs-selector-id {
250 | }
251 |
252 | .hljs-number{
253 | color: #6064da;
254 | }
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/hack-bold-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/hack-bold-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/hack-bolditalic-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/hack-bolditalic-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/hack-italic-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/hack-italic-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/hack-regular-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/hack-regular-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/latin/hack-bold-latin-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/latin/hack-bold-latin-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/latin/hack-bolditalic-latin-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/latin/hack-bolditalic-latin-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/latin/hack-italic-latin-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/latin/hack-italic-latin-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/eot/latin/hack-regular-latin-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/eot/latin/hack-regular-latin-webfont.eot
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/hack-bold-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/hack-bold-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/hack-bolditalic-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/hack-bolditalic-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/hack-italic-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/hack-italic-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/hack-regular-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/hack-regular-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/latin/hack-bold-latin-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/latin/hack-bold-latin-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/latin/hack-bolditalic-latin-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/latin/hack-bolditalic-latin-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/latin/hack-italic-latin-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/latin/hack-italic-latin-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/web-ttf/latin/hack-regular-latin-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/web-ttf/latin/hack-regular-latin-webfont.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/hack-bold-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/hack-bold-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/hack-bolditalic-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/hack-bolditalic-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/hack-italic-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/hack-italic-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/hack-regular-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/hack-regular-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/latin/hack-bold-latin-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/latin/hack-bold-latin-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/latin/hack-bolditalic-latin-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/latin/hack-bolditalic-latin-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/latin/hack-italic-latin-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/latin/hack-italic-latin-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff/latin/hack-regular-latin-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff/latin/hack-regular-latin-webfont.woff
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/hack-bold-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/hack-bold-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/hack-bolditalic-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/hack-bolditalic-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/hack-italic-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/hack-italic-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/hack-regular-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/hack-regular-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/latin/hack-bold-latin-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/latin/hack-bold-latin-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/latin/hack-bolditalic-latin-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/latin/hack-bolditalic-latin-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/latin/hack-italic-latin-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/latin/hack-italic-latin-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/hack/woff2/latin/hack-regular-latin-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/hack/woff2/latin/hack-regular-latin-webfont.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/icomoon.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/icomoon.eot
--------------------------------------------------------------------------------
/src/theme/fonts/icomoon.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/icomoon.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/icomoon.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/icomoon.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_AMS-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_AMS-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_AMS-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_AMS-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_AMS-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_AMS-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_AMS-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_AMS-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Bold.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Caligraphic-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Bold.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Bold.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Bold.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Bold.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Fraktur-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Fraktur-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Bold.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Bold.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Bold.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Bold.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Italic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Italic.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Italic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Italic.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Italic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Italic.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Italic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Italic.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Main-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Main-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-BoldItalic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-BoldItalic.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-BoldItalic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-BoldItalic.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-BoldItalic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-BoldItalic.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-BoldItalic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-BoldItalic.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Italic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Italic.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Italic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Italic.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Italic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Italic.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Italic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Italic.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Math-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Math-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Bold.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Bold.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Bold.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Bold.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Italic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Italic.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Italic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Italic.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Italic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Italic.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Italic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Italic.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_SansSerif-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_SansSerif-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Script-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Script-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Script-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Script-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Script-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Script-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Script-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Script-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size1-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size1-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size1-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size1-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size1-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size1-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size1-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size1-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size2-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size2-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size2-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size2-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size2-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size2-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size2-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size2-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size3-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size3-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size3-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size3-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size3-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size3-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size3-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size3-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size4-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size4-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size4-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size4-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size4-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size4-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Size4-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Size4-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Typewriter-Regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Typewriter-Regular.eot
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Typewriter-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Typewriter-Regular.ttf
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Typewriter-Regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Typewriter-Regular.woff
--------------------------------------------------------------------------------
/src/theme/fonts/katex/KaTeX_Typewriter-Regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/fonts/katex/KaTeX_Typewriter-Regular.woff2
--------------------------------------------------------------------------------
/src/theme/images/about.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/about.png
--------------------------------------------------------------------------------
/src/theme/images/book-button-edit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/book-button-edit.png
--------------------------------------------------------------------------------
/src/theme/images/book-button-remove.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/book-button-remove.png
--------------------------------------------------------------------------------
/src/theme/images/chapter-list-button.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/chapter-list-button.png
--------------------------------------------------------------------------------
/src/theme/images/export.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/export.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/body.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/body.jpg
--------------------------------------------------------------------------------
/src/theme/images/lolita/book-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/book-list.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/book-pre.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/book-pre.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/error-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/error-head.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/export-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/export-head.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/info-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/info-background.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/menu-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/menu-background.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/sys-info-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/sys-info-head.png
--------------------------------------------------------------------------------
/src/theme/images/lolita/warn-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/lolita/warn-head.png
--------------------------------------------------------------------------------
/src/theme/images/nature/body.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/body.png
--------------------------------------------------------------------------------
/src/theme/images/nature/book-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/book-list.png
--------------------------------------------------------------------------------
/src/theme/images/nature/book-pre.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/book-pre.png
--------------------------------------------------------------------------------
/src/theme/images/nature/error-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/error-head.png
--------------------------------------------------------------------------------
/src/theme/images/nature/export-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/export-head.png
--------------------------------------------------------------------------------
/src/theme/images/nature/info-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/info-background.png
--------------------------------------------------------------------------------
/src/theme/images/nature/menu-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/menu-background.png
--------------------------------------------------------------------------------
/src/theme/images/nature/sys-info-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/sys-info-head.png
--------------------------------------------------------------------------------
/src/theme/images/nature/warn-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/nature/warn-head.png
--------------------------------------------------------------------------------
/src/theme/images/night/body.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/body.png
--------------------------------------------------------------------------------
/src/theme/images/night/book-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/book-list.png
--------------------------------------------------------------------------------
/src/theme/images/night/book-pre.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/book-pre.png
--------------------------------------------------------------------------------
/src/theme/images/night/error-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/error-head.png
--------------------------------------------------------------------------------
/src/theme/images/night/export-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/export-head.png
--------------------------------------------------------------------------------
/src/theme/images/night/info-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/info-background.png
--------------------------------------------------------------------------------
/src/theme/images/night/menu-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/menu-background.png
--------------------------------------------------------------------------------
/src/theme/images/night/sys-info-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/sys-info-head.png
--------------------------------------------------------------------------------
/src/theme/images/night/warn-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/night/warn-head.png
--------------------------------------------------------------------------------
/src/theme/images/page-list-button.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/page-list-button.png
--------------------------------------------------------------------------------
/src/theme/images/reload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/reload.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/body.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/body.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/book-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/book-list.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/book-pre.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/book-pre.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/error-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/error-head.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/export-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/export-head.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/info-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/info-background.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/menu-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/menu-background.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/sys-info-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/sys-info-head.png
--------------------------------------------------------------------------------
/src/theme/images/sakura/warn-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/sakura/warn-head.png
--------------------------------------------------------------------------------
/src/theme/images/snow/body.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/body.png
--------------------------------------------------------------------------------
/src/theme/images/snow/book-list.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/book-list.png
--------------------------------------------------------------------------------
/src/theme/images/snow/book-pre.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/book-pre.png
--------------------------------------------------------------------------------
/src/theme/images/snow/error-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/error-head.png
--------------------------------------------------------------------------------
/src/theme/images/snow/export-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/export-head.png
--------------------------------------------------------------------------------
/src/theme/images/snow/info-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/info-background.png
--------------------------------------------------------------------------------
/src/theme/images/snow/menu-background.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/menu-background.png
--------------------------------------------------------------------------------
/src/theme/images/snow/sys-info-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/sys-info-head.png
--------------------------------------------------------------------------------
/src/theme/images/snow/warn-head.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dtysky/MoeNotes/507cf09420841bca1c6db6d5b611657d8ef34954/src/theme/images/snow/warn-head.png
--------------------------------------------------------------------------------
/src/theme/styles/article.css:
--------------------------------------------------------------------------------
1 | h1,h2,h3,h4,h5,h6,p,a{
2 | word-break: break-word;
3 | }
4 |
5 | @font-face {
6 | font-family: 'icomoon';
7 | src: url('../fonts/icomoon.eot?c8cymx');
8 | src: url('../fonts/icomoon.eot?c8cymx#iefix') format('embedded-opentype'),
9 | url('../fonts/icomoon.ttf?c8cymx') format('truetype'),
10 | url('../fonts/icomoon.woff?c8cymx') format('woff'),
11 | url('../fonts/icomoon.svg?c8cymx#icomoon') format('svg');
12 | font-weight: normal;
13 | font-style: normal;
14 | }
15 |
16 | .page-preview a:after{
17 | /* use !important to prevent issues with browser extensions that change fonts */
18 | font-family: 'icomoon' !important;
19 | font-style: normal;
20 | font-weight: normal;
21 | font-variant: normal;
22 | text-transform: none;
23 | line-height: 1;
24 |
25 | /* Better Font Rendering =========== */
26 | -webkit-font-smoothing: antialiased;
27 | -moz-osx-font-smoothing: grayscale;
28 | }
29 |
30 | .page-preview{
31 | margin-bottom: 22px;
32 | font-size: 16px;
33 | }
34 |
35 | .page-preview h1{
36 | font-size: 1.5em;
37 | margin-top: 1em;
38 | margin-bottom: 1em;
39 | }
40 |
41 | .page-preview h2{
42 | font-size: 1.4em;
43 | margin-top: 1em;
44 | margin-bottom: 1em;
45 | }
46 |
47 | .page-preview h3{
48 | font-size: 1.3em;
49 | margin-top: 1em;
50 | margin-bottom: 1em;
51 | }
52 |
53 | .page-preview h4,h5,h6{
54 | font-size: 1.2em;
55 | margin-top: 1em;
56 | margin-bottom: 1em;
57 | }
58 |
59 | .page-preview p,.page-preview a{
60 | font-size: 1em;
61 | line-height: 1.5em;
62 | }
63 |
64 | .page-preview p{
65 | margin-bottom: 1em;
66 | margin-top: 1em;
67 | text-align: left;
68 | display: block;
69 | }
70 |
71 | .page-preview a{
72 | text-decoration: none;
73 | font-weight: bolder;
74 | color: #444444;
75 | }
76 |
77 | .page-preview a:hover{
78 | color: black;
79 | }
80 |
81 | .page-preview a:after{
82 | margin-left: 2px;
83 | content: "\e906";
84 | }
85 |
86 | .page-preview blockquote{
87 | width: 90%;
88 | padding-left: 5%;
89 | padding-right: 5%;
90 | padding-top: 10px;
91 | padding-bottom: 10px;
92 | margin-left: 0;
93 | margin-right: 0;
94 | }
95 |
96 | .page-preview pre{
97 | width: 90%;
98 | padding-left: 5%;
99 | padding-right: 5%;
100 | padding-top: 10px;
101 | padding-bottom: 10px;
102 | overflow: auto;
103 | }
104 |
105 | .page-preview pre code{
106 | font-family: "Hack" ! important;
107 | background-color: rgba(0,0,0,0);
108 | }
109 |
110 | .page-preview pre::-webkit-scrollbar{
111 | display: none;
112 | }
113 |
114 | .highlight{
115 | margin-top: 4px;
116 | margin-bottom: 4px;
117 | padding-top: 5px;
118 | padding-bottom: 5px;
119 | padding-left: 12px;
120 | }
121 |
122 | .page-preview img {
123 | max-width: 100%;
124 | max-height: 100%;
125 | }
126 |
127 | .page-preview center {
128 | margin-top: 1em;
129 | margin-bottom: 1em;
130 | }
131 |
132 | .page-preview table{
133 | border-top-width: 1px;
134 | border-right-width: 1px;
135 | border-bottom-width: 1px;
136 | border-left-width: 1px;
137 | border-spacing: 0;
138 | padding: 0;
139 | margin: 10px;
140 | }
141 |
142 | .page-preview tr{
143 | text-align: center;
144 | }
145 |
146 | .page-preview th{
147 | padding: 10px;
148 | }
149 |
150 | .page-preview td{
151 | padding: 10px;
152 | }
153 |
154 | .page-preview table, th, td {
155 | border: 1px solid;
156 | border-color: rgba(20, 20, 20,0.8);
157 | }
158 |
159 | .page-preview th{
160 | background-color: rgba(160, 160, 160, 0.8);
161 | }
162 |
163 | .page-preview code{
164 | padding: 2px;
165 | }
--------------------------------------------------------------------------------
/src/theme/styles/books.css:
--------------------------------------------------------------------------------
1 | .bm-cross-button {
2 | height: 24px;
3 | width: 24px;
4 | }
5 |
6 | .bm-cross {
7 | background: #bdc3c7;
8 | }
9 |
10 | .bm-menu-wrap{
11 | background-size: 100% 100%;
12 | background-position: bottom;
13 | }
14 |
15 | .bm-menu {
16 | padding-top: 80px;
17 | }
18 |
19 | .bm-morph-shape {
20 | fill: #373a47;
21 | }
22 |
23 | .bm-item-list {
24 |
25 | }
26 |
27 | .bm-overlay {
28 | }
29 |
30 | .book{
31 | width: 270px;
32 | margin-left: 15px;
33 | margin-bottom: 10px;
34 | height: 64px;
35 | border-bottom-right-radius: 20px 40px;
36 | border-top-right-radius: 20px 40px;
37 | }
38 |
39 | .book-pre{
40 | margin-left: 4px;
41 | margin-right: 12px;
42 | width: 48px;
43 | height: 100%;
44 | -webkit-mask-repeat: no-repeat;
45 | -webkit-mask-size: 100% auto;
46 | -webkit-mask-position: center;
47 | }
48 |
49 | .book-pre:hover{
50 | animation: rotate-full 3s linear 0s infinite normal;
51 | }
52 |
53 | .book-text{
54 | width: 150px;
55 | background-size: auto 100%;
56 | background-position: left;
57 | }
58 |
59 | .book-text input{
60 | vertical-align: top;
61 | padding: 0;
62 | margin: 0;
63 | width: 100%;
64 | font-size: 24px;
65 | }
66 |
67 | .book-buttons{
68 | margin-left: 4px;
69 | margin-top: 8px;
70 | width: 36px;
71 | height: 14px;
72 | }
73 |
74 | .book-button{
75 | display: inline-block;
76 | width: 50%;
77 | height: 100%;
78 | -webkit-mask-repeat: no-repeat;
79 | -webkit-mask-size: auto 100%;
80 | transition: 0.5s ease-out;
81 | }
82 |
83 | .book-button:hover{
84 | transform: translateY(-3px);
85 | }
86 |
87 | .book-list-button{
88 | width: 40%;
89 | margin-top: 10px;
90 | margin-left: 5%;
91 | margin-right: 5%;
92 | line-height: 36px;
93 | font-size: 18px;
94 | color: white;
95 | transition: 0.3s ease-out;
96 | }
97 |
98 | .book-list-create{
99 | border-bottom-right-radius: 20px 30px;
100 | border-top-right-radius: 20px 30px;
101 | }
102 |
103 | .book-list-create:hover{
104 | transform: translateX(5px);
105 | }
106 |
107 | .book-list-load{
108 | border-bottom-left-radius: 20px 30px;
109 | border-top-left-radius: 20px 30px;
110 | }
111 |
112 | .book-list-load:hover{
113 | transform: translateX(-5px);
114 | }
115 |
116 | @keyframes rotate-full {
117 | from {
118 | transform: rotate(0deg);
119 |
120 | }
121 | to {
122 | transform: rotate(360deg);
123 | }
124 | }
--------------------------------------------------------------------------------
/src/theme/styles/context-menu.css:
--------------------------------------------------------------------------------
1 | .react-context-menu {
2 | width: 140px;
3 | padding: 5px 0;
4 | margin: 2px 0 0;
5 | font-size: 14px;
6 | color: #373a3c;
7 | text-align: left;
8 | -webkit-background-clip: padding-box;
9 | background-clip: padding-box;
10 | border: 1px solid rgba(0,0,0,.15);
11 | border-radius: .25rem;
12 | outline: none;
13 | background-position: top;
14 | background-size: 100% auto;
15 | }
16 |
17 | .react-context-menu-link {
18 | display: inline-block;
19 | width: 120px;
20 | padding: 4px 0 4px 20px;
21 | clear: both;
22 | font-weight: 200;
23 | line-height: 20px;
24 | color: #373a3c;
25 | text-align: inherit;
26 | white-space: nowrap;
27 | border: 0;
28 | text-decoration: none;
29 | cursor: pointer;
30 | }
31 |
32 | .react-context-menu-link.active,
33 | .react-context-menu-link:hover {
34 | }
35 |
36 | .react-context-menu-item.submenu > a {
37 | padding-right: 27px;
38 | }
39 |
40 | .react-context-menu-item.submenu > a:after {
41 | content: "▶";
42 | display: inline-block;
43 | position: absolute;
44 | right: 7px;
45 | }
--------------------------------------------------------------------------------
/src/theme/styles/notify.css:
--------------------------------------------------------------------------------
1 | .modal{
2 | animation-duration: 0.5s;
3 | animation-fill-mode: forwards;
4 | animation-name: anim_151461681900776;
5 | animation-timing-function: ease-out;
6 | }
7 |
8 | .modal-error, .modal-warn, .modal-sys-info, .modal-export{
9 | text-align: center;
10 | }
11 |
12 | .modal-head{
13 | width: 100%;
14 | height: 60px;
15 | background-size: 100% auto;
16 | background-position: top;
17 | }
18 |
19 | .modal-body {
20 | padding-top: 10px;
21 | width: 100%;
22 | }
23 |
24 | .modal-export .modal-body {
25 | height: 200px;
26 | }
27 |
28 | .modal-message{
29 | min-height: 30px;
30 | max-height: 400px;
31 | overflow: auto;
32 | margin-left: 10%;
33 | width: 80%;
34 | padding-top: 20px;
35 | padding-bottom: 10px;
36 | font-size: 16px;
37 | }
38 |
39 | .modal-sys-info .modal-message{
40 | text-align: left;
41 | }
42 |
43 | .modal-sys-info .modal-message > a,p,b{
44 | font-size: 14px;
45 | line-height: 20px;
46 | }
47 |
48 | .modal-sys-info .modal-message a{
49 | color: grey;
50 | }
51 |
52 | .modal-sys-info .modal-message a:hover{
53 | color: black;
54 | }
55 |
56 | .modal-sys-info .modal-message > h1,h2,h3,h4,h5,h6{
57 | margin-top: 8px;
58 | margin-bottom: 8px;
59 | }
60 |
61 | .modal-export .modal-message{
62 | padding-top: 0;
63 | }
64 |
65 | .modal-export .modal-message h3{
66 | margin-top: 20px;
67 | margin-bottom: 20px;
68 | }
69 |
70 | .modal-export .modal-message a{
71 | color: grey;
72 | }
73 |
74 | .modal-export .modal-message a:hover{
75 | color: black;
76 | }
77 |
78 | .modal-button{
79 | width: 70px;
80 | height: 30px;
81 | margin: 20px;
82 | font-size: 13px;
83 | cursor: pointer;
84 | border: none;
85 | outline: none;
86 | border-bottom-left-radius: 10px 20px;
87 | border-top-left-radius: 10px 20px;
88 | border-bottom-right-radius: 10px 20px;
89 | border-top-right-radius: 10px 20px;
90 | background-color: rgba(240, 240, 240, 0.8);
91 | }
92 |
93 | .modal-export .button-cancel{
94 |
95 | }
96 |
97 | .modal-export .button-export{
98 |
99 | }
--------------------------------------------------------------------------------
/src/theme/styles/sortable.css:
--------------------------------------------------------------------------------
1 | .ui-sortable {
2 | position: relative;
3 | -webkit-user-select: none;
4 | -moz-user-select: none;
5 | user-select: none;
6 | }
7 |
8 | .ui-sortable:after{
9 | clear: both;
10 | }
11 |
12 | .ui-sortable-item {
13 | float: left;
14 | cursor: move;
15 | }
16 |
17 | .ui-sortable-item form{
18 | cursor: move;
19 | }
20 |
21 | .ui-sortable-item form input{
22 | cursor: move;
23 | }
24 |
25 | .ui-sortable .ui-sortable-item.ui-sortable-dragging {
26 | position: absolute;
27 | z-index: 1688;
28 | }
29 |
30 | .ui-sortable .ui-sortable-placeholder {
31 | display: none;
32 | }
33 |
34 | .ui-sortable .ui-sortable-placeholder.visible {
35 | display: block;
36 | z-index: -1;
37 | }
38 |
39 | /* custom style */
40 |
41 | .ui-sortable .ui-sortable-placeholder.visible {
42 | opacity: .4;
43 | }
44 |
45 | .page-sortable-list .ui-sortable-placeholder .visible{
46 | border: 2px #fff solid;
47 | }
48 |
49 | .ui-sortable.full-width .ui-sortable-item{
50 | }
--------------------------------------------------------------------------------
/webpack.config.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Webpack development server configuration
3 | *
4 | * This file is set up for serving the webpack-dev-server, which will watch for changes and recompile as required if
5 | * the subfolder /webpack-dev-server/ is visited. Visiting the root will not automatically reload.
6 | */
7 | const webpack = require('webpack');
8 | const path = require('path');
9 | const ExtractTextPlugin = require('extract-text-webpack-plugin');
10 | const paths = require('./config').paths;
11 | const srcPath = paths.srcPath;
12 |
13 | module.exports = {
14 | cache: true,
15 | debug: true,
16 | entry: {
17 | main: [
18 | 'webpack-dev-server/client?' + paths.urlPath,
19 | 'webpack/hot/only-dev-server',
20 | path.join(srcPath, 'index.js')
21 | ]
22 | }
23 | ,
24 |
25 | output: {
26 | filename: "main.js",
27 | publicPath: '/assets/'
28 | },
29 |
30 | stats: {
31 | colors: true,
32 | reasons: true,
33 | errorDetails: true
34 | },
35 |
36 | devtool: false,
37 |
38 | resolve: {
39 | //root: [srcPath],
40 | extensions: ["", ".webpack.js", ".web.js", ".js"],
41 | alias: {
42 | config: "config.js"
43 | }
44 | },
45 |
46 | target: "electron",
47 |
48 | module: {
49 | preLoaders: [{
50 | test: /\.js$/,
51 | exclude: /node_modules|src\/theme\/*/,
52 | loader: 'jsxhint'
53 | }],
54 | loaders: [
55 | {
56 | test: /\.js$/,
57 | exclude: /node_modules/,
58 | loaders: [
59 | 'react-hot',
60 | 'babel?presets[]=react,presets[]=es2015'
61 | ],
62 | include : srcPath
63 | },
64 | {
65 | test: /\.css$/,
66 | loader: ExtractTextPlugin.extract("style-loader", "css-loader")
67 | },
68 | {
69 | test: /\.(png|jpg|gif|woff|woff2)$/,
70 | loader: 'url?limit=10'
71 | },
72 | {
73 | test : /\.woff|\.woff2|\.svg|.eot|\.ttf/,
74 | loader : 'url?prefix=font/&limit=10000'
75 | },
76 | {
77 | test: /\.json$/,
78 | loader: "json-loader"
79 | }
80 | ],
81 | noParse:[
82 | "jquery",
83 | /autoit.js/
84 | ]
85 | },
86 |
87 | plugins: [
88 | new ExtractTextPlugin("main.css"),
89 | new webpack.HotModuleReplacementPlugin(),
90 | new webpack.NoErrorsPlugin(),
91 | new webpack.ProvidePlugin({
92 | $:'jquery'
93 | })
94 | ]
95 | };
96 |
--------------------------------------------------------------------------------
/webpack.dist.config.js:
--------------------------------------------------------------------------------
1 | /*
2 | * Webpack development server configuration
3 | *
4 | * This file is set up for serving the webpack-dev-server, which will watch for changes and recompile as required if
5 | * the subfolder /webpack-dev-server/ is visited. Visiting the root will not automatically reload.
6 | */
7 | const webpack = require('webpack');
8 | const path = require('path');
9 | const ExtractTextPlugin = require('extract-text-webpack-plugin');
10 | var config = require('./config');
11 | var paths = config.paths;
12 | const srcPath = paths.srcPath;
13 |
14 | module.exports = {
15 | cache: true,
16 | debug: true,
17 | entry: {
18 | main: [path.join(srcPath, 'index.js')]
19 | },
20 |
21 | output: {
22 | path: paths.distPath + "/assets/",
23 | filename: "main.js",
24 | publicPath: '/assets/'
25 | },
26 |
27 | stats: {
28 | colors: true,
29 | reasons: true,
30 | errorDetails: true
31 | },
32 |
33 | devtool: false,
34 |
35 | resolve: {
36 | extensions: ["", ".webpack.js", ".web.js", ".js"],
37 | alias: {
38 | config: "config.js"
39 | }
40 | },
41 |
42 | target: "electron",
43 |
44 | module: {
45 | preLoaders: [{
46 | test: /\.js$/,
47 | exclude: /node_modules|src\/theme\/*/,
48 | loader: 'jsxhint'
49 | }],
50 | loaders: [
51 | {
52 | test: /\.js$/,
53 | exclude: /node_modules/,
54 | loaders: [
55 | 'react-hot',
56 | 'babel?presets[]=react,presets[]=es2015'
57 | ],
58 | include : srcPath
59 | },
60 | {
61 | test: /\.css$/,
62 | loader: ExtractTextPlugin.extract("style-loader", "css-loader")
63 | },
64 | {
65 | test: /\.(png|jpg|gif|woff|woff2)$/,
66 | loader: 'url?limit=10'
67 | },
68 | {
69 | test : /\.woff|\.woff2|\.svg|.eot|\.ttf/,
70 | loader : 'url?prefix=font/&limit=10000'
71 | },
72 | {
73 | test: /\.json$/,
74 | loader: "json-loader"
75 | }
76 | ],
77 | noParse:[
78 | "jquery",
79 | /autoit.js/
80 | ]
81 | },
82 |
83 | plugins: [
84 | new ExtractTextPlugin("main.css"),
85 | new webpack.HotModuleReplacementPlugin(),
86 | new webpack.NoErrorsPlugin(),
87 | new webpack.ProvidePlugin({
88 | $:'jquery'
89 | })
90 | ]
91 | };
92 |
--------------------------------------------------------------------------------