aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/MenuItem.mjs
diff options
context:
space:
mode:
authorHsieh Chin Fan <pham@topo.tw>2024-10-26 15:15:19 +0800
committerHsieh Chin Fan <pham@topo.tw>2024-10-26 15:15:51 +0800
commitc9efa62a5a41ae5ecf8aae5dd5abd266f7bea9fe (patch)
tree156d38f0da738cae6b66f85b4caa092605606da5 /src/MenuItem.mjs
parent9138d6b303c552d856b924950afdbdb8771cb2a3 (diff)
fix: title of menu item
Diffstat (limited to 'src/MenuItem.mjs')
-rw-r--r--src/MenuItem.mjs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/MenuItem.mjs b/src/MenuItem.mjs
index 7c617cc..1035cd1 100644
--- a/src/MenuItem.mjs
+++ b/src/MenuItem.mjs
@@ -31,7 +31,7 @@ export class Item extends window.HTMLDivElement {
31 constructor ({ text, innerHTML, title, onclick, style, className }) { 31 constructor ({ text, innerHTML, title, onclick, style, className }) {
32 super() 32 super()
33 this.innerHTML = innerHTML ?? text 33 this.innerHTML = innerHTML ?? text
34 this.title = title 34 if (title) this.title = title
35 this.onclick = onclick 35 this.onclick = onclick
36 this.style.cssText = style 36 this.style.cssText = style
37 this.classList.add('menu-item') 37 this.classList.add('menu-item')