OGeek|极客世界-中国程序员成长平台

标题: ios - 如何在导航栏ios上重叠图像 [打印本页]

作者: 菜鸟教程小白    时间: 2022-12-11 22:26
标题: ios - 如何在导航栏ios上重叠图像

大家可以看到,在图片的顶部有一个空白状态栏(white bar)

blank space

我的问题:

它可以在状态栏上使用我的封面(图片)吗?

我的代码:

profile.ts

<ion-content *ngIf="showLogin == false" no-bounce class="bg-modal">
    <div class="header-image">
        <img src="../assets/imgs/Tkm-resources/Capa.png" onerror="this.src = '../assets/imgs/Tkm-resources/Capa.png'"/>
    </div>

    <div class="main-content" text-wrap text-center>

        <div class="circular">
            <img no-border src="{{ usuario.avatar }}"
                 onerror="this.src='../../assets/imgs/person-flat.png'" (click)="changePicture()"/>
        </div>
        <h6 no-margin padding-top>{{ usuario.nome }}</h6>
        <span color="ticket-grey">{{ usuario.email }}</span>
        <div>
            <ion-row margin-top  (click)="onClickLogout()">
                <ion-icon name="ios-exit" item-left color="primary"></ion-icon>
                <span margin-left> Deslogar</span>
            </ion-row>
        </div>
    </div>
</ion-content>



Best Answer-推荐答案


为了删除这些空白,您可以在元标记中添加以下内容:

viewport-fit=cover

例子:

<meta name="viewport" content-type="initial-scale=1, maximum-scale=1, user-scalable=no, viewport-fit=cover">

关于ios - 如何在导航栏ios上重叠图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55126864/






欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://ogeek.cn/) Powered by Discuz! X3.4