mirror of
https://gitee.com/ant-design-blazor/ant-design-blazor.git
synced 2024-12-15 01:11:52 +08:00
d2e9c4b247
* feat(module: config-provider): support RTL * add rtl for each component * fix rtl for pagination * add rtl for overlay
21 lines
451 B
C#
21 lines
451 B
C#
using System.Threading.Tasks;
|
|
using Microsoft.JSInterop;
|
|
|
|
namespace AntDesign
|
|
{
|
|
public class ConfigService
|
|
{
|
|
private IJSRuntime _jS;
|
|
|
|
public ConfigService(IJSRuntime js)
|
|
{
|
|
_jS = js;
|
|
}
|
|
|
|
public async Task ChangeDirection(string direction)
|
|
{
|
|
await _jS.InvokeVoidAsync(JSInteropConstants.SetDomAttribute, "html", "class", direction?.ToLowerInvariant());
|
|
}
|
|
}
|
|
}
|