gpt4 book ai didi

ionic-framework - Ionic AlertController 和 HTML 代码

转载 作者:行者123 更新时间:2023-12-04 07:16:10 24 4
gpt4 key购买 nike

您好想要这样的东西,并将 css 分配给每个 div 和地址 block 。可能吗???

let alert = this.alertCtrl.create({
title: 'Contact Us',
subTitle: `
<div class="address-block pp-notes-row">

<address></address>
</div>
`,
buttons: ['OK'],
cssClass: `
.alert-wrapper {
width: 100%
}

.address-block {
text-align: left;
}
`
});
alert.present();

最佳答案

你可以这样做

let alert = this.alertCtrl.create({
title: '<h1 class="c-no-margin winner-alert-title">Congratulations!</h1>',
message: '<div>' +
'<p class="c-no-margin">You are the WINNER, now please submit your details to your favourite celebrity and get video call.</p>' +
'</div>',
buttons: [
{
text: 'Select Celebrity',
handler: () => {
this.navCtrl.push("CelebrityList");
}
}
]
});
alert.present();

关于ionic-framework - Ionic AlertController 和 HTML 代码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42803080/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com