gpt4 book ai didi

angular - Material Design 2 选项卡底部对齐

转载 作者:行者123 更新时间:2023-12-05 08:17:24 25 4
gpt4 key购买 nike

我想让标签在 md-tab-group 的底部对齐,如下所示:

enter image description here

在 Material 1 中使用 md-tabs-align="bottom" 是可能的。 Material 2 中是否有任何可用于此目的的内容?

这是我的代码:

<md-tab-group> 
<md-tab label="Tab One">
Tab One Contents
</md-tab>
<md-tab label="Tab Two">
Tab Two Contents
</md-tab>
</md-tab-group>

最佳答案

对于可能偶然发现这个问题的人。

The Tabs section of the component demo site references the following in the API Reference section

@Input()            | Position of the tab header.
headerPosition |

After looking through the source I found the following:

/** Possible positions for the tab header. */
export type MdTabHeaderPosition = 'above' | 'below';

因此,以下对我有用

<md-tab-group headerPosition="below"> 
<md-tab label="Tab One">
Tab One Contents
</md-tab>
<md-tab label="Tab Two">
Tab Two Contents
</md-tab>
</md-tab-group>

关于angular - Material Design 2 选项卡底部对齐,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41301877/

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