<ScrollView scrollY={scrollY} style={{ height: '100vh' }}>
<View style={{ paddingTop: ${sysInfo.statusBarHeight + 50}px
, marginBottom: '50vh' }}>
<Lights
lightsLenght={45}
hsv={hsv}
pNumber={pNumber}
setScrollY={setScrollY}
type={type}
></Lights>
<Control onChangeActive={handleControlChange} />
<View className={styles.pikerColor}>
<View style={{ width: '100%', display: 'flex', justifyContent: 'center' }}>
<LampCirclePickerColor
radius={110}
thumbRadius={15}
hs={{ h: hsv.h, s: hsv.s }}
onTouchEnd={handlePikerColor}
/>
</View>
<View style={{ color: 'black', paddingBottom: '10rpx' }}>
<Text style={{ marginRight: '20rpx' }}>亮度:</Text>
<Text>{hsv.v / 10}</Text>
</View>
<OpacitySlider
min={1}
max={1000}
onTouchMove={v => {
setHsv({ ...hsv, v });
}}
disable={false}
value={hsv.v}
trackBackgroundColor="linear-gradient(270deg, #E5E5E5 2.57%, #000000 100.64%)"
/>
</View>
<View
style={{
width: '100%',
display: 'flex',
justifyContent: 'space-around',
alignItems: 'center',
}}
>
<Button
onClick={() => {
if (pNumber > 0) {
showToast({
title: 第${pNumber}页
,
icon: 'none',
duration: 1000,
});
setPNumber(pNumber - 1);
}
}}
disabled={pNumber === 0}
>
上一页
</Button>
<Button
onClick={() => {
if (pNumber >= 9) return;
showToast({
title: 第${pNumber + 2}页
,
icon: 'none',
duration: 1000,
});
setPNumber(pNumber + 1);
}}
>
下一页
</Button>
</View>
</View>
</ScrollView>
scroll 在滑动时候 LampCirclePickerColor 组价色盘会出现 定位的bug, 色盘不会跟随滑动
LampCirclePickerColor bug
LampCirclePickerColor bug
- Attachments
-
Tags:
Re: LampCirclePickerColor bug
好的,我看了源码是色盘的canvas存在position:absolute;的原因估计