diff --git a/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/ManageNavPages.cs b/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/ManageNavPages.cs index 239834f5c444..3033ce741bb0 100644 --- a/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/ManageNavPages.cs +++ b/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/ManageNavPages.cs @@ -1,7 +1,6 @@ // Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. -using System; using Microsoft.AspNetCore.Mvc.Rendering; namespace Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal @@ -115,8 +114,67 @@ public static class ManageNavPages public static string PageNavClass(ViewContext viewContext, string page) { var activePage = viewContext.ViewData["ActivePage"] as string - ?? System.IO.Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); + ?? Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); return string.Equals(activePage, page, StringComparison.OrdinalIgnoreCase) ? "active" : null; } + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string IndexAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, Index); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string EmailAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, Email); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string ChangePasswordAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, ChangePassword); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string DownloadPersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, DownloadPersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string DeletePersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, DeletePersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string ExternalLoginsAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, ExternalLogins); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string PersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, PersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string TwoFactorAuthenticationAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, TwoFactorAuthentication); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string AriaCurrent(ViewContext viewContext, string page) + { + var activePage = viewContext.ViewData["ActivePage"] as string + ?? Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); + return string.Equals(activePage, page, StringComparison.OrdinalIgnoreCase) ? "page" : null; + } } } diff --git a/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/_ManageNav.cshtml b/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/_ManageNav.cshtml index 4936a2f02375..1c0de0ea0ea6 100644 --- a/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/_ManageNav.cshtml +++ b/src/Identity/UI/src/Areas/Identity/Pages/V4/Account/Manage/_ManageNav.cshtml @@ -1,11 +1,11 @@  diff --git a/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/ManageNavPages.cs b/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/ManageNavPages.cs index 4fd606bbf99f..ad8ad529e1b4 100644 --- a/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/ManageNavPages.cs +++ b/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/ManageNavPages.cs @@ -1,7 +1,6 @@ // Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. -using System; using Microsoft.AspNetCore.Mvc.Rendering; namespace Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal @@ -115,8 +114,67 @@ public static class ManageNavPages public static string PageNavClass(ViewContext viewContext, string page) { var activePage = viewContext.ViewData["ActivePage"] as string - ?? System.IO.Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); + ?? Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); return string.Equals(activePage, page, StringComparison.OrdinalIgnoreCase) ? "active" : null; } + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string IndexAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, Index); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string EmailAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, Email); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string ChangePasswordAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, ChangePassword); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string DownloadPersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, DownloadPersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string DeletePersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, DeletePersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string ExternalLoginsAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, ExternalLogins); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string PersonalDataAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, PersonalData); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string TwoFactorAuthenticationAriaCurrent(ViewContext viewContext) => AriaCurrent(viewContext, TwoFactorAuthentication); + + /// + /// This API supports the ASP.NET Core Identity default UI infrastructure and is not intended to be used + /// directly from your code. This API may change or be removed in future releases. + /// + public static string AriaCurrent(ViewContext viewContext, string page) + { + var activePage = viewContext.ViewData["ActivePage"] as string + ?? Path.GetFileNameWithoutExtension(viewContext.ActionDescriptor.DisplayName); + return string.Equals(activePage, page, StringComparison.OrdinalIgnoreCase) ? "page" : null; + } } } diff --git a/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/_ManageNav.cshtml b/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/_ManageNav.cshtml index 4936a2f02375..1c0de0ea0ea6 100644 --- a/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/_ManageNav.cshtml +++ b/src/Identity/UI/src/Areas/Identity/Pages/V5/Account/Manage/_ManageNav.cshtml @@ -1,11 +1,11 @@  diff --git a/src/Identity/UI/src/PublicAPI.Unshipped.txt b/src/Identity/UI/src/PublicAPI.Unshipped.txt index f94fb217f071..aedc85a9cee0 100644 --- a/src/Identity/UI/src/PublicAPI.Unshipped.txt +++ b/src/Identity/UI/src/PublicAPI.Unshipped.txt @@ -283,22 +283,40 @@ virtual Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Internal.ResendEmailCo ~Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.TwoFactorAuthenticationModel.StatusMessage.set -> void ~Microsoft.AspNetCore.Identity.UI.V5.Pages.Internal.ErrorModel.RequestId.get -> string ~Microsoft.AspNetCore.Identity.UI.V5.Pages.Internal.ErrorModel.RequestId.set -> void +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.AriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext, string page) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.ChangePasswordAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.DeletePersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.DownloadPersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.EmailAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.ExternalLoginsAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.IndexAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.PersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V4.Pages.Account.Manage.Internal.ManageNavPages.TwoFactorAuthenticationAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.AriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext, string page) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ChangePassword.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ChangePasswordAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ChangePasswordNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DeletePersonalData.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DeletePersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DeletePersonalDataNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DownloadPersonalData.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DownloadPersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.DownloadPersonalDataNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.Email.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.EmailAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.EmailNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ExternalLogins.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ExternalLoginsAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.ExternalLoginsNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.Index.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.IndexAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.IndexNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.PageNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext, string page) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.PersonalData.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.PersonalDataAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.PersonalDataNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.TwoFactorAuthentication.get -> string +~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.TwoFactorAuthenticationAriaCurrent(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~static Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Manage.Internal.ManageNavPages.TwoFactorAuthenticationNavClass(Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext) -> string ~virtual Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Internal.ConfirmEmailChangeModel.OnGetAsync(string userId, string email, string code) -> System.Threading.Tasks.Task ~virtual Microsoft.AspNetCore.Identity.UI.V5.Pages.Account.Internal.ConfirmEmailModel.OnGetAsync(string userId, string code) -> System.Threading.Tasks.Task