gpt4 book ai didi

html - PWA - IOS 13 深色模式下的状态栏背景和文本颜色

转载 作者:行者123 更新时间:2023-12-02 07:25:00 28 4
gpt4 key购买 nike

Apple 在新的 IOS 13 上引入深色模式后,我的 PWA 状态栏颜色遇到了一些问题。

我曾经将“apple-mobile-web-app-status-bar-style”设置为“black-translucent”,以获得状态栏上带有白色文本的透明背景。现在,根据用户系统主题(浅色或深色),文本颜色从白色变为黑色,反之亦然。因为我的布局使用深色背景,所以结果现在是“几乎黑色”背景上的黑色文本。

有什么解决办法吗?

black-translucent - shows white text - ios12 black-translucent - shows black text - ios13

最佳答案

black-translucent 似乎是此元标记的折旧值。根据用户“furvy”在 apple.com 上的讨论中所说:https://forums.developer.apple.com/thread/89471 。他说:

Today I noticed this in the Safari remote debugger when looking at one of my Web Apps... '"black-translucent" is a deprecated apple-mobile-web-app-status-bar-style value. Support for this value will be removed in a future release.' [...]

这对我的 PWA 来说也很烦人,但这个答案是在 2017 年的,所以可能由于 iOS 12 中的错误它仍然有效,但在 iOS 13 中他们完全删除了它。

关于html - PWA - IOS 13 深色模式下的状态栏背景和文本颜色,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58171234/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com