diff --git a/src/btn.ts b/src/btn.ts index 35c9ce0..2e375e4 100644 --- a/src/btn.ts +++ b/src/btn.ts @@ -97,7 +97,7 @@ export class BtnList { // hide buttons using the shadow DOM const newParent = btnParent.cloneNode(false) as HTMLDivElement - newParent.append(...this.list) + newParent.append(...this.list.map(e => e.cloneNode(true))) const slot = document.createElement('slot') newParent.append(slot) shadow.append(newParent)