`<h1><font` size="4">${(() => {
const titleTranslation = topItem.getField("titleTranslation");
if (titleTranslation) {
return `(${topItem.getField("date")}) ${topItem.getField("title")} (${titleTranslation})`;
} else {
return `(${topItem.getField("date")}) ${topItem.getField("title")}`;
}
})()}
</h1>
<div><strong>作者</strong>:: ${topItem.getCreators().map((v)=>v.firstName+" "+v.lastName).join("; ")}</div>
<div><strong>出版年份</strong>:: ${topItem.getField('date')}</div>
<div><strong>期刊</strong>:: ${topItem.getField('publicationTitle')}</div>
<div><strong>期刊标签</strong>:: ${(() => {
let tags = Zotero.ZoteroStyle.data.ztoolkit.ItemTree.fieldHooks.globalCache.getFieldHooks.PublicationTags(
"", true, true, topItem, undefined);
let out = " ";
if (!tags){
out += `<span></span>`;
}else{
const jsonStartIndex = tags.indexOf('{');
if (jsonStartIndex !== -1) {
tags = tags.slice(jsonStartIndex);
}
let regex = /"(sci|sciif)":"([^"]+)"/g;
let matches = tags.match(regex);
const keyValuePairs = JSON.parse(tags);
const colors = ["#b73508", "#d47828", "#f5d44b", "#afcfa6 ", "#4c6643"];
for (const key in keyValuePairs) {
if (key === "sci") {
out += `<span style="background-color: ${colors[0]}; margin-right: 20px; padding:5px">SCI ${keyValuePairs[key]}</span>`;
}
if (key === "sciUp") {
out += `<span style="background-color: ${colors[1]}; margin-right: 20px; padding:5px">中科院 ${keyValuePairs[key]}</span>`;
}
if (key === "sciif") {
out += `<span style="background-color: ${colors[2]}; margin-right: 20px; padding:5px">IF ${keyValuePairs[key]}</span>`;
}
if (key === "pku") {
out += `<span style="background-color: ${colors[3]}; margin-right: 20px; padding:5px"> 北核</span>`;
}
if (key === "cssci") {
out += `<span style="background-color: ${colors[4]}; margin-right: 20px; padding:5px"> ${keyValuePairs[key]}</span>`;
}
if (key === "xju") {
out += `<span style="background-color: ${colors[4]}; margin-right: 20px; padding:5px"> #${keyValuePairs[key]}</span>`;
}
}
}
return out;
})()}</div>
<div><strong>标题翻译</strong>:: ${topItem.getField('titleTranslation')}</div>
<div><strong>摘要翻译</strong>:: ${topItem.getField('abstractTranslation')}</div>
<div><strong>doi</strong>:: ${topItem.getField('DOI')}</div>
<div><strong>附件链接</strong>:: <a href="zotero://open-pdf/0_${Zotero.Items.get(topItem.getAttachments())[0].key}">
${Zotero.Items.get(topItem.getAttachments())[0].getFilename()}
</a></div>
<div><strong>创新摘要</strong>:: </div>
<h2 style="color: #45aab4;">📜 背景</h2>
<hr/>
<p></p>
<h2 style="color:#f9637c; ">🔬 研究内容</h2>
<hr/>
<p></p>
<h2 style="color:#fbb45c;">💧 数据</h2>
<hr/>
<p></p>
<h2 style="color:#4f6962; ">⚙️ 方法</h2>
<hr/>
<p></p>
<h2 style="color:#fbc1ad;">🚩 研究结果</h2>
<hr/>
<p></p>
<h2 style="color: #006064; ">💡 创新点</h2>
<hr/>
<p></p>
<h2 style="color:#fe7966;">💭 借鉴</h2>
<hr/>