【发布时间】:2021-05-11 08:34:17
【问题描述】:
我有以下离子代码:
ion-segment-button{
--indicator-box-shadow: transparent!important;
border-radius: 0.5rem !important;
margin: 0;
--background:white;
--color:#2d2e87;
--background-checked: #3880ff !important;
--color-checked: white;
--indicator-color : transparent!important; /* this solution */
}
<ion-content padding>
<ion-segment (ionChange)='onFilterUpdate($event)' value='all' slot="fixed">
<ion-segment-button value='all'>All places</ion-segment-button>
<ion-segment-button value='bookable'>Bookable places</ion-segment-button>
</ion-segment>
<ion-grid>
<ion-row>
<ion-col size='12' size-sm='8' offset-sm='2' text-center>
<ion-card>
<ion-card-header>
<ion-card-title>{{loadedPlaces[0].title}}</ion-card-title>
<ion-card-subtitle>{{loadedPlaces[0].price | currency}}/Night</ion-card-subtitle>
</ion-card-header>
...
离子段固定在顶部,但它像这样流过离子网格:
有人可以建议如何解决此问题,以使分段和网格位于正确的位置吗?
【问题讨论】: