You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Ionic Angular键盘关闭后内容尺寸无法恢复问题求助

问题:关闭键盘后页面内容尺寸无法恢复正常

关闭键盘后,页面内容的实际尺寸无法恢复正常,查看日志未发现错误。我使用了一个app-enter-amount组件实现金额输入功能(需在多个页面复用该组件)。

相关代码

main.page.html

<ion-content>
 <app-enter-amount></app-enter-amount>
</ion-content>
<ion-footer>
 <ion-button>Confirm</ion-button>
 <ion-button>Cancel</ion-button>
</ion-footer>

enter.amount.html

<ion-input type="tel" inputmode="numeric"></ion-input>

问题截图

  • 键盘打开时的页面状态
  • 关闭键盘后的页面状态1
  • 关闭键盘后的页面状态2

我期望关闭键盘后内容尺寸能恢复正常,尝试了网上多种方法均无效,目前考虑放弃组件,在每个页面直接编写金额输入的代码和逻辑,若无法解决该问题的话。若我的问题有遗漏信息,欢迎告知,非常感谢!

内容的提问来源于stack exchange,提问作者Aldon Prince Velasco

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.29 05:52:38