"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("./picker.js");class a extends s.default{constructor(e,t){super(e),this.label.innerHTML=t,this.container.classList.add("ql-color-picker"),Array.from(this.container.querySelectorAll(".ql-picker-item")).slice(0,7).forEach(l=>{l.classList.add("ql-primary")})}buildItem(e){const t=super.buildItem(e);return t.style.backgroundColor=e.getAttribute("value")||"",t}selectItem(e,t){super.selectItem(e,t);const l=this.label.querySelector(".ql-color-label"),r=e&&e.getAttribute("data-value")||"";l&&(l.tagName==="line"?l.style.stroke=r:l.style.fill=r)}}exports.default=a;
