Skip to content

Commit

Permalink
Fix: smartfilter UI bug
Browse files Browse the repository at this point in the history
  • Loading branch information
GeoffreyChen777 committed Mar 11, 2024
1 parent ddca695 commit 67fbdf2
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 9 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG_CN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# v3.0.0-beta.13 11/03 2024

1. 新特性:再其他 App 中和 Paperlib 通信的 API:paperlib://APIGroup.serviceName.methodName/?args=\[...\]
2. 改进: 添加了一个新的快捷键 `Ctrl/Cmd + s` 来保存当前编辑的论文。
3. 修复:一个 smartfilter 编辑器的 Bug。致谢 @Rccubc

# v3.0.0-beta.12 11/03 2024

1. 新特性:再其他 App 中和 Paperlib 通信的 API:paperlib://APIGroup.serviceName.methodName/?args=\[...\]
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG_EN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## v3.0.0-beta.13 11/03 2024

1. New Feature: API for other APPs: paperlib://APIGroup.serviceName.methodName/?args=\[...\]
2. Enhance: add `Ctrl/CMD + s` shortcut for the editing window.
3. Fix: a bug in smartfilter editor. Thanks @Rccubc

## v3.0.0-beta.12 11/03 2024

1. New Feature: API for other APPs: paperlib://APIGroup.serviceName.methodName/?args=\[...\]
Expand Down
25 changes: 17 additions & 8 deletions app/renderer/ui/edit-view/components/smart-filter-rule-box.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,24 @@ const parseInitFilter = () => {
const comps = filter.split(" ");
if (Array.from(Object.values(startOps.value)).includes(comps[0])) {
selectedStartOp.value = comps[0].toUpperCase();
selectedField.value = comps[1];
selectedOp.value = comps[2].toUpperCase().replaceAll("[C]", "[c]");
selectedValue.value = comps
.slice(3)
.join(" ")
.replace(/^["']/, "")
.replace(/["']$/, "");
} else {
selectedField.value = comps[0];
selectedOp.value = comps[1].toUpperCase().replaceAll("[C]", "[c]");
selectedValue.value = comps
.slice(2)
.join(" ")
.replace(/^["']/, "")
.replace(/["']$/, "");
}
selectedField.value = comps[1];
selectedOp.value = comps[2].toUpperCase().replaceAll("[C]", "[c]");
selectedValue.value = comps
.slice(3)
.join(" ")
.replace(/^["']/, "")
.replace(/["']$/, "");
}
};
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "paperlib-beta",
"version": "3.0.0-beta.12",
"version": "3.0.0-beta.13",
"main": "dist/main-entry.js",
"description": "A simple academic paper management tool.",
"author": "Future Scholars <[email protected]>",
Expand Down

0 comments on commit 67fbdf2

Please sign in to comment.