-
Notifications
You must be signed in to change notification settings - Fork 108
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(widget): add maxHeight parameter for the widget #5127
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -1,6 +1,6 @@ | |||
{ | |||
"name": "@cowprotocol/widget-lib", | |||
"version": "0.17.0", | |||
"version": "0.18.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to release a new version just after merging the PR
Report too large to display inline |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @shoom3301 , great, thank you!
Please, don't forget to update dev docs with this change :)
And I hope that users will figure out their the best widget height to specify
Summary
https://www.titanxhub.com/swap - if you click "connect wallet" in the widget here, you will see that the modal is displayed not correctly.
It happens because we always take
document.body.offsetHeight
as a max height for the widget.In order to handle that, I've added a new parameter -
maxHeight
.To Test
{"maxHeight": 200}
in "Raw JSON params" field