Skip to content

Commit

Permalink
feat: #341 整合所有配置,提供单一统一的配置入口页面-功能菜单调整
Browse files Browse the repository at this point in the history
  • Loading branch information
terwer committed Feb 11, 2023
1 parent b6f9ee1 commit 4e4cb8c
Show file tree
Hide file tree
Showing 9 changed files with 30 additions and 27 deletions.
29 changes: 22 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@

![](https://img1.terwer.space/api/public/202212181127124.png)

## 状态
使用之前请务必详细阅读 [快速上手指南](#快速上手指南)

## 项目运行状态

[![dev checks](https://img.shields.io/github/checks-status/terwer/src-sy-post-publisher/main?label=main)](https://github.com/terwer/src-sy-post-publisher)
[![dev checks](https://img.shields.io/github/checks-status/terwer/src-sy-post-publisher/dev?label=dev)](https://github.com/terwer/src-sy-post-publisher/tree/dev)
Expand All @@ -36,25 +38,38 @@

### 发布体验相关

## 快速上手
## 快速上手指南

### FAQ

Q1:使用此思源笔记挂件或者浏览器插件有什么注意事项吗?

A1:有。 **特别提示:各种使用模式请不要混合使用,使用其中一种即可。避免因为混用导致配置同步问题。**

### 挂件版挂载菜单打开新窗口操作方式快速上手 <sup>强烈推荐</sup> <sup>0.4.2+</sup>
Q2:有哪些方式可以使用?具体步骤是什么?

A2:请参考下面三种模式及其详细说明。特别注意温馨提示的内容。

### 模式一:挂件版挂载菜单打开新窗口操作方式快速上手 <sup>强烈推荐</sup> <sup>0.4.2+</sup>

首先在设置 - 集市 - 挂件 中下载 sy-post-publisher

点击设置 - 外观- 代码片段,代码片段加上下面的 `js` 片段,然后重启思源

```js
// 如果不喜欢这个菜单,直接去掉这个代码片段引用即可,去掉之后仍然可以通过挂件版通用方式使用
import("/widgets/sy-post-publisher/lib/siyuanhook.js")
```

点击按钮开始体验
点击按钮开始体验

![](https://img1.terwer.space/api/public/20221228-175950.jpeg)

详情请参考: [挂件模式用挂载菜单的方式使用](https://docs.publish.terwer.space/post/the-pendant-mode-is-used-in-the-method-of-mounting-menu-169wrw.html)

### 挂件版通用方式快速上手
温馨提示:此模式下,功能已经是最全面的了,直接使用菜单功能即可,请不要再添加挂件。避免因为混用导致配置同步问题。

### 模式二:挂件版通用方式快速上手

首先在设置 - 集市 - 挂件 中下载 sy-post-publisher

Expand All @@ -66,9 +81,9 @@ import("/widgets/sy-post-publisher/lib/siyuanhook.js")

点击发布即可。

温馨提示:0.7.0+ 之后通过通用版使用会自动激活菜单
温馨提示:不建议通用版模式下添加 JS 片段,可能会导致配置不同步问题。要么单独使用通用版,要么单独使用挂载菜单

### 浏览器插件快速上手
### 模式三:浏览器插件快速上手

参考 [浏览器插件快速上手指南](https://docs.publish.terwer.space/docs/getting-started/#%E6%B5%8F%E8%A7%88%E5%99%A8%E6%8F%92%E4%BB%B6%E6%96%B9%E5%BC%8F%E4%BD%BF%E7%94%A8)

Expand Down
2 changes: 1 addition & 1 deletion components/picgo/setting/ConfigForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
</div>

<div class="config-form">
<el-form ref="$configForm" label-width="125px" :model="configRuleForm">
<el-form ref="$configForm" label-width="150px" :model="configRuleForm">
<el-form-item
:label="$t('setting.picgo.picbed.uploader.config.name')"
required
Expand Down
12 changes: 0 additions & 12 deletions components/publish/PublishService.vue
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,6 @@
>
<platform-setting :is-reload="isReloadServiceTab" />
</el-tab-pane>
<el-tab-pane name="post-bind" :label="$t('service.tab.post.bind')">
<PostBind :is-reload="isReloadServiceTab" :page-id="props.pageId" />
</el-tab-pane>
<el-tab-pane
name="service-switch"
:label="$t('service.tab.service.switch')"
Expand All @@ -54,12 +51,6 @@
<el-tab-pane name="dynamic-platform" :label="$t('dynamic.platform.new')">
<dynamic-platform />
</el-tab-pane>
<el-tab-pane name="picgo-setting" :label="$t('picgo.pic.setting')">
<picgo-setting />
</el-tab-pane>
<el-tab-pane :label="$t('service.tab.change.local')" name="general-setting">
<general-setting :is-reload="isReloadServiceTab" />
</el-tab-pane>
</el-tabs>
</template>

Expand All @@ -68,11 +59,8 @@ import { ref } from "vue"
import { LogFactory } from "~/utils/logUtil"
import DynamicPlatform from "~/components/publish/tab/DynamicPlatform.vue"
import ServiceSwitch from "~/components/publish/tab/ServiceSwitch.vue"
import PostBind from "~/components/publish/tab/PostBind.vue"
import PlatformSetting from "~/components/publish/tab/PlatformSetting.vue"
import PlatformMain from "~/components/publish/tab/PlatformMain.vue"
import GeneralSetting from "~/components/set/GeneralSetting.vue"
import PicgoSetting from "~/components/picgo/PicgoSetting.vue"
const logger = LogFactory.getLogger("components/publish/PublishService.vue")
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "sy-post-publisher",
"private": true,
"version": "0.7.0-beta3",
"version": "0.7.0-beta4",
"scripts": {
"serve": "python scripts/serve.py",
"dev": "python scripts/dev.py",
Expand All @@ -11,7 +11,7 @@
"docs": "jsdoc -c jsdoc.json utils/api.ts",
"prettier": "prettier --write .",
"prepare": "husky install",
"new": "python scripts/version.py 0.7.0-beta3",
"new": "python scripts/version.py 0.7.0-beta4",
"widget": "python scripts/widget.py",
"ext": "python scripts/ext.py",
"package": "pnpm widget && pnpm ext"
Expand Down
2 changes: 1 addition & 1 deletion public/lib/siyuanhook.js
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ const initIframeWidaget = () => {
initMethods.initLocalStorageMethod("iframe挂件")

// 初始化插槽
initMethods.initSlotMethod("iframe挂件")
// initMethods.initSlotMethod("iframe挂件")

// 初始化主题适配
initMethods.initThemeAdaptor("iframe挂件")
Expand Down
2 changes: 1 addition & 1 deletion public/manifest.dev.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "开发版 - 思源笔记发布辅助工具",
"version": "0.7.0-beta3",
"version": "0.7.0-beta4",
"manifest_version": 3,
"author": "terwer",
"description": "思源笔记发布辅助工具,支持博客式只读浏览,多平台文章发布。",
Expand Down
2 changes: 1 addition & 1 deletion public/manifest.prod.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "思源笔记发布辅助工具",
"version": "0.7.0-beta3",
"version": "0.7.0-beta4",
"manifest_version": 3,
"author": "terwer",
"icons": {
Expand Down
2 changes: 1 addition & 1 deletion public/mv2/manifest-v2-for-firefox.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "开发版 - 思源笔记发布辅助工具",
"version": "0.7.0-beta3",
"version": "0.7.0-beta4",
"manifest_version": 2,
"author": "terwer",
"icons": {
Expand Down
2 changes: 1 addition & 1 deletion public/widget.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"name": "sy-post-publisher",
"author": "terwer",
"url": "https://github.com/terwer/src-sy-post-publisher",
"version": "0.7.0-beta3"
"version": "0.7.0-beta4"
}

0 comments on commit 4e4cb8c

Please sign in to comment.