@cas-smartdesign/swatch-picker 3.0.1 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/docs/doc.mjs +9 -10
- package/package.json +5 -5
- package/readme.md +0 -2
package/dist/docs/doc.mjs
CHANGED
|
@@ -154,7 +154,7 @@ createExample("Disabled picker", 20, "#2b63ba").disabled = true;
|
|
|
154
154
|
</div>
|
|
155
155
|
</div>
|
|
156
156
|
<div class="color-palette"></div>
|
|
157
|
-
`,c={"color-base-red-50":"#ffeeef","color-base-red-100":"#ffe2e5","color-base-red-150":"#ffccd2","color-base-red-200":"#ffb7bf","color-base-red-300":"#ff97a3","color-base-red-400":"#f96778","color-base-red-450":"#f14558","color-base-red-500":"#ea2138","color-base-red-600":"#e2001a","color-base-red-700":"#cc0017","color-base-red-800":"#b50015","color-base-red-900":"#9f0012","color-base-orange-50":"#fff5ef","color-base-orange-100":"#ffefe5","color-base-orange-150":"#ffe3d1","color-base-orange-200":"#ffd7be","color-base-orange-300":"#ffc19b","color-base-orange-400":"#ffa670","color-base-orange-450":"#ff9250","color-base-orange-500":"#ff7e30","color-base-orange-600":"#ff6b11","color-base-orange-700":"#e95f0c","color-base-orange-800":"#d65404","color-base-orange-900":"#bf4800","color-base-yellow-50":"#fffaeb","color-base-yellow-100":"#fff6de","color-base-yellow-150":"#fff0cc","color-base-yellow-200":"#ffeab6","color-base-yellow-300":"#ffe39d","color-base-yellow-400":"#ffd97b","color-base-yellow-450":"#ffcf58","color-base-yellow-500":"#ffc434","color-base-yellow-600":"#ffbb11","color-base-yellow-700":"#e9aa0c","color-base-yellow-800":"#d69a04","color-base-yellow-900":"#bf8800","color-base-green-50":"#f6faec","color-base-green-100":"#f0f7df","color-base-green-150":"#e8f2d0","color-base-green-200":"#deedbc","color-base-green-300":"#cee49c","color-base-green-400":"#bedb79","color-base-green-450":"#add154","color-base-green-500":"#9bc730","color-base-green-600":"#8abd0c","color-base-green-700":"#7baa0b","color-base-green-800":"#6e970a","color-base-green-900":"#618508","color-base-dark-green-50":"#eaf4ec","color-base-dark-green-100":"#dff2e3","color-base-dark-green-150":"#ccecd3","color-base-dark-green-200":"#b1dfbb","color-base-dark-green-300":"#93d3a2","color-base-dark-green-400":"#72c584","color-base-dark-green-450":"#4cb563","color-base-dark-green-500":"#26a642","color-base-dark-green-600":"#009621","color-base-dark-green-700":"#00871e","color-base-dark-green-800":"#00781a","color-base-dark-green-900":"#006917","color-base-cyan-50":"#e3f0f5","color-base-cyan-100":"#d5eff8","color-base-cyan-150":"#c2e8f3","color-base-cyan-200":"#aee0ef","color-base-cyan-300":"#92d4e7","color-base-cyan-400":"#70c7e0","color-base-cyan-450":"#43b4d6","color-base-cyan-500":"#19a3cb","color-base-cyan-600":"#0099c5","color-base-cyan-700":"#008ab2","color-base-cyan-800":"#007a9e","color-base-cyan-900":"#006b8a","color-base-blue-50":"#e7f1fa","color-base-blue-100":"#d6eeff","color-base-blue-150":"#c7e7ff","color-base-blue-200":"#b1deff","color-base-blue-300":"#8ecfff","color-base-blue-400":"#6ac0ff","color-base-blue-450":"#4ab2ff","color-base-blue-500":"#2ba4ff","color-base-blue-600":"#0d98ff","color-base-blue-700":"#0c88e6","color-base-blue-800":"#0a77ca","color-base-blue-900":"#0968af","color-base-dark-blue-50":"#e1ebf6","color-base-dark-blue-100":"#d3e6fa","color-base-dark-blue-150":"#b9d7f5","color-base-dark-blue-200":"#9bc6f2","color-base-dark-blue-300":"#77afe7","color-base-dark-blue-400":"#5198e0","color-base-dark-blue-450":"#3a85d1","color-base-dark-blue-500":"#2576c7","color-base-dark-blue-600":"#1467ba","color-base-dark-blue-700":"#125da8","color-base-dark-blue-800":"#105295","color-base-dark-blue-900":"#0e4883","color-base-pink-50":"#fce6f3","color-base-pink-100":"#fad5eb","color-base-pink-150":"#f7bbdd","color-base-pink-200":"#f2a1cf","color-base-pink-300":"#ec78ba","color-base-pink-400":"#e755a8","color-base-pink-450":"#d94397","color-base-pink-500":"#cc2f89","color-base-pink-600":"#c41579","color-base-pink-700":"#b4136e","color-base-pink-800":"#a01163","color-base-pink-900":"#8a0f55","color-base-purple-50":"#f4e2f6","color-base-purple-100":"#eccff0","color-base-purple-150":"#dab2e0","color-base-purple-200":"#c792cf","color-base-purple-300":"#ab66b4","color-base-purple-400":"#93459e","color-base-purple-450":"#823591","color-base-purple-500":"#772386","color-base-purple-600":"#6c127b","color-base-purple-700":"#5e106b","color-base-purple-800":"#530d5e","color-base-purple-900":"#450b4f","color-base-brown-50":"#f2eae4","color-base-brown-100":"#eadcd2","color-base-brown-150":"#d8c4b3","color-base-brown-200":"#bca38d","color-base-brown-300":"#a08165","color-base-brown-400":"#8b6747","color-base-brown-450":"#755438","color-base-brown-500":"#65472b","color-base-brown-600":"#593b20","color-base-brown-700":"#4f351d","color-base-brown-800":"#462f1b","color-base-brown-900":"#3f2915","color-base-grey-50":"#f9f9f9","color-base-grey-100":"#f3f3f3","color-base-grey-150":"#eeeeee","color-base-grey-200":"#e5e5e5","color-base-grey-300":"#d9d9d9","color-base-grey-400":"#cccccc","color-base-grey-450":"#bbbbbb","color-base-grey-500":"#aaaaaa","color-base-grey-600":"#999999","color-base-grey-700":"#777777","color-base-grey-800":"#666666","color-base-grey-900":"#555555","color-base-white":"#ffffff","color-base-black":"#111111","color-font-base":"#111111","color-font-secondary":"#555555","color-font-tertiary":"#999999","color-font-warn":"#555555","color-font-suggest":"#bf8800","color-font-error":"#cc0017","size-font-tiny":"12px","size-font-small":"13px","size-font-medium":"16px","size-font-large":"20px","size-font-xl":"24px","size-font-xxl":"32px","size-font-xxxl":"48px","size-font-base":"16px","font-family-base":'"Segoe UI", Tahoma, Geneva, Verdana, sans-serif',"time-transition-short":"275ms","time-transition-base":"300ms","time-transition-long":"600ms","time-transition-xl":"1000ms"},Gn=[c["color-base-red-50"],c["color-base-red-100"],c["color-base-red-150"],c["color-base-red-200"],c["color-base-red-300"],c["color-base-red-400"],c["color-base-red-500"],c["color-base-red-600"],c["color-base-red-700"],c["color-base-red-800"],c["color-base-red-900"],c["color-base-orange-50"],c["color-base-orange-100"],c["color-base-orange-150"],c["color-base-orange-200"],c["color-base-orange-300"],c["color-base-orange-400"],c["color-base-orange-500"],c["color-base-orange-600"],c["color-base-orange-700"],c["color-base-orange-800"],c["color-base-orange-900"],c["color-base-yellow-50"],c["color-base-yellow-100"],c["color-base-yellow-150"],c["color-base-yellow-200"],c["color-base-yellow-300"],c["color-base-yellow-400"],c["color-base-yellow-500"],c["color-base-yellow-600"],c["color-base-yellow-700"],c["color-base-yellow-800"],c["color-base-yellow-900"],c["color-base-green-50"],c["color-base-green-100"],c["color-base-green-150"],c["color-base-green-200"],c["color-base-green-300"],c["color-base-green-400"],c["color-base-green-500"],c["color-base-green-600"],c["color-base-green-700"],c["color-base-green-800"],c["color-base-green-900"],c["color-base-dark-green-50"],c["color-base-dark-green-100"],c["color-base-dark-green-150"],c["color-base-dark-green-200"],c["color-base-dark-green-300"],c["color-base-dark-green-400"],c["color-base-dark-green-500"],c["color-base-dark-green-600"],c["color-base-dark-green-700"],c["color-base-dark-green-800"],c["color-base-dark-green-900"],c["color-base-cyan-50"],c["color-base-cyan-100"],c["color-base-cyan-150"],c["color-base-cyan-200"],c["color-base-cyan-300"],c["color-base-cyan-400"],c["color-base-cyan-500"],c["color-base-cyan-600"],c["color-base-cyan-700"],c["color-base-cyan-800"],c["color-base-cyan-900"],c["color-base-blue-50"],c["color-base-blue-100"],c["color-base-blue-150"],c["color-base-blue-200"],c["color-base-blue-300"],c["color-base-blue-400"],c["color-base-blue-500"],c["color-base-blue-600"],c["color-base-blue-700"],c["color-base-blue-800"],c["color-base-blue-900"],c["color-base-dark-blue-50"],c["color-base-dark-blue-100"],c["color-base-dark-blue-150"],c["color-base-dark-blue-200"],c["color-base-dark-blue-300"],c["color-base-dark-blue-400"],c["color-base-dark-blue-500"],c["color-base-dark-blue-600"],c["color-base-dark-blue-700"],c["color-base-dark-blue-800"],c["color-base-dark-blue-900"],c["color-base-pink-50"],c["color-base-pink-100"],c["color-base-pink-150"],c["color-base-pink-200"],c["color-base-pink-300"],c["color-base-pink-400"],c["color-base-pink-500"],c["color-base-pink-600"],c["color-base-pink-700"],c["color-base-pink-800"],c["color-base-pink-900"],c["color-base-purple-50"],c["color-base-purple-100"],c["color-base-purple-150"],c["color-base-purple-200"],c["color-base-purple-300"],c["color-base-purple-400"],c["color-base-purple-500"],c["color-base-purple-600"],c["color-base-purple-700"],c["color-base-purple-800"],c["color-base-purple-900"],c["color-base-brown-50"],c["color-base-brown-100"],c["color-base-brown-150"],c["color-base-brown-200"],c["color-base-brown-300"],c["color-base-brown-400"],c["color-base-brown-500"],c["color-base-brown-600"],c["color-base-brown-700"],c["color-base-brown-800"],c["color-base-brown-900"],c["color-base-grey-50"],c["color-base-grey-100"],c["color-base-grey-150"],c["color-base-grey-200"],c["color-base-grey-300"],c["color-base-grey-400"],c["color-base-grey-500"],c["color-base-grey-600"],c["color-base-grey-700"],c["color-base-grey-800"],c["color-base-grey-900"]],Ve=class Ve extends Hn{constructor(){super(...arguments),this.keyDownListener=e=>{if(e.defaultPrevented)return;let t=!0;const r=this.colorList.indexOf(this.color);switch(e.key){case"Esc":case"Escape":this.colorWhenOpen&&(this.color=this.colorWhenOpen),this.close();break;case"Up":case"ArrowUp":r>0?this.color=this.colorList[r-1]:this.color=this.colorList[this.colorList.length-1];break;case"Down":case"ArrowDown":r<this.colorList.length-1?this.color=this.colorList[r+1]:this.color=this.colorList[0];break;case"Left":case"ArrowLeft":{let s;r===0?s=this.colorList.length-1:(s=r-this.colorNumberInColumn,s<0&&(s=this.colorList.length+s,s%this.colorNumberInColumn>0&&s--)),this.color=this.colorList[s];break}case"Right":case"ArrowRight":{let s;r===this.colorList.length-1?s=0:(s=r+this.colorNumberInColumn,s>=this.colorList.length&&(s=s-this.colorList.length,s<this.colorNumberInColumn&&s++)),this.color=this.colorList[s];break}case"Enter":this.close(),this.dispatchValueChange();break;default:t=!1;return}t&&e.preventDefault()},this.modalityListener=e=>{this.contains(e.target)||this.close()},this.scrollListener=()=>{this.restoreScrollPosition()}}is(){return Ve.ID}get color(){return this.getAttribute("color")}set color(e){if(e){if(this.setAttribute("color",e),this.shadowRoot){this.svg.style.fill=e;const t=this.colorList.indexOf(e);t>=0?this.selectedColorElement=this.colorPalette.children[t]:this.selectedColorElement=null}}else this.removeAttribute("color"),this.svg.style.fill="",this.selectedColorElement=null}get colorList(){return this._colorList||Gn}set colorList(e){this._colorList=e,this.shadowRoot&&this.updatePalette()}get columnCount(){return Number(this.getAttribute("columncount"))||12}set columnCount(e){e?this.setAttribute("columncount",`${e}`):this.removeAttribute("columncount")}get disabled(){return this.getAttribute("aria-disabled")=="true"}set disabled(e){this.setAttribute("aria-disabled",e.toString())}get colorSize(){return Number(this.getAttribute("colorsize"))||20}set colorSize(e){e?this.setAttribute("colorsize",`${e}`):this.removeAttribute("colorsize")}template(){const e=document.createElement("template");return e.innerHTML=Wn,e}static get observedAttributes(){return["colorsize","columncount"]}connectedCallback(){super.connectedCallback(),this.colorPalette||(this.colorPalette=this.shadowRoot.querySelector(".color-palette"),this.picker=this.shadowRoot.querySelector(".picker"),this.ripple=this.shadowRoot.querySelector(".ripple"),this.svg=this.shadowRoot.querySelector("svg"),this.color&&(this.svg.style.fill=this.color),this.picker.addEventListener("pointerdown",e=>{e.stopPropagation(),this.colorPalette.classList.contains("opened")?this.close():(this.updatePalettePosition(),this.open())}),this.addEventListener("keydown",e=>{e.key==="Enter"&&(this.open(),e.preventDefault())}),this.updatePalette()),this.hasAttribute("tabIndex")||(this.tabIndex=0)}attributeChangedCallback(){this.colorPalette&&this.updatePalette()}updatePalette(){for(;this.colorPalette.firstChild;)this.colorPalette.removeChild(this.colorPalette.firstChild);this.colorNumberInColumn=Math.ceil(this.colorList.length/this.columnCount),this.colorPalette.style.height=`${this.colorNumberInColumn*this.colorSize}px`,this.colorPalette.style.width=`${this.colorSize*this.columnCount}px`,this.colorPalette.appendChild(this.createColorPaletteFragment())}createColorPaletteFragment(){const e=document.createDocumentFragment(),t=this.color;for(const r of this.colorList){const s=document.createElement("div");s.classList.add("color"),s.style.backgroundColor=r,s.style.width=`${this.colorSize}px`,s.style.height=`${this.colorSize}px`,s.addEventListener("pointerdown",()=>{this.color=r,this.close(),this.dispatchValueChange()}),t===r&&(this.selectedColorElement=s,this.selectedColorElement.classList.add("active-color")),e.appendChild(s)}return e}get selectedColorElement(){return this._selectedColorElement}set selectedColorElement(e){this._selectedColorElement&&this._selectedColorElement.classList.remove("active-color"),this._selectedColorElement=e,this._selectedColorElement&&this._selectedColorElement.classList.add("active-color")}open(){this.disabled||(this.colorPalette.classList.add("opened"),this.ripple.classList.add("active"),this.colorWhenOpen=this.color,this.saveScrollPosition(),window.addEventListener("keydown",this.keyDownListener,{capture:!0}),window.addEventListener("pointerdown",this.modalityListener,{capture:!0}),window.addEventListener("scroll",this.scrollListener,{capture:!0}))}close(){this.colorPalette.classList.remove("opened"),this.ripple.classList.remove("active"),window.removeEventListener("keydown",this.keyDownListener,{capture:!0}),window.removeEventListener("pointerdown",this.modalityListener,{capture:!0}),window.removeEventListener("scroll",this.scrollListener,{capture:!0})}saveScrollPosition(){document.scrollingElement?(this._scrollTop=document.scrollingElement.scrollTop,this._scrollLeft=document.scrollingElement.scrollLeft):(this._scrollTop=Math.max(document.documentElement.scrollTop,document.body.scrollTop),this._scrollLeft=Math.max(document.documentElement.scrollLeft,document.body.scrollLeft))}restoreScrollPosition(){document.scrollingElement?(document.scrollingElement.scrollTop=this._scrollTop,document.scrollingElement.scrollLeft=this._scrollLeft):(document.documentElement.scrollTop=document.body.scrollTop=this._scrollTop,document.documentElement.scrollLeft=document.body.scrollLeft=this._scrollLeft)}updatePalettePosition(){const e=this.getBoundingClientRect();e.left+this.colorPalette.offsetWidth>this.scrollingElementClientWidth?this.colorPalette.style.left=`${this.scrollingElementClientWidth-this.colorPalette.offsetWidth}px`:this.colorPalette.style.left=`${e.left}px`,e.top+this.colorPalette.offsetHeight>this.scrollingElementClientHeight?this.colorPalette.style.top=`${this.scrollingElementClientHeight-this.colorPalette.offsetHeight}px`:this.colorPalette.style.top=`${e.top}px`}get scrollingElementClientHeight(){return document.scrollingElement?document.scrollingElement.clientHeight:Math.max(document.documentElement.clientHeight,document.body.clientHeight)}get scrollingElementClientWidth(){return document.scrollingElement?document.scrollingElement.clientWidth:Math.max(document.documentElement.clientWidth,document.body.clientWidth)}dispatchValueChange(){this.dispatchEvent(new CustomEvent("value-change",{detail:this.color}))}};Ve.ID="sd-swatch-picker";let Be=Ve;customElements.define(Be.ID,Be);function xr(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}function Zn(n){if(n.__esModule)return n;var e=n.default;if(typeof e=="function"){var t=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(n).forEach(function(r){var s=Object.getOwnPropertyDescriptor(n,r);Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:function(){return n[r]}})}),t}var At={exports:{}},_=String,vr=function(){return{isColorSupported:!1,reset:_,bold:_,dim:_,italic:_,underline:_,inverse:_,hidden:_,strikethrough:_,black:_,red:_,green:_,yellow:_,blue:_,magenta:_,cyan:_,white:_,gray:_,bgBlack:_,bgRed:_,bgGreen:_,bgYellow:_,bgBlue:_,bgMagenta:_,bgCyan:_,bgWhite:_}};At.exports=vr();At.exports.createColors=vr;var Vn=At.exports;const Kn={},qn=Object.freeze(Object.defineProperty({__proto__:null,default:Kn},Symbol.toStringTag,{value:"Module"})),z=Zn(qn);let Kt=Vn,qt=z,dt=class Er extends Error{constructor(e,t,r,s,o,i){super(e),this.name="CssSyntaxError",this.reason=e,o&&(this.file=o),s&&(this.source=s),i&&(this.plugin=i),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,Er)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=Kt.isColorSupported),qt&&e&&(t=qt(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),o=Math.min(this.line+2,r.length),i=String(o).length,l,a;if(e){let{bold:u,gray:f,red:y}=Kt.createColors(!0);l=m=>u(y(m)),a=m=>f(m)}else l=a=u=>u;return r.slice(s,o).map((u,f)=>{let y=s+1+f,m=" "+(" "+y).slice(-i)+" | ";if(y===this.line){let A=a(m.replace(/\d/g," "))+u.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+a(m)+u+`
|
|
157
|
+
`,c={"color-base-red-50":"#ffeeef","color-base-red-100":"#ffe2e5","color-base-red-150":"#ffccd2","color-base-red-200":"#ffb7bf","color-base-red-300":"#ff97a3","color-base-red-400":"#f96778","color-base-red-450":"#f14558","color-base-red-500":"#ea2138","color-base-red-600":"#e2001a","color-base-red-700":"#cc0017","color-base-red-800":"#b50015","color-base-red-900":"#9f0012","color-base-orange-50":"#fff5ef","color-base-orange-100":"#ffefe5","color-base-orange-150":"#ffe3d1","color-base-orange-200":"#ffd7be","color-base-orange-300":"#ffc19b","color-base-orange-400":"#ffa670","color-base-orange-450":"#ff9250","color-base-orange-500":"#ff7e30","color-base-orange-600":"#ff6b11","color-base-orange-700":"#e95f0c","color-base-orange-800":"#d65404","color-base-orange-900":"#bf4800","color-base-yellow-50":"#fffaeb","color-base-yellow-100":"#fff6de","color-base-yellow-150":"#fff0cc","color-base-yellow-200":"#ffeab6","color-base-yellow-300":"#ffe39d","color-base-yellow-400":"#ffd97b","color-base-yellow-450":"#ffcf58","color-base-yellow-500":"#ffc434","color-base-yellow-600":"#ffbb11","color-base-yellow-700":"#e9aa0c","color-base-yellow-800":"#d69a04","color-base-yellow-900":"#bf8800","color-base-green-50":"#f6faec","color-base-green-100":"#f0f7df","color-base-green-150":"#e8f2d0","color-base-green-200":"#deedbc","color-base-green-300":"#cee49c","color-base-green-400":"#bedb79","color-base-green-450":"#add154","color-base-green-500":"#9bc730","color-base-green-600":"#8abd0c","color-base-green-700":"#7baa0b","color-base-green-800":"#6e970a","color-base-green-900":"#618508","color-base-dark-green-50":"#eaf4ec","color-base-dark-green-100":"#dff2e3","color-base-dark-green-150":"#ccecd3","color-base-dark-green-200":"#b1dfbb","color-base-dark-green-300":"#93d3a2","color-base-dark-green-400":"#72c584","color-base-dark-green-450":"#4cb563","color-base-dark-green-500":"#26a642","color-base-dark-green-600":"#009621","color-base-dark-green-700":"#00871e","color-base-dark-green-800":"#00781a","color-base-dark-green-900":"#006917","color-base-cyan-50":"#e3f0f5","color-base-cyan-100":"#d5eff8","color-base-cyan-150":"#c2e8f3","color-base-cyan-200":"#aee0ef","color-base-cyan-300":"#92d4e7","color-base-cyan-400":"#70c7e0","color-base-cyan-450":"#43b4d6","color-base-cyan-500":"#19a3cb","color-base-cyan-600":"#0099c5","color-base-cyan-700":"#008ab2","color-base-cyan-800":"#007a9e","color-base-cyan-900":"#006b8a","color-base-blue-50":"#e7f1fa","color-base-blue-100":"#d6eeff","color-base-blue-150":"#c7e7ff","color-base-blue-200":"#b1deff","color-base-blue-300":"#8ecfff","color-base-blue-400":"#6ac0ff","color-base-blue-450":"#4ab2ff","color-base-blue-500":"#2ba4ff","color-base-blue-600":"#0d98ff","color-base-blue-700":"#0c88e6","color-base-blue-800":"#0a77ca","color-base-blue-900":"#0968af","color-base-dark-blue-50":"#e1ebf6","color-base-dark-blue-100":"#d3e6fa","color-base-dark-blue-150":"#b9d7f5","color-base-dark-blue-200":"#9bc6f2","color-base-dark-blue-300":"#77afe7","color-base-dark-blue-400":"#5198e0","color-base-dark-blue-450":"#3a85d1","color-base-dark-blue-500":"#2576c7","color-base-dark-blue-600":"#1467ba","color-base-dark-blue-700":"#125da8","color-base-dark-blue-800":"#105295","color-base-dark-blue-900":"#0e4883","color-base-pink-50":"#fce6f3","color-base-pink-100":"#fad5eb","color-base-pink-150":"#f7bbdd","color-base-pink-200":"#f2a1cf","color-base-pink-300":"#ec78ba","color-base-pink-400":"#e755a8","color-base-pink-450":"#d94397","color-base-pink-500":"#cc2f89","color-base-pink-600":"#c41579","color-base-pink-700":"#b4136e","color-base-pink-800":"#a01163","color-base-pink-900":"#8a0f55","color-base-purple-50":"#f4e2f6","color-base-purple-100":"#eccff0","color-base-purple-150":"#dab2e0","color-base-purple-200":"#c792cf","color-base-purple-300":"#ab66b4","color-base-purple-400":"#93459e","color-base-purple-450":"#823591","color-base-purple-500":"#772386","color-base-purple-600":"#6c127b","color-base-purple-700":"#5e106b","color-base-purple-800":"#530d5e","color-base-purple-900":"#450b4f","color-base-brown-50":"#f2eae4","color-base-brown-100":"#eadcd2","color-base-brown-150":"#d8c4b3","color-base-brown-200":"#bca38d","color-base-brown-300":"#a08165","color-base-brown-400":"#8b6747","color-base-brown-450":"#755438","color-base-brown-500":"#65472b","color-base-brown-600":"#593b20","color-base-brown-700":"#4f351d","color-base-brown-800":"#462f1b","color-base-brown-900":"#3f2915","color-base-grey-50":"#f9f9f9","color-base-grey-100":"#f3f3f3","color-base-grey-150":"#eeeeee","color-base-grey-200":"#e5e5e5","color-base-grey-300":"#d9d9d9","color-base-grey-400":"#cccccc","color-base-grey-450":"#bbbbbb","color-base-grey-500":"#aaaaaa","color-base-grey-600":"#999999","color-base-grey-700":"#777777","color-base-grey-800":"#666666","color-base-grey-900":"#555555","color-base-white":"#ffffff","color-base-black":"#111111","color-font-base":"#111111","color-font-secondary":"#555555","color-font-tertiary":"#999999","color-font-warn":"#555555","color-font-suggest":"#bf8800","color-font-error":"#cc0017","size-font-tiny":"12px","size-font-small":"13px","size-font-medium":"16px","size-font-large":"20px","size-font-xl":"24px","size-font-xxl":"32px","size-font-xxxl":"48px","size-font-base":"16px","font-family-base":'"Segoe UI", Tahoma, Geneva, Verdana, sans-serif',"time-transition-short":"275ms","time-transition-base":"300ms","time-transition-long":"600ms","time-transition-xl":"1000ms"},Gn=[c["color-base-red-50"],c["color-base-red-100"],c["color-base-red-150"],c["color-base-red-200"],c["color-base-red-300"],c["color-base-red-400"],c["color-base-red-500"],c["color-base-red-600"],c["color-base-red-700"],c["color-base-red-800"],c["color-base-red-900"],c["color-base-orange-50"],c["color-base-orange-100"],c["color-base-orange-150"],c["color-base-orange-200"],c["color-base-orange-300"],c["color-base-orange-400"],c["color-base-orange-500"],c["color-base-orange-600"],c["color-base-orange-700"],c["color-base-orange-800"],c["color-base-orange-900"],c["color-base-yellow-50"],c["color-base-yellow-100"],c["color-base-yellow-150"],c["color-base-yellow-200"],c["color-base-yellow-300"],c["color-base-yellow-400"],c["color-base-yellow-500"],c["color-base-yellow-600"],c["color-base-yellow-700"],c["color-base-yellow-800"],c["color-base-yellow-900"],c["color-base-green-50"],c["color-base-green-100"],c["color-base-green-150"],c["color-base-green-200"],c["color-base-green-300"],c["color-base-green-400"],c["color-base-green-500"],c["color-base-green-600"],c["color-base-green-700"],c["color-base-green-800"],c["color-base-green-900"],c["color-base-dark-green-50"],c["color-base-dark-green-100"],c["color-base-dark-green-150"],c["color-base-dark-green-200"],c["color-base-dark-green-300"],c["color-base-dark-green-400"],c["color-base-dark-green-500"],c["color-base-dark-green-600"],c["color-base-dark-green-700"],c["color-base-dark-green-800"],c["color-base-dark-green-900"],c["color-base-cyan-50"],c["color-base-cyan-100"],c["color-base-cyan-150"],c["color-base-cyan-200"],c["color-base-cyan-300"],c["color-base-cyan-400"],c["color-base-cyan-500"],c["color-base-cyan-600"],c["color-base-cyan-700"],c["color-base-cyan-800"],c["color-base-cyan-900"],c["color-base-blue-50"],c["color-base-blue-100"],c["color-base-blue-150"],c["color-base-blue-200"],c["color-base-blue-300"],c["color-base-blue-400"],c["color-base-blue-500"],c["color-base-blue-600"],c["color-base-blue-700"],c["color-base-blue-800"],c["color-base-blue-900"],c["color-base-dark-blue-50"],c["color-base-dark-blue-100"],c["color-base-dark-blue-150"],c["color-base-dark-blue-200"],c["color-base-dark-blue-300"],c["color-base-dark-blue-400"],c["color-base-dark-blue-500"],c["color-base-dark-blue-600"],c["color-base-dark-blue-700"],c["color-base-dark-blue-800"],c["color-base-dark-blue-900"],c["color-base-pink-50"],c["color-base-pink-100"],c["color-base-pink-150"],c["color-base-pink-200"],c["color-base-pink-300"],c["color-base-pink-400"],c["color-base-pink-500"],c["color-base-pink-600"],c["color-base-pink-700"],c["color-base-pink-800"],c["color-base-pink-900"],c["color-base-purple-50"],c["color-base-purple-100"],c["color-base-purple-150"],c["color-base-purple-200"],c["color-base-purple-300"],c["color-base-purple-400"],c["color-base-purple-500"],c["color-base-purple-600"],c["color-base-purple-700"],c["color-base-purple-800"],c["color-base-purple-900"],c["color-base-brown-50"],c["color-base-brown-100"],c["color-base-brown-150"],c["color-base-brown-200"],c["color-base-brown-300"],c["color-base-brown-400"],c["color-base-brown-500"],c["color-base-brown-600"],c["color-base-brown-700"],c["color-base-brown-800"],c["color-base-brown-900"],c["color-base-grey-50"],c["color-base-grey-100"],c["color-base-grey-150"],c["color-base-grey-200"],c["color-base-grey-300"],c["color-base-grey-400"],c["color-base-grey-500"],c["color-base-grey-600"],c["color-base-grey-700"],c["color-base-grey-800"],c["color-base-grey-900"]],Ve=class Ve extends Hn{constructor(){super(...arguments),this.keyDownListener=e=>{if(e.defaultPrevented)return;let t=!0;const r=this.colorList.indexOf(this.color);switch(e.key){case"Esc":case"Escape":this.colorWhenOpen&&(this.color=this.colorWhenOpen),this.close();break;case"Up":case"ArrowUp":r>0?this.color=this.colorList[r-1]:this.color=this.colorList[this.colorList.length-1];break;case"Down":case"ArrowDown":r<this.colorList.length-1?this.color=this.colorList[r+1]:this.color=this.colorList[0];break;case"Left":case"ArrowLeft":{let s;r===0?s=this.colorList.length-1:(s=r-this.colorNumberInColumn,s<0&&(s=this.colorList.length+s,s%this.colorNumberInColumn>0&&s--)),this.color=this.colorList[s];break}case"Right":case"ArrowRight":{let s;r===this.colorList.length-1?s=0:(s=r+this.colorNumberInColumn,s>=this.colorList.length&&(s=s-this.colorList.length,s<this.colorNumberInColumn&&s++)),this.color=this.colorList[s];break}case"Enter":this.close(),this.dispatchValueChange();break;default:t=!1;return}t&&e.preventDefault()},this.modalityListener=e=>{this.contains(e.target)||this.close()},this.scrollListener=()=>{this.restoreScrollPosition()}}is(){return Ve.ID}get color(){return this.getAttribute("color")}set color(e){if(e){if(this.setAttribute("color",e),this.shadowRoot){this.svg.style.fill=e;const t=this.colorList.indexOf(e);t>=0?this.selectedColorElement=this.colorPalette.children[t]:this.selectedColorElement=null}}else this.removeAttribute("color"),this.svg.style.fill="",this.selectedColorElement=null}get colorList(){return this._colorList||Gn}set colorList(e){this._colorList=e,this.shadowRoot&&this.updatePalette()}get columnCount(){return Number(this.getAttribute("columncount"))||12}set columnCount(e){e?this.setAttribute("columncount",`${e}`):this.removeAttribute("columncount")}get disabled(){return this.getAttribute("aria-disabled")=="true"}set disabled(e){this.setAttribute("aria-disabled",e.toString())}get colorSize(){return Number(this.getAttribute("colorsize"))||20}set colorSize(e){e?this.setAttribute("colorsize",`${e}`):this.removeAttribute("colorsize")}template(){const e=document.createElement("template");return e.innerHTML=Wn,e}static get observedAttributes(){return["colorsize","columncount"]}connectedCallback(){super.connectedCallback(),this.colorPalette||(this.colorPalette=this.shadowRoot.querySelector(".color-palette"),this.picker=this.shadowRoot.querySelector(".picker"),this.ripple=this.shadowRoot.querySelector(".ripple"),this.svg=this.shadowRoot.querySelector("svg"),this.color&&(this.svg.style.fill=this.color),this.picker.addEventListener("pointerdown",e=>{e.stopPropagation(),this.colorPalette.classList.contains("opened")?this.close():(this.updatePalettePosition(),this.open())}),this.addEventListener("keydown",e=>{e.key==="Enter"&&(this.open(),e.preventDefault())}),this.updatePalette()),this.hasAttribute("tabIndex")||(this.tabIndex=0)}attributeChangedCallback(){this.colorPalette&&this.updatePalette()}updatePalette(){for(;this.colorPalette.firstChild;)this.colorPalette.removeChild(this.colorPalette.firstChild);this.colorNumberInColumn=Math.ceil(this.colorList.length/this.columnCount),this.colorPalette.style.height=`${this.colorNumberInColumn*this.colorSize}px`,this.colorPalette.style.width=`${this.colorSize*this.columnCount}px`,this.colorPalette.appendChild(this.createColorPaletteFragment())}createColorPaletteFragment(){const e=document.createDocumentFragment(),t=this.color;for(const r of this.colorList){const s=document.createElement("div");s.classList.add("color"),s.style.backgroundColor=r,s.style.width=`${this.colorSize}px`,s.style.height=`${this.colorSize}px`,s.addEventListener("pointerdown",()=>{this.color=r,this.close(),this.dispatchValueChange()}),t===r&&(this.selectedColorElement=s,this.selectedColorElement.classList.add("active-color")),e.appendChild(s)}return e}get selectedColorElement(){return this._selectedColorElement}set selectedColorElement(e){this._selectedColorElement&&this._selectedColorElement.classList.remove("active-color"),this._selectedColorElement=e,this._selectedColorElement&&this._selectedColorElement.classList.add("active-color")}open(){this.disabled||(this.colorPalette.classList.add("opened"),this.ripple.classList.add("active"),this.colorWhenOpen=this.color,this.saveScrollPosition(),window.addEventListener("keydown",this.keyDownListener,{capture:!0}),window.addEventListener("pointerdown",this.modalityListener,{capture:!0}),window.addEventListener("scroll",this.scrollListener,{capture:!0}))}close(){this.colorPalette.classList.remove("opened"),this.ripple.classList.remove("active"),window.removeEventListener("keydown",this.keyDownListener,{capture:!0}),window.removeEventListener("pointerdown",this.modalityListener,{capture:!0}),window.removeEventListener("scroll",this.scrollListener,{capture:!0})}saveScrollPosition(){document.scrollingElement?(this._scrollTop=document.scrollingElement.scrollTop,this._scrollLeft=document.scrollingElement.scrollLeft):(this._scrollTop=Math.max(document.documentElement.scrollTop,document.body.scrollTop),this._scrollLeft=Math.max(document.documentElement.scrollLeft,document.body.scrollLeft))}restoreScrollPosition(){document.scrollingElement?(document.scrollingElement.scrollTop=this._scrollTop,document.scrollingElement.scrollLeft=this._scrollLeft):(document.documentElement.scrollTop=document.body.scrollTop=this._scrollTop,document.documentElement.scrollLeft=document.body.scrollLeft=this._scrollLeft)}updatePalettePosition(){const e=this.getBoundingClientRect();e.left+this.colorPalette.offsetWidth>this.scrollingElementClientWidth?this.colorPalette.style.left=`${this.scrollingElementClientWidth-this.colorPalette.offsetWidth}px`:this.colorPalette.style.left=`${e.left}px`,e.top+this.colorPalette.offsetHeight>this.scrollingElementClientHeight?this.colorPalette.style.top=`${this.scrollingElementClientHeight-this.colorPalette.offsetHeight}px`:this.colorPalette.style.top=`${e.top}px`}get scrollingElementClientHeight(){return document.scrollingElement?document.scrollingElement.clientHeight:Math.max(document.documentElement.clientHeight,document.body.clientHeight)}get scrollingElementClientWidth(){return document.scrollingElement?document.scrollingElement.clientWidth:Math.max(document.documentElement.clientWidth,document.body.clientWidth)}dispatchValueChange(){this.dispatchEvent(new CustomEvent("value-change",{detail:this.color}))}};Ve.ID="sd-swatch-picker";let Be=Ve;customElements.define(Be.ID,Be);function xr(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}function Zn(n){if(n.__esModule)return n;var e=n.default;if(typeof e=="function"){var t=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(n).forEach(function(r){var s=Object.getOwnPropertyDescriptor(n,r);Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:function(){return n[r]}})}),t}var At={exports:{}},_=String,vr=function(){return{isColorSupported:!1,reset:_,bold:_,dim:_,italic:_,underline:_,inverse:_,hidden:_,strikethrough:_,black:_,red:_,green:_,yellow:_,blue:_,magenta:_,cyan:_,white:_,gray:_,bgBlack:_,bgRed:_,bgGreen:_,bgYellow:_,bgBlue:_,bgMagenta:_,bgCyan:_,bgWhite:_}};At.exports=vr();At.exports.createColors=vr;var Vn=At.exports;const qn={},Kn=Object.freeze(Object.defineProperty({__proto__:null,default:qn},Symbol.toStringTag,{value:"Module"})),z=Zn(Kn);let qt=Vn,Kt=z,dt=class Er extends Error{constructor(e,t,r,s,o,i){super(e),this.name="CssSyntaxError",this.reason=e,o&&(this.file=o),s&&(this.source=s),i&&(this.plugin=i),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,Er)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=qt.isColorSupported),Kt&&e&&(t=Kt(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),o=Math.min(this.line+2,r.length),i=String(o).length,l,a;if(e){let{bold:u,gray:f,red:y}=qt.createColors(!0);l=m=>u(y(m)),a=m=>f(m)}else l=a=u=>u;return r.slice(s,o).map((u,f)=>{let y=s+1+f,m=" "+(" "+y).slice(-i)+" | ";if(y===this.line){let A=a(m.replace(/\d/g," "))+u.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+a(m)+u+`
|
|
158
158
|
`+A+l("^")}return" "+a(m)+u}).join(`
|
|
159
159
|
`)}toString(){let e=this.showSourceCode();return e&&(e=`
|
|
160
160
|
|
|
@@ -170,19 +170,19 @@ createExample("Disabled picker", 20, "#2b63ba").disabled = true;
|
|
|
170
170
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeDecl"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeDecl(e,t){let r;return e.walkDecls(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
171
171
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeRule"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeOpen(e){let t;return e.walk(r=>{if(r.type!=="decl"&&(t=r.raws.between,typeof t<"u"))return!1}),t}rawBeforeRule(e){let t;return e.walk(r=>{if(r.nodes&&(r.parent!==e||e.first!==r)&&typeof r.raws.before<"u")return t=r.raws.before,t.includes(`
|
|
172
172
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawColon(e){let t;return e.walkDecls(r=>{if(typeof r.raws.between<"u")return t=r.raws.between.replace(/[^\s:]/g,""),!1}),t}rawEmptyBody(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length===0&&(t=r.raws.after,typeof t<"u"))return!1}),t}rawIndent(e){if(e.raws.indent)return e.raws.indent;let t;return e.walk(r=>{let s=r.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof r.raws.before<"u"){let o=r.raws.before.split(`
|
|
173
|
-
`);return t=o[o.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}};var kr=pt;pt.default=pt;let Xn=kr;function gt(n,e){new Xn(e).stringify(n)}var
|
|
174
|
-
`?(s=1,o+=1):s+=1;return{column:s,line:o}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),o=s.indexOf(e.word);o!==-1&&(t=this.positionInside(o,s),r=this.positionInside(o+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:e.endIndex?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new es().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let o=0;for(let i in this){if(!Object.prototype.hasOwnProperty.call(this,i)||i==="parent"||i==="proxyCache")continue;let l=this[i];if(Array.isArray(l))r[i]=l.map(a=>typeof a=="object"&&a.toJSON?a.toJSON(null,t):a);else if(typeof l=="object"&&l.toJSON)r[i]=l.toJSON(null,t);else if(i==="source"){let a=t.get(l.input);a==null&&(a=o,t.set(l.input,o),o++),r[i]={end:l.end,inputId:a,start:l.start}}else r[i]=l}return s&&(r.inputs=[...t.keys()].map(i=>i.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=ts){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let o in r)s[o]=r[o];return e.warn(t,s)}get proxyOf(){return this}};var
|
|
173
|
+
`);return t=o[o.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}};var kr=pt;pt.default=pt;let Xn=kr;function gt(n,e){new Xn(e).stringify(n)}var qe=gt;gt.default=gt;let{isClean:_e,my:Qn}=xe,Yn=Rt,es=kr,ts=qe;function mt(n,e){let t=new n.constructor;for(let r in n){if(!Object.prototype.hasOwnProperty.call(n,r)||r==="proxyCache")continue;let s=n[r],o=typeof s;r==="parent"&&o==="object"?e&&(t[r]=e):r==="source"?t[r]=s:Array.isArray(s)?t[r]=s.map(i=>mt(i,t)):(o==="object"&&s!==null&&(s=mt(s)),t[r]=s)}return t}let bt=class{constructor(e={}){this.raws={},this[_e]=!1,this[Qn]=!0;for(let t in e)if(t==="nodes"){this.nodes=[];for(let r of e[t])typeof r.clone=="function"?this.append(r.clone()):this.append(r)}else this[t]=e[t]}addToError(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){let t=this.source;e.stack=e.stack.replace(/\n\s{4}at /,`$&${t.input.from}:${t.start.line}:${t.start.column}$&`)}return e}after(e){return this.parent.insertAfter(this,e),this}assign(e={}){for(let t in e)this[t]=e[t];return this}before(e){return this.parent.insertBefore(this,e),this}cleanRaws(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between}clone(e={}){let t=mt(this);for(let r in e)t[r]=e[r];return t}cloneAfter(e={}){let t=this.clone(e);return this.parent.insertAfter(this,t),t}cloneBefore(e={}){let t=this.clone(e);return this.parent.insertBefore(this,t),t}error(e,t={}){if(this.source){let{end:r,start:s}=this.rangeBy(t);return this.source.input.error(e,{column:s.column,line:s.line},{column:r.column,line:r.line},t)}return new Yn(e)}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:t==="root"?()=>e.root().toProxy():e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="prop"||t==="value"||t==="name"||t==="params"||t==="important"||t==="text")&&e.markDirty()),!0}}}markDirty(){if(this[_e]){this[_e]=!1;let e=this;for(;e=e.parent;)e[_e]=!1}}next(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e+1]}positionBy(e,t){let r=this.source.start;if(e.index)r=this.positionInside(e.index,t);else if(e.word){t=this.toString();let s=t.indexOf(e.word);s!==-1&&(r=this.positionInside(s,t))}return r}positionInside(e,t){let r=t||this.toString(),s=this.source.start.column,o=this.source.start.line;for(let i=0;i<e;i++)r[i]===`
|
|
174
|
+
`?(s=1,o+=1):s+=1;return{column:s,line:o}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),o=s.indexOf(e.word);o!==-1&&(t=this.positionInside(o,s),r=this.positionInside(o+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:e.endIndex?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new es().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let o=0;for(let i in this){if(!Object.prototype.hasOwnProperty.call(this,i)||i==="parent"||i==="proxyCache")continue;let l=this[i];if(Array.isArray(l))r[i]=l.map(a=>typeof a=="object"&&a.toJSON?a.toJSON(null,t):a);else if(typeof l=="object"&&l.toJSON)r[i]=l.toJSON(null,t);else if(i==="source"){let a=t.get(l.input);a==null&&(a=o,t.set(l.input,o),o++),r[i]={end:l.end,inputId:a,start:l.start}}else r[i]=l}return s&&(r.inputs=[...t.keys()].map(i=>i.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=ts){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let o in r)s[o]=r[o];return e.warn(t,s)}get proxyOf(){return this}};var Ke=bt;bt.default=bt;let rs=Ke,yt=class extends rs{constructor(e){e&&typeof e.value<"u"&&typeof e.value!="string"&&(e={...e,value:String(e.value)}),super(e),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}};var Je=yt;yt.default=yt;let ns="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",ss=(n,e=21)=>(t=e)=>{let r="",s=t;for(;s--;)r+=n[Math.random()*n.length|0];return r},is=(n=21)=>{let e="",t=n;for(;t--;)e+=ns[Math.random()*64|0];return e};var os={nanoid:is,customAlphabet:ss};let{SourceMapConsumer:Xt,SourceMapGenerator:Qt}=z,{existsSync:ls,readFileSync:as}=z,{dirname:at,join:cs}=z;function us(n){return Buffer?Buffer.from(n,"base64").toString():window.atob(n)}let wt=class{constructor(e,t){if(t.map===!1)return;this.loadAnnotation(e),this.inline=this.startWith(this.annotation,"data:");let r=t.map?t.map.prev:void 0,s=this.loadMap(t.from,r);!this.mapFile&&t.from&&(this.mapFile=t.from),this.mapFile&&(this.root=at(this.mapFile)),s&&(this.text=s)}consumer(){return this.consumerCache||(this.consumerCache=new Xt(this.text)),this.consumerCache}decodeInline(e){let t=/^data:application\/json;charset=utf-?8;base64,/,r=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,o=/^data:application\/json,/;if(s.test(e)||o.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(t.test(e)||r.test(e))return us(e.substr(RegExp.lastMatch.length));let i=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+i)}getAnnotationURL(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(e){return typeof e!="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)}loadAnnotation(e){let t=e.match(/\/\*\s*# sourceMappingURL=/gm);if(!t)return;let r=e.lastIndexOf(t.pop()),s=e.indexOf("*/",r);r>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(r,s)))}loadFile(e){if(this.root=at(e),ls(e))return this.mapFile=e,as(e,"utf-8").toString().trim()}loadMap(e,t){if(t===!1)return!1;if(t){if(typeof t=="string")return t;if(typeof t=="function"){let r=t(e);if(r){let s=this.loadFile(r);if(!s)throw new Error("Unable to load previous source map: "+r.toString());return s}}else{if(t instanceof Xt)return Qt.fromSourceMap(t).toString();if(t instanceof Qt)return t.toString();if(this.isMap(t))return JSON.stringify(t);throw new Error("Unsupported previous source map format: "+t.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let r=this.annotation;return e&&(r=cs(at(e),r)),this.loadFile(r)}}}startWith(e,t){return e?e.substr(0,t.length)===t:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}};var Sr=wt;wt.default=wt;let{SourceMapConsumer:hs,SourceMapGenerator:fs}=z,{fileURLToPath:Yt,pathToFileURL:Oe}=z,{isAbsolute:xt,resolve:vt}=z,{nanoid:ds}=os,ct=z,er=Rt,ps=Sr,ut=Symbol("fromOffsetCache"),gs=!!(hs&&fs),tr=!!(vt&&xt),Ue=class{constructor(e,t={}){if(e===null||typeof e>"u"||typeof e=="object"&&!e.toString)throw new Error(`PostCSS received ${e} instead of CSS string`);if(this.css=e.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,t.from&&(!tr||/^\w+:\/\//.test(t.from)||xt(t.from)?this.file=t.from:this.file=vt(t.from)),tr&&gs){let r=new ps(this.css,t);if(r.text){this.map=r;let s=r.consumer().file;!this.file&&s&&(this.file=this.mapResolve(s))}}this.file||(this.id="<input css "+ds(6)+">"),this.map&&(this.map.file=this.from)}error(e,t,r,s={}){let o,i,l;if(t&&typeof t=="object"){let u=t,f=r;if(typeof u.offset=="number"){let y=this.fromOffset(u.offset);t=y.line,r=y.col}else t=u.line,r=u.column;if(typeof f.offset=="number"){let y=this.fromOffset(f.offset);i=y.line,l=y.col}else i=f.line,l=f.column}else if(!r){let u=this.fromOffset(t);t=u.line,r=u.col}let a=this.origin(t,r,i,l);return a?o=new er(e,a.endLine===void 0?a.line:{column:a.column,line:a.line},a.endLine===void 0?a.column:{column:a.endColumn,line:a.endLine},a.source,a.file,s.plugin):o=new er(e,i===void 0?t:{column:r,line:t},i===void 0?r:{column:l,line:i},this.css,this.file,s.plugin),o.input={column:r,endColumn:l,endLine:i,line:t,source:this.css},this.file&&(Oe&&(o.input.url=Oe(this.file).toString()),o.input.file=this.file),o}fromOffset(e){let t,r;if(this[ut])r=this[ut];else{let o=this.css.split(`
|
|
175
175
|
`);r=new Array(o.length);let i=0;for(let l=0,a=o.length;l<a;l++)r[l]=i,i+=o[l].length+1;this[ut]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let o=r.length-2,i;for(;s<o;)if(i=s+(o-s>>1),e<r[i])o=i-1;else if(e>=r[i+1])s=i+1;else{s=i;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:vt(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let o=this.map.consumer(),i=o.originalPositionFor({column:t,line:e});if(!i.source)return!1;let l;typeof r=="number"&&(l=o.originalPositionFor({column:s,line:r}));let a;xt(i.source)?a=Oe(i.source):a=new URL(i.source,this.map.consumer().sourceRoot||Oe(this.map.mapFile));let u={column:i.column,endColumn:l&&l.column,endLine:l&&l.line,line:i.line,url:a.toString()};if(a.protocol==="file:")if(Yt)u.file=Yt(a);else throw new Error("file: protocol is not available in this PostCSS build");let f=o.sourceContentFor(i.source);return f&&(u.source=f),u}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}};var Xe=Ue;Ue.default=Ue;ct&&ct.registerInput&&ct.registerInput(Ue);let{SourceMapConsumer:Cr,SourceMapGenerator:ze}=z,{dirname:De,relative:_r,resolve:Or,sep:Ar}=z,{pathToFileURL:rr}=z,ms=Xe,bs=!!(Cr&&ze),ys=!!(De&&Or&&_r&&Ar),ws=class{constructor(e,t,r,s){this.stringify=e,this.mapOpts=r.map||{},this.root=t,this.opts=r,this.css=s,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";let t=`
|
|
176
176
|
`;this.css.includes(`\r
|
|
177
177
|
`)&&(t=`\r
|
|
178
178
|
`),this.css+=t+"/*# sourceMappingURL="+e+" */"}applyPrevMaps(){for(let e of this.previous()){let t=this.toUrl(this.path(e.file)),r=e.root||De(e.file),s;this.mapOpts.sourcesContent===!1?(s=new Cr(e.text),s.sourcesContent&&(s.sourcesContent=s.sourcesContent.map(()=>null))):s=e.consumer(),this.map.applySourceMap(s,t,this.toUrl(this.path(r)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let e;for(let t=this.root.nodes.length-1;t>=0;t--)e=this.root.nodes[t],e.type==="comment"&&e.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(t)}else this.css&&(this.css=this.css.replace(/(\n)?\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),ys&&bs&&this.isMap())return this.generateMap();{let e="";return this.stringify(this.root,t=>{e+=t}),[e]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let e=this.previous()[0].consumer();e.file=this.outputFile(),this.map=ze.fromSourceMap(e)}else this.map=new ze({file:this.outputFile()}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new ze({file:this.outputFile()});let e=1,t=1,r="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},o,i;this.stringify(this.root,(l,a,u)=>{if(this.css+=l,a&&u!=="end"&&(s.generated.line=e,s.generated.column=t-1,a.source&&a.source.start?(s.source=this.sourcePath(a),s.original.line=a.source.start.line,s.original.column=a.source.start.column-1,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,this.map.addMapping(s))),o=l.match(/\n/g),o?(e+=o.length,i=l.lastIndexOf(`
|
|
179
|
-
`),t=l.length-i):t+=l.length,a&&u!=="start"){let f=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==f.last||f.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?De(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=De(Or(r,this.mapOpts.annotation)));let s=_r(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new ms(this.css,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(rr){let r=rr(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;Ar==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}};var Rr=ws;let xs=qe,Et=class extends xs{constructor(e){super(e),this.type="comment"}};var Qe=Et;Et.default=Et;let{isClean:Lr,my:Nr}=xe,Pr=Je,Mr=Qe,vs=qe,Tr,Lt,Nt,Ir;function $r(n){return n.map(e=>(e.nodes&&(e.nodes=$r(e.nodes)),delete e.source,e))}function jr(n){if(n[Lr]=!1,n.proxyOf.nodes)for(let e of n.proxyOf.nodes)jr(e)}let V=class zr extends vs{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(o,i)=>s(o.toProxy(),i):s)):t==="every"||t==="some"?r=>e[t]((s,...o)=>r(s.toProxy(),...o)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let i of s)this.proxyOf.nodes.splice(r+1,0,i);let o;for(let i in this.indexes)o=this.indexes[i],r<o&&(this.indexes[i]=o+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,o=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of o)this.proxyOf.nodes.splice(r,0,l);let i;for(let l in this.indexes)i=this.indexes[l],r<=i&&(this.indexes[l]=i+o.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=$r(Tr(e).nodes);else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new Pr(e)]}else if(e.selector)e=[new Lt(e)];else if(e.name)e=[new Nt(e)];else if(e.text)e=[new Mr(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Nr]||zr.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[Lr]&&jr(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(o){throw t.addToError(o)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}};V.registerParse=n=>{Tr=n};V.registerRule=n=>{Lt=n};V.registerAtRule=n=>{Nt=n};V.registerRoot=n=>{Ir=n};var te=V;V.default=V;V.rebuild=n=>{n.type==="atrule"?Object.setPrototypeOf(n,Nt.prototype):n.type==="rule"?Object.setPrototypeOf(n,Lt.prototype):n.type==="decl"?Object.setPrototypeOf(n,Pr.prototype):n.type==="comment"?Object.setPrototypeOf(n,Mr.prototype):n.type==="root"&&Object.setPrototypeOf(n,Ir.prototype),n[Nr]=!0,n.nodes&&n.nodes.forEach(e=>{V.rebuild(e)})};let Es=te,Dr,Br,pe=class extends Es{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Dr(new Br,this,e).stringify()}};pe.registerLazyResult=n=>{Dr=n};pe.registerProcessor=n=>{Br=n};var Pt=pe;pe.default=pe;let kt=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}};var Ur=kt;kt.default=kt;let ks=Ur,St=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new ks(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}};var Mt=St;St.default=St;const ht=39,nr=34,Ae=92,sr=47,Re=10,ue=32,Le=12,Ne=9,Pe=13,Ss=91,Cs=93,_s=40,Os=41,As=123,Rs=125,Ls=59,Ns=42,Ps=58,Ms=64,Me=/[\t\n\f\r "#'()/;[\\\]{}]/g,Te=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,Ts=/.[\r\n"'(/\\]/,ir=/[\da-f]/i;var Is=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,o,i,l,a,u,f,y,m,A,L,$=r.length,b=0,H=[],W=[];function J(){return b}function j(D){throw e.error("Unclosed "+D,b)}function G(){return W.length===0&&b>=$}function ce(D){if(W.length)return W.pop();if(b>=$)return;let M=D?D.ignoreUnclosed:!1;switch(o=r.charCodeAt(b),o){case Re:case ue:case Ne:case Pe:case Le:{i=b;do i+=1,o=r.charCodeAt(i);while(o===ue||o===Re||o===Ne||o===Pe||o===Le);L=["space",r.slice(b,i)],b=i-1;break}case Ss:case Cs:case As:case Rs:case Ps:case Ls:case Os:{let X=String.fromCharCode(o);L=[X,X,b];break}case _s:{if(m=H.length?H.pop()[1]:"",A=r.charCodeAt(b+1),m==="url"&&A!==ht&&A!==nr&&A!==ue&&A!==Re&&A!==Ne&&A!==Le&&A!==Pe){i=b;do{if(f=!1,i=r.indexOf(")",i+1),i===-1)if(s||M){i=b;break}else j("bracket");for(y=i;r.charCodeAt(y-1)===Ae;)y-=1,f=!f}while(f);L=["brackets",r.slice(b,i+1),b,i],b=i}else i=r.indexOf(")",b+1),a=r.slice(b,i+1),i===-1||Ts.test(a)?L=["(","(",b]:(L=["brackets",a,b,i],b=i);break}case ht:case nr:{l=o===ht?"'":'"',i=b;do{if(f=!1,i=r.indexOf(l,i+1),i===-1)if(s||M){i=b+1;break}else j("string");for(y=i;r.charCodeAt(y-1)===Ae;)y-=1,f=!f}while(f);L=["string",r.slice(b,i+1),b,i],b=i;break}case Ms:{Me.lastIndex=b+1,Me.test(r),Me.lastIndex===0?i=r.length-1:i=Me.lastIndex-2,L=["at-word",r.slice(b,i+1),b,i],b=i;break}case Ae:{for(i=b,u=!0;r.charCodeAt(i+1)===Ae;)i+=1,u=!u;if(o=r.charCodeAt(i+1),u&&o!==sr&&o!==ue&&o!==Re&&o!==Ne&&o!==Pe&&o!==Le&&(i+=1,ir.test(r.charAt(i)))){for(;ir.test(r.charAt(i+1));)i+=1;r.charCodeAt(i+1)===ue&&(i+=1)}L=["word",r.slice(b,i+1),b,i],b=i;break}default:{o===sr&&r.charCodeAt(b+1)===Ns?(i=r.indexOf("*/",b+2)+1,i===0&&(s||M?i=r.length:j("comment")),L=["comment",r.slice(b,i+1),b,i],b=i):(Te.lastIndex=b+1,Te.test(r),Te.lastIndex===0?i=r.length-1:i=Te.lastIndex-2,L=["word",r.slice(b,i+1),b,i],H.push(L),b=i);break}}return b++,L}function ne(D){W.push(D)}return{back:ne,endOfFile:G,nextToken:ce,position:J}};let Fr=te,Fe=class extends Fr{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}};var Tt=Fe;Fe.default=Fe;Fr.registerAtRule(Fe);let Hr=te,Wr,Gr,ie=class extends Hr{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let o of s)o.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new Wr(new Gr,this,e).stringify()}};ie.registerLazyResult=n=>{Wr=n};ie.registerProcessor=n=>{Gr=n};var ve=ie;ie.default=ie;Hr.registerRoot(ie);let ge={comma(n){return ge.split(n,[","],!0)},space(n){let e=[" ",`
|
|
180
|
-
`," "];return ge.split(n,e)},split(n,e,t){let r=[],s="",o=!1,i=0,l=!1,a="",u=!1;for(let f of n)u?u=!1:f==="\\"?u=!0:l?f===a&&(l=!1):f==='"'||f==="'"?(l=!0,a=f):f==="("?i+=1:f===")"?i>0&&(i-=1):i===0&&e.includes(f)&&(o=!0),o?(s!==""&&r.push(s.trim()),s="",o=!1):s+=f;return(t||s!=="")&&r.push(s.trim()),r}};var Zr=ge;ge.default=ge;let Vr=te,$s=Zr,He=class extends Vr{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return $s.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}};var It=He;He.default=He;Vr.registerRule(He);let js=Je,zs=Is,Ds=Qe,Bs=Tt,Us=ve,or=It;const lr={empty:!0,space:!0};function Fs(n){for(let e=n.length-1;e>=0;e--){let t=n[e],r=t[3]||t[2];if(r)return r}}let Hs=class{constructor(e){this.input=e,this.root=new Us,this.current=this.root,this.spaces="",this.semicolon=!1,this.customProperty=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new Bs;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,o,i=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(o=a.length-1,s=a[o];s&&s[0]==="space";)s=a[--o];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){i=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),i&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let o=t-1;o>=0&&(s=e[o],!(s[0]!=="space"&&(r+=1,r===2)));o--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,o;for(let[i,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!o)this.doubleColon(r);else{if(o[0]==="word"&&o[1]==="progid")continue;return i}o=r}return!1}comment(e){let t=new Ds;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=zs(this.input)}decl(e,t){let r=new js;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||Fs(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let o;for(;e.length;)if(o=e.shift(),o[0]===":"){r.raws.between+=o[1];break}else o[0]==="word"&&/\w/.test(o[1])&&this.unknownWord([o]),r.raws.between+=o[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let i=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)i.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(o=e[u],o[1].toLowerCase()==="!important"){r.important=!0;let f=this.stringFrom(e,u);f=this.spacesFromEnd(e)+f,f!==" !important"&&(r.raws.important=f);break}else if(o[1].toLowerCase()==="important"){let f=e.slice(0),y="";for(let m=u;m>0;m--){let A=f[m][0];if(y.trim().indexOf("!")===0&&A!=="space")break;y=f.pop()[1]+y}y.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=y,e=f)}if(o[0]!=="space"&&o[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=i.map(u=>u[1]).join(""),i=[]),this.raw(r,"value",i.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new or;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,o=null,i=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")o||(o=u),i.push(r==="("?")":"]");else if(l&&s&&r==="{")o||(o=u),i.push("}");else if(i.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===i[i.length-1]&&(i.pop(),i.length===0&&(o=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),i.length>0&&this.unclosedBracket(o),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let o,i,l=r.length,a="",u=!0,f,y;for(let m=0;m<l;m+=1)o=r[m],i=o[0],i==="space"&&m===l-1&&!s?u=!1:i==="comment"?(y=r[m-1]?r[m-1][0]:"empty",f=r[m+1]?r[m+1][0]:"empty",!lr[y]&&!lr[f]?a.slice(-1)===","?u=!1:a+=o[1]:u=!1):a+=o[1];if(!u){let m=r.reduce((A,L)=>A+L[1],"");e.raws[t]={raw:m,value:a}}e[t]=a}rule(e){e.pop();let t=new or;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}};var Ws=Hs;let Gs=te,Zs=Ws,Vs=Xe;function We(n,e){let t=new Vs(n,e),r=new Zs(t);try{r.parse()}catch(s){throw s}return r.root}var $t=We;We.default=We;Gs.registerParse(We);let{isClean:F,my:Ks}=xe,qs=Rr,Js=Ke,Xs=te,Qs=Pt,ar=Mt,Ys=$t,ei=ve;const ti={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},ri={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},ni={Once:!0,postcssPlugin:!0,prepare:!0},oe=0;function he(n){return typeof n=="object"&&typeof n.then=="function"}function Kr(n){let e=!1,t=ti[n.type];return n.type==="decl"?e=n.prop.toLowerCase():n.type==="atrule"&&(e=n.name.toLowerCase()),e&&n.append?[t,t+"-"+e,oe,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:n.append?[t,oe,t+"Exit"]:[t,t+"Exit"]}function cr(n){let e;return n.type==="document"?e=["Document",oe,"DocumentExit"]:n.type==="root"?e=["Root",oe,"RootExit"]:e=Kr(n),{eventIndex:0,events:e,iterator:0,node:n,visitorIndex:0,visitors:[]}}function Ct(n){return n[F]=!1,n.nodes&&n.nodes.forEach(e=>Ct(e)),n}let _t={},le=class qr{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=Ct(t);else if(t instanceof qr||t instanceof ar)s=Ct(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let o=Ys;r.syntax&&(o=r.syntax.parse),r.parser&&(o=r.parser),o.parse&&(o=o.parse);try{s=o(t,r)}catch(i){this.processed=!0,this.error=i}s&&!s[Ks]&&Xs.rebuild(s)}this.result=new ar(e,s,r),this.helpers={..._t,postcss:_t,result:this.result},this.plugins=this.processor.plugins.map(o=>typeof o=="object"&&o.prepare?{...o,...o.prepare(this.result)}:o)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin?(e.plugin=r.postcssPlugin,e.setMessage()):r.postcssVersion}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!ri[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!ni[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(he(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[F];){e[F]=!0;let t=[cr(e)];for(;t.length>0;){let r=this.visitTick(t);if(he(r))try{await r}catch(s){let o=t[t.length-1].node;throw this.handleError(s,o)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(o=>r(o,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return he(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=Js;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new qs(t,this.result.root,this.result.opts).generate();return this.result.css=s[0],this.result.map=s[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let e of this.plugins){let t=this.runOnRoot(e);if(he(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[F];)e[F]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let o;try{o=s(t,this.helpers)}catch(i){throw this.handleError(i,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(he(o))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[i,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=i;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let i=t.iterator,l;for(;l=r.nodes[r.indexes[i]];)if(r.indexes[i]+=1,!l[F]){l[F]=!0,e.push(cr(l));return}t.iterator=0,delete r.indexes[i]}let o=t.events;for(;t.eventIndex<o.length;){let i=o[t.eventIndex];if(t.eventIndex+=1,i===oe){r.nodes&&r.nodes.length&&(r[F]=!0,t.iterator=r.getIterator());return}else if(this.listeners[i]){t.visitors=this.listeners[i];return}}e.pop()}walkSync(e){e[F]=!0;let t=Kr(e);for(let r of t)if(r===oe)e.nodes&&e.each(s=>{s[F]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};le.registerPostcss=n=>{_t=n};var Jr=le;le.default=le;ei.registerLazyResult(le);Qs.registerLazyResult(le);let si=Rr,ii=Ke,oi=$t;const li=Mt;let Ot=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,o=ii;this.result=new li(this._processor,s,this._opts),this.result.css=t;let i=this;Object.defineProperty(this.result,"root",{get(){return i.root}});let l=new si(o,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=oi;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}};var ai=Ot;Ot.default=Ot;let ci=ai,ui=Jr,hi=Pt,fi=ve,me=class{constructor(e=[]){this.version="8.4.32",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(!(typeof r=="object"&&(r.parse||r.stringify)))throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return this.plugins.length===0&&typeof t.parser>"u"&&typeof t.stringifier>"u"&&typeof t.syntax>"u"?new ci(this,e,t):new ui(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}};var di=me;me.default=me;fi.registerProcessor(me);hi.registerProcessor(me);let pi=Je,gi=Sr,mi=Qe,bi=Tt,yi=Xe,wi=ve,xi=It;function be(n,e){if(Array.isArray(n))return n.map(s=>be(s));let{inputs:t,...r}=n;if(t){e=[];for(let s of t){let o={...s,__proto__:yi.prototype};o.map&&(o.map={...o.map,__proto__:gi.prototype}),e.push(o)}}if(r.nodes&&(r.nodes=n.nodes.map(s=>be(s,e))),r.source){let{inputId:s,...o}=r.source;r.source=o,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new wi(r);if(r.type==="decl")return new pi(r);if(r.type==="rule")return new xi(r);if(r.type==="comment")return new mi(r);if(r.type==="atrule")return new bi(r);throw new Error("Unknown node type: "+n.type)}var vi=be;be.default=be;var ur={};let Ei=Rt,Xr=Je,ki=Jr,Si=te,jt=di,Ci=Ke,_i=vi,Qr=Pt,Oi=Ur,Yr=Qe,en=Tt,Ai=Mt,Ri=Xe,Li=$t,Ni=Zr,tn=It,rn=ve,Pi=qe;function k(...n){return n.length===1&&Array.isArray(n[0])&&(n=n[0]),new jt(n)}k.plugin=function(e,t){let r=!1;function s(...i){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
179
|
+
`),t=l.length-i):t+=l.length,a&&u!=="start"){let f=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==f.last||f.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?De(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=De(Or(r,this.mapOpts.annotation)));let s=_r(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new ms(this.css,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(rr){let r=rr(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;Ar==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}};var Rr=ws;let xs=Ke,Et=class extends xs{constructor(e){super(e),this.type="comment"}};var Qe=Et;Et.default=Et;let{isClean:Lr,my:Nr}=xe,Pr=Je,Mr=Qe,vs=Ke,Tr,Lt,Nt,Ir;function $r(n){return n.map(e=>(e.nodes&&(e.nodes=$r(e.nodes)),delete e.source,e))}function jr(n){if(n[Lr]=!1,n.proxyOf.nodes)for(let e of n.proxyOf.nodes)jr(e)}let V=class zr extends vs{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(o,i)=>s(o.toProxy(),i):s)):t==="every"||t==="some"?r=>e[t]((s,...o)=>r(s.toProxy(),...o)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let i of s)this.proxyOf.nodes.splice(r+1,0,i);let o;for(let i in this.indexes)o=this.indexes[i],r<o&&(this.indexes[i]=o+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,o=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of o)this.proxyOf.nodes.splice(r,0,l);let i;for(let l in this.indexes)i=this.indexes[l],r<=i&&(this.indexes[l]=i+o.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=$r(Tr(e).nodes);else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new Pr(e)]}else if(e.selector)e=[new Lt(e)];else if(e.name)e=[new Nt(e)];else if(e.text)e=[new Mr(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Nr]||zr.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[Lr]&&jr(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(o){throw t.addToError(o)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}};V.registerParse=n=>{Tr=n};V.registerRule=n=>{Lt=n};V.registerAtRule=n=>{Nt=n};V.registerRoot=n=>{Ir=n};var te=V;V.default=V;V.rebuild=n=>{n.type==="atrule"?Object.setPrototypeOf(n,Nt.prototype):n.type==="rule"?Object.setPrototypeOf(n,Lt.prototype):n.type==="decl"?Object.setPrototypeOf(n,Pr.prototype):n.type==="comment"?Object.setPrototypeOf(n,Mr.prototype):n.type==="root"&&Object.setPrototypeOf(n,Ir.prototype),n[Nr]=!0,n.nodes&&n.nodes.forEach(e=>{V.rebuild(e)})};let Es=te,Dr,Br,pe=class extends Es{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Dr(new Br,this,e).stringify()}};pe.registerLazyResult=n=>{Dr=n};pe.registerProcessor=n=>{Br=n};var Pt=pe;pe.default=pe;let kt=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}};var Ur=kt;kt.default=kt;let ks=Ur,St=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new ks(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}};var Mt=St;St.default=St;const ht=39,nr=34,Ae=92,sr=47,Re=10,ue=32,Le=12,Ne=9,Pe=13,Ss=91,Cs=93,_s=40,Os=41,As=123,Rs=125,Ls=59,Ns=42,Ps=58,Ms=64,Me=/[\t\n\f\r "#'()/;[\\\]{}]/g,Te=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,Ts=/.[\r\n"'(/\\]/,ir=/[\da-f]/i;var Is=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,o,i,l,a,u,f,y,m,A,L,$=r.length,b=0,H=[],W=[];function J(){return b}function j(D){throw e.error("Unclosed "+D,b)}function G(){return W.length===0&&b>=$}function ce(D){if(W.length)return W.pop();if(b>=$)return;let M=D?D.ignoreUnclosed:!1;switch(o=r.charCodeAt(b),o){case Re:case ue:case Ne:case Pe:case Le:{i=b;do i+=1,o=r.charCodeAt(i);while(o===ue||o===Re||o===Ne||o===Pe||o===Le);L=["space",r.slice(b,i)],b=i-1;break}case Ss:case Cs:case As:case Rs:case Ps:case Ls:case Os:{let X=String.fromCharCode(o);L=[X,X,b];break}case _s:{if(m=H.length?H.pop()[1]:"",A=r.charCodeAt(b+1),m==="url"&&A!==ht&&A!==nr&&A!==ue&&A!==Re&&A!==Ne&&A!==Le&&A!==Pe){i=b;do{if(f=!1,i=r.indexOf(")",i+1),i===-1)if(s||M){i=b;break}else j("bracket");for(y=i;r.charCodeAt(y-1)===Ae;)y-=1,f=!f}while(f);L=["brackets",r.slice(b,i+1),b,i],b=i}else i=r.indexOf(")",b+1),a=r.slice(b,i+1),i===-1||Ts.test(a)?L=["(","(",b]:(L=["brackets",a,b,i],b=i);break}case ht:case nr:{l=o===ht?"'":'"',i=b;do{if(f=!1,i=r.indexOf(l,i+1),i===-1)if(s||M){i=b+1;break}else j("string");for(y=i;r.charCodeAt(y-1)===Ae;)y-=1,f=!f}while(f);L=["string",r.slice(b,i+1),b,i],b=i;break}case Ms:{Me.lastIndex=b+1,Me.test(r),Me.lastIndex===0?i=r.length-1:i=Me.lastIndex-2,L=["at-word",r.slice(b,i+1),b,i],b=i;break}case Ae:{for(i=b,u=!0;r.charCodeAt(i+1)===Ae;)i+=1,u=!u;if(o=r.charCodeAt(i+1),u&&o!==sr&&o!==ue&&o!==Re&&o!==Ne&&o!==Pe&&o!==Le&&(i+=1,ir.test(r.charAt(i)))){for(;ir.test(r.charAt(i+1));)i+=1;r.charCodeAt(i+1)===ue&&(i+=1)}L=["word",r.slice(b,i+1),b,i],b=i;break}default:{o===sr&&r.charCodeAt(b+1)===Ns?(i=r.indexOf("*/",b+2)+1,i===0&&(s||M?i=r.length:j("comment")),L=["comment",r.slice(b,i+1),b,i],b=i):(Te.lastIndex=b+1,Te.test(r),Te.lastIndex===0?i=r.length-1:i=Te.lastIndex-2,L=["word",r.slice(b,i+1),b,i],H.push(L),b=i);break}}return b++,L}function ne(D){W.push(D)}return{back:ne,endOfFile:G,nextToken:ce,position:J}};let Fr=te,Fe=class extends Fr{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}};var Tt=Fe;Fe.default=Fe;Fr.registerAtRule(Fe);let Hr=te,Wr,Gr,ie=class extends Hr{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let o of s)o.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new Wr(new Gr,this,e).stringify()}};ie.registerLazyResult=n=>{Wr=n};ie.registerProcessor=n=>{Gr=n};var ve=ie;ie.default=ie;Hr.registerRoot(ie);let ge={comma(n){return ge.split(n,[","],!0)},space(n){let e=[" ",`
|
|
180
|
+
`," "];return ge.split(n,e)},split(n,e,t){let r=[],s="",o=!1,i=0,l=!1,a="",u=!1;for(let f of n)u?u=!1:f==="\\"?u=!0:l?f===a&&(l=!1):f==='"'||f==="'"?(l=!0,a=f):f==="("?i+=1:f===")"?i>0&&(i-=1):i===0&&e.includes(f)&&(o=!0),o?(s!==""&&r.push(s.trim()),s="",o=!1):s+=f;return(t||s!=="")&&r.push(s.trim()),r}};var Zr=ge;ge.default=ge;let Vr=te,$s=Zr,He=class extends Vr{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return $s.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}};var It=He;He.default=He;Vr.registerRule(He);let js=Je,zs=Is,Ds=Qe,Bs=Tt,Us=ve,or=It;const lr={empty:!0,space:!0};function Fs(n){for(let e=n.length-1;e>=0;e--){let t=n[e],r=t[3]||t[2];if(r)return r}}let Hs=class{constructor(e){this.input=e,this.root=new Us,this.current=this.root,this.spaces="",this.semicolon=!1,this.customProperty=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new Bs;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,o,i=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(o=a.length-1,s=a[o];s&&s[0]==="space";)s=a[--o];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){i=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),i&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let o=t-1;o>=0&&(s=e[o],!(s[0]!=="space"&&(r+=1,r===2)));o--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,o;for(let[i,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!o)this.doubleColon(r);else{if(o[0]==="word"&&o[1]==="progid")continue;return i}o=r}return!1}comment(e){let t=new Ds;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=zs(this.input)}decl(e,t){let r=new js;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||Fs(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let o;for(;e.length;)if(o=e.shift(),o[0]===":"){r.raws.between+=o[1];break}else o[0]==="word"&&/\w/.test(o[1])&&this.unknownWord([o]),r.raws.between+=o[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let i=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)i.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(o=e[u],o[1].toLowerCase()==="!important"){r.important=!0;let f=this.stringFrom(e,u);f=this.spacesFromEnd(e)+f,f!==" !important"&&(r.raws.important=f);break}else if(o[1].toLowerCase()==="important"){let f=e.slice(0),y="";for(let m=u;m>0;m--){let A=f[m][0];if(y.trim().indexOf("!")===0&&A!=="space")break;y=f.pop()[1]+y}y.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=y,e=f)}if(o[0]!=="space"&&o[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=i.map(u=>u[1]).join(""),i=[]),this.raw(r,"value",i.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new or;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,o=null,i=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")o||(o=u),i.push(r==="("?")":"]");else if(l&&s&&r==="{")o||(o=u),i.push("}");else if(i.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===i[i.length-1]&&(i.pop(),i.length===0&&(o=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),i.length>0&&this.unclosedBracket(o),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let o,i,l=r.length,a="",u=!0,f,y;for(let m=0;m<l;m+=1)o=r[m],i=o[0],i==="space"&&m===l-1&&!s?u=!1:i==="comment"?(y=r[m-1]?r[m-1][0]:"empty",f=r[m+1]?r[m+1][0]:"empty",!lr[y]&&!lr[f]?a.slice(-1)===","?u=!1:a+=o[1]:u=!1):a+=o[1];if(!u){let m=r.reduce((A,L)=>A+L[1],"");e.raws[t]={raw:m,value:a}}e[t]=a}rule(e){e.pop();let t=new or;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}};var Ws=Hs;let Gs=te,Zs=Ws,Vs=Xe;function We(n,e){let t=new Vs(n,e),r=new Zs(t);try{r.parse()}catch(s){throw s}return r.root}var $t=We;We.default=We;Gs.registerParse(We);let{isClean:F,my:qs}=xe,Ks=Rr,Js=qe,Xs=te,Qs=Pt,ar=Mt,Ys=$t,ei=ve;const ti={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},ri={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},ni={Once:!0,postcssPlugin:!0,prepare:!0},oe=0;function he(n){return typeof n=="object"&&typeof n.then=="function"}function qr(n){let e=!1,t=ti[n.type];return n.type==="decl"?e=n.prop.toLowerCase():n.type==="atrule"&&(e=n.name.toLowerCase()),e&&n.append?[t,t+"-"+e,oe,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:n.append?[t,oe,t+"Exit"]:[t,t+"Exit"]}function cr(n){let e;return n.type==="document"?e=["Document",oe,"DocumentExit"]:n.type==="root"?e=["Root",oe,"RootExit"]:e=qr(n),{eventIndex:0,events:e,iterator:0,node:n,visitorIndex:0,visitors:[]}}function Ct(n){return n[F]=!1,n.nodes&&n.nodes.forEach(e=>Ct(e)),n}let _t={},le=class Kr{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=Ct(t);else if(t instanceof Kr||t instanceof ar)s=Ct(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let o=Ys;r.syntax&&(o=r.syntax.parse),r.parser&&(o=r.parser),o.parse&&(o=o.parse);try{s=o(t,r)}catch(i){this.processed=!0,this.error=i}s&&!s[qs]&&Xs.rebuild(s)}this.result=new ar(e,s,r),this.helpers={..._t,postcss:_t,result:this.result},this.plugins=this.processor.plugins.map(o=>typeof o=="object"&&o.prepare?{...o,...o.prepare(this.result)}:o)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin?(e.plugin=r.postcssPlugin,e.setMessage()):r.postcssVersion}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!ri[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!ni[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(he(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[F];){e[F]=!0;let t=[cr(e)];for(;t.length>0;){let r=this.visitTick(t);if(he(r))try{await r}catch(s){let o=t[t.length-1].node;throw this.handleError(s,o)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(o=>r(o,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return he(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=Js;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new Ks(t,this.result.root,this.result.opts).generate();return this.result.css=s[0],this.result.map=s[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let e of this.plugins){let t=this.runOnRoot(e);if(he(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[F];)e[F]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let o;try{o=s(t,this.helpers)}catch(i){throw this.handleError(i,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(he(o))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[i,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=i;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let i=t.iterator,l;for(;l=r.nodes[r.indexes[i]];)if(r.indexes[i]+=1,!l[F]){l[F]=!0,e.push(cr(l));return}t.iterator=0,delete r.indexes[i]}let o=t.events;for(;t.eventIndex<o.length;){let i=o[t.eventIndex];if(t.eventIndex+=1,i===oe){r.nodes&&r.nodes.length&&(r[F]=!0,t.iterator=r.getIterator());return}else if(this.listeners[i]){t.visitors=this.listeners[i];return}}e.pop()}walkSync(e){e[F]=!0;let t=qr(e);for(let r of t)if(r===oe)e.nodes&&e.each(s=>{s[F]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};le.registerPostcss=n=>{_t=n};var Jr=le;le.default=le;ei.registerLazyResult(le);Qs.registerLazyResult(le);let si=Rr,ii=qe,oi=$t;const li=Mt;let Ot=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,o=ii;this.result=new li(this._processor,s,this._opts),this.result.css=t;let i=this;Object.defineProperty(this.result,"root",{get(){return i.root}});let l=new si(o,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=oi;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}};var ai=Ot;Ot.default=Ot;let ci=ai,ui=Jr,hi=Pt,fi=ve,me=class{constructor(e=[]){this.version="8.4.32",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(!(typeof r=="object"&&(r.parse||r.stringify)))throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return this.plugins.length===0&&typeof t.parser>"u"&&typeof t.stringifier>"u"&&typeof t.syntax>"u"?new ci(this,e,t):new ui(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}};var di=me;me.default=me;fi.registerProcessor(me);hi.registerProcessor(me);let pi=Je,gi=Sr,mi=Qe,bi=Tt,yi=Xe,wi=ve,xi=It;function be(n,e){if(Array.isArray(n))return n.map(s=>be(s));let{inputs:t,...r}=n;if(t){e=[];for(let s of t){let o={...s,__proto__:yi.prototype};o.map&&(o.map={...o.map,__proto__:gi.prototype}),e.push(o)}}if(r.nodes&&(r.nodes=n.nodes.map(s=>be(s,e))),r.source){let{inputId:s,...o}=r.source;r.source=o,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new wi(r);if(r.type==="decl")return new pi(r);if(r.type==="rule")return new xi(r);if(r.type==="comment")return new mi(r);if(r.type==="atrule")return new bi(r);throw new Error("Unknown node type: "+n.type)}var vi=be;be.default=be;var ur={};let Ei=Rt,Xr=Je,ki=Jr,Si=te,jt=di,Ci=qe,_i=vi,Qr=Pt,Oi=Ur,Yr=Qe,en=Tt,Ai=Mt,Ri=Xe,Li=$t,Ni=Zr,tn=It,rn=ve,Pi=Ke;function k(...n){return n.length===1&&Array.isArray(n[0])&&(n=n[0]),new jt(n)}k.plugin=function(e,t){let r=!1;function s(...i){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
181
181
|
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),ur.LANG&&ur.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
182
|
-
https://www.w3ctech.com/topic/2226`));let l=t(...i);return l.postcssPlugin=e,l.postcssVersion=new jt().version,l}let o;return Object.defineProperty(s,"postcss",{get(){return o||(o=s()),o}}),s.process=function(i,l,a){return k([s(a)]).process(i,l)},s};k.stringify=Ci;k.parse=Li;k.fromJSON=_i;k.list=Ni;k.comment=n=>new Yr(n);k.atRule=n=>new en(n);k.decl=n=>new Xr(n);k.rule=n=>new tn(n);k.root=n=>new rn(n);k.document=n=>new Qr(n);k.CssSyntaxError=Ei;k.Declaration=Xr;k.Container=Si;k.Processor=jt;k.Document=Qr;k.Comment=Yr;k.Warning=Oi;k.AtRule=en;k.Result=Ai;k.Input=Ri;k.Rule=tn;k.Root=rn;k.Node=Pi;ki.registerPostcss(k);var Mi=k;k.default=k;const O=xr(Mi);O.stringify;O.fromJSON;O.plugin;O.parse;O.list;O.document;O.comment;O.atRule;O.rule;O.decl;O.root;O.CssSyntaxError;O.Declaration;O.Container;O.Processor;O.Document;O.Comment;O.Warning;O.AtRule;O.Result;O.Input;O.Rule;O.Root;O.Node;var Ti=function(e){const t=e.prefix,r=/\s+$/.test(t)?t:`${t} `,s=e.ignoreFiles?[].concat(e.ignoreFiles):[],o=e.includeFiles?[].concat(e.includeFiles):[];return function(i){s.length&&i.source.input.file&&hr(i.source.input.file,s)||o.length&&i.source.input.file&&!hr(i.source.input.file,o)||i.walkRules(l=>{const a=["keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes"];l.parent&&a.includes(l.parent.name)||(l.selectors=l.selectors.map(u=>e.exclude&&Ii(u,e.exclude)?u:e.transform?e.transform(t,u,r+u,i.source.input.file,l):r+u))})}};function hr(n,e){return e.some(t=>t instanceof RegExp?t.test(n):n.includes(t))}function Ii(n,e){return e.some(t=>t instanceof RegExp?t.test(n):n===t)}const $i=xr(Ti),ji="code{white-space:pre}.example{display:flex;flex-wrap:wrap;flex-direction:row;align-items:center;gap:16px}.example>*{flex:1 1 500px}.example .tab-control{overflow:hidden}.example div[role=tab]{cursor:pointer;padding:8px 16px;display:inline-block;font-size:16px;border-bottom:2px solid transparent;background-clip:padding-box;-webkit-user-select:none;user-select:none}.example div[role=tab]:hover{background-color:#1467ba14}.example div[role=tab][selected]{background-color:#1467ba21;border-bottom:2px solid #1467ba}.tab-content{margin:16px 0}.tab-content>pre{padding-top:0}.tab-content.code{max-height:500px;overflow:auto}.tab-content.code pre{margin:0}",zi="pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{color:#24292e;background:#fff}.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-template-tag,.hljs-template-variable,.hljs-type,.hljs-variable.language_{color:#d73a49}.hljs-title,.hljs-title.class_,.hljs-title.class_.inherited__,.hljs-title.function_{color:#6f42c1}.hljs-attr,.hljs-attribute,.hljs-literal,.hljs-meta,.hljs-number,.hljs-operator,.hljs-variable,.hljs-selector-attr,.hljs-selector-class,.hljs-selector-id{color:#005cc5}.hljs-regexp,.hljs-string,.hljs-meta .hljs-string{color:#032f62}.hljs-built_in,.hljs-symbol{color:#e36209}.hljs-comment,.hljs-code,.hljs-formula{color:#6a737d}.hljs-name,.hljs-quote,.hljs-selector-tag,.hljs-selector-pseudo{color:#22863a}.hljs-subst{color:#24292e}.hljs-section{color:#005cc5;font-weight:700}.hljs-bullet{color:#735c0f}.hljs-emphasis{color:#24292e;font-style:italic}.hljs-strong{color:#24292e;font-weight:700}.hljs-addition{color:#22863a;background-color:#f0fff4}.hljs-deletion{color:#b31d28;background-color:#ffeef0}";function Di(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}function nn(n){return n instanceof Map?n.clear=n.delete=n.set=function(){throw new Error("map is read-only")}:n instanceof Set&&(n.add=n.clear=n.delete=function(){throw new Error("set is read-only")}),Object.freeze(n),Object.getOwnPropertyNames(n).forEach(e=>{const t=n[e],r=typeof t;(r==="object"||r==="function")&&!Object.isFrozen(t)&&nn(t)}),n}class fr{constructor(e){e.data===void 0&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function sn(n){return n.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function q(n,...e){const t=Object.create(null);for(const r in n)t[r]=n[r];return e.forEach(function(r){for(const s in r)t[s]=r[s]}),t}const Bi="</span>",dr=n=>!!n.scope,Ui=(n,{prefix:e})=>{if(n.startsWith("language:"))return n.replace("language:","language-");if(n.includes(".")){const t=n.split(".");return[`${e}${t.shift()}`,...t.map((r,s)=>`${r}${"_".repeat(s+1)}`)].join(" ")}return`${e}${n}`};class Fi{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=sn(e)}openNode(e){if(!dr(e))return;const t=Ui(e.scope,{prefix:this.classPrefix});this.span(t)}closeNode(e){dr(e)&&(this.buffer+=Bi)}value(){return this.buffer}span(e){this.buffer+=`<span class="${e}">`}}const pr=(n={})=>{const e={children:[]};return Object.assign(e,n),e};class zt{constructor(){this.rootNode=pr(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){this.top.children.push(e)}openNode(e){const t=pr({scope:e});this.add(t),this.stack.push(t)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(e){return this.constructor._walk(e,this.rootNode)}static _walk(e,t){return typeof t=="string"?e.addText(t):t.children&&(e.openNode(t),t.children.forEach(r=>this._walk(e,r)),e.closeNode(t)),e}static _collapse(e){typeof e!="string"&&e.children&&(e.children.every(t=>typeof t=="string")?e.children=[e.children.join("")]:e.children.forEach(t=>{zt._collapse(t)}))}}class Hi extends zt{constructor(e){super(),this.options=e}addText(e){e!==""&&this.add(e)}startScope(e){this.openNode(e)}endScope(){this.closeNode()}__addSublanguage(e,t){const r=e.root;t&&(r.scope=`language:${t}`),this.add(r)}toHTML(){return new Fi(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function ye(n){return n?typeof n=="string"?n:n.source:null}function on(n){return re("(?=",n,")")}function Wi(n){return re("(?:",n,")*")}function Gi(n){return re("(?:",n,")?")}function re(...n){return n.map(e=>ye(e)).join("")}function Zi(n){const e=n[n.length-1];return typeof e=="object"&&e.constructor===Object?(n.splice(n.length-1,1),e):{}}function Dt(...n){return"("+(Zi(n).capture?"":"?:")+n.map(e=>ye(e)).join("|")+")"}function ln(n){return new RegExp(n.toString()+"|").exec("").length-1}function Vi(n,e){const t=n&&n.exec(e);return t&&t.index===0}const Ki=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function Bt(n,{joinWith:e}){let t=0;return n.map(r=>{t+=1;const s=t;let o=ye(r),i="";for(;o.length>0;){const l=Ki.exec(o);if(!l){i+=o;break}i+=o.substring(0,l.index),o=o.substring(l.index+l[0].length),l[0][0]==="\\"&&l[1]?i+="\\"+String(Number(l[1])+s):(i+=l[0],l[0]==="("&&t++)}return i}).map(r=>`(${r})`).join(e)}const qi=/\b\B/,an="[a-zA-Z]\\w*",Ut="[a-zA-Z_]\\w*",cn="\\b\\d+(\\.\\d+)?",un="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",hn="\\b(0b[01]+)",Ji="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",Xi=(n={})=>{const e=/^#![ ]*\//;return n.binary&&(n.begin=re(e,/.*\b/,n.binary,/\b.*/)),q({scope:"meta",begin:e,end:/$/,relevance:0,"on:begin":(t,r)=>{t.index!==0&&r.ignoreMatch()}},n)},we={begin:"\\\\[\\s\\S]",relevance:0},Qi={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[we]},Yi={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[we]},eo={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},Ye=function(n,e,t={}){const r=q({scope:"comment",begin:n,end:e,contains:[]},t);r.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const s=Dt("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return r.contains.push({begin:re(/[ ]+/,"(",s,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),r},to=Ye("//","$"),ro=Ye("/\\*","\\*/"),no=Ye("#","$"),so={scope:"number",begin:cn,relevance:0},io={scope:"number",begin:un,relevance:0},oo={scope:"number",begin:hn,relevance:0},lo={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[we,{begin:/\[/,end:/\]/,relevance:0,contains:[we]}]},ao={scope:"title",begin:an,relevance:0},co={scope:"title",begin:Ut,relevance:0},uo={begin:"\\.\\s*"+Ut,relevance:0},ho=function(n){return Object.assign(n,{"on:begin":(e,t)=>{t.data._beginMatch=e[1]},"on:end":(e,t)=>{t.data._beginMatch!==e[1]&&t.ignoreMatch()}})};var Ie=Object.freeze({__proto__:null,APOS_STRING_MODE:Qi,BACKSLASH_ESCAPE:we,BINARY_NUMBER_MODE:oo,BINARY_NUMBER_RE:hn,COMMENT:Ye,C_BLOCK_COMMENT_MODE:ro,C_LINE_COMMENT_MODE:to,C_NUMBER_MODE:io,C_NUMBER_RE:un,END_SAME_AS_BEGIN:ho,HASH_COMMENT_MODE:no,IDENT_RE:an,MATCH_NOTHING_RE:qi,METHOD_GUARD:uo,NUMBER_MODE:so,NUMBER_RE:cn,PHRASAL_WORDS_MODE:eo,QUOTE_STRING_MODE:Yi,REGEXP_MODE:lo,RE_STARTERS_RE:Ji,SHEBANG:Xi,TITLE_MODE:ao,UNDERSCORE_IDENT_RE:Ut,UNDERSCORE_TITLE_MODE:co});function fo(n,e){n.input[n.index-1]==="."&&e.ignoreMatch()}function po(n,e){n.className!==void 0&&(n.scope=n.className,delete n.className)}function go(n,e){e&&n.beginKeywords&&(n.begin="\\b("+n.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",n.__beforeBegin=fo,n.keywords=n.keywords||n.beginKeywords,delete n.beginKeywords,n.relevance===void 0&&(n.relevance=0))}function mo(n,e){Array.isArray(n.illegal)&&(n.illegal=Dt(...n.illegal))}function bo(n,e){if(n.match){if(n.begin||n.end)throw new Error("begin & end are not supported with match");n.begin=n.match,delete n.match}}function yo(n,e){n.relevance===void 0&&(n.relevance=1)}const wo=(n,e)=>{if(!n.beforeMatch)return;if(n.starts)throw new Error("beforeMatch cannot be used with starts");const t=Object.assign({},n);Object.keys(n).forEach(r=>{delete n[r]}),n.keywords=t.keywords,n.begin=re(t.beforeMatch,on(t.begin)),n.starts={relevance:0,contains:[Object.assign(t,{endsParent:!0})]},n.relevance=0,delete t.beforeMatch},xo=["of","and","for","in","not","or","if","then","parent","list","value"],vo="keyword";function fn(n,e,t=vo){const r=Object.create(null);return typeof n=="string"?s(t,n.split(" ")):Array.isArray(n)?s(t,n):Object.keys(n).forEach(function(o){Object.assign(r,fn(n[o],e,o))}),r;function s(o,i){e&&(i=i.map(l=>l.toLowerCase())),i.forEach(function(l){const a=l.split("|");r[a[0]]=[o,Eo(a[0],a[1])]})}}function Eo(n,e){return e?Number(e):ko(n)?0:1}function ko(n){return xo.includes(n.toLowerCase())}const gr={},ee=n=>{console.error(n)},mr=(n,...e)=>{console.log(`WARN: ${n}`,...e)},se=(n,e)=>{gr[`${n}/${e}`]||(console.log(`Deprecated as of ${n}. ${e}`),gr[`${n}/${e}`]=!0)},Ge=new Error;function dn(n,e,{key:t}){let r=0;const s=n[t],o={},i={};for(let l=1;l<=e.length;l++)i[l+r]=s[l],o[l+r]=!0,r+=ln(e[l-1]);n[t]=i,n[t]._emit=o,n[t]._multi=!0}function So(n){if(Array.isArray(n.begin)){if(n.skip||n.excludeBegin||n.returnBegin)throw ee("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Ge;if(typeof n.beginScope!="object"||n.beginScope===null)throw ee("beginScope must be object"),Ge;dn(n,n.begin,{key:"beginScope"}),n.begin=Bt(n.begin,{joinWith:""})}}function Co(n){if(Array.isArray(n.end)){if(n.skip||n.excludeEnd||n.returnEnd)throw ee("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Ge;if(typeof n.endScope!="object"||n.endScope===null)throw ee("endScope must be object"),Ge;dn(n,n.end,{key:"endScope"}),n.end=Bt(n.end,{joinWith:""})}}function _o(n){n.scope&&typeof n.scope=="object"&&n.scope!==null&&(n.beginScope=n.scope,delete n.scope)}function Oo(n){_o(n),typeof n.beginScope=="string"&&(n.beginScope={_wrap:n.beginScope}),typeof n.endScope=="string"&&(n.endScope={_wrap:n.endScope}),So(n),Co(n)}function Ao(n){function e(i,l){return new RegExp(ye(i),"m"+(n.case_insensitive?"i":"")+(n.unicodeRegex?"u":"")+(l?"g":""))}class t{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(l,a){a.position=this.position++,this.matchIndexes[this.matchAt]=a,this.regexes.push([a,l]),this.matchAt+=ln(l)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const l=this.regexes.map(a=>a[1]);this.matcherRe=e(Bt(l,{joinWith:"|"}),!0),this.lastIndex=0}exec(l){this.matcherRe.lastIndex=this.lastIndex;const a=this.matcherRe.exec(l);if(!a)return null;const u=a.findIndex((y,m)=>m>0&&y!==void 0),f=this.matchIndexes[u];return a.splice(0,u),Object.assign(a,f)}}class r{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(l){if(this.multiRegexes[l])return this.multiRegexes[l];const a=new t;return this.rules.slice(l).forEach(([u,f])=>a.addRule(u,f)),a.compile(),this.multiRegexes[l]=a,a}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(l,a){this.rules.push([l,a]),a.type==="begin"&&this.count++}exec(l){const a=this.getMatcher(this.regexIndex);a.lastIndex=this.lastIndex;let u=a.exec(l);if(this.resumingScanAtSamePosition()&&!(u&&u.index===this.lastIndex)){const f=this.getMatcher(0);f.lastIndex=this.lastIndex+1,u=f.exec(l)}return u&&(this.regexIndex+=u.position+1,this.regexIndex===this.count&&this.considerAll()),u}}function s(i){const l=new r;return i.contains.forEach(a=>l.addRule(a.begin,{rule:a,type:"begin"})),i.terminatorEnd&&l.addRule(i.terminatorEnd,{type:"end"}),i.illegal&&l.addRule(i.illegal,{type:"illegal"}),l}function o(i,l){const a=i;if(i.isCompiled)return a;[po,bo,Oo,wo].forEach(f=>f(i,l)),n.compilerExtensions.forEach(f=>f(i,l)),i.__beforeBegin=null,[go,mo,yo].forEach(f=>f(i,l)),i.isCompiled=!0;let u=null;return typeof i.keywords=="object"&&i.keywords.$pattern&&(i.keywords=Object.assign({},i.keywords),u=i.keywords.$pattern,delete i.keywords.$pattern),u=u||/\w+/,i.keywords&&(i.keywords=fn(i.keywords,n.case_insensitive)),a.keywordPatternRe=e(u,!0),l&&(i.begin||(i.begin=/\B|\b/),a.beginRe=e(a.begin),!i.end&&!i.endsWithParent&&(i.end=/\B|\b/),i.end&&(a.endRe=e(a.end)),a.terminatorEnd=ye(a.end)||"",i.endsWithParent&&l.terminatorEnd&&(a.terminatorEnd+=(i.end?"|":"")+l.terminatorEnd)),i.illegal&&(a.illegalRe=e(i.illegal)),i.contains||(i.contains=[]),i.contains=[].concat(...i.contains.map(function(f){return Ro(f==="self"?i:f)})),i.contains.forEach(function(f){o(f,a)}),i.starts&&o(i.starts,l),a.matcher=s(a),a}if(n.compilerExtensions||(n.compilerExtensions=[]),n.contains&&n.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return n.classNameAliases=q(n.classNameAliases||{}),o(n)}function pn(n){return n?n.endsWithParent||pn(n.starts):!1}function Ro(n){return n.variants&&!n.cachedVariants&&(n.cachedVariants=n.variants.map(function(e){return q(n,{variants:null},e)})),n.cachedVariants?n.cachedVariants:pn(n)?q(n,{starts:n.starts?q(n.starts):null}):Object.isFrozen(n)?q(n):n}var Lo="11.9.0";class No extends Error{constructor(e,t){super(e),this.name="HTMLInjectionError",this.html=t}}const ft=sn,br=q,yr=Symbol("nomatch"),Po=7,gn=function(n){const e=Object.create(null),t=Object.create(null),r=[];let s=!0;const o="Could not find the language '{}', did you forget to load/include a language module?",i={disableAutodetect:!0,name:"Plain text",contains:[]};let l={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:Hi};function a(h){return l.noHighlightRe.test(h)}function u(h){let p=h.className+" ";p+=h.parentNode?h.parentNode.className:"";const x=l.languageDetectRe.exec(p);if(x){const E=M(x[1]);return E||(mr(o.replace("{}",x[1])),mr("Falling back to no-highlight mode for this block.",h)),E?x[1]:"no-highlight"}return p.split(/\s+/).find(E=>a(E)||M(E))}function f(h,p,x){let E="",R="";typeof p=="object"?(E=h,x=p.ignoreIllegals,R=p.language):(se("10.7.0","highlight(lang, code, ...args) has been deprecated."),se("10.7.0",`Please use highlight(code, options) instead.
|
|
183
|
-
https://github.com/highlightjs/highlight.js/issues/2277`),R=h,E=p),x===void 0&&(x=!0);const T={code:E,language:R};Q("before:highlight",T);const K=T.result?T.result:y(T.language,T.code,x);return K.code=T.code,Q("after:highlight",K),K}function y(h,p,x,E){const R=Object.create(null);function T(d,g){return d.keywords[g]}function K(){if(!w.keywords){N.addText(C);return}let d=0;w.keywordPatternRe.lastIndex=0;let g=w.keywordPatternRe.exec(C),v="";for(;g;){v+=C.substring(d,g.index);const S=U.case_insensitive?g[0].toLowerCase():g[0],P=T(w,S);if(P){const[Z,Rn]=P;if(N.addText(v),v="",R[S]=(R[S]||0)+1,R[S]<=Po&&(Ce+=Rn),Z.startsWith("_"))v+=g[0];else{const Ln=U.classNameAliases[Z]||Z;B(g[0],Ln)}}else v+=g[0];d=w.keywordPatternRe.lastIndex,g=w.keywordPatternRe.exec(C)}v+=C.substring(d),N.addText(v)}function ke(){if(C==="")return;let d=null;if(typeof w.subLanguage=="string"){if(!e[w.subLanguage]){N.addText(C);return}d=y(w.subLanguage,C,!0,Zt[w.subLanguage]),Zt[w.subLanguage]=d._top}else d=A(C,w.subLanguage.length?w.subLanguage:null);w.relevance>0&&(Ce+=d.relevance),N.__addSublanguage(d._emitter,d.language)}function I(){w.subLanguage!=null?ke():K(),C=""}function B(d,g){d!==""&&(N.startScope(g),N.addText(d),N.endScope())}function Ft(d,g){let v=1;const S=g.length-1;for(;v<=S;){if(!d._emit[v]){v++;continue}const P=U.classNameAliases[d[v]]||d[v],Z=g[v];P?B(Z,P):(C=Z,K(),C=""),v++}}function Ht(d,g){return d.scope&&typeof d.scope=="string"&&N.openNode(U.classNameAliases[d.scope]||d.scope),d.beginScope&&(d.beginScope._wrap?(B(C,U.classNameAliases[d.beginScope._wrap]||d.beginScope._wrap),C=""):d.beginScope._multi&&(Ft(d.beginScope,g),C="")),w=Object.create(d,{parent:{value:w}}),w}function Wt(d,g,v){let S=Vi(d.endRe,v);if(S){if(d["on:end"]){const P=new fr(d);d["on:end"](g,P),P.isMatchIgnored&&(S=!1)}if(S){for(;d.endsParent&&d.parent;)d=d.parent;return d}}if(d.endsWithParent)return Wt(d.parent,g,v)}function Sn(d){return w.matcher.regexIndex===0?(C+=d[0],1):(lt=!0,0)}function Cn(d){const g=d[0],v=d.rule,S=new fr(v),P=[v.__beforeBegin,v["on:begin"]];for(const Z of P)if(Z&&(Z(d,S),S.isMatchIgnored))return Sn(g);return v.skip?C+=g:(v.excludeBegin&&(C+=g),I(),!v.returnBegin&&!v.excludeBegin&&(C=g)),Ht(v,d),v.returnBegin?0:g.length}function _n(d){const g=d[0],v=p.substring(d.index),S=Wt(w,d,v);if(!S)return yr;const P=w;w.endScope&&w.endScope._wrap?(I(),B(g,w.endScope._wrap)):w.endScope&&w.endScope._multi?(I(),Ft(w.endScope,d)):P.skip?C+=g:(P.returnEnd||P.excludeEnd||(C+=g),I(),P.excludeEnd&&(C=g));do w.scope&&N.closeNode(),!w.skip&&!w.subLanguage&&(Ce+=w.relevance),w=w.parent;while(w!==S.parent);return S.starts&&Ht(S.starts,d),P.returnEnd?0:g.length}function On(){const d=[];for(let g=w;g!==U;g=g.parent)g.scope&&d.unshift(g.scope);d.forEach(g=>N.openNode(g))}let Se={};function Gt(d,g){const v=g&&g[0];if(C+=d,v==null)return I(),0;if(Se.type==="begin"&&g.type==="end"&&Se.index===g.index&&v===""){if(C+=p.slice(g.index,g.index+1),!s){const S=new Error(`0 width match regex (${h})`);throw S.languageName=h,S.badRule=Se.rule,S}return 1}if(Se=g,g.type==="begin")return Cn(g);if(g.type==="illegal"&&!x){const S=new Error('Illegal lexeme "'+v+'" for mode "'+(w.scope||"<unnamed>")+'"');throw S.mode=w,S}else if(g.type==="end"){const S=_n(g);if(S!==yr)return S}if(g.type==="illegal"&&v==="")return 1;if(ot>1e5&&ot>g.index*3)throw new Error("potential infinite loop, way more iterations than matches");return C+=v,v.length}const U=M(h);if(!U)throw ee(o.replace("{}",h)),new Error('Unknown language: "'+h+'"');const An=Ao(U);let it="",w=E||An;const Zt={},N=new l.__emitter(l);On();let C="",Ce=0,Y=0,ot=0,lt=!1;try{if(U.__emitTokens)U.__emitTokens(p,N);else{for(w.matcher.considerAll();;){ot++,lt?lt=!1:w.matcher.considerAll(),w.matcher.lastIndex=Y;const d=w.matcher.exec(p);if(!d)break;const g=p.substring(Y,d.index),v=Gt(g,d);Y=d.index+v}Gt(p.substring(Y))}return N.finalize(),it=N.toHTML(),{language:h,value:it,relevance:Ce,illegal:!1,_emitter:N,_top:w}}catch(d){if(d.message&&d.message.includes("Illegal"))return{language:h,value:ft(p),illegal:!0,relevance:0,_illegalBy:{message:d.message,index:Y,context:p.slice(Y-100,Y+100),mode:d.mode,resultSoFar:it},_emitter:N};if(s)return{language:h,value:ft(p),illegal:!1,relevance:0,errorRaised:d,_emitter:N,_top:w};throw d}}function m(h){const p={value:ft(h),illegal:!1,relevance:0,_top:i,_emitter:new l.__emitter(l)};return p._emitter.addText(h),p}function A(h,p){p=p||l.languages||Object.keys(e);const x=m(h),E=p.filter(M).filter(Ee).map(I=>y(I,h,!1));E.unshift(x);const R=E.sort((I,B)=>{if(I.relevance!==B.relevance)return B.relevance-I.relevance;if(I.language&&B.language){if(M(I.language).supersetOf===B.language)return 1;if(M(B.language).supersetOf===I.language)return-1}return 0}),[T,K]=R,ke=T;return ke.secondBest=K,ke}function L(h,p,x){const E=p&&t[p]||x;h.classList.add("hljs"),h.classList.add(`language-${E}`)}function $(h){let p=null;const x=u(h);if(a(x))return;if(Q("before:highlightElement",{el:h,language:x}),h.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",h);return}if(h.children.length>0&&(l.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(h)),l.throwUnescapedHTML))throw new No("One of your code blocks includes unescaped HTML.",h.innerHTML);p=h;const E=p.textContent,R=x?f(E,{language:x,ignoreIllegals:!0}):A(E);h.innerHTML=R.value,h.dataset.highlighted="yes",L(h,x,R.language),h.result={language:R.language,re:R.relevance,relevance:R.relevance},R.secondBest&&(h.secondBest={language:R.secondBest.language,relevance:R.secondBest.relevance}),Q("after:highlightElement",{el:h,result:R,text:E})}function b(h){l=br(l,h)}const H=()=>{j(),se("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function W(){j(),se("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let J=!1;function j(){if(document.readyState==="loading"){J=!0;return}document.querySelectorAll(l.cssSelector).forEach($)}function G(){J&&j()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",G,!1);function ce(h,p){let x=null;try{x=p(n)}catch(E){if(ee("Language definition for '{}' could not be registered.".replace("{}",h)),s)ee(E);else throw E;x=i}x.name||(x.name=h),e[h]=x,x.rawDefinition=p.bind(null,n),x.aliases&&X(x.aliases,{languageName:h})}function ne(h){delete e[h];for(const p of Object.keys(t))t[p]===h&&delete t[p]}function D(){return Object.keys(e)}function M(h){return h=(h||"").toLowerCase(),e[h]||e[t[h]]}function X(h,{languageName:p}){typeof h=="string"&&(h=[h]),h.forEach(x=>{t[x.toLowerCase()]=p})}function Ee(h){const p=M(h);return p&&!p.disableAutodetect}function tt(h){h["before:highlightBlock"]&&!h["before:highlightElement"]&&(h["before:highlightElement"]=p=>{h["before:highlightBlock"](Object.assign({block:p.el},p))}),h["after:highlightBlock"]&&!h["after:highlightElement"]&&(h["after:highlightElement"]=p=>{h["after:highlightBlock"](Object.assign({block:p.el},p))})}function rt(h){tt(h),r.push(h)}function nt(h){const p=r.indexOf(h);p!==-1&&r.splice(p,1)}function Q(h,p){const x=h;r.forEach(function(E){E[x]&&E[x](p)})}function st(h){return se("10.7.0","highlightBlock will be removed entirely in v12.0"),se("10.7.0","Please use highlightElement now."),$(h)}Object.assign(n,{highlight:f,highlightAuto:A,highlightAll:j,highlightElement:$,highlightBlock:st,configure:b,initHighlighting:H,initHighlightingOnLoad:W,registerLanguage:ce,unregisterLanguage:ne,listLanguages:D,getLanguage:M,registerAliases:X,autoDetection:Ee,inherit:br,addPlugin:rt,removePlugin:nt}),n.debugMode=function(){s=!1},n.safeMode=function(){s=!0},n.versionString=Lo,n.regex={concat:re,lookahead:on,either:Dt,optional:Gi,anyNumberOfTimes:Wi};for(const h in Ie)typeof Ie[h]=="object"&&nn(Ie[h]);return Object.assign(n,Ie),n},ae=gn({});ae.newInstance=()=>gn({});var Mo=ae;ae.HighlightJS=ae;ae.default=ae;const et=Di(Mo),Ze="[A-Za-z$_][0-9A-Za-z$_]*",mn=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],bn=["true","false","null","undefined","NaN","Infinity"],yn=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],wn=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],xn=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],vn=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],En=[].concat(xn,yn,wn);function To(n){const e=n.regex,t=(h,{after:p})=>{const x="</"+h[0].slice(1);return h.input.indexOf(x,p)!==-1},r=Ze,s={begin:"<>",end:"</>"},o=/<[A-Za-z0-9\\._:-]+\s*\/>/,i={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(h,p)=>{const x=h[0].length+h.index,E=h.input[x];if(E==="<"||E===","){p.ignoreMatch();return}E===">"&&(t(h,{after:x})||p.ignoreMatch());let R;const T=h.input.substring(x);if(R=T.match(/^\s*=/)){p.ignoreMatch();return}if((R=T.match(/^\s+extends\s+/))&&R.index===0){p.ignoreMatch();return}}},l={$pattern:Ze,keyword:mn,literal:bn,built_in:En,"variable.language":vn},a="[0-9](_?[0-9])*",u=`\\.(${a})`,f="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",y={className:"number",variants:[{begin:`(\\b(${f})((${u})|\\.)?|(${u}))[eE][+-]?(${a})\\b`},{begin:`\\b(${f})\\b((${u})\\b|\\.)?|(${u})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},m={className:"subst",begin:"\\$\\{",end:"\\}",keywords:l,contains:[]},A={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"xml"}},L={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"css"}},$={begin:"gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"graphql"}},b={className:"string",begin:"`",end:"`",contains:[n.BACKSLASH_ESCAPE,m]},H={className:"comment",variants:[n.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:r+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),n.C_BLOCK_COMMENT_MODE,n.C_LINE_COMMENT_MODE]},W=[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE,A,L,$,b,{match:/\$\d+/},y];m.contains=W.concat({begin:/\{/,end:/\}/,keywords:l,contains:["self"].concat(W)});const J=[].concat(H,m.contains),j=J.concat([{begin:/\(/,end:/\)/,keywords:l,contains:["self"].concat(J)}]),G={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:j},ce={variants:[{match:[/class/,/\s+/,r,/\s+/,/extends/,/\s+/,e.concat(r,"(",e.concat(/\./,r),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,r],scope:{1:"keyword",3:"title.class"}}]},ne={relevance:0,match:e.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...yn,...wn]}},D={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},M={variants:[{match:[/function/,/\s+/,r,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[G],illegal:/%/},X={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function Ee(h){return e.concat("(?!",h.join("|"),")")}const tt={match:e.concat(/\b/,Ee([...xn,"super","import"]),r,e.lookahead(/\(/)),className:"title.function",relevance:0},rt={begin:e.concat(/\./,e.lookahead(e.concat(r,/(?![0-9A-Za-z$_(])/))),end:r,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},nt={match:[/get|set/,/\s+/,r,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},G]},Q="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+n.UNDERSCORE_IDENT_RE+")\\s*=>",st={match:[/const|var|let/,/\s+/,r,/\s*/,/=\s*/,/(async\s*)?/,e.lookahead(Q)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[G]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:l,exports:{PARAMS_CONTAINS:j,CLASS_REFERENCE:ne},illegal:/#(?![$_A-z])/,contains:[n.SHEBANG({label:"shebang",binary:"node",relevance:5}),D,n.APOS_STRING_MODE,n.QUOTE_STRING_MODE,A,L,$,b,H,{match:/\$\d+/},y,ne,{className:"attr",begin:r+e.lookahead(":"),relevance:0},st,{begin:"("+n.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[H,n.REGEXP_MODE,{className:"function",begin:Q,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:n.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:j}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:s.begin,end:s.end},{match:o},{begin:i.begin,"on:begin":i.isTrulyOpeningTag,end:i.end}],subLanguage:"xml",contains:[{begin:i.begin,end:i.end,skip:!0,contains:["self"]}]}]},M,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+n.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[G,n.inherit(n.TITLE_MODE,{begin:r,className:"title.function"})]},{match:/\.\.\./,relevance:0},rt,{match:"\\$"+r,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[G]},tt,X,ce,nt,{match:/\$[(.]/}]}}function Io(n){const e=To(n),t=Ze,r=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],s={beginKeywords:"namespace",end:/\{/,excludeEnd:!0,contains:[e.exports.CLASS_REFERENCE]},o={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:r},contains:[e.exports.CLASS_REFERENCE]},i={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},l=["type","namespace","interface","public","private","protected","implements","declare","abstract","readonly","enum","override"],a={$pattern:Ze,keyword:mn.concat(l),literal:bn,built_in:En.concat(r),"variable.language":vn},u={className:"meta",begin:"@"+t},f=(m,A,L)=>{const $=m.contains.findIndex(b=>b.label===A);if($===-1)throw new Error("can not find mode to replace");m.contains.splice($,1,L)};Object.assign(e.keywords,a),e.exports.PARAMS_CONTAINS.push(u),e.contains=e.contains.concat([u,s,o]),f(e,"shebang",n.SHEBANG()),f(e,"use_strict",i);const y=e.contains.find(m=>m.label==="func.def");return y.relevance=0,Object.assign(e,{name:"TypeScript",aliases:["ts","tsx","mts","cts"]}),e}function $o(n){const e=n.regex,t=e.concat(/[\p{L}_]/u,e.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),r=/[\p{L}0-9._:-]+/u,s={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},o={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},i=n.inherit(o,{begin:/\(/,end:/\)/}),l=n.inherit(n.APOS_STRING_MODE,{className:"string"}),a=n.inherit(n.QUOTE_STRING_MODE,{className:"string"}),u={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:r,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[s]},{begin:/'/,end:/'/,contains:[s]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[o,a,l,i,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[o,i,a,l]}]}]},n.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},s,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[a]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[u],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[u],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:e.concat(/</,e.lookahead(e.concat(t,e.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:t,relevance:0,starts:u}]},{className:"tag",begin:e.concat(/<\//,e.lookahead(e.concat(t,/>/))),contains:[{className:"name",begin:t,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const jo=n=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:n.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:n.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),zo=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],Do=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],Bo=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],Uo=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],Fo=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse();function Ho(n){const e=n.regex,t=jo(n),r={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},s="and or not only",o=/@-?\w[\w]*(-\w+)*/,i="[a-zA-Z-][a-zA-Z0-9_-]*",l=[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[t.BLOCK_COMMENT,r,t.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+i,relevance:0},t.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+Bo.join("|")+")"},{begin:":(:)?("+Uo.join("|")+")"}]},t.CSS_VARIABLE,{className:"attribute",begin:"\\b("+Fo.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[t.BLOCK_COMMENT,t.HEXCOLOR,t.IMPORTANT,t.CSS_NUMBER_MODE,...l,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...l,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},t.FUNCTION_DISPATCH]},{begin:e.lookahead(/@/),end:"[{;]",relevance:0,illegal:/:/,contains:[{className:"keyword",begin:o},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:s,attribute:Do.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...l,t.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+zo.join("|")+")\\b"}]}}const kn=document.createElement("style");kn.innerText=[ji,zi].join(`
|
|
182
|
+
https://www.w3ctech.com/topic/2226`));let l=t(...i);return l.postcssPlugin=e,l.postcssVersion=new jt().version,l}let o;return Object.defineProperty(s,"postcss",{get(){return o||(o=s()),o}}),s.process=function(i,l,a){return k([s(a)]).process(i,l)},s};k.stringify=Ci;k.parse=Li;k.fromJSON=_i;k.list=Ni;k.comment=n=>new Yr(n);k.atRule=n=>new en(n);k.decl=n=>new Xr(n);k.rule=n=>new tn(n);k.root=n=>new rn(n);k.document=n=>new Qr(n);k.CssSyntaxError=Ei;k.Declaration=Xr;k.Container=Si;k.Processor=jt;k.Document=Qr;k.Comment=Yr;k.Warning=Oi;k.AtRule=en;k.Result=Ai;k.Input=Ri;k.Rule=tn;k.Root=rn;k.Node=Pi;ki.registerPostcss(k);var Mi=k;k.default=k;const O=xr(Mi);O.stringify;O.fromJSON;O.plugin;O.parse;O.list;O.document;O.comment;O.atRule;O.rule;O.decl;O.root;O.CssSyntaxError;O.Declaration;O.Container;O.Processor;O.Document;O.Comment;O.Warning;O.AtRule;O.Result;O.Input;O.Rule;O.Root;O.Node;var Ti=function(e){const t=e.prefix,r=/\s+$/.test(t)?t:`${t} `,s=e.ignoreFiles?[].concat(e.ignoreFiles):[],o=e.includeFiles?[].concat(e.includeFiles):[];return function(i){s.length&&i.source.input.file&&hr(i.source.input.file,s)||o.length&&i.source.input.file&&!hr(i.source.input.file,o)||i.walkRules(l=>{const a=["keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes"];l.parent&&a.includes(l.parent.name)||(l.selectors=l.selectors.map(u=>e.exclude&&Ii(u,e.exclude)?u:e.transform?e.transform(t,u,r+u,i.source.input.file,l):r+u))})}};function hr(n,e){return e.some(t=>t instanceof RegExp?t.test(n):n.includes(t))}function Ii(n,e){return e.some(t=>t instanceof RegExp?t.test(n):n===t)}const $i=xr(Ti),ji="code{white-space:pre}.example{display:flex;flex-wrap:wrap;flex-direction:row;align-items:center;gap:16px}.example>*{flex:1 1 500px}.example .tab-control{overflow:hidden}.example div[role=tab]{cursor:pointer;padding:8px 16px;display:inline-block;font-size:16px;border-bottom:2px solid transparent;background-clip:padding-box;-webkit-user-select:none;user-select:none}.example div[role=tab]:hover{background-color:#1467ba14}.example div[role=tab][selected]{background-color:#1467ba21;border-bottom:2px solid #1467ba}.tab-content{margin:16px 0}.tab-content>pre{padding-top:0}.tab-content.code{max-height:500px;overflow:auto}.tab-content.code pre{margin:0}",zi="pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{color:#24292e;background:#fff}.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-template-tag,.hljs-template-variable,.hljs-type,.hljs-variable.language_{color:#d73a49}.hljs-title,.hljs-title.class_,.hljs-title.class_.inherited__,.hljs-title.function_{color:#6f42c1}.hljs-attr,.hljs-attribute,.hljs-literal,.hljs-meta,.hljs-number,.hljs-operator,.hljs-variable,.hljs-selector-attr,.hljs-selector-class,.hljs-selector-id{color:#005cc5}.hljs-regexp,.hljs-string,.hljs-meta .hljs-string{color:#032f62}.hljs-built_in,.hljs-symbol{color:#e36209}.hljs-comment,.hljs-code,.hljs-formula{color:#6a737d}.hljs-name,.hljs-quote,.hljs-selector-tag,.hljs-selector-pseudo{color:#22863a}.hljs-subst{color:#24292e}.hljs-section{color:#005cc5;font-weight:700}.hljs-bullet{color:#735c0f}.hljs-emphasis{color:#24292e;font-style:italic}.hljs-strong{color:#24292e;font-weight:700}.hljs-addition{color:#22863a;background-color:#f0fff4}.hljs-deletion{color:#b31d28;background-color:#ffeef0}";function Di(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}function nn(n){return n instanceof Map?n.clear=n.delete=n.set=function(){throw new Error("map is read-only")}:n instanceof Set&&(n.add=n.clear=n.delete=function(){throw new Error("set is read-only")}),Object.freeze(n),Object.getOwnPropertyNames(n).forEach(e=>{const t=n[e],r=typeof t;(r==="object"||r==="function")&&!Object.isFrozen(t)&&nn(t)}),n}class fr{constructor(e){e.data===void 0&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function sn(n){return n.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function K(n,...e){const t=Object.create(null);for(const r in n)t[r]=n[r];return e.forEach(function(r){for(const s in r)t[s]=r[s]}),t}const Bi="</span>",dr=n=>!!n.scope,Ui=(n,{prefix:e})=>{if(n.startsWith("language:"))return n.replace("language:","language-");if(n.includes(".")){const t=n.split(".");return[`${e}${t.shift()}`,...t.map((r,s)=>`${r}${"_".repeat(s+1)}`)].join(" ")}return`${e}${n}`};class Fi{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=sn(e)}openNode(e){if(!dr(e))return;const t=Ui(e.scope,{prefix:this.classPrefix});this.span(t)}closeNode(e){dr(e)&&(this.buffer+=Bi)}value(){return this.buffer}span(e){this.buffer+=`<span class="${e}">`}}const pr=(n={})=>{const e={children:[]};return Object.assign(e,n),e};class zt{constructor(){this.rootNode=pr(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){this.top.children.push(e)}openNode(e){const t=pr({scope:e});this.add(t),this.stack.push(t)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(e){return this.constructor._walk(e,this.rootNode)}static _walk(e,t){return typeof t=="string"?e.addText(t):t.children&&(e.openNode(t),t.children.forEach(r=>this._walk(e,r)),e.closeNode(t)),e}static _collapse(e){typeof e!="string"&&e.children&&(e.children.every(t=>typeof t=="string")?e.children=[e.children.join("")]:e.children.forEach(t=>{zt._collapse(t)}))}}class Hi extends zt{constructor(e){super(),this.options=e}addText(e){e!==""&&this.add(e)}startScope(e){this.openNode(e)}endScope(){this.closeNode()}__addSublanguage(e,t){const r=e.root;t&&(r.scope=`language:${t}`),this.add(r)}toHTML(){return new Fi(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function ye(n){return n?typeof n=="string"?n:n.source:null}function on(n){return re("(?=",n,")")}function Wi(n){return re("(?:",n,")*")}function Gi(n){return re("(?:",n,")?")}function re(...n){return n.map(e=>ye(e)).join("")}function Zi(n){const e=n[n.length-1];return typeof e=="object"&&e.constructor===Object?(n.splice(n.length-1,1),e):{}}function Dt(...n){return"("+(Zi(n).capture?"":"?:")+n.map(e=>ye(e)).join("|")+")"}function ln(n){return new RegExp(n.toString()+"|").exec("").length-1}function Vi(n,e){const t=n&&n.exec(e);return t&&t.index===0}const qi=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function Bt(n,{joinWith:e}){let t=0;return n.map(r=>{t+=1;const s=t;let o=ye(r),i="";for(;o.length>0;){const l=qi.exec(o);if(!l){i+=o;break}i+=o.substring(0,l.index),o=o.substring(l.index+l[0].length),l[0][0]==="\\"&&l[1]?i+="\\"+String(Number(l[1])+s):(i+=l[0],l[0]==="("&&t++)}return i}).map(r=>`(${r})`).join(e)}const Ki=/\b\B/,an="[a-zA-Z]\\w*",Ut="[a-zA-Z_]\\w*",cn="\\b\\d+(\\.\\d+)?",un="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",hn="\\b(0b[01]+)",Ji="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",Xi=(n={})=>{const e=/^#![ ]*\//;return n.binary&&(n.begin=re(e,/.*\b/,n.binary,/\b.*/)),K({scope:"meta",begin:e,end:/$/,relevance:0,"on:begin":(t,r)=>{t.index!==0&&r.ignoreMatch()}},n)},we={begin:"\\\\[\\s\\S]",relevance:0},Qi={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[we]},Yi={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[we]},eo={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},Ye=function(n,e,t={}){const r=K({scope:"comment",begin:n,end:e,contains:[]},t);r.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const s=Dt("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return r.contains.push({begin:re(/[ ]+/,"(",s,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),r},to=Ye("//","$"),ro=Ye("/\\*","\\*/"),no=Ye("#","$"),so={scope:"number",begin:cn,relevance:0},io={scope:"number",begin:un,relevance:0},oo={scope:"number",begin:hn,relevance:0},lo={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[we,{begin:/\[/,end:/\]/,relevance:0,contains:[we]}]},ao={scope:"title",begin:an,relevance:0},co={scope:"title",begin:Ut,relevance:0},uo={begin:"\\.\\s*"+Ut,relevance:0},ho=function(n){return Object.assign(n,{"on:begin":(e,t)=>{t.data._beginMatch=e[1]},"on:end":(e,t)=>{t.data._beginMatch!==e[1]&&t.ignoreMatch()}})};var Ie=Object.freeze({__proto__:null,APOS_STRING_MODE:Qi,BACKSLASH_ESCAPE:we,BINARY_NUMBER_MODE:oo,BINARY_NUMBER_RE:hn,COMMENT:Ye,C_BLOCK_COMMENT_MODE:ro,C_LINE_COMMENT_MODE:to,C_NUMBER_MODE:io,C_NUMBER_RE:un,END_SAME_AS_BEGIN:ho,HASH_COMMENT_MODE:no,IDENT_RE:an,MATCH_NOTHING_RE:Ki,METHOD_GUARD:uo,NUMBER_MODE:so,NUMBER_RE:cn,PHRASAL_WORDS_MODE:eo,QUOTE_STRING_MODE:Yi,REGEXP_MODE:lo,RE_STARTERS_RE:Ji,SHEBANG:Xi,TITLE_MODE:ao,UNDERSCORE_IDENT_RE:Ut,UNDERSCORE_TITLE_MODE:co});function fo(n,e){n.input[n.index-1]==="."&&e.ignoreMatch()}function po(n,e){n.className!==void 0&&(n.scope=n.className,delete n.className)}function go(n,e){e&&n.beginKeywords&&(n.begin="\\b("+n.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",n.__beforeBegin=fo,n.keywords=n.keywords||n.beginKeywords,delete n.beginKeywords,n.relevance===void 0&&(n.relevance=0))}function mo(n,e){Array.isArray(n.illegal)&&(n.illegal=Dt(...n.illegal))}function bo(n,e){if(n.match){if(n.begin||n.end)throw new Error("begin & end are not supported with match");n.begin=n.match,delete n.match}}function yo(n,e){n.relevance===void 0&&(n.relevance=1)}const wo=(n,e)=>{if(!n.beforeMatch)return;if(n.starts)throw new Error("beforeMatch cannot be used with starts");const t=Object.assign({},n);Object.keys(n).forEach(r=>{delete n[r]}),n.keywords=t.keywords,n.begin=re(t.beforeMatch,on(t.begin)),n.starts={relevance:0,contains:[Object.assign(t,{endsParent:!0})]},n.relevance=0,delete t.beforeMatch},xo=["of","and","for","in","not","or","if","then","parent","list","value"],vo="keyword";function fn(n,e,t=vo){const r=Object.create(null);return typeof n=="string"?s(t,n.split(" ")):Array.isArray(n)?s(t,n):Object.keys(n).forEach(function(o){Object.assign(r,fn(n[o],e,o))}),r;function s(o,i){e&&(i=i.map(l=>l.toLowerCase())),i.forEach(function(l){const a=l.split("|");r[a[0]]=[o,Eo(a[0],a[1])]})}}function Eo(n,e){return e?Number(e):ko(n)?0:1}function ko(n){return xo.includes(n.toLowerCase())}const gr={},ee=n=>{console.error(n)},mr=(n,...e)=>{console.log(`WARN: ${n}`,...e)},se=(n,e)=>{gr[`${n}/${e}`]||(console.log(`Deprecated as of ${n}. ${e}`),gr[`${n}/${e}`]=!0)},Ge=new Error;function dn(n,e,{key:t}){let r=0;const s=n[t],o={},i={};for(let l=1;l<=e.length;l++)i[l+r]=s[l],o[l+r]=!0,r+=ln(e[l-1]);n[t]=i,n[t]._emit=o,n[t]._multi=!0}function So(n){if(Array.isArray(n.begin)){if(n.skip||n.excludeBegin||n.returnBegin)throw ee("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Ge;if(typeof n.beginScope!="object"||n.beginScope===null)throw ee("beginScope must be object"),Ge;dn(n,n.begin,{key:"beginScope"}),n.begin=Bt(n.begin,{joinWith:""})}}function Co(n){if(Array.isArray(n.end)){if(n.skip||n.excludeEnd||n.returnEnd)throw ee("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Ge;if(typeof n.endScope!="object"||n.endScope===null)throw ee("endScope must be object"),Ge;dn(n,n.end,{key:"endScope"}),n.end=Bt(n.end,{joinWith:""})}}function _o(n){n.scope&&typeof n.scope=="object"&&n.scope!==null&&(n.beginScope=n.scope,delete n.scope)}function Oo(n){_o(n),typeof n.beginScope=="string"&&(n.beginScope={_wrap:n.beginScope}),typeof n.endScope=="string"&&(n.endScope={_wrap:n.endScope}),So(n),Co(n)}function Ao(n){function e(i,l){return new RegExp(ye(i),"m"+(n.case_insensitive?"i":"")+(n.unicodeRegex?"u":"")+(l?"g":""))}class t{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(l,a){a.position=this.position++,this.matchIndexes[this.matchAt]=a,this.regexes.push([a,l]),this.matchAt+=ln(l)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const l=this.regexes.map(a=>a[1]);this.matcherRe=e(Bt(l,{joinWith:"|"}),!0),this.lastIndex=0}exec(l){this.matcherRe.lastIndex=this.lastIndex;const a=this.matcherRe.exec(l);if(!a)return null;const u=a.findIndex((y,m)=>m>0&&y!==void 0),f=this.matchIndexes[u];return a.splice(0,u),Object.assign(a,f)}}class r{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(l){if(this.multiRegexes[l])return this.multiRegexes[l];const a=new t;return this.rules.slice(l).forEach(([u,f])=>a.addRule(u,f)),a.compile(),this.multiRegexes[l]=a,a}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(l,a){this.rules.push([l,a]),a.type==="begin"&&this.count++}exec(l){const a=this.getMatcher(this.regexIndex);a.lastIndex=this.lastIndex;let u=a.exec(l);if(this.resumingScanAtSamePosition()&&!(u&&u.index===this.lastIndex)){const f=this.getMatcher(0);f.lastIndex=this.lastIndex+1,u=f.exec(l)}return u&&(this.regexIndex+=u.position+1,this.regexIndex===this.count&&this.considerAll()),u}}function s(i){const l=new r;return i.contains.forEach(a=>l.addRule(a.begin,{rule:a,type:"begin"})),i.terminatorEnd&&l.addRule(i.terminatorEnd,{type:"end"}),i.illegal&&l.addRule(i.illegal,{type:"illegal"}),l}function o(i,l){const a=i;if(i.isCompiled)return a;[po,bo,Oo,wo].forEach(f=>f(i,l)),n.compilerExtensions.forEach(f=>f(i,l)),i.__beforeBegin=null,[go,mo,yo].forEach(f=>f(i,l)),i.isCompiled=!0;let u=null;return typeof i.keywords=="object"&&i.keywords.$pattern&&(i.keywords=Object.assign({},i.keywords),u=i.keywords.$pattern,delete i.keywords.$pattern),u=u||/\w+/,i.keywords&&(i.keywords=fn(i.keywords,n.case_insensitive)),a.keywordPatternRe=e(u,!0),l&&(i.begin||(i.begin=/\B|\b/),a.beginRe=e(a.begin),!i.end&&!i.endsWithParent&&(i.end=/\B|\b/),i.end&&(a.endRe=e(a.end)),a.terminatorEnd=ye(a.end)||"",i.endsWithParent&&l.terminatorEnd&&(a.terminatorEnd+=(i.end?"|":"")+l.terminatorEnd)),i.illegal&&(a.illegalRe=e(i.illegal)),i.contains||(i.contains=[]),i.contains=[].concat(...i.contains.map(function(f){return Ro(f==="self"?i:f)})),i.contains.forEach(function(f){o(f,a)}),i.starts&&o(i.starts,l),a.matcher=s(a),a}if(n.compilerExtensions||(n.compilerExtensions=[]),n.contains&&n.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return n.classNameAliases=K(n.classNameAliases||{}),o(n)}function pn(n){return n?n.endsWithParent||pn(n.starts):!1}function Ro(n){return n.variants&&!n.cachedVariants&&(n.cachedVariants=n.variants.map(function(e){return K(n,{variants:null},e)})),n.cachedVariants?n.cachedVariants:pn(n)?K(n,{starts:n.starts?K(n.starts):null}):Object.isFrozen(n)?K(n):n}var Lo="11.9.0";class No extends Error{constructor(e,t){super(e),this.name="HTMLInjectionError",this.html=t}}const ft=sn,br=K,yr=Symbol("nomatch"),Po=7,gn=function(n){const e=Object.create(null),t=Object.create(null),r=[];let s=!0;const o="Could not find the language '{}', did you forget to load/include a language module?",i={disableAutodetect:!0,name:"Plain text",contains:[]};let l={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:Hi};function a(h){return l.noHighlightRe.test(h)}function u(h){let p=h.className+" ";p+=h.parentNode?h.parentNode.className:"";const x=l.languageDetectRe.exec(p);if(x){const E=M(x[1]);return E||(mr(o.replace("{}",x[1])),mr("Falling back to no-highlight mode for this block.",h)),E?x[1]:"no-highlight"}return p.split(/\s+/).find(E=>a(E)||M(E))}function f(h,p,x){let E="",R="";typeof p=="object"?(E=h,x=p.ignoreIllegals,R=p.language):(se("10.7.0","highlight(lang, code, ...args) has been deprecated."),se("10.7.0",`Please use highlight(code, options) instead.
|
|
183
|
+
https://github.com/highlightjs/highlight.js/issues/2277`),R=h,E=p),x===void 0&&(x=!0);const T={code:E,language:R};Q("before:highlight",T);const q=T.result?T.result:y(T.language,T.code,x);return q.code=T.code,Q("after:highlight",q),q}function y(h,p,x,E){const R=Object.create(null);function T(d,g){return d.keywords[g]}function q(){if(!w.keywords){N.addText(C);return}let d=0;w.keywordPatternRe.lastIndex=0;let g=w.keywordPatternRe.exec(C),v="";for(;g;){v+=C.substring(d,g.index);const S=U.case_insensitive?g[0].toLowerCase():g[0],P=T(w,S);if(P){const[Z,Rn]=P;if(N.addText(v),v="",R[S]=(R[S]||0)+1,R[S]<=Po&&(Ce+=Rn),Z.startsWith("_"))v+=g[0];else{const Ln=U.classNameAliases[Z]||Z;B(g[0],Ln)}}else v+=g[0];d=w.keywordPatternRe.lastIndex,g=w.keywordPatternRe.exec(C)}v+=C.substring(d),N.addText(v)}function ke(){if(C==="")return;let d=null;if(typeof w.subLanguage=="string"){if(!e[w.subLanguage]){N.addText(C);return}d=y(w.subLanguage,C,!0,Zt[w.subLanguage]),Zt[w.subLanguage]=d._top}else d=A(C,w.subLanguage.length?w.subLanguage:null);w.relevance>0&&(Ce+=d.relevance),N.__addSublanguage(d._emitter,d.language)}function I(){w.subLanguage!=null?ke():q(),C=""}function B(d,g){d!==""&&(N.startScope(g),N.addText(d),N.endScope())}function Ft(d,g){let v=1;const S=g.length-1;for(;v<=S;){if(!d._emit[v]){v++;continue}const P=U.classNameAliases[d[v]]||d[v],Z=g[v];P?B(Z,P):(C=Z,q(),C=""),v++}}function Ht(d,g){return d.scope&&typeof d.scope=="string"&&N.openNode(U.classNameAliases[d.scope]||d.scope),d.beginScope&&(d.beginScope._wrap?(B(C,U.classNameAliases[d.beginScope._wrap]||d.beginScope._wrap),C=""):d.beginScope._multi&&(Ft(d.beginScope,g),C="")),w=Object.create(d,{parent:{value:w}}),w}function Wt(d,g,v){let S=Vi(d.endRe,v);if(S){if(d["on:end"]){const P=new fr(d);d["on:end"](g,P),P.isMatchIgnored&&(S=!1)}if(S){for(;d.endsParent&&d.parent;)d=d.parent;return d}}if(d.endsWithParent)return Wt(d.parent,g,v)}function Sn(d){return w.matcher.regexIndex===0?(C+=d[0],1):(lt=!0,0)}function Cn(d){const g=d[0],v=d.rule,S=new fr(v),P=[v.__beforeBegin,v["on:begin"]];for(const Z of P)if(Z&&(Z(d,S),S.isMatchIgnored))return Sn(g);return v.skip?C+=g:(v.excludeBegin&&(C+=g),I(),!v.returnBegin&&!v.excludeBegin&&(C=g)),Ht(v,d),v.returnBegin?0:g.length}function _n(d){const g=d[0],v=p.substring(d.index),S=Wt(w,d,v);if(!S)return yr;const P=w;w.endScope&&w.endScope._wrap?(I(),B(g,w.endScope._wrap)):w.endScope&&w.endScope._multi?(I(),Ft(w.endScope,d)):P.skip?C+=g:(P.returnEnd||P.excludeEnd||(C+=g),I(),P.excludeEnd&&(C=g));do w.scope&&N.closeNode(),!w.skip&&!w.subLanguage&&(Ce+=w.relevance),w=w.parent;while(w!==S.parent);return S.starts&&Ht(S.starts,d),P.returnEnd?0:g.length}function On(){const d=[];for(let g=w;g!==U;g=g.parent)g.scope&&d.unshift(g.scope);d.forEach(g=>N.openNode(g))}let Se={};function Gt(d,g){const v=g&&g[0];if(C+=d,v==null)return I(),0;if(Se.type==="begin"&&g.type==="end"&&Se.index===g.index&&v===""){if(C+=p.slice(g.index,g.index+1),!s){const S=new Error(`0 width match regex (${h})`);throw S.languageName=h,S.badRule=Se.rule,S}return 1}if(Se=g,g.type==="begin")return Cn(g);if(g.type==="illegal"&&!x){const S=new Error('Illegal lexeme "'+v+'" for mode "'+(w.scope||"<unnamed>")+'"');throw S.mode=w,S}else if(g.type==="end"){const S=_n(g);if(S!==yr)return S}if(g.type==="illegal"&&v==="")return 1;if(ot>1e5&&ot>g.index*3)throw new Error("potential infinite loop, way more iterations than matches");return C+=v,v.length}const U=M(h);if(!U)throw ee(o.replace("{}",h)),new Error('Unknown language: "'+h+'"');const An=Ao(U);let it="",w=E||An;const Zt={},N=new l.__emitter(l);On();let C="",Ce=0,Y=0,ot=0,lt=!1;try{if(U.__emitTokens)U.__emitTokens(p,N);else{for(w.matcher.considerAll();;){ot++,lt?lt=!1:w.matcher.considerAll(),w.matcher.lastIndex=Y;const d=w.matcher.exec(p);if(!d)break;const g=p.substring(Y,d.index),v=Gt(g,d);Y=d.index+v}Gt(p.substring(Y))}return N.finalize(),it=N.toHTML(),{language:h,value:it,relevance:Ce,illegal:!1,_emitter:N,_top:w}}catch(d){if(d.message&&d.message.includes("Illegal"))return{language:h,value:ft(p),illegal:!0,relevance:0,_illegalBy:{message:d.message,index:Y,context:p.slice(Y-100,Y+100),mode:d.mode,resultSoFar:it},_emitter:N};if(s)return{language:h,value:ft(p),illegal:!1,relevance:0,errorRaised:d,_emitter:N,_top:w};throw d}}function m(h){const p={value:ft(h),illegal:!1,relevance:0,_top:i,_emitter:new l.__emitter(l)};return p._emitter.addText(h),p}function A(h,p){p=p||l.languages||Object.keys(e);const x=m(h),E=p.filter(M).filter(Ee).map(I=>y(I,h,!1));E.unshift(x);const R=E.sort((I,B)=>{if(I.relevance!==B.relevance)return B.relevance-I.relevance;if(I.language&&B.language){if(M(I.language).supersetOf===B.language)return 1;if(M(B.language).supersetOf===I.language)return-1}return 0}),[T,q]=R,ke=T;return ke.secondBest=q,ke}function L(h,p,x){const E=p&&t[p]||x;h.classList.add("hljs"),h.classList.add(`language-${E}`)}function $(h){let p=null;const x=u(h);if(a(x))return;if(Q("before:highlightElement",{el:h,language:x}),h.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",h);return}if(h.children.length>0&&(l.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(h)),l.throwUnescapedHTML))throw new No("One of your code blocks includes unescaped HTML.",h.innerHTML);p=h;const E=p.textContent,R=x?f(E,{language:x,ignoreIllegals:!0}):A(E);h.innerHTML=R.value,h.dataset.highlighted="yes",L(h,x,R.language),h.result={language:R.language,re:R.relevance,relevance:R.relevance},R.secondBest&&(h.secondBest={language:R.secondBest.language,relevance:R.secondBest.relevance}),Q("after:highlightElement",{el:h,result:R,text:E})}function b(h){l=br(l,h)}const H=()=>{j(),se("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function W(){j(),se("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let J=!1;function j(){if(document.readyState==="loading"){J=!0;return}document.querySelectorAll(l.cssSelector).forEach($)}function G(){J&&j()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",G,!1);function ce(h,p){let x=null;try{x=p(n)}catch(E){if(ee("Language definition for '{}' could not be registered.".replace("{}",h)),s)ee(E);else throw E;x=i}x.name||(x.name=h),e[h]=x,x.rawDefinition=p.bind(null,n),x.aliases&&X(x.aliases,{languageName:h})}function ne(h){delete e[h];for(const p of Object.keys(t))t[p]===h&&delete t[p]}function D(){return Object.keys(e)}function M(h){return h=(h||"").toLowerCase(),e[h]||e[t[h]]}function X(h,{languageName:p}){typeof h=="string"&&(h=[h]),h.forEach(x=>{t[x.toLowerCase()]=p})}function Ee(h){const p=M(h);return p&&!p.disableAutodetect}function tt(h){h["before:highlightBlock"]&&!h["before:highlightElement"]&&(h["before:highlightElement"]=p=>{h["before:highlightBlock"](Object.assign({block:p.el},p))}),h["after:highlightBlock"]&&!h["after:highlightElement"]&&(h["after:highlightElement"]=p=>{h["after:highlightBlock"](Object.assign({block:p.el},p))})}function rt(h){tt(h),r.push(h)}function nt(h){const p=r.indexOf(h);p!==-1&&r.splice(p,1)}function Q(h,p){const x=h;r.forEach(function(E){E[x]&&E[x](p)})}function st(h){return se("10.7.0","highlightBlock will be removed entirely in v12.0"),se("10.7.0","Please use highlightElement now."),$(h)}Object.assign(n,{highlight:f,highlightAuto:A,highlightAll:j,highlightElement:$,highlightBlock:st,configure:b,initHighlighting:H,initHighlightingOnLoad:W,registerLanguage:ce,unregisterLanguage:ne,listLanguages:D,getLanguage:M,registerAliases:X,autoDetection:Ee,inherit:br,addPlugin:rt,removePlugin:nt}),n.debugMode=function(){s=!1},n.safeMode=function(){s=!0},n.versionString=Lo,n.regex={concat:re,lookahead:on,either:Dt,optional:Gi,anyNumberOfTimes:Wi};for(const h in Ie)typeof Ie[h]=="object"&&nn(Ie[h]);return Object.assign(n,Ie),n},ae=gn({});ae.newInstance=()=>gn({});var Mo=ae;ae.HighlightJS=ae;ae.default=ae;const et=Di(Mo),Ze="[A-Za-z$_][0-9A-Za-z$_]*",mn=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],bn=["true","false","null","undefined","NaN","Infinity"],yn=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],wn=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],xn=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],vn=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],En=[].concat(xn,yn,wn);function To(n){const e=n.regex,t=(h,{after:p})=>{const x="</"+h[0].slice(1);return h.input.indexOf(x,p)!==-1},r=Ze,s={begin:"<>",end:"</>"},o=/<[A-Za-z0-9\\._:-]+\s*\/>/,i={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(h,p)=>{const x=h[0].length+h.index,E=h.input[x];if(E==="<"||E===","){p.ignoreMatch();return}E===">"&&(t(h,{after:x})||p.ignoreMatch());let R;const T=h.input.substring(x);if(R=T.match(/^\s*=/)){p.ignoreMatch();return}if((R=T.match(/^\s+extends\s+/))&&R.index===0){p.ignoreMatch();return}}},l={$pattern:Ze,keyword:mn,literal:bn,built_in:En,"variable.language":vn},a="[0-9](_?[0-9])*",u=`\\.(${a})`,f="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",y={className:"number",variants:[{begin:`(\\b(${f})((${u})|\\.)?|(${u}))[eE][+-]?(${a})\\b`},{begin:`\\b(${f})\\b((${u})\\b|\\.)?|(${u})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},m={className:"subst",begin:"\\$\\{",end:"\\}",keywords:l,contains:[]},A={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"xml"}},L={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"css"}},$={begin:"gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[n.BACKSLASH_ESCAPE,m],subLanguage:"graphql"}},b={className:"string",begin:"`",end:"`",contains:[n.BACKSLASH_ESCAPE,m]},H={className:"comment",variants:[n.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:r+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),n.C_BLOCK_COMMENT_MODE,n.C_LINE_COMMENT_MODE]},W=[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE,A,L,$,b,{match:/\$\d+/},y];m.contains=W.concat({begin:/\{/,end:/\}/,keywords:l,contains:["self"].concat(W)});const J=[].concat(H,m.contains),j=J.concat([{begin:/\(/,end:/\)/,keywords:l,contains:["self"].concat(J)}]),G={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:j},ce={variants:[{match:[/class/,/\s+/,r,/\s+/,/extends/,/\s+/,e.concat(r,"(",e.concat(/\./,r),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,r],scope:{1:"keyword",3:"title.class"}}]},ne={relevance:0,match:e.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...yn,...wn]}},D={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},M={variants:[{match:[/function/,/\s+/,r,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[G],illegal:/%/},X={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function Ee(h){return e.concat("(?!",h.join("|"),")")}const tt={match:e.concat(/\b/,Ee([...xn,"super","import"]),r,e.lookahead(/\(/)),className:"title.function",relevance:0},rt={begin:e.concat(/\./,e.lookahead(e.concat(r,/(?![0-9A-Za-z$_(])/))),end:r,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},nt={match:[/get|set/,/\s+/,r,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},G]},Q="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+n.UNDERSCORE_IDENT_RE+")\\s*=>",st={match:[/const|var|let/,/\s+/,r,/\s*/,/=\s*/,/(async\s*)?/,e.lookahead(Q)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[G]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:l,exports:{PARAMS_CONTAINS:j,CLASS_REFERENCE:ne},illegal:/#(?![$_A-z])/,contains:[n.SHEBANG({label:"shebang",binary:"node",relevance:5}),D,n.APOS_STRING_MODE,n.QUOTE_STRING_MODE,A,L,$,b,H,{match:/\$\d+/},y,ne,{className:"attr",begin:r+e.lookahead(":"),relevance:0},st,{begin:"("+n.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[H,n.REGEXP_MODE,{className:"function",begin:Q,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:n.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:l,contains:j}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:s.begin,end:s.end},{match:o},{begin:i.begin,"on:begin":i.isTrulyOpeningTag,end:i.end}],subLanguage:"xml",contains:[{begin:i.begin,end:i.end,skip:!0,contains:["self"]}]}]},M,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+n.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[G,n.inherit(n.TITLE_MODE,{begin:r,className:"title.function"})]},{match:/\.\.\./,relevance:0},rt,{match:"\\$"+r,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[G]},tt,X,ce,nt,{match:/\$[(.]/}]}}function Io(n){const e=To(n),t=Ze,r=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],s={beginKeywords:"namespace",end:/\{/,excludeEnd:!0,contains:[e.exports.CLASS_REFERENCE]},o={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:r},contains:[e.exports.CLASS_REFERENCE]},i={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},l=["type","namespace","interface","public","private","protected","implements","declare","abstract","readonly","enum","override"],a={$pattern:Ze,keyword:mn.concat(l),literal:bn,built_in:En.concat(r),"variable.language":vn},u={className:"meta",begin:"@"+t},f=(m,A,L)=>{const $=m.contains.findIndex(b=>b.label===A);if($===-1)throw new Error("can not find mode to replace");m.contains.splice($,1,L)};Object.assign(e.keywords,a),e.exports.PARAMS_CONTAINS.push(u),e.contains=e.contains.concat([u,s,o]),f(e,"shebang",n.SHEBANG()),f(e,"use_strict",i);const y=e.contains.find(m=>m.label==="func.def");return y.relevance=0,Object.assign(e,{name:"TypeScript",aliases:["ts","tsx","mts","cts"]}),e}function $o(n){const e=n.regex,t=e.concat(/[\p{L}_]/u,e.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),r=/[\p{L}0-9._:-]+/u,s={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},o={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},i=n.inherit(o,{begin:/\(/,end:/\)/}),l=n.inherit(n.APOS_STRING_MODE,{className:"string"}),a=n.inherit(n.QUOTE_STRING_MODE,{className:"string"}),u={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:r,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[s]},{begin:/'/,end:/'/,contains:[s]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[o,a,l,i,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[o,i,a,l]}]}]},n.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},s,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[a]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[u],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[u],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:e.concat(/</,e.lookahead(e.concat(t,e.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:t,relevance:0,starts:u}]},{className:"tag",begin:e.concat(/<\//,e.lookahead(e.concat(t,/>/))),contains:[{className:"name",begin:t,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const jo=n=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:n.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:n.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),zo=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],Do=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],Bo=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],Uo=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],Fo=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse();function Ho(n){const e=n.regex,t=jo(n),r={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},s="and or not only",o=/@-?\w[\w]*(-\w+)*/,i="[a-zA-Z-][a-zA-Z0-9_-]*",l=[n.APOS_STRING_MODE,n.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[t.BLOCK_COMMENT,r,t.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+i,relevance:0},t.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+Bo.join("|")+")"},{begin:":(:)?("+Uo.join("|")+")"}]},t.CSS_VARIABLE,{className:"attribute",begin:"\\b("+Fo.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[t.BLOCK_COMMENT,t.HEXCOLOR,t.IMPORTANT,t.CSS_NUMBER_MODE,...l,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...l,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},t.FUNCTION_DISPATCH]},{begin:e.lookahead(/@/),end:"[{;]",relevance:0,illegal:/:/,contains:[{className:"keyword",begin:o},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:s,attribute:Do.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...l,t.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+zo.join("|")+")\\b"}]}}const kn=document.createElement("style");kn.innerText=[ji,zi].join(`
|
|
184
184
|
`);document.head.appendChild(kn);et.registerLanguage("typescript",Io);et.registerLanguage("html",$o);et.registerLanguage("css",Ho);function Wo(...n){const e=document.createElement("div"),t=document.createElement("div");t.classList.add("tab-control");const r=document.createElement("div");return n.forEach(s=>{e.appendChild(s),s.addEventListener("click",()=>{n.forEach(o=>o.removeAttribute("selected")),s.setAttribute("selected",""),r.innerHTML="",r.appendChild(s.content),r.className=s.className,r.classList.add("tab-content")})}),t.appendChild(e),t.appendChild(r),r.classList.add("tab-content"),n[0].setAttribute("selected",""),r.appendChild(n[0].content),t}function fe(n,e){const t=document.createElement("div");return t.role="tab",t.tabIndex=0,t.innerText=n,t.content=e,e.tagName=="PRE"&&t.classList.add("code"),t}function de(n,e){const t=document.createElement(n);return typeof e=="string"?t.innerHTML=e:e.forEach(r=>{t.appendChild(r)}),t}async function Go(n,e,t){var r,s,o;const i=e.mainContent,l=de("div",i);l.id=`example-preview-${t}`;const a=typeof e.css=="string"||(r=e.css)==null?void 0:r.label,u=typeof e.css=="string"?e.css:(s=e.css)==null?void 0:s.content,f=Wo(fe("Preview",l),fe("HTML",$e("html",i)),...u?[fe(a??"CSS",$e("css",u))]:[],...e.initializer&&e.initializer.content?[fe(e.initializer.label??"TS",$e("typescript",e.initializer.content))]:[],...(e.additionalSources||[]).map(m=>fe(m.label,$e(m.language,m.content))));e.description&&n.appendChild(de("div",e.description));const y=de("div",[f]);y.classList.add("example"),n.appendChild(y),u&&Zo(`#${l.id}`,u),(o=e.initializer)!=null&&o.initialize&&await e.initializer.initialize(l)}function $e(n,e){let t=e.split(/\r?\n/).map(r=>{const s=r.indexOf("///");if(s>-1){const o=r.substring(s+3).trimStart();return o?r.replace(/^(\s*)([^\s].*)$/,`$1${o}`):void 0}return r}).filter(r=>typeof r<"u").join(`
|
|
185
|
-
`).trim();return n&&n!="raw"&&(t=et.highlight(t,{language:n}).value),de("pre",[de("code",t)])}function Zo(n,e){const t=document.createElement("style");t.innerHTML=O().use($i({prefix:n})).process(e).css,document.head.appendChild(t)}async function Vo(n,e=document.body){const t=
|
|
185
|
+
`).trim();return n&&n!="raw"&&(t=et.highlight(t,{language:n}).value),de("pre",[de("code",t)])}function Zo(n,e){const t=document.createElement("style");t.innerHTML=O().use($i({prefix:n})).process(e).css,document.head.appendChild(t)}async function Vo(n,e=document.body){const t=Ko(e);let r=0;Object.keys(n).forEach(async s=>{const o=document.createElement("div");o.className="example-container",t.appendChild(o);const i=n[s].default;Go(o,i,r++)})}function qo(n){const e=document.createElement("div");e.id="examples-container";const t=n.querySelector("#examples");return t?t.after(e):n.appendChild(e),e}function Ko(n){return n.children?qo(n):n}const Jo=`<h1 id="@cas-smartdesign/swatch-picker">@cas-smartdesign/swatch-picker</h1>
|
|
186
186
|
<p>A color picker element.</p>
|
|
187
187
|
<h2 id="attributes">Attributes</h2>
|
|
188
188
|
<ul>
|
|
@@ -220,8 +220,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`),R=h,E=p),x===void 0&&(
|
|
|
220
220
|
</ul>
|
|
221
221
|
</li>
|
|
222
222
|
</ul>
|
|
223
|
-
|
|
224
|
-
`;document.querySelector("#markdown-container").innerHTML=Jo;Vo(Object.assign({"./examples/1_declarative/index.ts":Tn,"./examples/2_create-from-source/index.ts":Fn}));export{Be as S};
|
|
223
|
+
`,Xo=document.querySelector("#markdown-container");Xo.innerHTML=Jo;Vo(Object.assign({"./examples/1_declarative/index.ts":Tn,"./examples/2_create-from-source/index.ts":Fn}),document.querySelector(".markdown-body"));export{Be as S};
|
|
225
224
|
function __vite__mapDeps(indexes) {
|
|
226
225
|
if (!__vite__mapDeps.viteFileDeps) {
|
|
227
226
|
__vite__mapDeps.viteFileDeps = []
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cas-smartdesign/swatch-picker",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"description": "A color picker element which has the look and feel of the smartdesign color picker",
|
|
5
5
|
"main": "dist/swatch-picker-with-externals.js",
|
|
6
6
|
"module": "dist/swatch-picker.mjs",
|
|
7
7
|
"types": "dist/swatch-picker.d.ts",
|
|
8
8
|
"license": "SEE LICENSE IN LICENSE",
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@cas-smartdesign/
|
|
11
|
-
"@cas-smartdesign/
|
|
10
|
+
"@cas-smartdesign/design-tokens": "^1.7.2",
|
|
11
|
+
"@cas-smartdesign/element-base": "^5.0.2"
|
|
12
12
|
},
|
|
13
13
|
"files": [
|
|
14
14
|
"dist",
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"access": "public"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@cas-smartdesign/element-preview": "^0.2.
|
|
23
|
-
"@cas-smartdesign/license-generator": "^1.6.
|
|
22
|
+
"@cas-smartdesign/element-preview": "^0.2.2",
|
|
23
|
+
"@cas-smartdesign/license-generator": "^1.6.3"
|
|
24
24
|
},
|
|
25
25
|
"scripts": {
|
|
26
26
|
"version": "pnpm version",
|