CircleProgress组件新增的thumbColor属性有时不生效,具体为问题描述中2种情况

小程序开发相关产品技术讨论,包括面板、智能小程序、React Native、Ray跨端框架、Panel SDK、微信小程序、小程序开发工具(IDE)及其他开发技术相关等话题


Post Reply
three
Posts: 10

  • Tuya MiniApp IDE 版本信息:关于中查看
    • App 应用版本信息: 设置-关于中进行查看~
    • @ray-js/ray, @ray-js/panel-sdk的版本(如使用ray开发)在package.json查看~
    • 移动设备信息:手机型号及系统
    • 相关代码:可复现该问题的代码内容
    • 日志信息:错误日志或 IDE 运行日志等~
    • 问题描述(复现步骤):
      情况1:配置thumbColor="#ffffff"、onTouchMove={null}、onTouchEnd={null},需要滑动滑块之后才出现滑块填充色,初始为透明;
      情况2:配置thumbColor="#ffffff"、onTouchMove={handleMove}、onTouchEnd={handleEnd},滑块填充色只在滑动了滑块之后的1-2s出现,否则为透明
    • 预期结果:
    • 实际结果:

Tags:
crisiron
Posts: 170

Re: CircleProgress组件新增的thumbColor属性有时不生效,具体为问题描述中2种情况

thumbColor 需要配合 trackColor 属性使用,这个后续迭代单独支持下

代码使用方式如下:
<RayCircleProgress
value={value}
trackColor="#e8a989"
colorList={[
{ offset: 0, color: '#e8a989' },
{ offset: 1, color: '#e8a989' },
]}
thumbColor="#ffffff"
startDegree={135}
offsetDegree={270}
touchCircleStrokeStyle="rgba(0, 0, 0, 0.4)"
thumbBorderWidth={0}
onTouchStart={handleTouchStart}
onTouchMove={handleMove}
onTouchEnd={handleEnd}
/>

three
Posts: 10

Re: CircleProgress组件新增的thumbColor属性有时不生效,具体为问题描述中2种情况

好的,感谢

Post Reply