2 lines
495 B
Java
2 lines
495 B
Java
const a=new Map,h=new Map,o=new Map,n=class i extends Array{constructor(){super(...arguments),this.optsMap=new Map,this.isShow=s=>{var t;const e=this.optsMap.get(s);return(t=e==null?void 0:e.show)!=null?t:!0}}clear(){this.splice(0,this.length)}add(s,t){var e;this.push(s),s!==i.DIVIDER&&this.optsMap.set(s,{show:(e=t==null?void 0:t.show)!=null?e:!0})}addDivider(){this.push(i.DIVIDER)}isDivider(s){return s===i.DIVIDER}};n.DIVIDER="divider";let r=n;const p=new r;export{h,a as n,p as o,o as r};
|