diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b06584..1d650f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,16 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +### [0.1.16](https://github.com/LiHowe/vuepress-plugin-mermaid/compare/v0.1.15...v0.1.16) (2023-01-16) + +### [0.1.15](https://github.com/LiHowe/vuepress-plugin-mermaid/compare/v0.1.14...v0.1.15) (2023-01-13) + + +### Features + +* preset theme:ocean [wip] ([4c69bae](https://github.com/LiHowe/vuepress-plugin-mermaid/commit/4c69bae9f6ad97d1806ea26127c65f9e52c92245)) +* preset themes ([c2fc4bb](https://github.com/LiHowe/vuepress-plugin-mermaid/commit/c2fc4bb77a27c24bc690e4e3101f0e8a2d91b226)) + ### [0.1.14](https://github.com/LiHowe/vuepress-plugin-mermaid/compare/v0.1.13...v0.1.14) (2023-01-12) ### [0.1.13-beta.0](https://github.com/LiHowe/vuepress-plugin-mermaid/compare/v0.1.10...v0.1.13) (2023-01-12) diff --git a/README.md b/README.md index 8d9d3ab..6b4f903 100644 --- a/README.md +++ b/README.md @@ -53,12 +53,13 @@ Mermaid 完整的配置字段可以查看 [Mermaid - Configuration](https://merm + `Themes.sky`: 浅蓝色调 ![浅蓝色主题](https://s2.loli.net/2023/01/13/e8Y3Rqu4KowCjN6.png) -+ `Themes.ocean`: 深蓝色调 #### 暗黑主题 + `Themes.brown` ![棕色主题](https://s2.loli.net/2023/01/13/NGYc2A4e7BytmOR.png) ++ `Themes.plain` +![朴素主题](https://s2.loli.net/2023/01/16/XTPdMQw96qRnEfs.png) #### 自定义主题 diff --git a/README_EN.md b/README_EN.md index 52d2df3..95059a9 100644 --- a/README_EN.md +++ b/README_EN.md @@ -48,13 +48,14 @@ Except Mermaid built-in theme, the plugin add some additional themes like: #### Light Mode Themes + `Themes.sky`: light blue -![浅蓝色主题](https://s2.loli.net/2023/01/13/e8Y3Rqu4KowCjN6.png) -+ `Themes.ocean`: dark blue +![light blue](https://s2.loli.net/2023/01/13/e8Y3Rqu4KowCjN6.png) #### Dark Mode Themes + `Themes.brown` -![brown themes](https://s2.loli.net/2023/01/13/NGYc2A4e7BytmOR.png) +![brown theme](https://s2.loli.net/2023/01/13/NGYc2A4e7BytmOR.png) ++ `Themes.plain` +![Plain theme](https://s2.loli.net/2023/01/16/XTPdMQw96qRnEfs.png) #### Theme customization diff --git a/docs/.vuepress/config.ts b/docs/.vuepress/config.ts index 260e04e..9664c0d 100644 --- a/docs/.vuepress/config.ts +++ b/docs/.vuepress/config.ts @@ -1,30 +1,33 @@ import { MermaidPlugin, Themes, registerTheme } from '../../lib/node' const cc = registerTheme('fire', { - background: '#EFF5F5', + background: '#393E46', fontSize: '14px', - primaryColor: '#EFF5F5', - noteBkgColor: '#497174', - noteTextColor: '#333', - darkMode: true, - lineColor: '#EB6440', - primaryBorderColor: '#D6E4E5', - primaryTextColor: '#497174', - git0: '#D6E4E5', - git1: '#D6E4E5', - git2: '#D6E4E5', - git3: '#D6E4E5', - git4: '#D6E4E5', - git5: '#D6E4E5', - git6: '#D6E4E5', - git7: '#D6E4E5', + primaryColor: '#393E46', + // noteBkgColor: '#00ADB5', + noteTextColor: '#393E46', + darkMode: false, + lineColor: '#EEEEEE', + actorBorder: '#EEEEEE', + primaryTextColor: '#EEEEEE', + attributeBackgroundColorOdd: '#43484e', + attributeBackgroundColorEven: '#393E46' + // primaryBorderColor: '#EEEEEE', + // git0: '#D6E4E5', + // git1: '#D6E4E5', + // git2: '#D6E4E5', + // git3: '#D6E4E5', + // git4: '#D6E4E5', + // git5: '#D6E4E5', + // git6: '#D6E4E5', + // git7: '#D6E4E5', }) export default { plugins: [ MermaidPlugin({ theme: cc, - darkTheme: cc, + darkTheme: Themes.ocean, }) ] } diff --git a/package.json b/package.json index 8fc3b3b..13170a1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vuepress-plugin-mermaid-next", - "version": "0.1.14", + "version": "0.1.16", "description": "A Mermaid plugin for vuepress-next", "main": "./lib/node/index.js", "directories": { diff --git a/src/shared/theme/index.ts b/src/shared/theme/index.ts index e7d3488..b66a2f0 100644 --- a/src/shared/theme/index.ts +++ b/src/shared/theme/index.ts @@ -8,9 +8,9 @@ enum Themes { base = 'base', null = 'null', - ocean = 'ocean', sky = 'sky', brown = 'brown', + plain = 'plain', } const builtinTheme: Themes[] = [ @@ -106,17 +106,7 @@ _registerTheme(Themes.sky, { darkMode: false, }) -// [light] - ocean -_registerTheme(Themes.ocean, { - background: '#e3f2fd', - fontSize: '14px', - primaryColor: '#e3f2fd', - noteBkgColor: '#fffada', - noteTextColor: '#333', - darkMode: false, -}) - -// [dark] - charcoal +// [dark] - brown _registerTheme(Themes.brown, { background: '#1A120B', fontSize: '14px', @@ -130,6 +120,20 @@ _registerTheme(Themes.brown, { attributeBackgroundColorEven: '#3C2A21' }) +// [dark] - plain +_registerTheme(Themes.plain, { + background: '#393E46', + fontSize: '14px', + primaryColor: '#393E46', + noteTextColor: '#393E46', + darkMode: false, + lineColor: '#EEEEEE', + actorBorder: '#EEEEEE', + primaryTextColor: '#EEEEEE', + attributeBackgroundColorOdd: '#43484e', + attributeBackgroundColorEven: '#393E46' +}) + export { Themes, ExtraTheme,