bromcom-ui 2.7.1 → 2.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bromcom-ui/bromcom-ui.css +2 -2
- package/dist/bromcom-ui/bromcom-ui.esm.js +1 -1
- package/dist/bromcom-ui/{p-09810641.entry.js → p-09f8ba7e.entry.js} +1 -1
- package/dist/bromcom-ui/{p-ddeb0ae4.entry.js → p-0de8098f.entry.js} +1 -1
- package/dist/bromcom-ui/p-108cea35.entry.js +1 -0
- package/dist/bromcom-ui/{p-b45dcbe8.entry.js → p-16b0d63c.entry.js} +1 -1
- package/dist/bromcom-ui/{p-4e35deee.entry.js → p-1931efe4.entry.js} +1 -1
- package/dist/bromcom-ui/{p-494fc83b.entry.js → p-1e629ab7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-67be60e2.entry.js → p-27440be5.entry.js} +1 -1
- package/dist/bromcom-ui/{p-da316919.entry.js → p-28304fca.entry.js} +1 -1
- package/dist/bromcom-ui/p-2c474a88.entry.js +1 -0
- package/dist/bromcom-ui/{p-b3b4ef8d.entry.js → p-3213c2a7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-64d3d605.entry.js → p-34e9a93c.entry.js} +1 -1
- package/dist/bromcom-ui/{p-43b0c385.entry.js → p-4c5fcb23.entry.js} +1 -1
- package/dist/bromcom-ui/{p-9a6410dc.entry.js → p-58ade41b.entry.js} +1 -1
- package/dist/bromcom-ui/{p-7c8ed186.entry.js → p-6a72fcb9.entry.js} +1 -1
- package/dist/bromcom-ui/{p-8144ffe7.entry.js → p-6ee18808.entry.js} +1 -1
- package/dist/bromcom-ui/{p-331e551b.entry.js → p-729c68a5.entry.js} +1 -1
- package/dist/bromcom-ui/{p-c3f9e0b2.entry.js → p-733d1e74.entry.js} +1 -1
- package/dist/bromcom-ui/{p-1b601be1.entry.js → p-75f3aab8.entry.js} +1 -1
- package/dist/bromcom-ui/{p-fc83d65c.entry.js → p-760d3ea6.entry.js} +1 -1
- package/dist/bromcom-ui/{p-965236c1.entry.js → p-7b119261.entry.js} +1 -1
- package/dist/bromcom-ui/p-82b236a9.entry.js +1 -0
- package/dist/bromcom-ui/{p-39a8376a.entry.js → p-92929a86.entry.js} +1 -1
- package/dist/bromcom-ui/{p-2348a904.entry.js → p-972adc7a.entry.js} +1 -1
- package/dist/bromcom-ui/{p-89e2597d.entry.js → p-b6fdac20.entry.js} +1 -1
- package/dist/bromcom-ui/{p-725810f8.js → p-c0b68c8c.js} +1 -1
- package/dist/bromcom-ui/p-c67da23a.entry.js +1 -0
- package/dist/bromcom-ui/{p-a2e25964.entry.js → p-c6dae946.entry.js} +1 -1
- package/dist/bromcom-ui/{p-9d04f3af.js → p-c9bd3da3.js} +1 -1
- package/dist/bromcom-ui/{p-ab435bec.entry.js → p-cb8d2ca7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-2144df2b.entry.js → p-cfb707d8.entry.js} +1 -1
- package/dist/bromcom-ui/{p-ceece3da.entry.js → p-d45b4649.entry.js} +1 -1
- package/dist/bromcom-ui/{p-9309e3a3.entry.js → p-d888f9d7.entry.js} +1 -1
- package/dist/bromcom-ui/{p-49dbb6be.entry.js → p-e6bbbe01.entry.js} +1 -1
- package/dist/bromcom-ui/{p-c18f9a02.entry.js → p-e6f85304.entry.js} +1 -1
- package/dist/bromcom-ui/{p-c5063246.entry.js → p-e7e69f6c.entry.js} +1 -1
- package/dist/bromcom-ui/{p-c5142b2f.entry.js → p-e8521633.entry.js} +1 -1
- package/dist/bromcom-ui/{p-917c8039.entry.js → p-ff048952.entry.js} +1 -1
- package/dist/cjs/bcm-accordion.cjs.entry.js +1 -1
- package/dist/cjs/bcm-action-buttons.cjs.entry.js +1 -1
- package/dist/cjs/bcm-alert.cjs.entry.js +1 -1
- package/dist/cjs/bcm-attendance.cjs.entry.js +1 -1
- package/dist/cjs/bcm-avatar.cjs.entry.js +1 -1
- package/dist/cjs/bcm-badge.cjs.entry.js +1 -1
- package/dist/cjs/bcm-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/bcm-button_14.cjs.entry.js +5 -4
- package/dist/cjs/bcm-checkbox-group.cjs.entry.js +1 -1
- package/dist/cjs/bcm-checkbox-lite_7.cjs.entry.js +1 -1
- package/dist/cjs/bcm-checkbox_3.cjs.entry.js +1 -1
- package/dist/cjs/bcm-collapse.cjs.entry.js +1 -1
- package/dist/cjs/bcm-default.cjs.entry.js +1 -1
- package/dist/cjs/bcm-drawer.cjs.entry.js +1 -1
- package/dist/cjs/bcm-expansion-panel.cjs.entry.js +1 -1
- package/dist/cjs/bcm-form-2.cjs.entry.js +1 -1
- package/dist/cjs/bcm-input.cjs.entry.js +1 -1
- package/dist/cjs/bcm-list.cjs.entry.js +1 -1
- package/dist/cjs/bcm-modal.cjs.entry.js +43 -3
- package/dist/cjs/bcm-popconfirm-box.cjs.entry.js +1 -1
- package/dist/cjs/bcm-popconfirm.cjs.entry.js +1 -1
- package/dist/cjs/bcm-popover-box.cjs.entry.js +1 -1
- package/dist/cjs/bcm-popover.cjs.entry.js +1 -1
- package/dist/cjs/bcm-radio-group.cjs.entry.js +1 -1
- package/dist/cjs/bcm-radio.cjs.entry.js +1 -1
- package/dist/cjs/bcm-range.cjs.entry.js +1 -1
- package/dist/cjs/bcm-search-2.cjs.entry.js +1 -1
- package/dist/cjs/bcm-step.cjs.entry.js +2 -2
- package/dist/cjs/bcm-stepper.cjs.entry.js +2 -2
- package/dist/cjs/bcm-student-card.cjs.entry.js +1 -1
- package/dist/cjs/bcm-switch.cjs.entry.js +2 -2
- package/dist/cjs/bcm-tab.cjs.entry.js +1 -1
- package/dist/cjs/bcm-tag.cjs.entry.js +1 -1
- package/dist/cjs/bcm-textarea.cjs.entry.js +1 -1
- package/dist/cjs/bcm-time-picker.cjs.entry.js +1 -1
- package/dist/cjs/bromcom-ui.cjs.js +1 -1
- package/dist/cjs/{generate-55674e27.js → generate-3c85d013.js} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{stepper-states-bbbef267.js → stepper-states-32b97a52.js} +1 -1
- package/dist/collection/components/atoms/button/button.css +2 -1
- package/dist/collection/components/molecules/dropdown/dropdown.js +1 -1
- package/dist/collection/components/molecules/modal/modal.css +308 -30
- package/dist/collection/components/molecules/modal/modal.js +60 -4
- package/dist/collection/components/molecules/switch/switch.css +1 -0
- package/dist/collection/components/organism/tabs/tab.css +284 -11
- package/dist/collection/new-ds/components/menu/menu.css +0 -1
- package/dist/collection/new-ds/components/menu/menu.js +1 -0
- package/dist/esm/bcm-accordion.entry.js +1 -1
- package/dist/esm/bcm-action-buttons.entry.js +1 -1
- package/dist/esm/bcm-alert.entry.js +1 -1
- package/dist/esm/bcm-attendance.entry.js +1 -1
- package/dist/esm/bcm-avatar.entry.js +1 -1
- package/dist/esm/bcm-badge.entry.js +1 -1
- package/dist/esm/bcm-breadcrumb.entry.js +1 -1
- package/dist/esm/bcm-button_14.entry.js +5 -4
- package/dist/esm/bcm-checkbox-group.entry.js +1 -1
- package/dist/esm/bcm-checkbox-lite_7.entry.js +1 -1
- package/dist/esm/bcm-checkbox_3.entry.js +1 -1
- package/dist/esm/bcm-collapse.entry.js +1 -1
- package/dist/esm/bcm-default.entry.js +1 -1
- package/dist/esm/bcm-drawer.entry.js +1 -1
- package/dist/esm/bcm-expansion-panel.entry.js +1 -1
- package/dist/esm/bcm-form-2.entry.js +1 -1
- package/dist/esm/bcm-input.entry.js +1 -1
- package/dist/esm/bcm-list.entry.js +1 -1
- package/dist/esm/bcm-modal.entry.js +43 -3
- package/dist/esm/bcm-popconfirm-box.entry.js +1 -1
- package/dist/esm/bcm-popconfirm.entry.js +1 -1
- package/dist/esm/bcm-popover-box.entry.js +1 -1
- package/dist/esm/bcm-popover.entry.js +1 -1
- package/dist/esm/bcm-radio-group.entry.js +1 -1
- package/dist/esm/bcm-radio.entry.js +1 -1
- package/dist/esm/bcm-range.entry.js +1 -1
- package/dist/esm/bcm-search-2.entry.js +1 -1
- package/dist/esm/bcm-step.entry.js +2 -2
- package/dist/esm/bcm-stepper.entry.js +2 -2
- package/dist/esm/bcm-student-card.entry.js +1 -1
- package/dist/esm/bcm-switch.entry.js +2 -2
- package/dist/esm/bcm-tab.entry.js +1 -1
- package/dist/esm/bcm-tag.entry.js +1 -1
- package/dist/esm/bcm-textarea.entry.js +1 -1
- package/dist/esm/bcm-time-picker.entry.js +1 -1
- package/dist/esm/bromcom-ui.js +1 -1
- package/dist/esm/{generate-f17b823f.js → generate-fc52157e.js} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{stepper-states-fc676d05.js → stepper-states-6f74146a.js} +1 -1
- package/dist/types/components/molecules/modal/modal.d.ts +3 -0
- package/dist/types/components.d.ts +2 -0
- package/package.json +1 -1
- package/dist/bromcom-ui/p-059d1920.entry.js +0 -1
- package/dist/bromcom-ui/p-0fc4f713.entry.js +0 -1
- package/dist/bromcom-ui/p-2ba00dc0.entry.js +0 -1
- package/dist/bromcom-ui/p-8ce907d9.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,H as h}from"./p-9d960649.js";import{G as e}from"./p-
|
|
1
|
+
import{r as t,c as s,h as i,H as h}from"./p-9d960649.js";import{G as e}from"./p-c9bd3da3.js";import{B as a}from"./p-beba9505.js";import"./p-112455b1.js";import{c as r}from"./p-7294ec8e.js";import"./p-6d018a8f.js";import{S as n}from"./p-208caef1.js";import{d as o}from"./p-fc2b2e5c.js";import{N as l}from"./p-44d6172f.js";import{V as c}from"./p-7e8b7a25.js";import{C as u}from"./p-fee1f12b.js";import{I as p}from"./p-cabaa43d.js";const d=class{constructor(i){t(this,i),this.focus=s(this,"bcm-focus",7),this.blur=s(this,"bcm-blur",7),this.clear=s(this,"bcm-clear",7),this.change=s(this,"bcm-change",7),this.input=s(this,"bcm-input",7),this._id=e.UID(),this._internal_id=e.UID(),this.value="",this.size=a.Size.medium,this.disabled=!1,this.readonly=!1,this.clearable=!1,this.type=a.InputType.text,this.hidden=!1,this.required=!1,this.fullWidth=!1,this.noMargin=!1,this.disableWatchValue=!1,this.passwordToggle=!1,this.maxLength=null,this.unitPrefix=null,this.decimal=!0,this.noCaption=!1,this.captionType=a.Status.default,this.inValid=!1,this.valueCache="",this.focused=!1,this.isPasswordVisible=!1,this.isBlur=!1}connectedCallback(){this.valueCache=this.value,this.captionCache=this.caption,this.captionTypeCache=this.captionType}componentWillRender(){const{type:t,isBlur:s,value:i}=this;if(i)switch(this.value.length>0&&this.checkPattern(),t){case"number":!this.checkValid("number")&&this.validationRange();break;case"email":s&&this.checkValid("email");break;case"tel":s&&this.checkValid("phone")}else!this.required&&this.resetCaption()}async onBcmFocus(){this.inputElement.focus()}async onBcmBlur(){this.inputElement.blur()}async onBcmSelect(){this.inputElement.select()}async set(t){await this.setValue(t)}async get(){return this.value||null}async setValue(t){return this.inputElement.value=t,this.value=t,this.handleChange(),t}async setClear(){return this.inputElement.value="",this.value="",await o(10),Promise.resolve()}async resetCaption(){return await o(10),this.caption=this.captionCache,this.captionType=this.captionTypeCache,this.captionError=null,this.inValid=!1,await o(10),Promise.resolve()}async getValue(){return this.value}watchValue(){this.disableWatchValue||"number"==this.type||this.handleChange()}listenKeyDown(t){if(!this.disabled&&!this.readonly&&(this.onBcmFocus(),"number"==this.type)){var s=t.which||0,i=t.key;38==s&&(t.preventDefault(),this.stepUpOrDown("up")),40==s&&(t.preventDefault(),this.stepUpOrDown("down")),(190==s||110==s||"."==i)&&this.value.indexOf(".")>-1&&t.preventDefault(),189!=s&&109!=s&&"-"!=i||("-"==this.value.charAt(0)||this.value.indexOf("-")>-1)&&t.preventDefault()}}handleFocus(){this.focused=!0,this.focus.emit(),this.whatchHasFocus()}handleBlur(){this.focused=!1,this.isBlur=!0,this.whatchHasFocus(),this.blur.emit()}handleChange(){this.value=this.inputElement.value,this.change.emit(this.value)}handleInput(){if("number"==this.type&&this.maxLength){const t=this.inputElement.value;t&&t.length>0&&t.length>this.maxLength&&(this.inputElement.value=t.substring(0,this.maxLength))}this.value=this.inputElement.value,this.input.emit(this.value)}handleClear(t){this.inputElement.value="",this.value="",this.inputElement.focus(),this.clear.emit(t),t.stopPropagation()}changePasswordVisibility(){this.isPasswordVisible=!this.isPasswordVisible}setCaption(t=null,s=null){this.caption=t||this.captionCache,this.captionType=s||this.captionTypeCache,this.captionError="error"==s?t:null}stepUpOrDown(t){if(!this.inValid&&!this.disabled&&!this.readonly){let s=+this.step||1,i=+this.value;i="up"==t?+(i+s):+(i-s),this.value=i.toString()}}validationRange(){const{min:t,max:s,value:i}=this;if(i)if(t&&s){if(i<t||i>s)return this.setCaption(n.getMessage("between",[t,s]),"error"),!1}else if(t){if(i<t)return this.setCaption(n.getMessage("min",[t]),"error"),!1}else if(s&&i>s)return this.setCaption(n.getMessage("max",[s]),"error"),!1;return this.setCaption(),!0}checkPattern(){const{pattern:t,value:s}=this;t&&(c.pattern(s,t)?(this.setCaption(),this.inValid=!1):(this.setCaption(n.getMessage("pattern"),"error"),this.inValid=!0))}checkValid(t){const{value:s}=this;return c.isValidate(s,t)?(this.setCaption(),this.inValid=!1):(this.setCaption(n.getMessage(t),"error"),this.inValid=!0),this.inValid}whatchHasFocus(){const{type:t,focused:s,valueCache:i,inValid:h}=this;t==a.InputType.number&&h&&(this.value=s?"":n.isNullOrEmpty(this.value)?i:this.value?this.fixToNumber(this.value):"")}fixToNumber(t){if(t){const s=l.getDecimalLength(this.step);return s>0?l.parseFloatFixed(t,s):t}return t}render(){const{value:t,size:s,label:e,type:a,captionType:n,caption:o,captionError:l,placeholder:c,fullWidth:d,disabled:m,readonly:f,clearable:b,passwordToggle:y,isPasswordVisible:w,noDefaultIcon:g,unit:C,inValid:V,focused:j,unitPrefix:v,noCaption:x,required:P,hidden:B,noMargin:k,_id:I}=this,T=(null==t?void 0:t.length)>0&&b,F=r("bcm-input",{hidden:B,"no-margin":k,"full-width":d,"size-1":"small"===s||"medium"===s,"size-2":"large"===s});return i(h,{tabindex:"-1",onfocus:()=>this.onBcmFocus(),class:F,onClick:()=>this.onBcmFocus()},e&&i("bcm-label",{tooltip:this.tooltip,type:n,value:e,required:P,htmlFor:I}),i(p,{id:I,type:a,value:t,pattern:this.pattern,placeholder:c,disabled:m,readonly:f,clearable:T,passwordToggle:y,isPasswordVisible:w,noDefaultIcon:g,focused:j,inValid:V,unitPrefix:v,maxLength:this.maxLength,internalId:this._internal_id,captionType:n,unit:C,size:s,handleFocus:()=>this.handleFocus(),handleBlur:()=>this.handleBlur(),handleChange:()=>this.handleChange(),handleInput:()=>this.handleInput(),steps:t=>this.stepUpOrDown(t),changePasswordVisibility:()=>this.changePasswordVisibility(),handleClear:t=>this.handleClear(t),ref:t=>this.inputElement=t,_suffix:this._suffix,_prefix:this._prefix}),i(u,{noCaption:x,captionType:n,captionError:l,caption:o,customErrorMessage:this.customErrorMessage}))}static get watchers(){return{value:["watchValue"]}}};export{d as bcm_input}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e,r;!function(e){e.info="info",e.error="error",e.warning="warning",e.success="success",e.default="default"}(e||(e={})),function(e){e.banner="banner",e.basic="basic"}(r||(r={}));const o=["localhost","beta-regression.bromcomcloud.com","beta-scrum.bromcomcloud.com","beta-kanban.bromcomcloud.com"];(()=>{const e=window.location.hostname;return o.includes(e)})()&&console.log("%cbromcom ui%c version: 2.7.
|
|
1
|
+
var e,r;!function(e){e.info="info",e.error="error",e.warning="warning",e.success="success",e.default="default"}(e||(e={})),function(e){e.banner="banner",e.basic="basic"}(r||(r={}));const o=["localhost","beta-regression.bromcomcloud.com","beta-scrum.bromcomcloud.com","beta-kanban.bromcomcloud.com"];(()=>{const e=window.location.hostname;return o.includes(e)})()&&console.log("%cbromcom ui%c version: 2.7.2-p ","color: white; background:#1890FF; font-weight: 300; font-size:10px; padding:2px 6px; border-radius: 5px","font-size:10px;");class c{}c.UID=()=>Math.random().toString(36).substr(2,9),c.getIconAttrWithStatusType=(r,o=!1)=>{if(o)return{icon:"loading",color:"blue-6"};switch(r){case e.info:return{color:"blue-6",icon:"info-circle"};case e.error:return{color:"red-6",icon:"close-circle"};case e.warning:return{color:"warmyellow-6",icon:"exclamation-circle"};case e.success:return{color:"green-6",icon:"check-circle"}}},c.createComponent=(e,r,o="append-area")=>{let c=o?document.querySelector(o):document.body;o&&!c&&(c=document.createElement("div"),c.id="append-area",document.body.appendChild(c),c.style.visibility="hidden",c.style.opacity="0");let n=document.getElementById(r.id);return n||(n=document.createElement(e)),Object.keys(r).forEach((e=>{n[e]=r[e]})),c.appendChild(n),n},c.debounceInput=(e,r,o,c)=>{let n;return function(){let t=this,i=arguments;c&&c.apply(t,i);let l=function(){n=null,o||e.apply(t,i)},a=o&&!n;clearTimeout(n),n=setTimeout(l,r),a&&e.apply(t,i)}},c.flatArray=e=>e.reduce(((e,r)=>e.concat(Array.isArray(r)?c.flatArray(r):r)),[]),c.reverseNodeList=e=>{let r=[];for(let o=e.length-1;o>=0;o--)r.push(e[o]);return r},c.findEventPathWithKey=(e,r,o)=>{o=Array.isArray(o)?o:[o];let c=e.composedPath()||e.path;if(c)return void 0!==c.filter((e=>o.includes(e[r])))[0]},c.findEventTarget=(e,r)=>{r=Array.isArray(r)?r:[r];let o=e.target||e.srcElement;if(console.log(o),o)return r.includes(o)},c.findEventPathWithNodeName=(e,r)=>{let o=e.composedPath()||e.path;if(o)return o.filter((e=>e.nodeName===r))[0]},c.findEventPath=(e,r)=>{r=Array.isArray(r)?r:[r];let o=e.composedPath()||e.path;if(o)return void 0!==o.filter((e=>r.includes(e)))[0]},c.objectIsEmpty=e=>0===Object.keys(e).length&&e.constructor===Object,c.convertIdsToNestedData=(e,r)=>{let o=[],n=[];return r.forEach((r=>{e&&e.indexOf(r.id)>-1?o.push(r):r.items&&(n=c.convertIdsToNestedData(e,r.items),n.length>0&&(r.items=n,o.push(r)))})),o},c.nodeListToArray=e=>Array.prototype.slice.call(e),c.setAttributes=(e,r)=>{Object.keys(r).forEach((o=>{e.setAttribute(o,r[o])}))};export{c as G,e as S,r as T}
|