2025-03-21 16:50:18 +08:00
|
|
|
(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["tuniao-ui/components/tn-input/tn-input"],{538:function(t,e,n){"use strict";n.r(e);var i=n(539),u=n(541);for(var r in u)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return u[t]}))}(r);n(543);var o,a=n(42),l=Object(a["default"])(u["default"],i["render"],i["staticRenderFns"],!1,null,"628dad5c",null,!1,i["components"],o);l.options.__file="tuniao-ui/components/tn-input/tn-input.vue",e["default"]=l.exports},539:function(t,e,n){"use strict";n.r(e);var i=n(540);n.d(e,"render",(function(){return i["render"]})),n.d(e,"staticRenderFns",(function(){return i["staticRenderFns"]})),n.d(e,"recyclableRender",(function(){return i["recyclableRender"]})),n.d(e,"components",(function(){return i["components"]}))},540:function(t,e,n){"use strict";var i;n.r(e),n.d(e,"render",(function(){return u})),n.d(e,"staticRenderFns",(function(){return o})),n.d(e,"recyclableRender",(function(){return r})),n.d(e,"components",(function(){return i}));var u=function(){var t=this,e=t.$createElement,n=(t._self._c,"textarea"===t.type?t.__get_style([t.inputStyle]):null),i="textarea"!==t.type&&"select"!==t.type?t.__get_style([t.inputStyle]):null;t._isMounted||(t.e0=function(e){t.showPassword=!t.showPassword}),t.$mp.data=Object.assign({},{$root:{s0:n,s1:i}})},r=!1,o=[];u._withStripped=!0},541:function(t,e,n){"use strict";n.r(e);var i=n(542),u=n.n(i);for(var r in i)["default"].indexOf(r)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(r);e["default"]=u.a},542:function(t,e,n){"use strict";var i=n(4);Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var u=i(n(525)),r={mixins:[u.default],name:"tn-input",props:{value:{type:[String,Number],default:""},type:{type:String,default:"text"},inputAlign:{type:String,default:"left"},placeholder:{type:String,default:""},placeholderStyle:{type:String,default:"color: #AAAAAA"},disabled:{type:Boolean,default:!1},maxLength:{type:Number,default:255},height:{type:Number,default:0},autoHeight:{type:Boolean,default:!0},confirmType:{type:String,default:"done"},customStyle:{type:Object,default:function(){return{}}},fixed:{type:Boolean,default:!1},focus:{type:Boolean,default:!1},passwordIcon:{type:Boolean,default:!0},border:{type:Boolean,default:!1},borderColor:{type:String,default:"#dcdfe6"},selectOpen:{type:Boolean,default:!1},clearable:{type:Boolean,default:!0},cursorSpacing:{type:Number,default:0},selectionStart:{type:Number,default:-1},selectionEnd:{type:Number,default:-1},trim:{type:Boolean,default:!0},showConfirmBar:{type:Boolean,default:!0},showRightIcon:{type:Boolean,default:!1},rightIcon:{type:String,default:""}},computed:{inputStyle:function(){var t={};return t.minHeight=this.height?this.height+"rpx":"textarea"===this.type?this.textareaHeight+"rpx":this.inputHeight+"rpx",t=Object.assign(t,this.customStyle),t},elSelectionStart:function(){return String(this.selectionStart)},elSelectionEnd:function(){return String(this.selectionEnd)}},data:function(){return{defaultValue:this.value,inputHeight:70,textareaHeight:100,validateState:!1,focused:!1,showPassword:!1,lastValue:""}},watch:{value:function(t,e){this.defaultValue=t,t!==e&&"select"===this.type&&this.handleInput({detail:{value:t}})}},created:function(){this.$on("on-form-item-error",this.onFormItemError)},methods:{handleInput:function(t){var e=this,n=t.detail.value;this.trim&&(n=this.$tn.string.trim(n)),this.$emit("input",n),this.defaultValue=n,setTimeout((function(){e.dispatch("tn-form-item","on-form-change",n)}),40)},handleBlur:function(t){var e=this,n=t.detail.value;setTimeout((function(){e.focused=!1}),100),this.$emit("blur",n),setTimeout((function(){e.dispatch("tn-form-item","on-form-blur",n)}),40)},onFormItemError:function(t){this.validateState=t},onFocus:function(t){this.focused=!0,this.$emit("focus")},onConfirm:function(t){this.$emit("confirm",t.detail.value)},onClear:function(t){this.$emit("input","")},inputClick:function(){this.$emit("click")}}};e.default=r},543:function(t,e,n){"use strict";n.r(e);var i=n(544),u=n.n(i);for(var r in i)["default"].indexOf(r)<0&&function(t){n.d(e,t,(fun
|