|
|
import{D as e,E as t,G as a,H as i,J as n,o as r,c as s,w as l,k as o,M as c,d as u,m as d,f as p,F as m,g as h,i as f,L as y,N as g,ah as _,b as w,e as C,t as I,O as x,v as k,am as v,j as b,C as S,B as A,al as T,aA as M,U as B,aB as U,aC as L,r as N,a as R,q as j,Y as H,_ as E,aD as $,aE as V,aF as O,aG as F,A as Q,u as D,n as q,an as P}from"./index-DkGewvWo.js";import{_ as K}from"./u-icon.x7ElsZU9.js";import{r as G,b as J,a as X}from"./uni-app.es.Bo01BzMV.js";import{_ as W}from"./u-navbar.CwZJfInl.js";import{_ as Y}from"./u-loading-icon.CdrBTsp-.js";import{_ as z}from"./_plugin-vue_export-helper.BCo6x5W8.js";import{_ as Z}from"./u-popup.C1usqomr.js";import{c as ee}from"./car.CcI8AEaV.js";import"./u-status-bar.DDNs5qwz.js";const te=z({name:"u-swiper-indicator",mixins:[a,i,e({props:{length:{type:[String,Number],default:()=>t.swiperIndicator.length},current:{type:[String,Number],default:()=>t.swiperIndicator.current},indicatorActiveColor:{type:String,default:()=>t.swiperIndicator.indicatorActiveColor},indicatorInactiveColor:{type:String,default:()=>t.swiperIndicator.indicatorInactiveColor},indicatorMode:{type:String,default:()=>t.swiperIndicator.indicatorMode}}})],data:()=>({lineWidth:22}),computed:{lineStyle(){let e={};return e.width=n(this.lineWidth),e.transform=`translateX(${n(this.current*this.lineWidth)})`,e.backgroundColor=this.indicatorActiveColor,e},dotStyle(){return e=>{let t={};return t.backgroundColor=e===this.current?this.indicatorActiveColor:this.indicatorInactiveColor,t}}},methods:{addUnit:n}},[["render",function(e,t,a,i,n,y){const g=f;return r(),s(g,{class:"u-swiper-indicator"},{default:l((()=>["line"===e.indicatorMode?(r(),s(g,{key:0,class:o(["u-swiper-indicator__wrapper",[`u-swiper-indicator__wrapper--${e.indicatorMode}`]]),style:c({width:y.addUnit(n.lineWidth*e.length),backgroundColor:e.indicatorInactiveColor})},{default:l((()=>[u(g,{class:"u-swiper-indicator__wrapper--line__bar",style:c([y.lineStyle])},null,8,["style"])])),_:1},8,["class","style"])):d("",!0),"dot"===e.indicatorMode?(r(),s(g,{key:1,class:"u-swiper-indicator__wrapper"},{default:l((()=>[(r(!0),p(m,null,h(e.length,((t,a)=>(r(),s(g,{class:o(["u-swiper-indicator__wrapper__dot",[a===e.current&&"u-swiper-indicator__wrapper__dot--active"]]),key:a,style:c([y.dotStyle(a)])},null,8,["class","style"])))),128))])),_:1})):d("",!0)])),_:1})}],["__scopeId","data-v-d306b816"]]);const ae=z({name:"u-swiper",mixins:[a,i,e({props:{list:{type:Array,default:()=>t.swiper.list},indicator:{type:Boolean,default:()=>t.swiper.indicator},indicatorActiveColor:{type:String,default:()=>t.swiper.indicatorActiveColor},indicatorInactiveColor:{type:String,default:()=>t.swiper.indicatorInactiveColor},indicatorStyle:{type:[String,Object],default:()=>t.swiper.indicatorStyle},indicatorMode:{type:String,default:()=>t.swiper.indicatorMode},autoplay:{type:Boolean,default:()=>t.swiper.autoplay},current:{type:[String,Number],default:()=>t.swiper.current},currentItemId:{type:String,default:()=>t.swiper.currentItemId},interval:{type:[String,Number],default:()=>t.swiper.interval},duration:{type:[String,Number],default:()=>t.swiper.duration},circular:{type:Boolean,default:()=>t.swiper.circular},previousMargin:{type:[String,Number],default:()=>t.swiper.previousMargin},nextMargin:{type:[String,Number],default:()=>t.swiper.nextMargin},acceleration:{type:Boolean,default:()=>t.swiper.acceleration},displayMultipleItems:{type:Number,default:()=>t.swiper.displayMultipleItems},easingFunction:{type:String,default:()=>t.swiper.easingFunction},keyName:{type:String,default:()=>t.swiper.keyName},imgMode:{type:String,default:()=>t.swiper.imgMode},height:{type:[String,Number],default:()=>t.swiper.height},bgColor:{type:String,default:()=>t.swiper.bgColor},radius:{type:[String,Number],default:()=>t.swiper.radius},loading:{type:Boolean,default:()=>t.swiper.loading},showTitle:{type:Boolean,default:()=>t.swiper.showTitle}}})],data:()=>({currentIndex:0}),watch:{current(e,t){e!==t&&(this.currentIndex=e)}},emits:["click","change"],computed:{itemStyle(){return e=>{const t={};return this.nextMargin&&this.previo
|