From 160477d612fa2c0db4ef6c7abbb203ac5f5d62da Mon Sep 17 00:00:00 2001 From: sbwalker Date: Thu, 8 Jun 2023 08:39:20 -0400 Subject: [PATCH] add ScrollToPageTop method to ThemeBase --- Oqtane.Client/Themes/ThemeBase.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Oqtane.Client/Themes/ThemeBase.cs b/Oqtane.Client/Themes/ThemeBase.cs index 0528259a..68519430 100644 --- a/Oqtane.Client/Themes/ThemeBase.cs +++ b/Oqtane.Client/Themes/ThemeBase.cs @@ -170,6 +170,12 @@ namespace Oqtane.Themes } } + public async Task ScrollToPageTop() + { + var interop = new Interop(JSRuntime); + await interop.ScrollTo(0, 0, "smooth"); + } + [Obsolete("ContentUrl(int fileId) is deprecated. Use FileUrl(int fileId) instead.", false)] public string ContentUrl(int fileid) {