diff --git a/assets/js/joe.short.js b/assets/js/joe.short.js
index 0530ecb..3fb55ba 100644
--- a/assets/js/joe.short.js
+++ b/assets/js/joe.short.js
@@ -91,12 +91,6 @@ document.addEventListener('DOMContentLoaded', () => {
}
}
window.customElements.define('joe-abtn', JoeAbtn);
-
- /*
- ------------------------以下未测试------------------------------------------
- */
-
- /* 便条按钮 */
class JoeAnote extends HTMLElement {
constructor() {
super();
@@ -104,22 +98,21 @@ document.addEventListener('DOMContentLoaded', () => {
icon: this.getAttribute('icon') || 'fa-download',
href: this.getAttribute('href') || '#',
type: /^secondary$|^success$|^warning$|^error$|^info$/.test(this.getAttribute('type')) ? this.getAttribute('type') : 'secondary',
- content: this.innerHTML.trim().replace(/^(
)|(
)$/g, '') || '标签按钮'
+ content: this.getAttribute('content') || '标签按钮'
};
- this.render();
- }
- get template() {
- return `
-
- ${this.options.content}
-
- `;
- }
- render() {
- this.innerHTML = this.template;
+ this.innerHTML = `
+
+ ${this.options.content}
+
+ `;
}
}
window.customElements.define('joe-anote', JoeAnote);
+
+ /*
+ ------------------------以下未测试------------------------------------------
+ */
+
/* 点击复制 */
class JoeCopy extends HTMLElement {
constructor() {
diff --git a/assets/js/joe.short.min.js b/assets/js/joe.short.min.js
index 27327e8..441ef9b 100644
--- a/assets/js/joe.short.min.js
+++ b/assets/js/joe.short.min.js
@@ -1 +1 @@
-document.addEventListener("DOMContentLoaded",()=>{class t extends HTMLElement{constructor(){super(),this.innerHTML=`\n\t\t\t\t