if("undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(e){const t=this.constructor;return this.then((a=>t.resolve(e()).then((()=>a))),(a=>t.resolve(e()).then((()=>{throw a}))))}),"undefined"!=typeof uni&&uni&&uni.requireGlobal){const e=uni.requireGlobal();ArrayBuffer=e.ArrayBuffer,Int8Array=e.Int8Array,Uint8Array=e.Uint8Array,Uint8ClampedArray=e.Uint8ClampedArray,Int16Array=e.Int16Array,Uint16Array=e.Uint16Array,Int32Array=e.Int32Array,Uint32Array=e.Uint32Array,Float32Array=e.Float32Array,Float64Array=e.Float64Array,BigInt64Array=e.BigInt64Array,BigUint64Array=e.BigUint64Array}uni.restoreGlobal&&uni.restoreGlobal(Vue,weex,plus,setTimeout,clearTimeout,setInterval,clearInterval),function(e){"use strict";const t=(e,t)=>{const a=e.__vccOpts||e;for(const[n,i]of t)a[n]=i;return a};const a=t({name:"page-head",props:{title:{type:String,default:""}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"common-page-head"},[e.createElementVNode("view",{class:"common-page-head-title"},e.toDisplayString(n.title),1)])}]]);function n(e,t,...a){uni.__log__?uni.__log__(e,t,...a):console[e].apply(console,[...a,t])}function i(e,t){return"string"==typeof e?t:e}const o=t({data:()=>({})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"view"}),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-hello-text"}," Flex是Flexible Box的缩写，意为“弹性布局”，用来为盒状模型提供最大的灵活性。当设置display: flex后，继续给view等容器组件设置flex-direction: row或column，就可以在该容器内按行或列排布子组件。uni-app推荐使用flex布局。因为flex布局有利于跨更多平台，尤其是采用原生渲染的平台。 "),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" flex-direction: row "),e.createElementVNode("text",null,"\\n横向布局")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"flex-item uni-bg-red"},"A"),e.createElementVNode("view",{class:"flex-item uni-bg-green"},"B"),e.createElementVNode("view",{class:"flex-item uni-bg-blue"},"C")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" flex-direction: column "),e.createElementVNode("text",null,"\\n纵向布局")]),e.createElementVNode("view",{class:"uni-flex uni-column"},[e.createElementVNode("view",{class:"flex-item flex-item-V uni-bg-red"},"A"),e.createElementVNode("view",{class:"flex-item flex-item-V uni-bg-green"},"B"),e.createElementVNode("view",{class:"flex-item flex-item-V uni-bg-blue"},"C")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 更多布局示例 "),e.createElementVNode("text",null,"\\nflex布局演示")]),e.createElementVNode("view",null,[e.createElementVNode("view",{class:"text"},"纵向布局-自动宽度"),e.createElementVNode("view",{class:"text",style:{width:"300rpx"}},"纵向布局-固定宽度"),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text"},"横向布局-自动宽度"),e.createElementVNode("view",{class:"text"},"横向布局-自动宽度")]),e.createElementVNode("view",{class:"uni-flex uni-row",style:{"-webkit-justify-content":"center","justify-content":"center"}},[e.createElementVNode("view",{class:"text"},"横向布局-居中"),e.createElementVNode("view",{class:"text"},"横向布局-居中")]),e.createElementVNode("view",{class:"uni-flex uni-row",style:{"-webkit-justify-content":"flex-end","justify-content":"flex-end"}},[e.createElementVNode("view",{class:"text"},"横向布局-居右"),e.createElementVNode("view",{class:"text"},"横向布局-居右")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"横向布局-平均分布"),e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"横向布局-平均分布")]),e.createElementVNode("view",{class:"uni-flex uni-row",style:{"-webkit-justify-content":"space-between","justify-content":"space-between"}},[e.createElementVNode("view",{class:"text"},"横向布局-两端对齐"),e.createElementVNode("view",{class:"text"},"横向布局-两端对齐")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text",style:{width:"200rpx"}},"固定宽度"),e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"自动占满余量")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text",style:{width:"200rpx"}},"固定宽度"),e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"自动占满"),e.createElementVNode("view",{class:"text",style:{width:"200rpx"}},"固定宽度")]),e.createElementVNode("view",{class:"uni-flex uni-row",style:{"-webkit-flex-wrap":"wrap","flex-wrap":"wrap"}},[e.createElementVNode("view",{class:"text",style:{width:"280rpx"}},"一行显示不全,wrap折行"),e.createElementVNode("view",{class:"text",style:{width:"280rpx"}},"一行显示不全,wrap折行"),e.createElementVNode("view",{class:"text",style:{width:"280rpx"}},"一行显示不全,wrap折行")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text uni-flex",style:{"-webkit-flex":"1",flex:"1",height:"200rpx","-webkit-justify-content":"center","justify-content":"center","-webkit-align-items":"flex-start","align-items":"flex-start"}},[e.createElementVNode("text",null,"垂直居顶")]),e.createElementVNode("view",{class:"text uni-flex",style:{"-webkit-flex":"1",flex:"1",height:"200rpx","-webkit-justify-content":"center","justify-content":"center","-webkit-align-items":"center","align-items":"center"}},[e.createElementVNode("text",null,"垂直居中")]),e.createElementVNode("view",{class:"text uni-flex",style:{"-webkit-flex":"1",flex:"1",height:"200rpx","-webkit-justify-content":"center","justify-content":"center","-webkit-align-items":"flex-end","align-items":"flex-end"}},[e.createElementVNode("text",null,"垂直居底")])])]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 组合示例 "),e.createElementVNode("text",null,"\\nflex布局演示")]),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text uni-flex",style:{width:"200rpx",height:"220rpx","-webkit-justify-content":"center","justify-content":"center","-webkit-align-items":"center","align-items":"center"}},[e.createElementVNode("image",{src:"/static/plus.png",style:{width:"150rpx",height:"150rpx"}})]),e.createElementVNode("view",{class:"uni-flex uni-column",style:{"-webkit-flex":"1",flex:"1","-webkit-justify-content":"space-between","justify-content":"space-between"}},[e.createElementVNode("view",{class:"text",style:{height:"120rpx","text-align":"left","padding-left":"20rpx","padding-top":"10rpx"}}," 文字居左，留出左间距 "),e.createElementVNode("view",{class:"uni-flex uni-row"},[e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"剩余数量"),e.createElementVNode("view",{class:"text",style:{"-webkit-flex":"1",flex:"1"}},"立即购买")])])])])])}]]),s={data:()=>({scrollTop:0,old:{scrollTop:0}}),methods:{upper:function(e){n("log","at pages/component/scroll-view/scroll-view.vue:48",e)},lower:function(e){n("log","at pages/component/scroll-view/scroll-view.vue:51",e)},scroll:function(e){n("log","at pages/component/scroll-view/scroll-view.vue:54",e),this.old.scrollTop=e.detail.scrollTop},goTop:function(e){this.scrollTop=this.old.scrollTop,this.$nextTick((function(){this.scrollTop=0})),uni.showToast({icon:"none",title:"纵向滚动 scrollTop 值已被修改为 0"})}}};const l=t(s,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"scroll-view,区域滚动视图"}),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" Vertical Scroll "),e.createElementVNode("text",null,"\\n纵向滚动")]),e.createElementVNode("view",null,[e.createElementVNode("scroll-view",{"scroll-top":l.scrollTop,"scroll-y":"true",class:"scroll-Y",onScrolltoupper:n[0]||(n[0]=(...e)=>r.upper&&r.upper(...e)),onScrolltolower:n[1]||(n[1]=(...e)=>r.lower&&r.lower(...e)),onScroll:n[2]||(n[2]=(...e)=>r.scroll&&r.scroll(...e))},[e.createElementVNode("view",{id:"demo1",class:"scroll-view-item uni-bg-red"},"A"),e.createElementVNode("view",{id:"demo2",class:"scroll-view-item uni-bg-green"},"B"),e.createElementVNode("view",{id:"demo3",class:"scroll-view-item uni-bg-blue"},"C")],40,["scroll-top"])]),e.createElementVNode("view",{onClick:n[3]||(n[3]=(...e)=>r.goTop&&r.goTop(...e)),class:"uni-link uni-center uni-common-mt"}," 点击这里返回顶部 "),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" Horizontal Scroll "),e.createElementVNode("text",null,"\\n横向滚动")]),e.createElementVNode("view",null,[e.createElementVNode("scroll-view",{class:"scroll-view_H","scroll-x":"true",onScroll:n[4]||(n[4]=(...e)=>r.scroll&&r.scroll(...e)),"scroll-left":"120"},[e.createElementVNode("view",{id:"demo1",class:"scroll-view-item_H uni-bg-red"},"A"),e.createElementVNode("view",{id:"demo2",class:"scroll-view-item_H uni-bg-green"},"B"),e.createElementVNode("view",{id:"demo3",class:"scroll-view-item_H uni-bg-blue"},"C")],32)]),e.createElementVNode("view",{class:"uni-common-pb"})])])}]]),r={data:()=>({background:["color1","color2","color3"],indicatorDots:!0,autoplay:!0,interval:2e3,duration:500}),methods:{changeIndicatorDots(e){this.indicatorDots=!this.indicatorDots},changeAutoplay(e){this.autoplay=!this.autoplay},intervalChange(e){this.interval=e.detail.value},durationChange(e){this.duration=e.detail.value}}};const c=t(r,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"swiper,可滑动视图"}),e.createElementVNode("view",{class:"uni-margin-wrap"},[e.createElementVNode("swiper",{class:"swiper",circular:"","indicator-dots":l.indicatorDots,autoplay:l.autoplay,interval:l.interval,duration:l.duration},[e.createElementVNode("swiper-item",null,[e.createElementVNode("view",{class:"swiper-item uni-bg-red"},"A")]),e.createElementVNode("swiper-item",null,[e.createElementVNode("view",{class:"swiper-item uni-bg-green"},"B")]),e.createElementVNode("swiper-item",null,[e.createElementVNode("view",{class:"swiper-item uni-bg-blue"},"C")])],8,["indicator-dots","autoplay","interval","duration"])]),e.createElementVNode("view",{class:"swiper-list"},[e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("view",{class:"uni-list-cell-db"},"指示点"),e.createElementVNode("switch",{checked:l.indicatorDots,onChange:n[0]||(n[0]=(...e)=>r.changeIndicatorDots&&r.changeIndicatorDots(...e))},null,40,["checked"])]),e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("view",{class:"uni-list-cell-db"},"自动播放"),e.createElementVNode("switch",{checked:l.autoplay,onChange:n[1]||(n[1]=(...e)=>r.changeAutoplay&&r.changeAutoplay(...e))},null,40,["checked"])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("text",null,"幻灯片切换时长(ms)"),e.createElementVNode("text",{class:"info"},e.toDisplayString(l.duration),1)]),e.createElementVNode("slider",{onChange:n[2]||(n[2]=(...e)=>r.durationChange&&r.durationChange(...e)),value:l.duration,min:"500",max:"2000"},null,40,["value"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("text",null,"自动播放间隔时长(ms)"),e.createElementVNode("text",{class:"info"},e.toDisplayString(l.interval),1)]),e.createElementVNode("slider",{onChange:n[3]||(n[3]=(...e)=>r.intervalChange&&r.intervalChange(...e)),value:l.interval,min:"2000",max:"10000"},null,40,["value"])])])}]]),d={data:()=>({x:0,y:0,scale:2,old:{x:0,y:0,scale:2}}),methods:{tap:function(e){this.x=this.old.x,this.y=this.old.y,this.$nextTick((function(){this.x=30,this.y=30}))},tap2(){this.scale=this.old.scale,this.scale=this.old.scale,this.$nextTick((function(){this.scale=3}))},onChange:function(e){this.old.x=e.detail.x,this.old.y=e.detail.y},onScale:function(e){this.old.scale=e.detail.scale}}};const u=t(d,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"page-body"},[e.createVNode(c,{title:"movable-view,可拖动视图"}),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 1 "),e.createElementVNode("text",null,"\\nmovable-view 区域小于 movable-area")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{x:l.x,y:l.y,direction:"all",onChange:n[0]||(n[0]=(...e)=>r.onChange&&r.onChange(...e))},"text",40,["x","y"])]),e.createElementVNode("view",{onClick:n[1]||(n[1]=(...e)=>r.tap&&r.tap(...e)),class:"uni-link uni-center uni-common-mt"}," 点击这里移动至 (30px, 30px) "),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 2 "),e.createElementVNode("text",null,"\\nmovable-view区域大于movable-area")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{class:"max",direction:"all"},"text")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 3 "),e.createElementVNode("text",null,"\\n只可以横向移动")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{direction:"horizontal"},"text")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 4 "),e.createElementVNode("text",null,"\\n只可以纵向移动")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{direction:"vertical"},"text")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 5 "),e.createElementVNode("text",null,"\\n可超出边界")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{direction:"all","out-of-bounds":""},"text")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 6 "),e.createElementVNode("text",null,"\\n带有惯性")]),e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{direction:"all",inertia:""},"text")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例 7 "),e.createElementVNode("text",null,"\\n可放缩")]),e.createElementVNode("movable-area",{"scale-area":""},[e.createElementVNode("movable-view",{direction:"all",onScale:n[2]||(n[2]=(...e)=>r.onScale&&r.onScale(...e)),scale:"","scale-min":"0.5","scale-max":"4","scale-value":l.scale},"text",40,["scale-value"])]),e.createElementVNode("view",{onClick:n[3]||(n[3]=(...e)=>r.tap2&&r.tap2(...e)),class:"uni-link uni-center uni-common-mt",style:{"padding-bottom":"80rpx"}}," 点击这里放大3倍 ")])])}]]);const h=t({data:()=>({title:"text",texts:["HBuilder，400万开发者选择的IDE","MUI，轻巧、漂亮的前端开源框架","wap2app，M站快速转换原生体验的App","5+Runtime，为HTML5插上原生的翅膀","HBuilderX，轻巧、极速，极客编辑器","uni-app，终极跨平台方案","HBuilder，400万开发者选择的IDE","MUI，轻巧、漂亮的前端开源框架","wap2app，M站快速转换原生体验的App","5+Runtime，为HTML5插上原生的翅膀","HBuilderX，轻巧、极速，极客编辑器","uni-app，终极跨平台方案","......"],text:"",canAdd:!0,canRemove:!1,extraLine:[]}),methods:{add:function(e){this.extraLine.push(this.texts[this.extraLine.length%12]),this.text=this.extraLine.join("\n"),this.canAdd=this.extraLine.length<12,this.canRemove=this.extraLine.length>0},remove:function(e){this.extraLine.length>0&&(this.extraLine.pop(),this.text=this.extraLine.join("\n"),this.canAdd=this.extraLine.length<12,this.canRemove=this.extraLine.length>0)}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"text-box","scroll-y":"true"},[e.createElementVNode("text",null,e.toDisplayString(l.text),1)]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",disabled:!l.canAdd,onClick:n[0]||(n[0]=(...e)=>r.add&&r.add(...e))},"add line",8,["disabled"]),e.createElementVNode("button",{type:"warn",disabled:!l.canRemove,onClick:n[1]||(n[1]=(...e)=>r.remove&&r.remove(...e))},"remove line",8,["disabled"])])])])}]]);const p=t({data:()=>({title:"rich-text",nodes:[{name:"div",attrs:{class:"div-class",style:"line-height: 60px; color: red; text-align:center;"},children:[{type:"text",text:"Hello&nbsp;uni-app!"}]}],strings:'<div style="text-align:center;"><img src="https://web-assets.dcloud.net.cn/unidoc/zh/uni@2x.png"/></div>'})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"content"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 数组类型 "),e.createElementVNode("text",null,"\\nnodes属性为Array")]),e.createElementVNode("view",{class:"uni-common-mt",style:{background:"#FFF",padding:"20rpx"}},[e.createElementVNode("rich-text",{nodes:l.nodes},null,8,["nodes"])]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 字符串类型 "),e.createElementVNode("text",null,"\\nnodes属性为String")]),e.createElementVNode("view",{class:"uni-common-mt",style:{background:"#FFF",padding:"20rpx"}},[e.createElementVNode("rich-text",{nodes:l.strings},null,8,["nodes"])])])])}]]),m=[{font_class:"arrow-down",unicode:""},{font_class:"arrow-left",unicode:""},{font_class:"arrow-right",unicode:""},{font_class:"arrow-up",unicode:""},{font_class:"auth",unicode:""},{font_class:"auth-filled",unicode:""},{font_class:"back",unicode:""},{font_class:"bars",unicode:""},{font_class:"calendar",unicode:""},{font_class:"calendar-filled",unicode:""},{font_class:"camera",unicode:""},{font_class:"camera-filled",unicode:""},{font_class:"cart",unicode:""},{font_class:"cart-filled",unicode:""},{font_class:"chat",unicode:""},{font_class:"chat-filled",unicode:""},{font_class:"chatboxes",unicode:""},{font_class:"chatboxes-filled",unicode:""},{font_class:"chatbubble",unicode:""},{font_class:"chatbubble-filled",unicode:""},{font_class:"checkbox",unicode:""},{font_class:"checkbox-filled",unicode:""},{font_class:"checkmarkempty",unicode:""},{font_class:"circle",unicode:""},{font_class:"circle-filled",unicode:""},{font_class:"clear",unicode:""},{font_class:"close",unicode:""},{font_class:"closeempty",unicode:""},{font_class:"cloud-download",unicode:""},{font_class:"cloud-download-filled",unicode:""},{font_class:"cloud-upload",unicode:""},{font_class:"cloud-upload-filled",unicode:""},{font_class:"color",unicode:""},{font_class:"color-filled",unicode:""},{font_class:"compose",unicode:""},{font_class:"contact",unicode:""},{font_class:"contact-filled",unicode:""},{font_class:"down",unicode:""},{font_class:"bottom",unicode:""},{font_class:"download",unicode:""},{font_class:"download-filled",unicode:""},{font_class:"email",unicode:""},{font_class:"email-filled",unicode:""},{font_class:"eye",unicode:""},{font_class:"eye-filled",unicode:""},{font_class:"eye-slash",unicode:""},{font_class:"eye-slash-filled",unicode:""},{font_class:"fire",unicode:""},{font_class:"fire-filled",unicode:""},{font_class:"flag",unicode:""},{font_class:"flag-filled",unicode:""},{font_class:"folder-add",unicode:""},{font_class:"folder-add-filled",unicode:""},{font_class:"font",unicode:""},{font_class:"forward",unicode:""},{font_class:"gear",unicode:""},{font_class:"gear-filled",unicode:""},{font_class:"gift",unicode:""},{font_class:"gift-filled",unicode:""},{font_class:"hand-down",unicode:""},{font_class:"hand-down-filled",unicode:""},{font_class:"hand-up",unicode:""},{font_class:"hand-up-filled",unicode:""},{font_class:"headphones",unicode:""},{font_class:"heart",unicode:""},{font_class:"heart-filled",unicode:""},{font_class:"help",unicode:""},{font_class:"help-filled",unicode:""},{font_class:"home",unicode:""},{font_class:"home-filled",unicode:""},{font_class:"image",unicode:""},{font_class:"image-filled",unicode:""},{font_class:"images",unicode:""},{font_class:"images-filled",unicode:""},{font_class:"info",unicode:""},{font_class:"info-filled",unicode:""},{font_class:"left",unicode:""},{font_class:"link",unicode:""},{font_class:"list",unicode:""},{font_class:"location",unicode:""},{font_class:"location-filled",unicode:""},{font_class:"locked",unicode:""},{font_class:"locked-filled",unicode:""},{font_class:"loop",unicode:""},{font_class:"mail-open",unicode:""},{font_class:"mail-open-filled",unicode:""},{font_class:"map",unicode:""},{font_class:"map-filled",unicode:""},{font_class:"map-pin",unicode:""},{font_class:"map-pin-ellipse",unicode:""},{font_class:"medal",unicode:""},{font_class:"medal-filled",unicode:""},{font_class:"mic",unicode:""},{font_class:"mic-filled",unicode:""},{font_class:"micoff",unicode:""},{font_class:"micoff-filled",unicode:""},{font_class:"minus",unicode:""},{font_class:"minus-filled",unicode:""},{font_class:"more",unicode:""},{font_class:"more-filled",unicode:""},{font_class:"navigate",unicode:""},{font_class:"navigate-filled",unicode:""},{font_class:"notification",unicode:""},{font_class:"notification-filled",unicode:""},{font_class:"paperclip",unicode:""},{font_class:"paperplane",unicode:""},{font_class:"paperplane-filled",unicode:""},{font_class:"person",unicode:""},{font_class:"person-filled",unicode:""},{font_class:"personadd",unicode:""},{font_class:"personadd-filled",unicode:""},{font_class:"personadd-filled-copy",unicode:""},{font_class:"phone",unicode:""},{font_class:"phone-filled",unicode:""},{font_class:"plus",unicode:""},{font_class:"plus-filled",unicode:""},{font_class:"plusempty",unicode:""},{font_class:"pulldown",unicode:""},{font_class:"pyq",unicode:""},{font_class:"qq",unicode:""},{font_class:"redo",unicode:""},{font_class:"redo-filled",unicode:""},{font_class:"refresh",unicode:""},{font_class:"refresh-filled",unicode:""},{font_class:"refreshempty",unicode:""},{font_class:"reload",unicode:""},{font_class:"right",unicode:""},{font_class:"scan",unicode:""},{font_class:"search",unicode:""},{font_class:"settings",unicode:""},{font_class:"settings-filled",unicode:""},{font_class:"shop",unicode:""},{font_class:"shop-filled",unicode:""},{font_class:"smallcircle",unicode:""},{font_class:"smallcircle-filled",unicode:""},{font_class:"sound",unicode:""},{font_class:"sound-filled",unicode:""},{font_class:"spinner-cycle",unicode:""},{font_class:"staff",unicode:""},{font_class:"staff-filled",unicode:""},{font_class:"star",unicode:""},{font_class:"star-filled",unicode:""},{font_class:"starhalf",unicode:""},{font_class:"trash",unicode:""},{font_class:"trash-filled",unicode:""},{font_class:"tune",unicode:""},{font_class:"tune-filled",unicode:""},{font_class:"undo",unicode:""},{font_class:"undo-filled",unicode:""},{font_class:"up",unicode:""},{font_class:"top",unicode:""},{font_class:"upload",unicode:""},{font_class:"upload-filled",unicode:""},{font_class:"videocam",unicode:""},{font_class:"videocam-filled",unicode:""},{font_class:"vip",unicode:""},{font_class:"vip-filled",unicode:""},{font_class:"wallet",unicode:""},{font_class:"wallet-filled",unicode:""},{font_class:"weibo",unicode:""},{font_class:"weixin",unicode:""}];const g=t({name:"UniIcons",emits:["click"],props:{type:{type:String,default:""},color:{type:String,default:"#333333"},size:{type:[Number,String],default:16},customPrefix:{type:String,default:""},fontFamily:{type:String,default:""}},data:()=>({icons:m}),computed:{unicode(){let e=this.icons.find((e=>e.font_class===this.type));return e?e.unicode:""},iconSize(){return"number"==typeof(e=this.size)||/^[0-9]*$/g.test(e)?e+"px":e;var e},styleObj(){return""!==this.fontFamily?`color: ${this.color}; font-size: ${this.iconSize}; font-family: ${this.fontFamily};`:`color: ${this.color}; font-size: ${this.iconSize};`}},methods:{_onClick(){this.$emit("click")}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("text",{style:e.normalizeStyle(s.styleObj),class:e.normalizeClass(["uni-icons",["uniui-"+n.type,n.customPrefix,n.customPrefix?n.type:""]]),onClick:a[0]||(a[0]=(...e)=>s._onClick&&s._onClick(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-5610c8db"]]);const f=t({data:()=>({title:"progress",pgList:[0,0,0,0]}),methods:{setProgress(){this.pgList=[20,40,60,80]},clearProgress(){this.pgList=[0,0,0,0]}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"progress-box"},[e.createElementVNode("progress",{percent:l.pgList[0],"show-info":"","stroke-width":"3"},null,8,["percent"])]),e.createElementVNode("view",{class:"progress-box"},[e.createElementVNode("progress",{percent:l.pgList[1],"stroke-width":"3"},null,8,["percent"]),e.createVNode(d,{type:"close",class:"progress-cancel",color:"#dd524d"})]),e.createElementVNode("view",{class:"progress-box"},[e.createElementVNode("progress",{percent:l.pgList[2],"stroke-width":"3"},null,8,["percent"])]),e.createElementVNode("view",{class:"progress-box"},[e.createElementVNode("progress",{percent:l.pgList[3],activeColor:"#10AEFF","stroke-width":"3"},null,8,["percent"])]),e.createElementVNode("view",{class:"progress-control"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.setProgress&&r.setProgress(...e))},"设置进度"),e.createElementVNode("button",{type:"warn",onClick:n[1]||(n[1]=(...e)=>r.clearProgress&&r.clearProgress(...e))},"清除进度")])])])}]]);const y=t({data:()=>({title:"button",loading:!1}),onLoad(){this._timer=null},onShow(){this.clearTimer(),this._timer=setTimeout((()=>{this.loading=!0}),300)},onUnload(){this.clearTimer(),this.loading=!1},methods:{openTypeError(e){n("error","at pages/component/button/button.vue:56","open-type error:",e)},clearTimer(){null!=this._timer&&clearTimeout(this._timer)}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("button",{type:"primary"},"页面主操作 Normal"),e.createElementVNode("button",{type:"primary",loading:l.loading},"页面主操作 Loading",8,["loading"]),e.createElementVNode("button",{type:"primary",disabled:"true"},"页面主操作 Disabled"),e.createElementVNode("button",{type:"default"},"页面次要操作 Normal"),e.createElementVNode("button",{type:"default",disabled:"true"},"页面次要操作 Disabled"),e.createElementVNode("button",{type:"warn"},"警告类操作 Normal"),e.createElementVNode("button",{type:"warn",disabled:"true"},"警告类操作 Disabled"),e.createElementVNode("view",{class:"button-sp-area"},[e.createElementVNode("button",{type:"primary",plain:"true"},"按钮"),e.createElementVNode("button",{type:"primary",disabled:"true",plain:"true"},"不可点击的按钮"),e.createElementVNode("button",{type:"default",plain:"true"},"按钮"),e.createElementVNode("button",{type:"default",disabled:"true",plain:"true"},"按钮"),e.createElementVNode("button",{class:"mini-btn",type:"primary",size:"mini"},"按钮"),e.createElementVNode("button",{class:"mini-btn",type:"default",size:"mini"},"按钮"),e.createElementVNode("button",{class:"mini-btn",type:"warn",size:"mini"},"按钮")])])])}]]),v={data:()=>({title:"checkbox 复选框",items:[{value:"USA",name:"美国"},{value:"CHN",name:"中国",checked:"true"},{value:"BRA",name:"巴西"},{value:"JPN",name:"日本"},{value:"ENG",name:"英国"},{value:"FRA",name:"法国"}]}),methods:{checkboxChange:function(e){for(var t=this.items,a=e.detail.value,n=0,i=t.length;n<i;++n){const e=t[n];a.indexOf(e.value)>=0?this.$set(e,"checked",!0):this.$set(e,"checked",!1)}}}};const w=t(v,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},"默认样式"),e.createElementVNode("view",null,[e.createElementVNode("checkbox-group",null,[e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"cb1",checked:"true"}),e.createTextVNode("选中 ")]),e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"cb"}),e.createTextVNode("未选中 ")])])]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},"不同颜色和尺寸的checkbox"),e.createElementVNode("view",null,[e.createElementVNode("checkbox-group",null,[e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"cb1",checked:"true",color:"#FFCC33",style:{transform:"scale(0.7)"}}),e.createTextVNode("选中 ")]),e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"cb",color:"#FFCC33",style:{transform:"scale(0.7)"}}),e.createTextVNode("未选中 ")])])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 推荐展示样式 "),e.createElementVNode("text",null,"\\n使用 uni-list 布局")])]),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("checkbox-group",{onChange:n[0]||(n[0]=(...e)=>r.checkboxChange&&r.checkboxChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.items,(t=>(e.openBlock(),e.createElementBlock("label",{class:"uni-list-cell uni-list-cell-pd",key:t.value},[e.createElementVNode("view",null,[e.createElementVNode("checkbox",{value:t.value,checked:t.checked},null,8,["value","checked"])]),e.createElementVNode("view",null,e.toDisplayString(t.name),1)])))),128))],32)])])}]]),b={error:"",check:function(e,t){for(var a=0;a<t.length;a++){if(!t[a].checkType)return!0;if(!t[a].name)return!0;if(!t[a].errorMsg)return!0;if(!e[t[a].name])return this.error=t[a].errorMsg,!1;switch(t[a].checkType){case"string":if(!new RegExp("^.{"+t[a].checkRule+"}$").test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"int":if(!new RegExp("^(-[1-9]|[1-9])[0-9]{"+t[a].checkRule+"}$").test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"between":if(!this.isNumber(e[t[a].name]))return this.error=t[a].errorMsg,!1;if((n=t[a].checkRule.split(","))[0]=Number(n[0]),n[1]=Number(n[1]),e[t[a].name]>n[1]||e[t[a].name]<n[0])return this.error=t[a].errorMsg,!1;break;case"betweenD":if(!/^-?[1-9][0-9]?$/.test(e[t[a].name]))return this.error=t[a].errorMsg,!1;if((n=t[a].checkRule.split(","))[0]=Number(n[0]),n[1]=Number(n[1]),e[t[a].name]>n[1]||e[t[a].name]<n[0])return this.error=t[a].errorMsg,!1;break;case"betweenF":var n;if(!/^-?[0-9][0-9]?.+[0-9]+$/.test(e[t[a].name]))return this.error=t[a].errorMsg,!1;if((n=t[a].checkRule.split(","))[0]=Number(n[0]),n[1]=Number(n[1]),e[t[a].name]>n[1]||e[t[a].name]<n[0])return this.error=t[a].errorMsg,!1;break;case"same":if(e[t[a].name]!=t[a].checkRule)return this.error=t[a].errorMsg,!1;break;case"notsame":if(e[t[a].name]==t[a].checkRule)return this.error=t[a].errorMsg,!1;break;case"email":if(!/^\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/.test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"phoneno":if(!/^1[0-9]{10,10}$/.test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"zipcode":if(!/^[0-9]{6}$/.test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"reg":if(!new RegExp(t[a].checkRule).test(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"in":if(-1==t[a].checkRule.indexOf(e[t[a].name]))return this.error=t[a].errorMsg,!1;break;case"notnull":if(null==e[t[a].name]||e[t[a].name].length<1)return this.error=t[a].errorMsg,!1}}return!0},isNumber:function(e){return/^-?[1-9][0-9]?.?[0-9]*$/.test(e)}},k={data:()=>({}),methods:{formSubmit:function(e){n("log","at pages/component/form/form.vue:59","form发生了submit事件，携带数据为："+JSON.stringify(e.detail.value));var t=e.detail.value;b.check(t,[{name:"nickname",checkType:"string",checkRule:"1,3",errorMsg:"姓名应为1-3个字符"},{name:"gender",checkType:"in",checkRule:"男,女",errorMsg:"请选择性别"},{name:"loves",checkType:"notnull",checkRule:"",errorMsg:"请选择爱好"}])?uni.showToast({title:"验证通过!",icon:"none"}):uni.showToast({title:b.error,icon:"none"})},formReset:function(e){n("log","at pages/component/form/form.vue:76","清空数据")}}};const x=t(k,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"form"}),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("form",{onSubmit:n[0]||(n[0]=(...e)=>r.formSubmit&&r.formSubmit(...e)),onReset:n[1]||(n[1]=(...e)=>r.formReset&&r.formReset(...e))},[e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"姓名"),e.createElementVNode("input",{class:"uni-input",name:"nickname",placeholder:"请输入姓名"})]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"性别"),e.createElementVNode("radio-group",{name:"gender"},[e.createElementVNode("label",null,[e.createElementVNode("radio",{value:"男"}),e.createElementVNode("text",null,"男")]),e.createElementVNode("label",null,[e.createElementVNode("radio",{value:"女"}),e.createElementVNode("text",null,"女")])])]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"爱好"),e.createElementVNode("checkbox-group",{name:"loves"},[e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"读书"}),e.createElementVNode("text",null,"读书")]),e.createElementVNode("label",null,[e.createElementVNode("checkbox",{value:"写字"}),e.createElementVNode("text",null,"写字")])])]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"年龄"),e.createElementVNode("slider",{value:"20",name:"age","show-value":""})]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"保留选项"),e.createElementVNode("view",null,[e.createElementVNode("switch",{name:"switch"})])]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{"form-type":"submit"},"Submit"),e.createElementVNode("button",{type:"default","form-type":"reset"},"Reset")])],32)])])}]]),V={data:()=>({title:"label",checkboxItems:[{name:"USA",value:"美国"},{name:"CHN",value:"中国",checked:"true"}],radioItems:[{name:"USA",value:"美国"},{name:"CHN",value:"中国",checked:"true"}],hidden:!1}),methods:{checkboxChange:function(e){n("log","at pages/component/label/label.vue:80",e.detail.value)},radioChange:function(e){n("log","at pages/component/label/label.vue:85",e.detail.value)}}};const N=t(V,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"表单组件在label内"),e.createElementVNode("checkbox-group",{class:"uni-list",onChange:n[0]||(n[0]=(...e)=>r.checkboxChange&&r.checkboxChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.checkboxItems,(t=>(e.openBlock(),e.createElementBlock("label",{class:"uni-list-cell uni-list-cell-pd",key:t.name},[e.createElementVNode("view",null,[e.createElementVNode("checkbox",{value:t.name,checked:t.checked},null,8,["value","checked"])]),e.createElementVNode("view",null,e.toDisplayString(t.value),1)])))),128))],32)]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"label用for标识表单组件"),e.createElementVNode("radio-group",{class:"uni-list",onChange:n[1]||(n[1]=(...e)=>r.radioChange&&r.radioChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.radioItems,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-list-cell uni-list-cell-pd",key:a},[e.createElementVNode("view",null,[e.createElementVNode("radio",{id:t.name,value:t.name,checked:t.checked},null,8,["id","value","checked"])]),e.createElementVNode("label",{class:"label-2-text",for:t.name},[e.createElementVNode("text",null,e.toDisplayString(t.value),1)],8,["for"])])))),128))],32)]),e.createElementVNode("view",{class:"uni-form-item uni-column"},[e.createElementVNode("view",{class:"title"},"label内有多个时选中第一个"),e.createElementVNode("checkbox-group",{class:"uni-list",onChange:n[2]||(n[2]=(...e)=>r.checkboxChange&&r.checkboxChange(...e))},[e.createElementVNode("label",{class:"label-3"},[e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("checkbox",{class:"checkbox-3"},"选项一")]),e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("checkbox",{class:"checkbox-3"},"选项二")]),e.createElementVNode("view",{class:"uni-link uni-center",style:{"margin-top":"20rpx"}},"点击该label下的文字默认选中第一个checkbox")])],32)])])])}]]);function E(e){const t=new Date;let a=t.getFullYear(),n=t.getMonth()+1,i=t.getDate();return"start"===e?a-=10:"end"===e&&(a+=10),n=n>9?n:"0"+n,i=i>9?i:"0"+i,`${a}-${n}-${i}`}const C={data:()=>({title:"picker",array:[{name:"中国"},{name:"美国"},{name:"巴西"},{name:"日本"}],index:0,multiArray:[["亚洲","欧洲"],["中国","日本"],["北京","上海","广州"]],multiIndex:[0,0,0],date:E({format:!0}),startDate:E("start"),endDate:E("end"),time:"12:01"}),methods:{bindPickerChange:function(e){n("log","at pages/component/picker/picker.vue:110","picker发送选择改变，携带值为："+e.detail.value),this.index=e.detail.value},bindMultiPickerColumnChange:function(e){switch(n("log","at pages/component/picker/picker.vue:114","修改的列为："+e.detail.column+"，值为："+e.detail.value),this.multiIndex[e.detail.column]=e.detail.value,e.detail.column){case 0:switch(this.multiIndex[0]){case 0:this.multiArray[1]=["中国","日本"],this.multiArray[2]=["北京","上海","广州"];break;case 1:this.multiArray[1]=["英国","法国"],this.multiArray[2]=["伦敦","曼彻斯特"]}this.multiIndex.splice(1,1,0),this.multiIndex.splice(2,1,0);break;case 1:switch(this.multiIndex[0]){case 0:switch(this.multiIndex[1]){case 0:this.multiArray[2]=["北京","上海","广州"];break;case 1:this.multiArray[2]=["东京","北海道"]}break;case 1:switch(this.multiIndex[1]){case 0:this.multiArray[2]=["伦敦","曼彻斯特"];break;case 1:this.multiArray[2]=["巴黎","马赛"]}}this.multiIndex.splice(2,1,0)}this.$forceUpdate()},bindDateChange:function(e){this.date=e.detail.value},bindTimeChange:function(e){this.time=e.detail.value}}};const _=t(C,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"普通选择器"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"}," 当前选择 "),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("picker",{onChange:n[0]||(n[0]=(...e)=>r.bindPickerChange&&r.bindPickerChange(...e)),value:l.index,range:l.array,"range-key":"name"},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.array[l.index].name),1)],40,["value","range"])])])]),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"多列选择器"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"}," 当前选择 "),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("picker",{mode:"multiSelector",onColumnchange:n[1]||(n[1]=(...e)=>r.bindMultiPickerColumnChange&&r.bindMultiPickerColumnChange(...e)),value:l.multiIndex,range:l.multiArray},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.multiArray[0][l.multiIndex[0]])+"，"+e.toDisplayString(l.multiArray[1][l.multiIndex[1]])+"，"+e.toDisplayString(l.multiArray[2][l.multiIndex[2]]),1)],40,["value","range"])])])]),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"时间选择器"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"}," 当前选择 "),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("picker",{mode:"time",value:l.time,start:"09:01",end:"21:01",onChange:n[2]||(n[2]=(...e)=>r.bindTimeChange&&r.bindTimeChange(...e))},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.time),1)],40,["value"])])])]),e.createElementVNode("view",{class:"uni-picker-tips"}," 注：选择 09:01 ~ 21:01 之间的时间, 不在区间内不能选中 "),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"日期选择器"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"}," 当前选择 "),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("picker",{mode:"date",value:l.date,start:l.startDate,end:l.endDate,onChange:n[3]||(n[3]=(...e)=>r.bindDateChange&&r.bindDateChange(...e))},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.date),1)],40,["value","start","end"])])])]),e.createElementVNode("view",{class:"uni-picker-tips"}," 注：选择当前时间 ±10 年之间的时间, 不在区间内不能选中 ")])}]]),S={data(){const e=new Date,t=[],a=e.getFullYear(),n=[],i=e.getMonth()+1,o=[],s=e.getDate();for(let l=1990;l<=e.getFullYear();l++)t.push(l);for(let l=1;l<=12;l++)n.push(l);for(let l=1;l<=31;l++)o.push(l);return{title:"picker-view",years:t,year:a,months:n,month:i,days:o,day:s,value:[9999,i-1,s-1],visible:!0,indicatorStyle:"height: 50px;",maskStyle:""}},methods:{bindChange(e){const t=e.detail.value;this.year=this.years[t[0]],this.month=this.months[t[1]],this.day=this.days[t[2]]}}};const T=t(S,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"}," 日期："+e.toDisplayString(l.year)+"年"+e.toDisplayString(l.month)+"月"+e.toDisplayString(l.day)+"日 ",1)]),l.visible?(e.openBlock(),e.createElementBlock("picker-view",{key:0,"indicator-style":l.indicatorStyle,"mask-style":l.maskStyle,value:l.value,onChange:n[0]||(n[0]=(...e)=>r.bindChange&&r.bindChange(...e))},[e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.years,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"item",key:a},e.toDisplayString(t)+"年",1)))),128))]),e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.months,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"item",key:a},e.toDisplayString(t)+"月",1)))),128))]),e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.days,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"item",key:a},e.toDisplayString(t)+"日",1)))),128))])],40,["indicator-style","mask-style","value"])):e.createCommentVNode("",!0)])}]]);const B=t({data:()=>({title:"radio 单选框",items:[{value:"USA",name:"美国"},{value:"CHN",name:"中国",checked:"true"},{value:"BRA",name:"巴西"},{value:"JPN",name:"日本"},{value:"ENG",name:"英国"},{value:"FRA",name:"法国"}],current:0}),methods:{radioChange(e){for(let t=0;t<this.items.length;t++)if(this.items[t].value===e.detail.value){this.current=t;break}}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"},"默认样式"),e.createElementVNode("view",null,[e.createElementVNode("label",{class:"radio",style:{"margin-right":"30rpx"}},[e.createElementVNode("radio",{value:"r1",checked:"true"}),e.createTextVNode("选中 ")]),e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"r2"}),e.createTextVNode("未选中 ")])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"},"不同颜色和尺寸的radio"),e.createElementVNode("view",null,[e.createElementVNode("label",{class:"radio",style:{"margin-right":"30rpx"}},[e.createElementVNode("radio",{value:"r1",checked:"true",color:"#FFCC33",style:{transform:"scale(0.7)"}}),e.createTextVNode("选中 ")]),e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"r2",color:"#FFCC33",style:{transform:"scale(0.7)"}}),e.createTextVNode("未选中 ")])])]),e.createElementVNode("view",{class:"uni-title uni-common-mt uni-common-pl"},"推荐展示样式"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("radio-group",{onChange:n[0]||(n[0]=(...e)=>r.radioChange&&r.radioChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.items,((t,a)=>(e.openBlock(),e.createElementBlock("label",{class:"uni-list-cell uni-list-cell-pd",key:t.value},[e.createElementVNode("view",null,[e.createElementVNode("radio",{value:t.value,checked:a===l.current},null,8,["value","checked"])]),e.createElementVNode("view",null,e.toDisplayString(t.name),1)])))),128))],32)])])}]]),D={data:()=>({title:"slider 滑块"}),methods:{sliderChange(e){n("log","at pages/component/slider/slider.vue:36","value 发生变化："+e.detail.value)}}};const I=t(D,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},"显示当前value"),e.createElementVNode("view",null,[e.createElementVNode("slider",{value:"50",onChange:n[0]||(n[0]=(...e)=>r.sliderChange&&r.sliderChange(...e)),"show-value":""},null,32)]),e.createElementVNode("view",{class:"uni-title"},"设置步进step跳动"),e.createElementVNode("view",null,[e.createElementVNode("slider",{value:"60",onChange:n[1]||(n[1]=(...e)=>r.sliderChange&&r.sliderChange(...e)),step:"5"},null,32)]),e.createElementVNode("view",{class:"uni-title"},"设置最小/最大值"),e.createElementVNode("view",null,[e.createElementVNode("slider",{value:"100",onChange:n[2]||(n[2]=(...e)=>r.sliderChange&&r.sliderChange(...e)),min:"50",max:"200","show-value":""},null,32)]),e.createElementVNode("view",{class:"uni-title"},"不同颜色和大小的滑块"),e.createElementVNode("view",null,[e.createElementVNode("slider",{value:"50",onChange:n[3]||(n[3]=(...e)=>r.sliderChange&&r.sliderChange(...e)),activeColor:"#FFCC33",backgroundColor:"#000000","block-color":"#8A6DE9","block-size":"20"},null,32)])])])}]]),P={data:()=>({title:"switch 开关"}),methods:{switch1Change:function(e){n("log","at pages/component/switch/switch.vue:39","switch1 发生 change 事件，携带值为",e.detail.value)},switch2Change:function(e){n("log","at pages/component/switch/switch.vue:42","switch2 发生 change 事件，携带值为",e.detail.value)}}};const A=t(P,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},"默认样式"),e.createElementVNode("view",null,[e.createElementVNode("switch",{checked:"",onChange:n[0]||(n[0]=(...e)=>r.switch1Change&&r.switch1Change(...e))},null,32),e.createElementVNode("switch",{onChange:n[1]||(n[1]=(...e)=>r.switch2Change&&r.switch2Change(...e))},null,32)]),e.createElementVNode("view",{class:"uni-title"},"不同颜色和尺寸的switch"),e.createElementVNode("view",null,[e.createElementVNode("switch",{checked:"",color:"#FFCC33",style:{transform:"scale(0.7)"}}),e.createElementVNode("switch",{color:"#FFCC33",style:{transform:"scale(0.7)"}})]),e.createElementVNode("view",{class:"uni-title"},"推荐展示样式")]),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("view",{class:"uni-list-cell-db"},"开启中"),e.createElementVNode("switch",{checked:""})]),e.createElementVNode("view",{class:"uni-list-cell uni-list-cell-pd"},[e.createElementVNode("view",{class:"uni-list-cell-db"},"关闭"),e.createElementVNode("switch")])])])}]]),F={data:()=>({title:"textarea",focus:!1}),methods:{bindTextAreaBlur:function(e){n("log","at pages/component/textarea/textarea.vue:24",e.detail.value)}}};const L=t(F,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"输入区域高度自适应，不会出现滚动条"),e.createElementVNode("view",{class:"uni-textarea"},[e.createElementVNode("textarea",{onBlur:n[0]||(n[0]=(...e)=>r.bindTextAreaBlur&&r.bindTextAreaBlur(...e)),"auto-height":""},null,32)]),e.createElementVNode("view",{class:"uni-title uni-common-pl"},"占位符字体是红色的textarea"),e.createElementVNode("view",{class:"uni-textarea"},[e.createElementVNode("textarea",{"placeholder-style":"color:#F76260",placeholder:"占位符字体是红色的"})])])}]]),M={data:()=>({readOnly:!1,formats:{}}),onLoad(){uni.loadFontFace({family:"Pacifico",source:'url("/static/font/Pacifico-Regular.ttf")',success(){n("log","at pages/component/editor/editor.vue:101","success load font")},fail(){n("log","at pages/component/editor/editor.vue:104","fail load font load")}})},methods:{readOnlyChange(){this.readOnly=!this.readOnly},getCon(){this.editorCtx.getContents({success:e=>{n("log","at pages/component/editor/editor.vue:116","文本详情：",e)},fail:e=>{}})},onEditorReady(){uni.createSelectorQuery().select("#editor").context((e=>{this.editorCtx=e.context})).exec()},undo(){this.editorCtx.undo()},redo(){this.editorCtx.redo()},format(e){let{name:t,value:a}=e.target.dataset;t&&this.editorCtx.format(t,a)},onStatusChange(e){const t=e.detail;this.formats=t},insertDivider(){this.editorCtx.insertDivider({success:function(){n("log","at pages/component/editor/editor.vue:156","insert divider success")}})},clear(){uni.showModal({title:"清空编辑器",content:"确定清空编辑器全部内容？",success:e=>{e.confirm&&this.editorCtx.clear({success:function(e){n("log","at pages/component/editor/editor.vue:168","clear success")}})}})},removeFormat(){this.editorCtx.removeFormat()},insertDate(){const e=new Date,t=`${e.getFullYear()}/${e.getMonth()+1}/${e.getDate()}`;this.editorCtx.insertText({text:t})},insertImage(){uni.chooseImage({count:1,success:e=>{this.editorCtx.insertImage({src:e.tempFilePaths[0],alt:"图像",success:function(){n("log","at pages/component/editor/editor.vue:193","insert image success")}})}})}}};const R=t(M,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createElementVNode("view",{class:"page-body"},[e.createElementVNode("view",{class:"wrapper"},[e.createElementVNode("view",{class:"toolbar",onClick:a[7]||(a[7]=(...e)=>s.format&&s.format(...e)),style:{height:"80px","overflow-y":"auto"}},[e.createElementVNode("view",{class:e.normalizeClass([o.formats.bold?"ql-active":"","iconfont icon-zitijiacu"]),"data-name":"bold"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.italic?"ql-active":"","iconfont icon-zitixieti"]),"data-name":"italic"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.underline?"ql-active":"","iconfont icon-zitixiahuaxian"]),"data-name":"underline"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.strike?"ql-active":"","iconfont icon-zitishanchuxian"]),"data-name":"strike"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["left"===o.formats.align?"ql-active":"","iconfont icon-zuoduiqi"]),"data-name":"align","data-value":"left"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["center"===o.formats.align?"ql-active":"","iconfont icon-juzhongduiqi"]),"data-name":"align","data-value":"center"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["right"===o.formats.align?"ql-active":"","iconfont icon-youduiqi"]),"data-name":"align","data-value":"right"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["justify"===o.formats.align?"ql-active":"","iconfont icon-zuoyouduiqi"]),"data-name":"align","data-value":"justify"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.lineHeight?"ql-active":"","iconfont icon-line-height"]),"data-name":"lineHeight","data-value":"2"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.letterSpacing?"ql-active":"","iconfont icon-Character-Spacing"]),"data-name":"letterSpacing","data-value":"2em"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.marginTop?"ql-active":"","iconfont icon-722bianjiqi_duanqianju"]),"data-name":"marginTop","data-value":"20px"},null,2),e.createElementVNode("view",{class:e.normalizeClass([o.formats.marginBottom?"ql-active":"","iconfont icon-723bianjiqi_duanhouju"]),"data-name":"marginBottom","data-value":"20px"},null,2),e.createElementVNode("view",{class:"iconfont icon-clearedformat",onClick:a[0]||(a[0]=(...e)=>s.removeFormat&&s.removeFormat(...e))}),e.createElementVNode("view",{class:e.normalizeClass([o.formats.fontFamily?"ql-active":"","iconfont icon-font"]),"data-name":"fontFamily","data-value":"Pacifico"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["24px"===o.formats.fontSize?"ql-active":"","iconfont icon-fontsize"]),"data-name":"fontSize","data-value":"24px"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["#0000ff"===o.formats.color?"ql-active":"","iconfont icon-text_color"]),"data-name":"color","data-value":"#0000ff"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["#00ff00"===o.formats.backgroundColor?"ql-active":"","iconfont icon-fontbgcolor"]),"data-name":"backgroundColor","data-value":"#00ff00"},null,2),e.createElementVNode("view",{class:"iconfont icon-date",onClick:a[1]||(a[1]=(...e)=>s.insertDate&&s.insertDate(...e))}),e.createElementVNode("view",{class:"iconfont icon--checklist","data-name":"list","data-value":"check"}),e.createElementVNode("view",{class:e.normalizeClass(["ordered"===o.formats.list?"ql-active":"","iconfont icon-youxupailie"]),"data-name":"list","data-value":"ordered"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["bullet"===o.formats.list?"ql-active":"","iconfont icon-wuxupailie"]),"data-name":"list","data-value":"bullet"},null,2),e.createElementVNode("view",{class:"iconfont icon-undo",onClick:a[2]||(a[2]=(...e)=>s.undo&&s.undo(...e))}),e.createElementVNode("view",{class:"iconfont icon-redo",onClick:a[3]||(a[3]=(...e)=>s.redo&&s.redo(...e))}),e.createElementVNode("view",{class:"iconfont icon-outdent","data-name":"indent","data-value":"-1"}),e.createElementVNode("view",{class:"iconfont icon-indent","data-name":"indent","data-value":"+1"}),e.createElementVNode("view",{class:"iconfont icon-fengexian",onClick:a[4]||(a[4]=(...e)=>s.insertDivider&&s.insertDivider(...e))}),e.createElementVNode("view",{class:"iconfont icon-charutupian",onClick:a[5]||(a[5]=(...e)=>s.insertImage&&s.insertImage(...e))}),e.createElementVNode("view",{class:e.normalizeClass([1===o.formats.header?"ql-active":"","iconfont icon-format-header-1"]),"data-name":"header","data-value":1},null,2),e.createElementVNode("view",{class:e.normalizeClass(["sub"===o.formats.script?"ql-active":"","iconfont icon-zitixiabiao"]),"data-name":"script","data-value":"sub"},null,2),e.createElementVNode("view",{class:e.normalizeClass(["super"===o.formats.script?"ql-active":"","iconfont icon-zitishangbiao"]),"data-name":"script","data-value":"super"},null,2),e.createElementVNode("view",{class:"iconfont icon-shanchu",onClick:a[6]||(a[6]=(...e)=>s.clear&&s.clear(...e))}),e.createElementVNode("view",{class:e.normalizeClass(["rtl"===o.formats.direction?"ql-active":"","iconfont icon-direction-rtl"]),"data-name":"direction","data-value":"rtl"},null,2)]),e.createElementVNode("view",{class:"editor-wrapper"},[e.createElementVNode("editor",{id:"editor",class:"ql-container",placeholder:"开始输入...","show-img-size":"","show-img-toolbar":"","show-img-resize":"",onStatuschange:a[8]||(a[8]=(...e)=>s.onStatusChange&&s.onStatusChange(...e)),"read-only":o.readOnly,onReady:a[9]||(a[9]=(...e)=>s.onEditorReady&&s.onEditorReady(...e))},null,40,["read-only"])]),e.createElementVNode("view",null,[e.createElementVNode("button",{onClick:a[10]||(a[10]=(...e)=>s.getCon&&s.getCon(...e))},"打印文本内容")])])])])}]]);function O(){return"undefined"!=typeof navigator&&"undefined"!=typeof window?window:"undefined"!=typeof global?global:{}}const $="function"==typeof Proxy;class z{constructor(e,t){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=t;const a={};if(e.settings)for(const o in e.settings){const t=e.settings[o];a[o]=t.defaultValue}const n=`__vue-devtools-plugin-settings__${e.id}`;let i={...a};try{const e=localStorage.getItem(n),t=JSON.parse(e);Object.assign(i,t)}catch($i){}this.fallbacks={getSettings:()=>i,setSettings(e){try{localStorage.setItem(n,JSON.stringify(e))}catch($i){}i=e}},t.on("plugin:settings:set",((e,t)=>{e===this.plugin.id&&this.fallbacks.setSettings(t)})),this.proxiedOn=new Proxy({},{get:(e,t)=>this.target?this.target.on[t]:(...e)=>{this.onQueue.push({method:t,args:e})}}),this.proxiedTarget=new Proxy({},{get:(e,t)=>this.target?this.target[t]:"on"===t?this.proxiedOn:Object.keys(this.fallbacks).includes(t)?(...e)=>(this.targetQueue.push({method:t,args:e,resolve:()=>{}}),this.fallbacks[t](...e)):(...e)=>new Promise((a=>{this.targetQueue.push({method:t,args:e,resolve:a})}))})}async setRealTarget(e){this.target=e;for(const t of this.onQueue)this.target.on[t.method](...t.args);for(const t of this.targetQueue)t.resolve(await this.target[t.method](...t.args))}}function U(e,t){const a=O(),n=O().__VUE_DEVTOOLS_GLOBAL_HOOK__,i=$&&e.enableEarlyProxy;if(!n||!a.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__&&i){const o=i?new z(e,n):null;(a.__VUE_DEVTOOLS_PLUGINS__=a.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:e,setupFn:t,proxy:o}),o&&t(o.proxiedTarget)}else n.emit("devtools-plugin:setup",e,t)}
/*!
   * vuex v4.1.0
   * (c) 2022 Evan You
   * @license MIT
   */var j="store";function q(e,t){if(void 0===t&&(t=[]),null===e||"object"!=typeof e)return e;var a,n=(a=function(t){return t.original===e},t.filter(a)[0]);if(n)return n.copy;var i=Array.isArray(e)?[]:{};return t.push({original:e,copy:i}),Object.keys(e).forEach((function(a){i[a]=q(e[a],t)})),i}function H(e,t){Object.keys(e).forEach((function(a){return t(e[a],a)}))}function W(e){return null!==e&&"object"==typeof e}function J(e,t,a){return t.indexOf(e)<0&&(a&&a.prepend?t.unshift(e):t.push(e)),function(){var a=t.indexOf(e);a>-1&&t.splice(a,1)}}function G(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var a=e.state;Q(e,a,[],e._modules.root,!0),K(e,a,t)}function K(t,a,n){var i=t._state,o=t._scope;t.getters={},t._makeLocalGettersCache=Object.create(null);var s=t._wrappedGetters,l={},r={},c=e.effectScope(!0);c.run((function(){H(s,(function(a,n){l[n]=function(e,t){return function(){return e(t)}}(a,t),r[n]=e.computed((function(){return l[n]()})),Object.defineProperty(t.getters,n,{get:function(){return r[n].value},enumerable:!0})}))})),t._state=e.reactive({data:a}),t._scope=c,t.strict&&function(t){e.watch((function(){return t._state.data}),(function(){}),{deep:!0,flush:"sync"})}(t),i&&n&&t._withCommit((function(){i.data=null})),o&&o.stop()}function Q(e,t,a,n,i){var o=!a.length,s=e._modules.getNamespace(a);if(n.namespaced&&(e._modulesNamespaceMap[s],e._modulesNamespaceMap[s]=n),!o&&!i){var l=X(t,a.slice(0,-1)),r=a[a.length-1];e._withCommit((function(){l[r]=n.state}))}var c=n.context=function(e,t,a){var n=""===t,i={dispatch:n?e.dispatch:function(a,n,i){var o=Z(a,n,i),s=o.payload,l=o.options,r=o.type;return l&&l.root||(r=t+r),e.dispatch(r,s)},commit:n?e.commit:function(a,n,i){var o=Z(a,n,i),s=o.payload,l=o.options,r=o.type;l&&l.root||(r=t+r),e.commit(r,s,l)}};return Object.defineProperties(i,{getters:{get:n?function(){return e.getters}:function(){return Y(e,t)}},state:{get:function(){return X(e.state,a)}}}),i}(e,s,a);n.forEachMutation((function(t,a){!function(e,t,a,n){(e._mutations[t]||(e._mutations[t]=[])).push((function(t){a.call(e,n.state,t)}))}(e,s+a,t,c)})),n.forEachAction((function(t,a){var n=t.root?a:s+a,i=t.handler||t;!function(e,t,a,n){(e._actions[t]||(e._actions[t]=[])).push((function(t){var i,o=a.call(e,{dispatch:n.dispatch,commit:n.commit,getters:n.getters,state:n.state,rootGetters:e.getters,rootState:e.state},t);return(i=o)&&"function"==typeof i.then||(o=Promise.resolve(o)),e._devtoolHook?o.catch((function(t){throw e._devtoolHook.emit("vuex:error",t),t})):o}))}(e,n,i,c)})),n.forEachGetter((function(t,a){!function(e,t,a,n){if(e._wrappedGetters[t])return;e._wrappedGetters[t]=function(e){return a(n.state,n.getters,e.state,e.getters)}}(e,s+a,t,c)})),n.forEachChild((function(n,o){Q(e,t,a.concat(o),n,i)}))}function Y(e,t){if(!e._makeLocalGettersCache[t]){var a={},n=t.length;Object.keys(e.getters).forEach((function(i){if(i.slice(0,n)===t){var o=i.slice(n);Object.defineProperty(a,o,{get:function(){return e.getters[i]},enumerable:!0})}})),e._makeLocalGettersCache[t]=a}return e._makeLocalGettersCache[t]}function X(e,t){return t.reduce((function(e,t){return e[t]}),e)}function Z(e,t,a){return W(e)&&e.type&&(a=t,t=e,e=e.type),{type:e,payload:t,options:a}}var ee="vuex:mutations",te="vuex:actions",ae="vuex",ne=0;function ie(e,t){U({id:"org.vuejs.vuex",app:e,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:["vuex bindings"]},(function(a){a.addTimelineLayer({id:ee,label:"Vuex Mutations",color:oe}),a.addTimelineLayer({id:te,label:"Vuex Actions",color:oe}),a.addInspector({id:ae,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),a.on.getInspectorTree((function(a){if(a.app===e&&a.inspectorId===ae)if(a.filter){var n=[];ce(n,t._modules.root,a.filter,""),a.rootNodes=n}else a.rootNodes=[re(t._modules.root,"")]})),a.on.getInspectorState((function(a){if(a.app===e&&a.inspectorId===ae){var n=a.nodeId;Y(t,n),a.state=function(e,t,a){t="root"===a?t:t[a];var n=Object.keys(t),i={state:Object.keys(e.state).map((function(t){return{key:t,editable:!0,value:e.state[t]}}))};if(n.length){var o=function(e){var t={};return Object.keys(e).forEach((function(a){var n=a.split("/");if(n.length>1){var i=t,o=n.pop();n.forEach((function(e){i[e]||(i[e]={_custom:{value:{},display:e,tooltip:"Module",abstract:!0}}),i=i[e]._custom.value})),i[o]=de((function(){return e[a]}))}else t[a]=de((function(){return e[a]}))})),t}(t);i.getters=Object.keys(o).map((function(e){return{key:e.endsWith("/")?le(e):e,editable:!1,value:de((function(){return o[e]}))}}))}return i}((i=t._modules,(s=(o=n).split("/").filter((function(e){return e}))).reduce((function(e,t,a){var n=e[t];if(!n)throw new Error('Missing module "'+t+'" for path "'+o+'".');return a===s.length-1?n:n._children}),"root"===o?i:i.root._children)),"root"===n?t.getters:t._makeLocalGettersCache,n)}var i,o,s})),a.on.editInspectorState((function(a){if(a.app===e&&a.inspectorId===ae){var n=a.nodeId,i=a.path;"root"!==n&&(i=n.split("/").filter(Boolean).concat(i)),t._withCommit((function(){a.set(t._state.data,i,a.state.value)}))}})),t.subscribe((function(e,t){var n={};e.payload&&(n.payload=e.payload),n.state=t,a.notifyComponentUpdate(),a.sendInspectorTree(ae),a.sendInspectorState(ae),a.addTimelineEvent({layerId:ee,event:{time:Date.now(),title:e.type,data:n}})})),t.subscribeAction({before:function(e,t){var n={};e.payload&&(n.payload=e.payload),e._id=ne++,e._time=Date.now(),n.state=t,a.addTimelineEvent({layerId:te,event:{time:e._time,title:e.type,groupId:e._id,subtitle:"start",data:n}})},after:function(e,t){var n={},i=Date.now()-e._time;n.duration={_custom:{type:"duration",display:i+"ms",tooltip:"Action duration",value:i}},e.payload&&(n.payload=e.payload),n.state=t,a.addTimelineEvent({layerId:te,event:{time:Date.now(),title:e.type,groupId:e._id,subtitle:"end",data:n}})}})}))}var oe=8702998,se={label:"namespaced",textColor:16777215,backgroundColor:6710886};function le(e){return e&&"root"!==e?e.split("/").slice(-2,-1)[0]:"Root"}function re(e,t){return{id:t||"root",label:le(t),tags:e.namespaced?[se]:[],children:Object.keys(e._children).map((function(a){return re(e._children[a],t+a+"/")}))}}function ce(e,t,a,n){n.includes(a)&&e.push({id:n||"root",label:n.endsWith("/")?n.slice(0,n.length-1):n||"Root",tags:t.namespaced?[se]:[]}),Object.keys(t._children).forEach((function(i){ce(e,t._children[i],a,n+i+"/")}))}function de(e){try{return e()}catch($i){return $i}}var ue=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var a=e.state;this.state=("function"==typeof a?a():a)||{}},he={namespaced:{configurable:!0}};he.namespaced.get=function(){return!!this._rawModule.namespaced},ue.prototype.addChild=function(e,t){this._children[e]=t},ue.prototype.removeChild=function(e){delete this._children[e]},ue.prototype.getChild=function(e){return this._children[e]},ue.prototype.hasChild=function(e){return e in this._children},ue.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)},ue.prototype.forEachChild=function(e){H(this._children,e)},ue.prototype.forEachGetter=function(e){this._rawModule.getters&&H(this._rawModule.getters,e)},ue.prototype.forEachAction=function(e){this._rawModule.actions&&H(this._rawModule.actions,e)},ue.prototype.forEachMutation=function(e){this._rawModule.mutations&&H(this._rawModule.mutations,e)},Object.defineProperties(ue.prototype,he);var pe=function(e){this.register([],e,!1)};function me(e,t,a){if(t.update(a),a.modules)for(var n in a.modules){if(!t.getChild(n))return;me(e.concat(n),t.getChild(n),a.modules[n])}}function ge(e){return new fe(e)}pe.prototype.get=function(e){return e.reduce((function(e,t){return e.getChild(t)}),this.root)},pe.prototype.getNamespace=function(e){var t=this.root;return e.reduce((function(e,a){return e+((t=t.getChild(a)).namespaced?a+"/":"")}),"")},pe.prototype.update=function(e){me([],this.root,e)},pe.prototype.register=function(e,t,a){var n=this;void 0===a&&(a=!0);var i=new ue(t,a);0===e.length?this.root=i:this.get(e.slice(0,-1)).addChild(e[e.length-1],i);t.modules&&H(t.modules,(function(t,i){n.register(e.concat(i),t,a)}))},pe.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),a=e[e.length-1],n=t.getChild(a);n&&n.runtime&&t.removeChild(a)},pe.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),a=e[e.length-1];return!!t&&t.hasChild(a)};var fe=function(e){var t=this;void 0===e&&(e={});var a=e.plugins;void 0===a&&(a=[]);var n=e.strict;void 0===n&&(n=!1);var i=e.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new pe(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=i;var o=this,s=this.dispatch,l=this.commit;this.dispatch=function(e,t){return s.call(o,e,t)},this.commit=function(e,t,a){return l.call(o,e,t,a)},this.strict=n;var r=this._modules.root.state;Q(this,r,[],this._modules.root),K(this,r),a.forEach((function(e){return e(t)}))},ye={state:{configurable:!0}};fe.prototype.install=function(e,t){e.provide(t||j,this),e.config.globalProperties.$store=this,void 0!==this._devtools&&this._devtools&&ie(e,this)},ye.state.get=function(){return this._state.data},ye.state.set=function(e){},fe.prototype.commit=function(e,t,a){var n=this,i=Z(e,t,a),o=i.type,s=i.payload,l={type:o,payload:s},r=this._mutations[o];r&&(this._withCommit((function(){r.forEach((function(e){e(s)}))})),this._subscribers.slice().forEach((function(e){return e(l,n.state)})))},fe.prototype.dispatch=function(e,t){var a=this,n=Z(e,t),i=n.type,o=n.payload,s={type:i,payload:o},l=this._actions[i];if(l){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(s,a.state)}))}catch($i){}var r=l.length>1?Promise.all(l.map((function(e){return e(o)}))):l[0](o);return new Promise((function(e,t){r.then((function(t){try{a._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(s,a.state)}))}catch($i){}e(t)}),(function(e){try{a._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(s,a.state,e)}))}catch($i){}t(e)}))}))}},fe.prototype.subscribe=function(e,t){return J(e,this._subscribers,t)},fe.prototype.subscribeAction=function(e,t){return J("function"==typeof e?{before:e}:e,this._actionSubscribers,t)},fe.prototype.watch=function(t,a,n){var i=this;return e.watch((function(){return t(i.state,i.getters)}),a,Object.assign({},n))},fe.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._state.data=e}))},fe.prototype.registerModule=function(e,t,a){void 0===a&&(a={}),"string"==typeof e&&(e=[e]),this._modules.register(e,t),Q(this,this.state,e,this._modules.get(e),a.preserveState),K(this,this.state)},fe.prototype.unregisterModule=function(e){var t=this;"string"==typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){delete X(t.state,e.slice(0,-1))[e[e.length-1]]})),G(this)},fe.prototype.hasModule=function(e){return"string"==typeof e&&(e=[e]),this._modules.isRegistered(e)},fe.prototype.hotUpdate=function(e){this._modules.update(e),G(this,!0)},fe.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(fe.prototype,ye);var ve=Ve((function(e,t){var a={};return xe(t).forEach((function(t){var n=t.key,i=t.val;a[n]=function(){var t=this.$store.state,a=this.$store.getters;if(e){var n=Ne(this.$store,"mapState",e);if(!n)return;t=n.context.state,a=n.context.getters}return"function"==typeof i?i.call(this,t,a):t[i]},a[n].vuex=!0})),a})),we=Ve((function(e,t){var a={};return xe(t).forEach((function(t){var n=t.key,i=t.val;a[n]=function(){for(var t=[],a=arguments.length;a--;)t[a]=arguments[a];var n=this.$store.commit;if(e){var o=Ne(this.$store,"mapMutations",e);if(!o)return;n=o.context.commit}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),a})),be=Ve((function(e,t){var a={};return xe(t).forEach((function(t){var n=t.key,i=t.val;i=e+i,a[n]=function(){if(!e||Ne(this.$store,"mapGetters",e))return this.$store.getters[i]},a[n].vuex=!0})),a})),ke=Ve((function(e,t){var a={};return xe(t).forEach((function(t){var n=t.key,i=t.val;a[n]=function(){for(var t=[],a=arguments.length;a--;)t[a]=arguments[a];var n=this.$store.dispatch;if(e){var o=Ne(this.$store,"mapActions",e);if(!o)return;n=o.context.dispatch}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),a}));function xe(e){return function(e){return Array.isArray(e)||W(e)}(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function Ve(e){return function(t,a){return"string"!=typeof t?(a=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,a)}}function Ne(e,t,a){return e._modulesNamespaceMap[a]}function Ee(e,t,a){var n=a?e.groupCollapsed:e.group;try{n.call(e,t)}catch($i){e.log(t)}}function Ce(e){try{e.groupEnd()}catch($i){e.log("—— log end ——")}}function _e(){var e=new Date;return" @ "+Se(e.getHours(),2)+":"+Se(e.getMinutes(),2)+":"+Se(e.getSeconds(),2)+"."+Se(e.getMilliseconds(),3)}function Se(e,t){return a="0",n=t-e.toString().length,new Array(n+1).join(a)+e;var a,n}var Te={version:"4.1.0",Store:fe,storeKey:j,createStore:ge,useStore:function(t){return void 0===t&&(t=null),e.inject(null!==t?t:j)},mapState:ve,mapMutations:we,mapGetters:be,mapActions:ke,createNamespacedHelpers:function(e){return{mapState:ve.bind(null,e),mapGetters:be.bind(null,e),mapMutations:we.bind(null,e),mapActions:ke.bind(null,e)}},createLogger:function(e){void 0===e&&(e={});var t=e.collapsed;void 0===t&&(t=!0);var a=e.filter;void 0===a&&(a=function(e,t,a){return!0});var n=e.transformer;void 0===n&&(n=function(e){return e});var i=e.mutationTransformer;void 0===i&&(i=function(e){return e});var o=e.actionFilter;void 0===o&&(o=function(e,t){return!0});var s=e.actionTransformer;void 0===s&&(s=function(e){return e});var l=e.logMutations;void 0===l&&(l=!0);var r=e.logActions;void 0===r&&(r=!0);var c=e.logger;return void 0===c&&(c=console),function(e){var d=q(e.state);void 0!==c&&(l&&e.subscribe((function(e,o){var s=q(o);if(a(e,d,s)){var l=_e(),r=i(e),u="mutation "+e.type+l;Ee(c,u,t),c.log("%c prev state","color: #9E9E9E; font-weight: bold",n(d)),c.log("%c mutation","color: #03A9F4; font-weight: bold",r),c.log("%c next state","color: #4CAF50; font-weight: bold",n(s)),Ce(c)}d=s})),r&&e.subscribeAction((function(e,a){if(o(e,a)){var n=_e(),i=s(e),l="action "+e.type+n;Ee(c,l,t),c.log("%c action","color: #03A9F4; font-weight: bold",i),Ce(c)}})))}}};const Be=t({data:()=>({title:"navigator"}),computed:{...ve({hasLeftWin:e=>!e.noMatchLeftWindow})}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("navigator",{url:"navigate/navigate?title=navigate","hover-class":"navigator-hover"},[e.createElementVNode("button",{type:"default"},"跳转到新页面")]),e.createElementVNode("navigator",{url:"redirect/redirect?title=redirect","open-type":"redirect","hover-class":"other-navigator-hover"},[e.createElementVNode("button",{type:"default"},"在当前页打开")]),t.hasLeftWin?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("navigator",{key:0,url:"/pages/tabBar/extUI/extUI","open-type":"switchTab","hover-class":"other-navigator-hover"},[e.createElementVNode("button",{type:"default"},"跳转tab页面")]))])])])}]]);const De=t({data:()=>({title:"新建的页面"})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"])])}]]);const Ie=t({data:()=>({title:"当前页"})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"])])}]]);const Pe=t({data:()=>({title:"image"})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createTextVNode(" 示例1 "),e.createElementVNode("text",null,"\\n本地图片")]),e.createElementVNode("view",{class:"uni-center",style:{background:"#FFFFFF","font-size":"0"}},[e.createElementVNode("image",{class:"image",mode:"widthFix",src:"/static/uni.png"})]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},[e.createTextVNode(" 示例2 "),e.createElementVNode("text",null,"\\n网络图片")]),e.createElementVNode("view",{class:"uni-center",style:{background:"#FFFFFF","font-size":"0"}},[e.createElementVNode("image",{class:"image",mode:"widthFix",src:"https://web-assets.dcloud.net.cn/unidoc/zh/uni@2x.png"})])])])}]]),Ae=e=>{(e.$renderjs||(e.$renderjs=[])).push("animate"),(e.$renderjsModules||(e.$renderjsModules={})).animate="39c049d8"},Fe={data:()=>({title:"canvas",canvasWidth:0,startStatus:!1,ballList:[]}),onReady:function(){this.$nextTick((()=>{uni.createSelectorQuery().select(".canvas").boundingClientRect((e=>{this.canvasWidth=e.width,this.startStatus=!0})).exec()}))}};Ae(Fe);const Le=t(Fe,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"page-body"},[e.createElementVNode("view",{class:"page-body-wrapper"},[e.createElementVNode("canvas",{"canvas-id":"canvas",class:"canvas",start:e.wp(l.startStatus),"change:start":t.animate.start,"data-width":l.canvasWidth,"data-height":l.canvasWidth},null,8,["start","change:start","data-width","data-height"])])])])}]]);const Me=t({data:()=>({url:"https://hellouniapp.dcloud.net.cn/html/web-view.html"}),onLoad(e){e&&e.url&&(this.url=e.url)},methods:{getMessage(e){uni.showModal({content:JSON.stringify(e.detail),showCancel:!1})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("web-view",{src:o.url,onMessage:a[0]||(a[0]=(...e)=>s.getMessage&&s.getMessage(...e))},null,40,["src"])])}]]),Re={data:()=>({title:"AD组件",unitId:"",isLoad:!1,adMessage:"广告加载中..."}),onLoad(){},methods:{adload(){this.isLoad=!0},aderror(e){this.adMessage=e.detail.errMsg},gotoapi(){uni.navigateTo({url:"/pages/API/rewarded-video-ad/rewarded-video-ad"})}}};const Oe=t(Re,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"ad-view"},[e.createElementVNode("ad",{adpid:"1111111111",onLoad:n[0]||(n[0]=(...e)=>r.adload&&r.adload(...e)),onError:n[1]||(n[1]=(...e)=>r.aderror&&r.aderror(...e))},null,32),l.isLoad?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"ad-tips"},[e.createElementVNode("text",null,e.toDisplayString(l.adMessage),1)]))]),e.createElementVNode("view",{class:"tips"},[e.createElementVNode("text",{class:"tips-text"},"本示例页面仅演示ad组件。另点此可体验"),e.createElementVNode("text",{class:"tips-hl",onClick:n[2]||(n[2]=(...e)=>r.gotoapi&&r.gotoapi(...e))},"激励视频API"),e.createElementVNode("text",{class:"tips-text"},"。")])])}]]),$e={methods:{getMessage(e){uni.showModal({content:JSON.stringify(e.detail),showCancel:!1})}}};const ze=t($e,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("web-view",{src:"/hybrid/html/local.html",onMessage:a[0]||(a[0]=(...e)=>s.getMessage&&s.getMessage(...e))},null,32)])}]]);const Ue=t({data:()=>({clickClientX:0,clickClientY:0}),onLoad(){},methods:{onWebViewMessage(e){const t=e.detail.data,a=t&&t[0];"click"===a.action&&(this.clickClientX=a.clientX,this.clickClientY=a.clientY)}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("web-view",{style:{"margin-top":"200px"},src:"/hybrid/html/issue-17581.html",onMessage:a[0]||(a[0]=(...e)=>s.onWebViewMessage&&s.onWebViewMessage(...e))},null,32)])}]]);var je;const qe={get isIOS(){return"boolean"==typeof je?je:je="ios"===uni.getSystemInfoSync().platform},requestIOS:function(e){return new Promise(((t,a)=>{switch(e){case"push":t(function(){var e=0,t=plus.ios.import("UIApplication"),a=t.sharedApplication();if(a.currentUserNotificationSettings){var i=a.currentUserNotificationSettings();0==i.plusGetAttribute("types")?(e=0,n("log","at common/permission.js:63","推送权限没有开启")):(e=1,n("log","at common/permission.js:66","已经开启推送功能!")),plus.ios.deleteObject(i)}else 0==a.enabledRemoteNotificationTypes()?(e=3,n("log","at common/permission.js:73","推送权限没有开启!")):(e=4,n("log","at common/permission.js:76","已经开启推送功能!"));return plus.ios.deleteObject(a),plus.ios.deleteObject(t),e}());break;case"location":t((i=0,o=plus.ios.import("CLLocationManager"),s=o.locationServicesEnabled(),l=o.authorizationStatus(),i=s?0===l?null:3===l||4===l?1:0:2,plus.ios.deleteObject(o),i));break;case"record":t(function(){var e=null,t=plus.ios.import("AVAudioSession"),a=t.sharedInstance().recordPermission();return n("log","at common/permission.js:104","permissionStatus:"+a),e=1970168948===a?null:1735552628===a?1:0,plus.ios.deleteObject(t),e}());break;case"camera":t(function(){var e=0,t=plus.ios.import("AVCaptureDevice"),a=t.authorizationStatusForMediaType("vide");return e=0===a?null:3==a?1:0,plus.ios.deleteObject(t),e}());break;case"album":t(function(){var e=0,t=plus.ios.import("PHPhotoLibrary"),a=t.authorizationStatus();return e=0===a?null:3==a?1:0,plus.ios.deleteObject(t),e}());break;case"contact":t(function(){var e=0,t=plus.ios.import("CNContactStore"),a=t.authorizationStatusForEntityType(0);return e=0===a?null:3==a?1:0,plus.ios.deleteObject(t),e}());break;case"calendar":t(function(){var e=null,t=plus.ios.import("EKEventStore");return 3==t.authorizationStatusForEntityType(0)?(e=1,n("log","at common/permission.js:122","日历权限已经开启")):n("log","at common/permission.js:124","日历权限没有开启"),plus.ios.deleteObject(t),e}());break;case"memo":t(function(){var e=null,t=plus.ios.import("EKEventStore");return 3==t.authorizationStatusForEntityType(1)?(e=1,n("log","at common/permission.js:136","备忘录权限已经开启")):n("log","at common/permission.js:138","备忘录权限没有开启"),plus.ios.deleteObject(t),e}());break;default:t(0)}var i,o,s,l}))},requestAndroid:function(e){return new Promise(((t,a)=>{plus.android.requestPermissions([e],(function(e){for(var a=0,i=0;i<e.granted.length;i++){n("log","at common/permission.js:187","已获取的权限："+e.granted[i]),a=1}for(i=0;i<e.deniedPresent.length;i++){n("log","at common/permission.js:192","拒绝本次申请的权限："+e.deniedPresent[i]),a=0}for(i=0;i<e.deniedAlways.length;i++){n("log","at common/permission.js:197","永久拒绝申请的权限："+e.deniedAlways[i]),a=-1}t(a)}),(function(e){n("log","at common/permission.js:203","result error: "+e.message),t({code:e.code,message:e.message})}))}))},gotoAppSetting:function(){if(qe.isIOS){var e=plus.ios.import("UIApplication").sharedApplication(),t=plus.ios.import("NSURL"),a=t.URLWithString("app-settings:");e.openURL(a),plus.ios.deleteObject(a),plus.ios.deleteObject(t),plus.ios.deleteObject(e)}else{var n=plus.android.importClass("android.content.Intent"),i=plus.android.importClass("android.provider.Settings"),o=plus.android.importClass("android.net.Uri"),s=plus.android.runtimeMainActivity(),l=new n;l.setAction(i.ACTION_APPLICATION_DETAILS_SETTINGS);var r=o.fromParts("package",s.getPackageName(),null);l.setData(r),s.startActivity(l)}}},He={data:()=>({title:"speech",value:""}),onUnload(){this.value=""},methods:{async startRecognize(){if(1===await this.checkPermission()){var e={},t=this;e.engine="baidu",t.value="",plus.speech.startRecognize(e,(function(e){n("log","at platforms/app-plus/speech/speech.vue:42",e),t.value+=e}),(function(e){n("log","at platforms/app-plus/speech/speech.vue:45","语音识别失败："+e.message)}))}},async startRecognizeEnglish(){if(1===await this.checkPermission()){var e={},t=this;e.engine="baidu",e.lang="en-us",t.value="",plus.speech.startRecognize(e,(function(e){n("log","at platforms/app-plus/speech/speech.vue:63",e),t.value+=e}),(function(e){n("log","at platforms/app-plus/speech/speech.vue:66","语音识别失败："+e.message)}))}},async checkPermission(){let e=qe.isIOS?await qe.requestIOS("record"):await qe.requestAndroid("android.permission.RECORD_AUDIO");return null===e||1===e?e=1:2===e?uni.showModal({content:"系统麦克风已关闭",confirmText:"确定",showCancel:!1,success:function(e){}}):uni.showModal({content:"需要麦克风权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),e}}};const We=t(He,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-textarea"},[e.createElementVNode("textarea",{value:l.value,placeholder:"语音识别内容展示区域",disabled:""},null,8,["value"])]),e.createElementVNode("view",{class:"uni-common-mt uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.startRecognize&&r.startRecognize(...e))},"开始语音识别")])])])}]]);var Je=null;const Ge={data:()=>({title:"orientation",value:""}),onUnload(){this.watchStop()},methods:{getOrient:function(){var e=this;plus.orientation.getCurrentOrientation((function(t){e.value="alpha："+t.alpha+"\nbeta："+t.beta+"\ngamma："+t.gamma}),(function(e){n("log","at platforms/app-plus/orientation/orientation.vue:34","获取失败:"+e.message)}))},watchOrient:function(){var e=this;Je||(Je=plus.orientation.watchOrientation((function(t){e.value="监听设备方向变化信息\nalpha："+t.alpha+"\nbeta："+t.beta+"\ngamma："+t.gamma}),(function(e){plus.orientation.clearWatch(Je),Je=null,n("log","at platforms/app-plus/orientation/orientation.vue:47","监听失败:"+e.message)})))},watchStop:function(){Je?(plus.orientation.clearWatch(Je),Je=null):n("log","at platforms/app-plus/orientation/orientation.vue:55","没有监听设备方向变化")}}};const Ke=t(Ge,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.getOrient&&r.getOrient(...e))},"获取设备的方向信息"),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.watchOrient&&r.watchOrient(...e))},"监听设备的方向变化"),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.watchStop&&r.watchStop(...e))},"停止监听")]),e.createElementVNode("view",{class:"uni-textarea"},[e.createElementVNode("textarea",{value:l.value},null,8,["value"])])])])}]]);var Qe=null,Ye=null;const Xe={data:()=>({title:"proximity",value:""}),methods:{getProximity:function(){var e=this;plus.proximity.getCurrentProximity((function(t){e.value="距离为："+t}),(function(t){e.value="获取失败:"+t.message}))},watchProximity:function(){var e=this;Qe||(Ye=plus.screen.getBrightness(),Qe=plus.proximity.watchProximity((function(t){e.value="距离变化："+t,plus.screen.setBrightness(t<1?.01:Ye)}),(function(t){plus.proximity.clearWatch(Qe),Qe=null,e.value="监听失败:"+t.message})))},watchStop:function(){Qe?(this.value="停止监听设备距离传感器信息",plus.proximity.clearWatch(Qe),Qe=null):this.value="没有监听设备距离传感器"}}};const Ze=t(Xe,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-hello-text"}," 手机顶部听筒处有传感器监听距离手机屏幕的障碍物，覆盖该传感器会触发本事件变化 "),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.getProximity&&r.getProximity(...e))},"获取距离传感器信息"),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.watchProximity&&r.watchProximity(...e))},"监听距离传感器变化"),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.watchStop&&r.watchStop(...e))},"停止监听")]),e.createElementVNode("view",{class:"uni-textarea uni-common-mt"},[e.createElementVNode("textarea",{value:l.value},null,8,["value"])])])])}]]),et={data:()=>({title:"push",provider:[],pushServer:"http://demo.dcloud.net.cn/push/?",tranMsg:""}),onLoad:function(){uni.getProvider({service:"push",success:e=>{n("log","at platforms/app-plus/push/push.vue:32","success",e),this.provider=e.provider},fail:e=>{n("log","at platforms/app-plus/push/push.vue:36","获取推送通道失败",e)}})},onUnload:function(){this.tranMsg=""},methods:{listenTranMsg(){plus.push.addEventListener("click",(e=>{this.tranMsg=JSON.stringify(e)})),plus.push.addEventListener("receive",(e=>{this.tranMsg=JSON.stringify(e)})),uni.showToast({title:"开始监听透传数据",icon:"success"})},requireTranMsg(){var e=plus.push.getClientInfo(),t=this.pushServer+"type=tran&appid="+encodeURIComponent(plus.runtime.appid);e.id&&(t+="&id="+e.id),t+="&cid="+encodeURIComponent(e.clientid),"iOS"==plus.os.name&&(t+="&token="+encodeURIComponent(e.token)),t+="&title="+encodeURIComponent("Hello uniapp"),t+="&content="+encodeURIComponent("带透传数据推送通知！"),"iOS"===plus.os.name?t+="&payload="+encodeURIComponent('{"title":"Hello uniapp Test","content":"test content"}'):t+="&payload="+encodeURIComponent('\'{"title":"Hello uniapp Test","content":"test content"}\''),t+="&version="+encodeURIComponent(plus.runtime.version),plus.runtime.openURL(t)}}};const tt=t(et,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),l.provider[0]?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.listenTranMsg&&r.listenTranMsg(...e))},"监听透传数据")]),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.requireTranMsg&&r.requireTranMsg(...e))},'发送"透传数据"消息')]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},"透传内容："),e.createElementVNode("view",{class:"uni-textarea"},[e.withDirectives(e.createElementVNode("textarea",{"onUpdate:modelValue":n[2]||(n[2]=e=>l.tranMsg=e)},null,512),[[e.vModelText,l.tranMsg]])])])):e.createCommentVNode("",!0)])}]]);const at=t({data:()=>({img:"https://web-assets.dcloud.net.cn/unidoc/zh/1.jpg",show:!1,isOpened:!1,index:1}),computed:{pageIndex(){return 1===this.index?"shake-1":2===this.index?"shake-2":3===this.index?"shake-3":4===this.index?"shake-4":"shake-1"}},onLoad:function(){this.music=uni.createInnerAudioContext(),this.music.src="https://web-assets.dcloud.net.cn/unidoc/zh/shake.wav";let e=null;uni.onAccelerometerChange((t=>{Math.abs(t.x)+Math.abs(t.y)+Math.abs(t.z)>20&&!this.show&&this.isOpened&&(this.music.play(),setTimeout((()=>{this.index++,this.index>4&&(this.index=1),this.img="https://web-ext-storage.dcloud.net.cn/hello-uni-app/"+this.pageIndex+".jpg"}),2e3),this.show=!0,e&&clearTimeout(e),e=setTimeout((()=>{e=null,this.show=!1}),600))}))},onShow(){this.isOpened=!0},onUnload(){this.show=!1,this.isOpened=!1,uni.stopAccelerometer(),this.music.destroy()}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"root",style:e.normalizeStyle({backgroundImage:"url("+o.img+")"})},[e.createElementVNode("view",{class:e.normalizeClass([o.show?"up":"","shake-up"])},[e.createElementVNode("image",{mode:"aspectFit",src:"https://web-assets.dcloud.net.cn/unidoc/zh/shakeup.png"})],2),e.createElementVNode("view",{class:e.normalizeClass([o.show?"down":"","shake-down"])},[e.createElementVNode("image",{mode:"aspectFit",src:"https://web-assets.dcloud.net.cn/unidoc/zh/shakedown.png"})],2)],4)}]]);const nt=t({name:"u-link",props:{href:{type:String,default:""},text:{type:String,default:""},inWhiteList:{type:Boolean,default:!1}},methods:{openURL(){plus.runtime.openURL(this.href)}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("text",{style:{"text-decoration":"underline"},href:n.href,onClick:a[0]||(a[0]=(...e)=>s.openURL&&s.openURL(...e)),inWhiteList:n.inWhiteList},e.toDisplayString(n.text),9,["href","inWhiteList"])}]]);const it=t({data:()=>({providerList:[],version:""}),onLoad(){this.version=plus.runtime.version,uni.getProvider({service:"share",success:e=>{const t=[];for(let a=0;a<e.provider.length;a++)switch(e.provider[a]){case"weixin":t.push({name:"分享到微信好友",id:"weixin"}),t.push({name:"分享到微信朋友圈",id:"weixin",type:"WXSceneTimeline"});break;case"qq":t.push({name:"分享到QQ",id:"qq"})}this.providerList=t},fail:e=>{n("log","at pages/about/about.vue:78","获取分享通道失败"+JSON.stringify(e))}})},methods:{save(){uni.showActionSheet({itemList:["保存图片到相册"],success:()=>{plus.gallery.save("https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/app_download.png",(function(){uni.showToast({title:"保存成功",icon:"none"})}),(function(){uni.showToast({title:"保存失败，请重试！",icon:"none"})}))}})},share(e){if(0===this.providerList.length)return void uni.showModal({title:"当前环境无分享渠道!",showCancel:!1});let t=this.providerList.map((function(e){return e.name}));uni.showActionSheet({itemList:t,success:e=>{let t=this.providerList[e.tapIndex].id;uni.share({provider:t,scene:this.providerList[e.tapIndex].type&&"WXSceneTimeline"===this.providerList[e.tapIndex].type?"WXSceneTimeline":"WXSceneSession",type:"qq"===t?1:0,title:"欢迎体验uni-app",summary:"uni-app 是一个使用 Vue.js 开发跨平台应用的前端框架",imageUrl:"https://web-assets.dcloud.net.cn/unidoc/zh/8.jpg",href:"https://m3w.cn/uniapp",success:e=>{n("log","at pages/about/about.vue:128","success:"+JSON.stringify(e))},fail:e=>{uni.showModal({content:e.errMsg,showCancel:!1})}})}})}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("u-link"),nt);return e.openBlock(),e.createElementBlock("view",{class:"about"},[e.createElementVNode("view",{class:"content"},[e.createElementVNode("view",{class:"qrcode"},[e.createElementVNode("image",{src:"https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/app_download.png",onLongtap:a[0]||(a[0]=(...e)=>l.save&&l.save(...e))},null,32),e.createElementVNode("text",{class:"tip"},"扫码体验uni-app")]),e.createElementVNode("view",{class:"desc"},[e.createElementVNode("text",{class:"code"},"uni-app"),e.createTextVNode(" 是一个使用 "),e.createElementVNode("text",{class:"code"},"Vue.js"),e.createTextVNode(" 开发跨平台应用的前端框架。 ")]),e.createElementVNode("view",{class:"source"},[e.createElementVNode("view",{class:"title"},"本示例源码获取方式："),e.createElementVNode("view",{class:"source-list"},[e.createElementVNode("view",{class:"source-cell"},[e.createElementVNode("text",{space:"nbsp"},"1. "),e.createElementVNode("text",null,[e.createTextVNode("下载 HBuilderX，新建 uni-app 项目时选择 "),e.createElementVNode("text",{class:"code"},"Hello uni-app"),e.createTextVNode(" 模板。")])]),e.createElementVNode("view",{class:"source-cell"},[e.createElementVNode("text",{space:"nbsp"},"2. "),e.createVNode(r,{class:"link",href:"https://github.com/dcloudio/hello-uniapp",text:"https://github.com/dcloudio/hello-uniapp"},null,8,["href","text"])])])]),e.createElementVNode("button",{type:"primary",onClick:a[1]||(a[1]=(...e)=>l.share&&l.share(...e))},"分享")]),e.createElementVNode("view",{class:"version"}," 当前版本："+e.toDisplayString(s.version),1)])}]]),ot={name:"UniRate",props:{isFill:{type:[Boolean,String],default:!0},color:{type:String,default:"#ececec"},activeColor:{type:String,default:"#ffca3e"},disabledColor:{type:String,default:"#c0c0c0"},size:{type:[Number,String],default:24},value:{type:[Number,String],default:0},modelValue:{type:[Number,String],default:0},max:{type:[Number,String],default:5},margin:{type:[Number,String],default:0},disabled:{type:[Boolean,String],default:!1},readonly:{type:[Boolean,String],default:!1},allowHalf:{type:[Boolean,String],default:!1},touchable:{type:[Boolean,String],default:!0}},data:()=>({valueSync:"",userMouseFristMove:!0,userRated:!1,userLastRate:1}),watch:{value(e){this.valueSync=Number(e)},modelValue(e){this.valueSync=Number(e)}},computed:{stars(){const e=this.valueSync?this.valueSync:0,t=[],a=Math.floor(e),n=Math.ceil(e);for(let i=0;i<this.max;i++)a>i?t.push({activeWitch:"100%"}):n-1===i?t.push({activeWitch:100*(e-a)+"%"}):t.push({activeWitch:"0"});return t},marginNumber(){return Number(this.margin)}},created(){this.valueSync=Number(this.value||this.modelValue),this._rateBoxLeft=0,this._oldValue=null},mounted(){setTimeout((()=>{this._getSize()}),100)},methods:{touchstart(e){if(this.readonly||this.disabled)return;const{clientX:t,screenX:a}=e.changedTouches[0];this._getRateCount(t||a)},touchmove(e){if(this.readonly||this.disabled||!this.touchable)return;const{clientX:t,screenX:a}=e.changedTouches[0];this._getRateCount(t||a)},mousedown(e){},mousemove(e){},mouseleave(e){},_getRateCount(e){this._getSize();const t=Number(this.size);if(isNaN(t))return new Error("size 属性只能设置为数字");const a=e-this._rateBoxLeft;let n=parseInt(a/(t+this.marginNumber));n=n<0?0:n,n=n>this.max?this.max:n;const i=parseInt(a-(t+this.marginNumber)*n);let o=0;(this._oldValue!==n||this.PC)&&(this._oldValue=n,o=this.allowHalf?i>t/2?n+1:n+.5:n+1,o=Math.max(.5,Math.min(o,this.max)),this.valueSync=o,this._onChange())},_onChange(){this.$emit("input",this.valueSync),this.$emit("update:modelValue",this.valueSync),this.$emit("change",{value:this.valueSync})},_getSize(){uni.createSelectorQuery().in(this).select(".uni-rate").boundingClientRect().exec((e=>{e&&(this._rateBoxLeft=e[0].left)}))}}};const st=t(ot,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{ref:"uni-rate",class:"uni-rate"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.stars,((t,i)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-rate__icon",{"uni-cursor-not-allowed":n.disabled}]),style:e.normalizeStyle({"margin-right":l.marginNumber+"px"}),key:i,onTouchstart:a[0]||(a[0]=e.withModifiers(((...e)=>l.touchstart&&l.touchstart(...e)),["stop"])),onTouchmove:a[1]||(a[1]=e.withModifiers(((...e)=>l.touchmove&&l.touchmove(...e)),["stop"])),onMousedown:a[2]||(a[2]=e.withModifiers(((...e)=>l.mousedown&&l.mousedown(...e)),["stop"])),onMousemove:a[3]||(a[3]=e.withModifiers(((...e)=>l.mousemove&&l.mousemove(...e)),["stop"])),onMouseleave:a[4]||(a[4]=(...e)=>l.mouseleave&&l.mouseleave(...e))},[e.createVNode(r,{color:n.color,size:n.size,type:n.isFill?"star-filled":"star"},null,8,["color","size","type"]),e.createElementVNode("view",{style:e.normalizeStyle({width:t.activeWitch}),class:"uni-rate__icon-on"},[e.createVNode(r,{color:n.disabled?n.disabledColor:n.activeColor,size:n.size,type:"star-filled"},null,8,["color","size"])],4)],38)))),128))],512)])}],["__scopeId","data-v-77c606f8"]]),lt={data:()=>({msgContents:["界面显示错乱","启动缓慢，卡出翔了","UI无法直视，丑哭了","偶发性崩溃"],stars:[1,2,3,4,5],imageList:[],sendDate:{score:0,content:"",contact:""}}),onLoad(){this.deviceInfo={appid:"__UNI__5D0B0CA",imei:plus.device.imei,p:"Android"===plus.os.name?"a":"i",md:plus.device.model,app_version:plus.runtime.version,plus_version:plus.runtime.innerVersion,os:plus.os.version,net:""+plus.networkinfo.getCurrentType()},this.sendDate=Object.assign(this.deviceInfo,this.sendDate)},methods:{close(e){this.imageList.splice(e,1)},chooseMsg(){uni.showActionSheet({itemList:this.msgContents,success:e=>{this.sendDate.content=this.msgContents[e.tapIndex]}})},chooseImg(){uni.chooseImage({sourceType:["camera","album"],sizeType:"compressed",count:5-this.imageList.length,success:e=>{this.imageList=this.imageList.concat(e.tempFilePaths)}})},chooseStar(e){this.sendDate.score=e},previewImage(e){uni.previewImage({urls:this.imageList,current:this.imageList[e]})},send(){if(0===this.sendDate.content.length)return void uni.showModal({content:"请输入问题和意见",showCancel:!1});uni.showLoading({title:"上传中..."});let e=this.imageList.map(((e,t)=>({name:"images"+t,uri:e})));this.request(this.sendDate,e).then((e=>{"string"==typeof e.data&&(e.data=JSON.parse(e.data)),200===e.statusCode&&e.data&&0===e.data.ret?(uni.showModal({content:"反馈成功",showCancel:!1}),this.imageList=[],this.sendDate=Object.assign(this.deviceInfo,{score:0,content:"",contact:""})):200!==e.statusCode?uni.showModal({content:"反馈失败，错误码为："+e.statusCode,showCancel:!1}):uni.showModal({content:"反馈失败",showCancel:!1})})).catch((e=>{n("log","at platforms/app-plus/feedback/feedback.vue:173",e)}))},request:(e,t)=>new Promise(((a,n)=>{let i={url:"https://service.dcloud.net.cn/feedback",success:e=>{a(e)},fail:e=>{n(e)},complete(){uni.hideLoading()}};t.length>0?(i.files=t,i.formData=e,uni.uploadFile(i)):(i.data=e,i.method="POST",uni.request(i))}))}};const rt=t(lt,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-rate"),st);return e.openBlock(),e.createElementBlock("view",{class:"page"},[e.createElementVNode("view",{class:"feedback-title"},[e.createElementVNode("text",null,"问题和意见"),e.createElementVNode("text",{class:"feedback-quick",onClick:a[0]||(a[0]=(...e)=>l.chooseMsg&&l.chooseMsg(...e))},"快速键入")]),e.createElementVNode("view",{class:"feedback-body"},[e.withDirectives(e.createElementVNode("textarea",{placeholder:"请详细描述你的问题和意见...","onUpdate:modelValue":a[1]||(a[1]=e=>s.sendDate.content=e),class:"feedback-textare"},null,512),[[e.vModelText,s.sendDate.content]])]),e.createElementVNode("view",{class:"feedback-title"},[e.createElementVNode("text",null,"图片(选填,提供问题截图,总大小10M以下)")]),e.createElementVNode("view",{class:"feedback-body feedback-uploader"},[e.createElementVNode("view",{class:"uni-uploader"},[e.createElementVNode("view",{class:"uni-uploader-head"},[e.createElementVNode("view",{class:"uni-uploader-title"},"点击预览图片"),e.createElementVNode("view",{class:"uni-uploader-info"},e.toDisplayString(s.imageList.length)+"/5",1)]),e.createElementVNode("view",{class:"uni-uploader-body"},[e.createElementVNode("view",{class:"uni-uploader__files"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.imageList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"uni-uploader__file",style:{position:"relative"}},[e.createElementVNode("image",{class:"uni-uploader__img",src:t,onClick:e=>l.previewImage(a)},null,8,["src","onClick"]),e.createElementVNode("view",{class:"close-view",onClick:e=>l.close(a)},"x",8,["onClick"])])))),128)),e.withDirectives(e.createElementVNode("view",{class:"uni-uploader__input-box"},[e.createElementVNode("view",{class:"uni-uploader__input",onClick:a[2]||(a[2]=(...e)=>l.chooseImg&&l.chooseImg(...e))})],512),[[e.vShow,s.imageList.length<5]])])])])]),e.createElementVNode("view",{class:"feedback-title"},[e.createElementVNode("text",null,"QQ/邮箱")]),e.createElementVNode("view",{class:"feedback-body"},[e.withDirectives(e.createElementVNode("input",{class:"feedback-input","onUpdate:modelValue":a[3]||(a[3]=e=>s.sendDate.contact=e),placeholder:"(选填,方便我们联系你 )"},null,512),[[e.vModelText,s.sendDate.contact]])]),e.createElementVNode("view",{class:"feedback-title feedback-star-view"},[e.createElementVNode("text",null,"应用评分"),e.createElementVNode("view",{class:"feedback-star-view"},[e.createVNode(r,{modelValue:s.sendDate.score,"onUpdate:modelValue":a[4]||(a[4]=e=>s.sendDate.score=e),color:"#bbb"},null,8,["modelValue"])])]),e.createElementVNode("button",{type:"default",class:"feedback-submit",onClick:a[5]||(a[5]=(...e)=>l.send&&l.send(...e))},"提交"),e.createElementVNode("view",{class:"feedback-title"},[e.createElementVNode("text",null,"用户反馈的结果可在app打包后于DCloud开发者中心查看")])])}]]),{registerUTSInterface:ct,initUTSProxyClass:dt,initUTSProxyFunction:ut,initUTSPackageName:ht,initUTSIndexClassName:pt,initUTSClassName:mt}=uni,gt="utsProgressNotification",ft="uts-progressNotification",yt=ht(gt,true),vt=pt(gt,true),wt=ut(!1,{moduleName:ft,moduleType:"",errMsg:"",main:!0,package:yt,class:vt,name:"createNotificationProgressByJs",keepAlive:!1,params:[{name:"options",type:"UTSSDKModulesUtsProgressNotificationCreateNotificationProgressOptionsJSONObject"}],return:""}),bt=ut(!1,{moduleName:ft,moduleType:"",errMsg:"",main:!0,package:yt,class:vt,name:"cancelNotificationProgressByJs",keepAlive:!1,params:[],return:""}),kt=ut(!1,{moduleName:ft,moduleType:"",errMsg:"",main:!0,package:yt,class:vt,name:"finishNotificationProgressByJs",keepAlive:!1,params:[{name:"options",type:"UTSSDKModulesUtsProgressNotificationFinishNotificationProgressOptionsJSONObject"}],return:""}),xt="UNI_ADMIN_UPGRADE_CENTER_LOCAL_FILE_PATH";let Vt,Nt=null;const Et={data:()=>({installForBeforeFilePath:"",installed:!1,installing:!1,downloadSuccess:!1,downloading:!1,downLoadPercent:0,downloadedSize:0,packageFileSize:0,tempFilePath:"",title:"更新日志",contents:"",version:"",is_mandatory:!1,url:"",platform:[],store_list:null,subTitle:"发现新版本",downLoadBtnTextiOS:"立即跳转更新",downLoadBtnText:"立即下载更新",downLoadingText:"安装包下载中，请稍后"}),onLoad({local_storage_key:e}){if(!e)return n("error","at uni_modules/uni-upgrade-center-app/pages/upgrade-popup.vue:159","local_storage_key为空，请检查后重试"),void uni.navigateBack();const t=uni.getStorageSync(e);if(!t)return n("error","at uni_modules/uni-upgrade-center-app/pages/upgrade-popup.vue:166","安装包信息为空，请检查后重试"),void uni.navigateBack();const a=["version","url","type"];for(let i in t)if(-1!==a.indexOf(i)&&!t[i])return n("error","at uni_modules/uni-upgrade-center-app/pages/upgrade-popup.vue:174",`参数 ${i} 必填，请检查后重试`),void uni.navigateBack();Object.assign(this,t),this.checkLocalStoragePackage()},onBackPress(){if(this.is_mandatory)return!0;this.needNotificationProgress||Nt&&Nt.abort()},onHide(){Vt=null},computed:{isWGT(){return"wgt"===this.type},isiOS(){return!this.isWGT&&-1!==this.platform.indexOf("iOS")},isAndroid(){return-1!==this.platform.indexOf("Android")},isAppStore(){return this.isiOS||!this.isiOS&&!this.isWGT&&-1===this.url.indexOf(".apk")},needNotificationProgress(){return-1===this.platform.indexOf("iOS")&&!this.is_mandatory}},methods:{checkLocalStoragePackage(){const e=uni.getStorageSync(xt);if(e){const{version:t,savedFilePath:a,installed:n}=e;n||0!==function(e="0",t="0"){e=String(e).split("."),t=String(t).split(".");const a=Math.min(e.length,t.length);let n=0;for(let i=0;i<a;i++){const a=Number(e[i]),o=Number(t[i]);if(a>o){n=1;break}if(a<o){n=-1;break}}if(0===n&&e.length!==t.length){const i=e.length>t.length,o=i?e:t;for(let e=a;e<o.length;e++)if(Number(o[e])>0){n=i?1:-1;break}}return n}(t,this.version)?this.deleteSavedFile(a):(this.downloadSuccess=!0,this.installForBeforeFilePath=a,this.tempFilePath=a)}},askAbortDownload(){uni.showModal({title:"是否取消下载？",cancelText:"否",confirmText:"是",success:e=>{e.confirm&&(Nt&&Nt.abort(),bt(),uni.navigateBack())}})},async closeUpdate(){if(this.downloading){if(this.is_mandatory)return uni.showToast({title:"下载中，请稍后……",icon:"none",duration:500});if(!this.needNotificationProgress)return void this.askAbortDownload()}!this.needNotificationProgress&&this.downloadSuccess&&this.tempFilePath&&await this.saveFile(this.tempFilePath,this.version),uni.navigateBack()},updateApp(){this.checkStoreScheme().catch((()=>{this.downloadPackage()})).finally((()=>{Vt=null}))},checkStoreScheme(){const e=(this.store_list||[]).filter((e=>e.enable));return e&&e.length?(e.sort(((e,t)=>t.priority-e.priority)).map((e=>e.scheme)).reduce(((e,t,a)=>(Vt=(e||(e=Promise.reject())).catch((()=>new Promise(((e,a)=>{plus.runtime.openURL(t,(e=>{a(e)}))})))),Vt)),Vt),Vt):Promise.reject()},downloadPackage(){this.downloading=!0,Nt=uni.downloadFile({url:this.url,success:e=>{if(200==e.statusCode)if(this.isWGT&&"wgt"!==e.tempFilePath.split(".").slice(-1)[0]){const t=e=>{n("log","at uni_modules/uni-upgrade-center-app/pages/upgrade-popup.vue:308","[FILE RENAME FAIL]：",JSON.stringify(e))};plus.io.resolveLocalFileSystemURL(e.tempFilePath,(e=>{e.getParent((a=>{const n=`new_wgt_${Date.now()}.wgt`;e.copyTo(a,n,(e=>{this.tempFilePath=e.fullPath,this.downLoadComplete()}),t)}),t)}),t)}else this.tempFilePath=e.tempFilePath,this.downLoadComplete()}}),Nt.onProgressUpdate((e=>{this.downLoadPercent=e.progress,this.downloadedSize=(e.totalBytesWritten/Math.pow(1024,2)).toFixed(2),this.packageFileSize=(e.totalBytesExpectedToWrite/Math.pow(1024,2)).toFixed(2),this.needNotificationProgress&&!this.downloadSuccess&&wt({title:"升级中心正在下载安装包……",content:`${this.downLoadPercent}%`,progress:this.downLoadPercent,onClick:()=>{this.askAbortDownload()}})})),this.needNotificationProgress&&uni.navigateBack()},downLoadComplete(){if(this.downloadSuccess=!0,this.downloading=!1,this.downLoadPercent=0,this.downloadedSize=0,this.packageFileSize=0,Nt=null,this.needNotificationProgress)return kt({title:"安装升级包",content:"下载完成"}),void this.installPackage();this.is_mandatory&&this.installPackage()},installPackage(){this.isWGT&&(this.installing=!0),plus.runtime.install(this.tempFilePath,{force:!1},(async e=>{if(this.installing=!1,this.installed=!0,this.isWGT)this.is_mandatory&&(uni.showLoading({icon:"none",title:"安装成功，正在重启……"}),setTimeout((()=>{uni.hideLoading(),this.restart()}),1e3));else{const e=uni.getStorageSync(xt);uni.setStorageSync(xt,{...e,installed:!0})}}),(async e=>{this.installForBeforeFilePath&&(await this.deleteSavedFile(this.installForBeforeFilePath),this.installForBeforeFilePath=""),this.installing=!1,this.installed=!1,uni.showModal({title:"更新失败，请重新下载",content:e.message,showCancel:!1})})),this.isWGT||this.is_mandatory||uni.navigateBack()},restart(){this.installed=!1,plus.runtime.restart()},saveFile:(e,t)=>new Promise(((a,n)=>{uni.saveFile({tempFilePath:e,success({savedFilePath:e}){uni.setStorageSync(xt,{version:t,savedFilePath:e})},complete(){a()}})})),deleteSavedFile:e=>(uni.removeStorageSync(xt),uni.removeSavedFile({filePath:e})),jumpToAppStore(){plus.runtime.openURL(this.url)}}};const Ct=t(Et,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"mask flex-center"},[e.createElementVNode("view",{class:"content botton-radius"},[e.createElementVNode("view",{class:"content-top"},[e.createElementVNode("text",{class:"content-top-text"},e.toDisplayString(o.title),1),e.createElementVNode("image",{class:"content-top",style:{top:"0"},width:"100%",height:"100%",src:"/uni_modules/uni-upgrade-center-app/static/bg_top.png"})]),e.createElementVNode("view",{class:"content-header"}),e.createElementVNode("view",{class:"content-body"},[e.createElementVNode("view",{class:"title"},[e.createElementVNode("text",null,e.toDisplayString(o.subTitle),1),e.createElementVNode("text",{class:"content-body-version"},e.toDisplayString(o.version),1)]),e.createElementVNode("view",{class:"body"},[e.createElementVNode("scroll-view",{class:"box-des-scroll","scroll-y":"true"},[e.createElementVNode("text",{class:"box-des"},e.toDisplayString(o.contents),1)])]),e.createElementVNode("view",{class:"footer flex-center"},[s.isAppStore?(e.openBlock(),e.createElementBlock("button",{key:0,class:"content-button",style:{border:"none",color:"#fff"},plain:"",onClick:a[0]||(a[0]=(...e)=>s.jumpToAppStore&&s.jumpToAppStore(...e))},e.toDisplayString(o.downLoadBtnTextiOS),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[o.downloadSuccess?o.downloadSuccess&&!o.installed?(e.openBlock(),e.createElementBlock("button",{key:1,class:"content-button",style:{border:"none",color:"#fff"},plain:"",loading:o.installing,disabled:o.installing,onClick:a[2]||(a[2]=(...e)=>s.installPackage&&s.installPackage(...e))},e.toDisplayString(o.installing?"正在安装……":"下载完成，立即安装"),9,["loading","disabled"])):o.installed&&!s.isWGT?(e.openBlock(),e.createElementBlock("button",{key:2,class:"content-button",style:{border:"none",color:"#fff"},plain:"",loading:o.installing,disabled:o.installing,onClick:a[3]||(a[3]=(...e)=>s.installPackage&&s.installPackage(...e))}," 安装未完成，点击安装 ",8,["loading","disabled"])):o.installed&&s.isWGT?(e.openBlock(),e.createElementBlock("button",{key:3,class:"content-button",style:{border:"none",color:"#fff"},plain:"",onClick:a[4]||(a[4]=(...e)=>s.restart&&s.restart(...e))}," 安装完毕，点击重启 ")):e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[o.downloading?(e.openBlock(),e.createElementBlock("view",{key:0,class:"progress-box flex-column"},[e.createElementVNode("progress",{class:"progress",percent:o.downLoadPercent,activeColor:"#3DA7FF","show-info":"","stroke-width":"10"},null,8,["percent"]),e.createElementVNode("view",{style:{width:"100%","font-size":"28rpx",display:"flex","justify-content":"space-around"}},[e.createElementVNode("text",null,e.toDisplayString(o.downLoadingText),1),e.createElementVNode("text",null,"("+e.toDisplayString(o.downloadedSize)+"/"+e.toDisplayString(o.packageFileSize)+"M)",1)])])):(e.openBlock(),e.createElementBlock("button",{key:1,class:"content-button",style:{border:"none",color:"#fff"},plain:"",onClick:a[1]||(a[1]=(...e)=>s.updateApp&&s.updateApp(...e))},e.toDisplayString(o.downLoadBtnText),1))],64))],64))])]),o.is_mandatory?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("image",{key:0,class:"close-img",src:"/uni_modules/uni-upgrade-center-app/static/app_update_close.png",onClick:a[5]||(a[5]=e.withModifiers(((...e)=>s.closeUpdate&&s.closeUpdate(...e)),["stop"]))}))])])}]]),_t="univerifyInfo",St={data:()=>({title:"login",providerList:[],phoneNumber:"",univerifyBtnLoading:!1}),computed:{...ve(["hasLogin","isUniverifyLogin","univerifyErrorMsg"])},onLoad(){uni.getProvider({service:"oauth",success:e=>{this.providerList=e.provider.map((e=>{let t="";switch(e){case"weixin":t="微信登录";break;case"qq":t="QQ登录";break;case"sinaweibo":t="新浪微博登录";break;case"xiaomi":t="小米登录";break;case"alipay":t="支付宝登录";break;case"baidu":t="百度登录";break;case"jd":t="京东登录";break;case"toutiao":t="头条登录";break;case"apple":t="苹果登录";break;case"univerify":t="一键登录";break;case"huawei":t="华为登录"}return{name:t,id:e}}))},fail:e=>{n("log","at pages/API/login/login.vue:107","获取登录通道失败",e)}}),this.hasLogin&&this.isUniverifyLogin&&this.getPhoneNumber(uni.getStorageSync(_t)).then((e=>{this.phoneNumber=e}))},methods:{...we(["login","setUniverifyLogin"]),...ke(["getPhoneNumber"]),Toast(e,t=1e3){uni.showToast(Object.assign({},e,{duration:t}))},tologin(e){"univerify"===e.id&&(this.univerifyBtnLoading=!0),uni.login({provider:e.id,success:async t=>{switch(n("log","at pages/API/login/login.vue:137","login success:",t),this.Toast({title:"登录成功"}),this.login(e.id),this.setUniverifyLogin("univerify"===e.id),e.id){case"univerify":this.loginByUniverify(e.id,t);break;case"apple":this.loginByApple(e.id,t)}},fail:e=>{if(n("log","at pages/API/login/login.vue:183","login fail:",e),"30002"==e.code)return uni.closeAuthView(),void this.Toast({title:"其他登录方式"});1e3!=e.code?"30005"!=e.code?"30003"!=e.code&&uni.showModal({showCancel:!1,title:"登录失败",content:JSON.stringify(e)}):uni.showModal({showCancel:!1,title:"预登录失败",content:this.univerifyErrorMsg||e.errMsg}):uni.showModal({title:"登录失败",content:`${e.errMsg}\n，错误码：${e.code}`,confirmText:"开通指南",cancelText:"确定",success:e=>{e.confirm&&setTimeout((()=>{plus.runtime.openWeb("https://ask.dcloud.net.cn/article/37965")}),500)}})},complete:()=>{this.univerifyBtnLoading=!1}})},loginByUniverify(e,t){this.setUniverifyLogin(!0),uni.closeAuthView();const a={provider:e,...t.authResult};this.getPhoneNumber(a).then((e=>{this.phoneNumber=e,uni.setStorageSync(_t,a)})).catch((e=>{uni.showModal({showCancel:!1,title:"手机号获取失败",content:`${e.errMsg}\n，错误码：${e.code}`}),n("error","at pages/API/login/login.vue:254",t)}))},async loginByApple(e,t){let a,i;try{i=await uni.getUserInfo({provider:e})}catch($i){a=$i}if(a){let e=a.errMsg;~e.indexOf("uni.login")&&(e="请在登录页面完成登录操作"),uni.showModal({title:"获取用户信息失败",content:"错误原因"+e,showCancel:!1})}n("warn","at pages/API/login/login.vue:288","此处使用uni-id处理苹果登录，详情参考: https://uniapp.dcloud.net.cn/uniCloud/uni-id"),uni.request({url:"https://97fca9f2-41f6-449f-a35e-3f135d4c3875.bspapp.com/http/user-center",method:"POST",data:{action:"loginByApple",params:i.userInfo},success:e=>{n("log","at pages/API/login/login.vue:297","uniId login success",e),0!==e.data.code?uni.showModal({showCancel:!1,content:`苹果登录失败: ${JSON.stringify(e.data.msg)}`}):(uni.setStorageSync("openid",e.data.openid),uni.setStorageSync("apple_nickname",e.data.userInfo.nickname))},fail:e=>{uni.showModal({content:`苹果登录失败: ${JSON.stringify(e)}`,showCancel:!1})}})}}};const Tt=t(St,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{style:{background:"#FFF",padding:"40rpx"}},[!0===t.hasLogin?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("view",{class:"uni-h3 uni-center uni-common-mt"},[e.createTextVNode("已登录 "),t.isUniverifyLogin?(e.openBlock(),e.createElementBlock("text",{key:0,style:{"font-size":"0.8em"}},[l.phoneNumber.length?(e.openBlock(),e.createElementBlock("i",{key:1},"（"+e.toDisplayString(l.phoneNumber)+"）",1)):(e.openBlock(),e.createElementBlock("i",{key:0,class:"uni-icon_toast uni-loading"}))])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-hello-text uni-center"},[e.createElementVNode("text",null,"每个账号仅需登录 1 次，\\n后续每次进入页面即可自动拉取用户信息。")])],64)):e.createCommentVNode("",!0),!1===t.hasLogin?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"uni-h3 uni-center uni-common-mt"},"未登录"),e.createElementVNode("view",{class:"uni-hello-text uni-center"}," 请点击按钮登录 ")],64)):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-btn-v uni- uni-common-mt"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.providerList,((t,a)=>(e.openBlock(),e.createElementBlock("button",{type:"primary",class:"page-body-button",onClick:e=>r.tologin(t),loading:"univerify"===t.id&&l.univerifyBtnLoading,key:a},e.toDisplayString(t.name),9,["onClick","loading"])))),128))])])])}]]);const Bt=t({data:()=>({title:"SubNvue",showVideo:!1}),onLoad(){this.closeMask(),uni.$on("popup-page",(e=>{if("interactive"===e.type)uni.showModal({title:"来自Popup的消息",content:e.info});else uni.showToast({title:e.title})})),uni.$on("drawer-page",(e=>{uni.showToast({title:"点击了第"+e+"项",icon:"none"})}))},onUnload(){uni.$off("popup-page"),uni.$off("drawer-page")},onReady(){this.showVideo=!0},methods:{showDrawer(){uni.getSubNVueById("drawer").show("slide-in-left",200)},showPopup(){uni.$emit("page-popup",{title:"请阅读软件内容",content:"uni-app 是一个使用 Vue.js 开发跨平台应用的前端框架，开发者编写一套代码，可编译到iOS、Android、H5、小程序等多个平台。"});uni.getSubNVueById("popup").show("slide-in-top",250)},videoErrorCallback:function(){uni.showModal({content:"视频加载失败",showCancel:!1})},playVideo(){uni.getSubNVueById("video_mask").show("fade-in",200,(()=>{uni.$emit("play-video",{status:"open"})}))},closeMask(){let e=uni.getSubNVueById("video_mask");uni.$emit("close-video",{status:"close"}),e.hide("fade-out",200)}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"content"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"example"},[e.createElementVNode("view",{class:"example-title"},"从左侧滑出"),e.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>r.showDrawer&&r.showDrawer(...e))},"显示抽屉")]),e.createElementVNode("view",{class:"example"},[e.createElementVNode("view",{class:"example-title"},"从上侧竖向滑出"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.showPopup&&r.showPopup(...e))},"显示 弹出层")]),e.createElementVNode("view",{style:{width:"100%"}},[l.showVideo?(e.openBlock(),e.createElementBlock("video",{key:0,id:"video",onPlay:n[2]||(n[2]=(...e)=>r.playVideo&&r.playVideo(...e)),onPause:n[3]||(n[3]=(...e)=>r.closeMask&&r.closeMask(...e)),controls:!1,src:"https://img.cdn.aliyun.dcloud.net.cn/guide/uniapp/%E7%AC%AC1%E8%AE%B2%EF%BC%88uni-app%E4%BA%A7%E5%93%81%E4%BB%8B%E7%BB%8D%EF%BC%89-%20DCloud%E5%AE%98%E6%96%B9%E8%A7%86%E9%A2%91%E6%95%99%E7%A8%8B@20181126-lite.m4v",onError:n[4]||(n[4]=(...e)=>r.videoErrorCallback&&r.videoErrorCallback(...e)),poster:"https://web-assets.dcloud.net.cn/unidoc/zh/poster.png"},null,32)):e.createCommentVNode("",!0)])])}]]);const Dt=t({data:()=>({title:"getUserInfo",hasUserInfo:!1,userInfo:{},btnLoading:!1}),computed:{...ve(["loginProvider","isUniverifyLogin"])},methods:{...ke(["getPhoneNumber"]),getUserInfo(){if(this.btnLoading=!0,this.isUniverifyLogin)this.getPhoneNumber(uni.getStorageSync("univerifyInfo")).then((e=>{this.hasUserInfo=!0,this.userInfo={phoneNumber:e}})).catch((e=>{n("error","at pages/API/get-user-info/get-user-info.vue:65","getUserInfo fail:",e),this.hasUserInfo=!1})).finally((()=>{this.btnLoading=!1}));else{if("apple"===this.loginProvider){const e=uni.getStorageSync("apple_nickname");if(e)return this.hasUserInfo=!0,this.userInfo={nickName:e},void(this.btnLoading=!1)}uni.getUserInfo({provider:this.loginProvider,success:e=>{this.hasUserInfo=!0,this.userInfo=e.userInfo},fail:e=>{n("log","at pages/API/get-user-info/get-user-info.vue:90","getUserInfo fail",e);let t=e.errMsg;~t.indexOf("uni.login")&&(t="请在登录页面完成登录操作"),uni.showModal({title:"获取用户信息失败",content:"错误原因"+t,showCancel:!1})},complete:()=>{this.btnLoading=!1}})}},mpGetUserInfo(e){n("log","at pages/API/get-user-info/get-user-info.vue:133","mpGetUserInfo",e),"getUserInfo:ok"===e.detail.errMsg?(this.hasUserInfo=!0,e.detail&&e.detail.userInfo&&(this.userInfo=e.detail.userInfo)):uni.showModal({title:"获取用户信息失败",content:"错误原因"+e.detail.errMsg,showCancel:!1})},clear(){this.hasUserInfo=!1,this.userInfo={}}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{style:{background:"#FFF",padding:"40rpx"}},[!1===l.hasUserInfo?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-hello-text uni-center"},[e.createElementVNode("text",null,"请点击下方按钮获取用户头像及昵称或手机号")])):e.createCommentVNode("",!0),!0===l.hasUserInfo?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"uni-h4 uni-center uni-common-mt"},e.toDisplayString(l.userInfo.nickName||l.userInfo.nickname||l.userInfo.gender||l.userInfo.email||l.userInfo.phoneNumber),1),l.userInfo.avatarUrl||l.userInfo.avatar_url?(e.openBlock(),e.createElementBlock("view",{key:0,style:{padding:"30rpx 0","text-align":"center"}},[e.createElementVNode("image",{class:"userinfo-avatar",src:l.userInfo.avatarUrl||l.userInfo.avatar_url},null,8,["src"])])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",loading:l.btnLoading,onClick:n[0]||(n[0]=(...e)=>r.getUserInfo&&r.getUserInfo(...e))},"获取用户信息",8,["loading"]),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.clear&&r.clear(...e))},"清空")])])])}]]),It={data:()=>({title:"request-payment",loading:!1,price:1,providerList:[]}),onLoad:function(){uni.getProvider({service:"payment",success:e=>{n("log","at pages/API/request-payment/request-payment.vue:40","payment success:"+JSON.stringify(e));let t=[];e.provider.map((e=>{switch(e){case"alipay":t.push({name:"支付宝",id:e,loading:!1});break;case"wxpay":t.push({name:"微信",id:e,loading:!1});break;case"huawei":t.push({name:"华为",id:e,loading:!1})}})),this.providerList=t},fail:e=>{n("log","at pages/API/request-payment/request-payment.vue:72","获取支付通道失败：",e)}})},methods:{loginMpWeixin:()=>new Promise(((e,t)=>{uni.login({provider:"weixin",success(a){n("warn","at pages/API/request-payment/request-payment.vue:83","此处使用uni-id处理微信小程序登录，详情参考: https://uniapp.dcloud.net.cn/uniCloud/uni-id"),uni.request({url:"https://97fca9f2-41f6-449f-a35e-3f135d4c3875.bspapp.com/http/user-center",method:"POST",data:{action:"loginByWeixin",params:{code:a.code,platform:"mp-weixin"}},success(a){0===a.data.code?(uni.setStorageSync("openid",a.data.openid),e(a.data.openid)):t(new Error("获取openid失败：",a.result.msg))},fail(e){t(new Error("获取openid失败："+e))}})},fail(e){t(e)}})})),async weixinPay(){let e=uni.getStorageSync("openid");if(n("log","at pages/API/request-payment/request-payment.vue:115","发起支付"),this.loading=!0,!e){try{e=await this.loginMpWeixin()}catch($i){n("error","at pages/API/request-payment/request-payment.vue:121",$i)}if(!e)return uni.showModal({content:"获取openid失败",showCancel:!1}),void(this.loading=!1)}this.openid=e;let t=await this.getOrderInfo("wxpay");t?uni.requestPayment({...t,success:e=>{uni.showToast({title:"感谢您的赞助!"})},fail:e=>{uni.showModal({content:"支付失败,原因为: "+e.errMsg,showCancel:!1})},complete:()=>{this.loading=!1}}):uni.showModal({content:"获取支付信息失败",showCancel:!1})},async requestPayment(e,t){this.providerList[t].loading=!0;const a=e.id;let i=await this.getOrderInfo(a);i?(n("log","at pages/API/request-payment/request-payment.vue:172","--------orderInfo--------"),n("log","at pages/API/request-payment/request-payment.vue:173",i),uni.requestPayment({provider:a,orderInfo:i,success:e=>{n("log","at pages/API/request-payment/request-payment.vue:178","success",e),uni.showToast({title:"感谢您的赞助!"})},fail:e=>{n("log","at pages/API/request-payment/request-payment.vue:184","fail",e),uni.showModal({content:"支付失败,原因为: "+e.errMsg,showCancel:!1})},complete:()=>{this.providerList[t].loading=!1}})):uni.showModal({content:"获取支付信息失败",showCancel:!1})},getOrderInfo(e){return new Promise(((t,a)=>{this.price||a(new Error("请输入金额")),n("warn","at pages/API/request-payment/request-payment.vue:200","此处使用uni-pay处理支付，详情参考: https://uniapp.dcloud.io/uniCloud/unipay"),uni.request({method:"POST",url:"https://97fca9f2-41f6-449f-a35e-3f135d4c3875.bspapp.com/http/pay",data:{provider:e,openid:this.openid,totalFee:100*Number(this.price),platform:"app-plus"},success(e){0===e.data.code?t(e.data.orderInfo):a(new Error("获取支付信息失败"+e.data.msg))},fail(e){a(new Error("请求支付接口失败"+e))}})}))},priceChange(e){n("log","at pages/API/request-payment/request-payment.vue:229",e.detail.value),this.price=e.detail.value}}};const Pt=t(It,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{style:{background:"#FFF",padding:"50rpx 0"}},[e.createElementVNode("view",{class:"uni-hello-text uni-center"},[e.createElementVNode("text",null,"支付金额")]),e.createElementVNode("view",{class:"uni-h1 uni-center uni-common-mt"},[e.createElementVNode("text",{class:"rmbLogo"},"￥"),e.createElementVNode("input",{class:"price",type:"digit",value:l.price,maxlength:"4",onInput:n[0]||(n[0]=(...e)=>r.priceChange&&r.priceChange(...e))},null,40,["value"])])]),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[l.providerList.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(l.providerList,((t,a)=>(e.openBlock(),e.createElementBlock("button",{key:a,onClick:e=>r.requestPayment(t,a),loading:t.loading},e.toDisplayString(t.name)+"支付",9,["onClick","loading"])))),128)):e.createCommentVNode("",!0)])])])}]]),At={data:()=>({title:"share",shareText:"uni-app可以同时发布成原生App、小程序、H5，邀请你一起体验！",href:"https://uniapp.dcloud.io",image:"",shareType:1,providerList:[]}),computed:{isDisableButton:()=>function(e){return 0===this.shareType&&"qq"===e.id||5===this.shareType&&"分享到微信好友"!==e.name}},onShareAppMessage(){return{title:this.shareText?this.shareText:"欢迎体验uni-app",path:"/pages/tabBar/component/component",imageUrl:this.image?this.image:"https://web-assets.dcloud.net.cn/unidoc/zh/share-logo@3.png"}},onUnload:function(){this.shareText="uni-app可以同时发布成原生App、小程序、H5，邀请你一起体验！",this.href="https://uniapp.dcloud.io",this.image=""},onLoad:function(){uni.getProvider({service:"share",success:e=>{n("log","at pages/API/share/share.vue:87","success",e);let t=[];for(let a=0;a<e.provider.length;a++)switch(e.provider[a]){case"weixin":t.push({name:"分享到微信好友",id:"weixin",sort:0}),t.push({name:"分享到微信朋友圈",id:"weixin",type:"WXSenceTimeline",sort:1});break;case"sinaweibo":t.push({name:"分享到新浪微博",id:"sinaweibo",sort:2});break;case"qq":t.push({name:"分享到QQ",id:"qq",sort:3})}this.providerList=t.sort(((e,t)=>e.sort-t.sort))},fail:e=>{n("log","at pages/API/share/share.vue:127","获取分享通道失败",e),uni.showModal({content:"获取分享通道失败",showCancel:!1})}})},methods:{async share(e){if(n("log","at pages/API/share/share.vue:137","分享通道:"+e.id+"； 分享类型:"+this.shareType),!this.shareText&&(1===this.shareType||0===this.shareType))return void uni.showModal({content:"分享内容不能为空",showCancel:!1});if(!this.image&&(2===this.shareType||0===this.shareType))return void uni.showModal({content:"分享图片不能为空",showCancel:!1});let t={provider:e.id,scene:e.type&&"WXSceneTimeline"===e.type?"WXSceneTimeline":"WXSceneSession",type:this.shareType,success:e=>{n("log","at pages/API/share/share.vue:160","success",e),uni.showModal({content:"已分享",showCancel:!1})},fail:e=>{n("log","at pages/API/share/share.vue:167","fail",e),uni.showModal({content:e.errMsg,showCancel:!1})},complete:function(){n("log","at pages/API/share/share.vue:174","分享操作结束!")}};switch(this.shareType){case 0:t.summary=this.shareText,t.imageUrl=this.image,t.title="欢迎体验uniapp",t.href="https://uniapp.dcloud.io";break;case 1:t.summary=this.shareText;break;case 2:t.imageUrl=this.image;break;case 5:t.imageUrl=this.image?this.image:"https://web-ext-storage.dcloud.net.cn/hello-uni-app/share.png",t.title="欢迎体验uniapp",t.miniProgram={id:"gh_33446d7f7a26",path:"/pages/tabBar/component/component",webUrl:"https://uniapp.dcloud.io",type:0}}0===t.type&&"iOS"===plus.os.name&&(t.imageUrl=await this.compress()),1===t.type&&"qq"===t.provider&&(t.href="https://uniapp.dcloud.io",t.title="欢迎体验uniapp"),uni.share(t)},radioChange(e){n("log","at pages/API/share/share.vue:215","type:"+e.detail.value),this.shareType=parseInt(e.detail.value)},chooseImage(){uni.chooseImage({count:1,sourceType:["album","camera"],sizeType:["compressed","original"],success:e=>{this.image=e.tempFilePaths[0]},fail:e=>{}})},compress(){n("log","at pages/API/share/share.vue:249","开始压缩");let e=this.image;return new Promise((t=>{var a=plus.io.convertAbsoluteFileSystem(e.replace("file://",""));n("log","at pages/API/share/share.vue:253","after"+a),plus.io.resolveLocalFileSystemURL(a,(a=>{a.file((a=>{n("log","at pages/API/share/share.vue:257","getFile:"+JSON.stringify(a)),a.size>20480&&plus.zip.compressImage({src:e,dst:e.replace(".jpg","2222.jpg").replace(".JPG","2222.JPG"),width:"10%",height:"10%",quality:1,overwrite:!0},(a=>{n("log","at pages/API/share/share.vue:267","success zip****"+a.size);let i=e.replace(".jpg","2222.jpg").replace(".JPG","2222.JPG");t(i)}),(function(e){uni.showModal({content:"分享图片太大,需要请重新选择图片!",showCancel:!1})}))}))}),(e=>{n("log","at pages/API/share/share.vue:279","Resolve file URL failed: "+e.message),uni.showModal({content:"分享图片太大,需要请重新选择图片!",showCancel:!1})}))}))}}};const Ft=t(At,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"},"分享内容"),e.createElementVNode("view",{class:"uni-textarea"},[e.withDirectives(e.createElementVNode("textarea",{class:"textarea","onUpdate:modelValue":n[0]||(n[0]=e=>l.shareText=e)},null,512),[[e.vModelText,l.shareText]])]),e.createElementVNode("view",{class:"uni-title"},"分享图片："),e.createElementVNode("view",{class:"uni-uploader",style:{padding:"15rpx",background:"#FFF"}},[l.image?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-uploader__input-box",onClick:n[1]||(n[1]=(...e)=>r.chooseImage&&r.chooseImage(...e))})),l.image?(e.openBlock(),e.createElementBlock("image",{key:1,class:"uni-uploader__img",src:l.image},null,8,["src"])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-title"},"分享类型："),e.createElementVNode("view",null,[e.createElementVNode("radio-group",{onChange:n[2]||(n[2]=(...e)=>r.radioChange&&r.radioChange(...e))},[e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"1",checked:"true"}),e.createTextVNode("文字 ")]),e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"2"}),e.createTextVNode("图片 ")]),e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"0"}),e.createTextVNode("图文 ")]),e.createElementVNode("label",{class:"radio"},[e.createElementVNode("radio",{value:"5"}),e.createTextVNode("小程序 ")])],32)]),l.providerList.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-btn-v uni-common-mt"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.providerList,((t,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:a},[t?(e.openBlock(),e.createElementBlock("button",{key:0,type:"primary",disabled:r.isDisableButton(t),onClick:e=>r.share(t)},e.toDisplayString(t.name),9,["disabled","onClick"])):e.createCommentVNode("",!0)],64)))),128))])):e.createCommentVNode("",!0)])])}]]);const Lt=t({data:()=>({title:"nav-default",hasSetText:!1,hasSetBg:!1}),methods:{setText(){this.hasSetText=!this.hasSetText,uni.setNavigationBarTitle({title:this.hasSetText?"Hello uni-app":"默认导航栏"})},setBg(){this.hasSetBg=!this.hasSetBg,uni.setNavigationBarColor({frontColor:this.hasSetBg?"#000000":"#ffffff",backgroundColor:this.hasSetBg?"#F8F8F8":"#007AFF"})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"page"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-helllo-text"}," 本页标题栏是uni-app的默认配置，开发者可在pages.json里配置文字内容及标题颜色，也可通过api接口将其改变。 "),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"default",onClick:n[0]||(n[0]=(...e)=>r.setText&&r.setText(...e))},"改变标题栏文字"),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.setBg&&r.setBg(...e))},"改变标题栏颜色")])])])}]]);const Mt=t({data:()=>({title:"loading"}),methods:{showLoading:function(){uni.showLoading({title:"loading"})},hideLoading:function(){uni.hideLoading()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{class:"btn-load",type:"primary",onClick:n[0]||(n[0]=(...e)=>r.showLoading&&r.showLoading(...e))},"显示 loading 提示框"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.hideLoading&&r.hideLoading(...e))},"隐藏 loading 提示框")])])])}]]),Rt="/pages/extUI/calendar/calendar",Ot={data:()=>({title:"navigate"}),computed:{...ve({hasLeftWin:e=>!e.noMatchLeftWindow})},methods:{navigateTo(){uni.navigateTo({url:"new-page/new-vue-page-1?data=Hello"})},navigateBack(){uni.navigateBack()},redirectTo(){uni.redirectTo({url:"new-page/new-vue-page-1"})},switchTab(){uni.switchTab({url:"/pages/tabBar/template/template"})},reLaunch(){this.hasLeftWin?uni.reLaunch({url:"/pages/component/view/view"}):uni.reLaunch({url:"/pages/tabBar/component/component"})},customAnimation(){uni.navigateTo({url:"new-page/new-vue-page-1?data=使用自定义动画打开页面",animationType:"slide-in-bottom",animationDuration:200})},preloadPage(){uni.preloadPage({url:Rt,success(){uni.showToast({title:"页面预载成功"})},fail(e){n("error","at pages/API/navigator/navigator.vue:87",e),uni.showToast({title:"页面预载失败"})}})},unPreloadPage(){uni.unPreloadPage({url:Rt})},navigateToPreloadPage(){uni.navigateTo({url:Rt})}}};const $t=t(Ot,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>r.navigateTo&&r.navigateTo(...e))},"跳转新页面，并传递数据"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.navigateBack&&r.navigateBack(...e))},"返回上一页"),e.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>r.redirectTo&&r.redirectTo(...e))},"在当前页面打开"),e.createElementVNode("button",{onClick:n[3]||(n[3]=(...e)=>r.switchTab&&r.switchTab(...e))},"切换到模板选项卡"),t.hasLeftWin?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,onClick:n[4]||(n[4]=(...e)=>r.reLaunch&&r.reLaunch(...e))},"关闭所有页面，打开首页")),e.createElementVNode("button",{onClick:n[5]||(n[5]=(...e)=>r.customAnimation&&r.customAnimation(...e))},"使用自定义动画打开页面"),e.createElementVNode("button",{onClick:n[6]||(n[6]=(...e)=>r.preloadPage&&r.preloadPage(...e))},"预载复杂页面"),e.createElementVNode("button",{onClick:n[7]||(n[7]=(...e)=>r.unPreloadPage&&r.unPreloadPage(...e))},"取消页面预载"),e.createElementVNode("button",{onClick:n[8]||(n[8]=(...e)=>r.navigateToPreloadPage&&r.navigateToPreloadPage(...e))},"打开复杂页面")])])])}]]),zt={data:()=>({title:"新页面",data:""}),computed:{...ve(["colorIndex","colorList"]),...be(["currentColor"])},onLoad(e){e.data&&(this.data=e.data),uni.$on("postMsg",(e=>{uni.showModal({content:`收到uni.$emit消息:${e.msg}`,showCancel:!1})}))},onUnload(){uni.$off("postMsg")},methods:{...we(["setColorIndex"]),navToNvue(){uni.navigateTo({url:"new-nvue-page-1"})},navToVue(){uni.navigateTo({url:"new-vue-page-2"})}}};const Ut=t(zt,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"root"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"page-body"},[e.createElementVNode("view",{class:"new-page__text-box"},[e.createElementVNode("text",{class:"new-page__text"},"从上个页面接收到参数："+e.toDisplayString(l.data),1)]),e.createElementVNode("view",{class:"new-page__color",onClick:n[0]||(n[0]=e=>t.setColorIndex(t.colorIndex>1?0:t.colorIndex+1)),style:e.normalizeStyle({backgroundColor:t.currentColor})},[e.createElementVNode("text",{class:"new-page__color-text"},"点击改变颜色")],4),e.createElementVNode("view",{class:"new-page__text-box"},[e.createElementVNode("text",{class:"new-page__text"},"点击上方色块使用vuex在页面之间进行通讯")]),e.createElementVNode("view",{class:"new-page__button"},[e.createElementVNode("button",{class:"new-page__button-item",onClick:n[1]||(n[1]=(...e)=>r.navToVue&&r.navToVue(...e))},"跳转VUE页面")])])])}]]);const jt=t({data:()=>({}),computed:{...ve(["colorIndex","colorList"]),...be(["currentColor"])},methods:{...we(["setColorIndex"]),emitMsg(){uni.$emit("postMsg",{msg:"From: Vue Page"})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"root"},[e.createElementVNode("view",{class:"page-body"},[e.createElementVNode("view",{class:"new-page__color",onClick:a[0]||(a[0]=e=>t.setColorIndex(t.colorIndex>1?0:t.colorIndex+1)),style:e.normalizeStyle({backgroundColor:t.currentColor})},[e.createElementVNode("text",{class:"new-page__color-text"},"点击改变颜色")],4),e.createElementVNode("view",{class:"new-page__text-box"},[e.createElementVNode("text",{class:"new-page__text"},"点击上方色块使用vuex在页面之间进行通讯")]),e.createElementVNode("view",{class:"new-page__button"},[e.createElementVNode("button",{class:"new-page__button-item",onClick:a[1]||(a[1]=(...e)=>s.emitMsg&&s.emitMsg(...e))},"向上一页面传递数据")])])])}]]);const qt=t({data:()=>({title:"下拉刷新 + 加载更多",data:[],loadMoreText:"加载中...",showLoadMore:!1,max:0}),onLoad(){this.initData()},onUnload(){this.max=0,this.data=[],this.loadMoreText="加载更多",this.showLoadMore=!1},onReachBottom(){n("log","at pages/API/pull-down-refresh/pull-down-refresh.vue:32","onReachBottom"),this.max>40?this.loadMoreText="没有更多数据了!":(this.showLoadMore=!0,setTimeout((()=>{this.setListData()}),300))},onPullDownRefresh(){n("log","at pages/API/pull-down-refresh/pull-down-refresh.vue:43","onPullDownRefresh"),this.initData()},methods:{initData(){setTimeout((()=>{this.max=0,this.data=[];let e=[];this.max+=20;for(var t=this.max-19;t<this.max+1;t++)e.push(t);this.data=this.data.concat(e),uni.stopPullDownRefresh()}),300)},setListData(){let e=[];this.max+=10;for(var t=this.max-9;t<this.max+1;t++)e.push(t);this.data=this.data.concat(e)}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{style:{"font-size":"12px",color:"#666"}},"注：PC 不支持下拉刷新"),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.data,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"text",key:a},"list - "+e.toDisplayString(t),1)))),128)),l.showLoadMore?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-loadmore"},e.toDisplayString(l.loadMoreText),1)):e.createCommentVNode("",!0)])])}]]);const Ht=t({data:()=>({title:"createAnimation",animationData:""}),onUnload(){this.animationData=""},onLoad(){this.animation=uni.createAnimation()},methods:{rotate:function(){this.animation.rotate(720*Math.random()-360).step(),this.animationData=this.animation.export()},scale:function(){this.animation.scale(2*Math.random()).step(),this.animationData=this.animation.export()},translate:function(){this.animation.translate(100*Math.random()-50,100*Math.random()-50).step(),this.animationData=this.animation.export()},skew:function(){this.animation.skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},rotateAndScale:function(){this.animation.rotate(720*Math.random()-360).scale(2*Math.random()).step(),this.animationData=this.animation.export()},rotateThenScale:function(){this.animation.rotate(720*Math.random()-360).step().scale(2*Math.random()).step(),this.animationData=this.animation.export()},all:function(){this.animation.rotate(720*Math.random()-360).scale(2*Math.random()).translate(100*Math.random()-50,100*Math.random()-50).skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},allInQueue:function(){this.animation.rotate(720*Math.random()-360).step().scale(2*Math.random()).step().translate(100*Math.random()-50,100*Math.random()-50).step().skew(90*Math.random(),90*Math.random()).step(),this.animationData=this.animation.export()},reset:function(){this.animation.rotate(0,0).scale(1).translate(0,0).skew(0,0).step({duration:0}),this.animationData=this.animation.export()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"animation-element-wrapper"},[e.createElementVNode("view",{class:"animation-element",animation:l.animationData},null,8,["animation"])]),e.createElementVNode("scroll-view",{class:"animation-buttons","scroll-y":"true"},[e.createElementVNode("button",{class:"animation-button",onClick:n[0]||(n[0]=(...e)=>r.rotate&&r.rotate(...e))},"旋转"),e.createElementVNode("button",{class:"animation-button",onClick:n[1]||(n[1]=(...e)=>r.scale&&r.scale(...e))},"缩放"),e.createElementVNode("button",{class:"animation-button",onClick:n[2]||(n[2]=(...e)=>r.translate&&r.translate(...e))},"移动"),e.createElementVNode("button",{class:"animation-button",onClick:n[3]||(n[3]=(...e)=>r.skew&&r.skew(...e))},"倾斜"),e.createElementVNode("button",{class:"animation-button",onClick:n[4]||(n[4]=(...e)=>r.rotateAndScale&&r.rotateAndScale(...e))},"旋转并缩放"),e.createElementVNode("button",{class:"animation-button",onClick:n[5]||(n[5]=(...e)=>r.rotateThenScale&&r.rotateThenScale(...e))},"旋转后缩放"),e.createElementVNode("button",{class:"animation-button",onClick:n[6]||(n[6]=(...e)=>r.all&&r.all(...e))},"同时展示全部"),e.createElementVNode("button",{class:"animation-button",onClick:n[7]||(n[7]=(...e)=>r.allInQueue&&r.allInQueue(...e))},"顺序展示全部"),e.createElementVNode("button",{class:"animation-button animation-button-reset",onClick:n[8]||(n[8]=(...e)=>r.reset&&r.reset(...e))},"还原")])])])}]]);const Wt=t({data:()=>({title:"createSelectorQuery",top:0,left:"0px",info:[]}),onReady(){this.getNodeInfo()},methods:{setPosition(){this.left=Math.random()*uni.upx2px(320)+"px",this.top=Math.random()*uni.upx2px(320)+"px",this.getNodeInfo()},getNodeInfo(){uni.createSelectorQuery().select(".target").boundingClientRect().exec((e=>{const t=e[0];if(t){const e=["left","right","top","bottom","width","height"],a=[];for(let n in e){let i=e[n];a.push({key:i,val:t[i]})}this.info=a}}))}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"movable block"},[e.createElementVNode("movable-area",null,[e.createElementVNode("movable-view",{class:"target",direction:"all",onChange:n[0]||(n[0]=(...e)=>r.getNodeInfo&&r.getNodeInfo(...e))},"Drag",32)])]),e.createElementVNode("view",{class:"movable"},[e.createElementVNode("view",{class:"info"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.info,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a},[e.createElementVNode("text",{class:"b"},e.toDisplayString(t.key),1),e.createElementVNode("text",{class:"span"},e.toDisplayString(t.val),1)])))),128))])]),e.createElementVNode("view",null,[e.createElementVNode("view",{class:"box box1"}),e.createElementVNode("view",{class:"box box2"}),e.createElementVNode("view",{class:"box box3"}),e.createElementVNode("view",{class:"box box4"})])])])}]]);let Jt=null;const Gt=t({data:()=>({appear:!1,title:"intersectionObserver"}),onReady(){Jt=uni.createIntersectionObserver(this),Jt.relativeTo(".scroll-view").observe(".ball",(e=>{e.intersectionRatio>0&&!this.appear?this.appear=!0:!e.intersectionRatio>0&&this.appear&&(this.appear=!1)}))},onUnload(){Jt&&Jt.disconnect()}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title uni-common-mt"},e.toDisplayString(l.appear?"小球出现":"小球消失"),1),e.createElementVNode("scroll-view",{class:"scroll-view","scroll-y":""},[e.createElementVNode("view",{class:"scroll-area"},[e.createElementVNode("text",{class:"notice"},"向下滚动让小球出现"),e.createElementVNode("view",{class:"ball"})])])])])}]]);var Kt=null;const Qt=t({data:()=>({title:"createContext",names:["rotate","scale","reset","translate","save","restore","drawImage","fillText","fill","stroke","clearRect","beginPath","closePath","moveTo","lineTo","rect","arc","quadraticCurveTo","bezierCurveTo","setFillStyle","setStrokeStyle","setGlobalAlpha","setShadow","setFontSize","setLineCap","setLineJoin","setLineWidth","setMiterLimit"]}),onReady:function(){Kt=uni.createCanvasContext("canvas",this)},methods:{toTempFilePath:function(){uni.canvasToTempFilePath({canvasId:"canvas",success:function(e){n("log","at pages/API/canvas/canvas.vue:36",e.tempFilePath)},fail:function(e){n("error","at pages/API/canvas/canvas.vue:39",JSON.stringify(e))}})},handleCanvasButton:function(e){this[e]&&this[e]()},rotate:function(){Kt.beginPath(),Kt.rotate(10*Math.PI/180),Kt.rect(225,75,20,10),Kt.fill(),Kt.draw()},scale:function(){Kt.beginPath(),Kt.rect(25,25,50,50),Kt.stroke(),Kt.scale(2,2),Kt.beginPath(),Kt.rect(25,25,50,50),Kt.stroke(),Kt.draw()},reset:function(){Kt.beginPath(),Kt.setFillStyle("#000000"),Kt.setStrokeStyle("#000000"),Kt.setFontSize(10),Kt.setGlobalAlpha(1),Kt.setShadow(0,0,0,"rgba(0, 0, 0, 0)"),Kt.setLineCap("butt"),Kt.setLineJoin("miter"),Kt.setLineWidth(1),Kt.setMiterLimit(10),Kt.draw()},translate:function(){Kt.beginPath(),Kt.rect(10,10,100,50),Kt.fill(),Kt.translate(70,70),Kt.beginPath(),Kt.fill(),Kt.draw()},save:function(){Kt.beginPath(),Kt.setStrokeStyle("#00ff00"),Kt.save(),Kt.scale(2,2),Kt.setStrokeStyle("#ff0000"),Kt.rect(0,0,100,100),Kt.stroke(),Kt.restore(),Kt.rect(0,0,50,50),Kt.stroke(),Kt.draw()},restore:function(){[3,2,1].forEach((function(e){Kt.beginPath(),Kt.save(),Kt.scale(e,e),Kt.rect(10,10,100,100),Kt.stroke(),Kt.restore()})),Kt.draw()},drawImage:function(){Kt.drawImage("../../../static/app-plus/uni@2x.png",0,0),Kt.draw()},fillText:function(){Kt.setStrokeStyle("#ff0000"),Kt.beginPath(),Kt.moveTo(0,10),Kt.lineTo(300,10),Kt.stroke(),Kt.setFontSize(10),Kt.fillText("Hello World",0,30),Kt.setFontSize(20),Kt.fillText("Hello World",100,30),Kt.beginPath(),Kt.moveTo(0,30),Kt.lineTo(300,30),Kt.stroke(),Kt.draw()},fill:function(){Kt.beginPath(),Kt.rect(20,20,150,100),Kt.setStrokeStyle("#00ff00"),Kt.fill(),Kt.draw()},stroke:function(){Kt.beginPath(),Kt.moveTo(20,20),Kt.lineTo(20,100),Kt.lineTo(70,100),Kt.setStrokeStyle("#00ff00"),Kt.stroke(),Kt.draw()},clearRect:function(){Kt.setFillStyle("#ff0000"),Kt.beginPath(),Kt.rect(0,0,300,150),Kt.fill(),Kt.clearRect(20,20,100,50),Kt.draw()},beginPath:function(){Kt.beginPath(),Kt.setLineWidth(5),Kt.setStrokeStyle("#ff0000"),Kt.moveTo(0,75),Kt.lineTo(250,75),Kt.stroke(),Kt.beginPath(),Kt.setStrokeStyle("#0000ff"),Kt.moveTo(50,0),Kt.lineTo(150,130),Kt.stroke(),Kt.draw()},closePath:function(){Kt.beginPath(),Kt.setLineWidth(1),Kt.moveTo(20,20),Kt.lineTo(20,100),Kt.lineTo(70,100),Kt.closePath(),Kt.stroke(),Kt.draw()},moveTo:function(){Kt.beginPath(),Kt.moveTo(0,0),Kt.lineTo(300,150),Kt.stroke(),Kt.draw()},lineTo:function(){Kt.beginPath(),Kt.moveTo(20,20),Kt.lineTo(20,100),Kt.lineTo(70,100),Kt.stroke(),Kt.draw()},rect:function(){Kt.beginPath(),Kt.rect(20,20,150,100),Kt.stroke(),Kt.draw()},arc:function(){Kt.beginPath(),Kt.setLineWidth(2),Kt.arc(75,75,50,0,2*Math.PI,!0),Kt.moveTo(110,75),Kt.arc(75,75,35,0,Math.PI,!1),Kt.moveTo(65,65),Kt.arc(60,65,5,0,2*Math.PI,!0),Kt.moveTo(95,65),Kt.arc(90,65,5,0,2*Math.PI,!0),Kt.stroke(),Kt.draw()},quadraticCurveTo:function(){Kt.beginPath(),Kt.moveTo(20,20),Kt.quadraticCurveTo(20,100,200,20),Kt.stroke(),Kt.draw()},bezierCurveTo:function(){Kt.beginPath(),Kt.moveTo(20,20),Kt.bezierCurveTo(20,100,200,100,200,20),Kt.stroke(),Kt.draw()},setFillStyle:function(){["#fef957","rgb(242,159,63)","rgb(242,117,63)","#e87e51"].forEach((function(e,t){Kt.setFillStyle(e),Kt.beginPath(),Kt.rect(0+75*t,0,50,50),Kt.fill()})),Kt.draw()},setStrokeStyle:function(){["#fef957","rgb(242,159,63)","rgb(242,117,63)","#e87e51"].forEach((function(e,t){Kt.setStrokeStyle(e),Kt.beginPath(),Kt.rect(0+75*t,0,50,50),Kt.stroke()})),Kt.draw()},setGlobalAlpha:function(){Kt.setFillStyle("#000000"),[1,.5,.1].forEach((function(e,t){Kt.setGlobalAlpha(e),Kt.beginPath(),Kt.rect(0+75*t,0,50,50),Kt.fill()})),Kt.draw(),Kt.setGlobalAlpha(1)},setShadow:function(){Kt.beginPath(),Kt.setShadow(10,10,10,"rgba(0, 0, 0, 199)"),Kt.rect(10,10,100,100),Kt.fill(),Kt.draw()},setFontSize:function(){[10,20,30,40].forEach((function(e,t){Kt.setFontSize(e),Kt.fillText("Hello, world",20,20+40*t)})),Kt.draw()},setLineCap:function(){Kt.setLineWidth(10),["butt","round","square"].forEach((function(e,t){Kt.beginPath(),Kt.setLineCap(e),Kt.moveTo(20,20+20*t),Kt.lineTo(100,20+20*t),Kt.stroke()})),Kt.draw()},setLineJoin:function(){Kt.setLineWidth(10),["bevel","round","miter"].forEach((function(e,t){Kt.beginPath(),Kt.setLineJoin(e),Kt.moveTo(20+80*t,20),Kt.lineTo(100+80*t,50),Kt.lineTo(20+80*t,100),Kt.stroke()})),Kt.draw()},setLineWidth:function(){[2,4,6,8,10].forEach((function(e,t){Kt.beginPath(),Kt.setLineWidth(e),Kt.moveTo(20,20+20*t),Kt.lineTo(100,20+20*t),Kt.stroke()})),Kt.draw()},setMiterLimit:function(){Kt.setLineWidth(4),[2,4,6,8,10].forEach((function(e,t){Kt.beginPath(),Kt.setMiterLimit(e),Kt.moveTo(20+80*t,20),Kt.lineTo(100+80*t,50),Kt.lineTo(20+80*t,100),Kt.stroke()})),Kt.draw()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("canvas",{class:"canvas-element","canvas-id":"canvas",id:"canvas"}),e.createElementVNode("scroll-view",{class:"canvas-buttons","scroll-y":"true"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.names,((t,a)=>(e.openBlock(),e.createElementBlock("button",{key:a,class:"canvas-button",onClick:e=>r.handleCanvasButton(t)},e.toDisplayString(t),9,["onClick"])))),128)),e.createElementVNode("button",{class:"canvas-button",onClick:n[0]||(n[0]=(...e)=>r.toTempFilePath&&r.toTempFilePath(...e)),type:"primary"},"toTempFilePath")])])])}]]),Yt={data:()=>({title:"action-sheet",buttonRect:{}}),methods:{actionSheetTap(){const e=this;uni.showActionSheet({title:"标题",itemList:["item1","item2","item3","item4"],popover:{top:e.buttonRect.top+104+e.buttonRect.height,left:e.buttonRect.left+e.buttonRect.width/2},success:e=>{n("log","at pages/API/action-sheet/action-sheet.vue:40",e.tapIndex),uni.showToast({title:"点击了第"+e.tapIndex+"个选项",icon:"none"})}})}}};const Xt=t(Yt,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{class:"target",type:"default",onClick:n[0]||(n[0]=(...e)=>r.actionSheetTap&&r.actionSheetTap(...e))},"弹出action sheet")])])])}]]);const Zt=t({data:()=>({title:"modal",modalHidden:!0,modalHidden2:!0}),methods:{modalTap:function(e){uni.showModal({title:"弹窗标题",content:"弹窗内容，告知当前状态、信息和解决方法，描述文字尽量控制在三行内",showCancel:!1,confirmText:"确定"})},noTitlemodalTap:function(e){uni.showModal({content:"弹窗内容，告知当前状态、信息和解决方法，描述文字尽量控制在三行内",confirmText:"确定",cancelText:"取消"})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"default",onClick:n[0]||(n[0]=(...e)=>r.modalTap&&r.modalTap(...e))},"有标题的modal"),e.createElementVNode("button",{type:"default",onClick:n[1]||(n[1]=(...e)=>r.noTitlemodalTap&&r.noTitlemodalTap(...e))},"无标题的modal")])])])}]]);const ea=t({data:()=>({title:"toast"}),methods:{toast1Tap:function(){uni.showToast({title:"默认"})},toast2Tap:function(){uni.showToast({title:"duration 3000",duration:3e3})},toast3Tap:function(){uni.showToast({title:"loading",icon:"loading",duration:5e3})},toast4Tap:function(){uni.showToast({title:"logo",image:"../../../static/uni.png"})},toast5Tap:function(){uni.showToast({title:"显示一段轻提示",position:"bottom"})},hideToast:function(){uni.hideToast()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"default",onClick:n[0]||(n[0]=(...e)=>r.toast1Tap&&r.toast1Tap(...e))},"点击弹出默认toast"),e.createElementVNode("button",{type:"default",onClick:n[1]||(n[1]=(...e)=>r.toast2Tap&&r.toast2Tap(...e))},"点击弹出设置duration的toast"),e.createElementVNode("button",{type:"default",onClick:n[2]||(n[2]=(...e)=>r.toast3Tap&&r.toast3Tap(...e))},"点击弹出显示loading的toast"),e.createElementVNode("button",{type:"default",onClick:n[3]||(n[3]=(...e)=>r.toast4Tap&&r.toast4Tap(...e))},"点击弹出显示自定义图片的toast"),e.createElementVNode("button",{type:"default",onClick:n[4]||(n[4]=(...e)=>r.toast5Tap&&r.toast5Tap(...e))},"点击显示无图标的居底toast"),e.createElementVNode("button",{type:"default",onClick:n[5]||(n[5]=(...e)=>r.hideToast&&r.hideToast(...e))},"点击隐藏toast")])])])}]]);const ta=t({data:()=>({title:"getNetworkType",hasNetworkType:!1,networkType:"",connectedWifi:""}),onUnload:function(){this.networkType="",this.hasNetworkType=!1},methods:{getNetworkType:function(){uni.getNetworkType({success:e=>{n("log","at pages/API/get-network-type/get-network-type.vue:47",e),this.hasNetworkType=!0,this.networkType=e.subtype||e.networkType},fail:()=>{uni.showModal({content:"获取失败！",showCancel:!1})}})},clear:function(){this.hasNetworkType=!1,this.networkType="",this.connectedWifi=""}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{style:{background:"#FFFFFF",padding:"40rpx"}},[e.createElementVNode("view",{class:"uni-hello-text uni-center"},"网络状态"),!1===l.hasNetworkType?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("view",{class:"uni-h2 uni-center uni-common-mt"},"未获取"),e.createElementVNode("view",{class:"uni-hello-text uni-center uni-common-mt"},"请点击下面按钮获取网络状态")],64)):e.createCommentVNode("",!0),!0===l.hasNetworkType?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-h2 uni-center uni-common-mt"},e.toDisplayString(l.networkType),1)):e.createCommentVNode("",!0),!0===l.hasNetworkType&&"wifi"===l.networkType?(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-textarea uni-common-mt"},[e.createElementVNode("textarea",{value:l.connectedWifi},null,8,["value"])])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.getNetworkType&&r.getNetworkType(...e))},"获取设备网络状态"),e.createElementVNode("button",{class:"uni-common-mt",onClick:n[1]||(n[1]=(...e)=>r.clear&&r.clear(...e))},"清空")])])])}]]);const aa=t({data:()=>({title:"getSystemInfo",systemInfo:{}}),onUnload:function(){this.systemInfo={}},methods:{getSystemInfo:function(){uni.getSystemInfo({success:e=>{this.systemInfo=e}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"设备型号")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.model},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"客户端平台")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.platform},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"操作系统版本")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.system},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"语言")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.language},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"版本")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.version},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"屏幕宽度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.screenWidth},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"屏幕高度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.screenHeight},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"可使用窗口高度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.windowHeight},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"可使用窗口的顶部位置")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.windowTop},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"可使用窗口的底部位置")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.windowBottom},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"状态栏的高度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.statusBarHeight},null,8,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-pd"},[e.createElementVNode("view",{class:"uni-label",style:{width:"180px"}},"DPI")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,placeholder:"未获取",value:l.systemInfo.pixelRatio},null,8,["value"])])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.getSystemInfo&&r.getSystemInfo(...e))},"获取设备系统信息")])])])])}]]),na={data:()=>({title:"addPhoneContact",name:"",phone:""}),methods:{nameChange:function(e){this.name=e.detail.value},phoneChange:function(e){this.phone=e.detail.value},async add(){1===await this.checkPermission()&&uni.addPhoneContact({firstName:this.name,mobilePhoneNumber:this.phone,success:function(){uni.showModal({content:"已成功添加联系人！",showCancel:!1})},fail:function(){uni.showModal({content:"添加联系人失败！",showCancel:!1})}})},async checkPermission(){let e=qe.isIOS?await qe.requestIOS("contact"):await qe.requestAndroid("android.permission.WRITE_CONTACTS");return null===e||1===e?e=1:uni.showModal({content:"需要联系人权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),e}}};const ia=t(na,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"名称")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",placeholder:"请输入联系人名称",name:"name",value:l.name,onInput:n[0]||(n[0]=(...e)=>r.nameChange&&r.nameChange(...e))},null,40,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"手机号")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",placeholder:"请输入联系人手机号",name:"phone",value:l.phone,onInput:n[1]||(n[1]=(...e)=>r.phoneChange&&r.phoneChange(...e))},null,40,["value"])])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",class:"btn-setstorage",onClick:n[2]||(n[2]=(...e)=>r.add&&r.add(...e))},"添加联系人")])])])])}]]);const oa=t({data:()=>({title:"onAccelerometerChange",value:""}),onUnload(){uni.stopAccelerometer()},methods:{shake(){uni.navigateTo({url:"/platforms/app-plus/shake/shake"})},watchAcce(){uni.onAccelerometerChange((e=>{this.value="监听设备的加速度变化:\nX轴："+e.x.toFixed(2)+"\nY轴："+e.y.toFixed(2)+"\nZ轴："+e.z.toFixed(2)}))},stopAcce(){uni.stopAccelerometer()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{class:"shake",onClick:n[0]||(n[0]=(...e)=>r.shake&&r.shake(...e))},"摇一摇")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.watchAcce&&r.watchAcce(...e))},"监听设备的加速度变化"),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.stopAcce&&r.stopAcce(...e))},"停止监听设备的加速度变化")]),e.createElementVNode("view",{class:"uni-textarea uni-common-mt"},[e.createElementVNode("textarea",{class:"acc-show",value:l.value},null,8,["value"])])])])}]]);const sa=t({data:()=>({title:"onCompassChange",direction:0}),onReady:function(){uni.onCompassChange((e=>{this.direction=parseInt(e.direction)}))},onUnload(){uni.stopCompass(),this.direction=0}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-hello-text uni-center",style:{"padding-bottom":"50rpx"}}," 旋转手机即可获取方位信息 "),e.createElementVNode("view",{class:"direction"},[e.createElementVNode("view",{class:"bg-compass-line"}),e.createElementVNode("image",{class:"bg-compass",src:"/static/compass.png",style:e.normalizeStyle("transform: rotate("+l.direction+"deg)")},null,4),e.createElementVNode("view",{class:"direction-value"},[e.createElementVNode("text",null,e.toDisplayString(l.direction),1),e.createElementVNode("text",{class:"direction-degree"},"o")])])])])}]]),la={data:()=>({title:"makePhoneCall",disabled:!0}),methods:{bindInput:function(e){this.inputValue=e.detail.value,this.inputValue.length>0?this.disabled=!1:this.disabled=!0},makePhoneCall:function(){uni.makePhoneCall({phoneNumber:this.inputValue,success:()=>{n("log","at pages/API/make-phone-call/make-phone-call.vue:34","成功拨打电话")}})}}};const ra=t(la,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-hello-text uni-center"},"请在下方输入电话号码"),e.createElementVNode("input",{class:"input uni-common-mt",type:"number",name:"input",onInput:n[0]||(n[0]=(...e)=>r.bindInput&&r.bindInput(...e))},null,32),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.makePhoneCall&&r.makePhoneCall(...e)),type:"primary",disabled:l.disabled},"拨打",8,["disabled"])])])])}]]);const ca=t({data:()=>({title:"scanCode",result:""}),methods:{async scan(){1===await this.checkPermission()&&uni.scanCode({success:e=>{this.result=e.result},fail:e=>{}})},async checkPermission(e){let t=qe.isIOS?await qe.requestIOS("camera"):await qe.requestAndroid("android.permission.CAMERA");return null===t||1===t?t=1:uni.showModal({content:"需要相机权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),t}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},"扫码结果："),l.result?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-list"},[e.createElementVNode("view",{class:"uni-cell"},[e.createElementVNode("view",{class:"scan-result"},e.toDisplayString(l.result),1)])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.scan&&r.scan(...e))},"扫一扫")])])])}]]),da={data:()=>({title:"get/setClipboardData",data:""}),methods:{dataChange:function(e){this.data=e.detail.value},getClipboard:function(){uni.getClipboardData({success:e=>{n("log","at pages/API/clipboard/clipboard.vue:33",e.data);const t=e.data?"剪贴板内容为:"+e.data:"剪贴板暂无内容";uni.showModal({content:t,title:"读取剪贴板",showCancel:!1})},fail:()=>{uni.showModal({content:"读取剪贴板失败!",showCancel:!1})}})},setClipboard:function(){var e=this.data;0===e.length?uni.showModal({title:"设置剪贴板失败",content:"内容不能为空",showCancel:!1}):uni.setClipboardData({data:e,success:()=>{},fail:()=>{}})}}};const ua=t(da,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"},"请输入剪贴板内容"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("input",{class:"uni-input",type:"text",placeholder:"请输入剪贴板内容",value:l.data,onInput:n[0]||(n[0]=(...e)=>r.dataChange&&r.dataChange(...e))},null,40,["value"])])]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.setClipboard&&r.setClipboard(...e))},"存储数据"),e.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>r.getClipboard&&r.getClipboard(...e))},"读取数据")])])])}]]),ha="https://unidemo.dcloud.net.cn/ajax/echo/text?name=uni-app",pa=2e3,ma={data:()=>({title:"request",loading:!1,res:""}),methods:{sendRequest(e){switch(this.loading=!0,e){case"promise":this._requestPromise();break;case"await":this._requestAwait();break;default:this._request()}},_request(){uni.request({url:ha,dataType:"text",data:{noncestr:Date.now()},success:e=>{n("log","at pages/API/request/request.vue:53","request success",e),uni.showToast({title:"请求成功",icon:"success",mask:!0,duration:pa}),this.res="请求结果 : "+JSON.stringify(e)},fail:e=>{n("log","at pages/API/request/request.vue:63","request fail",e),uni.showModal({content:e.errMsg,showCancel:!1})},complete:()=>{this.loading=!1}})},_requestPromise(){uni.request({url:ha,dataType:"text",data:{noncestr:Date.now()}}).then((e=>{n("log","at pages/API/request/request.vue:111","request success",e),uni.showToast({title:"请求成功",icon:"success",mask:!0,duration:pa}),this.res="请求结果 : "+JSON.stringify(e),this.loading=!1})).catch((e=>{n("log","at pages/API/request/request.vue:122","request fail",e),uni.showModal({content:e.errMsg,showCancel:!1}),this.loading=!1}))},async _requestAwait(){let e,t;try{e=await uni.request({url:ha,dataType:"text",data:{noncestr:Date.now()}})}catch($i){t=$i}t?(n("log","at pages/API/request/request.vue:157","request fail",t),uni.showModal({content:t.errMsg,showCancel:!1})):(n("log","at pages/API/request/request.vue:163","request success",e),uni.showToast({title:"请求成功",icon:"success",mask:!0,duration:pa}),this.res="请求结果 : "+JSON.stringify(e)),this.loading=!1}}};const ga=t(ma,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-hello-text"}," 请点击按钮向服务器发起请求 "),e.createElementVNode("view",{class:"uni-textarea uni-common-mt"},[e.createElementVNode("textarea",{value:l.res},null,8,["value"])]),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.sendRequest&&r.sendRequest(...e)),loading:l.loading},"发起请求（Callback）",8,["loading"]),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=e=>r.sendRequest("promise")),loading:l.loading},"发起请求（Promise）",8,["loading"]),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=e=>r.sendRequest("await")),loading:l.loading},"发起请求（Async/Await）",8,["loading"])])])])}]]);const fa=t({data:()=>({title:"uploadFile",imageSrc:""}),onUnload(){this.imageSrc=""},methods:{chooseImage:function(){uni.chooseImage({count:1,sizeType:["compressed"],sourceType:["album"],success:e=>{n("log","at pages/API/upload-file/upload-file.vue:34","chooseImage success, temp path is",e.tempFilePaths[0]);var t=e.tempFilePaths[0];uni.uploadFile({url:"https://unidemo.dcloud.net.cn/upload",filePath:t,fileType:"image",name:"data",success:e=>{n("log","at pages/API/upload-file/upload-file.vue:42","uploadImage success, res is:",e),uni.showToast({title:"上传成功",icon:"success",duration:1e3}),this.imageSrc=t},fail:e=>{n("log","at pages/API/upload-file/upload-file.vue:51","uploadImage fail",e),uni.showModal({content:e.errMsg,showCancel:!1})}})},fail:e=>{n("log","at pages/API/upload-file/upload-file.vue:60","chooseImage fail",e)}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"demo"},[l.imageSrc?(e.openBlock(),e.createElementBlock("image",{key:0,src:l.imageSrc,class:"image",mode:"widthFix"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-hello-addfile",onClick:n[0]||(n[0]=(...e)=>r.chooseImage&&r.chooseImage(...e))},"+ 选择图片"))])])])}]]);const ya=t({data:()=>({title:"downloadFile",imageSrc:"",jest_result:!1}),onUnload(){this.imageSrc=""},methods:{downloadImage:function(){uni.showLoading({title:"下载中"});var e=this;uni.downloadFile({url:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/uni-app.png",success:t=>{this.jest_result=!0,n("log","at pages/API/download-file/download-file.vue:42","downloadFile success, res is",t),e.imageSrc=t.tempFilePath,uni.hideLoading()},fail:e=>{n("log","at pages/API/download-file/download-file.vue:47","downloadFile fail, err is:",e),this.jest_result=!1}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[l.imageSrc?(e.openBlock(),e.createElementBlock("view",{key:0,class:"image-container"},[e.createElementVNode("image",{class:"img",src:l.imageSrc,mode:"center"},null,8,["src"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"uni-hello-text"}," 点击按钮下载服务端示例图片（下载网络文件到本地临时目录） "),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.downloadImage&&r.downloadImage(...e))},"下载")])],64))])])}]]);var va=[["camera"],["album"],["camera","album"]],wa=[["compressed"],["original"],["compressed","original"]];const ba={data:()=>({title:"choose/previewImage",imageList:[],sourceTypeIndex:2,sourceType:["拍照","相册","拍照或相册"],sizeTypeIndex:2,sizeType:["压缩","原图","压缩或原图"],countIndex:8,count:[1,2,3,4,5,6,7,8,9]}),onUnload(){this.imageList=[],this.sourceTypeIndex=2,this.sourceType=["拍照","相册","拍照或相册"],this.sizeTypeIndex=2,this.sizeType=["压缩","原图","压缩或原图"],this.countIndex=8},methods:{sourceTypeChange:function(e){this.sourceTypeIndex=parseInt(e.detail.value)},sizeTypeChange:function(e){this.sizeTypeIndex=parseInt(e.detail.value)},countChange:function(e){this.countIndex=e.detail.value},chooseImage:async function(){if(2!==this.sourceTypeIndex){if(1!==await this.checkPermission())return}if(9===this.imageList.length){let e=await this.isFullImg();if(n("log","at pages/API/image/image.vue:124","是否继续?",e),!e)return}uni.chooseImage({sourceType:va[this.sourceTypeIndex],sizeType:wa[this.sizeTypeIndex],count:this.imageList.length+this.count[this.countIndex]>9?9-this.imageList.length:this.count[this.countIndex],success:e=>{this.imageList=this.imageList.concat(e.tempFilePaths)},fail:e=>{n("log","at pages/API/image/image.vue:137","err: ",e),e.code&&0!==e.code&&2===this.sourceTypeIndex&&this.checkPermission(e.code)}})},isFullImg:function(){return new Promise((e=>{uni.showModal({content:"已经有9张图片了,是否清空现有图片？",success:t=>{t.confirm?(this.imageList=[],e(!0)):e(!1)},fail:()=>{e(!1)}})}))},previewImage:function(e){var t=e.target.dataset.src;uni.previewImage({current:t,urls:this.imageList})},async checkPermission(e){let t=e?e-1:this.sourceTypeIndex,a=qe.isIOS?await qe.requestIOS(va[t][0]):await qe.requestAndroid(0===t?"android.permission.CAMERA":"android.permission.READ_EXTERNAL_STORAGE");return null===a||1===a?a=1:uni.showModal({content:"没有开启权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),a}}};const ka=t(ba,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("form",null,[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"图片来源")]),e.createElementVNode("view",{class:"uni-list-cell-right"},[e.createElementVNode("picker",{range:l.sourceType,onChange:n[0]||(n[0]=(...e)=>r.sourceTypeChange&&r.sourceTypeChange(...e)),value:l.sourceTypeIndex,mode:"selector"},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.sourceType[l.sourceTypeIndex]),1)],40,["range","value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"图片质量")]),e.createElementVNode("view",{class:"uni-list-cell-right"},[e.createElementVNode("picker",{range:l.sizeType,onChange:n[1]||(n[1]=(...e)=>r.sizeTypeChange&&r.sizeTypeChange(...e)),value:l.sizeTypeIndex,mode:"selector"},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.sizeType[l.sizeTypeIndex]),1)],40,["range","value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"数量限制")]),e.createElementVNode("view",{class:"uni-list-cell-right"},[e.createElementVNode("picker",{range:l.count,onChange:n[2]||(n[2]=(...e)=>r.countChange&&r.countChange(...e)),mode:"selector"},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.count[l.countIndex]),1)],40,["range"])])])]),e.createElementVNode("view",{class:"uni-list list-pd"},[e.createElementVNode("view",{class:"uni-list-cell cell-pd"},[e.createElementVNode("view",{class:"uni-uploader"},[e.createElementVNode("view",{class:"uni-uploader-head"},[e.createElementVNode("view",{class:"uni-uploader-title"},"点击可预览选好的图片"),e.createElementVNode("view",{class:"uni-uploader-info"},e.toDisplayString(l.imageList.length)+"/9",1)]),e.createElementVNode("view",{class:"uni-uploader-body"},[e.createElementVNode("view",{class:"uni-uploader__files"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.imageList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"uni-uploader__file"},[e.createElementVNode("image",{class:"uni-uploader__img",src:t,"data-src":t,onClick:n[3]||(n[3]=(...e)=>r.previewImage&&r.previewImage(...e))},null,8,["src","data-src"])])))),128)),e.createElementVNode("view",{class:"uni-uploader__input-box"},[e.createElementVNode("view",{class:"uni-uploader__input",onClick:n[4]||(n[4]=(...e)=>r.chooseImage&&r.chooseImage(...e))})])])])])])])])])])}]]);function xa(e){if("number"!=typeof e||e<0)return e;var t=parseInt(e/3600);return e%=3600,[t,parseInt(e/60),e%=60].map((function(e){return(e=e.toString())[1]?e:"0"+e})).join(":")}function Va(e,t){return"string"==typeof e&&"string"==typeof t&&(e=parseFloat(e),t=parseFloat(t)),e=e.toFixed(2),t=t.toFixed(2),{longitude:e.toString().split("."),latitude:t.toString().split(".")}}var Na={UNITS:{"年":315576e5,"月":26298e5,"天":864e5,"小时":36e5,"分钟":6e4,"秒":1e3},humanize:function(e){var t="";for(var a in this.UNITS)if(e>=this.UNITS[a]){t=Math.floor(e/this.UNITS[a])+a+"前";break}return t||"刚刚"},format:function(e){var t=this.parse(e),a=Date.now()-t.getTime();if(a<this.UNITS["天"])return this.humanize(a);var n=function(e){return e<10?"0"+e:e};return t.getFullYear()+"/"+n(t.getMonth()+1)+"/"+n(t.getDate())+"-"+n(t.getHours())+":"+n(t.getMinutes())},parse:function(e){var t=e.split(/[^0-9]/);return new Date(t[0],t[1]-1,t[2],t[3],t[4],t[5])}};const Ea="/static/play.png",Ca="/static/trash.png",_a="/static/stop.png";var Sa=null,Ta=null,Ba=null,Da=null;const Ia=t({data:()=>({title:"start/stopRecord、play/stopVoice",recording:!1,playing:!1,hasRecord:!1,tempFilePath:"",recordTime:0,playTime:0,formatedRecordTime:"00:00:00",formatedPlayTime:"00:00:00"}),onUnload:function(){this.end()},onLoad:function(){(Da=uni.createInnerAudioContext()).onEnded((()=>{clearInterval(Sa);n("log","at pages/API/voice/voice.vue:91","play voice finished"),this.playing=!1,this.formatedPlayTime=xa(0),this.playTime=0})),(Ba=uni.getRecorderManager()).onStart((()=>{n("log","at pages/API/voice/voice.vue:98","recorder start"),this.recording=!0,Ta=setInterval((()=>{this.recordTime+=1,this.formatedRecordTime=xa(this.recordTime)}),1e3)})),Ba.onStop((e=>{n("log","at pages/API/voice/voice.vue:107","on stop"),Da.src=e.tempFilePath,this.hasRecord=!0,this.recording=!1})),Ba.onError((()=>{n("log","at pages/API/voice/voice.vue:114","recorder onError")}))},methods:{async startRecord(){1===await this.checkPermission()&&Ba.start({format:"mp3"})},stopRecord(){Ba.stop(),clearInterval(Ta)},playVoice(){n("log","at pages/API/voice/voice.vue:136","play voice"),this.playing=!0,Sa=setInterval((()=>{this.playTime+=1,this.formatedPlayTime=xa(this.playTime)}),1e3),Da.play()},stopVoice(){clearInterval(Sa),this.playing=!1,this.formatedPlayTime=xa(0),this.playTime=0,Da.stop()},end(){Da.stop(),Ba.stop(),clearInterval(Ta),clearInterval(Sa),this.recording=!1,this.playing=!1,this.hasRecord=!1,this.playTime=0,this.recordTime=0,this.formatedRecordTime="00:00:00",this.formatedRecordTime="00:00:00"},clear(){this.end()},async checkPermission(){let e=qe.isIOS?await qe.requestIOS("record"):await qe.requestAndroid("android.permission.RECORD_AUDIO");return null===e||1===e?e=1:2===e?uni.showModal({content:"系统麦克风已关闭",confirmText:"确定",showCancel:!1,success:function(e){}}):uni.showModal({content:"需要麦克风权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),e}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[l.recording||l.playing||l.hasRecord?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("view",{class:"page-body-time"},[e.createElementVNode("text",{class:"time-big"},e.toDisplayString(l.formatedRecordTime),1)]),e.createElementVNode("view",{class:"page-body-buttons"},[e.createElementVNode("view",{class:"page-body-button"}),e.createElementVNode("view",{class:"page-body-button",onClick:n[0]||(n[0]=(...e)=>r.startRecord&&r.startRecord(...e))},[e.createElementVNode("image",{src:"/static/record.png"})]),e.createElementVNode("view",{class:"page-body-button"})])],64)),!0===l.recording?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"page-body-time"},[e.createElementVNode("text",{class:"time-big"},e.toDisplayString(l.formatedRecordTime),1)]),e.createElementVNode("view",{class:"page-body-buttons"},[e.createElementVNode("view",{class:"page-body-button"}),e.createElementVNode("view",{class:"page-body-button",onClick:n[1]||(n[1]=(...e)=>r.stopRecord&&r.stopRecord(...e))},[e.createElementVNode("view",{class:"button-stop-record"})]),e.createElementVNode("view",{class:"page-body-button"})])],64)):e.createCommentVNode("",!0),!0===l.hasRecord&&!1===l.playing?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("view",{class:"page-body-time"},[e.createElementVNode("text",{class:"time-big"},e.toDisplayString(l.formatedPlayTime),1),e.createElementVNode("text",{class:"time-small"},e.toDisplayString(l.formatedRecordTime),1)]),e.createElementVNode("view",{class:"page-body-buttons"},[e.createElementVNode("view",{class:"page-body-button",onClick:n[2]||(n[2]=(...e)=>r.playVoice&&r.playVoice(...e))},[e.createElementVNode("image",{src:Ea})]),e.createElementVNode("view",{class:"page-body-button",onClick:n[3]||(n[3]=(...e)=>r.clear&&r.clear(...e))},[e.createElementVNode("image",{src:Ca})])])],64)):e.createCommentVNode("",!0),!0===l.hasRecord&&!0===l.playing?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createElementVNode("view",{class:"page-body-time"},[e.createElementVNode("text",{class:"time-big"},e.toDisplayString(l.formatedPlayTime),1),e.createElementVNode("text",{class:"time-small"},e.toDisplayString(l.formatedRecordTime),1)]),e.createElementVNode("view",{class:"page-body-buttons"},[e.createElementVNode("view",{class:"page-body-button",onClick:n[4]||(n[4]=(...e)=>r.stopVoice&&r.stopVoice(...e))},[e.createElementVNode("image",{src:_a})]),e.createElementVNode("view",{class:"page-body-button",onClick:n[5]||(n[5]=(...e)=>r.clear&&r.clear(...e))},[e.createElementVNode("image",{src:Ca})])])],64)):e.createCommentVNode("",!0)])])}]]),Pa={data:()=>({title:"innerAudioContext",isPlaying:!1,isPlayEnd:!1,currentTime:0,duration:100}),computed:{position(){return this.isPlayEnd?0:this.currentTime},playImage(){return this.isPlaying?"/static/pause.png":"/static/play.png"}},onLoad(){this._isChanging=!1,this._audioContext=null,this.createAudio()},onUnload(){null!=this._audioContext&&this.isPlaying&&this.stop()},methods:{createAudio(){var e=this._audioContext=uni.createInnerAudioContext();return e.autoplay=!1,e.src="https://web-ext-storage.dcloud.net.cn/uni-app/ForElise.mp3",e.onPlay((()=>{n("log","at pages/API/inner-audio/inner-audio.vue:52","开始播放")})),e.onTimeUpdate((t=>{!0!==this._isChanging&&(this.currentTime=e.currentTime||0,this.duration=e.duration||0)})),e.onEnded((()=>{this.currentTime=0,this.isPlaying=!1,this.isPlayEnd=!0})),e.onError((e=>{this.isPlaying=!1,n("log","at pages/API/inner-audio/inner-audio.vue:68",e.errMsg),n("log","at pages/API/inner-audio/inner-audio.vue:69",e.errCode)})),e},onchanging(){this._isChanging=!0},onchange(e){n("log","at pages/API/inner-audio/inner-audio.vue:77",e.detail.value),n("log","at pages/API/inner-audio/inner-audio.vue:78",typeof e.detail.value),this._audioContext.seek(e.detail.value),this._isChanging=!1},play(){this.isPlaying?this.pause():(this.isPlaying=!0,this._audioContext.play(),this.isPlayEnd=!1)},pause(){this._audioContext.pause(),this.isPlaying=!1},stop(){this._audioContext.stop(),this.isPlaying=!1}}};const Aa=t(Pa,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"uni-padding-wrap"},[e.createVNode(c,{title:"audio"}),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("slider",{value:r.position,min:0,max:l.duration,onChanging:n[0]||(n[0]=(...e)=>r.onchanging&&r.onchanging(...e)),onChange:n[1]||(n[1]=(...e)=>r.onchange&&r.onchange(...e))},null,40,["value","max"])]),e.createElementVNode("view",{class:"play-button-area"},[e.createElementVNode("image",{class:"icon-play",src:r.playImage,onClick:n[2]||(n[2]=(...e)=>r.play&&r.play(...e))},null,8,["src"])])])}]]),Fa={data:()=>({title:"backgroundAudio",bgAudioMannager:null,dataUrl:"https://web-ext-storage.dcloud.net.cn/uni-app/ForElise.mp3",playing:!1,playTime:0,formatedPlayTime:"00:00:00"}),onLoad:function(){this.playing=this.$backgroundAudioData.playing,this.playTime=this.$backgroundAudioData.playTime,this.formatedPlayTime=this.$backgroundAudioData.formatedPlayTime;let e=uni.getBackgroundAudioManager();e.title||(e.title="致爱丽丝"),e.singer||(e.singer="暂无"),e.coverImgUrl||(e.coverImgUrl="https://web-assets.dcloud.net.cn/unidoc/zh/Alice.jpeg"),e.onPlay((()=>{n("log","at pages/API/background-audio/background-audio.vue:68","开始播放"),this.$backgroundAudioData.playing=this.playing=!0})),e.onPause((()=>{n("log","at pages/API/background-audio/background-audio.vue:72","暂停播放"),this.$backgroundAudioData.playing=this.playing=!1})),e.onEnded((()=>{this.playing=!1,this.$backgroundAudioData.playing=!1,this.$backgroundAudioData.playTime=this.playTime=0,this.$backgroundAudioData.formatedPlayTime=this.formatedPlayTime=xa(0)})),e.onTimeUpdate((t=>{Math.floor(e.currentTime)>Math.floor(this.playTime)&&(this.$backgroundAudioData.formatedPlayTime=this.formatedPlayTime=xa(Math.floor(e.currentTime))),this.$backgroundAudioData.playTime=this.playTime=e.currentTime})),this.bgAudioMannager=e},methods:{play:function(e){this.bgAudioMannager.src?(this.bgAudioMannager.seek(this.playTime),this.bgAudioMannager.play()):(this.bgAudioMannager.startTime=this.playTime,this.bgAudioMannager.src=this.dataUrl)},seek:function(e){this.bgAudioMannager.seek(e.detail.value)},pause:function(){this.bgAudioMannager.pause()},stop:function(){this.bgAudioMannager.stop(),this.$backgroundAudioData.playing=this.playing=!1,this.$backgroundAudioData.playTime=this.playTime=0,this.$backgroundAudioData.formatedPlayTime=this.formatedPlayTime=xa(0)}}};const La=t(Fa,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-center"},[e.createElementVNode("text",{class:"time-big"},e.toDisplayString(l.formatedPlayTime),1)]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("slider",{class:"slider",min:"0",max:"21",step:"1",value:l.playTime,onChange:n[0]||(n[0]=(...e)=>r.seek&&r.seek(...e))},null,40,["value"])]),e.createElementVNode("view",{class:"play-time"},[e.createElementVNode("text",null,"00:00"),e.createElementVNode("text",null,"00:21")]),e.createElementVNode("view",{class:"uni-hello-text"},"注意：离开当前页面后背景音乐将保持播放，但退出uni-app将停止"),e.createElementVNode("view",{class:"page-body-buttons"},[l.playing?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("view",{class:"page-body-button",onClick:n[1]||(n[1]=(...e)=>r.stop&&r.stop(...e))},[e.createElementVNode("image",{src:_a})]),e.createElementVNode("view",{class:"page-body-button",onClick:n[2]||(n[2]=(...e)=>r.pause&&r.pause(...e))},[e.createElementVNode("image",{src:"/static/pause.png"})])],64)):e.createCommentVNode("",!0),l.playing?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"page-body-button"}),e.createElementVNode("view",{class:"page-body-button",onClick:n[3]||(n[3]=(...e)=>r.play&&r.play(...e))},[e.createElementVNode("image",{src:Ea})])],64)),e.createElementVNode("view",{class:"page-body-button"})])])])}]]);var Ma=[["camera"],["album"],["camera","album"]];const Ra={data:()=>({title:"chooseVideo",sourceTypeIndex:2,sourceType:["拍摄","相册","拍摄或相册"],src:"",cameraList:[{value:"back",name:"后置摄像头",checked:"true"},{value:"front",name:"前置摄像头"}],cameraIndex:0}),onUnload(){this.src="",this.sourceTypeIndex=2,this.sourceType=["拍摄","相册","拍摄或相册"]},methods:{radioChange(e){for(let t=0;t<this.cameraList.length;t++)if(this.cameraList[t].value===e.detail.value){this.cameraIndex=t;break}},sourceTypeChange:function(e){this.sourceTypeIndex=parseInt(e.detail.value)},chooseVideo:function(){uni.chooseVideo({camera:this.cameraList[this.cameraIndex].value,sourceType:Ma[this.sourceTypeIndex],success:e=>{this.src=e.tempFilePath},fail:e=>{}})}}};const Oa=t(Ra,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"视频来源")]),e.createElementVNode("view",{class:"uni-list-cell-right"},[e.createElementVNode("picker",{range:l.sourceType,onChange:n[0]||(n[0]=(...e)=>r.sourceTypeChange&&r.sourceTypeChange(...e)),value:l.sourceTypeIndex},[e.createElementVNode("view",{class:"uni-input"},e.toDisplayString(l.sourceType[l.sourceTypeIndex]),1)],40,["range","value"])])])])]),e.createElementVNode("view",{class:"uni-title uni-common-mt uni-common-pl"},"摄像头位置"),e.createElementVNode("view",{class:"uni-hello-text camera-tips"},"注意：部分 Android 手机下由于系统 ROM 不支持无法生效，打开拍摄界面后可操作切换"),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("radio-group",{onChange:n[1]||(n[1]=(...e)=>r.radioChange&&r.radioChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.cameraList,((t,a)=>(e.openBlock(),e.createElementBlock("label",{class:"uni-list-cell uni-list-cell-pd",key:t.value},[e.createElementVNode("radio",{value:t.value,checked:a===l.cameraIndex},e.toDisplayString(t.name),9,["value","checked"])])))),128))],32)]),l.src?(e.openBlock(),e.createElementBlock("video",{key:1,src:l.src,class:"video"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-hello-addfile",onClick:n[2]||(n[2]=(...e)=>r.chooseVideo&&r.chooseVideo(...e))},"+ 添加视频"))])}]]);const $a=t({data:()=>({title:"saveFile",tempFilePath:"",savedFilePath:""}),onLoad(){this.savedFilePath=uni.getStorageSync("savedFilePath")},methods:{chooseImage(){uni.chooseImage({count:1,success:e=>{this.tempFilePath=e.tempFilePaths[0]},fail:e=>{}})},saveFile(){this.tempFilePath.length>0?uni.saveFile({tempFilePath:this.tempFilePath,success:e=>{this.savedFilePath=e.savedFilePath,uni.setStorageSync("savedFilePath",e.savedFilePath),uni.showModal({title:"保存成功",content:"下次进入页面时，此文件仍可用",showCancel:!1})},fail:e=>{uni.showModal({title:"保存失败",content:"失败原因: "+JSON.stringify(e),showCancel:!1})}}):uni.showModal({content:"请选择文件",showCancel:!1})},clear(){uni.setStorageSync("savedFilePath",""),this.tempFilePath="",this.savedFilePath=""},openDocument(){uni.downloadFile({url:"https://web-assets.dcloud.net.cn/unidoc/zh/helloworld.pdf",success:e=>{uni.openDocument({filePath:e.tempFilePath,success:()=>{n("log","at pages/API/file/file.vue:108","打开文档成功")}})}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[l.tempFilePath?(e.openBlock(),e.createElementBlock("image",{key:0,src:l.tempFilePath,class:"image",mode:"aspectFit"},null,8,["src"])):e.createCommentVNode("",!0),!l.tempFilePath&&l.savedFilePath?(e.openBlock(),e.createElementBlock("image",{key:1,src:l.savedFilePath,class:"image",mode:"aspectFit"},null,8,["src"])):e.createCommentVNode("",!0),l.tempFilePath||l.savedFilePath?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-hello-addfile",onClick:n[0]||(n[0]=(...e)=>r.chooseImage&&r.chooseImage(...e))},"+ 请选择文件")),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{class:"btn-savefile",onClick:n[1]||(n[1]=(...e)=>r.saveFile&&r.saveFile(...e))},"保存文件"),e.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>r.clear&&r.clear(...e))},"删除文件")]),e.createElementVNode("view",{class:"btn-area"},[e.createElementVNode("button",{onClick:n[3]||(n[3]=(...e)=>r.openDocument&&r.openDocument(...e))},"打开pdf文件")])])])}]]);class za{constructor(e,t){this.options=e,this.animation=uni.createAnimation({...e}),this.currentStepAnimates={},this.next=0,this.$=t}_nvuePushAnimates(e,t){let a=this.currentStepAnimates[this.next],n={};if(n=a||{styles:{},config:{}},Ua.includes(e)){n.styles.transform||(n.styles.transform="");let a="";"rotate"===e&&(a="deg"),n.styles.transform+=`${e}(${t+a}) `}else n.styles[e]=`${t}`;this.currentStepAnimates[this.next]=n}_animateRun(e={},t={}){let a=this.$.$refs.ani.ref;if(a)return new Promise(((n,i)=>{nvueAnimation.transition(a,{styles:e,...t},(e=>{n()}))}))}_nvueNextAnimate(e,t=0,a){let n=e[t];if(n){let{styles:i,config:o}=n;this._animateRun(i,o).then((()=>{t+=1,this._nvueNextAnimate(e,t,a)}))}else this.currentStepAnimates={},"function"==typeof a&&a(),this.isEnd=!0}step(e={}){return this.animation.step(e),this}run(e){this.$.animationData=this.animation.export(),this.$.timer=setTimeout((()=>{"function"==typeof e&&e()}),this.$.durationTime)}}const Ua=["matrix","matrix3d","rotate","rotate3d","rotateX","rotateY","rotateZ","scale","scale3d","scaleX","scaleY","scaleZ","skew","skewX","skewY","translate","translate3d","translateX","translateY","translateZ"];function ja(e,t){if(t)return clearTimeout(t.timer),new za(e,t)}Ua.concat(["opacity","backgroundColor"],["width","height","left","right","top","bottom"]).forEach((e=>{za.prototype[e]=function(...t){return this.animation[e](...t),this}}));const qa=t({name:"uniTransition",emits:["click","change"],props:{show:{type:Boolean,default:!1},modeClass:{type:[Array,String],default:()=>"fade"},duration:{type:Number,default:300},styles:{type:Object,default:()=>({})},customClass:{type:String,default:""},onceRender:{type:Boolean,default:!1}},data:()=>({isShow:!1,transform:"",opacity:1,animationData:{},durationTime:300,config:{}}),watch:{show:{handler(e){e?this.open():this.isShow&&this.close()},immediate:!0}},computed:{stylesObject(){let e={...this.styles,"transition-duration":this.duration/1e3+"s"},t="";for(let a in e){t+=this.toLine(a)+":"+e[a]+";"}return t},transformStyles(){return"transform:"+this.transform+";opacity:"+this.opacity+";"+this.stylesObject}},created(){this.config={duration:this.duration,timingFunction:"ease",transformOrigin:"50% 50%",delay:0},this.durationTime=this.duration},methods:{init(e={}){e.duration&&(this.durationTime=e.duration),this.animation=ja(Object.assign(this.config,e),this)},onClick(){this.$emit("click",{detail:this.isShow})},step(e,t={}){if(this.animation){for(let t in e)try{"object"==typeof e[t]?this.animation[t](...e[t]):this.animation[t](e[t])}catch($i){n("error","at uni_modules/uni-transition/components/uni-transition/uni-transition.vue:148",`方法 ${t} 不存在`)}return this.animation.step(t),this}},run(e){this.animation&&this.animation.run(e)},open(){clearTimeout(this.timer),this.transform="",this.isShow=!0;let{opacity:e,transform:t}=this.styleInit(!1);void 0!==e&&(this.opacity=e),this.transform=t,this.$nextTick((()=>{this.timer=setTimeout((()=>{this.animation=ja(this.config,this),this.tranfromInit(!1).step(),this.animation.run(),this.$emit("change",{detail:this.isShow})}),20)}))},close(e){this.animation&&this.tranfromInit(!0).step().run((()=>{this.isShow=!1,this.animationData=null,this.animation=null;let{opacity:e,transform:t}=this.styleInit(!1);this.opacity=e||1,this.transform=t,this.$emit("change",{detail:this.isShow})}))},styleInit(e){let t={transform:""},a=(e,a)=>{"fade"===a?t.opacity=this.animationType(e)[a]:t.transform+=this.animationType(e)[a]+" "};return"string"==typeof this.modeClass?a(e,this.modeClass):this.modeClass.forEach((t=>{a(e,t)})),t},tranfromInit(e){let t=(e,t)=>{let a=null;"fade"===t?a=e?0:1:(a=e?"-100%":"0","zoom-in"===t&&(a=e?.8:1),"zoom-out"===t&&(a=e?1.2:1),"slide-right"===t&&(a=e?"100%":"0"),"slide-bottom"===t&&(a=e?"100%":"0")),this.animation[this.animationMode()[t]](a)};return"string"==typeof this.modeClass?t(e,this.modeClass):this.modeClass.forEach((a=>{t(e,a)})),this.animation},animationType:e=>({fade:e?0:1,"slide-top":`translateY(${e?"0":"-100%"})`,"slide-right":`translateX(${e?"0":"100%"})`,"slide-bottom":`translateY(${e?"0":"100%"})`,"slide-left":`translateX(${e?"0":"-100%"})`,"zoom-in":`scaleX(${e?1:.8}) scaleY(${e?1:.8})`,"zoom-out":`scaleX(${e?1:1.2}) scaleY(${e?1:1.2})`}),animationMode:()=>({fade:"opacity","slide-top":"translateY","slide-right":"translateX","slide-bottom":"translateY","slide-left":"translateX","zoom-in":"scale","zoom-out":"scale"}),toLine:e=>e.replace(/([A-Z])/g,"-$1").toLowerCase()}},[["render",function(t,a,n,i,o,s){return e.withDirectives((e.openBlock(),e.createElementBlock("view",{ref:"ani",animation:o.animationData,class:e.normalizeClass(n.customClass),style:e.normalizeStyle(s.transformStyles),onClick:a[0]||(a[0]=(...e)=>s.onClick&&s.onClick(...e))},[e.renderSlot(t.$slots,"default")],14,["animation"])),[[e.vShow,o.isShow]])}]]),Ha={name:"uniPopup",components:{},emits:["change","maskClick"],props:{animation:{type:Boolean,default:!0},type:{type:String,default:"center"},isMaskClick:{type:Boolean,default:null},maskClick:{type:Boolean,default:null},backgroundColor:{type:String,default:"none"},safeArea:{type:Boolean,default:!0},maskBackgroundColor:{type:String,default:"rgba(0, 0, 0, 0.4)"},borderRadius:{type:String}},watch:{type:{handler:function(e){this.config[e]&&this[this.config[e]](!0)},immediate:!0},isDesktop:{handler:function(e){this.config[e]&&this[this.config[this.type]](!0)},immediate:!0},maskClick:{handler:function(e){this.mkclick=e},immediate:!0},isMaskClick:{handler:function(e){this.mkclick=e},immediate:!0},showPopup(e){}},data(){return{duration:300,ani:[],showPopup:!1,showTrans:!1,popupWidth:0,popupHeight:0,config:{top:"top",bottom:"bottom",center:"center",left:"left",right:"right",message:"top",dialog:"center",share:"bottom"},maskClass:{position:"fixed",bottom:0,top:0,left:0,right:0,backgroundColor:"rgba(0, 0, 0, 0.4)"},transClass:{backgroundColor:"transparent",borderRadius:this.borderRadius||"0",position:"fixed",left:0,right:0},maskShow:!0,mkclick:!0,popupstyle:"top"}},computed:{getStyles(){let e={backgroundColor:this.bg};return this.borderRadius,e=Object.assign(e,{borderRadius:this.borderRadius}),e},isDesktop(){return this.popupWidth>=500&&this.popupHeight>=500},bg(){return""===this.backgroundColor||"none"===this.backgroundColor?"transparent":this.backgroundColor}},mounted(){(()=>{const{windowWidth:e,windowHeight:t,windowTop:a,safeArea:n,screenHeight:i,safeAreaInsets:o}=uni.getSystemInfoSync();this.popupWidth=e,this.popupHeight=t+(a||0),n&&this.safeArea?this.safeAreaInsets=o.bottom:this.safeAreaInsets=0})()},unmounted(){this.setH5Visible()},activated(){this.setH5Visible(!this.showPopup)},deactivated(){this.setH5Visible(!0)},created(){null===this.isMaskClick&&null===this.maskClick?this.mkclick=!0:this.mkclick=null!==this.isMaskClick?this.isMaskClick:this.maskClick,this.animation?this.duration=300:this.duration=0,this.messageChild=null,this.clearPropagation=!1,this.maskClass.backgroundColor=this.maskBackgroundColor},methods:{setH5Visible(e=!0){},closeMask(){this.maskShow=!1},disableMask(){this.mkclick=!1},clear(e){e.stopPropagation(),this.clearPropagation=!0},open(e){if(this.showPopup)return;e&&-1!==["top","center","bottom","left","right","message","dialog","share"].indexOf(e)||(e=this.type),this.config[e]?(this[this.config[e]](),this.$emit("change",{show:!0,type:e})):n("error","at uni_modules/uni-popup/components/uni-popup/uni-popup.vue:310","缺少类型：",e)},close(e){this.showTrans=!1,this.$emit("change",{show:!1,type:this.type}),clearTimeout(this.timer),this.timer=setTimeout((()=>{this.showPopup=!1}),300)},touchstart(){this.clearPropagation=!1},onTap(){this.clearPropagation?this.clearPropagation=!1:(this.$emit("maskClick"),this.mkclick&&this.close())},top(e){this.popupstyle=this.isDesktop?"fixforpc-top":"top",this.ani=["slide-top"],this.transClass={position:"fixed",left:0,right:0,backgroundColor:this.bg,borderRadius:this.borderRadius||"0"},e||(this.showPopup=!0,this.showTrans=!0,this.$nextTick((()=>{this.showPoptrans(),this.messageChild&&"message"===this.type&&this.messageChild.timerClose()})))},bottom(e){this.popupstyle="bottom",this.ani=["slide-bottom"],this.transClass={position:"fixed",left:0,right:0,bottom:0,paddingBottom:this.safeAreaInsets+"px",backgroundColor:this.bg,borderRadius:this.borderRadius||"0"},e||this.showPoptrans()},center(e){this.popupstyle="center",this.ani=["zoom-out","fade"],this.transClass={position:"fixed",display:"flex",flexDirection:"column",bottom:0,left:0,right:0,top:0,justifyContent:"center",alignItems:"center",borderRadius:this.borderRadius||"0"},e||this.showPoptrans()},left(e){this.popupstyle="left",this.ani=["slide-left"],this.transClass={position:"fixed",left:0,bottom:0,top:0,backgroundColor:this.bg,borderRadius:this.borderRadius||"0",display:"flex",flexDirection:"column"},e||this.showPoptrans()},right(e){this.popupstyle="right",this.ani=["slide-right"],this.transClass={position:"fixed",bottom:0,right:0,top:0,backgroundColor:this.bg,borderRadius:this.borderRadius||"0",display:"flex",flexDirection:"column"},e||this.showPoptrans()},showPoptrans(){this.$nextTick((()=>{this.showPopup=!0,this.showTrans=!0}))}}};const Wa=t(Ha,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-transition"),qa);return s.showPopup?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-popup",[s.popupstyle,l.isDesktop?"fixforpc-z-index":""]])},[e.createElementVNode("view",{onTouchstart:a[1]||(a[1]=(...e)=>l.touchstart&&l.touchstart(...e))},[s.maskShow?(e.openBlock(),e.createBlock(r,{key:"1",name:"mask","mode-class":"fade",styles:s.maskClass,duration:s.duration,show:s.showTrans,onClick:l.onTap},null,8,["styles","duration","show","onClick"])):e.createCommentVNode("",!0),e.createVNode(r,{key:"2","mode-class":s.ani,name:"content",styles:s.transClass,duration:s.duration,show:s.showTrans,onClick:l.onTap},{default:e.withCtx((()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-popup__wrapper",[s.popupstyle]]),style:e.normalizeStyle(l.getStyles),onClick:a[0]||(a[0]=(...e)=>l.clear&&l.clear(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)])),_:3},8,["mode-class","styles","duration","show","onClick"])],32)],2)):e.createCommentVNode("",!0)}],["__scopeId","data-v-a9edff3b"]]);var Ja=Va;const Ga=t({data:()=>({title:"getLocation",hasLocation:!1,location:{},type:""}),methods:{togglePopup(e){this.type=e},showConfirm(){this.type="showpopup"},hideConfirm(){this.type=""},async getLocation(){1===await this.checkPermission()&&this.doGetLocation()},doGetLocation(){uni.getLocation({success:e=>{this.hasLocation=!0,this.location=Ja(e.longitude,e.latitude)},fail:e=>{e.errMsg.indexOf("auth deny")>=0?uni.showToast({title:"访问位置被拒绝"}):uni.showToast({title:e.errMsg})}})},getSetting:function(){return new Promise(((e,t)=>{uni.getSetting({success:t=>{void 0!==t.authSetting["scope.userLocation"]?t.authSetting["scope.userLocation"]?e(1):e(2):e(0)}})}))},openSetting:function(){this.hideConfirm(),uni.openSetting({success:e=>{e.authSetting&&e.authSetting["scope.userLocation"]&&this.doGetLocation()},fail:e=>{}})},async checkPermission(){let e=qe.isIOS?await qe.requestIOS("location"):await qe.requestAndroid("android.permission.ACCESS_FINE_LOCATION");return null===e||1===e?e=1:2===e?uni.showModal({content:"系统定位已关闭",confirmText:"确定",showCancel:!1,success:function(e){}}):e.code?uni.showModal({content:e.message}):uni.showModal({content:"需要定位权限",confirmText:"设置",success:function(e){e.confirm&&qe.gotoAppSetting()}}),e},clear:function(){this.hasLocation=!1}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-popup"),Wa);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{style:{background:"#FFFFFF",padding:"40rpx"}},[e.createElementVNode("view",{class:"uni-hello-text uni-center"},"当前位置经纬度"),!1===l.hasLocation?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-h2 uni-center uni-common-mt"},"未获取")):e.createCommentVNode("",!0),!0===l.hasLocation?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-h2 uni-center uni-common-mt"},[e.createElementVNode("text",null,"E: "+e.toDisplayString(l.location.longitude[0])+"°"+e.toDisplayString(l.location.longitude[1])+"′",1),e.createElementVNode("text",null,"\\nN: "+e.toDisplayString(l.location.latitude[0])+"°"+e.toDisplayString(l.location.latitude[1])+"′",1)])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.getLocation&&r.getLocation(...e))},"获取位置"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.clear&&r.clear(...e))},"清空")])]),e.createVNode(d,{show:"showpopup"===l.type,mode:"fixed",onHidePopup:n[4]||(n[4]=e=>r.togglePopup(""))},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"popup-view"},[e.createElementVNode("text",{class:"popup-title"},"需要用户授权位置权限"),e.createElementVNode("view",{class:"uni-flex popup-buttons"},[e.createElementVNode("button",{class:"uni-flex-item",type:"primary","open-type":"openSetting",onClick:n[2]||(n[2]=(...e)=>r.openSetting&&r.openSetting(...e))},"设置"),e.createElementVNode("button",{class:"uni-flex-item",onClick:n[3]||(n[3]=e=>r.togglePopup(""))},"取消")])])])),_:1},8,["show"])])}]]),Ka={data:()=>({title:"openLocation"}),methods:{openLocation:function(e){n("log","at pages/API/open-location/open-location.vue:58",e);var t=e.detail.value;uni.openLocation({longitude:Number(t.longitude),latitude:Number(t.latitude),name:t.name,address:t.address})}}};const Qa=t(Ka,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("form",{onSubmit:n[0]||(n[0]=(...e)=>r.openLocation&&r.openLocation(...e))},[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"经度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,value:"116.39747",name:"longitude"})])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"纬度")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,value:"39.9085",name:"latitude"})])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"位置名称")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,value:"天安门",name:"name"})])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"详细位置")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",disabled:!0,value:"北京市东城区东长安街",name:"address"})])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{type:"primary",formType:"submit"},"查看位置")])])],32)])])}]]);var Ya=Va;const Xa=t({data:()=>({title:"chooseLocation",hasLocation:!1,location:{},locationAddress:""}),methods:{chooseLocation:function(){uni.chooseLocation({success:e=>{this.hasLocation=!0,this.location=Ya(e.longitude,e.latitude),this.locationAddress=e.address}})},clear:function(){this.hasLocation=!1}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{style:{background:"#FFFFFF",padding:"40rpx"}},[e.createElementVNode("view",{class:"uni-hello-text uni-center"},"当前位置信息"),!1===l.hasLocation?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-h2 uni-center uni-common-mt"},"未选择位置")):e.createCommentVNode("",!0),!0===l.hasLocation?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"uni-hello-text uni-center",style:{"margin-top":"10px"}},e.toDisplayString(l.locationAddress),1),e.createElementVNode("view",{class:"uni-h2 uni-center uni-common-mt"},[e.createElementVNode("text",null,"E: "+e.toDisplayString(l.location.longitude[0])+"°"+e.toDisplayString(l.location.longitude[1])+"′",1),e.createElementVNode("text",null,"\\nN: "+e.toDisplayString(l.location.latitude[0])+"°"+e.toDisplayString(l.location.latitude[1])+"′",1)])],64)):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.chooseLocation&&r.chooseLocation(...e))},"选择位置"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.clear&&r.clear(...e))},"清空")])])])}]]),Za={data:()=>({title:"get/set/clearStorage",key:"",data:""}),methods:{keyChange:function(e){this.key=e.detail.value},dataChange:function(e){this.data=e.detail.value},getStorage:function(){var e=this.key;this.data,0===e.length?uni.showModal({title:"读取数据失败",content:"key 不能为空",showCancel:!1}):uni.getStorage({key:e,success:e=>{uni.showModal({title:"读取数据成功",content:"data: '"+e.data+"'",showCancel:!1})},fail:()=>{uni.showModal({title:"读取数据失败",content:"找不到 key 对应的数据",showCancel:!1})}})},setStorage:function(){var e=this.key,t=this.data;0===e.length?uni.showModal({title:"保存数据失败",content:"key 不能为空",showCancel:!1}):uni.setStorage({key:e,data:t,success:e=>{uni.showModal({title:"存储数据成功",content:JSON.stringify(e.errMsg),showCancel:!1})},fail:()=>{uni.showModal({title:"储存数据失败!",showCancel:!1})}})},clearStorage:function(){uni.clearStorageSync(),this.key="",this.data="",uni.showModal({title:"清除数据成功",content:" ",showCancel:!1})}}};const en=t(Za,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-common-mt"},[e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"key")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",placeholder:"请输入key",name:"key",value:l.key,onInput:n[0]||(n[0]=(...e)=>r.keyChange&&r.keyChange(...e))},null,40,["value"])])]),e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("view",{class:"uni-list-cell-left"},[e.createElementVNode("view",{class:"uni-label"},"value")]),e.createElementVNode("view",{class:"uni-list-cell-db"},[e.createElementVNode("input",{class:"uni-input",type:"text",placeholder:"请输入value",name:"data",value:l.data,onInput:n[1]||(n[1]=(...e)=>r.dataChange&&r.dataChange(...e))},null,40,["value"])])])]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",class:"btn-setstorage",onClick:n[2]||(n[2]=(...e)=>r.setStorage&&r.setStorage(...e))},"存储数据"),e.createElementVNode("button",{onClick:n[3]||(n[3]=(...e)=>r.getStorage&&r.getStorage(...e))},"读取数据"),e.createElementVNode("button",{onClick:n[4]||(n[4]=(...e)=>r.clearStorage&&r.clearStorage(...e))},"清理数据")])])])])}]]),tn={data:()=>({title:"SQLite"}),methods:{openDB:function(){plus.sqlite.openDatabase({name:"first",path:"_doc/test.db",success:function(e){plus.nativeUI.alert("打开数据库test.db成功 ")},fail:function(e){plus.nativeUI.alert("打开数据库test.db失败: "+JSON.stringify(e))}})},executeSQL:function(){plus.sqlite.executeSql({name:"first",sql:'create table if not exists database("name" CHAR(110),"sex" CHAR(10),"age" INT(11))',success:function(e){plus.sqlite.executeSql({name:"first",sql:"insert into database values('彦','女','7000')",success:function(e){plus.nativeUI.alert("创建表table和插入数据成功")},fail:function(e){plus.nativeUI.alert("创建表table成功但插入数据失败: "+JSON.stringify(e))}})},fail:function(e){plus.nativeUI.alert("创建表table失败: "+JSON.stringify(e))}})},selectSQL:function(){plus.sqlite.selectSql({name:"first",sql:"select * from database",success:function(e){plus.nativeUI.alert("查询SQL语句成功: "+JSON.stringify(e))},fail:function(e){plus.nativeUI.alert("查询SQL语句失败: "+JSON.stringify(e))}})},droptable:function(){plus.sqlite.executeSql({name:"first",sql:"drop table database",success:function(e){plus.nativeUI.alert("删除表database成功")},fail:function(e){plus.nativeUI.alert("删除表database失败: "+JSON.stringify(e))}})},closeDB:function(){plus.sqlite.closeDatabase({name:"first",success:function(e){plus.nativeUI.alert("关闭数据库成功")},fail:function(e){plus.nativeUI.alert("关闭数据库失败: "+JSON.stringify(e))}})},isOpenDB:function(){plus.sqlite.isOpenDatabase({name:"first",path:"_doc/test.db"})?plus.nativeUI.alert("Opened!"):plus.nativeUI.alert("Unopened!")}}};const an=t(tn,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.openDB&&r.openDB(...e))},"打开数据库test.db")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.executeSQL&&r.executeSQL(...e))},"创建表database及插入数据")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.selectSQL&&r.selectSQL(...e))},"查询表database的数据")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[3]||(n[3]=(...e)=>r.droptable&&r.droptable(...e))},"删除表database")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[4]||(n[4]=(...e)=>r.closeDB&&r.closeDB(...e))},"关闭数据库test.db")]),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[5]||(n[5]=(...e)=>r.isOpenDB&&r.isOpenDB(...e))},"查询是否打开数据库")])])])}]]),nn=[-5001,-5002,-5003,-5004,-5005,-5006];const on=t({data:()=>({title:"激励视频广告",loading:!1,loadError:!1}),onReady(){this.adOption={adpid:"1507000689"},this.createAd()},methods:{createAd(){var e=this.rewardedVideoAd=uni.createRewardedVideoAd(this.adOption);e.onLoad((()=>{this.loading=!1,this.loadError=!1,n("log","at pages/API/rewarded-video-ad/rewarded-video-ad.vue:46","onLoad event")})),e.onClose((e=>{this.loading=!0,e&&e.isEnded?n("log","at pages/API/rewarded-video-ad/rewarded-video-ad.vue:53","onClose "+e.isEnded):n("log","at pages/API/rewarded-video-ad/rewarded-video-ad.vue:56","onClose "+e.isEnded),setTimeout((()=>{uni.showToast({title:"激励视频"+(e.isEnded?"成功":"未")+"播放完毕",duration:1e4,position:"bottom"})}),500)})),e.onError((e=>{this.loading=!1,e.code&&-1!==nn.indexOf(e.code)&&(this.loadError=!0),n("log","at pages/API/rewarded-video-ad/rewarded-video-ad.vue:72","onError event",e)})),this.loading=!0},show(){const e=this.rewardedVideoAd;e.show().catch((()=>{e.load().then((()=>e.show())).catch((e=>{n("log","at pages/API/rewarded-video-ad/rewarded-video-ad.vue:82","激励视频 广告显示失败",e),uni.showToast({title:e.errMsg||e.message,duration:5e3,position:"bottom"})}))}))},reloadAd(){this.loading=!0,this.rewardedVideoAd.load()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[l.loadError?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,loading:l.loading,disabled:l.loading,type:"primary",class:"btn",onClick:n[0]||(n[0]=(...e)=>r.show&&r.show(...e))},"显示广告",8,["loading","disabled"])),l.loadError?(e.openBlock(),e.createElementBlock("button",{key:1,loading:l.loading,disabled:l.loading,type:"primary",class:"btn",onClick:n[1]||(n[1]=(...e)=>r.reloadAd&&r.reloadAd(...e))},"重新加载广告",8,["loading","disabled"])):e.createCommentVNode("",!0)])])}]]);const sn=t({data:()=>({title:"全屏视频广告",loading:!1,loadError:!1}),onReady(){this.adOption={adpid:"1507000611"},this.createAd()},methods:{createAd(){var e=this._ad=uni.createFullScreenVideoAd(this.adOption);e.onLoad((()=>{this.loading=!1,this.loadError=!1,e.show(),n("log","at pages/API/full-screen-video-ad/full-screen-video-ad.vue:34","onLoad event")})),e.onClose((e=>{e&&e.isEnded?n("log","at pages/API/full-screen-video-ad/full-screen-video-ad.vue:40","onClose "+e.isEnded):n("log","at pages/API/full-screen-video-ad/full-screen-video-ad.vue:43","onClose "+e.isEnded),setTimeout((()=>{uni.showToast({title:"全屏视频"+(e.isEnded?"成功":"未")+"播放完毕",duration:1e4,position:"bottom"})}),500)})),e.onError((e=>{this.loading=!1,e.code&&(this.loadError=!0),n("log","at pages/API/full-screen-video-ad/full-screen-video-ad.vue:59","onError event",e),uni.showToast({title:e.errMsg,position:"bottom"})}))},showAd(){this.loading=!0,this._ad.load()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("button",{loading:l.loading,disabled:l.loading,type:"primary",class:"btn",onClick:n[0]||(n[0]=(...e)=>r.showAd&&r.showAd(...e))},"显示广告",8,["loading","disabled"])])])}]]),ln={data:()=>({title:"brightness",screen:0,keepScreenOn:!0}),onLoad(){uni.getScreenBrightness({success:e=>{this.screen=(100*e.value).toFixed()},fail(e){n("log","at pages/API/brightness/brightness.vue:33",e)}})},methods:{sliderChange(e){let t=e.detail.value;this.screen!==t&&(n("log","at pages/API/brightness/brightness.vue:42","当前数值："+e.detail.value),uni.setScreenBrightness({value:t/100,success:function(){},fail(e){n("log","at pages/API/brightness/brightness.vue:48",e)}}),this.screen=t)},keep(){uni.setKeepScreenOn({keepScreenOn:this.keepScreenOn}),this.keepScreenOn=!this.keepScreenOn}}};const rn=t(ln,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"text-box"},"亮度 : "+e.toDisplayString(l.screen),1),e.createElementVNode("view",{class:"uni-slider"},[e.createElementVNode("slider",{value:l.screen,onChanging:n[0]||(n[0]=(...e)=>r.sliderChange&&r.sliderChange(...e)),step:"1"},null,40,["value"])]),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.keep&&r.keep(...e))},e.toDisplayString(l.keepScreenOn?"保持常亮状态":"关闭常亮状态"),1),e.createElementVNode("view",{class:"tips"}," 保持常亮时，屏幕不会熄灭。仅在当前应用生效，离开应用后设置失效。 ")])])}]]);const cn=t({data:()=>({title:"saveImage/saveVideo",imagePath:"",videoPath:""}),onLoad(){},methods:{videoErrorCallback:function(){uni.showModal({content:"视频加载失败",showCancel:!1})},saveImage(){uni.chooseImage({count:1,sourceType:["camera"],success:e=>{this.imagePath=e.tempFilePaths[0],this.getTempFilePath(e.tempFilePaths[0],"imageTempPath")},fail:e=>{}})},saveVideo(){uni.chooseVideo({count:1,sourceType:["camera"],success:e=>{n("log","at pages/API/save-media/save-media.vue:76",e.tempFilePath),this.videoPath=e.tempFilePath,this.getTempFilePath(e.tempFilePath,"videoTempPath")},fail:e=>{}})},getTempFilePath(e,t){let a={filePath:e,success:()=>{n("log","at pages/API/save-media/save-media.vue:108","save success"),uni.showModal({content:"保存成功",showCancel:!1}),uni.hideLoading()},fail:e=>{uni.hideLoading(),uni.showModal({content:"保存失败",showCancel:!1})}};uni.showLoading({title:"保存中..."}),"videoTempPath"===t?uni.saveVideoToPhotosAlbum(a):uni.saveImageToPhotosAlbum(a)}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[""!==l.imagePath?(e.openBlock(),e.createElementBlock("view",{key:0,class:"media-box image"},[e.createElementVNode("image",{class:"image",mode:"widthFix",src:l.imagePath},null,8,["src"])])):e.createCommentVNode("",!0),e.createElementVNode("button",{type:"primary",class:"uni-button",onClick:n[0]||(n[0]=(...e)=>r.saveImage&&r.saveImage(...e))},"拍摄图片并保存到本地"),""!==l.videoPath?(e.openBlock(),e.createElementBlock("view",{key:1,class:"media-box"},[e.createElementVNode("video",{id:"myVideo",src:l.videoPath,onError:n[1]||(n[1]=(...e)=>r.videoErrorCallback&&r.videoErrorCallback(...e)),"enable-danmu":"","danmu-btn":"",controls:""},null,40,["src"])])):e.createCommentVNode("",!0),e.createElementVNode("button",{type:"primary",class:"uni-button",onClick:n[2]||(n[2]=(...e)=>r.saveVideo&&r.saveVideo(...e))},"录制视频并保存到本地")])])}]]),dn={data:()=>({title:"bluetooth",disabled:[!1,!0,!0,!0,!0,!0,!0,!0,!0,!0,!0],newDeviceLoad:!1,searchLoad:!1,maskShow:!1,equipment:[],adapterState:{discovering:!1,available:!1},connected:!1,showMaskType:"device",servicesData:[],characteristicsData:[],valueChangeData:{},isStop:!0,list:[]}),onLoad(){this.onBLEConnectionStateChange()},methods:{moveHandle(){},maskclose(){this.maskShow=!1},queryDevices(){this.showMaskType="device",this.maskShow=!0},tapQuery(e){"device"===this.showMaskType&&(this.$set(this.disabled,4,!1),this.equipment.length>0?this.equipment[0]=e:this.equipment.push(e),this.newDeviceLoad=!1),"service"===this.showMaskType&&(this.$set(this.disabled,6,!1),this.servicesData.length>0?this.servicesData[0]=e:this.servicesData.push(e)),"characteristics"===this.showMaskType&&(this.$set(this.disabled,7,!1),this.characteristicsData.length>0?this.characteristicsData[0]=e:this.characteristicsData.push(e)),this.maskShow=!1},openBluetoothAdapter(){uni.openBluetoothAdapter({success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:212","初始化蓝牙成功:"+e.errMsg),n("log","at pages/API/bluetooth/bluetooth.vue:213",JSON.stringify(e)),this.isStop=!1,this.$set(this.disabled,0,!0),this.$set(this.disabled,1,!1),this.$set(this.disabled,10,!1),this.getBluetoothAdapterState()},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:221",e),n("log","at pages/API/bluetooth/bluetooth.vue:222","初始化蓝牙失败，错误码："+(e.errCode||e.errMsg)),0!==e.errCode&&un(e.errCode,e.errMsg)}})},startBluetoothDevicesDiscovery(){uni.startBluetoothDevicesDiscovery({success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:235","开始搜索蓝牙设备:"+e.errMsg),this.searchLoad=!0,this.$set(this.disabled,1,!0),this.$set(this.disabled,2,!1),this.$set(this.disabled,3,!1),this.onBluetoothDeviceFound()},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:243","搜索蓝牙设备失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},stopBluetoothDevicesDiscovery(e){uni.stopBluetoothDevicesDiscovery({success:t=>{n("log","at pages/API/bluetooth/bluetooth.vue:256","停止搜索蓝牙设备:"+t.errMsg),e?this.$set(this.disabled,1,!0):this.$set(this.disabled,1,!1),this.$set(this.disabled,2,!0),this.searchLoad=!1},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:267","停止搜索蓝牙设备失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},onBluetoothDeviceFound(){uni.onBluetoothDeviceFound((e=>{n("log","at pages/API/bluetooth/bluetooth.vue:279","开始监听寻找到新设备的事件"),this.getBluetoothDevices()}))},getBluetoothDevices(){uni.getBluetoothDevices({success:e=>{this.newDeviceLoad=!1,n("log","at pages/API/bluetooth/bluetooth.vue:291","获取蓝牙设备成功:"+e.errMsg),this.list=e.devices},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:296","获取蓝牙设备错误，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},getBluetoothAdapterState(){n("log","at pages/API/bluetooth/bluetooth.vue:307","---\x3e"),uni.getBluetoothAdapterState({success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:310",JSON.stringify(e)),this.adapterState=e},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:314","获取本机蓝牙适配器状态失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},createBLEConnection(){let e=this.equipment[0].deviceId;uni.showToast({title:"连接蓝牙...",icon:"loading",duration:99999}),uni.createBLEConnection({deviceId:e,success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:335",e),n("log","at pages/API/bluetooth/bluetooth.vue:336","连接蓝牙成功:"+e.errMsg),this.stopBluetoothDevicesDiscovery(!0),uni.hideToast(),uni.showToast({title:"连接成功",icon:"success",duration:2e3}),this.$set(this.disabled,3,!0),this.$set(this.disabled,4,!0),this.$set(this.disabled,5,!1),this.$set(this.disabled,9,!1),this.connected=!0},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:352","连接低功耗蓝牙失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},closeBLEConnection(){let e=this.equipment[0].deviceId;uni.closeBLEConnection({deviceId:e,success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:367",e),n("log","at pages/API/bluetooth/bluetooth.vue:368","断开低功耗蓝牙成功:"+e.errMsg),this.$set(this.disabled,1,!1),this.$set(this.disabled,3,!0),this.$set(this.disabled,4,!0),this.$set(this.disabled,5,!0),this.$set(this.disabled,6,!0),this.$set(this.disabled,7,!0),this.$set(this.disabled,8,!0),this.$set(this.disabled,9,!0),this.equipment=[],this.servicesData=[],this.characteristicsData=[]},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:382","断开低功耗蓝牙成功，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},getBLEDeviceServices(){let e=this.equipment[0].deviceId;n("log","at pages/API/bluetooth/bluetooth.vue:394","获取所有服务的 uuid:"+e),uni.getBLEDeviceServices({deviceId:e,success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:400",JSON.stringify(e.services)),n("log","at pages/API/bluetooth/bluetooth.vue:401","获取设备服务成功:"+e.errMsg),this.$set(this.disabled,7,!0),this.$set(this.disabled,8,!0),this.showMaskType="service",this.list=e.services,this.characteristicsData=[],this.list.length<=0?hn("获取服务失败，请重试!"):this.maskShow=!0},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:415","获取设备服务失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},getBLEDeviceCharacteristics(){let e=this.equipment[0].deviceId,t=this.servicesData[0].uuid;n("log","at pages/API/bluetooth/bluetooth.vue:428",e),n("log","at pages/API/bluetooth/bluetooth.vue:429",t),uni.getBLEDeviceCharacteristics({deviceId:e,serviceId:t,success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:436",JSON.stringify(e)),n("log","at pages/API/bluetooth/bluetooth.vue:437","获取特征值成功:"+e.errMsg),this.$set(this.disabled,7,!0),this.valueChangeData={},this.showMaskType="characteristics",this.list=e.characteristics,this.list.length<=0?hn("获取特征值失败，请重试!"):this.maskShow=!0},fail:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:449","获取特征值失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}})},onBLEConnectionStateChange(){uni.onBLEConnectionStateChange((e=>{if(n("log","at pages/API/bluetooth/bluetooth.vue:462","蓝牙连接状态 --------------------------\x3e"),n("log","at pages/API/bluetooth/bluetooth.vue:463",JSON.stringify(e)),!e.connected){if(this.isStop)return;n("log","at pages/API/bluetooth/bluetooth.vue:466","断开低功耗蓝牙成功:"),this.$set(this.disabled,1,!1),this.$set(this.disabled,3,!0),this.$set(this.disabled,4,!0),this.$set(this.disabled,5,!0),this.$set(this.disabled,6,!0),this.$set(this.disabled,7,!0),this.$set(this.disabled,8,!0),this.$set(this.disabled,9,!0),this.searchLoad=!1,this.equipment=[],this.servicesData=[],this.characteristicsData=[],this.valueChangeData={},hn("已经断开当前蓝牙连接")}}))},readBLECharacteristicValue(){let e=this.equipment[0].deviceId,t=this.servicesData[0].uuid,a=this.characteristicsData[0].uuid;n("log","at pages/API/bluetooth/bluetooth.vue:491",e),n("log","at pages/API/bluetooth/bluetooth.vue:492",t),n("log","at pages/API/bluetooth/bluetooth.vue:493",a),uni.readBLECharacteristicValue({deviceId:e,serviceId:t,characteristicId:a,success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:502","读取设备数据值成功"),n("log","at pages/API/bluetooth/bluetooth.vue:503",JSON.stringify(e)),this.notifyBLECharacteristicValueChange()},fail(e){n("log","at pages/API/bluetooth/bluetooth.vue:507","读取设备数据值失败，错误码："+e.errCode),0!==e.errCode&&un(e.errCode)}}),this.onBLECharacteristicValueChange()},onBLECharacteristicValueChange(){uni.onBLECharacteristicValueChange((e=>{n("log","at pages/API/bluetooth/bluetooth.vue:521","监听低功耗蓝牙设备的特征值变化事件成功"),n("log","at pages/API/bluetooth/bluetooth.vue:522",JSON.stringify(e)),this.valueChangeData=e}))},notifyBLECharacteristicValueChange(){let e=this.equipment[0].deviceId,t=this.servicesData[0].uuid,a=this.characteristicsData[0].uuid,i=this.characteristicsData[0].properties.notify;n("log","at pages/API/bluetooth/bluetooth.vue:534",e),n("log","at pages/API/bluetooth/bluetooth.vue:535",t),n("log","at pages/API/bluetooth/bluetooth.vue:536",a),n("log","at pages/API/bluetooth/bluetooth.vue:537",i),uni.notifyBLECharacteristicValueChange({state:!0,deviceId:e,serviceId:t,characteristicId:a,success(e){n("log","at pages/API/bluetooth/bluetooth.vue:547","notifyBLECharacteristicValueChange success:"+e.errMsg),n("log","at pages/API/bluetooth/bluetooth.vue:548",JSON.stringify(e))}})},closeBluetoothAdapter(e){uni.closeBluetoothAdapter({success:e=>{n("log","at pages/API/bluetooth/bluetooth.vue:558","断开蓝牙模块成功"),this.isStop=!0,this.$set(this.disabled,0,!1),this.$set(this.disabled,1,!0),this.$set(this.disabled,2,!0),this.$set(this.disabled,3,!0),this.$set(this.disabled,4,!0),this.$set(this.disabled,5,!0),this.$set(this.disabled,6,!0),this.$set(this.disabled,7,!0),this.$set(this.disabled,8,!0),this.$set(this.disabled,9,!0),this.$set(this.disabled,10,!0),this.equipment=[],this.servicesData=[],this.characteristicsData=[],this.valueChangeData={},this.adapterState=[],this.searchLoad=!1,hn("断开蓝牙模块")}})}}};function un(e,t){switch(e){case 1e4:hn("未初始化蓝牙适配器");break;case 10001:hn("未检测到蓝牙，请打开蓝牙重试！");break;case 10002:hn("没有找到指定设备");break;case 10003:hn("连接失败");break;case 10004:hn("没有找到指定服务");break;case 10005:hn("没有找到指定特征值");break;case 10006:hn("当前连接已断开");break;case 10007:hn("当前特征值不支持此操作");break;case 10008:hn("其余所有系统上报的异常");break;case 10009:hn("Android 系统特有，系统版本低于 4.3 不支持 BLE");break;default:hn(t)}}function hn(e,t=!1){uni.showModal({title:"提示",content:e,showCancel:t})}const pn=t(dn,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",null," 本蓝牙协议只支持低功耗蓝牙协议ble。如果想连接非ble蓝牙设备，请在社区搜索 Native.js 蓝牙。 "),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",disabled:l.disabled[0],onClick:n[0]||(n[0]=(...e)=>r.openBluetoothAdapter&&r.openBluetoothAdapter(...e))}," 初始化蓝牙模块 ",8,["disabled"]),l.adapterState.available?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0},e.toDisplayString("蓝牙适配器不可用,请初始化蓝牙模块"))),e.createElementVNode("button",{type:"primary",loading:l.searchLoad,disabled:l.disabled[1],onClick:n[1]||(n[1]=(...e)=>r.startBluetoothDevicesDiscovery&&r.startBluetoothDevicesDiscovery(...e))}," 开始搜索蓝牙设备 ",8,["loading","disabled"]),e.createElementVNode("button",{type:"primary",disabled:l.disabled[2],onClick:n[2]||(n[2]=e=>r.stopBluetoothDevicesDiscovery(!1))}," 停止搜索蓝牙设备 ",8,["disabled"]),e.createElementVNode("button",{type:"primary",loading:l.newDeviceLoad,disabled:l.disabled[3],onClick:n[3]||(n[3]=(...e)=>r.queryDevices&&r.queryDevices(...e))}," 选择设备 ",8,["loading","disabled"]),l.equipment.length>0?(e.openBlock(),e.createElementBlock("view",{key:1},e.toDisplayString((l.connected?"已连接设备":"已选择设备")+" : "+l.equipment[0].name+" ("+l.equipment[0].deviceId+")"),1)):e.createCommentVNode("",!0),e.createElementVNode("button",{type:"primary",disabled:l.disabled[4],onClick:n[4]||(n[4]=(...e)=>r.createBLEConnection&&r.createBLEConnection(...e))}," 连接蓝牙设备 ",8,["disabled"]),e.createElementVNode("button",{type:"primary",disabled:l.disabled[5],onClick:n[5]||(n[5]=(...e)=>r.getBLEDeviceServices&&r.getBLEDeviceServices(...e))}," 选择设备服务 ",8,["disabled"]),l.servicesData.length>0?(e.openBlock(),e.createElementBlock("view",{key:2},"已选服务uuid："+e.toDisplayString(l.servicesData[0].uuid),1)):e.createCommentVNode("",!0),e.createElementVNode("button",{type:"primary",disabled:l.disabled[6],onClick:n[6]||(n[6]=(...e)=>r.getBLEDeviceCharacteristics&&r.getBLEDeviceCharacteristics(...e))}," 获取服务的特征值 ",8,["disabled"]),l.characteristicsData.length>0?(e.openBlock(),e.createElementBlock("view",{key:3},[e.createElementVNode("view",{class:"uni-list_name"},"uuid:"+e.toDisplayString(l.characteristicsData[0].uuid),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 read 操作:"+e.toDisplayString(l.characteristicsData[0].properties.read),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 write 操作:"+e.toDisplayString(l.characteristicsData[0].properties.write),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 notify 操作:"+e.toDisplayString(l.characteristicsData[0].properties.notify),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 indicate 操作:"+e.toDisplayString(l.characteristicsData[0].properties.indicate),1)])):e.createCommentVNode("",!0),e.createElementVNode("button",{type:"primary",disabled:l.disabled[9],onClick:n[7]||(n[7]=(...e)=>r.closeBLEConnection&&r.closeBLEConnection(...e))}," 断开蓝牙设备 ",8,["disabled"]),e.createElementVNode("button",{type:"primary",disabled:l.disabled[10],onClick:n[8]||(n[8]=(...e)=>r.closeBluetoothAdapter&&r.closeBluetoothAdapter(...e))}," 关闭蓝牙模块 ",8,["disabled"])])]),l.maskShow?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-mask",onTouchmove:n[11]||(n[11]=e.withModifiers(((...e)=>r.moveHandle&&r.moveHandle(...e)),["stop","prevent"])),onClick:n[12]||(n[12]=(...e)=>r.maskclose&&r.maskclose(...e))},[e.createElementVNode("scroll-view",{class:"uni-scroll_box","scroll-y":"",onTouchmove:n[9]||(n[9]=e.withModifiers(((...e)=>r.moveHandle&&r.moveHandle(...e)),["stop","prevent"])),onClick:n[10]||(n[10]=e.withModifiers(((...e)=>r.moveHandle&&r.moveHandle(...e)),["stop"]))},[e.createElementVNode("view",{class:"uni-title"}," 已经发现"+e.toDisplayString(l.list.length)+e.toDisplayString("device"===l.showMaskType?"台设备":"个服务")+": ",1),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.list,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-list-box",key:a,onClick:e=>r.tapQuery(t)},["device"===l.showMaskType?(e.openBlock(),e.createElementBlock("view",{key:0},[e.createElementVNode("view",{class:"uni-list_name"},e.toDisplayString(t.name||t.localName),1),e.createElementVNode("view",{class:"uni-list_item"},"信号强度:"+e.toDisplayString(t.RSSI)+"dBm",1),e.createElementVNode("view",{class:"uni-list_item"},"UUID:"+e.toDisplayString(t.deviceId),1)])):e.createCommentVNode("",!0),"service"===l.showMaskType?(e.openBlock(),e.createElementBlock("view",{key:1},[e.createElementVNode("view",{class:"uni-list_item",style:{"line-height":"2.2"}},[e.createTextVNode(" UUID: "+e.toDisplayString(t.uuid)+" ",1),"service"===l.showMaskType?(e.openBlock(),e.createElementBlock("text",{key:0},e.toDisplayString(t.isPrimary?"（主服务）":""),1)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),"characteristics"===l.showMaskType?(e.openBlock(),e.createElementBlock("view",{key:2},[e.createElementVNode("view",{class:"uni-list_name"},"uuid:"+e.toDisplayString(t.uuid),1),e.createElementVNode("view",{class:"uni-list_item"},"是否支持 read 操作:"+e.toDisplayString(t.properties.read),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 write 操作:"+e.toDisplayString(t.properties.write),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 notify 操作:"+e.toDisplayString(t.properties.notify),1),e.createElementVNode("view",{class:"uni-list_item"}," 是否支持 indicate 操作:"+e.toDisplayString(t.properties.indicate),1)])):e.createCommentVNode("",!0)],8,["onClick"])))),128))],32)],32)):e.createCommentVNode("",!0)])}]]);const mn=t({data:()=>({title:"生物认证",result:""}),onLoad(){},methods:{checkIsSupportSoterAuthentication(){uni.checkIsSupportSoterAuthentication({success(e){uni.showModal({content:"支持的认证方式："+e.supportMode,showCancel:!1}),n("log","at pages/API/soter/soter.vue:36",e)},fail(e){n("log","at pages/API/soter/soter.vue:39",e)}})},checkIsSoterEnrolledInDeviceFingerPrint(){uni.checkIsSoterEnrolledInDevice({checkAuthMode:"fingerPrint",success(e){e.isEnrolled?uni.showToast({icon:"none",title:"已录入指纹"}):uni.showModal({content:"未录入指纹",showCancel:!1}),n("log","at pages/API/soter/soter.vue:58",e)},fail(e){uni.showModal({content:"未录入指纹",showCancel:!1}),n("log","at pages/API/soter/soter.vue:65",e)}})},checkIsSoterEnrolledInDeviceFaceID(){uni.checkIsSoterEnrolledInDevice({checkAuthMode:"facial",success(e){e.isEnrolled?uni.showToast({icon:"none",title:"已录入FaceID"}):uni.showModal({content:"未录入FaceID",showCancel:!1}),n("log","at pages/API/soter/soter.vue:84",e)},fail(e){uni.showModal({content:"未录入FaceID",showCancel:!1}),n("log","at pages/API/soter/soter.vue:91",e)}})},startSoterAuthenticationFingerPrint(){uni.startSoterAuthentication({requestAuthModes:["fingerPrint"],challenge:"123456",authContent:"请用指纹解锁",success(e){uni.showToast({icon:"none",title:"指纹验证成功"}),n("log","at pages/API/soter/soter.vue:105",e)},fail(e){uni.showModal({content:"指纹验证失败，errCode："+e.errCode,showCancel:!1}),n("log","at pages/API/soter/soter.vue:112",e)}})},startSoterAuthenticationFaceID(){uni.startSoterAuthentication({requestAuthModes:["facial"],challenge:"123456",authContent:"请用FaceID解锁",success(e){uni.showToast({icon:"none",title:"FaceID验证成功"}),n("log","at pages/API/soter/soter.vue:126",e)},fail(e){uni.showModal({content:"FaceID验证失败，errCode："+e.errCode,showCancel:!1}),n("log","at pages/API/soter/soter.vue:133",e)}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.checkIsSupportSoterAuthentication&&r.checkIsSupportSoterAuthentication(...e))},"检查支持的认证方式"),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.checkIsSoterEnrolledInDeviceFingerPrint&&r.checkIsSoterEnrolledInDeviceFingerPrint(...e))},"检查是否录入指纹"),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.checkIsSoterEnrolledInDeviceFaceID&&r.checkIsSoterEnrolledInDeviceFaceID(...e))},"检查是否录入FaceID"),e.createElementVNode("button",{type:"primary",onClick:n[3]||(n[3]=(...e)=>r.startSoterAuthenticationFingerPrint&&r.startSoterAuthenticationFingerPrint(...e))},"开始指纹认证"),e.createElementVNode("button",{type:"primary",onClick:n[4]||(n[4]=(...e)=>r.startSoterAuthenticationFaceID&&r.startSoterAuthenticationFaceID(...e))},"开始FaceID认证")]),e.createElementVNode("view",{style:{width:"100%","text-align":"center"}},e.toDisplayString(l.result),1)])])}]]);function gn(e,t){switch(e){case 1e4:fn("未初始化蓝牙适配器");break;case 10001:fn("未检测到蓝牙，请打开蓝牙重试！");break;case 10002:fn("没有找到指定设备");break;case 10003:fn("连接失败");break;case 10004:fn("没有找到指定服务");break;case 10005:fn("没有找到指定特征值");break;case 10006:fn("当前连接已断开");break;case 10007:fn("当前特征值不支持此操作");break;case 10008:fn("其余所有系统上报的异常");break;case 10009:fn("Android 系统特有，系统版本低于 4.3 不支持 BLE");break;default:fn(t)}}function fn(e,t=!1){uni.showModal({title:"提示",content:e,showCancel:t})}const yn=t({data:()=>({title:"iBeacon",isOpen:!1,isStarted:!1,deviceList:[],isPageOpened:!1}),onLoad(){this.onBeaconUpdate()},onShow(){this.isPageOpened=!0},methods:{maskclose(){this.maskShow=!1},openBluetoothAdapter(){uni.openBluetoothAdapter({success:e=>{n("log","at pages/API/ibeacon/ibeacon.vue:52","初始化蓝牙成功:"+e.errMsg),n("log","at pages/API/ibeacon/ibeacon.vue:53",e),this.isOpen=!0,this.deviceList=[]},fail:e=>{n("log","at pages/API/ibeacon/ibeacon.vue:58","初始化蓝牙失败，错误码："+(e.errCode||e.errMsg)),0!==e.errCode&&gn(e.errCode,e.errMsg)}})},closeBluetoothAdapter(e){this.stopBeaconDiscovery(),wx.closeBluetoothAdapter({success:e=>{this.isOpen=!1,n("log","at pages/API/ibeacon/ibeacon.vue:70","断开蓝牙模块成功")}})},onBeaconUpdate(){uni.onBeaconUpdate((e=>{this.isPageOpened&&this.isOpen&&this.isStarted&&(n("log","at pages/API/ibeacon/ibeacon.vue:79",e),e.beacons&&e.beacons.length>0?this.getBeacons():e.connected||(this.deviceList=[]))}))},startBeaconDiscovery(){uni.startBeaconDiscovery({uuids:this.getUUIDList(),success:e=>{this.isStarted=!0,n("log","at pages/API/ibeacon/ibeacon.vue:95",e)},fail:e=>{n("error","at pages/API/ibeacon/ibeacon.vue:98",e)}})},stopBeaconDiscovery(e){this.isStarted&&uni.stopBeaconDiscovery({success:e=>{this.isStarted=!1},fail:e=>{n("error","at pages/API/ibeacon/ibeacon.vue:109",e)}})},getBeacons(){uni.getBeacons({success:e=>{e.beacons&&e.beacons.length>0&&(n("log","at pages/API/ibeacon/ibeacon.vue:118",e.beacons),this.deviceList=e.beacons)},fail:e=>{n("log","at pages/API/ibeacon/ibeacon.vue:123","获取设备服务失败，错误码："+e.errCode),0!==errCode.errCode&&gn(errCode.errCode)}})},getUUIDList(){const e=uni.getSystemInfoSync();if(!e)return[];return!!e.platform&&"ios"===e.platform.toLowerCase()?["FDA50693-A4E2-4FB1-AFCF-C6EB07647825"]:[]}},onUnload(){this.isPageOpened=!1}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"primary",disabled:l.isOpen,onClick:n[0]||(n[0]=(...e)=>r.openBluetoothAdapter&&r.openBluetoothAdapter(...e))},"打开蓝牙模块",8,["disabled"]),e.createElementVNode("button",{type:"primary",disabled:!l.isOpen,onClick:n[1]||(n[1]=(...e)=>r.closeBluetoothAdapter&&r.closeBluetoothAdapter(...e))},"关闭蓝牙模块",8,["disabled"]),e.createElementVNode("button",{type:"primary",disabled:!l.isOpen||l.isStarted,loading:l.isStarted,onClick:n[2]||(n[2]=(...e)=>r.startBeaconDiscovery&&r.startBeaconDiscovery(...e))},"开始搜索附近的iBeacon设备",8,["disabled","loading"]),e.createElementVNode("button",{type:"primary",disabled:!l.isStarted,onClick:n[3]||(n[3]=(...e)=>r.stopBeaconDiscovery&&r.stopBeaconDiscovery(...e))},"停止搜索附近的iBeacon设备",8,["disabled"])])]),e.createElementVNode("scroll-view",{class:"uni-scroll_box"},[l.isStarted||l.deviceList.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-title"},"已经发现 "+e.toDisplayString(l.deviceList.length)+" 台设备:",1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.deviceList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-list-box",key:t.uuid},[e.createElementVNode("view",null,[e.createElementVNode("view",{class:"uni-list_name"},"UUID: "+e.toDisplayString(t.uuid),1),e.createElementVNode("view",{class:"uni-list_item"},"major: "+e.toDisplayString(t.major),1),e.createElementVNode("view",{class:"uni-list_item"},"minor: "+e.toDisplayString(t.minor),1),e.createElementVNode("view",{class:"uni-list_item"},"rssi: "+e.toDisplayString(t.rssi)+" dBm",1),e.createElementVNode("view",{class:"uni-list_item"},"accuracy: "+e.toDisplayString(t.accuracy),1),e.createElementVNode("view",{class:"uni-list_item"},"heading: "+e.toDisplayString(t.heading),1)])])))),128))])])}]]);const vn=t({data:()=>({title:"vibrateLong/vibrateShort"}),onLoad(){},methods:{longshock(){uni.vibrateLong({success:function(){n("log","at pages/API/vibrate/vibrate.vue:28","success")}})},shortshock(){uni.vibrateShort({success:function(){n("log","at pages/API/vibrate/vibrate.vue:38","success")}})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("button",{class:"uni-button",type:"primary",onClick:n[0]||(n[0]=(...e)=>r.longshock&&r.longshock(...e))},"长震动"),e.createElementVNode("button",{class:"uni-button",onClick:n[1]||(n[1]=(...e)=>r.shortshock&&r.shortshock(...e))},"短震动"),e.createElementVNode("view",{class:"uni-tips"},[e.createElementVNode("view",null,"Tips"),e.createElementVNode("view",{class:"uni-tips-text"},"iOS上只有长震动，没有短震动"),e.createElementVNode("view",{class:"uni-tips-text"},"iOS上需要手机设置“打开响铃时震动”或“静音时震动”，否则无法震动")])])])}]]);let wn=uni.getSystemInfoSync().platform;const bn=t({data:()=>({connected:!1,connecting:!1,socketTask:!1,msg:!1}),computed:{showMsg(){return this.connected?this.msg?"收到消息："+this.msg:"等待接收消息":"尚未连接"}},onUnload(){uni.hideLoading(),this.socketTask&&this.socketTask.close&&this.socketTask.close()},methods:{connect(){if(this.connected||this.connecting)return uni.showModal({content:"正在连接或者已经连接，请勿重复连接",showCancel:!1}),!1;this.connecting=!0,uni.showLoading({title:"连接中..."}),this.socketTask=uni.connectSocket({url:"wss://echo.websocket.org",data:()=>({msg:"Hello"}),success(e){},fail(e){}}),n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:81",this.socketTask),this.socketTask.onOpen((e=>{this.connecting=!1,this.connected=!0,uni.hideLoading(),uni.showToast({icon:"none",title:"连接成功"}),n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:90","onOpen",e)})),this.socketTask.onError((e=>{this.connecting=!1,this.connected=!1,uni.hideLoading(),uni.showModal({content:"连接失败，可能是websocket服务不可用，请稍后再试",showCancel:!1}),n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:100","onError",e)})),this.socketTask.onMessage((e=>{this.msg=e.data,n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:104","onMessage",e)})),this.socketTask.onClose((e=>{this.connected=!1,this.startRecive=!1,this.socketTask=!1,this.msg=!1,n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:111","onClose",e)})),n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:113","task",this.socketTask)},send(){this.socketTask.send({data:"from "+wn+" : "+parseInt(1e4*Math.random()).toString(),success(e){n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:119",e)},fail(e){n("log","at pages/API/websocket-socketTask/websocket-socketTask.vue:122",e)}})},close(){this.socketTask&&this.socketTask.close&&this.socketTask.close()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"websocket通讯示例"}),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("view",{class:"websocket-msg"},e.toDisplayString(r.showMsg),1),e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.connect&&r.connect(...e))},"连接websocket服务"),e.withDirectives(e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.send&&r.send(...e))},"发送一条消息",512),[[e.vShow,l.connected]]),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.close&&r.close(...e))},"断开websocket服务"),e.createElementVNode("view",{class:"websocket-tips"},"发送消息后会收到一条服务器返回的消息（与发送的消息内容一致）")])])])}]]);let kn=uni.getSystemInfoSync().platform;const xn=t({data:()=>({connected:!1,connecting:!1,msg:!1,roomId:""}),computed:{showMsg(){return this.connected?this.msg?"收到消息："+this.msg:"等待接收消息":"尚未连接"}},onUnload(){uni.closeSocket(),uni.hideLoading()},methods:{connect(){if(this.connected||this.connecting)return uni.showModal({content:"正在连接或者已经连接，请勿重复连接",showCancel:!1}),!1;this.connecting=!0,uni.showLoading({title:"连接中..."}),uni.connectSocket({url:"wss://echo.websocket.org",data:()=>({msg:"Hello"}),success(e){},fail(e){}}),uni.onSocketOpen((e=>{this.connecting=!1,this.connected=!0,uni.hideLoading(),uni.showToast({icon:"none",title:"连接成功"}),n("log","at pages/API/websocket-global/websocket-global.vue:87","onOpen",e)})),uni.onSocketError((e=>{this.connecting=!1,this.connected=!1,uni.hideLoading(),uni.showModal({content:"连接失败，可能是websocket服务不可用，请稍后再试",showCancel:!1}),n("log","at pages/API/websocket-global/websocket-global.vue:97","onError",e)})),uni.onSocketMessage((e=>{this.msg=e.data,n("log","at pages/API/websocket-global/websocket-global.vue:101","onMessage",e)})),uni.onSocketClose((e=>{this.connected=!1,this.startRecive=!1,this.msg=!1,n("log","at pages/API/websocket-global/websocket-global.vue:107","onClose",e)}))},send(){uni.sendSocketMessage({data:"from "+kn+" : "+parseInt(1e4*Math.random()).toString(),success(e){n("log","at pages/API/websocket-global/websocket-global.vue:114",e)},fail(e){n("log","at pages/API/websocket-global/websocket-global.vue:117",e)}})},close(){uni.closeSocket()}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"websocket通讯示例"}),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("view",{class:"websocket-msg"},e.toDisplayString(r.showMsg),1),e.createElementVNode("button",{type:"primary",onClick:n[0]||(n[0]=(...e)=>r.connect&&r.connect(...e))},"连接websocket服务"),e.withDirectives(e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.send&&r.send(...e))},"发送一条消息",512),[[e.vShow,l.connected]]),e.createElementVNode("button",{type:"primary",onClick:n[2]||(n[2]=(...e)=>r.close&&r.close(...e))},"断开websocket服务"),e.createElementVNode("view",{class:"websocket-tips"},"发送消息后会收到一条服务器返回的消息（与发送的消息内容一致）")])])])}]]);const Vn=t({name:"UniCard",emits:["click"],props:{title:{type:String,default:""},subTitle:{type:String,default:""},padding:{type:String,default:"10px"},margin:{type:String,default:"15px"},spacing:{type:String,default:"0 10px"},extra:{type:String,default:""},cover:{type:String,default:""},thumbnail:{type:String,default:""},isFull:{type:Boolean,default:!1},isShadow:{type:Boolean,default:!0},shadow:{type:String,default:"0px 0px 3px 1px rgba(0, 0, 0, 0.08)"},border:{type:Boolean,default:!0}},methods:{onClick(e){this.$emit("click",e)}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-card",{"uni-card--full":n.isFull,"uni-card--shadow":n.isShadow,"uni-card--border":n.border}]),style:e.normalizeStyle({margin:n.isFull?0:n.margin,padding:n.spacing,"box-shadow":n.isShadow?n.shadow:""})},[e.renderSlot(t.$slots,"cover",{},(()=>[n.cover?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-card__cover"},[e.createElementVNode("image",{class:"uni-card__cover-image",mode:"widthFix",onClick:a[0]||(a[0]=e=>s.onClick("cover")),src:n.cover},null,8,["src"])])):e.createCommentVNode("",!0)]),!0),e.renderSlot(t.$slots,"title",{},(()=>[n.title||n.extra?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-card__header"},[e.createElementVNode("view",{class:"uni-card__header-box",onClick:a[1]||(a[1]=e=>s.onClick("title"))},[n.thumbnail?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-card__header-avatar"},[e.createElementVNode("image",{class:"uni-card__header-avatar-image",src:n.thumbnail,mode:"aspectFit"},null,8,["src"])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-card__header-content"},[e.createElementVNode("text",{class:"uni-card__header-content-title uni-ellipsis"},e.toDisplayString(n.title),1),n.title&&n.subTitle?(e.openBlock(),e.createElementBlock("text",{key:0,class:"uni-card__header-content-subtitle uni-ellipsis"},e.toDisplayString(n.subTitle),1)):e.createCommentVNode("",!0)])]),e.createElementVNode("view",{class:"uni-card__header-extra",onClick:a[2]||(a[2]=e=>s.onClick("extra"))},[e.createElementVNode("text",{class:"uni-card__header-extra-text"},e.toDisplayString(n.extra),1)])])):e.createCommentVNode("",!0)]),!0),e.createElementVNode("view",{class:"uni-card__content",style:e.normalizeStyle({padding:n.padding}),onClick:a[3]||(a[3]=e=>s.onClick("content"))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],4),e.createElementVNode("view",{class:"uni-card__actions",onClick:a[4]||(a[4]=e=>s.onClick("actions"))},[e.renderSlot(t.$slots,"actions",{},void 0,!0)])],6)}],["__scopeId","data-v-a4d554f5"]]);function Nn(e){let t="";for(let a in e){t+=`${a}:${e[a]};`}return t}const En=t({name:"uni-easyinput",emits:["click","iconClick","update:modelValue","input","focus","blur","confirm","clear","eyes","change","keyboardheightchange"],model:{prop:"modelValue",event:"update:modelValue"},options:{virtualHost:!0},inject:{form:{from:"uniForm",default:null},formItem:{from:"uniFormItem",default:null}},props:{name:String,value:[Number,String],modelValue:[Number,String],type:{type:String,default:"text"},clearable:{type:Boolean,default:!0},autoHeight:{type:Boolean,default:!1},placeholder:{type:String,default:" "},placeholderStyle:String,focus:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},maxlength:{type:[Number,String],default:140},confirmType:{type:String,default:"done"},clearSize:{type:[Number,String],default:24},inputBorder:{type:Boolean,default:!0},prefixIcon:{type:String,default:""},suffixIcon:{type:String,default:""},trim:{type:[Boolean,String],default:!1},cursorSpacing:{type:Number,default:0},passwordIcon:{type:Boolean,default:!0},adjustPosition:{type:Boolean,default:!0},primaryColor:{type:String,default:"#2979ff"},styles:{type:Object,default:()=>({color:"#333",backgroundColor:"#fff",disableColor:"#F7F6F6",borderColor:"#e5e5e5"})},errorMessage:{type:[String,Boolean],default:""}},data:()=>({focused:!1,val:"",showMsg:"",border:!1,isFirstBorder:!1,showClearIcon:!1,showPassword:!1,focusShow:!1,localMsg:"",isEnter:!1}),computed:{isVal(){const e=this.val;return!(!e&&0!==e)},msg(){return this.localMsg||this.errorMessage},inputMaxlength(){return Number(this.maxlength)},boxStyle(){return`color:${this.inputBorder&&this.msg?"#e43d33":this.styles.color};`},inputContentClass(){return function(e){let t="";for(let a in e)e[a]&&(t+=`${a} `);return t}({"is-input-border":this.inputBorder,"is-input-error-border":this.inputBorder&&this.msg,"is-textarea":"textarea"===this.type,"is-disabled":this.disabled,"is-focused":this.focusShow})},inputContentStyle(){const e=this.focusShow?this.primaryColor:this.styles.borderColor;return Nn({"border-color":(this.inputBorder&&this.msg?"#dd524d":e)||"#e5e5e5","background-color":this.disabled?this.styles.disableColor:this.styles.backgroundColor})},inputStyle(){return Nn({"padding-right":"password"===this.type||this.clearable||this.prefixIcon?"":"10px","padding-left":this.prefixIcon?"":"10px"})}},watch:{value(e){this.val=null!==e?e:""},modelValue(e){this.val=null!==e?e:""},focus(e){this.$nextTick((()=>{this.focused=this.focus,this.focusShow=this.focus}))}},created(){this.init(),this.form&&this.formItem&&this.$watch("formItem.errMsg",(e=>{this.localMsg=e}))},mounted(){this.$nextTick((()=>{this.focused=this.focus,this.focusShow=this.focus}))},methods:{init(){this.value||0===this.value?this.val=this.value:this.modelValue||0===this.modelValue||""===this.modelValue?this.val=this.modelValue:this.val=""},onClickIcon(e){this.$emit("iconClick",e)},onEyes(){this.showPassword=!this.showPassword,this.$emit("eyes",this.showPassword)},onInput(e){let t=e.detail.value;this.trim&&("boolean"==typeof this.trim&&this.trim&&(t=this.trimStr(t)),"string"==typeof this.trim&&(t=this.trimStr(t,this.trim))),this.errMsg&&(this.errMsg=""),this.val=t,this.$emit("input",t),this.$emit("update:modelValue",t)},onFocus(){this.$nextTick((()=>{this.focused=!0})),this.$emit("focus",null)},_Focus(e){this.focusShow=!0,this.$emit("focus",e)},onBlur(){this.focused=!1,this.$emit("blur",null)},_Blur(e){if(e.detail.value,this.focusShow=!1,this.$emit("blur",e),!1===this.isEnter&&this.$emit("change",this.val),this.form&&this.formItem){const{validateTrigger:e}=this.form;"blur"===e&&this.formItem.onFieldChange()}},onConfirm(e){this.$emit("confirm",this.val),this.isEnter=!0,this.$emit("change",this.val),this.$nextTick((()=>{this.isEnter=!1}))},onClear(e){this.val="",this.$emit("input",""),this.$emit("update:modelValue",""),this.$emit("clear")},onkeyboardheightchange(e){this.$emit("keyboardheightchange",e)},trimStr:(e,t="both")=>"both"===t?e.trim():"left"===t?e.trimLeft():"right"===t?e.trimRight():"start"===t?e.trimStart():"end"===t?e.trimEnd():"all"===t?e.replace(/\s+/g,""):e}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-easyinput",{"uni-easyinput-error":l.msg}]),style:e.normalizeStyle(l.boxStyle)},[e.createElementVNode("view",{class:e.normalizeClass(["uni-easyinput__content",l.inputContentClass]),style:e.normalizeStyle(l.inputContentStyle)},[n.prefixIcon?(e.openBlock(),e.createBlock(r,{key:0,class:"content-clear-icon",type:n.prefixIcon,color:"#c0c4cc",onClick:a[0]||(a[0]=e=>l.onClickIcon("prefix")),size:"22"},null,8,["type"])):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"left",{},void 0,!0),"textarea"===n.type?(e.openBlock(),e.createElementBlock("textarea",{key:1,class:e.normalizeClass(["uni-easyinput__content-textarea",{"input-padding":n.inputBorder}]),name:n.name,value:s.val,placeholder:n.placeholder,placeholderStyle:n.placeholderStyle,disabled:n.disabled,"placeholder-class":"uni-easyinput__placeholder-class",maxlength:l.inputMaxlength,focus:s.focused,autoHeight:n.autoHeight,"cursor-spacing":n.cursorSpacing,"adjust-position":n.adjustPosition,onInput:a[1]||(a[1]=(...e)=>l.onInput&&l.onInput(...e)),onBlur:a[2]||(a[2]=(...e)=>l._Blur&&l._Blur(...e)),onFocus:a[3]||(a[3]=(...e)=>l._Focus&&l._Focus(...e)),onConfirm:a[4]||(a[4]=(...e)=>l.onConfirm&&l.onConfirm(...e)),onKeyboardheightchange:a[5]||(a[5]=(...e)=>l.onkeyboardheightchange&&l.onkeyboardheightchange(...e))},null,42,["name","value","placeholder","placeholderStyle","disabled","maxlength","focus","autoHeight","cursor-spacing","adjust-position"])):(e.openBlock(),e.createElementBlock("input",{key:2,type:"password"===n.type?"text":n.type,class:"uni-easyinput__content-input",style:e.normalizeStyle(l.inputStyle),name:n.name,value:s.val,password:!s.showPassword&&"password"===n.type,placeholder:n.placeholder,placeholderStyle:n.placeholderStyle,"placeholder-class":"uni-easyinput__placeholder-class",disabled:n.disabled,maxlength:l.inputMaxlength,focus:s.focused,confirmType:n.confirmType,"cursor-spacing":n.cursorSpacing,"adjust-position":n.adjustPosition,onFocus:a[6]||(a[6]=(...e)=>l._Focus&&l._Focus(...e)),onBlur:a[7]||(a[7]=(...e)=>l._Blur&&l._Blur(...e)),onInput:a[8]||(a[8]=(...e)=>l.onInput&&l.onInput(...e)),onConfirm:a[9]||(a[9]=(...e)=>l.onConfirm&&l.onConfirm(...e)),onKeyboardheightchange:a[10]||(a[10]=(...e)=>l.onkeyboardheightchange&&l.onkeyboardheightchange(...e))},null,44,["type","name","value","password","placeholder","placeholderStyle","disabled","maxlength","focus","confirmType","cursor-spacing","adjust-position"])),"password"===n.type&&n.passwordIcon?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[l.isVal?(e.openBlock(),e.createBlock(r,{key:0,class:e.normalizeClass(["content-clear-icon",{"is-textarea-icon":"textarea"===n.type}]),type:s.showPassword?"eye-slash-filled":"eye-filled",size:22,color:s.focusShow?n.primaryColor:"#c0c4cc",onClick:l.onEyes},null,8,["class","type","color","onClick"])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),n.suffixIcon?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[n.suffixIcon?(e.openBlock(),e.createBlock(r,{key:0,class:"content-clear-icon",type:n.suffixIcon,color:"#c0c4cc",onClick:a[11]||(a[11]=e=>l.onClickIcon("suffix")),size:"22"},null,8,["type"])):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[n.clearable&&l.isVal&&!n.disabled&&"textarea"!==n.type?(e.openBlock(),e.createBlock(r,{key:0,class:e.normalizeClass(["content-clear-icon",{"is-textarea-icon":"textarea"===n.type}]),type:"clear",size:n.clearSize,color:l.msg?"#dd524d":s.focusShow?n.primaryColor:"#c0c4cc",onClick:l.onClear},null,8,["class","size","color","onClick"])):e.createCommentVNode("",!0)],64)),e.renderSlot(t.$slots,"right",{},void 0,!0)],6)],6)}],["__scopeId","data-v-d17898f6"]]);const Cn=t({name:"uniFormsItem",options:{virtualHost:!0},provide(){return{uniFormItem:this}},inject:{form:{from:"uniForm",default:null}},props:{rules:{type:Array,default:()=>null},name:{type:[String,Array],default:""},required:{type:Boolean,default:!1},label:{type:String,default:""},labelWidth:{type:[String,Number],default:""},labelAlign:{type:String,default:""},errorMessage:{type:[String,Boolean],default:""},leftIcon:String,iconColor:{type:String,default:"#606266"}},data:()=>({errMsg:"",userRules:null,localLabelAlign:"left",localLabelWidth:"70px",localLabelPos:"left",border:!1,isFirstBorder:!1}),computed:{msg(){return this.errorMessage||this.errMsg}},watch:{"form.formRules"(e){this.init()},"form.labelWidth"(e){this.localLabelWidth=this._labelWidthUnit(e)},"form.labelPosition"(e){this.localLabelPos=this._labelPosition()},"form.labelAlign"(e){}},created(){this.init(!0),this.name&&this.form&&this.$watch((()=>this.form._getDataValue(this.name,this.form.localData)),((e,t)=>{if(!this.form._isEqual(e,t)){const t=this.itemSetValue(e);this.onFieldChange(t,!1)}}),{immediate:!1})},unmounted(){this.__isUnmounted=!0,this.unInit()},methods:{setRules(e=null){this.userRules=e,this.init(!1)},setValue(){},async onFieldChange(e,t=!0){const{formData:a,localData:n,errShowType:i,validateCheck:o,validateTrigger:s,_isRequiredField:l,_realName:r}=this.form,c=r(this.name);e||(e=this.form.formData[c]);const d=this.itemRules.rules&&this.itemRules.rules.length;if(!this.validator||!d||0===d)return;const u=l(this.itemRules.rules||[]);let h=null;return"bind"===s||t?(h=await this.validator.validateUpdate({[c]:e},a),u||void 0!==e&&""!==e||(h=null),h&&h.errorMessage?("undertext"===i&&(this.errMsg=h?h.errorMessage:""),"toast"===i&&uni.showToast({title:h.errorMessage||"校验错误",icon:"none"}),"modal"===i&&uni.showModal({title:"提示",content:h.errorMessage||"校验错误"})):this.errMsg="",o(h||null)):this.errMsg="",h||null},init(e=!1){const{validator:t,formRules:a,childrens:n,formData:i,localData:o,_realName:s,labelWidth:l,_getDataValue:r,_setDataValue:c}=this.form||{};if(this.localLabelAlign=this._justifyContent(),this.localLabelWidth=this._labelWidthUnit(l),this.localLabelPos=this._labelPosition(),this.form&&e&&n.push(this),!t||!a)return;this.form.isFirstBorder||(this.form.isFirstBorder=!0,this.isFirstBorder=!0),this.group&&(this.group.isFirstBorder||(this.group.isFirstBorder=!0,this.isFirstBorder=!0)),this.border=this.form.border;const d=s(this.name),u=this.userRules||this.rules;"object"==typeof a&&u&&(a[d]={rules:u},t.updateSchema(a));const h=a[d]||{};this.itemRules=h,this.validator=t,this.itemSetValue(r(this.name,o))},unInit(){if(this.form){const{childrens:e,formData:t,_realName:a}=this.form;e.forEach(((e,n)=>{e===this&&(this.form.childrens.splice(n,1),delete t[a(e.name)])}))}},itemSetValue(e){const t=this.form._realName(this.name),a=this.itemRules.rules||[],n=this.form._getValue(t,e,a);return this.form._setDataValue(t,this.form.formData,n),n},clearValidate(){this.errMsg=""},_isRequired(){return this.required},_justifyContent(){if(this.form){const{labelAlign:e}=this.form;let t=this.labelAlign?this.labelAlign:e;if("left"===t)return"flex-start";if("center"===t)return"center";if("right"===t)return"flex-end"}return"flex-start"},_labelWidthUnit(e){return this.num2px(this.labelWidth?this.labelWidth:e||(this.label?70:"auto"))},_labelPosition(){return this.form&&this.form.labelPosition||"left"},isTrigger:(e,t,a)=>"submit"!==e&&e?"bind":void 0===e?"bind"!==t?t?"submit":""===a?"bind":"submit":"bind":"submit",num2px:e=>"number"==typeof e?`${e}px`:e}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-forms-item",["is-direction-"+o.localLabelPos,o.border?"uni-forms-item--border":"",o.border&&o.isFirstBorder?"is-first-border":""]])},[e.renderSlot(t.$slots,"label",{},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-forms-item__label",{"no-label":!n.label&&!n.required}]),style:e.normalizeStyle({width:o.localLabelWidth,justifyContent:o.localLabelAlign})},[n.required?(e.openBlock(),e.createElementBlock("text",{key:0,class:"is-required"},"*")):e.createCommentVNode("",!0),e.createElementVNode("text",null,e.toDisplayString(n.label),1)],6)]),!0),e.createElementVNode("view",{class:"uni-forms-item__content"},[e.renderSlot(t.$slots,"default",{},void 0,!0),e.createElementVNode("view",{class:e.normalizeClass(["uni-forms-item__error",{"msg--active":s.msg}])},[e.createElementVNode("text",null,e.toDisplayString(s.msg),1)],2)])],2)}],["__scopeId","data-v-2380ed3a"]]),_n={leftWindow:{path:"windows/left-window.vue",style:{width:"350px"}},topWindow:{path:"windows/top-window.vue",style:{height:"60px"}},pages:[{path:"pages/tabBar/component/component",style:{navigationBarTitleText:"内置组件","app-plus":{bounce:"vertical",titleNView:{buttons:[{text:"",fontSrc:"/static/uni.ttf",fontSize:"22px",color:"#FFFFFF"}]}}}},{path:"pages/tabBar/API/API",style:{navigationBarTitleText:"接口","app-plus":{titleNView:{buttons:[{text:"",fontSrc:"/static/uni.ttf",fontSize:"22px",color:"#FFFFFF"}]}}}},{path:"pages/tabBar/template/template",style:{navigationBarTitleText:"模版","app-plus":{titleNView:{buttons:[{text:"",fontSrc:"/static/uni.ttf",fontSize:"22px",color:"#FFFFFF"}]}}}},{path:"pages/tabBar/extUI/extUI",style:{navigationBarTitleText:"扩展组件","app-plus":{titleNView:{buttons:[{text:"",fontSrc:"/static/uni.ttf",fontSize:"22px",color:"#FFFFFF"}]}}}},{path:"pages/component/view/view",style:{navigationBarTitleText:"view"}},{path:"pages/component/scroll-view/scroll-view",style:{navigationBarTitleText:"scroll-view"}},{path:"pages/component/swiper/swiper",style:{navigationBarTitleText:"swiper"}},{path:"pages/component/cover-view/cover-view",style:{navigationBarTitleText:"cover-view"}},{path:"pages/component/movable-view/movable-view",style:{navigationBarTitleText:"movable-view"}},{path:"pages/component/text/text",style:{navigationBarTitleText:"text"}},{path:"pages/component/rich-text/rich-text",style:{navigationBarTitleText:"rich-text"}},{path:"pages/component/progress/progress",style:{navigationBarTitleText:"progress"}},{path:"pages/component/button/button",style:{navigationBarTitleText:"button"}},{path:"pages/component/checkbox/checkbox",style:{navigationBarTitleText:"checkbox"}},{path:"pages/component/form/form",style:{navigationBarTitleText:"form"}},{path:"pages/component/input/input",style:{navigationBarTitleText:"input","app-plus":{softinputNavBar:"none"}}},{path:"pages/component/label/label",style:{navigationBarTitleText:"label"}},{path:"pages/component/picker/picker",style:{navigationBarTitleText:"picker"}},{path:"pages/component/picker-view/picker-view",style:{navigationBarTitleText:"picker-view"}},{path:"pages/component/radio/radio",style:{navigationBarTitleText:"radio"}},{path:"pages/component/slider/slider",style:{navigationBarTitleText:"slider"}},{path:"pages/component/switch/switch",style:{navigationBarTitleText:"switch"}},{path:"pages/component/textarea/textarea",style:{navigationBarTitleText:"textarea"}},{path:"pages/component/editor/editor",style:{navigationBarTitleText:"editor","app-plus":{softinputMode:"adjustResize"}}},{path:"pages/component/navigator/navigator",style:{navigationBarTitleText:"navigator"}},{path:"pages/component/navigator/navigate/navigate",style:{navigationBarTitleText:"navigatePage"}},{path:"pages/component/navigator/redirect/redirect",style:{navigationBarTitleText:"redirectPage"}},{path:"pages/component/image/image",style:{navigationBarTitleText:"image"}},{path:"pages/component/video/video",style:{navigationBarTitleText:"video"}},{path:"pages/component/map/map",style:{navigationBarTitleText:"map"}},{path:"pages/component/canvas/canvas",style:{navigationBarTitleText:"canvas"}},{path:"pages/component/web-view/web-view",style:{navigationBarTitleText:"web-view"}},{path:"pages/component/ad/ad",style:{navigationBarTitleText:"AD"}},{path:"pages/component/web-view-local/web-view-local",style:{}},{path:"pages/component/web-view-local/issue-17581",style:{navigationBarTitleText:"issue-17581"}},{path:"platforms/app-plus/speech/speech",style:{navigationBarTitleText:"语音识别"}},{path:"platforms/app-plus/orientation/orientation",style:{navigationBarTitleText:"方向传感器"}},{path:"platforms/app-plus/proximity/proximity",style:{navigationBarTitleText:"距离传感器"}},{path:"platforms/app-plus/push/push",style:{navigationBarTitleText:"推送"}},{path:"platforms/app-plus/shake/shake",style:{navigationBarTitleText:"摇一摇"}},{path:"pages/about/about",style:{navigationBarTitleText:"关于"}},{path:"platforms/app-plus/feedback/feedback",style:{navigationBarTitleText:"问题反馈"}},{path:"uni_modules/uni-upgrade-center-app/pages/upgrade-popup",style:{"app-plus":{animationDuration:200,animationType:"fade-in",background:"transparent",backgroundColorTop:"transparent",popGesture:"none",scrollIndicator:!1,titleNView:!1},disableScroll:!0}}],subPackages:[{root:"pages/API",pages:[{path:"login/login",style:{navigationBarTitleText:"授权登录"}},{path:"subnvue/subnvue",style:{navigationBarTitleText:"原生子窗体","app-plus":{subNVues:[{id:"drawer",path:"subnvue/subnvue/drawer",type:"popup",style:{width:"50%"}},{id:"popup",path:"subnvue/subnvue/popup",type:"popup",style:{margin:"auto",width:"80%",height:"600rpx"}},{id:"video_mask",path:"subnvue/subnvue/video-mask",style:{position:"absolute",bottom:"30px",left:"0",width:"230px",height:"110px",background:"transparent"}}]}}},{path:"get-user-info/get-user-info",style:{navigationBarTitleText:"获取用户信息"}},{path:"request-payment/request-payment",style:{navigationBarTitleText:"发起支付"}},{path:"share/share",style:{navigationBarTitleText:"分享"}},{path:"set-navigation-bar-title/set-navigation-bar-title",style:{navigationBarTitleText:"设置界面标题"}},{path:"show-loading/show-loading",style:{navigationBarTitleText:"加载提示框"}},{path:"navigator/navigator",style:{navigationBarTitleText:"页面跳转"}},{path:"navigator/new-page/new-vue-page-1",style:{navigationBarTitleText:"新VUE页面1"}},{path:"navigator/new-page/new-vue-page-2",style:{navigationBarTitleText:"新VUE页面2"}},{path:"pull-down-refresh/pull-down-refresh",style:{navigationBarTitleText:"下拉刷新",enablePullDownRefresh:!0}},{path:"animation/animation",style:{navigationBarTitleText:"创建动画"}},{path:"get-node-info/get-node-info",style:{navigationBarTitleText:"节点信息"}},{path:"intersection-observer/intersection-observer",style:{navigationBarTitleText:"节点布局相交状态"}},{path:"canvas/canvas",style:{navigationBarTitleText:"创建绘画"}},{path:"action-sheet/action-sheet",style:{navigationBarTitleText:"操作菜单"}},{path:"modal/modal",style:{navigationBarTitleText:"模态弹窗"}},{path:"toast/toast",style:{navigationBarTitleText:"消息提示框"}},{path:"get-network-type/get-network-type",style:{navigationBarTitleText:"获取设备网络状态"}},{path:"get-system-info/get-system-info",style:{navigationBarTitleText:"获取设备系统信息"}},{path:"add-phone-contact/add-phone-contact",style:{navigationBarTitleText:"添加手机联系人"}},{path:"on-accelerometer-change/on-accelerometer-change",style:{navigationBarTitleText:"监听加速度计数据"}},{path:"on-compass-change/on-compass-change",style:{navigationBarTitleText:"监听罗盘数据"}},{path:"make-phone-call/make-phone-call",style:{navigationBarTitleText:"打电话"}},{path:"scan-code/scan-code",style:{navigationBarTitleText:"扫码"}},{path:"clipboard/clipboard",style:{navigationBarTitleText:"剪贴板"}},{path:"request/request",style:{navigationBarTitleText:"网络请求"}},{path:"upload-file/upload-file",style:{navigationBarTitleText:"上传文件"}},{path:"download-file/download-file",style:{navigationBarTitleText:"下载文件"}},{path:"image/image",style:{navigationBarTitleText:"图片"}},{path:"voice/voice",style:{navigationBarTitleText:"录音"}},{path:"inner-audio/inner-audio",style:{navigationBarTitleText:"音频"}},{path:"background-audio/background-audio",style:{navigationBarTitleText:"背景音频"}},{path:"video/video",style:{navigationBarTitleText:"视频"}},{path:"file/file",style:{navigationBarTitleText:"文件"}},{path:"map/map",style:{navigationBarTitleText:"map"}},{path:"map-search/map-search",style:{navigationBarTitleText:"map search"}},{path:"get-location/get-location",style:{navigationBarTitleText:"获取位置"}},{path:"open-location/open-location",style:{navigationBarTitleText:"查看位置"}},{path:"choose-location/choose-location",style:{navigationBarTitleText:"使用地图选择位置"}},{path:"storage/storage",style:{navigationBarTitleText:"数据存储"}},{path:"sqlite/sqlite",style:{navigationBarTitleText:"SQLite"}},{path:"rewarded-video-ad/rewarded-video-ad",style:{navigationBarTitleText:"激励视频广告"}},{path:"full-screen-video-ad/full-screen-video-ad",style:{navigationBarTitleText:"全屏视频广告"}},{path:"brightness/brightness",style:{navigationBarTitleText:"屏幕亮度"}},{path:"save-media/save-media",style:{navigationBarTitleText:"保存媒体到本地"}},{path:"bluetooth/bluetooth",style:{navigationBarTitleText:"蓝牙"}},{path:"soter/soter",style:{navigationBarTitleText:"生物认证"}},{path:"ibeacon/ibeacon",style:{navigationBarTitleText:"iBeacon"}},{path:"vibrate/vibrate",style:{navigationBarTitleText:"震动"}},{path:"websocket-socketTask/websocket-socketTask",style:{navigationBarTitleText:"websocket-socketTask"}},{path:"websocket-global/websocket-global",style:{navigationBarTitleText:"websocket-global"}}]},{root:"pages/extUI",pages:[{path:"forms/forms",style:{navigationBarTitleText:"Form 表单"}},{path:"group/group",style:{navigationBarTitleText:"Group 分组"}},{path:"badge/badge",style:{navigationBarTitleText:"Badge 数字角标"}},{path:"breadcrumb/breadcrumb",style:{navigationBarTitleText:"Breadcrumb 面包屑"}},{path:"countdown/countdown",style:{navigationBarTitleText:"Countdown 倒计时"}},{path:"drawer/drawer",style:{navigationBarTitleText:"Drawer 抽屉"}},{path:"icons/icons",style:{navigationBarTitleText:"Icons 图标"}},{path:"load-more/load-more",style:{navigationBarTitleText:"LoadMore 加载更多"}},{path:"nav-bar/nav-bar",style:{navigationBarTitleText:"NavBar 导航栏",navigationStyle:"custom",enablePullDownRefresh:!0,"app-plus":{titleNView:!1,bounce:"none",pullToRefresh:{style:"circle",offset:"70px"}}}},{path:"number-box/number-box",style:{navigationBarTitleText:"NumberBox 数字输入框"}},{path:"popup/popup",style:{navigationBarTitleText:"Popup 弹出层","app-plus":{softinputMode:"adjustResize"}}},{path:"segmented-control/segmented-control",style:{navigationBarTitleText:"SegmentedControl 分段器"}},{path:"tag/tag",style:{navigationBarTitleText:"Tag 标签"}},{path:"list/list",style:{navigationBarTitleText:"List 列表"}},{path:"card/card",style:{navigationBarTitleText:"Card 卡片"}},{path:"collapse/collapse",style:{navigationBarTitleText:"Collapse 折叠面板"}},{path:"pagination/pagination",style:{navigationBarTitleText:"Pagination 分页器"}},{path:"swiper-dot/swiper-dot",style:{navigationBarTitleText:"SwiperDot 轮播图指示点","mp-baidu":{disableSwipeBack:!0}}},{path:"grid/grid",style:{navigationBarTitleText:"Grid 宫格"}},{path:"rate/rate",style:{navigationBarTitleText:"Rate 评分"}},{path:"steps/steps",style:{navigationBarTitleText:"Steps 步骤条"}},{path:"notice-bar/notice-bar",style:{navigationBarTitleText:"NoticeBar 通告栏"}},{path:"swipe-action/swipe-action",style:{navigationBarTitleText:"SwipeAction 滑动操作","app-plus":{bounce:"none"}}},{path:"search-bar/search-bar",style:{navigationBarTitleText:"SearchBar 搜索栏"}},{path:"calendar/calendar",style:{navigationBarTitleText:"Calendar 日历"}},{path:"indexed-list/indexed-list",style:{navigationBarTitleText:"IndexedList 索引列表","mp-weixin":{disableScroll:!0},"app-plus":{bounce:"none"},"mp-alipay":{allowsBounceVertical:"NO"},"mp-baidu":{disableScroll:!0}}},{path:"fab/fab",style:{navigationBarTitleText:"Fab 悬浮按钮"}},{path:"fav/fav",style:{navigationBarTitleText:"Fav 收藏按钮"}},{path:"goods-nav/goods-nav",style:{navigationBarTitleText:"GoodsNav 商品导航"}},{path:"section/section",style:{navigationBarTitleText:"Section 标题栏"}},{path:"transition/transition",style:{navigationBarTitleText:"Transition 过渡动画"}},{path:"title/title",style:{navigationBarTitleText:"Title 章节标题"}},{path:"tooltip/tooltip",style:{navigationBarTitleText:"Tooltip 文字提示"}},{path:"link/link",style:{navigationBarTitleText:"Link 链接"}},{path:"combox/combox",style:{navigationBarTitleText:"Combox 组合框"}},{path:"list/chat",style:{}},{path:"table/table",style:{navigationBarTitleText:"",enablePullDownRefresh:!1}},{path:"dateformat/dateformat",style:{navigationBarTitleText:"Dateformat 日期格式化",enablePullDownRefresh:!1}},{path:"data-checkbox/data-checkbox",style:{navigationBarTitleText:"DataCheckbox 单选复选框",enablePullDownRefresh:!1}},{path:"easyinput/easyinput",style:{navigationBarTitleText:"Easyinput 增强输入框",enablePullDownRefresh:!1}},{path:"data-picker/data-picker",style:{navigationBarTitleText:"DataPicker 级联选择",enablePullDownRefresh:!1}},{path:"data-select/data-select",style:{navigationBarTitleText:"DataSelect 下拉框",enablePullDownRefresh:!1}},{path:"datetime-picker/datetime-picker",style:{navigationBarTitleText:"DatetimePicker 日期时间",enablePullDownRefresh:!1}},{path:"row/row",style:{navigationBarTitleText:"Layout 布局",enablePullDownRefresh:!1}},{path:"file-picker/file-picker",style:{navigationBarTitleText:"FilePicker 文件选择上传",enablePullDownRefresh:!1}},{path:"space/space",style:{navigationBarTitleText:"间距",enablePullDownRefresh:!1}},{path:"font/font",style:{navigationBarTitleText:"字体",enablePullDownRefresh:!1}},{path:"color/color",style:{navigationBarTitleText:"颜色",enablePullDownRefresh:!1}},{path:"radius/radius",style:{navigationBarTitleText:"圆角",enablePullDownRefresh:!1}},{path:"button/button",style:{navigationBarTitleText:"",enablePullDownRefresh:!1}}]},{root:"pages/template",pages:[{path:"nav-default/nav-default",style:{navigationBarTitleText:"默认导航栏"}},{path:"component-communication/component-communication",style:{navigationBarTitleText:"组件通讯"}},{path:"nav-transparent/nav-transparent",style:{navigationBarTitleText:"透明渐变导航栏",transparentTitle:"auto"}},{path:"nav-button/nav-button",style:{navigationBarTitleText:"导航栏带自定义按钮","app-plus":{titleNView:{buttons:[{type:"share"},{type:"favorite"}]}}}},{path:"nav-image/nav-image",style:{navigationBarBackgroundColor:"#FFFFFF",navigationBarTextStyle:"black",titleImage:"https://web-assets.dcloud.net.cn/unidoc/zh/logo1@2x.png"}},{path:"nav-city-dropdown/nav-city-dropdown",style:{navigationBarTitleText:"导航栏带城市选择","app-plus":{titleNView:{buttons:[{text:"北京市",fontSize:"14",select:!0,width:"auto"}]}}}},{path:"nav-dot/nav-dot",style:{navigationBarTitleText:"导航栏带红点和角标","app-plus":{titleNView:{buttons:[{text:"消息",fontSize:"14",redDot:!0},{text:"关注",fontSize:"14",badgeText:"12"}]}}}},{path:"nav-search-input/nav-search-input",style:{navigationBarTitleText:"导航栏带搜索框","app-plus":{titleNView:{type:"transparent",titleColor:"#fff",backgroundColor:"#007AFF",buttons:[{fontSrc:"/static/uni.ttf",text:"",width:"40px",fontSize:"28px",color:"#fff",background:"rgba(0,0,0,0)"}],searchInput:{backgroundColor:"#fff",borderRadius:"6px",placeholder:"请输入地址 如：大钟寺",disabled:!0}}}}},{path:"nav-search-input/detail/detail",style:{navigationBarTitleText:"搜索","app-plus":{titleNView:{titleColor:"#fff",backgroundColor:"#007AFF",buttons:[{fontSrc:"/static/uni.ttf",text:"",width:"auto",fontSize:"28px",color:"#fff"}],searchInput:{backgroundColor:"#fff",borderRadius:"6px",placeholder:"请输入地址 如：大钟寺",autoFocus:!0}}}}},{path:"list2detail-list/list2detail-list",style:{navigationBarTitleText:"列表到详情示例",enablePullDownRefresh:!0}},{path:"list2detail-detail/list2detail-detail",style:{navigationBarTitleText:"详情","app-plus":{titleNView:{type:"transparent",buttons:[{type:"share"}]}},h5:{titleNView:{type:"transparent",buttons:[]}}}},{path:"tabbar/tabbar",style:{navigationBarTitleText:"可拖动顶部选项卡"}},{path:"tabbar/detail/detail",style:{navigationBarTitleText:"详情页面"}},{path:"swiper-vertical/swiper-vertical",style:{navigationBarTitleText:"上下滑动切换视频","app-plus":{titleNView:!1}}},{path:"swiper-list/swiper-list",style:{navigationBarTitleText:"swiper-list"}},{path:"swiper-list-nvue/swiper-list-nvue",style:{navigationBarTitleText:"swiper-list"}},{path:"scheme/scheme",style:{navigationBarTitleText:"打开外部应用"}},{path:"renderjs/renderjs",style:{navigationBarTitleText:"renderjs"}},{path:"global/global",style:{navigationBarTitleText:"GlobalData和vuex"}},{path:"pinia/pinia",style:{navigationBarTitleText:"pinia"}},{path:"vuex-nvue/vuex-nvue",style:{navigationBarTitleText:"vuex-nvue"}},{path:"vuex-vue/vuex-vue",style:{navigationBarTitleText:"vuex-vue"}},{path:"crypto-api/crypto-api",style:{navigationBarTitleText:"crypto"}}]}],globalStyle:{pageOrientation:"portrait",navigationBarTitleText:"Hello uniapp",navigationBarTextStyle:"white",navigationBarBackgroundColor:"#007AFF",backgroundColor:"#F8F8F8",backgroundColorTop:"#F4F5F6",backgroundColorBottom:"#F4F5F6","mp-360":{navigationStyle:"custom"},h5:{maxWidth:1190,navigationBarTextStyle:"black",navigationBarBackgroundColor:"#F1F1F1"}},tabBar:{color:"#7A7E83",selectedColor:"#007AFF",borderStyle:"black",backgroundColor:"#F8F8F8",list:[{pagePath:"pages/tabBar/component/component",iconPath:"static/component.png",selectedIconPath:"static/componentHL.png",text:"内置组件"},{pagePath:"pages/tabBar/API/API",iconPath:"static/api.png",selectedIconPath:"static/apiHL.png",text:"接口"},{pagePath:"pages/tabBar/extUI/extUI",iconPath:"static/extui.png",selectedIconPath:"static/extuiHL.png",text:"扩展组件"},{pagePath:"pages/tabBar/template/template",iconPath:"static/template.png",selectedIconPath:"static/templateHL.png",text:"模板"}]}};function Sn(e,t,a){return e(a={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&a.path)}},a.exports),a.exports}var Tn=Sn((function(e,t){var a;e.exports=(a=a||function(e,t){var a=Object.create||function(){function e(){}return function(t){var a;return e.prototype=t,a=new e,e.prototype=null,a}}(),n={},i=n.lib={},o=i.Base={extend:function(e){var t=a(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},s=i.WordArray=o.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||r).stringify(this)},concat:function(e){var t=this.words,a=e.words,n=this.sigBytes,i=e.sigBytes;if(this.clamp(),n%4)for(var o=0;o<i;o++){var s=a[o>>>2]>>>24-o%4*8&255;t[n+o>>>2]|=s<<24-(n+o)%4*8}else for(o=0;o<i;o+=4)t[n+o>>>2]=a[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,a=this.sigBytes;t[a>>>2]&=4294967295<<32-a%4*8,t.length=e.ceil(a/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var a,n=[],i=function(t){var a=987654321,n=4294967295;return function(){var i=((a=36969*(65535&a)+(a>>16)&n)<<16)+(t=18e3*(65535&t)+(t>>16)&n)&n;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o<t;o+=4){var l=i(4294967296*(a||e.random()));a=987654071*l(),n.push(4294967296*l()|0)}return new s.init(n,t)}}),l=n.enc={},r=l.Hex={stringify:function(e){for(var t=e.words,a=e.sigBytes,n=[],i=0;i<a;i++){var o=t[i>>>2]>>>24-i%4*8&255;n.push((o>>>4).toString(16)),n.push((15&o).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,a=[],n=0;n<t;n+=2)a[n>>>3]|=parseInt(e.substr(n,2),16)<<24-n%8*4;return new s.init(a,t/2)}},c=l.Latin1={stringify:function(e){for(var t=e.words,a=e.sigBytes,n=[],i=0;i<a;i++){var o=t[i>>>2]>>>24-i%4*8&255;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var t=e.length,a=[],n=0;n<t;n++)a[n>>>2]|=(255&e.charCodeAt(n))<<24-n%4*8;return new s.init(a,t)}},d=l.Utf8={stringify:function(e){try{return decodeURIComponent(escape(c.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return c.parse(unescape(encodeURIComponent(e)))}},u=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new s.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=d.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var a=this._data,n=a.words,i=a.sigBytes,o=this.blockSize,l=i/(4*o),r=(l=t?e.ceil(l):e.max((0|l)-this._minBufferSize,0))*o,c=e.min(4*r,i);if(r){for(var d=0;d<r;d+=o)this._doProcessBlock(n,d);var u=n.splice(0,r);a.sigBytes-=c}return new s.init(u,c)},clone:function(){var e=o.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});i.Hasher=u.extend({cfg:o.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){u.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,a){return new e.init(a).finalize(t)}},_createHmacHelper:function(e){return function(t,a){return new h.HMAC.init(e,a).finalize(t)}}});var h=n.algo={};return n}(Math),a)})),Bn=Tn,Dn=(Sn((function(e,t){var a;e.exports=(a=Bn,function(e){var t=a,n=t.lib,i=n.WordArray,o=n.Hasher,s=t.algo,l=[];!function(){for(var t=0;t<64;t++)l[t]=4294967296*e.abs(e.sin(t+1))|0}();var r=s.MD5=o.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var a=0;a<16;a++){var n=t+a,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,s=e[t+0],r=e[t+1],p=e[t+2],m=e[t+3],g=e[t+4],f=e[t+5],y=e[t+6],v=e[t+7],w=e[t+8],b=e[t+9],k=e[t+10],x=e[t+11],V=e[t+12],N=e[t+13],E=e[t+14],C=e[t+15],_=o[0],S=o[1],T=o[2],B=o[3];_=c(_,S,T,B,s,7,l[0]),B=c(B,_,S,T,r,12,l[1]),T=c(T,B,_,S,p,17,l[2]),S=c(S,T,B,_,m,22,l[3]),_=c(_,S,T,B,g,7,l[4]),B=c(B,_,S,T,f,12,l[5]),T=c(T,B,_,S,y,17,l[6]),S=c(S,T,B,_,v,22,l[7]),_=c(_,S,T,B,w,7,l[8]),B=c(B,_,S,T,b,12,l[9]),T=c(T,B,_,S,k,17,l[10]),S=c(S,T,B,_,x,22,l[11]),_=c(_,S,T,B,V,7,l[12]),B=c(B,_,S,T,N,12,l[13]),T=c(T,B,_,S,E,17,l[14]),_=d(_,S=c(S,T,B,_,C,22,l[15]),T,B,r,5,l[16]),B=d(B,_,S,T,y,9,l[17]),T=d(T,B,_,S,x,14,l[18]),S=d(S,T,B,_,s,20,l[19]),_=d(_,S,T,B,f,5,l[20]),B=d(B,_,S,T,k,9,l[21]),T=d(T,B,_,S,C,14,l[22]),S=d(S,T,B,_,g,20,l[23]),_=d(_,S,T,B,b,5,l[24]),B=d(B,_,S,T,E,9,l[25]),T=d(T,B,_,S,m,14,l[26]),S=d(S,T,B,_,w,20,l[27]),_=d(_,S,T,B,N,5,l[28]),B=d(B,_,S,T,p,9,l[29]),T=d(T,B,_,S,v,14,l[30]),_=u(_,S=d(S,T,B,_,V,20,l[31]),T,B,f,4,l[32]),B=u(B,_,S,T,w,11,l[33]),T=u(T,B,_,S,x,16,l[34]),S=u(S,T,B,_,E,23,l[35]),_=u(_,S,T,B,r,4,l[36]),B=u(B,_,S,T,g,11,l[37]),T=u(T,B,_,S,v,16,l[38]),S=u(S,T,B,_,k,23,l[39]),_=u(_,S,T,B,N,4,l[40]),B=u(B,_,S,T,s,11,l[41]),T=u(T,B,_,S,m,16,l[42]),S=u(S,T,B,_,y,23,l[43]),_=u(_,S,T,B,b,4,l[44]),B=u(B,_,S,T,V,11,l[45]),T=u(T,B,_,S,C,16,l[46]),_=h(_,S=u(S,T,B,_,p,23,l[47]),T,B,s,6,l[48]),B=h(B,_,S,T,v,10,l[49]),T=h(T,B,_,S,E,15,l[50]),S=h(S,T,B,_,f,21,l[51]),_=h(_,S,T,B,V,6,l[52]),B=h(B,_,S,T,m,10,l[53]),T=h(T,B,_,S,k,15,l[54]),S=h(S,T,B,_,r,21,l[55]),_=h(_,S,T,B,w,6,l[56]),B=h(B,_,S,T,C,10,l[57]),T=h(T,B,_,S,y,15,l[58]),S=h(S,T,B,_,N,21,l[59]),_=h(_,S,T,B,g,6,l[60]),B=h(B,_,S,T,x,10,l[61]),T=h(T,B,_,S,p,15,l[62]),S=h(S,T,B,_,b,21,l[63]),o[0]=o[0]+_|0,o[1]=o[1]+S|0,o[2]=o[2]+T|0,o[3]=o[3]+B|0},_doFinalize:function(){var t=this._data,a=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;a[i>>>5]|=128<<24-i%32;var o=e.floor(n/4294967296),s=n;a[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),a[14+(i+64>>>9<<4)]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),t.sigBytes=4*(a.length+1),this._process();for(var l=this._hash,r=l.words,c=0;c<4;c++){var d=r[c];r[c]=16711935&(d<<8|d>>>24)|4278255360&(d<<24|d>>>8)}return l},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function c(e,t,a,n,i,o,s){var l=e+(t&a|~t&n)+i+s;return(l<<o|l>>>32-o)+t}function d(e,t,a,n,i,o,s){var l=e+(t&n|a&~n)+i+s;return(l<<o|l>>>32-o)+t}function u(e,t,a,n,i,o,s){var l=e+(t^a^n)+i+s;return(l<<o|l>>>32-o)+t}function h(e,t,a,n,i,o,s){var l=e+(a^(t|~n))+i+s;return(l<<o|l>>>32-o)+t}t.MD5=o._createHelper(r),t.HmacMD5=o._createHmacHelper(r)}(Math),a.MD5)})),Sn((function(e,t){var a,n,i;e.exports=(n=(a=Bn).lib.Base,i=a.enc.Utf8,void(a.algo.HMAC=n.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=i.parse(t));var a=e.blockSize,n=4*a;t.sigBytes>n&&(t=e.finalize(t)),t.clamp();for(var o=this._oKey=t.clone(),s=this._iKey=t.clone(),l=o.words,r=s.words,c=0;c<a;c++)l[c]^=1549556828,r[c]^=909522486;o.sigBytes=s.sigBytes=n,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,a=t.finalize(e);return t.reset(),t.finalize(this._oKey.clone().concat(a))}})))})),Sn((function(e,t){e.exports=Bn.HmacMD5}))),In=Sn((function(e,t){e.exports=Bn.enc.Utf8})),Pn=Sn((function(e,t){var a,n,i;e.exports=(i=(n=a=Bn).lib.WordArray,n.enc.Base64={stringify:function(e){var t=e.words,a=e.sigBytes,n=this._map;e.clamp();for(var i=[],o=0;o<a;o+=3)for(var s=(t[o>>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,l=0;l<4&&o+.75*l<a;l++)i.push(n.charAt(s>>>6*(3-l)&63));var r=n.charAt(64);if(r)for(;i.length%4;)i.push(r);return i.join("")},parse:function(e){var t=e.length,a=this._map,n=this._reverseMap;if(!n){n=this._reverseMap=[];for(var o=0;o<a.length;o++)n[a.charCodeAt(o)]=o}var s=a.charAt(64);if(s){var l=e.indexOf(s);-1!==l&&(t=l)}return function(e,t,a){for(var n=[],o=0,s=0;s<t;s++)if(s%4){var l=a[e.charCodeAt(s-1)]<<s%4*2,r=a[e.charCodeAt(s)]>>>6-s%4*2;n[o>>>2]|=(l|r)<<24-o%4*8,o++}return i.create(n,o)}(e,t,n)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},a.enc.Base64)}));const An="uni_id_token",Fn="uni_id_token_expired",Ln="FUNCTION",Mn="OBJECT",Rn="CLIENT_DB",On="pending",$n="rejected";function zn(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function Un(e){return"object"===zn(e)}function jn(e){return"function"==typeof e}function qn(e){return function(){try{return e.apply(e,arguments)}catch(t){console.error(t)}}}const Hn="REJECTED",Wn="NOT_PENDING";class Jn{constructor({createPromise:e,retryRule:t=Hn}={}){this.createPromise=e,this.status=null,this.promise=null,this.retryRule=t}get needRetry(){if(!this.status)return!0;switch(this.retryRule){case Hn:return this.status===$n;case Wn:return this.status!==On}}exec(){return this.needRetry?(this.status=On,this.promise=this.createPromise().then((e=>(this.status="fulfilled",Promise.resolve(e))),(e=>(this.status=$n,Promise.reject(e)))),this.promise):this.promise}}function Gn(e){return e&&"string"==typeof e?JSON.parse(e):e}const Kn=Gn([]);Gn("");const Qn=Gn("[]")||[];let Yn="";try{Yn="__UNI__3BC70CE"}catch($i){}let Xn,Zn={};function ei(e,t={}){var a,n;return a=Zn,n=e,Object.prototype.hasOwnProperty.call(a,n)||(Zn[e]=t),Zn[e]}Zn=uni._globalUniCloudObj?uni._globalUniCloudObj:uni._globalUniCloudObj={};const ti=["invoke","success","fail","complete"],ai=ei("_globalUniCloudInterceptor");function ni(e,t){ai[e]||(ai[e]={}),Un(t)&&Object.keys(t).forEach((a=>{ti.indexOf(a)>-1&&function(e,t,a){let n=ai[e][t];n||(n=ai[e][t]=[]),-1===n.indexOf(a)&&jn(a)&&n.push(a)}(e,a,t[a])}))}function ii(e,t){ai[e]||(ai[e]={}),Un(t)?Object.keys(t).forEach((a=>{ti.indexOf(a)>-1&&function(e,t,a){const n=ai[e][t];if(!n)return;const i=n.indexOf(a);i>-1&&n.splice(i,1)}(e,a,t[a])})):delete ai[e]}function oi(e,t){return e&&0!==e.length?e.reduce(((e,a)=>e.then((()=>a(t)))),Promise.resolve()):Promise.resolve()}function si(e,t){return ai[e]&&ai[e][t]||[]}function li(e){ni("callObject",e)}const ri=ei("_globalUniCloudListener"),ci="response",di="needLogin",ui="refreshToken",hi="clientdb",pi="cloudfunction",mi="cloudobject";function gi(e){return ri[e]||(ri[e]=[]),ri[e]}function fi(e,t){const a=gi(e);a.includes(t)||a.push(t)}function yi(e,t){const a=gi(e),n=a.indexOf(t);-1!==n&&a.splice(n,1)}function vi(e,t){const a=gi(e);for(let n=0;n<a.length;n++)(0,a[n])(t)}let wi,bi=!1;function ki(){return wi||(wi=new Promise((e=>{bi&&e(),function t(){if("function"==typeof getCurrentPages){const t=getCurrentPages();t&&t[0]&&(bi=!0,e())}bi||setTimeout((()=>{t()}),30)}()})),wi)}function xi(e){const t={};for(const a in e){const n=e[a];jn(n)&&(t[a]=qn(n))}return t}class Vi extends Error{constructor(e){const t=e.message||e.errMsg||"unknown system error";super(t),this.errMsg=t,this.code=this.errCode=e.code||e.errCode||"SYSTEM_ERROR",this.errSubject=this.subject=e.subject||e.errSubject,this.cause=e.cause,this.requestId=e.requestId}toJson(e=0){if(!(e>=10))return e++,{errCode:this.errCode,errMsg:this.errMsg,errSubject:this.errSubject,cause:this.cause&&this.cause.toJson?this.cause.toJson(e):this.cause}}}var Ni={request:e=>uni.request(e),uploadFile:e=>uni.uploadFile(e),setStorageSync:(e,t)=>uni.setStorageSync(e,t),getStorageSync:e=>uni.getStorageSync(e),removeStorageSync:e=>uni.removeStorageSync(e),clearStorageSync:()=>uni.clearStorageSync(),connectSocket:e=>uni.connectSocket(e)};function Ei(e){return e&&Ei(e.__v_raw)||e}function Ci(){return{token:Ni.getStorageSync(An)||Ni.getStorageSync("uniIdToken"),tokenExpired:Ni.getStorageSync(Fn)}}function _i({token:e,tokenExpired:t}={}){e&&Ni.setStorageSync(An,e),t&&Ni.setStorageSync(Fn,t)}let Si,Ti;function Bi(){return Si||(Si=uni.getSystemInfoSync()),Si}function Di(){let e,t;try{if(uni.getLaunchOptionsSync){if(uni.getLaunchOptionsSync.toString().indexOf("not yet implemented")>-1)return;const{scene:a,channel:n}=uni.getLaunchOptionsSync();e=n,t=a}}catch(a){}return{channel:e,scene:t}}let Ii={};function Pi(){const e=uni.getLocale&&uni.getLocale()||"en";if(Ti)return{...Ii,...Ti,locale:e,LOCALE:e};const t=Bi(),{deviceId:a,osName:n,uniPlatform:i,appId:o}=t,s=["appId","appLanguage","appName","appVersion","appVersionCode","appWgtVersion","browserName","browserVersion","deviceBrand","deviceId","deviceModel","deviceType","osName","osVersion","romName","romVersion","ua","hostName","hostVersion","uniPlatform","uniRuntimeVersion","uniRuntimeVersionCode","uniCompilerVersion","uniCompilerVersionCode"];for(const l in t)Object.hasOwnProperty.call(t,l)&&-1===s.indexOf(l)&&delete t[l];return Ti={PLATFORM:i,OS:n,APPID:o,DEVICEID:a,...Di(),...t},{...Ii,...Ti,locale:e,LOCALE:e}}var Ai=function(e,t){let a="";return Object.keys(e).sort().forEach((function(t){e[t]&&(a=a+"&"+t+"="+e[t])})),a=a.slice(1),Dn(a,t).toString()},Fi=function(e,t){return new Promise(((a,n)=>{t(Object.assign(e,{complete(e){e||(e={});const t=e.data&&e.data.header&&e.data.header["x-serverless-request-id"]||e.header&&e.header["request-id"];if(!e.statusCode||e.statusCode>=400){const a=e.data&&e.data.error&&e.data.error.code||"SYS_ERR",i=e.data&&e.data.error&&e.data.error.message||e.errMsg||"request:fail";return n(new Vi({code:a,message:i,requestId:t}))}const i=e.data;if(i.error)return n(new Vi({code:i.error.code,message:i.error.message,requestId:t}));i.result=i.data,i.requestId=t,delete i.data,a(i)}}))}))},Li=function(e){return Pn.stringify(In.parse(e))},Mi={init(e){const t=new class{constructor(e){["spaceId","clientSecret"].forEach((t=>{if(!Object.prototype.hasOwnProperty.call(e,t))throw new Error(`${t} required`)})),this.config=Object.assign({},{endpoint:0===e.spaceId.indexOf("mp-")?"https://api.next.bspapp.com":"https://api.bspapp.com"},e),this.config.provider="aliyun",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.config.accessTokenKey="access_token_"+this.config.spaceId,this.adapter=Ni,this._getAccessTokenPromiseHub=new Jn({createPromise:()=>this.requestAuth(this.setupRequest({method:"serverless.auth.user.anonymousAuthorize",params:"{}"},"auth")).then((e=>{if(!e.result||!e.result.accessToken)throw new Vi({code:"AUTH_FAILED",message:"获取accessToken失败"});this.setAccessToken(e.result.accessToken)})),retryRule:Wn})}get hasAccessToken(){return!!this.accessToken}setAccessToken(e){this.accessToken=e}requestWrapped(e){return Fi(e,this.adapter.request)}requestAuth(e){return this.requestWrapped(e)}request(e,t){return Promise.resolve().then((()=>this.hasAccessToken?t?this.requestWrapped(e):this.requestWrapped(e).catch((t=>new Promise(((e,a)=>{!t||"GATEWAY_INVALID_TOKEN"!==t.code&&"InvalidParameter.InvalidToken"!==t.code?a(t):e()})).then((()=>this.getAccessToken())).then((()=>{const t=this.rebuildRequest(e);return this.request(t,!0)})))):this.getAccessToken().then((()=>{const t=this.rebuildRequest(e);return this.request(t,!0)}))))}rebuildRequest(e){const t=Object.assign({},e);return t.data.token=this.accessToken,t.header["x-basement-token"]=this.accessToken,t.header["x-serverless-sign"]=Ai(t.data,this.config.clientSecret),t}setupRequest(e,t){const a=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),n={"Content-Type":"application/json"};return"auth"!==t&&(a.token=this.accessToken,n["x-basement-token"]=this.accessToken),n["x-serverless-sign"]=Ai(a,this.config.clientSecret),{url:this.config.requestUrl,method:"POST",data:a,dataType:"json",header:n}}getAccessToken(){return this._getAccessTokenPromiseHub.exec()}async authorize(){await this.getAccessToken()}callFunction(e){const t={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:e.name,functionArgs:e.data||{}})};return this.request({...this.setupRequest(t),timeout:e.timeout})}getOSSUploadOptionsFromPath(e){const t={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}uploadFileToOSS({url:e,formData:t,name:a,filePath:n,fileType:i,onUploadProgress:o}){return new Promise(((s,l)=>{const r=this.adapter.uploadFile({url:e,formData:t,name:a,filePath:n,fileType:i,header:{"X-OSS-server-side-encrpytion":"AES256"},success(e){e&&e.statusCode<400?s(e):l(new Vi({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(e){l(new Vi({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof o&&r&&"function"==typeof r.onProgressUpdate&&r.onProgressUpdate((e=>{o({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}reportOSSUpload(e){const t={method:"serverless.file.resource.report",params:JSON.stringify(e)};return this.request(this.setupRequest(t))}async uploadFile({filePath:e,cloudPath:t,fileType:a="image",cloudPathAsRealPath:n=!1,onUploadProgress:i,config:o}){if("string"!==zn(t))throw new Vi({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});if(!(t=t.trim()))throw new Vi({code:"INVALID_PARAM",message:"cloudPath不可为空"});if(/:\/\//.test(t))throw new Vi({code:"INVALID_PARAM",message:"cloudPath不合法"});const s=o&&o.envType||this.config.envType;if(n&&("/"!==t[0]&&(t="/"+t),t.indexOf("\\")>-1))throw new Vi({code:"INVALID_PARAM",message:"使用cloudPath作为路径时，cloudPath不可包含“\\”"});const l=(await this.getOSSUploadOptionsFromPath({env:s,filename:n?t.split("/").pop():t,fileId:n?t:void 0})).result,r="https://"+l.cdnDomain+"/"+l.ossPath,{securityToken:c,accessKeyId:d,signature:u,host:h,ossPath:p,id:m,policy:g,ossCallbackUrl:f}=l,y={"Cache-Control":"max-age=2592000","Content-Disposition":"attachment",OSSAccessKeyId:d,Signature:u,host:h,id:m,key:p,policy:g,success_action_status:200};if(c&&(y["x-oss-security-token"]=c),f){const e=JSON.stringify({callbackUrl:f,callbackBody:JSON.stringify({fileId:m,spaceId:this.config.spaceId}),callbackBodyType:"application/json"});y.callback=Li(e)}const v={url:"https://"+l.host,formData:y,fileName:"file",name:"file",filePath:e,fileType:a};if(await this.uploadFileToOSS(Object.assign({},v,{onUploadProgress:i})),f)return{success:!0,filePath:e,fileID:r};if((await this.reportOSSUpload({id:m})).success)return{success:!0,filePath:e,fileID:r};throw new Vi({code:"UPLOAD_FAILED",message:"文件上传失败"})}getTempFileURL({fileList:e}={}){return new Promise(((t,a)=>{Array.isArray(e)&&0!==e.length||a(new Vi({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"})),this.getFileInfo({fileList:e}).then((a=>{t({fileList:e.map(((e,t)=>{const n=a.fileList[t];return{fileID:e,tempFileURL:n&&n.url||e}}))})}))}))}async getFileInfo({fileList:e}={}){if(!Array.isArray(e)||0===e.length)throw new Vi({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});const t={method:"serverless.file.resource.info",params:JSON.stringify({id:e.map((e=>e.split("?")[0])).join(",")})};return{fileList:(await this.request(this.setupRequest(t))).result}}}(e),a={signInAnonymously:function(){return t.authorize()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return a},t.customAuth=t.auth,t}};const Ri="undefined"!=typeof location&&"http:"===location.protocol?"http:":"https:";var Oi,$i;($i=Oi||(Oi={})).local="local",$i.none="none",$i.session="session";var zi=function(){},Ui=Sn((function(e,t){var a;e.exports=(a=Bn,function(e){var t=a,n=t.lib,i=n.WordArray,o=n.Hasher,s=t.algo,l=[],r=[];!function(){function t(t){for(var a=e.sqrt(t),n=2;n<=a;n++)if(!(t%n))return!1;return!0}function a(e){return 4294967296*(e-(0|e))|0}for(var n=2,i=0;i<64;)t(n)&&(i<8&&(l[i]=a(e.pow(n,.5))),r[i]=a(e.pow(n,1/3)),i++),n++}();var c=[],d=s.SHA256=o.extend({_doReset:function(){this._hash=new i.init(l.slice(0))},_doProcessBlock:function(e,t){for(var a=this._hash.words,n=a[0],i=a[1],o=a[2],s=a[3],l=a[4],d=a[5],u=a[6],h=a[7],p=0;p<64;p++){if(p<16)c[p]=0|e[t+p];else{var m=c[p-15],g=(m<<25|m>>>7)^(m<<14|m>>>18)^m>>>3,f=c[p-2],y=(f<<15|f>>>17)^(f<<13|f>>>19)^f>>>10;c[p]=g+c[p-7]+y+c[p-16]}var v=n&i^n&o^i&o,w=(n<<30|n>>>2)^(n<<19|n>>>13)^(n<<10|n>>>22),b=h+((l<<26|l>>>6)^(l<<21|l>>>11)^(l<<7|l>>>25))+(l&d^~l&u)+r[p]+c[p];h=u,u=d,d=l,l=s+b|0,s=o,o=i,i=n,n=b+(w+v)|0}a[0]=a[0]+n|0,a[1]=a[1]+i|0,a[2]=a[2]+o|0,a[3]=a[3]+s|0,a[4]=a[4]+l|0,a[5]=a[5]+d|0,a[6]=a[6]+u|0,a[7]=a[7]+h|0},_doFinalize:function(){var t=this._data,a=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;return a[i>>>5]|=128<<24-i%32,a[14+(i+64>>>9<<4)]=e.floor(n/4294967296),a[15+(i+64>>>9<<4)]=n,t.sigBytes=4*a.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(d),t.HmacSHA256=o._createHmacHelper(d)}(Math),a.SHA256)})),ji=Ui,qi=Sn((function(e,t){e.exports=Bn.HmacSHA256}));const Hi=()=>{let e;if(!Promise){e=()=>{},e.promise={};const t=()=>{throw new Vi({message:'Your Node runtime does support ES6 Promises. Set "global.Promise" to your preferred implementation of promises.'})};return Object.defineProperty(e.promise,"then",{get:t}),Object.defineProperty(e.promise,"catch",{get:t}),e}const t=new Promise(((t,a)=>{e=(e,n)=>e?a(e):t(n)}));return e.promise=t,e};function Wi(e){return void 0===e}function Ji(e){return"[object Null]"===Object.prototype.toString.call(e)}function Gi(e=""){return e.replace(/([\s\S]+)\s+(请前往云开发AI小助手查看问题：.*)/,"$1")}function Ki(e=32){let t="";for(let a=0;a<e;a++)t+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.floor(62*Math.random()));return t}var Qi;!function(e){e.WEB="web",e.WX_MP="wx_mp"}(Qi||(Qi={}));const Yi={adapter:null,runtime:void 0},Xi=["anonymousUuidKey"];class Zi extends zi{constructor(){super(),Yi.adapter.root.tcbObject||(Yi.adapter.root.tcbObject={})}setItem(e,t){Yi.adapter.root.tcbObject[e]=t}getItem(e){return Yi.adapter.root.tcbObject[e]}removeItem(e){delete Yi.adapter.root.tcbObject[e]}clear(){delete Yi.adapter.root.tcbObject}}function eo(e,t){switch(e){case"local":return t.localStorage||new Zi;case"none":return new Zi;default:return t.sessionStorage||new Zi}}class to{constructor(e){if(!this._storage){this._persistence=Yi.adapter.primaryStorage||e.persistence,this._storage=eo(this._persistence,Yi.adapter);const t=`access_token_${e.env}`,a=`access_token_expire_${e.env}`,n=`refresh_token_${e.env}`,i=`anonymous_uuid_${e.env}`,o=`login_type_${e.env}`,s="device_id",l=`token_type_${e.env}`,r=`user_info_${e.env}`;this.keys={accessTokenKey:t,accessTokenExpireKey:a,refreshTokenKey:n,anonymousUuidKey:i,loginTypeKey:o,userInfoKey:r,deviceIdKey:s,tokenTypeKey:l}}}updatePersistence(e){if(e===this._persistence)return;const t="local"===this._persistence;this._persistence=e;const a=eo(e,Yi.adapter);for(const n in this.keys){const e=this.keys[n];if(t&&Xi.includes(n))continue;const i=this._storage.getItem(e);Wi(i)||Ji(i)||(a.setItem(e,i),this._storage.removeItem(e))}this._storage=a}setStore(e,t,a){if(!this._storage)return;const n={version:a||"localCachev1",content:t},i=JSON.stringify(n);try{this._storage.setItem(e,i)}catch(o){throw o}}getStore(e,t){try{if(!this._storage)return}catch(n){return""}t=t||"localCachev1";const a=this._storage.getItem(e);return a&&a.indexOf(t)>=0?JSON.parse(a).content:""}removeStore(e){this._storage.removeItem(e)}}const ao={},no={};function io(e){return ao[e]}class oo{constructor(e,t){this.data=t||null,this.name=e}}class so extends oo{constructor(e,t){super("error",{error:e,data:t}),this.error=e}}const lo=new class{constructor(){this._listeners={}}on(e,t){return a=e,n=t,(i=this._listeners)[a]=i[a]||[],i[a].push(n),this;var a,n,i}off(e,t){return function(e,t,a){if(a&&a[e]){const n=a[e].indexOf(t);-1!==n&&a[e].splice(n,1)}}(e,t,this._listeners),this}fire(e,t){if(e instanceof so)return console.error(e.error),this;const a="string"==typeof e?new oo(e,t||{}):e,n=a.name;if(this._listens(n)){a.target=this;const e=this._listeners[n]?[...this._listeners[n]]:[];for(const t of e)t.call(this,a)}return this}_listens(e){return this._listeners[e]&&this._listeners[e].length>0}};function ro(e,t){lo.on(e,t)}function co(e,t={}){lo.fire(e,t)}function uo(e,t){lo.off(e,t)}const ho="loginStateChanged",po="loginStateExpire",mo="loginTypeChanged",go="anonymousConverted",fo="refreshAccessToken";var yo;!function(e){e.ANONYMOUS="ANONYMOUS",e.WECHAT="WECHAT",e.WECHAT_PUBLIC="WECHAT-PUBLIC",e.WECHAT_OPEN="WECHAT-OPEN",e.CUSTOM="CUSTOM",e.EMAIL="EMAIL",e.USERNAME="USERNAME",e.NULL="NULL"}(yo||(yo={}));class vo{constructor(){this._fnPromiseMap=new Map}async run(e,t){let a=this._fnPromiseMap.get(e);return a||(a=new Promise((async(a,n)=>{try{await this._runIdlePromise();const n=t();a(await n)}catch(i){n(i)}finally{this._fnPromiseMap.delete(e)}})),this._fnPromiseMap.set(e,a)),a}_runIdlePromise(){return Promise.resolve()}}class wo{constructor(e){this._singlePromise=new vo,this._cache=io(e.env),this._baseURL=`https://${e.env}.ap-shanghai.tcb-api.tencentcloudapi.com`,this._reqClass=new Yi.adapter.reqClass({timeout:e.timeout,timeoutMsg:`请求在${e.timeout/1e3}s内未完成，已中断`,restrictedMethods:["post"]})}_getDeviceId(){if(this._deviceID)return this._deviceID;const{deviceIdKey:e}=this._cache.keys;let t=this._cache.getStore(e);return"string"==typeof t&&t.length>=16&&t.length<=48||(t=Ki(),this._cache.setStore(e,t)),this._deviceID=t,t}async _request(e,t,a={}){const n={"x-request-id":Ki(),"x-device-id":this._getDeviceId()};if(a.withAccessToken){const{tokenTypeKey:e}=this._cache.keys,t=await this.getAccessToken(),a=this._cache.getStore(e);n.authorization=`${a} ${t}`}return this._reqClass["get"===a.method?"get":"post"]({url:`${this._baseURL}${e}`,data:t,headers:n})}async _fetchAccessToken(){const{loginTypeKey:e,accessTokenKey:t,accessTokenExpireKey:a,tokenTypeKey:n}=this._cache.keys,i=this._cache.getStore(e);if(i&&i!==yo.ANONYMOUS)throw new Vi({code:"INVALID_OPERATION",message:"非匿名登录不支持刷新 access token"});const o=await this._singlePromise.run("fetchAccessToken",(async()=>(await this._request("/auth/v1/signin/anonymously",{},{method:"post"})).data)),{access_token:s,expires_in:l,token_type:r}=o;return this._cache.setStore(n,r),this._cache.setStore(t,s),this._cache.setStore(a,Date.now()+1e3*l),s}isAccessTokenExpired(e,t){let a=!0;return e&&t&&(a=t<Date.now()),a}async getAccessToken(){const{accessTokenKey:e,accessTokenExpireKey:t}=this._cache.keys,a=this._cache.getStore(e),n=this._cache.getStore(t);return this.isAccessTokenExpired(a,n)?this._fetchAccessToken():a}async refreshAccessToken(){const{accessTokenKey:e,accessTokenExpireKey:t,loginTypeKey:a}=this._cache.keys;return this._cache.removeStore(e),this._cache.removeStore(t),this._cache.setStore(a,yo.ANONYMOUS),this.getAccessToken()}async getUserInfo(){return this._singlePromise.run("getUserInfo",(async()=>(await this._request("/auth/v1/user/me",{},{withAccessToken:!0,method:"get"})).data))}}const bo=["auth.getJwt","auth.logout","auth.signInWithTicket","auth.signInAnonymously","auth.signIn","auth.fetchAccessTokenWithRefreshToken","auth.signUpWithEmailAndPassword","auth.activateEndUserMail","auth.sendPasswordResetEmail","auth.resetPasswordWithToken","auth.isUsernameRegistered"],ko={"X-SDK-Version":"1.3.5"};function xo(e,t,a){const n=e[t];e[t]=function(t){const i={},o={};a.forEach((a=>{const{data:n,headers:s}=a.call(e,t);Object.assign(i,n),Object.assign(o,s)}));const s=t.data;return s&&(()=>{var e;if(e=s,"[object FormData]"!==Object.prototype.toString.call(e))t.data={...s,...i};else for(const t in i)s.append(t,i[t])})(),t.headers={...t.headers||{},...o},n.call(e,t)}}function Vo(){const e=Math.random().toString(16).slice(2);return{data:{seqId:e},headers:{...ko,"x-seqid":e}}}class No{constructor(e={}){var t;this.config=e,this._reqClass=new Yi.adapter.reqClass({timeout:this.config.timeout,timeoutMsg:`请求在${this.config.timeout/1e3}s内未完成，已中断`,restrictedMethods:["post"]}),this._cache=io(this.config.env),this._localCache=(t=this.config.env,no[t]),this.oauth=new wo(this.config),xo(this._reqClass,"post",[Vo]),xo(this._reqClass,"upload",[Vo]),xo(this._reqClass,"download",[Vo])}async post(e){return await this._reqClass.post(e)}async upload(e){return await this._reqClass.upload(e)}async download(e){return await this._reqClass.download(e)}async refreshAccessToken(){let e,t;this._refreshAccessTokenPromise||(this._refreshAccessTokenPromise=this._refreshAccessToken());try{e=await this._refreshAccessTokenPromise}catch(a){t=a}if(this._refreshAccessTokenPromise=null,this._shouldRefreshAccessTokenHook=null,t)throw t;return e}async _refreshAccessToken(){const{accessTokenKey:e,accessTokenExpireKey:t,refreshTokenKey:a,loginTypeKey:n,anonymousUuidKey:i}=this._cache.keys;this._cache.removeStore(e),this._cache.removeStore(t);let o=this._cache.getStore(a);if(!o)throw new Vi({message:"未登录CloudBase"});const s={refresh_token:o},l=await this.request("auth.fetchAccessTokenWithRefreshToken",s);if(l.data.code){const{code:e}=l.data;if("SIGN_PARAM_INVALID"===e||"REFRESH_TOKEN_EXPIRED"===e||"INVALID_REFRESH_TOKEN"===e){if(this._cache.getStore(n)===yo.ANONYMOUS&&"INVALID_REFRESH_TOKEN"===e){const e=this._cache.getStore(i),t=this._cache.getStore(a),n=await this.send("auth.signInAnonymously",{anonymous_uuid:e,refresh_token:t});return this.setRefreshToken(n.refresh_token),this._refreshAccessToken()}co(po),this._cache.removeStore(a)}throw new Vi({code:l.data.code,message:`刷新access token失败：${l.data.code}`})}if(l.data.access_token)return co(fo),this._cache.setStore(e,l.data.access_token),this._cache.setStore(t,l.data.access_token_expire+Date.now()),{accessToken:l.data.access_token,accessTokenExpire:l.data.access_token_expire};l.data.refresh_token&&(this._cache.removeStore(a),this._cache.setStore(a,l.data.refresh_token),this._refreshAccessToken())}async getAccessToken(){const{accessTokenKey:e,accessTokenExpireKey:t,refreshTokenKey:a}=this._cache.keys;if(!this._cache.getStore(a))throw new Vi({message:"refresh token不存在，登录状态异常"});let n=this._cache.getStore(e),i=this._cache.getStore(t),o=!0;return this._shouldRefreshAccessTokenHook&&!(await this._shouldRefreshAccessTokenHook(n,i))&&(o=!1),(!n||!i||i<Date.now())&&o?this.refreshAccessToken():{accessToken:n,accessTokenExpire:i}}async request(e,t,a){const n=`x-tcb-trace_${this.config.env}`;let i="application/x-www-form-urlencoded";const o={action:e,env:this.config.env,dataVersion:"2019-08-16",...t};let s;if(-1===bo.indexOf(e)&&(this._cache.keys,o.access_token=await this.oauth.getAccessToken()),"storage.uploadFile"===e){s=new FormData;for(let e in s)s.hasOwnProperty(e)&&void 0!==s[e]&&s.append(e,o[e]);i="multipart/form-data"}else{i="application/json",s={};for(let e in o)void 0!==o[e]&&(s[e]=o[e])}let l={headers:{"content-type":i}};a&&a.timeout&&(l.timeout=a.timeout),a&&a.onUploadProgress&&(l.onUploadProgress=a.onUploadProgress);const r=this._localCache.getStore(n);r&&(l.headers["X-TCB-Trace"]=r);const{parse:c,inQuery:d,search:u}=t;let h={env:this.config.env};c&&(h.parse=!0),d&&(h={...d,...h});let p=function(e,t,a={}){const n=/\?/.test(t);let i="";for(let o in a)""===i?!n&&(t+="?"):i+="&",i+=`${o}=${encodeURIComponent(a[o])}`;return/^http(s)?\:\/\//.test(t+=i)?t:`${e}${t}`}(Ri,"//tcb-api.tencentcloudapi.com/web",h);u&&(p+=u);const m=await this.post({url:p,data:s,...l}),g=m.header&&m.header["x-tcb-trace"];if(g&&this._localCache.setStore(n,g),200!==Number(m.status)&&200!==Number(m.statusCode)||!m.data)throw new Vi({code:"NETWORK_ERROR",message:"network request error"});return m}async send(e,t={},a={}){const n=await this.request(e,t,{...a,onUploadProgress:t.onUploadProgress});if(("ACCESS_TOKEN_DISABLED"===n.data.code||"ACCESS_TOKEN_EXPIRED"===n.data.code)&&-1===bo.indexOf(e)){await this.oauth.refreshAccessToken();const n=await this.request(e,t,{...a,onUploadProgress:t.onUploadProgress});if(n.data.code)throw new Vi({code:n.data.code,message:Gi(n.data.message)});return n.data}if(n.data.code)throw new Vi({code:n.data.code,message:Gi(n.data.message)});return n.data}setRefreshToken(e){const{accessTokenKey:t,accessTokenExpireKey:a,refreshTokenKey:n}=this._cache.keys;this._cache.removeStore(t),this._cache.removeStore(a),this._cache.setStore(n,e)}}const Eo={};function Co(e){return Eo[e]}class _o{constructor(e){this.config=e,this._cache=io(e.env),this._request=Co(e.env)}setRefreshToken(e){const{accessTokenKey:t,accessTokenExpireKey:a,refreshTokenKey:n}=this._cache.keys;this._cache.removeStore(t),this._cache.removeStore(a),this._cache.setStore(n,e)}setAccessToken(e,t){const{accessTokenKey:a,accessTokenExpireKey:n}=this._cache.keys;this._cache.setStore(a,e),this._cache.setStore(n,t)}async refreshUserInfo(){const{data:e}=await this._request.send("auth.getUserInfo",{});return this.setLocalUserInfo(e),e}setLocalUserInfo(e){const{userInfoKey:t}=this._cache.keys;this._cache.setStore(t,e)}}class So{constructor(e){if(!e)throw new Vi({code:"PARAM_ERROR",message:"envId is not defined"});this._envId=e,this._cache=io(this._envId),this._request=Co(this._envId),this.setUserInfo()}linkWithTicket(e){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"ticket must be string"});return this._request.send("auth.linkWithTicket",{ticket:e})}linkWithRedirect(e){e.signInWithRedirect()}updatePassword(e,t){return this._request.send("auth.updatePassword",{oldPassword:t,newPassword:e})}updateEmail(e){return this._request.send("auth.updateEmail",{newEmail:e})}updateUsername(e){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"username must be a string"});return this._request.send("auth.updateUsername",{username:e})}async getLinkedUidList(){const{data:e}=await this._request.send("auth.getLinkedUidList",{});let t=!1;const{users:a}=e;return a.forEach((e=>{e.wxOpenId&&e.wxPublicId&&(t=!0)})),{users:a,hasPrimaryUid:t}}setPrimaryUid(e){return this._request.send("auth.setPrimaryUid",{uid:e})}unlink(e){return this._request.send("auth.unlink",{platform:e})}async update(e){const{nickName:t,gender:a,avatarUrl:n,province:i,country:o,city:s}=e,{data:l}=await this._request.send("auth.updateUserInfo",{nickName:t,gender:a,avatarUrl:n,province:i,country:o,city:s});this.setLocalUserInfo(l)}async refresh(){const e=await this._request.oauth.getUserInfo();return this.setLocalUserInfo(e),e}setUserInfo(){const{userInfoKey:e}=this._cache.keys,t=this._cache.getStore(e);["uid","loginType","openid","wxOpenId","wxPublicId","unionId","qqMiniOpenId","email","hasPassword","customUserId","nickName","gender","avatarUrl"].forEach((e=>{this[e]=t[e]})),this.location={country:t.country,province:t.province,city:t.city}}setLocalUserInfo(e){const{userInfoKey:t}=this._cache.keys;this._cache.setStore(t,e),this.setUserInfo()}}class To{constructor(e){if(!e)throw new Vi({code:"PARAM_ERROR",message:"envId is not defined"});this._cache=io(e);const{refreshTokenKey:t,accessTokenKey:a,accessTokenExpireKey:n}=this._cache.keys,i=this._cache.getStore(t),o=this._cache.getStore(a),s=this._cache.getStore(n);this.credential={refreshToken:i,accessToken:o,accessTokenExpire:s},this.user=new So(e)}get isAnonymousAuth(){return this.loginType===yo.ANONYMOUS}get isCustomAuth(){return this.loginType===yo.CUSTOM}get isWeixinAuth(){return this.loginType===yo.WECHAT||this.loginType===yo.WECHAT_OPEN||this.loginType===yo.WECHAT_PUBLIC}get loginType(){return this._cache.getStore(this._cache.keys.loginTypeKey)}}class Bo extends _o{async signIn(){this._cache.updatePersistence("local"),await this._request.oauth.getAccessToken(),co(ho),co(mo,{env:this.config.env,loginType:yo.ANONYMOUS,persistence:"local"});const e=new To(this.config.env);return await e.user.refresh(),e}async linkAndRetrieveDataWithTicket(e){const{anonymousUuidKey:t,refreshTokenKey:a}=this._cache.keys,n=this._cache.getStore(t),i=this._cache.getStore(a),o=await this._request.send("auth.linkAndRetrieveDataWithTicket",{anonymous_uuid:n,refresh_token:i,ticket:e});if(o.refresh_token)return this._clearAnonymousUUID(),this.setRefreshToken(o.refresh_token),await this._request.refreshAccessToken(),co(go,{env:this.config.env}),co(mo,{loginType:yo.CUSTOM,persistence:"local"}),{credential:{refreshToken:o.refresh_token}};throw new Vi({message:"匿名转化失败"})}_setAnonymousUUID(e){const{anonymousUuidKey:t,loginTypeKey:a}=this._cache.keys;this._cache.removeStore(t),this._cache.setStore(t,e),this._cache.setStore(a,yo.ANONYMOUS)}_clearAnonymousUUID(){this._cache.removeStore(this._cache.keys.anonymousUuidKey)}}class Do extends _o{async signIn(e){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"ticket must be a string"});const{refreshTokenKey:t}=this._cache.keys,a=await this._request.send("auth.signInWithTicket",{ticket:e,refresh_token:this._cache.getStore(t)||""});if(a.refresh_token)return this.setRefreshToken(a.refresh_token),await this._request.refreshAccessToken(),co(ho),co(mo,{env:this.config.env,loginType:yo.CUSTOM,persistence:this.config.persistence}),await this.refreshUserInfo(),new To(this.config.env);throw new Vi({message:"自定义登录失败"})}}class Io extends _o{async signIn(e,t){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"email must be a string"});const{refreshTokenKey:a}=this._cache.keys,n=await this._request.send("auth.signIn",{loginType:"EMAIL",email:e,password:t,refresh_token:this._cache.getStore(a)||""}),{refresh_token:i,access_token:o,access_token_expire:s}=n;if(i)return this.setRefreshToken(i),o&&s?this.setAccessToken(o,s):await this._request.refreshAccessToken(),await this.refreshUserInfo(),co(ho),co(mo,{env:this.config.env,loginType:yo.EMAIL,persistence:this.config.persistence}),new To(this.config.env);throw n.code?new Vi({code:n.code,message:`邮箱登录失败: ${n.message}`}):new Vi({message:"邮箱登录失败"})}async activate(e){return this._request.send("auth.activateEndUserMail",{token:e})}async resetPasswordWithToken(e,t){return this._request.send("auth.resetPasswordWithToken",{token:e,newPassword:t})}}class Po extends _o{async signIn(e,t){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"username must be a string"});"string"!=typeof t&&(t="",console.warn("password is empty"));const{refreshTokenKey:a}=this._cache.keys,n=await this._request.send("auth.signIn",{loginType:yo.USERNAME,username:e,password:t,refresh_token:this._cache.getStore(a)||""}),{refresh_token:i,access_token_expire:o,access_token:s}=n;if(i)return this.setRefreshToken(i),s&&o?this.setAccessToken(s,o):await this._request.refreshAccessToken(),await this.refreshUserInfo(),co(ho),co(mo,{env:this.config.env,loginType:yo.USERNAME,persistence:this.config.persistence}),new To(this.config.env);throw n.code?new Vi({code:n.code,message:`用户名密码登录失败: ${n.message}`}):new Vi({message:"用户名密码登录失败"})}}class Ao{constructor(e){this.config=e,this._cache=io(e.env),this._request=Co(e.env),this._onAnonymousConverted=this._onAnonymousConverted.bind(this),this._onLoginTypeChanged=this._onLoginTypeChanged.bind(this),ro(mo,this._onLoginTypeChanged)}get currentUser(){const e=this.hasLoginState();return e&&e.user||null}get loginType(){return this._cache.getStore(this._cache.keys.loginTypeKey)}anonymousAuthProvider(){return new Bo(this.config)}customAuthProvider(){return new Do(this.config)}emailAuthProvider(){return new Io(this.config)}usernameAuthProvider(){return new Po(this.config)}async signInAnonymously(){return new Bo(this.config).signIn()}async signInWithEmailAndPassword(e,t){return new Io(this.config).signIn(e,t)}signInWithUsernameAndPassword(e,t){return new Po(this.config).signIn(e,t)}async linkAndRetrieveDataWithTicket(e){return this._anonymousAuthProvider||(this._anonymousAuthProvider=new Bo(this.config)),ro(go,this._onAnonymousConverted),await this._anonymousAuthProvider.linkAndRetrieveDataWithTicket(e)}async signOut(){if(this.loginType===yo.ANONYMOUS)throw new Vi({message:"匿名用户不支持登出操作"});const{refreshTokenKey:e,accessTokenKey:t,accessTokenExpireKey:a}=this._cache.keys,n=this._cache.getStore(e);if(!n)return;const i=await this._request.send("auth.logout",{refresh_token:n});return this._cache.removeStore(e),this._cache.removeStore(t),this._cache.removeStore(a),co(ho),co(mo,{env:this.config.env,loginType:yo.NULL,persistence:this.config.persistence}),i}async signUpWithEmailAndPassword(e,t){return this._request.send("auth.signUpWithEmailAndPassword",{email:e,password:t})}async sendPasswordResetEmail(e){return this._request.send("auth.sendPasswordResetEmail",{email:e})}onLoginStateChanged(e){ro(ho,(()=>{const t=this.hasLoginState();e.call(this,t)}));const t=this.hasLoginState();e.call(this,t)}onLoginStateExpired(e){ro(po,e.bind(this))}onAccessTokenRefreshed(e){ro(fo,e.bind(this))}onAnonymousConverted(e){ro(go,e.bind(this))}onLoginTypeChanged(e){ro(mo,(()=>{const t=this.hasLoginState();e.call(this,t)}))}async getAccessToken(){return{accessToken:(await this._request.getAccessToken()).accessToken,env:this.config.env}}hasLoginState(){const{accessTokenKey:e,accessTokenExpireKey:t}=this._cache.keys,a=this._cache.getStore(e),n=this._cache.getStore(t);return this._request.oauth.isAccessTokenExpired(a,n)?null:new To(this.config.env)}async isUsernameRegistered(e){if("string"!=typeof e)throw new Vi({code:"PARAM_ERROR",message:"username must be a string"});const{data:t}=await this._request.send("auth.isUsernameRegistered",{username:e});return t&&t.isRegistered}getLoginState(){return Promise.resolve(this.hasLoginState())}async signInWithTicket(e){return new Do(this.config).signIn(e)}shouldRefreshAccessToken(e){this._request._shouldRefreshAccessTokenHook=e.bind(this)}getUserInfo(){return this._request.send("auth.getUserInfo",{}).then((e=>e.code?e:{...e.data,requestId:e.seqId}))}getAuthHeader(){const{refreshTokenKey:e,accessTokenKey:t}=this._cache.keys,a=this._cache.getStore(e);return{"x-cloudbase-credentials":this._cache.getStore(t)+"/@@/"+a}}_onAnonymousConverted(e){const{env:t}=e.data;t===this.config.env&&this._cache.updatePersistence(this.config.persistence)}_onLoginTypeChanged(e){const{loginType:t,persistence:a,env:n}=e.data;n===this.config.env&&(this._cache.updatePersistence(a),this._cache.setStore(this._cache.keys.loginTypeKey,t))}}const Fo=function(e,t){t=t||Hi();const a=Co(this.config.env),{cloudPath:n,filePath:i,onUploadProgress:o,fileType:s="image"}=e;return a.send("storage.getUploadMetadata",{path:n}).then((e=>{const{data:{url:l,authorization:r,token:c,fileId:d,cosFileId:u},requestId:h}=e,p={key:n,signature:r,"x-cos-meta-fileid":u,success_action_status:"201","x-cos-security-token":c};a.upload({url:l,data:p,file:i,name:n,fileType:s,onUploadProgress:o}).then((e=>{201===e.statusCode?t(null,{fileID:d,requestId:h}):t(new Vi({code:"STORAGE_REQUEST_FAIL",message:`STORAGE_REQUEST_FAIL: ${e.data}`}))})).catch((e=>{t(e)}))})).catch((e=>{t(e)})),t.promise},Lo=function(e,t){t=t||Hi();const a=Co(this.config.env),{cloudPath:n}=e;return a.send("storage.getUploadMetadata",{path:n}).then((e=>{t(null,e)})).catch((e=>{t(e)})),t.promise},Mo=function({fileList:e},t){if(t=t||Hi(),!e||!Array.isArray(e))return{code:"INVALID_PARAM",message:"fileList必须是非空的数组"};for(let n of e)if(!n||"string"!=typeof n)return{code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"};const a={fileid_list:e};return Co(this.config.env).send("storage.batchDeleteFile",a).then((e=>{e.code?t(null,e):t(null,{fileList:e.data.delete_list,requestId:e.requestId})})).catch((e=>{t(e)})),t.promise},Ro=function({fileList:e},t){t=t||Hi(),e&&Array.isArray(e)||t(null,{code:"INVALID_PARAM",message:"fileList必须是非空的数组"});let a=[];for(let i of e)"object"==typeof i?(i.hasOwnProperty("fileID")&&i.hasOwnProperty("maxAge")||t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是包含fileID和maxAge的对象"}),a.push({fileid:i.fileID,max_age:i.maxAge})):"string"==typeof i?a.push({fileid:i}):t(null,{code:"INVALID_PARAM",message:"fileList的元素必须是字符串"});const n={file_list:a};return Co(this.config.env).send("storage.batchGetDownloadUrl",n).then((e=>{e.code?t(null,e):t(null,{fileList:e.data.download_list,requestId:e.requestId})})).catch((e=>{t(e)})),t.promise},Oo=async function({fileID:e},t){const a=(await Ro.call(this,{fileList:[{fileID:e,maxAge:600}]})).fileList[0];if("SUCCESS"!==a.code)return t?t(a):new Promise((e=>{e(a)}));const n=Co(this.config.env);let i=a.download_url;if(i=encodeURI(i),!t)return n.download({url:i});t(await n.download({url:i}))},$o=function({name:e,data:t,query:a,parse:n,search:i,timeout:o},s){const l=s||Hi();let r;try{r=t?JSON.stringify(t):""}catch(d){return Promise.reject(d)}if(!e)return Promise.reject(new Vi({code:"PARAM_ERROR",message:"函数名不能为空"}));const c={inQuery:a,parse:n,search:i,function_name:e,request_data:r};return Co(this.config.env).send("functions.invokeFunction",c,{timeout:o}).then((e=>{if(e.code)l(null,e);else{let a=e.data.response_data;if(n)l(null,{result:a,requestId:e.requestId});else try{a=JSON.parse(e.data.response_data),l(null,{result:a,requestId:e.requestId})}catch(t){l(new Vi({message:"response data must be json"}))}}return l.promise})).catch((e=>{l(e)})),l.promise},zo={timeout:15e3,persistence:"session"},Uo=6e5,jo={};class qo{constructor(e){this.config=e||this.config,this.authObj=void 0}init(e){switch(Yi.adapter||(this.requestClient=new Yi.adapter.reqClass({timeout:e.timeout||5e3,timeoutMsg:`请求在${(e.timeout||5e3)/1e3}s内未完成，已中断`})),this.config={...zo,...e},!0){case this.config.timeout>Uo:console.warn("timeout大于可配置上限[10分钟]，已重置为上限数值"),this.config.timeout=Uo;break;case this.config.timeout<100:console.warn("timeout小于可配置下限[100ms]，已重置为下限数值"),this.config.timeout=100}return new qo(this.config)}auth({persistence:e}={}){if(this.authObj)return this.authObj;const t=e||Yi.adapter.primaryStorage||zo.persistence;var a;return t!==this.config.persistence&&(this.config.persistence=t),function(e){const{env:t}=e;ao[t]=new to(e),no[t]=new to({...e,persistence:"local"})}(this.config),a=this.config,Eo[a.env]=new No(a),this.authObj=new Ao(this.config),this.authObj}on(e,t){return ro.apply(this,[e,t])}off(e,t){return uo.apply(this,[e,t])}callFunction(e,t){return $o.apply(this,[e,t])}deleteFile(e,t){return Mo.apply(this,[e,t])}getTempFileURL(e,t){return Ro.apply(this,[e,t])}downloadFile(e,t){return Oo.apply(this,[e,t])}uploadFile(e,t){return Fo.apply(this,[e,t])}getUploadMetadata(e,t){return Lo.apply(this,[e,t])}registerExtension(e){jo[e.name]=e}async invokeExtension(e,t){const a=jo[e];if(!a)throw new Vi({message:`扩展${e} 必须先注册`});return await a.invoke(t,this)}useAdapters(e){const{adapter:t,runtime:a}=function(e){const t=(a=e,"[object Array]"===Object.prototype.toString.call(a)?e:[e]);var a;for(const n of t){const{isMatch:e,genAdapter:t,runtime:a}=n;if(e())return{adapter:t(),runtime:a}}}(e)||{};t&&(Yi.adapter=t),a&&(Yi.runtime=a)}}var Ho=new qo;function Wo(e,t,a){void 0===a&&(a={});var n=/\?/.test(t),i="";for(var o in a)""===i?!n&&(t+="?"):i+="&",i+=o+"="+encodeURIComponent(a[o]);return/^http(s)?:\/\//.test(t+=i)?t:""+e+t}class Jo{get(e){const{url:t,data:a,headers:n,timeout:i}=e;return new Promise(((e,o)=>{Ni.request({url:Wo("https:",t),data:a,method:"GET",header:n,timeout:i,success(t){e(t)},fail(e){o(e)}})}))}post(e){const{url:t,data:a,headers:n,timeout:i}=e;return new Promise(((e,o)=>{Ni.request({url:Wo("https:",t),data:a,method:"POST",header:n,timeout:i,success(t){e(t)},fail(e){o(e)}})}))}upload(e){return new Promise(((t,a)=>{const{url:n,file:i,data:o,headers:s,fileType:l}=e,r=Ni.uploadFile({url:Wo("https:",n),name:"file",formData:Object.assign({},o),filePath:i,fileType:l,header:s,success(e){const a={statusCode:e.statusCode,data:e.data||{}};200===e.statusCode&&o.success_action_status&&(a.statusCode=parseInt(o.success_action_status,10)),t(a)},fail(e){a(new Error(e.errMsg||"uploadFile:fail"))}});"function"==typeof e.onUploadProgress&&r&&"function"==typeof r.onProgressUpdate&&r.onProgressUpdate((t=>{e.onUploadProgress({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))}}const Go={setItem(e,t){Ni.setStorageSync(e,t)},getItem:e=>Ni.getStorageSync(e),removeItem(e){Ni.removeStorageSync(e)},clear(){Ni.clearStorageSync()}};var Ko={genAdapter:function(){return{root:{},reqClass:Jo,localStorage:Go,primaryStorage:"local"}},isMatch:function(){return!0},runtime:"uni_app"};Ho.useAdapters(Ko);const Qo=Ho,Yo=Qo.init;Qo.init=function(e){e.env=e.spaceId;const t=Yo.call(this,e);t.config.provider="tencent",t.config.spaceId=e.spaceId;const a=t.auth;return t.auth=function(e){const t=a.call(this,e);return["linkAndRetrieveDataWithTicket","signInAnonymously","signOut","getAccessToken","getLoginState","signInWithTicket","getUserInfo"].forEach((e=>{var a;t[e]=(a=t[e],function(e){e=e||{};const{success:t,fail:n,complete:i}=xi(e);if(!(t||n||i))return a.call(this,e);a.call(this,e).then((e=>{t&&t(e),i&&i(e)}),(e=>{n&&n(e),i&&i(e)}))}).bind(t)})),t},t.customAuth=t.auth,t};var Xo=Qo;async function Zo(e,t){const a=`http://${e}:${t}/system/ping`;try{const e=await(n={url:a,timeout:500},new Promise(((e,t)=>{Ni.request({...n,success(t){e(t)},fail(e){t(e)}})})));return!(!e.data||0!==e.data.code)}catch(i){return!1}var n}const es={"serverless.file.resource.generateProximalSign":"storage/generate-proximal-sign","serverless.file.resource.report":"storage/report","serverless.file.resource.delete":"storage/delete","serverless.file.resource.getTempFileURL":"storage/get-temp-file-url"};var ts={init(e){const t=new class{constructor(e){if(["spaceId","clientSecret"].forEach((t=>{if(!Object.prototype.hasOwnProperty.call(e,t))throw new Error(`${t} required`)})),!e.endpoint)throw new Error("集群空间未配置ApiEndpoint，配置后需要重新关联服务空间后生效");this.config=Object.assign({},e),this.config.provider="dcloud",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.adapter=Ni}async request(e,t=!0){return e=this.setupRequest(e),Promise.resolve().then((()=>Fi(e,this.adapter.request)))}requestLocal(e){return new Promise(((t,a)=>{this.adapter.request(Object.assign(e,{complete(e){if(e||(e={}),!e.statusCode||e.statusCode>=400){const t=e.data&&e.data.code||"SYS_ERR",n=e.data&&e.data.message||"request:fail";return a(new Vi({code:t,message:n}))}t({success:!0,result:e.data})}}))}))}setupRequest(e){const t=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now()}),a={"Content-Type":"application/json"};a["x-serverless-sign"]=Ai(t,this.config.clientSecret);const n=Pi();a["x-client-info"]=encodeURIComponent(JSON.stringify(n));const{token:i}=Ci();return a["x-client-token"]=i,{url:this.config.requestUrl,method:"POST",data:t,dataType:"json",header:JSON.parse(JSON.stringify(a))}}async setupLocalRequest(e){const t=Pi(),{token:a}=Ci(),n=Object.assign({},e,{spaceId:this.config.spaceId,timestamp:Date.now(),clientInfo:t,token:a}),{address:i,servePort:o}=this.__dev__&&this.__dev__.debugInfo||{},{address:s}=await async function(e,t){let a;for(let n=0;n<e.length;n++){const i=e[n];if(await Zo(i,t)){a=i;break}}return{address:a,port:t}}(i,o);return{url:`http://${s}:${o}/${es[e.method]}`,method:"POST",data:n,dataType:"json",header:JSON.parse(JSON.stringify({"Content-Type":"application/json"}))}}callFunction(e){const t={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:e.name,functionArgs:e.data||{}})};return this.request(t,!1)}getUploadFileOptions(e){const t={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(e)};return this.request(t)}reportUploadFile(e){const t={method:"serverless.file.resource.report",params:JSON.stringify(e)};return this.request(t)}uploadFile({filePath:e,cloudPath:t,fileType:a="image",onUploadProgress:n}){if(!t)throw new Vi({code:"CLOUDPATH_REQUIRED",message:"cloudPath不可为空"});let i;return this.getUploadFileOptions({cloudPath:t}).then((t=>{const{url:o,formData:s,name:l}=t.result;return i=t.result.fileUrl,new Promise(((t,i)=>{const r=this.adapter.uploadFile({url:o,formData:s,name:l,filePath:e,fileType:a,success(e){e&&e.statusCode<400?t(e):i(new Vi({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(e){i(new Vi({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof n&&r&&"function"==typeof r.onProgressUpdate&&r.onProgressUpdate((e=>{n({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))})).then((()=>this.reportUploadFile({cloudPath:t}))).then((t=>new Promise(((a,n)=>{t.success?a({success:!0,filePath:e,fileID:i}):n(new Vi({code:"UPLOAD_FAILED",message:"文件上传失败"}))}))))}deleteFile({fileList:e}){const t={method:"serverless.file.resource.delete",params:JSON.stringify({fileList:e})};return this.request(t).then((e=>{if(e.success)return e.result;throw new Vi({code:"DELETE_FILE_FAILED",message:"删除文件失败"})}))}getTempFileURL({fileList:e,maxAge:t}={}){if(!Array.isArray(e)||0===e.length)throw new Vi({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});const a={method:"serverless.file.resource.getTempFileURL",params:JSON.stringify({fileList:e,maxAge:t})};return this.request(a).then((e=>{if(e.success)return{fileList:e.result.fileList.map((e=>({fileID:e.fileID,tempFileURL:e.tempFileURL})))};throw new Vi({code:"GET_TEMP_FILE_URL_FAILED",message:"获取临时文件链接失败"})}))}}(e),a={signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!1)}};return t.auth=function(){return a},t.customAuth=t.auth,t}},as=Sn((function(e,t){e.exports=Bn.enc.Hex}));function ns(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function is(e="",t={}){const{data:a,functionName:n,method:i,headers:o,signHeaderKeys:s=[],config:l}=t,r=String(Date.now()),c=ns(),d=Object.assign({},o,{"x-from-app-id":l.spaceAppId,"x-from-env-id":l.spaceId,"x-to-env-id":l.spaceId,"x-from-instance-id":r,"x-from-function-name":n,"x-client-timestamp":r,"x-alipay-source":"client","x-request-id":c,"x-alipay-callid":c,"x-trace-id":c}),u=["x-from-app-id","x-from-env-id","x-to-env-id","x-from-instance-id","x-from-function-name","x-client-timestamp"].concat(s),[h="",p=""]=e.split("?")||[],m=function(e){const t="HMAC-SHA256",a=e.signedHeaders.join(";"),n=e.signedHeaders.map((t=>`${t.toLowerCase()}:${e.headers[t]}\n`)).join(""),i=ji(e.body).toString(as),o=`${e.method.toUpperCase()}\n${e.path}\n${e.query}\n${n}\n${a}\n${i}\n`,s=ji(o).toString(as),l=`${t}\n${e.timestamp}\n${s}\n`,r=qi(l,e.secretKey).toString(as);return`${t} Credential=${e.secretId}, SignedHeaders=${a}, Signature=${r}`}({path:h,query:p,method:i,headers:d,timestamp:r,body:JSON.stringify(a),secretId:l.accessKey,secretKey:l.secretKey,signedHeaders:u.sort()});return{url:`${l.endpoint}${e}`,headers:Object.assign({},d,{Authorization:m})}}function os({url:e,data:t,method:a="POST",headers:n={},timeout:i}){return new Promise(((o,s)=>{Ni.request({url:e,method:a,data:"object"==typeof t?JSON.stringify(t):t,header:n,dataType:"json",timeout:i,complete:(e={})=>{const t=n["x-trace-id"]||"";if(!e.statusCode||e.statusCode>=400){const{message:a,errMsg:n,trace_id:i}=e.data||{};return s(new Vi({code:"SYS_ERR",message:a||n||"request:fail",requestId:i||t}))}o({status:e.statusCode,data:e.data,headers:e.header,requestId:t})}})}))}function ss(e,t){const{path:a,data:n,method:i="GET"}=e,{url:o,headers:s}=is(a,{functionName:"",data:n,method:i,headers:{"x-alipay-cloud-mode":"oss","x-data-api-type":"oss","x-expire-timestamp":Date.now()+6e4},signHeaderKeys:["x-data-api-type","x-expire-timestamp"],config:t});return os({url:o,data:n,method:i,headers:s}).then((e=>{const t=e.data||{};if(!t.success)throw new Vi({code:e.errCode,message:e.errMsg,requestId:e.requestId});return t.data||{}})).catch((e=>{throw new Vi({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}function ls(e=""){const t=e.trim().replace(/^cloud:\/\//,""),a=t.indexOf("/");if(a<=0)throw new Vi({code:"INVALID_PARAM",message:"fileID不合法"});const n=t.substring(0,a),i=t.substring(a+1);return n!==this.config.spaceId&&console.warn("file ".concat(e," does not belong to env ").concat(this.config.spaceId)),i}function rs(e=""){return"cloud://".concat(this.config.spaceId,"/").concat(e.replace(/^\/+/,""))}class cs{constructor(e){this.config=e}signedURL(e,t={}){const a=`/ws/function/${e}`,n=this.config.wsEndpoint.replace(/^ws(s)?:\/\//,""),i=Object.assign({},t,{accessKeyId:this.config.accessKey,signatureNonce:ns(),timestamp:""+Date.now()}),o=[a,["accessKeyId","authorization","signatureNonce","timestamp"].sort().map((function(e){return i[e]?"".concat(e,"=").concat(i[e]):null})).filter(Boolean).join("&"),`host:${n}`].join("\n"),s=["HMAC-SHA256",ji(o).toString(as)].join("\n"),l=qi(s,this.config.secretKey).toString(as),r=Object.keys(i).map((e=>`${e}=${encodeURIComponent(i[e])}`)).join("&");return`${this.config.wsEndpoint}${a}?${r}&signature=${l}`}}var ds={init:e=>{e.provider="alipay";const t=new class{constructor(e){if(["spaceId","spaceAppId","accessKey","secretKey"].forEach((t=>{if(!Object.prototype.hasOwnProperty.call(e,t))throw new Error(`${t} required`)})),e.endpoint){if("string"!=typeof e.endpoint)throw new Error("endpoint must be string");if(!/^https:\/\//.test(e.endpoint))throw new Error("endpoint must start with https://");e.endpoint=e.endpoint.replace(/\/$/,"")}this.config=Object.assign({},e,{endpoint:e.endpoint||`https://${e.spaceId}.api-hz.cloudbasefunction.cn`,wsEndpoint:e.wsEndpoint||`wss://${e.spaceId}.api-hz.cloudbasefunction.cn`}),this._websocket=new cs(this.config)}callFunction(e){return function(e,t){const{name:a,data:n,async:i=!1,timeout:o}=e,s="POST",l={"x-to-function-name":a};i&&(l["x-function-invoke-type"]="async");const{url:r,headers:c}=is("/functions/invokeFunction",{functionName:a,data:n,method:s,headers:l,signHeaderKeys:["x-to-function-name"],config:t});return os({url:r,data:n,method:s,headers:c,timeout:o}).then((e=>{let t=0;if(i){const a=e.data||{};t="200"===a.errCode?0:a.errCode,e.data=a.data||{},e.errMsg=a.errMsg}if(0!==t)throw new Vi({code:t,message:e.errMsg,requestId:e.requestId});return{errCode:t,success:0===t,requestId:e.requestId,result:e.data}})).catch((e=>{throw new Vi({code:e.errCode,message:e.errMsg,requestId:e.requestId})}))}(e,this.config)}uploadFileToOSS({url:e,filePath:t,fileType:a,formData:n,onUploadProgress:i}){return new Promise(((o,s)=>{const l=Ni.uploadFile({url:e,filePath:t,fileType:a,formData:n,name:"file",success(e){e&&e.statusCode<400?o(e):s(new Vi({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(e){s(new Vi({code:e.code||"UPLOAD_FAILED",message:e.message||e.errMsg||"文件上传失败"}))}});"function"==typeof i&&l&&"function"==typeof l.onProgressUpdate&&l.onProgressUpdate((e=>{i({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}async uploadFile({filePath:e,cloudPath:t="",fileType:a="image",onUploadProgress:n}){if("string"!==zn(t))throw new Vi({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});if(!(t=t.trim()))throw new Vi({code:"INVALID_PARAM",message:"cloudPath不可为空"});if(/:\/\//.test(t))throw new Vi({code:"INVALID_PARAM",message:"cloudPath不合法"});const i=await ss({path:"/".concat(t.replace(/^\//,""),"?post_url")},this.config),{file_id:o,upload_url:s,form_data:l}=i,r=l&&l.reduce(((e,t)=>(e[t.key]=t.value,e)),{});return this.uploadFileToOSS({url:s,filePath:e,fileType:a,formData:r,onUploadProgress:n}).then((()=>({fileID:o})))}async getTempFileURL({fileList:e}){return new Promise(((t,a)=>{(!e||e.length<0)&&t({code:"INVALID_PARAM",message:"fileList不能为空数组"}),e.length>50&&t({code:"INVALID_PARAM",message:"fileList数组长度不能超过50"});const n=[];for(const o of e){let e;"string"!==zn(o)&&t({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});try{e=ls.call(this,o)}catch(i){console.warn(i.errCode,i.errMsg),e=o}n.push({file_id:e,expire:600})}ss({path:"/?download_url",data:{file_list:n},method:"POST"},this.config).then((e=>{const{file_list:a=[]}=e;t({fileList:a.map((e=>({fileID:rs.call(this,e.file_id),tempFileURL:e.download_url})))})})).catch((e=>a(e)))}))}async connectWebSocket(e){const{name:t,query:a}=e;return Ni.connectSocket({url:this._websocket.signedURL(t,a),complete:()=>{}})}}(e);return t.auth=function(){return{signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!0)}}},t}};function us({data:e}){let t;t=Pi();const a=JSON.parse(JSON.stringify(e||{}));if(Object.assign(a,{clientInfo:t}),!a.uniIdToken){const{token:e}=Ci();e&&(a.uniIdToken=e)}return a}const hs=[{rule:/fc_function_not_found|FUNCTION_NOT_FOUND/,content:"，云函数[{functionName}]在云端不存在，请检查此云函数名称是否正确以及该云函数是否已上传到服务空间",mode:"append"}];var ps=/[\\^$.*+?()[\]{}|]/g,ms=RegExp(ps.source);function gs(e,t,a){return e.replace(new RegExp((n=t)&&ms.test(n)?n.replace(ps,"\\$&"):n,"g"),a);var n}const fs="request",ys="response",vs="both",ws="_globalUniCloudStatus",bs={code:2e4,message:"System error"},ks={code:20101,message:"Invalid client"};function xs(e){const{errSubject:t,subject:a,errCode:n,errMsg:i,code:o,message:s,cause:l}=e||{};return new Vi({subject:t||a||"uni-secure-network",code:n||o||bs.code,message:i||s,cause:l})}let Vs;function Ns({secretType:e}={}){return e===fs||e===ys||e===vs}function Es({name:e,data:t={}}={}){return"DCloud-clientDB"===e&&"encryption"===t.redirectTo&&"getAppClientKey"===t.action}function Cs({functionName:e,result:t,logPvd:a}){}function _s(e){const t=e.callFunction,a=function(a){const n=a.name;a.data=us.call(e,{data:a.data});const i={aliyun:"aliyun",tencent:"tcb",tcb:"tcb",alipay:"alipay",dcloud:"dcloud"}[this.config.provider],o=Ns(a),s=Es(a),l=o||s;return t.call(this,a).then((e=>(e.errCode=0,!l&&Cs.call(this,{functionName:n,result:e,logPvd:i}),Promise.resolve(e))),(e=>(!l&&Cs.call(this,{functionName:n,result:e,logPvd:i}),e&&e.message&&(e.message=function({message:e="",extraInfo:t={},formatter:a=[]}={}){for(let n=0;n<a.length;n++){const{rule:i,content:o,mode:s}=a[n],l=e.match(i);if(!l)continue;let r=o;for(let e=1;e<l.length;e++)r=gs(r,`{$${e}}`,l[e]);for(const e in t)r=gs(r,`{${e}}`,t[e]);return"replace"===s?r:e+r}return e}({message:`[${a.name}]: ${e.message}`,formatter:hs,extraInfo:{functionName:n}})),Promise.reject(e))))};e.callFunction=function(t){const{provider:n,spaceId:i}=e.config,o=t.name;let s,l;return t.data=t.data||{},s=a,s=s.bind(e),l=Es(t)?a.call(e,t):Ns(t)?new Vs({secretType:t.secretType,uniCloudIns:e}).wrapEncryptDataCallFunction(a.bind(e))(t):function({provider:e,spaceId:t,functionName:a}={}){const{appId:n,uniPlatform:i,osName:o}=Bi();let s=i;"app"===i&&(s=o);const l=function({provider:e,spaceId:t}={}){const a=Kn;if(!a)return{};e=function(e){return"tencent"===e?"tcb":e}(e);const n=a.find((a=>a.provider===e&&a.spaceId===t));return n&&n.config}({provider:e,spaceId:t});if(!l||!l.accessControl||!l.accessControl.enable)return!1;const r=l.accessControl.function||{},c=Object.keys(r);if(0===c.length)return!0;const d=function(e,t){let a,n,i;for(let o=0;o<e.length;o++){const s=e[o];s!==t?"*"!==s?s.split(",").map((e=>e.trim())).indexOf(t)>-1&&(n=s):i=s:a=s}return a||n||i}(c,a);if(!d)return!1;if((r[d]||[]).find(((e={})=>e.appId===n&&(e.platform||"").toLowerCase()===s.toLowerCase())))return!0;throw console.error(`此应用[appId: ${n}, platform: ${s}]不在云端配置的允许访问的应用列表内，参考：https://uniapp.dcloud.net.cn/uniCloud/secure-network.html#verify-client`),xs(ks)}({provider:n,spaceId:i,functionName:o})?new Vs({secretType:t.secretType,uniCloudIns:e}).wrapVerifyClientCallFunction(a.bind(e))(t):s(t),Object.defineProperty(l,"result",{get:()=>(console.warn("当前返回结果为Promise类型，不可直接访问其result属性，详情请参考：https://uniapp.dcloud.net.cn/uniCloud/faq?id=promise"),{})}),l.then((e=>e))}}Vs=class{constructor(){throw xs({message:"Platform app is not enabled, please check whether secure network module is enabled in your manifest.json"})}};const Ss=Symbol("CLIENT_DB_INTERNAL");function Ts(e,t){return e.then="DoNotReturnProxyWithAFunctionNamedThen",e._internalType=Ss,e.inspect=null,e.__v_raw=void 0,new Proxy(e,{get(e,a,n){if("_uniClient"===a)return null;if("symbol"==typeof a)return e[a];if(a in e||"string"!=typeof a){const t=e[a];return"function"==typeof t?t.bind(e):t}return t.get(e,a,n)}})}function Bs(e){return{on:(t,a)=>{e[t]=e[t]||[],e[t].indexOf(a)>-1||e[t].push(a)},off:(t,a)=>{e[t]=e[t]||[];const n=e[t].indexOf(a);-1!==n&&e[t].splice(n,1)}}}const Ds=["db.Geo","db.command","command.aggregate"];function Is(e,t){return Ds.indexOf(`${e}.${t}`)>-1}function Ps(e){switch(zn(e=Ei(e))){case"array":return e.map((e=>Ps(e)));case"object":return e._internalType===Ss||Object.keys(e).forEach((t=>{e[t]=Ps(e[t])})),e;case"regexp":return{$regexp:{source:e.source,flags:e.flags}};case"date":return{$date:e.toISOString()};default:return e}}function As(e){return e&&e.content&&e.content.$method}class Fs{constructor(e,t,a){this.content=e,this.prevStage=t||null,this.udb=null,this._database=a}toJSON(){let e=this;const t=[e.content];for(;e.prevStage;)e=e.prevStage,t.push(e.content);return{$db:t.reverse().map((e=>({$method:e.$method,$param:Ps(e.$param)})))}}toString(){return JSON.stringify(this.toJSON())}getAction(){const e=this.toJSON().$db.find((e=>"action"===e.$method));return e&&e.$param&&e.$param[0]}getCommand(){return{$db:this.toJSON().$db.filter((e=>"action"!==e.$method))}}get isAggregate(){let e=this;for(;e;){const t=As(e),a=As(e.prevStage);if("aggregate"===t&&"collection"===a||"pipeline"===t)return!0;e=e.prevStage}return!1}get isCommand(){let e=this;for(;e;){if("command"===As(e))return!0;e=e.prevStage}return!1}get isAggregateCommand(){let e=this;for(;e;){const t=As(e),a=As(e.prevStage);if("aggregate"===t&&"command"===a)return!0;e=e.prevStage}return!1}getNextStageFn(e){const t=this;return function(){return Ls({$method:e,$param:Ps(Array.from(arguments))},t,t._database)}}get count(){return this.isAggregate?this.getNextStageFn("count"):function(){return this._send("count",Array.from(arguments))}}get remove(){return this.isCommand?this.getNextStageFn("remove"):function(){return this._send("remove",Array.from(arguments))}}get(){return this._send("get",Array.from(arguments))}get add(){return this.isCommand?this.getNextStageFn("add"):function(){return this._send("add",Array.from(arguments))}}update(){return this._send("update",Array.from(arguments))}end(){return this._send("end",Array.from(arguments))}get set(){return this.isCommand?this.getNextStageFn("set"):function(){throw new Error("JQL禁止使用set方法")}}_send(e,t){const a=this.getAction(),n=this.getCommand();return n.$db.push({$method:e,$param:Ps(t)}),this._database._callCloudFunction({action:a,command:n})}}function Ls(e,t,a){return Ts(new Fs(e,t,a),{get(e,t){let n="db";return e&&e.content&&(n=e.content.$method),Is(n,t)?Ls({$method:t},e,a):function(){return Ls({$method:t,$param:Ps(Array.from(arguments))},e,a)}}})}function Ms({path:e,method:t}){return class{constructor(){this.param=Array.from(arguments)}toJSON(){return{$newDb:[...e.map((e=>({$method:e}))),{$method:t,$param:this.param}]}}toString(){return JSON.stringify(this.toJSON())}}}function Rs(e,t={}){return Ts(new e(t),{get:(e,t)=>Is("db",t)?Ls({$method:t},null,e):function(){return Ls({$method:t,$param:Ps(Array.from(arguments))},null,e)}})}class Os extends class{constructor({uniClient:e={},isJQL:t=!1}={}){this._uniClient=e,this._authCallBacks={},this._dbCallBacks={},e._isDefault&&(this._dbCallBacks=ei("_globalUniCloudDatabaseCallback")),t||(this.auth=Bs(this._authCallBacks)),this._isJQL=t,Object.assign(this,Bs(this._dbCallBacks)),this.env=Ts({},{get:(e,t)=>({$env:t})}),this.Geo=Ts({},{get:(e,t)=>Ms({path:["Geo"],method:t})}),this.serverDate=Ms({path:[],method:"serverDate"}),this.RegExp=Ms({path:[],method:"RegExp"})}getCloudEnv(e){if("string"!=typeof e||!e.trim())throw new Error("getCloudEnv参数错误");return{$env:e.replace("$cloudEnv_","")}}_callback(e,t){const a=this._dbCallBacks;a[e]&&a[e].forEach((e=>{e(...t)}))}_callbackAuth(e,t){const a=this._authCallBacks;a[e]&&a[e].forEach((e=>{e(...t)}))}multiSend(){const e=Array.from(arguments),t=e.map((e=>{const t=e.getAction(),a=e.getCommand();if("getTemp"!==a.$db[a.$db.length-1].$method)throw new Error("multiSend只支持子命令内使用getTemp");return{action:t,command:a}}));return this._callCloudFunction({multiCommand:t,queryList:e})}}{_parseResult(e){return this._isJQL?e.result:e}_callCloudFunction({action:e,command:t,multiCommand:a,queryList:n}){function i(e,t){if(a&&n)for(let a=0;a<n.length;a++){const i=n[a];i.udb&&"function"==typeof i.udb.setResult&&(t?i.udb.setResult(t):i.udb.setResult(e.result.dataList[a]))}}const o=this,s=this._isJQL?"databaseForJQL":"database";function l(e){return o._callback("error",[e]),oi(si(s,"fail"),e).then((()=>oi(si(s,"complete"),e))).then((()=>(i(null,e),vi(ci,{type:hi,content:e}),Promise.reject(e))))}const r=oi(si(s,"invoke")),c=this._uniClient;return r.then((()=>c.callFunction({name:"DCloud-clientDB",type:Rn,data:{action:e,command:t,multiCommand:a}}))).then((e=>{const{code:t,message:a,token:n,tokenExpired:r,systemInfo:c=[]}=e.result;if(c)for(let i=0;i<c.length;i++){const{level:e,message:t,detail:a}=c[i];let n="[System Info]"+t;a&&(n=`${n}\n详细信息：${a}`),(console["warn"===e?"error":e]||console.log)(n)}if(t)return l(new Vi({code:t,message:a,requestId:e.requestId}));e.result.errCode=e.result.errCode||e.result.code,e.result.errMsg=e.result.errMsg||e.result.message,n&&r&&(_i({token:n,tokenExpired:r}),this._callbackAuth("refreshToken",[{token:n,tokenExpired:r}]),this._callback("refreshToken",[{token:n,tokenExpired:r}]),vi(ui,{token:n,tokenExpired:r}));const d=[{prop:"affectedDocs",tips:"affectedDocs不再推荐使用，请使用inserted/deleted/updated/data.length替代"},{prop:"code",tips:"code不再推荐使用，请使用errCode替代"},{prop:"message",tips:"message不再推荐使用，请使用errMsg替代"}];for(let i=0;i<d.length;i++){const{prop:t,tips:a}=d[i];if(t in e.result){const n=e.result[t];Object.defineProperty(e.result,t,{get:()=>(console.warn(a),n)})}}return u=e,oi(si(s,"success"),u).then((()=>oi(si(s,"complete"),u))).then((()=>{i(u,null);const e=o._parseResult(u);return vi(ci,{type:hi,content:e}),Promise.resolve(e)}));var u}),(e=>(/fc_function_not_found|FUNCTION_NOT_FOUND/g.test(e.message)&&console.warn("clientDB未初始化，请在web控制台保存一次schema以开启clientDB"),l(new Vi({code:e.code||"SYSTEM_ERROR",message:e.message,requestId:e.requestId})))))}}const $s="token无效，跳转登录页面",zs="token过期，跳转登录页面",Us={TOKEN_INVALID_TOKEN_EXPIRED:zs,TOKEN_INVALID_INVALID_CLIENTID:$s,TOKEN_INVALID:$s,TOKEN_INVALID_WRONG_TOKEN:$s,TOKEN_INVALID_ANONYMOUS_USER:$s},js={"uni-id-token-expired":zs,"uni-id-check-token-failed":$s,"uni-id-token-not-exist":$s,"uni-id-check-device-feature-failed":$s},qs={...Us,...js,default:"用户未登录或登录状态过期，自动跳转登录页面"};function Hs(e,t){let a="";return a=e?`${e}/${t}`:t,a.replace(/^\//,"")}function Ws(e=[],t=""){const a=[],n=[];return e.forEach((e=>{!0===e.needLogin?a.push(Hs(t,e.path)):!1===e.needLogin&&n.push(Hs(t,e.path))})),{needLoginPage:a,notNeedLoginPage:n}}function Js(e){return e.split("?")[0].replace(/^\//,"")}function Gs(){return function(e){let t=e&&e.$page&&e.$page.fullPath;return t?("/"!==t.charAt(0)&&(t="/"+t),t):""}(function(){const e=getCurrentPages();return e[e.length-1]}())}function Ks(){return Js(Gs())}function Qs(e="",t={}){if(!e)return!1;if(!(t&&t.list&&t.list.length))return!1;const a=t.list,n=Js(e);return a.some((e=>e.pagePath===n))}const Ys=!!_n.uniIdRouter,{loginPage:Xs,routerNeedLogin:Zs,resToLogin:el,needLoginPage:tl,notNeedLoginPage:al,loginPageInTabBar:nl}=function({pages:e=[],subPackages:t=[],uniIdRouter:a={},tabBar:n={}}=_n){const{loginPage:i,needLogin:o=[],resToLogin:s=!0}=a,{needLoginPage:l,notNeedLoginPage:r}=Ws(e),{needLoginPage:c,notNeedLoginPage:d}=function(e=[]){const t=[],a=[];return e.forEach((e=>{const{root:n,pages:i=[]}=e,{needLoginPage:o,notNeedLoginPage:s}=Ws(i,n);t.push(...o),a.push(...s)})),{needLoginPage:t,notNeedLoginPage:a}}(t);return{loginPage:i,routerNeedLogin:o,resToLogin:s,needLoginPage:[...l,...c],notNeedLoginPage:[...r,...d],loginPageInTabBar:Qs(i,n)}}();if(tl.indexOf(Xs)>-1)throw new Error(`Login page [${Xs}] should not be "needLogin", please check your pages.json`);function il(e){const t=Ks();if("/"===e.charAt(0))return e;const[a,n]=e.split("?"),i=a.replace(/^\//,"").split("/"),o=t.split("/");o.pop();for(let s=0;s<i.length;s++){const e=i[s];".."===e?o.pop():"."!==e&&o.push(e)}return""===o[0]&&o.shift(),"/"+o.join("/")+(n?"?"+n:"")}function ol({redirect:e}){const t=Js(e),a=Js(Xs);return Ks()!==a&&t!==a}function sl({api:e,redirect:t}={}){if(!t||!ol({redirect:t}))return;const a=(i=t,"/"!==(n=Xs).charAt(0)&&(n="/"+n),i?n.indexOf("?")>-1?n+`&uniIdRedirectUrl=${encodeURIComponent(i)}`:n+`?uniIdRedirectUrl=${encodeURIComponent(i)}`:n);var n,i;nl?"navigateTo"!==e&&"redirectTo"!==e||(e="switchTab"):"switchTab"===e&&(e="navigateTo");const o={navigateTo:uni.navigateTo,redirectTo:uni.redirectTo,switchTab:uni.switchTab,reLaunch:uni.reLaunch};setTimeout((()=>{o[e]({url:a})}),0)}function ll({url:e}={}){const t={abortLoginPageJump:!1,autoToLoginPage:!1},a=function(){const{token:e,tokenExpired:t}=Ci();let a;if(e){if(t<Date.now()){const e="uni-id-token-expired";a={errCode:e,errMsg:qs[e]}}}else{const e="uni-id-check-token-failed";a={errCode:e,errMsg:qs[e]}}return a}();if(function(e){const t=Js(il(e));return!(al.indexOf(t)>-1)&&(tl.indexOf(t)>-1||Zs.some((t=>{return a=e,new RegExp(t).test(a);var a})))}(e)&&a){if(a.uniIdRedirectUrl=e,gi(di).length>0)return setTimeout((()=>{vi(di,a)}),0),t.abortLoginPageJump=!0,t;t.autoToLoginPage=!0}return t}function rl(){!function(){const e=Gs(),{abortLoginPageJump:t,autoToLoginPage:a}=ll({url:e});t||a&&sl({api:"redirectTo",redirect:e})}();const e=["navigateTo","redirectTo","reLaunch","switchTab"];for(let t=0;t<e.length;t++){const a=e[t];uni.addInterceptor(a,{invoke(e){const{abortLoginPageJump:t,autoToLoginPage:n}=ll({url:e.url});return t?e:n?(sl({api:a,redirect:il(e.url)}),!1):e}})}}function cl(){this.onResponse((e=>{const{type:t,content:a}=e;let n=!1;switch(t){case"cloudobject":n=function(e){if("object"!=typeof e)return!1;const{errCode:t}=e||{};return t in qs}(a);break;case"clientdb":n=function(e){if("object"!=typeof e)return!1;const{errCode:t}=e||{};return t in Us}(a)}n&&function(e={}){const t=gi(di);ki().then((()=>{const a=Gs();if(a&&ol({redirect:a}))return t.length>0?vi(di,Object.assign({uniIdRedirectUrl:a},e)):void(Xs&&sl({api:"navigateTo",redirect:a}))}))}(a)}))}function dl(e){var t;(t=e).onResponse=function(e){fi(ci,e)},t.offResponse=function(e){yi(ci,e)},function(e){e.onNeedLogin=function(e){fi(di,e)},e.offNeedLogin=function(e){yi(di,e)},Ys&&(ei(ws).needLoginInit||(ei(ws).needLoginInit=!0,ki().then((()=>{rl.call(e)})),el&&cl.call(e)))}(e),function(e){e.onRefreshToken=function(e){fi(ui,e)},e.offRefreshToken=function(e){yi(ui,e)}}(e)}let ul;const hl="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",pl=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function ml(){const e=Ci().token||"",t=e.split(".");if(!e||3!==t.length)return{uid:null,role:[],permission:[],tokenExpired:0};let a;try{a=JSON.parse((n=t[1],decodeURIComponent(ul(n).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))))}catch(i){throw new Error("获取当前用户信息出错，详细错误信息为："+i.message)}var n;return a.tokenExpired=1e3*a.exp,delete a.exp,delete a.iat,a}ul="function"!=typeof atob?function(e){if(e=String(e).replace(/[\t\n\f\r ]+/g,""),!pl.test(e))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var t;e+="==".slice(2-(3&e.length));for(var a,n,i="",o=0;o<e.length;)t=hl.indexOf(e.charAt(o++))<<18|hl.indexOf(e.charAt(o++))<<12|(a=hl.indexOf(e.charAt(o++)))<<6|(n=hl.indexOf(e.charAt(o++))),i+=64===a?String.fromCharCode(t>>16&255):64===n?String.fromCharCode(t>>16&255,t>>8&255):String.fromCharCode(t>>16&255,t>>8&255,255&t);return i}:atob;var gl=function(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}(Sn((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const a="chooseAndUploadFile:ok",n="chooseAndUploadFile:fail";function i(e,t){return e.tempFiles.forEach(((e,a)=>{e.name||(e.name=e.path.substring(e.path.lastIndexOf("/")+1)),t&&(e.fileType=t),e.cloudPath=Date.now()+"_"+a+e.name.substring(e.name.lastIndexOf("."))})),e.tempFilePaths||(e.tempFilePaths=e.tempFiles.map((e=>e.path))),e}function o(e,t,{onChooseFile:n,onUploadProgress:i}){return t.then((e=>{if(n){const t=n(e);if(void 0!==t)return Promise.resolve(t).then((t=>void 0===t?e:t))}return e})).then((t=>!1===t?{errMsg:a,tempFilePaths:[],tempFiles:[]}:function(e,t,n=5,i){(t=Object.assign({},t)).errMsg=a;const o=t.tempFiles,s=o.length;let l=0;return new Promise((a=>{for(;l<n;)r();function r(){const n=l++;if(n>=s)return void(!o.find((e=>!e.url&&!e.errMsg))&&a(t));const c=o[n];e.uploadFile({provider:c.provider,filePath:c.path,cloudPath:c.cloudPath,fileType:c.fileType,cloudPathAsRealPath:c.cloudPathAsRealPath,onUploadProgress(e){e.index=n,e.tempFile=c,e.tempFilePath=c.path,i&&i(e)}}).then((e=>{c.url=e.fileID,n<s&&r()})).catch((e=>{c.errMsg=e.errMsg||e.message,n<s&&r()}))}}))}(e,t,5,i)))}t.initChooseAndUploadFile=function(e){return function(t={type:"all"}){return"image"===t.type?o(e,function(e){const{count:t,sizeType:a,sourceType:o=["album","camera"],extension:s}=e;return new Promise(((e,l)=>{uni.chooseImage({count:t,sizeType:a,sourceType:o,extension:s,success(t){e(i(t,"image"))},fail(e){l({errMsg:e.errMsg.replace("chooseImage:fail",n)})}})}))}(t),t):"video"===t.type?o(e,function(e){const{camera:t,compressed:a,maxDuration:o,sourceType:s=["album","camera"],extension:l}=e;return new Promise(((e,r)=>{uni.chooseVideo({camera:t,compressed:a,maxDuration:o,sourceType:s,extension:l,success(t){const{tempFilePath:a,duration:n,size:o,height:s,width:l}=t;e(i({errMsg:"chooseVideo:ok",tempFilePaths:[a],tempFiles:[{name:t.tempFile&&t.tempFile.name||"",path:a,size:o,type:t.tempFile&&t.tempFile.type||"",width:l,height:s,duration:n,fileType:"video",cloudPath:""}]},"video"))},fail(e){r({errMsg:e.errMsg.replace("chooseVideo:fail",n)})}})}))}(t),t):o(e,function(e){const{count:t,extension:a}=e;return new Promise(((e,o)=>{let s=uni.chooseFile;if("undefined"!=typeof wx&&"function"==typeof wx.chooseMessageFile&&(s=wx.chooseMessageFile),"function"!=typeof s)return o({errMsg:n+" 请指定 type 类型，该平台仅支持选择 image 或 video。"});s({type:"all",count:t,extension:a,success(t){e(i(t))},fail(e){o({errMsg:e.errMsg.replace("chooseFile:fail",n)})}})}))}(t),t)}}})));const fl="manual";function yl(e){return{props:{localdata:{type:Array,default:()=>[]},options:{type:[Object,Array],default:()=>({})},spaceInfo:{type:Object,default:()=>({})},collection:{type:[String,Array],default:""},action:{type:String,default:""},field:{type:String,default:""},orderby:{type:String,default:""},where:{type:[String,Object],default:""},pageData:{type:String,default:"add"},pageCurrent:{type:Number,default:1},pageSize:{type:Number,default:20},getcount:{type:[Boolean,String],default:!1},gettree:{type:[Boolean,String],default:!1},gettreepath:{type:[Boolean,String],default:!1},startwith:{type:String,default:""},limitlevel:{type:Number,default:10},groupby:{type:String,default:""},groupField:{type:String,default:""},distinct:{type:[Boolean,String],default:!1},foreignKey:{type:String,default:""},loadtime:{type:String,default:"auto"},manual:{type:Boolean,default:!1}},data:()=>({mixinDatacomLoading:!1,mixinDatacomHasMore:!1,mixinDatacomResData:[],mixinDatacomErrorMessage:"",mixinDatacomPage:{},mixinDatacomError:null}),created(){this.mixinDatacomPage={current:this.pageCurrent,size:this.pageSize,count:0},this.$watch((()=>{var e=[];return["pageCurrent","pageSize","localdata","collection","action","field","orderby","where","getont","getcount","gettree","groupby","groupField","distinct"].forEach((t=>{e.push(this[t])})),e}),((e,t)=>{if(this.loadtime===fl)return;let a=!1;const n=[];for(let i=2;i<e.length;i++)e[i]!==t[i]&&(n.push(e[i]),a=!0);e[0]!==t[0]&&(this.mixinDatacomPage.current=this.pageCurrent),this.mixinDatacomPage.size=this.pageSize,this.onMixinDatacomPropsChange(a,n)}))},methods:{onMixinDatacomPropsChange(e,t){},mixinDatacomEasyGet({getone:e=!1,success:t,fail:a}={}){this.mixinDatacomLoading||(this.mixinDatacomLoading=!0,this.mixinDatacomErrorMessage="",this.mixinDatacomError=null,this.mixinDatacomGet().then((a=>{this.mixinDatacomLoading=!1;const{data:n,count:i}=a.result;this.getcount&&(this.mixinDatacomPage.count=i),this.mixinDatacomHasMore=n.length<this.pageSize;const o=e?n.length?n[0]:void 0:n;this.mixinDatacomResData=o,t&&t(o)})).catch((e=>{this.mixinDatacomLoading=!1,this.mixinDatacomErrorMessage=e,this.mixinDatacomError=e,a&&a(e)})))},mixinDatacomGet(t={}){let a;t=t||{},a="undefined"!=typeof __uniX&&__uniX?e.databaseForJQL(this.spaceInfo):e.database(this.spaceInfo);const n=t.action||this.action;n&&(a=a.action(n));const i=t.collection||this.collection;a=Array.isArray(i)?a.collection(...i):a.collection(i);const o=t.where||this.where;o&&Object.keys(o).length&&(a=a.where(o));const s=t.field||this.field;s&&(a=a.field(s));const l=t.foreignKey||this.foreignKey;l&&(a=a.foreignKey(l));const r=t.groupby||this.groupby;r&&(a=a.groupBy(r));const c=t.groupField||this.groupField;c&&(a=a.groupField(c)),!0===(void 0!==t.distinct?t.distinct:this.distinct)&&(a=a.distinct());const d=t.orderby||this.orderby;d&&(a=a.orderBy(d));const u=void 0!==t.pageCurrent?t.pageCurrent:this.mixinDatacomPage.current,h=void 0!==t.pageSize?t.pageSize:this.mixinDatacomPage.size,p=void 0!==t.getcount?t.getcount:this.getcount,m=void 0!==t.gettree?t.gettree:this.gettree,g=void 0!==t.gettreepath?t.gettreepath:this.gettreepath,f={getCount:p},y={limitLevel:void 0!==t.limitlevel?t.limitlevel:this.limitlevel,startWith:void 0!==t.startwith?t.startwith:this.startwith};return m&&(f.getTree=y),g&&(f.getTreePath=y),a=a.skip(h*(u-1)).limit(h).get(f),a}}}}function vl(e){return ei("_globalUniCloudSecureNetworkCache__{spaceId}".replace("{spaceId}",e.config.spaceId))}async function wl({openid:e,callLoginByWeixin:t=!1}={}){throw vl(this),new Error("[SecureNetwork] API `initSecureNetworkByWeixin` is not supported on platform `app`")}async function bl(e){const t=vl(this);return t.initPromise||(t.initPromise=wl.call(this,e).then((e=>e)).catch((e=>{throw delete t.initPromise,e}))),t.initPromise}function kl(e){Ii=e}function xl(e){const t={getAppBaseInfo:uni.getSystemInfo,getPushClientId:uni.getPushClientId};return function(a){return new Promise(((n,i)=>{t[e]({...a,success(e){n(e)},fail(e){i(e)}})}))}}class Vl extends class{constructor(){this._callback={}}addListener(e,t){this._callback[e]||(this._callback[e]=[]),this._callback[e].push(t)}on(e,t){return this.addListener(e,t)}removeListener(e,t){if(!t)throw new Error('The "listener" argument must be of type function. Received undefined');const a=this._callback[e];if(!a)return;const n=function(e,t){for(let a=e.length-1;a>=0;a--)if(e[a]===t)return a;return-1}(a,t);a.splice(n,1)}off(e,t){return this.removeListener(e,t)}removeAllListener(e){delete this._callback[e]}emit(e,...t){const a=this._callback[e];if(a)for(let n=0;n<a.length;n++)a[n](...t)}}{constructor(){super(),this._uniPushMessageCallback=this._receivePushMessage.bind(this),this._currentMessageId=-1,this._payloadQueue=[]}init(){return Promise.all([xl("getAppBaseInfo")(),xl("getPushClientId")()]).then((([{appId:e}={},{cid:t}={}]=[])=>{if(!e)throw new Error("Invalid appId, please check the manifest.json file");if(!t)throw new Error("Invalid push client id");this._appId=e,this._pushClientId=t,this._seqId=Date.now()+"-"+Math.floor(9e5*Math.random()+1e5),this.emit("open"),this._initMessageListener()}),(e=>{throw this.emit("error",e),this.close(),e}))}async open(){return this.init()}_isUniCloudSSE(e){if("receive"!==e.type)return!1;const t=e&&e.data&&e.data.payload;return!(!t||"UNI_CLOUD_SSE"!==t.channel||t.seqId!==this._seqId)}_receivePushMessage(e){if(!this._isUniCloudSSE(e))return;const t=e&&e.data&&e.data.payload,{action:a,messageId:n,message:i}=t;this._payloadQueue.push({action:a,messageId:n,message:i}),this._consumMessage()}_consumMessage(){for(;;){const e=this._payloadQueue.find((e=>e.messageId===this._currentMessageId+1));if(!e)break;this._currentMessageId++,this._parseMessagePayload(e)}}_parseMessagePayload(e){const{action:t,messageId:a,message:n}=e;"end"===t?this._end({messageId:a,message:n}):"message"===t&&this._appendMessage({messageId:a,message:n})}_appendMessage({messageId:e,message:t}={}){this.emit("message",t)}_end({messageId:e,message:t}={}){this.emit("end",t),this.close()}_initMessageListener(){uni.onPushMessage(this._uniPushMessageCallback)}_destroy(){uni.offPushMessage(this._uniPushMessageCallback)}toJSON(){return{appId:this._appId,pushClientId:this._pushClientId,seqId:this._seqId}}close(){this._destroy(),this.emit("close")}}const Nl={tcb:Xo,tencent:Xo,aliyun:Mi,private:ts,dcloud:ts,alipay:ds};let El=new class{init(e){let t={};const a=Nl[e.provider];if(!a)throw new Error("未提供正确的provider参数");var n;return t=a.init(e),function(e){e._initPromiseHub||(e._initPromiseHub=new Jn({createPromise:function(){let t=Promise.resolve();t=new Promise((e=>{setTimeout((()=>{e()}),1)}));const a=e.auth();return t.then((()=>a.getLoginState())).then((e=>e?Promise.resolve():a.signInAnonymously()))}}))}(t),_s(t),function(e){const t=e.uploadFile;e.uploadFile=function(e){return t.call(this,e)}}(t),(n=t).database=function(e){if(e&&Object.keys(e).length>0)return n.init(e).database();if(this._database)return this._database;const t=Rs(Os,{uniClient:n});return this._database=t,t},n.databaseForJQL=function(e){if(e&&Object.keys(e).length>0)return n.init(e).databaseForJQL();if(this._databaseForJQL)return this._databaseForJQL;const t=Rs(Os,{uniClient:n,isJQL:!0});return this._databaseForJQL=t,t},function(e){e.getCurrentUserInfo=ml,e.chooseAndUploadFile=gl.initChooseAndUploadFile(e),Object.assign(e,{get mixinDatacom(){return yl(e)}}),e.SSEChannel=Vl,e.initSecureNetworkByWeixin=function(e){return function({openid:t,callLoginByWeixin:a=!1}={}){return bl.call(e,{openid:t,callLoginByWeixin:a})}}(e),e.setCustomClientInfo=kl,e.importObject=function(t){return function(a,n={}){n=function(e,t={}){return e.customUI=t.customUI||e.customUI,e.parseSystemError=t.parseSystemError||e.parseSystemError,Object.assign(e.loadingOptions,t.loadingOptions),Object.assign(e.errorOptions,t.errorOptions),"object"==typeof t.secretMethods&&(e.secretMethods=t.secretMethods),e}({customUI:!1,loadingOptions:{title:"加载中...",mask:!0},errorOptions:{type:"modal",retry:!1}},n);const{customUI:i,loadingOptions:o,errorOptions:s,parseSystemError:l}=n,r=!i;return new Proxy({},{get(i,c){switch(c){case"toString":return"[object UniCloudObject]";case"toJSON":return{}}return function({fn:e,interceptorName:t,getCallbackArgs:a}={}){return async function(...n){const i=a?a({params:n}):{};let o,s;try{return await oi(si(t,"invoke"),{...i}),o=await e(...n),await oi(si(t,"success"),{...i,result:o}),o}catch(l){throw s=l,await oi(si(t,"fail"),{...i,error:s}),s}finally{await oi(si(t,"complete"),s?{...i,error:s}:{...i,result:o})}}}({fn:async function i(...d){let u;r&&uni.showLoading({title:o.title,mask:o.mask});const h={name:a,type:Mn,data:{method:c,params:d}};"object"==typeof n.secretMethods&&function(e,t){const a=t.data.method,n=e.secretMethods||{},i=n[a]||n["*"];i&&(t.secretType=i)}(n,h);let p=!1;try{u=await t.callFunction(h)}catch(e){p=!0,u={result:new Vi(e)}}const{errSubject:m,errCode:g,errMsg:f,newToken:y}=u.result||{};if(r&&uni.hideLoading(),y&&y.token&&y.tokenExpired&&(_i(y),vi(ui,{...y})),g){let e=f;if(p&&l&&(e=(await l({objectName:a,methodName:c,params:d,errSubject:m,errCode:g,errMsg:f})).errMsg||f),r)if("toast"===s.type)uni.showToast({title:e,icon:"none"});else{if("modal"!==s.type)throw new Error(`Invalid errorOptions.type: ${s.type}`);{const{confirm:t}=await async function({title:e,content:t,showCancel:a,cancelText:n,confirmText:i}={}){return new Promise(((o,s)=>{uni.showModal({title:e,content:t,showCancel:a,cancelText:n,confirmText:i,success(e){o(e)},fail(){o({confirm:!1,cancel:!0})}})}))}({title:"提示",content:e,showCancel:s.retry,cancelText:"取消",confirmText:s.retry?"重试":"确定"});if(s.retry&&t)return i(...d)}}const t=new Vi({subject:m,code:g,message:f,requestId:u.requestId});throw t.detail=u.result,vi(ci,{type:mi,content:t}),t}return vi(ci,{type:mi,content:u.result}),u.result},interceptorName:"callObject",getCallbackArgs:function({params:e}={}){return{objectName:a,methodName:c,params:e}}})}})}}(e)}(t),["callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","chooseAndUploadFile"].forEach((e=>{if(!t[e])return;const a=t[e];t[e]=function(){return a.apply(t,Array.from(arguments))},t[e]=function(e,t){return function(a){let n=!1;if("callFunction"===t){const e=a&&a.type||Ln;n=e!==Ln}const i="callFunction"===t&&!n,o=this._initPromiseHub.exec();a=a||{};const{success:s,fail:l,complete:r}=xi(a),c=o.then((()=>n?Promise.resolve():oi(si(t,"invoke"),a))).then((()=>e.call(this,a))).then((e=>n?Promise.resolve(e):oi(si(t,"success"),e).then((()=>oi(si(t,"complete"),e))).then((()=>(i&&vi(ci,{type:pi,content:e}),Promise.resolve(e))))),(e=>n?Promise.reject(e):oi(si(t,"fail"),e).then((()=>oi(si(t,"complete"),e))).then((()=>(vi(ci,{type:pi,content:e}),Promise.reject(e))))));if(!(s||l||r))return c;c.then((e=>{s&&s(e),r&&r(e),i&&vi(ci,{type:pi,content:e})}),(e=>{l&&l(e),r&&r(e),i&&vi(ci,{type:pi,content:e})}))}}(t[e],e).bind(t)})),t.init=this.init,t}};(()=>{const e=Qn;let t={};if(e&&1===e.length)t=e[0],El=El.init(t),El._isDefault=!0;else{const t=["auth","callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile"],a=["database","getCurrentUserInfo","importObject"];let n;n=e&&e.length>0?"应用有多个服务空间，请通过uniCloud.init方法指定要使用的服务空间":"应用未关联服务空间，请在uniCloud目录右键关联服务空间",[...t,...a].forEach((e=>{El[e]=function(){if(console.error(n),-1===a.indexOf(e))return Promise.reject(new Vi({code:"SYS_ERR",message:n}));console.error(n)}}))}Object.assign(El,{get mixinDatacom(){return yl(El)}}),dl(El),El.addInterceptor=ni,El.removeInterceptor=ii,El.interceptObject=li,uni.__uniCloud=El;{const e=Xn||(Xn=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;function e(){return this}return void 0!==e()?e():new Function("return this")()}(),Xn);e.uniCloud=El,e.UniCloudError=Vi}})();var Cl=El;const _l=["{","}"];const Sl=/^(?:\d)+/,Tl=/^(?:\w)+/;const Bl="zh-Hans",Dl="zh-Hant",Il="en",Pl=Object.prototype.hasOwnProperty,Al=(e,t)=>Pl.call(e,t),Fl=new class{constructor(){this._caches=Object.create(null)}interpolate(e,t,a=_l){if(!t)return[e];let n=this._caches[e];return n||(n=function(e,[t,a]){const n=[];let i=0,o="";for(;i<e.length;){let s=e[i++];if(s===t){o&&n.push({type:"text",value:o}),o="";let t="";for(s=e[i++];void 0!==s&&s!==a;)t+=s,s=e[i++];const l=s===a,r=Sl.test(t)?"list":l&&Tl.test(t)?"named":"unknown";n.push({value:t,type:r})}else o+=s}return o&&n.push({type:"text",value:o}),n}(e,a),this._caches[e]=n),function(e,t){const a=[];let n=0;const i=Array.isArray(t)?"list":(o=t,null!==o&&"object"==typeof o?"named":"unknown");var o;if("unknown"===i)return a;for(;n<e.length;){const o=e[n];switch(o.type){case"text":a.push(o.value);break;case"list":a.push(t[parseInt(o.value,10)]);break;case"named":"named"===i&&a.push(t[o.value])}n++}return a}(n,t)}};function Ll(e,t){if(!e)return;if(e=e.trim().replace(/_/g,"-"),t&&t[e])return e;if("chinese"===(e=e.toLowerCase()))return Bl;if(0===e.indexOf("zh"))return e.indexOf("-hans")>-1?Bl:e.indexOf("-hant")>-1?Dl:(a=e,["-tw","-hk","-mo","-cht"].find((e=>-1!==a.indexOf(e)))?Dl:Bl);var a;let n=[Il,"fr","es"];t&&Object.keys(t).length>0&&(n=Object.keys(t));const i=function(e,t){return t.find((t=>0===e.indexOf(t)))}(e,n);return i||void 0}class Ml{constructor({locale:e,fallbackLocale:t,messages:a,watcher:n,formater:i}){this.locale=Il,this.fallbackLocale=Il,this.message={},this.messages={},this.watchers=[],t&&(this.fallbackLocale=t),this.formater=i||Fl,this.messages=a||{},this.setLocale(e||Il),n&&this.watchLocale(n)}setLocale(e){const t=this.locale;this.locale=Ll(e,this.messages)||this.fallbackLocale,this.messages[this.locale]||(this.messages[this.locale]={}),this.message=this.messages[this.locale],t!==this.locale&&this.watchers.forEach((e=>{e(this.locale,t)}))}getLocale(){return this.locale}watchLocale(e){const t=this.watchers.push(e)-1;return()=>{this.watchers.splice(t,1)}}add(e,t,a=!0){const n=this.messages[e];n?a?Object.assign(n,t):Object.keys(t).forEach((e=>{Al(n,e)||(n[e]=t[e])})):this.messages[e]=t}f(e,t,a){return this.formater.interpolate(e,t,a).join("")}t(e,t,a){let n=this.message;return"string"==typeof t?(t=Ll(t,this.messages))&&(n=this.messages[t]):a=t,Al(n,e)?this.formater.interpolate(n[e],a).join(""):(console.warn(`Cannot translate the value of keypath ${e}. Use the value of keypath as default.`),e)}}function Rl(e,t={},a,n){if("string"!=typeof e){const a=[t,e];e=a[0],t=a[1]}"string"!=typeof e&&(e="undefined"!=typeof uni&&uni.getLocale?uni.getLocale():"undefined"!=typeof global&&global.getLocale?global.getLocale():Il),"string"!=typeof a&&(a="undefined"!=typeof __uniConfig&&__uniConfig.fallbackLocale||Il);const i=new Ml({locale:e,fallbackLocale:a,messages:t,watcher:n});let o=(e,t)=>{if("function"!=typeof getApp)o=function(e,t){return i.t(e,t)};else{let e=!1;o=function(t,a){const n=getApp().$vm;return n&&(n.$locale,e||(e=!0,function(e,t){e.$watchLocale?e.$watchLocale((e=>{t.setLocale(e)})):e.$watch((()=>e.$locale),(e=>{t.setLocale(e)}))}(n,i))),i.t(t,a)}}return o(e,t)};return{i18n:i,f:(e,t,a)=>i.f(e,t,a),t:(e,t)=>o(e,t),add:(e,t,a=!0)=>i.add(e,t,a),watch:e=>i.watchLocale(e),getLocale:()=>i.getLocale(),setLocale:e=>i.setLocale(e)}}const Ol={en:{"uni-load-more.contentdown":"Pull up to show more","uni-load-more.contentrefresh":"loading...","uni-load-more.contentnomore":"No more data"},"zh-Hans":{"uni-load-more.contentdown":"上拉显示更多","uni-load-more.contentrefresh":"正在加载...","uni-load-more.contentnomore":"没有更多数据了"},"zh-Hant":{"uni-load-more.contentdown":"上拉顯示更多","uni-load-more.contentrefresh":"正在加載...","uni-load-more.contentnomore":"沒有更多數據了"}};let $l;setTimeout((()=>{$l=uni.getSystemInfoSync().platform}),16);const{t:zl}=Rl(Ol);const Ul=t({name:"UniLoadMore",emits:["clickLoadMore"],props:{status:{type:String,default:"more"},showIcon:{type:Boolean,default:!0},iconType:{type:String,default:"auto"},iconSize:{type:Number,default:24},color:{type:String,default:"#777777"},contentText:{type:Object,default:()=>({contentdown:"",contentrefresh:"",contentnomore:""})},showText:{type:Boolean,default:!0}},data:()=>({webviewHide:!1,platform:$l,imgBase64:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNiAoV2luZG93cykiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6QzlBMzU3OTlEOUM0MTFFOUI0NTZDNERBQURBQzI4RkUiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6QzlBMzU3OUFEOUM0MTFFOUI0NTZDNERBQURBQzI4RkUiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDpDOUEzNTc5N0Q5QzQxMUU5QjQ1NkM0REFBREFDMjhGRSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDpDOUEzNTc5OEQ5QzQxMUU5QjQ1NkM0REFBREFDMjhGRSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pt+ALSwAAA6CSURBVHja1FsLkFZVHb98LM+F5bHL8khA1iSeiyQBCRM+YGqKUnnJTDLGI0BGZlKDIU2MMglUiDApEZvSsZnQtBRJtKwQNKQMFYeRDR10WOLd8ljYXdh+v8v5fR3Od+797t1dnOnO/Ofce77z+J//+b/P+ZqtXbs2sJ9MJhNUV1cHJ06cCJo3bx7EPc2aNcvpy7pWrVoF+/fvDyoqKoI2bdoE9fX1F7TjN8a+EXBn/fkfvw942Tf+wYMHg9mzZwfjxo0LDhw4EPa1x2MbFw/fOGfPng1qa2tzcCkILsLDydq2bRsunpOTMM7TD/W/tZDZhPdeKD+yGxHhdu3aBV27dg3OnDlzMVANMheLAO3btw8KCwuDmpoaX5OxbgUIMEq7K8IcPnw4KCsrC/r37x8cP378/4cAXAB3vqSkJMuiDhTkw+XcuXNhOWbMmKBly5YhUT8xArhyFvP0BfwRsAuwxJZJsm/nzp2DTp06he/OU+cZ64K6o0ePBkOHDg2GDx8e6gEbJ5Q/NHNuAJQ1hgBeHUDlR7nVTkY8rQAvAi4z34vR/mPs1FoRsaCgIJThI0eOBC1atEiFGGV+5MiRoS45efJkqFjJFXV1dQuA012m2WcwTw98fy6CqBdsaiIO4CScrGPHjvk4odhavPquRtFWXEC25VgkREKOCh/qDSq+vn37htzD/mZTOmOc5U7zKzBPEedygWshcDyWvs30igAbU+6oyMgJBCFhwQE0fccxN60Ay9iebbjoDh06hMowjQxT4fXq1SskArmHZpkArvixp/kWzHdMeArExSJEaiXIjjRjRJ4DaAGWpibLzXN3Fm1vA5teBgh3j1Rv3bp1YgKwPdmf2p9zcyNYYgPKMfY0T5f5nNYdw158nJ8QawW4CLKwiOBSEgO/hok2eBydR+3dYH+PLxA5J8Vv0KBBwenTp0P2JWAx6+yFEBfs8lMY+y0SWMBNI9E4ThKi58VKTg3FQZS1RQF1cz27eC0QHMu+3E0SkUowjhVt5VdaWhp07949ZHv2Qd1EjDXM2cla1M0nl3GxAs3J9yREzyTdFVKVFOaE9qRA8GM0WebRuo9JGZKA7Mv2SeS/Z8+eoQ9BArMfFrLGo6jvxbhHbJZnKX2Rzz1O7QhJJ9Cs2ZMaWIyq/zhdeqPNfIoHd58clIQD+JSXl4dKlyIAuBdVXZwFVWKspSSoxE++h8x4k3uCnEhE4I5KwRiFWGOU0QWKiCYLbdoRMRKAu2kQ9vkfLU6dOhX06NEjlH+yMRZSinnuyWnYosVcji8CEA/6Cg2JF+IIUBqnGKUTCNwtwBN4f89RiK1R96DEgO2o0NDmtEdvVFdVVYV+P3UAPUEs6GFwV3PHmXkD4vh74iDFJysVI/MlaQhwKeBNTLYX5VuA8T4/gZxA4MRGFxDB6R7OmYPfyykGRJbyie+XnGYnQIC/coH9+vULiYrxrkL9ZA9+0ykaHIfEpM7ge8TiJ2CsHYwyMfafAF1yCGBHYIbCVDjDjKt7BeB51D+LgQa6OkG7IDYEEtvQ7lnXLKLtLdLuJBpE4gPUXcW2+PkZwOex+4cGDhwYDBkyRL7/HFcEwUGPo/8uWRUpYnfxGHco8HkewLHLyYmAawAPuIFZxhOpDfJQ8gbUv41yORAptMWBNr6oqMhWird5+u+iHmBb2nhjDV7HWBNQTgK8y11l5NetWzc5ULscAtSj7nbNI0skhWeUZCc0W4nyH/jO4Vz0u1IeYhbk4AiwM6tjxIWByHsoZ9qcIBPJd/y+DwPfBESOmCa/QF3WiZHucLlEDpNxcNhmheEOPgdQNx6/VZFQzFZ5TN08AHXQt2Ii3EdyFuUsPtTcGPhW5iMiCNELvz+Gdn9huG4HUJaW/w3g0wxV0XaG7arG2WeKiUWYM4Y7GO5ezshTARbbWGw/DvXkpp/ivVvE0JVoMxN4rpGzJMhE5Pl+xlATsDIqikP9F9D2z3h9nOksEUFhK+qO4rcPkoalMQ/HqJLIyb3F3JdjrCcw1yZ8joyJLR5gCo54etlag7qIoeNh1N1BRYj3DTFJ0elotxPlVzkGuYAmL0VSJVGAJA41c4Z6A3BzTLfn0HYwYKEI6CUAMzZEWvLsIcQOo1AmmyyM72nHJCfYsogflGV6jEk9vyQZXSuq6w4c16NsGcGZbwOPr+H1RkOk2LEzjNepxQkihHSCQ4ynAYNRx2zMKV92CQMWqj8J0BRE8EShxRFN6YrfCRhC0x3r/Zm4IbQCcmJoV0kMamllccR6FjHqUC5F2R/wS2dcymOlfAKOS4KmzQb5cpNC2MC7JhVn5wjXoJ44rYhLh8n0eXOCorJxa7POjbSlCGVczr34/RsAmrcvo9s+wGp3tzVhntxiXiJ4nvEYb4FJkf0O8HocAePmLvCxnL0AORraVekJk6TYjDabRVXfRE2lCN1h6ZQRN1+InUbsCpKwoBZHh0dODN9JBCUffItXxEavTQkUtnfTVAplCWL3JISz29h4NjotnuSsQKJCk8dF+kJR6RARjrqFVmfPnj3ZbK8cIJ0msd6jgHPGtfVTQ8VLmlvh4mct9sobRmPic0DyDQQnx/NlfYUgyz59+oScsH379pAwXABD32nTpoUHIToESeI5mnbE/UqDdyLcafEBf2MCqgC7NwxIbMREJQ0g4D4sfJwnD+AmRrII05cfMWJE+L1169bQr+fip06dGp4oJ83lmYd5wj/EmMa4TaHivo4EeCguYZBnkB5g2aWA69OIEnUHOaGysjIYMGBAMGnSpODYsWPZwCpFmm4lNq+4gSLQA7jcX8DwtjEyRC8wjabnXEx9kfWnTJkSJkAo90xpJVV+FmcVNeYAF5zWngS4C4O91MBxmAv8blLEpbjI5sz9MTdAhcgkCT1RO8mZkAjfiYpTEvStAS53Uw1vAiUGgZ3GpuQEYvoiBqlIan7kSDHnTwJQFNiPu0+5VxCVYhcZIjNrdXUDdp+Eq5AZ3Gkg8QAyVZRZIk4Tl4QAbF9cXJxNYZMAtAokgs4BrNxEpCtteXg7DDTMDKYNSuQdKsnJBek7HxewvxaosWxLYXtw+cJp18217wql4aKCfBNoEu0O5VU+PhctJ0YeXD4C6JQpyrlpSLTojpGGGN5YwNziChdIZLk4lvLcFJ9jMX3QdiImY9bmGQU+TRUL5CHITTRlgF8D9ouD1MfmLoEPl5xokIumZ2cfgMpHt47IW9N64Hsh7wQYYjyIugWuF5fCqYncXRd5vPMWyizzvhi/32+nvG0dZc9vR6fZOu0md5e+uC408FvKSIOZwXlGvxPv95izA2Vtvg1xKFWARI+vMX66HUhpQQb643uW1bSjuTWyw2SBvDrBvjFic1eGGlz5esq3ko9uSIlBRqPuFcCv8F4WIcN12nVaBd0SaYwI6PDDImR11JkqgHcPmQssjxIn6bUshygDFJUTxPMpHk+jfjPgupgdnYV2R/g7xSjtpah8RJBewhwf0gGK6XI92u4wXFEU40afJ4DN4h5LcAd+40HI3JgJecuT0c062W0i2hQJUTcxan3/CMW1PF2K6bbA+Daz4xRs1D3Br1Cm0OihKCqizW78/nXAF/G5TXrEcVzaNMH6CyMswqsAHqDyDLEyou8lwOXnKF8DjI6KjV3KzMBiXkDH8ij/H214J5A596ekrZ3F0zXlWeL7+P5eUrNo3/QwC15uxthuzidy7DzKRwEDaAViiDgKbTbz7CJnzo0bN7pIfIiid8SuPwn25o3QCmpnyjlZkyxPP8EomCJzrGb7GJMx7tNsq4MT2xMUYaiErZOluTzKsnz3gwCeCZyVRZJfYplNEokEjwrPtxlxjeYAk+F1F74VAzPxQRNYYdtpOUvWs8J1sGhBJMNsb7igN8plJs1eSmLIhLKE4rvaCX27gOhLpLOsIzJ7qn/i+wZzcvSOZ23/du8TZjwV8zHIXoP4R3ifBxiFz1dcVpa3aPntPE+c6TmIWE9EtcMmAcPdWAhYhAXxcLOQi9L1WhD1Sc8p1d2oL7XGiRKp8F4A2i8K/nfI+y/gsTDJ/YC/8+AD5Uh04KHiGl+cIFPnBDDrPMjwRGkLXyxO4VGbfQWnDH2v0bVWE3C9QOXlepbgjEfIJQI6XDG3z5ahD9cw2pS78ipB85wyScNTvsVzlzzhL8/jRrnmVjfFJK/m3m4nj9vbgQTguT8XZTjsm672R5uJKEaQmBI/c58gyus8ZDagLpEVSJBIyHp4jn++xqPV71OgQgJYEWOtZ/haxRtKmWOBu8xdBLftWltsY84zE6WIEy/eIOWL+BaayMx+KHtL7EAkqdNDLiEXmEMUHniedtJqg9HmZtfvt26vNi0BdG3Ft3g8ZOf7PAu59TxtzivLNIekyi+wD1i8CuUiD9FXAa8C+/xS3JPmZnomyc7H+fb4/Se0bk41Fel621r4cgVxbq91V4jVqwB7HTe2M7jgB+QWHavZkDRPmZcASoZEmBx6i75bGjPcMdL4/VKGFAGWZkGzPG0XAbdL9A81G5LOmUnC9hHKJeO7dcUMjblSl12867ElFTtaGl20xvvLGPdVz/8TVuU7y0x1PG7vtNg24oz9Uo/Z412++VFWI7Fcog9tu9Lm6gvRmIPv9x1xmQAu6RDkXtbOtlGEmpgD5Nvnyc0dcv0EE6cfdi1HmhMf9wDF3k3gtRvEedhxjpgfqPb9PU9iEJHnyOUA7bQUXh6kq/D7l2iTjWv7XOD530BDr8jIrus+srXjt4MzumJMHuTsBa63YKE1+RR5lBjEikCCnWKWiHdzOgKO+nRIBAF88za/IFmJ3eMZov4CYxGBabcpGL8EYx+SeMXJeRwHNsV/h+vdxeuhEpN3ZyNY78Gm2fknJxVGhyjixPiQvVkNzT1elD9Py/aTAL64Hb9vcYmC9zfdXdT/C1LeGbg4rnBaAihDFJH12W5ulfNCNe/xTsP3bp8ikzJs5BF+5PNfAQYAPaseTdsEcaYAAAAASUVORK5CYII="}),computed:{iconSnowWidth(){return 2*(Math.floor(this.iconSize/24)||1)},contentdownText(){return this.contentText.contentdown||zl("uni-load-more.contentdown")},contentrefreshText(){return this.contentText.contentrefresh||zl("uni-load-more.contentrefresh")},contentnomoreText(){return this.contentText.contentnomore||zl("uni-load-more.contentnomore")}},mounted(){var e=getCurrentPages(),t=e[e.length-1].$getAppWebview();t.addEventListener("hide",(()=>{this.webviewHide=!0})),t.addEventListener("show",(()=>{this.webviewHide=!1}))},methods:{onClick(){this.$emit("clickLoadMore",{detail:{status:this.status}})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-load-more",onClick:a[0]||(a[0]=(...e)=>s.onClick&&s.onClick(...e))},[!o.webviewHide&&("circle"===n.iconType||"auto"===n.iconType&&"android"===o.platform)&&"loading"===n.status&&n.showIcon?(e.openBlock(),e.createElementBlock("view",{key:0,style:e.normalizeStyle({width:n.iconSize+"px",height:n.iconSize+"px"}),class:"uni-load-more__img uni-load-more__img--android-MP"},[e.createElementVNode("view",{class:"uni-load-more__img-icon",style:e.normalizeStyle({borderTopColor:n.color,borderTopWidth:n.iconSize/12})},null,4),e.createElementVNode("view",{class:"uni-load-more__img-icon",style:e.normalizeStyle({borderTopColor:n.color,borderTopWidth:n.iconSize/12})},null,4),e.createElementVNode("view",{class:"uni-load-more__img-icon",style:e.normalizeStyle({borderTopColor:n.color,borderTopWidth:n.iconSize/12})},null,4)],4)):!o.webviewHide&&"loading"===n.status&&n.showIcon?(e.openBlock(),e.createElementBlock("view",{key:1,style:e.normalizeStyle({width:n.iconSize+"px",height:n.iconSize+"px"}),class:"uni-load-more__img uni-load-more__img--ios-H5"},[e.createElementVNode("image",{src:o.imgBase64,mode:"widthFix"},null,8,["src"])],4)):e.createCommentVNode("",!0),n.showText?(e.openBlock(),e.createElementBlock("text",{key:2,class:"uni-load-more__text",style:e.normalizeStyle({color:n.color})},e.toDisplayString("more"===n.status?s.contentdownText:"loading"===n.status?s.contentrefreshText:s.contentnomoreText),5)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-7c9b2f47"]]),jl={name:"uniDataChecklist",mixins:[Cl.mixinDatacom||{}],emits:["input","update:modelValue","change"],props:{mode:{type:String,default:"default"},multiple:{type:Boolean,default:!1},value:{type:[Array,String,Number],default:()=>""},modelValue:{type:[Array,String,Number],default:()=>""},localdata:{type:Array,default:()=>[]},min:{type:[Number,String],default:""},max:{type:[Number,String],default:""},wrap:{type:Boolean,default:!1},icon:{type:String,default:"left"},selectedColor:{type:String,default:""},selectedTextColor:{type:String,default:""},emptyText:{type:String,default:"暂无数据"},disabled:{type:Boolean,default:!1},map:{type:Object,default:()=>({text:"text",value:"value"})}},watch:{localdata:{handler(e){this.range=e,this.dataList=this.getDataList(this.getSelectedValue(e))},deep:!0},mixinDatacomResData(e){this.range=e,this.dataList=this.getDataList(this.getSelectedValue(e))},value(e){this.dataList=this.getDataList(e)},modelValue(e){this.dataList=this.getDataList(e)}},data:()=>({dataList:[],range:[],contentText:{contentdown:"查看更多",contentrefresh:"加载中",contentnomore:"没有更多"},isLocal:!0,styles:{selectedColor:"#2979ff",selectedTextColor:"#666"},isTop:0}),computed:{dataValue(){return""===this.value?this.modelValue:(this.modelValue,this.value)}},created(){this.localdata&&0!==this.localdata.length?(this.isLocal=!0,this.range=this.localdata,this.dataList=this.getDataList(this.getSelectedValue(this.range))):this.collection&&(this.isLocal=!1,this.loadData())},methods:{loadData(){this.mixinDatacomGet().then((e=>{this.mixinDatacomResData=e.result.data,0===this.mixinDatacomResData.length?(this.isLocal=!1,this.mixinDatacomErrorMessage=this.emptyText):this.isLocal=!0})).catch((e=>{this.mixinDatacomErrorMessage=e.message}))},getForm(e="uniForms"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t},change(e){const t=e.detail.value;let a={value:[],data:[]};if(this.multiple)this.range.forEach((e=>{t.includes(e[this.map.value]+"")&&(a.value.push(e[this.map.value]),a.data.push(e))}));else{const e=this.range.find((e=>e[this.map.value]+""===t));e&&(a={value:e[this.map.value],data:e})}this.$emit("input",a.value),this.$emit("update:modelValue",a.value),this.$emit("change",{detail:a}),this.multiple?this.dataList=this.getDataList(a.value,!0):this.dataList=this.getDataList(a.value)},getDataList(e){let t=JSON.parse(JSON.stringify(this.range)),a=[];return this.multiple?Array.isArray(e)||(e=[]):Array.isArray(e)&&e.length&&(e=e[0]),t.forEach(((t,n)=>{if(t.disabled=t.disable||t.disabled||!1,this.multiple)if(e.length>0){let a=e.find((e=>e===t[this.map.value]));t.selected=void 0!==a}else t.selected=!1;else t.selected=e===t[this.map.value];a.push(t)})),this.setRange(a)},setRange(e){let t=e.filter((e=>e.selected)),a=Number(this.min)||0,n=Number(this.max)||"";return e.forEach(((i,o)=>{if(this.multiple){if(t.length<=a){void 0!==t.find((e=>e[this.map.value]===i[this.map.value]))&&(i.disabled=!0)}if(t.length>=n&&""!==n){void 0===t.find((e=>e[this.map.value]===i[this.map.value]))&&(i.disabled=!0)}}this.setStyles(i,o),e[o]=i})),e},setStyles(e,t){e.styleBackgroud=this.setStyleBackgroud(e),e.styleIcon=this.setStyleIcon(e),e.styleIconText=this.setStyleIconText(e),e.styleRightIcon=this.setStyleRightIcon(e)},getSelectedValue(e){if(!this.multiple)return this.dataValue;let t=[];return e.forEach((e=>{e.selected&&t.push(e[this.map.value])})),this.dataValue.length>0?this.dataValue:t},setStyleBackgroud(e){let t={},a=this.selectedColor?this.selectedColor:"#2979ff";this.selectedColor&&("list"!==this.mode&&(t["border-color"]=e.selected?a:"#DCDFE6"),"tag"===this.mode&&(t["background-color"]=e.selected?a:"#f5f5f5"));let n="";for(let i in t)n+=`${i}:${t[i]};`;return n},setStyleIcon(e){let t={},a="";if(this.selectedColor){let a=this.selectedColor?this.selectedColor:"#2979ff";t["background-color"]=e.selected?a:"#fff",t["border-color"]=e.selected?a:"#DCDFE6",!e.selected&&e.disabled&&(t["background-color"]="#F2F6FC",t["border-color"]=e.selected?a:"#DCDFE6")}for(let n in t)a+=`${n}:${t[n]};`;return a},setStyleIconText(e){let t={},a="";if(this.selectedColor){let a=this.selectedColor?this.selectedColor:"#2979ff";"tag"===this.mode?t.color=e.selected?this.selectedTextColor?this.selectedTextColor:"#fff":"#666":t.color=e.selected?this.selectedTextColor?this.selectedTextColor:a:"#666",!e.selected&&e.disabled&&(t.color="#999")}for(let n in t)a+=`${n}:${t[n]};`;return a},setStyleRightIcon(e){let t={},a="";"list"===this.mode&&(t["border-color"]=e.selected?this.styles.selectedColor:"#DCDFE6");for(let n in t)a+=`${n}:${t[n]};`;return a}}};const ql=t(jl,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-load-more"),Ul);return e.openBlock(),e.createElementBlock("view",{class:"uni-data-checklist",style:e.normalizeStyle({"margin-top":s.isTop+"px"})},[s.isLocal?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.multiple?(e.openBlock(),e.createElementBlock("checkbox-group",{key:0,class:e.normalizeClass(["checklist-group",{"is-list":"list"===n.mode||n.wrap}]),onChange:a[0]||(a[0]=(...e)=>l.change&&l.change(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.dataList,((t,a)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checklist-box",["is--"+n.mode,t.selected?"is-checked":"",n.disabled||t.disabled?"is-disable":"",0!==a&&"list"===n.mode?"is-list-border":""]]),style:e.normalizeStyle(t.styleBackgroud),key:a},[e.createElementVNode("checkbox",{class:"hidden",hidden:"",disabled:n.disabled||!!t.disabled,value:t[n.map.value]+"",checked:t.selected},null,8,["disabled","value","checked"]),"tag"!==n.mode&&"list"!==n.mode||"list"===n.mode&&"left"===n.icon?(e.openBlock(),e.createElementBlock("view",{key:0,class:"checkbox__inner",style:e.normalizeStyle(t.styleIcon)},[e.createElementVNode("view",{class:"checkbox__inner-icon"})],4)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["checklist-content",{"list-content":"list"===n.mode&&"left"===n.icon}])},[e.createElementVNode("text",{class:"checklist-text",style:e.normalizeStyle(t.styleIconText)},e.toDisplayString(t[n.map.text]),5),"list"===n.mode&&"right"===n.icon?(e.openBlock(),e.createElementBlock("view",{key:0,class:"checkobx__list",style:e.normalizeStyle(t.styleBackgroud)},null,4)):e.createCommentVNode("",!0)],2)],6)))),128))],34)):(e.openBlock(),e.createElementBlock("radio-group",{key:1,class:e.normalizeClass(["checklist-group",{"is-list":"list"===n.mode,"is-wrap":n.wrap}]),onChange:a[1]||(a[1]=(...e)=>l.change&&l.change(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.dataList,((t,a)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checklist-box",["is--"+n.mode,t.selected?"is-checked":"",n.disabled||t.disabled?"is-disable":"",0!==a&&"list"===n.mode?"is-list-border":""]]),style:e.normalizeStyle(t.styleBackgroud),key:a},[e.createElementVNode("radio",{class:"hidden",hidden:"",disabled:n.disabled||t.disabled,value:t[n.map.value]+"",checked:t.selected},null,8,["disabled","value","checked"]),"tag"!==n.mode&&"list"!==n.mode||"list"===n.mode&&"left"===n.icon?(e.openBlock(),e.createElementBlock("view",{key:0,class:"radio__inner",style:e.normalizeStyle(t.styleBackgroud)},[e.createElementVNode("view",{class:"radio__inner-icon",style:e.normalizeStyle(t.styleIcon)},null,4)],4)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["checklist-content",{"list-content":"list"===n.mode&&"left"===n.icon}])},[e.createElementVNode("text",{class:"checklist-text",style:e.normalizeStyle(t.styleIconText)},e.toDisplayString(t[n.map.text]),5),"list"===n.mode&&"right"===n.icon?(e.openBlock(),e.createElementBlock("view",{key:0,style:e.normalizeStyle(t.styleRightIcon),class:"checkobx__list"},null,4)):e.createCommentVNode("",!0)],2)],6)))),128))],34))],64)):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-data-loading"},[t.mixinDatacomErrorMessage?(e.openBlock(),e.createElementBlock("text",{key:1},e.toDisplayString(t.mixinDatacomErrorMessage),1)):(e.openBlock(),e.createBlock(r,{key:0,status:"loading",iconType:"snow",iconSize:18,"content-text":s.contentText},null,8,["content-text"]))]))],4)}],["__scopeId","data-v-3398f6ea"]]);function Hl(e,t){return`${Wl(e)} ${Jl(e,t)}`}function Wl(e){e=Zl(e);const t=(e=new Date(e)).getFullYear(),a=e.getMonth()+1,n=e.getDate();return`${t}-${Gl(a)}-${Gl(n)}`}function Jl(e,t){e=Zl(e);const a=(e=new Date(e)).getHours(),n=e.getMinutes(),i=e.getSeconds();return t?`${Gl(a)}:${Gl(n)}`:`${Gl(a)}:${Gl(n)}:${Gl(i)}`}function Gl(e){return e<10&&(e=`0${e}`),e}function Kl(e){return e?"00:00":"00:00:00"}function Ql(e,t){return(e=new Date(Zl(e)))<=(t=new Date(Zl(t)))}function Yl(e){return e.match(/((19|20)\d{2})(-|\/)\d{1,2}(-|\/)\d{1,2}/g)}const Xl=/^\d{4}-(0?[1-9]|1[012])-(0?[1-9]|[12][0-9]|3[01])( [0-5]?[0-9]:[0-5]?[0-9](:[0-5]?[0-9])?)?$/;function Zl(e){return"string"==typeof e&&Xl.test(e)&&(e=e.replace(/-/g,"/")),e}const er=t({props:{weeks:{type:Object,default:()=>({})},calendar:{type:Object,default:()=>({})},selected:{type:Array,default:()=>[]},checkHover:{type:Boolean,default:!1}},methods:{choiceDate(e){this.$emit("change",e)},handleMousemove(e){this.$emit("handleMouse",e)}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-calendar-item__weeks-box",{"uni-calendar-item--disable":n.weeks.disable,"uni-calendar-item--before-checked-x":n.weeks.beforeMultiple,"uni-calendar-item--multiple":n.weeks.multiple,"uni-calendar-item--after-checked-x":n.weeks.afterMultiple}]),onClick:a[0]||(a[0]=e=>s.choiceDate(n.weeks)),onMouseenter:a[1]||(a[1]=e=>s.handleMousemove(n.weeks))},[e.createElementVNode("view",{class:e.normalizeClass(["uni-calendar-item__weeks-box-item",{"uni-calendar-item--checked":n.calendar.fullDate===n.weeks.fullDate&&(n.calendar.userChecked||!n.checkHover),"uni-calendar-item--checked-range-text":n.checkHover,"uni-calendar-item--before-checked":n.weeks.beforeMultiple,"uni-calendar-item--multiple":n.weeks.multiple,"uni-calendar-item--after-checked":n.weeks.afterMultiple,"uni-calendar-item--disable":n.weeks.disable}])},[n.selected&&n.weeks.extraInfo?(e.openBlock(),e.createElementBlock("text",{key:0,class:"uni-calendar-item__weeks-box-circle"})):e.createCommentVNode("",!0),e.createElementVNode("text",{class:"uni-calendar-item__weeks-box-text uni-calendar-item__weeks-box-text-disable uni-calendar-item--checked-text"},e.toDisplayString(n.weeks.date),1)],2),e.createElementVNode("view",{class:e.normalizeClass({"uni-calendar-item--today":n.weeks.isToday})},null,2)],34)}],["__scopeId","data-v-ee11a364"]]),tr={en:{"uni-datetime-picker.selectDate":"select date","uni-datetime-picker.selectTime":"select time","uni-datetime-picker.selectDateTime":"select date and time","uni-datetime-picker.startDate":"start date","uni-datetime-picker.endDate":"end date","uni-datetime-picker.startTime":"start time","uni-datetime-picker.endTime":"end time","uni-datetime-picker.ok":"ok","uni-datetime-picker.clear":"clear","uni-datetime-picker.cancel":"cancel","uni-datetime-picker.year":"-","uni-datetime-picker.month":"","uni-calender.MON":"MON","uni-calender.TUE":"TUE","uni-calender.WED":"WED","uni-calender.THU":"THU","uni-calender.FRI":"FRI","uni-calender.SAT":"SAT","uni-calender.SUN":"SUN","uni-calender.confirm":"confirm"},"zh-Hans":{"uni-datetime-picker.selectDate":"选择日期","uni-datetime-picker.selectTime":"选择时间","uni-datetime-picker.selectDateTime":"选择日期时间","uni-datetime-picker.startDate":"开始日期","uni-datetime-picker.endDate":"结束日期","uni-datetime-picker.startTime":"开始时间","uni-datetime-picker.endTime":"结束时间","uni-datetime-picker.ok":"确定","uni-datetime-picker.clear":"清除","uni-datetime-picker.cancel":"取消","uni-datetime-picker.year":"年","uni-datetime-picker.month":"月","uni-calender.SUN":"日","uni-calender.MON":"一","uni-calender.TUE":"二","uni-calender.WED":"三","uni-calender.THU":"四","uni-calender.FRI":"五","uni-calender.SAT":"六","uni-calender.confirm":"确认"},"zh-Hant":{"uni-datetime-picker.selectDate":"選擇日期","uni-datetime-picker.selectTime":"選擇時間","uni-datetime-picker.selectDateTime":"選擇日期時間","uni-datetime-picker.startDate":"開始日期","uni-datetime-picker.endDate":"結束日期","uni-datetime-picker.startTime":"開始时间","uni-datetime-picker.endTime":"結束时间","uni-datetime-picker.ok":"確定","uni-datetime-picker.clear":"清除","uni-datetime-picker.cancel":"取消","uni-datetime-picker.year":"年","uni-datetime-picker.month":"月","uni-calender.SUN":"日","uni-calender.MON":"一","uni-calender.TUE":"二","uni-calender.WED":"三","uni-calender.THU":"四","uni-calender.FRI":"五","uni-calender.SAT":"六","uni-calender.confirm":"確認"}},{t:ar}=Rl(tr),nr={name:"UniDatetimePicker",data:()=>({indicatorStyle:"height: 50px;",visible:!1,fixNvueBug:{},dateShow:!0,timeShow:!0,title:"日期和时间",time:"",year:1920,month:0,day:0,hour:0,minute:0,second:0,startYear:1920,startMonth:1,startDay:1,startHour:0,startMinute:0,startSecond:0,endYear:2120,endMonth:12,endDay:31,endHour:23,endMinute:59,endSecond:59}),options:{virtualHost:!0},props:{type:{type:String,default:"datetime"},value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},start:{type:[Number,String],default:""},end:{type:[Number,String],default:""},returnType:{type:String,default:"string"},disabled:{type:[Boolean,String],default:!1},border:{type:[Boolean,String],default:!0},hideSecond:{type:[Boolean,String],default:!1}},watch:{modelValue:{handler(e){e?(this.parseValue(Zl(e)),this.initTime(!1)):(this.time="",this.parseValue(Date.now()))},immediate:!0},type:{handler(e){"date"===e?(this.dateShow=!0,this.timeShow=!1,this.title="日期"):"time"===e?(this.dateShow=!1,this.timeShow=!0,this.title="时间"):(this.dateShow=!0,this.timeShow=!0,this.title="日期和时间")},immediate:!0},start:{handler(e){this.parseDatetimeRange(Zl(e),"start")},immediate:!0},end:{handler(e){this.parseDatetimeRange(Zl(e),"end")},immediate:!0},months(e){this.checkValue("month",this.month,e)},days(e){this.checkValue("day",this.day,e)},hours(e){this.checkValue("hour",this.hour,e)},minutes(e){this.checkValue("minute",this.minute,e)},seconds(e){this.checkValue("second",this.second,e)}},computed:{years(){return this.getCurrentRange("year")},months(){return this.getCurrentRange("month")},days(){return this.getCurrentRange("day")},hours(){return this.getCurrentRange("hour")},minutes(){return this.getCurrentRange("minute")},seconds(){return this.getCurrentRange("second")},ymd(){return[this.year-this.minYear,this.month-this.minMonth,this.day-this.minDay]},hms(){return[this.hour-this.minHour,this.minute-this.minMinute,this.second-this.minSecond]},currentDateIsStart(){return this.year===this.startYear&&this.month===this.startMonth&&this.day===this.startDay},currentDateIsEnd(){return this.year===this.endYear&&this.month===this.endMonth&&this.day===this.endDay},minYear(){return this.startYear},maxYear(){return this.endYear},minMonth(){return this.year===this.startYear?this.startMonth:1},maxMonth(){return this.year===this.endYear?this.endMonth:12},minDay(){return this.year===this.startYear&&this.month===this.startMonth?this.startDay:1},maxDay(){return this.year===this.endYear&&this.month===this.endMonth?this.endDay:this.daysInMonth(this.year,this.month)},minHour(){return"datetime"===this.type?this.currentDateIsStart?this.startHour:0:"time"===this.type?this.startHour:void 0},maxHour(){return"datetime"===this.type?this.currentDateIsEnd?this.endHour:23:"time"===this.type?this.endHour:void 0},minMinute(){return"datetime"===this.type?this.currentDateIsStart&&this.hour===this.startHour?this.startMinute:0:"time"===this.type?this.hour===this.startHour?this.startMinute:0:void 0},maxMinute(){return"datetime"===this.type?this.currentDateIsEnd&&this.hour===this.endHour?this.endMinute:59:"time"===this.type?this.hour===this.endHour?this.endMinute:59:void 0},minSecond(){return"datetime"===this.type?this.currentDateIsStart&&this.hour===this.startHour&&this.minute===this.startMinute?this.startSecond:0:"time"===this.type?this.hour===this.startHour&&this.minute===this.startMinute?this.startSecond:0:void 0},maxSecond(){return"datetime"===this.type?this.currentDateIsEnd&&this.hour===this.endHour&&this.minute===this.endMinute?this.endSecond:59:"time"===this.type?this.hour===this.endHour&&this.minute===this.endMinute?this.endSecond:59:void 0},selectTimeText:()=>ar("uni-datetime-picker.selectTime"),okText:()=>ar("uni-datetime-picker.ok"),clearText:()=>ar("uni-datetime-picker.clear"),cancelText:()=>ar("uni-datetime-picker.cancel")},mounted(){},methods:{lessThanTen:e=>e<10?"0"+e:e,parseTimeType(e){if(e){let t=e.split(":");this.hour=Number(t[0]),this.minute=Number(t[1]),this.second=Number(t[2])}},initPickerValue(e){let t=null;e?t=this.compareValueWithStartAndEnd(e,this.start,this.end):(t=Date.now(),t=this.compareValueWithStartAndEnd(t,this.start,this.end)),this.parseValue(t)},compareValueWithStartAndEnd(e,t,a){let n=null;return e=this.superTimeStamp(e),t=this.superTimeStamp(t),a=this.superTimeStamp(a),n=t&&a?e<t?new Date(t):e>a?new Date(a):new Date(e):t&&!a?t<=e?new Date(e):new Date(t):!t&&a?e<=a?new Date(e):new Date(a):new Date(e),n},superTimeStamp(e){let t="";if("time"===this.type&&e&&"string"==typeof e){const e=new Date;t=e.getFullYear()+"/"+(e.getMonth()+1)+"/"+e.getDate()+" "}return Number(e)&&(e=parseInt(e),t=0),this.createTimeStamp(t+e)},parseValue(e){if(e){if("time"===this.type&&"string"==typeof e)this.parseTimeType(e);else{let t=null;t=new Date(e),"time"!==this.type&&(this.year=t.getFullYear(),this.month=t.getMonth()+1,this.day=t.getDate()),"date"!==this.type&&(this.hour=t.getHours(),this.minute=t.getMinutes(),this.second=t.getSeconds())}this.hideSecond&&(this.second=0)}},parseDatetimeRange(e,t){if(!e)return"start"===t&&(this.startYear=1920,this.startMonth=1,this.startDay=1,this.startHour=0,this.startMinute=0,this.startSecond=0),void("end"===t&&(this.endYear=2120,this.endMonth=12,this.endDay=31,this.endHour=23,this.endMinute=59,this.endSecond=59));if("time"===this.type){const a=e.split(":");this[t+"Hour"]=Number(a[0]),this[t+"Minute"]=Number(a[1]),this[t+"Second"]=Number(a[2])}else{if(!e)return void("start"===t?this.startYear=this.year-60:this.endYear=this.year+60);Number(e)&&(e=parseInt(e));const a=/[0-9]:[0-9]/;"datetime"!==this.type||"end"!==t||"string"!=typeof e||a.test(e)||(e+=" 23:59:59");const n=new Date(e);this[t+"Year"]=n.getFullYear(),this[t+"Month"]=n.getMonth()+1,this[t+"Day"]=n.getDate(),"datetime"===this.type&&(this[t+"Hour"]=n.getHours(),this[t+"Minute"]=n.getMinutes(),this[t+"Second"]=n.getSeconds())}},getCurrentRange(e){const t=[];for(let a=this["min"+this.capitalize(e)];a<=this["max"+this.capitalize(e)];a++)t.push(a);return t},capitalize:e=>e.charAt(0).toUpperCase()+e.slice(1),checkValue(e,t,a){-1===a.indexOf(t)&&(this[e]=a[0])},daysInMonth:(e,t)=>new Date(e,t,0).getDate(),createTimeStamp(e){if(e)return"number"==typeof e?e:(e=e.replace(/-/g,"/"),"date"===this.type&&(e+=" 00:00:00"),Date.parse(e))},createDomSting(){const e=this.year+"-"+this.lessThanTen(this.month)+"-"+this.lessThanTen(this.day);let t=this.lessThanTen(this.hour)+":"+this.lessThanTen(this.minute);return this.hideSecond||(t=t+":"+this.lessThanTen(this.second)),"date"===this.type?e:"time"===this.type?t:e+" "+t},initTime(e=!0){this.time=this.createDomSting(),e&&("timestamp"===this.returnType&&"time"!==this.type?(this.$emit("change",this.createTimeStamp(this.time)),this.$emit("input",this.createTimeStamp(this.time)),this.$emit("update:modelValue",this.createTimeStamp(this.time))):(this.$emit("change",this.time),this.$emit("input",this.time),this.$emit("update:modelValue",this.time)))},bindDateChange(e){const t=e.detail.value;this.year=this.years[t[0]],this.month=this.months[t[1]],this.day=this.days[t[2]]},bindTimeChange(e){const t=e.detail.value;this.hour=this.hours[t[0]],this.minute=this.minutes[t[1]],this.second=this.seconds[t[2]]},initTimePicker(){if(this.disabled)return;const e=Zl(this.time);this.initPickerValue(e),this.visible=!this.visible},tiggerTimePicker(e){this.visible=!this.visible},clearTime(){this.time="",this.$emit("change",this.time),this.$emit("input",this.time),this.$emit("update:modelValue",this.time),this.tiggerTimePicker()},setTime(){this.initTime(),this.tiggerTimePicker()}}};const ir=t(nr,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker"},[e.createElementVNode("view",{onClick:a[0]||(a[0]=(...e)=>s.initTimePicker&&s.initTimePicker(...e))},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-datetime-picker-timebox-pointer",{"uni-datetime-picker-disabled":n.disabled,"uni-datetime-picker-timebox":n.border}])},[e.createElementVNode("text",{class:"uni-datetime-picker-text"},e.toDisplayString(o.time),1),o.time?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-datetime-picker-time"},[e.createElementVNode("text",{class:"uni-datetime-picker-text"},e.toDisplayString(s.selectTimeText),1)]))],2)]),!0)]),o.visible?(e.openBlock(),e.createElementBlock("view",{key:0,id:"mask",class:"uni-datetime-picker-mask",onClick:a[1]||(a[1]=(...e)=>s.tiggerTimePicker&&s.tiggerTimePicker(...e))})):e.createCommentVNode("",!0),o.visible?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["uni-datetime-picker-popup",[o.dateShow&&o.timeShow?"":"fix-nvue-height"]]),style:e.normalizeStyle(o.fixNvueBug)},[e.createElementVNode("view",{class:"uni-title"},[e.createElementVNode("text",{class:"uni-datetime-picker-text"},e.toDisplayString(s.selectTimeText),1)]),o.dateShow?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-datetime-picker__container-box"},[e.createElementVNode("picker-view",{class:"uni-datetime-picker-view","indicator-style":o.indicatorStyle,value:s.ymd,onChange:a[2]||(a[2]=(...e)=>s.bindDateChange&&s.bindDateChange(...e))},[e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.years,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))]),e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.months,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))]),e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.days,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))])],40,["indicator-style","value"]),e.createElementVNode("text",{class:"uni-datetime-picker-sign sign-left"},"-"),e.createElementVNode("text",{class:"uni-datetime-picker-sign sign-right"},"-")])):e.createCommentVNode("",!0),o.timeShow?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-datetime-picker__container-box"},[e.createElementVNode("picker-view",{class:e.normalizeClass(["uni-datetime-picker-view",[n.hideSecond?"time-hide-second":""]]),"indicator-style":o.indicatorStyle,value:s.hms,onChange:a[3]||(a[3]=(...e)=>s.bindTimeChange&&s.bindTimeChange(...e))},[e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.hours,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))]),e.createElementVNode("picker-view-column",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.minutes,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))]),n.hideSecond?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("picker-view-column",{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.seconds,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-datetime-picker-item",key:a},[e.createElementVNode("text",{class:"uni-datetime-picker-item"},e.toDisplayString(s.lessThanTen(t)),1)])))),128))]))],42,["indicator-style","value"]),e.createElementVNode("text",{class:e.normalizeClass(["uni-datetime-picker-sign",[n.hideSecond?"sign-center":"sign-left"]])},":",2),n.hideSecond?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("text",{key:0,class:"uni-datetime-picker-sign sign-right"},":"))])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-datetime-picker-btn"},[e.createElementVNode("view",{onClick:a[4]||(a[4]=(...e)=>s.clearTime&&s.clearTime(...e))},[e.createElementVNode("text",{class:"uni-datetime-picker-btn-text"},e.toDisplayString(s.clearText),1)]),e.createElementVNode("view",{class:"uni-datetime-picker-btn-group"},[e.createElementVNode("view",{class:"uni-datetime-picker-cancel",onClick:a[5]||(a[5]=(...e)=>s.tiggerTimePicker&&s.tiggerTimePicker(...e))},[e.createElementVNode("text",{class:"uni-datetime-picker-btn-text"},e.toDisplayString(s.cancelText),1)]),e.createElementVNode("view",{onClick:a[6]||(a[6]=(...e)=>s.setTime&&s.setTime(...e))},[e.createElementVNode("text",{class:"uni-datetime-picker-btn-text"},e.toDisplayString(s.okText),1)])])])],6)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-8a3925ff"]]),{t:or}=Rl(tr),sr={components:{calendarItem:er,timePicker:ir},options:{virtualHost:!0},props:{date:{type:String,default:""},defTime:{type:[String,Object],default:""},selectableTimes:{type:[Object],default:()=>({})},selected:{type:Array,default:()=>[]},startDate:{type:String,default:""},endDate:{type:String,default:""},startPlaceholder:{type:String,default:""},endPlaceholder:{type:String,default:""},range:{type:Boolean,default:!1},hasTime:{type:Boolean,default:!1},insert:{type:Boolean,default:!0},showMonth:{type:Boolean,default:!0},clearDate:{type:Boolean,default:!0},checkHover:{type:Boolean,default:!0},hideSecond:{type:[Boolean],default:!1},pleStatus:{type:Object,default:()=>({before:"",after:"",data:[],fulldate:""})},defaultValue:{type:[String,Object,Array],default:""}},data:()=>({show:!1,weeks:[],calendar:{},nowDate:{},aniMaskShow:!1,firstEnter:!0,time:"",timeRange:{startTime:"",endTime:""},tempSingleDate:"",tempRange:{before:"",after:""}}),watch:{date:{immediate:!0,handler(e){this.range||(this.tempSingleDate=e,setTimeout((()=>{this.init(e)}),100))}},defTime:{immediate:!0,handler(e){this.range?(this.timeRange.startTime=e.start,this.timeRange.endTime=e.end):this.time=e}},startDate(e){this.cale&&(this.cale.setStartDate(e),this.cale.setDate(this.nowDate.fullDate),this.weeks=this.cale.weeks)},endDate(e){this.cale&&(this.cale.setEndDate(e),this.cale.setDate(this.nowDate.fullDate),this.weeks=this.cale.weeks)},selected(e){this.cale&&(this.cale.setSelectInfo(this.nowDate.fullDate,e),this.weeks=this.cale.weeks)},pleStatus:{immediate:!0,handler(e){const{before:t,after:a,fulldate:n,which:i}=e;this.tempRange.before=t,this.tempRange.after=a,setTimeout((()=>{if(n)if(this.cale.setHoverMultiple(n),t&&a){if(this.cale.lastHover=!0,this.rangeWithinMonth(a,t))return;this.setDate(t)}else this.cale.setMultiple(n),this.setDate(this.nowDate.fullDate),this.calendar.fullDate="",this.cale.lastHover=!1;else{if(!this.cale)return;this.cale.setDefaultMultiple(t,a),"left"===i&&t?(this.setDate(t),this.weeks=this.cale.weeks):a&&(this.setDate(a),this.weeks=this.cale.weeks),this.cale.lastHover=!0}}),16)}}},computed:{timepickerStartTime(){return(this.range?this.tempRange.before:this.calendar.fullDate)===this.startDate?this.selectableTimes.start:""},timepickerEndTime(){return(this.range?this.tempRange.after:this.calendar.fullDate)===this.endDate?this.selectableTimes.end:""},selectDateText:()=>or("uni-datetime-picker.selectDate"),startDateText(){return this.startPlaceholder||or("uni-datetime-picker.startDate")},endDateText(){return this.endPlaceholder||or("uni-datetime-picker.endDate")},okText:()=>or("uni-datetime-picker.ok"),yearText:()=>or("uni-datetime-picker.year"),monthText:()=>or("uni-datetime-picker.month"),MONText:()=>or("uni-calender.MON"),TUEText:()=>or("uni-calender.TUE"),WEDText:()=>or("uni-calender.WED"),THUText:()=>or("uni-calender.THU"),FRIText:()=>or("uni-calender.FRI"),SATText:()=>or("uni-calender.SAT"),SUNText:()=>or("uni-calender.SUN"),confirmText:()=>or("uni-calender.confirm")},created(){this.cale=new class{constructor({selected:e,startDate:t,endDate:a,range:n}={}){this.date=this.getDateObj(new Date),this.selected=e||[],this.startDate=t,this.endDate=a,this.range=n,this.cleanMultipleStatus(),this.weeks={},this.lastHover=!1}setDate(e){const t=this.getDateObj(e);this.getWeeks(t.fullDate)}cleanMultipleStatus(){this.multipleStatus={before:"",after:"",data:[]}}setStartDate(e){this.startDate=e}setEndDate(e){this.endDate=e}getPreMonthObj(e){e=Zl(e);const t=(e=new Date(e)).getMonth();e.setMonth(t-1);const a=e.getMonth();return 0!==t&&a-t==0&&e.setMonth(a-1),this.getDateObj(e)}getNextMonthObj(e){e=Zl(e);const t=(e=new Date(e)).getMonth();e.setMonth(t+1);const a=e.getMonth();return a-t>1&&e.setMonth(a-1),this.getDateObj(e)}getDateObj(e){return e=Zl(e),{fullDate:Wl(e=new Date(e)),year:e.getFullYear(),month:Gl(e.getMonth()+1),date:Gl(e.getDate()),day:e.getDay()}}getPreMonthDays(e,t){const a=[];for(let n=e-1;n>=0;n--){const e=t.month-1;a.push({date:new Date(t.year,e,-n).getDate(),month:e,disable:!0})}return a}getCurrentMonthDays(e,t){const a=[],n=this.date.fullDate;for(let i=1;i<=e;i++){const e=`${t.year}-${t.month}-${Gl(i)}`,o=n===e,s=this.selected&&this.selected.find((t=>{if(this.dateEqual(e,t.date))return t}));this.startDate&&Ql(this.startDate,e),this.endDate&&Ql(e,this.endDate);let l=this.multipleStatus.data,r=-1;this.range&&l&&(r=l.findIndex((t=>this.dateEqual(t,e))));const c=-1!==r;a.push({fullDate:e,year:t.year,date:i,multiple:!!this.range&&c,beforeMultiple:this.isLogicBefore(e,this.multipleStatus.before,this.multipleStatus.after),afterMultiple:this.isLogicAfter(e,this.multipleStatus.before,this.multipleStatus.after),month:t.month,disable:this.startDate&&!Ql(this.startDate,e)||this.endDate&&!Ql(e,this.endDate),isToday:o,userChecked:!1,extraInfo:s})}return a}_getNextMonthDays(e,t){const a=[],n=t.month+1;for(let i=1;i<=e;i++)a.push({date:i,month:n,disable:!0});return a}getInfo(e){e||(e=new Date);return this.calendar.find((t=>t.fullDate===this.getDateObj(e).fullDate))||this.getDateObj(e)}dateEqual(e,t){return e=new Date(Zl(e)),t=new Date(Zl(t)),e.valueOf()===t.valueOf()}isLogicBefore(e,t,a){let n=t;return t&&a&&(n=Ql(t,a)?t:a),this.dateEqual(n,e)}isLogicAfter(e,t,a){let n=a;return t&&a&&(n=Ql(t,a)?a:t),this.dateEqual(n,e)}geDateAll(e,t){var a=[],n=e.split("-"),i=t.split("-"),o=new Date;o.setFullYear(n[0],n[1]-1,n[2]);var s=new Date;s.setFullYear(i[0],i[1]-1,i[2]);for(var l=o.getTime()-864e5,r=s.getTime()-864e5,c=l;c<=r;)c+=864e5,a.push(this.getDateObj(new Date(parseInt(c))).fullDate);return a}setMultiple(e){if(!this.range)return;let{before:t,after:a}=this.multipleStatus;if(t&&a){if(!this.lastHover)return void(this.lastHover=!0);this.multipleStatus.before=e,this.multipleStatus.after="",this.multipleStatus.data=[],this.multipleStatus.fulldate="",this.lastHover=!1}else t?(this.multipleStatus.after=e,Ql(this.multipleStatus.before,this.multipleStatus.after)?this.multipleStatus.data=this.geDateAll(this.multipleStatus.before,this.multipleStatus.after):this.multipleStatus.data=this.geDateAll(this.multipleStatus.after,this.multipleStatus.before),this.lastHover=!0):(this.multipleStatus.before=e,this.multipleStatus.after=void 0,this.lastHover=!1);this.getWeeks(e)}setHoverMultiple(e){if(!this.range||this.lastHover)return;const{before:t}=this.multipleStatus;t?(this.multipleStatus.after=e,Ql(this.multipleStatus.before,this.multipleStatus.after)?this.multipleStatus.data=this.geDateAll(this.multipleStatus.before,this.multipleStatus.after):this.multipleStatus.data=this.geDateAll(this.multipleStatus.after,this.multipleStatus.before)):this.multipleStatus.before=e,this.getWeeks(e)}setDefaultMultiple(e,t){this.multipleStatus.before=e,this.multipleStatus.after=t,e&&t&&(Ql(e,t)?(this.multipleStatus.data=this.geDateAll(e,t),this.getWeeks(t)):(this.multipleStatus.data=this.geDateAll(t,e),this.getWeeks(e)))}getWeeks(e){const{year:t,month:a}=this.getDateObj(e),n=new Date(t,a-1,1).getDay(),i=this.getPreMonthDays(n,this.getDateObj(e)),o=new Date(t,a,0).getDate(),s=42-n-o,l=[...i,...this.getCurrentMonthDays(o,this.getDateObj(e)),...this._getNextMonthDays(s,this.getDateObj(e))],r=new Array(6);for(let c=0;c<l.length;c++){const e=Math.floor(c/7);r[e]||(r[e]=new Array(7)),r[e][c%7]=l[c]}this.calendar=l,this.weeks=r}}({selected:this.selected,startDate:this.startDate,endDate:this.endDate,range:this.range}),this.init(this.date)},methods:{leaveCale(){this.firstEnter=!0},handleMouse(e){if(e.disable)return;if(this.cale.lastHover)return;let{before:t,after:a}=this.cale.multipleStatus;t&&(this.calendar=e,this.cale.setHoverMultiple(this.calendar.fullDate),this.weeks=this.cale.weeks,this.firstEnter&&(this.$emit("firstEnterCale",this.cale.multipleStatus),this.firstEnter=!1))},rangeWithinMonth(e,t){const[a,n]=e.split("-"),[i,o]=t.split("-");return a===i&&n===o},maskClick(){this.close(),this.$emit("maskClose")},clearCalender(){this.range?(this.timeRange.startTime="",this.timeRange.endTime="",this.tempRange.before="",this.tempRange.after="",this.cale.multipleStatus.before="",this.cale.multipleStatus.after="",this.cale.multipleStatus.data=[],this.cale.lastHover=!1):(this.time="",this.tempSingleDate=""),this.calendar.fullDate="",this.setDate(new Date)},bindDateChange(e){const t=e.detail.value+"-1";this.setDate(t)},init(e){if(this.cale&&(this.cale.setDate(e||new Date),this.weeks=this.cale.weeks,this.nowDate=this.cale.getInfo(e),this.calendar={...this.nowDate},!e&&(this.calendar.fullDate="",this.defaultValue&&!this.range))){const e=new Date(this.defaultValue),t=Wl(e),a=e.getFullYear(),n=e.getMonth()+1,i=e.getDate(),o=e.getDay();this.calendar={fullDate:t,year:a,month:n,date:i,day:o},this.tempSingleDate=t,this.time=Jl(e,this.hideSecond)}},open(){this.clearDate&&!this.insert&&(this.cale.cleanMultipleStatus(),this.init(this.date)),this.show=!0,this.$nextTick((()=>{setTimeout((()=>{this.aniMaskShow=!0}),50)}))},close(){this.aniMaskShow=!1,this.$nextTick((()=>{setTimeout((()=>{this.show=!1,this.$emit("close")}),300)}))},confirm(){this.setEmit("confirm"),this.close()},change(e){(this.insert||e)&&this.setEmit("change")},monthSwitch(){let{year:e,month:t}=this.nowDate;this.$emit("monthSwitch",{year:e,month:Number(t)})},setEmit(e){this.range||(this.calendar.fullDate||(this.calendar=this.cale.getInfo(new Date),this.tempSingleDate=this.calendar.fullDate),this.hasTime&&!this.time&&(this.time=Jl(new Date,this.hideSecond)));let{year:t,month:a,date:n,fullDate:i,extraInfo:o}=this.calendar;this.$emit(e,{range:this.cale.multipleStatus,year:t,month:a,date:n,time:this.time,timeRange:this.timeRange,fulldate:i,extraInfo:o||{}})},choiceDate(e){if(e.disable)return;this.calendar=e,this.calendar.userChecked=!0,this.cale.setMultiple(this.calendar.fullDate,!0),this.weeks=this.cale.weeks,this.tempSingleDate=this.calendar.fullDate;const t=new Date(this.cale.multipleStatus.before).getTime(),a=new Date(this.cale.multipleStatus.after).getTime();t>a&&a?(this.tempRange.before=this.cale.multipleStatus.after,this.tempRange.after=this.cale.multipleStatus.before):(this.tempRange.before=this.cale.multipleStatus.before,this.tempRange.after=this.cale.multipleStatus.after),this.change(!0)},changeMonth(e){let t;"pre"===e?t=this.cale.getPreMonthObj(this.nowDate.fullDate).fullDate:"next"===e&&(t=this.cale.getNextMonthObj(this.nowDate.fullDate).fullDate),this.setDate(t),this.monthSwitch()},setDate(e){this.cale.setDate(e),this.weeks=this.cale.weeks,this.nowDate=this.cale.getInfo(e)}}};const lr={name:"UniDatetimePicker",options:{virtualHost:!0},components:{Calendar:t(sr,[["render",function(t,a,n,o,s,l){const r=e.resolveComponent("calendar-item"),c=e.resolveComponent("time-picker"),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-calendar",onMouseleave:a[9]||(a[9]=(...e)=>l.leaveCale&&l.leaveCale(...e))},[!n.insert&&s.show?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-calendar__mask",{"uni-calendar--mask-show":s.aniMaskShow}]),onClick:a[0]||(a[0]=(...e)=>l.maskClick&&l.maskClick(...e))},null,2)):e.createCommentVNode("",!0),n.insert||s.show?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["uni-calendar__content",{"uni-calendar--fixed":!n.insert,"uni-calendar--ani-show":s.aniMaskShow,"uni-calendar__content-mobile":s.aniMaskShow}])},[e.createElementVNode("view",{class:e.normalizeClass(["uni-calendar__header",{"uni-calendar__header-mobile":!n.insert}])},[e.createElementVNode("view",{class:"uni-calendar__header-btn-box",onClick:a[1]||(a[1]=e.withModifiers((e=>l.changeMonth("pre")),["stop"]))},[e.createElementVNode("view",{class:"uni-calendar__header-btn uni-calendar--left"})]),e.createElementVNode("picker",{mode:"date",value:n.date,fields:"month",onChange:a[2]||(a[2]=(...e)=>l.bindDateChange&&l.bindDateChange(...e))},[e.createElementVNode("text",{class:"uni-calendar__header-text"},e.toDisplayString((s.nowDate.year||"")+l.yearText+(s.nowDate.month||"")+l.monthText),1)],40,["value"]),e.createElementVNode("view",{class:"uni-calendar__header-btn-box",onClick:a[3]||(a[3]=e.withModifiers((e=>l.changeMonth("next")),["stop"]))},[e.createElementVNode("view",{class:"uni-calendar__header-btn uni-calendar--right"})]),n.insert?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"dialog-close",onClick:a[4]||(a[4]=(...e)=>l.maskClick&&l.maskClick(...e))},[e.createElementVNode("view",{class:"dialog-close-plus","data-id":"close"}),e.createElementVNode("view",{class:"dialog-close-plus dialog-close-rotate","data-id":"close"})]))],2),e.createElementVNode("view",{class:"uni-calendar__box"},[n.showMonth?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-calendar__box-bg"},[e.createElementVNode("text",{class:"uni-calendar__box-bg-text"},e.toDisplayString(s.nowDate.month),1)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-calendar__weeks",style:{"padding-bottom":"7px"}},[e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.SUNText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.MONText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.TUEText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.WEDText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.THUText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.FRIText),1)]),e.createElementVNode("view",{class:"uni-calendar__weeks-day"},[e.createElementVNode("text",{class:"uni-calendar__weeks-day-text"},e.toDisplayString(l.SATText),1)])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.weeks,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-calendar__weeks",key:a},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-calendar__weeks-item",key:a},[e.createVNode(r,{class:"uni-calendar-item--hook",weeks:t,calendar:s.calendar,selected:n.selected,checkHover:n.range,onChange:l.choiceDate,onHandleMouse:l.handleMouse},null,8,["weeks","calendar","selected","checkHover","onChange","onHandleMouse"])])))),128))])))),128))]),n.insert||n.range||!n.hasTime?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-date-changed uni-calendar--fixed-top",style:{padding:"0 80px"}},[e.createElementVNode("view",{class:"uni-date-changed--time-date"},e.toDisplayString(s.tempSingleDate?s.tempSingleDate:l.selectDateText),1),e.createVNode(c,{type:"time",start:l.timepickerStartTime,end:l.timepickerEndTime,modelValue:s.time,"onUpdate:modelValue":a[5]||(a[5]=e=>s.time=e),disabled:!s.tempSingleDate,border:!1,"hide-second":n.hideSecond,class:"time-picker-style"},null,8,["start","end","modelValue","disabled","hide-second"])])),!n.insert&&n.range&&n.hasTime?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-date-changed uni-calendar--fixed-top"},[e.createElementVNode("view",{class:"uni-date-changed--time-start"},[e.createElementVNode("view",{class:"uni-date-changed--time-date"},e.toDisplayString(s.tempRange.before?s.tempRange.before:l.startDateText),1),e.createVNode(c,{type:"time",start:l.timepickerStartTime,modelValue:s.timeRange.startTime,"onUpdate:modelValue":a[6]||(a[6]=e=>s.timeRange.startTime=e),border:!1,"hide-second":n.hideSecond,disabled:!s.tempRange.before,class:"time-picker-style"},null,8,["start","modelValue","hide-second","disabled"])]),e.createElementVNode("view",{style:{"line-height":"50px"}},[e.createVNode(d,{type:"arrowthinright",color:"#999"})]),e.createElementVNode("view",{class:"uni-date-changed--time-end"},[e.createElementVNode("view",{class:"uni-date-changed--time-date"},e.toDisplayString(s.tempRange.after?s.tempRange.after:l.endDateText),1),e.createVNode(c,{type:"time",end:l.timepickerEndTime,modelValue:s.timeRange.endTime,"onUpdate:modelValue":a[7]||(a[7]=e=>s.timeRange.endTime=e),border:!1,"hide-second":n.hideSecond,disabled:!s.tempRange.after,class:"time-picker-style"},null,8,["end","modelValue","hide-second","disabled"])])])):e.createCommentVNode("",!0),n.insert?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-date-changed uni-date-btn--ok"},[e.createElementVNode("view",{class:"uni-datetime-picker--btn",onClick:a[8]||(a[8]=(...e)=>l.confirm&&l.confirm(...e))},e.toDisplayString(l.confirmText),1)]))],2)):e.createCommentVNode("",!0)],32)}],["__scopeId","data-v-24c3b263"]]),TimePicker:ir},data:()=>({isRange:!1,hasTime:!1,displayValue:"",inputDate:"",calendarDate:"",pickerTime:"",calendarRange:{startDate:"",startTime:"",endDate:"",endTime:""},displayRangeValue:{startDate:"",endDate:""},tempRange:{startDate:"",startTime:"",endDate:"",endTime:""},startMultipleStatus:{before:"",after:"",data:[],fulldate:""},endMultipleStatus:{before:"",after:"",data:[],fulldate:""},pickerVisible:!1,pickerPositionStyle:null,isEmitValue:!1,isPhone:!1,isFirstShow:!0,i18nT:()=>{}}),props:{type:{type:String,default:"datetime"},value:{type:[String,Number,Array,Date],default:""},modelValue:{type:[String,Number,Array,Date],default:""},start:{type:[Number,String],default:""},end:{type:[Number,String],default:""},returnType:{type:String,default:"string"},placeholder:{type:String,default:""},startPlaceholder:{type:String,default:""},endPlaceholder:{type:String,default:""},rangeSeparator:{type:String,default:"-"},border:{type:[Boolean],default:!0},disabled:{type:[Boolean],default:!1},clearIcon:{type:[Boolean],default:!0},hideSecond:{type:[Boolean],default:!1},defaultValue:{type:[String,Object,Array],default:""}},watch:{type:{immediate:!0,handler(e){this.hasTime=-1!==e.indexOf("time"),this.isRange=-1!==e.indexOf("range")}},modelValue:{immediate:!0,handler(e){this.isEmitValue?this.isEmitValue=!1:this.initPicker(e)}},start:{immediate:!0,handler(e){e&&(this.calendarRange.startDate=Wl(e),this.hasTime&&(this.calendarRange.startTime=Jl(e)))}},end:{immediate:!0,handler(e){e&&(this.calendarRange.endDate=Wl(e),this.hasTime&&(this.calendarRange.endTime=Jl(e,this.hideSecond)))}}},computed:{timepickerStartTime(){return(this.isRange?this.tempRange.startDate:this.inputDate)===this.calendarRange.startDate?this.calendarRange.startTime:""},timepickerEndTime(){return(this.isRange?this.tempRange.endDate:this.inputDate)===this.calendarRange.endDate?this.calendarRange.endTime:""},mobileCalendarTime(){const e={start:this.tempRange.startTime,end:this.tempRange.endTime};return this.isRange?e:this.pickerTime},mobSelectableTime(){return{start:this.calendarRange.startTime,end:this.calendarRange.endTime}},datePopupWidth(){return this.isRange?653:301},singlePlaceholderText(){return this.placeholder||("date"===this.type?this.selectDateText:this.selectDateTimeText)},startPlaceholderText(){return this.startPlaceholder||this.startDateText},endPlaceholderText(){return this.endPlaceholder||this.endDateText},selectDateText(){return this.i18nT("uni-datetime-picker.selectDate")},selectDateTimeText(){return this.i18nT("uni-datetime-picker.selectDateTime")},selectTimeText(){return this.i18nT("uni-datetime-picker.selectTime")},startDateText(){return this.startPlaceholder||this.i18nT("uni-datetime-picker.startDate")},startTimeText(){return this.i18nT("uni-datetime-picker.startTime")},endDateText(){return this.endPlaceholder||this.i18nT("uni-datetime-picker.endDate")},endTimeText(){return this.i18nT("uni-datetime-picker.endTime")},okText(){return this.i18nT("uni-datetime-picker.ok")},clearText(){return this.i18nT("uni-datetime-picker.clear")},showClearIcon(){return this.clearIcon&&!this.disabled&&(this.displayValue||this.displayRangeValue.startDate&&this.displayRangeValue.endDate)}},created(){this.initI18nT(),this.platform()},methods:{initI18nT(){const e=Rl(tr);this.i18nT=e.t},initPicker(e){if(!e&&!this.defaultValue||Array.isArray(e)&&!e.length)this.$nextTick((()=>{this.clear(!1)}));else if(Array.isArray(e)||this.isRange){const[t,a]=e;if(!t&&!a)return;const n=Wl(t),i=Jl(t,this.hideSecond),o=Wl(a),s=Jl(a,this.hideSecond),l=n,r=o;this.displayRangeValue.startDate=this.tempRange.startDate=l,this.displayRangeValue.endDate=this.tempRange.endDate=r,this.hasTime&&(this.displayRangeValue.startDate=`${n} ${i}`,this.displayRangeValue.endDate=`${o} ${s}`,this.tempRange.startTime=i,this.tempRange.endTime=s);const c={before:n,after:o};this.startMultipleStatus=Object.assign({},this.startMultipleStatus,c,{which:"right"}),this.endMultipleStatus=Object.assign({},this.endMultipleStatus,c,{which:"left"})}else e?(this.displayValue=this.inputDate=this.calendarDate=Wl(e),this.hasTime&&(this.pickerTime=Jl(e,this.hideSecond),this.displayValue=`${this.displayValue} ${this.pickerTime}`)):this.defaultValue&&(this.inputDate=this.calendarDate=Wl(this.defaultValue),this.hasTime&&(this.pickerTime=Jl(this.defaultValue,this.hideSecond)))},updateLeftCale(e){const t=this.$refs.left;t.cale.setHoverMultiple(e.after),t.setDate(this.$refs.left.nowDate.fullDate)},updateRightCale(e){const t=this.$refs.right;t.cale.setHoverMultiple(e.after),t.setDate(this.$refs.right.nowDate.fullDate)},platform(){if("undefined"!=typeof navigator)return void(this.isPhone=-1!==navigator.userAgent.toLowerCase().indexOf("mobile"));const{windowWidth:e}=uni.getSystemInfoSync();this.isPhone=e<=500,this.windowWidth=e},show(){if(this.$emit("show"),this.disabled)return;if(this.platform(),this.isPhone)return void setTimeout((()=>{this.$refs.mobile.open()}),0);this.pickerPositionStyle={top:"10px"};uni.createSelectorQuery().in(this).select(".uni-date-editor").boundingClientRect((e=>{this.windowWidth-e.left<this.datePopupWidth&&(this.pickerPositionStyle.right=0)})).exec(),setTimeout((()=>{if(this.pickerVisible=!this.pickerVisible,!this.isPhone&&this.isRange&&this.isFirstShow){this.isFirstShow=!1;const{startDate:e,endDate:t}=this.calendarRange;e&&t?this.diffDate(e,t)<30&&this.$refs.right.changeMonth("pre"):this.isPhone&&(this.$refs.right.cale.lastHover=!1)}}),50)},close(){setTimeout((()=>{this.pickerVisible=!1,this.$emit("maskClick",this.value),this.$refs.mobile&&this.$refs.mobile.close()}),20)},setEmit(e){"timestamp"!==this.returnType&&"date"!==this.returnType||(Array.isArray(e)?(this.hasTime||(e[0]=e[0]+" 00:00:00",e[1]=e[1]+" 00:00:00"),e[0]=this.createTimestamp(e[0]),e[1]=this.createTimestamp(e[1]),"date"===this.returnType&&(e[0]=new Date(e[0]),e[1]=new Date(e[1]))):(this.hasTime||(e+=" 00:00:00"),e=this.createTimestamp(e),"date"===this.returnType&&(e=new Date(e)))),this.$emit("update:modelValue",e),this.$emit("input",e),this.$emit("change",e),this.isEmitValue=!0},createTimestamp:e=>(e=Zl(e),Date.parse(new Date(e))),singleChange(e){this.calendarDate=this.inputDate=e.fulldate,this.hasTime||this.confirmSingleChange()},confirmSingleChange(){if(!Yl(this.inputDate)){const e=new Date;this.calendarDate=this.inputDate=Wl(e),this.pickerTime=Jl(e,this.hideSecond)}let e,t,a=!1;if(this.start){let n=this.start;"number"==typeof this.start&&(n=Hl(this.start,this.hideSecond)),[e,t]=n.split(" "),this.start&&!Ql(e,this.inputDate)&&(a=!0,this.inputDate=e)}let n,i,o=!1;if(this.end){let e=this.end;"number"==typeof this.end&&(e=Hl(this.end,this.hideSecond)),[n,i]=e.split(" "),this.end&&!Ql(this.inputDate,n)&&(o=!0,this.inputDate=n)}this.hasTime?(a&&(this.pickerTime=t||Kl(this.hideSecond)),o&&(this.pickerTime=i||Kl(this.hideSecond)),this.pickerTime||(this.pickerTime=Jl(Date.now(),this.hideSecond)),this.displayValue=`${this.inputDate} ${this.pickerTime}`):this.displayValue=this.inputDate,this.setEmit(this.displayValue),this.pickerVisible=!1},leftChange(e){const{before:t,after:a}=e.range;this.rangeChange(t,a);const n={before:e.range.before,after:e.range.after,data:e.range.data,fulldate:e.fulldate};this.startMultipleStatus=Object.assign({},this.startMultipleStatus,n),this.$emit("calendarClick",e)},rightChange(e){const{before:t,after:a}=e.range;this.rangeChange(t,a);const n={before:e.range.before,after:e.range.after,data:e.range.data,fulldate:e.fulldate};this.endMultipleStatus=Object.assign({},this.endMultipleStatus,n),this.$emit("calendarClick",e)},mobileChange(e){if(this.isRange){const{before:t,after:a}=e.range;if(!t)return;if(this.handleStartAndEnd(t,a,!0),this.hasTime){const{startTime:t,endTime:a}=e.timeRange;this.tempRange.startTime=t,this.tempRange.endTime=a}this.confirmRangeChange()}else this.hasTime?this.displayValue=e.fulldate+" "+e.time:this.displayValue=e.fulldate,this.setEmit(this.displayValue);this.$refs.mobile.close()},rangeChange(e,t){e&&t&&(this.handleStartAndEnd(e,t,!0),this.hasTime||this.confirmRangeChange())},confirmRangeChange(){if(!this.tempRange.startDate||!this.tempRange.endDate)return void(this.pickerVisible=!1);let e,t;Yl(this.tempRange.startDate)||(this.tempRange.startDate=Wl(Date.now())),Yl(this.tempRange.endDate)||(this.tempRange.endDate=Wl(Date.now()));let a,n,i=!1,o=!1;if(this.start){let e=this.start;"number"==typeof this.start&&(e=Hl(this.start,this.hideSecond)),[a,n]=e.split(" "),this.start&&!Ql(this.start,`${this.tempRange.startDate} ${this.tempRange.startTime}`)&&(i=!0,this.tempRange.startDate=a),this.start&&!Ql(this.start,`${this.tempRange.endDate} ${this.tempRange.endTime}`)&&(o=!0,this.tempRange.endDate=a)}let s,l,r=!1,c=!1;if(this.end){let e=this.end;"number"==typeof this.end&&(e=Hl(this.end,this.hideSecond)),[s,l]=e.split(" "),this.end&&!Ql(`${this.tempRange.startDate} ${this.tempRange.startTime}`,this.end)&&(r=!0,this.tempRange.startDate=s),this.end&&!Ql(`${this.tempRange.endDate} ${this.tempRange.endTime}`,this.end)&&(c=!0,this.tempRange.endDate=s)}this.hasTime?(i?this.tempRange.startTime=n||Kl(this.hideSecond):r&&(this.tempRange.startTime=l||Kl(this.hideSecond)),this.tempRange.startTime||(this.tempRange.startTime=Jl(Date.now(),this.hideSecond)),o?this.tempRange.endTime=n||Kl(this.hideSecond):c&&(this.tempRange.endTime=l||Kl(this.hideSecond)),this.tempRange.endTime||(this.tempRange.endTime=Jl(Date.now(),this.hideSecond)),e=this.displayRangeValue.startDate=`${this.tempRange.startDate} ${this.tempRange.startTime}`,t=this.displayRangeValue.endDate=`${this.tempRange.endDate} ${this.tempRange.endTime}`):(e=this.displayRangeValue.startDate=this.tempRange.startDate,t=this.displayRangeValue.endDate=this.tempRange.endDate),Ql(e,t)||([e,t]=[t,e]),this.displayRangeValue.startDate=e,this.displayRangeValue.endDate=t;const d=[e,t];this.setEmit(d),this.pickerVisible=!1},handleStartAndEnd(e,t,a=!1){if(!e)return;t||(t=e);const n=a?"tempRange":"range",i=Ql(e,t);this[n].startDate=i?e:t,this[n].endDate=i?t:e},dateCompare:(e,t)=>(e=new Date(e.replace("-","/").replace("-","/")))<=(t=new Date(t.replace("-","/").replace("-","/"))),diffDate(e,t){e=new Date(e.replace("-","/").replace("-","/"));const a=((t=new Date(t.replace("-","/").replace("-","/")))-e)/864e5;return Math.abs(a)},clear(e=!0){this.isRange?(this.displayRangeValue.startDate="",this.displayRangeValue.endDate="",this.tempRange.startDate="",this.tempRange.startTime="",this.tempRange.endDate="",this.tempRange.endTime="",this.isPhone?this.$refs.mobile&&this.$refs.mobile.clearCalender():(this.$refs.left&&this.$refs.left.clearCalender(),this.$refs.right&&this.$refs.right.clearCalender(),this.$refs.right&&this.$refs.right.changeMonth("next")),e&&(this.$emit("change",[]),this.$emit("input",[]),this.$emit("update:modelValue",[]))):(this.displayValue="",this.inputDate="",this.pickerTime="",this.isPhone?this.$refs.mobile&&this.$refs.mobile.clearCalender():this.$refs.pcSingle&&this.$refs.pcSingle.clearCalender(),e&&(this.$emit("change",""),this.$emit("input",""),this.$emit("update:modelValue","")))},calendarClick(e){this.$emit("calendarClick",e)}}};const rr=t(lr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g),c=e.resolveComponent("time-picker"),d=e.resolveComponent("Calendar");return e.openBlock(),e.createElementBlock("view",{class:"uni-date"},[e.createElementVNode("view",{class:"uni-date-editor",onClick:a[1]||(a[1]=(...e)=>l.show&&l.show(...e))},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-date-editor--x",{"uni-date-editor--x__disabled":n.disabled,"uni-date-x--border":n.border}])},[s.isRange?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-date-x uni-date-range"},[e.createVNode(r,{class:"icon-calendar",type:"calendar",color:"#c0c4cc",size:"22"}),e.createElementVNode("view",{class:"uni-date__x-input text-center"},e.toDisplayString(s.displayRangeValue.startDate||l.startPlaceholderText),1),e.createElementVNode("view",{class:"range-separator"},e.toDisplayString(n.rangeSeparator),1),e.createElementVNode("view",{class:"uni-date__x-input text-center"},e.toDisplayString(s.displayRangeValue.endDate||l.endPlaceholderText),1)])):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-date-x uni-date-single"},[e.createVNode(r,{class:"icon-calendar",type:"calendar",color:"#c0c4cc",size:"22"}),e.createElementVNode("view",{class:"uni-date__x-input"},e.toDisplayString(s.displayValue||l.singlePlaceholderText),1)])),l.showClearIcon?(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-date__icon-clear",onClick:a[0]||(a[0]=e.withModifiers(((...e)=>l.clear&&l.clear(...e)),["stop"]))},[e.createVNode(r,{type:"clear",color:"#c0c4cc",size:"22"})])):e.createCommentVNode("",!0)],2)]),!0)]),e.withDirectives(e.createElementVNode("view",{class:"uni-date-mask--pc",onClick:a[2]||(a[2]=(...e)=>l.close&&l.close(...e))},null,512),[[e.vShow,s.pickerVisible]]),s.isPhone?e.createCommentVNode("",!0):e.withDirectives((e.openBlock(),e.createElementBlock("view",{key:0,ref:"datePicker",class:"uni-date-picker__container"},[s.isRange?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-date-range--x",style:e.normalizeStyle(s.pickerPositionStyle)},[e.createElementVNode("view",{class:"uni-popper__arrow"}),s.hasTime?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-x-header uni-date-changed"},[e.createElementVNode("view",{class:"popup-x-header--datetime"},[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input uni-date-range__input",type:"text","onUpdate:modelValue":a[7]||(a[7]=e=>s.tempRange.startDate=e),placeholder:l.startDateText},null,8,["placeholder"]),[[e.vModelText,s.tempRange.startDate]]),e.createVNode(c,{type:"time",modelValue:s.tempRange.startTime,"onUpdate:modelValue":a[9]||(a[9]=e=>s.tempRange.startTime=e),start:l.timepickerStartTime,border:!1,disabled:!s.tempRange.startDate,hideSecond:n.hideSecond},{default:e.withCtx((()=>[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input uni-date-range__input",type:"text","onUpdate:modelValue":a[8]||(a[8]=e=>s.tempRange.startTime=e),placeholder:l.startTimeText,disabled:!s.tempRange.startDate},null,8,["placeholder","disabled"]),[[e.vModelText,s.tempRange.startTime]])])),_:1},8,["modelValue","start","disabled","hideSecond"])]),e.createVNode(r,{type:"arrowthinright",color:"#999",style:{"line-height":"40px"}}),e.createElementVNode("view",{class:"popup-x-header--datetime"},[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input uni-date-range__input",type:"text","onUpdate:modelValue":a[10]||(a[10]=e=>s.tempRange.endDate=e),placeholder:l.endDateText},null,8,["placeholder"]),[[e.vModelText,s.tempRange.endDate]]),e.createVNode(c,{type:"time",modelValue:s.tempRange.endTime,"onUpdate:modelValue":a[12]||(a[12]=e=>s.tempRange.endTime=e),end:l.timepickerEndTime,border:!1,disabled:!s.tempRange.endDate,hideSecond:n.hideSecond},{default:e.withCtx((()=>[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input uni-date-range__input",type:"text","onUpdate:modelValue":a[11]||(a[11]=e=>s.tempRange.endTime=e),placeholder:l.endTimeText,disabled:!s.tempRange.endDate},null,8,["placeholder","disabled"]),[[e.vModelText,s.tempRange.endTime]])])),_:1},8,["modelValue","end","disabled","hideSecond"])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"popup-x-body"},[e.createVNode(d,{ref:"left",showMonth:!1,"start-date":s.calendarRange.startDate,"end-date":s.calendarRange.endDate,range:!0,pleStatus:s.endMultipleStatus,onChange:l.leftChange,onFirstEnterCale:l.updateRightCale,style:{padding:"0 8px"}},null,8,["start-date","end-date","pleStatus","onChange","onFirstEnterCale"]),e.createVNode(d,{ref:"right",showMonth:!1,"start-date":s.calendarRange.startDate,"end-date":s.calendarRange.endDate,range:!0,onChange:l.rightChange,pleStatus:s.startMultipleStatus,onFirstEnterCale:l.updateLeftCale,style:{padding:"0 8px","border-left":"1px solid #F1F1F1"}},null,8,["start-date","end-date","onChange","pleStatus","onFirstEnterCale"])]),s.hasTime?(e.openBlock(),e.createElementBlock("view",{key:1,class:"popup-x-footer"},[e.createElementVNode("text",{onClick:a[13]||(a[13]=(...e)=>l.clear&&l.clear(...e))},e.toDisplayString(l.clearText),1),e.createElementVNode("text",{class:"confirm-text",onClick:a[14]||(a[14]=(...e)=>l.confirmRangeChange&&l.confirmRangeChange(...e))},e.toDisplayString(l.okText),1)])):e.createCommentVNode("",!0)],4)):(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-date-single--x",style:e.normalizeStyle(s.pickerPositionStyle)},[e.createElementVNode("view",{class:"uni-popper__arrow"}),s.hasTime?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-date-changed popup-x-header"},[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input text-center",type:"text","onUpdate:modelValue":a[3]||(a[3]=e=>s.inputDate=e),placeholder:l.selectDateText},null,8,["placeholder"]),[[e.vModelText,s.inputDate]]),e.createVNode(c,{type:"time",modelValue:s.pickerTime,"onUpdate:modelValue":a[5]||(a[5]=e=>s.pickerTime=e),border:!1,disabled:!s.inputDate,start:l.timepickerStartTime,end:l.timepickerEndTime,hideSecond:n.hideSecond,style:{width:"100%"}},{default:e.withCtx((()=>[e.withDirectives(e.createElementVNode("input",{class:"uni-date__input text-center",type:"text","onUpdate:modelValue":a[4]||(a[4]=e=>s.pickerTime=e),placeholder:l.selectTimeText,disabled:!s.inputDate},null,8,["placeholder","disabled"]),[[e.vModelText,s.pickerTime]])])),_:1},8,["modelValue","disabled","start","end","hideSecond"])])):e.createCommentVNode("",!0),e.createVNode(d,{ref:"pcSingle",showMonth:!1,"start-date":s.calendarRange.startDate,"end-date":s.calendarRange.endDate,date:s.calendarDate,onChange:l.singleChange,"default-value":n.defaultValue,style:{padding:"0 8px"}},null,8,["start-date","end-date","date","onChange","default-value"]),s.hasTime?(e.openBlock(),e.createElementBlock("view",{key:1,class:"popup-x-footer"},[e.createElementVNode("text",{class:"confirm-text",onClick:a[6]||(a[6]=(...e)=>l.confirmSingleChange&&l.confirmSingleChange(...e))},e.toDisplayString(l.okText),1)])):e.createCommentVNode("",!0)],4))],512)),[[e.vShow,s.pickerVisible]]),s.isPhone?(e.openBlock(),e.createBlock(d,{key:1,ref:"mobile",clearDate:!1,date:s.calendarDate,defTime:l.mobileCalendarTime,"start-date":s.calendarRange.startDate,"end-date":s.calendarRange.endDate,selectableTimes:l.mobSelectableTime,startPlaceholder:n.startPlaceholder,endPlaceholder:n.endPlaceholder,"default-value":n.defaultValue,pleStatus:s.endMultipleStatus,showMonth:!1,range:s.isRange,hasTime:s.hasTime,insert:!1,hideSecond:n.hideSecond,onConfirm:l.mobileChange,onMaskClose:l.close,onChange:l.calendarClick},null,8,["date","defTime","start-date","end-date","selectableTimes","startPlaceholder","endPlaceholder","default-value","pleStatus","range","hasTime","hideSecond","onConfirm","onMaskClose","onChange"])):e.createCommentVNode("",!0)])}],["__scopeId","data-v-9d07eb1e"]]),cr={props:{localdata:{type:[Array,Object],default:()=>[]},spaceInfo:{type:Object,default:()=>({})},collection:{type:String,default:""},action:{type:String,default:""},field:{type:String,default:""},orderby:{type:String,default:""},where:{type:[String,Object],default:""},pageData:{type:String,default:"add"},pageCurrent:{type:Number,default:1},pageSize:{type:Number,default:500},getcount:{type:[Boolean,String],default:!1},getone:{type:[Boolean,String],default:!1},gettree:{type:[Boolean,String],default:!1},manual:{type:Boolean,default:!1},value:{type:[Array,String,Number],default:()=>[]},modelValue:{type:[Array,String,Number],default:()=>[]},preload:{type:Boolean,default:!1},stepSearh:{type:Boolean,default:!0},selfField:{type:String,default:""},parentField:{type:String,default:""},multiple:{type:Boolean,default:!1},map:{type:Object,default:()=>({text:"text",value:"value"})}},data(){return{loading:!1,errorMessage:"",loadMore:{contentdown:"",contentrefresh:"",contentnomore:""},dataList:[],selected:[],selectedIndex:0,page:{current:this.pageCurrent,size:this.pageSize,count:0}}},computed:{isLocalData(){return!this.collection.length},isCloudData(){return this.collection.length>0},isCloudDataList(){return this.isCloudData&&!this.parentField&&!this.selfField},isCloudDataTree(){return this.isCloudData&&this.parentField&&this.selfField},dataValue(){return(Array.isArray(this.modelValue)?this.modelValue.length>0:null!==this.modelValue||void 0!==this.modelValue)?this.modelValue:this.value},hasValue(){return"number"==typeof this.dataValue||null!=this.dataValue&&this.dataValue.length>0}},created(){this.$watch((()=>{var e=[];return["pageCurrent","pageSize","spaceInfo","value","modelValue","localdata","collection","action","field","orderby","where","getont","getcount","gettree"].forEach((t=>{e.push(this[t])})),e}),((e,t)=>{for(let a=2;a<e.length&&e[a]==t[a];a++);e[0]!=t[0]&&(this.page.current=this.pageCurrent),this.page.size=this.pageSize,this.onPropsChange()})),this._treeData=[]},methods:{onPropsChange(){this._treeData=[]},async loadData(){this.isLocalData?this.loadLocalData():this.isCloudDataList?this.loadCloudDataList():this.isCloudDataTree&&this.loadCloudDataTree()},async loadLocalData(){this._treeData=[],this._extractTree(this.localdata,this._treeData);let e=this.dataValue;void 0!==e&&(Array.isArray(e)&&(e=e[e.length-1],"object"==typeof e&&e[this.map.value]&&(e=e[this.map.value])),this.selected=this._findNodePath(e,this.localdata))},async loadCloudDataList(){if(!this.loading){this.loading=!0;try{let e=(await this.getCommand()).result.data;this._treeData=e,this._updateBindData(),this._updateSelected(),this.onDataChange()}catch($i){this.errorMessage=$i}finally{this.loading=!1}}},async loadCloudDataTree(){if(!this.loading){this.loading=!0;try{let e={field:this._cloudDataPostField(),where:this._cloudDataTreeWhere()};this.gettree&&(e.startwith=`${this.selfField}=='${this.dataValue}'`);let t=(await this.getCommand(e)).result.data;this._treeData=t,this._updateBindData(),this._updateSelected(),this.onDataChange()}catch($i){this.errorMessage=$i}finally{this.loading=!1}}},async loadCloudDataNode(e){if(!this.loading){this.loading=!0;try{let t={field:this._cloudDataPostField(),where:this._cloudDataNodeWhere()};e((await this.getCommand(t)).result.data)}catch($i){this.errorMessage=$i}finally{this.loading=!1}}},getCloudDataValue(){return this.isCloudDataList?this.getCloudDataListValue():this.isCloudDataTree?this.getCloudDataTreeValue():void 0},getCloudDataListValue(){let e=[],t=this._getForeignKeyByField();return t&&e.push(`${t} == '${this.dataValue}'`),e=e.join(" || "),this.where&&(e=`(${this.where}) && (${e})`),this.getCommand({field:this._cloudDataPostField(),where:e}).then((e=>(this.selected=e.result.data,e.result.data)))},getCloudDataTreeValue(){return this.getCommand({field:this._cloudDataPostField(),getTreePath:{startWith:`${this.selfField}=='${this.dataValue}'`}}).then((e=>{let t=[];return this._extractTreePath(e.result.data,t),this.selected=t,t}))},getCommand(e={}){let t=Cl.database(this.spaceInfo);const a=e.action||this.action;a&&(t=t.action(a));const n=e.collection||this.collection;t=t.collection(n);const i=e.where||this.where;i&&Object.keys(i).length&&(t=t.where(i));const o=e.field||this.field;o&&(t=t.field(o));const s=e.orderby||this.orderby;s&&(t=t.orderBy(s));const l=void 0!==e.pageCurrent?e.pageCurrent:this.page.current,r=void 0!==e.pageSize?e.pageSize:this.page.size,c={getCount:void 0!==e.getcount?e.getcount:this.getcount,getTree:void 0!==e.gettree?e.gettree:this.gettree};return e.getTreePath&&(c.getTreePath=e.getTreePath),t=t.skip(r*(l-1)).limit(r).get(c),t},_cloudDataPostField(){let e=[this.field];return this.parentField&&e.push(`${this.parentField} as parent_value`),e.join(",")},_cloudDataTreeWhere(){let e=[],t=this.selected,a=this.parentField;if(a&&e.push(`${a} == null || ${a} == ""`),t.length)for(var n=0;n<t.length-1;n++)e.push(`${a} == '${t[n].value}'`);let i=[];return this.where&&i.push(`(${this.where})`),e.length&&i.push(`(${e.join(" || ")})`),i.join(" && ")},_cloudDataNodeWhere(){let e=[],t=this.selected;return t.length&&e.push(`${this.parentField} == '${t[t.length-1].value}'`),e=e.join(" || "),this.where?`(${this.where}) && (${e})`:e},_getWhereByForeignKey(){let e=[],t=this._getForeignKeyByField();return t&&e.push(`${t} == '${this.dataValue}'`),this.where?`(${this.where}) && (${e.join(" || ")})`:e.join(" || ")},_getForeignKeyByField(){let e=this.field.split(","),t=null;for(let a=0;a<e.length;a++){const n=e[a].split("as");if(!(n.length<2)&&"value"===n[1].trim()){t=n[0].trim();break}}return t},_updateBindData(e){const{dataList:t,hasNodes:a}=this._filterData(this._treeData,this.selected);let n=!1===this._stepSearh&&!a;return e&&(e.isleaf=n),this.dataList=t,this.selectedIndex=t.length-1,!n&&this.selected.length<t.length&&this.selected.push({value:null,text:"请选择"}),{isleaf:n,hasNodes:a}},_updateSelected(){let e=this.dataList,t=this.selected,a=this.map.text,n=this.map.value;for(let i=0;i<t.length;i++){let o=t[i].value,s=e[i];for(let e=0;e<s.length;e++){let l=s[e];if(l[n]===o){t[i].text=l[a];break}}}},_filterData(e,t){let a=[],n=!0;a.push(e.filter((e=>null===e.parent_value||void 0===e.parent_value||""===e.parent_value)));for(let i=0;i<t.length;i++){let o=t[i].value,s=e.filter((e=>e.parent_value===o));s.length?a.push(s):n=!1}return{dataList:a,hasNodes:n}},_extractTree(e,t,a){let n=this.map.value;for(let i=0;i<e.length;i++){let o=e[i],s={};for(let e in o)"children"!==e&&(s[e]=o[e]);null!=a&&""!==a&&(s.parent_value=a),t.push(s);let l=o.children;l&&this._extractTree(l,t,o[n])}},_extractTreePath(e,t){for(let a=0;a<e.length;a++){let n=e[a],i={};for(let e in n)"children"!==e&&(i[e]=n[e]);t.push(i);let o=n.children;o&&this._extractTreePath(o,t)}},_findNodePath(e,t,a=[]){let n=this.map.text,i=this.map.value;for(let o=0;o<t.length;o++){let s=t[o],l=s.children,r=s[n],c=s[i];if(a.push({value:c,text:r}),c===e)return a;if(l){const t=this._findNodePath(e,l,a);if(t.length)return t}a.pop()}return[]}}};const dr={name:"UniDataPicker",emits:["popupopened","popupclosed","nodeclick","input","change","update:modelValue","inputclick"],mixins:[cr],components:{DataPickerView:t({name:"UniDataPickerView",emits:["nodeclick","change","datachange","update:modelValue"],mixins:[cr],props:{managedMode:{type:Boolean,default:!1},ellipsis:{type:Boolean,default:!0}},created(){this.managedMode||this.$nextTick((()=>{this.loadData()}))},methods:{onPropsChange(){this._treeData=[],this.selectedIndex=0,this.$nextTick((()=>{this.loadData()}))},handleSelect(e){this.selectedIndex=e},handleNodeClick(e,t,a){if(e.disable)return;const n=this.dataList[t][a],i=n[this.map.text],o=n[this.map.value];if(t<this.selected.length-1?(this.selected.splice(t,this.selected.length-t),this.selected.push({text:i,value:o})):t===this.selected.length-1&&this.selected.splice(t,1,{text:i,value:o}),n.isleaf)return void this.onSelectedChange(n,n.isleaf);const{isleaf:s,hasNodes:l}=this._updateBindData();this.isLocalData?this.onSelectedChange(n,!l||s):this.isCloudDataList?this.onSelectedChange(n,!0):this.isCloudDataTree&&(s?this.onSelectedChange(n,n.isleaf):l||this.loadCloudDataNode((e=>{e.length?(this._treeData.push(...e),this._updateBindData(n)):n.isleaf=!0,this.onSelectedChange(n,n.isleaf)})))},updateData(e){this._treeData=e.treeData,this.selected=e.selected,this._treeData.length?this._updateBindData():this.loadData()},onDataChange(){this.$emit("datachange")},onSelectedChange(e,t){t&&this._dispatchEvent(),e&&this.$emit("nodeclick",e)},_dispatchEvent(){this.$emit("change",this.selected.slice(0))}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-load-more"),Ul);return e.openBlock(),e.createElementBlock("view",{class:"uni-data-pickerview"},[t.isCloudDataList?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("scroll-view",{key:0,class:"selected-area","scroll-x":"true"},[e.createElementVNode("view",{class:"selected-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.selected,((a,n)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["selected-item",{"selected-item-active":n==t.selectedIndex}]),key:n,onClick:e=>l.handleSelect(n)},[e.createElementVNode("text",null,e.toDisplayString(a.text||""),1)],10,["onClick"])))),128))])])),e.createElementVNode("view",{class:"tab-c"},[e.createElementVNode("scroll-view",{class:"list","scroll-y":!0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dataList[t.selectedIndex],((a,n)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["item",{"is-disabled":!!a.disable}]),key:n,onClick:e=>l.handleNodeClick(a,t.selectedIndex,n)},[e.createElementVNode("text",{class:"item-text"},e.toDisplayString(a[t.map.text]),1),t.selected.length>t.selectedIndex&&a[t.map.value]==t.selected[t.selectedIndex].value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"check"})):e.createCommentVNode("",!0)],10,["onClick"])))),128))]),t.loading?(e.openBlock(),e.createElementBlock("view",{key:0,class:"loading-cover"},[e.createVNode(r,{class:"load-more",contentText:t.loadMore,status:"loading"},null,8,["contentText"])])):e.createCommentVNode("",!0),t.errorMessage?(e.openBlock(),e.createElementBlock("view",{key:1,class:"error-message"},[e.createElementVNode("text",{class:"error-text"},e.toDisplayString(t.errorMessage),1)])):e.createCommentVNode("",!0)])])}],["__scopeId","data-v-c0c521c5"]])},props:{options:{type:[Object,Array],default:()=>({})},popupTitle:{type:String,default:"请选择"},placeholder:{type:String,default:"请选择"},heightMobile:{type:String,default:""},readonly:{type:Boolean,default:!1},clearIcon:{type:Boolean,default:!0},border:{type:Boolean,default:!0},split:{type:String,default:"/"},ellipsis:{type:Boolean,default:!0}},data:()=>({isOpened:!1,inputSelected:[]}),created(){this.$nextTick((()=>{this.load()}))},watch:{localdata:{handler(){this.load()},deep:!0}},methods:{clear(){this._dispatchEvent([])},onPropsChange(){this._treeData=[],this.selectedIndex=0,this.load()},load(){this.readonly?this._processReadonly(this.localdata,this.dataValue):this.isLocalData?(this.loadData(),this.inputSelected=this.selected.slice(0)):(this.isCloudDataList||this.isCloudDataTree)&&(this.loading=!0,this.getCloudDataValue().then((e=>{this.loading=!1,this.inputSelected=e})).catch((e=>{this.loading=!1,this.errorMessage=e})))},show(){this.isOpened=!0,setTimeout((()=>{this.$refs.pickerView.updateData({treeData:this._treeData,selected:this.selected,selectedIndex:this.selectedIndex})}),200),this.$emit("popupopened")},hide(){this.isOpened=!1,this.$emit("popupclosed")},handleInput(){this.readonly?this.$emit("inputclick"):this.show()},handleClose(e){this.hide()},onnodeclick(e){this.$emit("nodeclick",e)},ondatachange(e){this._treeData=this.$refs.pickerView._treeData},onchange(e){this.hide(),this.$nextTick((()=>{this.inputSelected=e})),this._dispatchEvent(e)},_processReadonly(e,t){if(e.findIndex((e=>e.children))>-1){let e;return Array.isArray(t)?(e=t[t.length-1],"object"==typeof e&&e.value&&(e=e.value)):e=t,void(this.inputSelected=this._findNodePath(e,this.localdata))}if(!this.hasValue)return void(this.inputSelected=[]);let a=[];for(let o=0;o<t.length;o++){var n=t[o],i=e.find((e=>e.value==n));i&&a.push(i)}a.length&&(this.inputSelected=a)},_filterForArray(e,t){var a=[];for(let o=0;o<t.length;o++){var n=t[o],i=e.find((e=>e.value==n));i&&a.push(i)}return a},_dispatchEvent(e){let t={};if(e.length){for(var a=new Array(e.length),n=0;n<e.length;n++)a[n]=e[n].value;t=e[e.length-1]}else t.value="";this.formItem&&this.formItem.setValue(t.value),this.$emit("input",t.value),this.$emit("update:modelValue",t.value),this.$emit("change",{detail:{value:e}})}}};const ur=t(dr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-load-more"),Ul),c=i(e.resolveDynamicComponent("uni-icons"),g),d=e.resolveComponent("data-picker-view");return e.openBlock(),e.createElementBlock("view",{class:"uni-data-tree"},[e.createElementVNode("view",{class:"uni-data-tree-input",onClick:a[1]||(a[1]=(...e)=>l.handleInput&&l.handleInput(...e))},[e.renderSlot(t.$slots,"default",{options:n.options,data:s.inputSelected,error:t.errorMessage},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["input-value",{"input-value-border":n.border}])},[t.errorMessage?(e.openBlock(),e.createElementBlock("text",{key:0,class:"selected-area error-text"},e.toDisplayString(t.errorMessage),1)):t.loading&&!s.isOpened?(e.openBlock(),e.createElementBlock("view",{key:1,class:"selected-area"},[e.createVNode(r,{class:"load-more",contentText:t.loadMore,status:"loading"},null,8,["contentText"])])):s.inputSelected.length?(e.openBlock(),e.createElementBlock("scroll-view",{key:2,class:"selected-area","scroll-x":"true"},[e.createElementVNode("view",{class:"selected-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.inputSelected,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"selected-item",key:a},[e.createElementVNode("text",{class:"text-color"},e.toDisplayString(t.text),1),a<s.inputSelected.length-1?(e.openBlock(),e.createElementBlock("text",{key:0,class:"input-split-line"},e.toDisplayString(n.split),1)):e.createCommentVNode("",!0)])))),128))])])):(e.openBlock(),e.createElementBlock("text",{key:3,class:"selected-area placeholder"},e.toDisplayString(n.placeholder),1)),n.clearIcon&&!n.readonly&&s.inputSelected.length?(e.openBlock(),e.createElementBlock("view",{key:4,class:"icon-clear",onClick:a[0]||(a[0]=e.withModifiers(((...e)=>l.clear&&l.clear(...e)),["stop"]))},[e.createVNode(c,{type:"clear",color:"#c0c4cc",size:"24"})])):e.createCommentVNode("",!0),n.clearIcon&&s.inputSelected.length||n.readonly?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:5,class:"arrow-area"},[e.createElementVNode("view",{class:"input-arrow"})]))],2)]),!0)]),s.isOpened?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-data-tree-cover",onClick:a[2]||(a[2]=(...e)=>l.handleClose&&l.handleClose(...e))})):e.createCommentVNode("",!0),s.isOpened?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-data-tree-dialog"},[e.createElementVNode("view",{class:"uni-popper__arrow"}),e.createElementVNode("view",{class:"dialog-caption"},[e.createElementVNode("view",{class:"title-area"},[e.createElementVNode("text",{class:"dialog-title"},e.toDisplayString(n.popupTitle),1)]),e.createElementVNode("view",{class:"dialog-close",onClick:a[3]||(a[3]=(...e)=>l.handleClose&&l.handleClose(...e))},[e.createElementVNode("view",{class:"dialog-close-plus","data-id":"close"}),e.createElementVNode("view",{class:"dialog-close-plus dialog-close-rotate","data-id":"close"})])]),e.createVNode(d,{class:"picker-view",ref:"pickerView",modelValue:t.dataValue,"onUpdate:modelValue":a[4]||(a[4]=e=>t.dataValue=e),localdata:t.localdata,preload:t.preload,collection:t.collection,field:t.field,orderby:t.orderby,where:t.where,"step-searh":t.stepSearh,"self-field":t.selfField,"parent-field":t.parentField,"managed-mode":!0,map:t.map,ellipsis:n.ellipsis,onChange:l.onchange,onDatachange:l.ondatachange,onNodeclick:l.onnodeclick},null,8,["modelValue","localdata","preload","collection","field","orderby","where","step-searh","self-field","parent-field","map","ellipsis","onChange","onDatachange","onNodeclick"])])):e.createCommentVNode("",!0)])}],["__scopeId","data-v-2015cfd3"]]);const hr=t({name:"uni-data-select",mixins:[Cl.mixinDatacom||{}],props:{localdata:{type:Array,default:()=>[]},value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},label:{type:String,default:""},placeholder:{type:String,default:"请选择"},emptyTips:{type:String,default:"无选项"},clear:{type:Boolean,default:!0},defItem:{type:Number,default:0},disabled:{type:Boolean,default:!1},format:{type:String,default:""},placement:{type:String,default:"bottom"}},data:()=>({showSelector:!1,current:"",mixinDatacomResData:[],apps:[],channels:[],cacheKey:"uni-data-select-lastSelectedValue"}),created(){this.debounceGet=this.debounce((()=>{this.query()}),300),this.collection&&!this.localdata.length&&this.debounceGet()},computed:{typePlaceholder(){const e=this.placeholder,t={"opendb-stat-app-versions":"版本","opendb-app-channels":"渠道","opendb-app-list":"应用"}[this.collection];return t?e+t:e},valueCom(){return this.modelValue},textShow(){let e=this.current;return e.length>10?e.slice(0,25)+"...":e},getOffsetByPlacement(){switch(this.placement){case"top":return"bottom:calc(100% + 12px);";case"bottom":return"top:calc(100% + 12px);"}}},watch:{localdata:{immediate:!0,handler(e,t){Array.isArray(e)&&t!==e&&(this.mixinDatacomResData=e)}},valueCom(e,t){this.initDefVal()},mixinDatacomResData:{immediate:!0,handler(e){e.length&&this.initDefVal()}}},methods:{debounce(e,t=100){let a=null;return function(...n){a&&clearTimeout(a),a=setTimeout((()=>{e.apply(this,n)}),t)}},query(){this.mixinDatacomEasyGet()},onMixinDatacomPropsChange(){this.collection&&this.debounceGet()},initDefVal(){let e="";if(!this.valueCom&&0!==this.valueCom||this.isDisabled(this.valueCom)){let t;if(this.collection&&(t=this.getCache()),t||0===t)e=t;else{let t="";this.defItem>0&&this.defItem<=this.mixinDatacomResData.length&&(t=this.mixinDatacomResData[this.defItem-1].value),e=t}(e||0===e)&&this.emit(e)}else e=this.valueCom;const t=this.mixinDatacomResData.find((t=>t.value===e));this.current=t?this.formatItemName(t):""},isDisabled(e){let t=!1;return this.mixinDatacomResData.forEach((a=>{a.value===e&&(t=a.disable)})),t},clearVal(){this.emit(""),this.collection&&this.removeCache()},change(e){e.disable||(this.showSelector=!1,this.current=this.formatItemName(e),this.emit(e.value))},emit(e){this.$emit("input",e),this.$emit("update:modelValue",e),this.$emit("change",e),this.collection&&this.setCache(e)},toggleSelector(){this.disabled||(this.showSelector=!this.showSelector)},formatItemName(e){let{text:t,value:a,channel_code:n}=e;if(n=n?`(${n})`:"",this.format){let t="";t=this.format;for(let a in e)t=t.replace(new RegExp(`{${a}}`,"g"),e[a]);return t}return this.collection.indexOf("app-list")>0?`${t}(${a})`:t||`未命名${n}`},getLoadData(){return this.mixinDatacomResData},getCurrentCacheKey(){return this.collection},getCache(e=this.getCurrentCacheKey()){return(uni.getStorageSync(this.cacheKey)||{})[e]},setCache(e,t=this.getCurrentCacheKey()){let a=uni.getStorageSync(this.cacheKey)||{};a[t]=e,uni.setStorageSync(this.cacheKey,a)},removeCache(e=this.getCurrentCacheKey()){let t=uni.getStorageSync(this.cacheKey)||{};delete t[e],uni.setStorageSync(this.cacheKey,t)}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-stat__select"},[n.label?(e.openBlock(),e.createElementBlock("span",{key:0,class:"uni-label-text hide-on-phone"},e.toDisplayString(n.label+"："),1)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["uni-stat-box",{"uni-stat__actived":s.current}])},[e.createElementVNode("view",{class:e.normalizeClass(["uni-select",{"uni-select--disabled":n.disabled}])},[e.createElementVNode("view",{class:"uni-select__input-box",onClick:a[1]||(a[1]=(...e)=>l.toggleSelector&&l.toggleSelector(...e))},[s.current?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-select__input-text"},e.toDisplayString(l.textShow),1)):(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-select__input-text uni-select__input-placeholder"},e.toDisplayString(l.typePlaceholder),1)),s.current&&n.clear&&!n.disabled?(e.openBlock(),e.createElementBlock("view",{key:2,onClick:a[0]||(a[0]=e.withModifiers(((...e)=>l.clearVal&&l.clearVal(...e)),["stop"]))},[e.createVNode(r,{type:"clear",color:"#c0c4cc",size:"24"})])):(e.openBlock(),e.createElementBlock("view",{key:3},[e.createVNode(r,{type:s.showSelector?"top":"bottom",size:"14",color:"#999"},null,8,["type"])]))]),s.showSelector?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-select--mask",onClick:a[2]||(a[2]=(...e)=>l.toggleSelector&&l.toggleSelector(...e))})):e.createCommentVNode("",!0),s.showSelector?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-select__selector",style:e.normalizeStyle(l.getOffsetByPlacement)},[e.createElementVNode("view",{class:e.normalizeClass("bottom"==n.placement?"uni-popper__arrow_bottom":"uni-popper__arrow_top")},null,2),e.createElementVNode("scroll-view",{"scroll-y":"true",class:"uni-select__selector-scroll"},[0===s.mixinDatacomResData.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-select__selector-empty"},[e.createElementVNode("text",null,e.toDisplayString(n.emptyTips),1)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(s.mixinDatacomResData,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-select__selector-item",key:a,onClick:e=>l.change(t)},[e.createElementVNode("text",{class:e.normalizeClass({"uni-select__selector__disabled":t.disable})},e.toDisplayString(l.formatItemName(t)),3)],8,["onClick"])))),128))])],4)):e.createCommentVNode("",!0)],2)],2)])}],["__scopeId","data-v-6d601b46"]]);var pr={email:/^\S+?@\S+?\.\S+?$/,idcard:/^[1-9]\d{5}(18|19|([23]\d))\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/,url:new RegExp("^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\S+(?::\\S*)?@)?(?:(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[0-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)*(?:\\.(?:[a-z\\u00a1-\\uffff]{2,})))|localhost)(?::\\d{2,5})?(?:(/|\\?|#)[^\\s]*)?$","i")};const mr={int:"integer",bool:"boolean",double:"number",long:"number",password:"string"};function gr(e,t=""){["label"].forEach((t=>{void 0===e[t]&&(e[t]="")}));let a=t;for(let n in e){let t=new RegExp("{"+n+"}");a=a.replace(t,e[n])}return a}const fr={integer:e=>fr.number(e)&&parseInt(e,10)===e,string:e=>"string"==typeof e,number:e=>!isNaN(e)&&"number"==typeof e,boolean:function(e){return"boolean"==typeof e},float:function(e){return fr.number(e)&&!fr.integer(e)},array:e=>Array.isArray(e),object:e=>"object"==typeof e&&!fr.array(e),date:e=>e instanceof Date,timestamp(e){return!(!this.integer(e)||Math.abs(e).toString().length>16)},file:e=>"string"==typeof e.url,email:e=>"string"==typeof e&&!!e.match(pr.email)&&e.length<255,url:e=>"string"==typeof e&&!!e.match(pr.url),pattern(e,t){try{return new RegExp(e).test(t)}catch($i){return!1}},method:e=>"function"==typeof e,idcard:e=>"string"==typeof e&&!!e.match(pr.idcard),"url-https"(e){return this.url(e)&&e.startsWith("https://")},"url-scheme":e=>e.startsWith("://"),"url-web":e=>!1};const yr={required:(e,t,a)=>e.required&&function(e,t){return null==e||"string"==typeof e&&!e||!(!Array.isArray(e)||e.length)||"object"===t&&!Object.keys(e).length}(t,e.format||typeof t)?gr(e,e.errorMessage||a.required):null,range(e,t,a){const{range:n,errorMessage:i}=e;let o=new Array(n.length);for(let l=0;l<n.length;l++){const e=n[l];fr.object(e)&&void 0!==e.value?o[l]=e.value:o[l]=e}let s=!1;return Array.isArray(t)?s=new Set(t.concat(o)).size===o.length:o.indexOf(t)>-1&&(s=!0),s?null:gr(e,i||a.enum)},rangeNumber(e,t,a){if(!fr.number(t))return gr(e,e.errorMessage||a.pattern.mismatch);let{minimum:n,maximum:i,exclusiveMinimum:o,exclusiveMaximum:s}=e,l=o?t<=n:t<n,r=s?t>=i:t>i;return void 0!==n&&l?gr(e,e.errorMessage||a.number[o?"exclusiveMinimum":"minimum"]):void 0!==i&&r?gr(e,e.errorMessage||a.number[s?"exclusiveMaximum":"maximum"]):void 0!==n&&void 0!==i&&(l||r)?gr(e,e.errorMessage||a.number.range):null},rangeLength(e,t,a){if(!fr.string(t)&&!fr.array(t))return gr(e,e.errorMessage||a.pattern.mismatch);let n=e.minLength,i=e.maxLength,o=t.length;return void 0!==n&&o<n?gr(e,e.errorMessage||a.length.minLength):void 0!==i&&o>i?gr(e,e.errorMessage||a.length.maxLength):void 0!==n&&void 0!==i&&(o<n||o>i)?gr(e,e.errorMessage||a.length.range):null},pattern:(e,t,a)=>fr.pattern(e.pattern,t)?null:gr(e,e.errorMessage||a.pattern.mismatch),format(e,t,a){var n=Object.keys(fr),i=mr[e.format]?mr[e.format]:e.format||e.arrayType;return n.indexOf(i)>-1&&!fr[i](t)?gr(e,e.errorMessage||a.typeError):null},arrayTypeFormat(e,t,a){if(!Array.isArray(t))return gr(e,e.errorMessage||a.typeError);for(let n=0;n<t.length;n++){const i=t[n];let o=this.format(e,i,a);if(null!==o)return o}return null}};class vr extends class{constructor(e){this._message=e}async validateRule(e,t,a,n,i){var o=null;let s=t.rules;if(s.findIndex((e=>e.required))<0){if(null==a)return o;if("string"==typeof a&&!a.length)return o}var l=this._message;if(void 0===s)return l.default;for(var r=0;r<s.length;r++){let c=s[r],d=this._getValidateType(c);if(Object.assign(c,{label:t.label||`["${e}"]`}),yr[d]&&null!=(o=yr[d](c,a,l)))break;if(c.validateExpr){let e=Date.now();if(!1===c.validateExpr(a,i,e)){o=this._getMessage(c,c.errorMessage||this._message.default);break}}if(c.validateFunction&&null!==(o=await this.validateFunction(c,a,n,i,d)))break}return null!==o&&(o=l.TAG+o),o}async validateFunction(e,t,a,n,i){let o=null;try{let s=null;const l=await e.validateFunction(e,t,n||a,(e=>{s=e}));(s||"string"==typeof l&&l||!1===l)&&(o=this._getMessage(e,s||l,i))}catch($i){o=this._getMessage(e,$i.message,i)}return o}_getMessage(e,t,a){return gr(e,t||e.errorMessage||this._message[a]||t.default)}_getValidateType(e){var t="";return e.required?t="required":e.format?t="format":e.arrayType?t="arrayTypeFormat":e.range?t="range":void 0!==e.maximum||void 0!==e.minimum?t="rangeNumber":void 0!==e.maxLength||void 0!==e.minLength?t="rangeLength":e.pattern?t="pattern":e.validateFunction&&(t="validateFunction"),t}}{constructor(e,t){super(vr.message),this._schema=e,this._options=t||null}updateSchema(e){this._schema=e}async validate(e,t){let a=this._checkFieldInSchema(e);return a||(a=await this.invokeValidate(e,!1,t)),a.length?a[0]:null}async validateAll(e,t){let a=this._checkFieldInSchema(e);return a||(a=await this.invokeValidate(e,!0,t)),a}async validateUpdate(e,t){let a=this._checkFieldInSchema(e);return a||(a=await this.invokeValidateUpdate(e,!1,t)),a.length?a[0]:null}async invokeValidate(e,t,a){let n=[],i=this._schema;for(let o in i){let s=i[o],l=await this.validateRule(o,s,e[o],e,a);if(null!=l&&(n.push({key:o,errorMessage:l}),!t))break}return n}async invokeValidateUpdate(e,t,a){let n=[];for(let i in e){let o=await this.validateRule(i,this._schema[i],e[i],e,a);if(null!=o&&(n.push({key:i,errorMessage:o}),!t))break}return n}_checkFieldInSchema(e){var t=Object.keys(e),a=Object.keys(this._schema);if(new Set(t.concat(a)).size===a.length)return"";var n=t.filter((e=>a.indexOf(e)<0));return[{key:"invalid",errorMessage:gr({field:JSON.stringify(n)},vr.message.TAG+vr.message.defaultInvalid)}]}}vr.message=new function(){return{TAG:"",default:"验证错误",defaultInvalid:"提交的字段{field}在数据库中并不存在",validateFunction:"验证无效",required:"{label}必填",enum:"{label}超出范围",timestamp:"{label}格式无效",whitespace:"{label}不能为空",typeError:"{label}类型无效",date:{format:"{label}日期{value}格式无效",parse:"{label}日期无法解析,{value}无效",invalid:"{label}日期{value}无效"},length:{minLength:"{label}长度不能少于{minLength}",maxLength:"{label}长度不能超过{maxLength}",range:"{label}必须介于{minLength}和{maxLength}之间"},number:{minimum:"{label}不能小于{minimum}",maximum:"{label}不能大于{maximum}",exclusiveMinimum:"{label}不能小于等于{minimum}",exclusiveMaximum:"{label}不能大于等于{maximum}",range:"{label}必须介于{minimum}and{maximum}之间"},pattern:{mismatch:"{label}格式不匹配"}}};const wr=(e,t,a)=>{const n=a.find((e=>{return e.format&&("int"===(t=e.format)||"double"===t||"number"===t||"timestamp"===t);var t})),i=a.find((e=>e.format&&"boolean"===e.format||"bool"===e.format));return n&&(t=t||0===t?Cr(Number(t))?Number(t):t:null),i&&(t=!!_r(t)&&t),t},br=(e,t)=>Er(t,e),kr=(e,t={})=>{const a=Nr(e);if("object"==typeof a&&Array.isArray(a)&&a.length>1){return a.reduce(((e,t)=>e+`#${t}`),"_formdata_")}return a[0]||e},xr=e=>{let t=e.replace("_formdata_#","");return t=t.split("#").map((e=>Cr(e)?Number(e):e)),t},Vr=(e,t,a)=>("object"!=typeof e||Nr(t).reduce(((e,t,n,i)=>n===i.length-1?(e[t]=a,null):(t in e||(e[t]=/^[0-9]{1,}$/.test(i[n+1])?[]:{}),e[t])),e),e);function Nr(e){return Array.isArray(e)?e:e.replace(/\[/g,".").replace(/\]/g,"").split(".")}const Er=(e,t,a="undefined")=>{let n=Nr(t).reduce(((e,t)=>(e||{})[t]),e);return n&&void 0===n?a:n},Cr=e=>!isNaN(Number(e)),_r=e=>"boolean"==typeof e;const Sr=t({name:"uniForms",emits:["validate","submit"],options:{virtualHost:!0},props:{value:{type:Object,default:()=>null},modelValue:{type:Object,default:()=>null},model:{type:Object,default:()=>null},rules:{type:Object,default:()=>({})},errShowType:{type:String,default:"undertext"},validateTrigger:{type:String,default:"submit"},labelPosition:{type:String,default:"left"},labelWidth:{type:[String,Number],default:""},labelAlign:{type:String,default:"left"},border:{type:Boolean,default:!1}},provide(){return{uniForm:this}},data:()=>({formData:{},formRules:{}}),computed:{localData(){const e=this.model||this.modelValue||this.value;return e?(t=e,JSON.parse(JSON.stringify(t))):{};var t}},watch:{rules:{handler:function(e,t){this.setRules(e)},deep:!0,immediate:!0}},created(){getApp().$vm.$.appContext.config.globalProperties.binddata||(getApp().$vm.$.appContext.config.globalProperties.binddata=function(e,t,a){if(a)this.$refs[a].setValue(e,t);else{let a;for(let e in this.$refs){const t=this.$refs[e];if(t&&t.$options&&"uniForms"===t.$options.name){a=t;break}}if(!a)return n("error","at uni_modules/uni-forms/components/uni-forms/uni-forms.vue:187","当前 uni-froms 组件缺少 ref 属性");a.model&&(a.model[e]=t),a.modelValue&&(a.modelValue[e]=t),a.value&&(a.value[e]=t)}}),this.childrens=[],this.inputChildrens=[],this.setRules(this.rules)},methods:{setRules(e){this.formRules=Object.assign({},this.formRules,e),this.validator=new vr(e)},setValue(e,t){let a=this.childrens.find((t=>t.name===e));return a?(this.formData[e]=wr(0,t,this.formRules[e]&&this.formRules[e].rules||[]),a.onFieldChange(this.formData[e])):null},validate(e,t){return this.checkAll(this.formData,e,t)},validateField(e=[],t){e=[].concat(e);let a={};return this.childrens.forEach((t=>{const n=kr(t.name);-1!==e.indexOf(n)&&(a=Object.assign({},a,{[n]:this.formData[n]}))})),this.checkAll(a,[],t)},clearValidate(e=[]){e=[].concat(e),this.childrens.forEach((t=>{if(0===e.length)t.errMsg="";else{const a=kr(t.name);-1!==e.indexOf(a)&&(t.errMsg="")}}))},submit(e,t,a){for(let n in this.dataValue){this.childrens.find((e=>e.name===n))&&void 0===this.formData[n]&&(this.formData[n]=this._getValue(n,this.dataValue[n]))}return a||n("warn","at uni_modules/uni-forms/components/uni-forms/uni-forms.vue:296","submit 方法即将废弃，请使用validate方法代替！"),this.checkAll(this.formData,e,t,"submit")},async checkAll(e,t,a,n){if(!this.validator)return;let i,o=[];for(let c in e){const e=this.childrens.find((e=>kr(e.name)===c));e&&o.push(e)}a||"function"!=typeof t||(a=t),!a&&"function"!=typeof a&&Promise&&(i=new Promise(((e,t)=>{a=function(a,n){a?t(a):e(n)}})));let s=[],l=JSON.parse(JSON.stringify(e));for(let c in o){const e=o[c];let t=kr(e.name);const a=await e.onFieldChange(l[t]);if(a&&(s.push(a),"toast"===this.errShowType||"modal"===this.errShowType))break}Array.isArray(s)&&0===s.length&&(s=null),Array.isArray(t)&&t.forEach((e=>{let t=kr(e),a=br(e,this.localData);void 0!==a&&(l[t]=a)})),"submit"===n?this.$emit("submit",{detail:{value:l,errors:s}}):this.$emit("validate",s);let r={};return r=((e={},t)=>{let a=JSON.parse(JSON.stringify(e)),n={};for(let i in a){let e=xr(i);Vr(n,e,a[i])}return n})(l,this.name),a&&"function"==typeof a&&a(s,r),i&&a?i:null},validateCheck(e){this.$emit("validate",e)},_getValue:wr,_isRequiredField:e=>{let t=!1;for(let a=0;a<e.length;a++){if(e[a].required){t=!0;break}}return t},_setDataValue:(e,t,a)=>(t[e]=a,a||""),_getDataValue:br,_realName:kr,_isRealName:e=>/^_formdata_#*/.test(e),_isEqual:(e,t)=>{if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return e===t;var a=toString.call(e);if(a!==toString.call(t))return!1;switch(a){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0==+e?1/+e==1/t:+e==+t;case"[object Date]":case"[object Boolean]":return+e==+t}if("[object Object]"==a){var n=Object.getOwnPropertyNames(e),i=Object.getOwnPropertyNames(t);if(n.length!=i.length)return!1;for(var o=0;o<n.length;o++){var s=n[o];if(e[s]!==t[s])return!1}return!0}return"[object Array]"==a?e.toString()==t.toString():void 0}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-forms"},[e.createElementVNode("form",null,[e.renderSlot(t.$slots,"default",{},void 0,!0)])])}],["__scopeId","data-v-5e601aef"]]);const Tr=t({name:"UniSection",emits:["click"],props:{type:{type:String,default:""},title:{type:String,required:!0,default:""},titleFontSize:{type:String,default:"14px"},titleColor:{type:String,default:"#333"},subTitle:{type:String,default:""},subTitleFontSize:{type:String,default:"12px"},subTitleColor:{type:String,default:"#999"},padding:{type:[Boolean,String],default:!1}},computed:{_padding(){return"string"==typeof this.padding?this.padding:this.padding?"10px":""}},watch:{title(e){uni.report&&""!==e&&uni.report("title",e)}},methods:{onClick(){this.$emit("click")}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-section"},[e.createElementVNode("view",{class:"uni-section-header",onClick:a[0]||(a[0]=(...e)=>s.onClick&&s.onClick(...e))},[n.type?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-section-header__decoration",n.type])},null,2)):e.renderSlot(t.$slots,"decoration",{key:1},void 0,!0),e.createElementVNode("view",{class:"uni-section-header__content"},[e.createElementVNode("text",{style:e.normalizeStyle({"font-size":n.titleFontSize,color:n.titleColor}),class:e.normalizeClass(["uni-section__content-title",{distraction:!n.subTitle}])},e.toDisplayString(n.title),7),n.subTitle?(e.openBlock(),e.createElementBlock("text",{key:0,style:e.normalizeStyle({"font-size":n.subTitleFontSize,color:n.subTitleColor}),class:"uni-section-header__content-sub"},e.toDisplayString(n.subTitle),5)):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"uni-section-header__slot-right"},[e.renderSlot(t.$slots,"right",{},void 0,!0)])]),e.createElementVNode("view",{class:"uni-section-content",style:e.normalizeStyle({padding:s._padding})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],4)])}],["__scopeId","data-v-0a8818d5"]]);const Br=t({name:"UniSegmentedControl",emits:["clickItem"],props:{current:{type:Number,default:0},values:{type:Array,default:()=>[]},activeColor:{type:String,default:"#2979FF"},inActiveColor:{type:String,default:"transparent"},styleType:{type:String,default:"button"}},data:()=>({currentIndex:0}),watch:{current(e){e!==this.currentIndex&&(this.currentIndex=e)}},computed:{},created(){this.currentIndex=this.current},methods:{_onClick(e){this.currentIndex!==e&&(this.currentIndex=e,this.$emit("clickItem",{currentIndex:e}))}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass([["text"===n.styleType?"segmented-control--text":"segmented-control--button"],"segmented-control"]),style:e.normalizeStyle({borderColor:"text"===n.styleType?"":n.activeColor})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.values,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass([["text"===n.styleType?"":"segmented-control__item--button",0===a&&"button"===n.styleType?"segmented-control__item--button--first":"",a===n.values.length-1&&"button"===n.styleType?"segmented-control__item--button--last":""],"segmented-control__item"]),key:a,style:e.normalizeStyle({backgroundColor:a===o.currentIndex&&"button"===n.styleType?n.activeColor:"button"===n.styleType?n.inActiveColor:"transparent",borderColor:a===o.currentIndex&&"text"===n.styleType||"button"===n.styleType?n.activeColor:n.inActiveColor}),onClick:e=>s._onClick(a)},[e.createElementVNode("view",null,[e.createElementVNode("text",{style:e.normalizeStyle({color:a===o.currentIndex?"text"===n.styleType?n.activeColor:"#fff":"text"===n.styleType?"#000":n.activeColor}),class:e.normalizeClass(["segmented-control__text","text"===n.styleType&&a===o.currentIndex?"segmented-control__item--text":""])},e.toDisplayString(t),7)])],14,["onClick"])))),128))],6)}],["__scopeId","data-v-409bd450"]]),Dr={data:()=>({baseFormData:{name:"",age:"",introduction:"",sex:2,hobby:[5],datetimesingle:1627529992399,city:"",skills:0},cityData:[{text:"北京",value:"10001"},{text:"上海",value:"10002"},{text:"深圳",value:"10004"}],skillsRange:[{value:0,text:"编程"},{value:1,text:"绘画"},{value:2,text:"运动"}],alignmentFormData:{name:"",age:""},sexs:[{text:"男",value:0},{text:"女",value:1},{text:"保密",value:2}],hobbys:[{text:"跑步",value:0},{text:"游泳",value:1},{text:"绘画",value:2},{text:"足球",value:3},{text:"篮球",value:4},{text:"其他",value:5}],current:0,items:["左对齐","顶部对齐"],valiFormData:{name:"",age:"",introduction:""},rules:{name:{rules:[{required:!0,errorMessage:"姓名不能为空"}]},age:{rules:[{required:!0,errorMessage:"年龄不能为空"},{format:"number",errorMessage:"年龄只能输入数字"}]}},customFormData:{name:"",age:"",hobby:[]},customRules:{name:{rules:[{required:!0,errorMessage:"姓名不能为空"}]},age:{rules:[{required:!0,errorMessage:"年龄不能为空"}]},hobby:{rules:[{format:"array"},{validateFunction:function(e,t,a,n){return t.length<2&&n("请至少勾选两个兴趣爱好"),!0}}]}},dynamicFormData:{email:"",domains:[]},dynamicLists:[],dynamicRules:{email:{rules:[{required:!0,errorMessage:"域名不能为空"},{format:"email",errorMessage:"域名格式错误"}]}}}),computed:{alignment(){return 0===this.current?"left":1===this.current?"top":"left"}},onLoad(){},onReady(){this.$refs.customForm.setRules(this.customRules)},methods:{onClickItem(e){n("log","at pages/extUI/forms/forms.vue:293",e),this.current=e.currentIndex},add(){this.dynamicFormData.domains.push({label:"域名",value:"",rules:[{required:!0,errorMessage:"域名项必填"}],id:Date.now()})},del(e){let t=this.dynamicLists.findIndex((t=>t.id===e));this.dynamicLists.splice(t,1)},submit(e){n("log","at pages/extUI/forms/forms.vue:312",this.baseFormData),this.$refs[e].validate().then((e=>{n("log","at pages/extUI/forms/forms.vue:314","success",e),uni.showToast({title:"校验通过"})})).catch((e=>{n("log","at pages/extUI/forms/forms.vue:319","err",e)}))}}};const Ir=t(Dr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-easyinput"),En),d=i(e.resolveDynamicComponent("uni-forms-item"),Cn),u=i(e.resolveDynamicComponent("uni-data-checkbox"),ql),h=i(e.resolveDynamicComponent("uni-datetime-picker"),rr),p=i(e.resolveDynamicComponent("uni-data-picker"),ur),m=i(e.resolveDynamicComponent("uni-data-select"),hr),g=i(e.resolveDynamicComponent("uni-forms"),Sr),f=i(e.resolveDynamicComponent("uni-section"),Tr),y=i(e.resolveDynamicComponent("uni-segmented-control"),Br);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"uni-forms 组件一般由输入框、选择器、单选框、多选框等控件组成，用以收集、校验、提交数据。")])),_:1}),e.createVNode(f,{title:"基本用法",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createVNode(g,{ref:"baseForm",model:s.baseFormData,labelWidth:"80px"},{default:e.withCtx((()=>[e.createVNode(d,{label:"姓名",required:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.baseFormData.name,"onUpdate:modelValue":a[0]||(a[0]=e=>s.baseFormData.name=e),placeholder:"请输入姓名"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"年龄",required:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.baseFormData.age,"onUpdate:modelValue":a[1]||(a[1]=e=>s.baseFormData.age=e),placeholder:"请输入年龄"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"性别",required:""},{default:e.withCtx((()=>[e.createVNode(u,{modelValue:s.baseFormData.sex,"onUpdate:modelValue":a[2]||(a[2]=e=>s.baseFormData.sex=e),localdata:s.sexs},null,8,["modelValue","localdata"])])),_:1}),e.createVNode(d,{label:"兴趣爱好",required:""},{default:e.withCtx((()=>[e.createVNode(u,{modelValue:s.baseFormData.hobby,"onUpdate:modelValue":a[3]||(a[3]=e=>s.baseFormData.hobby=e),multiple:"",localdata:s.hobbys},null,8,["modelValue","localdata"])])),_:1}),e.createVNode(d,{label:"自我介绍"},{default:e.withCtx((()=>[e.createVNode(c,{type:"textarea",modelValue:s.baseFormData.introduction,"onUpdate:modelValue":a[4]||(a[4]=e=>s.baseFormData.introduction=e),placeholder:"请输入自我介绍"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"日期时间"},{default:e.withCtx((()=>[e.createVNode(h,{type:"datetime","return-type":"timestamp",modelValue:s.baseFormData.datetimesingle,"onUpdate:modelValue":a[5]||(a[5]=e=>s.baseFormData.datetimesingle=e)},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"选择城市"},{default:e.withCtx((()=>[e.createVNode(p,{modelValue:s.baseFormData.city,"onUpdate:modelValue":a[6]||(a[6]=e=>s.baseFormData.city=e),localdata:s.cityData,"popup-title":"选择城市"},null,8,["modelValue","localdata"])])),_:1}),e.createVNode(d,{label:"选择技能"},{default:e.withCtx((()=>[e.createVNode(m,{modelValue:s.baseFormData.skills,"onUpdate:modelValue":a[7]||(a[7]=e=>s.baseFormData.skills=e),localdata:s.skillsRange},null,8,["modelValue","localdata"])])),_:1})])),_:1},8,["model"])])])),_:1}),e.createVNode(f,{title:"对齐方式",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createElementVNode("view",{class:"segmented-control"},[e.createVNode(y,{current:s.current,values:s.items,onClickItem:l.onClickItem,styleType:"button"},null,8,["current","values","onClickItem"])]),e.createVNode(g,{ref:"baseForm",modelValue:s.alignmentFormData,"label-position":l.alignment},{default:e.withCtx((()=>[e.createVNode(d,{label:"姓名",required:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.baseFormData.name,"onUpdate:modelValue":a[8]||(a[8]=e=>s.baseFormData.name=e),placeholder:"请输入姓名"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"年龄",required:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.baseFormData.age,"onUpdate:modelValue":a[9]||(a[9]=e=>s.baseFormData.age=e),placeholder:"请输入年龄"},null,8,["modelValue"])])),_:1})])),_:1},8,["modelValue","label-position"])])])),_:1}),e.createVNode(f,{title:"表单校验",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createVNode(g,{ref:"valiForm",rules:s.rules,model:s.valiFormData,labelWidth:"80px"},{default:e.withCtx((()=>[e.createVNode(d,{label:"姓名",required:"",name:"name"},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.valiFormData.name,"onUpdate:modelValue":a[10]||(a[10]=e=>s.valiFormData.name=e),placeholder:"请输入姓名"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"年龄",required:"",name:"age"},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.valiFormData.age,"onUpdate:modelValue":a[11]||(a[11]=e=>s.valiFormData.age=e),placeholder:"请输入年龄"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"自我介绍"},{default:e.withCtx((()=>[e.createVNode(c,{type:"textarea",modelValue:s.valiFormData.introduction,"onUpdate:modelValue":a[12]||(a[12]=e=>s.valiFormData.introduction=e),placeholder:"请输入自我介绍"},null,8,["modelValue"])])),_:1})])),_:1},8,["rules","model"]),e.createElementVNode("button",{type:"primary",onClick:a[13]||(a[13]=e=>l.submit("valiForm"))},"提交")])])),_:1}),e.createVNode(f,{title:"自定义校验规则",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createVNode(g,{ref:"customForm",rules:s.customRules,labelWidth:"80px",modelValue:s.customFormData},{default:e.withCtx((()=>[e.createVNode(d,{label:"姓名",required:"",name:"name"},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.customFormData.name,"onUpdate:modelValue":a[14]||(a[14]=e=>s.customFormData.name=e),placeholder:"请输入姓名"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"年龄",required:"",name:"age"},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.customFormData.age,"onUpdate:modelValue":a[15]||(a[15]=e=>s.customFormData.age=e),placeholder:"请输入年龄"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{label:"兴趣爱好",required:"",name:"hobby"},{default:e.withCtx((()=>[e.createVNode(u,{modelValue:s.customFormData.hobby,"onUpdate:modelValue":a[16]||(a[16]=e=>s.customFormData.hobby=e),multiple:"",localdata:s.hobbys},null,8,["modelValue","localdata"])])),_:1})])),_:1},8,["rules","modelValue"]),e.createElementVNode("button",{type:"primary",onClick:a[17]||(a[17]=e=>l.submit("customForm"))},"提交")])])),_:1}),e.createVNode(f,{title:"动态表单",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createVNode(g,{ref:"dynamicForm",rules:s.dynamicRules,model:s.dynamicFormData,labelWidth:"80px"},{default:e.withCtx((()=>[e.createVNode(d,{label:"邮箱",required:"",name:"email"},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.dynamicFormData.email,"onUpdate:modelValue":a[18]||(a[18]=e=>s.dynamicFormData.email=e),placeholder:"请输入姓名"},null,8,["modelValue"])])),_:1}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.dynamicFormData.domains,((t,a)=>(e.openBlock(),e.createBlock(d,{key:t.id,label:t.label+" "+a,required:"",rules:t.rules,name:["domains",a,"value"]},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"form-item"},[e.createVNode(c,{modelValue:s.dynamicFormData.domains[a].value,"onUpdate:modelValue":e=>s.dynamicFormData.domains[a].value=e,placeholder:"请输入域名"},null,8,["modelValue","onUpdate:modelValue"]),e.createElementVNode("button",{class:"button",size:"mini",type:"default",onClick:e=>l.del(t.id)},"删除",8,["onClick"])])])),_:2},1032,["label","rules","name"])))),128))])),_:1},8,["rules","model"]),e.createElementVNode("view",{class:"button-group"},[e.createElementVNode("button",{type:"primary",size:"mini",onClick:a[19]||(a[19]=(...e)=>l.add&&l.add(...e))},"新增域名"),e.createElementVNode("button",{type:"primary",size:"mini",onClick:a[20]||(a[20]=e=>l.submit("dynamicForm"))},"提交")])])])),_:1})])}]]);const Pr=t({name:"uniGroup",emits:["click"],props:{title:{type:String,default:""},top:{type:[Number,String],default:10},mode:{type:String,default:"default"},stat:{type:Boolean,default:!1}},data:()=>({margin:!1,border:!1}),watch:{title(e){uni.report&&this.stat&&""!==e&&uni.report("title",e)}},created(){this.form=this.getForm(),this.form&&(this.margin=!0,this.border=this.form.border)},methods:{getForm(){let e=this.$parent,t=e.$options.name;for(;"uniForms"!==t;){if(e=e.$parent,!e)return!1;t=e.$options.name}return e},onClick(){this.$emit("click")}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-group",["uni-group--"+n.mode,o.margin?"group-margin":""]]),style:e.normalizeStyle({marginTop:`${n.top}px`})},[e.renderSlot(t.$slots,"title",{},(()=>[n.title?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-group__title",style:e.normalizeStyle({"padding-left":o.border?"30px":"15px"})},[e.createElementVNode("text",{class:"uni-group__title-text"},e.toDisplayString(n.title),1)],4)):e.createCommentVNode("",!0)]),!0),e.createElementVNode("view",{class:e.normalizeClass(["uni-group__content",{"group-conent-padding":o.border}])},[e.renderSlot(t.$slots,"default",{},void 0,!0)],2)],6)}],["__scopeId","data-v-f9b5d343"]]);const Ar=t({components:{},data:()=>({appear:!1,name:"",mobile:"139 9999 9999",weixin:"sskd",message:"",errorMessage:""}),onReady(){},methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-group"),Pr),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"分组组件可用于将组件分组，添加间隔，以产生明显的区块。")])),_:1}),e.createVNode(d,{title:"基础分组",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,null,{default:e.withCtx((()=>[e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 ")])),_:1}),e.createVNode(c,{title:"基本模式","margin-top":"20"},{default:e.withCtx((()=>[e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 ")])),_:1})])),_:1}),e.createVNode(d,{title:"卡片分组",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{mode:"card"},{default:e.withCtx((()=>[e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 ")])),_:1}),e.createVNode(c,{title:"card 模式",mode:"card"},{default:e.withCtx((()=>[e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 "),e.createElementVNode("view",null," 分组内容 ")])),_:1})])),_:1})])}]]);const Fr=t({name:"UniBadge",emits:["click"],props:{type:{type:String,default:"error"},inverted:{type:Boolean,default:!1},isDot:{type:Boolean,default:!1},maxNum:{type:Number,default:99},absolute:{type:String,default:""},offset:{type:Array,default:()=>[0,0]},text:{type:[String,Number],default:""},size:{type:String,default:"small"},customStyle:{type:Object,default:()=>({})}},data:()=>({}),computed:{width(){return 8*String(this.text).length+12},classNames(){const{inverted:e,type:t,size:a,absolute:n}=this;return[e?"uni-badge--"+t+"-inverted":"","uni-badge--"+t,"uni-badge--"+a,n?"uni-badge--absolute":""].join(" ")},positionStyle(){if(!this.absolute)return{};let e=this.width/2,t=10;this.isDot&&(e=5,t=5);const a=`${-e+this.offset[0]}px`,n=`${-t+this.offset[1]}px`,i={rightTop:{right:a,top:n},rightBottom:{right:a,bottom:n},leftBottom:{left:a,bottom:n},leftTop:{left:a,top:n}},o=i[this.absolute];return o||i.rightTop},dotStyle(){return this.isDot?{width:"10px",minWidth:"0",height:"10px",padding:"0",borderRadius:"10px"}:{}},displayValue(){const{isDot:e,text:t,maxNum:a}=this;return e?"":Number(t)>a?`${a}+`:t}},methods:{onClick(){this.$emit("click")}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-badge--x"},[e.renderSlot(t.$slots,"default",{},void 0,!0),n.text?(e.openBlock(),e.createElementBlock("text",{key:0,class:e.normalizeClass([s.classNames,"uni-badge"]),style:e.normalizeStyle([s.positionStyle,n.customStyle,s.dotStyle]),onClick:a[0]||(a[0]=e=>s.onClick())},e.toDisplayString(s.displayValue),7)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-bca7b097"]]);const Lr=t({components:{},data:()=>({value:0,customStyle:{backgroundColor:"#62ed0d",color:"#fff"}}),mounted(){const e=setInterval((()=>{this.value>=199?clearInterval(e):this.value++}),100)}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-badge"),Fr),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"数字角标通用来标记重点信息使用，如接受到新消息、有未读消息等")])),_:1}),e.createVNode(d,{title:"基础用法",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{class:"uni-badge-left-margin",text:"1"}),e.createVNode(c,{class:"uni-badge-left-margin",text:"2",type:"primary"}),e.createVNode(c,{class:"uni-badge-left-margin",text:"34",type:"success"}),e.createVNode(c,{class:"uni-badge-left-margin",text:"45",type:"warning"}),e.createVNode(c,{class:"uni-badge-left-margin",text:"123",type:"info"})])])),_:1}),e.createVNode(d,{title:"无底色",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{class:"uni-badge-left-margin",inverted:!0,text:"1"}),e.createVNode(c,{class:"uni-badge-left-margin",inverted:!0,text:"2",type:"primary"}),e.createVNode(c,{class:"uni-badge-left-margin",inverted:!0,text:"34",type:"success"}),e.createVNode(c,{class:"uni-badge-left-margin",inverted:!0,text:"45",type:"warning"}),e.createVNode(c,{class:"uni-badge-left-margin",inverted:!0,text:"123",type:"info"})])])),_:1}),e.createVNode(d,{title:"自定义样式",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{class:"uni-badge-left-margin",text:"2",type:"primary",customStyle:{background:"#4335d6"}}),e.createVNode(c,{class:"uni-badge-left-margin",text:"2",type:"primary",customStyle:s.customStyle},null,8,["customStyle"])])])),_:1}),e.createVNode(d,{title:"定位: aboslute 属性",subTitle:"注：在安卓端不支持 nvue",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{class:"uni-badge-left-margin",text:s.value,absolute:"rightTop",size:"small"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"box"},[e.createElementVNode("text",{class:"box-text"},"右上")])])),_:1},8,["text"])])),_:1}),e.createVNode(d,{title:"偏移: offset 属性(存在 aboslute)",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{class:"uni-badge-left-margin",text:8,absolute:"rightTop",offset:[-3,-3],size:"small"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"box"},[e.createElementVNode("text",{class:"box-text"},"右上")])])),_:1})])),_:1}),e.createVNode(d,{title:"仅显示点: is-dot 属性",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{class:"uni-badge-left-margin","is-dot":!0,text:s.value,absolute:"rightTop",size:"small"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"box"},[e.createElementVNode("text",{class:"box-text"},"圆点")])])),_:1},8,["text"])])),_:1})])}]]);const Mr=t({data:()=>({currentPage:""}),options:{virtualHost:!0},props:{to:{type:String,default:""},replace:{type:Boolean,default:!1}},inject:{uniBreadcrumb:{from:"uniBreadcrumb",default:null}},created(){const e=getCurrentPages(),t=e[e.length-1];t&&(this.currentPage=`/${t.route}`)},computed:{separator(){return this.uniBreadcrumb.separator},separatorClass(){return this.uniBreadcrumb.separatorClass}},methods:{navTo(){const{to:e}=this;e&&this.currentPage!==e&&(this.replace?uni.redirectTo({url:e}):uni.navigateTo({url:e}))}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-breadcrumb-item"},[e.createElementVNode("view",{class:e.normalizeClass({"uni-breadcrumb-item--slot":!0,"uni-breadcrumb-item--slot-link":n.to&&o.currentPage!==n.to}),onClick:a[0]||(a[0]=(...e)=>s.navTo&&s.navTo(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],2),s.separatorClass?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(["uni-breadcrumb-item--separator",s.separatorClass])},null,2)):(e.openBlock(),e.createElementBlock("text",{key:1,class:"uni-breadcrumb-item--separator"},e.toDisplayString(s.separator),1))])}],["__scopeId","data-v-c8775c9c"]]);const Rr=t({options:{virtualHost:!0},props:{separator:{type:String,default:"/"},separatorClass:{type:String,default:""}},provide(){return{uniBreadcrumb:this}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-breadcrumb"},[e.renderSlot(t.$slots,"default",{},void 0,!0)])}],["__scopeId","data-v-fd9c4191"]]);const Or=t({components:{},data:()=>({routes:[{to:"/pages/index/index",name:"首页"},{to:"",name:"菜单 A"},{to:"",name:"菜单 B"}]})},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-breadcrumb-item"),Mr),d=i(e.resolveDynamicComponent("uni-breadcrumb"),Rr),u=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"面包屑导航显示当前页面的路径，快速返回之前的任意可跳转页面")])),_:1}),e.createVNode(u,{title:"基础用法",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(d,{separator:"/"},{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.routes,((t,a)=>(e.openBlock(),e.createBlock(c,{key:a,to:t.to},{default:e.withCtx((()=>[e.createTextVNode(e.toDisplayString(t.name),1)])),_:2},1032,["to"])))),128))])),_:1})])),_:1}),e.createVNode(u,{title:"自定义分隔符",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(d,{separator:">"},{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.routes,((t,a)=>(e.openBlock(),e.createBlock(c,{key:a,to:t.to},{default:e.withCtx((()=>[e.createTextVNode(e.toDisplayString(t.name),1)])),_:2},1032,["to"])))),128))])),_:1})])),_:1})])}]]);const $r=t({name:"UniDrawer",components:{},emits:["change"],props:{mode:{type:String,default:""},mask:{type:Boolean,default:!0},maskClick:{type:Boolean,default:!0},width:{type:Number,default:220}},data:()=>({visibleSync:!1,showDrawer:!1,rightMode:!1,watchTimer:null,drawerWidth:220}),created(){this.drawerWidth=this.width,this.rightMode="right"===this.mode},methods:{clear(){},close(e){("mask"!==e||this.maskClick)&&this.visibleSync&&this._change("showDrawer","visibleSync",!1)},open(){this.visibleSync||this._change("visibleSync","showDrawer",!0)},_change(e,t,a){this[e]=a,this.watchTimer&&clearTimeout(this.watchTimer),this.watchTimer=setTimeout((()=>{this[t]=a,this.$emit("change",a)}),a?50:300)}}},[["render",function(t,a,n,i,o,s){return o.visibleSync?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass([{"uni-drawer--visible":o.showDrawer},"uni-drawer"]),onTouchmove:a[1]||(a[1]=e.withModifiers(((...e)=>s.clear&&s.clear(...e)),["stop","prevent"]))},[e.createElementVNode("view",{class:e.normalizeClass(["uni-drawer__mask",{"uni-drawer__mask--visible":o.showDrawer&&n.mask}]),onClick:a[0]||(a[0]=e=>s.close("mask"))},null,2),e.createElementVNode("view",{class:e.normalizeClass(["uni-drawer__content",{"uni-drawer--right":o.rightMode,"uni-drawer--left":!o.rightMode,"uni-drawer__content--visible":o.showDrawer}]),style:e.normalizeStyle({width:o.drawerWidth+"px"})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)],34)):e.createCommentVNode("",!0)}],["__scopeId","data-v-8b8b609c"]]),zr={data:()=>({showRight:!1,showLeft:!1}),methods:{confirm(){},showDrawer(e){this.$refs[e].open()},closeDrawer(e){this.$refs[e].close()},change(e,t){n("log","at pages/extUI/drawer/drawer.vue:67",("showLeft"===t?"左窗口":"右窗口")+(e?"打开":"关闭")),this[t]=e}},onNavigationBarButtonTap(e){this.showLeft?this.$refs.showLeft.close():this.$refs.showLeft.open()},onBackPress(){if(this.showRight||this.showLeft)return this.$refs.showLeft.close(),this.$refs.showRight.close(),!0}};const Ur=t(zr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-drawer"),$r),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"这是抽屉式导航组件使用示例，可以指定菜单左侧或者右侧弹出（仅初始化生效），组件内部可以放置任何内容。点击页面按钮即可显示导航菜单。")])),_:1}),e.createVNode(d,{title:"左侧滑出",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("button",{type:"primary",onClick:a[0]||(a[0]=e=>l.showDrawer("showLeft"))},[e.createElementVNode("text",{class:"word-btn-white"},"显示Drawer")]),e.createVNode(c,{ref:"showLeft",mode:"left",width:320,onChange:a[2]||(a[2]=e=>l.change(e,"showLeft"))},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"close"},[e.createElementVNode("button",{onClick:a[1]||(a[1]=e=>l.closeDrawer("showLeft"))},[e.createElementVNode("text",{class:"word-btn-white"},"关闭Drawer")])])])),_:1},512)])])),_:1}),e.createVNode(d,{title:"右侧滑出",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("button",{type:"primary",onClick:a[3]||(a[3]=e=>l.showDrawer("showRight"))},[e.createElementVNode("text",{class:"word-btn-white"},"显示Drawer")]),e.createVNode(c,{ref:"showRight",mode:"right","mask-click":!1,onChange:a[6]||(a[6]=e=>l.change(e,"showRight"))},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"scroll-view"},[e.createElementVNode("scroll-view",{class:"scroll-view-box","scroll-y":"true"},[e.createElementVNode("view",{class:"info"},[e.createElementVNode("text",{class:"info-text"},"右侧遮罩只能通过按钮关闭，不能通过点击遮罩关闭")]),e.createElementVNode("view",{class:"close"},[e.createElementVNode("button",{onClick:a[4]||(a[4]=e=>l.closeDrawer("showRight"))},[e.createElementVNode("text",{class:"word-btn-white"},"关闭Drawer")])]),(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(100,(t=>e.createElementVNode("view",{class:"info-content",key:t},[e.createElementVNode("text",null,"可滚动内容 "+e.toDisplayString(t),1)]))),64)),e.createElementVNode("view",{class:"close"},[e.createElementVNode("button",{onClick:a[5]||(a[5]=e=>l.closeDrawer("showRight"))},[e.createElementVNode("text",{class:"word-btn-white"},"关闭Drawer")])])])])])),_:1},512)])])),_:1})])}]]),jr={data:()=>({}),created(){this.popup=this.getParent()},methods:{getParent(e="uniPopup"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}};const qr=t({name:"uniPopupMessage",mixins:[jr],props:{type:{type:String,default:"success"},message:{type:String,default:""},duration:{type:Number,default:3e3},maskShow:{type:Boolean,default:!1}},data:()=>({}),created(){this.popup.maskShow=this.maskShow,this.popup.messageChild=this},methods:{timerClose(){0!==this.duration&&(clearTimeout(this.timer),this.timer=setTimeout((()=>{this.popup.close()}),this.duration))}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-popup-message"},[e.createElementVNode("view",{class:e.normalizeClass(["uni-popup-message__box fixforpc-width","uni-popup__"+n.type])},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("text",{class:e.normalizeClass(["uni-popup-message-text","uni-popup__"+n.type+"-text"])},e.toDisplayString(n.message),3)]),!0)],2)])}],["__scopeId","data-v-d81cfb56"]]),Hr={en:{"uni-popup.cancel":"cancel","uni-popup.ok":"ok","uni-popup.placeholder":"pleace enter","uni-popup.title":"Hint","uni-popup.shareTitle":"Share to"},"zh-Hans":{"uni-popup.cancel":"取消","uni-popup.ok":"确定","uni-popup.placeholder":"请输入","uni-popup.title":"提示","uni-popup.shareTitle":"分享到"},"zh-Hant":{"uni-popup.cancel":"取消","uni-popup.ok":"確定","uni-popup.placeholder":"請輸入","uni-popup.title":"提示","uni-popup.shareTitle":"分享到"}},{t:Wr}=Rl(Hr);const Jr=t({name:"uniPopupDialog",mixins:[jr],emits:["confirm","close","update:modelValue","input"],props:{inputType:{type:String,default:"text"},showClose:{type:Boolean,default:!0},modelValue:{type:[Number,String],default:""},placeholder:{type:[String,Number],default:""},type:{type:String,default:"error"},mode:{type:String,default:"base"},title:{type:String,default:""},content:{type:String,default:""},beforeClose:{type:Boolean,default:!1},cancelText:{type:String,default:""},confirmText:{type:String,default:""},maxlength:{type:Number,default:-1},focus:{type:Boolean,default:!0}},data:()=>({dialogType:"error",val:""}),computed:{okText(){return this.confirmText||Wr("uni-popup.ok")},closeText(){return this.cancelText||Wr("uni-popup.cancel")},placeholderText(){return this.placeholder||Wr("uni-popup.placeholder")},titleText(){return this.title||Wr("uni-popup.title")}},watch:{type(e){this.dialogType=e},mode(e){"input"===e&&(this.dialogType="info")},value(e){-1!=this.maxlength&&"input"===this.mode?this.val=e.slice(0,this.maxlength):this.val=e},val(e){this.$emit("update:modelValue",e)}},created(){this.popup.disableMask(),"input"===this.mode?(this.dialogType="info",this.val=this.value,this.val=this.modelValue):this.dialogType=this.type},methods:{onOk(){"input"===this.mode?this.$emit("confirm",this.val):this.$emit("confirm"),this.beforeClose||this.popup.close()},closeDialog(){this.$emit("close"),this.beforeClose||this.popup.close()},close(){this.popup.close()}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-popup-dialog"},[e.createElementVNode("view",{class:"uni-dialog-title"},[e.createElementVNode("text",{class:e.normalizeClass(["uni-dialog-title-text",["uni-popup__"+o.dialogType]])},e.toDisplayString(s.titleText),3)]),"base"===n.mode?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-dialog-content"},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("text",{class:"uni-dialog-content-text"},e.toDisplayString(n.content),1)]),!0)])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-dialog-content"},[e.renderSlot(t.$slots,"default",{},(()=>[e.withDirectives(e.createElementVNode("input",{class:"uni-dialog-input",maxlength:n.maxlength,"onUpdate:modelValue":a[0]||(a[0]=e=>o.val=e),type:n.inputType,placeholder:s.placeholderText,focus:n.focus},null,8,["maxlength","type","placeholder","focus"]),[[e.vModelDynamic,o.val]])]),!0)])),e.createElementVNode("view",{class:"uni-dialog-button-group"},[n.showClose?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-dialog-button",onClick:a[1]||(a[1]=(...e)=>s.closeDialog&&s.closeDialog(...e))},[e.createElementVNode("text",{class:"uni-dialog-button-text"},e.toDisplayString(s.closeText),1)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["uni-dialog-button",n.showClose?"uni-border-left":""]),onClick:a[2]||(a[2]=(...e)=>s.onOk&&s.onOk(...e))},[e.createElementVNode("text",{class:"uni-dialog-button-text uni-button-color"},e.toDisplayString(s.okText),1)],2)])])}],["__scopeId","data-v-dc2a088f"]]),{t:Gr}=Rl(Hr);const Kr=t({name:"UniPopupShare",mixins:[jr],emits:["select"],props:{title:{type:String,default:""},beforeClose:{type:Boolean,default:!1}},data:()=>({bottomData:[{text:"微信",icon:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png",name:"wx"},{text:"支付宝",icon:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png",name:"ali"},{text:"QQ",icon:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png",name:"qq"},{text:"新浪",icon:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png",name:"sina"}]}),created(){},computed:{cancelText:()=>Gr("uni-popup.cancel"),shareTitleText(){return this.title||Gr("uni-popup.shareTitle")}},methods:{select(e,t){this.$emit("select",{item:e,index:t}),this.close()},close(){this.beforeClose||this.popup.close()}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-popup-share"},[e.createElementVNode("view",{class:"uni-share-title"},[e.createElementVNode("text",{class:"uni-share-title-text"},e.toDisplayString(s.shareTitleText),1)]),e.createElementVNode("view",{class:"uni-share-content"},[e.createElementVNode("view",{class:"uni-share-content-box"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.bottomData,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-share-content-item",key:a,onClick:e.withModifiers((e=>s.select(t,a)),["stop"])},[e.createElementVNode("image",{class:"uni-share-image",src:t.icon,mode:"aspectFill"},null,8,["src"]),e.createElementVNode("text",{class:"uni-share-text"},e.toDisplayString(t.text),1)],8,["onClick"])))),128))])]),e.createElementVNode("view",{class:"uni-share-button-box"},[e.createElementVNode("button",{class:"uni-share-button",onClick:a[0]||(a[0]=(...e)=>s.close&&s.close(...e))},e.toDisplayString(s.cancelText),1)])])}],["__scopeId","data-v-2a810589"]]),Qr={data:()=>({type:"center",msgType:"success",messageText:"这是一条成功提示",value:""}),onReady(){},methods:{change(e){n("log","at pages/extUI/popup/popup.vue:107","当前模式："+e.type+",状态："+e.show)},toggle(e){this.type=e,this.$refs.popup.open(e)},messageToggle(e){this.msgType=e,this.messageText=`这是一条${e}消息提示`,this.$refs.message.open()},dialogToggle(e){this.msgType=e,this.$refs.alertDialog.open()},dialogConfirm(){n("log","at pages/extUI/popup/popup.vue:124","点击确认"),this.messageText=`点击确认了 ${this.msgType} 窗口`,this.$refs.message.open()},inputDialogToggle(){this.$refs.inputDialog.open()},dialogClose(){n("log","at pages/extUI/popup/popup.vue:132","点击关闭")},dialogInputConfirm(e){uni.showLoading({title:"3秒后会关闭"}),setTimeout((()=>{uni.hideLoading(),n("log","at pages/extUI/popup/popup.vue:141",e),this.value=e,this.$refs.inputDialog.close()}),3e3)},shareToggle(){this.$refs.share.open()}}};const Yr=t(Qr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr),d=i(e.resolveDynamicComponent("uni-popup"),Wa),u=i(e.resolveDynamicComponent("uni-popup-message"),qr),h=i(e.resolveDynamicComponent("uni-popup-dialog"),Jr),p=i(e.resolveDynamicComponent("uni-popup-share"),Kr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"弹出层组件用于弹出一个覆盖到页面上的内容，使用场景如：底部弹出分享弹窗、页面插屏广告等。")])),_:1}),e.createVNode(c,{title:"基本示例",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body box"},[e.createElementVNode("button",{class:"button",type:"primary",onClick:a[0]||(a[0]=e=>l.toggle("top"))},[e.createElementVNode("text",{class:"button-text"},"顶部")]),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[1]||(a[1]=e=>l.toggle("bottom"))},[e.createElementVNode("text",{class:"button-text"},"底部")]),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[2]||(a[2]=e=>l.toggle("center"))},[e.createElementVNode("text",{class:"button-text"},"居中")]),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[3]||(a[3]=e=>l.toggle("left"))},[e.createElementVNode("text",{class:"button-text"},"左侧")]),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[4]||(a[4]=e=>l.toggle("right"))},[e.createElementVNode("text",{class:"button-text"},"右侧")])])])),_:1}),e.createVNode(c,{title:"提示消息",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body box"},[e.createElementVNode("button",{class:"button popup-success",onClick:a[5]||(a[5]=e=>l.messageToggle("success"))},[e.createElementVNode("text",{class:"button-text success-text"},"成功")]),e.createElementVNode("button",{class:"button popup-error",onClick:a[6]||(a[6]=e=>l.messageToggle("error"))},[e.createElementVNode("text",{class:"button-text error-text"},"失败")]),e.createElementVNode("button",{class:"button popup-warn",onClick:a[7]||(a[7]=e=>l.messageToggle("warn"))},[e.createElementVNode("text",{class:"button-text warn-text"},"警告")]),e.createElementVNode("button",{class:"button popup-info",onClick:a[8]||(a[8]=e=>l.messageToggle("info"))},[e.createElementVNode("text",{class:"button-text info-text"},"信息")])])])),_:1}),e.createVNode(c,{title:"对话框示例",type:"line",class:"hideOnPc"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body box"},[e.createElementVNode("button",{class:"button popup-success",onClick:a[9]||(a[9]=e=>l.dialogToggle("success"))},[e.createElementVNode("text",{class:"button-text success-text"},"成功")]),e.createElementVNode("button",{class:"button popup-error",onClick:a[10]||(a[10]=e=>l.dialogToggle("error"))},[e.createElementVNode("text",{class:"button-text error-text"},"失败")]),e.createElementVNode("button",{class:"button popup-warn",onClick:a[11]||(a[11]=e=>l.dialogToggle("warn"))},[e.createElementVNode("text",{class:"button-text warn-text"},"警告")]),e.createElementVNode("button",{class:"button popup-info",onClick:a[12]||(a[12]=e=>l.dialogToggle("info"))},[e.createElementVNode("text",{class:"button-text info-text"},"信息")])])])),_:1}),e.createVNode(c,{title:"输入框示例",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"dialog-box"},[e.createElementVNode("text",{class:"dialog-text"},"输入内容："+e.toDisplayString(s.value),1)]),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[13]||(a[13]=(...e)=>l.inputDialogToggle&&l.inputDialogToggle(...e))},[e.createElementVNode("text",{class:"button-text"},"输入对话框")])])),_:1}),e.createVNode(c,{title:"底部分享示例",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("button",{class:"button",type:"primary",onClick:a[14]||(a[14]=(...e)=>l.shareToggle&&l.shareToggle(...e))},[e.createElementVNode("text",{class:"button-text"},"分享模版示例")])])),_:1}),e.createElementVNode("view",null,[e.createVNode(d,{ref:"popup","background-color":"#fff",onChange:l.change},{default:e.withCtx((()=>[e.createElementVNode("view",{class:e.normalizeClass(["popup-content",{"popup-height":"left"===s.type||"right"===s.type}])},[e.createElementVNode("text",{class:"text"},"popup 内容")],2)])),_:1},8,["onChange"])]),e.createElementVNode("view",null,[e.createVNode(d,{ref:"message",type:"message"},{default:e.withCtx((()=>[e.createVNode(u,{type:s.msgType,message:s.messageText,duration:2e3},null,8,["type","message"])])),_:1},512)]),e.createElementVNode("view",null,[e.createVNode(d,{ref:"alertDialog",type:"dialog"},{default:e.withCtx((()=>[e.createVNode(h,{type:s.msgType,cancelText:"关闭",confirmText:"同意",title:"通知",content:"欢迎使用 uni-popup!",onConfirm:l.dialogConfirm,onClose:l.dialogClose},null,8,["type","onConfirm","onClose"])])),_:1},512)]),e.createElementVNode("view",null,[e.createVNode(d,{ref:"inputDialog",type:"dialog"},{default:e.withCtx((()=>[e.createVNode(h,{ref:"inputClose",mode:"input",title:"输入内容",value:"对话框预置提示内容!",placeholder:"请输入内容",onConfirm:l.dialogInputConfirm},null,8,["onConfirm"])])),_:1},512)]),e.createElementVNode("view",null,[e.createVNode(d,{ref:"share",type:"share",safeArea:"",backgroundColor:"#fff"},{default:e.withCtx((()=>[e.createVNode(p)])),_:1},512)])])}]]),Xr={components:{},data:()=>({items:["选项卡1","选项卡2","选项卡3"],styles:[{value:"button",text:"按钮",checked:!0},{value:"text",text:"文字"}],colors:["#007aff","#4cd964","#dd524d"],current:0,colorIndex:0,activeColor:"#007aff",styleType:"button"}),methods:{onClickItem(e){this.current!==e.currentIndex&&(this.current=e.currentIndex)},styleChange(e){this.styleType!==e.detail.value&&(this.styleType=e.detail.value)},colorChange(e){this.styleType!==e.detail.value&&(n("log","at pages/extUI/segmented-control/segmented-control.vue:88",e.detail.value),this.activeColor=e.detail.value)}}};const Zr=t(Xr,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-segmented-control"),Br),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"标签组件多用于商品分类、重点内容显示等场景。")])),_:1}),e.createVNode(d,{title:"实心标签",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createVNode(c,{current:s.current,values:s.items,"style-type":s.styleType,"active-color":s.activeColor,onClickItem:l.onClickItem},null,8,["current","values","style-type","active-color","onClickItem"])]),e.createElementVNode("view",{class:"content"},[0===s.current?(e.openBlock(),e.createElementBlock("view",{key:0},[e.createElementVNode("text",{class:"content-text"},"选项卡1的内容")])):e.createCommentVNode("",!0),1===s.current?(e.openBlock(),e.createElementBlock("view",{key:1},[e.createElementVNode("text",{class:"content-text"},"选项卡2的内容")])):e.createCommentVNode("",!0),2===s.current?(e.openBlock(),e.createElementBlock("view",{key:2},[e.createElementVNode("text",{class:"content-text"},"选项卡3的内容")])):e.createCommentVNode("",!0)])])),_:1}),e.createVNode(d,{title:"Style",type:"line"}),e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("radio-group",{class:"uni-list",onChange:a[0]||(a[0]=(...e)=>l.styleChange&&l.styleChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.styles,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"uni-list-item"},[e.createElementVNode("view",{class:"uni-list-item__container"},[e.createElementVNode("view",{class:"uni-list-item__content"},[e.createElementVNode("text",{class:"uni-list-item__content-title"},e.toDisplayString(t.text),1)]),e.createElementVNode("view",{class:"uni-list-item__extra"},[e.createElementVNode("radio",{value:t.value,checked:t.checked},null,8,["value","checked"])])])])))),128))],32)]),e.createVNode(d,{title:"Color",type:"line"}),e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("radio-group",{class:"uni-list",onChange:a[1]||(a[1]=(...e)=>l.colorChange&&l.colorChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.colors,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"uni-list-item"},[e.createElementVNode("view",{class:"uni-list-item__container"},[e.createElementVNode("view",{class:"uni-list-item__content"},[e.createElementVNode("view",{style:e.normalizeStyle({backgroundColor:t}),class:"color-tag"},null,4)]),e.createElementVNode("view",{class:"uni-list-item__extra"},[e.createElementVNode("radio",{value:t,checked:a===s.colorIndex},null,8,["value","checked"])])])])))),128))],32)])])}]]);const ec=t({name:"uniCollapseItem",props:{title:{type:String,default:""},name:{type:[Number,String],default:""},disabled:{type:Boolean,default:!1},showAnimation:{type:Boolean,default:!1},open:{type:Boolean,default:!1},thumb:{type:String,default:""},titleBorder:{type:String,default:"auto"},border:{type:Boolean,default:!0},showArrow:{type:Boolean,default:!0}},data:()=>({isOpen:!1,isheight:null,height:0,elId:`Uni_${Math.ceil(1e6*Math.random()).toString(36)}`,nameSync:0}),watch:{open(e){this.isOpen=e,this.onClick(e,"init")}},updated(e){this.$nextTick((()=>{this.init(!0)}))},created(){this.collapse=this.getCollapse(),this.oldHeight=0,this.onClick(this.open,"init")},unmounted(){this.__isUnmounted=!0,this.uninstall()},mounted(){this.collapse&&(""!==this.name?this.nameSync=this.name:this.nameSync=this.collapse.childrens.length+"",-1===this.collapse.names.indexOf(this.nameSync)?this.collapse.names.push(this.nameSync):n("warn","at uni_modules/uni-collapse/components/uni-collapse-item/uni-collapse-item.vue:154",`name 值 ${this.nameSync} 重复`),-1===this.collapse.childrens.indexOf(this)&&this.collapse.childrens.push(this),this.init())},methods:{init(e){this.getCollapseHeight(e)},uninstall(){this.collapse&&(this.collapse.childrens.forEach(((e,t)=>{e===this&&this.collapse.childrens.splice(t,1)})),this.collapse.names.forEach(((e,t)=>{e===this.nameSync&&this.collapse.names.splice(t,1)})))},onClick(e,t){this.disabled||(this.isOpen=e,this.isOpen&&this.collapse&&this.collapse.setAccordion(this),"init"!==t&&this.collapse.onChange(e,this))},getCollapseHeight(e,t=0){uni.createSelectorQuery().in(this).select(`#${this.elId}`).fields({size:!0},(a=>{if(!(t>=10)){if(!a)return t++,void this.getCollapseHeight(!1,t);this.height=a.height,this.isheight=!0,e||this.onClick(this.isOpen,"init")}})).exec()},getNvueHwight(e){dom.getComponentRect(this.$refs["collapse--hook"],(t=>{if(t&&t.result&&t.size){if(this.height=t.size.height,this.isheight=!0,e)return;this.onClick(this.open,"init")}}))},getCollapse(e="uniCollapse"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-collapse-item"},[e.createElementVNode("view",{onClick:a[0]||(a[0]=e=>l.onClick(!s.isOpen)),class:e.normalizeClass(["uni-collapse-item__title",{"is-open":s.isOpen&&"auto"===n.titleBorder,"uni-collapse-item-border":"none"!==n.titleBorder}])},[e.createElementVNode("view",{class:"uni-collapse-item__title-wrap"},[e.renderSlot(t.$slots,"title",{},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-collapse-item__title-box",{"is-disabled":n.disabled}])},[n.thumb?(e.openBlock(),e.createElementBlock("image",{key:0,src:n.thumb,class:"uni-collapse-item__title-img"},null,8,["src"])):e.createCommentVNode("",!0),e.createElementVNode("text",{class:"uni-collapse-item__title-text"},e.toDisplayString(n.title),1)],2)]),!0)]),n.showArrow?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass([{"uni-collapse-item__title-arrow-active":s.isOpen,"uni-collapse-item--animation":!0===n.showAnimation},"uni-collapse-item__title-arrow"])},[e.createVNode(r,{color:n.disabled?"#ddd":"#bbb",size:"14",type:"bottom"},null,8,["color"])],2)):e.createCommentVNode("",!0)],2),e.createElementVNode("view",{class:e.normalizeClass(["uni-collapse-item__wrap",{"is--transition":n.showAnimation}]),style:e.normalizeStyle({height:(s.isOpen?s.height:0)+"px"})},[e.createElementVNode("view",{id:s.elId,ref:"collapse--hook",class:e.normalizeClass(["uni-collapse-item__wrap-content",{open:s.isheight,"uni-collapse-item--border":n.border&&s.isOpen}])},[e.renderSlot(t.$slots,"default",{},void 0,!0)],10,["id"])],6)])}],["__scopeId","data-v-b5be0bf0"]]);const tc=t({name:"uniCollapse",emits:["change","activeItem","input","update:modelValue"],props:{value:{type:[String,Array],default:""},modelValue:{type:[String,Array],default:""},accordion:{type:[Boolean,String],default:!1}},data:()=>({}),computed:{dataValue(){let e="string"==typeof this.value&&""===this.value||Array.isArray(this.value)&&0===this.value.length;"string"==typeof this.modelValue&&""===this.modelValue||Array.isArray(this.modelValue)&&this.modelValue.length;return e?this.modelValue:this.value}},watch:{dataValue(e){this.setOpen(e)}},created(){this.childrens=[],this.names=[]},mounted(){this.$nextTick((()=>{this.setOpen(this.dataValue)}))},methods:{setOpen(e){let t="string"==typeof e,a=Array.isArray(e);this.childrens.forEach(((i,o)=>{if(t&&e===i.nameSync){if(!this.accordion)return void n("warn","at uni_modules/uni-collapse/components/uni-collapse/uni-collapse.vue:75","accordion 属性为 false ,v-model 类型应该为 array");i.isOpen=!0}a&&e.forEach((e=>{if(e===i.nameSync){if(this.accordion)return void n("warn","at uni_modules/uni-collapse/components/uni-collapse/uni-collapse.vue:85","accordion 属性为 true ,v-model 类型应该为 string");i.isOpen=!0}}))})),this.emit(e)},setAccordion(e){this.accordion&&this.childrens.forEach(((t,a)=>{e!==t&&(t.isOpen=!1)}))},resize(){this.childrens.forEach(((e,t)=>{e.getCollapseHeight()}))},onChange(e,t){let a=[];this.accordion?a=e?t.nameSync:"":this.childrens.forEach(((e,t)=>{e.isOpen&&a.push(e.nameSync)})),this.$emit("change",a),this.emit(a)},emit(e){this.$emit("input",e),this.$emit("update:modelValue",e)}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-collapse"},[e.renderSlot(t.$slots,"default",{},void 0,!0)])}],["__scopeId","data-v-61e2e72f"]]),ac={name:"UniListItem",emits:["click","switchChange"],props:{direction:{type:String,default:"row"},title:{type:String,default:""},note:{type:String,default:""},ellipsis:{type:[Number,String],default:0},disabled:{type:[Boolean,String],default:!1},clickable:{type:Boolean,default:!1},showArrow:{type:[Boolean,String],default:!1},link:{type:[Boolean,String],default:!1},to:{type:String,default:""},showBadge:{type:[Boolean,String],default:!1},showSwitch:{type:[Boolean,String],default:!1},switchChecked:{type:[Boolean,String],default:!1},badgeText:{type:String,default:""},badgeType:{type:String,default:"success"},badgeStyle:{type:Object,default:()=>({})},rightText:{type:String,default:""},thumb:{type:String,default:""},thumbSize:{type:String,default:"base"},showExtraIcon:{type:[Boolean,String],default:!1},extraIcon:{type:Object,default:()=>({type:"",color:"#000000",size:20,customPrefix:""})},border:{type:Boolean,default:!0},customStyle:{type:Object,default:()=>({padding:"",backgroundColor:"#FFFFFF"})},keepScrollPosition:{type:Boolean,default:!1}},watch:{"customStyle.padding":{handler(e){"number"==typeof e&&(e+="");let t=e.split(" ");if(1===t.length){const e=t[0];this.padding={top:e,right:e,bottom:e,left:e}}else if(2===t.length){const[e,a]=t;this.padding={top:e,right:a,bottom:e,left:a}}else if(4===t.length){const[e,a,n,i]=t;this.padding={top:e,right:a,bottom:n,left:i}}},immediate:!0}},data:()=>({isFirstChild:!1,padding:{top:"",right:"",bottom:"",left:""}}),mounted(){this.list=this.getForm(),this.list&&(this.list.firstChildAppend||(this.list.firstChildAppend=!0,this.isFirstChild=!0))},methods:{getForm(e="uniList"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t},onClick(){""===this.to?(this.clickable||this.link)&&this.$emit("click",{data:{}}):this.openPage()},onSwitchChange(e){this.$emit("switchChange",e.detail)},openPage(){-1!==["navigateTo","redirectTo","reLaunch","switchTab"].indexOf(this.link)?this.pageApi(this.link):this.pageApi("navigateTo")},pageApi(e){let t={url:this.to,success:e=>{this.$emit("click",{data:e})},fail:e=>{this.$emit("click",{data:e})}};switch(e){case"navigateTo":default:uni.navigateTo(t);break;case"redirectTo":uni.redirectTo(t);break;case"reLaunch":uni.reLaunch(t);break;case"switchTab":uni.switchTab(t)}}}};const nc=t(ac,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g),c=i(e.resolveDynamicComponent("uni-badge"),Fr);return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass([{"uni-list-item--disabled":n.disabled},"uni-list-item"]),style:e.normalizeStyle({"background-color":n.customStyle.backgroundColor}),"hover-class":!n.clickable&&!n.link||n.disabled||n.showSwitch?"":"uni-list-item--hover",onClick:a[1]||(a[1]=(...e)=>l.onClick&&l.onClick(...e))},[s.isFirstChild?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["border--left",{"uni-list--border":n.border}])},null,2)),e.createElementVNode("view",{class:e.normalizeClass(["uni-list-item__container",{"container--right":n.showArrow||n.link,"flex--direction":"column"===n.direction}]),style:e.normalizeStyle({paddingTop:s.padding.top,paddingLeft:s.padding.left,paddingRight:s.padding.right,paddingBottom:s.padding.bottom})},[e.renderSlot(t.$slots,"header",{},(()=>[e.createElementVNode("view",{class:"uni-list-item__header"},[n.thumb?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-list-item__icon"},[e.createElementVNode("image",{src:n.thumb,class:e.normalizeClass(["uni-list-item__icon-img",["uni-list--"+n.thumbSize]])},null,10,["src"])])):n.showExtraIcon?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-list-item__icon"},[e.createVNode(r,{customPrefix:n.extraIcon.customPrefix,color:n.extraIcon.color,size:n.extraIcon.size,type:n.extraIcon.type},null,8,["customPrefix","color","size","type"])])):e.createCommentVNode("",!0)])]),!0),e.renderSlot(t.$slots,"body",{},(()=>[e.createElementVNode("view",{class:e.normalizeClass(["uni-list-item__content",{"uni-list-item__content--center":n.thumb||n.showExtraIcon||n.showBadge||n.showSwitch}])},[n.title?(e.openBlock(),e.createElementBlock("text",{key:0,class:e.normalizeClass(["uni-list-item__content-title",[0!==n.ellipsis&&n.ellipsis<=2?"uni-ellipsis-"+n.ellipsis:""]])},e.toDisplayString(n.title),3)):e.createCommentVNode("",!0),n.note?(e.openBlock(),e.createElementBlock("text",{key:1,class:"uni-list-item__content-note"},e.toDisplayString(n.note),1)):e.createCommentVNode("",!0)],2)]),!0),e.renderSlot(t.$slots,"footer",{},(()=>[n.rightText||n.showBadge||n.showSwitch?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-list-item__extra",{"flex--justify":"column"===n.direction}])},[n.rightText?(e.openBlock(),e.createElementBlock("text",{key:0,class:"uni-list-item__extra-text"},e.toDisplayString(n.rightText),1)):e.createCommentVNode("",!0),n.showBadge?(e.openBlock(),e.createBlock(c,{key:1,type:n.badgeType,text:n.badgeText,"custom-style":n.badgeStyle},null,8,["type","text","custom-style"])):e.createCommentVNode("",!0),n.showSwitch?(e.openBlock(),e.createElementBlock("switch",{key:2,disabled:n.disabled,checked:n.switchChecked,onChange:a[0]||(a[0]=(...e)=>l.onSwitchChange&&l.onSwitchChange(...e))},null,40,["disabled","checked"])):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)]),!0)],6),n.showArrow||n.link?(e.openBlock(),e.createBlock(r,{key:1,size:16,class:"uni-icon-wrapper",color:"#bbb",type:"arrowright"})):e.createCommentVNode("",!0)],14,["hover-class"])}],["__scopeId","data-v-380d0f47"]]),ic={name:"uniList","mp-weixin":{options:{multipleSlots:!1}},props:{stackFromEnd:{type:Boolean,default:!1},enableBackToTop:{type:[Boolean,String],default:!1},scrollY:{type:[Boolean,String],default:!1},border:{type:Boolean,default:!0},renderReverse:{type:Boolean,default:!1}},created(){this.firstChildAppend=!1},methods:{loadMore(e){this.$emit("scrolltolower")},scroll(e){this.$emit("scroll",e)}}};const oc=t(ic,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-list uni-border-top-bottom"},[n.border?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-list--border-top"})):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},void 0,!0),n.border?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-list--border-bottom"})):e.createCommentVNode("",!0)])}],["__scopeId","data-v-c1d7c358"]]),sc={components:{},data:()=>({value:["0"],accordionVal:"1",content:"折叠内容主体，可自定义内容及样式，点击按钮修改内容使高度发生变化。",extraIcon:{color:"#4cd964",size:"26",type:"image"}}),methods:{add(){this.content.length>35?this.content="折叠内容主体，可自定义内容及样式，点击按钮修改内容使高度发生变化。":this.content="折叠内容主体，这是一段比较长内容。通过点击按钮修改后内容后，使组件高度发生变化，在次点击按钮恢复之前的内容和高度。"},onClick(e){uni.showToast({title:"列表被点击"})},change(e){n("log","at pages/extUI/collapse/collapse.vue:144",e)}}};const lc=t(sc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-collapse-item"),ec),d=i(e.resolveDynamicComponent("uni-collapse"),tc),u=i(e.resolveDynamicComponent("uni-section"),Tr),h=i(e.resolveDynamicComponent("uni-list-item"),nc),p=i(e.resolveDynamicComponent("uni-list"),oc);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"折叠面板用来折叠/显示过长的内容或者是列表。通常是在多内容分类项使用，折叠不重要的内容，显示重要内容。点击可以展开折叠部分。")])),_:1}),e.createVNode(u,{title:"基础用法",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,{ref:"collapse",modelValue:s.value,"onUpdate:modelValue":a[0]||(a[0]=e=>s.value=e),onChange:l.change},{default:e.withCtx((()=>[e.createVNode(c,{title:"默认开启"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},e.toDisplayString(s.content),1)])])),_:1}),e.createVNode(c,{title:"折叠内容"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"折叠内容主体，这是一段比较长内容。默认折叠主要内容，只显示当前项标题。点击标题展开，才能看到这段文字。再次点击标题，折叠内容。")])])),_:1}),e.createVNode(c,{title:"禁用状态",disabled:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"禁用状态内容主体，页面上是看不到这段话的。")])])),_:1})])),_:1},8,["modelValue","onChange"])])),_:1}),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[1]||(a[1]=(...e)=>l.add&&l.add(...e))},"动态修改内容"),e.createVNode(u,{title:"使用动画效果",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[e.createVNode(c,{title:"使用动画","show-animation":!0},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"默认开启组件动画，使用动画效果折叠内容会有一个从上到下的动画。")])])),_:1}),e.createVNode(c,{title:"不使用动画","show-animation":!1},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},'设置 show-animation="false",关闭当前组件动画效果。')])])),_:1})])),_:1})])),_:1}),e.createVNode(u,{title:"手风琴效果（只会保留一个的打开状态）",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,{accordion:"",modelValue:s.accordionVal,"onUpdate:modelValue":a[2]||(a[2]=e=>s.accordionVal=e),onChange:l.change},{default:e.withCtx((()=>[e.createVNode(c,{title:"手风琴效果"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"手风琴效果同时只会保留一个组件的打开状态，其余组件会自动关闭。")])])),_:1}),e.createVNode(c,{title:"手风琴效果"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"手风琴效果同时只会保留一个组件的打开状态，其余组件会自动关闭。")])])),_:1}),e.createVNode(c,{title:"手风琴效果"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"手风琴效果同时只会保留一个组件的打开状态，其余组件会自动关闭。")])])),_:1})])),_:1},8,["modelValue","onChange"])])),_:1}),e.createVNode(u,{title:"配置图片",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[e.createVNode(c,{title:"标题文字",thumb:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"折叠内容主体，可自定义内容及样式")])])),_:1}),e.createVNode(c,{title:"标题文字",thumb:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"折叠内容主体，可自定义内容及样式")])])),_:1})])),_:1})])),_:1}),e.createVNode(u,{title:"使用插槽",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[e.createVNode(c,{titleBorder:"none"},{title:e.withCtx((()=>[e.createVNode(p,null,{default:e.withCtx((()=>[e.createVNode(h,{title:"标题使用自定义标题插槽","show-extra-icon":!0,"extra-icon":s.extraIcon},null,8,["extra-icon"])])),_:1})])),default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createElementVNode("text",{class:"text"},"折叠内容主体，可自定义内容及样式")])])),_:1}),e.createVNode(c,{title:"折叠内容使用 uni-list 组件"},{default:e.withCtx((()=>[e.createVNode(p,null,{default:e.withCtx((()=>[e.createVNode(h,{title:"列表文字"}),e.createVNode(h,{disabled:!0,title:"列表文字",note:"列表禁用状态"}),e.createVNode(h,{title:"列表右侧显示 switch","show-switch":!0}),e.createVNode(h,{"show-extra-icon":!0,"extra-icon":s.extraIcon,title:"列表左侧带扩展图标"},null,8,["extra-icon"]),e.createVNode(h,{title:"列表左侧带略缩图",note:"列表描述信息",thumb:"https://qiniu-web-assets.dcloud.net.cn/unidoc/zh/unicloudlogo.png","thumb-size":"lg",rightText:"右侧文字",showArrow:""}),e.createVNode(h,{title:"开启点击反馈",clickable:"",showArrow:"",onClick:l.onClick},null,8,["onClick"])])),_:1})])),_:1})])),_:1})])),_:1})])}]]),rc={en:{"uni-pagination.prevText":"prev","uni-pagination.nextText":"next","uni-pagination.piecePerPage":"piece/page"},es:{"uni-pagination.prevText":"anterior","uni-pagination.nextText":"prxima","uni-pagination.piecePerPage":"Art��culo/P��gina"},fr:{"uni-pagination.prevText":"précédente","uni-pagination.nextText":"suivante","uni-pagination.piecePerPage":"Articles/Pages"},"zh-Hans":{"uni-pagination.prevText":"上一页","uni-pagination.nextText":"下一页","uni-pagination.piecePerPage":"条/页"},"zh-Hant":{"uni-pagination.prevText":"上一頁","uni-pagination.nextText":"下一頁","uni-pagination.piecePerPage":"條/頁"}},{t:cc}=Rl(rc),dc={name:"UniPagination",emits:["update:modelValue","input","change","pageSizeChange"],props:{value:{type:[Number,String],default:1},modelValue:{type:[Number,String],default:1},prevText:{type:String},nextText:{type:String},piecePerPageText:{type:String},current:{type:[Number,String],default:1},total:{type:[Number,String],default:0},pageSize:{type:[Number,String],default:10},showIcon:{type:[Boolean,String],default:!1},showPageSize:{type:[Boolean,String],default:!1},pagerCount:{type:Number,default:7},pageSizeRange:{type:Array,default:()=>[20,50,100,500]}},data:()=>({pageSizeIndex:0,currentIndex:1,paperData:[],pickerShow:!1}),computed:{piecePerPage(){return this.piecePerPageText||cc("uni-pagination.piecePerPage")},prevPageText(){return this.prevText||cc("uni-pagination.prevText")},nextPageText(){return this.nextText||cc("uni-pagination.nextText")},maxPage(){let e=1,t=Number(this.total),a=Number(this.pageSize);return t&&a&&(e=Math.ceil(t/a)),e},paper(){const e=this.currentIndex,t=this.pagerCount,a=this.total,n=this.pageSize;let i=[],o=[],s=Math.ceil(a/n);for(let r=0;r<s;r++)i.push(r+1);o.push(1);const l=i[i.length-(t+1)/2];return i.forEach(((a,n)=>{(t+1)/2>=e?a<t+1&&a>1&&o.push(a):e+2<=l?a>e-(t+1)/2&&a<e+(t+1)/2&&o.push(a):(a>e-(t+1)/2||s-t<a)&&a<i[i.length-1]&&o.push(a)})),s>t?((t+1)/2>=e?o[o.length-1]="...":e+2<=l?(o[1]="...",o[o.length-1]="..."):o[1]="...",o.push(i[i.length-1])):(t+1)/2>=e||e+2<=l||(o.shift(),o.push(i[i.length-1])),o}},watch:{current:{immediate:!0,handler(e,t){this.currentIndex=e<1?1:e}},value:{immediate:!0,handler(e){1===Number(this.current)&&(this.currentIndex=e<1?1:e)}},pageSizeIndex(e){this.$emit("pageSizeChange",this.pageSizeRange[e])}},methods:{pickerChange(e){this.pageSizeIndex=e.detail.value,this.pickerClick()},pickerClick(){},selectPage(e,t){if(parseInt(e))this.currentIndex=e,this.change("current");else{let e=Math.ceil(this.total/this.pageSize);if(t<=1)return void(this.currentIndex-5>1?this.currentIndex-=5:this.currentIndex=1);if(t>=6)return void(this.currentIndex+5>e?this.currentIndex=e:this.currentIndex+=5)}},clickLeft(){1!==Number(this.currentIndex)&&(this.currentIndex-=1,this.change("prev"))},clickRight(){Number(this.currentIndex)>=this.maxPage||(this.currentIndex+=1,this.change("next"))},change(e){this.$emit("input",this.currentIndex),this.$emit("update:modelValue",this.currentIndex),this.$emit("change",{type:e,current:this.currentIndex})}}};const uc=t(dc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-pagination"},[!0===n.showPageSize||"true"===n.showPageSize?(e.openBlock(),e.createElementBlock("picker",{key:0,class:"select-picker",mode:"selector",value:s.pageSizeIndex,range:n.pageSizeRange,onChange:a[0]||(a[0]=(...e)=>l.pickerChange&&l.pickerChange(...e)),onCancel:a[1]||(a[1]=(...e)=>l.pickerClick&&l.pickerClick(...e)),onClick:a[2]||(a[2]=(...e)=>l.pickerClick&&l.pickerClick(...e))},[e.createElementVNode("button",{type:"default",size:"mini",plain:!0},[e.createElementVNode("text",null,e.toDisplayString(n.pageSizeRange[s.pageSizeIndex])+" "+e.toDisplayString(l.piecePerPage),1),e.createVNode(r,{class:"select-picker-icon",type:"arrowdown",size:"12",color:"#999"})])],40,["value","range"])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-pagination__total is-phone-hide"},"共 "+e.toDisplayString(n.total)+" 条",1),e.createElementVNode("view",{class:e.normalizeClass(["uni-pagination__btn",1===s.currentIndex?"uni-pagination--disabled":"uni-pagination--enabled"]),"hover-class":1===s.currentIndex?"":"uni-pagination--hover","hover-start-time":20,"hover-stay-time":70,onClick:a[3]||(a[3]=(...e)=>l.clickLeft&&l.clickLeft(...e))},[!0===n.showIcon||"true"===n.showIcon?(e.openBlock(),e.createBlock(r,{key:0,color:"#666",size:"16",type:"left"})):(e.openBlock(),e.createElementBlock("text",{key:1,class:"uni-pagination__child-btn"},e.toDisplayString(l.prevPageText),1))],10,["hover-class"]),e.createElementVNode("view",{class:"uni-pagination__num uni-pagination__num-flex-none"},[e.createElementVNode("view",{class:"uni-pagination__num-current"},[e.createElementVNode("text",{class:"uni-pagination__num-current-text is-pc-hide current-index-text"},e.toDisplayString(s.currentIndex),1),e.createElementVNode("text",{class:"uni-pagination__num-current-text is-pc-hide"},"/"+e.toDisplayString(l.maxPage||0),1),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.paper,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass([{"page--active":t===s.currentIndex},"uni-pagination__num-tag tag--active is-phone-hide"]),onClick:e=>l.selectPage(t,a)},[e.createElementVNode("text",null,e.toDisplayString(t),1)],10,["onClick"])))),128))])]),e.createElementVNode("view",{class:e.normalizeClass(["uni-pagination__btn",s.currentIndex>=l.maxPage?"uni-pagination--disabled":"uni-pagination--enabled"]),"hover-class":s.currentIndex===l.maxPage?"":"uni-pagination--hover","hover-start-time":20,"hover-stay-time":70,onClick:a[4]||(a[4]=(...e)=>l.clickRight&&l.clickRight(...e))},[!0===n.showIcon||"true"===n.showIcon?(e.openBlock(),e.createBlock(r,{key:0,color:"#666",size:"16",type:"right"})):(e.openBlock(),e.createElementBlock("text",{key:1,class:"uni-pagination__child-btn"},e.toDisplayString(l.nextPageText),1))],10,["hover-class"])])}],["__scopeId","data-v-e95c131e"]]),hc={components:{},data:()=>({current:3,total:10,pageSize:10}),mounted(){setTimeout((()=>{this.current=5}),3e3)},methods:{add(){this.total+=10},reset(){this.total=0,this.current=1},change(e){n("log","at pages/extUI/pagination/pagination.vue:55",e),this.current=e.current}}};const pc=t(hc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-pagination"),uc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"分页器组件，用于展示页码、请求数据等")])),_:1}),e.createVNode(d,{title:"默认样式",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{total:50,title:"标题文字"})])),_:1}),e.createVNode(d,{title:"修改按钮文字",subTitle:"使用 prev-text / next-text 属性修改按钮文字",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{total:50,title:"标题文字","prev-text":"前一页","next-text":"后一页"})])),_:1}),e.createVNode(d,{title:"图标样式",subTitle:"使用 show-icon 属性显示图标按钮",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{"show-icon":!0,total:50,title:"标题文字"})])),_:1}),e.createVNode(d,{title:"修改数据长度",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{current:s.current,total:s.total,pageSize:20,title:"标题文字","show-icon":!0,onChange:l.change},null,8,["current","total","onChange"]),e.createElementVNode("view",{class:"btn-view"},[e.createElementVNode("view",null,[e.createElementVNode("text",{class:"example-info"},"当前页："+e.toDisplayString(s.current)+"，数据总量："+e.toDisplayString(s.total)+"条，每页数据："+e.toDisplayString(s.pageSize),1)]),e.createElementVNode("view",{class:"btn-flex"},[e.createElementVNode("button",{class:"button word-btn","hover-class":"word-btn--hover","hover-start-time":20,"hover-stay-time":70,onClick:a[0]||(a[0]=(...e)=>l.add&&l.add(...e))},[e.createElementVNode("text",{class:"word-btn-white"},"增加10条数据")]),e.createElementVNode("button",{class:"button",type:"default",onClick:a[1]||(a[1]=(...e)=>l.reset&&l.reset(...e))},"重置数据")])])])),_:1})])}]]);const mc=t({name:"UniSteps",props:{direction:{type:String,default:"row"},activeColor:{type:String,default:"#2979FF"},deactiveColor:{type:String,default:"#B7BDC6"},active:{type:Number,default:0},activeIcon:{type:String,default:"checkbox-filled"},options:{type:Array,default:()=>[]}},data:()=>({heightArr:[]}),mounted(){if("column"===this.direction){let e=this;uni.createSelectorQuery().in(this).selectAll(".uni-steps__column-text").boundingClientRect((t=>{e.heightArr=t.map((e=>e.height+1))})).exec()}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-steps"},[e.createElementVNode("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column":"uni-steps__row"])},[e.createElementVNode("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column-text-container":"uni-steps__row-text-container"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.options,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass(["column"===n.direction?"uni-steps__column-text":"uni-steps__row-text"])},[e.createElementVNode("text",{style:e.normalizeStyle({color:a===n.active?n.activeColor:n.deactiveColor}),class:e.normalizeClass(["column"===n.direction?"uni-steps__column-title":"uni-steps__row-title"])},e.toDisplayString(t.title),7),e.createElementVNode("text",{style:e.normalizeStyle({color:n.deactiveColor}),class:e.normalizeClass(["column"===n.direction?"uni-steps__column-desc":"uni-steps__row-desc"])},e.toDisplayString(t.desc),7)],2)))),128))],2),e.createElementVNode("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column-container":"uni-steps__row-container"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.options,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column-line-item":"uni-steps__row-line-item"]),key:a,style:e.normalizeStyle({height:"column"===n.direction?s.heightArr[a]+"px":"14px"})},[e.createElementVNode("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column-line":"uni-steps__row-line","column"===n.direction?"uni-steps__column-line--before":"uni-steps__row-line--before"]),style:e.normalizeStyle({backgroundColor:a<=n.active&&0!==a?n.activeColor:0===a?"transparent":n.deactiveColor})},null,6),a===n.active?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["column"===n.direction?"uni-steps__column-check":"uni-steps__row-check"])},[e.createVNode(r,{color:n.activeColor,type:n.activeIcon,size:"14"},null,8,["color","type"])],2)):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["column"===n.direction?"uni-steps__column-circle":"uni-steps__row-circle"]),style:e.normalizeStyle({backgroundColor:a<n.active?n.activeColor:n.deactiveColor})},null,6)),e.createElementVNode("view",{class:e.normalizeClass(["column"===n.direction?"uni-steps__column-line":"uni-steps__row-line","column"===n.direction?"uni-steps__column-line--after":"uni-steps__row-line--after"]),style:e.normalizeStyle({backgroundColor:a<n.active&&a!==n.options.length-1?n.activeColor:a===n.options.length-1?"transparent":n.deactiveColor})},null,6)],6)))),128))],2)],2)])}],["__scopeId","data-v-3c69c4c5"]]);const gc=t({components:{},data:()=>({active:1,list1:[{title:"事件一"},{title:"事件二"},{title:"事件三"},{title:"事件四"}],list2:[{title:"买家下单",desc:"2018-11-11"},{title:"卖家发货",desc:"2018-11-12"},{title:"买家签收",desc:"2018-11-13"},{title:"交易完成",desc:"2018-11-14"}]}),methods:{change(){this.active<this.list1.length-1?this.active+=1:this.active=0}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-steps"),mc),c=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"基本用法",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(r,{options:s.list1,active:s.active},null,8,["options","active"])])),_:1}),e.createVNode(c,{title:"自定义图标",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(r,{options:s.list1,"active-icon":"checkbox",active:s.active},null,8,["options","active"])])),_:1}),e.createVNode(c,{title:"自定义图标",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(r,{options:s.list1,"active-icon":"medal",active:s.active},null,8,["options","active"])])),_:1}),e.createVNode(c,{title:"纵向排列",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(r,{options:s.list2,"active-color":"#007AFF",active:s.active,direction:"column"},null,8,["options","active"])])),_:1}),e.createElementVNode("button",{type:"primary",size:"mini",style:{margin:"30px 10px",width:"100px"},onClick:a[0]||(a[0]=(...e)=>l.change&&l.change(...e))},"改变状态")])}]]);const fc=t({name:"UniNoticeBar",emits:["click","getmore","close"],props:{text:{type:String,default:""},moreText:{type:String,default:""},backgroundColor:{type:String,default:"#FFF9EA"},speed:{type:Number,default:100},color:{type:String,default:"#FF9A43"},fontSize:{type:Number,default:14},moreColor:{type:String,default:"#FF9A43"},single:{type:[Boolean,String],default:!1},scrollable:{type:[Boolean,String],default:!1},showIcon:{type:[Boolean,String],default:!1},showGetMore:{type:[Boolean,String],default:!1},showClose:{type:[Boolean,String],default:!1}},data:()=>({textWidth:0,boxWidth:0,wrapWidth:"",webviewHide:!1,elId:`Uni_${Math.ceil(1e6*Math.random()).toString(36)}`,elIdBox:`Uni_${Math.ceil(1e6*Math.random()).toString(36)}`,show:!0,animationDuration:"none",animationPlayState:"paused",animationDelay:"0s"}),watch:{text:function(e,t){this.initSize()}},computed:{isShowGetMore(){return!0===this.showGetMore||"true"===this.showGetMore},isShowClose(){return!(!0!==this.showClose&&"true"!==this.showClose||!1!==this.showGetMore&&"false"!==this.showGetMore)}},mounted(){var e=getCurrentPages(),t=e[e.length-1].$getAppWebview();t.addEventListener("hide",(()=>{this.webviewHide=!0})),t.addEventListener("show",(()=>{this.webviewHide=!1})),this.$nextTick((()=>{this.initSize()}))},methods:{initSize(){if(this.scrollable){let e=[],t=new Promise(((e,t)=>{uni.createSelectorQuery().in(this).select(`#${this.elId}`).boundingClientRect().exec((t=>{this.textWidth=t[0].width,e()}))})),a=new Promise(((e,t)=>{uni.createSelectorQuery().in(this).select(`#${this.elIdBox}`).boundingClientRect().exec((t=>{this.boxWidth=t[0].width,e()}))}));e.push(t),e.push(a),Promise.all(e).then((()=>{this.animationDuration=this.textWidth/this.speed+"s",this.animationDelay=`-${this.boxWidth/this.speed}s`,setTimeout((()=>{this.animationPlayState="running"}),1e3)}))}},loopAnimation(){},clickMore(){this.$emit("getmore")},close(){this.show=!1,this.$emit("close")},onClick(){this.$emit("click")}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return s.show?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-noticebar",style:e.normalizeStyle({backgroundColor:n.backgroundColor}),onClick:a[1]||(a[1]=(...e)=>l.onClick&&l.onClick(...e))},[!0===n.showIcon||"true"===n.showIcon?(e.openBlock(),e.createBlock(r,{key:0,class:"uni-noticebar-icon",type:"sound",color:n.color,size:1.5*n.fontSize},null,8,["color","size"])):e.createCommentVNode("",!0),e.createElementVNode("view",{ref:"textBox",class:e.normalizeClass(["uni-noticebar__content-wrapper",{"uni-noticebar__content-wrapper--scrollable":n.scrollable,"uni-noticebar__content-wrapper--single":!n.scrollable&&(n.single||n.moreText)}]),style:e.normalizeStyle({height:n.scrollable?1.5*n.fontSize+"px":"auto"})},[e.createElementVNode("view",{id:s.elIdBox,class:e.normalizeClass(["uni-noticebar__content",{"uni-noticebar__content--scrollable":n.scrollable,"uni-noticebar__content--single":!n.scrollable&&(n.single||n.moreText)}])},[e.createElementVNode("text",{id:s.elId,ref:"animationEle",class:e.normalizeClass(["uni-noticebar__content-text",{"uni-noticebar__content-text--scrollable":n.scrollable,"uni-noticebar__content-text--single":!n.scrollable&&(n.single||n.showGetMore)}]),style:e.normalizeStyle({color:n.color,fontSize:n.fontSize+"px",lineHeight:1.5*n.fontSize+"px",width:s.wrapWidth+"px",animationDuration:s.animationDuration,"-webkit-animationDuration":s.animationDuration,animationPlayState:s.webviewHide?"paused":s.animationPlayState,"-webkit-animationPlayState":s.webviewHide?"paused":s.animationPlayState,animationDelay:s.animationDelay,"-webkit-animationDelay":s.animationDelay})},e.toDisplayString(n.text),15,["id"])],10,["id"])],6),l.isShowGetMore?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-noticebar__more uni-cursor-point",onClick:a[0]||(a[0]=(...e)=>l.clickMore&&l.clickMore(...e))},[n.moreText.length>0?(e.openBlock(),e.createElementBlock("text",{key:0,style:e.normalizeStyle({color:n.moreColor,fontSize:n.fontSize+"px"})},e.toDisplayString(n.moreText),5)):(e.openBlock(),e.createBlock(r,{key:1,type:"right",color:n.moreColor,size:1.1*n.fontSize},null,8,["color","size"]))])):e.createCommentVNode("",!0),l.isShowClose?(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-noticebar-close uni-cursor-point"},[e.createVNode(r,{type:"closeempty",color:n.color,size:1.1*n.fontSize,onClick:l.close},null,8,["color","size","onClick"])])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)}],["__scopeId","data-v-a43ccb02"]]);const yc=t({components:{},data:()=>({}),created(){},methods:{getMore(){uni.showToast({title:"点击查看更多",icon:"none"})}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-notice-bar"),fc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"通告栏组件多用于系统通知，广告通知等场景，可自定义图标，颜色，展现方式等。")])),_:1}),e.createVNode(d,{title:"多行显示",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{text:"uni-app 版正式发布，开发一次，同时发布iOS、Android、H5、微信小程序、支付宝小程序、百度小程序、头条小程序等7大平台。"})])),_:1}),e.createVNode(d,{title:"单行显示",subTitle:"使用 single 属性单行显示通知",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{single:"",text:"uni-app 版正式发布，开发一次，同时发布iOS、Android、H5、微信小程序、支付宝小程序、百度小程序、头条小程序等7大平台。"})])),_:1}),e.createVNode(d,{title:"显示图标",subTitle:"使用 show-icon 属性显示左侧小喇叭图标",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{"show-icon":"",text:"uni-app发布，开发一次、7端覆盖！"})])),_:1}),e.createVNode(d,{title:"文字滚动",subTitle:"使用 scrollable 属性使通告滚动,此时 single 属性将失效,始终单行显示",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{"show-icon":"",scrollable:"",text:"uni-app 版正式发布，开发一次，同时发布iOS、Android、H5、微信小程序、支付宝小程序、百度小程序、头条小程序等7大平台。"})])),_:1}),e.createVNode(d,{title:"查看更多",subTitle:"使用 show-get-more 显示更多,此时 single 属性将失效,始终单行显示,如不配置 more-text 属性 ,将显示箭头图标",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{"show-get-more":"","show-icon":"",text:"年末大礼：uni-app1.4 新增百度、支付宝小程序。插件市场重磅上线！",onGetmore:l.getMore},null,8,["onGetmore"]),e.createVNode(c,{"show-get-more":"","show-icon":"","more-text":"查看更多",text:"年末大礼：uni-app1.4 新增百度、支付宝小程序。插件市场重磅上线！",onGetmore:l.getMore},null,8,["onGetmore"])])),_:1}),e.createVNode(d,{title:"修改颜色",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{single:"",color:"#2979FF","background-color":"#EAF2FF",text:"uni-app 1.6版正式发布，开发一次，同时发布iOS、Android、H5、微信小程序、支付宝小程序、百度小程序、头条小程序等7大平台。"})])),_:1}),e.createVNode(d,{title:"关闭按钮",subTitle:"使用 show-close 属性,可关闭通知",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{"show-close":"",single:"",text:"HBuilderX 1.0正式发布！uni-app实现里程碑突破实现里程碑突破！"})])),_:1})])}]]);let vc={};vc={data:()=>({is_show:"none"}),watch:{show(e){this.is_show=this.show}},created(){this.swipeaction=this.getSwipeAction(),this.swipeaction&&Array.isArray(this.swipeaction.children)&&this.swipeaction.children.push(this)},mounted(){this.is_show=this.show},methods:{closeSwipe(e){this.autoClose&&this.swipeaction&&this.swipeaction.closeOther(this)},change(e){this.$emit("change",e.open),this.is_show!==e.open&&(this.is_show=e.open)},appTouchStart(e){const{clientX:t}=e.changedTouches[0];this.clientX=t,this.timestamp=(new Date).getTime()},appTouchEnd(e,t,a,n){const{clientX:i}=e.changedTouches[0];let o=Math.abs(this.clientX-i),s=(new Date).getTime()-this.timestamp;o<40&&s<300&&this.$emit("click",{content:a,index:t,position:n})},onClickForPC(e,t,a){}}};const wc=e=>{(e.$wxs||(e.$wxs=[])).push("wxsswipe"),(e.$wxsModules||(e.$wxsModules={})).wxsswipe="afd46426"},bc=e=>{(e.$renderjs||(e.$renderjs=[])).push("renderswipe"),(e.$renderjsModules||(e.$renderjsModules={})).renderswipe="5a1e922e"},kc={mixins:[vc,{},{}],emits:["click","change"],props:{show:{type:String,default:"none"},disabled:{type:Boolean,default:!1},autoClose:{type:Boolean,default:!0},threshold:{type:Number,default:20},leftOptions:{type:Array,default:()=>[]},rightOptions:{type:Array,default:()=>[]}},unmounted(){this.__isUnmounted=!0,this.uninstall()},methods:{uninstall(){this.swipeaction&&this.swipeaction.children.forEach(((e,t)=>{e===this&&this.swipeaction.children.splice(t,1)}))},getSwipeAction(e="uniSwipeAction"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}};wc(kc),bc(kc);const xc=t(kc,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-swipe"},[e.createElementVNode("view",{class:"uni-swipe_box","change:prop":t.renderswipe.showWatch,prop:e.wp(t.is_show),"data-threshold":n.threshold,"data-disabled":n.disabled+"",onTouchstart:a[2]||(a[2]=(...e)=>t.renderswipe.touchstart&&t.renderswipe.touchstart(...e)),onTouchmove:a[3]||(a[3]=(...e)=>t.renderswipe.touchmove&&t.renderswipe.touchmove(...e)),onTouchend:a[4]||(a[4]=(...e)=>t.renderswipe.touchend&&t.renderswipe.touchend(...e))},[e.createElementVNode("view",{class:"uni-swipe_button-group button-group--left"},[e.renderSlot(t.$slots,"left",{},(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.leftOptions,((n,i)=>(e.openBlock(),e.createElementBlock("view",{key:i,style:e.normalizeStyle({backgroundColor:n.style&&n.style.backgroundColor?n.style.backgroundColor:"#C7C6CD"}),class:"uni-swipe_button button-hock",onTouchstart:a[0]||(a[0]=e.withModifiers(((...e)=>t.appTouchStart&&t.appTouchStart(...e)),["stop"])),onTouchend:e.withModifiers((e=>t.appTouchEnd(e,i,n,"left")),["stop"]),onClick:e.withModifiers((e=>t.onClickForPC(i,n,"left")),["stop"])},[e.createElementVNode("text",{class:"uni-swipe_button-text",style:e.normalizeStyle({color:n.style&&n.style.color?n.style.color:"#FFFFFF",fontSize:n.style&&n.style.fontSize?n.style.fontSize:"16px"})},e.toDisplayString(n.text),5)],44,["onTouchend","onClick"])))),128))]),!0)]),e.createElementVNode("view",{class:"uni-swipe_text--center"},[e.renderSlot(t.$slots,"default",{},void 0,!0)]),e.createElementVNode("view",{class:"uni-swipe_button-group button-group--right"},[e.renderSlot(t.$slots,"right",{},(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.rightOptions,((n,i)=>(e.openBlock(),e.createElementBlock("view",{key:i,style:e.normalizeStyle({backgroundColor:n.style&&n.style.backgroundColor?n.style.backgroundColor:"#C7C6CD"}),class:"uni-swipe_button button-hock",onTouchstart:a[1]||(a[1]=e.withModifiers(((...e)=>t.appTouchStart&&t.appTouchStart(...e)),["stop"])),onTouchend:e.withModifiers((e=>t.appTouchEnd(e,i,n,"right")),["stop"]),onClick:e.withModifiers((e=>t.onClickForPC(i,n,"right")),["stop"])},[e.createElementVNode("text",{class:"uni-swipe_button-text",style:e.normalizeStyle({color:n.style&&n.style.color?n.style.color:"#FFFFFF",fontSize:n.style&&n.style.fontSize?n.style.fontSize:"16px"})},e.toDisplayString(n.text),5)],44,["onTouchend","onClick"])))),128))]),!0)])],40,["change:prop","prop","data-threshold","data-disabled"])])}],["__scopeId","data-v-1a99cb91"]]);const Vc=t({name:"uniSwipeAction",data:()=>({}),created(){this.children=[]},methods:{resize(){},closeAll(){this.children.forEach((e=>{e.is_show="none"}))},closeOther(e){this.openItem&&this.openItem!==e&&(this.openItem.is_show="none"),this.openItem=e}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.renderSlot(t.$slots,"default")])}]]),Nc={components:{},data:()=>({show:!1,isOpened:"none",options1:[{text:"取消置顶"}],options2:[{text:"取消",style:{backgroundColor:"#007aff"}},{text:"确认",style:{backgroundColor:"#F56C6C"}}],swipeList:[{options:[{text:"添加",style:{backgroundColor:"#F56C6C"}}],id:0,content:"左滑点击添加新增一条数据"},{id:1,options:[{text:"置顶"},{text:"删除",style:{backgroundColor:"rgb(255,58,49)"}}],content:"item2"},{id:2,options:[{text:"置顶"},{text:"标记为已读",style:{backgroundColor:"rgb(254,156,1)"}},{text:"删除",style:{backgroundColor:"rgb(255,58,49)"}}],content:"item3"}]}),onReady(){setTimeout((()=>{this.isOpened="right"}),1e3),uni.$on("update",(e=>{n("log","at pages/extUI/swipe-action/swipe-action.vue:187",111),this.swipeClick({content:{text:"添加"}})}))},methods:{contentClick(){n("log","at pages/extUI/swipe-action/swipe-action.vue:197","点击内容"),uni.showToast({title:"点击内容",icon:"none"})},bindClick(e){n("log","at pages/extUI/swipe-action/swipe-action.vue:204",e),uni.showToast({title:`点击了${"left"===e.position?"左侧":"右侧"} ${e.content.text}按钮`,icon:"none"})},setOpened(){"none"!==this.isOpened?"left"!==this.isOpened?"right"!==this.isOpened||(this.isOpened="none"):this.isOpened="right":this.isOpened="left"},change(e){this.isOpened=e,n("log","at pages/extUI/swipe-action/swipe-action.vue:226","返回：",e)},swipeChange(e,t){n("log","at pages/extUI/swipe-action/swipe-action.vue:229","返回：",e),n("log","at pages/extUI/swipe-action/swipe-action.vue:230","当前索引：",t)},swipeClick(e,t){let{content:a}=e;"删除"===a.text?uni.showModal({title:"提示",content:"是否删除",success:e=>{e.confirm?this.swipeList.splice(t,1):e.cancel&&n("log","at pages/extUI/swipe-action/swipe-action.vue:244","用户点击取消")}}):"添加"===a.text?this.swipeList.length<10?(this.swipeList.push({id:(new Date).getTime(),options:[{text:"置顶"},{text:"标记为已读",style:{backgroundColor:"rgb(254,156,1)"}},{text:"删除",style:{backgroundColor:"rgb(255,58,49)"}}],content:"新增"+(new Date).getTime()}),uni.showToast({title:"添加了一条数据",icon:"none"})):uni.showToast({title:"最多添加十条数据",icon:"none"}):uni.showToast({title:`点击了${e.content.text}按钮`,icon:"none"})}}};const Ec=t(Nc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr),d=i(e.resolveDynamicComponent("uni-swipe-action-item"),xc),u=i(e.resolveDynamicComponent("uni-swipe-action"),Vc);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"通过滑动触发选项的容器，容器内可放置列表等组件，通过左右滑动来触发一些操作。")])),_:1}),e.createVNode(c,{title:"基本用法",type:"line"}),e.createVNode(u,null,{default:e.withCtx((()=>[e.createVNode(d,{"left-options":s.options2,threshold:0,"right-options":s.options1,onClick:l.bindClick},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box",onClick:a[0]||(a[0]=(...e)=>l.contentClick&&l.contentClick(...e))},[e.createElementVNode("text",{class:"content-text"},"使用数据填充")])])),_:1},8,["left-options","right-options","onClick"]),e.createVNode(d,{onClick:l.bindClick},{left:e.withCtx((()=>[e.createElementVNode("view",{class:"slot-button"},[e.createElementVNode("text",{class:"slot-button-text",onClick:a[1]||(a[1]=e=>l.bindClick({position:"left",content:{text:"置顶"}}))},"置顶")])])),right:e.withCtx((()=>[e.createElementVNode("view",{class:"slot-button",onClick:a[3]||(a[3]=e=>l.bindClick({position:"right",content:{text:"删除"}}))},[e.createElementVNode("text",{class:"slot-button-text"},"删除")])])),default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box",onClick:a[2]||(a[2]=(...e)=>l.contentClick&&l.contentClick(...e))},[e.createElementVNode("text",{class:"content-text"},"使用左右插槽")])])),_:1},8,["onClick"]),e.createVNode(d,{"right-options":s.options1,onClick:l.bindClick},{left:e.withCtx((()=>[e.createElementVNode("view",{class:"slot-button"},[e.createElementVNode("text",{class:"slot-button-text",onClick:a[4]||(a[4]=e=>l.bindClick({position:"left",content:{text:"置顶"}}))},"置顶")])])),default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box",onClick:a[5]||(a[5]=(...e)=>l.contentClick&&l.contentClick(...e))},[e.createElementVNode("text",{class:"content-text"},"数据与插槽混合使用")])])),_:1},8,["right-options","onClick"])])),_:1}),e.createVNode(c,{title:"禁止滑动",type:"line"}),e.createVNode(u,null,{default:e.withCtx((()=>[e.createVNode(d,{disabled:!0},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box"},[e.createElementVNode("text",{class:"content-text"},"禁止左右滚动")])])),_:1})])),_:1}),e.createVNode(c,{title:"使用变量控制开关",type:"line"}),e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("view",{class:"button",onClick:a[6]||(a[6]=(...e)=>l.setOpened&&l.setOpened(...e))},[e.createElementVNode("text",{class:"button-text"},"当前状态："+e.toDisplayString(s.isOpened),1)])]),e.createVNode(u,null,{default:e.withCtx((()=>[e.createVNode(d,{"left-options":s.options2,"right-options":s.options2,show:s.isOpened,"auto-close":!1,onChange:l.change,onClick:l.bindClick},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box"},[e.createElementVNode("text",{class:"content-text"},"使用变量控制SwipeAction的开启状态")])])),_:1},8,["left-options","right-options","show","onChange","onClick"])])),_:1}),e.createVNode(c,{title:"swipe-action 列表",type:"line"}),e.createVNode(u,{ref:"swipeAction"},{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.swipeList,((t,a)=>(e.openBlock(),e.createBlock(d,{"right-options":t.options,key:t.id,onChange:e=>l.swipeChange(e,a),onClick:e=>l.swipeClick(e,a)},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content-box"},[e.createElementVNode("text",{class:"content-text"},e.toDisplayString(t.content),1)])])),_:2},1032,["right-options","onChange","onClick"])))),128))])),_:1},512)])}]]),Cc={en:{"uni-search-bar.cancel":"cancel","uni-search-bar.placeholder":"Search enter content"},"zh-Hans":{"uni-search-bar.cancel":"取消","uni-search-bar.placeholder":"请输入搜索内容"},"zh-Hant":{"uni-search-bar.cancel":"取消","uni-search-bar.placeholder":"請輸入搜索內容"}},{t:_c}=Rl(Cc),Sc={name:"UniSearchBar",emits:["input","update:modelValue","clear","cancel","confirm","blur","focus"],props:{placeholder:{type:String,default:""},radius:{type:[Number,String],default:5},clearButton:{type:String,default:"auto"},cancelButton:{type:String,default:"auto"},cancelText:{type:String,default:""},bgColor:{type:String,default:"#F8F8F8"},textColor:{type:String,default:"#000000"},maxlength:{type:[Number,String],default:100},value:{type:[Number,String],default:""},modelValue:{type:[Number,String],default:""},focus:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},data:()=>({show:!1,showSync:!1,searchVal:""}),computed:{cancelTextI18n(){return this.cancelText||_c("uni-search-bar.cancel")},placeholderText(){return this.placeholder||_c("uni-search-bar.placeholder")}},watch:{modelValue:{immediate:!0,handler(e){this.searchVal=e,e&&(this.show=!0)}},focus:{immediate:!0,handler(e){if(e){if(this.readonly)return;this.show=!0,this.$nextTick((()=>{this.showSync=!0}))}}},searchVal(e,t){this.$emit("input",e),this.$emit("update:modelValue",e)}},methods:{searchClick(){this.readonly||this.show||(this.show=!0,this.$nextTick((()=>{this.showSync=!0})))},clear(){this.searchVal="",this.$nextTick((()=>{this.$emit("clear",{value:""})}))},cancel(){this.readonly||(this.$emit("cancel",{value:this.searchVal}),this.searchVal="",this.show=!1,this.showSync=!1,plus.key.hideSoftKeybord())},confirm(){plus.key.hideSoftKeybord(),this.$emit("confirm",{value:this.searchVal})},blur(){plus.key.hideSoftKeybord(),this.$emit("blur",{value:this.searchVal})},emitFocus(e){this.$emit("focus",e.detail)}}};const Tc=t(Sc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-searchbar"},[e.createElementVNode("view",{style:e.normalizeStyle({borderRadius:n.radius+"px",backgroundColor:n.bgColor}),class:"uni-searchbar__box",onClick:a[5]||(a[5]=(...e)=>l.searchClick&&l.searchClick(...e))},[e.createElementVNode("view",{class:"uni-searchbar__box-icon-search"},[e.renderSlot(t.$slots,"searchIcon",{},(()=>[e.createVNode(r,{color:"#c0c4cc",size:"18",type:"search"})]),!0)]),s.show||s.searchVal?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,focus:s.showSync,disabled:n.readonly,placeholder:l.placeholderText,maxlength:n.maxlength,class:"uni-searchbar__box-search-input","confirm-type":"search",type:"text","onUpdate:modelValue":a[0]||(a[0]=e=>s.searchVal=e),style:e.normalizeStyle({color:n.textColor}),onConfirm:a[1]||(a[1]=(...e)=>l.confirm&&l.confirm(...e)),onBlur:a[2]||(a[2]=(...e)=>l.blur&&l.blur(...e)),onFocus:a[3]||(a[3]=(...e)=>l.emitFocus&&l.emitFocus(...e))},null,44,["focus","disabled","placeholder","maxlength"])),[[e.vModelText,s.searchVal]]):(e.openBlock(),e.createElementBlock("text",{key:1,class:"uni-searchbar__text-placeholder"},e.toDisplayString(n.placeholder),1)),s.show&&("always"===n.clearButton||"auto"===n.clearButton&&""!==s.searchVal)&&!n.readonly?(e.openBlock(),e.createElementBlock("view",{key:2,class:"uni-searchbar__box-icon-clear",onClick:a[4]||(a[4]=(...e)=>l.clear&&l.clear(...e))},[e.renderSlot(t.$slots,"clearIcon",{},(()=>[e.createVNode(r,{color:"#c0c4cc",size:"20",type:"clear"})]),!0)])):e.createCommentVNode("",!0)],4),"always"===n.cancelButton||s.show&&"auto"===n.cancelButton?(e.openBlock(),e.createElementBlock("text",{key:0,onClick:a[6]||(a[6]=(...e)=>l.cancel&&l.cancel(...e)),class:"uni-searchbar__cancel"},e.toDisplayString(l.cancelTextI18n),1)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-2ba324d9"]]),Bc={data:()=>({searchValue:"123123"}),methods:{search(e){uni.showToast({title:"搜索："+e.value,icon:"none"})},input(e){n("log","at pages/extUI/search-bar/search-bar.vue:52","----input:",e)},clear(e){uni.showToast({title:"clear事件，清除值为："+e.value,icon:"none"})},blur(e){uni.showToast({title:"blur事件，输入值为："+e.value,icon:"none"})},focus(e){uni.showToast({title:"focus事件，输出值为："+e.value,icon:"none"})},cancel(e){uni.showToast({title:"点击取消，输入值为："+e.value,icon:"none"})}},onBackPress(){plus.key.hideSoftKeybord()}};const Dc=t(Bc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-search-bar"),Tc),d=i(e.resolveDynamicComponent("uni-section"),Tr),u=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"搜索栏组件，通常用于搜索商品、文章等。")])),_:1}),e.createVNode(d,{title:"基本用法",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{onConfirm:l.search,focus:!0,modelValue:s.searchValue,"onUpdate:modelValue":a[0]||(a[0]=e=>s.searchValue=e),onBlur:l.blur,onFocus:l.focus,onInput:l.input,onCancel:l.cancel,onClear:l.clear},null,8,["onConfirm","modelValue","onBlur","onFocus","onInput","onCancel","onClear"]),e.createElementVNode("view",{class:"search-result"},[e.createElementVNode("text",{class:"search-result-text"},"当前输入为："+e.toDisplayString(s.searchValue),1)])])),_:1}),e.createVNode(d,{title:"自定义样式",subTitle:"使用 bgColor 属性自定义背景色",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{placeholder:"自定义背景色",bgColor:"#EEEEEE",onConfirm:l.search},null,8,["onConfirm"])])),_:1}),e.createVNode(d,{title:"只读样式",subTitle:"使用 readonly 使搜索框只读",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{readonly:"",placeholder:"自定义背景色",onConfirm:l.search},null,8,["onConfirm"])])),_:1}),e.createVNode(d,{title:"自定义icon",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{placeholder:"自定义searchIcon",onConfirm:l.search,onCancel:l.cancel,"cancel-text":"cancel"},{default:e.withCtx((()=>[e.createVNode(u,{slot:"searchIcon",color:"#999999",size:"18",type:"home"})])),_:1},8,["onConfirm","onCancel"])])),_:1}),e.createVNode(d,{title:"控制清除/取消按钮",subTitle:"使用 clearButton 属性设置清除按钮",type:"line"},{default:e.withCtx((()=>[e.createVNode(c,{radius:"5",placeholder:"一直显示",clearButton:"always",cancelButton:"always",onConfirm:l.search,onCancel:l.cancel},null,8,["onConfirm","onCancel"]),e.createVNode(c,{class:"uni-mt-10",radius:"5",placeholder:"自动显示隐藏",clearButton:"auto",cancelButton:"none",onConfirm:l.search},null,8,["onConfirm"]),e.createVNode(c,{class:"uni-mt-10",radius:"100",placeholder:"一直不显示",clearButton:"none",cancelButton:"none",onConfirm:l.search},null,8,["onConfirm"])])),_:1})])}]]);const Ic=t({name:"UniFab",emits:["fabClick","trigger"],props:{pattern:{type:Object,default:()=>({})},horizontal:{type:String,default:"left"},vertical:{type:String,default:"bottom"},direction:{type:String,default:"horizontal"},content:{type:Array,default:()=>[]},show:{type:Boolean,default:!1},popMenu:{type:Boolean,default:!0}},data:()=>({fabShow:!1,isShow:!1,isAndroidNvue:!1,styles:{color:"#3c3e49",selectedColor:"#007AFF",backgroundColor:"#fff",buttonColor:"#007AFF",iconColor:"#fff",icon:"plusempty"}}),computed:{contentWidth(e){return 55*(this.content.length+1)+15+"px"},contentWidthMin:()=>"55px",boxWidth(){return this.getPosition(3,"horizontal")},boxHeight(){return this.getPosition(3,"vertical")},leftBottom(){return this.getPosition(0,"left","bottom")},rightBottom(){return this.getPosition(0,"right","bottom")},leftTop(){return this.getPosition(0,"left","top")},rightTop(){return this.getPosition(0,"right","top")},flexDirectionStart(){return this.getPosition(1,"vertical","top")},flexDirectionEnd(){return this.getPosition(1,"vertical","bottom")},horizontalLeft(){return this.getPosition(2,"horizontal","left")},horizontalRight(){return this.getPosition(2,"horizontal","right")},nvueBottom:()=>30},watch:{pattern:{handler(e,t){this.styles=Object.assign({},this.styles,e)},deep:!0}},created(){this.isShow=this.show,0===this.top&&(this.fabShow=!0),this.styles=Object.assign({},this.styles,this.pattern)},methods:{_onClick(){this.$emit("fabClick"),this.popMenu&&(this.isShow=!this.isShow)},open(){this.isShow=!0},close(){this.isShow=!1},_onItemClick(e,t){this.isShow&&this.$emit("trigger",{index:e,item:t})},getPosition(e,t,a){return 0===e?this.horizontal===t&&this.vertical===a:1===e?this.direction===t&&this.vertical===a:2===e?this.direction===t&&this.horizontal===a:this.isShow&&this.direction===t?this.contentWidth:this.contentWidthMin}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"uni-cursor-point"},[n.popMenu&&(l.leftBottom||l.rightBottom||l.leftTop||l.rightTop)&&n.content.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass([{"uni-fab--leftBottom":l.leftBottom,"uni-fab--rightBottom":l.rightBottom,"uni-fab--leftTop":l.leftTop,"uni-fab--rightTop":l.rightTop},"uni-fab"]),style:e.normalizeStyle(l.nvueBottom)},[e.createElementVNode("view",{class:e.normalizeClass([{"uni-fab__content--left":"left"===n.horizontal,"uni-fab__content--right":"right"===n.horizontal,"uni-fab__content--flexDirection":"vertical"===n.direction,"uni-fab__content--flexDirectionStart":l.flexDirectionStart,"uni-fab__content--flexDirectionEnd":l.flexDirectionEnd,"uni-fab__content--other-platform":!s.isAndroidNvue},"uni-fab__content"]),style:e.normalizeStyle({width:l.boxWidth,height:l.boxHeight,backgroundColor:s.styles.backgroundColor}),elevation:"5"},[l.flexDirectionStart||l.horizontalLeft?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-fab__item uni-fab__item--first"})):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.content,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass([{"uni-fab__item--active":s.isShow},"uni-fab__item"]),onClick:e=>l._onItemClick(a,t)},[e.createElementVNode("image",{src:t.active?t.selectedIconPath:t.iconPath,class:"uni-fab__item-image",mode:"aspectFit"},null,8,["src"]),e.createElementVNode("text",{class:"uni-fab__item-text",style:e.normalizeStyle({color:t.active?s.styles.selectedColor:s.styles.color})},e.toDisplayString(t.text),5)],10,["onClick"])))),128)),l.flexDirectionEnd||l.horizontalRight?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-fab__item uni-fab__item--first"})):e.createCommentVNode("",!0)],6)],6)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass([{"uni-fab__circle--leftBottom":l.leftBottom,"uni-fab__circle--rightBottom":l.rightBottom,"uni-fab__circle--leftTop":l.leftTop,"uni-fab__circle--rightTop":l.rightTop,"uni-fab__content--other-platform":!s.isAndroidNvue},"uni-fab__circle uni-fab__plus"]),style:e.normalizeStyle({"background-color":s.styles.buttonColor,bottom:l.nvueBottom}),onClick:a[0]||(a[0]=(...e)=>l._onClick&&l._onClick(...e))},[e.createVNode(r,{class:e.normalizeClass(["fab-circle-icon",{"uni-fab__plus--active":s.isShow&&n.content.length>0}]),type:s.styles.icon,color:s.styles.iconColor,size:"32"},null,8,["type","color","class"])],6)])}],["__scopeId","data-v-47087623"]]),Pc={components:{},data:()=>({title:"uni-fab",directionStr:"垂直",horizontal:"left",vertical:"bottom",direction:"horizontal",pattern:{color:"#7A7E83",backgroundColor:"#fff",selectedColor:"#007AFF",buttonColor:"#007AFF",iconColor:"#fff"},is_color_type:!1,content:[{iconPath:"/static/image.png",selectedIconPath:"/static/image-active.png",text:"相册",active:!1},{iconPath:"/static/home.png",selectedIconPath:"/static/home-active.png",text:"首页",active:!1},{iconPath:"/static/star.png",selectedIconPath:"/static/star-active.png",text:"收藏",active:!1}]}),onBackPress(){return!!this.$refs.fab.isShow&&(this.$refs.fab.close(),!0)},methods:{trigger(e){n("log","at pages/extUI/fab/fab.vue:70",e),this.content[e.index].active=!e.item.active,uni.showModal({title:"提示",content:`您${this.content[e.index].active?"选中了":"取消了"}${e.item.text}`,success:function(e){e.confirm?n("log","at pages/extUI/fab/fab.vue:77","用户点击确定"):e.cancel&&n("log","at pages/extUI/fab/fab.vue:79","用户点击取消")}})},fabClick(){uni.showToast({title:"点击了悬浮按钮",icon:"none"})},switchBtn(e,t){0===e?(this.direction="horizontal"===this.direction?"vertical":"horizontal",this.directionStr="horizontal"===this.direction?"垂直":"水平"):(this.horizontal=e,this.vertical=t),this.$forceUpdate()},switchColor(){this.is_color_type=!this.is_color_type,this.is_color_type?(this.pattern.iconColor="#aaa",this.pattern.buttonColor="#fff"):(this.pattern.iconColor="#fff",this.pattern.buttonColor="#007AFF")}}};const Ac=t(Pc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr),d=i(e.resolveDynamicComponent("uni-fab"),Ic);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"uni-ui 规范颜色色板，通过内置样式快速指定元素前景和背景色。")])),_:1}),e.createVNode(c,{title:"基本功能",subTitle:"点击按钮,切换 fab 不同状态",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"warp"},[e.createElementVNode("button",{class:"button",type:"primary",onClick:a[0]||(a[0]=e=>l.switchBtn(0))},"切换菜单方向("+e.toDisplayString(s.directionStr)+")",1),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[1]||(a[1]=e=>l.switchBtn("left","bottom"))},"左下角显示"),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[2]||(a[2]=e=>l.switchBtn("right","bottom"))},"右下角显示"),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[3]||(a[3]=e=>l.switchBtn("left","top"))},"左上角显示"),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[4]||(a[4]=e=>l.switchBtn("right","top"))},"右上角显示"),e.createElementVNode("button",{class:"button",type:"primary",onClick:a[5]||(a[5]=(...e)=>l.switchColor&&l.switchColor(...e))},"修改颜色")])])),_:1}),e.createVNode(d,{ref:"fab",pattern:s.pattern,content:s.content,horizontal:s.horizontal,vertical:s.vertical,direction:s.direction,onTrigger:l.trigger,onFabClick:l.fabClick},null,8,["pattern","content","horizontal","vertical","direction","onTrigger","onFabClick"])])}]]),Fc={en:{"uni-fav.collect":"collect","uni-fav.collected":"collected"},"zh-Hans":{"uni-fav.collect":"收藏","uni-fav.collected":"已收藏"},"zh-Hant":{"uni-fav.collect":"收藏","uni-fav.collected":"已收藏"}},{t:Lc}=Rl(Fc);const Mc=t({name:"UniFav",emits:["click"],props:{star:{type:[Boolean,String],default:!0},bgColor:{type:String,default:"#eeeeee"},fgColor:{type:String,default:"#666666"},bgColorChecked:{type:String,default:"#007aff"},fgColorChecked:{type:String,default:"#FFFFFF"},circle:{type:[Boolean,String],default:!1},checked:{type:Boolean,default:!1},contentText:{type:Object,default:()=>({contentDefault:"",contentFav:""})},stat:{type:Boolean,default:!1}},computed:{contentDefault(){return this.contentText.contentDefault||Lc("uni-fav.collect")},contentFav(){return this.contentText.contentFav||Lc("uni-fav.collected")}},watch:{checked(){uni.report&&this.stat&&(this.checked?uni.report("收藏","收藏"):uni.report("取消收藏","取消收藏"))}},methods:{onClick(){this.$emit("click")}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass([[!0===n.circle||"true"===n.circle?"uni-fav--circle":""],"uni-fav"]),style:e.normalizeStyle([{backgroundColor:n.checked?n.bgColorChecked:n.bgColor}]),onClick:a[0]||(a[0]=(...e)=>l.onClick&&l.onClick(...e))},[n.checked||!0!==n.star&&"true"!==n.star?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(r,{key:0,color:n.fgColor,style:e.normalizeStyle({color:n.checked?n.fgColorChecked:n.fgColor}),class:"uni-fav-star",size:"14",type:"star-filled"},null,8,["color","style"])),e.createElementVNode("text",{style:e.normalizeStyle({color:n.checked?n.fgColorChecked:n.fgColor}),class:"uni-fav-text"},e.toDisplayString(n.checked?l.contentFav:l.contentDefault),5)],6)}],["__scopeId","data-v-5edc009f"]]);const Rc=e=>"number"==typeof e?e+"px":e;const Oc=t({name:"UniNavBar",components:{statusBar:t({name:"UniStatusBar",data:()=>({statusBarHeight:uni.getSystemInfoSync().statusBarHeight+"px"})},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{style:e.normalizeStyle({height:o.statusBarHeight}),class:"uni-status-bar"},[e.renderSlot(t.$slots,"default",{},void 0,!0)],4)}],["__scopeId","data-v-4539ef65"]])},emits:["clickLeft","clickRight","clickTitle"],props:{dark:{type:Boolean,default:!1},title:{type:String,default:""},leftText:{type:String,default:""},rightText:{type:String,default:""},leftIcon:{type:String,default:""},rightIcon:{type:String,default:""},fixed:{type:[Boolean,String],default:!1},color:{type:String,default:""},backgroundColor:{type:String,default:""},statusBar:{type:[Boolean,String],default:!1},shadow:{type:[Boolean,String],default:!1},border:{type:[Boolean,String],default:!0},height:{type:[Number,String],default:44},leftWidth:{type:[Number,String],default:60},rightWidth:{type:[Number,String],default:60},stat:{type:[Boolean,String],default:""}},computed:{themeBgColor(){return this.dark?this.backgroundColor?this.backgroundColor:this.dark?"#333":"#FFF":this.backgroundColor||"#FFF"},themeColor(){return this.dark?this.color?this.color:this.dark?"#fff":"#333":this.color||"#333"},navbarHeight(){return Rc(this.height)},leftIconWidth(){return Rc(this.leftWidth)},rightIconWidth(){return Rc(this.rightWidth)}},mounted(){uni.report&&this.stat&&""!==this.title&&uni.report("title",this.title)},methods:{onClickLeft(){this.$emit("clickLeft")},onClickRight(){this.$emit("clickRight")},onClickTitle(){this.$emit("clickTitle")}}},[["render",function(t,a,n,o,s,l){const r=e.resolveComponent("status-bar"),c=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-navbar",{"uni-dark":n.dark,"uni-nvue-fixed":n.fixed}])},[e.createElementVNode("view",{class:e.normalizeClass(["uni-navbar__content",{"uni-navbar--fixed":n.fixed,"uni-navbar--shadow":n.shadow,"uni-navbar--border":n.border}]),style:e.normalizeStyle({"background-color":l.themeBgColor,"border-bottom-color":l.themeColor})},[n.statusBar?(e.openBlock(),e.createBlock(r,{key:0})):e.createCommentVNode("",!0),e.createElementVNode("view",{style:e.normalizeStyle({color:l.themeColor,backgroundColor:l.themeBgColor,height:l.navbarHeight}),class:"uni-navbar__header"},[e.createElementVNode("view",{onClick:a[0]||(a[0]=(...e)=>l.onClickLeft&&l.onClickLeft(...e)),class:"uni-navbar__header-btns uni-navbar__header-btns-left",style:e.normalizeStyle({width:l.leftIconWidth})},[e.renderSlot(t.$slots,"left",{},(()=>[n.leftIcon.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-navbar__content_view"},[e.createVNode(c,{color:l.themeColor,type:n.leftIcon,size:"20"},null,8,["color","type"])])):e.createCommentVNode("",!0),n.leftText.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass([{"uni-navbar-btn-icon-left":!n.leftIcon.length>0},"uni-navbar-btn-text"])},[e.createElementVNode("text",{style:e.normalizeStyle({color:l.themeColor,fontSize:"12px"})},e.toDisplayString(n.leftText),5)],2)):e.createCommentVNode("",!0)]),!0)],4),e.createElementVNode("view",{class:"uni-navbar__header-container",onClick:a[1]||(a[1]=(...e)=>l.onClickTitle&&l.onClickTitle(...e))},[e.renderSlot(t.$slots,"default",{},(()=>[n.title.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-navbar__header-container-inner"},[e.createElementVNode("text",{class:"uni-nav-bar-text uni-ellipsis-1",style:e.normalizeStyle({color:l.themeColor})},e.toDisplayString(n.title),5)])):e.createCommentVNode("",!0)]),!0)]),e.createElementVNode("view",{onClick:a[2]||(a[2]=(...e)=>l.onClickRight&&l.onClickRight(...e)),class:"uni-navbar__header-btns uni-navbar__header-btns-right",style:e.normalizeStyle({width:l.rightIconWidth})},[e.renderSlot(t.$slots,"right",{},(()=>[n.rightIcon.length?(e.openBlock(),e.createElementBlock("view",{key:0},[e.createVNode(c,{color:l.themeColor,type:n.rightIcon,size:"22"},null,8,["color","type"])])):e.createCommentVNode("",!0),n.rightText.length&&!n.rightIcon.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-navbar-btn-text"},[e.createElementVNode("text",{class:"uni-nav-bar-right-text",style:e.normalizeStyle({color:l.themeColor})},e.toDisplayString(n.rightText),5)])):e.createCommentVNode("",!0)]),!0)],4)],4)],6),n.fixed?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-navbar__placeholder"},[n.statusBar?(e.openBlock(),e.createBlock(r,{key:0})):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-navbar__placeholder-view",style:e.normalizeStyle({height:l.navbarHeight})},null,4)])):e.createCommentVNode("",!0)],2)}],["__scopeId","data-v-100b908f"]]);const $c=t({components:{},data:()=>({checkList:[!1,!1,!1,!1,!1,!1],contentText:{contentDefault:"追番",contentFav:"已追番"}}),methods:{favClick(e){this.checkList[e]=!this.checkList[e],n("log","at pages/extUI/fav/fav.vue:52",this.checkList[e]),this.$forceUpdate()}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-fav"),Mc),d=i(e.resolveDynamicComponent("uni-section"),Tr),u=i(e.resolveDynamicComponent("uni-nav-bar"),Oc);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"用于收藏功能，可点击切换选中、不选中的状态。")])),_:1}),e.createVNode(d,{title:"基本用法",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{checked:s.checkList[0],class:"favBtn",onClick:a[0]||(a[0]=e=>l.favClick(0))},null,8,["checked"]),e.createVNode(c,{checked:s.checkList[1],star:!1,class:"favBtn",onClick:a[1]||(a[1]=e=>l.favClick(1))},null,8,["checked"]),e.createVNode(c,{checked:s.checkList[2],class:"favBtn",circle:!0,"bg-color":"#dd524d","bg-color-checked":"#007aff","fg-color":"#ffffff","fg-color-checked":"#ffffff",onClick:a[2]||(a[2]=e=>l.favClick(2))},null,8,["checked"]),e.createVNode(c,{checked:s.checkList[3],class:"favBtn","bg-color":"#f8f8f8","bg-color-checked":"#eeeeee","fg-color":"#333333","fg-color-checked":"#333333",onClick:a[3]||(a[3]=e=>l.favClick(3))},null,8,["checked"])])])),_:1}),e.createVNode(d,{title:"自定义文字",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{checked:s.checkList[4],"content-text":s.contentText,onClick:a[4]||(a[4]=e=>l.favClick(4))},null,8,["checked","content-text"])])])),_:1}),e.createVNode(d,{title:"在自定义导航栏使用",type:"line"},{default:e.withCtx((()=>[e.createVNode(u,{style:{width:"100%"},fixed:!1,"left-icon":"arrowleft",title:"标题",color:"#333333","background-color":"#FFFFFF"},{right:e.withCtx((()=>[e.createVNode(c,{checked:s.checkList[5],circle:!0,onClick:a[5]||(a[5]=e=>l.favClick(5))},null,8,["checked"])])),_:1})])),_:1}),e.createElementVNode("view",{class:"example-body example-body-fullWidth"})])}]]);const zc=t({data:()=>({}),onReady(){},methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"uni-wrap"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"uni-section 组件主要用于文章、列表详情等标题展示")])),_:1}),e.createVNode(c,{class:"mb-10",title:"基础用法","sub-title":"副标题"}),e.createVNode(c,{class:"mb-10",title:"竖线装饰","sub-title":"副标题",type:"line"}),e.createVNode(c,{class:"mb-10",title:"装饰器插槽","sub-title":"副标题"},{decoration:e.withCtx((()=>[e.createElementVNode("view",{class:"decoration"})])),_:1}),e.createVNode(c,{class:"mb-10",title:"默认插槽","sub-title":"副标题",padding:"0 0 5px 10px"},{default:e.withCtx((()=>[e.createTextVNode("默认插槽内容")])),_:1}),e.createVNode(c,{class:"mb-10",title:"主标题"},{right:e.withCtx((()=>[e.createTextVNode(" right slot ")])),_:1})])}]]);const Uc=t({components:{},data:()=>({show:!0,modeClass:"fade",styles:{}}),onLoad(){},methods:{handle(e){this.show=!this.show,this.modeClass=e},custom(){this.$refs.ani.step({width:"100px",height:"100px",rotate:"180"},{delay:200,duration:300}),this.$refs.ani.step({width:"100px",height:"100px",rotate:"0"},{transformOrigin:"50% 50%"}),this.$refs.ani.step({translateX:"-100px"},{timingFunction:"ease-in",duration:100}),this.$refs.ani.step({translateX:"100px"},{timingFunction:"ease",duration:300}),this.$refs.ani.step({translateX:"50px",scale:1.5},{timingFunction:"linear",duration:100}),this.$refs.ani.step({translateX:"0px",scale:1},{timingFunction:"linear",duration:150}),this.$refs.ani.run()}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-transition"),qa),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"过渡动画，通常用于元素的过渡效果，例如淡隐淡出效果，遮罩层的效果、放大缩小的效果等")])),_:1}),e.createVNode(d,{title:"示例",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example"},[e.createVNode(c,{ref:"ani","custom-class":"transition","mode-class":s.modeClass,styles:s.styles,show:s.show},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"text"},"示例元素")])),_:1},8,["mode-class","styles","show"])])])),_:1}),e.createVNode(d,{title:"操作",subTitle:"点击按钮 ,切换动画效果",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("button",{class:"transition-button",type:"primary",onClick:a[0]||(a[0]=e=>l.handle("fade"))},"淡隐淡出"),e.createElementVNode("button",{class:"transition-button",type:"primary",onClick:a[1]||(a[1]=e=>l.handle(["fade","slide-top"]))},"由上至下"),e.createElementVNode("button",{class:"transition-button",type:"primary",onClick:a[2]||(a[2]=e=>l.handle(["fade","slide-right"]))},"由右至左过"),e.createElementVNode("button",{class:"transition-button",type:"primary",onClick:a[3]||(a[3]=e=>l.handle(["fade","zoom-in"]))},"由小到大过"),e.createElementVNode("button",{class:"transition-button",type:"primary",onClick:a[4]||(a[4]=(...e)=>l.custom&&l.custom(...e))},"自定义动画")])])),_:1})])}]]);const jc=t({name:"UniTitle",props:{type:{type:String,default:""},title:{type:String,default:""},align:{type:String,default:"left"},color:{type:String,default:"#333333"},stat:{type:[Boolean,String],default:""}},data:()=>({}),computed:{textAlign(){let e="center";switch(this.align){case"left":e="flex-start";break;case"center":e="center";break;case"right":e="flex-end"}return e}},watch:{title(e){this.isOpenStat()&&uni.report&&uni.report("title",this.title)}},mounted(){this.isOpenStat()&&uni.report&&uni.report("title",this.title)},methods:{isOpenStat(){""===this.stat&&(this.isStat=!1);let e="boolean"==typeof this.stat&&this.stat||"string"==typeof this.stat&&""!==this.stat;return""===this.type&&(this.isStat=!0,"false"===this.stat.toString()&&(this.isStat=!1)),""!==this.type&&(this.isStat=!0,this.isStat=!!e),this.isStat}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-title__box",style:e.normalizeStyle({"align-items":s.textAlign})},[e.createElementVNode("text",{class:e.normalizeClass(["uni-title__base",["uni-"+n.type]]),style:e.normalizeStyle({color:n.color})},e.toDisplayString(n.title),7)],4)}],["__scopeId","data-v-7e58812f"]]);const qc=t({components:{},data:()=>({title:"标题组件通常用于记录页面标题，例如商品标题、新闻标题等，当前组件会自动上报内容统计数据"}),onLoad(){},methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-title"),jc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"uni-content"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"}," 标题组件，通常用于记录页面标题，使用当前组件在 uni-app 开启统计的情况下，将会自动统计页面标题.")])),_:1}),e.createVNode(d,{title:"不同类型",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{type:"h1",title:"h1 一级标题"}),e.createVNode(c,{type:"h2",title:"h2 二级标题"}),e.createVNode(c,{type:"h3",title:"h3 三级标题"}),e.createVNode(c,{type:"h4",title:"h4 四级标题"}),e.createVNode(c,{type:"h5",title:"h5 五级标题"})])])),_:1}),e.createVNode(d,{title:"改变颜色",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{type:"h1",title:"h1 一级标题",color:"#027fff"}),e.createVNode(c,{type:"h2",title:"h2 二级标题",color:"#2490ff"}),e.createVNode(c,{type:"h3",title:"h3 三级标题",color:"#439ffc"}),e.createVNode(c,{type:"h4",title:"h4 四级标题",color:"#60adfb"}),e.createVNode(c,{type:"h5",title:"h5 五级标题",color:"#7db9f7"})])])),_:1}),e.createVNode(d,{title:"对齐方式",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{type:"h1",title:"h1 左对齐",align:"left"}),e.createVNode(c,{type:"h2",title:"h2 居中",align:"center"}),e.createVNode(c,{type:"h3",title:"h3 右对齐",align:"right"}),e.createVNode(c,{type:"h4",title:"h4 居中",align:"center"}),e.createVNode(c,{type:"h5",title:"h5 左对齐",align:"left"})])])),_:1}),e.createVNode(d,{title:"组合示例",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createElementVNode("view",{class:"uni-box-head"},[e.createVNode(c,{type:"h1",align:"center",title:"uni-app介绍"})]),e.createElementVNode("view",{class:"uni-box"},[e.createVNode(c,{class:"h3",type:"h3",title:"1 框架介绍"})]),e.createElementVNode("view",{class:"uni-box"},[e.createVNode(c,{class:"h4",type:"h4",title:"1.1 什么是uni-app"})]),e.createElementVNode("view",null,[e.createElementVNode("text",{class:"uni-text"},"uni-app是一个使用Vue.js开发所有前端应用的框架，开发者编写一套代码，可发布到iOS、Android、H5、以及各种小程序（微信/支付宝/百度/头条/QQ/钉钉）等多个平台。即使不跨端，uni-app同时也是更好的小程序开发框架。DCloud公司拥有370万开发者用户，旗下uni-app有5万+案例、900款插件、50+微信/qq群，并且被阿里小程序工具内置，开发者可以放心选择。")]),e.createElementVNode("view",{class:"uni-box"},[e.createVNode(c,{class:"h4",type:"h4",title:"1.2 开发规范"})]),e.createElementVNode("view",{class:""},[e.createVNode(c,{class:"h5",type:"h5",color:"#666",title:"- 页面文件遵循 Vue 单文件组件 (SFC) 规范"}),e.createVNode(c,{class:"h5",type:"h5",color:"#666",title:"- 组件标签靠近小程序规范，详见uni-app 组件规范"}),e.createVNode(c,{class:"h5",type:"h5",color:"#666",title:"- 接口能力（JS API）靠近微信小程序规范，但需将前缀 wx 替换为 uni，详见uni-app接口规范"}),e.createVNode(c,{class:"h5",type:"h5",color:"#666",title:"- 数据绑定及事件处理同 Vue.js 规范，同时补充了App及页面的生命周期"}),e.createVNode(c,{class:"h5",type:"h5",color:"#666",title:"- 为兼容多端运行，建议使用flex布局进行开发"})])])])),_:1})])}]]);const Hc=t({name:"uni-tooltip",data:()=>({}),methods:{},computed:{initPlacement(){let e={};switch(this.placement){case"left":e={top:"50%",transform:"translateY(-50%)",right:"100%","margin-right":"10rpx"};break;case"right":e={top:"50%",transform:"translateY(-50%)",left:"100%","margin-left":"10rpx"};break;case"top":e={bottom:"100%",transform:"translateX(-50%)",left:"50%","margin-bottom":"10rpx"};break;case"bottom":e={top:"100%",transform:"translateX(-50%)",left:"50%","margin-top":"10rpx"}}return e}},props:{content:{type:String,default:""},placement:{type:String,default:"bottom"}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-tooltip"},[e.renderSlot(t.$slots,"default",{},void 0,!0),n.content||t.$slots.content?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-tooltip-popup",style:e.normalizeStyle(s.initPlacement)},[e.renderSlot(t.$slots,"content",{},(()=>[e.createTextVNode(e.toDisplayString(n.content),1)]),!0)],4)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-58de326e"]]);const Wc=t({components:{},data:()=>({})},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-tooltip"),Hc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"常用于展示鼠标 hover 时的提示信息，注意：无法覆盖原生组件")])),_:1}),e.createVNode(d,{title:"基础用法",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createVNode(c,{class:"tooltip",content:"提示文字",placement:"left"},{default:e.withCtx((()=>[e.createElementVNode("button",{size:"mini",type:"primary",plain:""},"左")])),_:1}),e.createVNode(c,{class:"tooltip",content:"提示文字",placement:"bottom"},{default:e.withCtx((()=>[e.createElementVNode("button",{size:"mini",type:"primary",plain:""},"底")])),_:1}),e.createVNode(c,{class:"tooltip",content:"提示文字",placement:"top"},{default:e.withCtx((()=>[e.createElementVNode("button",{size:"mini",type:"primary",plain:""},"上")])),_:1}),e.createVNode(c,{class:"tooltip",content:"提示文字",placement:"right"},{default:e.withCtx((()=>[e.createElementVNode("button",{size:"mini",type:"primary",plain:""},"右")])),_:1})])])),_:1}),e.createVNode(d,{title:"弹出层插槽",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"content"},[e.createVNode(c,{class:"tooltip",placement:"bottom"},{content:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-stat-tooltip"}," 一段文字一段文字一段文字一段文字一段文字一段文字一段文字 一段文字一段文字一段文字一段文字一段文字一段文字一段文字 ")])),default:e.withCtx((()=>[e.createElementVNode("button",{size:"mini",type:"primary",plain:""},"多行文字提示")])),_:1})])])),_:1})])}]]);const Jc=t({name:"uniLink",props:{href:{type:String,default:""},text:{type:String,default:""},download:{type:String,default:""},showUnderLine:{type:[Boolean,String],default:!0},copyTips:{type:String,default:"已自动复制网址，请在手机浏览器里粘贴该网址"},color:{type:String,default:"#999999"},fontSize:{type:[Number,String],default:14}},computed:{isShowA(){return!(!this.isMail()&&!this.isTel()||!0!==this._isH5)}},created(){this._isH5=null},methods:{isMail(){return this.href.startsWith("mailto:")},isTel(){return this.href.startsWith("tel:")},openURL(){this.isTel()?this.makePhoneCall(this.href.replace("tel:","")):plus.runtime.openURL(this.href)},makePhoneCall(e){uni.makePhoneCall({phoneNumber:e})}}},[["render",function(t,a,n,i,o,s){return s.isShowA?(e.openBlock(),e.createElementBlock("a",{key:0,class:e.normalizeClass(["uni-link",{"uni-link--withline":!0===n.showUnderLine||"true"===n.showUnderLine}]),href:n.href,style:e.normalizeStyle({color:n.color,fontSize:n.fontSize+"px"}),download:n.download},[e.renderSlot(t.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(n.text),1)]),!0)],14,["href","download"])):(e.openBlock(),e.createElementBlock("text",{key:1,class:e.normalizeClass(["uni-link",{"uni-link--withline":!0===n.showUnderLine||"true"===n.showUnderLine}]),style:e.normalizeStyle({color:n.color,fontSize:n.fontSize+"px"}),onClick:a[0]||(a[0]=(...e)=>s.openURL&&s.openURL(...e))},[e.renderSlot(t.$slots,"default",{},(()=>[e.createTextVNode(e.toDisplayString(n.text),1)]),!0)],6))}],["__scopeId","data-v-c0949d4e"]]);const Gc=t({components:{},data:()=>({})},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-link"),Jc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"超链接组件，在小程序内复制url，在app内打开外部浏览器，在h5端打开新网页。")])),_:1}),e.createVNode(d,{title:"基本示例",subTitle:"打开外部连接",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{href:"https://uniapp.dcloud.io/",text:"https://uniapp.dcloud.io/"})])),_:1}),e.createVNode(d,{title:"自定义颜色",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{href:"https://uniapp.dcloud.io/",text:"https://uniapp.dcloud.io/",color:"#007BFF"})])),_:1}),e.createVNode(d,{title:"自定义下划线",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{href:"https://uniapp.dcloud.io/",text:"https://uniapp.dcloud.io/",showUnderLine:"false"})])),_:1}),e.createVNode(d,{title:"自定义字体大小",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{href:"https://uniapp.dcloud.io/",text:"https://uniapp.dcloud.io/",showUnderLine:"false","font-size":"20"})])),_:1}),e.createVNode(d,{title:"自定义插槽",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{href:"https://uniapp.dcloud.io/",text:"https://uniapp.dcloud.io/",showUnderLine:"false",color:"red"},{default:e.withCtx((()=>[e.createTextVNode("点击跳转")])),_:1})])),_:1})])}]]);const Kc=t({name:"uniCombox",emits:["input","update:modelValue"],props:{clearAble:{type:Boolean,default:!1},border:{type:Boolean,default:!0},label:{type:String,default:""},labelWidth:{type:String,default:"auto"},placeholder:{type:String,default:""},candidates:{type:Array,default:()=>[]},emptyTips:{type:String,default:"无匹配项"},modelValue:{type:[String,Number],default:""}},data:()=>({showSelector:!1,inputVal:""}),computed:{labelStyle(){return"auto"===this.labelWidth?"":`width: ${this.labelWidth}`},filterCandidates(){return this.candidates.filter((e=>e.toString().indexOf(this.inputVal)>-1))},filterCandidatesLength(){return this.filterCandidates.length}},watch:{modelValue:{handler(e){this.inputVal=e},immediate:!0}},methods:{toggleSelector(){this.showSelector=!this.showSelector},onFocus(){this.showSelector=!0},onBlur(){setTimeout((()=>{this.showSelector=!1}),153)},onSelectorClick(e){this.inputVal=this.filterCandidates[e],this.showSelector=!1,this.$emit("input",this.inputVal),this.$emit("update:modelValue",this.inputVal)},onInput(){setTimeout((()=>{this.$emit("input",this.inputVal),this.$emit("update:modelValue",this.inputVal)}))},clean(){this.inputVal="",this.onInput()}}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-combox",n.border?"":"uni-combox__no-border"])},[n.label?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-combox__label",style:e.normalizeStyle(l.labelStyle)},[e.createElementVNode("text",null,e.toDisplayString(n.label),1)],4)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-combox__input-box"},[e.withDirectives(e.createElementVNode("input",{class:"uni-combox__input",type:"text",placeholder:n.placeholder,"placeholder-class":"uni-combox__input-plac","onUpdate:modelValue":a[0]||(a[0]=e=>s.inputVal=e),onInput:a[1]||(a[1]=(...e)=>l.onInput&&l.onInput(...e)),onFocus:a[2]||(a[2]=(...e)=>l.onFocus&&l.onFocus(...e)),onBlur:a[3]||(a[3]=(...e)=>l.onBlur&&l.onBlur(...e))},null,40,["placeholder"]),[[e.vModelText,s.inputVal]]),s.inputVal&&n.clearAble?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(r,{key:0,type:s.showSelector?"top":"bottom",size:"14",color:"#999",onClick:l.toggleSelector},null,8,["type","onClick"])),s.inputVal&&n.clearAble?(e.openBlock(),e.createBlock(r,{key:1,type:"clear",size:"24",color:"#999",onClick:l.clean},null,8,["onClick"])):e.createCommentVNode("",!0)]),s.showSelector?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-combox__selector"},[e.createElementVNode("view",{class:"uni-popper__arrow"}),e.createElementVNode("scroll-view",{"scroll-y":"true",class:"uni-combox__selector-scroll"},[0===l.filterCandidatesLength?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-combox__selector-empty"},[e.createElementVNode("text",null,e.toDisplayString(n.emptyTips),1)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.filterCandidates,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"uni-combox__selector-item",key:a,onClick:e=>l.onSelectorClick(a)},[e.createElementVNode("text",null,e.toDisplayString(t),1)],8,["onClick"])))),128))])])):e.createCommentVNode("",!0)],2)}],["__scopeId","data-v-90eaae72"]]);const Qc=t({components:{},data:()=>({candidates:["北京","南京","东京","武汉","天津","上海","海口"],city:""}),methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-combox"),Kc),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"组合框一般用于可以选择也可以输入的表单项。")])),_:1}),e.createVNode(d,{title:"基本用法",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{candidates:s.candidates,placeholder:"请选择所在城市",modelValue:s.city,"onUpdate:modelValue":a[0]||(a[0]=e=>s.city=e)},null,8,["candidates","modelValue"]),e.createElementVNode("view",{class:"result-box"},[e.createElementVNode("text",null,"所选城市为："+e.toDisplayString(s.city),1)])])])),_:1}),e.createVNode(d,{title:"无边框",subTitle:"使用 border = false 取消边框",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{border:!1,candidates:s.candidates,placeholder:"请选择所在城市"},null,8,["candidates"])])])),_:1}),e.createVNode(d,{title:"设置无匹配项时的提示语",subTitle:"使用 emptyTips 属性设置无匹配项时的提示语",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{emptyTips:"这里啥都没有",placeholder:"请选择所在城市"})])])),_:1})])}]]);const Yc=t({name:"UniListChat",emits:["click"],props:{title:{type:String,default:""},note:{type:String,default:""},clickable:{type:Boolean,default:!1},link:{type:[Boolean,String],default:!1},to:{type:String,default:""},badgeText:{type:[String,Number],default:""},badgePositon:{type:String,default:"right"},time:{type:String,default:""},avatarCircle:{type:Boolean,default:!1},avatar:{type:String,default:""},avatarList:{type:Array,default:()=>[]}},computed:{isDraft(){return"[uni-im-draft]"==this.note.slice(0,14)},isSingle(){if("dot"===this.badgeText)return"uni-badge--dot";return this.badgeText.toString().length>1?"uni-badge--complex":"uni-badge--single"},computedAvatar(){return this.avatarList.length>4?(this.imageWidth=13.95,"avatarItem--3"):this.avatarList.length>1?(this.imageWidth=21.15,"avatarItem--2"):(this.imageWidth=45,"avatarItem--1")}},watch:{avatar:{handler(e){"cloud://"==e.substr(0,8)?Cl.getTempFileURL({fileList:[e]}).then((e=>{let t=e.fileList||e.result.fileList;this.avatarUrl=t[0].tempFileURL})):this.avatarUrl=e},immediate:!0}},data:()=>({isFirstChild:!1,border:!0,imageWidth:50,avatarUrl:""}),mounted(){this.list=this.getForm(),this.list&&(this.list.firstChildAppend||(this.list.firstChildAppend=!0,this.isFirstChild=!0),this.border=this.list.border)},methods:{getForm(e="uniList"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t},onClick(){""===this.to?(this.clickable||this.link)&&this.$emit("click",{data:{}}):this.openPage()},openPage(){-1!==["navigateTo","redirectTo","reLaunch","switchTab"].indexOf(this.link)?this.pageApi(this.link):this.pageApi("navigateTo")},pageApi(e){let t={url:this.to,success:e=>{this.$emit("click",{data:e})},fail:e=>{this.$emit("click",{data:e})}};switch(e){case"navigateTo":default:uni.navigateTo(t);break;case"redirectTo":uni.redirectTo(t);break;case"reLaunch":uni.reLaunch(t);break;case"switchTab":uni.switchTab(t)}}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{"hover-class":n.clickable||n.link?"uni-list-chat--hover":"",class:"uni-list-chat",onClick:a[0]||(a[0]=e.withModifiers(((...e)=>s.onClick&&s.onClick(...e)),["stop"]))},[e.createElementVNode("view",{class:e.normalizeClass({"uni-list--border":o.border,"uni-list-chat--first":o.isFirstChild})},null,2),e.createElementVNode("view",{class:"uni-list-chat__container"},[e.createElementVNode("view",{class:"uni-list-chat__header-warp"},[n.avatarCircle||0===n.avatarList.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-list-chat__header",{"header--circle":n.avatarCircle}])},[e.createElementVNode("image",{class:e.normalizeClass(["uni-list-chat__header-image",{"header--circle":n.avatarCircle}]),src:o.avatarUrl,mode:"aspectFill"},null,10,["src"])],2)):(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-list-chat__header"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.avatarList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass(["uni-list-chat__header-box",s.computedAvatar]),style:e.normalizeStyle({width:o.imageWidth+"px",height:o.imageWidth+"px"})},[e.createElementVNode("image",{class:"uni-list-chat__header-image",style:e.normalizeStyle({width:o.imageWidth+"px",height:o.imageWidth+"px"}),src:t.url,mode:"aspectFill"},null,12,["src"])],6)))),128))]))]),e.renderSlot(t.$slots,"header",{},void 0,!0),n.badgeText&&"left"===n.badgePositon?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-list-chat__badge uni-list-chat__badge-pos",[s.isSingle]])},[e.createElementVNode("text",{class:"uni-list-chat__badge-text"},e.toDisplayString("dot"===n.badgeText?"":n.badgeText),1)],2)):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-list-chat__content"},[e.createElementVNode("view",{class:"uni-list-chat__content-main"},[e.createElementVNode("text",{class:"uni-list-chat__content-title uni-ellipsis"},e.toDisplayString(n.title),1),e.createElementVNode("view",{style:{"flex-direction":"row"}},[s.isDraft?(e.openBlock(),e.createElementBlock("text",{key:0,class:"draft"},"[草稿]")):e.createCommentVNode("",!0),e.createElementVNode("text",{class:"uni-list-chat__content-note uni-ellipsis"},e.toDisplayString(s.isDraft?n.note.slice(14):n.note),1)])]),e.createElementVNode("view",{class:"uni-list-chat__content-extra"},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("text",{class:"uni-list-chat__content-extra-text"},e.toDisplayString(n.time),1),n.badgeText&&"right"===n.badgePositon?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["uni-list-chat__badge",[s.isSingle,"right"===n.badgePositon?"uni-list-chat--right":""]])},[e.createElementVNode("text",{class:"uni-list-chat__badge-text"},e.toDisplayString("dot"===n.badgeText?"":n.badgeText),1)],2)):e.createCommentVNode("",!0)]),!0)])])])],8,["hover-class"])}],["__scopeId","data-v-bb149a91"]]),Xc={components:{},data:()=>({UNITS:{"年":315576e5,"月":26298e5,"天":864e5,"小时":36e5,"分钟":6e4,"秒":1e3},listData:[],avatarList:[{url:"/static/logo.png"},{url:"/static/logo.png"},{url:"/static/logo.png"}]}),onLoad(){this.getList()},methods:{onClick(){uni.showToast({title:"列表被点击"})},avatar(e){let t=[];return this.avatarList.forEach(((a,n)=>{n<e&&t.push(a)})),t},getList(){uni.request({url:"https://unidemo.dcloud.net.cn/api/news",data:{column:"id,post_id,title,author_name,cover,published_at"},success:e=>{if(200==e.statusCode){let t=this.setTime(e.data);t=this.reload?t:this.listData.concat(t),t.map((e=>(e.text=Math.floor(-19*Math.random()+20),e))),this.listData=this.getRandomArrayElements(t,3)}},fail:(e,t)=>{n("log","at pages/extUI/list/chat.vue:109","fail"+JSON.stringify(e))}})},getRandomArrayElements(e,t){for(var a,n,i=e.slice(0),o=e.length,s=o-t;o-- >s;)a=i[n=Math.floor((o+1)*Math.random())],i[n]=i[o],i[o]=a;return i.slice(s)},setTime(e){var t=[];return e.forEach((e=>{t.push({author_name:e.author_name,cover:e.cover,id:e.id,post_id:e.post_id,published_at:this.format(e.published_at),title:e.title})})),t},format(e){var t=this.parse(e),a=Date.now()-t.getTime();if(a<this.UNITS["天"])return this.humanize(a);var n=function(e){return e<10?"0"+e:e};return t.getFullYear()+"-"+n(t.getMonth()+1)+"-"+n(t.getDate())+" "+n(t.getHours())+":"+n(t.getMinutes())},parse(e){var t=e.split(/[^0-9]/);return new Date(t[0],t[1]-1,t[2],t[3],t[4],t[5])}}};const Zc=t(Xc,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-list-chat"),Yc),d=i(e.resolveDynamicComponent("uni-list"),oc),u=i(e.resolveDynamicComponent("uni-section"),Tr),h=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"此示例展示了聊天列表的使用场景。")])),_:1}),e.createVNode(u,{title:"圆头像且不显示分割线",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,{border:!1},{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,(t=>(e.openBlock(),e.createBlock(c,{"avatar-circle":!0,key:t.id,title:t.author_name,avatar:t.cover,note:t.title,time:t.published_at,clickable:!1},null,8,["title","avatar","note","time"])))),128))])),_:1})])),_:1}),e.createVNode(u,{title:"带圆点",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,(t=>(e.openBlock(),e.createBlock(c,{key:t.id,title:t.author_name,avatar:t.cover,note:t.title,time:t.published_at,"badge-text":t.text,clickable:!1,"badge-positon":"left"},null,8,["title","avatar","note","time","badge-text"])))),128))])),_:1})])),_:1}),e.createVNode(u,{title:"自定义右侧内容",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,(t=>(e.openBlock(),e.createBlock(c,{key:t.id,title:t.author_name,avatar:t.cover,note:t.title,"badge-positon":"left","badge-text":t.text},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"chat-custom-right"},[e.createElementVNode("text",{class:"chat-custom-text"},"刚刚"),e.createVNode(h,{type:"star-filled",color:"#999",size:"18"})])])),_:2},1032,["title","avatar","note","badge-text"])))),128))])),_:1})])),_:1}),e.createVNode(u,{title:"带通知角标的单头像聊天列表",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,(t=>(e.openBlock(),e.createBlock(c,{key:t.id,title:t.author_name,avatar:t.cover,note:t.title,time:t.published_at,clickable:!0,"badge-text":t.text,onClick:l.onClick},null,8,["title","avatar","note","time","badge-text","onClick"])))),128))])),_:1})])),_:1}),e.createVNode(u,{title:"带通知角标的多头像聊天列表",type:"line"},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,((t,a)=>(e.openBlock(),e.createBlock(c,{key:t.id,title:t.author_name,avatar:t.cover,note:t.title,time:t.published_at,clickable:!0,avatarList:l.avatar(a+1),"badge-text":t.text,onClick:l.onClick},null,8,["title","avatar","note","time","avatarList","badge-text","onClick"])))),128))])),_:1})])),_:1})])}]]),ed={name:"uniTh",options:{virtualHost:!0},components:{},emits:["sort-change","filter-change"],props:{width:{type:[String,Number],default:""},align:{type:String,default:"left"},rowspan:{type:[Number,String],default:1},colspan:{type:[Number,String],default:1},sortable:{type:Boolean,default:!1},filterType:{type:String,default:""},filterData:{type:Array,default:()=>[]},filterDefaultValue:{type:[Array,String],default:()=>""}},data:()=>({border:!1,ascending:!1,descending:!1}),computed:{customWidth(){if("number"==typeof this.width)return this.width;if("string"==typeof this.width){let e=new RegExp(/^[1-9][0-9]*px$/g),t=new RegExp(/^[1-9][0-9]*rpx$/g),a=new RegExp(/^[1-9][0-9]*$/g);if(null!==this.width.match(e))return this.width.replace("px","");if(null!==this.width.match(t)){let e=Number(this.width.replace("rpx","")),t=uni.getSystemInfoSync().screenWidth/750;return Math.round(e*t)}return null!==this.width.match(a)?this.width:""}return""},contentAlign(){let e="left";switch(this.align){case"left":e="flex-start";break;case"center":e="center";break;case"right":e="flex-end"}return e}},created(){this.root=this.getTable("uniTable"),this.rootTr=this.getTable("uniTr"),this.rootTr.minWidthUpdate(this.customWidth?this.customWidth:140),this.border=this.root.border,this.root.thChildren.push(this)},methods:{sort(){if(this.sortable)return this.clearOther(),this.ascending||this.descending?this.ascending&&!this.descending?(this.ascending=!1,this.descending=!0,void this.$emit("sort-change",{order:"descending"})):void(!this.ascending&&this.descending&&(this.ascending=!1,this.descending=!1,this.$emit("sort-change",{order:null}))):(this.ascending=!0,void this.$emit("sort-change",{order:"ascending"}))},ascendingFn(){this.clearOther(),this.ascending=!this.ascending,this.descending=!1,this.$emit("sort-change",{order:this.ascending?"ascending":null})},descendingFn(){this.clearOther(),this.descending=!this.descending,this.ascending=!1,this.$emit("sort-change",{order:this.descending?"descending":null})},clearOther(){this.root.thChildren.map((e=>(e!==this&&(e.ascending=!1,e.descending=!1),e)))},ondropdown(e){this.$emit("filter-change",e)},getTable(e){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}};const td=t(ed,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-table-th",{"table--border":o.border}]),style:e.normalizeStyle({width:s.customWidth+"px","text-align":n.align})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-c82f19e3"]]);const ad={name:"uniTr",components:{tableCheckbox:t({name:"TableCheckbox",emits:["checkboxSelected"],props:{indeterminate:{type:Boolean,default:!1},checked:{type:[Boolean,String],default:!1},disabled:{type:Boolean,default:!1},index:{type:Number,default:-1},cellData:{type:Object,default:()=>({})}},watch:{checked(e){"boolean"==typeof this.checked?this.isChecked=e:this.isChecked=!0},indeterminate(e){this.isIndeterminate=e}},data:()=>({isChecked:!1,isDisabled:!1,isIndeterminate:!1}),created(){"boolean"==typeof this.checked&&(this.isChecked=this.checked),this.isDisabled=this.disabled},methods:{selected(){this.isDisabled||(this.isIndeterminate=!1,this.isChecked=!this.isChecked,this.$emit("checkboxSelected",{checked:this.isChecked,data:this.cellData}))}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-table-checkbox",onClick:a[0]||(a[0]=(...e)=>s.selected&&s.selected(...e))},[n.indeterminate?(e.openBlock(),e.createElementBlock("view",{key:1,class:"checkbox__inner checkbox--indeterminate"},[e.createElementVNode("view",{class:"checkbox__inner-icon"})])):(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["checkbox__inner",{"is-checked":o.isChecked,"is-disable":o.isDisabled}])},[e.createElementVNode("view",{class:"checkbox__inner-icon"})],2))])}],["__scopeId","data-v-296f1239"]])},props:{disabled:{type:Boolean,default:!1},keyValue:{type:[String,Number],default:""}},options:{virtualHost:!0},data:()=>({value:!1,border:!1,selection:!1,widthThArr:[],ishead:!0,checked:!1,indeterminate:!1}),created(){this.root=this.getTable(),this.head=this.getTable("uniThead"),this.head&&(this.ishead=!1,this.head.init(this)),this.border=this.root.border,this.selection=this.root.type,this.root.trChildren.push(this);const e=this.root.data.find((e=>e[this.root.rowKey]===this.keyValue));e&&(this.rowData=e),this.root.isNodata()},mounted(){if(this.widthThArr.length>0){const e="selection"===this.selection?50:0;this.root.minWidth=Number(this.widthThArr.reduce(((e,t)=>Number(e)+Number(t))))+e}},unmounted(){const e=this.root.trChildren.findIndex((e=>e===this));this.root.trChildren.splice(e,1),this.root.isNodata()},methods:{minWidthUpdate(e){if(this.widthThArr.push(e),this.widthThArr.length>0){const e="selection"===this.selection?50:0;this.root.minWidth=Number(this.widthThArr.reduce(((e,t)=>Number(e)+Number(t))))+e}},checkboxSelected(e){let t=this.root.data.find((e=>e[this.root.rowKey]===this.keyValue));this.checked=e.checked,this.root.check(t||this,e.checked,t?this.keyValue:null)},change(e){this.root.trChildren.forEach((t=>{t===this&&this.root.check(this,e.detail.value.length>0)}))},getTable(e="uniTable"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}};const nd=t(ad,[["render",function(t,a,n,i,o,s){const l=e.resolveComponent("table-checkbox");return e.openBlock(),e.createElementBlock("view",{class:"uni-table-tr"},["selection"===o.selection?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["checkbox",{"tr-table--border":o.border}])},[e.createVNode(l,{checked:o.checked,indeterminate:o.indeterminate,disabled:n.disabled,onCheckboxSelected:s.checkboxSelected},null,8,["checked","indeterminate","disabled","onCheckboxSelected"])],2)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},void 0,!0)])}],["__scopeId","data-v-59fecc4c"]]);const id=t({name:"uniTd",options:{virtualHost:!0},props:{width:{type:[String,Number],default:""},align:{type:String,default:"left"},rowspan:{type:[Number,String],default:1},colspan:{type:[Number,String],default:1}},data:()=>({border:!1}),created(){this.root=this.getTable(),this.border=this.root.border},methods:{getTable(){let e=this.$parent,t=e.$options.name;for(;"uniTable"!==t;){if(e=e.$parent,!e)return!1;t=e.$options.name}return e}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-table-td",{"table--border":o.border}]),style:e.normalizeStyle({width:n.width+"px","text-align":n.align})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-40da01a0"]]);const od=t({name:"uniTable",options:{virtualHost:!0},emits:["selection-change"],props:{data:{type:Array,default:()=>[]},border:{type:Boolean,default:!1},stripe:{type:Boolean,default:!1},type:{type:String,default:""},emptyText:{type:String,default:"没有更多数据"},loading:{type:Boolean,default:!1},rowKey:{type:String,default:""}},data:()=>({noData:!0,minWidth:0,multiTableHeads:[]}),watch:{loading(e){},data(e){this.theadChildren,this.theadChildren&&this.theadChildren.rowspan,this.noData=!1}},created(){this.trChildren=[],this.thChildren=[],this.theadChildren=null,this.backData=[],this.backIndexData=[]},methods:{isNodata(){this.theadChildren;let e=1;this.theadChildren&&(e=this.theadChildren.rowspan),this.noData=this.trChildren.length-e<=0},selectionAll(){let e=1,t=this.theadChildren;this.theadChildren?e=t.rowspan-1:t=this.trChildren[0];let a=this.data&&this.data.length>0;t.checked=!0,t.indeterminate=!1,this.trChildren.forEach(((t,n)=>{if(!t.disabled){if(t.checked=!0,a&&t.keyValue){const e=this.data.find((e=>e[this.rowKey]===t.keyValue));this.backData.find((t=>t[this.rowKey]===e[this.rowKey]))||this.backData.push(e)}n>e-1&&-1===this.backIndexData.indexOf(n-e)&&this.backIndexData.push(n-e)}})),this.$emit("selection-change",{detail:{value:this.backData,index:this.backIndexData}})},toggleRowSelection(e,t){e=[].concat(e),this.trChildren.forEach(((a,n)=>{const i=e.findIndex((e=>"number"==typeof e?e===n-1:e[this.rowKey]===a.keyValue));let o=a.checked;-1!==i&&(a.checked="boolean"==typeof t?t:!a.checked,o!==a.checked&&this.check(a.rowData||a,a.checked,a.rowData?a.keyValue:null,!0))})),this.$emit("selection-change",{detail:{value:this.backData,index:this.backIndexData}})},clearSelection(){let e=this.theadChildren;this.theadChildren||(e=this.trChildren[0]),e.checked=!1,e.indeterminate=!1,this.trChildren.forEach((e=>{e.checked=!1})),this.backData=[],this.backIndexData=[],this.$emit("selection-change",{detail:{value:[],index:[]}})},toggleAllSelection(){let e=[],t=1,a=this.theadChildren;this.theadChildren?t=a.rowspan-1:a=this.trChildren[0],this.trChildren.forEach(((a,n)=>{a.disabled||n>t-1&&e.push(n-t)})),this.toggleRowSelection(e)},check(e,t,a,n){let i=this.theadChildren;this.theadChildren||(i=this.trChildren[0]);let o=this.trChildren.findIndex(((t,a)=>e===t));if(o<0&&(o=this.data.findIndex((e=>e[this.rowKey]===a))+1),this.trChildren.filter((e=>!e.disabled&&e.keyValue)).length,0===o)return void(t?this.selectionAll():this.clearSelection());if(t)a&&this.backData.push(e),this.backIndexData.push(o-1);else{const e=this.backData.findIndex((e=>e[this.rowKey]===a)),t=this.backIndexData.findIndex((e=>e===o-1));a&&this.backData.splice(e,1),this.backIndexData.splice(t,1)}this.trChildren.find(((e,t)=>t>0&&!e.checked&&!e.disabled))?(i.indeterminate=!0,i.checked=!1):(i.indeterminate=!1,i.checked=!0),0===this.backIndexData.length&&(i.indeterminate=!1),n||this.$emit("selection-change",{detail:{value:this.backData,index:this.backIndexData}})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-table-scroll",{"table--border":n.border,"border-none":!o.noData}])},[e.createElementVNode("view",{class:e.normalizeClass(["uni-table",{"table--stripe":n.stripe}]),style:e.normalizeStyle({"min-width":o.minWidth+"px"})},[e.renderSlot(t.$slots,"default",{},void 0,!0),o.noData?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-table-loading"},[e.createElementVNode("view",{class:e.normalizeClass(["uni-table-text",{"empty-border":n.border}])},e.toDisplayString(n.emptyText),3)])):e.createCommentVNode("",!0),n.loading?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["uni-table-mask",{"empty-border":n.border}])},[e.createElementVNode("div",{class:"uni-table--loader"})],2)):e.createCommentVNode("",!0)],6)],2)}],["__scopeId","data-v-21bafa3b"]]),sd=[{date:"2020-09-01",name:"Dcloud1",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-02",name:"Dcloud2",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-03",name:"Dcloud3",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-04",name:"Dcloud4",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-05",name:"Dcloud5",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-06",name:"Dcloud6",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-07",name:"Dcloud7",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-08",name:"Dcloud8",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-09",name:"Dcloud9",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-10",name:"Dcloud10",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-11",name:"Dcloud11",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-12",name:"Dcloud12",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-13",name:"Dcloud13",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-14",name:"Dcloud14",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-15",name:"Dcloud15",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-16",name:"Dcloud16",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-01",name:"Dcloud17",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-02",name:"Dcloud18",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-03",name:"Dcloud19",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-04",name:"Dcloud20",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-05",name:"Dcloud21",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-06",name:"Dcloud22",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-07",name:"Dcloud23",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-08",name:"Dcloud24",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-09",name:"Dcloud25",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-10",name:"Dcloud26",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-11",name:"Dcloud27",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-12",name:"Dcloud28",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-13",name:"Dcloud29",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-14",name:"Dcloud30",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-15",name:"Dcloud31",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-16",name:"Dcloud32",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-01",name:"Dcloud33",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-02",name:"Dcloud34",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-03",name:"Dcloud35",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-04",name:"Dcloud36",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-05",name:"Dcloud37",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-06",name:"Dcloud38",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-07",name:"Dcloud39",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-08",name:"Dcloud40",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-09",name:"Dcloud41",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-10",name:"Dcloud42",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-11",name:"Dcloud43",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-12",name:"Dcloud44",address:"上海市普陀区金沙江路 1516 弄"},{date:"2020-09-13",name:"Dcloud45",address:"上海市普陀区金沙江路 1518 弄"},{date:"2020-09-14",name:"Dcloud46",address:"上海市普陀区金沙江路 1517 弄"},{date:"2020-09-15",name:"Dcloud47",address:"上海市普陀区金沙江路 1519 弄"},{date:"2020-09-16",name:"Dcloud48",address:"上海市普陀区金沙江路 1516 弄"}],ld={data:()=>({searchVal:"",tableData:[],pageSize:10,pageCurrent:1,total:0,loading:!1}),onLoad(){this.selectedIndexs=[],this.getData(1)},methods:{selectedItems(){return this.selectedIndexs.map((e=>this.tableData[e]))},selectionChange(e){n("log","at pages/extUI/table/table.vue:57",e.detail.index),this.selectedIndexs=e.detail.index},delTable(){n("log","at pages/extUI/table/table.vue:62",this.selectedItems())},change(e){this.$refs.table.clearSelection(),this.selectedIndexs.length=0,this.getData(e.current)},search(){this.getData(1,this.searchVal)},getData(e,t=""){this.loading=!0,this.pageCurrent=e,this.request({pageSize:this.pageSize,pageCurrent:e,value:t,success:e=>{this.tableData=e.data,this.total=e.total,this.loading=!1}})},request(e){const{pageSize:t,pageCurrent:a,success:n,value:i}=e;let o=sd.length,s=sd.filter(((e,n)=>{const i=n-(a-1)*t;return i<t&&i>=0}));i&&(s=[],sd.forEach((e=>{-1!==e.name.indexOf(i)&&s.push(e)})),o=s.length),setTimeout((()=>{"function"==typeof n&&n({data:s,total:o})}),500)}}};const rd=t(ld,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-th"),td),c=i(e.resolveDynamicComponent("uni-tr"),nd),d=i(e.resolveDynamicComponent("uni-td"),id),u=i(e.resolveDynamicComponent("uni-table"),od),h=i(e.resolveDynamicComponent("uni-pagination"),uc);return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{class:"uni-container"},[e.createVNode(u,{ref:"table",loading:s.loading,border:"",stripe:"",type:"selection",emptyText:"暂无更多数据",onSelectionChange:l.selectionChange},{default:e.withCtx((()=>[e.createVNode(c,null,{default:e.withCtx((()=>[e.createVNode(r,{width:"150",align:"center"},{default:e.withCtx((()=>[e.createTextVNode("日期")])),_:1}),e.createVNode(r,{width:"150",align:"center"},{default:e.withCtx((()=>[e.createTextVNode("姓名")])),_:1}),e.createVNode(r,{align:"center"},{default:e.withCtx((()=>[e.createTextVNode("地址")])),_:1}),e.createVNode(r,{width:"204",align:"center"},{default:e.withCtx((()=>[e.createTextVNode("设置")])),_:1})])),_:1}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.tableData,((t,a)=>(e.openBlock(),e.createBlock(c,{key:a},{default:e.withCtx((()=>[e.createVNode(d,null,{default:e.withCtx((()=>[e.createTextVNode(e.toDisplayString(t.date),1)])),_:2},1024),e.createVNode(d,null,{default:e.withCtx((()=>[e.createElementVNode("view",{class:"name"},e.toDisplayString(t.name),1)])),_:2},1024),e.createVNode(d,{align:"center"},{default:e.withCtx((()=>[e.createTextVNode(e.toDisplayString(t.address),1)])),_:2},1024),e.createVNode(d,null,{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-group"},[e.createElementVNode("button",{class:"uni-button",size:"mini",type:"primary"},"修改"),e.createElementVNode("button",{class:"uni-button",size:"mini",type:"warn"},"删除")])])),_:1})])),_:2},1024)))),128))])),_:1},8,["loading","onSelectionChange"]),e.createElementVNode("view",{class:"uni-pagination-box"},[e.createVNode(h,{"show-icon":"","page-size":s.pageSize,current:s.pageCurrent,total:s.total,onChange:l.change},null,8,["page-size","current","total","onChange"])])])])}]]);function cd(e,t=2){for(e+="";e.length<t;)e="0"+e;return e.slice(-t)}const dd={yyyy:e=>cd(e.year,4),yy:e=>cd(e.year),MM:e=>cd(e.month),M:e=>e.month,dd:e=>cd(e.day),d:e=>e.day,hh:e=>cd(e.hour),h:e=>e.hour,mm:e=>cd(e.minute),m:e=>e.minute,ss:e=>cd(e.second),s:e=>e.second,SSS:e=>cd(e.millisecond,3),S:e=>e.millisecond};function ud(e){return e instanceof Date?e:"string"==typeof e?e.indexOf("T")>-1?new Date(e):new Date(e.replace(/-/g,"/")):new Date(e)}function hd(e,{locale:t="zh",threshold:a=[6e4,36e5],format:n="yyyy/MM/dd hh:mm:ss"}){if("-"===e)return e;if(!e&&0!==e)return"";const i={zh:{year:"年",month:"月",day:"天",hour:"小时",minute:"分钟",second:"秒",ago:"前",later:"后",justNow:"刚刚",soon:"马上",template:"{num}{unit}{suffix}"},en:{year:"year",month:"month",day:"day",hour:"hour",minute:"minute",second:"second",ago:"ago",later:"later",justNow:"just now",soon:"soon",template:"{num} {unit} {suffix}"}},o=i[t]||i.zh;let s,l,r=ud(e),c=r.getTime()-Date.now(),d=Math.abs(c);if(d<a[0])return c<0?o.justNow:o.soon;if(d>=a[1])return function(e,t="yyyy/MM/dd hh:mm:ss"){if(!e&&0!==e)return"";const a={year:(e=ud(e)).getFullYear(),month:e.getMonth()+1,day:e.getDate(),hour:e.getHours(),minute:e.getMinutes(),second:e.getSeconds(),millisecond:e.getMilliseconds()},n=/yyyy|yy|MM|M|dd|d|hh|h|mm|m|ss|s|SSS|SS|S/;let i=!0,o=t;for(;i;)i=!1,o=o.replace(n,(function(e){return i=!0,dd[e](a)}));return o}(r,n);let u=o.later;c<0&&(u=o.ago,c=-c);const h=Math.floor(c/1e3),p=Math.floor(h/60),m=Math.floor(p/60),g=Math.floor(m/24),f=Math.floor(g/30),y=Math.floor(f/12);switch(!0){case y>0:s=y,l=o.year;break;case f>0:s=f,l=o.month;break;case g>0:s=g,l=o.day;break;case m>0:s=m,l=o.hour;break;case p>0:s=p,l=o.minute;break;default:s=h,l=o.second}return"en"===t&&(1===s?s="a":l+="s"),o.template.replace(/{\s*num\s*}/g,s+"").replace(/{\s*unit\s*}/g,l).replace(/{\s*suffix\s*}/g,u)}const pd=t({name:"uniDateformat",props:{date:{type:[Object,String,Number],default:()=>"-"},locale:{type:String,default:"zh"},threshold:{type:Array,default:()=>[0,0]},format:{type:String,default:"yyyy/MM/dd hh:mm:ss"},refreshRate:{type:[Number,String],default:0}},data:()=>({refreshMark:0}),computed:{dateShow(){return this.refreshMark,hd(this.date,{locale:this.locale,threshold:this.threshold,format:this.format})}},watch:{refreshRate:{handler(){this.setAutoRefresh()},immediate:!0}},methods:{refresh(){this.refreshMark++},setAutoRefresh(){clearInterval(this.refreshInterval),this.refreshRate&&(this.refreshInterval=setInterval((()=>{this.refresh()}),parseInt(this.refreshRate)))}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("text",null,e.toDisplayString(s.dateShow),1)}]]);const md=t({data:()=>({now:Date.now()}),methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-dateformat"),pd),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"日期格式化组件，通常用于需要展示友好的日期格式的场景。")])),_:1}),e.createVNode(d,{title:"基础用法",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{date:s.now-72e5},null,8,["date"]),e.createVNode(c,{date:"2020/12/12"})])])),_:1}),e.createVNode(d,{title:"设置阈值",subTitle:"阈值用于控制什么时候显示刚刚|马上，什么时候显示xx分钟前|xx分钟后",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{date:s.now-3e4,threshold:[0,36e5]},null,8,["date"]),e.createVNode(c,{date:s.now-3e4,threshold:[0,0]},null,8,["date"])])])),_:1}),e.createVNode(d,{title:"使用英文",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{date:s.now-12e5,threshold:[6e4,36e5],locale:"en"},null,8,["date"]),e.createVNode(c,{date:s.now-3e4,threshold:[6e4,36e5],locale:"en"},null,8,["date"]),e.createVNode(c,{date:s.now-8e4,threshold:[6e4,36e5],locale:"en"},null,8,["date"])])])),_:1})])}]]);const gd=t({data:()=>({radio1:0,radio2:0,radio3:0,radio4:0,radio5:0,radio6:0,checkbox1:[0],checkbox2:[0],checkbox3:[0],checkbox4:[0],checkbox5:[0],checkbox6:[0],sex:[{text:"男",value:0},{text:"女",value:1},{text:"未知",value:2}],sex1:[{text:"男",value:0},{text:"女",value:1,disable:!0},{text:"未知",value:2}],hobby:[{text:"足球",value:0},{text:"篮球",value:1},{text:"游泳",value:2}],hobby2:[{text:"足球",value:0,disable:!0},{text:"篮球",value:1,disable:!0},{text:"游泳",value:2}]}),onLoad(){},onReady(){},methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-data-checkbox"),ql),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"通过数据驱动的单选框和复选框，可直接通过连接 uniCloud 获取数据，同时可以配合表单组件 uni-forms 使用")])),_:1}),e.createVNode(d,{title:"单选",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"单选选中："+e.toDisplayString(JSON.stringify(s.radio1)),1),e.createVNode(c,{modelValue:s.radio1,"onUpdate:modelValue":a[0]||(a[0]=e=>s.radio1=e),localdata:s.sex},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"多选",subTitle:"使用multiple属性开启多选",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"多选选中："+e.toDisplayString(JSON.stringify(s.checkbox1)),1),e.createVNode(c,{multiple:"",modelValue:s.checkbox1,"onUpdate:modelValue":a[1]||(a[1]=e=>s.checkbox1=e),localdata:s.hobby},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"最大最小值",subTitle:"使用 min / max 设置多选的最大最小值,单选无效"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"选中："+e.toDisplayString(JSON.stringify(s.checkbox6)),1),e.createVNode(c,{min:"1",max:"2",multiple:"",modelValue:s.checkbox6,"onUpdate:modelValue":a[2]||(a[2]=e=>s.checkbox6=e),localdata:s.hobby},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"更多样式 - button",subTitle:"使用mode=button属性使用按钮样式",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5"},[e.createElementVNode("view",{class:"text"},"单选选中："+e.toDisplayString(JSON.stringify(s.radio2)),1),e.createVNode(c,{mode:"button",modelValue:s.radio2,"onUpdate:modelValue":a[3]||(a[3]=e=>s.radio2=e),localdata:s.sex},null,8,["modelValue","localdata"])]),e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"多选选中："+e.toDisplayString(JSON.stringify(s.checkbox2)),1),e.createVNode(c,{mode:"button",multiple:"",modelValue:s.checkbox2,"onUpdate:modelValue":a[4]||(a[4]=e=>s.checkbox2=e),localdata:s.hobby},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"更多样式 - tag",subTitle:"使用mode=tag属性使用标签样式",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5"},[e.createElementVNode("view",{class:"text"},"单选选中："+e.toDisplayString(JSON.stringify(s.radio3)),1),e.createVNode(c,{mode:"tag",modelValue:s.radio3,"onUpdate:modelValue":a[5]||(a[5]=e=>s.radio3=e),localdata:s.sex},null,8,["modelValue","localdata"])]),e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"多选选中："+e.toDisplayString(JSON.stringify(s.checkbox3)),1),e.createVNode(c,{mode:"tag",multiple:"",modelValue:s.checkbox3,"onUpdate:modelValue":a[6]||(a[6]=e=>s.checkbox3=e),localdata:s.hobby},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"禁用",subTitle:"数据中使用 disable 属性实现单独禁用,组件使用 disable 属性实现全部禁用",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5"},[e.createElementVNode("view",{class:"text"},"单选选中："+e.toDisplayString(JSON.stringify(s.radio4)),1),e.createVNode(c,{mode:"button",modelValue:s.radio4,"onUpdate:modelValue":a[7]||(a[7]=e=>s.radio4=e),localdata:s.sex1},null,8,["modelValue","localdata"])]),e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"多选选中："+e.toDisplayString(JSON.stringify(s.checkbox4)),1),e.createVNode(c,{mode:"button",multiple:"",modelValue:s.checkbox4,"onUpdate:modelValue":a[8]||(a[8]=e=>s.checkbox4=e),localdata:s.hobby2},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"自定义高亮颜色",subTitle:"使用 selectedColor 属性修改颜色",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5"},[e.createElementVNode("view",{class:"text"},"单选选中："+e.toDisplayString(JSON.stringify(s.radio5)),1),e.createVNode(c,{selectedColor:"red",modelValue:s.radio5,"onUpdate:modelValue":a[9]||(a[9]=e=>s.radio5=e),localdata:s.sex1},null,8,["modelValue","localdata"])]),e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createElementVNode("view",{class:"text"},"多选选中："+e.toDisplayString(JSON.stringify(s.checkbox5)),1),e.createVNode(c,{selectedColor:"red",multiple:"",modelValue:s.checkbox5,"onUpdate:modelValue":a[10]||(a[10]=e=>s.checkbox5=e),localdata:s.hobby2},null,8,["modelValue","localdata"])])])),_:1})])}]]),fd={data:()=>({value:"",password:"",placeholderStyle:"color:#2979FF;font-size:14px",styles:{color:"#2979FF",borderColor:"#2979FF"}}),onLoad(){},onReady(){},methods:{input(e){n("log","at pages/extUI/easyinput/easyinput.vue:85","输入内容：",e)},iconClick(e){uni.showToast({title:`点击了${"prefix"===e?"左侧":"右侧"}的图标`,icon:"none"})}}};const yd=t(fd,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-easyinput"),En),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"easyinput 组件是对原生input组件的增强 ，是专门为配合表单组件 uni-forms 而设计的，easyinput 内置了边框，图标等，同时包含 input 所有功能")])),_:1}),e.createVNode(d,{title:"默认",subTitle:"使用 focus 属性自动获取输入框焦点",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{errorMessage:"",modelValue:s.value,"onUpdate:modelValue":a[0]||(a[0]=e=>s.value=e),focus:"",placeholder:"请输入内容",onInput:l.input},null,8,["modelValue","onInput"])])),_:1}),e.createVNode(d,{title:"去除空格",subTitle:"使用 trim 属性 ,可以控制返回内容的空格 ",type:"line",padding:""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-subtitle"},"输入内容："+e.toDisplayString('"'+s.value+'"'),1),e.createVNode(c,{class:"uni-mt-5",trim:"all",modelValue:s.value,"onUpdate:modelValue":a[1]||(a[1]=e=>s.value=e),placeholder:"请输入内容",onInput:l.input},null,8,["modelValue","onInput"])])),_:1}),e.createVNode(d,{title:"自定义样式",subTitle:"使用 styles 属性 ,可以自定义输入框样式",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[2]||(a[2]=e=>s.value=e),styles:s.styles,placeholderStyle:s.placeholderStyle,placeholder:"请输入内容",onInput:l.input},null,8,["modelValue","styles","placeholderStyle","onInput"])])),_:1}),e.createVNode(d,{title:"图标",subTitle:"使用 prefixIcon / suffixIcon 属性 ,可以自定义输入框左右侧图标",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{prefixIcon:"search",modelValue:s.value,"onUpdate:modelValue":a[3]||(a[3]=e=>s.value=e),placeholder:"左侧图标",onIconClick:l.iconClick},null,8,["modelValue","onIconClick"]),e.createVNode(c,{class:"uni-mt-5",suffixIcon:"search",modelValue:s.value,"onUpdate:modelValue":a[4]||(a[4]=e=>s.value=e),placeholder:"右侧图标",onIconClick:l.iconClick},null,8,["modelValue","onIconClick"])])),_:1}),e.createVNode(d,{title:"插槽",subTitle:"使用 prefixIcon / suffixIcon 插槽 ,可以自定义输入框左右侧内容",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[5]||(a[5]=e=>s.value=e),placeholder:"请输入网址"},{prefixIcon:e.withCtx((()=>[e.createElementVNode("view",{style:{"background-color":"#f2f2f2",padding:"0 10rpx",height:"70rpx","line-height":"70rpx","margin-right":"10rpx"}},"https://")])),_:1},8,["modelValue"]),e.createVNode(c,{class:"uni-mt-5",prefixIcon:"search",modelValue:s.value,"onUpdate:modelValue":a[6]||(a[6]=e=>s.value=e),placeholder:"想看什么,搜索一下"},{suffixIcon:e.withCtx((()=>[e.createElementVNode("button",{class:"uni-btn uni-btn-mini uni-btn-radius",type:"primary",size:"mini"},"搜索")])),_:1},8,["modelValue"])])),_:1}),e.createVNode(d,{title:"禁用",subTitle:"使用 disabled 属性禁用输入框",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{disabled:"",value:"已禁用",placeholder:"请输入内容"})])),_:1}),e.createVNode(d,{title:"密码框",subTitle:"指定属性 type=password 使用密码框,右侧会显示眼睛图标",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{type:"password",modelValue:s.password,"onUpdate:modelValue":a[7]||(a[7]=e=>s.password=e),placeholder:"请输入密码"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{title:"多行文本",subTitle:"指定属性 type=textarea 使用多行文本框",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{type:"textarea",modelValue:s.value,"onUpdate:modelValue":a[8]||(a[8]=e=>s.value=e),placeholder:"请输入内容"},null,8,["modelValue"])])),_:1}),e.createVNode(d,{title:"多行文本自动高度",subTitle:"使用属性 autoHeight 使多行文本框自动增高",type:"line",padding:""},{default:e.withCtx((()=>[e.createVNode(c,{type:"textarea",autoHeight:"",modelValue:s.value,"onUpdate:modelValue":a[9]||(a[9]=e=>s.value=e),placeholder:"请输入内容"},null,8,["modelValue"])])),_:1})])}]]),vd={data:()=>({value:0,range:[{value:0,text:"篮球",disable:!0},{value:1,text:"足球"},{value:2,text:"游泳"}]}),methods:{change(e){n("log","at pages/extUI/data-select/data-select.vue:55","e:",e)}}};const wd=t(vd,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-data-select"),hr),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"通过数据驱动的单选框和复选框，可直接通过连接 uniCloud 获取数据，同时可以配合表单组件 uni-forms 使用")])),_:1}),e.createVNode(d,{title:"本地数据",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[0]||(a[0]=e=>s.value=e),localdata:s.range,onChange:l.change},null,8,["modelValue","localdata","onChange"])])])),_:1}),e.createVNode(d,{title:"禁用状态",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[1]||(a[1]=e=>s.value=e),disabled:!0,localdata:s.range},null,8,["modelValue","localdata"])])])),_:1}),e.createVNode(d,{title:"是否可清除已选项",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[2]||(a[2]=e=>s.value=e),localdata:s.range,onChange:l.change,clear:!1},null,8,["modelValue","localdata","onChange"])])])),_:1}),e.createVNode(d,{title:"配置左侧标题",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-px-5 uni-pb-5"},[e.createVNode(c,{modelValue:s.value,"onUpdate:modelValue":a[3]||(a[3]=e=>s.value=e),localdata:s.range,onChange:l.change,label:"应用选择"},null,8,["modelValue","localdata","onChange"])])])),_:1})])}]]),bd={data(){return{dateString:this.getDateTime(new Date),datetimeString:this.getDateTime(new Date),dateTimestamp:Date.now(),dateInstance:new Date,dateRange:[this.getDate(Date.now()-432e6),this.getDate(Date.now()+432e6)],datetimeRange:[this.getDateTime(Date.now()-432e6),this.getDateTime(Date.now()+432e6)],start:Date.now()-864e6,end:Date.now()+864e6}},watch:{datetimeString(){n("log","at pages/extUI/datetime-picker/datetime-picker.vue:65","日期时间单选:",this.datetimeString)},dateRange(){n("log","at pages/extUI/datetime-picker/datetime-picker.vue:68","日期范围选:",this.dateRange)},datetimeRange(){n("log","at pages/extUI/datetime-picker/datetime-picker.vue:71","日期时间范围选:",this.datetimeRange)}},methods:{change(e){n("log","at pages/extUI/datetime-picker/datetime-picker.vue:76","----change事件:",e)},maskClick(e){n("log","at pages/extUI/datetime-picker/datetime-picker.vue:79","----maskClick事件:",e)},getDateTime(e){return`${this.getDate(e)} ${this.getTime(e)}`},getDate(e){const t=(e=new Date(e)).getFullYear(),a=e.getMonth()+1,n=e.getDate();return`${t}-${this.addZero(a)}-${this.addZero(n)}`},getTime(e){const t=(e=new Date(e)).getHours(),a=e.getMinutes(),n=e.getSeconds();return this.hideSecond?`${this.addZero(t)}:${this.addZero(a)}`:`${this.addZero(t)}:${this.addZero(a)}:${this.addZero(n)}`},addZero:e=>(e<10&&(e=`0${e}`),e)}};const kd=t(bd,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr),d=i(e.resolveDynamicComponent("uni-datetime-picker"),rr);return e.openBlock(),e.createElementBlock("view",{class:"page container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"可以同时选择日期和时间的选择器")])),_:1}),e.createVNode(c,{title:"日期用法："+s.dateString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{type:"date","clear-icon":!1,modelValue:s.dateString,"onUpdate:modelValue":a[0]||(a[0]=e=>s.dateString=e),onMaskClick:l.maskClick},null,8,["modelValue","onMaskClick"])]),e.createVNode(c,{title:"日期时间用法："+s.datetimeString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{type:"datetime",start:s.start,end:s.end,modelValue:s.datetimeString,"onUpdate:modelValue":a[1]||(a[1]=e=>s.datetimeString=e),onChange:l.change},null,8,["start","end","modelValue","onChange"])]),e.createVNode(c,{title:"日期范围用法：["+s.dateRange+"]",type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.dateRange,"onUpdate:modelValue":a[2]||(a[2]=e=>s.dateRange=e),type:"daterange",onMaskClick:l.maskClick},null,8,["modelValue","onMaskClick"])]),e.createVNode(c,{title:"日期时间范围用法：["+s.datetimeRange+"]",type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.datetimeRange,"onUpdate:modelValue":a[3]||(a[3]=e=>s.datetimeRange=e),type:"datetimerange",rangeSeparator:"至"},null,8,["modelValue"])]),e.createVNode(c,{title:"时间戳用法："+s.dateTimestamp,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{returnType:"timestamp",modelValue:s.dateTimestamp,"onUpdate:modelValue":a[4]||(a[4]=e=>s.dateTimestamp=e),onChange:l.change},null,8,["modelValue","onChange"])]),e.createVNode(c,{title:"date 对象用法："+s.dateInstance,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{type:"datetime",returnType:"date",modelValue:s.dateInstance,"onUpdate:modelValue":a[5]||(a[5]=e=>s.dateInstance=e),onChange:l.change},null,8,["modelValue","onChange"])]),e.createVNode(c,{title:"插槽用法："+s.dateString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.dateString,"onUpdate:modelValue":a[6]||(a[6]=e=>s.dateString=e)},{default:e.withCtx((()=>[e.createTextVNode("我是一个插槽，点击我")])),_:1},8,["modelValue"])]),e.createVNode(c,{title:"无边框用法："+s.dateString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.dateString,"onUpdate:modelValue":a[7]||(a[7]=e=>s.dateString=e),border:!1},null,8,["modelValue"])]),e.createVNode(c,{title:"隐藏清除按钮用法："+s.dateString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.dateString,"onUpdate:modelValue":a[8]||(a[8]=e=>s.dateString=e),clearIcon:!1},null,8,["modelValue"])]),e.createVNode(c,{title:"disabled用法："+s.dateString,type:"line"},null,8,["title"]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{modelValue:s.dateString,"onUpdate:modelValue":a[9]||(a[9]=e=>s.dateString=e),disabled:""},null,8,["modelValue"])])])}]]);const xd=t({name:"uniCol",props:{span:{type:Number,default:24},offset:{type:Number,default:-1},pull:{type:Number,default:-1},push:{type:Number,default:-1},xs:[Number,Object],sm:[Number,Object],md:[Number,Object],lg:[Number,Object],xl:[Number,Object]},data:()=>({gutter:0,sizeClass:"",parentWidth:0,nvueWidth:0,marginLeft:0,right:0,left:0}),created(){let e=this.$parent;for(;e&&"uniRow"!==e.$options.componentName;)e=e.$parent;this.updateGutter(e.gutter),e.$watch("gutter",(e=>{this.updateGutter(e)}))},computed:{sizeList(){let{span:e,offset:t,pull:a,push:n}=this;return{span:e,offset:t,pull:a,push:n}},pointClassList(){let e=[];return["xs","sm","md","lg","xl"].forEach((t=>{const a=this[t];"number"==typeof a?e.push(`uni-col-${t}-${a}`):"object"==typeof a&&a&&Object.keys(a).forEach((n=>{e.push("span"===n?`uni-col-${t}-${a[n]}`:`uni-col-${t}-${n}-${a[n]}`)}))})),e.join(" ")}},methods:{updateGutter(e){e=Number(e),isNaN(e)||(this.gutter=e/2)}},watch:{sizeList:{immediate:!0,handler(e){let t=[];for(let a in e){const n=e[a];!n&&0!==n||-1===n||t.push("span"===a?`uni-col-${n}`:`uni-col-${a}-${n}`)}this.sizeClass=t.join(" ")}}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-col",o.sizeClass,s.pointClassList]),style:e.normalizeStyle({paddingLeft:`${Number(o.gutter)}rpx`,paddingRight:`${Number(o.gutter)}rpx`})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-84ac5f6d"]]);const Vd=t({name:"uniRow",componentName:"uniRow",props:{type:String,gutter:Number,justify:{type:String,default:"start"},align:{type:String,default:"top"},width:{type:[String,Number],default:750}},created(){},computed:{marginValue(){return this.gutter?-this.gutter/2:0},typeClass(){return"flex"===this.type?"uni-row--flex":""},justifyClass(){return"start"!==this.justify?`uni-row--flex-justify-${this.justify}`:""},alignClass(){return"top"!==this.align?`uni-row--flex-align-${this.align}`:""}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-row",s.typeClass,s.justifyClass,s.alignClass]),style:e.normalizeStyle({marginLeft:`${Number(s.marginValue)}rpx`,marginRight:`${Number(s.marginValue)}rpx`})},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-9ff25b7f"]]);const Nd=t({data:()=>({gutter:0,nvueWidth:730})},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-col"),xd),d=i(e.resolveDynamicComponent("uni-row"),Vd),u=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-full":"","is-shadow":!1},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"}," 流式栅格系统，随着屏幕或视口分为 24 份，可以迅速简便地创建布局")])),_:1}),e.createVNode(u,{title:"基础布局",subTitle:"使用单一分栏创建基础的栅格布局",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{class:"demo-uni-row",width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,null,{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark_deep"})])),_:1})])),_:1},8,["width"]),e.createVNode(d,{class:"demo-uni-row",width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:12},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:12},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["width"]),e.createVNode(d,{class:"demo-uni-row",width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1})])),_:1},8,["width"]),e.createVNode(d,{class:"demo-uni-row",width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["width"]),e.createVNode(d,{class:"demo-uni-row",width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["width"])])])),_:1}),e.createVNode(u,{title:"混合布局",subTitle:"通过基础的 1/24 分栏任意扩展组合形成较为复杂的混合布局",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["gutter","width"]),e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:16},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{span:4},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1})])),_:1},8,["gutter","width"])])])),_:1}),e.createVNode(u,{title:"分栏偏移",subTitle:"支持偏移指定的栏数",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:8},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:8,offset:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["gutter","width"]),e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:6,offset:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:6,offset:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["gutter","width"]),e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:12,pull:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{span:6,push:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["gutter","width"]),e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter,width:s.nvueWidth},{default:e.withCtx((()=>[e.createVNode(c,{span:12,offset:6},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1})])),_:1},8,["gutter","width"])])])),_:1}),e.createVNode(u,{title:"响应式布局",subTitle:"共五个响应尺寸：xs、sm、md、lg 和 xl",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(d,{class:"demo-uni-row",gutter:s.gutter},{default:e.withCtx((()=>[e.createVNode(c,{xs:8,sm:6,md:4,lg:3,xl:1},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{xs:4,sm:6,md:8,lg:9,xl:11},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1}),e.createVNode(c,{xs:4,sm:6,md:8,lg:9,xl:11},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col dark"})])),_:1}),e.createVNode(c,{xs:8,sm:6,md:4,lg:3,xl:1},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"demo-uni-col light"})])),_:1})])),_:1},8,["gutter"])])])),_:1})])}]]),Ed="chooseAndUploadFile:fail";function Cd(e,t){return e.tempFiles.forEach(((e,a)=>{e.name||(e.name=e.path.substring(e.path.lastIndexOf("/")+1)),t&&(e.fileType=t),e.cloudPath=Date.now()+"_"+a+e.name.substring(e.name.lastIndexOf("."))})),e.tempFilePaths||(e.tempFilePaths=e.tempFiles.map((e=>e.path))),e}function _d(e,t=5,a){const n=(e=JSON.parse(JSON.stringify(e))).length;let i=0,o=this;return new Promise((s=>{for(;i<t;)l();function l(){let t=i++;if(t>=n)return void(!e.find((e=>!e.url&&!e.errMsg))&&s(e));const r=e[t],c=o.files.findIndex((e=>e.uuid===r.uuid));r.url="",delete r.errMsg,Cl.uploadFile({filePath:r.path,cloudPath:r.cloudPath,fileType:r.fileType,onUploadProgress:e=>{e.index=c,a&&a(e)}}).then((e=>{r.url=e.fileID,r.index=c,t<n&&l()})).catch((e=>{r.errMsg=e.errMsg||e.message,r.index=c,t<n&&l()}))}}))}function Sd(e,{onChooseFile:t,onUploadProgress:a}){return e.then((e=>{if(t){const a=t(e);if(void 0!==a)return Promise.resolve(a).then((t=>void 0===t?e:t))}return e})).then((e=>!1===e?{errMsg:"chooseAndUploadFile:ok",tempFilePaths:[],tempFiles:[]}:e))}function Td(e={type:"all"}){return"image"===e.type?Sd(function(e){const{count:t,sizeType:a=["original","compressed"],sourceType:n,extension:i}=e;return new Promise(((e,o)=>{uni.chooseImage({count:t,sizeType:a,sourceType:n,extension:i,success(t){e(Cd(t,"image"))},fail(e){o({errMsg:e.errMsg.replace("chooseImage:fail",Ed)})}})}))}(e),e):"video"===e.type?Sd(function(e){const{count:t,camera:a,compressed:n,maxDuration:i,sourceType:o,extension:s}=e;return new Promise(((e,t)=>{uni.chooseVideo({camera:a,compressed:n,maxDuration:i,sourceType:o,extension:s,success(t){const{tempFilePath:a,duration:n,size:i,height:o,width:s}=t;e(Cd({errMsg:"chooseVideo:ok",tempFilePaths:[a],tempFiles:[{name:t.tempFile&&t.tempFile.name||"",path:a,size:i,type:t.tempFile&&t.tempFile.type||"",width:s,height:o,duration:n,fileType:"video",cloudPath:""}]},"video"))},fail(e){t({errMsg:e.errMsg.replace("chooseVideo:fail",Ed)})}})}))}(e),e):Sd(function(e){const{count:t,extension:a}=e;return new Promise(((e,n)=>{let i=uni.chooseFile;if("undefined"!=typeof wx&&"function"==typeof wx.chooseMessageFile&&(i=wx.chooseMessageFile),"function"!=typeof i)return n({errMsg:Ed+" 请指定 type 类型，该平台仅支持选择 image 或 video。"});i({type:"all",count:t,extension:a,success(t){e(Cd(t))},fail(e){n({errMsg:e.errMsg.replace("chooseFile:fail",Ed)})}})}))}(e),e)}const Bd=e=>{const t=e.lastIndexOf("."),a=e.length;return{name:e.substring(0,t),ext:e.substring(t+1,a)}},Dd=e=>{if(Array.isArray(e))return e;return e.replace(/(\[|\])/g,"").split(",")},Id=async(e,t="image")=>{const a=Bd(e.name).ext.toLowerCase();let n={name:e.name,uuid:e.uuid,extname:a||"",cloudPath:e.cloudPath,fileType:e.fileType,thumbTempFilePath:e.thumbTempFilePath,url:e.path||e.path,size:e.size,image:{},path:e.path,video:{}};if("image"===t){const t=await(i=e.path,new Promise(((e,t)=>{uni.getImageInfo({src:i,success(t){e(t)},fail(e){t(e)}})})));delete n.video,n.image.width=t.width,n.image.height=t.height,n.image.location=t.path}else delete n.image;var i;return n};const Pd=t({name:"uniFilePicker",components:{uploadImage:t({name:"uploadImage",emits:["uploadFiles","choose","delFile"],props:{filesList:{type:Array,default:()=>[]},disabled:{type:Boolean,default:!1},disablePreview:{type:Boolean,default:!1},limit:{type:[Number,String],default:9},imageStyles:{type:Object,default:()=>({width:"auto",height:"auto",border:{}})},delIcon:{type:Boolean,default:!0},readonly:{type:Boolean,default:!1}},computed:{styles(){return Object.assign({width:"auto",height:"auto",border:{}},this.imageStyles)},boxStyle(){const{width:e="auto",height:t="auto"}=this.styles;let a={};"auto"===t?"auto"!==e?(a.height=this.value2px(e),a["padding-top"]=0):a.height=0:(a.height=this.value2px(t),a["padding-top"]=0),a.width="auto"===e?"auto"!==t?this.value2px(t):"33.3%":this.value2px(e);let n="";for(let i in a)n+=`${i}:${a[i]};`;return n},borderStyle(){let{border:e}=this.styles,t={};if("boolean"==typeof e)t.border=e?"1px #eee solid":"none";else{let a=e&&e.width||1;a=this.value2px(a);let n=e&&e.radius||3;n=this.value2px(n),t={"border-width":a,"border-style":e&&e.style||"solid","border-color":e&&e.color||"#eee","border-radius":n}}let a="";for(let n in t)a+=`${n}:${t[n]};`;return a}},methods:{uploadFiles(e,t){this.$emit("uploadFiles",e)},choose(){this.$emit("choose")},delFile(e){this.$emit("delFile",e)},prviewImage(e,t){let a=[];1===Number(this.limit)&&this.disablePreview&&!this.disabled&&this.$emit("choose"),this.disablePreview||(this.filesList.forEach((e=>{a.push(e.url)})),uni.previewImage({urls:a,current:t}))},value2px:e=>("number"==typeof e?e+="px":-1===e.indexOf("%")&&(e=-1!==e.indexOf("px")?e:e+"px"),e)}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-file-picker__container"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.filesList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"file-picker__box",key:a,style:e.normalizeStyle(s.boxStyle)},[e.createElementVNode("view",{class:"file-picker__box-content",style:e.normalizeStyle(s.borderStyle)},[e.createElementVNode("image",{class:"file-image",src:t.url,mode:"aspectFill",onClick:e.withModifiers((e=>s.prviewImage(t,a)),["stop"])},null,8,["src","onClick"]),n.delIcon&&!n.readonly?(e.openBlock(),e.createElementBlock("view",{key:0,class:"icon-del-box",onClick:e.withModifiers((e=>s.delFile(a)),["stop"])},[e.createElementVNode("view",{class:"icon-del"}),e.createElementVNode("view",{class:"icon-del rotate"})],8,["onClick"])):e.createCommentVNode("",!0),t.progress&&100!==t.progress||0===t.progress?(e.openBlock(),e.createElementBlock("view",{key:1,class:"file-picker__progress"},[e.createElementVNode("progress",{class:"file-picker__progress-item",percent:-1===t.progress?0:t.progress,"stroke-width":"4",backgroundColor:t.errMsg?"#ff5a5f":"#EBEBEB"},null,8,["percent","backgroundColor"])])):e.createCommentVNode("",!0),t.errMsg?(e.openBlock(),e.createElementBlock("view",{key:2,class:"file-picker__mask",onClick:e.withModifiers((e=>s.uploadFiles(t,a)),["stop"])}," 点击重试 ",8,["onClick"])):e.createCommentVNode("",!0)],4)],4)))),128)),n.filesList.length<n.limit&&!n.readonly?(e.openBlock(),e.createElementBlock("view",{key:0,class:"file-picker__box",style:e.normalizeStyle(s.boxStyle)},[e.createElementVNode("view",{class:"file-picker__box-content is-add",style:e.normalizeStyle(s.borderStyle),onClick:a[0]||(a[0]=(...e)=>s.choose&&s.choose(...e))},[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("view",{class:"icon-add"}),e.createElementVNode("view",{class:"icon-add rotate"})]),!0)],4)],4)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-86b162f5"]]),uploadFile:t({name:"uploadFile",emits:["uploadFiles","choose","delFile"],props:{filesList:{type:Array,default:()=>[]},delIcon:{type:Boolean,default:!0},limit:{type:[Number,String],default:9},showType:{type:String,default:""},listStyles:{type:Object,default:()=>({border:!0,dividline:!0,borderStyle:{}})},readonly:{type:Boolean,default:!1}},computed:{list(){let e=[];return this.filesList.forEach((t=>{e.push(t)})),e},styles(){return Object.assign({border:!0,dividline:!0,"border-style":{}},this.listStyles)},borderStyle(){let{borderStyle:e,border:t}=this.styles,a={};if(t){let t=e&&e.width||1;t=this.value2px(t);let n=e&&e.radius||5;n=this.value2px(n),a={"border-width":t,"border-style":e&&e.style||"solid","border-color":e&&e.color||"#eee","border-radius":n}}else a.border="none";let n="";for(let i in a)n+=`${i}:${a[i]};`;return n},borderLineStyle(){let e={},{borderStyle:t}=this.styles;if(t&&t.color&&(e["border-color"]=t.color),t&&t.width){let a=t&&t.width||1,n=t&&t.style||0;"number"==typeof a?a+="px":a=a.indexOf("px")?a:a+"px",e["border-width"]=a,"number"==typeof n?n+="px":n=n.indexOf("px")?n:n+"px",e["border-top-style"]=n}let a="";for(let n in e)a+=`${n}:${e[n]};`;return a}},methods:{uploadFiles(e,t){this.$emit("uploadFiles",{item:e,index:t})},choose(){this.$emit("choose")},delFile(e){this.$emit("delFile",e)},value2px:e=>("number"==typeof e?e+="px":e=-1!==e.indexOf("px")?e:e+"px",e)}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"uni-file-picker__files"},[n.readonly?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"files-button",onClick:a[0]||(a[0]=(...e)=>s.choose&&s.choose(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)])),s.list.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"uni-file-picker__lists is-text-box",style:e.normalizeStyle(s.borderStyle)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.list,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["uni-file-picker__lists-box",{"files-border":0!==a&&s.styles.dividline}]),key:a,style:e.normalizeStyle(0!==a&&s.styles.dividline&&s.borderLineStyle)},[e.createElementVNode("view",{class:"uni-file-picker__item"},[e.createElementVNode("view",{class:"files__name"},e.toDisplayString(t.name),1),n.delIcon&&!n.readonly?(e.openBlock(),e.createElementBlock("view",{key:0,class:"icon-del-box icon-files",onClick:e=>s.delFile(a)},[e.createElementVNode("view",{class:"icon-del icon-files"}),e.createElementVNode("view",{class:"icon-del rotate"})],8,["onClick"])):e.createCommentVNode("",!0)]),t.progress&&100!==t.progress||0===t.progress?(e.openBlock(),e.createElementBlock("view",{key:0,class:"file-picker__progress"},[e.createElementVNode("progress",{class:"file-picker__progress-item",percent:-1===t.progress?0:t.progress,"stroke-width":"4",backgroundColor:t.errMsg?"#ff5a5f":"#EBEBEB"},null,8,["percent","backgroundColor"])])):e.createCommentVNode("",!0),"error"===t.status?(e.openBlock(),e.createElementBlock("view",{key:1,class:"file-picker__mask",onClick:e.withModifiers((e=>s.uploadFiles(t,a)),["stop"])}," 点击重试 ",8,["onClick"])):e.createCommentVNode("",!0)],6)))),128))],4)):e.createCommentVNode("",!0)])}],["__scopeId","data-v-e61666c7"]])},options:{virtualHost:!0},emits:["select","success","fail","progress","delete","update:modelValue","input"],props:{modelValue:{type:[Array,Object],default:()=>[]},value:{type:[Array,Object],default:()=>[]},disabled:{type:Boolean,default:!1},disablePreview:{type:Boolean,default:!1},delIcon:{type:Boolean,default:!0},autoUpload:{type:Boolean,default:!0},limit:{type:[Number,String],default:9},mode:{type:String,default:"grid"},fileMediatype:{type:String,default:"image"},fileExtname:{type:[Array,String],default:()=>[]},title:{type:String,default:""},listStyles:{type:Object,default:()=>({border:!0,dividline:!0,borderStyle:{}})},imageStyles:{type:Object,default:()=>({width:"auto",height:"auto"})},readonly:{type:Boolean,default:!1},returnType:{type:String,default:"array"},sizeType:{type:Array,default:()=>["original","compressed"]},sourceType:{type:Array,default:()=>["album","camera"]},provider:{type:String,default:""}},data:()=>({files:[],localValue:[]}),watch:{value:{handler(e,t){this.setValue(e,t)},immediate:!0},modelValue:{handler(e,t){this.setValue(e,t)},immediate:!0}},computed:{filesList(){let e=[];return this.files.forEach((t=>{e.push(t)})),e},showType(){return"image"===this.fileMediatype?this.mode:"list"},limitLength(){return"object"===this.returnType?1:this.limit?this.limit>=9?9:this.limit:1}},created(){Cl.config&&Cl.config.provider||(this.noSpace=!0,Cl.chooseAndUploadFile=Td),this.form=this.getForm("uniForms"),this.formItem=this.getForm("uniFormsItem"),this.form&&this.formItem&&this.formItem.name&&(this.rename=this.formItem.name,this.form.inputChildrens.push(this))},methods:{clearFiles(e){0===e||e?this.files.splice(e,1):(this.files=[],this.$nextTick((()=>{this.setEmit()}))),this.$nextTick((()=>{this.setEmit()}))},upload(){let e=[];return this.files.forEach(((t,a)=>{"ready"!==t.status&&"error"!==t.status||e.push(Object.assign({},t))})),this.uploadFiles(e)},async setValue(e,t){const a=async e=>{let t="";return t=e.fileID?e.fileID:e.url,/cloud:\/\/([\w.]+\/?)\S*/.test(t)&&(e.fileID=t,e.url=await this.getTempFileURL(t)),e.url&&(e.path=e.url),e};if("object"===this.returnType)e?await a(e):e={};else{e||(e=[]);for(let t=0;t<e.length;t++){let n=e[t];await a(n)}}this.localValue=e,this.form&&this.formItem&&!this.is_reset&&(this.is_reset=!1,this.formItem.setValue(this.localValue));let n=Object.keys(e).length>0?e:[];this.files=[].concat(n)},choose(){this.disabled||(this.files.length>=Number(this.limitLength)&&"grid"!==this.showType&&"array"===this.returnType?uni.showToast({title:`您最多选择 ${this.limitLength} 个文件`,icon:"none"}):this.chooseFiles())},chooseFiles(){const e=Dd(this.fileExtname);Cl.chooseAndUploadFile({type:this.fileMediatype,compressed:!1,sizeType:this.sizeType,sourceType:this.sourceType,extension:e.length>0?e:void 0,count:this.limitLength-this.files.length,onChooseFile:this.chooseFileCallback,onUploadProgress:e=>{this.setProgress(e,e.index)}}).then((e=>{this.setSuccessAndError(e.tempFiles)})).catch((e=>{n("log","at uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue:364","选择失败",e)}))},async chooseFileCallback(e){const t=Dd(this.fileExtname);(1===Number(this.limitLength)&&this.disablePreview&&!this.disabled||"object"===this.returnType)&&(this.files=[]);let{filePaths:a,files:n}=((e,t)=>{let a=[],n=[];return t&&0!==t.length?(e.tempFiles.forEach((e=>{const i=Bd(e.name).ext.toLowerCase();-1!==t.indexOf(i)&&(n.push(e),a.push(e.path))})),n.length!==e.tempFiles.length&&uni.showToast({title:`当前选择了${e.tempFiles.length}个文件 ，${e.tempFiles.length-n.length} 个文件格式不正确`,icon:"none",duration:5e3}),{filePaths:a,files:n}):{filePaths:a,files:n}})(e,t);t&&t.length>0||(a=e.tempFilePaths,n=e.tempFiles);let i=[];for(let o=0;o<n.length&&!(this.limitLength-this.files.length<=0);o++){n[o].uuid=Date.now();let e=await Id(n[o],this.fileMediatype);e.progress=0,e.status="ready",this.files.push(e),i.push({...e,file:n[o]})}this.$emit("select",{tempFiles:i,tempFilePaths:a}),e.tempFiles=n,this.autoUpload&&!this.noSpace||(e.tempFiles=[]),e.tempFiles.forEach(((e,t)=>{this.provider&&(e.provider=this.provider);const a=e.name.split("."),n=a.pop(),i=a.join(".").replace(/[\s\/\?<>\\:\*\|":]/g,"_");e.cloudPath=i+"_"+Date.now()+"_"+t+"."+n}))},uploadFiles(e){return e=[].concat(e),_d.call(this,e,5,(e=>{this.setProgress(e,e.index,!0)})).then((e=>(this.setSuccessAndError(e),e))).catch((e=>{n("log","at uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue:437",e)}))},async setSuccessAndError(e,t){let a=[],n=[],i=[],o=[];for(let s=0;s<e.length;s++){const t=e[s],l=t.uuid?this.files.findIndex((e=>e.uuid===t.uuid)):t.index;if(-1===l||!this.files)break;if("request:fail"===t.errMsg)this.files[l].url=t.path,this.files[l].status="error",this.files[l].errMsg=t.errMsg,n.push(this.files[l]),o.push(this.files[l].url);else{this.files[l].errMsg="",this.files[l].fileID=t.url;/cloud:\/\/([\w.]+\/?)\S*/.test(t.url)?this.files[l].url=await this.getTempFileURL(t.url):this.files[l].url=t.url,this.files[l].status="success",this.files[l].progress+=1,a.push(this.files[l]),i.push(this.files[l].fileID)}}a.length>0&&(this.setEmit(),this.$emit("success",{tempFiles:this.backObject(a),tempFilePaths:i})),n.length>0&&this.$emit("fail",{tempFiles:this.backObject(n),tempFilePaths:o})},setProgress(e,t,a){this.files.length;const n=Math.round(100*e.loaded/e.total);let i=t;a||(i=this.files.findIndex((t=>t.uuid===e.tempFile.uuid))),-1!==i&&this.files[i]&&(this.files[i].progress=n-1,this.$emit("progress",{index:i,progress:parseInt(n),tempFile:this.files[i]}))},delFile(e){this.$emit("delete",{index:e,tempFile:this.files[e],tempFilePath:this.files[e].url}),this.files.splice(e,1),this.$nextTick((()=>{this.setEmit()}))},getFileExt(e){const t=e.lastIndexOf("."),a=e.length;return{name:e.substring(0,t),ext:e.substring(t+1,a)}},setEmit(){let e=[];"object"===this.returnType?(e=this.backObject(this.files)[0],this.localValue=e||null):(e=this.backObject(this.files),this.localValue||(this.localValue=[]),this.localValue=[...e]),this.$emit("update:modelValue",this.localValue)},backObject(e){let t=[];return e.forEach((e=>{t.push({extname:e.extname,fileType:e.fileType,image:e.image,name:e.name,path:e.path,size:e.size,fileID:e.fileID,url:e.url,uuid:e.uuid,status:e.status,cloudPath:e.cloudPath})})),t},async getTempFileURL(e){e={fileList:[].concat(e)};return(await Cl.getTempFileURL(e)).fileList[0].tempFileURL||""},getForm(e="uniForms"){let t=this.$parent,a=t.$options.name;for(;a!==e;){if(t=t.$parent,!t)return!1;a=t.$options.name}return t}}},[["render",function(t,a,n,i,o,s){const l=e.resolveComponent("upload-image"),r=e.resolveComponent("upload-file");return e.openBlock(),e.createElementBlock("view",{class:"uni-file-picker"},[n.title?(e.openBlock(),e.createElementBlock("view",{key:0,class:"uni-file-picker__header"},[e.createElementVNode("text",{class:"file-title"},e.toDisplayString(n.title),1),e.createElementVNode("text",{class:"file-count"},e.toDisplayString(s.filesList.length)+"/"+e.toDisplayString(s.limitLength),1)])):e.createCommentVNode("",!0),"image"===n.fileMediatype&&"grid"===s.showType?(e.openBlock(),e.createBlock(l,{key:1,readonly:n.readonly,"image-styles":n.imageStyles,"files-list":s.filesList,limit:s.limitLength,disablePreview:n.disablePreview,delIcon:n.delIcon,onUploadFiles:s.uploadFiles,onChoose:s.choose,onDelFile:s.delFile},{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("view",{class:"is-add"},[e.createElementVNode("view",{class:"icon-add"}),e.createElementVNode("view",{class:"icon-add rotate"})])]),!0)])),_:3},8,["readonly","image-styles","files-list","limit","disablePreview","delIcon","onUploadFiles","onChoose","onDelFile"])):e.createCommentVNode("",!0),"image"!==n.fileMediatype||"grid"!==s.showType?(e.openBlock(),e.createBlock(r,{key:2,readonly:n.readonly,"list-styles":n.listStyles,"files-list":s.filesList,showType:s.showType,delIcon:n.delIcon,onUploadFiles:s.uploadFiles,onChoose:s.choose,onDelFile:s.delFile},{default:e.withCtx((()=>[e.renderSlot(t.$slots,"default",{},(()=>[e.createElementVNode("button",{type:"primary",size:"mini"},"选择文件")]),!0)])),_:3},8,["readonly","list-styles","files-list","showType","delIcon","onUploadFiles","onChoose","onDelFile"])):e.createCommentVNode("",!0)])}],["__scopeId","data-v-086f9922"]]);const Ad=t({data:()=>({sourceType:["album","camera"],imageStyles:{width:64,height:64,border:{radius:"50%"}},listStyles:{border:!0,dividline:!0,borderStyle:{width:1,color:"blue",style:"dashed",radius:2}},fileLists:[{url:"https://web-assets.dcloud.net.cn/unidoc/zh/shuijiao-small.jpg",extname:"png",name:"shuijiao.png"},{url:"https://web-assets.dcloud.net.cn/unidoc/zh/shuijiao-small.jpg",extname:"png",name:"uniapp-logo.png"},{url:"https://web-assets.dcloud.net.cn/unidoc/zh/shuijiao-small.jpg",extname:"png",name:"shuijiao.png"}]}),methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-file-picker"),Pd),d=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"文件选择上传组件，可以选择图片、视频等任意文件并上传到当前绑定的服务空间。")])),_:1}),e.createVNode(d,{title:"只选择图片",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{limit:"9",title:"最多选择9张图片","source-type":s.sourceType},null,8,["source-type"])])])),_:1}),e.createVNode(d,{title:"只选择视频",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{limit:"9","file-mediatype":"video",title:"最多选择9个视频","source-type":s.sourceType},null,8,["source-type"])])])),_:1}),e.createVNode(d,{title:"自定义图片和视频选择的来源",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{limit:"9",title:"从相册选图","source-type":["album"]})]),e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{limit:"9",title:"使用相机","file-mediatype":"video","source-type":["camera"]})])])),_:1}),e.createVNode(d,{title:"自定义图片大小",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body custom-image-box"},[e.createElementVNode("text",{class:"text"},"选择头像"),e.createVNode(c,{limit:"1","del-icon":!1,"disable-preview":"",imageStyles:s.imageStyles,"file-mediatype":"image"},{default:e.withCtx((()=>[e.createTextVNode("选择")])),_:1},8,["imageStyles"])])])),_:1}),e.createVNode(d,{title:"自定义图片大小",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"example-body"},[e.createVNode(c,{readonly:"",modelValue:s.fileLists,"onUpdate:modelValue":a[0]||(a[0]=e=>s.fileLists=e),imageStyles:s.imageStyles,"file-mediatype":"image"},null,8,["modelValue","imageStyles"]),e.createVNode(c,{readonly:"",modelValue:s.fileLists,"onUpdate:modelValue":a[1]||(a[1]=e=>s.fileLists=e),listStyles:s.listStyles,"file-mediatype":"all"},null,8,["modelValue","listStyles"])])])),_:1})])}]]);const Fd=t({data:()=>({}),onLoad(){},methods:{}},[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-card"),Vn),c=i(e.resolveDynamicComponent("uni-section"),Tr);return e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createVNode(r,{"is-shadow":!1,"is-full":""},{default:e.withCtx((()=>[e.createElementVNode("text",{class:"uni-h6"},"使用 '.uni-btn' 样式，可对内置button组件设置样式")])),_:1}),e.createVNode(c,{title:"按钮形状","sub-title":"添加类名 .uni-btn-radius 可以使用圆角按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn"},"默认按钮"),e.createElementVNode("button",{class:"uni-btn uni-btn-radius","hover-class":"hover-class"},"圆角")])])),_:1}),e.createVNode(c,{title:"按钮形状(size=mini)","sub-title":"添加类名 .uni-btn-radius 可以使用圆角按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",size:"mini"},"默认按钮"),e.createElementVNode("button",{class:"uni-btn uni-btn-radius",size:"mini"},"圆角")])])),_:1}),e.createVNode(c,{title:"普通按钮","sub-title":"指定不同的 type 属性 ,展示不同类型按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",type:"default"},"default"),e.createElementVNode("button",{class:"uni-btn",type:"primary"},"primary"),e.createElementVNode("button",{class:"uni-btn",type:"success"},"success"),e.createElementVNode("button",{class:"uni-btn",type:"warning"},"warning"),e.createElementVNode("button",{class:"uni-btn",type:"error"},"error"),e.createElementVNode("button",{class:"uni-btn",type:"info"},"info")])])),_:1}),e.createVNode(c,{title:"普通按钮(size=mini)","sub-title":"指定不同的 type 属性 ,展示不同类型按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",size:"mini"},"default"),e.createElementVNode("button",{class:"uni-btn",type:"primary",size:"mini"},"primary"),e.createElementVNode("button",{class:"uni-btn",type:"success",size:"mini"},"success"),e.createElementVNode("button",{class:"uni-btn",type:"warning",size:"mini"},"warning"),e.createElementVNode("button",{class:"uni-btn",type:"error",size:"mini"},"error"),e.createElementVNode("button",{class:"uni-btn",type:"info",size:"mini"},"info")])])),_:1}),e.createVNode(c,{title:"镂空按钮","sub-title":"添加类名 .uni-btn-plain 使用镂空按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",plain:""},"default"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"primary"},"primary"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"success"},"success"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"warning"},"warning"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"error"},"error"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"info"},"info")])])),_:1}),e.createVNode(c,{title:"镂空按钮(size=mini)","sub-title":"添加类名 .uni-btn-plain 使用镂空按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",plain:"",size:"mini"},"default"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"primary",size:"mini"},"primary"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"success",size:"mini"},"success"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"warning",size:"mini"},"warning"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"error",size:"mini"},"error"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"info",size:"mini"},"info")])])),_:1}),e.createVNode(c,{title:"禁用","sub-title":"使用 disabled 属性 ,展示禁用按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",type:"primary",disabled:""},"primary"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"primary",disabled:""},"primary"),e.createElementVNode("button",{class:"uni-btn uni-btn-radius",disabled:""},"圆角")])])),_:1}),e.createVNode(c,{title:"禁用(size=mini)","sub-title":"使用 disabled 属性 ,展示禁用按钮",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",type:"primary",disabled:"",size:"mini"},"primary"),e.createElementVNode("button",{class:"uni-btn",plain:"",type:"primary",disabled:"",size:"mini"},"primary"),e.createElementVNode("button",{class:"uni-btn uni-btn-radius",disabled:"",size:"mini"},"圆角")])])),_:1}),e.createVNode(c,{title:"大小","sub-title":"添加类名 .uni-btn-small .uni-btn-mini 展示按钮的不同大小",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",type:"primary"},"default"),e.createElementVNode("button",{class:"uni-btn uni-btn-small",type:"primary"},"samll"),e.createElementVNode("button",{class:"uni-btn uni-btn-mini uni-btn-radius",type:"primary"},"mini")])])),_:1}),e.createVNode(c,{title:"大小(sizi=mini)","sub-title":"添加类名 .uni-btn-small .uni-btn-mini 展示按钮的不同大小",type:"line"},{default:e.withCtx((()=>[e.createElementVNode("view",{class:"uni-ma-5 uni-pb-5"},[e.createElementVNode("button",{class:"uni-btn",type:"primary",size:"mini"},"default"),e.createElementVNode("button",{class:"uni-btn uni-btn-small",type:"primary",size:"mini"},"samll"),e.createElementVNode("button",{class:"uni-btn uni-btn-mini uni-btn-radius",type:"primary",size:"mini"},"mini")])])),_:1})])}]]);const Ld=t({data:()=>({title:"nav-default",hasSetText:!1,hasSetBg:!1}),methods:{setText(){this.hasSetText=!this.hasSetText,uni.setNavigationBarTitle({title:this.hasSetText?"Hello uni-app":"默认导航栏"})},setBg(){this.hasSetBg=!this.hasSetBg,uni.setNavigationBarColor({frontColor:this.hasSetBg?"#ffffff":"#000000",backgroundColor:this.hasSetBg?"#007AFF":"#F8F8F8"})}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"page"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-helllo-text"}," 本页标题栏是uni-app的默认配置，开发者可在pages.json里配置文字内容及标题颜色，也可通过api接口将其改变。 "),e.createElementVNode("view",{class:"uni-btn-v"},[e.createElementVNode("button",{type:"default",onClick:n[0]||(n[0]=(...e)=>r.setText&&r.setText(...e))},"改变标题栏文字"),e.createElementVNode("button",{type:"primary",onClick:n[1]||(n[1]=(...e)=>r.setBg&&r.setBg(...e))},"改变标题栏颜色")])])])}]]),Md={data:()=>({msg:""}),created(){uni.$on("cc",this.recive)},beforeDestroy(){uni.$off("cc",this.recive)},methods:{recive(e){this.msg=e.msg}}};const Rd=t({components:{reciver:t(Md,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{class:"reciver"},e.toDisplayString(""===o.msg?"等待发送":"收到消息：")+e.toDisplayString(o.msg),1)])}],["__scopeId","data-v-d6b0a0ea"]]),sender:t({methods:{send(){let e=parseInt(1e4*Math.random());uni.$emit("cc",{msg:"From uni.$emit -> "+e})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"sender-container"},[e.createElementVNode("button",{type:"primary",onClick:a[0]||(a[0]=(...e)=>s.send&&s.send(...e))},"点击发送消息")])}],["__scopeId","data-v-102ec174"]]),senderBus:t({methods:{send(){let e=parseInt(1e4*Math.random());uni.$emit("cc",{msg:"From event bus -> "+e})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"sender-container"},[e.createElementVNode("button",{type:"primary",onClick:a[0]||(a[0]=(...e)=>s.send&&s.send(...e))},"自定义EventBus")])}],["__scopeId","data-v-61be45df"]])},data:()=>({}),methods:{}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=e.resolveComponent("reciver"),u=e.resolveComponent("sender"),h=e.resolveComponent("sender-bus");return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"组件通讯示例"}),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-btn-v"},[e.createVNode(d),e.createVNode(u),e.createVNode(h)])])])}]]),Od={data:()=>({showSwiper:!1,imgUrls:["../../../static/shuijiao.jpg","https://web-assets.dcloud.net.cn/unidoc/zh/muwu.jpg","https://web-assets.dcloud.net.cn/unidoc/zh/cbd.jpg"],items:[{value:"img",name:"静态图",checked:!0},{value:"swiper",name:"轮播图",checked:!1}]}),methods:{radioChange(e){this.showSwiper="swiper"===e.detail.value}}};const $d=t(Od,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"page"},[o.showSwiper?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"img-view"},[e.createElementVNode("image",{src:o.imgUrls[0]},null,8,["src"])])),o.showSwiper?(e.openBlock(),e.createElementBlock("swiper",{key:1,"indicator-dots":"true"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.imgUrls,((t,a)=>(e.openBlock(),e.createElementBlock("swiper-item",{key:a},[e.createElementVNode("image",{src:t},null,8,["src"])])))),128))])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createElementVNode("view",null,"在App端默认为标题栏透明，当用户向下滚动时，标题栏逐渐由透明转变为不透明；当用户再次向上滚动时，标题栏又从不透明变为透明状态。"),e.createElementVNode("view",null,"在微信小程序端，导航栏始终为不透明样式。")]),e.createElementVNode("view",{class:"uni-title uni-common-mt"},"图片类型")]),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("radio-group",{onChange:a[0]||(a[0]=(...e)=>s.radioChange&&s.radioChange(...e))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.items,((t,a)=>(e.openBlock(),e.createElementBlock("label",{class:"uni-list-cell uni-list-cell-pd",key:a},[e.createElementVNode("view",null,e.toDisplayString(t.name),1),e.createElementVNode("view",null,[e.createElementVNode("radio",{value:t.value,checked:t.checked},null,8,["value","checked"])])])))),128))],32)]),e.createElementVNode("view",{style:{height:"1000rpx"}})])}]]),zd={data:()=>({title:"nav-button"}),onNavigationBarButtonTap(e){uni.showToast({title:0===e.index?"你点了分享按钮":"你点了收藏按钮",icon:"none"})}};const Ud=t(zd,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createVNode(d,{size:"16",type:"info"}),e.createTextVNode("说明 : ")]),e.createElementVNode("view",{class:"uni-helllo-text"},[e.createElementVNode("view",null,"在App端可在pages.json里配置buttons，暂不支持动态改变buttons的样式，使用onNavigationBarButtonTap可监听buttons的点击事件。"),e.createElementVNode("view",null,"在小程序端，不支持配置buttons，故按钮不见了。")])])])}]]);const jd=t({data:()=>({title:"nav-image"})},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createVNode(d,{size:"16",type:"info"}),e.createTextVNode("说明 : ")]),e.createElementVNode("view",{class:"uni-helllo-text"},[e.createElementVNode("view",null,"在App端可在pages.json里通过 style -> titleImage 配置，支付宝小程序只支持https地址的图片，暂不支持动态改变；常用于App首页顶部导航显示产品Logo。"),e.createElementVNode("view",null,"在支付宝小程序里请使用真机调试查看效果。")])])])}]]),qd={data:()=>({title:"nav-city-dropdown",pickerValueArray:[{label:"北京市",value:11e4},{label:"天津市",value:12e4},{label:"广州市",value:440100},{label:"深圳市",value:440300}]}),onReady(){this.setStyle(0,"北京市")},methods:{setStyle(e,t){let a=getCurrentPages(),n=a[a.length-1];t.length>3&&(t=t.substr(0,3)+"...");let i=n.$getAppWebview(),o=i.getStyle().titleNView;o.buttons[0].text=t,i.setStyle({titleNView:o})}},onNavigationBarButtonTap(e){let t=this;0===e.index&&uni.showActionSheet({itemList:t.pickerValueArray.map((e=>e.label)),success:function(e){let a=e.tapIndex;t.setStyle(0,t.pickerValueArray[a].label),n("log","at pages/template/nav-city-dropdown/nav-city-dropdown.vue:93",JSON.stringify(t.pickerValueArray[a]))},fail:function(e){n("log","at pages/template/nav-city-dropdown/nav-city-dropdown.vue:96",e.errMsg)}})}};const Hd=t(qd,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",{class:"mpvue-picker"},[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createVNode(d,{size:"16",type:"info"}),e.createTextVNode(" 说明 : ")]),e.createElementVNode("view",{class:"uni-helllo-text"},[e.createElementVNode("text",null," 在App端可在pages.json里配置buttons，暂不支持动态改变buttons的样式，使用onNavigationBarButtonTap可监听城市选择按钮的点击事件。 ")])])])}]]),Wd={data:()=>({title:"nav-dot"}),onReady(){this.setStyle(0,!0),this.setStyle(1,!0,"9")},methods:{setStyle(e,t,a){let n=getCurrentPages(),i=n[n.length-1].$getAppWebview();t?0===e?i.showTitleNViewButtonRedDot({index:e,text:a}):i.setTitleNViewButtonBadge({index:e,text:a}):0===e?i.hideTitleNViewButtonRedDot({index:e}):i.removeTitleNViewButtonBadge({index:e})}},onNavigationBarButtonTap(e){uni.showToast({title:0===e.index?"你点了消息按钮":"你点了关注按钮",icon:"none"}),this.setStyle(e.index,!1)}};const Jd=t(Wd,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a),d=i(e.resolveDynamicComponent("uni-icons"),g);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createVNode(d,{size:"16",type:"info"}),e.createTextVNode("说明 : ")]),e.createElementVNode("view",{class:"uni-helllo-text"},[e.createElementVNode("view",null,"在App端可在pages.json里配置buttons，暂不支持动态改变buttons的样式，使用onNavigationBarButtonTap可监听红点按钮的点击事件。")])])])}]]);const Gd=t({data:()=>({showSwiper:!1,imgUrls:["https://web-assets.dcloud.net.cn/unidoc/zh/muwu.jpg","https://web-assets.dcloud.net.cn/unidoc/zh/cbd.jpg"]}),onNavigationBarSearchInputClicked(e){n("log","at pages/template/nav-search-input/nav-search-input.vue:42","事件执行了"),uni.navigateTo({url:"/pages/template/nav-search-input/detail/detail"})},onNavigationBarButtonTap(){uni.showModal({title:"提示",content:"用户点击了功能按钮，这里仅做展示。",success:e=>{e.confirm&&n("log","at pages/template/nav-search-input/nav-search-input.vue:56","用户点击了确定")}})}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"page"},[e.createElementVNode("swiper",{"indicator-dots":"true"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.imgUrls,((t,a)=>(e.openBlock(),e.createElementBlock("swiper-item",{key:a},[e.createElementVNode("image",{src:t},null,8,["src"])])))),128))]),e.createElementVNode("view",{class:"uni-padding-wrap uni-common-mt"},[e.createElementVNode("view",{class:"uni-title"},[e.createElementVNode("view",null,"本示例为导航栏带搜索框完整功能演示，主要演示有："),e.createElementVNode("view",null,"1. 导航栏为 transparent 模式，向上滑动页面，导航栏会从透明变为实色。"),e.createElementVNode("view",null,"2. 点击搜索框跳转到搜索页面。"),e.createElementVNode("view",null,"3. 点击导航栏右侧按钮实现关联操作。"),e.createElementVNode("view",null,"4. 搜索页面为提示词搜索，输入内容实时显示关联词。"),e.createElementVNode("view",null,"5. 搜索结果根据搜索内容高亮显示文字。"),e.createElementVNode("view",null,"6. 点击搜索列表或者软键盘搜索按钮，会将结果保存到搜索历史列表。"),e.createElementVNode("view",null,"7. 点击删除图标，清空历史搜索列表。"),e.createElementVNode("view",null,"Tips "),e.createElementVNode("view",null,"1. 本示例目前仅支持 App 端"),e.createElementVNode("view",null,"2. 所有示例均为演示使用，具体逻辑需要自己实现。")])]),e.createElementVNode("view",{style:{height:"1000rpx"}})])}]]);function Kd(e){this.key=e.key,this.requestConfig={key:e.key,s:"rsx",platform:"WXJS",appname:e.key,sdkversion:"1.2.0",logversion:"2.0"}}Kd.prototype.getWxLocation=function(e,t){wx.getLocation({type:"gcj02",success:function(e){var a=e.longitude+","+e.latitude;wx.setStorage({key:"userLocation",data:a}),t(a)},fail:function(a){wx.getStorage({key:"userLocation",success:function(e){e.data&&t(e.data)}}),e.fail({errCode:"0",errMsg:a.errMsg||""})}})},Kd.prototype.getRegeo=function(e){function t(t){var n=a.requestConfig;wx.request({url:"https://restapi.amap.com/v3/geocode/regeo",data:{key:a.key,location:t,extensions:"all",s:n.s,platform:n.platform,appname:a.key,sdkversion:n.sdkversion,logversion:n.logversion},method:"GET",header:{"content-type":"application/json"},success:function(a){var n,i,o,s,l,r,c,d,u;a.data.status&&"1"==a.data.status?(i=(n=a.data.regeocode).addressComponent,o=[],s="",n&&n.roads[0]&&n.roads[0].name&&(s=n.roads[0].name+"附近"),l=t.split(",")[0],r=t.split(",")[1],n.pois&&n.pois[0]&&(s=n.pois[0].name+"附近",(c=n.pois[0].location)&&(l=parseFloat(c.split(",")[0]),r=parseFloat(c.split(",")[1]))),i.provice&&o.push(i.provice),i.city&&o.push(i.city),i.district&&o.push(i.district),i.streetNumber&&i.streetNumber.street&&i.streetNumber.number?(o.push(i.streetNumber.street),o.push(i.streetNumber.number)):(d="",n&&n.roads[0]&&n.roads[0].name&&(d=n.roads[0].name),o.push(d)),o=o.join(""),u=[{iconPath:e.iconPath,width:e.iconWidth,height:e.iconHeight,name:o,desc:s,longitude:l,latitude:r,id:0,regeocodeData:n}],e.success(u)):e.fail({errCode:a.data.infocode,errMsg:a.data.info})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})}var a=this;e.location?t(e.location):a.getWxLocation(e,(function(e){t(e)}))},Kd.prototype.getWeather=function(e){function t(t){var i="base";e.type&&"forecast"==e.type&&(i="all"),wx.request({url:"https://restapi.amap.com/v3/weather/weatherInfo",data:{key:a.key,city:t,extensions:i,s:n.s,platform:n.platform,appname:a.key,sdkversion:n.sdkversion,logversion:n.logversion},method:"GET",header:{"content-type":"application/json"},success:function(t){var a,n,i;t.data.status&&"1"==t.data.status?t.data.lives?(a=t.data.lives)&&a.length>0&&(a=a[0],(n={city:{text:"城市",data:(i=a).city},weather:{text:"天气",data:i.weather},temperature:{text:"温度",data:i.temperature},winddirection:{text:"风向",data:i.winddirection+"风"},windpower:{text:"风力",data:i.windpower+"级"},humidity:{text:"湿度",data:i.humidity+"%"}}).liveData=a,e.success(n)):t.data.forecasts&&t.data.forecasts[0]&&e.success({forecast:t.data.forecasts[0]}):e.fail({errCode:t.data.infocode,errMsg:t.data.info})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})}var a=this,n=a.requestConfig;e.city?t(e.city):a.getWxLocation(e,(function(i){var o;o=i,wx.request({url:"https://restapi.amap.com/v3/geocode/regeo",data:{key:a.key,location:o,extensions:"all",s:n.s,platform:n.platform,appname:a.key,sdkversion:n.sdkversion,logversion:n.logversion},method:"GET",header:{"content-type":"application/json"},success:function(a){var n,i;a.data.status&&"1"==a.data.status?((i=a.data.regeocode).addressComponent?n=i.addressComponent.adcode:i.aois&&i.aois.length>0&&(n=i.aois[0].adcode),t(n)):e.fail({errCode:a.data.infocode,errMsg:a.data.info})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})}))},Kd.prototype.getPoiAround=function(e){function t(t){var i={key:a.key,location:t,s:n.s,platform:n.platform,appname:a.key,sdkversion:n.sdkversion,logversion:n.logversion};e.querytypes&&(i.types=e.querytypes),e.querykeywords&&(i.keywords=e.querykeywords),wx.request({url:"https://restapi.amap.com/v3/place/around",data:i,method:"GET",header:{"content-type":"application/json"},success:function(t){var a,n,i,o;if(t.data.status&&"1"==t.data.status){if((t=t.data)&&t.pois){for(a=[],n=0;n<t.pois.length;n++)i=0==n?e.iconPathSelected:e.iconPath,a.push({latitude:parseFloat(t.pois[n].location.split(",")[1]),longitude:parseFloat(t.pois[n].location.split(",")[0]),iconPath:i,width:22,height:32,id:n,name:t.pois[n].name,address:t.pois[n].address});o={markers:a,poisData:t.pois},e.success(o)}}else e.fail({errCode:t.data.infocode,errMsg:t.data.info})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})}var a=this,n=a.requestConfig;e.location?t(e.location):a.getWxLocation(e,(function(e){t(e)}))},Kd.prototype.getStaticmap=function(e){function t(t){i.push("location="+t),e.zoom&&i.push("zoom="+e.zoom),e.size&&i.push("size="+e.size),e.scale&&i.push("scale="+e.scale),e.markers&&i.push("markers="+e.markers),e.labels&&i.push("labels="+e.labels),e.paths&&i.push("paths="+e.paths),e.traffic&&i.push("traffic="+e.traffic);var a=o+i.join("&");e.success({url:a})}var a,n=this,i=[],o="https://restapi.amap.com/v3/staticmap?";i.push("key="+n.key),a=n.requestConfig,i.push("s="+a.s),i.push("platform="+a.platform),i.push("appname="+a.appname),i.push("sdkversion="+a.sdkversion),i.push("logversion="+a.logversion),e.location?t(e.location):n.getWxLocation(e,(function(e){t(e)}))},Kd.prototype.getInputtips=function(e){var t=this,a=t.requestConfig,n={key:t.key,s:a.s,platform:a.platform,appname:t.key,sdkversion:a.sdkversion,logversion:a.logversion};e.location&&(n.location=e.location),e.keywords&&(n.keywords=e.keywords),e.type&&(n.type=e.type),e.city&&(n.city=e.city),e.citylimit&&(n.citylimit=e.citylimit),wx.request({url:"https://restapi.amap.com/v3/assistant/inputtips",data:n,method:"GET",header:{"content-type":"application/json"},success:function(t){t&&t.data&&t.data.tips&&e.success({tips:t.data.tips})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})},Kd.prototype.getDrivingRoute=function(e){var t=this,a=t.requestConfig,n={key:t.key,s:a.s,platform:a.platform,appname:t.key,sdkversion:a.sdkversion,logversion:a.logversion};e.origin&&(n.origin=e.origin),e.destination&&(n.destination=e.destination),e.strategy&&(n.strategy=e.strategy),e.waypoints&&(n.waypoints=e.waypoints),e.avoidpolygons&&(n.avoidpolygons=e.avoidpolygons),e.avoidroad&&(n.avoidroad=e.avoidroad),wx.request({url:"https://restapi.amap.com/v3/direction/driving",data:n,method:"GET",header:{"content-type":"application/json"},success:function(t){t&&t.data&&t.data.route&&e.success({paths:t.data.route.paths,taxi_cost:t.data.route.taxi_cost||""})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})},Kd.prototype.getWalkingRoute=function(e){var t=this,a=t.requestConfig,n={key:t.key,s:a.s,platform:a.platform,appname:t.key,sdkversion:a.sdkversion,logversion:a.logversion};e.origin&&(n.origin=e.origin),e.destination&&(n.destination=e.destination),wx.request({url:"https://restapi.amap.com/v3/direction/walking",data:n,method:"GET",header:{"content-type":"application/json"},success:function(t){t&&t.data&&t.data.route&&e.success({paths:t.data.route.paths})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})},Kd.prototype.getTransitRoute=function(e){var t=this,a=t.requestConfig,n={key:t.key,s:a.s,platform:a.platform,appname:t.key,sdkversion:a.sdkversion,logversion:a.logversion};e.origin&&(n.origin=e.origin),e.destination&&(n.destination=e.destination),e.strategy&&(n.strategy=e.strategy),e.city&&(n.city=e.city),e.cityd&&(n.cityd=e.cityd),wx.request({url:"https://restapi.amap.com/v3/direction/transit/integrated",data:n,method:"GET",header:{"content-type":"application/json"},success:function(t){if(t&&t.data&&t.data.route){var a=t.data.route;e.success({distance:a.distance||"",taxi_cost:a.taxi_cost||"",transits:a.transits})}},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})},Kd.prototype.getRidingRoute=function(e){var t=this,a=t.requestConfig,n={key:t.key,s:a.s,platform:a.platform,appname:t.key,sdkversion:a.sdkversion,logversion:a.logversion};e.origin&&(n.origin=e.origin),e.destination&&(n.destination=e.destination),wx.request({url:"https://restapi.amap.com/v4/direction/bicycling",data:n,method:"GET",header:{"content-type":"application/json"},success:function(t){t&&t.data&&t.data.data&&e.success({paths:t.data.data.paths})},fail:function(t){e.fail({errCode:"0",errMsg:t.errMsg||""})}})};const Qd={AMapWX:Kd},Yd={"1号线":"#C43B33","2号线":"#016299","4号线/大兴线":"#008E9C","5号线":"#A42380","6号线":"#D09900","7号线":"#F2C172","8号线":"#009D6A","9号线":"#8FC41E","10号线":"#009DBE","13号线":"#F9E701","14号线东段":"#D4A7A2","14号线西段":"#D4A7A2","15号线":"#5D2D69","八通线":"#C33A32","昌平线":"#DE82B1","亦庄线":"#E40177","房山线":"#E66021","机场线":"#A29BBC"},Xd=[{id:"150500",icon:"icon-ditie"},{id:"150700",icon:"icon-gongjiao"},{id:"190700",icon:"icon-gonglu"}],Zd={key:"b526b09b86cd2996e7732be8ab8c4430",mapInit(){return new Qd.AMapWX({key:this.key})},typecode:Xd,lineColor:e=>Yd[e]?Yd[e]:"#ccc",serachNmme(e,t){let a=new RegExp(e);return`<div style="font-size: 14px;color: #333;line-height: 1.5;">\n\t\t    ${t.replace(a,"<span style='color:#66ccff;'>"+e+"</span>")}\n\t\t    </div>`.trim()},addressToLine(e,t){let a=e.split(";"),n="";return a.forEach((e=>{let a="#cccccc";t===Xd[0].id?a=this.lineColor(e):t===Xd[1].id&&(a="#4075cb"),n+=`<div style='${"margin:5px 0;margin-right:5px;padding:0 5px;background:"+a+";font-size:12px;color:#fff;border-radius:3px;"}'>${e}</div>`})),`<div style="display:flex;flex-wrap: wrap;">${n}</div>`},dataHandle:(e,t)=>(e.nameNodes=t?Zd.serachNmme(t,e.name):`<div style="font-size: 14px;color: #333;line-height: 1.5;">${e.name}</div>`,e.typecode===Zd.typecode[0].id||e.typecode===Zd.typecode[1].id?(e.addressNodes=Zd.addressToLine(e.address,e.typecode),e.typecode===Zd.typecode[0].id?e.icon=Zd.typecode[0].icon:e.typecode===Zd.typecode[1].id&&(e.icon=Zd.typecode[1].icon)):(e.addressNodes=`<span>${e.district}${e.address.length>0?"·"+e.address:""}</span>`.trim(),e.icon="icon-weizhi"),e.location&&0===e.location.length&&(e.icon="icon-sousuo"),e),setHistory(e){let t=uni.getStorageSync("search:history");t||(t=[]);let a={};a="string"==typeof e?{adcode:[],address:[],city:[],district:[],id:[],location:[],name:e,typecode:[]}:e;for(var n=0;n<t.length;n++)if(t[n].name===a.name){t.splice(n,1);break}t.unshift(Zd.dataHandle(a)),uni.setStorage({key:"search:history",data:t,success:function(){}})},getHistory(){},removeHistory:()=>(uni.removeStorage({key:"search:history",success:function(e){n("log","at components/amap-wx/js/util.js:173","success")}}),[])},eu={data:()=>({historyList:[],isHistory:!0,list:[],flng:!0,timer:null}),onLoad(){this.amapPlugin=Zd.mapInit(),this.historyList=uni.getStorageSync("search:history")},methods:{listTap(e){e=JSON.parse(JSON.stringify(e)),this.history||(this.isHistory=!0,Zd.setHistory(e),uni.navigateBack())},clearSearch(){uni.showModal({title:"提示",content:"是否清理全部搜索历史？该操作不可逆。",success:e=>{e.confirm&&(this.historyList=Zd.removeHistory())}})},getInputtips(e){let t=this;this.amapPlugin.getInputtips({keywords:e,city:"北京",success:a=>{let n=a.tips;n.map((t=>Zd.dataHandle(t,e))),t.historyList=n},fail:e=>{n("log","at pages/template/nav-search-input/detail/detail.vue:103",e)}})}},onNavigationBarSearchInputChanged(e){let t=e.text;if(!t)return this.isHistory=!0,this.historyList=[],void(this.historyList=uni.getStorageSync("search:history"));this.isHistory=!1,this.getInputtips(t)},onNavigationBarSearchInputConfirmed(e){let t=e.text;if(!t)return this.isHistory=!0,this.historyList=[],this.historyList=uni.getStorageSync("search:history"),void uni.showModal({title:"提示",content:"请输入内容。",success:e=>{e.confirm}});uni.showModal({title:"提示",content:`您输入的内容为"${t}",如果点击确定,将记录到历史搜索,并返回.如果取消不做操作`,success:e=>{e.confirm&&(Zd.setHistory(t),uni.navigateBack())}})},onNavigationBarButtonTap(){uni.showModal({title:"提示",content:"点击确定，修改输入框的内容为abc",success:e=>{if(e.confirm){this.$mp.page.$getAppWebview().setTitleNViewSearchInputText("abc")}}})}};const tu=t(eu,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"wrapper"},[o.isHistory?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-box"},[o.historyList.length>0?(e.openBlock(),e.createElementBlock("view",{key:0},[e.createElementVNode("view",{class:"history-title"},[e.createElementVNode("text",null,"搜索历史"),e.createElementVNode("text",{class:"uni-icon uni-icon-trash",onClick:a[0]||(a[0]=(...e)=>s.clearSearch&&s.clearSearch(...e))})]),e.createElementVNode("view",{class:"history-content"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.historyList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"history-item",key:a},e.toDisplayString(t.name),1)))),128))])])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"no-data"},"您还没有历史记录"))])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"history-box"},[o.historyList.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-list-box"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.historyList,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"history-list-item",key:a,onClick:e=>s.listTap(t)},[e.createElementVNode("rich-text",{nodes:t.nameNodes},null,8,["nodes"])],8,["onClick"])))),128))])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"no-data"},"没有搜索到相关内容"))]))])}]]),au={data:()=>({banner:{},listData:[],last_id:"",reload:!1,status:"more",adpid:"",contentText:{contentdown:"上拉加载更多",contentrefresh:"加载中",contentnomore:"没有更多"}}),onLoad(){this.adpid=this.$adpid,this.getBanner(),this.getList()},onPullDownRefresh(){this.reload=!0,this.last_id="",this.getBanner(),this.getList()},onReachBottom(){this.status="more",this.getList()},methods:{getBanner(){uni.request({url:"https://unidemo.dcloud.net.cn/api/banner/36kr",data:{column:"id,post_id,title,author_name,cover,published_at"},success:e=>{uni.stopPullDownRefresh(),200==e.statusCode&&(this.banner=e.data)},fail:(e,t)=>{n("log","at pages/template/list2detail-list/list2detail-list.vue:81","fail"+JSON.stringify(e))}})},getList(){var e={column:"id,post_id,title,author_name,cover,published_at"};this.last_id&&(this.status="loading",e.minId=this.last_id,e.time=(new Date).getTime()+"",e.pageSize=10),uni.request({url:"https://unidemo.dcloud.net.cn/api/news",data:e,success:e=>{if(200==e.statusCode){let t=this.setTime(e.data);this.listData=this.reload?t:this.listData.concat(t),this.last_id=t[t.length-1].id,this.reload=!1}},fail:(e,t)=>{n("log","at pages/template/list2detail-list/list2detail-list.vue:108","fail"+JSON.stringify(e))}})},goDetail:function(e){let t={author_name:e.author_name,cover:e.cover,id:e.id,post_id:e.post_id,published_at:e.published_at,title:e.title};uni.navigateTo({url:"../list2detail-detail/list2detail-detail?detailDate="+encodeURIComponent(JSON.stringify(t))})},setTime:function(e){var t=[];return e.forEach((e=>{t.push({author_name:e.author_name,cover:e.cover,id:e.id,post_id:e.post_id,published_at:Na.format(e.published_at),title:e.title})})),t},aderror(e){n("log","at pages/template/list2detail-list/list2detail-list.vue:143","aderror: "+JSON.stringify(e.detail))}}};const nu=t(au,[["render",function(t,a,n,o,s,l){const r=i(e.resolveDynamicComponent("uni-load-more"),Ul);return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{class:"banner",onClick:a[0]||(a[0]=e=>l.goDetail(s.banner))},[e.createElementVNode("image",{class:"banner-img",src:s.banner.cover},null,8,["src"]),e.createElementVNode("view",{class:"banner-title"},e.toDisplayString(s.banner.title),1)]),e.createElementVNode("view",{class:"uni-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.listData,((t,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:n},[e.createElementVNode("view",{class:"uni-list-cell","hover-class":"uni-list-cell-hover",onClick:e=>l.goDetail(t)},[e.createElementVNode("view",{class:"uni-media-list"},[e.createElementVNode("image",{class:"uni-media-list-logo",src:t.cover},null,8,["src"]),e.createElementVNode("view",{class:"uni-media-list-body"},[e.createElementVNode("view",{class:"uni-media-list-text-top"},e.toDisplayString(t.title),1),e.createElementVNode("view",{class:"uni-media-list-text-bottom"},[e.createElementVNode("text",null,e.toDisplayString(t.author_name),1),e.createElementVNode("text",null,e.toDisplayString(t.published_at),1)])])])],8,["onClick"]),n>0&&(n+1)%10==0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"ad-view"},[e.createElementVNode("ad",{adpid:s.adpid,onError:a[1]||(a[1]=(...e)=>l.aderror&&l.aderror(...e))},null,40,["adpid"])])):e.createCommentVNode("",!0)],64)))),128))]),e.createVNode(r,{status:s.status,"icon-size":16,"content-text":s.contentText},null,8,["status","content-text"])])}]]);var iu=/^<([-A-Za-z0-9_]+)((?:\s+[a-zA-Z_:][-a-zA-Z0-9_:.]*(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)>/,ou=/^<\/([-A-Za-z0-9_]+)[^>]*>/,su=/([a-zA-Z_:][-a-zA-Z0-9_:.]*)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|([^>\s]+)))?/g,lu=pu("area,base,basefont,br,col,frame,hr,img,input,link,meta,param,embed,command,keygen,source,track,wbr"),ru=pu("a,address,article,applet,aside,audio,blockquote,button,canvas,center,dd,del,dir,div,dl,dt,fieldset,figcaption,figure,footer,form,frameset,h1,h2,h3,h4,h5,h6,header,hgroup,hr,iframe,isindex,li,map,menu,noframes,noscript,object,ol,output,p,pre,section,script,table,tbody,td,tfoot,th,thead,tr,ul,video"),cu=pu("abbr,acronym,applet,b,basefont,bdo,big,br,button,cite,code,del,dfn,em,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,select,small,span,strike,strong,sub,sup,textarea,tt,u,var"),du=pu("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr"),uu=pu("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected"),hu=pu("script,style");function pu(e){for(var t={},a=e.split(","),n=0;n<a.length;n++)t[a[n]]=!0;return t}function mu(e){e=function(e){return e.replace(/<\?xml.*\?>\n/,"").replace(/<!doctype.*>\n/,"").replace(/<!DOCTYPE.*>\n/,"")}(e);var t=[],a={node:"root",children:[]};return function(e,t){var a,n,i,o=[],s=e;for(o.last=function(){return this[this.length-1]};e;){if(n=!0,o.last()&&hu[o.last()])e=e.replace(new RegExp("([\\s\\S]*?)</"+o.last()+"[^>]*>"),(function(e,a){return a=a.replace(/<!--([\s\S]*?)-->|<!\[CDATA\[([\s\S]*?)]]>/g,"$1$2"),t.chars&&t.chars(a),""})),c("",o.last());else if(0==e.indexOf("\x3c!--")?(a=e.indexOf("--\x3e"))>=0&&(t.comment&&t.comment(e.substring(4,a)),e=e.substring(a+3),n=!1):0==e.indexOf("</")?(i=e.match(ou))&&(e=e.substring(i[0].length),i[0].replace(ou,c),n=!1):0==e.indexOf("<")&&(i=e.match(iu))&&(e=e.substring(i[0].length),i[0].replace(iu,r),n=!1),n){var l=(a=e.indexOf("<"))<0?e:e.substring(0,a);e=a<0?"":e.substring(a),t.chars&&t.chars(l)}if(e==s)throw"Parse Error: "+e;s=e}function r(e,a,n,i){if(a=a.toLowerCase(),ru[a])for(;o.last()&&cu[o.last()];)c("",o.last());if(du[a]&&o.last()==a&&c("",a),(i=lu[a]||!!i)||o.push(a),t.start){var s=[];n.replace(su,(function(e,t){var a=arguments[2]?arguments[2]:arguments[3]?arguments[3]:arguments[4]?arguments[4]:uu[t]?t:"";s.push({name:t,value:a,escaped:a.replace(/(^|[^\\])"/g,'$1\\"')})})),t.start&&t.start(a,s,i)}}function c(e,a){if(a)for(n=o.length-1;n>=0&&o[n]!=a;n--);else var n=0;if(n>=0){for(var i=o.length-1;i>=n;i--)t.end&&t.end(o[i]);o.length=n}}c()}(e,{start:function(e,n,i){var o={name:e};if(0!==n.length&&(o.attrs=function(e){return e.reduce((function(e,t){var a=t.value,n=t.name;return e[n]?e[n]=e[n]+" "+a:e[n]=a,e}),{})}(n)),i){var s=t[0]||a;s.children||(s.children=[]),s.children.push(o)}else t.unshift(o)},end:function(e){var i=t.shift();if(i.name!==e&&n("error","at common/html-parser.js:303","invalid state: mismatch end tag"),0===t.length)a.children.push(i);else{var o=t[0];o.children||(o.children=[]),o.children.push(i)}},chars:function(e){var n={type:"text",text:e};if(0===t.length)a.children.push(n);else{var i=t[0];i.children||(i.children=[]),i.children.push(n)}},comment:function(e){var a={node:"comment",text:e},n=t[0];n.children||(n.children=[]),n.children.push(a)}}),a.children}const gu="/pages/template/list2detail-detail/list2detail-detail";const fu=t({data:()=>({title:"",banner:{},htmlNodes:[],visible:!0}),onLoad(e){const t=e.detailDate||e.payload;try{this.banner=JSON.parse(decodeURIComponent(t))}catch(a){this.banner=JSON.parse(t)}uni.setNavigationBarTitle({title:this.banner.title}),this.getDetail()},onShareAppMessage(){return{title:this.banner.title,path:gu+"?detailDate="+JSON.stringify(this.banner)}},onNavigationBarButtonTap(e){0===e.index&&uni.getProvider({service:"share",success:e=>{if(e.provider&&e.provider.length&&~e.provider.indexOf("weixin")){const t=function(e){let t=[];for(let a=0,n=e.length;a<n;a++)"weixin"===e[a]&&(t.push({text:"分享到微信好友",id:"weixin",sort:0}),t.push({text:"分享到微信朋友圈",id:"weixin",sort:1}));return t.sort((function(e,t){return e.sort-t.sort})),t}(e.provider);uni.showActionSheet({itemList:t.map((e=>e.text)),success:e=>{const t=e.tapIndex;uni.share({provider:"weixin",type:0,title:this.banner.title,scene:0===t?"WXSceneSession":"WXSceneTimeline",href:"https://uniapp.dcloud.io/h5"+gu+"?detailDate="+JSON.stringify(this.banner),imageUrl:"https://web-assets.dcloud.net.cn/unidoc/zh/share-logo@3.png"})}})}else uni.showToast({title:"未检测到可用的微信分享服务"})},fail:e=>{uni.showToast({title:"获取分享服务失败"})}})},methods:{getDetail(){uni.request({url:"https://unidemo.dcloud.net.cn/api/news/36kr/"+this.banner.post_id,success:e=>{if(200==e.statusCode){var t=e.data.content.replace(/\\/g,"").replace(/<img/g,'<img style="display:none;"');this.htmlNodes=mu(t)}},fail:()=>{n("log","at pages/template/list2detail-detail/list2detail-detail.vue:140","fail")}})}}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{class:"banner"},[e.createElementVNode("image",{class:"banner-img",src:o.banner.cover},null,8,["src"]),e.createElementVNode("view",{class:"banner-title"},e.toDisplayString(o.banner.title),1)]),e.createElementVNode("view",{class:"article-meta"},[e.createElementVNode("text",{class:"article-author"},e.toDisplayString(o.banner.author_name),1),e.createElementVNode("text",{class:"article-text"},"发表于"),e.createElementVNode("text",{class:"article-time"},e.toDisplayString(o.banner.published_at),1)]),e.createElementVNode("view",{class:"article-content"},[o.visible?(e.openBlock(),e.createElementBlock("rich-text",{key:0,nodes:o.htmlNodes},null,8,["nodes"])):e.createCommentVNode("",!0)])])}]]),yu={data:()=>({title:""}),onLoad(e){this.title=e.title||""}};const vu=t(yu,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"root"},[e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("view",{class:"uni-title"},"这是选项卡页面跳转详情页面的演示，下面是页面跳转时传递过来的标题："),e.createElementVNode("view",{class:"uni-title"},e.toDisplayString(o.title),1)])])}]]),wu={data:()=>({}),methods:{openBrowser(e){plus.runtime.openURL(e)},openMarket(e){var t;t="Android"==plus.os.name?"market://details?id=io.dcloud.hellouniapp":"itms-apps://itunes.apple.com/cn/app/hello-uni-app/id1417078253",void 0===e?plus.runtime.openURL(t,(function(e){n("log","at pages/template/scheme/scheme.vue:61",e)})):"Android"==plus.os.name?plus.runtime.openURL(t,(function(e){plus.nativeUI.alert("本机没有安装应用宝")}),e):plus.nativeUI.alert("仅Android手机才支持应用宝")},openTaobao(e){plus.runtime.openURL(e,(function(e){uni.showModal({content:"本机未检测到淘宝客户端，是否打开浏览器访问淘宝？",success:function(e){e.confirm&&plus.runtime.openURL("https://s.taobao.com/search?q=uni-app")}})}))},openMap(){var e="";if("Android"==plus.os.name){var t=plus.runtime.isApplicationExist({pname:"com.baidu.BaiduMap",action:"baidumap://"}),a=plus.runtime.isApplicationExist({pname:"com.autonavi.minimap",action:"androidamap://"}),i="baidumap://map/marker?location=39.968789,116.347247&title=DCloud&src=Hello%20uni-app",o="androidamap://viewMap?sourceApplication=Hello%20uni-app&poiname=DCloud&lat=39.9631018208&lon=116.3406135236&dev=0";a&&t?plus.nativeUI.actionSheet({title:"选择地图应用",cancel:"取消",buttons:[{title:"百度地图"},{title:"高德地图"}]},(function(e){switch(e.index){case 1:plus.runtime.openURL(i);break;case 2:plus.runtime.openURL(o)}})):a?plus.runtime.openURL(o):t?plus.runtime.openURL(i):(e="geo:39.96310,116.340698?q=%e6%95%b0%e5%ad%97%e5%a4%a9%e5%a0%82",plus.runtime.openURL(e))}else plus.nativeUI.actionSheet({title:"选择地图应用",cancel:"取消",buttons:[{title:"Apple地图"},{title:"百度地图"},{title:"高德地图"}]},(function(t){switch(n("log","at pages/template/scheme/scheme.vue:117","e.index: "+t.index),t.index){case 1:e="http://maps.apple.com/?q=%e6%95%b0%e5%ad%97%e5%a4%a9%e5%a0%82&ll=39.96310,116.340698&spn=0.008766,0.019441";break;case 2:e="baidumap://map/marker?location=39.968789,116.347247&title=DCloud&src=Hello%20uni-app";break;case 3:e="iosamap://viewMap?sourceApplication=Hello%20uni-app&poiname=DCloud&lat=39.9631018208&lon=116.3406135236&dev=0"}""!=e&&plus.runtime.openURL(e,(function(e){plus.nativeUI.alert("本机未安装指定的地图应用")}))}))},openQQ:function(e){plus.runtime.openURL("mqqwpa://im/chat?chat_type="+e.detail.value.qqNumType+"&uin="+e.detail.value.qqNum,(function(e){plus.nativeUI.alert("本机没有安装QQ，无法启动")}))}}};const bu=t(wu,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:"通过scheme打开三方app示例"}),e.createElementVNode("button",{class:"button",onClick:n[0]||(n[0]=e=>r.openBrowser("https://uniapp.dcloud.io/h5"))},"使用浏览器打开指定URL"),e.createElementVNode("button",{class:"button",onClick:n[1]||(n[1]=e=>r.openMarket())},"使用应用商店打开指定App"),e.createElementVNode("button",{class:"button",onClick:n[2]||(n[2]=e=>r.openMarket("com.tencent.android.qqdownloader"))},"强制使用应用宝打开指定App"),e.createElementVNode("button",{class:"button",onClick:n[3]||(n[3]=e=>r.openTaobao("taobao://s.taobao.com/search?q=uni-app"))},"打开淘宝搜索页面"),e.createElementVNode("button",{class:"button",onClick:n[4]||(n[4]=e=>r.openMap())},"打开地图并指定地点"),e.createElementVNode("view",{class:"uni-divider"},[e.createElementVNode("view",{class:"uni-divider__content"},"打开QQ"),e.createElementVNode("view",{class:"uni-divider__line"})]),e.createElementVNode("view",{class:"uni-padding-wrap"},[e.createElementVNode("form",{onSubmit:n[5]||(n[5]=(...e)=>r.openQQ&&r.openQQ(...e))},[e.createElementVNode("view",null,[e.createElementVNode("view",{class:"uni-title"},"请输入聊天对象QQ号："),e.createElementVNode("view",{class:"uni-list"},[e.createElementVNode("view",{class:"uni-list-cell"},[e.createElementVNode("input",{class:"uni-input",name:"qqNum",type:"number"})])])]),e.createElementVNode("view",null,[e.createElementVNode("view",{class:"uni-title"},"请选择QQ号类型："),e.createElementVNode("radio-group",{class:"uni-flex",name:"qqNumType"},[e.createElementVNode("label",null,[e.createElementVNode("radio",{value:"wpa",checked:""}),e.createTextVNode("普通QQ号")]),e.createElementVNode("label",null,[e.createElementVNode("radio",{value:"crm"}),e.createTextVNode("营销QQ号(无需加好友直接聊天)")])])]),e.createElementVNode("view",{class:"uni-btn-v uni-common-mt"},[e.createElementVNode("button",{class:"button",formType:"submit"},"打开qq并到指定聊天界面")])],32)])])}]]),ku=e=>{(e.$renderjs||(e.$renderjs=[])).push("renderjs"),(e.$renderjsModules||(e.$renderjsModules={})).renderjs="5be2ab59"},xu={data:()=>({title:"renderjs",data:"serviceData"}),methods:{changeServiceData(){this.data="serviceData改变了"},getRenderData(e){n("log","at pages/template/renderjs/renderjs.vue:25","renderjs返回的值--\x3e",e),this.data=e}}};ku(xu);const Vu=t(xu,[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",null,[e.createVNode(c,{title:l.title},null,8,["title"]),e.createElementVNode("view",{data:e.wp(l.data),"change:data":t.renderjs.getServiceData,class:"renderjs",style:{margin:"40rpx"}},e.toDisplayString(l.data),9,["data","change:data"]),e.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>t.renderjs.sendRenderjsData&&t.renderjs.sendRenderjsData(...e))},"调用renderjs中的sendRenderjsData方法"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.changeServiceData&&r.changeServiceData(...e))},"改变data的值,renderjs层收到改变后的数据")])}]]);const Nu=t({data:()=>({gd:{}}),computed:{...ve(["testvuex"])},methods:{...we(["setTestTrue"]),...we(["setTestFalse"]),setGD:function(){this.gd.test="123"},setVUEX:function(e){e?this.setTestTrue(this.$store.state):this.setTestFalse(this.$store.state)}},onShow(){this.gd=getApp().globalData}},[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",{class:"pa"},[e.createElementVNode("view",{class:"uni-divider"},[e.createElementVNode("view",{class:"uni-divider__content"},"globalData"),e.createElementVNode("view",{class:"uni-divider__line"})]),e.createElementVNode("text",{class:"text"},"globalData中text的值: "+e.toDisplayString(o.gd.test),1),e.createElementVNode("button",{onClick:a[0]||(a[0]=e=>s.setGD()),class:"button"},"修改上述值为123"),e.createElementVNode("view",{class:"uni-divider"},[e.createElementVNode("view",{class:"uni-divider__content"},"vuex"),e.createElementVNode("view",{class:"uni-divider__line"})]),e.createElementVNode("text",{class:"text"},"vuex中hasLogin的值: "+e.toDisplayString(t.testvuex),1),e.createElementVNode("button",{onClick:a[1]||(a[1]=e=>s.setVUEX(!0)),class:"button"},"修改上述值为true"),e.createElementVNode("button",{onClick:a[2]||(a[2]=e=>s.setVUEX(!1)),class:"button"},"修改上述值为false")])}]]);
/*!
   * pinia v2.1.7
   * (c) 2023 Eduardo San Martin Morote
   * @license MIT
   */
let Eu;const Cu=e=>Eu=e,_u=Symbol();function Su(e){return e&&"object"==typeof e&&"[object Object]"===Object.prototype.toString.call(e)&&"function"!=typeof e.toJSON}var Tu,Bu;(Bu=Tu||(Tu={})).direct="direct",Bu.patchObject="patch object",Bu.patchFunction="patch function";const Du="undefined"!=typeof window;function Iu(){const t=e.effectScope(!0),a=t.run((()=>e.ref({})));let n=[],i=[];const o=e.markRaw({install(e){Cu(o),o._a=e,e.provide(_u,o),e.config.globalProperties.$pinia=o,i.forEach((e=>n.push(e))),i=[]},use(e){return this._a?n.push(e):i.push(e),this},_p:n,_a:null,_e:t,_s:new Map,state:a});return o}const Pu=()=>{};function Au(t,a,n,i=Pu){t.push(a);const o=()=>{const e=t.indexOf(a);e>-1&&(t.splice(e,1),i())};return!n&&e.getCurrentScope()&&e.onScopeDispose(o),o}function Fu(e,...t){e.slice().forEach((e=>{e(...t)}))}const Lu=e=>e();function Mu(t,a){t instanceof Map&&a instanceof Map&&a.forEach(((e,a)=>t.set(a,e))),t instanceof Set&&a instanceof Set&&a.forEach(t.add,t);for(const n in a){if(!a.hasOwnProperty(n))continue;const i=a[n],o=t[n];Su(o)&&Su(i)&&t.hasOwnProperty(n)&&!e.isRef(i)&&!e.isReactive(i)?t[n]=Mu(o,i):t[n]=i}return t}const Ru=Symbol();const{assign:Ou}=Object;function $u(t,a,n={},i,o,s){let l;const r=Ou({actions:{}},n),c={deep:!0};let d,u,h,p=[],m=[];const g=i.state.value[t];let f;function y(a){let n;d=u=!1,"function"==typeof a?(a(i.state.value[t]),n={type:Tu.patchFunction,storeId:t,events:h}):(Mu(i.state.value[t],a),n={type:Tu.patchObject,payload:a,storeId:t,events:h});const o=f=Symbol();e.nextTick().then((()=>{f===o&&(d=!0)})),u=!0,Fu(p,n,i.state.value[t])}s||g||(i.state.value[t]={}),e.ref({});const v=s?function(){const{state:e}=n,t=e?e():{};this.$patch((e=>{Ou(e,t)}))}:Pu;function w(e,a){return function(){Cu(i);const n=Array.from(arguments),o=[],s=[];function l(e){o.push(e)}function r(e){s.push(e)}let c;Fu(m,{args:n,name:e,store:k,after:l,onError:r});try{c=a.apply(this&&this.$id===t?this:k,n)}catch(d){throw Fu(s,d),d}return c instanceof Promise?c.then((e=>(Fu(o,e),e))).catch((e=>(Fu(s,e),Promise.reject(e)))):(Fu(o,c),c)}}const b={_p:i,$id:t,$onAction:Au.bind(null,m),$patch:y,$reset:v,$subscribe(a,n={}){const o=Au(p,a,n.detached,(()=>s())),s=l.run((()=>e.watch((()=>i.state.value[t]),(e=>{("sync"===n.flush?u:d)&&a({storeId:t,type:Tu.direct,events:h},e)}),Ou({},c,n))));return o},$dispose:function(){l.stop(),p=[],m=[],i._s.delete(t)}},k=e.reactive(b);i._s.set(t,k);const x=(i._a&&i._a.runWithContext||Lu)((()=>i._e.run((()=>(l=e.effectScope()).run(a)))));for(const E in x){const a=x[E];if(e.isRef(a)&&(N=a,!e.isRef(N)||!N.effect)||e.isReactive(a))s||(!g||Su(V=a)&&V.hasOwnProperty(Ru)||(e.isRef(a)?a.value=g[E]:Mu(a,g[E])),i.state.value[t][E]=a);else if("function"==typeof a){const e=w(E,a);x[E]=e,r.actions[E]=a}}var V,N;return Ou(k,x),Ou(e.toRaw(k),x),Object.defineProperty(k,"$state",{get:()=>i.state.value[t],set:e=>{y((t=>{Ou(t,e)}))}}),i._p.forEach((e=>{Ou(k,l.run((()=>e({store:k,app:i._a,pinia:i,options:r}))))})),g&&s&&n.hydrate&&n.hydrate(k.$state,g),d=!0,u=!0,k}function zu(t,a,n){let i,o;const s="function"==typeof a;function l(t,n){const l=e.hasInjectionContext();(t=t||(l?e.inject(_u,null):null))&&Cu(t),(t=Eu)._s.has(i)||(s?$u(i,a,o,t):function(t,a,n,i){const{state:o,actions:s,getters:l}=a,r=n.state.value[t];let c;c=$u(t,(function(){r||(n.state.value[t]=o?o():{});const a=e.toRefs(n.state.value[t]);return Ou(a,s,Object.keys(l||{}).reduce(((a,i)=>(a[i]=e.markRaw(e.computed((()=>{Cu(n);const e=n._s.get(t);return l[i].call(e,e)}))),a)),{}))}),a,n,0,!0)}(i,o,t));return t._s.get(i)}return"string"==typeof t?(i=t,o=s?n:a):(o=t,i=t.id),l.$id=i,l}let Uu="Store";function ju(e,t){return Array.isArray(t)?t.reduce(((t,a)=>(t[a]=function(){return e(this.$pinia)[a]},t)),{}):Object.keys(t).reduce(((a,n)=>(a[n]=function(){const a=e(this.$pinia),i=t[n];return"function"==typeof i?i.call(this,a):a[i]},a)),{})}const qu=ju;const Hu=Object.freeze(Object.defineProperty({__proto__:null,get MutationType(){return Tu},PiniaVuePlugin:function(e){e.mixin({beforeCreate(){const e=this.$options;if(e.pinia){const t=e.pinia;if(!this._provided){const e={};Object.defineProperty(this,"_provided",{get:()=>e,set:t=>Object.assign(e,t)})}this._provided[_u]=t,this.$pinia||(this.$pinia=t),t._a=this,Du&&Cu(t)}else!this.$pinia&&e.parent&&e.parent.$pinia&&(this.$pinia=e.parent.$pinia)},destroyed(){delete this._pStores}})},acceptHMRUpdate:function(e,t){return()=>{}},createPinia:Iu,defineStore:zu,getActivePinia:()=>e.hasInjectionContext()&&e.inject(_u)||Eu,mapActions:function(e,t){return Array.isArray(t)?t.reduce(((t,a)=>(t[a]=function(...t){return e(this.$pinia)[a](...t)},t)),{}):Object.keys(t).reduce(((a,n)=>(a[n]=function(...a){return e(this.$pinia)[t[n]](...a)},a)),{})},mapGetters:qu,mapState:ju,mapStores:function(...e){return e.reduce(((e,t)=>(e[t.$id+Uu]=function(){return t(this.$pinia)},e)),{})},mapWritableState:function(e,t){return Array.isArray(t)?t.reduce(((t,a)=>(t[a]={get(){return e(this.$pinia)[a]},set(t){return e(this.$pinia)[a]=t}},t)),{}):Object.keys(t).reduce(((a,n)=>(a[n]={get(){return e(this.$pinia)[t[n]]},set(a){return e(this.$pinia)[t[n]]=a}},a)),{})},setActivePinia:Cu,setMapStoreSuffix:function(e){Uu=e},skipHydrate:function(e){return Object.defineProperty(e,Ru,{})},storeToRefs:function(t){{t=e.toRaw(t);const a={};for(const n in t){const i=t[n];(e.isRef(i)||e.isReactive(i))&&(a[n]=e.toRef(t,n))}return a}}},Symbol.toStringTag,{value:"Module"})),Wu=zu("counter",{state:()=>({count:0}),getters:{doubleCount:e=>2*e.count},actions:{increment(){this.count++},decrement(){this.count--}}});const Ju=t({setup(){const e=Wu();return{counter:e,incrementCounter:function(){e.count++},incrementPatchCounter:function(){e.$patch({count:e.count+1})}}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"uni-product"},[e.createVNode(c,{title:"Pinia"}),e.createElementVNode("text",{class:"count"},"当前计数："+e.toDisplayString(s.counter.count),1),e.createElementVNode("text",{class:"doubleCount",style:{margin:"20rpx 0"}},"计数翻倍："+e.toDisplayString(s.counter.doubleCount),1),e.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>s.incrementCounter&&s.incrementCounter(...e))},"增加计数"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>s.incrementPatchCounter&&s.incrementPatchCounter(...e))},"使用$patch方法增加计数"),e.createElementVNode("button",{class:"increment",onClick:n[2]||(n[2]=(...e)=>s.counter.increment&&s.counter.increment(...e))},"通过actions中的increment增加计数"),e.createElementVNode("button",{class:"decrement",onClick:n[3]||(n[3]=(...e)=>s.counter.decrement&&s.counter.decrement(...e))},"通过actions中的decrement减少计数")])}]]),Gu=ge({state:{hasLogin:!1,isUniverifyLogin:!1,loginProvider:"",openid:null,testvuex:!1,colorIndex:0,colorList:["#FF0000","#00FF00","#0000FF"],noMatchLeftWindow:!0,active:"componentPage",leftWinActive:"/pages/component/view/view",activeOpen:"",menu:[],univerifyErrorMsg:"",username:"foo",sex:"男",age:10},mutations:{login(e,t){e.hasLogin=!0,e.loginProvider=t},logout(e){e.hasLogin=!1,e.openid=null},setOpenid(e,t){e.openid=t},setTestTrue(e){e.testvuex=!0},setTestFalse(e){e.testvuex=!1},setColorIndex(e,t){e.colorIndex=t},setMatchLeftWindow(e,t){e.noMatchLeftWindow=!t},setActive(e,t){e.active=t},setLeftWinActive(e,t){e.leftWinActive=t},setActiveOpen(e,t){e.activeOpen=t},setMenu(e,t){e.menu=t},setUniverifyLogin(e,t){"boolean"!=typeof t&&(t=!!t),e.isUniverifyLogin=t},setUniverifyErrorMsg(e,t=""){e.univerifyErrorMsg=t},increment(e){e.age++},incrementTen(e,t){e.age+=t.amount},resetAge(e){e.age=10}},getters:{currentColor:e=>e.colorList[e.colorIndex],doubleAge:e=>2*e.age},actions:{incrementAsync(e,t){e.commit("incrementTen",t)},getUserOpenId:async function({commit:e,state:t}){return await new Promise(((a,i)=>{t.openid?a(t.openid):uni.login({success:t=>{e("login"),setTimeout((function(){const t="123456789";n("log","at store/index.js:113","uni.request mock openid[123456789]"),e("setOpenid",t),a(t)}),1e3)},fail:e=>{n("log","at store/index.js:119","uni.login 接口调用失败，将无法正常使用开放接口等服务",e),i(e)}})}))},getPhoneNumber:function({commit:e},t){return new Promise(((e,a)=>{uni.request({url:"https://97fca9f2-41f6-449f-a35e-3f135d4c3875.bspapp.com/http/univerify-login",method:"POST",data:t,success:t=>{const n=t.data;n.success?e(n.phoneNumber):a(t)},fail:e=>{a(res)}})}))}}});const Ku=t({data:()=>({}),computed:{...ve(["age"]),username(){return this.$store.state.username},sex:()=>Gu.state.sex,doubleAge:()=>Gu.getters.doubleAge},methods:{addAge(){Gu.commit("increment")},addAgeTen(){Gu.commit("incrementTen",{amount:10})},addAgeAction(){Gu.dispatch("incrementAsync",{amount:20})},resetAge(){Gu.commit("resetAge")}}},[["render",function(t,n,o,s,l,r){const c=i(e.resolveDynamicComponent("page-head"),a);return e.openBlock(),e.createElementBlock("view",{class:"uni-product"},[e.createVNode(c,{title:"vuex:vue页面"}),e.createElementVNode("text",{class:"username"},"用户名："+e.toDisplayString(r.username),1),e.createElementVNode("text",{class:"sex"},"性别："+e.toDisplayString(r.sex),1),e.createElementVNode("view",{class:"age"},"年龄："+e.toDisplayString(t.age),1),e.createElementVNode("view",{class:"doubleAge"},"年龄翻倍："+e.toDisplayString(r.doubleAge),1),e.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>r.addAge&&r.addAge(...e))},"增加1岁"),e.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>r.addAgeTen&&r.addAgeTen(...e))},"增加10岁"),e.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>r.addAgeAction&&r.addAgeAction(...e))},"增加20岁"),e.createElementVNode("button",{onClick:n[3]||(n[3]=(...e)=>r.resetAge&&r.resetAge(...e))},"重置")])}]]);var Qu=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,62,0,62,0,63,52,53,54,55,56,57,58,59,60,61,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,0,0,0,0,63,0,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51];const Yu={getRandomValues(e){if(!(e instanceof Int8Array||e instanceof Uint8Array||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8ClampedArray))throw new Error("Expected an integer array");if(e.byteLength>65536)throw new Error("Can only request a maximum of 65536 bytes");var t;return function(e,t){for(var a,n=e.length,i="="===e[n-2]?2:"="===e[n-1]?1:0,o=0,s=n-i&4294967292,l=0;l<s;l+=4)a=Qu[e.charCodeAt(l)]<<18|Qu[e.charCodeAt(l+1)]<<12|Qu[e.charCodeAt(l+2)]<<6|Qu[e.charCodeAt(l+3)],t[o++]=a>>16&255,t[o++]=a>>8&255,t[o++]=255&a;1===i&&(a=Qu[e.charCodeAt(l)]<<10|Qu[e.charCodeAt(l+1)]<<4|Qu[e.charCodeAt(l+2)]>>2,t[o++]=a>>8&255,t[o++]=255&a),2===i&&(a=Qu[e.charCodeAt(l)]<<2|Qu[e.charCodeAt(l+1)]>>4,t[o++]=255&a)}((t="DCloud-Crypto",weex.requireModule(t)).getRandomValues(e.byteLength),new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),e}},Xu={data:()=>({str:[!1,!1,!1]}),methods:{getRandomValues(){try{this.str[0]="object"==typeof Yu,this.str[1]="function"==typeof Yu.getRandomValues;var e=new Uint8Array(16);const t=Yu.getRandomValues(e);this.str[2]=16===t.length}catch($i){n("log","at pages/template/crypto-api/crypto-api.vue:25","crypto error:",$i)}}}};const Zu=t(Xu,[["render",function(t,a,n,i,o,s){return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{id:"str"},e.toDisplayString(o.str.join("-")),1),e.createElementVNode("button",{id:"button",onClick:a[0]||(a[0]=(...e)=>s.getRandomValues&&s.getRandomValues(...e))},"crypto.getRandomValues")])}]]);__definePage("pages/component/view/view",o),__definePage("pages/component/scroll-view/scroll-view",l),__definePage("pages/component/swiper/swiper",c),__definePage("pages/component/movable-view/movable-view",u),__definePage("pages/component/text/text",h),__definePage("pages/component/rich-text/rich-text",p),__definePage("pages/component/progress/progress",f),__definePage("pages/component/button/button",y),__definePage("pages/component/checkbox/checkbox",w),__definePage("pages/component/form/form",x),__definePage("pages/component/label/label",N),__definePage("pages/component/picker/picker",_),__definePage("pages/component/picker-view/picker-view",T),__definePage("pages/component/radio/radio",B),__definePage("pages/component/slider/slider",I),__definePage("pages/component/switch/switch",A),__definePage("pages/component/textarea/textarea",L),__definePage("pages/component/editor/editor",R),__definePage("pages/component/navigator/navigator",Be),__definePage("pages/component/navigator/navigate/navigate",De),__definePage("pages/component/navigator/redirect/redirect",Ie),__definePage("pages/component/image/image",Pe),__definePage("pages/component/canvas/canvas",Le),__definePage("pages/component/web-view/web-view",Me),__definePage("pages/component/ad/ad",Oe),__definePage("pages/component/web-view-local/web-view-local",ze),__definePage("pages/component/web-view-local/issue-17581",Ue),__definePage("platforms/app-plus/speech/speech",We),__definePage("platforms/app-plus/orientation/orientation",Ke),__definePage("platforms/app-plus/proximity/proximity",Ze),__definePage("platforms/app-plus/push/push",tt),__definePage("platforms/app-plus/shake/shake",at),__definePage("pages/about/about",it),__definePage("platforms/app-plus/feedback/feedback",rt),__definePage("uni_modules/uni-upgrade-center-app/pages/upgrade-popup",Ct),__definePage("pages/API/login/login",Tt),__definePage("pages/API/subnvue/subnvue",Bt),__definePage("pages/API/get-user-info/get-user-info",Dt),__definePage("pages/API/request-payment/request-payment",Pt),__definePage("pages/API/share/share",Ft),__definePage("pages/API/set-navigation-bar-title/set-navigation-bar-title",Lt),__definePage("pages/API/show-loading/show-loading",Mt),__definePage("pages/API/navigator/navigator",$t),__definePage("pages/API/navigator/new-page/new-vue-page-1",Ut),__definePage("pages/API/navigator/new-page/new-vue-page-2",jt),__definePage("pages/API/pull-down-refresh/pull-down-refresh",qt),__definePage("pages/API/animation/animation",Ht),__definePage("pages/API/get-node-info/get-node-info",Wt),__definePage("pages/API/intersection-observer/intersection-observer",Gt),__definePage("pages/API/canvas/canvas",Qt),__definePage("pages/API/action-sheet/action-sheet",Xt),__definePage("pages/API/modal/modal",Zt),__definePage("pages/API/toast/toast",ea),__definePage("pages/API/get-network-type/get-network-type",ta),__definePage("pages/API/get-system-info/get-system-info",aa),__definePage("pages/API/add-phone-contact/add-phone-contact",ia),__definePage("pages/API/on-accelerometer-change/on-accelerometer-change",oa),__definePage("pages/API/on-compass-change/on-compass-change",sa),__definePage("pages/API/make-phone-call/make-phone-call",ra),__definePage("pages/API/scan-code/scan-code",ca),__definePage("pages/API/clipboard/clipboard",ua),__definePage("pages/API/request/request",ga),__definePage("pages/API/upload-file/upload-file",fa),__definePage("pages/API/download-file/download-file",ya),__definePage("pages/API/image/image",ka),__definePage("pages/API/voice/voice",Ia),__definePage("pages/API/inner-audio/inner-audio",Aa),__definePage("pages/API/background-audio/background-audio",La),__definePage("pages/API/video/video",Oa),__definePage("pages/API/file/file",$a),__definePage("pages/API/get-location/get-location",Ga),__definePage("pages/API/open-location/open-location",Qa),__definePage("pages/API/choose-location/choose-location",Xa),__definePage("pages/API/storage/storage",en),__definePage("pages/API/sqlite/sqlite",an),__definePage("pages/API/rewarded-video-ad/rewarded-video-ad",on),__definePage("pages/API/full-screen-video-ad/full-screen-video-ad",sn),__definePage("pages/API/brightness/brightness",rn),__definePage("pages/API/save-media/save-media",cn),__definePage("pages/API/bluetooth/bluetooth",pn),__definePage("pages/API/soter/soter",mn),__definePage("pages/API/ibeacon/ibeacon",yn),__definePage("pages/API/vibrate/vibrate",vn),__definePage("pages/API/websocket-socketTask/websocket-socketTask",bn),__definePage("pages/API/websocket-global/websocket-global",xn),__definePage("pages/extUI/forms/forms",Ir),__definePage("pages/extUI/group/group",Ar),__definePage("pages/extUI/badge/badge",Lr),__definePage("pages/extUI/breadcrumb/breadcrumb",Or),__definePage("pages/extUI/drawer/drawer",Ur),__definePage("pages/extUI/popup/popup",Yr),__definePage("pages/extUI/segmented-control/segmented-control",Zr),__definePage("pages/extUI/collapse/collapse",lc),__definePage("pages/extUI/pagination/pagination",pc),__definePage("pages/extUI/steps/steps",gc),__definePage("pages/extUI/notice-bar/notice-bar",yc),__definePage("pages/extUI/swipe-action/swipe-action",Ec),__definePage("pages/extUI/search-bar/search-bar",Dc),__definePage("pages/extUI/fab/fab",Ac),__definePage("pages/extUI/fav/fav",$c),__definePage("pages/extUI/section/section",zc),__definePage("pages/extUI/transition/transition",Uc),__definePage("pages/extUI/title/title",qc),__definePage("pages/extUI/tooltip/tooltip",Wc),__definePage("pages/extUI/link/link",Gc),__definePage("pages/extUI/combox/combox",Qc),__definePage("pages/extUI/list/chat",Zc),__definePage("pages/extUI/table/table",rd),__definePage("pages/extUI/dateformat/dateformat",md),__definePage("pages/extUI/data-checkbox/data-checkbox",gd),__definePage("pages/extUI/easyinput/easyinput",yd),__definePage("pages/extUI/data-select/data-select",wd),__definePage("pages/extUI/datetime-picker/datetime-picker",kd),__definePage("pages/extUI/row/row",Nd),__definePage("pages/extUI/file-picker/file-picker",Ad),__definePage("pages/extUI/button/button",Fd),__definePage("pages/template/nav-default/nav-default",Ld),__definePage("pages/template/component-communication/component-communication",Rd),__definePage("pages/template/nav-transparent/nav-transparent",$d),__definePage("pages/template/nav-button/nav-button",Ud),__definePage("pages/template/nav-image/nav-image",jd),__definePage("pages/template/nav-city-dropdown/nav-city-dropdown",Hd),__definePage("pages/template/nav-dot/nav-dot",Jd),__definePage("pages/template/nav-search-input/nav-search-input",Gd),__definePage("pages/template/nav-search-input/detail/detail",tu),__definePage("pages/template/list2detail-list/list2detail-list",nu),__definePage("pages/template/list2detail-detail/list2detail-detail",fu),__definePage("pages/template/tabbar/detail/detail",vu),__definePage("pages/template/scheme/scheme",bu),__definePage("pages/template/renderjs/renderjs",Vu),__definePage("pages/template/global/global",Nu),__definePage("pages/template/pinia/pinia",Ju),__definePage("pages/template/vuex-vue/vuex-vue",Ku),__definePage("pages/template/crypto-api/crypto-api",Zu);const eh="__package_info__";function th(){return new Promise(((e,t)=>{new Promise(((e,t)=>{plus.runtime.getProperty(plus.runtime.appid,(function(a){const i={action:"checkVersion",appid:plus.runtime.appid,appVersion:plus.runtime.version,wgtVersion:a.version};n("log","at uni_modules/uni-upgrade-center-app/utils/call-check-version.js:11","data: ",i),Cl.callFunction({name:"uni-upgrade-center",data:i,success:t=>{n("log","at uni_modules/uni-upgrade-center-app/utils/call-check-version.js:16","e: ",t),e(t)},fail:e=>{t(e)}})}))})).then((async a=>{if(!a.result)return;const{code:i,message:o,is_silently:s,url:l,platform:r,type:c}=a.result;if(i>0){const{fileList:t}=await Cl.getTempFileURL({fileList:[l]});return t[0].tempFileURL&&(a.result.url=t[0].tempFileURL),e(a),s?void uni.downloadFile({url:a.result.url,success:e=>{200==e.statusCode&&plus.runtime.install(e.tempFilePath,{force:!1})}}):(uni.setStorageSync(eh,a.result),void uni.navigateTo({url:"/uni_modules/uni-upgrade-center-app/pages/upgrade-popup?local_storage_key=__package_info__",fail:e=>{n("error","at uni_modules/uni-upgrade-center-app/utils/check-update.js:63","更新弹框跳转失败",e),uni.removeStorageSync(eh)}}))}return i<0?(n("error","at uni_modules/uni-upgrade-center-app/utils/check-update.js:71",o),t(a)):e(a)})).catch((e=>{n("error","at uni_modules/uni-upgrade-center-app/utils/check-update.js:77",e.message),t(e)}))}))}const ah={onLaunch:function(){n("log","at App.vue:23","App Launch"),"HBuilder"!==plus.runtime.appid&&th(),uni.preLogin({provider:"univerify",success:e=>{this.setUniverifyErrorMsg(),n("log","at App.vue:36","preLogin success: ",e)},fail:e=>{this.setUniverifyLogin(!1),this.setUniverifyErrorMsg(e.errMsg),n("log","at App.vue:42","preLogin fail res: ",e)}})},onShow:function(){n("log","at App.vue:48","App Show")},onHide:function(){n("log","at App.vue:51","App Hide")},globalData:{test:""},methods:{...we(["setUniverifyErrorMsg","setUniverifyLogin"])}};const{app:nh,Vuex:ih,Pinia:oh}=function(){const t=e.createVueApp(ah);return t.use(Gu),t.use(Iu()),t.config.globalProperties.$adpid="1111111111",t.config.globalProperties.$backgroundAudioData={playing:!1,playTime:0,formatedPlayTime:"00:00:00"},{app:t,Vuex:Te,Pinia:Hu}}();uni.Vuex=ih,uni.Pinia=oh,nh.provide("__globalStyles",__uniConfig.styles),nh._component.mpType="app",nh._component.render=()=>{},nh.mount("#app")}(Vue);
