如何集中元素
我已经开始使用Radzen学习大麻,并希望在页面上水平居中。我了解到,这样做的唯一方法是将内联CSS应用于元素的属性,但是我应该编写哪些特定的CSS?我是否使用一些引导程序类(在哪里可以找到可以使用的列表?),还是应该使用普通的经典CSS?
<RadzenMenu>
<RadzenMenuItem Text="General" Path="/" Icon="home">
</RadzenMenuItem>
</RadzenMenu>
@code {
}
I've started learning Blazor with Radzen and want to center horizontally a Radzen element on the page. I understood, the only way to do that is to apply inline CSS to an element's property but what specific CSS should I write? Do I use some Bootstrap classes (where to find a list of what I can use?) or should I use plain classic CSS?
<RadzenMenu>
<RadzenMenuItem Text="General" Path="/" Icon="home">
</RadzenMenuItem>
</RadzenMenu>
@code {
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
虽然它与大爆炸或辐射不是很
重要
(ref: https://getbootstrap.com/docs/5.2/5.2/utilities/flex )
CSS:显示:Flex;
Jusify-content:中心;
Though it's not very related to blazor or radzen,
Bootstrap classes : d-flex, justify-content-center
( ref: https://getbootstrap.com/docs/5.2/utilities/flex )
CSS: display: flex;
justify-content: center;