import{D as e,E as t,G as a,H as o,K as n,L as i,J as r,a8 as s,o as l,c as d,w as u,d as g,M as h,e as p,t as c,m,k as f,a9 as b,j as A,i as y,aa as S,ab as x,b as B,f as C,F as N,O as v,a3 as T}from"./index-DkGewvWo.js";import{_ as F}from"./_plugin-vue_export-helper.BCo6x5W8.js";import{_ as w}from"./u-loading-icon.CdrBTsp-.js";import{r as z}from"./uni-app.es.Bo01BzMV.js";import{_ as P}from"./u-icon.x7ElsZU9.js";const M=F({name:"u-textarea",mixins:[a,o,e({props:{value:{type:[String,Number],default:()=>t.textarea.value},modelValue:{type:[String,Number],default:()=>t.textarea.value},placeholder:{type:[String,Number],default:()=>t.textarea.placeholder},placeholderClass:{type:String,default:()=>t.input.placeholderClass},placeholderStyle:{type:[String,Object],default:()=>t.input.placeholderStyle},height:{type:[String,Number],default:()=>t.textarea.height},confirmType:{type:String,default:()=>t.textarea.confirmType},disabled:{type:Boolean,default:()=>t.textarea.disabled},count:{type:Boolean,default:()=>t.textarea.count},focus:{type:Boolean,default:()=>t.textarea.focus},autoHeight:{type:Boolean,default:()=>t.textarea.autoHeight},fixed:{type:Boolean,default:()=>t.textarea.fixed},cursorSpacing:{type:Number,default:()=>t.textarea.cursorSpacing},cursor:{type:[String,Number],default:()=>t.textarea.cursor},showConfirmBar:{type:Boolean,default:()=>t.textarea.showConfirmBar},selectionStart:{type:Number,default:()=>t.textarea.selectionStart},selectionEnd:{type:Number,default:()=>t.textarea.selectionEnd},adjustPosition:{type:Boolean,default:()=>t.textarea.adjustPosition},disableDefaultPadding:{type:Boolean,default:()=>t.textarea.disableDefaultPadding},holdKeyboard:{type:Boolean,default:()=>t.textarea.holdKeyboard},maxlength:{type:[String,Number],default:()=>t.textarea.maxlength},border:{type:String,default:()=>t.textarea.border},formatter:{type:[Function,null],default:()=>t.textarea.formatter},ignoreCompositionEvent:{type:Boolean,default:!0}}})],data:()=>({innerValue:"",focused:!1,firstChange:!0,changeFromInner:!1,innerFormatter:e=>e}),created(){},watch:{modelValue:{immediate:!0,handler(e,t){this.innerValue=e,!1===this.firstChange&&!1===this.changeFromInner&&this.valueChange(),this.firstChange=!1,this.changeFromInner=!1}}},computed:{textareaClass(){let e=[],{border:t,disabled:a}=this;return"surround"===t&&(e=e.concat(["u-border","u-textarea--radius"])),"bottom"===t&&(e=e.concat(["u-border-bottom","u-textarea--no-radius"])),a&&e.push("u-textarea--disabled"),e.join(" ")},textareaStyle(){return n({},i(this.customStyle))}},emits:["update:modelValue","linechange","focus","blur","change","confirm","keyboardheightchange"],methods:{addStyle:i,addUnit:r,setFormatter(e){this.innerFormatter=e},onFocus(e){this.$emit("focus",e)},onBlur(e){this.$emit("blur",e),s(this,"blur")},onLinechange(e){this.$emit("linechange",e)},onInput(e){let{value:t=""}=e.detail||{};const a=(this.formatter||this.innerFormatter)(t);this.innerValue=t,this.$nextTick((()=>{this.innerValue=a,this.valueChange()}))},valueChange(){const e=this.innerValue;this.$nextTick((()=>{this.$emit("update:modelValue",e),this.changeFromInner=!0,this.$emit("change",e),s(this,"change")}))},onConfirm(e){this.$emit("confirm",e)},onKeyboardheightchange(e){this.$emit("keyboardheightchange",e)}}},[["render",function(e,t,a,o,n,i){const r=b,s=A,S=y;return l(),d(S,{class:f(["u-textarea",i.textareaClass]),style:h([i.textareaStyle])},{default:u((()=>[g(r,{class:"u-textarea__field",value:n.innerValue,style:h({height:i.addUnit(e.height)}),placeholder:e.placeholder,"placeholder-style":i.addStyle(e.placeholderStyle,"string"),"placeholder-class":e.placeholderClass,disabled:e.disabled,focus:e.focus,autoHeight:e.autoHeight,fixed:e.fixed,cursorSpacing:e.cursorSpacing,cursor:e.cursor,showConfirmBar:e.showConfirmBar,selectionStart:e.selectionStart,selectionEnd:e.selectionEnd,adjustPosition:e.adjustPosition,disableDefaultPadding:e.disableDefaultPadding,holdKeyboard:e.holdKeyboard,maxlength:e.maxlength,"confirm-type":e.confirmType,ignoreCompositionEvent:e.ignoreCompositionEvent,onFocus:i.onFocus,onBlur:i.onBlur,onLinechange:i.onLinechange,onInput:i.onInput,onConfirm:i.onConfirm,onKeyboardheightchange:i.onKeyboardheightchange},null,8,["value","style","placeholder","placeholder-style","placeholder-class","disabled","focus","autoHeight","fixed","cursorSpacing","cursor","showConfirmBar","selectionStart","selectionEnd","adjustPosition","disableDefaultPadding","holdKeyboard","maxlength","confirm-type","ignoreCompositionEvent","onFocus","onBlur","onLinechange","onInput","onConfirm","onKeyboardheightchange"]),e.count?(l(),d(s,{key:0,class:"u-textarea__count",style:h({"background-color":e.disabled?"transparent":"#fff"})},{default:u((()=>[p(c(n.innerValue.length)+"/"+c(e.maxlength),1)])),_:1},8,["style"])):m("",!0)])),_:1},8,["class","style"])}],["__scopeId","data-v-aafb8306"]]);const E=F({name:"u-button",mixins:[a,o,e({props:{hairline:{type:Boolean,default:()=>t.button.hairline},type:{type:String,default:()=>t.button.type},size:{type:String,default:()=>t.button.size},shape:{type:String,default:()=>t.button.shape},plain:{type:Boolean,default:()=>t.button.plain},disabled:{type:Boolean,default:()=>t.button.disabled},loading:{type:Boolean,default:()=>t.button.loading},loadingText:{type:[String,Number],default:()=>t.button.loadingText},loadingMode:{type:String,default:()=>t.button.loadingMode},loadingSize:{type:[String,Number],default:()=>t.button.loadingSize},openType:{type:String,default:()=>t.button.openType},formType:{type:String,default:()=>t.button.formType},appParameter:{type:String,default:()=>t.button.appParameter},hoverStopPropagation:{type:Boolean,default:()=>t.button.hoverStopPropagation},lang:{type:String,default:()=>t.button.lang},sessionFrom:{type:String,default:()=>t.button.sessionFrom},sendMessageTitle:{type:String,default:()=>t.button.sendMessageTitle},sendMessagePath:{type:String,default:()=>t.button.sendMessagePath},sendMessageImg:{type:String,default:()=>t.button.sendMessageImg},showMessageCard:{type:Boolean,default:()=>t.button.showMessageCard},dataName:{type:String,default:()=>t.button.dataName},throttleTime:{type:[String,Number],default:()=>t.button.throttleTime},hoverStartTime:{type:[String,Number],default:()=>t.button.hoverStartTime},hoverStayTime:{type:[String,Number],default:()=>t.button.hoverStayTime},text:{type:[String,Number],default:()=>t.button.text},icon:{type:String,default:()=>t.button.icon},iconColor:{type:String,default:()=>t.button.icon},color:{type:String,default:()=>t.button.color}}})],data:()=>({}),computed:{bemClass(){return this.color?this.bem("button",["shape","size"],["disabled","plain","hairline"]):this.bem("button",["type","shape","size"],["disabled","plain","hairline"])},loadingColor(){return this.plain?this.color?this.color:S[`u-${this.type}`]:"info"===this.type?"#c9c9c9":"rgb(200, 200, 200)"},iconColorCom(){return this.iconColor?this.iconColor:this.plain?this.color?this.color:this.type:"info"===this.type?"#000000":"#ffffff"},baseColor(){let e={};return this.color&&(e.color=this.plain?this.color:"white",this.plain||(e["background-color"]=this.color),-1!==this.color.indexOf("gradient")?(e.borderTopWidth=0,e.borderRightWidth=0,e.borderBottomWidth=0,e.borderLeftWidth=0,this.plain||(e.backgroundImage=this.color)):(e.borderColor=this.color,e.borderWidth="1px",e.borderStyle="solid")),e},nvueTextStyle(){let e={};return"info"===this.type&&(e.color="#323233"),this.color&&(e.color=this.plain?this.color:"white"),e.fontSize=this.textSize+"px",e},textSize(){let e=14,{size:t}=this;return"large"===t&&(e=16),"normal"===t&&(e=14),"small"===t&&(e=12),"mini"===t&&(e=10),e}},emits:["click","getphonenumber","getuserinfo","error","opensetting","launchapp","agreeprivacyauthorization"],methods:{addStyle:i,clickHandler(){this.disabled||this.loading||x((()=>{this.$emit("click")}),this.throttleTime)},getphonenumber(e){this.$emit("getphonenumber",e)},getuserinfo(e){this.$emit("getuserinfo",e)},error(e){this.$emit("error",e)},opensetting(e){this.$emit("opensetting",e)},launchapp(e){this.$emit("launchapp",e)},agreeprivacyauthorization(e){this.$emit("agreeprivacyauthorization",e)}}},[["render",function(e,t,a,o,n,i){const r=z(B("u-loading-icon"),w),s=A,b=z(B("u-icon"),P),y=T;return l(),d(y,{"hover-start-time":Number(e.hoverStartTime),"hover-stay-time":Number(e.hoverStayTime),"form-type":e.formType,"open-type":e.openType,"app-parameter":e.appParameter,"hover-stop-propagation":e.hoverStopPropagation,"send-message-title":e.sendMessageTitle,"send-message-path":e.sendMessagePath,lang:e.lang,"data-name":e.dataName,"session-from":e.sessionFrom,"send-message-img":e.sendMessageImg,"show-message-card":e.showMessageCard,onGetphonenumber:i.getphonenumber,onGetuserinfo:i.getuserinfo,onError:i.error,onOpensetting:i.opensetting,onLaunchapp:i.launchapp,onAgreeprivacyauthorization:i.agreeprivacyauthorization,"hover-class":e.disabled||e.loading?"":"u-button--active",class:f(["u-button u-reset-button",i.bemClass]),style:h([i.baseColor,i.addStyle(e.customStyle)]),onClick:i.clickHandler},{default:u((()=>[e.loading?(l(),C(N,{key:0},[g(r,{mode:e.loadingMode,size:1.15*e.loadingSize,color:i.loadingColor},null,8,["mode","size","color"]),g(s,{class:"u-button__loading-text",style:h([{fontSize:i.textSize+"px"}])},{default:u((()=>[p(c(e.loadingText||e.text),1)])),_:1},8,["style"])],64)):(l(),C(N,{key:1},[e.icon?(l(),d(b,{key:0,name:e.icon,color:i.iconColorCom,size:1.35*i.textSize,customStyle:{marginRight:"2px"}},null,8,["name","color","size"])):m("",!0),v(e.$slots,"default",{},(()=>[g(s,{class:"u-button__text",style:h([{fontSize:i.textSize+"px"}])},{default:u((()=>[p(c(e.text),1)])),_:1},8,["style"])]),!0)],64))])),_:3},8,["hover-start-time","hover-stay-time","form-type","open-type","app-parameter","hover-stop-propagation","send-message-title","send-message-path","lang","data-name","session-from","send-message-img","show-message-card","onGetphonenumber","onGetuserinfo","onError","onOpensetting","onLaunchapp","onAgreeprivacyauthorization","hover-class","style","onClick","class"])}],["__scopeId","data-v-f239a016"]]),K="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAABU0lEQVRIie2VPUoEQRCFvxFX0NxAMNFYMHJRRAMxMhMvYOIJdPEChl5B0MzIxNhAWFbUQFEwMFTESME//EFZqeUNFM3OzowzGllQFF019R49/bqaX7Q54C4S/hCwDAwAXzk5r4EVoOly08A+cGaLqormD8BbDv8ATo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