Tencent / QMUI_iOS

QMUI iOS——致力于提高项目 UI 开发效率的解决方案

Home Page:http://qmuiteam.com/ios

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

QMUISearchController 的 hidesNavigationBarDuringPresentation 设置成 NO 时,在 iOS 17 上 searchBar frame 异常

DarrenKong opened this issue · comments

Bug 表现
问题的具体描述
QMUISearchController 最新代码在 iOS 17 设备上运行,如果 hidesNavigationBarDuringPresentation 设置成 NO 时,在 iOS 17 的设备上 searchBar 的 frame 不是预期结果。在 iOS 13 - iOS 16 设备上正常,仅 iOS 17 不正常。

截图

  1. searchBar 没有获得焦点时截图:
    image
  2. searchBar 获得焦点时截图:
    image

如何重现

  1. 将最新的 QMUIDemo 运行在 iOS 17 设备上,点击 QMUIKit 中的 NSObject+QMUI Component,在 searchBar 获得焦点时,searchBar 会被 NavigationBar 覆盖。
  2. 具体代码可以查阅QMUIDemo QDObjectViewController.m line35

预期的表现
正常情况下,searchBar 获得焦点时,不应该被导航栏覆盖。

其他信息

  • 设备: iPhone 12
  • iOS 版本: [iOS 17.0.2]
  • Xcode 版本: [Xcode 14.2]
  • QMUI 版本: [4.7.0]