Ion-slide 有一个内置的 transform:translate3d 属性,我该如何删除它?

问题描述

我正在接管一个带有幻灯片的离子项目,我不明白我是如何取消内置的 translate3d 的。 我需要移除它才能做一个位置:固定在幻灯片中的一个按钮上。 我尝试通过 javascript 获取 swiper-wrapper 类并在其上放置一个 translate3d(0,0),但它并没有解决问题。 以下是有关幻灯片的文档:https://ionicframework.com/docs/api/slides

div 的 html:

<div class="fixeddiv" *ngIf="positionActive <= i+1 && indice.type == 'itinerary'">
                                <button [disabled]="(distance > 10 && userLat && userLng) ? true : false" class="fixedbutton btn quizz__submit" (click)="validationItinerary(i)">
                                    {{ 'hunt-detail.quizz.place.btn' | translate }}
                                </button>
                            </div>

CSS:

.fixeddiv{
    position:fixed;
    background-color: white;
    border-radius: 30 30 0px 0px;
    Box-shadow: 60 -10px 0px 20px rgba(37,32,0.12);
    padding: 30px 30px 43px 30px;
    bottom:0px;
    left:0px;
    width:100%;
}

修复 translate3d 的 Javascript:

const temp = Array.from(document.getElementsByClassName('swiper-wrapper') as HTMLCollectionOf<HTMLElement>)
        temp.forEach(element=>{
            element.style.transform='translate3d(0,0)'
        })
```
So far I'm working with a solid 320px as it is the width of my testing screen,the current translate3d is (-320px,0)

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)