Nativescript iOS Action Bar Subtitle

℡╲_俬逩灬. 提交于 2019-12-13 04:16:26

问题


I'm attempting to put a subtitle under a title in the action bar on iOS. While there is this solution for Android it doesn't work on iOS at all. Is there any way to do this on iOS?

<ActionBar [title]="This works" [subTitle]="I want a subtitle here"></ActionBar>

回答1:


iOS doesn't have a subtitle option. But you could use a custom title view and wrap two labels one below another.




回答2:


iOS has some sort of subtitle, but it is named as prompt (for more detail, you can see the doc for UINavigationBar).

Unfortunately, you can't set its value from XML, so you need to use some handler - I create simple playground to demonstrate prompt property.



来源:https://stackoverflow.com/questions/54244115/nativescript-ios-action-bar-subtitle

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!