@shrfe/assets 1.0.20 → 1.0.22

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.
Files changed (43) hide show
  1. package/js/shrfe-core-umd.js +4 -4
  2. package/package.json +1 -1
  3. package/wc-lib/p-0ab5aa8f.entry.js +1 -0
  4. package/wc-lib/{p-7aab95ba.entry.js → p-0c66b75b.entry.js} +1 -1
  5. package/wc-lib/p-1721388d.entry.js +1 -0
  6. package/wc-lib/p-252bb260.entry.js +1 -0
  7. package/wc-lib/p-28add28f.entry.js +1 -0
  8. package/wc-lib/p-322b6a84.entry.js +1 -0
  9. package/wc-lib/p-45d216c5.entry.js +6 -0
  10. package/wc-lib/p-4adb8241.entry.js +1 -0
  11. package/wc-lib/p-513a64f8.entry.js +1 -0
  12. package/wc-lib/p-681129c8.entry.js +1 -0
  13. package/wc-lib/p-82beda62.entry.js +1 -0
  14. package/wc-lib/p-929e3dd9.entry.js +1 -0
  15. package/wc-lib/p-CUS2AmqM.js +2 -0
  16. package/wc-lib/p-a0c6e079.entry.js +1 -0
  17. package/wc-lib/p-a5a7f920.js +1 -0
  18. package/wc-lib/p-a9faae34.entry.js +1 -0
  19. package/wc-lib/p-adc51af7.entry.js +1 -0
  20. package/wc-lib/{p-b6c40d9f.entry.js → p-bbc59b1f.entry.js} +1 -1
  21. package/wc-lib/p-cb6082d5.entry.js +1 -0
  22. package/wc-lib/p-ee08c411.entry.js +1 -0
  23. package/wc-lib/p-f1e95f08.entry.js +1 -0
  24. package/wc-lib/wc-lib.esm.js +1 -1
  25. package/wc-lib/p-06933d31.entry.js +0 -1
  26. package/wc-lib/p-073e72b7.js +0 -1
  27. package/wc-lib/p-125d443b.entry.js +0 -1
  28. package/wc-lib/p-197b576e.entry.js +0 -1
  29. package/wc-lib/p-3eaa4250.entry.js +0 -1
  30. package/wc-lib/p-4865cb8d.entry.js +0 -1
  31. package/wc-lib/p-6f116fdb.entry.js +0 -1
  32. package/wc-lib/p-72ad0bd5.entry.js +0 -1
  33. package/wc-lib/p-75161f0b.entry.js +0 -1
  34. package/wc-lib/p-86b5690c.entry.js +0 -1
  35. package/wc-lib/p-8f324339.entry.js +0 -1
  36. package/wc-lib/p-9cf22f72.entry.js +0 -1
  37. package/wc-lib/p-C6hwjI5h.js +0 -2
  38. package/wc-lib/p-ae4dbe50.entry.js +0 -6
  39. package/wc-lib/p-b243e285.entry.js +0 -1
  40. package/wc-lib/p-bbc4e214.entry.js +0 -1
  41. package/wc-lib/p-c57ce36c.entry.js +0 -1
  42. package/wc-lib/p-c592afb3.entry.js +0 -1
  43. package/wc-lib/p-ff9e9733.entry.js +0 -1
@@ -1 +0,0 @@
1
- import{r as t,h as s}from"./p-C6hwjI5h.js";const o={info:{titleColor:"var(--sfe-color-text-info-strong, #004CA6)",borderLeftColor:"var(--sfe-color-border-info-solid, #004CA6)",subtleBgColor:"var(--sfe-color-fill-info-lightest, #E4EDFC)",icon:"Info",iconColor:"#004CA6"},error:{titleColor:"var(--sfe-color-text-critical-strong, #A22827)",borderLeftColor:"var(--sfe-color-border-critical-solid, #A22827)",subtleBgColor:"var(--sfe-color-fill-critical-lightest, #FCF4F4)",icon:"Warning",iconColor:"#821C1C"},success:{titleColor:"var(--sfe-color-text-positive-strong, #135216)",borderLeftColor:"var(--sfe-color-border-positive-solid, #1D7F22)",subtleBgColor:"var(--sfe-color-fill-positive-lightest, #F4FBF4)",icon:"Checkmark Circle",iconColor:"#135216"},warning:{titleColor:"var(--sfe-color-text-warning-strong, #7A4510)",borderLeftColor:"var(--sfe-color-border-warning-solid, #FEB872)",subtleBgColor:"var(--sfe-color-fill-warning-lightest, #FFF5EB)",icon:"Error Circle",iconColor:"#A05C1C"}},a=class{constructor(s){t(this,s)}type="success";position="top-center";_title;message;timeout=5e3;showTitle=!0;dismissible=!0;isVisible=!1;timeoutId;transitionDuration=300;get resolvedStyle(){const t=o[this.type];return{config:t,styles:{"background-color":this.showTitle?"#FFF":t.subtleBgColor,"inline-size":this.showTitle?"273px":"332px","padding-inline":this.showTitle?"14px":"12px","border-left-width":this.showTitle?"4px":"2px"}}}async showToast(){this.isVisible=!0,this.timeoutId=setTimeout((()=>{this.hideToast()}),this.timeout)}hideToast(){const t=document.querySelector("swc-toast");t&&(t.isVisible=!1,clearTimeout(t.timeoutId),setTimeout((()=>{t.reset(),t.remove()}),this.transitionDuration))}async reset(){this.type="success",this.position="top-center",this._title="",this.message="",this.timeout=5e3,this.showTitle=!0,this.isVisible=!1,this.dismissible=!0}render(){return s("div",{key:"6a60c1490b4e3367feee0538f9b9f3462f003e44",role:"alert","aria-live":"assertive","aria-labelledby":"shr-toast-title","aria-describedby":"shr-toast-message","data-testid":"sfe-toast","data-state":this.isVisible?"showing":"hidden",class:`shr-toast ${this.position}`,style:{"--transition-duration":`${this.transitionDuration}ms`,"--title-color":this.resolvedStyle.config.titleColor,"--message-color":this.showTitle?"var(--sfe-color-text-default-primary, rgba(0, 0, 0, 0.80))":"var(--sfe-color-text-default-primary, rgba(0, 0, 0, 0.95))","--border-left-color":this.resolvedStyle.config.borderLeftColor,...this.resolvedStyle.styles}},this.showTitle&&s("div",{key:"c82f1944e5ad988bb13367f75846cff988e98831",class:"shr-toast--with-title"},s("div",{key:"21f53c56290ee60a8c3effc53a043e30acefd073",class:"d-flex justify-content-between align-items-center mb-1"},s("div",{key:"17f3e2e8410b7935899b0837bed0a8da01f3b931",class:"d-flex align-items-center mr-3"},s("swc-svg-icon",{key:"9c226c6c06873c38685dfc81e3a6721e3ed2b534",name:this.resolvedStyle.config.icon,variant:"filled",color:this.resolvedStyle.config.iconColor,size:"16"}),s("span",{key:"83d6bbe6b39bf40650e5068878923b2816b8675e",id:"shr-toast-title",class:"shr-toast__title ml-1"}," ",this._title)),this.dismissible&&s("swc-icon-button",{key:"512c615aa3df639624fb5677e76e9ffdc8b7e4da",intent:"neutral",variant:"bare",round:!0,"aria-label":"Close toast",onClick:this.hideToast},s("swc-svg-icon",{key:"6a5cfda2f74719e23b0aca31b58972651a4938fa",name:"Dismiss",size:"16"}))),s("div",{key:"f7998a73124b85a982577cb6cc58035f49a506cf",id:"shr-toast-message",class:"shr-toast__message fs-12"}," ",this.message)),!this.showTitle&&s("div",{key:"d4f8155ea1f273eab56bcb388795863eb11ffa9c",class:"shr-toast--without-title"},s("div",{key:"d4f3a7b402dc5d88fad19b725785a30ec30a616b",class:"d-flex justify-content-between align-items-center"},s("div",{key:"34589efce3ad8ba1e97f1c9d03c94f6b1622146a",class:"d-flex align-items-center mr-3"},s("swc-svg-icon",{key:"81ba3521313dc240e89f402eef13eec16bbfb736",name:this.resolvedStyle.config.icon,variant:"outline",color:this.resolvedStyle.config.iconColor,size:"16"}),s("p",{key:"337daa3bf2c9b2e41487d05bf1c22ba2f878d05c",id:"shr-toast-message",class:"m-0 shr-toast__message fs-14 ml-1"},this.message)),this.dismissible&&s("swc-icon-button",{key:"31f4cfdc2cfaf029de9e25a838dd6def58da8945",intent:"neutral",variant:"bare",round:!0,"aria-label":"Close toast",onClick:this.hideToast},s("swc-svg-icon",{key:"6462901d6513677ef3cb14b165c16abbbfd23b0d",name:"Dismiss",size:"16"})))))}};a.style=".sc-swc-toast-h .d-flex.sc-swc-toast{display:flex}.sc-swc-toast-h .align-items-center.sc-swc-toast{align-items:center}.sc-swc-toast-h .justify-content-center.sc-swc-toast{justify-content:center}.sc-swc-toast-h .justify-content-between.sc-swc-toast{justify-content:space-between}.sc-swc-toast-h .ml-1.sc-swc-toast{margin-inline-start:4px}.sc-swc-toast-h .mr-3.sc-swc-toast{margin-inline-end:12px}.sc-swc-toast-h .mb-1.sc-swc-toast{margin-block-end:4px}.sc-swc-toast-h .shr-toast.sc-swc-toast{position:fixed;z-index:var(--sfe-stack-level-alert);border-radius:4px;border:1px solid rgba(0, 0, 0, 0.1);border-left-style:solid;border-left-color:var(--border-left-color);padding-block:12px;overflow:hidden}.sc-swc-toast-h .shr-toast__message.sc-swc-toast{font-family:var(--sfe-typography-font-serif-font, Sora);font-weight:400;line-height:16px;color:var(--message-color);word-break:break-word}.sc-swc-toast-h .shr-toast--with-title.sc-swc-toast .shr-toast__message.sc-swc-toast{line-height:1.5}.sc-swc-toast-h .shr-toast--without-title.sc-swc-toast .shr-toast__message.sc-swc-toast{line-height:1.75}.sc-swc-toast-h .shr-toast__title.sc-swc-toast{font-family:var(--sfe-typography-font-serif-font, Sora);font-size:14px;font-weight:500;line-height:16px;color:var(--title-color);word-break:break-word}.sc-swc-toast-h .shr-toast__close-icon-wrapper.sc-swc-toast{block-size:25px;inline-size:25px;border-radius:50%;border:none;background-color:transparent;transition:background-color 0.2s ease-out}.sc-swc-toast-h .shr-toast__close-icon-wrapper.sc-swc-toast:hover{background-color:#f3f3f3}.sc-swc-toast-h .shr-toast__close-icon-wrapper.sc-swc-toast .close-icon.sc-swc-toast{color:rgba(0, 0, 0, 0.7)}.sc-swc-toast-h .shr-toast.top-right.sc-swc-toast{top:20px;right:20px;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.top-right[data-state=hidden].sc-swc-toast{opacity:0;transform:translateX(20px)}.sc-swc-toast-h .shr-toast.top-right[data-state=showing].sc-swc-toast{opacity:1;transform:translateX(0)}.sc-swc-toast-h .shr-toast.top-left.sc-swc-toast{top:20px;left:20px;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.top-left[data-state=hidden].sc-swc-toast{opacity:0;transform:translateX(-20px)}.sc-swc-toast-h .shr-toast.top-left[data-state=showing].sc-swc-toast{opacity:1;transform:translateX(0)}.sc-swc-toast-h .shr-toast.top-center.sc-swc-toast{top:20px;left:0;right:0;margin-inline:auto;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.top-center[data-state=hidden].sc-swc-toast{opacity:0;transform:translateY(-20px)}.sc-swc-toast-h .shr-toast.top-center[data-state=showing].sc-swc-toast{opacity:1;transform:translateY(0)}.sc-swc-toast-h .shr-toast.bottom-right.sc-swc-toast{bottom:20px;right:20px;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.bottom-right[data-state=hidden].sc-swc-toast{opacity:0;transform:translateX(20px)}.sc-swc-toast-h .shr-toast.bottom-right[data-state=showing].sc-swc-toast{opacity:1;transform:translateX(0)}.sc-swc-toast-h .shr-toast.bottom-left.sc-swc-toast{bottom:20px;left:20px;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.bottom-left[data-state=hidden].sc-swc-toast{opacity:0;transform:translateX(-20px)}.sc-swc-toast-h .shr-toast.bottom-left[data-state=showing].sc-swc-toast{opacity:1;transform:translateX(0)}.sc-swc-toast-h .shr-toast.bottom-center.sc-swc-toast{bottom:20px;left:0;right:0;margin-inline:auto;transition:opacity var(--transition-duration), transform var(--transition-duration)}.sc-swc-toast-h .shr-toast.bottom-center[data-state=hidden].sc-swc-toast{opacity:0;transform:translateY(20px)}.sc-swc-toast-h .shr-toast.bottom-center[data-state=showing].sc-swc-toast{opacity:1;transform:translateY(0)}";export{a as swc_toast}
@@ -1 +0,0 @@
1
- import{r as e,d as s,h as a}from"./p-C6hwjI5h.js";const i=class{constructor(a){e(this,a),this.closeModal=s(this,"closeModal",7)}isModalOpen=!1;closeOnEsc=!0;closeOnOverlayClick=!0;size="sm";position="right";closeModal;closeDialog=()=>{this.closeModal.emit()};render(){return a("swc-modal-root",{key:"b4a1c983be02e296463c93f2c24f93452a929df2",isModalOpen:this.isModalOpen,closeOnEsc:this.closeOnEsc,closeOnOverlayClick:this.closeOnOverlayClick,onCloseModal:this.closeDialog},a("div",{key:"e876c2bd86bce532d6a2b334a5fa17acbff0b4c9",class:`sfe-side-panel sfe-side-panel--${this.position} sfe-side-panel--${this.size}`},a("header",{key:"3e5387675a4062c5efbe7b254ae59a3f822a4a9d",class:"sfe-side-panel__header"},a("div",{key:"551d35d7545e836186b3d90a72fcb461544e6bc6"},a("h3",{key:"6a31fa76f9f044d91ae9b0a338a0a6c0753aeee6",class:"sfe-side-panel__title"},a("slot",{key:"8a4dc91e0db4e2f89c84305af9c4d4b9199347a5",name:"title"})),a("p",{key:"6b93ae0beeff828348ad4124821ac79909fe9753",class:"sfe-side-panel__description"},a("slot",{key:"97ab107db2ca63d763804c1519c380c666d041ae",name:"description"}))),a("swc-button",{key:"feaa7354451467d1bc400946924cb4b3aa296747",round:!0,intent:"neutral",variant:"bare",size:"md","aria-label":"Close",onClick:this.closeDialog},"×")),a("section",{key:"fe0eccc3bac150b4041eb430c15634474c6cd6d4",class:"sfe-side-panel__body"},a("slot",{key:"e093dcf1881c7d00c4a3c7aa9723c2bd0d1ce828",name:"body"})),a("footer",{key:"fb1824abb92039afabc7d29447c9f604a9052f6e",class:"sfe-side-panel__footer"},a("slot",{key:"0af4cf8b82b3e98517c4d65906a60f5b3392d8a5",name:"footer"}))))}};i.style=".sfe-side-panel.sc-swc-side-panel{display:flex;flex-direction:column;height:100vh;background-color:white;position:fixed;top:0;bottom:0}.sfe-side-panel--right.sc-swc-side-panel{right:0;animation:slide-left 0.3s ease}.sfe-side-panel--left.sc-swc-side-panel{left:0;animation:slide-right 0.3s ease}.sfe-side-panel--sm.sc-swc-side-panel{width:360px}.sfe-side-panel--md.sc-swc-side-panel{width:480px}.sfe-side-panel--lg.sc-swc-side-panel{width:640px}.sfe-side-panel__header.sc-swc-side-panel{display:flex;justify-content:space-between;align-items:center;padding:1em;border-bottom:1px solid #ccc}.sfe-side-panel__title.sc-swc-side-panel{font-size:1rem;font-weight:500;margin:0}.sfe-side-panel__description.sc-swc-side-panel{font-size:0.875rem;color:gray;margin:0}.sfe-side-panel__body.sc-swc-side-panel{padding:1em;overflow-y:auto}.sfe-side-panel__footer.sc-swc-side-panel{padding:1em;margin:auto auto 2em 0;text-align:right}@keyframes slide-left{from{opacity:0;transform:translateX(50%)}}@keyframes slide-right{from{opacity:0;transform:translateX(-50%)}}";export{i as swc_side_panel}
@@ -1 +0,0 @@
1
- import{r as e,e as t,h as s}from"./p-C6hwjI5h.js";const i=class{constructor(t){e(this,t)}get hostElement(){return t(this)}index;isLastItem=!1;activeIndex;orientation;withCheckmark;lineSize;idProp;computedStatus;computeStatus(){return this.index<this.activeIndex?"completed":this.index===this.activeIndex?"active":"incomplete"}componentWillLoad(){this.computedStatus=this.computeStatus()}render(){return s("div",{key:"cf4e4d06b399505b4d217ce68bccaaf5857a4508","aria-current":this.activeIndex===this.index?"step":void 0,class:`stepper-item stepper-item--${this.computedStatus} stepper-item--${this.orientation} ${this.isLastItem?"last-item":""}`,style:{"--line-size":this.lineSize,"--thumb-size":this.withCheckmark?"20px":"12px"},"data-testid":"sfe-stepper-item"},s("div",{key:"33f419564aa6b17b023383c5660e969ee5ff9e1f",class:"stepper-item__thumb-wrapper"},s("div",{key:"72b9606ca90ba58d7ab23fb157ee9313caa1674c",class:"stepper-item__thumb"},this.withCheckmark&&"completed"===this.computedStatus&&s("swc-svg-icon",{key:"7264d1efbd806a5295ac397b11fa401e1ba374ea",color:"#ffffff",size:"12",name:"Checkmark"}))),s("div",{key:"d7829344d76a84fa4ebf4d56d8c757ac0e9aa802",class:"stepper-item__content"},s("slot",{key:"78047c282dbd7004324de74d9368b9c774671bd1",name:"content"})))}};i.style='.stepper-item.sc-swc-stepper-item{--item-size:calc(max(120px, var(--line-size)));display:flex;flex-direction:column;align-items:center}.stepper-item.stepper-item--horizontal.sc-swc-stepper-item{width:var(--item-size)}.stepper-item__thumb.sc-swc-stepper-item{width:var(--thumb-size);height:var(--thumb-size);border-radius:50%;position:relative;display:grid;place-content:center}.stepper-item__thumb.sc-swc-stepper-item::after{position:absolute;content:"";top:50%;left:100%;transform:translateY(-50%);width:var(--item-size);height:2px;background-color:#ccc}.stepper-item--incomplete.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item{background-color:#fff;border:1px solid var(--sfe-color-icon-default-muted)}.stepper-item--active.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item{background-color:var(--sfe-color-fill-brand-on-subtle)}.stepper-item--completed.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item,.stepper-item--completed.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item::after{background-color:var(--sfe-color-icon-default-brand)}.stepper-item--horizontal.sc-swc-stepper-item .stepper-item__thumb-wrapper.sc-swc-stepper-item{margin-block-end:16px}.stepper-item--vertical.sc-swc-stepper-item .stepper-item__thumb-wrapper.sc-swc-stepper-item{margin-inline-end:16px}.stepper-item--vertical.sc-swc-stepper-item{flex-direction:row;height:var(--item-size)}.stepper-item--vertical.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item{margin-inline-end:10px}.stepper-item--vertical.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item::after{position:absolute;content:"";top:100%;left:50%;transform:translateX(-50%);width:2px;height:var(--item-size)}.last-item.sc-swc-stepper-item .stepper-item__thumb.sc-swc-stepper-item::after{width:0;height:0}.stepper-item--horizontal.sc-swc-stepper-item .stepper-item__content.sc-swc-stepper-item{text-align:center}';export{i as swc_stepper_item}
@@ -1 +0,0 @@
1
- import{r as e,h as s,H as t}from"./p-C6hwjI5h.js";const i=class{constructor(s){e(this,s)}round=!1;size="50px";height="20px";width="100%";borderRadius="var(--sfe-sizing-radius-large, 12px)";DEFAULT_PROPS_VALUE={size:"50px",height:"20px",width:"100%",borderRadius:"var(--sfe-sizing-radius-large, 12px)"};isValidSize(e){return/^(auto|(\d+(\.\d+)?(px|em|rem|%)))$/.test(e)}get validatedSize(){return this.isValidSize(this.size)?this.size:this.DEFAULT_PROPS_VALUE.size}get validatedWidth(){return this.isValidSize(this.width)?this.width:this.DEFAULT_PROPS_VALUE.width}get validatedHeight(){return this.isValidSize(this.height)?this.height:this.DEFAULT_PROPS_VALUE.height}get validatedBorderRadius(){return this.isValidSize(this.borderRadius)?this.borderRadius:this.DEFAULT_PROPS_VALUE.borderRadius}get shimmerStyleProps(){return{width:this.round?this.validatedSize:this.validatedWidth,height:this.round?this.validatedSize:this.validatedHeight,borderRadius:this.round?"50%":this.validatedBorderRadius}}render(){return s(t,{key:"4ac2749eb86b07d68be926a9891388b901861ea5"},s("div",{key:"5ab9585c2010783e0b81fcc19c860ff74d93bb92",class:"skeleton-loader","data-testid":"sfe-skeleton"},s("div",{key:"780c247210cd52cc4061451d5f80ad9526c1d219",class:"skeleton-item","aria-hidden":"true",style:{...this.shimmerStyleProps}})))}};i.style=".sc-swc-skeleton-h .skeleton-loader.sc-swc-skeleton{display:flex;gap:10px}.sc-swc-skeleton-h .skeleton-loader.sc-swc-skeleton .skeleton-item.sc-swc-skeleton{background-color:var(--sfe-color-fill-neutral-subtle, #eaedf0);animation:shimmer 2s infinite;transition:opacity 0.3s ease-in-out}@keyframes shimmer{0%{opacity:1}50%{opacity:0.3}100%{opacity:1}}";export{i as swc_skeleton}
@@ -1 +0,0 @@
1
- import{r as s,d as t,h as a,H as e}from"./p-C6hwjI5h.js";const i=class{constructor(a){s(this,a),this.handleChange=t(this,"handleChange",7)}value=[];max=1/0;placeholder="Add a tag";disabled=!1;hasError=!1;newTag="";isFocused=!1;focusedTagIndex=null;tags=[...this.value??[]];handleChange;addTag=()=>{const s=this.newTag.trim();s&&this.tags.length<this.max&&(this.tags=[...this.tags,s],this.newTag="")};removeTag=s=>{this.disabled||(this.tags=this.tags.filter(((t,a)=>s!==a)),this.focusedTagIndex=null)};handleBackspace=()=>{this.newTag||(null===this.focusedTagIndex&&this.tags.length>0?this.focusedTagIndex=this.tags.length-1:null!==this.focusedTagIndex&&this.removeTag(this.focusedTagIndex))};handleClickTagRemoval=s=>{this.focusedTagIndex=s,this.removeTag(this.focusedTagIndex)};handleFocus=()=>{this.isFocused=!0,this.focusedTagIndex=null};handleBlur=()=>{this.isFocused=!0,this.focusedTagIndex=null};handleKeyDown=s=>{"backspace"===s.key.toLowerCase()&&this.handleBackspace(),"enter"===s.key.toLowerCase()&&(s.preventDefault(),this.addTag())};handleInputChange=s=>{const t=s.target.value.trim();this.newTag=t};valueChangeHandler(s){Array.isArray(s)&&(this.tags=[...s??[]])}tagsChangeHandler(s){this.handleChange.emit(s)}componentWillLoad(){Array.isArray(this.value)&&(this.tags=[...this.value??[]])}render(){return a(e,{key:"2f04a1fcecef7d76e48e9a126350115a34beff46"},a("div",{key:"9a8503819a3bccd6a30e605cd164f7e759ff9215",class:`sfe-tags-input \n ${this.hasError?"has-error":""} \n ${this.disabled} \n ${this.isFocused?"focused":""}`,"data-testid":"sfe-tags-input"},a("div",{key:"99e59fc7a74d42df5239e84c20d0c74fb32922f6",class:"tags-wrapper"},this.tags.map(((s,t)=>a("swc-tag",{key:t,instanceId:t,dismissible:!this.disabled,class:this.focusedTagIndex===t?"focused":"","on-dismiss":()=>this.handleClickTagRemoval(t)},s))),a("input",{key:"003b16b80e723bc81e3d85a845aa30b4942a24df",type:"text",placeholder:this.placeholder,disabled:this.disabled,class:"tag-input",value:this.newTag,onInput:this.handleInputChange,onBlur:this.handleBlur,onFocus:this.handleFocus,onKeyDown:this.handleKeyDown}))))}static get watchers(){return{value:[{valueChangeHandler:0}],tags:[{tagsChangeHandler:0}]}}};i.style=".sc-swc-tags-input-h .sfe-tags-input.sc-swc-tags-input{display:flex;flex-wrap:wrap;align-items:flex-start;border-radius:var(--sfe-sizing-radius-small, 4px);border:1px solid var(--sfe-form-input-color-border-default, #9ea8b3);padding:10px;transition:border-color 0.2s}.sc-swc-tags-input-h .sfe-tags-input.disabled.sc-swc-tags-input{opacity:0.4;pointer-events:none}.sc-swc-tags-input-h .sfe-tags-input.sc-swc-tags-input:hover,.sc-swc-tags-input-h .sfe-tags-input.sc-swc-tags-input .focused.sc-swc-tags-input{border:1px solid var(--sfe-form-input-color-border-hover, #4080e0)}.sc-swc-tags-input-h .sfe-tags-input.has-error.sc-swc-tags-input{border:1px solid var(--sfe-form-input-color-border-error, #a22827)}.sc-swc-tags-input-h .tags-wrapper.sc-swc-tags-input{display:flex;flex-wrap:wrap;gap:5px;width:100%}.sc-swc-tags-input-h input[type=text].sc-swc-tags-input{min-width:100px;flex-grow:1;outline:none;border:none;background:transparent}.sc-swc-tags-input-h input[type=text].sc-swc-tags-input:disabled{cursor:not-allowed;background:transparent;opacity:0.4}";export{i as swc_tags_input}