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: QRCode style.padding should work #45815
Conversation
Run & review this pull request in StackBlitz Codeflow. |
size-limit report 📦
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit a75e92c:
|
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
3070be8
to
c0184c4
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #45815 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 700 700
Lines 11833 11833
Branches 3155 3155
=========================================
Hits 11833 11833
☔ View full report in Codecov by Sentry. |
fbdb5f2
to
db96681
Compare
e0f4686
to
8412209
Compare
8412209
to
8f95928
Compare
[中文版模板 / Chinese template]
🤔 This is a ...
🔗 Related issue link
close #45801
💡 Background and solution
这个修改后,将可以通过
或者
修改默认的 padding。
📝 Changelog
style.padding
is not working.style.padding
时无效的问题。☑️ Self-Check before Merge
🚀 Summary
🤖 Generated by Copilot at 3070be8
This pull request fixes a bug in the
QRCode
component that ignored thestyle.padding
prop. It adds a helper function to handle different padding formats and a test case to verify the component's behavior.🔍 Walkthrough
🤖 Generated by Copilot at 3070be8
style.padding
prop (link, link)getQrCodePadding
to calculate the padding value from different types and formats of the prop incomponents/qr-code/index.tsx
(link)style.padding
prop incomponents/qr-code/__tests__/index.test.tsx
to check the width and height of the canvas element with different values of padding (link)