mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-21 17:10:12 +01:00
This commit is contained in:
parent
002b5adf16
commit
38f0b0f469
2 changed files with 6 additions and 6 deletions
|
|
@ -319,11 +319,14 @@ export const setTitle = (title: string) => {
|
|||
};
|
||||
|
||||
export const downloadProgress = (data: { id: string, percent: number }) => {
|
||||
const bazzarElement = document.getElementById("configBazaarReadme");
|
||||
if (!bazzarElement) {
|
||||
const bazzarSideElement = document.querySelector("#configBazaarReadme .item__side");
|
||||
if (!bazzarSideElement) {
|
||||
return;
|
||||
}
|
||||
const btnElement = bazzarElement.querySelector('[data-type="install"]') as HTMLElement;
|
||||
if (data.id !== JSON.parse(bazzarSideElement.getAttribute("data-obj")).repoURL) {
|
||||
return;
|
||||
}
|
||||
const btnElement = bazzarSideElement.querySelector('[data-type="install"]') as HTMLElement;
|
||||
if (btnElement) {
|
||||
if (data.percent >= 1) {
|
||||
btnElement.parentElement.classList.add("fn__none");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue