优化页面
This commit is contained in:
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../common/vendor.js"),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)}}};const s=e._export_sfc(t,[["render",function(t,s,l,o,a,c){return e.e({a:l.selected&&l.weeks.extraInfo},(l.selected&&l.weeks.extraInfo,{}),{b:e.t(l.weeks.date),c:l.calendar.fullDate!==l.weeks.fullDate||!l.calendar.userChecked&&l.checkHover?"":1,d:l.checkHover?1:"",e:l.weeks.beforeMultiple?1:"",f:l.weeks.multiple?1:"",g:l.weeks.afterMultiple?1:"",h:l.weeks.disable?1:"",i:l.weeks.isToday?1:"",j:l.weeks.disable?1:"",k:l.weeks.beforeMultiple?1:"",l:l.weeks.multiple?1:"",m:l.weeks.afterMultiple?1:"",n:e.o$1((e=>c.choiceDate(l.weeks))),o:e.o$1((e=>c.handleMousemove(l.weeks)))})}]]);wx.createComponent(s);
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="{{['uni-calendar-item__weeks-box', j && 'uni-calendar-item--disable', k && 'uni-calendar-item--before-checked-x', l && 'uni-calendar-item--multiple', m && 'uni-calendar-item--after-checked-x']}}" bindtap="{{n}}" bindmouseenter="{{o}}"><view class="{{['uni-calendar-item__weeks-box-item', c && 'uni-calendar-item--checked', d && 'uni-calendar-item--checked-range-text', e && 'uni-calendar-item--before-checked', f && 'uni-calendar-item--multiple', g && 'uni-calendar-item--after-checked', h && 'uni-calendar-item--disable']}}"><text wx:if="{{a}}" class="uni-calendar-item__weeks-box-circle"></text><text class="uni-calendar-item__weeks-box-text uni-calendar-item__weeks-box-text-disable uni-calendar-item--checked-text">{{b}}</text></view><view class="{{[i && 'uni-calendar-item--today']}}"></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-calendar-item__weeks-box{flex:1;display:flex;flex-direction:column;justify-content:center;align-items:center;margin:1px 0;position:relative}.uni-calendar-item__weeks-box-text{font-size:14px;font-weight:700;color:#001833}.uni-calendar-item__weeks-box-item{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;width:40px;height:40px}.uni-calendar-item__weeks-box-circle{position:absolute;top:5px;right:5px;width:8px;height:8px;border-radius:8px;background-color:#dd524d}.uni-calendar-item__weeks-box .uni-calendar-item--disable{cursor:default}.uni-calendar-item--disable .uni-calendar-item__weeks-box-text-disable{color:#d1d1d1}.uni-calendar-item--today{position:absolute;top:10px;right:17%;background-color:#dd524d;width:6px;height:6px;border-radius:50%}.uni-calendar-item--extra{color:#dd524d;opacity:.8}.uni-calendar-item__weeks-box .uni-calendar-item--checked{background-color:#007aff;border-radius:50%;box-sizing:border-box;border:3px solid #fff}.uni-calendar-item--checked .uni-calendar-item--checked-text{color:#fff}.uni-calendar-item--multiple .uni-calendar-item--checked-range-text{color:#333}.uni-calendar-item--multiple{background-color:#f6f7fc}.uni-calendar-item--multiple .uni-calendar-item--before-checked,.uni-calendar-item--multiple .uni-calendar-item--after-checked{background-color:#007aff;border-radius:50%;box-sizing:border-box;border:3px solid #F6F7FC}.uni-calendar-item--before-checked .uni-calendar-item--checked-text,.uni-calendar-item--after-checked .uni-calendar-item--checked-text{color:#fff}.uni-calendar-item--before-checked-x{border-top-left-radius:50px;border-bottom-left-radius:50px;box-sizing:border-box;background-color:#f6f7fc}.uni-calendar-item--after-checked-x{border-top-right-radius:50px;border-bottom-right-radius:50px;background-color:#f6f7fc}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"calendar-item": "./calendar-item",
|
||||
"time-picker": "./time-picker",
|
||||
"uni-icons": "../../../uni-icons/components/uni-icons/uni-icons"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="uni-calendar" bindmouseleave="{{P}}"><view wx:if="{{a}}" class="{{['uni-calendar__mask', b && 'uni-calendar--mask-show']}}" bindtap="{{c}}"></view><view wx:if="{{d}}" class="{{['uni-calendar__content', M && 'uni-calendar--fixed', N && 'uni-calendar--ani-show', O && 'uni-calendar__content-mobile']}}"><view class="{{['uni-calendar__header', l && 'uni-calendar__header-mobile']}}"><view class="uni-calendar__header-btn-box" catchtap="{{e}}"><view class="uni-calendar__header-btn uni-calendar--left"></view></view><picker mode="date" value="{{g}}" fields="month" bindchange="{{h}}"><text class="uni-calendar__header-text">{{f}}</text></picker><view class="uni-calendar__header-btn-box" catchtap="{{i}}"><view class="uni-calendar__header-btn uni-calendar--right"></view></view><view wx:if="{{j}}" class="dialog-close" bindtap="{{k}}"><view class="dialog-close-plus" data-id="close"></view><view class="dialog-close-plus dialog-close-rotate" data-id="close"></view></view></view><view class="uni-calendar__box"><view wx:if="{{m}}" class="uni-calendar__box-bg"><text class="uni-calendar__box-bg-text">{{n}}</text></view><view class="uni-calendar__weeks" style="padding-bottom:7px"><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{o}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{p}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{q}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{r}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{s}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{t}}</text></view><view class="uni-calendar__weeks-day"><text class="uni-calendar__weeks-day-text">{{v}}</text></view></view><view wx:for="{{w}}" wx:for-item="item" wx:key="b" class="uni-calendar__weeks"><view wx:for="{{item.a}}" wx:for-item="weeks" wx:key="e" class="uni-calendar__weeks-item"><calendar-item wx:if="{{weeks.d}}" class="uni-calendar-item--hook" bindchange="{{weeks.a}}" bindhandleMouse="{{weeks.b}}" u-i="{{weeks.c}}" bind:__l="__l" u-p="{{weeks.d}}"></calendar-item></view></view></view><view wx:if="{{x}}" class="uni-date-changed uni-calendar--fixed-top" style="padding:0 80px"><view class="uni-date-changed--time-date">{{y}}</view><time-picker wx:if="{{A}}" class="time-picker-style" u-i="9e80a514-1" bind:__l="__l" bindupdateModelValue="{{z}}" u-p="{{A}}"></time-picker></view><view wx:if="{{B}}" class="uni-date-changed uni-calendar--fixed-top"><view class="uni-date-changed--time-start"><view class="uni-date-changed--time-date">{{C}}</view><time-picker wx:if="{{E}}" class="time-picker-style" u-i="9e80a514-2" bind:__l="__l" bindupdateModelValue="{{D}}" u-p="{{E}}"></time-picker></view><view style="line-height:50px"><uni-icons wx:if="{{F}}" u-i="9e80a514-3" bind:__l="__l" u-p="{{F}}"></uni-icons></view><view class="uni-date-changed--time-end"><view class="uni-date-changed--time-date">{{G}}</view><time-picker wx:if="{{I}}" class="time-picker-style" u-i="9e80a514-4" bind:__l="__l" bindupdateModelValue="{{H}}" u-p="{{I}}"></time-picker></view></view><view wx:if="{{J}}" class="uni-date-changed uni-date-btn--ok"><view class="uni-datetime-picker--btn" bindtap="{{L}}">{{K}}</view></view></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-calendar{display:flex;flex-direction:column}.uni-calendar__mask{position:fixed;bottom:0;top:0;left:0;right:0;background-color:rgba(0,0,0,.4);transition-property:opacity;transition-duration:.3s;opacity:0;z-index:99}.uni-calendar--mask-show{opacity:1}.uni-calendar--fixed{position:fixed;bottom:calc(var(--window-bottom));left:0;right:0;transition-property:transform;transition-duration:.3s;transform:translateY(460px);z-index:99}.uni-calendar--ani-show{transform:translateY(0)}.uni-calendar__content{background-color:#fff}.uni-calendar__content-mobile{border-top-left-radius:10px;border-top-right-radius:10px;box-shadow:0 0 5px 3px rgba(0,0,0,.1)}.uni-calendar__header{position:relative;display:flex;flex-direction:row;justify-content:center;align-items:center;height:50px}.uni-calendar__header-mobile{padding:10px 10px 0}.uni-calendar--fixed-top{display:flex;flex-direction:row;justify-content:space-between;border-top-color:rgba(0,0,0,.4);border-top-style:solid;border-top-width:1px}.uni-calendar--fixed-width{width:50px}.uni-calendar__backtoday{position:absolute;right:0;top:25rpx;padding:0 5px 0 10px;height:25px;line-height:25px;font-size:12px;border-top-left-radius:25px;border-bottom-left-radius:25px;color:#fff;background-color:#f1f1f1}.uni-calendar__header-text{text-align:center;width:100px;font-size:15px;color:#666}.uni-calendar__button-text{text-align:center;width:100px;font-size:14px;color:#007aff;letter-spacing:3px}.uni-calendar__header-btn-box{display:flex;flex-direction:row;align-items:center;justify-content:center;width:50px;height:50px}.uni-calendar__header-btn{width:9px;height:9px;border-left-color:gray;border-left-style:solid;border-left-width:1px;border-top-color:#555;border-top-style:solid;border-top-width:1px}.uni-calendar--left{transform:rotate(-45deg)}.uni-calendar--right{transform:rotate(135deg)}.uni-calendar__weeks{position:relative;display:flex;flex-direction:row}.uni-calendar__weeks-item{flex:1}.uni-calendar__weeks-day{flex:1;display:flex;flex-direction:column;justify-content:center;align-items:center;height:40px;border-bottom-color:#f5f5f5;border-bottom-style:solid;border-bottom-width:1px}.uni-calendar__weeks-day-text{font-size:12px;color:#b2b2b2}.uni-calendar__box{position:relative;padding-bottom:7px}.uni-calendar__box-bg{display:flex;justify-content:center;align-items:center;position:absolute;top:0;left:0;right:0;bottom:0}.uni-calendar__box-bg-text{font-size:200px;font-weight:700;color:#999;opacity:.1;text-align:center;line-height:1}.uni-date-changed{padding:0 10px;text-align:center;color:#333;border-top-color:#dcdcdc;border-top-style:solid;border-top-width:1px;flex:1}.uni-date-btn--ok{padding:20px 15px}.uni-date-changed--time-start,.uni-date-changed--time-end{display:flex;align-items:center}.uni-date-changed--time-date{color:#999;line-height:50px;margin-right:5px}.time-picker-style{display:flex;justify-content:center;align-items:center}.mr-10{margin-right:10px}.dialog-close{position:absolute;top:0;right:0;bottom:0;display:flex;flex-direction:row;align-items:center;padding:0 25px;margin-top:10px}.dialog-close-plus{width:16px;height:2px;background-color:#737987;border-radius:2px;transform:rotate(45deg)}.dialog-close-rotate{position:absolute;transform:rotate(-45deg)}.uni-datetime-picker--btn{border-radius:100px;height:40px;line-height:40px;background-color:#007aff;color:#fff;font-size:16px;letter-spacing:2px}.uni-datetime-picker--btn:active{opacity:.7}
|
||||
@@ -0,0 +1 @@
|
||||
"use strict";const e={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":"確認"}};exports.i18nMessages=e;
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="uni-datetime-picker"><view bindtap="{{f}}"><block wx:if="{{$slots.d}}"><slot></slot></block><block wx:else><view class="{{['uni-datetime-picker-timebox-pointer', d && 'uni-datetime-picker-disabled', e && 'uni-datetime-picker-timebox']}}"><text class="uni-datetime-picker-text">{{a}}</text><view wx:if="{{b}}" class="uni-datetime-picker-time"><text class="uni-datetime-picker-text">{{c}}</text></view></view></block></view><view wx:if="{{g}}" id="mask" class="uni-datetime-picker-mask" bindtap="{{h}}"></view><view wx:if="{{i}}" class="{{['uni-datetime-picker-popup', J]}}" style="{{K}}"><view class="uni-title"><text class="uni-datetime-picker-text">{{j}}</text></view><view wx:if="{{k}}" class="uni-datetime-picker__container-box"><block wx:if="{{r0}}"><picker-view class="uni-datetime-picker-view" indicator-style="{{o}}" value="{{p}}" bindchange="{{q}}"><picker-view-column><view wx:for="{{l}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column><picker-view-column><view wx:for="{{m}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column><picker-view-column><view wx:for="{{n}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column></picker-view></block><text class="uni-datetime-picker-sign sign-left">-</text><text class="uni-datetime-picker-sign sign-right">-</text></view><view wx:if="{{r}}" class="uni-datetime-picker__container-box"><block wx:if="{{r0}}"><picker-view class="{{['uni-datetime-picker-view', x]}}" indicator-style="{{y}}" value="{{z}}" bindchange="{{A}}"><picker-view-column><view wx:for="{{s}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column><picker-view-column><view wx:for="{{t}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column><picker-view-column wx:if="{{v}}"><view wx:for="{{w}}" wx:for-item="item" wx:key="b" class="uni-datetime-picker-item"><text class="uni-datetime-picker-item">{{item.a}}</text></view></picker-view-column></picker-view></block><text class="{{['uni-datetime-picker-sign', B]}}">:</text><text wx:if="{{C}}" class="uni-datetime-picker-sign sign-right">:</text></view><view class="uni-datetime-picker-btn"><view bindtap="{{E}}"><text class="uni-datetime-picker-btn-text">{{D}}</text></view><view class="uni-datetime-picker-btn-group"><view class="uni-datetime-picker-cancel" bindtap="{{G}}"><text class="uni-datetime-picker-btn-text">{{F}}</text></view><view bindtap="{{I}}"><text class="uni-datetime-picker-btn-text">{{H}}</text></view></view></view></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-datetime-picker-view{height:130px;width:270px;cursor:pointer}.uni-datetime-picker-item{height:50px;line-height:50px;text-align:center;font-size:14px}.uni-datetime-picker-btn{margin-top:60px;display:flex;cursor:pointer;flex-direction:row;justify-content:space-between}.uni-datetime-picker-btn-text{font-size:14px;color:#007aff}.uni-datetime-picker-btn-group{display:flex;flex-direction:row}.uni-datetime-picker-cancel{margin-right:30px}.uni-datetime-picker-mask{position:fixed;bottom:0;top:0;left:0;right:0;background-color:rgba(0,0,0,.4);transition-duration:.3s;z-index:998}.uni-datetime-picker-popup{border-radius:8px;padding:30px;width:270px;background-color:#fff;position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);transition-duration:.3s;z-index:999}.uni-datetime-picker-time{color:gray}.uni-datetime-picker-column{height:50px}.uni-datetime-picker-timebox{border:1px solid #E5E5E5;border-radius:5px;padding:7px 10px;box-sizing:border-box;cursor:pointer}.uni-datetime-picker-timebox-pointer{cursor:pointer}.uni-datetime-picker-disabled{opacity:.4}.uni-datetime-picker-text{font-size:14px;line-height:50px}.uni-datetime-picker-sign{position:absolute;top:53px;color:#999}.sign-left{left:86px}.sign-right{right:86px}.sign-center{left:135px}.uni-datetime-picker__container-box{position:relative;display:flex;align-items:center;justify-content:center;margin-top:40px}.time-hide-second{width:180px}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"calendar": "./calendar",
|
||||
"time-picker": "./time-picker",
|
||||
"uni-icons": "../../../uni-icons/components/uni-icons/uni-icons"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="uni-date"><view class="uni-date-editor" bindtap="{{m}}"><block wx:if="{{$slots.d}}"><slot></slot></block><block wx:else><view class="{{['uni-date-editor--x', k && 'uni-date-editor--x__disabled', l && 'uni-date-x--border']}}"><view wx:if="{{a}}" class="uni-date-x uni-date-single"><uni-icons wx:if="{{b}}" class="icon-calendar" u-i="347f72bb-0" bind:__l="__l" u-p="{{b}}"></uni-icons><view class="uni-date__x-input">{{c}}</view></view><view wx:else class="uni-date-x uni-date-range"><uni-icons wx:if="{{d}}" class="icon-calendar" u-i="347f72bb-1" bind:__l="__l" u-p="{{d}}"></uni-icons><view class="uni-date__x-input text-center">{{e}}</view><view class="range-separator">{{f}}</view><view class="uni-date__x-input text-center">{{g}}</view></view><view wx:if="{{h}}" class="uni-date__icon-clear" catchtap="{{j}}"><uni-icons wx:if="{{i}}" u-i="347f72bb-2" bind:__l="__l" u-p="{{i}}"></uni-icons></view></view></block></view><view hidden="{{!n}}" class="uni-date-mask--pc" bindtap="{{o}}"></view><view wx:if="{{p}}" hidden="{{!ar}}" ref="datePicker" class="uni-date-picker__container"><view wx:if="{{q}}" class="uni-date-single--x" style="{{I}}"><view class="uni-popper__arrow"></view><view wx:if="{{r}}" class="uni-date-changed popup-x-header"><input class="uni-date__input text-center" type="text" placeholder="{{s}}" value="{{t}}" bindinput="{{v}}"/><time-picker wx:if="{{B}}" u-s="{{['d']}}" style="width:100%" u-i="347f72bb-3" bind:__l="__l" bindupdateModelValue="{{A}}" u-p="{{B}}"><input class="uni-date__input text-center" type="text" placeholder="{{w}}" disabled="{{x}}" value="{{y}}" bindinput="{{z}}"/></time-picker></view><calendar wx:if="{{E}}" class="r" u-r="pcSingle" bindchange="{{D}}" style="padding:0 8px" u-i="347f72bb-4" bind:__l="__l" u-p="{{E}}"/><view wx:if="{{F}}" class="popup-x-footer"><text class="confirm-text" bindtap="{{H}}">{{G}}</text></view></view><view wx:else class="uni-date-range--x" style="{{aq}}"><view class="uni-popper__arrow"></view><view wx:if="{{J}}" class="popup-x-header uni-date-changed"><view class="popup-x-header--datetime"><input class="uni-date__input uni-date-range__input" type="text" placeholder="{{K}}" value="{{L}}" bindinput="{{M}}"/><time-picker wx:if="{{S}}" u-s="{{['d']}}" u-i="347f72bb-5" bind:__l="__l" bindupdateModelValue="{{R}}" u-p="{{S}}"><input class="uni-date__input uni-date-range__input" type="text" placeholder="{{N}}" disabled="{{O}}" value="{{P}}" bindinput="{{Q}}"/></time-picker></view><uni-icons wx:if="{{T}}" style="line-height:40px" u-i="347f72bb-6" bind:__l="__l" u-p="{{T}}"></uni-icons><view class="popup-x-header--datetime"><input class="uni-date__input uni-date-range__input" type="text" placeholder="{{U}}" value="{{V}}" bindinput="{{W}}"/><time-picker wx:if="{{ac}}" u-s="{{['d']}}" u-i="347f72bb-7" bind:__l="__l" bindupdateModelValue="{{ab}}" u-p="{{ac}}"><input class="uni-date__input uni-date-range__input" type="text" placeholder="{{X}}" disabled="{{Y}}" value="{{Z}}" bindinput="{{aa}}"/></time-picker></view></view><view class="popup-x-body"><calendar wx:if="{{ag}}" class="r" u-r="left" bindchange="{{ae}}" bindfirstEnterCale="{{af}}" style="padding:0 8px" u-i="347f72bb-8" bind:__l="__l" u-p="{{ag}}"/><calendar wx:if="{{ak}}" class="r" u-r="right" bindchange="{{ai}}" bindfirstEnterCale="{{aj}}" style="padding:0 8px;border-left:1px solid #F1F1F1" u-i="347f72bb-9" bind:__l="__l" u-p="{{ak}}"/></view><view wx:if="{{al}}" class="popup-x-footer"><text bindtap="{{an}}">{{am}}</text><text class="confirm-text" bindtap="{{ap}}">{{ao}}</text></view></view></view><calendar wx:if="{{as}}" class="r" u-r="mobile" bindconfirm="{{av}}" bindmaskClose="{{aw}}" bindchange="{{ax}}" u-i="347f72bb-10" bind:__l="__l" u-p="{{ay}}"/></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-date{width:100%;flex:1}.uni-date-x{display:flex;flex-direction:row;align-items:center;justify-content:center;border-radius:4px;background-color:#fff;color:#666;font-size:14px;flex:1}.uni-date-x .icon-calendar{padding-left:3px}.uni-date-x .range-separator{height:35px;line-height:35px}.uni-date-x--border{box-sizing:border-box;border-radius:4px;border:1px solid #e5e5e5}.uni-date-editor--x{display:flex;align-items:center;position:relative}.uni-date-editor--x .uni-date__icon-clear{padding-right:3px;display:flex;align-items:center}.uni-date__x-input{width:auto;height:35px;position:relative;flex:1;line-height:35px;font-size:14px;overflow:hidden}.text-center{text-align:center}.uni-date__input{height:40px;width:100%;line-height:40px;font-size:14px}.uni-date-range__input{text-align:center;max-width:142px}.uni-date-picker__container{position:relative}.uni-date-mask--pc{position:fixed;bottom:0;top:0;left:0;right:0;background-color:rgba(0,0,0,0);transition-duration:.3s;z-index:996}.uni-date-single--x,.uni-date-range--x{background-color:#fff;position:absolute;top:0;z-index:999;border:1px solid #EBEEF5;box-shadow:0 2px 12px rgba(0,0,0,.1);border-radius:4px}.uni-date-editor--x__disabled{opacity:.4;cursor:default}.uni-date-editor--logo{width:16px;height:16px;vertical-align:middle}.popup-x-header{display:flex;flex-direction:row}.popup-x-header--datetime{display:flex;flex-direction:row;flex:1}.popup-x-body{display:flex}.popup-x-footer{padding:0 15px;border-top-color:#f1f1f1;border-top-style:solid;border-top-width:1px;line-height:40px;text-align:right;color:#666}.popup-x-footer text:hover{color:#007aff;cursor:pointer;opacity:.8}.popup-x-footer .confirm-text{margin-left:20px;color:#007aff}.uni-date-changed{text-align:center;color:#333;border-bottom-color:#f1f1f1;border-bottom-style:solid;border-bottom-width:1px}.uni-date-changed--time text{height:50px;line-height:50px}.uni-date-changed .uni-date-changed--time{flex:1}.uni-date-changed--time-date{color:#333;opacity:.6}.mr-50{margin-right:50px}.uni-popper__arrow,.uni-popper__arrow:after{position:absolute;display:block;width:0;height:0;border:6px solid transparent;border-top-width:0}.uni-popper__arrow{filter:drop-shadow(0 2px 12px rgba(0,0,0,.03));top:-6px;left:10%;margin-right:3px;border-bottom-color:#ebeef5}.uni-popper__arrow:after{content:" ";top:1px;margin-left:-6px;border-bottom-color:#fff}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"uni-icons": "../../../uni-icons/components/uni-icons/uni-icons"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="{{['uni-easyinput', ac && 'uni-easyinput-error']}}" style="{{ad}}"><view class="{{['uni-easyinput__content', aa]}}" style="{{ab}}"><uni-icons wx:if="{{a}}" class="content-clear-icon" catchclick="{{b}}" u-i="61595fa3-0" bind:__l="__l" u-p="{{c}}"></uni-icons><slot name="left"></slot><textarea wx:if="{{d}}" class="{{['uni-easyinput__content-textarea', e && 'input-padding']}}" name="{{f}}" value="{{g}}" placeholder="{{h}}" placeholderStyle="{{i}}" disabled="{{j}}" placeholder-class="uni-easyinput__placeholder-class" maxlength="{{k}}" focus="{{l}}" autoHeight="{{m}}" cursor-spacing="{{n}}" adjust-position="{{o}}" bindinput="{{p}}" bindblur="{{q}}" bindfocus="{{r}}" bindconfirm="{{s}}" bindkeyboardheightchange="{{t}}"></textarea><block wx:else><input wx:if="{{r0}}" type="{{v}}" class="uni-easyinput__content-input" style="{{w}}" name="{{x}}" value="{{y}}" password="{{z}}" placeholder="{{A}}" placeholderStyle="{{B}}" placeholder-class="uni-easyinput__placeholder-class" disabled="{{C}}" maxlength="{{D}}" focus="{{E}}" confirmType="{{F}}" cursor-spacing="{{G}}" adjust-position="{{H}}" bindfocus="{{I}}" bindblur="{{J}}" bindinput="{{K}}" bindconfirm="{{L}}" bindkeyboardheightchange="{{M}}"/></block><block wx:if="{{N}}"><uni-icons wx:if="{{O}}" class="{{['content-clear-icon', P && 'is-textarea-icon']}}" bindclick="{{Q}}" u-i="61595fa3-1" bind:__l="__l" u-p="{{R}}"></uni-icons></block><block wx:if="{{S}}"><uni-icons wx:if="{{T}}" class="content-clear-icon" catchclick="{{U}}" u-i="61595fa3-2" bind:__l="__l" u-p="{{V}}"></uni-icons></block><block wx:else><uni-icons wx:if="{{W}}" class="{{['content-clear-icon', X && 'is-textarea-icon']}}" bindclick="{{Y}}" u-i="61595fa3-3" bind:__l="__l" u-p="{{Z}}"></uni-icons></block><slot name="right"></slot></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-easyinput{width:100%;flex:1;position:relative;text-align:left;color:#333;font-size:14px}.uni-easyinput__content{flex:1;width:100%;display:flex;box-sizing:border-box;flex-direction:row;align-items:center;border-color:#fff;transition-property:border-color;transition-duration:.3s}.uni-easyinput__content-input{width:auto;position:relative;overflow:hidden;flex:1;line-height:1;font-size:14px;height:35px}.uni-easyinput__content-input ::-ms-reveal{display:none}.uni-easyinput__content-input ::-ms-clear{display:none}.uni-easyinput__content-input ::-o-clear{display:none}.uni-easyinput__placeholder-class{color:#999;font-size:12px}.is-textarea{align-items:flex-start}.is-textarea-icon{margin-top:5px}.uni-easyinput__content-textarea{position:relative;overflow:hidden;flex:1;line-height:1.5;font-size:14px;margin:6px 6px 6px 0;height:80px;min-height:80px;width:auto}.input-padding{padding-left:10px}.content-clear-icon{padding:0 5px}.label-icon{margin-right:5px;margin-top:-1px}.is-input-border{display:flex;box-sizing:border-box;flex-direction:row;align-items:center;border:1px solid #dcdfe6;border-radius:4px}.uni-error-message{position:absolute;bottom:-17px;left:0;line-height:12px;color:#e43d33;font-size:12px;text-align:left}.uni-error-msg--boeder{position:relative;bottom:0;line-height:22px}.is-input-error-border{border-color:#e43d33}.is-input-error-border .uni-easyinput__placeholder-class{color:#f29e99}.uni-easyinput--border{margin-bottom:0;padding:10px 15px;border-top:1px #eee solid}.uni-easyinput-error{padding-bottom:0}.is-first-border{border:none}.is-disabled{background-color:#f7f6f6;color:#d5d5d5}.is-disabled .uni-easyinput__placeholder-class{color:#d5d5d5;font-size:12px}
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const t=require("./uniicons_file_vue.js"),e=require("../../../../common/vendor.js"),i={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:t.fontData}),computed:{unicode(){let t=this.icons.find((t=>t.font_class===this.type));return t?t.unicode:""},iconSize(){return"number"==typeof(t=this.size)||/^[0-9]*$/g.test(t)?t+"px":t;var t},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")}}};const n=e._export_sfc(i,[["render",function(t,i,n,o,s,r){return{a:e.s(r.styleObj),b:e.n("uniui-"+n.type),c:e.n(n.customPrefix),d:e.n(n.customPrefix?n.type:""),e:e.o$1(((...t)=>r._onClick&&r._onClick(...t)))}}]]);wx.createComponent(n);
|
||||
4
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.json
vendored
Normal file
4
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.json
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<text style="{{a}}" class="{{['uni-icons', b, c, d]}}" bindtap="{{e}}"><slot></slot></text>
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
"use strict";const t=require("../../../../common/vendor.js"),e={name:"UniNumberBox",emits:["change","input","update:modelValue","blur","focus"],props:{value:{type:[Number,String],default:1},modelValue:{type:[Number,String],default:1},min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},background:{type:String,default:"#f5f5f5"},color:{type:String,default:"#333"},disabled:{type:Boolean,default:!1},width:{type:Number,default:40}},data:()=>({inputValue:0}),watch:{value(t){this.inputValue=+t},modelValue(t){this.inputValue=+t}},computed:{widthWithPx(){return this.width+"px"}},created(){1===this.value&&(this.inputValue=+this.modelValue),1===this.modelValue&&(this.inputValue=+this.value)},methods:{_calcValue(t){if(this.disabled)return;const e=this._getDecimalScale();let i=this.inputValue*e,u=this.step*e;if("minus"===t){if(i-=u,i<this.min*e)return;i>this.max*e&&(i=this.max*e)}if("plus"===t){if(i+=u,i>this.max*e)return;i<this.min*e&&(i=this.min*e)}this.inputValue=(i/e).toFixed(String(e).length-1),this.$emit("input",+this.inputValue),this.$emit("update:modelValue",+this.inputValue),this.$emit("change",+this.inputValue)},_getDecimalScale(){let t=1;return~~this.step!==this.step&&(t=Math.pow(10,String(this.step).split(".")[1].length)),t},_onBlur(t){this.$emit("blur",t);let e=t.detail.value;if(isNaN(e))return void(this.inputValue=this.value);e=+e,e>this.max?e=this.max:e<this.min&&(e=this.min);const i=this._getDecimalScale();this.inputValue=e.toFixed(String(i).length-1),this.$emit("input",+this.inputValue),this.$emit("update:modelValue",+this.inputValue),this.$emit("change",+this.inputValue)},_onFocus(t){this.$emit("focus",t)}}};const i=t._export_sfc(e,[["render",function(e,i,u,a,l,s){return{a:l.inputValue<=u.min||u.disabled?1:"",b:u.color,c:t.o$1((t=>s._calcValue("minus"))),d:u.background,e:u.disabled,f:t.o$1(((...t)=>s._onFocus&&s._onFocus(...t))),g:t.o$1(((...t)=>s._onBlur&&s._onBlur(...t))),h:u.step<1?"digit":"number",i:u.background,j:u.color,k:s.widthWithPx,l:l.inputValue,m:t.o$1((t=>l.inputValue=t.detail.value)),n:l.inputValue>=u.max||u.disabled?1:"",o:u.color,p:t.o$1((t=>s._calcValue("plus"))),q:u.background}}]]);wx.createComponent(i);
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="uni-numbox"><view bindtap="{{c}}" class="uni-numbox__minus uni-numbox-btns" style="{{'background:' + d}}"><text class="{{['uni-numbox--text', a && 'uni-numbox--disabled']}}" style="{{'color:' + b}}">-</text></view><block wx:if="{{r0}}"><input disabled="{{e}}" bindfocus="{{f}}" bindblur="{{g}}" class="uni-numbox__value" type="{{h}}" style="{{'background:' + i + ';' + ('color:' + j) + ';' + ('width:' + k)}}" value="{{l}}" bindinput="{{m}}"/></block><view bindtap="{{p}}" class="uni-numbox__plus uni-numbox-btns" style="{{'background:' + q}}"><text class="{{['uni-numbox--text', n && 'uni-numbox--disabled']}}" style="{{'color:' + o}}">+</text></view></view>
|
||||
@@ -0,0 +1 @@
|
||||
.uni-numbox{display:flex;flex-direction:row}.uni-numbox-btns{display:flex;flex-direction:row;align-items:center;justify-content:center;padding:0 8px;background-color:#f5f5f5}.uni-numbox__value{margin:0 2px;background-color:#f5f5f5;width:40px;height:26px;text-align:center;font-size:14px;border-width:0;color:#333}.uni-numbox__minus{border-top-left-radius:2px;border-bottom-left-radius:2px}.uni-numbox__plus{border-top-right-radius:2px;border-bottom-right-radius:2px}.uni-numbox--text{line-height:20px;margin-bottom:2px;font-size:20px;font-weight:300;color:#333}.uni-numbox .uni-numbox--disabled{color:silver!important}
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const t=require("../../../../common/vendor.js"),s={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(t){this.config[t]&&this[this.config[t]](!0)},immediate:!0},isDesktop:{handler:function(t){this.config[t]&&this[this.config[this.type]](!0)},immediate:!0},maskClick:{handler:function(t){this.mkclick=t},immediate:!0},isMaskClick:{handler:function(t){this.mkclick=t},immediate:!0},showPopup(t){}},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 t={backgroundColor:this.bg};return this.borderRadius,t=Object.assign(t,{borderRadius:this.borderRadius}),t},isDesktop(){return this.popupWidth>=500&&this.popupHeight>=500},bg(){return""===this.backgroundColor||"none"===this.backgroundColor?"transparent":this.backgroundColor}},mounted(){(()=>{const{windowWidth:s,windowHeight:i,windowTop:o,safeArea:e,screenHeight:a,safeAreaInsets:r}=t.index.getWindowInfo();this.popupWidth=s,this.popupHeight=i+(o||0),e&&this.safeArea?this.safeAreaInsets=a-e.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(t=!0){},closeMask(){this.maskShow=!1},disableMask(){this.mkclick=!1},clear(t){t.stopPropagation(),this.clearPropagation=!0},open(t){if(this.showPopup)return;t&&-1!==["top","center","bottom","left","right","message","dialog","share"].indexOf(t)||(t=this.type),this.config[t]?(this[this.config[t]](),this.$emit("change",{show:!0,type:t})):console.error("缺少类型:",t)},close(t){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(t){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"},t||(this.showPopup=!0,this.showTrans=!0,this.$nextTick((()=>{this.showPoptrans(),this.messageChild&&"message"===this.type&&this.messageChild.timerClose()})))},bottom(t){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"},t||this.showPoptrans()},center(t){this.popupstyle="center",this.ani=["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"},t||this.showPoptrans()},left(t){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"},t||this.showPoptrans()},right(t){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"},t||this.showPoptrans()},showPoptrans(){this.$nextTick((()=>{this.showPopup=!0,this.showTrans=!0}))}}};if(!Array){t.resolveComponent("uni-transition")()}Math;const i=t._export_sfc(s,[["render",function(s,i,o,e,a,r){return t.e({a:a.showPopup},a.showPopup?t.e({b:a.maskShow},a.maskShow?{c:t.o$1(r.onTap),d:t.p({name:"mask","mode-class":"fade",styles:a.maskClass,duration:a.duration,show:a.showTrans})}:{},{e:t.s(r.getStyles),f:t.n(a.popupstyle),g:t.o$1(((...t)=>r.clear&&r.clear(...t))),h:t.o$1(r.onTap),i:t.p({"mode-class":a.ani,name:"content",styles:a.transClass,duration:a.duration,show:a.showTrans}),j:t.o$1(((...t)=>r.touchstart&&r.touchstart(...t))),k:t.n(a.popupstyle),l:t.n(r.isDesktop?"fixforpc-z-index":"")}):{})}]]);wx.createComponent(i);
|
||||
6
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.json
vendored
Normal file
6
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"uni-transition": "../../../uni-transition/components/uni-transition/uni-transition"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view wx:if="{{a}}" class="{{['uni-popup', k, l]}}"><view bindtouchstart="{{j}}"><uni-transition wx:if="{{b}}" key="1" bindclick="{{c}}" u-i="3309e7c7-0" bind:__l="__l" u-p="{{d}}"/><uni-transition wx:if="{{i}}" u-s="{{['d']}}" key="2" bindclick="{{h}}" u-i="3309e7c7-1" bind:__l="__l" u-p="{{i}}"><view style="{{e}}" class="{{['uni-popup__wrapper', f]}}" bindtap="{{g}}"><slot/></view></uni-transition></view></view>
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/uni-popup/components/uni-popup/uni-popup.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.uni-popup{position:fixed;z-index:99}.uni-popup.top,.uni-popup.left,.uni-popup.right{top:0}.uni-popup .uni-popup__wrapper{display:block;position:relative}.uni-popup .uni-popup__wrapper.left,.uni-popup .uni-popup__wrapper.right{padding-top:0;flex:1}.fixforpc-z-index{z-index:999}.fixforpc-top{top:0}
|
||||
@@ -0,0 +1 @@
|
||||
"use strict";const t=require("../../../../common/vendor.js");class e{constructor(e,i){this.options=e,this.animation=t.index.createAnimation({...e}),this.currentStepAnimates={},this.next=0,this.$=i}_nvuePushAnimates(t,e){let n=this.currentStepAnimates[this.next],s={};if(s=n||{styles:{},config:{}},i.includes(t)){s.styles.transform||(s.styles.transform="");let i="";"rotate"===t&&(i="deg"),s.styles.transform+=`${t}(${e+i}) `}else s.styles[t]=`${e}`;this.currentStepAnimates[this.next]=s}_animateRun(t={},e={}){let i=this.$.$refs.ani.ref;if(i)return new Promise(((n,s)=>{nvueAnimation.transition(i,{styles:t,...e},(t=>{n()}))}))}_nvueNextAnimate(t,e=0,i){let n=t[e];if(n){let{styles:s,config:a}=n;this._animateRun(s,a).then((()=>{e+=1,this._nvueNextAnimate(t,e,i)}))}else this.currentStepAnimates={},"function"==typeof i&&i(),this.isEnd=!0}step(t={}){return this.animation.step(t),this}run(t){this.$.animationData=this.animation.export(),this.$.timer=setTimeout((()=>{"function"==typeof t&&t()}),this.$.durationTime)}}const i=["matrix","matrix3d","rotate","rotate3d","rotateX","rotateY","rotateZ","scale","scale3d","scaleX","scaleY","scaleZ","skew","skewX","skewY","translate","translate3d","translateX","translateY","translateZ"];i.concat(["opacity","backgroundColor"],["width","height","left","right","top","bottom"]).forEach((t=>{e.prototype[t]=function(...e){return this.animation[t](...e),this}})),exports.createAnimation=function(t,i){if(i)return clearTimeout(i.timer),new e(t,i)};
|
||||
@@ -0,0 +1 @@
|
||||
"use strict";const t=require("./createAnimation.js"),i=require("../../../../common/vendor.js"),s={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(t){t?this.open():this.isShow&&this.close()},immediate:!0}},computed:{stylesObject(){let t={...this.styles,"transition-duration":this.duration/1e3+"s"},i="";for(let s in t){i+=this.toLine(s)+":"+t[s]+";"}return i},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(i={}){i.duration&&(this.durationTime=i.duration),this.animation=t.createAnimation(Object.assign(this.config,i),this)},onClick(){this.$emit("click",{detail:this.isShow})},step(t,i={}){if(this.animation){for(let i in t)try{"object"==typeof t[i]?this.animation[i](...t[i]):this.animation[i](t[i])}catch(s){console.error(`方法 ${i} 不存在`)}return this.animation.step(i),this}},run(t){this.animation&&this.animation.run(t)},open(){clearTimeout(this.timer),this.transform="",this.isShow=!0;let{opacity:i,transform:s}=this.styleInit(!1);void 0!==i&&(this.opacity=i),this.transform=s,this.$nextTick((()=>{this.timer=setTimeout((()=>{this.animation=t.createAnimation(this.config,this),this.tranfromInit(!1).step(),this.animation.run((()=>{this.transform="",this.opacity=i||1})),this.$emit("change",{detail:this.isShow})}),20)}))},close(t){this.animation&&this.tranfromInit(!0).step().run((()=>{this.isShow=!1,this.animationData=null,this.animation=null;let{opacity:t,transform:i}=this.styleInit(!1);this.opacity=t||1,this.transform=i,this.$emit("change",{detail:this.isShow})}))},styleInit(t){let i={transform:""},s=(t,s)=>{"fade"===s?i.opacity=this.animationType(t)[s]:i.transform+=this.animationType(t)[s]+" "};return"string"==typeof this.modeClass?s(t,this.modeClass):this.modeClass.forEach((i=>{s(t,i)})),i},tranfromInit(t){let i=(t,i)=>{let s=null;"fade"===i?s=t?0:1:(s=t?"-100%":"0","zoom-in"===i&&(s=t?.8:1),"zoom-out"===i&&(s=t?1.2:1),"slide-right"===i&&(s=t?"100%":"0"),"slide-bottom"===i&&(s=t?"100%":"0")),this.animation[this.animationMode()[i]](s)};return"string"==typeof this.modeClass?i(t,this.modeClass):this.modeClass.forEach((s=>{i(t,s)})),this.animation},animationType:t=>({fade:t?0:1,"slide-top":`translateY(${t?"0":"-100%"})`,"slide-right":`translateX(${t?"0":"100%"})`,"slide-bottom":`translateY(${t?"0":"100%"})`,"slide-left":`translateX(${t?"0":"-100%"})`,"zoom-in":`scaleX(${t?1:.8}) scaleY(${t?1:.8})`,"zoom-out":`scaleX(${t?1:1.2}) scaleY(${t?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:t=>t.replace(/([A-Z])/g,"-$1").toLowerCase()}};const a=i._export_sfc(s,[["render",function(t,s,a,e,o,n){return{a:o.isShow,b:o.animationData,c:i.n(a.customClass),d:i.s(n.transformStyles),e:i.o$1(((...t)=>n.onClick&&n.onClick(...t)))}}]]);wx.createComponent(a);
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view hidden="{{!a}}" ref="ani" animation="{{b}}" class="{{c}}" style="{{d}}" bindtap="{{e}}"><slot></slot></view>
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.js
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const e=require("../../../../common/vendor.js"),t={name:"wht-select",props:{options:{type:Array,default:()=>[]},value:{type:[String,Number],default:""},placeholder:{type:String,default:"请选择"},disabled:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},height:{type:Number,default:40},fontSize:{type:Number,default:14},borderColor:{type:String,default:"#dcdfe6"},borderRadius:{type:Number,default:4},backgroundColor:{type:String,default:"#ffffff"},textColor:{type:String,default:"#606266"},placeholderColor:{type:String,default:"#c0c4cc"},activeColor:{type:String,default:"#409eff"},filterable:{type:Boolean,default:!1},searchPlaceholder:{type:String,default:"请输入搜索内容"}},data:()=>({currentValue:"",isOpen:!1,searchQuery:""}),computed:{currentLabel(){const e=this.options.find((e=>e.value===this.currentValue));return e?e.label:""},filteredOptions(){return this.filterable&&this.searchQuery?this.options.filter((e=>e.label.toLowerCase().includes(this.searchQuery.toLowerCase()))):this.options}},watch:{value:{handler(e){this.currentValue=e},immediate:!0}},methods:{togglePicker(){this.disabled||(this.isOpen=!this.isOpen,this.isOpen||(this.searchQuery=""))},selectOption(e,t){e.disabled||(this.currentValue=e.value,this.searchQuery="",this.$emit("input",e.value),this.$emit("change",e),this.isOpen=!1)},clearValue(e){this.currentValue="",this.searchQuery="",this.$emit("input",""),this.$emit("change",null),this.$emit("clear")},onSearch(){this.$emit("search",this.searchQuery)},handleFocus(){this.disabled||(this.isOpen=!0)}}};const r=e._export_sfc(t,[["render",function(t,r,l,a,o,i){return e.e({a:l.filterable},l.filterable?{b:o.currentValue?i.currentLabel:l.placeholder,c:l.fontSize+"px",d:o.currentValue?l.textColor:l.placeholderColor,e:e.o$1((()=>{})),f:e.o$1([e=>o.searchQuery=e.detail.value,(...e)=>i.onSearch&&i.onSearch(...e)]),g:e.o$1(((...e)=>i.handleFocus&&i.handleFocus(...e))),h:o.searchQuery}:{i:e.t(i.currentLabel||l.placeholder),j:l.fontSize+"px",k:o.currentValue?l.textColor:l.placeholderColor},{l:l.clearable&&o.currentValue&&!l.disabled},l.clearable&&o.currentValue&&!l.disabled?{m:e.o$1(((...e)=>i.clearValue&&i.clearValue(...e)))}:{n:l.placeholderColor},{o:o.isOpen?1:"",p:o.currentValue?"":1,q:l.height+"px",r:l.backgroundColor,s:l.borderColor,t:l.borderRadius+"px",v:e.o$1(((...e)=>i.togglePicker&&i.togglePicker(...e))),w:o.isOpen},o.isOpen?e.e({x:e.o$1(((...e)=>i.togglePicker&&i.togglePicker(...e))),y:i.filteredOptions.length>0},i.filteredOptions.length>0?{z:e.f(i.filteredOptions,((t,r,a)=>({a:e.t(t.label),b:t.value,c:t.disabled?1:"",d:o.currentValue===t.value?1:"",e:t.disabled?l.placeholderColor:l.textColor,f:o.currentValue===t.value?l.activeColor+"20":l.backgroundColor,g:e.o$1((e=>i.selectOption(t,r)),t.value)}))),A:l.fontSize+"px"}:{B:l.fontSize+"px",C:l.placeholderColor},{D:l.backgroundColor,E:l.borderRadius+"px"}):{},{F:l.disabled?1:""})}],["__scopeId","data-v-27db697e"]]);wx.createComponent(r);
|
||||
4
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.json
vendored
Normal file
4
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.json
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxml
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view class="{{['wht-select-wrapper', 'data-v-27db697e', F && 'is-disabled']}}"><view class="{{['wht-select-inner', 'data-v-27db697e', o && 'is-active', p && 'is-placeholder']}}" style="{{'height:' + q + ';' + ('background-color:' + r) + ';' + ('border-color:' + s) + ';' + ('border-radius:' + t)}}" bindtap="{{v}}"><view class="wht-select-value data-v-27db697e"><input wx:if="{{a}}" class="wht-select-input data-v-27db697e" placeholder="{{b}}" style="{{'font-size:' + c + ';' + ('color:' + d)}}" catchtap="{{e}}" bindinput="{{f}}" bindfocus="{{g}}" value="{{h}}"/><text wx:else class="data-v-27db697e" style="{{'font-size:' + j + ';' + ('color:' + k)}}">{{i}}</text></view><view class="wht-select-suffix data-v-27db697e"><view wx:if="{{l}}" class="wht-select-clear data-v-27db697e" catchtap="{{m}}">×</view><view wx:else class="wht-select-arrow data-v-27db697e" style="{{'border-top-color:' + n}}"></view></view></view><view wx:if="{{w}}" class="select-dropdown data-v-27db697e"><view class="select-dropdown-mask data-v-27db697e" catchtap="{{x}}"></view><view class="select-dropdown-content data-v-27db697e" style="{{'background-color:' + D + ';' + ('border-radius:' + E)}}"><block wx:if="{{y}}"><view wx:for="{{z}}" wx:for-item="item" wx:key="b" class="{{['data-v-27db697e', item.c && 'disabled', item.d && 'active']}}" style="{{'font-size:' + A + ';' + ('color:' + item.e) + ';' + ('background-color:' + item.f)}}" catchtap="{{item.g}}">{{item.a}}</view></block><view wx:else class="select-dropdown-empty data-v-27db697e" style="{{'font-size:' + B + ';' + ('color:' + C)}}"> 暂无数据 </view></view></view></view>
|
||||
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxss
vendored
Normal file
1
unpackage/dist/build/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxss
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.wht-select-wrapper.data-v-27db697e{width:100%;position:relative}.wht-select-wrapper .wht-select-inner.data-v-27db697e{position:relative;width:100%;border-width:1px;border-style:solid;transition:all .2s;cursor:pointer}.wht-select-wrapper .wht-select-inner.is-active .wht-select-arrow.data-v-27db697e{transform:rotate(180deg)}.wht-select-wrapper .wht-select-value.data-v-27db697e{position:absolute;left:12px;right:30px;top:50%;transform:translateY(-50%);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;height:100%;display:flex;align-items:center}.wht-select-wrapper .wht-select-suffix.data-v-27db697e{position:absolute;right:8px;top:50%;transform:translateY(-50%);display:flex;align-items:center}.wht-select-wrapper .wht-select-clear.data-v-27db697e{width:16px;height:16px;line-height:16px;text-align:center;border-radius:50%;background-color:#c0c4cc;color:#fff;font-size:12px;cursor:pointer;transition:all .2s}.wht-select-wrapper .wht-select-clear.data-v-27db697e:hover{background-color:#909399}.wht-select-wrapper .wht-select-arrow.data-v-27db697e{width:0;height:0;border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid;transition:transform .2s}.wht-select-wrapper .select-dropdown.data-v-27db697e{position:absolute;top:100%;left:0;width:100%;margin-top:4px;z-index:999}.wht-select-wrapper .select-dropdown-mask.data-v-27db697e{position:fixed;top:0;left:0;right:0;bottom:0;z-index:998}.wht-select-wrapper .select-dropdown-content.data-v-27db697e{position:relative;max-height:240px;border:1px solid #e4e7ed;box-shadow:0 2px 12px rgba(0,0,0,.1);z-index:999;overflow-y:auto}.wht-select-wrapper .select-dropdown-content.data-v-27db697e::-webkit-scrollbar{width:6px}.wht-select-wrapper .select-dropdown-content.data-v-27db697e::-webkit-scrollbar-thumb{background-color:#e4e7ed;border-radius:3px}.wht-select-wrapper .select-dropdown-content>view.data-v-27db697e{padding:0 12px;height:36px;line-height:36px;cursor:pointer}.wht-select-wrapper .select-dropdown-content>view.disabled.data-v-27db697e{cursor:not-allowed}.wht-select-wrapper .select-dropdown-content .select-dropdown-search.data-v-27db697e{padding:8px;border-bottom:1px solid #e4e7ed}.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-27db697e{width:100%;height:32px;padding:0 8px;border:1px solid #dcdfe6;border-radius:4px;font-size:14px}.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-27db697e:focus{border-color:#409eff;outline:none}.wht-select-wrapper .select-dropdown-content .select-dropdown-empty.data-v-27db697e{padding:12px;text-align:center}.wht-select-wrapper .wht-select-input.data-v-27db697e{width:100%;height:100%;background:transparent;border:none;outline:none;padding:0;margin:0;line-height:normal}.wht-select-wrapper .wht-select-input.data-v-27db697e::-webkit-input-placeholder{color:inherit;line-height:normal}.wht-select-wrapper .wht-select-input.data-v-27db697e::placeholder{color:inherit;line-height:normal}
|
||||
Reference in New Issue
Block a user