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

feat: Form rule support warningOnly that not block form submit #30829

Merged
merged 25 commits into from
Jun 4, 2021
Merged

Conversation

zombieJ
Copy link
Member

@zombieJ zombieJ commented Jun 2, 2021

[中文版模板 / Chinese template]

🤔 This is a ...

  • New feature
  • Bug fix
  • Site / documentation update
  • Demo update
  • Component style update
  • TypeScript definition update
  • Bundle size optimization
  • Performance optimization
  • Enhancement feature
  • Internationalization
  • Refactoring
  • Code style optimization
  • Test Case
  • Branch merge
  • Other (about what?)

🔗 Related issue link

https://preview-30829-ant-design.surge.sh/components/form-cn/#components-form-demo-warning-only

💡 Background and solution

📝 Changelog

Language Changelog
🇺🇸 English
🇨🇳 Chinese

☑️ Self Check before Merge

⚠️ Please check all items below before review. ⚠️

  • Doc is updated/provided or not needed
  • Demo is updated/provided or not needed
  • TypeScript definition is updated/provided or not needed
  • Changelog is provided or not needed

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2021

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2021

  • 🚨 Please fill changelog in the PR

    • Write with a developer-oriented perspective and narrative method, without describing the details of the repair
    • Describing the problem and the impact on the developer
    • describing the user-first site problem, not your solution
    • Refer: https://ant.design/changelog#4.9.0
  • 🚨 请填写 PR 中的 changelog

    • 请用面向开发者的角度叙述方式撰写,不描述修复细节
    • 描述问题和对开发者的影响
    • 描述用户第一现场的问题,而非你的解决方式
    • 参考:https://ant.design/changelog-cn#4.9.0

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2021

Size Change: +429 B (0%)

Total Size: 831 kB

Filename Size Change
./dist/antd-with-locales.min.js 340 kB +223 B (0%)
./dist/antd.compact.min.css 63.9 kB -28 B (0%)
./dist/antd.dark.min.css 65.2 kB -30 B (0%)
./dist/antd.min.css 64.1 kB -32 B (0%)
./dist/antd.min.js 297 kB +296 B (0%)

compressed-size-action

@BigCkam34578
Copy link

@@ -3,7 +3,17 @@ import { MotionEvent } from 'rc-motion/lib/interface';

// ================== Collapse Motion ==================
const getCollapsedHeight: MotionEventHandler = () => ({ height: 0, opacity: 0 });
const getRealHeight: MotionEventHandler = node => ({ height: node.scrollHeight, opacity: 1 });
const getRealHeight: MotionEventHandler = node => {
const { overflow } = node.style;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这会不会有overflow-x, overflow-y 的属性?

image

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个 overflow 只做覆盖还原用,不在乎它的值的~

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

会给其他值怼没了(忽略我默认值是否合理)

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

或者看这个

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这是否也是预期的?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个代码应该没用了,我去掉它~

@codecov
Copy link

codecov bot commented Jun 3, 2021

Codecov Report

Merging #30829 (513f4d6) into feature (f45f735) will increase coverage by 1.14%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           feature   #30829      +/-   ##
===========================================
+ Coverage    98.81%   99.96%   +1.14%     
===========================================
  Files          363      397      +34     
  Lines         7280     7523     +243     
  Branches      1967     2105     +138     
===========================================
+ Hits          7194     7520     +326     
+ Misses          86        3      -83     
Impacted Files Coverage Δ
components/_util/easings.ts 100.00% <ø> (ø)
components/_util/raf.ts 100.00% <ø> (ø)
components/_util/scrollTo.ts 100.00% <ø> (ø)
components/_util/type.ts 100.00% <ø> (ø)
components/calendar/generateCalendar.tsx 100.00% <ø> (+1.33%) ⬆️
components/calendar/index.tsx 100.00% <ø> (ø)
components/card/Grid.tsx 100.00% <ø> (ø)
components/_util/getScroll.tsx 100.00% <100.00%> (ø)
components/_util/hooks/useFlexGapSupport.ts 100.00% <100.00%> (ø)
components/_util/hooks/useForceUpdate.ts 100.00% <100.00%> (ø)
... and 241 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6fa59e7...513f4d6. Read the comment docs.

@zombieJ zombieJ changed the title [WIP] feat: Form rule support warningOnly that not block form submit feat: Form rule support warningOnly that not block form submit Jun 4, 2021
@zombieJ zombieJ marked this pull request as ready for review June 4, 2021 02:53
@zombieJ
Copy link
Member Author

zombieJ commented Jun 4, 2021

TS 校验那个需要 antd 发包才能对上,先不用管

@zombieJ zombieJ merged commit 7a3bf82 into feature Jun 4, 2021
@zombieJ zombieJ deleted the warning branch June 4, 2021 06:44
@afc163
Copy link
Member

afc163 commented Jun 5, 2021

ci 挂了

@zombieJ
Copy link
Member Author

zombieJ commented Jun 6, 2021

ci 挂了

#30829 (comment)

@afc163
Copy link
Member

afc163 commented Jun 30, 2021

测试覆盖率掉了 3 行。

@zombieJ zombieJ mentioned this pull request Sep 1, 2021
15 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants