[英]How can I remove the border from the last ion-item in an ion-list
I have a standard ion-list of ion-items which is dynamically populated.我有一个动态填充的离子项目的标准离子列表。
<ion-list>
<ion-item></ion-item>
<ion-item></ion-item>
<ion-item></ion-item>
</ion-list>
I would like to make it so that the standard border doesn't show up on the last ion-item in the list.我想这样做,以便标准边框不会出现在列表中的最后一个离子项目上。
I've tried the following but it is just removing the border from every item.我已经尝试了以下但它只是从每个项目中删除了边框。
ion-list ion-item:last-child{
--inner-border-width:0;
}
Hello I had misunderstood your question and I thought you wanted to remove the bottom line.你好,我误解了你的问题,我以为你想删除底线。
<ng-container *ngFor="let item of itemList; let last = last;">
<ion-item [lines]="last ? 'none' : 'full'">{{item.value}}</ion-item>
</ng-container>
Best regards and I hope this can help you最好的问候,我希望这可以帮助你
Can you try with this你能试试这个吗
ion-list ion-item:last-child{
--border: none;
--inner-border: none;
}
let me know if this works for you让我知道这是否适合你
and if it doesn't work, then send me a screenshot of the border that's wetting you如果它不起作用,请向我发送润湿您的边框的屏幕截图
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.