We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
5.30.0
No response
https://codesandbox.io/p/sandbox/vibrant-jasper-g7yz6n?file=%2Fapp.tsx%3A18%2C18
CalendarPickerView 相关组件设置了 min 属性后 jumpTo jumpToToday 等方法不生效
复现链接:https://codesandbox.io/p/sandbox/vibrant-jasper-g7yz6n?file=%2Fapp.tsx%3A18%2C18
The text was updated successfully, but these errors were encountered:
确实是这样
Sorry, something went wrong.
预期是怎样的,调用 jumpTo jumpToToday 方法时,第一个渲染日期月份就是 jumpTo 传参的月份/当天的日期月份,原先展示的第一个就看不到了。 如 当前日期是 2024-01,jumpTo(2025-01) 就看不到 2024-01了。 代码中有下边的逻辑:
const minDay = useMemo( () => (props.min ? dayjs(props.min) : current), [props.min, current] )
如果设置了最小值,那开始渲染的日期就是从最小值日期开始,所以 jumpTo jumpToToday 等方法不生效。 #6425
感觉可以重写一下
很多业务场景会有最大最小值,定位到当前选中的日期,这样体验会好很多。
No branches or pull requests
Version of antd-mobile
5.30.0
Operating system and its version
No response
Browser and its version
No response
Sandbox to reproduce
https://codesandbox.io/p/sandbox/vibrant-jasper-g7yz6n?file=%2Fapp.tsx%3A18%2C18
What happened?
CalendarPickerView 相关组件设置了 min 属性后 jumpTo jumpToToday 等方法不生效
复现链接:https://codesandbox.io/p/sandbox/vibrant-jasper-g7yz6n?file=%2Fapp.tsx%3A18%2C18
Relevant log output
No response
The text was updated successfully, but these errors were encountered: