Modify LLM HTML translation to also use DOM parser
This commit is contained in:
@@ -238,10 +238,7 @@ export async function translateHTML(html: string, reverse:boolean, charArg:simpl
|
||||
return html
|
||||
}
|
||||
}
|
||||
if(db.translatorType === 'llm'){
|
||||
const tr = db.translator || 'en'
|
||||
return translateLLM(html, {to: tr})
|
||||
}
|
||||
|
||||
const dom = new DOMParser().parseFromString(html, 'text/html');
|
||||
console.log(html)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user