@vscode-elements/elements 2.4.1-pre.0 → 2.5.0
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/LICENSE +1 -1
- package/custom-elements.json +752 -708
- package/dist/bundled.js +40 -40
- package/dist/includes/VscElement.js +1 -1
- package/dist/includes/VscElement.js.map +1 -1
- package/dist/includes/sizes.d.ts +12 -0
- package/dist/includes/sizes.d.ts.map +1 -0
- package/dist/includes/sizes.js +30 -0
- package/dist/includes/sizes.js.map +1 -0
- package/dist/includes/vscode-select/styles.d.ts.map +1 -1
- package/dist/includes/vscode-select/styles.js +12 -14
- package/dist/includes/vscode-select/styles.js.map +1 -1
- package/dist/vscode-button/vscode-button.styles.js +4 -4
- package/dist/vscode-button/vscode-button.styles.js.map +1 -1
- package/dist/vscode-checkbox/vscode-checkbox.js +1 -1
- package/dist/vscode-checkbox/vscode-checkbox.js.map +1 -1
- package/dist/vscode-collapsible/vscode-collapsible.d.ts +1 -1
- package/dist/vscode-collapsible/vscode-collapsible.d.ts.map +1 -1
- package/dist/vscode-collapsible/vscode-collapsible.js +5 -3
- package/dist/vscode-collapsible/vscode-collapsible.js.map +1 -1
- package/dist/vscode-icon/vscode-icon.js +1 -1
- package/dist/vscode-icon/vscode-icon.js.map +1 -1
- package/dist/vscode-multi-select/vscode-multi-select.js +1 -1
- package/dist/vscode-multi-select/vscode-multi-select.js.map +1 -1
- package/dist/vscode-radio/vscode-radio.js +1 -1
- package/dist/vscode-radio/vscode-radio.js.map +1 -1
- package/dist/vscode-single-select/vscode-single-select.js +1 -1
- package/dist/vscode-single-select/vscode-single-select.js.map +1 -1
- package/dist/vscode-table/ColumnResizeController.d.ts +4 -3
- package/dist/vscode-table/ColumnResizeController.d.ts.map +1 -1
- package/dist/vscode-table/ColumnResizeController.js +10 -5
- package/dist/vscode-table/ColumnResizeController.js.map +1 -1
- package/dist/vscode-table/calculations.d.ts +2 -12
- package/dist/vscode-table/calculations.d.ts.map +1 -1
- package/dist/vscode-table/calculations.js +4 -32
- package/dist/vscode-table/calculations.js.map +1 -1
- package/dist/vscode-table/vscode-table.d.ts +2 -0
- package/dist/vscode-table/vscode-table.d.ts.map +1 -1
- package/dist/vscode-table/vscode-table.js +55 -28
- package/dist/vscode-table/vscode-table.js.map +1 -1
- package/dist/vscode-table-header-cell/vscode-table-header-cell.d.ts +12 -1
- package/dist/vscode-table-header-cell/vscode-table-header-cell.d.ts.map +1 -1
- package/dist/vscode-table-header-cell/vscode-table-header-cell.js +18 -0
- package/dist/vscode-table-header-cell/vscode-table-header-cell.js.map +1 -1
- package/dist/vscode-textarea/vscode-textarea.styles.js +1 -1
- package/dist/vscode-textarea/vscode-textarea.styles.js.map +1 -1
- package/dist/vscode-textfield/vscode-textfield.js +1 -1
- package/dist/vscode-textfield/vscode-textfield.js.map +1 -1
- package/dist/vscode-textfield/vscode-textfield.styles.js +1 -1
- package/dist/vscode-textfield/vscode-textfield.styles.js.map +1 -1
- package/package.json +1 -2
- package/vscode.css-custom-data.json +18 -18
- package/vscode.html-custom-data.json +34 -34
package/dist/bundled.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),s=new WeakMap;let o=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=s.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&s.set(i,t))}return t}toString(){return this.cssText}};const r=t=>new o("string"==typeof t?t:t+"",void 0,i),n=(t,...e)=>{const s=1===t.length?t[0]:e.reduce(((e,i,s)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[s+1]),t[0]);return new o(s,t,i)},h=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return r(e)})(t):t,{is:a,defineProperty:l,getOwnPropertyDescriptor:c,getOwnPropertyNames:d,getOwnPropertySymbols:u,getPrototypeOf:p}=Object,v=globalThis,b=v.trustedTypes,f=b?b.emptyScript:"",g=v.reactiveElementPolyfillSupport,m=(t,e)=>t,x={toAttribute(t,e){switch(e){case Boolean:t=t?f:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},w=(t,e)=>!a(t,e),y={attribute:!0,type:String,converter:x,reflect:!1,useDefault:!1,hasChanged:w};Symbol.metadata??=Symbol("metadata"),v.litPropertyMetadata??=new WeakMap;let k=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=y){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),s=this.getPropertyDescriptor(t,i,e);void 0!==s&&l(this.prototype,t,s)}}static getPropertyDescriptor(t,e,i){const{get:s,set:o}=c(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:s,set(e){const r=s?.call(this);o?.call(this,e),this.requestUpdate(t,r,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??y}static _$Ei(){if(this.hasOwnProperty(m("elementProperties")))return;const t=p(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(m("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(m("properties"))){const t=this.properties,e=[...d(t),...u(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(h(t))}else void 0!==t&&e.push(h(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const i=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((i,s)=>{if(e)i.adoptedStyleSheets=s.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const e of s){const s=document.createElement("style"),o=t.litNonce;void 0!==o&&s.setAttribute("nonce",o),s.textContent=e.cssText,i.appendChild(s)}})(i,this.constructor.elementStyles),i}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){const i=this.constructor.elementProperties.get(t),s=this.constructor._$Eu(t,i);if(void 0!==s&&!0===i.reflect){const o=(void 0!==i.converter?.toAttribute?i.converter:x).toAttribute(e,i.type);this._$Em=t,null==o?this.removeAttribute(s):this.setAttribute(s,o),this._$Em=null}}_$AK(t,e){const i=this.constructor,s=i._$Eh.get(t);if(void 0!==s&&this._$Em!==s){const t=i.getPropertyOptions(s),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:x;this._$Em=s,this[s]=o.fromAttribute(e,t.type)??this._$Ej?.get(s)??null,this._$Em=null}}requestUpdate(t,e,i){if(void 0!==t){const s=this.constructor,o=this[t];if(i??=s.getPropertyOptions(t),!((i.hasChanged??w)(o,e)||i.useDefault&&i.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:s,wrapped:o},r){i&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,r??e??this[t]),!0!==o||void 0!==r)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===s&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,s=this[e];!0!==t||this._$AL.has(e)||void 0===s||this.C(e,void 0,i,s)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach((t=>this._$ET(t,this[t]))),this._$EM()}updated(t){}firstUpdated(t){}};k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[m("elementProperties")]=new Map,k[m("finalized")]=new Map,g?.({ReactiveElement:k}),(v.reactiveElementVersions??=[]).push("2.1.0");const $=globalThis,_=$.trustedTypes,S=_?_.createPolicy("lit-html",{createHTML:t=>t}):void 0,C="$lit$",B=`lit$${Math.random().toFixed(9).slice(2)}$`,A="?"+B,O=`<${A}>`,z=document,E=()=>z.createComment(""),I=t=>null===t||"object"!=typeof t&&"function"!=typeof t,j=Array.isArray,M="[ \t\n\f\r]",D=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,F=/-->/g,P=/>/g,V=RegExp(`>|${M}(?:([^\\s"'>=/]+)(${M}*=${M}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),T=/'/g,N=/"/g,R=/^(?:script|style|textarea|title)$/i,L=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),U=L(1),H=L(2),G=Symbol.for("lit-noChange"),q=Symbol.for("lit-nothing"),W=new WeakMap,K=z.createTreeWalker(z,129);function X(t,e){if(!j(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==S?S.createHTML(e):e}const J=(t,e)=>{const i=t.length-1,s=[];let o,r=2===e?"<svg>":3===e?"<math>":"",n=D;for(let e=0;e<i;e++){const i=t[e];let h,a,l=-1,c=0;for(;c<i.length&&(n.lastIndex=c,a=n.exec(i),null!==a);)c=n.lastIndex,n===D?"!--"===a[1]?n=F:void 0!==a[1]?n=P:void 0!==a[2]?(R.test(a[2])&&(o=RegExp("</"+a[2],"g")),n=V):void 0!==a[3]&&(n=V):n===V?">"===a[0]?(n=o??D,l=-1):void 0===a[1]?l=-2:(l=n.lastIndex-a[2].length,h=a[1],n=void 0===a[3]?V:'"'===a[3]?N:T):n===N||n===T?n=V:n===F||n===P?n=D:(n=V,o=void 0);const d=n===V&&t[e+1].startsWith("/>")?" ":"";r+=n===D?i+O:l>=0?(s.push(h),i.slice(0,l)+C+i.slice(l)+B+d):i+B+(-2===l?e:d)}return[X(t,r+(t[i]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),s]};class Y{constructor({strings:t,_$litType$:e},i){let s;this.parts=[];let o=0,r=0;const n=t.length-1,h=this.parts,[a,l]=J(t,e);if(this.el=Y.createElement(a,i),K.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(s=K.nextNode())&&h.length<n;){if(1===s.nodeType){if(s.hasAttributes())for(const t of s.getAttributeNames())if(t.endsWith(C)){const e=l[r++],i=s.getAttribute(t).split(B),n=/([.?@])?(.*)/.exec(e);h.push({type:1,index:o,name:n[2],strings:i,ctor:"."===n[1]?et:"?"===n[1]?it:"@"===n[1]?st:tt}),s.removeAttribute(t)}else t.startsWith(B)&&(h.push({type:6,index:o}),s.removeAttribute(t));if(R.test(s.tagName)){const t=s.textContent.split(B),e=t.length-1;if(e>0){s.textContent=_?_.emptyScript:"";for(let i=0;i<e;i++)s.append(t[i],E()),K.nextNode(),h.push({type:2,index:++o});s.append(t[e],E())}}}else if(8===s.nodeType)if(s.data===A)h.push({type:2,index:o});else{let t=-1;for(;-1!==(t=s.data.indexOf(B,t+1));)h.push({type:7,index:o}),t+=B.length-1}o++}}static createElement(t,e){const i=z.createElement("template");return i.innerHTML=t,i}}function Z(t,e,i=t,s){if(e===G)return e;let o=void 0!==s?i._$Co?.[s]:i._$Cl;const r=I(e)?void 0:e._$litDirective$;return o?.constructor!==r&&(o?._$AO?.(!1),void 0===r?o=void 0:(o=new r(t),o._$AT(t,i,s)),void 0!==s?(i._$Co??=[])[s]=o:i._$Cl=o),void 0!==o&&(e=Z(t,o._$AS(t,e.values),o,s)),e}class Q{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,i,s){this.type=2,this._$AH=q,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=s,this._$Cv=s?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Z(this,t,e),I(t)?t===q||null==t||""===t?(this._$AH!==q&&this._$AR(),this._$AH=q):t!==this._$AH&&t!==G&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>j(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==q&&I(this._$AH)?this._$AA.nextSibling.data=t:this.T(z.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:i}=t,s="number"==typeof i?this._$AC(t):(void 0===i.el&&(i.el=Y.createElement(X(i.h,i.h[0]),this.options)),i);if(this._$AH?._$AD===s)this._$AH.p(e);else{const t=new class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:i}=this._$AD,s=(t?.creationScope??z).importNode(e,!0);K.currentNode=s;let o=K.nextNode(),r=0,n=0,h=i[0];for(;void 0!==h;){if(r===h.index){let e;2===h.type?e=new Q(o,o.nextSibling,this,t):1===h.type?e=new h.ctor(o,h.name,h.strings,this,t):6===h.type&&(e=new ot(o,this,t)),this._$AV.push(e),h=i[++n]}r!==h?.index&&(o=K.nextNode(),r++)}return K.currentNode=z,s}p(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}(s,this),i=t.u(this.options);t.p(e),this.T(i),this._$AH=t}}_$AC(t){let e=W.get(t.strings);return void 0===e&&W.set(t.strings,e=new Y(t)),e}k(t){j(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,s=0;for(const o of t)s===e.length?e.push(i=new Q(this.O(E()),this.O(E()),this,this.options)):i=e[s],i._$AI(o),s++;s<e.length&&(this._$AR(i&&i._$AB.nextSibling,s),e.length=s)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class tt{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,i,s,o){this.type=1,this._$AH=q,this._$AN=void 0,this.element=t,this.name=e,this._$AM=s,this.options=o,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=q}_$AI(t,e=this,i,s){const o=this.strings;let r=!1;if(void 0===o)t=Z(this,t,e,0),r=!I(t)||t!==this._$AH&&t!==G,r&&(this._$AH=t);else{const s=t;let n,h;for(t=o[0],n=0;n<o.length-1;n++)h=Z(this,s[i+n],e,n),h===G&&(h=this._$AH[n]),r||=!I(h)||h!==this._$AH[n],h===q?t=q:t!==q&&(t+=(h??"")+o[n+1]),this._$AH[n]=h}r&&!s&&this.j(t)}j(t){t===q?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class et extends tt{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===q?void 0:t}}class it extends tt{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==q)}}class st extends tt{constructor(t,e,i,s,o){super(t,e,i,s,o),this.type=5}_$AI(t,e=this){if((t=Z(this,t,e,0)??q)===G)return;const i=this._$AH,s=t===q&&i!==q||t.capture!==i.capture||t.once!==i.once||t.passive!==i.passive,o=t!==q&&(i===q||s);s&&this.element.removeEventListener(this.name,this,i),o&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class ot{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Z(this,t)}}const rt={I:Q},nt=$.litHtmlPolyfillSupport;nt?.(Y,Q),($.litHtmlVersions??=[]).push("3.3.0");const ht=(t,e,i)=>{const s=i?.renderBefore??e;let o=s._$litPart$;if(void 0===o){const t=i?.renderBefore??null;s._$litPart$=o=new Q(e.insertBefore(E(),t),t,void 0,i??{})}return o._$AI(t),o},at=globalThis;let lt=class extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=ht(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return G}};lt._$litElement$=!0,lt.finalized=!0,at.litElementHydrateSupport?.({LitElement:lt});const ct=at.litElementPolyfillSupport;ct?.({LitElement:lt}),(at.litElementVersions??=[]).push("4.2.0");const dt={attribute:!0,type:String,converter:x,reflect:!1,hasChanged:w},ut=(t=dt,e,i)=>{const{kind:s,metadata:o}=i;let r=globalThis.litPropertyMetadata.get(o);if(void 0===r&&globalThis.litPropertyMetadata.set(o,r=new Map),"setter"===s&&((t=Object.create(t)).wrapped=!0),r.set(i.name,t),"accessor"===s){const{name:s}=i;return{set(i){const o=e.get.call(this);e.set.call(this,i),this.requestUpdate(s,o,t)},init(e){return void 0!==e&&this.C(s,void 0,t,e),e}}}if("setter"===s){const{name:s}=i;return function(i){const o=this[s];e.call(this,i),this.requestUpdate(s,o,t)}}throw Error("Unsupported decorator location: "+s)};function pt(t){return(e,i)=>"object"==typeof i?ut(t,e,i):((t,e,i)=>{const s=e.hasOwnProperty(i);return e.constructor.createProperty(i,t),s?Object.getOwnPropertyDescriptor(e,i):void 0})(t,e,i)}function vt(t){return pt({...t,state:!0,attribute:!1})}const bt=(t,e,i)=>(i.configurable=!0,i.enumerable=!0,i);function ft(t,e){return(i,s,o)=>{const r=e=>e.renderRoot?.querySelector(t)??null;if(e){const{get:t,set:e}="object"==typeof s?i:o??(()=>{const t=Symbol();return{get(){return this[t]},set(e){this[t]=e}}})();return bt(0,0,{get(){let i=t.call(this);return void 0===i&&(i=r(this),(null!==i||this.hasUpdated)&&e.call(this,i)),i}})}return bt(0,0,{get(){return r(this)}})}}let gt;function mt(t){return(e,i)=>{const{slot:s,selector:o}=t??{},r="slot"+(s?`[name=${s}]`:":not([name])");return bt(0,0,{get(){const e=this.renderRoot?.querySelector(r),i=e?.assignedElements(t)??[];return void 0===o?i:i.filter((t=>t.matches(o)))}})}}const xt="2.4.1-pre.0",wt="__vscodeElements_disableRegistryWarning__",yt=(t,e)=>{e?console.warn(`[VSCode Elements] ${t}\n%o`,e):console.warn(`${t}\n%o`,e)};class kt extends lt{get version(){return xt}warn(t){yt(t,this)}}const $t=t=>e=>{if(!customElements.get(t))return void customElements.define(t,e);if(wt in window)return;const i=document.createElement(t),s=i?.version;let o="";s?s!==xt?(o+="is already registered by a different version of VSCode Elements. ",o+=`This version is "${xt}", while the other one is "${s}".`):o+=`is already registered by the same version of VSCode Elements (${xt}).`:o+="is already registered by an unknown custom element handler class.",yt(`The custom element "${t}" ${o}\nTo suppress this warning, set window.${wt} to true`)};var _t=n`
|
|
1
|
+
const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,i=Symbol(),s=new WeakMap;let o=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==i)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const i=this.t;if(e&&void 0===t){const e=void 0!==i&&1===i.length;e&&(t=s.get(i)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),e&&s.set(i,t))}return t}toString(){return this.cssText}};const r=t=>new o("string"==typeof t?t:t+"",void 0,i),n=(t,...e)=>{const s=1===t.length?t[0]:e.reduce(((e,i,s)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+t[s+1]),t[0]);return new o(s,t,i)},h=e?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return r(e)})(t):t,{is:a,defineProperty:l,getOwnPropertyDescriptor:c,getOwnPropertyNames:d,getOwnPropertySymbols:u,getPrototypeOf:p}=Object,v=globalThis,b=v.trustedTypes,f=b?b.emptyScript:"",g=v.reactiveElementPolyfillSupport,m=(t,e)=>t,x={toAttribute(t,e){switch(e){case Boolean:t=t?f:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},w=(t,e)=>!a(t,e),y={attribute:!0,type:String,converter:x,reflect:!1,useDefault:!1,hasChanged:w};Symbol.metadata??=Symbol("metadata"),v.litPropertyMetadata??=new WeakMap;let k=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=y){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),s=this.getPropertyDescriptor(t,i,e);void 0!==s&&l(this.prototype,t,s)}}static getPropertyDescriptor(t,e,i){const{get:s,set:o}=c(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:s,set(e){const r=s?.call(this);o?.call(this,e),this.requestUpdate(t,r,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??y}static _$Ei(){if(this.hasOwnProperty(m("elementProperties")))return;const t=p(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(m("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(m("properties"))){const t=this.properties,e=[...d(t),...u(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(h(t))}else void 0!==t&&e.push(h(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const i=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((i,s)=>{if(e)i.adoptedStyleSheets=s.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const e of s){const s=document.createElement("style"),o=t.litNonce;void 0!==o&&s.setAttribute("nonce",o),s.textContent=e.cssText,i.appendChild(s)}})(i,this.constructor.elementStyles),i}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){const i=this.constructor.elementProperties.get(t),s=this.constructor._$Eu(t,i);if(void 0!==s&&!0===i.reflect){const o=(void 0!==i.converter?.toAttribute?i.converter:x).toAttribute(e,i.type);this._$Em=t,null==o?this.removeAttribute(s):this.setAttribute(s,o),this._$Em=null}}_$AK(t,e){const i=this.constructor,s=i._$Eh.get(t);if(void 0!==s&&this._$Em!==s){const t=i.getPropertyOptions(s),o="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:x;this._$Em=s,this[s]=o.fromAttribute(e,t.type)??this._$Ej?.get(s)??null,this._$Em=null}}requestUpdate(t,e,i){if(void 0!==t){const s=this.constructor,o=this[t];if(i??=s.getPropertyOptions(t),!((i.hasChanged??w)(o,e)||i.useDefault&&i.reflect&&o===this._$Ej?.get(t)&&!this.hasAttribute(s._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:s,wrapped:o},r){i&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,r??e??this[t]),!0!==o||void 0!==r)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===s&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,s=this[e];!0!==t||this._$AL.has(e)||void 0===s||this.C(e,void 0,i,s)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach((t=>this._$ET(t,this[t]))),this._$EM()}updated(t){}firstUpdated(t){}};k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[m("elementProperties")]=new Map,k[m("finalized")]=new Map,g?.({ReactiveElement:k}),(v.reactiveElementVersions??=[]).push("2.1.0");const $=globalThis,_=$.trustedTypes,S=_?_.createPolicy("lit-html",{createHTML:t=>t}):void 0,C="$lit$",B=`lit$${Math.random().toFixed(9).slice(2)}$`,A="?"+B,O=`<${A}>`,z=document,E=()=>z.createComment(""),I=t=>null===t||"object"!=typeof t&&"function"!=typeof t,j=Array.isArray,M="[ \t\n\f\r]",D=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,F=/-->/g,P=/>/g,V=RegExp(`>|${M}(?:([^\\s"'>=/]+)(${M}*=${M}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),N=/'/g,T=/"/g,R=/^(?:script|style|textarea|title)$/i,L=t=>(e,...i)=>({_$litType$:t,strings:e,values:i}),U=L(1),H=L(2),G=Symbol.for("lit-noChange"),q=Symbol.for("lit-nothing"),W=new WeakMap,K=z.createTreeWalker(z,129);function X(t,e){if(!j(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==S?S.createHTML(e):e}const J=(t,e)=>{const i=t.length-1,s=[];let o,r=2===e?"<svg>":3===e?"<math>":"",n=D;for(let e=0;e<i;e++){const i=t[e];let h,a,l=-1,c=0;for(;c<i.length&&(n.lastIndex=c,a=n.exec(i),null!==a);)c=n.lastIndex,n===D?"!--"===a[1]?n=F:void 0!==a[1]?n=P:void 0!==a[2]?(R.test(a[2])&&(o=RegExp("</"+a[2],"g")),n=V):void 0!==a[3]&&(n=V):n===V?">"===a[0]?(n=o??D,l=-1):void 0===a[1]?l=-2:(l=n.lastIndex-a[2].length,h=a[1],n=void 0===a[3]?V:'"'===a[3]?T:N):n===T||n===N?n=V:n===F||n===P?n=D:(n=V,o=void 0);const d=n===V&&t[e+1].startsWith("/>")?" ":"";r+=n===D?i+O:l>=0?(s.push(h),i.slice(0,l)+C+i.slice(l)+B+d):i+B+(-2===l?e:d)}return[X(t,r+(t[i]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),s]};class Y{constructor({strings:t,_$litType$:e},i){let s;this.parts=[];let o=0,r=0;const n=t.length-1,h=this.parts,[a,l]=J(t,e);if(this.el=Y.createElement(a,i),K.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(s=K.nextNode())&&h.length<n;){if(1===s.nodeType){if(s.hasAttributes())for(const t of s.getAttributeNames())if(t.endsWith(C)){const e=l[r++],i=s.getAttribute(t).split(B),n=/([.?@])?(.*)/.exec(e);h.push({type:1,index:o,name:n[2],strings:i,ctor:"."===n[1]?et:"?"===n[1]?it:"@"===n[1]?st:tt}),s.removeAttribute(t)}else t.startsWith(B)&&(h.push({type:6,index:o}),s.removeAttribute(t));if(R.test(s.tagName)){const t=s.textContent.split(B),e=t.length-1;if(e>0){s.textContent=_?_.emptyScript:"";for(let i=0;i<e;i++)s.append(t[i],E()),K.nextNode(),h.push({type:2,index:++o});s.append(t[e],E())}}}else if(8===s.nodeType)if(s.data===A)h.push({type:2,index:o});else{let t=-1;for(;-1!==(t=s.data.indexOf(B,t+1));)h.push({type:7,index:o}),t+=B.length-1}o++}}static createElement(t,e){const i=z.createElement("template");return i.innerHTML=t,i}}function Z(t,e,i=t,s){if(e===G)return e;let o=void 0!==s?i._$Co?.[s]:i._$Cl;const r=I(e)?void 0:e._$litDirective$;return o?.constructor!==r&&(o?._$AO?.(!1),void 0===r?o=void 0:(o=new r(t),o._$AT(t,i,s)),void 0!==s?(i._$Co??=[])[s]=o:i._$Cl=o),void 0!==o&&(e=Z(t,o._$AS(t,e.values),o,s)),e}class Q{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,i,s){this.type=2,this._$AH=q,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=s,this._$Cv=s?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=Z(this,t,e),I(t)?t===q||null==t||""===t?(this._$AH!==q&&this._$AR(),this._$AH=q):t!==this._$AH&&t!==G&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>j(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==q&&I(this._$AH)?this._$AA.nextSibling.data=t:this.T(z.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:i}=t,s="number"==typeof i?this._$AC(t):(void 0===i.el&&(i.el=Y.createElement(X(i.h,i.h[0]),this.options)),i);if(this._$AH?._$AD===s)this._$AH.p(e);else{const t=new class{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:i}=this._$AD,s=(t?.creationScope??z).importNode(e,!0);K.currentNode=s;let o=K.nextNode(),r=0,n=0,h=i[0];for(;void 0!==h;){if(r===h.index){let e;2===h.type?e=new Q(o,o.nextSibling,this,t):1===h.type?e=new h.ctor(o,h.name,h.strings,this,t):6===h.type&&(e=new ot(o,this,t)),this._$AV.push(e),h=i[++n]}r!==h?.index&&(o=K.nextNode(),r++)}return K.currentNode=z,s}p(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}(s,this),i=t.u(this.options);t.p(e),this.T(i),this._$AH=t}}_$AC(t){let e=W.get(t.strings);return void 0===e&&W.set(t.strings,e=new Y(t)),e}k(t){j(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,s=0;for(const o of t)s===e.length?e.push(i=new Q(this.O(E()),this.O(E()),this,this.options)):i=e[s],i._$AI(o),s++;s<e.length&&(this._$AR(i&&i._$AB.nextSibling,s),e.length=s)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class tt{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,i,s,o){this.type=1,this._$AH=q,this._$AN=void 0,this.element=t,this.name=e,this._$AM=s,this.options=o,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=q}_$AI(t,e=this,i,s){const o=this.strings;let r=!1;if(void 0===o)t=Z(this,t,e,0),r=!I(t)||t!==this._$AH&&t!==G,r&&(this._$AH=t);else{const s=t;let n,h;for(t=o[0],n=0;n<o.length-1;n++)h=Z(this,s[i+n],e,n),h===G&&(h=this._$AH[n]),r||=!I(h)||h!==this._$AH[n],h===q?t=q:t!==q&&(t+=(h??"")+o[n+1]),this._$AH[n]=h}r&&!s&&this.j(t)}j(t){t===q?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class et extends tt{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===q?void 0:t}}class it extends tt{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==q)}}class st extends tt{constructor(t,e,i,s,o){super(t,e,i,s,o),this.type=5}_$AI(t,e=this){if((t=Z(this,t,e,0)??q)===G)return;const i=this._$AH,s=t===q&&i!==q||t.capture!==i.capture||t.once!==i.once||t.passive!==i.passive,o=t!==q&&(i===q||s);s&&this.element.removeEventListener(this.name,this,i),o&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class ot{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Z(this,t)}}const rt={I:Q},nt=$.litHtmlPolyfillSupport;nt?.(Y,Q),($.litHtmlVersions??=[]).push("3.3.0");const ht=(t,e,i)=>{const s=i?.renderBefore??e;let o=s._$litPart$;if(void 0===o){const t=i?.renderBefore??null;s._$litPart$=o=new Q(e.insertBefore(E(),t),t,void 0,i??{})}return o._$AI(t),o},at=globalThis;let lt=class extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=ht(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return G}};lt._$litElement$=!0,lt.finalized=!0,at.litElementHydrateSupport?.({LitElement:lt});const ct=at.litElementPolyfillSupport;ct?.({LitElement:lt}),(at.litElementVersions??=[]).push("4.2.0");const dt={attribute:!0,type:String,converter:x,reflect:!1,hasChanged:w},ut=(t=dt,e,i)=>{const{kind:s,metadata:o}=i;let r=globalThis.litPropertyMetadata.get(o);if(void 0===r&&globalThis.litPropertyMetadata.set(o,r=new Map),"setter"===s&&((t=Object.create(t)).wrapped=!0),r.set(i.name,t),"accessor"===s){const{name:s}=i;return{set(i){const o=e.get.call(this);e.set.call(this,i),this.requestUpdate(s,o,t)},init(e){return void 0!==e&&this.C(s,void 0,t,e),e}}}if("setter"===s){const{name:s}=i;return function(i){const o=this[s];e.call(this,i),this.requestUpdate(s,o,t)}}throw Error("Unsupported decorator location: "+s)};function pt(t){return(e,i)=>"object"==typeof i?ut(t,e,i):((t,e,i)=>{const s=e.hasOwnProperty(i);return e.constructor.createProperty(i,t),s?Object.getOwnPropertyDescriptor(e,i):void 0})(t,e,i)}function vt(t){return pt({...t,state:!0,attribute:!1})}const bt=(t,e,i)=>(i.configurable=!0,i.enumerable=!0,i);function ft(t,e){return(i,s,o)=>{const r=e=>e.renderRoot?.querySelector(t)??null;if(e){const{get:t,set:e}="object"==typeof s?i:o??(()=>{const t=Symbol();return{get(){return this[t]},set(e){this[t]=e}}})();return bt(0,0,{get(){let i=t.call(this);return void 0===i&&(i=r(this),(null!==i||this.hasUpdated)&&e.call(this,i)),i}})}return bt(0,0,{get(){return r(this)}})}}let gt;function mt(t){return(e,i)=>{const{slot:s,selector:o}=t??{},r="slot"+(s?`[name=${s}]`:":not([name])");return bt(0,0,{get(){const e=this.renderRoot?.querySelector(r),i=e?.assignedElements(t)??[];return void 0===o?i:i.filter((t=>t.matches(o)))}})}}const xt="2.5.0",wt="__vscodeElements_disableRegistryWarning__",yt=(t,e)=>{e?console.warn(`[VSCode Elements] ${t}\n%o`,e):console.warn(`${t}\n%o`,e)};class kt extends lt{get version(){return xt}warn(t){yt(t,this)}}const $t=t=>e=>{if(!customElements.get(t))return void customElements.define(t,e);if(wt in window)return;const i=document.createElement(t),s=i?.version;let o="";s?s!==xt?(o+="is already registered by a different version of VSCode Elements. ",o+=`This version is "${xt}", while the other one is "${s}".`):o+=`is already registered by the same version of VSCode Elements (${xt}).`:o+="is already registered by an unknown custom element handler class.",yt(`The custom element "${t}" ${o}\nTo suppress this warning, set window.${wt} to true`)};var _t=n`
|
|
2
2
|
:host([hidden]) {
|
|
3
3
|
display: none;
|
|
4
4
|
}
|
|
@@ -118,7 +118,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
118
118
|
animation-timing-function: linear;
|
|
119
119
|
animation-iteration-count: infinite;
|
|
120
120
|
}
|
|
121
|
-
`];var Vt,
|
|
121
|
+
`];var Vt,Nt=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Tt=Vt=class extends kt{constructor(){super(...arguments),this.label="",this.name="",this.size=16,this.spin=!1,this.spinDuration=1.5,this.actionIcon=!1,this._onButtonClick=t=>{this.dispatchEvent(new CustomEvent("vsc-click",{detail:{originalEvent:t}}))}}connectedCallback(){super.connectedCallback();const{href:t,nonce:e}=this._getStylesheetConfig();Vt.stylesheetHref=t,Vt.nonce=e}_getStylesheetConfig(){const t=document.getElementById("vscode-codicon-stylesheet"),e=t?.getAttribute("href")||void 0,i=t?.nonce||void 0;if(!t){let t='To use the Icon component, the codicons.css file must be included in the page with the id "vscode-codicon-stylesheet"! ';t+="See https://vscode-elements.github.io/components/icon/ for more details.",this.warn(t)}return{nonce:i,href:e}}render(){const{stylesheetHref:t,nonce:e}=Vt,i=U`<span
|
|
122
122
|
class=${Mt({codicon:!0,["codicon-"+this.name]:!0,spin:this.spin})}
|
|
123
123
|
.style=${Ft({animationDuration:String(this.spinDuration)+"s",fontSize:this.size+"px",height:this.size+"px",width:this.size+"px"})}
|
|
124
124
|
></span>`,s=this.actionIcon?U` <button
|
|
@@ -134,9 +134,9 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
134
134
|
rel="stylesheet"
|
|
135
135
|
href=${Dt(t)}
|
|
136
136
|
nonce=${Dt(e)}
|
|
137
|
-
|
|
137
|
+
/>
|
|
138
138
|
${s}
|
|
139
|
-
`}};
|
|
139
|
+
`}};Tt.styles=Pt,Tt.stylesheetHref="",Tt.nonce="",Nt([pt()],Tt.prototype,"label",void 0),Nt([pt({type:String})],Tt.prototype,"name",void 0),Nt([pt({type:Number})],Tt.prototype,"size",void 0),Nt([pt({type:Boolean,reflect:!0})],Tt.prototype,"spin",void 0),Nt([pt({type:Number,attribute:"spin-duration"})],Tt.prototype,"spinDuration",void 0),Nt([pt({type:Boolean,reflect:!0,attribute:"action-icon"})],Tt.prototype,"actionIcon",void 0),Tt=Vt=Nt([$t("vscode-icon")],Tt);const Rt=[_t,n`
|
|
140
140
|
:host {
|
|
141
141
|
cursor: pointer;
|
|
142
142
|
display: inline-block;
|
|
@@ -151,15 +151,15 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
151
151
|
.base {
|
|
152
152
|
align-items: center;
|
|
153
153
|
background-color: var(--vscode-button-background, #0078d4);
|
|
154
|
-
border-bottom-left-radius: var(--vsc-border-left-radius,
|
|
155
|
-
border-bottom-right-radius: var(--vsc-border-right-radius,
|
|
154
|
+
border-bottom-left-radius: var(--vsc-border-left-radius, 4px);
|
|
155
|
+
border-bottom-right-radius: var(--vsc-border-right-radius, 4px);
|
|
156
156
|
border-bottom-width: 1px;
|
|
157
157
|
border-color: var(--vscode-button-border, transparent);
|
|
158
158
|
border-left-width: var(--vsc-border-left-width, 1px);
|
|
159
159
|
border-right-width: var(--vsc-border-right-width, 1px);
|
|
160
160
|
border-style: solid;
|
|
161
|
-
border-top-left-radius: var(--vsc-border-left-radius,
|
|
162
|
-
border-top-right-radius: var(--vsc-border-right-radius,
|
|
161
|
+
border-top-left-radius: var(--vsc-border-left-radius, 4px);
|
|
162
|
+
border-top-right-radius: var(--vsc-border-right-radius, 4px);
|
|
163
163
|
border-top-width: 1px;
|
|
164
164
|
box-sizing: border-box;
|
|
165
165
|
color: var(--vscode-button-foreground, #ffffff);
|
|
@@ -580,7 +580,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
580
580
|
role=${Dt(this.toggle?"switch":void 0)}
|
|
581
581
|
aria-checked=${Dt(this.toggle?this.checked?"true":"false":void 0)}
|
|
582
582
|
value=${this.value}
|
|
583
|
-
|
|
583
|
+
/>
|
|
584
584
|
<div class=${t}>${r}</div>
|
|
585
585
|
<label for="input" class="label" @click=${this._handleClick}>
|
|
586
586
|
<span class=${e}>
|
|
@@ -717,7 +717,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
717
717
|
.collapsible.open .collapsible-body {
|
|
718
718
|
display: block;
|
|
719
719
|
}
|
|
720
|
-
`];var re=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let ne=class extends kt{constructor(){super(...arguments),this.alwaysShowHeaderActions=!1,this.title="",this.heading="",this.description="",this.open=!1}_emitToggleEvent(){this.dispatchEvent(new CustomEvent("vsc-collapsible-toggle",{detail:{open:this.open}}))}_onHeaderClick(){this.open=!this.open,this._emitToggleEvent()}_onHeaderKeyDown(t){"Enter"===t.key&&(this.open=!this.open,this._emitToggleEvent())}
|
|
720
|
+
`];var re=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let ne=class extends kt{constructor(){super(...arguments),this.alwaysShowHeaderActions=!1,this.title="",this.heading="",this.description="",this.open=!1}_emitToggleEvent(){this.dispatchEvent(new CustomEvent("vsc-collapsible-toggle",{detail:{open:this.open}}))}_onHeaderClick(){this.open=!this.open,this._emitToggleEvent()}_onHeaderKeyDown(t){"Enter"===t.key&&(this.open=!this.open,this._emitToggleEvent())}_onHeaderSlotClick(t){t.stopPropagation()}render(){const t={collapsible:!0,open:this.open},e={actions:!0,"always-visible":this.alwaysShowHeaderActions},i=this.heading?this.heading:this.title,s=U`<svg
|
|
721
721
|
width="16"
|
|
722
722
|
height="16"
|
|
723
723
|
viewBox="0 0 16 16"
|
|
@@ -742,9 +742,11 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
742
742
|
<h3 class="title">${i}${o}</h3>
|
|
743
743
|
<div class="header-slots">
|
|
744
744
|
<div class=${Mt(e)}>
|
|
745
|
-
<slot name="actions" @click=${this.
|
|
745
|
+
<slot name="actions" @click=${this._onHeaderSlotClick}></slot>
|
|
746
|
+
</div>
|
|
747
|
+
<div class="decorations">
|
|
748
|
+
<slot name="decorations" @click=${this._onHeaderSlotClick}></slot>
|
|
746
749
|
</div>
|
|
747
|
-
<div class="decorations"><slot name="decorations"></slot></div>
|
|
748
750
|
</div>
|
|
749
751
|
</div>
|
|
750
752
|
<div class="collapsible-body" part="body">
|
|
@@ -1060,7 +1062,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1060
1062
|
clip-rule="evenodd"
|
|
1061
1063
|
d="M14.431 3.323l-8.47 10-.79-.036-3.35-4.77.818-.574 2.978 4.24 8.051-9.506.764.646z"
|
|
1062
1064
|
/>
|
|
1063
|
-
</svg>`,{I:Me}=rt,De=()=>document.createComment(""),Fe=(t,e,i)=>{const s=t._$AA.parentNode,o=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=s.insertBefore(De(),o),r=s.insertBefore(De(),o);i=new Me(e,r,t,t.options)}else{const e=i._$AB.nextSibling,r=i._$AM,n=r!==t;if(n){let e;i._$AQ?.(t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==r._$AU&&i._$AP(e)}if(e!==o||n){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;s.insertBefore(t,o),t=e}}}return i},Pe=(t,e,i=t)=>(t._$AI(e,i),t),Ve={},Te=t=>{t._$AP?.(!1,!0);let e=t._$AA;const i=t._$AB.nextSibling;for(;e!==i;){const t=e.nextSibling;e.remove(),e=t}},Ne=(t,e,i)=>{const s=new Map;for(let o=e;o<=i;o++)s.set(t[o],o);return s},Re=It(class extends jt{constructor(t){if(super(t),t.type!==zt)throw Error("repeat() can only be used in text expressions")}dt(t,e,i){let s;void 0===i?i=e:void 0!==e&&(s=e);const o=[],r=[];let n=0;for(const e of t)o[n]=s?s(e,n):n,r[n]=i(e,n),n++;return{values:r,keys:o}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,s]){const o=(t=>t._$AH)(t),{values:r,keys:n}=this.dt(e,i,s);if(!Array.isArray(o))return this.ut=n,r;const h=this.ut??=[],a=[];let l,c,d=0,u=o.length-1,p=0,v=r.length-1;for(;d<=u&&p<=v;)if(null===o[d])d++;else if(null===o[u])u--;else if(h[d]===n[p])a[p]=Pe(o[d],r[p]),d++,p++;else if(h[u]===n[v])a[v]=Pe(o[u],r[v]),u--,v--;else if(h[d]===n[v])a[v]=Pe(o[d],r[v]),Fe(t,a[v+1],o[d]),d++,v--;else if(h[u]===n[p])a[p]=Pe(o[u],r[p]),Fe(t,o[d],o[u]),u--,p++;else if(void 0===l&&(l=Ne(n,p,v),c=Ne(h,d,u)),l.has(h[d]))if(l.has(h[u])){const e=c.get(n[p]),i=void 0!==e?o[e]:null;if(null===i){const e=Fe(t,o[d]);Pe(e,r[p]),a[p]=e}else a[p]=Pe(i,r[p]),Fe(t,o[d],i),o[e]=null;p++}else Te(o[u]),u--;else Te(o[d]),d++;for(;p<=v;){const e=Fe(t,a[v+1]);Pe(e,r[p]),a[p++]=e}for(;d<=u;){const t=o[d++];null!==t&&Te(t)}return this.ut=n,((t,e=Ve)=>{t._$AH=e})(t,a),G}});var Le=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Ue=class extends kt{constructor(){super(...arguments),this.description="",this.selected=!1,this.disabled=!1,this._initialized=!1,this._handleSlotChange=()=>{this._initialized&&this.dispatchEvent(new Event("vsc-option-state-change",{bubbles:!0}))}}connectedCallback(){super.connectedCallback(),this.updateComplete.then((()=>{this._initialized=!0}))}willUpdate(t){this._initialized&&(t.has("description")||t.has("value")||t.has("selected")||t.has("disabled"))&&this.dispatchEvent(new Event("vsc-option-state-change",{bubbles:!0}))}render(){return U`<slot @slotchange=${this._handleSlotChange}></slot>`}};Ue.styles=_t,Le([pt({type:String})],Ue.prototype,"value",void 0),Le([pt({type:String})],Ue.prototype,"description",void 0),Le([pt({type:Boolean,reflect:!0})],Ue.prototype,"selected",void 0),Le([pt({type:Boolean,reflect:!0})],Ue.prototype,"disabled",void 0),Ue=Le([$t("vscode-option")],Ue);const He=(t,e)=>{const i={match:!1,ranges:[]},s=t.toLowerCase(),o=e.toLowerCase(),r=s.split(" ");let n=0;return r.forEach(((e,s)=>{if(s>0&&(n+=r[s-1].length+1),i.match)return;const h=e.indexOf(o),a=o.length;0===h&&(i.match=!0,i.ranges.push([n+h,Math.min(n+h+a,t.length)]))})),i},Ge=(t,e)=>{const i={match:!1,ranges:[]};return 0===t.toLowerCase().indexOf(e.toLowerCase())&&(i.match=!0,i.ranges=[[0,e.length]]),i},qe=(t,e)=>{const i={match:!1,ranges:[]},s=t.toLowerCase().indexOf(e.toLowerCase());return s>-1&&(i.match=!0,i.ranges=[[s,s+e.length]]),i},We=(t,e)=>{const i={match:!1,ranges:[]};let s=0,o=0;const r=e.length-1,n=t.toLowerCase(),h=e.toLowerCase();for(let t=0;t<=r;t++){if(o=n.indexOf(h[t],s),-1===o)return{match:!1,ranges:[]};i.match=!0,i.ranges.push([o,o+1]),s=o+1}return i},Ke=t=>{const e=[];return" "===t?(e.push(U` `),e):(0===t.indexOf(" ")&&e.push(U` `),e.push(U`${t.trimStart().trimEnd()}`),t.lastIndexOf(" ")===t.length-1&&e.push(U` `),e)};class Xe{constructor(t){this._activeIndex=-1,this._options=[],this._filterPattern="",this._filterMethod="fuzzy",this._combobox=!1,this._indexByValue=new Map,this._indexByLabel=new Map,this._selectedIndex=-1,this._selectedIndexes=new Set,this._multiSelect=!1,this._numOfVisibleOptions=0,(this._host=t).addController(this)}hostConnected(){}get activeIndex(){return this._activeIndex}set activeIndex(t){this._activeIndex=t,this._host.requestUpdate()}get relativeActiveIndex(){return this._options[this._activeIndex]?.filteredIndex??-1}set comboboxMode(t){this._combobox=t,this._host.requestUpdate()}get comboboxMode(){return this._combobox}get multiSelect(){return this._multiSelect}set multiSelect(t){this._selectedIndex=-1,this._selectedIndexes.clear(),this._multiSelect=t,this._host.requestUpdate()}get selectedIndex(){return this._selectedIndex}set selectedIndex(t){-1!==this._selectedIndex&&this._options[this._selectedIndex]&&(this._options[this._selectedIndex].selected??=!1);const e=this.getOptionByIndex(t);this._selectedIndex=e?t:-1,this._host.requestUpdate()}get selectedIndexes(){return Array.from(this._selectedIndexes)}set selectedIndexes(t){this._selectedIndexes.forEach((t=>{this._options[t].selected=!1})),this._selectedIndexes=new Set(t),t.forEach((t=>{void 0!==this._options[t]&&(this._options[t].selected=!0)})),this._host.requestUpdate()}set value(t){if(this._multiSelect){const e=t.map((t=>this._indexByValue.get(t))).filter((t=>void 0!==t));this._selectedIndexes=new Set(e)}else this._selectedIndex=this._indexByValue.get(t)??-1;this._host.requestUpdate()}get value(){return this._multiSelect?this._selectedIndexes.size>0?Array.from(this._selectedIndexes).filter((t=>t>=0&&t<this._options.length)).map((t=>this._options[t].value)):[]:this._selectedIndex>-1&&this._selectedIndex<this._options.length?this._options[this._selectedIndex].value:""}set multiSelectValue(t){const e=t.map((t=>this._indexByValue.get(t))).filter((t=>void 0!==t));this._selectedIndexes=new Set(e)}get multiSelectValue(){return this._selectedIndexes.size>0?Array.from(this._selectedIndexes).map((t=>this._options[t].value)):[]}get filterPattern(){return this._filterPattern}set filterPattern(t){t!==this._filterPattern&&(this._filterPattern=t,this._updateState())}get filterMethod(){return this._filterMethod}set filterMethod(t){t!==this._filterMethod&&(this._filterMethod=t,this._updateState())}get options(){return this._options}get numOfVisibleOptions(){return this._numOfVisibleOptions}get numOptions(){return this._options.length}populate(t){this._indexByValue.clear(),this._indexByLabel.clear(),this._options=t.map(((t,e)=>(this._indexByValue.set(t.value??"",e),this._indexByLabel.set(t.label??"",e),{description:t.description??"",disabled:t.disabled??!1,label:t.label??"",selected:t.selected??!1,value:t.value??"",index:e,filteredIndex:e,ranges:[],visible:!0}))),this._numOfVisibleOptions=this._options.length}add(t){const e=this._options.length,{description:i,disabled:s,label:o,selected:r,value:n}=t;let h=!0,a=[];if(this._combobox&&""!==this._filterPattern){const t=this._searchByPattern(o??"");h=t.match,a=t.ranges}this._indexByValue.set(n??"",e),this._indexByLabel.set(o??"",e),r&&(this._selectedIndex=e,this._selectedIndexes.add(e),this._activeIndex=e),this._options.push({index:e,filteredIndex:e,description:i??"",disabled:s??!1,label:o??"",selected:r??!1,value:n??"",visible:h,ranges:a}),h&&(this._numOfVisibleOptions+=1)}clear(){this._options=[],this._indexByValue.clear(),this._indexByLabel.clear(),this._numOfVisibleOptions=0,this._selectedIndex=-1,this._selectedIndexes.clear(),this._activeIndex=-1}getIsIndexSelected(t){return this._multiSelect?this._selectedIndexes.has(t):this._selectedIndex===t}expandMultiSelection(t){t.forEach((t=>{const e=this._indexByValue.get(t)??-1;-1!==e&&this._selectedIndexes.add(e)})),this._host.requestUpdate()}toggleActiveMultiselectOption(){const t=this._options[this._activeIndex]??null;if(!t)return;this._selectedIndexes.has(t.index)?this._selectedIndexes.delete(t.index):this._selectedIndexes.add(t.index),this._host.requestUpdate()}toggleOptionSelected(t){const e=this._selectedIndexes.has(t);this._options[t].selected=!this._options[t].selected,e?this._selectedIndexes.delete(t):this._selectedIndexes.add(t),this._host.requestUpdate()}getActiveOption(){return this._options[this._activeIndex]??null}getSelectedOption(){return this._options[this._selectedIndex]??null}getOptionByIndex(t){return this._options[t]??null}findOptionIndex(t){return this._indexByValue.get(t)??-1}getOptionByValue(t,e=!1){const i=this._indexByValue.get(t)??-1;return-1===i?null:e||this._options[i].visible?this._options[i]:null}getOptionByLabel(t){const e=this._indexByLabel.get(t)??-1;return-1===e?null:this._options[e]}next(t){let e=-1;for(let i=(t??this._activeIndex)+1;i<this._options.length;i++)if(this._options[i]&&!this._options[i].disabled&&this._options[i].visible){e=i;break}return e>-1?this._options[e]:null}prev(t){let e=-1;for(let i=(t??this._activeIndex)-1;i>=0;i--)if(this._options[i]&&!this._options[i].disabled&&this._options[i].visible){e=i;break}return e>-1?this._options[e]:null}activateDefault(){if(this._multiSelect){if(this._selectedIndexes.size>0){const t=this._selectedIndexes.values().next();this._activeIndex=t.value?t.value:0}}else this._selectedIndex>-1?this._activeIndex=this._selectedIndex:this._activeIndex=0;this._host.requestUpdate()}selectAll(){this._multiSelect&&(this._options.forEach(((t,e)=>{this._options[e].selected=!0,this._selectedIndexes.add(e)})),this._host.requestUpdate())}selectNone(){this._multiSelect&&(this._options.forEach(((t,e)=>{this._options[e].selected=!1})),this._selectedIndexes.clear(),this._host.requestUpdate())}_searchByPattern(t){let e;switch(this._filterMethod){case"startsWithPerTerm":e=He(t,this._filterPattern);break;case"startsWith":e=Ge(t,this._filterPattern);break;case"contains":e=qe(t,this._filterPattern);break;default:e=We(t,this._filterPattern)}return e}_updateState(){if(this._combobox&&""!==this._filterPattern){let t=-1;this._numOfVisibleOptions=0,this._options.forEach((({label:e},i)=>{const s=this._searchByPattern(e);this._options[i].visible=s.match,this._options[i].ranges=s.ranges,this._options[i].filteredIndex=s.match?++t:-1,s.match&&(this._numOfVisibleOptions+=1)}))}else this._options.forEach(((t,e)=>{this._options[e].visible=!0,this._options[e].ranges=[]})),this._numOfVisibleOptions=this._options.length;this._host.requestUpdate()}}const Je=[_t,n`
|
|
1065
|
+
</svg>`,{I:Me}=rt,De=()=>document.createComment(""),Fe=(t,e,i)=>{const s=t._$AA.parentNode,o=void 0===e?t._$AB:e._$AA;if(void 0===i){const e=s.insertBefore(De(),o),r=s.insertBefore(De(),o);i=new Me(e,r,t,t.options)}else{const e=i._$AB.nextSibling,r=i._$AM,n=r!==t;if(n){let e;i._$AQ?.(t),i._$AM=t,void 0!==i._$AP&&(e=t._$AU)!==r._$AU&&i._$AP(e)}if(e!==o||n){let t=i._$AA;for(;t!==e;){const e=t.nextSibling;s.insertBefore(t,o),t=e}}}return i},Pe=(t,e,i=t)=>(t._$AI(e,i),t),Ve={},Ne=t=>{t._$AP?.(!1,!0);let e=t._$AA;const i=t._$AB.nextSibling;for(;e!==i;){const t=e.nextSibling;e.remove(),e=t}},Te=(t,e,i)=>{const s=new Map;for(let o=e;o<=i;o++)s.set(t[o],o);return s},Re=It(class extends jt{constructor(t){if(super(t),t.type!==zt)throw Error("repeat() can only be used in text expressions")}dt(t,e,i){let s;void 0===i?i=e:void 0!==e&&(s=e);const o=[],r=[];let n=0;for(const e of t)o[n]=s?s(e,n):n,r[n]=i(e,n),n++;return{values:r,keys:o}}render(t,e,i){return this.dt(t,e,i).values}update(t,[e,i,s]){const o=(t=>t._$AH)(t),{values:r,keys:n}=this.dt(e,i,s);if(!Array.isArray(o))return this.ut=n,r;const h=this.ut??=[],a=[];let l,c,d=0,u=o.length-1,p=0,v=r.length-1;for(;d<=u&&p<=v;)if(null===o[d])d++;else if(null===o[u])u--;else if(h[d]===n[p])a[p]=Pe(o[d],r[p]),d++,p++;else if(h[u]===n[v])a[v]=Pe(o[u],r[v]),u--,v--;else if(h[d]===n[v])a[v]=Pe(o[d],r[v]),Fe(t,a[v+1],o[d]),d++,v--;else if(h[u]===n[p])a[p]=Pe(o[u],r[p]),Fe(t,o[d],o[u]),u--,p++;else if(void 0===l&&(l=Te(n,p,v),c=Te(h,d,u)),l.has(h[d]))if(l.has(h[u])){const e=c.get(n[p]),i=void 0!==e?o[e]:null;if(null===i){const e=Fe(t,o[d]);Pe(e,r[p]),a[p]=e}else a[p]=Pe(i,r[p]),Fe(t,o[d],i),o[e]=null;p++}else Ne(o[u]),u--;else Ne(o[d]),d++;for(;p<=v;){const e=Fe(t,a[v+1]);Pe(e,r[p]),a[p++]=e}for(;d<=u;){const t=o[d++];null!==t&&Ne(t)}return this.ut=n,((t,e=Ve)=>{t._$AH=e})(t,a),G}});var Le=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Ue=class extends kt{constructor(){super(...arguments),this.description="",this.selected=!1,this.disabled=!1,this._initialized=!1,this._handleSlotChange=()=>{this._initialized&&this.dispatchEvent(new Event("vsc-option-state-change",{bubbles:!0}))}}connectedCallback(){super.connectedCallback(),this.updateComplete.then((()=>{this._initialized=!0}))}willUpdate(t){this._initialized&&(t.has("description")||t.has("value")||t.has("selected")||t.has("disabled"))&&this.dispatchEvent(new Event("vsc-option-state-change",{bubbles:!0}))}render(){return U`<slot @slotchange=${this._handleSlotChange}></slot>`}};Ue.styles=_t,Le([pt({type:String})],Ue.prototype,"value",void 0),Le([pt({type:String})],Ue.prototype,"description",void 0),Le([pt({type:Boolean,reflect:!0})],Ue.prototype,"selected",void 0),Le([pt({type:Boolean,reflect:!0})],Ue.prototype,"disabled",void 0),Ue=Le([$t("vscode-option")],Ue);const He=(t,e)=>{const i={match:!1,ranges:[]},s=t.toLowerCase(),o=e.toLowerCase(),r=s.split(" ");let n=0;return r.forEach(((e,s)=>{if(s>0&&(n+=r[s-1].length+1),i.match)return;const h=e.indexOf(o),a=o.length;0===h&&(i.match=!0,i.ranges.push([n+h,Math.min(n+h+a,t.length)]))})),i},Ge=(t,e)=>{const i={match:!1,ranges:[]};return 0===t.toLowerCase().indexOf(e.toLowerCase())&&(i.match=!0,i.ranges=[[0,e.length]]),i},qe=(t,e)=>{const i={match:!1,ranges:[]},s=t.toLowerCase().indexOf(e.toLowerCase());return s>-1&&(i.match=!0,i.ranges=[[s,s+e.length]]),i},We=(t,e)=>{const i={match:!1,ranges:[]};let s=0,o=0;const r=e.length-1,n=t.toLowerCase(),h=e.toLowerCase();for(let t=0;t<=r;t++){if(o=n.indexOf(h[t],s),-1===o)return{match:!1,ranges:[]};i.match=!0,i.ranges.push([o,o+1]),s=o+1}return i},Ke=t=>{const e=[];return" "===t?(e.push(U` `),e):(0===t.indexOf(" ")&&e.push(U` `),e.push(U`${t.trimStart().trimEnd()}`),t.lastIndexOf(" ")===t.length-1&&e.push(U` `),e)};class Xe{constructor(t){this._activeIndex=-1,this._options=[],this._filterPattern="",this._filterMethod="fuzzy",this._combobox=!1,this._indexByValue=new Map,this._indexByLabel=new Map,this._selectedIndex=-1,this._selectedIndexes=new Set,this._multiSelect=!1,this._numOfVisibleOptions=0,(this._host=t).addController(this)}hostConnected(){}get activeIndex(){return this._activeIndex}set activeIndex(t){this._activeIndex=t,this._host.requestUpdate()}get relativeActiveIndex(){return this._options[this._activeIndex]?.filteredIndex??-1}set comboboxMode(t){this._combobox=t,this._host.requestUpdate()}get comboboxMode(){return this._combobox}get multiSelect(){return this._multiSelect}set multiSelect(t){this._selectedIndex=-1,this._selectedIndexes.clear(),this._multiSelect=t,this._host.requestUpdate()}get selectedIndex(){return this._selectedIndex}set selectedIndex(t){-1!==this._selectedIndex&&this._options[this._selectedIndex]&&(this._options[this._selectedIndex].selected??=!1);const e=this.getOptionByIndex(t);this._selectedIndex=e?t:-1,this._host.requestUpdate()}get selectedIndexes(){return Array.from(this._selectedIndexes)}set selectedIndexes(t){this._selectedIndexes.forEach((t=>{this._options[t].selected=!1})),this._selectedIndexes=new Set(t),t.forEach((t=>{void 0!==this._options[t]&&(this._options[t].selected=!0)})),this._host.requestUpdate()}set value(t){if(this._multiSelect){const e=t.map((t=>this._indexByValue.get(t))).filter((t=>void 0!==t));this._selectedIndexes=new Set(e)}else this._selectedIndex=this._indexByValue.get(t)??-1;this._host.requestUpdate()}get value(){return this._multiSelect?this._selectedIndexes.size>0?Array.from(this._selectedIndexes).filter((t=>t>=0&&t<this._options.length)).map((t=>this._options[t].value)):[]:this._selectedIndex>-1&&this._selectedIndex<this._options.length?this._options[this._selectedIndex].value:""}set multiSelectValue(t){const e=t.map((t=>this._indexByValue.get(t))).filter((t=>void 0!==t));this._selectedIndexes=new Set(e)}get multiSelectValue(){return this._selectedIndexes.size>0?Array.from(this._selectedIndexes).map((t=>this._options[t].value)):[]}get filterPattern(){return this._filterPattern}set filterPattern(t){t!==this._filterPattern&&(this._filterPattern=t,this._updateState())}get filterMethod(){return this._filterMethod}set filterMethod(t){t!==this._filterMethod&&(this._filterMethod=t,this._updateState())}get options(){return this._options}get numOfVisibleOptions(){return this._numOfVisibleOptions}get numOptions(){return this._options.length}populate(t){this._indexByValue.clear(),this._indexByLabel.clear(),this._options=t.map(((t,e)=>(this._indexByValue.set(t.value??"",e),this._indexByLabel.set(t.label??"",e),{description:t.description??"",disabled:t.disabled??!1,label:t.label??"",selected:t.selected??!1,value:t.value??"",index:e,filteredIndex:e,ranges:[],visible:!0}))),this._numOfVisibleOptions=this._options.length}add(t){const e=this._options.length,{description:i,disabled:s,label:o,selected:r,value:n}=t;let h=!0,a=[];if(this._combobox&&""!==this._filterPattern){const t=this._searchByPattern(o??"");h=t.match,a=t.ranges}this._indexByValue.set(n??"",e),this._indexByLabel.set(o??"",e),r&&(this._selectedIndex=e,this._selectedIndexes.add(e),this._activeIndex=e),this._options.push({index:e,filteredIndex:e,description:i??"",disabled:s??!1,label:o??"",selected:r??!1,value:n??"",visible:h,ranges:a}),h&&(this._numOfVisibleOptions+=1)}clear(){this._options=[],this._indexByValue.clear(),this._indexByLabel.clear(),this._numOfVisibleOptions=0,this._selectedIndex=-1,this._selectedIndexes.clear(),this._activeIndex=-1}getIsIndexSelected(t){return this._multiSelect?this._selectedIndexes.has(t):this._selectedIndex===t}expandMultiSelection(t){t.forEach((t=>{const e=this._indexByValue.get(t)??-1;-1!==e&&this._selectedIndexes.add(e)})),this._host.requestUpdate()}toggleActiveMultiselectOption(){const t=this._options[this._activeIndex]??null;if(!t)return;this._selectedIndexes.has(t.index)?this._selectedIndexes.delete(t.index):this._selectedIndexes.add(t.index),this._host.requestUpdate()}toggleOptionSelected(t){const e=this._selectedIndexes.has(t);this._options[t].selected=!this._options[t].selected,e?this._selectedIndexes.delete(t):this._selectedIndexes.add(t),this._host.requestUpdate()}getActiveOption(){return this._options[this._activeIndex]??null}getSelectedOption(){return this._options[this._selectedIndex]??null}getOptionByIndex(t){return this._options[t]??null}findOptionIndex(t){return this._indexByValue.get(t)??-1}getOptionByValue(t,e=!1){const i=this._indexByValue.get(t)??-1;return-1===i?null:e||this._options[i].visible?this._options[i]:null}getOptionByLabel(t){const e=this._indexByLabel.get(t)??-1;return-1===e?null:this._options[e]}next(t){let e=-1;for(let i=(t??this._activeIndex)+1;i<this._options.length;i++)if(this._options[i]&&!this._options[i].disabled&&this._options[i].visible){e=i;break}return e>-1?this._options[e]:null}prev(t){let e=-1;for(let i=(t??this._activeIndex)-1;i>=0;i--)if(this._options[i]&&!this._options[i].disabled&&this._options[i].visible){e=i;break}return e>-1?this._options[e]:null}activateDefault(){if(this._multiSelect){if(this._selectedIndexes.size>0){const t=this._selectedIndexes.values().next();this._activeIndex=t.value?t.value:0}}else this._selectedIndex>-1?this._activeIndex=this._selectedIndex:this._activeIndex=0;this._host.requestUpdate()}selectAll(){this._multiSelect&&(this._options.forEach(((t,e)=>{this._options[e].selected=!0,this._selectedIndexes.add(e)})),this._host.requestUpdate())}selectNone(){this._multiSelect&&(this._options.forEach(((t,e)=>{this._options[e].selected=!1})),this._selectedIndexes.clear(),this._host.requestUpdate())}_searchByPattern(t){let e;switch(this._filterMethod){case"startsWithPerTerm":e=He(t,this._filterPattern);break;case"startsWith":e=Ge(t,this._filterPattern);break;case"contains":e=qe(t,this._filterPattern);break;default:e=We(t,this._filterPattern)}return e}_updateState(){if(this._combobox&&""!==this._filterPattern){let t=-1;this._numOfVisibleOptions=0,this._options.forEach((({label:e},i)=>{const s=this._searchByPattern(e);this._options[i].visible=s.match,this._options[i].ranges=s.ranges,this._options[i].filteredIndex=s.match?++t:-1,s.match&&(this._numOfVisibleOptions+=1)}))}else this._options.forEach(((t,e)=>{this._options[e].visible=!0,this._options[e].ranges=[]})),this._numOfVisibleOptions=this._options.length;this._host.requestUpdate()}}const Je=[_t,n`
|
|
1064
1066
|
:host {
|
|
1065
1067
|
display: block;
|
|
1066
1068
|
position: relative;
|
|
@@ -1261,7 +1263,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1261
1263
|
.combobox-face {
|
|
1262
1264
|
background-color: var(--vscode-settings-dropdownBackground, #313131);
|
|
1263
1265
|
border-color: var(--vscode-settings-dropdownBorder, #3c3c3c);
|
|
1264
|
-
border-radius:
|
|
1266
|
+
border-radius: 4px;
|
|
1265
1267
|
border-style: solid;
|
|
1266
1268
|
border-width: 1px;
|
|
1267
1269
|
box-sizing: border-box;
|
|
@@ -1328,10 +1330,16 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1328
1330
|
:host(:focus) .combobox-face,
|
|
1329
1331
|
:host([focused]) .select-face,
|
|
1330
1332
|
:host([focused]) .combobox-face {
|
|
1331
|
-
border-color: var(--vscode-focusBorder, #0078d4);
|
|
1332
1333
|
outline: none;
|
|
1333
1334
|
}
|
|
1334
1335
|
|
|
1336
|
+
:host(:focus:not([open])) .select-face,
|
|
1337
|
+
:host(:focus:not([open])) .combobox-face,
|
|
1338
|
+
:host([focused]:not([open])) .select-face,
|
|
1339
|
+
:host([focused]:not([open])) .combobox-face {
|
|
1340
|
+
border-color: var(--vscode-focusBorder, #0078d4);
|
|
1341
|
+
}
|
|
1342
|
+
|
|
1335
1343
|
.combobox-input {
|
|
1336
1344
|
background-color: transparent;
|
|
1337
1345
|
box-sizing: border-box;
|
|
@@ -1403,16 +1411,14 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1403
1411
|
.dropdown {
|
|
1404
1412
|
background-color: var(--vscode-settings-dropdownBackground, #313131);
|
|
1405
1413
|
border-color: var(--vscode-settings-dropdownListBorder, #454545);
|
|
1406
|
-
border-radius:
|
|
1414
|
+
border-radius: 4px;
|
|
1407
1415
|
border-style: solid;
|
|
1408
1416
|
border-width: 1px;
|
|
1409
1417
|
bottom: unset;
|
|
1418
|
+
box-shadow: 0 2px 8px var(--vscode-widget-shadow, rgba(0, 0, 0, 0.36));
|
|
1410
1419
|
box-sizing: border-box;
|
|
1411
1420
|
display: none;
|
|
1412
|
-
padding
|
|
1413
|
-
padding-left: 0;
|
|
1414
|
-
padding-right: 0;
|
|
1415
|
-
padding-top: 0;
|
|
1421
|
+
padding: 0;
|
|
1416
1422
|
right: unset;
|
|
1417
1423
|
}
|
|
1418
1424
|
|
|
@@ -1421,22 +1427,16 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1421
1427
|
}
|
|
1422
1428
|
|
|
1423
1429
|
:host([position='above']) .dropdown {
|
|
1424
|
-
border-radius: 3px 3px 0 0;
|
|
1425
1430
|
bottom: 26px;
|
|
1426
1431
|
padding-bottom: 0;
|
|
1427
1432
|
padding-top: 2px;
|
|
1428
1433
|
top: unset;
|
|
1429
1434
|
}
|
|
1430
1435
|
|
|
1431
|
-
:host(:focus) .dropdown,
|
|
1432
|
-
:host([focused]) .dropdown {
|
|
1433
|
-
border-color: var(--vscode-focusBorder, #0078d4);
|
|
1434
|
-
}
|
|
1435
|
-
|
|
1436
1436
|
.scrollable {
|
|
1437
1437
|
display: block;
|
|
1438
1438
|
max-height: 222px;
|
|
1439
|
-
margin:
|
|
1439
|
+
margin: 0;
|
|
1440
1440
|
outline: none;
|
|
1441
1441
|
overflow: hidden;
|
|
1442
1442
|
}
|
|
@@ -1677,7 +1677,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1677
1677
|
@input=${this._onComboboxInputInput}
|
|
1678
1678
|
@click=${this._onComboboxInputClick}
|
|
1679
1679
|
@keydown=${this._onComboboxInputSpaceKeyDown}
|
|
1680
|
-
|
|
1680
|
+
/>
|
|
1681
1681
|
<button
|
|
1682
1682
|
aria-label="Open the list of options"
|
|
1683
1683
|
class="combobox-button"
|
|
@@ -1922,7 +1922,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
1922
1922
|
?checked=${this.checked}
|
|
1923
1923
|
value=${this.value}
|
|
1924
1924
|
tabindex=${this.tabIndex}
|
|
1925
|
-
|
|
1925
|
+
/>
|
|
1926
1926
|
<div class=${t}></div>
|
|
1927
1927
|
<label for="input" class="label" @click=${this._handleClick}>
|
|
1928
1928
|
<span class=${e}>
|
|
@@ -2002,7 +2002,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2002
2002
|
@input=${this._onComboboxInputInput}
|
|
2003
2003
|
@click=${this._onComboboxInputClick}
|
|
2004
2004
|
@keydown=${this._onComboboxInputSpaceKeyDown}
|
|
2005
|
-
|
|
2005
|
+
/>
|
|
2006
2006
|
<button
|
|
2007
2007
|
aria-label="Open the list of options"
|
|
2008
2008
|
class="combobox-button"
|
|
@@ -2348,7 +2348,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2348
2348
|
table-layout: fixed;
|
|
2349
2349
|
width: 100%;
|
|
2350
2350
|
}
|
|
2351
|
-
`];var
|
|
2351
|
+
`];var Ni=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Ti=class extends kt{constructor(){super(...arguments),this.role="rowgroup"}render(){return U` <slot></slot> `}};Ti.styles=Vi,Ni([pt({reflect:!0})],Ti.prototype,"role",void 0),Ti=Ni([$t("vscode-table-header")],Ti);const Ri=[_t,n`
|
|
2352
2352
|
:host {
|
|
2353
2353
|
box-sizing: border-box;
|
|
2354
2354
|
color: var(--vscode-foreground, #cccccc);
|
|
@@ -2373,11 +2373,11 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2373
2373
|
white-space: inherit;
|
|
2374
2374
|
width: 100%;
|
|
2375
2375
|
}
|
|
2376
|
-
`];var Li=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Ui=class extends kt{constructor(){super(...arguments),this.role="columnheader"}render(){return U`
|
|
2376
|
+
`];var Li=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Ui=class extends kt{constructor(){super(...arguments),this.minWidth="0",this.index=-1,this.role="columnheader"}willUpdate(t){t.has("minWidth")&&this.index>-1&&this.dispatchEvent(new CustomEvent("vsc-table-change-min-column-width",{detail:{columnIndex:this.index,propertyValue:this.minWidth},bubbles:!0}))}render(){return U`
|
|
2377
2377
|
<div class="wrapper">
|
|
2378
2378
|
<slot></slot>
|
|
2379
2379
|
</div>
|
|
2380
|
-
`}};Ui.styles=Ri,Li([pt({reflect:!0})],Ui.prototype,"role",void 0),Ui=Li([$t("vscode-table-header-cell")],Ui);const Hi=[_t,n`
|
|
2380
|
+
`}};Ui.styles=Ri,Li([pt({attribute:"min-width"})],Ui.prototype,"minWidth",void 0),Li([pt({type:Number})],Ui.prototype,"index",void 0),Li([pt({reflect:!0})],Ui.prototype,"role",void 0),Ui=Li([$t("vscode-table-header-cell")],Ui);const Hi=[_t,n`
|
|
2381
2381
|
:host {
|
|
2382
2382
|
border-top-color: var(
|
|
2383
2383
|
--vscode-editorGroup-border,
|
|
@@ -2522,7 +2522,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2522
2522
|
position: absolute;
|
|
2523
2523
|
width: ${5}px;
|
|
2524
2524
|
}
|
|
2525
|
-
`];class Ji{constructor(t){this._hostWidth=0,this._hostX=0,this._activeSplitter=null,this._minColumnWidth=0,this._columnWidths=[],this._dragState=null,this._cachedSplitterPositions=null,(this._host=t).addController(this)}hostConnected(){this.saveHostDimensions()}get isDragging(){return null!==this._dragState}get splitterPositions(){if(this._cachedSplitterPositions)return this._cachedSplitterPositions;const t=[];let e=0;for(let i=0;i<this._columnWidths.length-1;i++)e+=this._columnWidths[i],t.push(e);return this._cachedSplitterPositions=t,t}getActiveSplitterCalculatedPosition(){const t=this.splitterPositions;if(!this._dragState)return 0;const e=t[this._dragState.splitterIndex];return this._toPx(e)}get columnWidths(){return this._columnWidths}saveHostDimensions(){const t=this._host.getBoundingClientRect(),{width:e,x:i}=t;return this._hostWidth=e,this._hostX=i,this}setActiveSplitter(t){return this._activeSplitter=t,this}getActiveSplitter(){return this._activeSplitter}setMinColumnWidth(t){return this._minColumnWidth=t,this}setColumWidths(t){return this._columnWidths=t,this._cachedSplitterPositions=null,this._host.requestUpdate(),this}shouldDrag(t){return+t.currentTarget.dataset.index===this._dragState?.splitterIndex}startDrag(t){if(t.stopPropagation(),this._dragState)return;this._activeSplitter?.setPointerCapture(t.pointerId);const e=t.pageX,i=t.currentTarget,s=e-i.getBoundingClientRect().x;this._dragState={dragOffset:s,pointerId:t.pointerId,splitterIndex:+i.dataset.index,prevX:e-s},this._host.requestUpdate()}drag(t){if(t.stopPropagation(),!t?.currentTarget?.hasPointerCapture?.(t.pointerId))return;if(!this._dragState)return;if(t.pointerId!==this._dragState.pointerId)return;if(!this.shouldDrag(t))return;const e=t.pageX,i=e-this._dragState.dragOffset,s=i-this._dragState.prevX,o=this._toPercent(s);this._dragState.prevX=i;const r=this.getActiveSplitterCalculatedPosition();s<=0&&e>r+this._hostX||s>0&&e<r+this._hostX||(this._columnWidths=function(t,e,i,s){const o=[...t];if(0===i||e<0||e>=t.length-1)return o;const r=Math.abs(i);let n=r;const h=[],a=[];for(let t=e;t>=0;t--)h.push(t);for(let i=e+1;i<t.length;i++)a.push(i);const l=i>0?a:h,c=i>0?h:a;let d=0;for(const t of l)d+=Math.max(0,o[t]-s);if(d<n)return o;for(const t of l){if(0===n)break;const e=Math.max(0,o[t]-s),i=Math.min(e,n);o[t]=o[t]-i,n-=i}let u=r;for(const t of c){if(0===u)break;o[t]=o[t]+u,u=0}return o}(this._columnWidths,this._dragState.splitterIndex,o,this._minColumnWidth),this._cachedSplitterPositions=null,this._host.requestUpdate())}stopDrag(t){if(t.stopPropagation(),!this._dragState)return;const e=t.currentTarget;try{e.releasePointerCapture(this._dragState.pointerId)}catch(t){}this._dragState=null,this._activeSplitter=null,this._host.requestUpdate()}_toPercent(t){return((t,e)=>t/e*100)(t,this._hostWidth)}_toPx(t){return((t,e)=>t/100*e)(t,this._hostWidth)}}var Yi=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Zi=class extends kt{constructor(){super(...arguments),this.role="table",this.resizable=!1,this.responsive=!1,this.bordered=!1,this.borderedColumns=!1,this.borderedRows=!1,this.breakpoint=300,this.minColumnWidth="50px",this.delayedResizing=!1,this.compact=!1,this.zebra=!1,this.zebraOdd=!1,this._sashPositions=[],this._isDragging=!1,this._sashHovers=[],this._columns=[],this._activeSashElementIndex=-1,this._componentH=0,this._componentW=0,this._headerCells=[],this._cellsOfFirstRow=[],this._prevHeaderHeight=0,this._prevComponentHeight=0,this._columnResizeController=new Ji(this),this._componentResizeObserverCallback=()=>{this._memoizeComponentDimensions(),this._updateResizeHandlersSize(),this.responsive&&this._toggleCompactView(),this._resizeTableBody()},this._headerResizeObserverCallback=()=>{this._updateResizeHandlersSize()},this._bodyResizeObserverCallback=()=>{this._resizeTableBody()},this._handleSplitterPointerMove=t=>{this._columnResizeController.shouldDrag(t)&&(this._columnResizeController.drag(t),this.delayedResizing?this._resizeColumns(!1):this._resizeColumns(!0))},this._handleSplitterPointerUp=t=>{this._stopDrag(t)},this._handleSplitterPointerCancel=t=>{this._stopDrag(t)}}set columns(t){if(!Array.isArray(t))return this.warn('Invalid value for "columns": expected an array.'),void(this._columns=[]);this._columns=t,this.isConnected&&this._initDefaultColumnSizes()}get columns(){return this._columns}connectedCallback(){super.connectedCallback(),this._memoizeComponentDimensions(),this._initDefaultColumnSizes()}disconnectedCallback(){super.disconnectedCallback(),this._componentResizeObserver?.unobserve(this),this._componentResizeObserver?.disconnect(),this._bodyResizeObserver?.disconnect()}willUpdate(t){if(t.has("minColumnWidth")){const t=Ki(this.minColumnWidth,this._componentW)??0;this._columnResizeController.setMinColumnWidth(t)}}_memoizeComponentDimensions(){const t=this.getBoundingClientRect();this._componentH=t.height,this._componentW=t.width}_queryHeaderCells(){const t=this._assignedHeaderElements;return t&&t[0]?Array.from(t[0].querySelectorAll("vscode-table-header-cell")):[]}_getHeaderCells(){return this._headerCells.length||(this._headerCells=this._queryHeaderCells()),this._headerCells}_queryCellsOfFirstRow(){const t=this._assignedBodyElements;return t&&t[0]?Array.from(t[0].querySelectorAll("vscode-table-row:first-child vscode-table-cell")):[]}_getCellsOfFirstRow(){return this._cellsOfFirstRow.length||(this._cellsOfFirstRow=this._queryCellsOfFirstRow()),this._cellsOfFirstRow}_resizeTableBody(){let t=0,e=0;const i=this.getBoundingClientRect().height;this._assignedHeaderElements&&this._assignedHeaderElements.length&&(t=this._assignedHeaderElements[0].getBoundingClientRect().height),this._assignedBodyElements&&this._assignedBodyElements.length&&(e=this._assignedBodyElements[0].getBoundingClientRect().height);const s=e-t-i;this._scrollableElement.style.height=s>0?i-t+"px":"auto"}_initResizeObserver(){this._componentResizeObserver=new ResizeObserver(this._componentResizeObserverCallback),this._componentResizeObserver.observe(this),this._headerResizeObserver=new ResizeObserver(this._headerResizeObserverCallback),this._headerResizeObserver.observe(this._headerElement)}_calculateInitialColumnWidths(){const t=this._getHeaderCells().length;let e=this.columns.slice(0,t);const i=e.filter((t=>"auto"===t)).length+t-e.length;let s=100;if(e=e.map((t=>{const e=Ki(t,this._componentW);return null===e?"auto":(s-=e,e)})),e.length<t)for(let i=e.length;i<t;i++)e.push("auto");return e=e.map((t=>"auto"===t?s/i:t)),e}_initHeaderCellSizes(t){this._getHeaderCells().forEach(((e,i)=>{e.style.width=`${t[i]}%`}))}_initBodyColumnSizes(t){this._getCellsOfFirstRow().forEach(((e,i)=>{e.style.width=`${t[i]}%`}))}_initSashes(t){const e=t.length;let i=0;this._sashPositions=[],t.forEach(((t,s)=>{if(s<e-1){const e=i+t;this._sashPositions.push(e),i=e}}))}_initDefaultColumnSizes(){const t=this._calculateInitialColumnWidths();this._columnResizeController.setColumWidths(t.map((t=>t))),this._initHeaderCellSizes(t),this._initBodyColumnSizes(t),this._initSashes(t)}_updateResizeHandlersSize(){const t=this._headerElement.getBoundingClientRect();if(t.height===this._prevHeaderHeight&&this._componentH===this._prevComponentHeight)return;this._prevHeaderHeight=t.height,this._prevComponentHeight=this._componentH;const e=this._componentH-t.height;this._sashVisibleElements.forEach((i=>{i.style.height=`${e}px`,i.style.top=`${t.height}px`}))}_applyCompactViewColumnLabels(){const t=this._getHeaderCells().map((t=>t.innerText));this.querySelectorAll("vscode-table-row").forEach((e=>{e.querySelectorAll("vscode-table-cell").forEach(((e,i)=>{e.columnLabel=t[i],e.compact=!0}))}))}_clearCompactViewColumnLabels(){this.querySelectorAll("vscode-table-cell").forEach((t=>{t.columnLabel="",t.compact=!1}))}_toggleCompactView(){const t=this.getBoundingClientRect().width<this.breakpoint;this.compact!==t&&(this.compact=t,t?this._applyCompactViewColumnLabels():this._clearCompactViewColumnLabels())}_stopDrag(t){const e=this._columnResizeController.getActiveSplitter();e&&(e.removeEventListener("pointermove",this._handleSplitterPointerMove),e.removeEventListener("pointerup",this._handleSplitterPointerUp),e.removeEventListener("pointercancel",this._handleSplitterPointerCancel)),this._columnResizeController.stopDrag(t),this._resizeColumns(!0),this._sashHovers[this._activeSashElementIndex]=!1,this._isDragging=!1,this._activeSashElementIndex=-1}_onDefaultSlotChange(){this._assignedElements.forEach((t=>{"vscode-table-header"!==t.tagName.toLowerCase()?"vscode-table-body"!==t.tagName.toLowerCase()||(t.slot="body"):t.slot="header"}))}_onHeaderSlotChange(){this._headerCells=this._queryHeaderCells()}_onBodySlotChange(){if(this._initDefaultColumnSizes(),this._initResizeObserver(),this._updateResizeHandlersSize(),!this._bodyResizeObserver){const t=this._assignedBodyElements[0]??null;t&&(this._bodyResizeObserver=new ResizeObserver(this._bodyResizeObserverCallback),this._bodyResizeObserver.observe(t))}}_onSashMouseOver(t){if(this._isDragging)return;const e=t.currentTarget,i=Number(e.dataset.index);this._sashHovers[i]=!0,this.requestUpdate()}_onSashMouseOut(t){if(t.stopPropagation(),this._isDragging)return;const e=t.currentTarget,i=Number(e.dataset.index);this._sashHovers[i]=!1,this.requestUpdate()}_resizeColumns(t=!0){const e=this._columnResizeController.columnWidths;if(this._getHeaderCells().forEach(((t,i)=>t.style.width=`${e[i]}%`)),t){this._getCellsOfFirstRow().forEach(((t,i)=>t.style.width=`${e[i]}%`))}}_handleSplitterPointerDown(t){t.stopPropagation();const e=t.currentTarget;this._columnResizeController.saveHostDimensions().setActiveSplitter(e).startDrag(t),e.addEventListener("pointermove",this._handleSplitterPointerMove),e.addEventListener("pointerup",this._handleSplitterPointerUp),e.addEventListener("pointercancel",this._handleSplitterPointerCancel)}render(){const t=this._columnResizeController.splitterPositions.map(((t,e)=>{const i=Mt({sash:!0,hover:this._sashHovers[e],resizable:this.resizable}),s=`${t}%`;return this.resizable?U`
|
|
2525
|
+
`];class Ji{constructor(t){this._hostWidth=0,this._hostX=0,this._activeSplitter=null,this._columnMinWidths=new Map,this._columnWidths=[],this._dragState=null,this._cachedSplitterPositions=null,(this._host=t).addController(this)}hostConnected(){this.saveHostDimensions()}get isDragging(){return null!==this._dragState}get splitterPositions(){if(this._cachedSplitterPositions)return this._cachedSplitterPositions;const t=[];let e=0;for(let i=0;i<this._columnWidths.length-1;i++)e+=this._columnWidths[i],t.push(e);return this._cachedSplitterPositions=t,t}getActiveSplitterCalculatedPosition(){const t=this.splitterPositions;if(!this._dragState)return 0;const e=t[this._dragState.splitterIndex];return this._toPx(e)}get columnWidths(){return this._columnWidths}get columnMinWidths(){return new Map(this._columnMinWidths)}saveHostDimensions(){const t=this._host.getBoundingClientRect(),{width:e,x:i}=t;return this._hostWidth=e,this._hostX=i,this}setActiveSplitter(t){return this._activeSplitter=t,this}getActiveSplitter(){return this._activeSplitter}setColumnMinWidthAt(t,e){return this._columnMinWidths.set(t,e),this._host.requestUpdate(),this}setColumWidths(t){return this._columnWidths=t,this._cachedSplitterPositions=null,this._host.requestUpdate(),this}shouldDrag(t){return+t.currentTarget.dataset.index===this._dragState?.splitterIndex}startDrag(t){if(t.stopPropagation(),this._dragState)return;this._activeSplitter?.setPointerCapture(t.pointerId);const e=t.pageX,i=t.currentTarget,s=e-i.getBoundingClientRect().x;this._dragState={dragOffset:s,pointerId:t.pointerId,splitterIndex:+i.dataset.index,prevX:e-s},this._host.requestUpdate()}drag(t){if(t.stopPropagation(),!t?.currentTarget?.hasPointerCapture?.(t.pointerId))return;if(!this._dragState)return;if(t.pointerId!==this._dragState.pointerId)return;if(!this.shouldDrag(t))return;const e=t.pageX,i=e-this._dragState.dragOffset,s=i-this._dragState.prevX,o=this._toPercent(s);this._dragState.prevX=i;const r=this.getActiveSplitterCalculatedPosition();s<=0&&e>r+this._hostX||s>0&&e<r+this._hostX||(this._columnWidths=function(t,e,i,s){const o=[...t];if(0===i||e<0||e>=t.length-1)return o;const r=Math.abs(i);let n=r;const h=[],a=[];for(let t=e;t>=0;t--)h.push(t);for(let i=e+1;i<t.length;i++)a.push(i);const l=i>0?a:h,c=i>0?h:a;let d=0;for(const t of l)d+=Math.max(0,o[t]-(s.get(t)??0));if(d<n)return o;for(const t of l){if(0===n)break;const e=Math.max(0,o[t]-(s.get(t)??0)),i=Math.min(e,n);o[t]=o[t]-i,n-=i}let u=r;for(const t of c){if(0===u)break;o[t]=o[t]+u,u=0}return o}(this._columnWidths,this._dragState.splitterIndex,o,this._columnMinWidths),this._cachedSplitterPositions=null,this._host.requestUpdate())}stopDrag(t){if(t.stopPropagation(),!this._dragState)return;const e=t.currentTarget;try{e.releasePointerCapture(this._dragState.pointerId)}catch(t){}this._dragState=null,this._activeSplitter=null,this._host.requestUpdate()}_toPercent(t){return((t,e)=>t/e*100)(t,this._hostWidth)}_toPx(t){return((t,e)=>t/100*e)(t,this._hostWidth)}}var Yi=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};let Zi=class extends kt{set columns(t){if(!Array.isArray(t))return this.warn('Invalid value for "columns": expected an array.'),void(this._columns=[]);this._columns=t,this.isConnected&&this._initDefaultColumnSizes()}get columns(){return this._columns}constructor(){super(),this.role="table",this.resizable=!1,this.responsive=!1,this.bordered=!1,this.borderedColumns=!1,this.borderedRows=!1,this.breakpoint=300,this.minColumnWidth="50px",this.delayedResizing=!1,this.compact=!1,this.zebra=!1,this.zebraOdd=!1,this._sashPositions=[],this._isDragging=!1,this._sashHovers=[],this._columns=[],this._activeSashElementIndex=-1,this._componentH=0,this._componentW=0,this._headerCells=[],this._cellsOfFirstRow=[],this._prevHeaderHeight=0,this._prevComponentHeight=0,this._columnResizeController=new Ji(this),this._componentResizeObserverCallback=()=>{this._memoizeComponentDimensions(),this._updateResizeHandlersSize(),this.responsive&&this._toggleCompactView(),this._resizeTableBody()},this._headerResizeObserverCallback=()=>{this._updateResizeHandlersSize()},this._bodyResizeObserverCallback=()=>{this._resizeTableBody()},this._handleSplitterPointerMove=t=>{this._columnResizeController.shouldDrag(t)&&(this._columnResizeController.drag(t),this.delayedResizing?this._resizeColumns(!1):this._resizeColumns(!0))},this._handleSplitterPointerUp=t=>{this._stopDrag(t)},this._handleSplitterPointerCancel=t=>{this._stopDrag(t)},this._handleMinColumnWidthChange=t=>{const{columnIndex:e,propertyValue:i}=t.detail,s=Ki(i,this._componentW);s&&this._columnResizeController.setColumnMinWidthAt(e,s)},this.addEventListener("vsc-table-change-min-column-width",this._handleMinColumnWidthChange)}connectedCallback(){super.connectedCallback(),this._memoizeComponentDimensions(),this._initDefaultColumnSizes()}disconnectedCallback(){super.disconnectedCallback(),this._componentResizeObserver?.unobserve(this),this._componentResizeObserver?.disconnect(),this._bodyResizeObserver?.disconnect()}willUpdate(t){if(t.has("minColumnWidth")){const t=Ki(this.minColumnWidth,this._componentW)??0,e=this._columnResizeController.columnMinWidths,i=this._columnResizeController.columnWidths;for(let s=0;s<i.length;s++)e.has(s)||this._columnResizeController.setColumnMinWidthAt(s,t)}}_memoizeComponentDimensions(){const t=this.getBoundingClientRect();this._componentH=t.height,this._componentW=t.width}_queryHeaderCells(){const t=this._assignedHeaderElements;return t&&t[0]?Array.from(t[0].querySelectorAll("vscode-table-header-cell")):[]}_getHeaderCells(){return this._headerCells.length||(this._headerCells=this._queryHeaderCells()),this._headerCells}_queryCellsOfFirstRow(){const t=this._assignedBodyElements;return t&&t[0]?Array.from(t[0].querySelectorAll("vscode-table-row:first-child vscode-table-cell")):[]}_getCellsOfFirstRow(){return this._cellsOfFirstRow.length||(this._cellsOfFirstRow=this._queryCellsOfFirstRow()),this._cellsOfFirstRow}_resizeTableBody(){let t=0,e=0;const i=this.getBoundingClientRect().height;this._assignedHeaderElements&&this._assignedHeaderElements.length&&(t=this._assignedHeaderElements[0].getBoundingClientRect().height),this._assignedBodyElements&&this._assignedBodyElements.length&&(e=this._assignedBodyElements[0].getBoundingClientRect().height);const s=e-t-i;this._scrollableElement.style.height=s>0?i-t+"px":"auto"}_initResizeObserver(){this._componentResizeObserver=new ResizeObserver(this._componentResizeObserverCallback),this._componentResizeObserver.observe(this),this._headerResizeObserver=new ResizeObserver(this._headerResizeObserverCallback),this._headerResizeObserver.observe(this._headerElement)}_calculateInitialColumnWidths(){const t=this._getHeaderCells().length;let e=this.columns.slice(0,t);const i=e.filter((t=>"auto"===t)).length+t-e.length;let s=100;if(e=e.map((t=>{const e=Ki(t,this._componentW);return null===e?"auto":(s-=e,e)})),e.length<t)for(let i=e.length;i<t;i++)e.push("auto");return e=e.map((t=>"auto"===t?s/i:t)),e}_initHeaderCellSizes(t){this._getHeaderCells().forEach(((e,i)=>{e.style.width=`${t[i]}%`}))}_initBodyColumnSizes(t){this._getCellsOfFirstRow().forEach(((e,i)=>{e.style.width=`${t[i]}%`}))}_initSashes(t){const e=t.length;let i=0;this._sashPositions=[],t.forEach(((t,s)=>{if(s<e-1){const e=i+t;this._sashPositions.push(e),i=e}}))}_initDefaultColumnSizes(){const t=this._calculateInitialColumnWidths();this._columnResizeController.setColumWidths(t.map((t=>t))),this._initHeaderCellSizes(t),this._initBodyColumnSizes(t),this._initSashes(t)}_updateResizeHandlersSize(){const t=this._headerElement.getBoundingClientRect();if(t.height===this._prevHeaderHeight&&this._componentH===this._prevComponentHeight)return;this._prevHeaderHeight=t.height,this._prevComponentHeight=this._componentH;const e=this._componentH-t.height;this._sashVisibleElements.forEach((i=>{i.style.height=`${e}px`,i.style.top=`${t.height}px`}))}_applyCompactViewColumnLabels(){const t=this._getHeaderCells().map((t=>t.innerText));this.querySelectorAll("vscode-table-row").forEach((e=>{e.querySelectorAll("vscode-table-cell").forEach(((e,i)=>{e.columnLabel=t[i],e.compact=!0}))}))}_clearCompactViewColumnLabels(){this.querySelectorAll("vscode-table-cell").forEach((t=>{t.columnLabel="",t.compact=!1}))}_toggleCompactView(){const t=this.getBoundingClientRect().width<this.breakpoint;this.compact!==t&&(this.compact=t,t?this._applyCompactViewColumnLabels():this._clearCompactViewColumnLabels())}_stopDrag(t){const e=this._columnResizeController.getActiveSplitter();e&&(e.removeEventListener("pointermove",this._handleSplitterPointerMove),e.removeEventListener("pointerup",this._handleSplitterPointerUp),e.removeEventListener("pointercancel",this._handleSplitterPointerCancel)),this._columnResizeController.stopDrag(t),this._resizeColumns(!0),this._sashHovers[this._activeSashElementIndex]=!1,this._isDragging=!1,this._activeSashElementIndex=-1}_onDefaultSlotChange(){this._assignedElements.forEach((t=>{"vscode-table-header"!==t.tagName.toLowerCase()?"vscode-table-body"!==t.tagName.toLowerCase()||(t.slot="body"):t.slot="header"}))}_onHeaderSlotChange(){this._headerCells=this._queryHeaderCells();[].fill(0,0,this._headerCells.length-1),this._headerCells.forEach(((t,e)=>{if(t.index=e,t.minWidth){const i=Ki(t.minWidth,this._componentW)??0;this._columnResizeController.setColumnMinWidthAt(e,i)}}))}_onBodySlotChange(){if(this._initDefaultColumnSizes(),this._initResizeObserver(),this._updateResizeHandlersSize(),!this._bodyResizeObserver){const t=this._assignedBodyElements[0]??null;t&&(this._bodyResizeObserver=new ResizeObserver(this._bodyResizeObserverCallback),this._bodyResizeObserver.observe(t))}}_onSashMouseOver(t){if(this._isDragging)return;const e=t.currentTarget,i=Number(e.dataset.index);this._sashHovers[i]=!0,this.requestUpdate()}_onSashMouseOut(t){if(t.stopPropagation(),this._isDragging)return;const e=t.currentTarget,i=Number(e.dataset.index);this._sashHovers[i]=!1,this.requestUpdate()}_resizeColumns(t=!0){const e=this._columnResizeController.columnWidths;if(this._getHeaderCells().forEach(((t,i)=>t.style.width=`${e[i]}%`)),t){this._getCellsOfFirstRow().forEach(((t,i)=>t.style.width=`${e[i]}%`))}}_handleSplitterPointerDown(t){t.stopPropagation();const e=t.currentTarget;this._columnResizeController.saveHostDimensions().setActiveSplitter(e).startDrag(t),e.addEventListener("pointermove",this._handleSplitterPointerMove),e.addEventListener("pointerup",this._handleSplitterPointerUp),e.addEventListener("pointercancel",this._handleSplitterPointerCancel)}render(){const t=this._columnResizeController.splitterPositions.map(((t,e)=>{const i=Mt({sash:!0,hover:this._sashHovers[e],resizable:this.resizable}),s=`${t}%`;return this.resizable?U`
|
|
2526
2526
|
<div
|
|
2527
2527
|
class=${i}
|
|
2528
2528
|
data-index=${e}
|
|
@@ -2642,7 +2642,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2642
2642
|
textarea {
|
|
2643
2643
|
background-color: var(--vscode-settings-textInputBackground, #313131);
|
|
2644
2644
|
border-color: var(--vscode-settings-textInputBorder, transparent);
|
|
2645
|
-
border-radius:
|
|
2645
|
+
border-radius: 4px;
|
|
2646
2646
|
border-style: solid;
|
|
2647
2647
|
border-width: 1px;
|
|
2648
2648
|
box-sizing: border-box;
|
|
@@ -2780,7 +2780,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2780
2780
|
--vscode-settings-textInputBorder,
|
|
2781
2781
|
var(--vscode-settings-textInputBackground, #3c3c3c)
|
|
2782
2782
|
);
|
|
2783
|
-
border-radius:
|
|
2783
|
+
border-radius: 4px;
|
|
2784
2784
|
border-style: solid;
|
|
2785
2785
|
border-width: 1px;
|
|
2786
2786
|
box-sizing: border-box;
|
|
@@ -2898,7 +2898,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
2898
2898
|
@focus=${this._onFocus}
|
|
2899
2899
|
@input=${this._onInput}
|
|
2900
2900
|
@keydown=${this._onKeyDown}
|
|
2901
|
-
|
|
2901
|
+
/>
|
|
2902
2902
|
<slot name="content-after"></slot>
|
|
2903
2903
|
</div>
|
|
2904
2904
|
`}};as.styles=ns,as.formAssociated=!0,as.shadowRootOptions={...lt.shadowRootOptions,delegatesFocus:!0},hs([pt()],as.prototype,"autocomplete",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"autofocus",void 0),hs([pt({attribute:"default-value"})],as.prototype,"defaultValue",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"disabled",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"focused",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"invalid",void 0),hs([pt({attribute:!1})],as.prototype,"label",void 0),hs([pt({type:Number})],as.prototype,"max",void 0),hs([pt({type:Number})],as.prototype,"maxLength",void 0),hs([pt({type:Number})],as.prototype,"min",void 0),hs([pt({type:Number})],as.prototype,"minLength",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"multiple",void 0),hs([pt({reflect:!0})],as.prototype,"name",void 0),hs([pt()],as.prototype,"pattern",void 0),hs([pt()],as.prototype,"placeholder",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"readonly",void 0),hs([pt({type:Boolean,reflect:!0})],as.prototype,"required",void 0),hs([pt({type:Number})],as.prototype,"step",void 0),hs([pt({reflect:!0})],as.prototype,"type",null),hs([pt()],as.prototype,"value",null),hs([ft("#input")],as.prototype,"_inputEl",void 0),hs([vt()],as.prototype,"_value",void 0),hs([vt()],as.prototype,"_type",void 0),as=hs([$t("vscode-textfield")],as);const ls=[_t,n`
|
|
@@ -3338,7 +3338,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
3338
3338
|
:host([branch][open]) ::slotted(vscode-tree-item) {
|
|
3339
3339
|
display: block;
|
|
3340
3340
|
}
|
|
3341
|
-
`];var Vs,
|
|
3341
|
+
`];var Vs,Ns=function(t,e,i,s){for(var o,r=arguments.length,n=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s,h=t.length-1;h>=0;h--)(o=t[h])&&(n=(r<3?o(n):r>3?o(e,i,n):o(e,i))||n);return r>3&&n&&Object.defineProperty(e,i,n),n};const Ts=U`<svg
|
|
3342
3342
|
width="16"
|
|
3343
3343
|
height="16"
|
|
3344
3344
|
viewBox="0 0 16 16"
|
|
@@ -3361,7 +3361,7 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
3361
3361
|
class=${Mt({"arrow-container":!0,"icon-rotated":this.open})}
|
|
3362
3362
|
part="arrow-icon-container"
|
|
3363
3363
|
>
|
|
3364
|
-
${
|
|
3364
|
+
${Ts}
|
|
3365
3365
|
</div>`:q}
|
|
3366
3366
|
<div class=${Mt(c)} part="icon-container">
|
|
3367
3367
|
${this.branch&&!this.open?U`<slot
|
|
@@ -3416,4 +3416,4 @@ const t=globalThis,e=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow
|
|
|
3416
3416
|
@slotchange=${this._handleChildrenSlotChange}
|
|
3417
3417
|
></slot>
|
|
3418
3418
|
</div>
|
|
3419
|
-
</div>`}};Ls.styles=Ps,
|
|
3419
|
+
</div>`}};Ls.styles=Ps,Ns([pt({type:Boolean})],Ls.prototype,"active",void 0),Ns([pt({type:Boolean,reflect:!0})],Ls.prototype,"branch",void 0),Ns([pt({type:Boolean})],Ls.prototype,"hasActiveItem",void 0),Ns([pt({type:Boolean})],Ls.prototype,"hasSelectedItem",void 0),Ns([pt({type:Boolean})],Ls.prototype,"highlightedGuides",void 0),Ns([pt({type:Boolean,reflect:!0})],Ls.prototype,"open",void 0),Ns([pt({type:Number,reflect:!0})],Ls.prototype,"level",void 0),Ns([pt({type:Boolean,reflect:!0})],Ls.prototype,"selected",null),Ns([vt()],Ls.prototype,"_hasBranchIcon",void 0),Ns([vt()],Ls.prototype,"_hasBranchOpenedIcon",void 0),Ns([vt()],Ls.prototype,"_hasLeafIcon",void 0),Ns([vt()],Ls.prototype,"_hasDescriptionSlotContent",void 0),Ns([vt()],Ls.prototype,"_hasActionsSlotContent",void 0),Ns([vt()],Ls.prototype,"_hasDecorationSlotContent",void 0),Ns([ys({context:$s,subscribe:!0})],Ls.prototype,"_treeContextState",void 0),Ns([ys({context:_s,subscribe:!0})],Ls.prototype,"_configContext",void 0),Ns([mt({selector:"vscode-tree-item"})],Ls.prototype,"_initiallyAssignedTreeItems",void 0),Ns([mt({selector:"vscode-tree-item",slot:"children"})],Ls.prototype,"_childrenTreeItems",void 0),Ns([mt({slot:"description",flatten:!0})],Ls.prototype,"_descriptionSlotElements",void 0),Ns([mt({slot:"actions",flatten:!0})],Ls.prototype,"_actionsSlotElements",void 0),Ns([mt({slot:"decoration",flatten:!0})],Ls.prototype,"_decorationSlotElements",void 0),Ls=Vs=Ns([$t("vscode-tree-item")],Ls);export{At as VscodeBadge,Ut as VscodeButton,qt as VscodeButtonGroup,te as VscodeCheckbox,se as VscodeCheckboxGroup,ne as VscodeCollapsible,ue as VscodeContextMenu,le as VscodeContextMenuItem,be as VscodeDivider,xe as VscodeFormContainer,ke as VscodeFormGroup,Ce as VscodeFormHelper,Tt as VscodeIcon,Ee as VscodeLabel,oi as VscodeMultiSelect,Ue as VscodeOption,ci as VscodeProgressBar,hi as VscodeProgressRing,pi as VscodeRadio,fi as VscodeRadioGroup,Ze as VscodeScrollable,mi as VscodeSingleSelect,Si as VscodeSplitLayout,Ai as VscodeTabHeader,Ei as VscodeTabPanel,Zi as VscodeTable,Mi as VscodeTableBody,Pi as VscodeTableCell,Ti as VscodeTableHeader,Ui as VscodeTableHeaderCell,qi as VscodeTableRow,es as VscodeTabs,os as VscodeTextarea,as as VscodeTextfield,ds as VscodeToolbarButton,vs as VscodeToolbarContainer,Fs as VscodeTree,Ls as VscodeTreeItem};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VscElement.js","sourceRoot":"","sources":["../../src/includes/VscElement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,KAAK,CAAC;AAE/B,MAAM,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"VscElement.js","sourceRoot":"","sources":["../../src/includes/VscElement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,KAAK,CAAC;AAE/B,MAAM,OAAO,GAAG,OAAO,CAAC;AACxB,MAAM,UAAU,GAAG,2CAA2C,CAAC;AAE/D,MAAM,IAAI,GAAG,CAAC,OAAe,EAAE,iBAA8B,EAAE,EAAE;IAC/D,MAAM,MAAM,GAAG,oBAAoB,CAAC;IAEpC,IAAI,iBAAiB,EAAE,CAAC;QACtB,sCAAsC;QACtC,OAAO,CAAC,IAAI,CAAC,GAAG,MAAM,GAAG,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;IAC7D,CAAC;SAAM,CAAC;QACN,sCAAsC;QACtC,OAAO,CAAC,IAAI,CAAC,GAAG,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;IACpD,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,OAAO,UAAW,SAAQ,UAAU;IACxC,8BAA8B;IAC9B,IAAI,OAAO;QACT,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,IAAI,CAAC,OAAe;QAClB,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IACtB,CAAC;CACF;AASD;;GAEG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,OAAe,EAAE,EAAE;IAC/C,OAAO,CAAC,aAAiC,EAAE,EAAE;QAC3C,MAAM,kBAAkB,GAAG,cAAc,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC;QAEvD,IAAI,CAAC,kBAAkB,EAAE,CAAC;YACxB,cAAc,CAAC,MAAM,CAAC,OAAO,EAAE,aAAyC,CAAC,CAAC;YAC1E,OAAO;QACT,CAAC;QAED,IAAI,UAAU,IAAI,MAAM,EAAE,CAAC;YACzB,OAAO;QACT,CAAC;QAED,MAAM,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;QAC3C,MAAM,cAAc,GAAI,EAAiB,EAAE,OAAO,CAAC;QACnD,IAAI,OAAO,GAAG,EAAE,CAAC;QAEjB,IAAI,CAAC,cAAc,EAAE,CAAC;YACpB,OAAO;gBACL,mEAAmE,CAAC;QACxE,CAAC;aAAM,IAAI,cAAc,KAAK,OAAO,EAAE,CAAC;YACtC,OAAO;gBACL,mEAAmE,CAAC;YACtE,OAAO,IAAI,oBAAoB,OAAO,8BAA8B,cAAc,IAAI,CAAC;QACzF,CAAC;aAAM,CAAC;YACN,OAAO,IAAI,iEAAiE,OAAO,IAAI,CAAC;QAC1F,CAAC;QAED,IAAI,CACF,uBAAuB,OAAO,KAAK,OAAO,0CAA0C,UAAU,UAAU,CACzG,CAAC;IACJ,CAAC,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import {LitElement} from 'lit';\n\nconst VERSION = '2.5.0';\nconst CONFIG_KEY = '__vscodeElements_disableRegistryWarning__';\n\nconst warn = (message: string, componentInstance?: VscElement) => {\n const prefix = '[VSCode Elements] ';\n\n if (componentInstance) {\n // eslint-disable-next-line no-console\n console.warn(`${prefix}${message}\\n%o`, componentInstance);\n } else {\n // eslint-disable-next-line no-console\n console.warn(`${message}\\n%o`, componentInstance);\n }\n};\n\nexport class VscElement extends LitElement {\n /** VSCode Elements version */\n get version(): string {\n return VERSION;\n }\n\n warn(message: string) {\n warn(message, this);\n }\n}\n\ntype CustomElementClass = Omit<typeof HTMLElement, 'new'>;\n\nexport type Constructor<T> = {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n new (...args: any[]): T;\n};\n\n/**\n * Own implementation of Lit's customElement decorator.\n */\nexport const customElement = (tagName: string) => {\n return (classOrTarget: CustomElementClass) => {\n const customElementClass = customElements.get(tagName);\n\n if (!customElementClass) {\n customElements.define(tagName, classOrTarget as CustomElementConstructor);\n return;\n }\n\n if (CONFIG_KEY in window) {\n return;\n }\n\n const el = document.createElement(tagName);\n const anotherVersion = (el as VscElement)?.version;\n let message = '';\n\n if (!anotherVersion) {\n message +=\n 'is already registered by an unknown custom element handler class.';\n } else if (anotherVersion !== VERSION) {\n message +=\n 'is already registered by a different version of VSCode Elements. ';\n message += `This version is \"${VERSION}\", while the other one is \"${anotherVersion}\".`;\n } else {\n message += `is already registered by the same version of VSCode Elements (${VERSION}).`;\n }\n\n warn(\n `The custom element \"${tagName}\" ${message}\\nTo suppress this warning, set window.${CONFIG_KEY} to true`\n );\n };\n};\n"]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type Px = number & {
|
|
2
|
+
readonly __unit: 'px';
|
|
3
|
+
};
|
|
4
|
+
export type Percent = number & {
|
|
5
|
+
readonly __unit: '%';
|
|
6
|
+
};
|
|
7
|
+
export declare const px: (value: number) => Px;
|
|
8
|
+
export declare const percent: (value: number) => Percent;
|
|
9
|
+
export declare const toPercent: (px: Px, container: Px) => Percent;
|
|
10
|
+
export declare const toPx: (p: Percent, container: Px) => Px;
|
|
11
|
+
export declare const parseSizeAttributeToPercent: (raw: string | number, base: number) => Percent | null;
|
|
12
|
+
//# sourceMappingURL=sizes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sizes.d.ts","sourceRoot":"","sources":["../../src/includes/sizes.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,EAAE,GAAG,MAAM,GAAG;IAAC,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAA;CAAC,CAAC;AAClD,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG;IAAC,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAA;CAAC,CAAC;AAEtD,eAAO,MAAM,EAAE,GAAI,OAAO,MAAM,KAAG,EAAiB,CAAC;AACrD,eAAO,MAAM,OAAO,GAAI,OAAO,MAAM,KAAG,OAA2B,CAAC;AAEpE,eAAO,MAAM,SAAS,GAAI,IAAI,EAAE,EAAE,WAAW,EAAE,KAAG,OACjB,CAAC;AAElC,eAAO,MAAM,IAAI,GAAI,GAAG,OAAO,EAAE,WAAW,EAAE,KAAG,EACtB,CAAC;AAsB5B,eAAO,MAAM,2BAA2B,GACtC,KAAK,MAAM,GAAG,MAAM,EACpB,MAAM,MAAM,KACX,OAAO,GAAG,IAaZ,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export const px = (value) => value;
|
|
2
|
+
export const percent = (value) => value;
|
|
3
|
+
export const toPercent = (px, container) => percent((px / container) * 100);
|
|
4
|
+
export const toPx = (p, container) => px((p / 100) * container);
|
|
5
|
+
const parsers = [
|
|
6
|
+
{
|
|
7
|
+
test: (v) => /^-?\d+(\.\d+)?%$/.test(v),
|
|
8
|
+
parse: (v) => Number(v.slice(0, -1)),
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
test: (v) => /^-?\d+(\.\d+)?px$/.test(v),
|
|
12
|
+
parse: (v, base) => (Number(v.slice(0, -2)) / base) * 100,
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
test: (v) => /^-?\d+(\.\d+)?$/.test(v),
|
|
16
|
+
parse: (v, base) => (Number(v) / base) * 100,
|
|
17
|
+
},
|
|
18
|
+
];
|
|
19
|
+
export const parseSizeAttributeToPercent = (raw, base) => {
|
|
20
|
+
if (!Number.isFinite(base) || base === 0) {
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
if (typeof raw === 'number') {
|
|
24
|
+
return Number.isFinite(raw) ? percent((raw / base) * 100) : null;
|
|
25
|
+
}
|
|
26
|
+
const value = raw.trim();
|
|
27
|
+
const parser = parsers.find((p) => p.test(value));
|
|
28
|
+
return parser ? percent(parser.parse(value, base)) : null;
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=sizes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sizes.js","sourceRoot":"","sources":["../../src/includes/sizes.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAa,EAAM,EAAE,CAAC,KAAW,CAAC;AACrD,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,KAAa,EAAW,EAAE,CAAC,KAAgB,CAAC;AAEpE,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EAAM,EAAE,SAAa,EAAW,EAAE,CAC1D,OAAO,CAAC,CAAC,EAAE,GAAG,SAAS,CAAC,GAAG,GAAG,CAAC,CAAC;AAElC,MAAM,CAAC,MAAM,IAAI,GAAG,CAAC,CAAU,EAAE,SAAa,EAAM,EAAE,CACpD,EAAE,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,GAAG,SAAS,CAAC,CAAC;AAO5B,MAAM,OAAO,GAAa;IACxB;QACE,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC,CAAC;QACvC,KAAK,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;KACrC;IACD;QACE,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,mBAAmB,CAAC,IAAI,CAAC,CAAC,CAAC;QACxC,KAAK,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,GAAG,GAAG;KAC1D;IACD;QACE,IAAI,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC,CAAC;QACtC,KAAK,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,GAAG,GAAG;KAC7C;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,2BAA2B,GAAG,CACzC,GAAoB,EACpB,IAAY,EACI,EAAE;IAClB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,IAAI,KAAK,CAAC,EAAE,CAAC;QACzC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,OAAO,GAAG,KAAK,QAAQ,EAAE,CAAC;QAC5B,OAAO,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,GAAG,IAAI,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IACnE,CAAC;IAED,MAAM,KAAK,GAAG,GAAG,CAAC,IAAI,EAAE,CAAC;IACzB,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;IAElD,OAAO,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;AAC5D,CAAC,CAAC","sourcesContent":["export type Px = number & {readonly __unit: 'px'};\nexport type Percent = number & {readonly __unit: '%'};\n\nexport const px = (value: number): Px => value as Px;\nexport const percent = (value: number): Percent => value as Percent;\n\nexport const toPercent = (px: Px, container: Px): Percent =>\n percent((px / container) * 100);\n\nexport const toPx = (p: Percent, container: Px): Px =>\n px((p / 100) * container);\n\ntype Parser = {\n test: (value: string) => boolean;\n parse: (value: string, base: number) => number;\n};\n\nconst parsers: Parser[] = [\n {\n test: (v) => /^-?\\d+(\\.\\d+)?%$/.test(v),\n parse: (v) => Number(v.slice(0, -1)),\n },\n {\n test: (v) => /^-?\\d+(\\.\\d+)?px$/.test(v),\n parse: (v, base) => (Number(v.slice(0, -2)) / base) * 100,\n },\n {\n test: (v) => /^-?\\d+(\\.\\d+)?$/.test(v),\n parse: (v, base) => (Number(v) / base) * 100,\n },\n];\n\nexport const parseSizeAttributeToPercent = (\n raw: string | number,\n base: number\n): Percent | null => {\n if (!Number.isFinite(base) || base === 0) {\n return null;\n }\n\n if (typeof raw === 'number') {\n return Number.isFinite(raw) ? percent((raw / base) * 100) : null;\n }\n\n const value = raw.trim();\n const parser = parsers.find((p) => p.test(value));\n\n return parser ? percent(parser.parse(value, base)) : null;\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/includes/vscode-select/styles.ts"],"names":[],"mappings":";AAGA,
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/includes/vscode-select/styles.ts"],"names":[],"mappings":";AAGA,wBA2ZE"}
|