Skip to content
New issue

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

fix(components): [date-picker] fix the logic of checking the date range #13377

Merged
merged 1 commit into from
Aug 24, 2023

Conversation

inottn
Copy link
Contributor

@inottn inottn commented Jun 28, 2023

Please make sure these boxes are checked before submitting your PR, thank you!

  • Make sure you follow contributing guide English | (中文 | Español | Français).
  • Make sure you are merging your commits to dev branch.
  • Add some descriptions and refer to relative issues for your PR.

Description

🤖 Generated by Copilot at b724a20

This pull request enhances the date-picker component with better validation of date ranges based on the disabledDate prop. It also adds a test case to verify the new functionality in date-picker.test.ts.

Related Issue

Fixes #13373

Explanation of Changes

🤖 Generated by Copilot at b724a20

  • Add a new function isValidValue to the panel-date-range component that checks the validity of the selected date range with respect to the disabledDate prop (link)
  • Use the new isValidValue function to emit the correct validation result to the parent date-picker component (link)
  • Add a test case for the date-picker component with the type of daterange and the disabledDate prop, verifying that the input value is updated and validated correctly (link)

@pull-request-triage
Copy link

👋 @inottn, thank you for contributing element-plus.

  • You can comment with /label Components:[component_name] to add a label for which component you are working on.
  • You may join our Discord for staying tuned.

@github-actions
Copy link

Hello @inottn, thank you for contributing to element-plus, please see our guideline to see how to make contribution

@github-actions
Copy link

github-actions bot commented Jun 28, 2023

@github-actions github-actions bot added the CommitMessage::Qualified Qualified commit message label Jun 28, 2023
@github-actions
Copy link

🧪 Playground Preview: https://element-plus.run/?pr=13377
Please comment the example via this playground if needed.

@chendx97
Copy link

chendx97 commented Aug 8, 2023

这个什么时候能合并啊

@inottn
Copy link
Contributor Author

inottn commented Aug 8, 2023

这个什么时候能合并啊

@ryuhangyeong @btea help review? thx.

@inottn
Copy link
Contributor Author

inottn commented Aug 23, 2023

And this PR, thx. @btea @ryuhangyeong

@btea btea merged commit a661de2 into element-plus:dev Aug 24, 2023
13 checks passed
@element-bot element-bot mentioned this pull request Aug 25, 2023
3 tasks
laizuan pushed a commit to laizuan/element-plus that referenced this pull request Sep 5, 2023
consultation-applio pushed a commit to consultation-applio/element-plus that referenced this pull request Nov 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Component] [date-picker] 日期时间选择器如果在文本框输入时间,disabled-date会不生效
5 participants