@descope/web-components-ui 2.2.23 → 2.2.25
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/README.md +1 -1
- package/dist/umd/1408.js +2 -2
- package/dist/umd/1453.js +177 -0
- package/dist/umd/{1995.js.LICENSE.txt → 1453.js.LICENSE.txt} +6 -0
- package/dist/umd/1453.js.map +1 -0
- package/dist/umd/1899.js +2 -2
- package/dist/umd/2562.js +3 -0
- package/dist/umd/2562.js.map +1 -0
- package/dist/umd/3620.js +3 -3
- package/dist/umd/4518.js +3 -3
- package/dist/umd/4550.js +2 -2
- package/dist/umd/4623.js +1 -1
- package/dist/umd/4914.js +1 -1
- package/dist/umd/4914.js.map +1 -1
- package/dist/umd/5260.js +2 -2
- package/dist/umd/5263.js +498 -0
- package/dist/umd/5263.js.LICENSE.txt +17 -0
- package/dist/umd/5263.js.map +1 -0
- package/dist/umd/5648.js +1 -1
- package/dist/umd/5966.js +125 -0
- package/dist/umd/5966.js.map +1 -0
- package/dist/umd/6477.js +3 -3
- package/dist/umd/7291.js +2 -2
- package/dist/umd/7387.js +144 -0
- package/dist/umd/{6419.js.LICENSE.txt → 7387.js.LICENSE.txt} +8 -2
- package/dist/umd/7387.js.map +1 -0
- package/dist/umd/7774.js +3 -3
- package/dist/umd/7939.js +1 -1
- package/dist/umd/8202.js +82 -0
- package/dist/umd/{descope-apps-list.js.LICENSE.txt → 8202.js.LICENSE.txt} +0 -6
- package/dist/umd/8202.js.map +1 -0
- package/dist/umd/8983.js +1 -1
- package/dist/umd/9117.js +3 -3
- package/dist/umd/9970.js +1 -1
- package/dist/umd/button-selection-group-fields-descope-button-selection-group-item-index-js.js +1 -1
- package/dist/umd/descope-apps-list.js +1 -17
- package/dist/umd/descope-apps-list.js.map +1 -1
- package/dist/umd/descope-avatar.js +161 -2
- package/dist/umd/descope-avatar.js.LICENSE.txt +6 -0
- package/dist/umd/descope-avatar.js.map +1 -1
- package/dist/umd/descope-button.js +1 -1
- package/dist/umd/descope-combo-box.js +2 -2
- package/dist/umd/descope-date-field-index-js.js +1 -1
- package/dist/umd/descope-email-field-index-js.js +1 -1
- package/dist/umd/descope-grid-descope-grid-custom-column-index-js.js +1 -1
- package/dist/umd/descope-grid-descope-grid-custom-column-index-js.js.map +1 -1
- package/dist/umd/descope-grid-descope-grid-item-details-column-index-js.js +1 -1
- package/dist/umd/descope-grid-descope-grid-item-details-column-index-js.js.map +1 -1
- package/dist/umd/descope-grid-descope-grid-selection-column-index-js.js +1 -1
- package/dist/umd/descope-grid-descope-grid-selection-column-index-js.js.map +1 -1
- package/dist/umd/descope-grid-descope-grid-text-column-index-js.js +1 -1
- package/dist/umd/descope-grid-descope-grid-text-column-index-js.js.map +1 -1
- package/dist/umd/descope-outbound-app-button.js +1 -1
- package/dist/umd/descope-outbound-apps.js +1 -338
- package/dist/umd/descope-outbound-apps.js.map +1 -1
- package/dist/umd/descope-passcode-index-js.js +1 -1
- package/dist/umd/descope-security-questions-verify-index-js.js +1 -1
- package/dist/umd/descope-text-field-index-js.js +1 -1
- package/dist/umd/descope-timer-button.js +1 -1
- package/dist/umd/descope-tooltip.js +2 -1
- package/dist/umd/descope-tooltip.js.LICENSE.txt +11 -0
- package/dist/umd/descope-tooltip.js.map +1 -1
- package/dist/umd/descope-upload-file-index-js.js +1 -1
- package/dist/umd/descope-user-attribute-index-js.js +1 -1
- package/dist/umd/descope-user-auth-method-index-js.js +1 -1
- package/dist/umd/index.js +1 -1
- package/dist/umd/index.js.map +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-descope-phone-input-box-internal-index-js.js +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-index-js.js +1 -1
- package/package.json +29 -29
- package/dist/umd/1519.js +0 -203
- package/dist/umd/1519.js.LICENSE.txt +0 -51
- package/dist/umd/1519.js.map +0 -1
- package/dist/umd/1995.js +0 -241
- package/dist/umd/1995.js.map +0 -1
- package/dist/umd/6419.js +0 -82
- package/dist/umd/6419.js.map +0 -1
- package/dist/umd/676.js +0 -3
- package/dist/umd/676.js.map +0 -1
- package/dist/umd/8618.js +0 -125
- package/dist/umd/8618.js.map +0 -1
- package/dist/umd/descope-outbound-apps.js.LICENSE.txt +0 -5
- /package/dist/umd/{676.js.LICENSE.txt → 2562.js.LICENSE.txt} +0 -0
- /package/dist/umd/{8618.js.LICENSE.txt → 5966.js.LICENSE.txt} +0 -0
|
@@ -1,339 +1,2 @@
|
|
|
1
|
-
/*! For license information please see descope-outbound-apps.js.LICENSE.txt */
|
|
2
|
-
"use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[461,2294,4292,4551,5087],{7720:(t,e,o)=>{o.d(e,{T:()=>l,x:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(93895),s=o(72270);const l=(0,i.xE)("list");class d extends((0,s.qu)({componentName:l,baseSelector:".wrapper"})){static get observedAttributes(){return["variant","readonly"]}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <slot></slot>\n <slot name="empty-state">\n No item...\n </slot>\n </div>\n\t',(0,i.fz)('\n .wrapper {\n overflow: auto;\n display: grid;\n max-height: 100%;\n width: 100%;\n }\n\n :host {\n display: inline-flex;\n width: 100%;\n }\n slot[name="empty-state"] {\n justify-content: center;\n align-items: center;\n display: flex;\n flex-grow: 1;\n }\n\n :host slot[name="empty-state"] {\n display: none;\n }\n :host([empty]) slot[name="empty-state"] {\n display: flex;\n }\n ::slotted(:not([slot])) {\n width: 100%;\n }\n ',this)}get items(){return this.shadowRoot.querySelector("slot").assignedElements()}#t(){0===this.items.length?this.setAttribute("empty","true"):this.removeAttribute("empty")}get variant(){return this.getAttribute("variant")||"list"}#e(){this.items.forEach(t=>{let e=t;e.localName!==a.O.componentName&&(e=t.querySelector(a.O.componentName));const o="tiles"===this.variant?"tile":"row";e?.setAttribute("variant",o)})}init(){super.init?.(),(0,i.Ge)(this,()=>{this.#t(),this.#e(),this.#o()})}get isReadOnly(){return"true"===this.getAttribute("readonly")}#o(){this.items.forEach(t=>{this.isReadOnly?t.setAttribute("inert",""):t.removeAttribute("inert")})}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),o!==e&&("variant"===t?this.#e():"readonly"===t&&this.#o())}}const c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},maxHeight:{selector:()=>":host"},minHeight:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],hostDirection:{selector:()=>":host",property:"direction"},fontFamily:{},gap:{},backgroundColor:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},boxShadow:{},gridTemplateColumns:{},maxItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"max-width"},minItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"min-width"},maxRowItems:{property:"max-row-items"},itemsHorizontalAlign:{selector:()=>"::slotted(*)",property:"justify-self"},emptyStateTextColor:{selector:()=>'slot[name="empty-state"]',property:"color"},emptyStateTextFontFamily:{selector:()=>'slot[name="empty-state"]',property:"font-family"}}}),n.VO,n.tQ)(d)},8512:(t,e,o)=>{o.d(e,{T:()=>l,q:()=>p});var n=o(88961),r=o(72270),i=o(63200),a=o(25964),s=o(18782);const l=(0,a.xE)("image"),d=["src","src-dark"];class c extends((0,r.qu)({componentName:l,baseSelector:"slot"})){static get observedAttributes(){return d}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<slot></slot>\n\t",(0,a.fz)("\n\t\t\t:host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t}\n :host > slot {\n width: 100%;\n height: 100%;\n\t\t\t\tbox-sizing: border-box;\n\t\t\t\tdisplay: flex;\n\t\t\t\toverflow: hidden;\n\t\t\t}\n\n ::slotted(*) {\n width: 100%;\n\t\t\t}\n\n .hidden {\n display: none;\n }\n ",this)}init(){super.init?.(),this.toggleVisibility(this.getSrc)}onThemeChange(){this.renderImage()}toggleVisibility(t){t?this.classList.remove("hidden"):this.classList.add("hidden")}get altText(){return this.getAttribute("alt")||""}get legacySrc(){return this.getAttribute("src")}get themeSrc(){return this.getAttribute(`src-${this.currentThemeName}`)}get getSrc(){return this.themeSrc||this.legacySrc}updateFillColor(t){[t,...t.querySelectorAll("*[fill]")].forEach(t=>{t.setAttribute("fill",`var(${p.cssVarList.fill}, ${t.getAttribute("fill")||"''"})`)})}renderImage(){this.toggleVisibility(this.getSrc),(0,s.m)(this.getSrc,this.altText).then(t=>{this.innerHTML="",t&&(this.updateFillColor(t),this.appendChild(t))})}shouldRender(t){const e=this.getAttribute(t);return this.getSrc===e}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),e!==o&&this.shouldRender(t)&&this.renderImage()}}const p=(0,i.Zz)((0,n.RF)({mappings:{fill:{},height:{selector:()=>":host"},width:{selector:()=>":host"}}}),n.VO,n.tQ)(c)},10767:(t,e,o)=>{o.d(e,{G:()=>n});const n=t=>class extends t{get isLoading(){return"true"===this.getAttribute("loading")}click(){this.isLoading||super.click()}}},18782:(t,e,o)=>{o.d(e,{m:()=>i});var n=o(25414);const r=t=>{const e=n.A.sanitize(t,{USE_PROFILES:{svg:!0,svgFilters:!0},ADD_TAGS:["image"],FORBID_TAGS:["defs"]});return(new DOMParser).parseFromString(e,"image/svg+xml").querySelector("svg")},i=async(t,e)=>{try{let o;if((t=>t.startsWith("data:image/svg+xml;base64,"))(t)){const e=atob(t.slice(26));o=r(e)}else if("svg"===(t=>{const e=t.match(/\.([0-9a-z]+)(?:[\\?#]|$)/i);return e?e[1]:null})(t)){const e=await fetch(t),n=await e.text();o=r(n)}else o=((t,e)=>{const o=document.createElement("img");return o.setAttribute("src",t),o.setAttribute("alt",e),o})(t,e);return o.style.setProperty("max-width","100%"),o.style.setProperty("max-height","100%"),o}catch{return null}}},19624:(t,e,o)=>{o.d(e,{J:()=>m,T:()=>l});var n=o(63200),r=o(25964),i=o(88961),a=o(98538),s=o(10767);const l=(0,r.xE)("button"),{host:d,label:c,slottedIcon:p}={host:{selector:()=>":host"},label:{selector:"::part(label)"},slottedIcon:{selector:()=>"::slotted(descope-icon)"}};let h;const m=(0,n.Zz)((0,i.RF)({mappings:{hostWidth:{property:"width"},hostHeight:{property:"height"},hostDirection:{...d,property:"direction"},fontSize:{},fontFamily:{},cursor:{},backgroundColor:{},outlineOffset:{},outlineColor:{},outlineStyle:{},outlineWidth:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-right",fallback:"0.875em"},{property:"padding-left",fallback:"0.875em"}],labelTextColor:{property:"color"},iconColor:{selector:()=>"::slotted(*)",property:a.S.cssVarList.fill},labelTextDecoration:{...c,property:"text-decoration"},labelSpacing:{...c,property:"gap"},textAlign:{...c,property:"justify-content",fallback:"center"},iconSize:[{...p,property:"width"},{...p,property:"height"}]}}),s.G,i.VO,i.tQ)((0,i.tz)({slots:["","prefix","label","suffix"],wrappedEleName:"vaadin-button",style:()=>`\n\t\t\t\n\t:host {\n\t\tdisplay: inline-block;\n\t\tbox-sizing: border-box;\n\t}\n\tvaadin-button::before,\n\tvaadin-button::after {\n\t\topacity: 0;\n\t}\n\tvaadin-button {\n\t\tmargin: 0;\n\t\tmin-width: 0;\n\t\twidth: 100%;\n\t\theight: auto;\n\t\tbox-shadow: none;\n\t}\n\tvaadin-button::part(label) {\n\t\tpadding: 0;\n width: 100%;\n\t}\n\tvaadin-button::part(prefix) {\n\t\tmargin-left: 0;\n\t\tmargin-right: 0;\n\t}\n\n\t\t\t\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n\n\t\t\t${h}\n\t\t\tvaadin-button::part(label) { pointer-events: none; }\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${m.cssVarList.outlineWidth}) + var(${m.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width="true"]) {\n width: var(${m.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${m.cssVarList.hostHeight}) - var(${m.cssVarList.outlineWidth}) - var(${m.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square="true"]:not([full-width="true"]) {\n\t\t\t\twidth: calc(var(${m.cssVarList.hostWidth}) - var(${m.cssVarList.outlineWidth}) - var(${m.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,excludeAttrsSync:["tabindex","class","style"],componentName:l})),{color:u,fontSize:b}=m.cssVarList;h=`\n\t@keyframes spin {\n\t\t0% { -webkit-transform: rotate(0deg); }\n\t\t100% { -webkit-transform: rotate(360deg); }\n\t}\n\t:host([loading="true"]) ::before {\n\t\tanimation: spin 2s linear infinite;\n\t\tposition: absolute;\n\t\tcontent: '';\n\t\tz-index: 1;\n\t\tbox-sizing: border-box;\n\t\tborder-radius: 50%;\n\t\tborder-bottom-color: transparent;\n\t\tborder-left-color: transparent;\n\t\tborder-style: solid;\n\t\tcolor: var(${u});\n\t\ttop: calc(50% - (var(${b}) / 2));\n\t\tleft: calc(50% - (var(${b}) / 2));\n\t\tborder-width: calc(var(${b}) / 10);\n\t\twidth: var(${b});\n\t\theight: var(${b});\n\t}\n\t:host([disabled="true"]),\n\t:host([loading="true"]) {\n\t\tpointer-events: none;\n\t}\n\t:host([loading="true"]) ::part(prefix),\n\t:host([loading="true"]) ::part(label) {\n\t\tvisibility: hidden;\n\t}\n`},24542:(t,e,o)=>{o.r(e),o.d(e,{ListItemClass:()=>n.O,componentName:()=>n.T});var n=o(93895);customElements.define(n.T,n.O)},30576:(t,e,o)=>{o.r(e),o.d(e,{ButtonClass:()=>n.J,componentName:()=>n.T});var n=o(19624);o(83799),customElements.define(n.T,n.J)},45400:(t,e,o)=>{o.r(e),o.d(e,{ListClass:()=>n.x,componentName:()=>n.T}),o(24542);var n=o(7720);customElements.define(n.T,n.x)},53557:(t,e,o)=>{o.r(e),o.d(e,{AvatarClass:()=>h,componentName:()=>s});var n=o(88961),r=o(72270),i=o(63200),a=o(25964);const s=(0,a.xE)("avatar");class l extends((0,r.qu)({componentName:s,baseSelector:":host > .wrapper"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <vaadin-avatar></vaadin-avatar>\n <div class="editableBadge">\n <vaadin-icon icon="vaadin:pencil"></vaadin-icon>\n </div>\n </div>\n\t\t',(0,a.fz)("\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n ",this),this.avatarComponent=this.shadowRoot.querySelector("vaadin-avatar"),(0,a.EA)(this,this.avatarComponent,{includeAttrs:["display-name","img","abbr"],mapAttrs:{"display-name":"name"}});const t=this.shadowRoot.querySelector(".editableBadge");(0,a.mx)(this,()=>{t.style.display=this.isEditable?"":"none"},{includeAttrs:["editable"]})}get isEditable(){return"true"===this.getAttribute("editable")}}const{host:d,editableBadge:c,avatar:p}={host:{selector:()=>":host"},editableBadge:{selector:"> .editableBadge"},avatar:{selector:"vaadin-avatar"}},h=(0,i.Zz)((0,n.RF)({mappings:{hostWidth:[{...d,property:"width"},{...d,property:"min-width"}],hostHeight:{...d,property:"height"},cursor:[p,d],hostDirection:{...d,property:"direction"},avatarTextColor:{...p,property:"color"},avatarBackgroundColor:{...p,property:"background-color"},editableIconColor:{...c,property:"color"},editableBorderColor:{...c,property:"border-color"},editableBackgroundColor:{...c,property:"background-color"}}}),n.VO,n.tQ)(l);o(4408),o(95260),o(37182),customElements.define(s,h)},58204:(t,e,o)=>{o.r(e),o.d(e,{OutboundAppsClass:()=>b,componentName:()=>p}),o(45400),o(24542),o(63595),o(53557),o(30576);var n=o(63200),r=o(25964),i=o(88961),a=o(72270),s=o(98538),l=o(66434),d=o(7720),c=o(93895);const p=(0,r.xE)("outbound-apps"),h=({name:t,description:e,logo:o,appId:n,isConnected:i},a,s)=>{const l=i?"disconnect":"connect";return`\n <descope-list-item>\n <descope-avatar\n ${o?`img="${o}"`:""}\n ${t?`display-name="${t}" abbr=${(0,r.ie)(t)}`:""}\n size=${s.size}\n ${o?'st-avatar-background-color="none"':""}\n class="app-logo"\n ></descope-avatar>\n\n <div class="content">\n <descope-text\n class="app-title"\n variant="subtitle1"\n mode="primary"\n >${t}</descope-text>\n ${e?`\n <descope-text\n class="app-description"\n variant="body2"\n mode="primary"\n >${e}</descope-text>\n `:""}\n </div>\n <div class="controls">\n <descope-button variant="link" mode="primary" size=${s.size} data-action="${l}" data-outbound-app-id="${n}" data-id="${l}">\n ${i?s.disconnectButtonLabel:s.connectButtonLabel}\n </descope-button>\n </div>\n </descope-list-item>\n`},m=(0,a.qu)({componentName:p,baseSelector:"descope-list"}),{host:u}={host:{selector:()=>":host"}},b=(0,n.Zz)((0,i.RF)({mappings:{hostWidth:{...u,property:"width"},minHeight:{selector:()=>":host"},hostDirection:[{...u,property:"direction"},{selector:"descope-list",property:"direction"},{selector:"descope-list-item",property:"direction"}],iconColor:{selector:()=>" descope-icon",property:s.S.cssVarList.fill},errorIconColor:{selector:()=>" descope-icon.error-icon",property:s.S.cssVarList.fill},fontSize:{selector:l.s.componentName,property:l.s.cssVarList.fontSize},appLogoGap:{selector:()=>" .app-logo",property:"margin-inline-end"},contentGap:{selector:()=>" .content",property:"gap"},itemsTextAlign:{selector:l.s.componentName,property:l.s.cssVarList.textAlign},itemCursor:{selector:c.O.componentName,property:c.O.cssVarList.cursor},itemOutline:{selector:c.O.componentName,property:c.O.cssVarList.outline},itemBorderColor:{selector:c.O.componentName,property:c.O.cssVarList.borderColor},itemBackgroundColor:{selector:c.O.componentName,property:c.O.cssVarList.backgroundColor},listBorderWidth:{selector:()=>d.x.componentName,property:d.x.cssVarList.borderWidth},listBoxShadow:{selector:()=>d.x.componentName,property:d.x.cssVarList.boxShadow},listPadding:[{selector:()=>d.x.componentName,property:d.x.cssVarList.verticalPadding},{selector:()=>d.x.componentName,property:d.x.cssVarList.horizontalPadding}]}}),i.VO,(0,i.t$)({itemRenderer:h,rerenderAttrsList:["size","connect-button-label","disconnect-button-label"]}),i.tQ)(class extends m{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <descope-list>\n <slot name="empty-state" slot="empty-state"></slot>\n </descope-list>\n ',this.appsList=this.shadowRoot.querySelector("descope-list"),(0,r.fz)("\n :host {\n width: 100%;\n }\n .controls {\n display: flex;\n min-width: 8em;\n justify-content: end;\n }\n .content {\n flex-grow: 1;\n display: flex;\n flex-direction: column;\n }\n .app-title,\n .app-description {\n display: flex;\n direction: inherit;\n }\n descope-list {\n display: block;\n }\n ",this)}init(){super.init?.(),this.appsList.itemRenderer=h,this.appsList.addEventListener("click",this.onAppsListClick.bind(this))}get readonly(){return"true"===this.getAttribute("readonly")}onAppsListClick(t){if(!this.readonly){const e=t.srcElement.getAttribute("data-outbound-app-id"),o=t.srcElement.getAttribute("data-action");e&&o&&this.dispatchEvent(new CustomEvent(`${o}-clicked`,{bubbles:!0,detail:{id:e,action:o}}))}}get size(){return this.getAttribute("size")||"sm"}get connectButtonLabel(){return this.getAttribute("connect-button-label")||"Connect"}get disconnectButtonLabel(){return this.getAttribute("disconnect-button-label")||"Disconnect"}});customElements.define(p,b)},63595:(t,e,o)=>{o.r(e),o.d(e,{TextClass:()=>n.s,componentName:()=>n.T});var n=o(66434);customElements.define(n.T,n.s)},66434:(t,e,o)=>{o.d(e,{T:()=>s,s:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("text");class l extends((0,a.qu)({componentName:s,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,i.fz)("\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n ",this)}get hideWhenEmpty(){return"true"===this.getAttribute("hide-when-empty")}init(){super.init(),(0,i.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:d}={host:{selector:()=>":host"}},c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{...d,property:"width"},hostDirection:{...d,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),n.VO,n.tQ)(l)},83799:(t,e,o)=>{o(93555),o(89389)},89389:(t,e,o)=>{o.d(e,{$:()=>u});var n=o(13256),r=o(55774),i=o(82901),a=o(90676),s=o(81488),l=o(87550);const d=o(51450).AH`
|
|
3
|
-
:host {
|
|
4
|
-
display: inline-block;
|
|
5
|
-
position: relative;
|
|
6
|
-
outline: none;
|
|
7
|
-
white-space: nowrap;
|
|
8
|
-
-webkit-user-select: none;
|
|
9
|
-
-moz-user-select: none;
|
|
10
|
-
user-select: none;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
:host([hidden]) {
|
|
14
|
-
display: none !important;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/* Aligns the button with form fields when placed on the same line.
|
|
18
|
-
Note, to make it work, the form fields should have the same "::before" pseudo-element. */
|
|
19
|
-
.vaadin-button-container::before {
|
|
20
|
-
content: '\\2003';
|
|
21
|
-
display: inline-block;
|
|
22
|
-
width: 0;
|
|
23
|
-
max-height: 100%;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.vaadin-button-container {
|
|
27
|
-
display: inline-flex;
|
|
28
|
-
align-items: center;
|
|
29
|
-
justify-content: center;
|
|
30
|
-
text-align: center;
|
|
31
|
-
width: 100%;
|
|
32
|
-
height: 100%;
|
|
33
|
-
min-height: inherit;
|
|
34
|
-
text-shadow: inherit;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
[part='prefix'],
|
|
38
|
-
[part='suffix'] {
|
|
39
|
-
flex: none;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
[part='label'] {
|
|
43
|
-
white-space: nowrap;
|
|
44
|
-
overflow: hidden;
|
|
45
|
-
text-overflow: ellipsis;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
@media (forced-colors: active) {
|
|
49
|
-
:host {
|
|
50
|
-
outline: 1px solid;
|
|
51
|
-
outline-offset: -1px;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
:host([focused]) {
|
|
55
|
-
outline-width: 2px;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
:host([disabled]) {
|
|
59
|
-
outline-color: GrayText;
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
`;var c=o(84467),p=o(53149),h=o(36176);const m=t=>class extends((0,c.e)((0,h.l)((0,p.y)(t)))){static get properties(){return{tabindex:{type:Number,value:0,reflectToAttribute:!0}}}get _activeKeys(){return["Enter"," "]}ready(){super.ready(),this.hasAttribute("role")||this.setAttribute("role","button")}_onKeyDown(t){super._onKeyDown(t),t.altKey||t.shiftKey||t.ctrlKey||t.metaKey||this._activeKeys.includes(t.key)&&(t.preventDefault(),this.click())}};(0,l.SF)("vaadin-button",d,{moduleId:"vaadin-button-styles"});class u extends(m((0,a.q)((0,l.cp)((0,r.w)(n.Pu))))){static get is(){return"vaadin-button"}static get template(){return n.qy`
|
|
63
|
-
<div class="vaadin-button-container">
|
|
64
|
-
<span part="prefix" aria-hidden="true">
|
|
65
|
-
<slot name="prefix"></slot>
|
|
66
|
-
</span>
|
|
67
|
-
<span part="label">
|
|
68
|
-
<slot></slot>
|
|
69
|
-
</span>
|
|
70
|
-
<span part="suffix" aria-hidden="true">
|
|
71
|
-
<slot name="suffix"></slot>
|
|
72
|
-
</span>
|
|
73
|
-
</div>
|
|
74
|
-
<slot name="tooltip"></slot>
|
|
75
|
-
`}ready(){super.ready(),this._tooltipController=new s.I(this),this.addController(this._tooltipController)}}(0,i.X)(u)},93555:(t,e,o)=>{o.d(e,{x:()=>r}),o(64511),o(42068),o(9433),o(3241),o(83315);var n=o(87550);const r=n.AH`
|
|
76
|
-
:host {
|
|
77
|
-
/* Sizing */
|
|
78
|
-
--lumo-button-size: var(--lumo-size-m);
|
|
79
|
-
min-width: var(--vaadin-button-min-width, calc(var(--_button-size) * 2));
|
|
80
|
-
height: var(--_button-size);
|
|
81
|
-
padding: var(--vaadin-button-padding, 0 calc(var(--_button-size) / 3 + var(--lumo-border-radius-m) / 2));
|
|
82
|
-
margin: var(--vaadin-button-margin, var(--lumo-space-xs) 0);
|
|
83
|
-
box-sizing: border-box;
|
|
84
|
-
/* Style */
|
|
85
|
-
font-family: var(--lumo-font-family);
|
|
86
|
-
font-size: var(--vaadin-button-font-size, var(--lumo-font-size-m));
|
|
87
|
-
font-weight: var(--vaadin-button-font-weight, 500);
|
|
88
|
-
color: var(--_lumo-button-text-color);
|
|
89
|
-
background: var(--_lumo-button-background);
|
|
90
|
-
border: var(--vaadin-button-border, none);
|
|
91
|
-
border-radius: var(--vaadin-button-border-radius, var(--lumo-border-radius-m));
|
|
92
|
-
cursor: var(--lumo-clickable-cursor);
|
|
93
|
-
-webkit-tap-highlight-color: transparent;
|
|
94
|
-
-webkit-font-smoothing: antialiased;
|
|
95
|
-
-moz-osx-font-smoothing: grayscale;
|
|
96
|
-
flex-shrink: 0;
|
|
97
|
-
--_button-size: var(--vaadin-button-height, var(--lumo-button-size));
|
|
98
|
-
--_focus-ring-color: var(--vaadin-focus-ring-color, var(--lumo-primary-color-50pct));
|
|
99
|
-
--_focus-ring-width: var(--vaadin-focus-ring-width, 2px);
|
|
100
|
-
/* Used by notification */
|
|
101
|
-
--_lumo-button-background: var(--vaadin-button-background, var(--lumo-contrast-5pct));
|
|
102
|
-
--_lumo-button-text-color: var(--vaadin-button-text-color, var(--lumo-primary-text-color));
|
|
103
|
-
--_lumo-button-primary-background: var(--vaadin-button-primary-background, var(--lumo-primary-color));
|
|
104
|
-
--_lumo-button-primary-text-color: var(--vaadin-button-primary-text-color, var(--lumo-primary-contrast-color));
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
/* Set only for the internal parts so we don't affect the host vertical alignment */
|
|
108
|
-
[part='label'],
|
|
109
|
-
[part='prefix'],
|
|
110
|
-
[part='suffix'] {
|
|
111
|
-
line-height: var(--lumo-line-height-xs);
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
[part='label'] {
|
|
115
|
-
padding: calc(var(--lumo-button-size) / 6) 0;
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
:host([theme~='small']) {
|
|
119
|
-
font-size: var(--lumo-font-size-s);
|
|
120
|
-
--lumo-button-size: var(--lumo-size-s);
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
:host([theme~='large']) {
|
|
124
|
-
font-size: var(--lumo-font-size-l);
|
|
125
|
-
--lumo-button-size: var(--lumo-size-l);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
/* For interaction states */
|
|
129
|
-
:host::before,
|
|
130
|
-
:host::after {
|
|
131
|
-
content: '';
|
|
132
|
-
/* We rely on the host always being relative */
|
|
133
|
-
position: absolute;
|
|
134
|
-
z-index: 1;
|
|
135
|
-
inset: 0;
|
|
136
|
-
background-color: currentColor;
|
|
137
|
-
border-radius: inherit;
|
|
138
|
-
opacity: 0;
|
|
139
|
-
pointer-events: none;
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
/* Hover */
|
|
143
|
-
|
|
144
|
-
@media (any-hover: hover) {
|
|
145
|
-
:host(:hover)::before {
|
|
146
|
-
opacity: 0.02;
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
/* Active */
|
|
151
|
-
|
|
152
|
-
:host::after {
|
|
153
|
-
transition: opacity 1.4s, transform 0.1s;
|
|
154
|
-
filter: blur(8px);
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
:host([active])::before {
|
|
158
|
-
opacity: 0.05;
|
|
159
|
-
transition-duration: 0s;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
:host([active])::after {
|
|
163
|
-
opacity: 0.1;
|
|
164
|
-
transition-duration: 0s, 0s;
|
|
165
|
-
transform: scale(0);
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
/* Keyboard focus */
|
|
169
|
-
|
|
170
|
-
:host([focus-ring]) {
|
|
171
|
-
box-shadow: 0 0 0 var(--_focus-ring-width) var(--_focus-ring-color);
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
:host([theme~='primary'][focus-ring]) {
|
|
175
|
-
box-shadow: 0 0 0 1px var(--lumo-base-color), 0 0 0 3px var(--lumo-primary-color-50pct);
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
/* Types (primary, tertiary, tertiary-inline */
|
|
179
|
-
|
|
180
|
-
:host([theme~='tertiary']),
|
|
181
|
-
:host([theme~='tertiary-inline']) {
|
|
182
|
-
--_background: transparent !important;
|
|
183
|
-
background: var(--vaadin-button-tertiary-background, var(--_background));
|
|
184
|
-
min-width: 0;
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
:host([theme~='tertiary']) {
|
|
188
|
-
border: var(--vaadin-button-tertiary-border, none);
|
|
189
|
-
color: var(--vaadin-button-tertiary-text-color, var(--lumo-primary-text-color));
|
|
190
|
-
font-weight: var(--vaadin-button-tertiary-font-weight, 500);
|
|
191
|
-
padding: var(--vaadin-button-tertiary-padding, 0 calc(var(--_button-size) / 6));
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
:host([theme~='tertiary-inline'])::before {
|
|
195
|
-
display: none;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
:host([theme~='tertiary-inline']) {
|
|
199
|
-
margin: 0;
|
|
200
|
-
height: auto;
|
|
201
|
-
padding: 0;
|
|
202
|
-
line-height: inherit;
|
|
203
|
-
font-size: inherit;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
:host([theme~='tertiary-inline']) [part='label'] {
|
|
207
|
-
padding: 0;
|
|
208
|
-
overflow: visible;
|
|
209
|
-
line-height: inherit;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
:host([theme~='primary']) {
|
|
213
|
-
background: var(--_lumo-button-primary-background);
|
|
214
|
-
border: var(--vaadin-button-primary-border, none);
|
|
215
|
-
color: var(--_lumo-button-primary-text-color);
|
|
216
|
-
font-weight: var(--vaadin-button-primary-font-weight, 600);
|
|
217
|
-
min-width: calc(var(--lumo-button-size) * 2.5);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
:host([theme~='primary'])::before {
|
|
221
|
-
background-color: black;
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
@media (any-hover: hover) {
|
|
225
|
-
:host([theme~='primary']:hover)::before {
|
|
226
|
-
opacity: 0.05;
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
:host([theme~='primary'][active])::before {
|
|
231
|
-
opacity: 0.1;
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
:host([theme~='primary'][active])::after {
|
|
235
|
-
opacity: 0.2;
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
/* Colors (success, error, contrast) */
|
|
239
|
-
|
|
240
|
-
:host([theme~='success']) {
|
|
241
|
-
color: var(--lumo-success-text-color);
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
:host([theme~='success'][theme~='primary']) {
|
|
245
|
-
background-color: var(--lumo-success-color);
|
|
246
|
-
color: var(--lumo-success-contrast-color);
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
:host([theme~='error']) {
|
|
250
|
-
color: var(--lumo-error-text-color);
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
:host([theme~='error'][theme~='primary']) {
|
|
254
|
-
background-color: var(--lumo-error-color);
|
|
255
|
-
color: var(--lumo-error-contrast-color);
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
:host([theme~='contrast']) {
|
|
259
|
-
color: var(--lumo-contrast);
|
|
260
|
-
}
|
|
261
|
-
|
|
262
|
-
:host([theme~='contrast'][theme~='primary']) {
|
|
263
|
-
background-color: var(--lumo-contrast);
|
|
264
|
-
color: var(--lumo-base-color);
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
/* Disabled state. Keep selectors after other color variants. */
|
|
268
|
-
|
|
269
|
-
:host([disabled]) {
|
|
270
|
-
pointer-events: none;
|
|
271
|
-
color: var(--lumo-disabled-text-color);
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
:host([theme~='primary'][disabled]) {
|
|
275
|
-
background-color: var(--lumo-contrast-30pct);
|
|
276
|
-
color: var(--lumo-base-color);
|
|
277
|
-
}
|
|
278
|
-
|
|
279
|
-
:host([theme~='primary'][disabled]) [part] {
|
|
280
|
-
opacity: 0.7;
|
|
281
|
-
}
|
|
282
|
-
|
|
283
|
-
/* Icons */
|
|
284
|
-
|
|
285
|
-
[part] ::slotted(vaadin-icon) {
|
|
286
|
-
display: inline-block;
|
|
287
|
-
width: var(--lumo-icon-size-m);
|
|
288
|
-
height: var(--lumo-icon-size-m);
|
|
289
|
-
}
|
|
290
|
-
|
|
291
|
-
/* Vaadin icons are based on a 16x16 grid (unlike Lumo and Material icons with 24x24), so they look too big by default */
|
|
292
|
-
[part] ::slotted(vaadin-icon[icon^='vaadin:']) {
|
|
293
|
-
padding: 0.25em;
|
|
294
|
-
box-sizing: border-box !important;
|
|
295
|
-
}
|
|
296
|
-
|
|
297
|
-
[part='prefix'] {
|
|
298
|
-
margin-left: -0.25em;
|
|
299
|
-
margin-right: 0.25em;
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
[part='suffix'] {
|
|
303
|
-
margin-left: 0.25em;
|
|
304
|
-
margin-right: -0.25em;
|
|
305
|
-
}
|
|
306
|
-
|
|
307
|
-
/* Icon-only */
|
|
308
|
-
|
|
309
|
-
:host([theme~='icon']:not([theme~='tertiary-inline'])) {
|
|
310
|
-
min-width: var(--lumo-button-size);
|
|
311
|
-
padding-left: calc(var(--lumo-button-size) / 4);
|
|
312
|
-
padding-right: calc(var(--lumo-button-size) / 4);
|
|
313
|
-
}
|
|
314
|
-
|
|
315
|
-
:host([theme~='icon']) [part='prefix'],
|
|
316
|
-
:host([theme~='icon']) [part='suffix'] {
|
|
317
|
-
margin-left: 0;
|
|
318
|
-
margin-right: 0;
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
/* RTL specific styles */
|
|
322
|
-
|
|
323
|
-
:host([dir='rtl']) [part='prefix'] {
|
|
324
|
-
margin-left: 0.25em;
|
|
325
|
-
margin-right: -0.25em;
|
|
326
|
-
}
|
|
327
|
-
|
|
328
|
-
:host([dir='rtl']) [part='suffix'] {
|
|
329
|
-
margin-left: -0.25em;
|
|
330
|
-
margin-right: 0.25em;
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
:host([dir='rtl'][theme~='icon']) [part='prefix'],
|
|
334
|
-
:host([dir='rtl'][theme~='icon']) [part='suffix'] {
|
|
335
|
-
margin-left: 0;
|
|
336
|
-
margin-right: 0;
|
|
337
|
-
}
|
|
338
|
-
`;(0,n.SF)("vaadin-button",r,{moduleId:"lumo-button"})},93895:(t,e,o)=>{o.d(e,{O:()=>l,T:()=>s});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("list-item"),l=(0,r.Zz)((0,n.RF)({mappings:{verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],backgroundColor:{},borderColor:{},borderStyle:{},borderWidth:{},borderRadius:{},outline:{},cursor:{},gap:{},maxWidth:{selector:()=>":host"},alignItems:{},flexDirection:{},transition:{}}}),n.VO,n.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,i.fz)("\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n ",this)}},n.y)((0,a.qu)({componentName:s,baseSelector:"slot"}))},98538:(t,e,o)=>{o.d(e,{S:()=>l,T:()=>s});var n=o(88961),r=o(25964),i=o(8512),a=o(63200);const s=(0,r.xE)("icon"),l=(0,a.Zz)((0,n.RF)({mappings:{fill:[{},{property:i.q.cssVarList.fill}]}}),n.VO,n.tQ)((0,n.tz)({slots:[],wrappedEleName:"descope-image",style:()=>"\n :host {\n display: inline-flex;\n }\n ",excludeAttrsSync:["tabindex","class","style"],componentName:s}))}}]);
|
|
1
|
+
"use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[461,2294,4292,4551],{7720:(t,e,n)=>{n.d(e,{T:()=>l,x:()=>c});var o=n(88961),r=n(63200),i=n(25964),s=n(93895),a=n(72270);const l=(0,i.xE)("list");class d extends((0,a.qu)({componentName:l,baseSelector:".wrapper"})){static get observedAttributes(){return["variant","readonly"]}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <slot></slot>\n <slot name="empty-state">\n No item...\n </slot>\n </div>\n\t',(0,i.fz)('\n .wrapper {\n overflow: auto;\n display: grid;\n max-height: 100%;\n width: 100%;\n }\n\n :host {\n display: inline-flex;\n width: 100%;\n }\n slot[name="empty-state"] {\n justify-content: center;\n align-items: center;\n display: flex;\n flex-grow: 1;\n }\n\n :host slot[name="empty-state"] {\n display: none;\n }\n :host([empty]) slot[name="empty-state"] {\n display: flex;\n }\n ::slotted(:not([slot])) {\n width: 100%;\n }\n ',this)}get items(){return this.shadowRoot.querySelector("slot").assignedElements()}#t(){0===this.items.length?this.setAttribute("empty","true"):this.removeAttribute("empty")}get variant(){return this.getAttribute("variant")||"list"}#e(){this.items.forEach(t=>{let e=t;e.localName!==s.O.componentName&&(e=t.querySelector(s.O.componentName));const n="tiles"===this.variant?"tile":"row";e?.setAttribute("variant",n)})}init(){super.init?.(),(0,i.Ge)(this,()=>{this.#t(),this.#e(),this.#n()})}get isReadOnly(){return"true"===this.getAttribute("readonly")}#n(){this.items.forEach(t=>{this.isReadOnly?t.setAttribute("inert",""):t.removeAttribute("inert")})}attributeChangedCallback(t,e,n){super.attributeChangedCallback?.(t,e,n),n!==e&&("variant"===t?this.#e():"readonly"===t&&this.#n())}}const c=(0,r.Zz)((0,o.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},maxHeight:{selector:()=>":host"},minHeight:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],hostDirection:{selector:()=>":host",property:"direction"},fontFamily:{},gap:{},backgroundColor:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},boxShadow:{},gridTemplateColumns:{},maxItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"max-width"},minItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"min-width"},maxRowItems:{property:"max-row-items"},itemsHorizontalAlign:{selector:()=>"::slotted(*)",property:"justify-self"},emptyStateTextColor:{selector:()=>'slot[name="empty-state"]',property:"color"},emptyStateTextFontFamily:{selector:()=>'slot[name="empty-state"]',property:"font-family"}}}),o.VO,o.tQ)(d)},8512:(t,e,n)=>{n.d(e,{T:()=>l,q:()=>p});var o=n(88961),r=n(72270),i=n(63200),s=n(25964),a=n(18782);const l=(0,s.xE)("image"),d=["src","src-dark"];class c extends((0,r.qu)({componentName:l,baseSelector:"slot"})){static get observedAttributes(){return d}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<slot></slot>\n\t",(0,s.fz)("\n\t\t\t:host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t}\n :host > slot {\n width: 100%;\n height: 100%;\n\t\t\t\tbox-sizing: border-box;\n\t\t\t\tdisplay: flex;\n\t\t\t\toverflow: hidden;\n\t\t\t}\n\n ::slotted(*) {\n width: 100%;\n\t\t\t}\n\n .hidden {\n display: none;\n }\n ",this)}init(){super.init?.(),this.toggleVisibility(this.getSrc)}onThemeChange(){this.renderImage()}toggleVisibility(t){t?this.classList.remove("hidden"):this.classList.add("hidden")}get altText(){return this.getAttribute("alt")||""}get legacySrc(){return this.getAttribute("src")}get themeSrc(){return this.getAttribute(`src-${this.currentThemeName}`)}get getSrc(){return this.themeSrc||this.legacySrc}updateFillColor(t){[t,...t.querySelectorAll("*[fill]")].forEach(t=>{t.setAttribute("fill",`var(${p.cssVarList.fill}, ${t.getAttribute("fill")||"''"})`)})}renderImage(){this.toggleVisibility(this.getSrc),(0,a.m)(this.getSrc,this.altText).then(t=>{this.innerHTML="",t&&(this.updateFillColor(t),this.appendChild(t))})}shouldRender(t){const e=this.getAttribute(t);return this.getSrc===e}attributeChangedCallback(t,e,n){super.attributeChangedCallback?.(t,e,n),e!==n&&this.shouldRender(t)&&this.renderImage()}}const p=(0,i.Zz)((0,o.RF)({mappings:{fill:{},height:{selector:()=>":host"},width:{selector:()=>":host"}}}),o.VO,o.tQ)(c)},10767:(t,e,n)=>{n.d(e,{G:()=>o});const o=t=>class extends t{get isLoading(){return"true"===this.getAttribute("loading")}click(){this.isLoading||super.click()}}},18782:(t,e,n)=>{n.d(e,{m:()=>i});var o=n(25414);const r=t=>{const e=o.A.sanitize(t,{USE_PROFILES:{svg:!0,svgFilters:!0},ADD_TAGS:["image"],FORBID_TAGS:["defs"]});return(new DOMParser).parseFromString(e,"image/svg+xml").querySelector("svg")},i=async(t,e)=>{try{let n;if((t=>t.startsWith("data:image/svg+xml;base64,"))(t)){const e=atob(t.slice(26));n=r(e)}else if("svg"===(t=>{const e=t.match(/\.([0-9a-z]+)(?:[\\?#]|$)/i);return e?e[1]:null})(t)){const e=await fetch(t),o=await e.text();n=r(o)}else n=((t,e)=>{const n=document.createElement("img");return n.setAttribute("src",t),n.setAttribute("alt",e),n})(t,e);return n.style.setProperty("max-width","100%"),n.style.setProperty("max-height","100%"),n}catch{return null}}},19624:(t,e,n)=>{n.d(e,{J:()=>m,T:()=>l});var o=n(63200),r=n(25964),i=n(88961),s=n(98538),a=n(10767);const l=(0,r.xE)("button"),{host:d,label:c,slottedIcon:p}={host:{selector:()=>":host"},label:{selector:"::part(label)"},slottedIcon:{selector:()=>"::slotted(descope-icon)"}};let h;const m=(0,o.Zz)((0,i.RF)({mappings:{hostWidth:{property:"width"},hostHeight:{property:"height"},hostDirection:{...d,property:"direction"},fontSize:{},fontFamily:{},cursor:{},backgroundColor:{},outlineOffset:{},outlineColor:{},outlineStyle:{},outlineWidth:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-right",fallback:"0.875em"},{property:"padding-left",fallback:"0.875em"}],labelTextColor:{property:"color"},iconColor:{selector:()=>"::slotted(*)",property:s.S.cssVarList.fill},labelTextDecoration:{...c,property:"text-decoration"},labelSpacing:{...c,property:"gap"},textAlign:{...c,property:"justify-content",fallback:"center"},iconSize:[{...p,property:"width"},{...p,property:"height"}]}}),a.G,i.VO,i.tQ)((0,i.tz)({slots:["","prefix","label","suffix"],wrappedEleName:"vaadin-button",style:()=>`\n\t\t\t\n\t:host {\n\t\tdisplay: inline-block;\n\t\tbox-sizing: border-box;\n\t}\n\tvaadin-button::before,\n\tvaadin-button::after {\n\t\topacity: 0;\n\t}\n\tvaadin-button {\n\t\tmargin: 0;\n\t\tmin-width: 0;\n\t\twidth: 100%;\n\t\theight: auto;\n\t\tbox-shadow: none;\n\t}\n\tvaadin-button::part(label) {\n\t\tpadding: 0;\n width: 100%;\n\t}\n\tvaadin-button::part(prefix) {\n\t\tmargin-left: 0;\n\t\tmargin-right: 0;\n\t}\n\n\t\t\t\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n\n\t\t\t${h}\n\t\t\tvaadin-button::part(label) { pointer-events: none; }\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${m.cssVarList.outlineWidth}) + var(${m.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width="true"]) {\n width: var(${m.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${m.cssVarList.hostHeight}) - var(${m.cssVarList.outlineWidth}) - var(${m.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square="true"]:not([full-width="true"]) {\n\t\t\t\twidth: calc(var(${m.cssVarList.hostWidth}) - var(${m.cssVarList.outlineWidth}) - var(${m.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,excludeAttrsSync:["tabindex","class","style"],componentName:l})),{color:u,fontSize:g}=m.cssVarList;h=`\n\t@keyframes spin {\n\t\t0% { -webkit-transform: rotate(0deg); }\n\t\t100% { -webkit-transform: rotate(360deg); }\n\t}\n\t:host([loading="true"]) ::before {\n\t\tanimation: spin 2s linear infinite;\n\t\tposition: absolute;\n\t\tcontent: '';\n\t\tz-index: 1;\n\t\tbox-sizing: border-box;\n\t\tborder-radius: 50%;\n\t\tborder-bottom-color: transparent;\n\t\tborder-left-color: transparent;\n\t\tborder-style: solid;\n\t\tcolor: var(${u});\n\t\ttop: calc(50% - (var(${g}) / 2));\n\t\tleft: calc(50% - (var(${g}) / 2));\n\t\tborder-width: calc(var(${g}) / 10);\n\t\twidth: var(${g});\n\t\theight: var(${g});\n\t}\n\t:host([disabled="true"]),\n\t:host([loading="true"]) {\n\t\tpointer-events: none;\n\t}\n\t:host([loading="true"]) ::part(prefix),\n\t:host([loading="true"]) ::part(label) {\n\t\tvisibility: hidden;\n\t}\n`},24542:(t,e,n)=>{n.r(e),n.d(e,{ListItemClass:()=>o.O,componentName:()=>o.T});var o=n(93895);customElements.define(o.T,o.O)},30576:(t,e,n)=>{n.r(e),n.d(e,{ButtonClass:()=>o.J,componentName:()=>o.T});var o=n(19624);n(83799),customElements.define(o.T,o.J)},45400:(t,e,n)=>{n.r(e),n.d(e,{ListClass:()=>o.x,componentName:()=>o.T}),n(24542);var o=n(7720);customElements.define(o.T,o.x)},53557:(t,e,n)=>{n.r(e),n.d(e,{AvatarClass:()=>h,componentName:()=>a});var o=n(88961),r=n(72270),i=n(63200),s=n(25964);const a=(0,s.xE)("avatar");class l extends((0,r.qu)({componentName:a,baseSelector:":host > .wrapper"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <vaadin-avatar></vaadin-avatar>\n <div class="editableBadge">\n <vaadin-icon icon="vaadin:pencil"></vaadin-icon>\n </div>\n </div>\n\t\t',(0,s.fz)("\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n ",this),this.avatarComponent=this.shadowRoot.querySelector("vaadin-avatar"),(0,s.EA)(this,this.avatarComponent,{includeAttrs:["display-name","img","abbr"],mapAttrs:{"display-name":"name"}});const t=this.shadowRoot.querySelector(".editableBadge");(0,s.mx)(this,()=>{t.style.display=this.isEditable?"":"none"},{includeAttrs:["editable"]})}get isEditable(){return"true"===this.getAttribute("editable")}}const{host:d,editableBadge:c,avatar:p}={host:{selector:()=>":host"},editableBadge:{selector:"> .editableBadge"},avatar:{selector:"vaadin-avatar"}},h=(0,i.Zz)((0,o.RF)({mappings:{hostWidth:[{...d,property:"width"},{...d,property:"min-width"}],hostHeight:{...d,property:"height"},cursor:[p,d],hostDirection:{...d,property:"direction"},avatarTextColor:{...p,property:"color"},avatarBackgroundColor:{...p,property:"background-color"},editableIconColor:{...c,property:"color"},editableBorderColor:{...c,property:"border-color"},editableBackgroundColor:{...c,property:"background-color"}}}),o.VO,o.tQ)(l);n(87133),n(95260),n(37182),customElements.define(a,h)},58204:(t,e,n)=>{n.r(e),n.d(e,{OutboundAppsClass:()=>g,componentName:()=>p}),n(45400),n(24542),n(63595),n(53557),n(30576);var o=n(63200),r=n(25964),i=n(88961),s=n(72270),a=n(98538),l=n(66434),d=n(7720),c=n(93895);const p=(0,r.xE)("outbound-apps"),h=({name:t,description:e,logo:n,appId:o,isConnected:i},s,a)=>{const l=i?"disconnect":"connect";return`\n <descope-list-item>\n <descope-avatar\n ${n?`img="${n}"`:""}\n ${t?`display-name="${t}" abbr=${(0,r.ie)(t)}`:""}\n size=${a.size}\n ${n?'st-avatar-background-color="none"':""}\n class="app-logo"\n ></descope-avatar>\n\n <div class="content">\n <descope-text\n class="app-title"\n variant="subtitle1"\n mode="primary"\n >${t}</descope-text>\n ${e?`\n <descope-text\n class="app-description"\n variant="body2"\n mode="primary"\n >${e}</descope-text>\n `:""}\n </div>\n <div class="controls">\n <descope-button variant="link" mode="primary" size=${a.size} data-action="${l}" data-outbound-app-id="${o}" data-id="${l}">\n ${i?a.disconnectButtonLabel:a.connectButtonLabel}\n </descope-button>\n </div>\n </descope-list-item>\n`},m=(0,s.qu)({componentName:p,baseSelector:"descope-list"}),{host:u}={host:{selector:()=>":host"}},g=(0,o.Zz)((0,i.RF)({mappings:{hostWidth:{...u,property:"width"},minHeight:{selector:()=>":host"},hostDirection:[{...u,property:"direction"},{selector:"descope-list",property:"direction"},{selector:"descope-list-item",property:"direction"}],iconColor:{selector:()=>" descope-icon",property:a.S.cssVarList.fill},errorIconColor:{selector:()=>" descope-icon.error-icon",property:a.S.cssVarList.fill},fontSize:{selector:l.s.componentName,property:l.s.cssVarList.fontSize},appLogoGap:{selector:()=>" .app-logo",property:"margin-inline-end"},contentGap:{selector:()=>" .content",property:"gap"},itemsTextAlign:{selector:l.s.componentName,property:l.s.cssVarList.textAlign},itemCursor:{selector:c.O.componentName,property:c.O.cssVarList.cursor},itemOutline:{selector:c.O.componentName,property:c.O.cssVarList.outline},itemBorderColor:{selector:c.O.componentName,property:c.O.cssVarList.borderColor},itemBackgroundColor:{selector:c.O.componentName,property:c.O.cssVarList.backgroundColor},listBorderWidth:{selector:()=>d.x.componentName,property:d.x.cssVarList.borderWidth},listBoxShadow:{selector:()=>d.x.componentName,property:d.x.cssVarList.boxShadow},listPadding:[{selector:()=>d.x.componentName,property:d.x.cssVarList.verticalPadding},{selector:()=>d.x.componentName,property:d.x.cssVarList.horizontalPadding}]}}),i.VO,(0,i.t$)({itemRenderer:h,rerenderAttrsList:["size","connect-button-label","disconnect-button-label"]}),i.tQ)(class extends m{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <descope-list>\n <slot name="empty-state" slot="empty-state"></slot>\n </descope-list>\n ',this.appsList=this.shadowRoot.querySelector("descope-list"),(0,r.fz)("\n :host {\n width: 100%;\n }\n .controls {\n display: flex;\n min-width: 8em;\n justify-content: end;\n }\n .content {\n flex-grow: 1;\n display: flex;\n flex-direction: column;\n }\n .app-title,\n .app-description {\n display: flex;\n direction: inherit;\n }\n descope-list {\n display: block;\n }\n ",this)}init(){super.init?.(),this.appsList.itemRenderer=h,this.appsList.addEventListener("click",this.onAppsListClick.bind(this))}get readonly(){return"true"===this.getAttribute("readonly")}onAppsListClick(t){if(!this.readonly){const e=t.srcElement.getAttribute("data-outbound-app-id"),n=t.srcElement.getAttribute("data-action");e&&n&&this.dispatchEvent(new CustomEvent(`${n}-clicked`,{bubbles:!0,detail:{id:e,action:n}}))}}get size(){return this.getAttribute("size")||"sm"}get connectButtonLabel(){return this.getAttribute("connect-button-label")||"Connect"}get disconnectButtonLabel(){return this.getAttribute("disconnect-button-label")||"Disconnect"}});customElements.define(p,g)},63595:(t,e,n)=>{n.r(e),n.d(e,{TextClass:()=>o.s,componentName:()=>o.T});var o=n(66434);customElements.define(o.T,o.s)},66434:(t,e,n)=>{n.d(e,{T:()=>a,s:()=>c});var o=n(88961),r=n(63200),i=n(25964),s=n(72270);const a=(0,i.xE)("text");class l extends((0,s.qu)({componentName:a,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,i.fz)("\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n ",this)}get hideWhenEmpty(){return"true"===this.getAttribute("hide-when-empty")}init(){super.init(),(0,i.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:d}={host:{selector:()=>":host"}},c=(0,r.Zz)((0,o.RF)({mappings:{hostWidth:{...d,property:"width"},hostDirection:{...d,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),o.VO,o.tQ)(l)},93895:(t,e,n)=>{n.d(e,{O:()=>l,T:()=>a});var o=n(88961),r=n(63200),i=n(25964),s=n(72270);const a=(0,i.xE)("list-item"),l=(0,r.Zz)((0,o.RF)({mappings:{verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],backgroundColor:{},borderColor:{},borderStyle:{},borderWidth:{},borderRadius:{},outline:{},cursor:{},gap:{},maxWidth:{selector:()=>":host"},alignItems:{},flexDirection:{},transition:{}}}),o.VO,o.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,i.fz)("\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n ",this)}},o.y)((0,s.qu)({componentName:a,baseSelector:"slot"}))},98538:(t,e,n)=>{n.d(e,{S:()=>l,T:()=>a});var o=n(88961),r=n(25964),i=n(8512),s=n(63200);const a=(0,r.xE)("icon"),l=(0,s.Zz)((0,o.RF)({mappings:{fill:[{},{property:i.q.cssVarList.fill}]}}),o.VO,o.tQ)((0,o.tz)({slots:[],wrappedEleName:"descope-image",style:()=>"\n :host {\n display: inline-flex;\n }\n ",excludeAttrsSync:["tabindex","class","style"],componentName:a}))}}]);
|
|
339
2
|
//# sourceMappingURL=descope-outbound-apps.js.map
|