Skip to content

Commit

Permalink
版本升级及细节优化
Browse files Browse the repository at this point in the history
  • Loading branch information
kiwiflydream committed Dec 30, 2020
1 parent e53a9b6 commit be6a0d1
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 17 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "yuque-helper",
"version": "1.0.0",
"version": "1.1.0",
"description": "一个语雀辅助小工具",
"author": "[email protected]",
"license": "MIT",
Expand Down
3 changes: 2 additions & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "yuque-helper",
"description": "一个语雀辅助小工具",
"version": null,
"version": "1.1.0",
"manifest_version": 2,
"icons": {
"48": "icons/icon_48.png",
Expand All @@ -17,6 +17,7 @@
"storage",
"notifications"
],
"homepage_url": "https://blog.coder4j.cn",
"background": {
"scripts": [
"background.js"
Expand Down
5 changes: 2 additions & 3 deletions src/markmap/markmap.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@

<head>
<meta charset="UTF-8">
<title>New Tab Page</title>
<title>yuque-helper - markmap</title>
<link rel="stylesheet" href="markmap.css">
</head>

<body>

<div id="app"></div>
<script src="markmap.js"></script>
</body>
Expand All @@ -26,6 +25,6 @@
<style scoped>
.markmap>svg {
width: 100%;
height: 800px;
height: 1000px;
}
</style>
12 changes: 6 additions & 6 deletions src/options/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,18 @@

<el-row type="flex" justify="center">
<el-col :span="9">
<el-form-item label="阅读速度" prop="readWordCount">
<el-input v-model="yuqueOption.readWordCount" placeholder="默认为每分钟 300">
<template slot="append">/ 分钟</template>
</el-input>
<el-form-item label="字数统计系数" prop="countCoefficient">
<el-input v-model="yuqueOption.countCoefficient" placeholder="默认为 1"></el-input>
</el-form-item>
</el-col>
</el-row>

<el-row type="flex" justify="center">
<el-col :span="9">
<el-form-item label="字数统计系数" prop="countCoefficient">
<el-input v-model="yuqueOption.countCoefficient" placeholder="默认为 1"></el-input>
<el-form-item label="阅读速度" prop="readWordCount">
<el-input v-model="yuqueOption.readWordCount" placeholder="默认为每分钟 300">
<template slot="append">/ 分钟</template>
</el-input>
</el-form-item>
</el-col>
</el-row>
Expand Down
2 changes: 1 addition & 1 deletion src/options/options.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<title>yuque-helper - Options</title>
<title>yuque-helper - 设置</title>
<link rel="stylesheet" href="options.css">
<% if (NODE_ENV === 'development') { %>
<!-- Load some resources only in development environment -->
Expand Down
17 changes: 12 additions & 5 deletions src/popup/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,18 @@ export default {
},
// 打开 markmap 目录
openMarkmap() {
this.sendMessageToContentScript({ cmd: 'get_markmap' }, function (response) {
console.log(response);
chrome.storage.local.set({ temp: response }, () => {
window.open('/markmap/markmap.html', '_blank');
});
this.getCurrentTab((tab) => {
if (!tab.url.includes('markdown')) {
// 通知
this.notify('生成失败', '请在 markdown 视图下打开');
} else {
this.sendMessageToContentScript({ cmd: 'get_markmap' }, function (response) {
console.log(response);
chrome.storage.local.set({ temp: response }, () => {
window.open('/markmap/markmap.html', '_blank');
});
});
}
});
},
// 打开设置
Expand Down

0 comments on commit be6a0d1

Please sign in to comment.