bromcom-ui 2.5.2-rc.2 → 2.5.2-rc.3

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.
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as e,H as r,g as i}from"./p-74df82e2.js";import"./p-112455b1.js";import"./p-1429a2b4.js";import{G as a}from"./p-b05a7460.js";import"./p-7e73190d.js";import{S as o}from"./p-66ba7ea5.js";import{s as d}from"./p-6d018a8f.js";const l=class{constructor(e){t(this,e),this.bcmItems=s(this,"bcm-items",7),this._id=a.UID()}connectedCallback(){if(this.el.children&&this.el.children.length>0){let t=d((()=>{var t;return Array.from(null===(t=this.el)||void 0===t?void 0:t.children).map((t=>({id:t.getAttribute("id")||a.UID(),text:t.getAttribute("text")||t.textContent.trim(),isHtmlContent:t.innerHTML.trim(),disabled:o.elementBooleanCheck(t.getAttribute("disabled")),selected:o.elementBooleanCheck(t.getAttribute("selected")),checked:o.elementBooleanCheck(t.getAttribute("checked")),readonly:o.elementBooleanCheck(t.getAttribute("readonly"))})))}),[]);this.bcmItems.emit(t),this.el.remove()}}render(){return e(r,null,e("slot",null))}get el(){return i(this)}};export{l as bcm_items}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bromcom-ui",
3
- "version": "2.5.2-rc.2",
3
+ "version": "2.5.2-rc.3",
4
4
  "description": "Stencil Component Starter",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -1 +0,0 @@
1
- import{h as s,r as e,c as t,g as i}from"./p-74df82e2.js";import"./p-112455b1.js";import{c}from"./p-7294ec8e.js";import"./p-1429a2b4.js";import{G as o}from"./p-f422ec12.js";import{B as r}from"./p-7e73190d.js";import{C as l}from"./p-312efff7.js";import{e as a}from"./p-a80ff3e5.js";import"./p-6d018a8f.js";import{N as h}from"./p-44d6172f.js";var n;!function(s){s.black="black",s.white="white",s["prime-blue"]="prime-blue",s.grey="grey",s.blue="blue",s.warmyellow="warmyellow",s.yellow="yellow",s.limegreen="limegreen",s.red="red",s.darkorange="darkorange",s.orange="orange",s.green="green",s.turquosie="turquosie",s.cobaltblue="cobaltblue",s.magenta="magenta",s.purple="purple",s["bc-red"]="bc-red",s["bc-blue"]="bc-blue",s["bc-green"]="bc-green",s["bc-orange"]="bc-orange"}(n||(n={}));const m=({_id:e,color:t,customStyle:i,size:o,checked:m,hidden:p,value:d,type:b,onDismiss:u,onSelect:f})=>{!o&&(o=r.FontSize["size-1"]);const g=(s,e=!1)=>(h.isNumber(s)&&(s=r.FontSize["size-"+s]||r.FontSize["size-4"]),e?+(r.FontSizeValue[s]||r.FontSizeValue["size-4"])+2:s),y=c("bcm-tag-2__content",b,g(o)),k=c("bcm-tag-2",{hidden:p}),j=g(o,!0);return s("div",{id:e,class:c(k,{checked:m})},s("span",{hidden:!0},s("slot",null)),s("span",{class:y,style:(s=>{if((b===r.TagType.basic||b==r.TagType.dismissable)&&n[s])return{color:a(l,n[s]+"-6"),borderColor:a(l,n[s]+"-3"),backgroundColor:a(l,n[s]+"-1")}})(t),onClick:s=>f(s)},b===r.TagType.add&&s("span",{class:"left"},s("bcm-icon",{icon:"plus",type:"outlined",color:"grey-8",size:j})),b===r.TagType.checkable&&s("input",{type:"checkbox",checked:m}),s("span",{class:"value",style:i},d),b===r.TagType.dismissable&&s("span",{class:"right close-button",onClick:s=>u(s)},s("i",{class:"bcm-fal bcm-fa-times"}))))},p=class{constructor(s){e(this,s),this.change=t(this,"bcm-change",7),this.tagDismissable=t(this,"bcm-tag-dismissable",7),this.bcmTagSelect=t(this,"bcm-tag-select",7),this._id=o.UID(),this._internal_id=o.UID(),this.hidden=!1,this.value="",this.type=r.TagType.basic,this.checked=!1,this.size=r.FontSize["size-1"],this.closeFunc=s=>s,this.selectFunc=s=>s}handleClick(){this.type===r.TagType.checkable&&this.handleChecked()}handleClose(){this.tagDismissable.emit(this.el)}handleChecked(){this.checked=!this.checked,this.change.emit(this.checked)}render(){const{type:e,color:t,value:i,customStyle:c,size:o,hidden:l,checked:a}=this;return s(m,{size:o,hidden:l,color:t,customStyle:c,checked:a,value:i,type:r.TagType[e],onSelect:s=>{this.bcmTagSelect.emit(s),this.selectFunc({event:s,id:this._id})},onDismiss:s=>{this.handleClose(),this.closeFunc(s)}})}get el(){return i(this)}};p.style="";export{p as bcm_tag_2}