cas-ds-web-components 1.2.113 → 1.2.114

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.
@@ -1,4 +1,4 @@
1
- (function(_,J){typeof exports=="object"&&typeof module<"u"?J(exports):typeof define=="function"&&define.amd?define(["exports"],J):(_=typeof globalThis<"u"?globalThis:_||self,J(_["all-components"]={}))})(this,function(_){"use strict";var Fv=Object.defineProperty;var Nv=(_,J,J1)=>J in _?Fv(_,J,{enumerable:!0,configurable:!0,writable:!0,value:J1}):_[J]=J1;var g=(_,J,J1)=>(Nv(_,typeof J!="symbol"?J+"":J,J1),J1);var I3,SC;(()=>{const o=document.createElement("link");o.setAttribute("href","https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap"),o.setAttribute("rel","stylesheet"),document.head.appendChild(o)})();const Y5={name:"@eloisa-ds/all-components",version:"1.0.115",dependencies:{},main:"./index.js",module:"./index.mjs",typings:"./index.d.ts",private:!0};/**
1
+ (function(_,J){typeof exports=="object"&&typeof module<"u"?J(exports):typeof define=="function"&&define.amd?define(["exports"],J):(_=typeof globalThis<"u"?globalThis:_||self,J(_["all-components"]={}))})(this,function(_){"use strict";var Fv=Object.defineProperty;var Nv=(_,J,J1)=>J in _?Fv(_,J,{enumerable:!0,configurable:!0,writable:!0,value:J1}):_[J]=J1;var g=(_,J,J1)=>(Nv(_,typeof J!="symbol"?J+"":J,J1),J1);var I3,SC;(()=>{const o=document.createElement("link");o.setAttribute("href","https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap"),o.setAttribute("rel","stylesheet"),document.head.appendChild(o)})();const Y5={name:"@eloisa-ds/all-components",version:"1.0.116",dependencies:{},main:"./index.js",module:"./index.mjs",typings:"./index.d.ts",private:!0};/**
2
2
  * @license
3
3
  * Copyright 2019 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
@@ -13171,8 +13171,8 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
13171
13171
  margin: 0 16px;
13172
13172
  }
13173
13173
  `;function ov({value:o,hasError:C,icon:t,pattern:e,showHelperText:i,label:a,placeholder:l,size:h}){const n=i==="true"||C,r=t!=="",d=o!=="",c=sv({value:o,pattern:e}),p=q({"input-container":!0,"has-content":d||l,"has-error":C||d&&!c,"has-icon":r,[h]:h});return{showHelper:n,contentStyle:p,hasValue:d,hasIcon:r,isValid:c}}function sv({value:o,pattern:C}){if(!C)return!0;const t=typeof C=="string"?new RegExp(C.startsWith("/")&&C.endsWith("/")?C.slice(1,-1):C):C;return(t==null?void 0:t.test(o))??!1}class S2 extends f{constructor(){var C;super(),this.value="",this.defaultValue="",this.name=((C=this.getAttribute("label"))==null?void 0:C.toLowerCase().replace(" ","-"))||"input",this.isInputError="false",this.icon="",this.iconSize="20",this.alignment="leading"}_onChange(C){this.value=C.composedPath()[0].value,this.dispatchEvent(new Event("change",{bubbles:!0,composed:!0}))}updated(){var t,e;this.disabled==="true"&&((t=this.shadowRoot.querySelector("input"))==null||t.setAttribute("disabled",!0)),this.readonly&&((e=this.shadowRoot.querySelector("input"))==null||e.setAttribute("readonly",!0))}firstUpdated(){const{iconProps:C,iconPosition:t}=this;t==="right"&&this.setAttribute("alignment","trailing");const e=C==null?void 0:C.replace(/'/g,'"');if(e){let i=JSON.parse(e);this.icon=i.name,this.iconSize=i.size}}render(){const{label:C,value:t,name:e,required:i,pattern:a,isInputError:l,helperText:h,icon:n,showHelperText:r,placeholder:d,size:c}=this,{showHelper:p,contentStyle:v,hasIcon:u,isValid:w}=ov({value:t,hasError:l==="true",icon:n,pattern:a,required:i,showHelperText:r,label:C,placeholder:d,size:c}),m={name:e,value:t,error:!1,success:!1};let k="Campo válido";i&&!t||!w?(i&&!t&&(k="Este campo es requerido"),w||(k=`El valor ingresado no es válido ${h}`),m.error=!0):m.success=!0;const $=new CustomEvent("callback",{detail:{...m,message:k}});return this.dispatchEvent($),M`
13174
- <div class=${v}>
13175
- <div class="input-content">
13174
+ <div class=${v} part="input-container">
13175
+ <div class="input-content" part="input-content">
13176
13176
  ${u?M`
13177
13177
  <div class="icon">
13178
13178
  <cas-icon name=${n} size=${this.iconSize}></cas-icon>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cas-ds-web-components",
3
3
  "description": "Web Components based on CAS DS",
4
- "version": "1.2.113",
4
+ "version": "1.2.114",
5
5
  "author": "aconejeros",
6
6
  "keywords": [
7
7
  "direflow",