mirror of
https://github.com/lllin000/PaperForge.git
synced 2026-07-22 06:50:53 +00:00
feat(plugin): add 重做OCR button to global and collection dashboard
This commit is contained in:
parent
d089a53441
commit
5f073c8c09
1 changed files with 14 additions and 0 deletions
|
|
@ -798,6 +798,13 @@ export class PaperForgeStatusView extends ItemView {
|
|||
globalStatusBtn.addEventListener('click', () => {
|
||||
this._fetchStats(false);
|
||||
});
|
||||
const globalRedoBtn = btnsRow.createEl('button', { cls: 'paperforge-contextual-btn warn' });
|
||||
globalRedoBtn.createEl('span', { cls: 'paperforge-contextual-btn-icon', text: '\u21BA' });
|
||||
globalRedoBtn.createEl('span', { text: '\u91CD\u505AOCR' });
|
||||
globalRedoBtn.addEventListener('click', () => {
|
||||
const action = ACTIONS.find(a => a.id === 'paperforge-ocr-redo');
|
||||
if (action) this._runAction(action, globalRedoBtn);
|
||||
});
|
||||
const globalRepairBtn = btnsRow.createEl('button', { cls: 'paperforge-contextual-btn' });
|
||||
globalRepairBtn.createEl('span', { cls: 'paperforge-contextual-btn-icon', text: '\u21BA' });
|
||||
globalRepairBtn.createEl('span', { text: 'Repair Issues' });
|
||||
|
|
@ -1254,6 +1261,13 @@ export class PaperForgeStatusView extends ItemView {
|
|||
const action = ACTIONS.find(a => a.id === 'paperforge-sync');
|
||||
if (action) this._runAction(action, syncBtn);
|
||||
});
|
||||
const redoBtn = actionsRow.createEl('button', { cls: 'paperforge-contextual-btn warn' });
|
||||
redoBtn.createEl('span', { cls: 'paperforge-contextual-btn-icon', text: '\u21BA' });
|
||||
redoBtn.createEl('span', { text: '\u91CD\u505AOCR' });
|
||||
redoBtn.addEventListener('click', () => {
|
||||
const action = ACTIONS.find(a => a.id === 'paperforge-ocr-redo');
|
||||
if (action) this._runAction(action, redoBtn);
|
||||
});
|
||||
}
|
||||
|
||||
/* ── Refresh current mode (called on index change, D-09, REFR-01) ── */
|
||||
|
|
|
|||
Loading…
Reference in a new issue