RTL 单词在侧菜单离子



我只想将侧边菜单中的单词向右翻转,我的侧菜单在右边,但即使我在主题文件夹上的 rtl 上应用,这个词仍然使用 LTR

在变量中.scss

$app-direction: rtl;

在加州.html

<ion-header>
<ion-navbar color = "newcolor">
<button ion-button menuToggle right>
<ion-icon name="menu" style="text-align:right"></ion-icon>
</button>
<ion-title style="text-align:right">ألـة الحاسبـة</ion-title>
</ion-navbar>
</ion-header>

您还必须在选择器中编写@include rtl(),以便从右到左翻转以及从左到右@include ltr()使用的函数。下面我给出了page-title类添加到@include rtl()函数以从右向左翻转的示例

卡尔.html

<ion-header>
<ion-navbar color = "newcolor">
<button ion-button menuToggle right>
<ion-icon name="menu" class="page-icon"></ion-icon>
</button>
<ion-title class="page-title">ألـة الحاسبـة</ion-title>
</ion-navbar>
</ion-header>

变量.scss

$app-direction: rtl;
.page-title  {
@include rtl {
// Custom rtl style goes here
text-align:right
}
}

固定标题方向

<ion-title dir="rtl">ألـة الحاسبـة</ion-title>

最新更新