@tarojs/components 3.3.8 → 3.3.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/taro-audio-core.cjs.entry.js +3 -2
- package/dist/cjs/taro-canvas-core.cjs.entry.js +4 -3
- package/dist/cjs/taro-checkbox-core_2.cjs.entry.js +4 -3
- package/dist/cjs/taro-components.cjs.js +1 -1
- package/dist/cjs/taro-image-core.cjs.entry.js +3 -2
- package/dist/cjs/taro-input-core.cjs.entry.js +4 -3
- package/dist/cjs/taro-picker-core_2.cjs.entry.js +33 -8
- package/dist/cjs/taro-radio-core_2.cjs.entry.js +4 -3
- package/dist/cjs/taro-switch-core.cjs.entry.js +3 -2
- package/dist/cjs/taro-tabbar.cjs.entry.js +2 -4
- package/dist/cjs/taro-textarea-core.cjs.entry.js +4 -3
- package/dist/cjs/taro-video-control_3.cjs.entry.js +4 -3
- package/dist/collection/components/audio/audio.js +19 -2
- package/dist/collection/components/canvas/canvas.js +20 -3
- package/dist/collection/components/checkbox/checkbox.js +20 -3
- package/dist/collection/components/image/image.js +19 -2
- package/dist/collection/components/input/input.js +20 -3
- package/dist/collection/components/picker/picker-group.js +59 -9
- package/dist/collection/components/radio/radio.js +20 -3
- package/dist/collection/components/switch/switch.js +19 -2
- package/dist/collection/components/tabbar/tabbar.js +2 -4
- package/dist/collection/components/textarea/textarea.js +20 -3
- package/dist/collection/components/video/video.js +20 -3
- package/dist/esm/loader.js +1 -1
- package/dist/esm/taro-audio-core.entry.js +3 -2
- package/dist/esm/taro-canvas-core.entry.js +4 -3
- package/dist/esm/taro-checkbox-core_2.entry.js +4 -3
- package/dist/esm/taro-components.js +1 -1
- package/dist/esm/taro-image-core.entry.js +3 -2
- package/dist/esm/taro-input-core.entry.js +4 -3
- package/dist/esm/taro-picker-core_2.entry.js +33 -8
- package/dist/esm/taro-radio-core_2.entry.js +4 -3
- package/dist/esm/taro-switch-core.entry.js +3 -2
- package/dist/esm/taro-tabbar.entry.js +2 -4
- package/dist/esm/taro-textarea-core.entry.js +4 -3
- package/dist/esm/taro-video-control_3.entry.js +4 -3
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/taro-audio-core.entry.js +1 -1
- package/dist/esm-es5/taro-canvas-core.entry.js +1 -1
- package/dist/esm-es5/taro-checkbox-core_2.entry.js +1 -1
- package/dist/esm-es5/taro-components.js +1 -1
- package/dist/esm-es5/taro-image-core.entry.js +1 -1
- package/dist/esm-es5/taro-input-core.entry.js +1 -1
- package/dist/esm-es5/taro-picker-core_2.entry.js +1 -1
- package/dist/esm-es5/taro-radio-core_2.entry.js +1 -1
- package/dist/esm-es5/taro-switch-core.entry.js +1 -1
- package/dist/esm-es5/taro-tabbar.entry.js +1 -1
- package/dist/esm-es5/taro-textarea-core.entry.js +1 -1
- package/dist/esm-es5/taro-video-control_3.entry.js +1 -1
- package/dist/taro-components/p-239bf0ca.system.entry.js +1 -0
- package/dist/taro-components/p-3eb31172.system.entry.js +1 -0
- package/dist/taro-components/p-4afe24d7.entry.js +1 -0
- package/dist/taro-components/p-593ee811.entry.js +1 -0
- package/dist/taro-components/p-6287057a.entry.js +1 -0
- package/dist/taro-components/p-7911ccd6.system.entry.js +1 -0
- package/dist/taro-components/{p-671a39e4.system.entry.js → p-8031d6b5.system.entry.js} +1 -1
- package/dist/taro-components/{p-3bda72b4.entry.js → p-80f50da7.entry.js} +1 -1
- package/dist/taro-components/p-82185d54.system.entry.js +1 -0
- package/dist/taro-components/p-8c43da73.system.entry.js +1 -0
- package/dist/taro-components/p-8f7b75f6.system.entry.js +1 -0
- package/dist/taro-components/p-906c3a0a.entry.js +1 -0
- package/dist/taro-components/p-945fa1a0.entry.js +1 -0
- package/dist/taro-components/p-96f1e9e7.entry.js +1 -0
- package/dist/taro-components/p-970ed6da.system.entry.js +1 -0
- package/dist/taro-components/p-9fe2309f.entry.js +1 -0
- package/dist/taro-components/p-a079321f.system.entry.js +1 -0
- package/dist/taro-components/{p-671dcbc6.system.entry.js → p-a74d5aa5.system.entry.js} +1 -1
- package/dist/taro-components/p-af393b0b.entry.js +1 -0
- package/dist/taro-components/p-b5d2597b.system.js +1 -1
- package/dist/taro-components/p-c2810ece.entry.js +1 -0
- package/dist/taro-components/p-c9380fa6.entry.js +1 -0
- package/dist/taro-components/p-e256974b.system.entry.js +1 -0
- package/dist/taro-components/taro-components.esm.js +1 -1
- package/dist/types/components/audio/audio.d.ts +1 -0
- package/dist/types/components/canvas/canvas.d.ts +1 -0
- package/dist/types/components/checkbox/checkbox.d.ts +1 -0
- package/dist/types/components/image/image.d.ts +1 -0
- package/dist/types/components/input/input.d.ts +1 -0
- package/dist/types/components/picker/picker-group.d.ts +7 -0
- package/dist/types/components/radio/radio.d.ts +1 -0
- package/dist/types/components/switch/switch.d.ts +1 -0
- package/dist/types/components/textarea/textarea.d.ts +1 -0
- package/dist/types/components.d.ts +18 -0
- package/dist-h5/react/utils/reactify-wc.js +1 -0
- package/package.json +4 -3
- package/types/Camera.d.ts +7 -7
- package/types/LivePusher.d.ts +51 -3
- package/types/Map.d.ts +11 -1
- package/types/PickerView.d.ts +7 -7
- package/types/Swiper.d.ts +2 -0
- package/dist/taro-components/p-1342e810.system.entry.js +0 -1
- package/dist/taro-components/p-153b839d.system.entry.js +0 -1
- package/dist/taro-components/p-1925bbdb.entry.js +0 -1
- package/dist/taro-components/p-1f44e8ef.system.entry.js +0 -1
- package/dist/taro-components/p-2a504632.system.entry.js +0 -1
- package/dist/taro-components/p-40144442.entry.js +0 -1
- package/dist/taro-components/p-45af8e04.entry.js +0 -1
- package/dist/taro-components/p-50e44e3f.system.entry.js +0 -1
- package/dist/taro-components/p-576b86cb.entry.js +0 -1
- package/dist/taro-components/p-68781eab.entry.js +0 -1
- package/dist/taro-components/p-a5df0ffb.system.entry.js +0 -1
- package/dist/taro-components/p-a9608c73.system.entry.js +0 -1
- package/dist/taro-components/p-b9aa76c5.entry.js +0 -1
- package/dist/taro-components/p-d36e9c1c.entry.js +0 -1
- package/dist/taro-components/p-d8e323fe.entry.js +0 -1
- package/dist/taro-components/p-e05be870.entry.js +0 -1
- package/dist/taro-components/p-ee8eec25.system.entry.js +0 -1
- package/dist/taro-components/p-f23386d1.entry.js +0 -1
- package/dist/taro-components/p-fd44be7c.system.entry.js +0 -1
package/types/Map.d.ts
CHANGED
|
@@ -19,6 +19,16 @@ interface MapProps extends StandardProps {
|
|
|
19
19
|
* @alipay 取值范围为5-18
|
|
20
20
|
*/
|
|
21
21
|
scale?: number
|
|
22
|
+
/** 最小缩放级别3-20
|
|
23
|
+
* @default 3
|
|
24
|
+
* @supported weapp
|
|
25
|
+
*/
|
|
26
|
+
minScale?: number
|
|
27
|
+
/** 最大缩放级别3-20
|
|
28
|
+
* @default 20
|
|
29
|
+
* @supported weapp
|
|
30
|
+
*/
|
|
31
|
+
maxScale?: number
|
|
22
32
|
|
|
23
33
|
/** 标记点
|
|
24
34
|
* @supported weapp, swan, alipay
|
|
@@ -302,7 +312,7 @@ declare namespace MapProps {
|
|
|
302
312
|
}
|
|
303
313
|
|
|
304
314
|
/** marker 上的自定义气泡 customCallout
|
|
305
|
-
*
|
|
315
|
+
*
|
|
306
316
|
* `customCallout` 存在时将忽略 `callout` 与 `title` 属性。自定义气泡采用采用 `cover-view` 定制,灵活度更高。
|
|
307
317
|
*/
|
|
308
318
|
interface customCallout {
|
package/types/PickerView.d.ts
CHANGED
|
@@ -4,12 +4,12 @@ import { StandardProps, CommonEventFunction } from './common'
|
|
|
4
4
|
interface PickerViewProps extends StandardProps {
|
|
5
5
|
|
|
6
6
|
/** 数组中的数字依次表示 picker-view 内的 picker-view-column 选择的第几项(下标从 0 开始),数字大于 picker-view-column 可选项长度时,选择最后一项。
|
|
7
|
-
* @supported weapp, swan, alipay, tt
|
|
7
|
+
* @supported weapp, swan, alipay, tt, rn
|
|
8
8
|
*/
|
|
9
9
|
value?: number[]
|
|
10
10
|
|
|
11
11
|
/** 设置选择器中间选中框的样式
|
|
12
|
-
* @supported weapp, swan, alipay, tt
|
|
12
|
+
* @supported weapp, swan, alipay, tt, rn
|
|
13
13
|
*/
|
|
14
14
|
indicatorStyle?: string
|
|
15
15
|
|
|
@@ -29,7 +29,7 @@ interface PickerViewProps extends StandardProps {
|
|
|
29
29
|
maskClass?: string
|
|
30
30
|
|
|
31
31
|
/** 当滚动选择,value 改变时触发 change 事件,event.detail = {value: value};value为数组,表示 picker-view 内的 picker-view-column 当前选择的是第几项(下标从 0 开始)
|
|
32
|
-
* @supported weapp, swan, alipay, tt
|
|
32
|
+
* @supported weapp, swan, alipay, tt, rn
|
|
33
33
|
*/
|
|
34
34
|
onChange?: CommonEventFunction<PickerViewProps.onChangeEventDetail>
|
|
35
35
|
|
|
@@ -57,7 +57,7 @@ declare namespace PickerViewProps {
|
|
|
57
57
|
* @example
|
|
58
58
|
* ```tsx
|
|
59
59
|
* export default class Picks extends Component {
|
|
60
|
-
*
|
|
60
|
+
*
|
|
61
61
|
* constructor () {
|
|
62
62
|
* super(...arguments)
|
|
63
63
|
* const date = new Date()
|
|
@@ -83,7 +83,7 @@ declare namespace PickerViewProps {
|
|
|
83
83
|
* value: [9999, 1, 1]
|
|
84
84
|
* }
|
|
85
85
|
* }
|
|
86
|
-
*
|
|
86
|
+
*
|
|
87
87
|
* onChange = e => {
|
|
88
88
|
* const val = e.detail.value
|
|
89
89
|
* this.setState({
|
|
@@ -93,7 +93,7 @@ declare namespace PickerViewProps {
|
|
|
93
93
|
* value: val
|
|
94
94
|
* })
|
|
95
95
|
* }
|
|
96
|
-
*
|
|
96
|
+
*
|
|
97
97
|
* render() {
|
|
98
98
|
* return (
|
|
99
99
|
* <View>
|
|
@@ -125,7 +125,7 @@ declare namespace PickerViewProps {
|
|
|
125
125
|
* )
|
|
126
126
|
* }
|
|
127
127
|
* }
|
|
128
|
-
*
|
|
128
|
+
*
|
|
129
129
|
* ```
|
|
130
130
|
* @see https://developers.weixin.qq.com/miniprogram/dev/component/picker-view.html
|
|
131
131
|
*/
|
package/types/Swiper.d.ts
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(t){"use strict";var e,n,i,o;return{setters:[function(t){e=t.r;n=t.c;i=t.h;o=t.g}],execute:function(){var s="taro-input-core{display:block}input{display:block;height:1.4rem;text-align:inherit;text-overflow:clip;overflow:hidden;white-space:nowrap}";function u(t,e,n){if(e==="search")t="search";if(n)t="password";if(typeof t==="undefined"){return"text"}if(!t){throw new Error("unexpected type")}if(t==="digit")t="number";return t}function a(t){return t!==null&&t!==void 0?t:""}var r=t("taro_input_core",function(){function t(t){var i=this;e(this,t);this.onInput=n(this,"input",7);this.onFocus=n(this,"focus",7);this.onBlur=n(this,"blur",7);this.onConfirm=n(this,"confirm",7);this.onChange=n(this,"change",7);this.onKeyDown=n(this,"keydown",7);this.isOnComposition=false;this.onInputExcuted=false;this.password=false;this.disabled=false;this.maxlength=140;this.autoFocus=false;this.confirmType="done";this.handleInput=function(t){t.stopPropagation();var e=i,n=e.type,o=e.maxlength,s=e.confirmType,a=e.password;if(!i.isOnComposition&&!i.onInputExcuted){var r=t.target.value;var l=u(n,s,a);i.onInputExcuted=true;if(l==="number"&&r&&o<=r.length){r=r.substring(0,o);t.target.value=r}i._value=r;i.onInput.emit({value:r,cursor:r.length})}};this.handleFocus=function(t){i.onInputExcuted=false;i.onFocus.emit({value:t.target.value})};this.handleBlur=function(t){i.onBlur.emit({value:t.target.value})};this.handleChange=function(t){t.stopPropagation();i.onChange.emit({value:t.target.value})};this.handleKeyDown=function(t){var e=t.target.value;i.onInputExcuted=false;t.stopPropagation();i.onKeyDown.emit({value:e});t.keyCode===13&&i.onConfirm.emit({value:e})};this.handleComposition=function(t){if(!(t.target instanceof HTMLInputElement))return;if(t.type==="compositionend"){i.isOnComposition=false;i.onInput.emit({value:t.target.value})}else{i.isOnComposition=true}}}t.prototype.watchHandler=function(t,e){if(t!==e){this._value=t}};t.prototype.watchFocus=function(t,e){if(!e&&t){this.inputRef.focus()}};t.prototype.componentWillLoad=function(){this._value=this.value};t.prototype.componentDidLoad=function(){var t=this;if(this.type==="file"){this.fileListener=function(){t.onInput.emit()};this.inputRef.addEventListener("change",this.fileListener)}else{this.inputRef.addEventListener("compositionstart",this.handleComposition);this.inputRef.addEventListener("compositionend",this.handleComposition)}Object.defineProperty(this.el,"value",{get:function(){return t.inputRef.value},set:function(e){t._value=e},configurable:true})};t.prototype.disconnectedCallback=function(){if(this.type==="file"){this.inputRef.removeEventListener("change",this.fileListener)}};t.prototype.render=function(){var t=this;var e=this,n=e._value,o=e.type,s=e.password,r=e.placeholder,l=e.disabled,h=e.maxlength,c=e.autoFocus,p=e.confirmType,f=e.name;return i("input",{ref:function(e){t.inputRef=e;c&&(e===null||e===void 0?void 0:e.focus())},class:"weui-input",value:a(n),type:u(o,p,s),placeholder:r,disabled:l,maxlength:h,autofocus:c,name:f,onInput:this.handleInput,onFocus:this.handleFocus,onBlur:this.handleBlur,onChange:this.handleChange,onKeyDown:this.handleKeyDown})};Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{value:["watchHandler"],autoFocus:["watchFocus"]}},enumerable:false,configurable:true});return t}());r.style=s}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js","./p-bd00f506.system.js"],(function(e){"use strict";var t,a,r,o,n,i;return{setters:[function(e){t=e.h;a=e.r;r=e.c;o=e.H;n=e.g},function(e){i=e.c}],execute:function(){function s(e){return e.charAt(0)==="/"}function l(e,t){for(var a=t,r=a+1,o=e.length;r<o;a+=1,r+=1){e[a]=e[r]}e.pop()}function b(e,t){if(t===undefined)t="";var a=e&&e.split("/")||[];var r=t&&t.split("/")||[];var o=e&&s(e);var n=t&&s(t);var i=o||n;if(e&&s(e)){r=a}else if(a.length){r.pop();r=r.concat(a)}if(!r.length)return"/";var b;if(r.length){var d=r[r.length-1];b=d==="."||d===".."||d===""}else{b=false}var h=0;for(var f=r.length;f>=0;f--){var u=r[f];if(u==="."){l(r,f)}else if(u===".."){l(r,f);h++}else if(h){l(r,f);h--}}if(!i)for(;h--;h)r.unshift("..");if(i&&r[0]!==""&&(!r[0]||!s(r[0])))r.unshift("");var c=r.join("/");if(b&&c.substr(-1)!=="/")c+="/";return c}var d=function(e){var t=e||"";var a;var r={path:null,query:null,fragment:null};a=t.indexOf("#");if(a>-1){r.fragment=t.substring(a+1);t=t.substring(0,a)}a=t.indexOf("?");if(a>-1){r.query=t.substring(a+1);t=t.substring(0,a)}r.path=t;return r};var h=function(e){var a=e.index,r=e.isSelected,o=r===void 0?false:r,n=e.textColor,s=e.iconPath,l=e.badgeText,b=e.showRedDot,d=b===void 0?false:b,h=e.text,f=e.onSelect;var u=i("weui-tabbar__item",{"weui-bar__item_on":o});var c={position:"absolute",top:"-2px",right:"-13px"};var v={position:"absolute",top:"0",right:"-6px"};function g(){f(a)}return t("a",{key:a,href:"javascript:;",class:u,onClick:g},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:s,alt:"",class:"weui-tabbar__icon"}),!!l&&t("span",{class:"weui-badge taro-tabbar-badge",style:c},l),d&&t("span",{class:"weui-badge weui-badge_dot",style:v})),t("p",{class:"weui-tabbar__label",style:{color:n}},h))};var f="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;height:100%;-ms-flex-direction:column;flex-direction:column;overflow:hidden}.taro-tabbar__panel{-ms-flex:1;flex:1;position:relative;overflow:auto;-webkit-overflow-scrolling:touch}.taro-tabbar__tabbar{position:relative;height:50px;width:100%;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var u=require("@tarojs/taro");var c=function(e){return e[0]==="/"?e:"/"+e};var v=function(e,t){return new RegExp("^"+t+"(\\/|\\?|#|$)","i").test(e)};var g=function(e,t){return v(e,t)?e.substr(t.length):e};var p=0;var _=1;var T=2;var m="taro-tabbar__tabbar";var B="taro-tabbar__tabbar-hide";var w="taro-tabbar__tabbar-slideout";var x=e("taro_tabbar",function(){function e(e){var t=this;a(this,e);this.onLongPress=r(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.selectedIndex=-1;this.status=p;this.getOriginUrl=function(e){var a=t.customRoutes.filter((function(t){var a=t[1];var r=d(a).path;var o=d(e).path;return r===o}));return a.length?a[0][0]:e};this.getSelectedIndex=function(e){var a=-1;t.list.forEach((function(t,r){var o=t.pagePath;var n=d(e).path;var i=d(o).path;if(n===i){a=r}}));return a};this.switchTab=function(e){t.selectedIndex=e;u.navigateTo({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var a=e.url,r=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=b(a,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);r({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'+i+'" is not found'})}};this.routerChangeHandler=function(e){var a;var r;if(e){a=e.toLocation}if(a&&a.path){var o=c(a.path);r=o==="/"?t.homePage:o}else{r=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(r))};this.setTabBarBadgeHandler=function(e){var a=e.index,r=e.text,o=e.errorHandler;var n=t.list;if(a in n){t.list[a].showRedDot=false;t.list[a].badgeText=r}else{o({errMsg:"setTabBarBadge:fail tabbar item not found"})}};this.removeTabBarBadgeHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=t.list;if(a in n){t.list[a].badgeText=null;t.list[a].badgeText=null;r({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}};this.showTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=t.list;if(a in n){n[a].badgeText=null;n[a].showRedDot=true;r({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}};this.hideTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=t.list;if(a in n){n[a].showRedDot=false;r({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}};this.showTabBarHandler=function(e){var a=e.successHandler;t.status=p;a({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var a=e.animation,r=e.successHandler;t.status=a?T:_;r({errMsg:"hideTabBar:ok"})};var o=this.conf.list;var n=this.conf.customRoutes;if(Object.prototype.toString.call(o)!=="[object Array]"||o.length<2||o.length>5){throw new Error("tabBar 配置错误")}this.homePage=c(this.conf.homePage);for(var i in n){this.customRoutes.push([i,n[i]])}o.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=o}e.prototype.getCurrentUrl=function(){var e=this.conf.mode;var t=this.conf.basename||"/";var a;if(e==="hash"){var r=window.location.href;var o=r.indexOf("#");a=o===-1?"":r.substring(o+1)}else{a=location.pathname}var n=c(g(a,t));return n==="/"?this.homePage:n};e.prototype.bindEvent=function(){u.eventCenter.on("__taroRouterChange",this.routerChangeHandler);u.eventCenter.on("__taroSwitchTab",this.switchTabHandler);u.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);u.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);u.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);u.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);u.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);u.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler)};e.prototype.removeEvent=function(){u.eventCenter.off("__taroRouterChange",this.routerChangeHandler);u.eventCenter.off("__taroSwitchTab",this.switchTabHandler);u.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);u.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);u.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);u.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);u.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);u.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,a;var r=this;var n=this,s=n.conf,l=n.tabbarPos,b=l===void 0?"bottom":l;var d=this.status;var f=i("weui-tabbar",(e={},e["taro-tabbar__border-"+(s.borderStyle||"black")]=true,e));var u=this.selectedIndex===-1||d===_;var c=d===T;return t(o,{class:i(m,m+"-"+b,(a={},a[B]=u,a[w]=c,a))},t("div",{class:f,style:{backgroundColor:s.backgroundColor||""}},this.list.map((function(e,a){var o=r.selectedIndex===a;var n;var i;if(o){n=s.selectedColor;i=e.selectedIconPath}else{n=s.color||"";i=e.iconPath}return t(h,{index:a,onSelect:r.switchTab.bind(r),isSelected:o,textColor:n,iconPath:i,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return n(this)},enumerable:false,configurable:true});return e}());x.style=f}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h as t,r as a,c as r,H as e,g as o}from"./p-30c0639e.js";import{c as s}from"./p-625158f0.js";function i(t){return"/"===t.charAt(0)}function b(t,a){for(var r=a,e=r+1,o=t.length;e<o;r+=1,e+=1)t[r]=t[e];t.pop()}const n=t=>{let a,r=t||"";const e={path:null,query:null,fragment:null};return a=r.indexOf("#"),a>-1&&(e.fragment=r.substring(a+1),r=r.substring(0,a)),a=r.indexOf("?"),a>-1&&(e.query=r.substring(a+1),r=r.substring(0,a)),e.path=r,e},h=({index:a,isSelected:r=!1,textColor:e,iconPath:o,badgeText:i,showRedDot:b=!1,text:n,onSelect:h})=>{const l=s("weui-tabbar__item",{"weui-bar__item_on":r});return t("a",{key:a,href:"javascript:;",class:l,onClick:function(){h(a)}},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:o,alt:"",class:"weui-tabbar__icon"}),!!i&&t("span",{class:"weui-badge taro-tabbar-badge",style:{position:"absolute",top:"-2px",right:"-13px"}},i),b&&t("span",{class:"weui-badge weui-badge_dot",style:{position:"absolute",top:"0",right:"-6px"}})),t("p",{class:"weui-tabbar__label",style:{color:e}},n))},l=require("@tarojs/taro"),d=t=>"/"===t[0]?t:`/${t}`,c=class{constructor(t){a(this,t),this.onLongPress=r(this,"longpress",7),this.homePage="",this.customRoutes=[],this.tabbarPos="bottom",this.selectedIndex=-1,this.status=0,this.getOriginUrl=t=>{const a=this.customRoutes.filter((([,a])=>n(a).path===n(t).path));return a.length?a[0][0]:t},this.getSelectedIndex=t=>{let a=-1;return this.list.forEach((({pagePath:r},e)=>{n(t).path===n(r).path&&(a=e)})),a},this.switchTab=t=>{this.selectedIndex=t,l.navigateTo({url:this.list[t].pagePath})},this.switchTabHandler=({url:t,successHandler:a,errorHandler:r})=>{const e=function(t,a){void 0===a&&(a="");var r,e=t&&t.split("/")||[],o=a&&a.split("/")||[],s=t&&i(t),n=a&&i(a),h=s||n;if(t&&i(t)?o=e:e.length&&(o.pop(),o=o.concat(e)),!o.length)return"/";if(o.length){var l=o[o.length-1];r="."===l||".."===l||""===l}else r=!1;for(var d=0,c=o.length;c>=0;c--){var _=o[c];"."===_?b(o,c):".."===_?(b(o,c),d++):d&&(b(o,c),d--)}if(!h)for(;d--;d)o.unshift("..");!h||""===o[0]||o[0]&&i(o[0])||o.unshift("");var u=o.join("/");return r&&"/"!==u.substr(-1)&&(u+="/"),u}(t,this.getOriginUrl(this.getCurrentUrl()||this.homePage)),o=this.getSelectedIndex(e);o>-1?(this.switchTab(o),a({errMsg:"switchTab:ok"})):r({errMsg:`switchTab:fail page "${e}" is not found`})},this.routerChangeHandler=t=>{let a,r;if(t&&(a=t.toLocation),a&&a.path){const t=d(a.path);r="/"===t?this.homePage:t}else r=this.getCurrentUrl();this.selectedIndex=this.getSelectedIndex(this.getOriginUrl(r))},this.setTabBarBadgeHandler=({index:t,text:a,errorHandler:r})=>{t in this.list?(this.list[t].showRedDot=!1,this.list[t].badgeText=a):r({errMsg:"setTabBarBadge:fail tabbar item not found"})},this.removeTabBarBadgeHandler=({index:t,successHandler:a,errorHandler:r})=>{t in this.list?(this.list[t].badgeText=null,this.list[t].badgeText=null,a({errMsg:"removeTabBarBadge:ok"})):r({errMsg:"removeTabBarBadge:fail tabbar item not found"})},this.showTabBarRedDotHandler=({index:t,successHandler:a,errorHandler:r})=>{const e=this.list;t in e?(e[t].badgeText=null,e[t].showRedDot=!0,a({errMsg:"showTabBarRedDot:ok"})):r({errMsg:"showTabBarRedDot:fail tabbar item not found"})},this.hideTabBarRedDotHandler=({index:t,successHandler:a,errorHandler:r})=>{const e=this.list;t in e?(e[t].showRedDot=!1,a({errMsg:"hideTabBarRedDot:ok"})):r({errMsg:"hideTabBarRedDot:fail tabbar item not found"})},this.showTabBarHandler=({successHandler:t})=>{this.status=0,t({errMsg:"showTabBar:ok"})},this.hideTabBarHandler=({animation:t,successHandler:a})=>{this.status=t?2:1,a({errMsg:"hideTabBar:ok"})};const e=this.conf.list,o=this.conf.customRoutes;if("[object Array]"!==Object.prototype.toString.call(e)||e.length<2||e.length>5)throw new Error("tabBar 配置错误");this.homePage=d(this.conf.homePage);for(const t in o)this.customRoutes.push([t,o[t]]);e.forEach((t=>{0!==t.pagePath.indexOf("/")&&(t.pagePath="/"+t.pagePath)})),this.list=e}getCurrentUrl(){const t=this.conf.basename||"/";let a;if("hash"===this.conf.mode){const t=window.location.href,r=t.indexOf("#");a=-1===r?"":t.substring(r+1)}else a=location.pathname;const r=d(((t,a)=>new RegExp("^"+a+"(\\/|\\?|#|$)","i").test(t))(e=a,o=t)?e.substr(o.length):e);var e,o;return"/"===r?this.homePage:r}bindEvent(){l.eventCenter.on("__taroRouterChange",this.routerChangeHandler),l.eventCenter.on("__taroSwitchTab",this.switchTabHandler),l.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler),l.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler),l.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler),l.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler),l.eventCenter.on("__taroShowTabBar",this.showTabBarHandler),l.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler)}removeEvent(){l.eventCenter.off("__taroRouterChange",this.routerChangeHandler),l.eventCenter.off("__taroSwitchTab",this.switchTabHandler),l.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler),l.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler),l.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler),l.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler),l.eventCenter.off("__taroShowTabBar",this.showTabBarHandler),l.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler)}componentDidLoad(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom",this.bindEvent(),this.routerChangeHandler()}disconnectedCallback(){this.removeEvent()}render(){const{conf:a,tabbarPos:r="bottom"}=this,o=this.status,i=s("weui-tabbar",{[`taro-tabbar__border-${a.borderStyle||"black"}`]:!0});return t(e,{class:s("taro-tabbar__tabbar",`taro-tabbar__tabbar-${r}`,{"taro-tabbar__tabbar-hide":-1===this.selectedIndex||1===o,"taro-tabbar__tabbar-slideout":2===o})},t("div",{class:i,style:{backgroundColor:a.backgroundColor||""}},this.list.map(((r,e)=>{const o=this.selectedIndex===e;let s,i;return o?(s=a.selectedColor,i=r.selectedIconPath):(s=a.color||"",i=r.iconPath),t(h,{index:e,onSelect:this.switchTab.bind(this),isSelected:o,textColor:s,iconPath:i,text:r.text,badgeText:r.badgeText,showRedDot:r.showRedDot})}))))}get tabbar(){return o(this)}};c.style="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;height:100%;-ms-flex-direction:column;flex-direction:column;overflow:hidden}.taro-tabbar__panel{-ms-flex:1;flex:1;position:relative;overflow:auto;-webkit-overflow-scrolling:touch}.taro-tabbar__tabbar{position:relative;height:50px;width:100%;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";export{c as taro_tabbar}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var __spreadArrays=this&&this.__spreadArrays||function(){for(var e=0,t=0,i=arguments.length;t<i;t++)e+=arguments[t].length;for(var r=Array(e),a=0,t=0;t<i;t++)for(var n=arguments[t],u=0,o=n.length;u<o;u++,a++)r[a]=n[u];return r};System.register(["./p-cf496b3b.system.js","./p-bd00f506.system.js"],(function(e){"use strict";var t,i,r,a,n,u;return{setters:[function(e){t=e.r;i=e.c;r=e.h;a=e.H;n=e.g},function(e){u=e.c}],execute:function(){function o(e,t){var i=[];for(var r=e;r<=t;r++){i.push(""+(r<10?"0":"")+r)}return i}var s=__spreadArrays(["20","21","22","23"],o(0,23),["00","01","02","03"]);var h=__spreadArrays(["56","57","58","59"],o(0,59),["00","01","02","03"]);function l(e,t){if(!isNaN(+e)&&e>=0&&e<t.length)return true;return false}function c(e){if(!/^\d{1,2}:\d{1,2}$/.test(e))return false;var t=e.split(":").map((function(e){return+e}));if(t[0]<0||t[0]>23)return false;if(t[1]<0||t[1]>59)return false;return true}function d(e,t){var i=e.split(":").map((function(e){return+e}));var r=t.split(":").map((function(e){return+e}));if(i[0]<r[0])return true;if(i[0]===r[0]&&i[1]<=r[1])return true;return false}function f(e){if(!e)return false;var t=new Date(e.replace(/-/g,"/"));return isNaN(t.getMonth())?false:t}function p(e,t){if(t===4||t===6||t===9||t===11)return 30;if(t===2){if(e%4===0&&e%100!==0||e%400===0)return 29;else return 28}return 31}function v(e){var t;if(Array.isArray(e)){t=e.map((function(e){return String(e)}))}else{t=e}return t}function g(e,t){var i=[];for(var r=e;r<=t;r++){i.push(r)}return i}function m(e,t){return g(e,t)}function y(e,t,i){var r=1;var a=12;if(e.getFullYear()===i){r=e.getMonth()+1}if(t.getFullYear()===i){a=t.getMonth()+1}return g(r,a)}function k(e,t,i,r){var a=1;var n=p(i,r);if(e.getFullYear()===i&&e.getMonth()+1===r){a=e.getDate()}if(t.getFullYear()===i&&t.getMonth()+1===r){n=t.getDate()}return g(a,n)}var _=102;var w=34;var C=w*7;var D=".weui-picker,.weui-picker__hd{font-size:12px}";var x=e("taro_picker_core",function(){function e(e){var a=this;t(this,e);this.onChange=i(this,"change",7);this.onColumnChange=i(this,"columnchange",7);this.onCancel=i(this,"cancel",7);this.index=[];this.mode="selector";this.disabled=false;this.range=[];this.start="";this.end="";this.fields="day";this.name="";this.pickerValue=[];this.height=[];this.hidden=true;this.fadeOut=false;this.isWillLoadCalled=false;this.showPicker=function(){if(a.disabled)return;a.height=a.getHeightByIndex();a.hidden=false};this.getHeightByIndex=function(){var e=a.index.map((function(e){var t=0;if(a.mode==="time"){t=w*4}return _-w*e-t}));return e};this.hidePicker=function(){a.fadeOut=true;setTimeout((function(){a.hidden=true;a.fadeOut=false}),350)};this.handleChange=function(){a.hidePicker();a.index=a.height.map((function(e){return(_-e)/w}));var e=a.index.length&&a.mode!=="selector"?a.index:a.index[0];if(a.mode==="time"){var t=[s.slice(),h.slice()];var i=a.index.map((function(e,i){return t[i][e]}));a.index=i.map((function(e){return parseInt(e)}));e=i.join(":")}if(a.mode==="date"){var r=a.pickerDate,n=r._start,u=r._end,o=r._updateValue;var l=o[0];var c=o[1];var d=m(n.getFullYear(),u.getFullYear());var f=y(n,u,l);var p=k(n,u,l,c);var v=d[a.index[0]];var g=f[a.index[1]];var C=p[a.index[2]];if(a.fields==="year"){e=[v]}else if(a.fields==="month"){e=[v,g]}else{e=[v,g,C]}e=e.map((function(e){return e<10?"0"+e:e})).join("-")}a.pickerValue=e;a.onChange.emit({value:e})};this.handleCancel=function(){a.hidePicker();a.onCancel.emit()};this.updateHeight=function(e,t,i){if(i===void 0){i=false}var r=__spreadArrays(a.height);r[t]=e;a.height=r;if(i){var n=a,u=n.start,o=n.end;if(!c(u))u="00:00";if(!c(o))o="23:59";if(!d(u,o))return;var l=[s.slice(),h.slice()];var f=a.height.map((function(e){return(_-e)/w}));var p=f.map((function(e,t){return l[t][e]})).join(":");if(!d(u,p)){var v=u.split(":").map((function(e){return _-w*(+e+4)}));requestAnimationFrame((function(){return a.height=v}))}else if(!d(p,o)){var g=o.split(":").map((function(e){return _-w*(+e+4)}));requestAnimationFrame((function(){return a.height=g}))}}};this.handleColumnChange=function(e,t){a.onColumnChange.emit({column:Number(t),value:(_-e)/w})};this.updateDay=function(e,t){var i=a.pickerDate,r=i._start,n=i._end,u=i._updateValue;u[t]=e;var o=u[0];var s=u[1];var h=u[2];if(t===0){var l=y(r,n,o);var c=l[l.length-1];var d=l[0];if(s>c)u[1]=c;if(s<d)u[1]=d;var f=l.indexOf(u[1]);var p=_-w*f;a.updateDay(u[1],1);a.updateHeight(p,"1")}else if(t===1){var v=k(r,n,o,s);var c=v[v.length-1];var d=v[0];if(h>c)u[2]=c;if(h<d)u[2]=d;var f=v.indexOf(u[2]);var p=_-w*f;a.updateDay(u[2],2);a.updateHeight(p,"2")}};this.getSelector=function(){return r("taro-picker-group",{range:a.range,rangeKey:a.rangeKey,height:a.height[0],updateHeight:a.updateHeight,columnId:"0"})};this.getMultiSelector=function(){return a.range.map((function(e,t){return r("taro-picker-group",{range:e,rangeKey:a.rangeKey,height:a.height[t],updateHeight:a.updateHeight,onColumnChange:a.handleColumnChange,columnId:String(t)})}))};this.getTimeSelector=function(){var e=s.slice();var t=h.slice();return[r("taro-picker-group",{mode:"time",range:e,height:a.height[0],updateHeight:a.updateHeight,columnId:"0"}),r("taro-picker-group",{mode:"time",range:t,height:a.height[1],updateHeight:a.updateHeight,columnId:"1"})]};this.getDateSelector=function(){var e=a,t=e.fields,i=e.height;var n=a.pickerDate,u=n._start,o=n._end,s=n._updateValue;var h=s[0];var l=s[1];var c=m(u.getFullYear(),o.getFullYear()).map((function(e){return e+"年"}));var d=y(u,o,h).map((function(e){return(e<10?"0"+e:e)+"月"}));var f=k(u,o,h,l).map((function(e){return(e<10?"0"+e:e)+"日"}));var p=[r("taro-picker-group",{mode:"date",range:c,height:i[0],updateDay:a.updateDay,updateHeight:a.updateHeight,columnId:"0"})];if(t==="month"||t==="day"){p.push(r("taro-picker-group",{mode:"date",range:d,height:i[1],updateDay:a.updateDay,updateHeight:a.updateHeight,columnId:"1"}))}if(t==="day"){p.push(r("taro-picker-group",{mode:"date",range:f,height:i[2],updateDay:a.updateDay,updateHeight:a.updateHeight,columnId:"2"}))}return p}}e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true;this.handleProps()};e.prototype.componentDidLoad=function(){var e=this;Object.defineProperty(this.el,"value",{get:function(){return e.pickerValue},set:function(t){return e.value=t},configurable:true});if(this.overlay){document.body.appendChild(this.overlay)}};e.prototype.disconnectedCallback=function(){var e;if(this.overlay){(e=this.overlay.parentNode)===null||e===void 0?void 0:e.removeChild(this.overlay)}};e.prototype.onPropsChange=function(){if(!this.isWillLoadCalled)return;this.handleProps()};e.prototype.handleProps=function(){var e=this;var t=this,i=t.mode,r=t.start,a=t.end;if(i==="selector"){var n=this.value;this.index=[l(n,this.range)?Math.floor(n):0]}else if(i==="multiSelector"){var u=this.value;this.index=[];this.range.forEach((function(t,i){var r=u===null||u===void 0?void 0:u[i];var a=l(r,t)?Math.floor(r):0;e.index.push(a)}))}else if(i==="time"){var n=this.value;if(!c(n)){console.warn("time picker value illegal");n="0:0"}var o=n.split(":").map((function(e){return+e}));this.index=o}else if(i==="date"){var n=this.value;var s=f(n)||new Date((new Date).setHours(0,0,0,0));var h=f(r)||new Date("1970/01/01");var d=f(a)||new Date("2999/01/01");if(s>=h&&s<=d){var p=s.getFullYear();var v=s.getMonth()+1;var g=s.getDate();var _=m(h.getFullYear(),d.getFullYear());var w=y(h,d,p);var C=k(h,d,p,v);this.index=[_.indexOf(p),w.indexOf(v),C.indexOf(g)];if(!this.pickerDate||this.pickerDate._value.getTime()!==s.getTime()||this.pickerDate._start.getTime()!==h.getTime()||this.pickerDate._end.getTime()!==d.getTime()){this.pickerDate={_value:s,_start:h,_end:d,_updateValue:[p,v,g]}}}else{throw new Error("Date Interval Error")}}this.height=this.getHeightByIndex();this.pickerValue=this.value;if(i==="date"){var D=this.pickerValue;if(this.fields==="month"){this.pickerValue=D.split("-").slice(0,2).join("-")}else if(this.fields==="year"){this.pickerValue=D.split("-")[0]}}};e.prototype.render=function(){var e=this;var t=this,i=t.name,n=t.mode,o=t.fadeOut,s=t.hidden;var h;switch(n){case"multiSelector":h=this.getMultiSelector();break;case"time":h=this.getTimeSelector();break;case"date":h=this.getDateSelector();break;default:h=this.getSelector()}var l=u("weui-mask","weui-animate-fade-in",{"weui-animate-fade-out":o});var c=u("weui-picker","weui-animate-slide-up",{"weui-animate-slide-down":o});var d=s?{display:"none"}:{};return r(a,null,r("div",{onClick:this.showPicker},r("slot",null),r("input",{type:"hidden",name:i,value:v(this.pickerValue)})),r("div",{class:"weui-picker__overlay",style:d,ref:function(t){e.overlay=t}},r("div",{class:l,onClick:this.handleCancel}),r("div",{class:c},r("div",{class:"weui-picker__hd"},r("div",{class:"weui-picker__action",onClick:this.handleCancel},"取消"),r("div",{class:"weui-picker__action",onClick:this.handleChange},"确定")),r("div",{class:"weui-picker__bd"},h),r("input",{type:"hidden",name:i,value:v(this.pickerValue)}))))};Object.defineProperty(e.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{mode:["onPropsChange"],value:["onPropsChange"],range:["onPropsChange"],start:["onPropsChange"],end:["onPropsChange"]}},enumerable:false,configurable:true});return e}());x.style=D;var H=e("taro_picker_group",function(){function e(e){t(this,e);this.range=[]}e.prototype.getPosition=function(){var e=this.touchEnd?.3:0;var t="translate3d(0, "+this.height+"px, 0)";var i="transform "+e+"s";return{transform:t,"-webkit-transform":t,transition:i,"-webkit-transition":i}};e.prototype.formulaUnlimitedScroll=function(e,t,i){var r=this;var a=this,n=a.height,u=a.updateHeight,o=a.columnId;var s=i==="up"?1:-1;this.touchEnd=false;u(-e*s*w+n,o);requestAnimationFrame((function(){r.touchEnd=true;var i=Math.round(t/-w)+e*s;var a=_-w*i;u(a,o,true)}))};e.prototype.onTouchStart=function(e){this.startY=e.changedTouches[0].clientY;this.preY=e.changedTouches[0].clientY;this.hadMove=false};e.prototype.onTouchMove=function(e){e.preventDefault();var t=e.changedTouches[0].clientY;var i=t-this.preY;this.preY=t;this.touchEnd=false;if(Math.abs(t-this.startY)>10)this.hadMove=true;var r=this.height+i;if(this.mode==="time"){if(this.columnId==="0"){if(r>_-w*3){r=_-w*27+i}if(r<_-w*28){r=_-w*4+i}}else if(this.columnId==="1"){if(r>_-w*3){r=_-w*63+i}if(r<_-w*64){r=_-w*4+i}}}this.updateHeight(r,this.columnId)};e.prototype.onTouchEnd=function(e){var t=this,i=t.mode,r=t.range,a=t.height,n=t.updateHeight,u=t.onColumnChange,o=t.columnId;var s=0;var h=-w*(r.length-1);var l=e.changedTouches[0].clientY;this.touchEnd=true;var c;if(!this.hadMove){var d=window.innerHeight;var f=d-C/2;c=a-_-(l-f);if(i==="time"){if(o==="0"){if(c>-w*2.5){return this.formulaUnlimitedScroll(24,c,"up")}if(c<-w*28.5){return this.formulaUnlimitedScroll(24,c,"down")}}else if(o==="1"){if(c>-w*2.5){return this.formulaUnlimitedScroll(60,c,"up")}if(c<-w*64.5){return this.formulaUnlimitedScroll(60,c,"down")}}}}else{c=a-_}if(c>s)c=0;if(c<h)c=h;var p=Math.round(c/-w);var v=_-w*p;if(this.mode==="date"){if(this.columnId==="0"){this.updateDay(+this.range[p].replace(/[^0-9]/gi,""),0)}if(this.columnId==="1"){this.updateDay(+this.range[p].replace(/[^0-9]/gi,""),1)}if(this.columnId==="2"){this.updateDay(+this.range[p].replace(/[^0-9]/gi,""),2)}}n(v,o,i==="time");u&&u(v,o)};e.prototype.render=function(){var e=this,t=e.range,i=e.rangeKey;var n=t.map((function(e){var t=i?e[i]:e;return r("div",{class:"weui-picker__item"},t)}));return r(a,{class:"weui-picker__group"},r("div",{class:"weui-picker__mask"}),r("div",{class:"weui-picker__indicator"}),r("div",{class:"weui-picker__content",style:this.getPosition()},n))};return e}())}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(t){"use strict";var e,n,i;return{setters:[function(t){e=t.r;n=t.c;i=t.h}],execute:function(){var o="audio{max-width:100%;outline:none}";var r=t("taro_audio_core",function(){function t(t){e(this,t);this.onError=n(this,"error",7);this.onPlay=n(this,"play",7);this.onPause=n(this,"pause",7);this.onTimeUpdate=n(this,"timeupdate",7);this.onEnded=n(this,"ended",7);this.controls=true;this.autoplay=false;this.loop=false;this.muted=false}t.prototype.bindevent=function(){var t=this;this.audio.addEventListener("timeupdate",(function(e){t.onTimeUpdate.emit({duration:e.srcElement.duration,currentTime:e.srcElement.duration})}));this.audio.addEventListener("ended",(function(){t.onEnded.emit()}));this.audio.addEventListener("play",(function(){t.onPlay.emit()}));this.audio.addEventListener("pause",(function(e){t.onPause.emit(e)}));this.audio.addEventListener("error",(function(e){var n;t.onError.emit({errMsg:(n=e.srcElement.error)===null||n===void 0?void 0:n.code})}))};t.prototype.componentDidLoad=function(){this.bindevent()};t.prototype.render=function(){var t=this;var e=this,n=e.src,o=e.controls,r=e.autoplay,s=e.loop,a=e.muted;return i("audio",{src:n,controls:o,autoplay:r,loop:s,muted:a,ref:function(e){t.audio=e}})};return t}());r.style=o}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,g as o}from"./p-30c0639e.js";const h=class{constructor(i){t(this,i),this.onLongTap=s(this,"longtap",7),this.onTouchStart=()=>{this.timer=setTimeout((()=>{this.onLongTap.emit()}),500)},this.onTouchMove=()=>{clearTimeout(this.timer)},this.onTouchEnd=()=>{clearTimeout(this.timer)}}render(){const{canvasId:t}=this;return i("canvas",{"canvas-id":t,style:{width:"100%",height:"100%"},onTouchStart:this.onTouchStart,onTouchMove:this.onTouchMove,onTouchEnd:this.onTouchEnd})}get el(){return o(this)}};h.style="taro-canvas-core{position:relative;display:block;width:300px;height:150px}";export{h as taro_canvas_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as e,h as o,H as i,g as n}from"./p-30c0639e.js";const c=class{constructor(o){t(this,o),this.onChange=e(this,"checkboxchange",7),this.value="",this.checked=!1,this.isWillLoadCalled=!1,this.handleChange=t=>{t.stopPropagation(),this.onChange.emit({value:this.value})}}watchId(t){this.isWillLoadCalled&&t&&this.inputEl.setAttribute("id",t)}componentWillLoad(){this.isWillLoadCalled=!0}componentDidRender(){this.id&&this.el.removeAttribute("id")}render(){const{checked:t,name:e,color:n,value:c}=this;return o(i,{className:"weui-cells_checkbox"},o("input",{ref:t=>{t&&(this.inputEl=t,this.id&&t.setAttribute("id",this.id))},type:"checkbox",value:c,name:e,class:"taro-checkbox_checked",style:{color:n},checked:t,onChange:this.handleChange}),o("slot",null))}get el(){return n(this)}static get watchers(){return{id:["watchId"]}}};c.style='@charset "UTF-8";.taro-checkbox{position:relative;display:inline-block}.taro-checkbox_checked{display:inline-block;min-height:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;outline:0;font-size:23px;border:1px solid #d1d1d1;background-color:#ffffff;border-radius:3px;color:#1AAD19;width:23px;height:23px;position:relative;vertical-align:0;top:5px}.taro-checkbox_checked:checked::before{font-family:"weui";font-style:normal;font-weight:normal;font-variant:normal;text-transform:none;text-align:center;speak:none;display:inline-block;vertical-align:middle;text-decoration:inherit;content:"";color:inherit;font-size:inherit;position:absolute;top:50%;left:50%;-webkit-transform:translate(-50%, -48%) scale(0.73);transform:translate(-50%, -48%) scale(0.73)}';const s=class{constructor(o){t(this,o),this.onChange=e(this,"change",7),this.uniqueName=Date.now().toString(36)}function(t){if(t.stopPropagation(),"TARO-CHECKBOX-CORE"!==t.target.tagName)return;const e=this.el.querySelectorAll("taro-checkbox-core");this.value=this.getValues(e),this.onChange.emit({value:this.value})}componentDidLoad(){this.el.querySelectorAll("taro-checkbox-core").forEach((t=>{t.setAttribute("name",this.name||this.uniqueName)})),Object.defineProperty(this.el,"value",{get:()=>{if(!this.value){const t=this.el.querySelectorAll("taro-checkbox-core");this.value=this.getValues(t)}return this.value},configurable:!0})}getValues(t){return Array.from(t).filter((t=>{const e=t.querySelector("input");return null==e?void 0:e.checked})).map((t=>t.value))}render(){return o(i,null)}get el(){return n(this)}};export{c as taro_checkbox_core,s as taro_checkbox_group_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(e){"use strict";var t,i,r,n,o;return{setters:[function(e){t=e.r;i=e.c;r=e.h;n=e.H;o=e.g}],execute:function(){var a=e("taro_radio_core",function(){function e(e){var r=this;t(this,e);this.onChange=i(this,"radiochange",7);this.value="";this.checked=false;this.disabled=false;this.isWillLoadCalled=false;this.handleClick=function(){if(r.disabled)return;if(!r.checked)r.checked=true}}e.prototype.watchChecked=function(e){if(!this.isWillLoadCalled)return;e&&this.onChange.emit({value:this.value})};e.prototype.watchId=function(e){if(!this.isWillLoadCalled)return;if(e)this.inputEl.setAttribute("id",e)};e.prototype.componentDidRender=function(){this.id&&this.el.removeAttribute("id")};e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true};e.prototype.render=function(){var e=this;var t=this,i=t.checked,o=t.name,a=t.value,u=t.disabled;return r(n,{className:"weui-cells_checkbox",onClick:this.handleClick},r("input",{ref:function(t){if(!t)return;e.inputEl=t;if(e.id)t.setAttribute("id",e.id)},type:"radio",name:o,value:a,class:"weui-check",checked:i,disabled:u,onChange:function(e){return e.stopPropagation()}}),r("i",{class:"weui-icon-checked"}),r("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{checked:["watchChecked"],id:["watchId"]}},enumerable:false,configurable:true});return e}());var u=e("taro_radio_group_core",function(){function e(e){t(this,e);this.onChange=i(this,"change",7);this.uniqueName=Date.now().toString(36)}e.prototype.function=function(e){e.stopPropagation();if(e.target.tagName!=="TARO-RADIO-CORE")return;var t=e.target;if(t.checked){var i=this.el.querySelectorAll("taro-radio-core");i.forEach((function(e){if(e!==t){e.checked=false}}));this.value=e.detail.value;this.onChange.emit({value:this.value})}};e.prototype.componentDidLoad=function(){var e=this;var t=this.el.querySelectorAll("taro-radio-core");t.forEach((function(t){t.setAttribute("name",e.name||e.uniqueName)}));Object.defineProperty(this.el,"value",{get:function(){if(!e.value){var t=e.el.querySelectorAll("taro-radio-core");e.value=e.getValues(t)}return e.value},configurable:true})};e.prototype.getValues=function(e){var t="";Array.from(e).forEach((function(e){var i=e.querySelector("input");if(i===null||i===void 0?void 0:i.checked){t=i.value||""}}));return t};e.prototype.render=function(){return r(n,{class:"weui-cells_radiogroup"})};Object.defineProperty(e.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return e}())}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as i,h as o,H as e}from"./p-30c0639e.js";import{c as s}from"./p-625158f0.js";import("./p-72f327e1.js");const r=class{constructor(o){t(this,o),this.onLoad=i(this,"load",7),this.onError=i(this,"error",7),this.mode="scaleToFill",this.lazyLoad=!1,this.aspectFillMode="width"}componentDidLoad(){if(!this.lazyLoad)return;const t=new IntersectionObserver((i=>{i[i.length-1].isIntersecting&&(t.unobserve(this.imgRef),this.imgRef.src=this.src)}),{rootMargin:"300px 0px"});t.observe(this.imgRef)}imageOnLoad(){const{width:t,height:i,naturalWidth:o,naturalHeight:e}=this.imgRef;this.onLoad.emit({width:t,height:i}),this.aspectFillMode=o>e?"width":"height"}imageOnError(){this.onError.emit()}render(){const{src:t,mode:i,lazyLoad:r,aspectFillMode:a,imageOnLoad:h,imageOnError:m}=this,d=s({"taro-img__widthfix":"widthFix"===i}),g=s(`taro-img__mode-${i.toLowerCase().replace(/\s/g,"")}`,{[`taro-img__mode-aspectfill--${a}`]:"aspectFill"===i});return o(e,{class:d},o("img",r?{ref:t=>this.imgRef=t,class:g,onLoad:h.bind(this),onError:m.bind(this)}:{ref:t=>this.imgRef=t,class:g,src:t,onLoad:h.bind(this),onError:m.bind(this)}))}};r.style='img[src=""]{opacity:0}taro-image-core{display:inline-block;overflow:hidden;position:relative;font-size:0;width:320px;height:240px}.taro-img.taro-img__widthfix{height:100%}.taro-img__mode-scaletofill{width:100%;height:100%}.taro-img__mode-aspectfit{max-width:100%;max-height:100%}.taro-img__mode-aspectfill{position:absolute;top:50%;left:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.taro-img__mode-aspectfill--width{min-width:100%;height:100%}.taro-img__mode-aspectfill--height{width:100%;min-height:100%}.taro-img__mode-widthfix{width:100%}.taro-img__mode-top{width:100%}.taro-img__mode-bottom{width:100%;position:absolute;bottom:0}.taro-img__mode-left{height:100%}.taro-img__mode-right{position:absolute;height:100%;right:0}.taro-img__mode-topright{position:absolute;right:0}.taro-img__mode-bottomleft{position:absolute;bottom:0}.taro-img__mode-bottomright{position:absolute;right:0;bottom:0}';export{r as taro_image_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,h as i,H as e,g as o,c as s}from"./p-30c0639e.js";import{c as a}from"./p-625158f0.js";const r=t=>{if(null==t)return"";const i=Math.round(t%60),e=Math.round((t-i)/60);return`${e<10?`0${e}`:e}:${i<10?`0${i}`:i}`},n=t=>Math.max(-1,Math.min(t,1)),h=(t,i)=>{let e=0;return function(){const o=Date.now();o-e>i&&(t.apply(this,arguments),e=o)}},l=function(){let t;const i=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];var e=["webkitEnterFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"];let o=0;const s=i.length,a={};for(;o<s;o++)if(t=i[o],t&&t[1]in document){for(o=0;o<t.length;o++)a[i[0][o]]=t[o];return a}if(!a[i[0][0]])for(o=0;o<e.length;o++)a[i[0][o]]=e[o];return a}(),A=class{constructor(i){t(this,i),this.visible=!1,this.isDraggingProgressBall=!1,this.percentage=0,this.progressDimentions={left:0,width:0},this.calcPercentage=t=>{let i=t-this.progressDimentions.left;return i=Math.max(i,0),i=Math.min(i,this.progressDimentions.width),i/this.progressDimentions.width},this.onDragProgressBallStart=()=>{this.isDraggingProgressBall=!0,this.hideControlsTimer&&clearTimeout(this.hideControlsTimer)},this.onClickProgress=t=>{t.stopPropagation();const i=this.calcPercentage(t.pageX);this.seekFunc(i*this.duration),this.toggleVisibility(!0)}}onDocumentTouchMove(t){this.isDraggingProgressBall&&(this.percentage=this.calcPercentage(t.touches[0].pageX),this.setProgressBall(this.percentage),this.setCurrentTime(this.percentage*this.duration))}onDocumentTouchEnd(){this.isDraggingProgressBall&&(this.isDraggingProgressBall=!1,this.seekFunc(this.percentage*this.duration),this.toggleVisibility(!0))}async setProgressBall(t){this.progressBallRef&&(this.progressBallRef.style.left=100*t+"%")}async toggleVisibility(t){const i=void 0===t?!this.visible:t;i?(this.hideControlsTimer&&clearTimeout(this.hideControlsTimer),this.isPlaying&&(this.hideControlsTimer=setTimeout((()=>{this.toggleVisibility(!1)}),2e3)),this.controlsRef.style.visibility="visible"):this.controlsRef.style.visibility="hidden",this.visible=!!i}async getIsDraggingProgressBall(){return this.isDraggingProgressBall}async setCurrentTime(t){this.currentTimeRef.innerHTML=r(t)}render(){const{controls:t,currentTime:o,duration:s,isPlaying:a,pauseFunc:n,playFunc:h,showPlayBtn:l,showProgress:A}=this,d=r(s);let c;return c=l?i("div",a?{class:"taro-video-control-button taro-video-control-button-pause",onClick:n}:{class:"taro-video-control-button taro-video-control-button-play",onClick:h}):null,i(e,{class:"taro-video-bar taro-video-bar-full"},t&&i("div",{class:"taro-video-controls"},c,A&&i("div",{class:"taro-video-current-time",ref:t=>this.currentTimeRef=t},r(o)),A&&i("div",{class:"taro-video-progress-container",onClick:this.onClickProgress},i("div",{class:"taro-video-progress",ref:t=>{if(!t)return;const i=t.getBoundingClientRect();this.progressDimentions.left=i.left,this.progressDimentions.width=i.width}},i("div",{class:"taro-video-progress-buffered",style:{width:"100%"}}),i("div",{class:"taro-video-ball",ref:t=>this.progressBallRef=t,onTouchStart:this.onDragProgressBallStart,style:{left:(d?this.currentTime/s*100:0)+"%"}},i("div",{class:"taro-video-inner"})))),A&&i("div",{class:"taro-video-duration"},d)),i("slot",null))}get controlsRef(){return o(this)}},d=class{constructor(i){t(this,i),this.onPlay=s(this,"play",7),this.onPause=s(this,"pause",7),this.onEnded=s(this,"ended",7),this.onTimeUpdate=s(this,"timeupdate",7),this.onError=s(this,"error",7),this.onFullScreenChange=s(this,"fullscreenchange",7),this.onProgress=s(this,"progress",7),this.onLoadedMetaData=s(this,"loadedmetadata",7),this.currentTime=0,this.isDraggingProgress=!1,this.gestureType="none",this.controls=!0,this.autoplay=!1,this.loop=!1,this.muted=!1,this.initialTime=0,this.objectFit="contain",this.showProgress=!0,this.showFullscreenBtn=!0,this.showPlayBtn=!0,this.showCenterPlayBtn=!0,this.showMuteBtn=!1,this.danmuBtn=!1,this.enableDanmu=!1,this.enablePlayGesture=!1,this.enableProgressGesture=!0,this.vslideGesture=!1,this.vslideGestureInFullscreen=!0,this._enableDanmu=!1,this.isPlaying=!1,this.isFirst=!0,this.isFullScreen=!1,this.fullScreenTimestamp=(new Date).getTime(),this.isMute=!1,this.analyseGesture=t=>{var i;const e={type:"none"},o=t.touches[0].screenX-this.lastTouchScreenX,s=t.touches[0].screenY-this.lastTouchScreenY,a=this.isFullScreen?this.vslideGestureInFullscreen:this.vslideGesture;if("none"===this.gestureType){if(r=s,Math.sqrt(Math.pow(o,2)+Math.pow(r,2))<10)return e;if(Math.abs(s)>=Math.abs(o)){if(!a)return e;this.gestureType="adjustVolume",this.lastVolume=this.videoRef.volume}else if(Math.abs(s)<Math.abs(o)){if(!this.enableProgressGesture)return e;this.gestureType="adjustProgress",this.lastPercentage=this.currentTime/(null!==(i=this.duration)&&void 0!==i?i:this._duration)}}var r;return e.type=this.gestureType,e.dataX=n(o/200),e.dataY=n(s/200),e},this.handlePlay=()=>{this.isPlaying=!0,this.isFirst=!1,this.controlsRef.toggleVisibility(!0),this.onPlay.emit()},this.handlePause=()=>{this.isPlaying=!1,this.controlsRef.toggleVisibility(!0),this.onPause.emit()},this.handleEnded=()=>{this.isFirst=!0,this.pause(),this.controlsRef.toggleVisibility(),this.onEnded.emit()},this.handleTimeUpdate=h((async t=>{var i,e;this.currentTime=this.videoRef.currentTime;const o=this.duration||this._duration,s=await this.controlsRef.getIsDraggingProgressBall();this.controls&&this.showProgress&&(s||this.isDraggingProgress||(this.controlsRef.setProgressBall(this.currentTime/o),this.controlsRef.setCurrentTime(this.currentTime))),this.danmuRef.tick(this.currentTime),this.onTimeUpdate.emit({duration:null===(i=t.target)||void 0===i?void 0:i.duration,currentTime:null===(e=t.target)||void 0===e?void 0:e.currentTime}),this.duration&&this.currentTime>=this.duration&&(this.seek(0),this.handleEnded())}),250),this.handleError=t=>{var i,e;this.onError.emit({errMsg:null===(e=null===(i=t.target)||void 0===i?void 0:i.error)||void 0===e?void 0:e.message})},this.handleDurationChange=()=>{this._duration=this.videoRef.duration},this.handleProgress=()=>{this.onProgress.emit()},this.handleLoadedMetaData=t=>{const i=t.target;this.onLoadedMetaData.emit({width:i.videoWidth,height:i.videoHeight,duration:i.duration})},this._play=()=>this.videoRef.play(),this._pause=()=>this.videoRef.pause(),this._stop=()=>{this.videoRef.pause(),this._seek(0)},this._seek=t=>{this.videoRef.currentTime=t},this.onTouchStartContainer=t=>{this.lastTouchScreenX=t.touches[0].screenX,this.lastTouchScreenY=t.touches[0].screenY},this.onClickContainer=()=>{if(this.enablePlayGesture){const t=Date.now();t-this.lastClickedTime<300&&(this.isPlaying?this.pause():this.play()),this.lastClickedTime=t}this.controlsRef.toggleVisibility()},this.onClickFullScreenBtn=t=>{t.stopPropagation(),this.toggleFullScreen()},this.handleFullScreenChange=t=>{const i=(new Date).getTime();!t.detail&&this.isFullScreen&&!document[l.fullscreenElement]&&i-this.fullScreenTimestamp>100&&this.toggleFullScreen(!1)},this.toggleFullScreen=(t=!this.isFullScreen)=>{this.isFullScreen=t,this.controlsRef.toggleVisibility(!0),this.fullScreenTimestamp=(new Date).getTime(),this.onFullScreenChange.emit({fullScreen:this.isFullScreen,direction:"vertical"}),this.isFullScreen&&!document[l.fullscreenElement]&&setTimeout((()=>{this.videoRef[l.requestFullscreen]({navigationUI:"show"})}),0)},this.toggleMute=t=>{t.stopPropagation(),this.videoRef.muted=!this.isMute,this.controlsRef.toggleVisibility(!0),this.isMute=!this.isMute},this.toggleDanmu=t=>{t.stopPropagation(),this.controlsRef.toggleVisibility(!0),this._enableDanmu=!this._enableDanmu}}componentWillLoad(){this._enableDanmu=this.enableDanmu}componentDidLoad(){this.initialTime&&(this.videoRef.currentTime=this.initialTime),this.danmuRef.sendDanmu(this.danmuList),document.addEventListener&&document.addEventListener(l.fullscreenchange,this.handleFullScreenChange)}componentDidRender(){}disconnectedCallback(){document.removeEventListener&&document.removeEventListener(l.fullscreenchange,this.handleFullScreenChange)}watchEnableDanmu(t){this._enableDanmu=t}async onDocumentTouchMove(t){if(void 0===this.lastTouchScreenX||void 0===this.lastTouchScreenY)return;if(await this.controlsRef.getIsDraggingProgressBall())return;const i=this.analyseGesture(t);if("adjustVolume"===i.type){this.toastVolumeRef.style.visibility="visible";const t=Math.max(Math.min(this.lastVolume-i.dataY,1),0);this.videoRef.volume=t,this.toastVolumeBarRef.style.width=100*t+"%"}else if("adjustProgress"===i.type){this.isDraggingProgress=!0,this.nextPercentage=Math.max(Math.min(this.lastPercentage+i.dataX,1),0),this.controls&&this.showProgress&&(this.controlsRef.setProgressBall(this.nextPercentage),this.controlsRef.toggleVisibility(!0));const t=this.duration||this._duration;this.toastProgressTitleRef.innerHTML=`${r(this.nextPercentage*t)} / ${r(t)}`,this.toastProgressRef.style.visibility="visible"}}onDocumentTouchEnd(){var t;"adjustVolume"===this.gestureType?this.toastVolumeRef.style.visibility="hidden":"adjustProgress"===this.gestureType&&(this.toastProgressRef.style.visibility="hidden"),this.isDraggingProgress&&(this.isDraggingProgress=!1,this.seek(this.nextPercentage*(null!==(t=this.duration)&&void 0!==t?t:this._duration))),this.gestureType="none",this.lastTouchScreenX=void 0,this.lastTouchScreenY=void 0}async play(){this._play()}async pause(){this._pause()}async stop(){this._stop()}async seek(t){this._seek(t)}async requestFullScreen(){this.toggleFullScreen(!0)}async exitFullScreen(){this.toggleFullScreen(!1)}render(){const{src:t,controls:o,autoplay:s,loop:n,muted:h,poster:l,objectFit:A,isFirst:d,isMute:c,isFullScreen:u,duration:b,_duration:g,showCenterPlayBtn:p,isPlaying:v,_enableDanmu:m,showMuteBtn:w,danmuBtn:E,showFullscreenBtn:I}=this,x=r(b||g||null);return i(e,{class:a("taro-video-container",{"taro-video-type-fullscreen":u}),onTouchStart:this.onTouchStartContainer,onClick:this.onClickContainer},i("video",{class:"taro-video-video",style:{"object-fit":A},ref:t=>{t&&(this.videoRef=t)},src:t,autoplay:s,loop:n,muted:h,poster:o?l:void 0,playsinline:!0,"webkit-playsinline":!0,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onTimeUpdate:this.handleTimeUpdate,onError:this.handleError,onDurationChange:this.handleDurationChange,onProgress:this.handleProgress,onLoadedMetaData:this.handleLoadedMetaData},"暂时不支持播放该视频"),i("taro-video-danmu",{ref:t=>{t&&(this.danmuRef=t)},enable:m}),d&&p&&!v&&i("div",{class:"taro-video-cover"},i("div",{class:"taro-video-cover-play-button",onClick:()=>this.play()}),i("p",{class:"taro-video-cover-duration"},x)),i("taro-video-control",{ref:t=>{t&&(this.controlsRef=t)},controls:o,currentTime:this.currentTime,duration:this.duration||this._duration||void 0,isPlaying:this.isPlaying,pauseFunc:this._pause,playFunc:this._play,seekFunc:this._seek,showPlayBtn:this.showPlayBtn,showProgress:this.showProgress},w&&i("div",{class:a("taro-video-mute",{"taro-video-type-mute":c}),onClick:this.toggleMute}),E&&i("div",{class:a("taro-video-danmu-button",{"taro-video-danmu-button-active":m}),onClick:this.toggleDanmu},"弹幕"),I&&i("div",{class:a("taro-video-fullscreen",{"taro-video-type-fullscreen":u}),onClick:this.onClickFullScreenBtn})),i("div",{class:"taro-video-toast taro-video-toast-volume",ref:t=>{t&&(this.toastVolumeRef=t)}},i("div",{class:"taro-video-toast-title"},"音量"),i("div",{class:"taro-video-toast-icon"}),i("div",{class:"taro-video-toast-value"},i("div",{class:"taro-video-toast-value-content",ref:t=>{t&&(this.toastVolumeBarRef=t)}},i("div",{class:"taro-video-toast-volume-grids"},Array(10).fill(1).map((()=>i("div",{class:"taro-video-toast-volume-grids-item"}))))))),i("div",{class:"taro-video-toast taro-video-toast-progress",ref:t=>{t&&(this.toastProgressRef=t)}},i("div",{class:"taro-video-toast-title",ref:t=>{t&&(this.toastProgressTitleRef=t)}})))}get el(){return o(this)}static get watchers(){return{enableDanmu:["watchEnableDanmu"]}}};d.style='.taro-video{width:100%;height:225px;display:inline-block;line-height:0;overflow:hidden;position:relative}.taro-video[hidden]{display:none}.taro-video-container{width:100%;height:100%;background-color:#000;display:inline-block;position:absolute;top:0;left:0;overflow:hidden;-o-object-position:inherit;object-position:inherit}.taro-video-container.taro-video-type-fullscreen{position:fixed;top:0;left:0;right:0;bottom:0;z-index:999}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-left{-webkit-transform:translate(-50%, -50%) rotate(-90deg);transform:translate(-50%, -50%) rotate(-90deg)}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-right{-webkit-transform:translate(-50%, -50%) rotate(90deg);transform:translate(-50%, -50%) rotate(90deg)}.taro-video-video{width:100%;height:100%;-o-object-position:inherit;object-position:inherit}.taro-video-cover{position:absolute;top:0;left:0;bottom:0;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;background-color:rgba(1, 1, 1, 0.5);z-index:1}.taro-video-cover-play-button{width:40px;height:40px;background-size:50%;background-repeat:no-repeat;background-position:50% 50%}.taro-video-cover-duration{color:#fff;font-size:16px;line-height:1;margin-top:10px}.taro-video-bar{visibility:hidden;height:44px;background-color:rgba(0, 0, 0, 0.5);overflow:hidden;position:absolute;bottom:0;right:0;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;padding:0 10px;z-index:1}.taro-video-bar.taro-video-bar-full{left:0}.taro-video-controls{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;margin:0 8.5px}.taro-video-control-button{width:13px;height:15px;padding:14.5px 12.5px 14.5px 12.5px;margin-left:-8.5px;-webkit-box-sizing:content-box;box-sizing:content-box}.taro-video-control-button:after{content:"";display:block;width:100%;height:100%;background-size:100%;background-position:50% 50%;background-repeat:no-repeat}.taro-video-control-button.taro-video-control-button-play:after,.taro-video-cover-play-button{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAeCAYAAAAy2w7YAAAAAXNSR0IArs4c6QAAAWhJREFUSA1j+P///0cgBoHjQGzCQCsAtgJB/AMy5wCxGNXtQ9iBwvoA5BUCMQvVLEQxHpNzDSjkRhXLMM3GKrIeKKpEkYVYjcUu+AMo3ALE3GRZiN1MvKKPgbIRJFuG10j8koeA0gZEW4jfLIKyf4EqpgOxMEELCRpFnIJ3QGU5QMyM00LizCFa1SWgSkeslhFtBGkKVwGVy6FYSJp+klR/A6quB2JOkIWMIK0oNlOf8xBoZDE9LAI7nYn6HsBq4l96WHQEaLUpAyiOaASeAM2NgvuPBpaACt82IEYtfKls0UagecpwXyAzqGTRdaA57sjmYrAptAjUsCkGYlYMg9EFyLQI1IiZB8Ti6Obh5JNh0QmgHlOcBuKSIMGi50C18UDMiMssvOJEWPQLqKYbiHnxGkRIkoBF24DyaoTMIEoeh0W3geI+RBlArCI0iz4D+RVAzEasfqLVAQ19AcSg5LoYiKWI1kiiQgCMBLnEEcfDSgAAAABJRU5ErkJggg==)}.taro-video-control-button.taro-video-control-button-pause:after{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAAgCAYAAAAffCjxAAAAAXNSR0IArs4c6QAAAFlJREFUSA3tksEKACAIQ7X//5zq98wOgQayum8QaGweHhMzG/6OujzKAymn+0LMqivu1XznWmX8/echTIyMyAgTwA72iIwwAexgj8gIE8CO3aMRbDPMaEy5BRGaKcZv8YxRAAAAAElFTkSuQmCC)}.taro-video-current-time,.taro-video-duration{height:14.5px;line-height:14.5px;margin-top:15px;margin-bottom:14.5px;font-size:12px;color:#cbcbcb}.taro-video-progress-container{-webkit-box-flex:2;-webkit-flex-grow:2;-ms-flex-positive:2;flex-grow:2;position:relative}.taro-video-progress{height:2px;margin:21px 12px;background-color:rgba(255, 255, 255, 0.4);position:relative}.taro-video-progress-buffered{position:absolute;left:0;top:0;width:0;height:100%;-webkit-transition:width 0.1s;transition:width 0.1s;background-color:rgba(255, 255, 255, 0.8)}.taro-video-ball{width:16px;height:16px;padding:14px;position:absolute;top:-21px;-webkit-box-sizing:content-box;box-sizing:content-box;left:0;margin-left:-22px}.taro-video-inner{width:100%;height:100%;background-color:#fff;border-radius:50%}.taro-video-danmu-button{white-space:nowrap;line-height:1;padding:2px 10px;border:1px solid #fff;border-radius:5px;font-size:13px;color:#fff;margin:0 8.5px}.taro-video-danmu-button.taro-video-danmu-button-active{border-color:#48c23d;color:#48c23d}.taro-video-fullscreen,.taro-video-mute{width:17px;height:17px;padding:8.5px;-webkit-box-sizing:content-box;box-sizing:content-box;background-size:50%;background-position:50% 50%;background-repeat:no-repeat}.taro-video-fullscreen{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAhUlEQVRYR+2WSwrAMAhEnZO3PfmULLooGEFTiIXJ2s/kRY2wzQeb85sE9CRA8jSzY1YfAFzhJBnU1AVgxH2dSiArCnD9QgGzRNnOech48SRABHoSyFb5in3PSbhyo6yvCPQkEM3u7BsPe/0FIvBfAh/vhKmVbO9SWun1qk/PSVi9TcVPBG6R1YIhgWwNpQAAAABJRU5ErkJggg==)}.taro-video-fullscreen.taro-video-type-fullscreen{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzen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jpTZXE+IDwveG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5PmxYVAAACLklEQVRYhc2XP2sVQRRHz40hKoqaQgVBCy1EozFlGiVFxMLGh4piYWEh+hkEP4YKAVFEEFTyughaCH6DqIVpAhYWEgIxoJE8cywyi5tNHu/tJmvyg2WZO3dmzt47/zZUtoJ6Nhsg09YDiYhKDzACTAFNYH9lEpUq80TdrT5wpV5n/ZV9KoGoo+pXV2uyKkipOaLuUceAt8DhUvQd1FsCYhR4ChzaSIBMHSOi7lOfsByFWiCgEBH1GHAF2JlMPcBt4GC3HUYEaj9wF3gVEVPtfNVTwAXgWX7CDKq/1piAZTSZBmim8qJ6sQ3EgDqb/L7kU3MH2NHtl3dQX3r3Ak21UYAYAj4A/cl0JB+RF+uMRj4iQ+p8zt7KYFLdXKHuRi0gacBhV6a6pd5bA6KRNagFJPU9qv5u47toLmW1HnoR8Q5oAK1CVQu4FBHj/wUkaXsb+4pzpVaQFPqXrN7Be4Fx9VztIOr1BLEtmX4A94E/qdwHTKjDWYM6lu81dSlnn3V570BtuLxaMs2rZ/IgYxsBovaoPwsQA4VoFWEm8ql5DiysNyURsQTMpOIMcDYiPhd8xoGr/FtNC2G6FKXD6ihwGdiVHMoeeh8jYlA9ANwE3kTEp3bO6vE03qOONzR1r/q4RGrquaFFxFxE3ALOA9+6jExpdb180y55AhirhaRTatq0GXEzL8+ZIuI9cBJ4WKiartJf9nWV/mty7UfUafW7erpqRGI9EBuprffvu9n6C1KOmsqwI5A1AAAAAElFTkSuQmCC)}.taro-video-danmu{position:absolute;top:0;left:0;bottom:0;width:100%;margin-top:14px;margin-bottom:44px;font-size:14px;line-height:14px;overflow:visible}.taro-video-danmu-item{line-height:1;position:absolute;color:#fff;white-space:nowrap;left:100%;-webkit-transform:translatex(0);transform:translatex(0);-webkit-transition-property:left, -webkit-transform;transition-property:left, -webkit-transform;transition-property:left, transform;transition-property:left, transform, -webkit-transform;-webkit-transition-duration:3s;transition-duration:3s;-webkit-transition-timing-function:linear;transition-timing-function:linear}.taro-video-toast{pointer-events:none;position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);border-radius:5px;background-color:rgba(255, 255, 255, 0.8);color:#000;display:block;visibility:hidden}.taro-video-toast.taro-video-toast-volume{width:100px;height:100px;display:block}.taro-video-toast-volume .taro-video-toast-title{width:100%;font-size:12px;line-height:16px;text-align:center;margin-top:10px;display:block}.taro-video-toast-volume .taro-video-toast-icon{fill:#000;width:50%;height:50%;margin-left:25%;display:block;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAFhklEQVR4Xu2aeaxfQxTHP1VBES0NIQitWtpaaxeCUkQtaYVa0tiClAq1ExIiQTVppaWxt8RWSa2tWkJQRGgtQaSIpUKEpG0ssbbk28yV2+mZO/e9e3vvu/e98897mZnfzPl+75mZs0wvurn06ub46SGgxwLqZaA3sB/wO/A+8G/V6tS5BU4BJgJbO9DvAMOB36okoQ4CNgAeBEYbQK8Bbm4zAdsBc4EdAyA/APZoKwHHAA8DG2UA/AnYrG0ErAVcD1yXA9gfQJ8c40obsqbPgH7AY8CROTVuFQFD3X7fJid4DWsNAWOAGZ0w58YTsDZwKzChA189PbTRBGwKzAYO6iT4srbAMHfTfAksjulS1iG4JzAH2Dy2YKS/qAVcCdzi1vgZOBZ4PWvNGAG6wgYCW0IwctzNmf06BcEXtYABwOeA4otEfgEOdnGGqV6IAAUopwM6zDYuAVjeKYpYwCjgCWOhH513+b2lhE+Avrj89NPyalzyuCIE6EN9BfQ1dHoPOAD40+9LE6D/5aoqSqtLsgiQC60DTiHzfGCFoaSsQAexZdlTgEuyCDgLuK8u5G7dEAHyKN8CBrtxLwDHAX8Z+l4N3GS0L3db4aN0X5opmc+2XZQAfb2LPd2eciG1lUSRJZ9qYHkZONwiYAjwS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e9lXqhpd9DcZMXOvdkPF0Xu/8dohNUmZ/1QQkuitXr+d4fryuFx3jywQYm6suAqSX8vLTXKJDt4QqO6rtLYspXWZ/nQQkOJTAUJZGIav19q9MvKvN1RUIWKMAY5P3EBBjqO393d4C/gMVHwRQlpx21QAAAABJRU5ErkJggg==);background-size:50%;background-position:50% 50%;background-repeat:no-repeat}.taro-video-toast-volume .taro-video-toast-value{width:80px;height:5px;margin-top:5px;margin-left:10px}.taro-video-toast-volume .taro-video-toast-value>.taro-video-toast-value-content{overflow:hidden}.taro-video-toast-volume-grids{width:80px;height:5px}.taro-video-toast-volume-grids-item{float:left;width:7.1px;height:5px;background-color:#000}.taro-video-toast-volume-grids-item:not(:first-child){margin-left:1px}.taro-video-toast.taro-video-toast-progress{background-color:rgba(0, 0, 0, 0.8);color:#fff;font-size:14px;line-height:18px;padding:6px}';const c=class{constructor(i){t(this,i),this.list=[],this.danmuElList=[],this.currentTime=0,this.enable=!1,this.danmuList=[]}ensureProperties(t){const i=Object.assign({},t);return"time"in t||(i.time=this.currentTime),i.key=Math.random(),i.bottom=90*Math.random()+5+"%",i}async sendDanmu(t=[]){this.list=Array.isArray(t)?[...this.list,...t.map((t=>this.ensureProperties(t)))]:[...this.list,Object.assign({},this.ensureProperties(t))]}async tick(t){if(this.currentTime=t,!this.enable)return;const i=this.list.filter((({time:i})=>t-i<4&&t>i));let e=!1;const o=this.danmuList;e=i.length!==o.length||i.some((({key:t})=>o.every((i=>t!==i.key)))),e&&(this.danmuList=i)}componentDidUpdate(){requestAnimationFrame((()=>{setTimeout((()=>{this.danmuElList.splice(0).forEach((t=>{t.style.left="0",t.style.webkitTransform="translateX(-100%)",t.style.transform="translateX(-100%)"}))}))}))}render(){return this.enable?i(e,{class:"taro-video-danmu"},this.danmuList.map((({text:t,color:e,bottom:o,key:s})=>i("p",{class:"taro-video-danmu-item",key:s,style:{color:e,bottom:o},ref:t=>{t&&this.danmuElList.push(t)}},t)))):""}};export{A as taro_video_control,d as taro_video_core,c as taro_video_danmu}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(t){"use strict";var e,a,n,o;return{setters:[function(t){e=t.r;a=t.c;n=t.h;o=t.g}],execute:function(){var r="taro-textarea-core{display:block;width:300px;height:150px}.taro-textarea{-webkit-appearance:none;cursor:auto;width:100%;height:100%;border:0;display:block;position:relative}.taro-textarea:focus{outline:none}";function u(t){return t!==null&&t!==void 0?t:""}var i=t("taro_textarea_core",function(){function t(t){var n=this;e(this,t);this.onInput=a(this,"input",7);this.onFocus=a(this,"focus",7);this.onBlur=a(this,"blur",7);this.onChange=a(this,"change",7);this.disabled=false;this.maxlength=140;this.autoFocus=false;this.hanldeInput=function(t){t.stopPropagation();n.onInput.emit({value:t.target.value,cursor:t.target.value.length})};this.handleFocus=function(t){n.onFocus.emit({value:t.target.value})};this.handleBlur=function(t){n.onBlur.emit({value:t.target.value})};this.handleChange=function(t){t.stopPropagation();n.onChange.emit({value:t.target.value})}}t.prototype.componentDidLoad=function(){var t=this;Object.defineProperty(this.el,"value",{get:function(){return t.textareaRef.value},set:function(e){return t.value=e},configurable:true});this.autoFocus&&this.textareaRef.focus()};t.prototype.render=function(){var t=this;var e=this,a=e.value,o=e.placeholder,r=e.disabled,i=e.maxlength,s=e.autoFocus,l=e.name,h=e.hanldeInput,c=e.handleFocus,f=e.handleBlur,p=e.handleChange;return n("textarea",{ref:function(e){if(e){t.textareaRef=e}},class:"taro-textarea",value:u(a),placeholder:o,name:l,disabled:r,maxlength:i,autofocus:s,onInput:h,onFocus:c,onBlur:f,onChange:p})};Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return t}());i.style=r}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(t){"use strict";var n,o,e,i;return{setters:[function(t){n=t.r;o=t.c;e=t.h;i=t.g}],execute:function(){var r="taro-canvas-core{position:relative;display:block;width:300px;height:150px}";var c=500;var s=t("taro_canvas_core",function(){function t(t){var e=this;n(this,t);this.onLongTap=o(this,"longtap",7);this.onTouchStart=function(){e.timer=setTimeout((function(){e.onLongTap.emit()}),c)};this.onTouchMove=function(){clearTimeout(e.timer)};this.onTouchEnd=function(){clearTimeout(e.timer)}}t.prototype.render=function(){var t=this.canvasId;return e("canvas",{"canvas-id":t,style:{width:"100%",height:"100%"},onTouchStart:this.onTouchStart,onTouchMove:this.onTouchMove,onTouchEnd:this.onTouchEnd})};Object.defineProperty(t.prototype,"el",{get:function(){return i(this)},enumerable:false,configurable:true});return t}());s.style=r}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as s,h as i}from"./p-30c0639e.js";const o=class{constructor(i){t(this,i),this.onError=s(this,"error",7),this.onPlay=s(this,"play",7),this.onPause=s(this,"pause",7),this.onTimeUpdate=s(this,"timeupdate",7),this.onEnded=s(this,"ended",7),this.controls=!0,this.autoplay=!1,this.loop=!1,this.muted=!1}bindevent(){this.audio.addEventListener("timeupdate",(t=>{this.onTimeUpdate.emit({duration:t.srcElement.duration,currentTime:t.srcElement.duration})})),this.audio.addEventListener("ended",(()=>{this.onEnded.emit()})),this.audio.addEventListener("play",(()=>{this.onPlay.emit()})),this.audio.addEventListener("pause",(t=>{this.onPause.emit(t)})),this.audio.addEventListener("error",(t=>{var s;this.onError.emit({errMsg:null===(s=t.srcElement.error)||void 0===s?void 0:s.code})}))}componentDidLoad(){this.bindevent()}render(){const{src:t,controls:s,autoplay:o,loop:e,muted:h}=this;return i("audio",{src:t,controls:s,autoplay:o,loop:e,muted:h,ref:t=>{this.audio=t}})}};o.style="audio{max-width:100%;outline:none}";export{o as taro_audio_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,H as e,g as h}from"./p-30c0639e.js";const c=class{constructor(i){t(this,i),this.onChange=s(this,"radiochange",7),this.value="",this.checked=!1,this.disabled=!1,this.isWillLoadCalled=!1,this.handleClick=()=>{this.disabled||this.checked||(this.checked=!0)}}watchChecked(t){this.isWillLoadCalled&&t&&this.onChange.emit({value:this.value})}watchId(t){this.isWillLoadCalled&&t&&this.inputEl.setAttribute("id",t)}componentDidRender(){this.id&&this.el.removeAttribute("id")}componentWillLoad(){this.isWillLoadCalled=!0}render(){const{checked:t,name:s,value:h,disabled:c}=this;return i(e,{className:"weui-cells_checkbox",onClick:this.handleClick},i("input",{ref:t=>{t&&(this.inputEl=t,this.id&&t.setAttribute("id",this.id))},type:"radio",name:s,value:h,class:"weui-check",checked:t,disabled:c,onChange:t=>t.stopPropagation()}),i("i",{class:"weui-icon-checked"}),i("slot",null))}get el(){return h(this)}static get watchers(){return{checked:["watchChecked"],id:["watchId"]}}},r=class{constructor(i){t(this,i),this.onChange=s(this,"change",7),this.uniqueName=Date.now().toString(36)}function(t){if(t.stopPropagation(),"TARO-RADIO-CORE"!==t.target.tagName)return;const s=t.target;s.checked&&(this.el.querySelectorAll("taro-radio-core").forEach((t=>{t!==s&&(t.checked=!1)})),this.value=t.detail.value,this.onChange.emit({value:this.value}))}componentDidLoad(){this.el.querySelectorAll("taro-radio-core").forEach((t=>{t.setAttribute("name",this.name||this.uniqueName)})),Object.defineProperty(this.el,"value",{get:()=>{if(!this.value){const t=this.el.querySelectorAll("taro-radio-core");this.value=this.getValues(t)}return this.value},configurable:!0})}getValues(t){let s="";return Array.from(t).forEach((t=>{const i=t.querySelector("input");(null==i?void 0:i.checked)&&(s=i.value||"")})),s}render(){return i(e,{class:"weui-cells_radiogroup"})}get el(){return h(this)}};export{c as taro_radio_core,r as taro_radio_group_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as s,h as i,g as h}from"./p-30c0639e.js";function e(t,s,i){if("search"===s&&(t="search"),i&&(t="password"),void 0===t)return"text";if(!t)throw new Error("unexpected type");return"digit"===t&&(t="number"),t}const o=class{constructor(i){t(this,i),this.onInput=s(this,"input",7),this.onFocus=s(this,"focus",7),this.onBlur=s(this,"blur",7),this.onConfirm=s(this,"confirm",7),this.onChange=s(this,"change",7),this.onKeyDown=s(this,"keydown",7),this.isOnComposition=!1,this.onInputExcuted=!1,this.password=!1,this.disabled=!1,this.maxlength=140,this.autoFocus=!1,this.confirmType="done",this.handleInput=t=>{t.stopPropagation();const{type:s,maxlength:i,confirmType:h,password:o}=this;if(!this.isOnComposition&&!this.onInputExcuted){let n=t.target.value;const a=e(s,h,o);this.onInputExcuted=!0,"number"===a&&n&&i<=n.length&&(n=n.substring(0,i),t.target.value=n),this._value=n,this.onInput.emit({value:n,cursor:n.length})}},this.handleFocus=t=>{this.onInputExcuted=!1,this.onFocus.emit({value:t.target.value})},this.handleBlur=t=>{this.onBlur.emit({value:t.target.value})},this.handleChange=t=>{t.stopPropagation(),this.onChange.emit({value:t.target.value})},this.handleKeyDown=t=>{const{value:s}=t.target;this.onInputExcuted=!1,t.stopPropagation(),this.onKeyDown.emit({value:s}),13===t.keyCode&&this.onConfirm.emit({value:s})},this.handleComposition=t=>{t.target instanceof HTMLInputElement&&("compositionend"===t.type?(this.isOnComposition=!1,this.onInput.emit({value:t.target.value})):this.isOnComposition=!0)}}watchHandler(t,s){t!==s&&(this._value=t)}watchFocus(t,s){!s&&t&&this.inputRef.focus()}componentWillLoad(){this._value=this.value}componentDidLoad(){"file"===this.type?(this.fileListener=()=>{this.onInput.emit()},this.inputRef.addEventListener("change",this.fileListener)):(this.inputRef.addEventListener("compositionstart",this.handleComposition),this.inputRef.addEventListener("compositionend",this.handleComposition)),Object.defineProperty(this.el,"value",{get:()=>this.inputRef.value,set:t=>{this._value=t},configurable:!0})}disconnectedCallback(){"file"===this.type&&this.inputRef.removeEventListener("change",this.fileListener)}render(){const{_value:t,type:s,password:h,placeholder:o,disabled:n,maxlength:a,autoFocus:c,confirmType:r,name:l}=this;return i("input",{ref:t=>{this.inputRef=t,c&&(null==t||t.focus())},class:"weui-input",value:(u=t,null!=u?u:""),type:e(s,r,h),placeholder:o,disabled:n,maxlength:a,autofocus:c,name:l,onInput:this.handleInput,onFocus:this.handleFocus,onBlur:this.handleBlur,onChange:this.handleChange,onKeyDown:this.handleKeyDown});var u}get el(){return h(this)}static get watchers(){return{value:["watchHandler"],autoFocus:["watchFocus"]}}};o.style="taro-input-core{display:block}input{display:block;height:1.4rem;text-align:inherit;text-overflow:clip;overflow:hidden;white-space:nowrap}";export{o as taro_input_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as i,h as s,g as e}from"./p-30c0639e.js";const h=class{constructor(s){t(this,s),this.onChange=i(this,"change",7),this.type="switch",this.checked=!1,this.color="#04BE02",this.disabled=!1,this.isWillLoadCalled=!1,this.switchChange=t=>{t.stopPropagation();const i=t.target.checked;this.isChecked=i,this.onChange.emit({value:i})}}function(t,i){this.isWillLoadCalled&&t!==i&&(this.isChecked=t)}componentWillLoad(){this.isWillLoadCalled=!0,this.isChecked=this.checked}componentDidLoad(){Object.defineProperty(this.el,"value",{get:()=>this.isChecked,configurable:!0})}render(){const{type:t,color:i,isChecked:e,name:h,disabled:c}=this;return s("input",{type:"checkbox",class:`weui-${t}`,style:e?{borderColor:i||"04BE02",backgroundColor:i||"04BE02"}:{},checked:e,name:h,disabled:c,onChange:this.switchChange})}get el(){return e(this)}static get watchers(){return{checked:["function"]}}};h.style="taro-switch-core{display:inline-block;width:52px;height:32px}taro-switch-core .weui-switch{display:block;width:100%;height:100%}";export{h as taro_switch_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(e){"use strict";var t,i,n,o;return{setters:[function(e){t=e.r;i=e.c;n=e.h;o=e.g}],execute:function(){var r="taro-switch-core{display:inline-block;width:52px;height:32px}taro-switch-core .weui-switch{display:block;width:100%;height:100%}";var c=e("taro_switch_core",function(){function e(e){var n=this;t(this,e);this.onChange=i(this,"change",7);this.type="switch";this.checked=false;this.color="#04BE02";this.disabled=false;this.isWillLoadCalled=false;this.switchChange=function(e){e.stopPropagation();var t=e.target.checked;n.isChecked=t;n.onChange.emit({value:t})}}e.prototype.function=function(e,t){if(!this.isWillLoadCalled)return;if(e!==t)this.isChecked=e};e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true;this.isChecked=this.checked};e.prototype.componentDidLoad=function(){var e=this;Object.defineProperty(this.el,"value",{get:function(){return e.isChecked},configurable:true})};e.prototype.render=function(){var e=this,t=e.type,i=e.color,o=e.isChecked,r=e.name,c=e.disabled;var s=o?{borderColor:i||"04BE02",backgroundColor:i||"04BE02"}:{};return n("input",{type:"checkbox",class:"weui-"+t,style:s,checked:o,name:r,disabled:c,onChange:this.switchChange})};Object.defineProperty(e.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{checked:["function"]}},enumerable:false,configurable:true});return e}());c.style=r}}}));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as e,h as a,g as s}from"./p-30c0639e.js";function i(t){return null!=t?t:""}const h=class{constructor(a){t(this,a),this.onInput=e(this,"input",7),this.onFocus=e(this,"focus",7),this.onBlur=e(this,"blur",7),this.onChange=e(this,"change",7),this.disabled=!1,this.maxlength=140,this.autoFocus=!1,this.hanldeInput=t=>{t.stopPropagation(),this.onInput.emit({value:t.target.value,cursor:t.target.value.length})},this.handleFocus=t=>{this.onFocus.emit({value:t.target.value})},this.handleBlur=t=>{this.onBlur.emit({value:t.target.value})},this.handleChange=t=>{t.stopPropagation(),this.onChange.emit({value:t.target.value})}}componentDidLoad(){Object.defineProperty(this.el,"value",{get:()=>this.textareaRef.value,set:t=>this.value=t,configurable:!0}),this.autoFocus&&this.textareaRef.focus()}render(){const{value:t,placeholder:e,disabled:s,maxlength:h,autoFocus:o,name:r,hanldeInput:n,handleFocus:l,handleBlur:u,handleChange:c}=this;return a("textarea",{ref:t=>{t&&(this.textareaRef=t)},class:"taro-textarea",value:i(t),placeholder:e,name:r,disabled:s,maxlength:h,autofocus:o,onInput:n,onFocus:l,onBlur:u,onChange:c})}get el(){return s(this)}};h.style="taro-textarea-core{display:block;width:300px;height:150px}.taro-textarea{-webkit-appearance:none;cursor:auto;width:100%;height:100%;border:0;display:block;position:relative}.taro-textarea:focus{outline:none}";export{h as taro_textarea_core}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-cf496b3b.system.js"],(function(e){"use strict";var t,n,o,r,i;return{setters:[function(e){t=e.r;n=e.c;o=e.h;r=e.H;i=e.g}],execute:function(){var a='@charset "UTF-8";.taro-checkbox{position:relative;display:inline-block}.taro-checkbox_checked{display:inline-block;min-height:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;outline:0;font-size:23px;border:1px solid #d1d1d1;background-color:#ffffff;border-radius:3px;color:#1AAD19;width:23px;height:23px;position:relative;vertical-align:0;top:5px}.taro-checkbox_checked:checked::before{font-family:"weui";font-style:normal;font-weight:normal;font-variant:normal;text-transform:none;text-align:center;speak:none;display:inline-block;vertical-align:middle;text-decoration:inherit;content:"";color:inherit;font-size:inherit;position:absolute;top:50%;left:50%;-webkit-transform:translate(-50%, -48%) scale(0.73);transform:translate(-50%, -48%) scale(0.73)}';var c=e("taro_checkbox_core",function(){function e(e){var o=this;t(this,e);this.onChange=n(this,"checkboxchange",7);this.value="";this.checked=false;this.isWillLoadCalled=false;this.handleChange=function(e){e.stopPropagation();o.onChange.emit({value:o.value})}}e.prototype.watchId=function(e){if(!this.isWillLoadCalled)return;if(e)this.inputEl.setAttribute("id",e)};e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true};e.prototype.componentDidRender=function(){this.id&&this.el.removeAttribute("id")};e.prototype.render=function(){var e=this;var t=this,n=t.checked,i=t.name,a=t.color,c=t.value;return o(r,{className:"weui-cells_checkbox"},o("input",{ref:function(t){if(!t)return;e.inputEl=t;if(e.id)t.setAttribute("id",e.id)},type:"checkbox",value:c,name:i,class:"taro-checkbox_checked",style:{color:a},checked:n,onChange:this.handleChange}),o("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return i(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{id:["watchId"]}},enumerable:false,configurable:true});return e}());c.style=a;var l=e("taro_checkbox_group_core",function(){function e(e){t(this,e);this.onChange=n(this,"change",7);this.uniqueName=Date.now().toString(36)}e.prototype.function=function(e){e.stopPropagation();if(e.target.tagName!=="TARO-CHECKBOX-CORE")return;var t=this.el.querySelectorAll("taro-checkbox-core");this.value=this.getValues(t);this.onChange.emit({value:this.value})};e.prototype.componentDidLoad=function(){var e=this;var t=this.el.querySelectorAll("taro-checkbox-core");t.forEach((function(t){t.setAttribute("name",e.name||e.uniqueName)}));Object.defineProperty(this.el,"value",{get:function(){if(!e.value){var t=e.el.querySelectorAll("taro-checkbox-core");e.value=e.getValues(t)}return e.value},configurable:true})};e.prototype.getValues=function(e){return Array.from(e).filter((function(e){var t=e.querySelector("input");return t===null||t===void 0?void 0:t.checked})).map((function(e){return e.value}))};e.prototype.render=function(){return o(r,null)};Object.defineProperty(e.prototype,"el",{get:function(){return i(this)},enumerable:false,configurable:true});return e}())}}}));
|