mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-03-13 07:56:14 +01:00
🚨
This commit is contained in:
parent
8db6015709
commit
358047dea0
6 changed files with 11 additions and 20 deletions
|
|
@ -574,12 +574,12 @@ export const updateCellsValue = (protyle: IProtyle, nodeElement: HTMLElement, va
|
|||
let link = protyle.lute.GetLinkDest(value);
|
||||
let name = "";
|
||||
if (html) {
|
||||
const tempElement = document.createElement("template")
|
||||
tempElement.innerHTML = html
|
||||
const aElement = tempElement.content.querySelector('[data-type~="a"]')
|
||||
const tempElement = document.createElement("template");
|
||||
tempElement.innerHTML = html;
|
||||
const aElement = tempElement.content.querySelector('[data-type~="a"]');
|
||||
if (aElement) {
|
||||
link = aElement.getAttribute("data-href");
|
||||
name = aElement.textContent
|
||||
name = aElement.textContent;
|
||||
}
|
||||
}
|
||||
if (!link && !name) {
|
||||
|
|
|
|||
|
|
@ -583,7 +583,7 @@ export const mergeAddOption = (column: IAVColumn, cellValue: IAVCellValue, avID:
|
|||
}
|
||||
});
|
||||
if (!needAdd) {
|
||||
const newColor = ((column.options?.length || 0) % 13 + 1).toString()
|
||||
const newColor = ((column.options?.length || 0) % 13 + 1).toString();
|
||||
column.options.push({
|
||||
name: item.content,
|
||||
color: newColor
|
||||
|
|
@ -594,7 +594,7 @@ export const mergeAddOption = (column: IAVColumn, cellValue: IAVCellValue, avID:
|
|||
id: column.id,
|
||||
avID,
|
||||
data: column.options
|
||||
})
|
||||
});
|
||||
undoOperations.push({
|
||||
action: "removeAttrViewColOption",
|
||||
id: column.id,
|
||||
|
|
@ -607,4 +607,4 @@ export const mergeAddOption = (column: IAVColumn, cellValue: IAVCellValue, avID:
|
|||
doOperations,
|
||||
undoOperations
|
||||
};
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue