taro-react-uilib 1.4.19-5 → 1.4.20
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/components/Echarts/weapp/wx-touch.js +1 -1
- package/dist/components/Echarts/weapp/wx-touch.js.map +1 -1
- package/dist/components/ProgressCircle/index.js +1 -1
- package/dist/components/ProgressCircle/index.js.map +1 -1
- package/dist/index.esm.js +5 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/dist/styles/components/progresscircle.scss +9 -0
- package/dist/styles/components/step.scss +2 -1
- package/lib/components/Echarts/weapp/wx-touch.js +3 -3
- package/lib/components/Echarts/weapp/wx-touch.js.map +1 -1
- package/lib/components/ProgressCircle/index.js +2 -2
- package/lib/components/ProgressCircle/index.js.map +1 -1
- package/package.json +1 -1
- package/types/components/ProgressCircle/index.d.ts +1 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
function t(t){for(var
|
|
1
|
+
function t(t){for(var n=0;n<t.touches.length;++n){var o=t.touches[n];o.offsetX=o.x,o.offsetY=o.y}return t}function n(n){var o,e=n.chart,a=n.event;if(e&&a.touches.length>0){var r=a.touches[0],u=null===(o=e.getZr())||void 0===o?void 0:o.handler;null==u||u.dispatch("mousedown",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.dispatch("mousemove",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.processGesture(t(a),"start")}}function o(n){var o,e=n.chart,a=n.event;if(e&&a.touches.length>0){var r=a.touches[0],u=null===(o=e.getZr())||void 0===o?void 0:o.handler;null==u||u.dispatch("mousedown",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.dispatch("mousemove",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.processGesture(t(a),"start")}}function e(n){var o,e=n.chart,a=n.event;if(e){var r=a.changedTouches?a.changedTouches[0]:{},u=null===(o=e.getZr())||void 0===o?void 0:o.handler;null==u||u.dispatch("mouseup",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.dispatch("click",{zrX:r.x,zrY:r.y,preventDefault:function(){},stopImmediatePropagation:function(){},stopPropagation:function(){}}),null==u||u.processGesture(t(a),"end")}}export{e as touchEnd,o as touchMove,n as touchStart,t as wrapTouch};
|
|
2
2
|
//# sourceMappingURL=wx-touch.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"wx-touch.js","sources":["../../../../src/components/Echarts/weapp/wx-touch.ts"],"sourcesContent":["export function wrapTouch(event) {\n for (let i = 0; i < event.touches.length; ++i) {\n const touch = event.touches[i];\n touch.offsetX = touch.x;\n touch.offsetY = touch.y;\n }\n return event;\n}\n\nexport function touchStart({ chart, event }) {\n if (chart && event.touches.length > 0) {\n const touch = event.touches[0];\n const handler = chart.getZr()?.handler;\n handler?.dispatch(\"mousedown\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.dispatch(\"mousemove\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler
|
|
1
|
+
{"version":3,"file":"wx-touch.js","sources":["../../../../src/components/Echarts/weapp/wx-touch.ts"],"sourcesContent":["export function wrapTouch(event) {\n for (let i = 0; i < event.touches.length; ++i) {\n const touch = event.touches[i];\n touch.offsetX = touch.x;\n touch.offsetY = touch.y;\n }\n return event;\n}\n\nexport function touchStart({ chart, event }) {\n if (chart && event.touches.length > 0) {\n const touch = event.touches[0];\n const handler = chart.getZr()?.handler;\n handler?.dispatch(\"mousedown\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.dispatch(\"mousemove\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.processGesture(wrapTouch(event), \"start\");\n }\n}\n\nexport function touchMove({ chart, event }) {\n if (chart && event.touches.length > 0) {\n const touch = event.touches[0];\n const handler = chart.getZr()?.handler;\n handler?.dispatch(\"mousedown\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.dispatch(\"mousemove\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.processGesture(wrapTouch(event), \"start\");\n }\n}\n\nexport function touchEnd({ chart, event }) {\n if (chart) {\n const touch = event.changedTouches ? event.changedTouches[0] : {};\n const handler = chart.getZr()?.handler;\n handler?.dispatch(\"mouseup\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.dispatch(\"click\", {\n zrX: touch.x,\n zrY: touch.y,\n preventDefault: () => {},\n stopImmediatePropagation: () => {},\n stopPropagation: () => {},\n });\n handler?.processGesture(wrapTouch(event), \"end\");\n }\n}\n"],"names":["wrapTouch","event","i","touches","length","touch","offsetX","x","offsetY","y","touchStart","_a","chart","handler","_b","getZr","dispatch","zrX","zrY","preventDefault","stopImmediatePropagation","stopPropagation","processGesture","touchMove","touchEnd","changedTouches"],"mappings":"AAAM,SAAUA,EAAUC,GACxB,IAAK,IAAIC,EAAI,EAAGA,EAAID,EAAME,QAAQC,SAAUF,EAAG,CAC7C,IAAMG,EAAQJ,EAAME,QAAQD,GAC5BG,EAAMC,QAAUD,EAAME,EACtBF,EAAMG,QAA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,IAAMP,EAAQJ,EAAMwB,eAAiBxB,EAAMwB,eAAe,GAAK,GACzDZ,EAAyB,QAAfC,EAAAF,EAAMG,eAAS,IAAAD,OAAA,EAAAA,EAAAD,QAC/BA,SAAAA,EAASG,SAAS,UAAW,CAC3BC,IAAKZ,EAAME,EACXW,IAAKb,EAAMI,EACXU,eAAgB,WAAQ,EACxBC,yBAA0B,WAAQ,EAClCC,gBAAiB,WAAQ,IAE3BR,SAAAA,EAASG,SAAS,QAAS,CACzBC,IAAKZ,EAAME,EACXW,IAAKb,EAAMI,EACXU,eAAgB,WAAQ,EACxBC,yBAA0B,WAAQ,EAClCC,gBAAiB,WAAQ,IAE3BR,SAAAA,EAASS,eAAetB,EAAUC,GAAQ,MAC3C,CACH"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as
|
|
1
|
+
import{__assign as e}from"../node_modules/tslib/tslib.es6.js";import o from"react";import r from"classnames";import{View as t}from"@tarojs/components";import{pxTransform as s}from"../src/utils/index.js";var a=function(a){var l=a.percent,c=void 0===l?88:l,n=a.className,m=a.doneColor,i=void 0===m?"#DDD":m,d=a.backgroundColor,p=void 0===d?"rgba(0,0,0, 0.25)":d,u=a.maskColor,f=void 0===u?"#FFF":u,g=a.size,x=a.style,C=a.text,h=r("xh-progress-circle",n),v=g?{width:s(g),height:s(g)}:{},b=100===c,k=e(e(e({},v),{"--percent":"".concat(c/100,"turn"),"--doneColor":i,"--backgroundColor":p,"--maskContent":"percent","--maskColor":f}),x);return o.createElement(t,{className:h,style:k},C?o.createElement(t,{className:"xh-progress-circle-text"},C):b?o.createElement(t,{className:"xh-progress-circle-done"}):null)};export{a as default};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/ProgressCircle/index.tsx"],"sourcesContent":["import React from \"react\";\nimport classNames from \"classnames\";\nimport { View } from \"@tarojs/components\";\nimport { pxTransform } from \"@/utils\";\nimport { XHComponentCommonProps } from \"../../types\";\nimport \"./index.scss\";\n\nexport type ProgressProps = {\n percent: number;\n // showPercent?: boolean;\n doneColor?: string;\n size?: number;\n backgroundColor?: string;\n maskColor?: string;\n style?: React.CSSProperties;\n} & XHComponentCommonProps;\n\nconst Progress: React.FC<ProgressProps> = props => {\n const {\n percent = 88,\n className,\n // showPercent = false,\n doneColor = \"#DDD\",\n backgroundColor = \"rgba(0,0,0, 0.25)\",\n maskColor = \"#FFF\",\n size,\n style,\n } = props;\n const progresslcs = classNames(\"xh-progress-circle\", className);\n\n const finalSize: React.CSSProperties = size\n ? {\n width: pxTransform(size),\n height: pxTransform(size),\n }\n : {};\n\n const done = percent === 100;\n\n const finalStyle = {\n ...finalSize,\n \"--percent\": `${percent / 100}turn`,\n \"--doneColor\": doneColor,\n \"--backgroundColor\": backgroundColor,\n \"--maskContent\": \"percent\",\n \"--maskColor\": maskColor,\n ...style,\n };\n\n return (\n <View className={progresslcs} style={finalStyle}>\n {done
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/ProgressCircle/index.tsx"],"sourcesContent":["import React from \"react\";\nimport classNames from \"classnames\";\nimport { View } from \"@tarojs/components\";\nimport { pxTransform } from \"@/utils\";\nimport { XHComponentCommonProps } from \"../../types\";\nimport \"./index.scss\";\n\nexport type ProgressProps = {\n percent: number;\n // showPercent?: boolean;\n doneColor?: string;\n size?: number;\n backgroundColor?: string;\n maskColor?: string;\n style?: React.CSSProperties;\n text?: React.ReactNode;\n} & XHComponentCommonProps;\n\nconst Progress: React.FC<ProgressProps> = props => {\n const {\n percent = 88,\n className,\n // showPercent = false,\n doneColor = \"#DDD\",\n backgroundColor = \"rgba(0,0,0, 0.25)\",\n maskColor = \"#FFF\",\n size,\n style,\n text,\n } = props;\n const progresslcs = classNames(\"xh-progress-circle\", className);\n\n const finalSize: React.CSSProperties = size\n ? {\n width: pxTransform(size),\n height: pxTransform(size),\n }\n : {};\n\n const done = percent === 100;\n\n const finalStyle = {\n ...finalSize,\n \"--percent\": `${percent / 100}turn`,\n \"--doneColor\": doneColor,\n \"--backgroundColor\": backgroundColor,\n \"--maskContent\": \"percent\",\n \"--maskColor\": maskColor,\n ...style,\n };\n\n return (\n <View className={progresslcs} style={finalStyle}>\n {text ? (\n <View className=\"xh-progress-circle-text\">{text}</View>\n ) : done ? (\n <View className=\"xh-progress-circle-done\"></View>\n ) : null}\n </View>\n );\n};\n\nexport default Progress;\n"],"names":["Progress","props","_a","percent","className","_b","doneColor","_c","backgroundColor","_d","maskColor","size","style","text","progresslcs","classNames","finalSize","width","pxTransform","height","done","finalStyle","__assign","concat","React","View","createElement"],"mappings":"2MAkBM,IAAAA,EAAoC,SAAAC,GAEtC,IAAAC,EASED,EATUE,QAAZA,OAAO,IAAAD,EAAG,GAAEA,EACZE,EAQEH,EAROG,UAETC,EAMEJ,EANgBK,UAAlBA,aAAY,OAAMD,EAClBE,EAKEN,EALmCO,gBAArCA,OAAe,IAAAD,EAAG,oBAAmBA,EACrCE,EAIER,YAJFS,OAAY,IAAAD,EAAA,SACZE,EAGEV,OAFFW,EAEEX,QADFY,EACEZ,OACEa,EAAcC,EAAW,qBAAsBX,GAE/CY,EAAiCL,EACnC,CACEM,MAAOC,EAAYP,GACnBQ,OAAQD,EAAYP,IAEtB,GAEES,EAAmB,MAAZjB,EAEPkB,EAAUC,EAAAA,EAAAA,EAAA,CAAA,EACXN,GAAS,CACZ,YAAa,GAAGO,OAAApB,EAAU,IAAS,QACnC,cAAeG,EACf,oBAAqBE,EACrB,gBAAiB,UACjB,cAAeE,IACZE,GAGL,OACEY,gBAACC,EAAI,CAACrB,UAAWU,EAAaF,MAAOS,GAClCR,EACCW,gBAACC,EAAI,CAACrB,UAAU,2BAA2BS,GACzCO,EACFI,EAACE,cAAAD,GAAKrB,UAAU,4BACd,KAGV"}
|