PageSourceSearch

https://app-durch-die-eifel.de/build/assets/Input.e73b3e14.js

js app-durch-die-eifel.de collected 2026-09-24 10:53:55 UTC 3,161 bytes, 1 lines download raw bytes

1import{d as b}from"./debounce.bea674fa.js";import{r as m,j as v,Q as w,f as x,o as r,c as u,g as s,n as f,u as t,h as d,p as V,q as k}from"./vendor.0d0ae17d.js";const S={class:"input-wrapper relative"},q=["placeholder","required","value","type"],I={class:"icons absolute right-4 top-inputIconSmall lg:top-inputIcon flex space-x-4"},B=s("i",{class:"fa-solid fa-eye-slash text-primary-500 w-5 h-5"},null,-1),N=[B],C=s("i",{class:"fa-solid fa-eye text-primary-500 w-5 h-5"},null,-1),E=[C],z={key:1},A=s("i",{class:"fa-solid fa-circle-check text-success-500 w-5 h-5"},null,-1),M=[A],R={key:2},Z=s("i",{class:"fa-solid fa-circle-exclamation text-danger-500 w-5 h-5"},null,-1),$=[Z],j={key:0,class:"bg-danger-500 text-sm text-white w-max ml-4 px-[4px] font-medium absolute mt-2"},D={key:0},P=s("i",{class:"fa-solid fa-caret-up absolute aboslute top-[-0.6rem] ml-2 text-danger-500 text-base"},null,-1),F={__name:"Input",props:{modelValue:String|Number,placeholder:String,type:String,error:String,showErrorMessage:{type:Boolean,default:!0},icon:String,required:Boolean,debounceValue:{type:Number,default:300}},emits:["update:modelValue","clickIcon"],setup(n,{emit:p}){const e=n,h=m(null),c=m(e.type),l=v(()=>{var a;return(a=e.error)!=null?a:null}),g=v(()=>e.icon);let o=m(null);w(()=>{h.value.hasAttribute("autofocus")&&h.value.focus()}),x(()=>e.modelValue,b(function(a){if(l.value&&(p("update:modelValue",e.modelValue),o.value=!1),e.type==="email"){const i=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;o.value=new RegExp(i).test(a);return}if(e.type!=="email"&&p("update:modelValue",e.modelValue),e.required&&a&&(o.value=!0),!a){o.value=null;return}},e.debounceValue)),x(o,()=>{o.value===!0&&p("update:modelValue",e.modelValue)});const _=()=>{c.value=c.value==="password"?"text":"password"};return(a,i)=>(r(),u("div",S,[s("input",{class:f([[{"border-danger-500 hover:border-danger-500 focus:border-danger-500 focus-ring-danger-500":t(l)!=null},{"border-success-500 hover:border-success-500 focus:border-success-500 focus:ring-success-500":t(l)===null&&t(o)===!0}],"rounded pr-12 py-3 px-4 w-full placeholder:text-base placeholder:font-light focus:outline-0 outline-0 placeholder:text-gray-700 border-gray-300 focus:border-gray-500 hover:border-gray-500 transition-all duration-300 ease-in-out focus:ring-0 ring-0"]),placeholder:n.placeholder,required:n.required,onInput:i[0]||(i[0]=y=>n.modelValue=y.target.value),value:n.modelValue,ref_key:"input",ref:h,type:c.value},null,42,q),s("div",I,[e.type==="password"?(r(),u("div",{key:0,onClick:_,class:"cursor-pointer"},[s("div",{class:f({hidden:c.value==="password"})},N,2),s("div",{class:f({hidden:c.value==="text"})},E,2)])):d("",!0),t(o)===!0&&t(l)==null?(r(),u("div",z,M)):d("",!0),t(o)===!1||t(l)!=null?(r(),u("div",R,$)):d("",!0),t(g)&&e.type!=="password"?(r(),u("div",{key:3,onClick:i[1]||(i[1]=y=>p("clickIcon"))},[s("i",{class:f(t(g)+" text-primary-500 text-xl")},null,2)])):d("",!0)]),t(l)?(r(),u("div",j,[n.showErrorMessage?(r(),u("span",D,[P,V(" "+k(t(l)),1)])):d("",!0)])):d("",!0)]))}};export{F as _};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.