"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const u=require("../blots/block.js"),l=require("../blots/container.js"),d=require("../core/quill.js");class s extends l.default{}s.blotName="list-container";s.tagName="OL";class r extends u.default{static create(t){const e=super.create();return e.setAttribute("data-list",t),e}static formats(t){return t.getAttribute("data-list")||void 0}static register(){d.default.register(s)}constructor(t,e){super(t,e);const i=e.ownerDocument.createElement("span"),a=n=>{if(!t.isEnabled())return;const c=this.statics.formats(e,t);c==="checked"?(this.format("list","unchecked"),n.preventDefault()):c==="unchecked"&&(this.format("list","checked"),n.preventDefault())};i.addEventListener("mousedown",a),i.addEventListener("touchstart",a),this.attachUI(i)}format(t,e){t===this.statics.blotName&&e?this.domNode.setAttribute("data-list",e):super.format(t,e)}}r.blotName="list";r.tagName="LI";s.allowedChildren=[r];r.requiredContainer=s;exports.ListContainer=s;exports.default=r;
