i’m working on a multi-language app Arabic and English,
and i want to change the font family of the toolbar title based on the platform dir … anyone knows how to do that ?
Hi@a7mdFo2ad
Can you put some code here what you try to implement?
Or can you explain in detail?
thank you for reply
i treid to use ngClass with if condtion and make to each toolbar title font family
<ion-title [ngClass]="(this.Platform.isRTL) ? 'app-home-ar' : 'app-home'">{{ 'PROFILE' | translate:param }}</ion-title>
but i can’t apply the both style cuz ion-titlebar class
sorry Actually iam not clear what you wnat to do
Do you want to change the ion title based on the language am i right?
what you meant by platform dir…
Please add your controller code too
<ion-title [ngClass]="(this.Platform.isRTL) ? 'app-home-ar' : 'app-home'">{{ 'PROFILE' | translate:param }}</ion-title>
anyway this is wrong because ‘this’ key cannot be used in HTML
While using ngclass
You have to mention the class name first followed by the condition like this
<ion-title [ngClass]="{'class1 class2' : (user.id == this.session.userDefaultId), 'class3 class4':(user.id != this.session.userDefaultId)}">
</title>
Hope You understood?
yes change the style based on the language …
dir -> direction
Please try as per above I suggested
You have to mention the class name first followed by the condition
didn’t work
all i want to change the toolbar font family based on platform reflect
You have to post your code here then only some one can help to solve the issue?