diff --git a/.all-contributorsrc b/.all-contributorsrc
index 50c79429a8d..d96ec12168e 100644
--- a/.all-contributorsrc
+++ b/.all-contributorsrc
@@ -3177,6 +3177,42 @@
"contributions": [
"code"
]
+ },
+ {
+ "login": "davidpuplava",
+ "name": "David Puplava",
+ "avatar_url": "https://avatars.githubusercontent.com/u/5144137?v=4",
+ "profile": "https://www.davidpuplava.com",
+ "contributions": [
+ "code"
+ ]
+ },
+ {
+ "login": "shinexyt",
+ "name": "Hanming Xing",
+ "avatar_url": "https://avatars.githubusercontent.com/u/12826837?v=4",
+ "profile": "https://github.com/shinexyt",
+ "contributions": [
+ "code"
+ ]
+ },
+ {
+ "login": "XopcT",
+ "name": "Vladimir Verbitsky",
+ "avatar_url": "https://avatars.githubusercontent.com/u/8039133?v=4",
+ "profile": "https://github.com/XopcT",
+ "contributions": [
+ "code"
+ ]
+ },
+ {
+ "login": "matTrabolsi",
+ "name": "matTrabolsi",
+ "avatar_url": "https://avatars.githubusercontent.com/u/72926503?v=4",
+ "profile": "https://github.com/matTrabolsi",
+ "contributions": [
+ "code"
+ ]
}
],
"skipCi": true,
diff --git a/.dockerignore b/.dockerignore
index 86de177373f..6c08ef8ca28 100644
--- a/.dockerignore
+++ b/.dockerignore
@@ -1,16 +1,6 @@
-# ignore all
-**
-
-# Except src for building
-!./src/*
-!Directory.Build.props
-
-# TODO : Remove this line when Docker Buildkit works in Windows
-!/.build/release/*
-
# Ignore any App_Data folder
**/App_Data/
-# Ignore all prebuild
+# Ignore all built assets
**/[b|B]in/
**/[O|o]bj/
diff --git a/.editorconfig b/.editorconfig
index 7181698744e..bbb5af24d58 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -78,6 +78,8 @@ dotnet_diagnostic.IDE0303.severity = silent # Co
dotnet_diagnostic.IDE0078.severity = silent # Use pattern matching
+dotnet_diagnostic.IDE0130.severity = silent # Namespace does not match folder structure
+
dotnet_style_prefer_conditional_expression_over_assignment = silent # Remove redundant equality, e.g. Disabled == false
dotnet_diagnostic.CA2263.severity = warning # Prefer generic overload when type is known
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
index 33005a6079f..2514eeffeee 100644
--- a/.git-blame-ignore-revs
+++ b/.git-blame-ignore-revs
@@ -1 +1,7 @@
+# .git-blame-ignore-revs
+
+# Define formatting rules (#16567)
+657342d05a221dfaba1fdf46813c0161dd12d4ec
+
+# Convert to file-scope namespaces (#16539)
05730cfeb221680240feb3d9edca563bc388a1ef
diff --git a/.github/ISSUE_TEMPLATE/release.md b/.github/ISSUE_TEMPLATE/release.md
index 7e9d91e9d3a..a841f6f7ea7 100644
--- a/.github/ISSUE_TEMPLATE/release.md
+++ b/.github/ISSUE_TEMPLATE/release.md
@@ -27,7 +27,6 @@ Update the source, so everything looks like on the new version.
- [ ] Update the `OrchardCore.Commons.props` file with `` such that preview build numbers are not injected in packages. Verify the `VersionPrefix` tag matches the released version.
- [ ] Update module versions in `src/OrchardCore/OrchardCore.Abstractions/Modules/Manifest/ManifestConstants.cs`.
- [ ] Create a new milestone.
-- [ ] Change the Orchard Core version in the project templates, more specifically in `dotnetcli.host.json` and `template.json` files.
- [ ] Add final updates to the release notes in the documentation. It should include the following, at least:
- Overview of the release's highlights and goals. What do you want people to remember this release for?
- Prerequisites. What framework version do you need, anything else to work with Orchard?
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index a0ae63c5d47..bdbcf2043ab 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -1,11 +1,21 @@
version: 2
updates:
- - package-ecosystem: "nuget" # See documentation for possible values
- directory: "/" # Location of package manifests
+ # Dependabot can handle at most 150 "manifests", so for NuGet, csprojs referencing packages (see docs:
+ # https://docs.github.com/en/enterprise-cloud@latest/code-security/supply-chain-security/understanding-your-software-supply-chain/troubleshooting-the-dependency-graph#are-there-limits-which-affect-the-dependency-graph-data).
+ # Thus, it would fail for the whole solution.
+ # Grouping updates per directories or otherwise trying to have smaller batches is unnecessary, because due to
+ # centralized package management, Dependabot will find all dependencies from any project. So, just processing the
+ # OrchardCore project.
+ - package-ecosystem: "nuget"
+ directory: "/src/OrchardCore/OrchardCore"
schedule:
interval: "weekly"
groups:
- # Grouped version updates configuration
all-dependencies:
patterns:
- "*"
+ ignore:
+ # We'll update GraphQL for v3 because it's breaking, see https://github.com/OrchardCMS/OrchardCore/issues/16826.
+ - dependency-name: "GraphQL*"
+ # See the corresponding comment in Directory.Packages.props.
+ - dependency-name: "System.Drawing.Common"
diff --git a/.github/workflows/first_time_contributor.yml b/.github/workflows/first_time_contributor.yml
index a4cb9cc6c18..a557c023a30 100644
--- a/.github/workflows/first_time_contributor.yml
+++ b/.github/workflows/first_time_contributor.yml
@@ -16,6 +16,7 @@ jobs:
# directly.
- uses: OrchardCMS/welcome-action@task/update-to-node-20
with:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
FIRST_ISSUE_COMMENT: >
Thank you for submitting your first issue, awesome! 🚀 We're thrilled to receive your input. If you haven't
completed the template yet, please take a moment to do so. This ensures that we fully understand your feature
diff --git a/.gitignore b/.gitignore
index e82568c0a66..564c6bdfcfa 100644
--- a/.gitignore
+++ b/.gitignore
@@ -200,15 +200,14 @@ wwwroot
!src/OrchardCore.Themes/**/wwwroot
!src/OrchardCore.Modules/**/Localization/**/*.po
!src/OrchardCore.Themes/**/Localization/**/*.po
-!src/Templates/**/content/**
-src/Templates/**/content/**/[Bb]in/
-src/Templates/**/content/**/[Oo]bj/
-.template.config/
/OrchardCore.sln.GhostDoc.xml
+# Templates
+# .template.config folders are generated by our own msbuild task that injects the build version
+src/Templates/**/content/**/.template.config/
+
# Rider
/.idea
# BenchmarkDotNet artifacts
BenchmarkDotNet.Artifacts
-
diff --git a/Directory.Build.props b/Directory.Build.props
index 658a1de0111..61e0d8aae96 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -47,9 +47,6 @@
$(NoWarn);CA2201
-
- $(NoWarn);CA1727
-
$(NoWarn);CA1861
diff --git a/Directory.Packages.props b/Directory.Packages.props
index e8cd3979080..cc1bd445047 100644
--- a/Directory.Packages.props
+++ b/Directory.Packages.props
@@ -1,51 +1,46 @@
-
true
+ true
-
- true
- true
2.3.0
-
-
+
-
+
+
-
+
-
+
-
-
-
-
-
-
+
+
+
+
+
+
-
-
+
+
-
+
-
-
-
-
-
+
+
+
-
-
-
-
-
-
+
+
+
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+
-
-
+
+
@@ -93,10 +85,13 @@
-
-
-
-
+
+
+
+
+
+
+
-
+
-
-
- 8.0.8
- 8.0.8
+ 8.0.10
+ 8.0.10
-
-
@@ -154,11 +145,9 @@
-
-
-
+
\ No newline at end of file
diff --git a/Dockerfile b/Dockerfile
index 7adafe714ea..3cb0f13bb44 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,23 +1,25 @@
-FROM --platform=$BUILDPLATFORM golang:alpine AS build
+# TARGETARCH and TARGETOS are set automatically when --platform is provided.
+FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build-env
ARG TARGETOS
-
-FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build-env
LABEL stage=build-env
-WORKDIR /app
+WORKDIR /source
-# Copy and build
-COPY ./src /app
-COPY Directory.Build.props /
+# copy required files for building
+# .dockerignore excludes App_Data and binaries from these
+COPY ./src ./src
+COPY Directory.Build.props .
+COPY Directory.Packages.props .
-RUN dotnet publish /app/OrchardCore.Cms.Web -c Release -o ./build/release --framework net8.0 /p:RunAnalyzers=false
+# build, results are placed in /app
+RUN dotnet publish src/OrchardCore.Cms.Web/OrchardCore.Cms.Web.csproj -c Release -o /app --framework net8.0 /p:RunAnalyzers=false
-# Build runtime image
+# build runtime image
FROM mcr.microsoft.com/dotnet/aspnet:8.0-nanoserver-1809 AS build_windows
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS build_linux
FROM build_${TARGETOS} AS aspnet
EXPOSE 80
-ENV ASPNETCORE_URLS http://+:80
+ENV ASPNETCORE_URLS=http://+:80
WORKDIR /app
-COPY --from=build-env /app/build/release .
+COPY --from=build-env /app/ .
ENTRYPOINT ["dotnet", "OrchardCore.Cms.Web.dll"]
diff --git a/NuGet.config b/NuGet.config
index fdb4bf7ac2a..84081b7aa33 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -3,8 +3,25 @@
-
+
+
+
+
diff --git a/OrchardCore.sln b/OrchardCore.sln
index e2b57d6f876..172cbd5cfc9 100644
--- a/OrchardCore.sln
+++ b/OrchardCore.sln
@@ -525,6 +525,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Rules.Core", "s
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Queries.Core", "src\OrchardCore\OrchardCore.Queries.Core\OrchardCore.Queries.Core.csproj", "{61B358F2-702C-40AA-9DF7-7121248FE6DE}"
EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OrchardCore.Sms.Azure", "src\OrchardCore.Modules\OrchardCore.Sms.Azure\OrchardCore.Sms.Azure.csproj", "{013C8BBF-6879-4B47-80C9-A466923E45E5}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -1389,6 +1391,10 @@ Global
{61B358F2-702C-40AA-9DF7-7121248FE6DE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{61B358F2-702C-40AA-9DF7-7121248FE6DE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{61B358F2-702C-40AA-9DF7-7121248FE6DE}.Release|Any CPU.Build.0 = Release|Any CPU
+ {013C8BBF-6879-4B47-80C9-A466923E45E5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {013C8BBF-6879-4B47-80C9-A466923E45E5}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {013C8BBF-6879-4B47-80C9-A466923E45E5}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {013C8BBF-6879-4B47-80C9-A466923E45E5}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -1629,6 +1635,7 @@ Global
{E8A1097D-A65A-4B17-A3A2-F50D79552732} = {A066395F-6F73-45DC-B5A6-B4E306110DCE}
{4BAA08A2-878C-4B96-86BF-5B3DB2B6C2C7} = {F23AC6C2-DE44-4699-999D-3C478EF3D691}
{61B358F2-702C-40AA-9DF7-7121248FE6DE} = {F23AC6C2-DE44-4699-999D-3C478EF3D691}
+ {013C8BBF-6879-4B47-80C9-A466923E45E5} = {A066395F-6F73-45DC-B5A6-B4E306110DCE}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {46A1D25A-78D1-4476-9CBF-25B75E296341}
diff --git a/README.md b/README.md
index 51afb895a40..425242463c7 100644
--- a/README.md
+++ b/README.md
@@ -10,10 +10,11 @@ Orchard Core consists of two distinct projects:
[![BSD-3-Clause License](https://img.shields.io/badge/license-BSD--3--Clause-blue.svg)](LICENSE)
[![Documentation](https://readthedocs.org/projects/orchardcore/badge/)](https://docs.orchardcore.net/)
[![Crowdin](https://badges.crowdin.net/orchard-core/localized.svg)](https://crowdin.com/project/orchard-core)
+[![Discord](https://img.shields.io/discord/551136772243980291?color=%237289DA&label=OrchardCore&logo=discord&logoColor=white&style=flat-square)](https://orchardcore.net/discord)
## Build Status
-Stable (`release/1.8.3`):
+Stable (`release/2.0`):
[![Build status](https://github.com/OrchardCMS/OrchardCore/actions/workflows/release_ci.yml/badge.svg)](https://github.com/OrchardCMS/OrchardCore/actions?query=workflow%3A%22Release+-+CI%22)
[![NuGet](https://img.shields.io/nuget/v/OrchardCore.Application.Cms.Targets.svg)](https://www.nuget.org/packages/OrchardCore.Application.Cms.Targets)
@@ -23,7 +24,7 @@ Nightly (`main`):
[![Build status](https://github.com/OrchardCMS/OrchardCore/actions/workflows/preview_ci.yml/badge.svg)](https://github.com/OrchardCMS/OrchardCore/actions?query=workflow%3A%22Preview+-+CI%22)
[![Cloudsmith](https://api-prd.cloudsmith.io/badges/version/orchardcore/preview/nuget/OrchardCore.Application.Cms.Targets/latest/x/?render=true&badge_token=gAAAAABey9hKFD_C-ZIpLvayS3HDsIjIorQluDs53KjIdlxoDz6Ntt1TzvMNJp7a_UWvQbsfN5nS7_0IbxCyqHZsjhmZP6cBkKforo-NqwrH5-E6QCrJ3D8%3D)](https://cloudsmith.io/~orchardcore/repos/preview/packages/detail/nuget/OrchardCore.Application.Cms.Targets/latest/)
-## Project Status: v1.8.3
+## Project Status: v2.0.2
The software is production-ready, and capable of serving large mission-critical applications as well, and we're not aware of any fundamental bugs or missing features we deem crucial. Orchard Core continues to evolve, with each version bringing new improvements, and keeping up with the cutting-edge of .NET.
diff --git a/mkdocs.yml b/mkdocs.yml
index 3f005a20504..1a8c392cb2a 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -5,11 +5,12 @@ theme:
logo: assets/images/orchard-logo.png
favicon: assets/images/favicon.png
features:
- - navigation.footer
+ - content.tabs.link
- header.autohide
+ - navigation.footer
- navigation.instant
- navigation.tabs
- - content.tabs.link
+ - navigation.top
palette:
- media: "(prefers-color-scheme: light)"
scheme: default
@@ -54,7 +55,7 @@ validation:
# Add files here that are intentionally not in the navigation and thus omitted_files shouldn't warn about them.
not_in_nav: |
samples/
- releases/2.0.0.md
+ releases/2.1.0.md
# Extensions
markdown_extensions:
@@ -196,6 +197,7 @@ nav:
- Shortcodes: reference/modules/Shortcodes/README.md
- Sitemaps: reference/modules/Sitemaps/README.md
- SMS: reference/modules/Sms/README.md
+ - Azure Communication SMS: reference/modules/Sms.Azure/README.md
- Spatial: reference/modules/Spatial/README.md
- XML-RPC: reference/modules/XmlRpc/README.md
- Menu: reference/modules/Menu/README.md
@@ -271,6 +273,10 @@ nav:
- Owners: resources/owners/README.md
- Workshops: resources/workshops/README.md
- Releases:
+ - 2.0.2: releases/2.0.2.md
+ - 2.0.1: releases/2.0.1.md
+ - 2.0.0: releases/2.0.0.md
+ - 1.8.4: releases/1.8.4.md
- 1.8.3: releases/1.8.3.md
- 1.8.2: releases/1.8.2.md
- 1.8.1: releases/1.8.1.md
diff --git a/src/OrchardCore.Build/OrchardCore.Commons.props b/src/OrchardCore.Build/OrchardCore.Commons.props
index 896f8eddf95..ea4fa9d60eb 100644
--- a/src/OrchardCore.Build/OrchardCore.Commons.props
+++ b/src/OrchardCore.Build/OrchardCore.Commons.props
@@ -2,7 +2,7 @@
12.0
- 2.0.0
+ 2.1.0
preview
$(VersionSuffix)-$(BuildNumber)
612,618
@@ -39,20 +39,10 @@
-
-
True
icon.png
-
-
- all
- runtime; build; native; contentfiles; analyzers
-
-
-
-
diff --git a/src/OrchardCore.Cms.Web/appsettings.json b/src/OrchardCore.Cms.Web/appsettings.json
index a4e2b9e1074..4dbff971208 100644
--- a/src/OrchardCore.Cms.Web/appsettings.json
+++ b/src/OrchardCore.Cms.Web/appsettings.json
@@ -173,7 +173,11 @@
// "Key": ""
// }
//},
- // "Url": "http://localhost",
+ // Roles
+ //"OrchardCore_Roles": {
+ // "AdminRoleName":"Administrator"
+ //},
+ //"Url": "http://localhost",
// "Ports": [ 9200 ],
// "Username": "admin",
// "Password": "admin",
@@ -250,10 +254,14 @@
// "Username": "",
// "Password": ""
//},
- //"OrchardCore_Email_Azure": {
+ //"OrchardCore_Email_AzureCommunicationServices": {
// "DefaultSender": "",
// "ConnectionString": ""
//}
+ //"OrchardCore_Sms_AzureCommunicationServices": {
+ // "PhoneNumber": "",
+ // "ConnectionString": ""
+ //}
//"OrchardCore_ReverseProxy": {
// "ForwardedHeaders": "None"
//},
diff --git a/src/OrchardCore.Modules/OrchardCore.Admin/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.Admin/AdminMenu.cs
index 22d4da0c5c7..cdf8270f5e8 100644
--- a/src/OrchardCore.Modules/OrchardCore.Admin/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Admin/AdminMenu.cs
@@ -5,7 +5,7 @@
namespace OrchardCore.Admin;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _routeValues = new()
{
@@ -15,18 +15,13 @@ public sealed class AdminMenu : INavigationProvider
internal readonly IStringLocalizer S;
- public AdminMenu(IStringLocalizer localizer)
+ public AdminMenu(IStringLocalizer stringLocalizer)
{
- S = localizer;
+ S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Settings"], settings => settings
@@ -39,6 +34,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Admin/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Admin/Startup.cs
index 1a83938744d..054c654b2d8 100644
--- a/src/OrchardCore.Modules/OrchardCore.Admin/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Admin/Startup.cs
@@ -22,7 +22,6 @@
using OrchardCore.Mvc.Routing;
using OrchardCore.Navigation;
using OrchardCore.Security.Permissions;
-using OrchardCore.Settings;
using OrchardCore.Settings.Deployment;
namespace OrchardCore.Admin;
@@ -52,12 +51,12 @@ public override void ConfigureServices(IServiceCollection services)
});
services.AddTransient();
- services.AddScoped();
+ services.AddPermissionProvider();
services.AddScoped();
services.AddScoped();
- services.AddScoped, AdminSiteSettingsDisplayDriver>();
- services.AddScoped();
- services.AddScoped();
+ services.AddSiteDisplayDriver();
+ services.AddPermissionProvider();
+ services.AddNavigationProvider();
services.AddSingleton();
services.AddScoped, VisitSiteNavbarDisplayDriver>();
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminDashboard/Startup.cs b/src/OrchardCore.Modules/OrchardCore.AdminDashboard/Startup.cs
index a1b471ccd58..26b34aab842 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminDashboard/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminDashboard/Startup.cs
@@ -31,7 +31,7 @@ public Startup(IOptions adminOptions)
public override void ConfigureServices(IServiceCollection services)
{
- services.AddScoped();
+ services.AddPermissionProvider();
services.AddScoped();
services.AddIndexProvider();
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/AdminMenu.cs
index 266a89a2b3e..9a60dc21942 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/AdminMenu.cs
@@ -4,27 +4,23 @@
namespace OrchardCore.AdminMenu;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
- private readonly AdminMenuNavigationProvidersCoordinator _adminMenuNavigationProvider;
+ private readonly AdminMenuNavigationProvidersCoordinator _adminMenuNavigationProviderCoordinator;
internal readonly IStringLocalizer S;
- public AdminMenu(AdminMenuNavigationProvidersCoordinator adminMenuNavigationProvider,
- IStringLocalizer localizer)
+ public AdminMenu(
+ AdminMenuNavigationProvidersCoordinator adminMenuNavigationProviderCoordinator,
+ IStringLocalizer stringLocalizer)
{
- _adminMenuNavigationProvider = adminMenuNavigationProvider;
- S = localizer;
+ _adminMenuNavigationProviderCoordinator = adminMenuNavigationProviderCoordinator;
+ S = stringLocalizer;
}
- public async Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return;
- }
-
- // Configuration and settings menus for the AdminMenu module
+ // Configuration and settings menus for the AdminMenu module.
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Admin Menus"], S["Admin Menus"].PrefixPosition(), adminMenu => adminMenu
@@ -34,7 +30,7 @@ public async Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- // This is the entry point for the adminMenu: dynamically generated custom admin menus
- await _adminMenuNavigationProvider.BuildNavigationAsync(NavigationConstants.AdminMenuId, builder);
+ // This is the entry point for the adminMenu: dynamically generated custom admin menus.
+ return _adminMenuNavigationProviderCoordinator.BuildNavigationAsync(NavigationConstants.AdminMenuId, builder);
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs
index 0d62c16c142..0502063da9b 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Deployment/AdminMenuDeploymentSource.cs
@@ -7,7 +7,8 @@
namespace OrchardCore.AdminMenu.Deployment;
-public class AdminMenuDeploymentSource : IDeploymentSource
+public class AdminMenuDeploymentSource
+ : DeploymentSourceBase
{
private readonly IAdminMenuService _adminMenuService;
private readonly JsonSerializerOptions _serializationOptions;
@@ -19,15 +20,8 @@ public AdminMenuDeploymentSource(IAdminMenuService adminMenuService,
_serializationOptions = serializationOptions.Value.SerializerOptions;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(AdminMenuDeploymentStep step, DeploymentPlanResult result)
{
- var adminMenuStep = step as AdminMenuDeploymentStep;
-
- if (adminMenuStep == null)
- {
- return;
- }
-
var data = new JsonArray();
result.Steps.Add(new JsonObject
{
@@ -40,7 +34,5 @@ public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlan
var objectData = JObject.FromObject(adminMenu, _serializationOptions);
data.Add(objectData);
}
-
- return;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs
index 6939244db07..6425c3d017e 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Recipes/AdminMenuStep.cs
@@ -11,7 +11,7 @@ namespace OrchardCore.AdminMenu.Recipes;
///
/// This recipe step creates a set of admin menus.
///
-public sealed class AdminMenuStep : IRecipeStepHandler
+public sealed class AdminMenuStep : NamedRecipeStepHandler
{
private readonly IAdminMenuService _adminMenuService;
private readonly JsonSerializerOptions _serializationOptions;
@@ -19,20 +19,16 @@ public sealed class AdminMenuStep : IRecipeStepHandler
public AdminMenuStep(
IAdminMenuService adminMenuService,
IOptions serializationOptions)
+ : base("AdminMenu")
{
_adminMenuService = adminMenuService;
- // The recipe step contains polymorphic types (menu items) which need to be resolved
+ // The recipe step contains polymorphic types (menu items) which need to be resolved.
_serializationOptions = serializationOptions.Value.SerializerOptions;
}
- public async Task ExecuteAsync(RecipeExecutionContext context)
+ protected override async Task HandleAsync(RecipeExecutionContext context)
{
- if (!string.Equals(context.Name, "AdminMenu", StringComparison.OrdinalIgnoreCase))
- {
- return;
- }
-
var model = context.Step.ToObject(_serializationOptions);
foreach (var token in model.Data.Cast())
@@ -47,8 +43,6 @@ public async Task ExecuteAsync(RecipeExecutionContext context)
await _adminMenuService.SaveAsync(adminMenu);
}
-
- return;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Services/AdminMenuNavigationProvidersCoordinator.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Services/AdminMenuNavigationProvidersCoordinator.cs
index dba9e021d3e..8653cbe4b2d 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Services/AdminMenuNavigationProvidersCoordinator.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Services/AdminMenuNavigationProvidersCoordinator.cs
@@ -31,7 +31,7 @@ public AdminMenuNavigationProvidersCoordinator(
_logger = logger;
}
- public async Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ public async ValueTask BuildNavigationAsync(string name, NavigationBuilder builder)
{
// We only add them if the caller uses the string "adminMenu".
if (name != NavigationConstants.AdminMenuId)
diff --git a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Startup.cs b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Startup.cs
index 9a639e053c4..74e1b7fa0e9 100644
--- a/src/OrchardCore.Modules/OrchardCore.AdminMenu/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AdminMenu/Startup.cs
@@ -15,8 +15,8 @@ public sealed class Startup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
- services.AddScoped();
- services.AddScoped();
+ services.AddPermissionProvider();
+ services.AddNavigationProvider();
services.AddScoped();
services.AddScoped();
diff --git a/src/OrchardCore.Modules/OrchardCore.Alias/Handlers/AliasPartHandler.cs b/src/OrchardCore.Modules/OrchardCore.Alias/Handlers/AliasPartHandler.cs
index 7c0407ac870..f8a31fe026f 100644
--- a/src/OrchardCore.Modules/OrchardCore.Alias/Handlers/AliasPartHandler.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Alias/Handlers/AliasPartHandler.cs
@@ -49,7 +49,7 @@ public override async Task ValidatingAsync(ValidateContentContext context, Alias
}
}
- public async override Task UpdatedAsync(UpdateContentContext context, AliasPart part)
+ public override async Task UpdatedAsync(UpdateContentContext context, AliasPart part)
{
// Compute the Alias only if it's empty.
if (!string.IsNullOrEmpty(part.Alias))
diff --git a/src/OrchardCore.Modules/OrchardCore.Alias/Services/ContentAliasShapeTableProvider.cs b/src/OrchardCore.Modules/OrchardCore.Alias/Services/ContentAliasShapeTableProvider.cs
new file mode 100644
index 00000000000..cc883a8a9d2
--- /dev/null
+++ b/src/OrchardCore.Modules/OrchardCore.Alias/Services/ContentAliasShapeTableProvider.cs
@@ -0,0 +1,35 @@
+using OrchardCore.Alias.Models;
+using OrchardCore.ContentManagement;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement.Utilities;
+
+namespace OrchardCore.Alias.Services;
+
+public sealed class ContentAliasShapeTableProvider : ShapeTableProvider
+{
+ public override ValueTask DiscoverAsync(ShapeTableBuilder builder)
+ {
+ builder.Describe("Content")
+ .OnDisplaying(displaying =>
+ {
+ var shape = displaying.Shape;
+ var contentItem = shape.GetProperty("ContentItem");
+
+ var aliasPart = contentItem?.As();
+
+ if (aliasPart != null)
+ {
+ var encodedAlias = aliasPart.Alias.EncodeAlternateElement();
+
+ // Content__Alias__[Alias] e.g. Content-Alias-example, Content-Alias-my-page
+ displaying.Shape.Metadata.Alternates.Add("Content__Alias__" + encodedAlias);
+
+ // Content_[DisplayType]__Alias__[Alias] e.g. Content-Alias-example.Summary, Content-Alias-my-page.Summary
+ displaying.Shape.Metadata.Alternates.Add("Content_" + displaying.Shape.Metadata.DisplayType + "__Alias__" + encodedAlias);
+ }
+ });
+
+ return ValueTask.CompletedTask;
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.Alias/Services/WidgetAliasShapeTableProvider.cs b/src/OrchardCore.Modules/OrchardCore.Alias/Services/WidgetAliasShapeTableProvider.cs
new file mode 100644
index 00000000000..85d8a984550
--- /dev/null
+++ b/src/OrchardCore.Modules/OrchardCore.Alias/Services/WidgetAliasShapeTableProvider.cs
@@ -0,0 +1,35 @@
+using OrchardCore.Alias.Models;
+using OrchardCore.ContentManagement;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement.Utilities;
+
+namespace OrchardCore.Alias.Services;
+
+public sealed class WidgetAliasShapeTableProvider : ShapeTableProvider
+{
+ public override ValueTask DiscoverAsync(ShapeTableBuilder builder)
+ {
+ builder.Describe("Widget")
+ .OnDisplaying(displaying =>
+ {
+ var shape = displaying.Shape;
+ var contentItem = shape.GetProperty("ContentItem");
+
+ var aliasPart = contentItem?.As();
+
+ if (aliasPart != null)
+ {
+ var encodedAlias = aliasPart.Alias.EncodeAlternateElement();
+
+ // Widget__Alias__[Alias] e.g. Widget-Alias-example, Widget-Alias-my-page
+ displaying.Shape.Metadata.Alternates.Add("Widget__Alias__" + encodedAlias);
+
+ // Widget_[DisplayType]__Alias__[Alias] e.g. Widget-Alias-example.Summary, Widget-Alias-my-page.Summary
+ displaying.Shape.Metadata.Alternates.Add("Widget_" + displaying.Shape.Metadata.DisplayType + "__Alias__" + encodedAlias);
+ }
+ });
+
+ return ValueTask.CompletedTask;
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.Alias/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Alias/Startup.cs
index 36f54299b5b..c08f6df7e85 100644
--- a/src/OrchardCore.Modules/OrchardCore.Alias/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Alias/Startup.cs
@@ -15,6 +15,8 @@
using OrchardCore.ContentTypes.Editors;
using OrchardCore.Data;
using OrchardCore.Data.Migration;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
using OrchardCore.Indexing;
using OrchardCore.Liquid;
using OrchardCore.Modules;
@@ -72,3 +74,21 @@ public override void ConfigureServices(IServiceCollection services)
services.AddScoped();
}
}
+
+[RequireFeatures("OrchardCore.Contents")]
+public sealed class ContentAliasStartup : StartupBase
+{
+ public override void ConfigureServices(IServiceCollection services)
+ {
+ services.AddShapeTableProvider();
+ }
+}
+
+[RequireFeatures("OrchardCore.Widgets")]
+public sealed class WidgetAliasStartup : StartupBase
+{
+ public override void ConfigureServices(IServiceCollection services)
+ {
+ services.AddShapeTableProvider();
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/AdminMenu.cs
index 7785b68d27b..02c371cda73 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/AdminMenu.cs
@@ -3,22 +3,17 @@
namespace OrchardCore.Apis.GraphQL;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
internal readonly IStringLocalizer S;
- public AdminMenu(IStringLocalizer localizer)
+ public AdminMenu(IStringLocalizer stringLocalizer)
{
- S = localizer;
+ S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["GraphiQL"], S["GraphiQL"].PrefixPosition(), graphiQL => graphiQL
@@ -28,6 +23,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/Startup.cs
index 09c260d0ba1..c928c74358f 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/Startup.cs
@@ -45,8 +45,8 @@ public override void ConfigureServices(IServiceCollection services)
return new ErrorInfoProvider(new ErrorInfoProviderOptions { ExposeExceptionDetails = settings.Value.ExposeExceptions });
});
- services.AddScoped();
- services.AddTransient();
+ services.AddPermissionProvider();
+ services.AddNavigationProvider();
services.AddSingleton();
services.AddGraphQL(builder => builder.AddSystemTextJson((options, sp) =>
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/MaxNumberOfResultsValidationRule.cs b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/MaxNumberOfResultsValidationRule.cs
index a429869af6f..c4df8595dfc 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/MaxNumberOfResultsValidationRule.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/MaxNumberOfResultsValidationRule.cs
@@ -60,7 +60,7 @@ public ValueTask ValidateAsync(ValidationContext validationContext
}
else
{
- _logger.LogInformation("'{value}' exceeds the maximum number of results for '{name}' ({total})", value.Value, arg.Name, _maxNumberOfResults);
+ _logger.LogInformation("'{Value}' exceeds the maximum number of results for '{Name}' ({Total})", value.Value, arg.Name, _maxNumberOfResults);
arg = new GraphQLArgument(arg.Name, new GraphQLIntValue(_maxNumberOfResults)); // if disabled mode we just log info and override the arg to be maxvalue
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/RequiresPermissionValidationRule.cs b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/RequiresPermissionValidationRule.cs
index cd43c8d99dd..ba3183d2447 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/RequiresPermissionValidationRule.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/ValidationRules/RequiresPermissionValidationRule.cs
@@ -9,8 +9,10 @@ namespace OrchardCore.Apis.GraphQL.ValidationRules;
public class RequiresPermissionValidationRule : IValidationRule
{
- public static readonly string ErrorCode = "Unauthorized";
+ public const string ErrorCode = "Unauthorized";
+
private readonly IAuthorizationService _authorizationService;
+
protected readonly IStringLocalizer S;
public RequiresPermissionValidationRule(
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package-lock.json b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package-lock.json
index ca50fbe1e2b..54a7b89a2d8 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package-lock.json
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package-lock.json
@@ -28,7 +28,7 @@
"style-loader": "^3.3.3",
"ts-loader": "^9.4.4",
"typescript": "^5.2.2",
- "webpack": "^5.88.2",
+ "webpack": "^5.94.0",
"webpack-cli": "^5.1.4"
}
},
@@ -1953,14 +1953,14 @@
}
},
"node_modules/@jridgewell/gen-mapping": {
- "version": "0.3.3",
- "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz",
- "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==",
+ "version": "0.3.5",
+ "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz",
+ "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==",
"dev": true,
"dependencies": {
- "@jridgewell/set-array": "^1.0.1",
+ "@jridgewell/set-array": "^1.2.1",
"@jridgewell/sourcemap-codec": "^1.4.10",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/trace-mapping": "^0.3.24"
},
"engines": {
"node": ">=6.0.0"
@@ -1976,22 +1976,22 @@
}
},
"node_modules/@jridgewell/set-array": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz",
- "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==",
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz",
+ "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==",
"dev": true,
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/@jridgewell/source-map": {
- "version": "0.3.5",
- "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.5.tgz",
- "integrity": "sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==",
+ "version": "0.3.6",
+ "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz",
+ "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==",
"dev": true,
"dependencies": {
- "@jridgewell/gen-mapping": "^0.3.0",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/gen-mapping": "^0.3.5",
+ "@jridgewell/trace-mapping": "^0.3.25"
}
},
"node_modules/@jridgewell/sourcemap-codec": {
@@ -2001,21 +2001,15 @@
"dev": true
},
"node_modules/@jridgewell/trace-mapping": {
- "version": "0.3.18",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz",
- "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==",
+ "version": "0.3.25",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz",
+ "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==",
"dev": true,
"dependencies": {
- "@jridgewell/resolve-uri": "3.1.0",
- "@jridgewell/sourcemap-codec": "1.4.14"
+ "@jridgewell/resolve-uri": "^3.1.0",
+ "@jridgewell/sourcemap-codec": "^1.4.14"
}
},
- "node_modules/@jridgewell/trace-mapping/node_modules/@jridgewell/sourcemap-codec": {
- "version": "1.4.14",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
- "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==",
- "dev": true
- },
"node_modules/@lezer/common": {
"version": "0.16.1",
"resolved": "https://registry.npmjs.org/@lezer/common/-/common-0.16.1.tgz",
@@ -2064,30 +2058,10 @@
"semver": "bin/semver.js"
}
},
- "node_modules/@types/eslint": {
- "version": "8.4.1",
- "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.1.tgz",
- "integrity": "sha512-GE44+DNEyxxh2Kc6ro/VkIj+9ma0pO0bwv9+uHSyBrikYOHr8zYcdPvnBOp1aw8s+CjRvuSx7CyWqRrNFQ59mA==",
- "dev": true,
- "dependencies": {
- "@types/estree": "*",
- "@types/json-schema": "*"
- }
- },
- "node_modules/@types/eslint-scope": {
- "version": "3.7.3",
- "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.3.tgz",
- "integrity": "sha512-PB3ldyrcnAicT35TWPs5IcwKD8S333HMaa2VVv4+wdvebJkjWuW/xESoB8IwRcog8HYVYamb1g/R31Qv5Bx03g==",
- "dev": true,
- "dependencies": {
- "@types/eslint": "*",
- "@types/estree": "*"
- }
- },
"node_modules/@types/estree": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz",
- "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==",
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz",
+ "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==",
"dev": true
},
"node_modules/@types/json-schema": {
@@ -2103,9 +2077,9 @@
"devOptional": true
},
"node_modules/@webassemblyjs/ast": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz",
- "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz",
+ "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==",
"dev": true,
"dependencies": {
"@webassemblyjs/helper-numbers": "1.11.6",
@@ -2125,9 +2099,9 @@
"dev": true
},
"node_modules/@webassemblyjs/helper-buffer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz",
- "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz",
+ "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==",
"dev": true
},
"node_modules/@webassemblyjs/helper-numbers": {
@@ -2148,15 +2122,15 @@
"dev": true
},
"node_modules/@webassemblyjs/helper-wasm-section": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz",
- "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz",
+ "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6"
+ "@webassemblyjs/wasm-gen": "1.12.1"
}
},
"node_modules/@webassemblyjs/ieee754": {
@@ -2184,28 +2158,28 @@
"dev": true
},
"node_modules/@webassemblyjs/wasm-edit": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz",
- "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz",
+ "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/helper-wasm-section": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-opt": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6",
- "@webassemblyjs/wast-printer": "1.11.6"
+ "@webassemblyjs/helper-wasm-section": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-opt": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1",
+ "@webassemblyjs/wast-printer": "1.12.1"
}
},
"node_modules/@webassemblyjs/wasm-gen": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz",
- "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz",
+ "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
"@webassemblyjs/leb128": "1.11.6",
@@ -2213,24 +2187,24 @@
}
},
"node_modules/@webassemblyjs/wasm-opt": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz",
- "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz",
+ "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6"
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1"
}
},
"node_modules/@webassemblyjs/wasm-parser": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz",
- "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz",
+ "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-api-error": "1.11.6",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
@@ -2239,12 +2213,12 @@
}
},
"node_modules/@webassemblyjs/wast-printer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz",
- "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz",
+ "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@xtuc/long": "4.2.2"
}
},
@@ -2305,9 +2279,9 @@
"dev": true
},
"node_modules/acorn": {
- "version": "8.10.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
- "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "version": "8.12.1",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz",
+ "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==",
"dev": true,
"bin": {
"acorn": "bin/acorn"
@@ -2316,10 +2290,10 @@
"node": ">=0.4.0"
}
},
- "node_modules/acorn-import-assertions": {
- "version": "1.9.0",
- "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz",
- "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==",
+ "node_modules/acorn-import-attributes": {
+ "version": "1.9.5",
+ "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz",
+ "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==",
"dev": true,
"peerDependencies": {
"acorn": "^8"
@@ -2817,9 +2791,9 @@
}
},
"node_modules/enhanced-resolve": {
- "version": "5.15.0",
- "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz",
- "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==",
+ "version": "5.17.1",
+ "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz",
+ "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==",
"dev": true,
"dependencies": {
"graceful-fs": "^4.2.4",
@@ -3165,9 +3139,9 @@
}
},
"node_modules/graceful-fs": {
- "version": "4.2.9",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz",
- "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==",
+ "version": "4.2.11",
+ "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
+ "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
"dev": true
},
"node_modules/graphiql": {
@@ -4526,9 +4500,9 @@
}
},
"node_modules/serialize-javascript": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz",
- "integrity": "sha512-owoXEFjWRllis8/M1Q+Cw5k8ZH40e3zhp/ovX+Xr/vi1qj6QesbyXXViFbpNvWvPNAD62SutwEXavefrLJWj7w==",
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz",
+ "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==",
"dev": true,
"dependencies": {
"randombytes": "^2.1.0"
@@ -4705,9 +4679,9 @@
}
},
"node_modules/terser": {
- "version": "5.19.0",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.0.tgz",
- "integrity": "sha512-JpcpGOQLOXm2jsomozdMDpd5f8ZHh1rR48OFgWUH3QsyZcfPgv2qDCYbcDEAYNd4OZRj2bWYKpwdll/udZCk/Q==",
+ "version": "5.31.6",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz",
+ "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==",
"dev": true,
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
@@ -4723,16 +4697,16 @@
}
},
"node_modules/terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"dev": true,
"dependencies": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
},
"engines": {
"node": ">= 10.13.0"
@@ -5036,9 +5010,9 @@
"peer": true
},
"node_modules/watchpack": {
- "version": "2.4.0",
- "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz",
- "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==",
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz",
+ "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==",
"dev": true,
"dependencies": {
"glob-to-regexp": "^0.4.1",
@@ -5049,34 +5023,33 @@
}
},
"node_modules/webpack": {
- "version": "5.88.2",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.88.2.tgz",
- "integrity": "sha512-JmcgNZ1iKj+aiR0OvTYtWQqJwq37Pf683dY9bVORwVbUrDhLhdn/PlO2sHsFHPkj7sHNQF3JwaAkp49V+Sq1tQ==",
+ "version": "5.94.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz",
+ "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==",
"dev": true,
"dependencies": {
- "@types/eslint-scope": "^3.7.3",
- "@types/estree": "^1.0.0",
- "@webassemblyjs/ast": "^1.11.5",
- "@webassemblyjs/wasm-edit": "^1.11.5",
- "@webassemblyjs/wasm-parser": "^1.11.5",
+ "@types/estree": "^1.0.5",
+ "@webassemblyjs/ast": "^1.12.1",
+ "@webassemblyjs/wasm-edit": "^1.12.1",
+ "@webassemblyjs/wasm-parser": "^1.12.1",
"acorn": "^8.7.1",
- "acorn-import-assertions": "^1.9.0",
- "browserslist": "^4.14.5",
+ "acorn-import-attributes": "^1.9.5",
+ "browserslist": "^4.21.10",
"chrome-trace-event": "^1.0.2",
- "enhanced-resolve": "^5.15.0",
+ "enhanced-resolve": "^5.17.1",
"es-module-lexer": "^1.2.1",
"eslint-scope": "5.1.1",
"events": "^3.2.0",
"glob-to-regexp": "^0.4.1",
- "graceful-fs": "^4.2.9",
+ "graceful-fs": "^4.2.11",
"json-parse-even-better-errors": "^2.3.1",
"loader-runner": "^4.2.0",
"mime-types": "^2.1.27",
"neo-async": "^2.6.2",
"schema-utils": "^3.2.0",
"tapable": "^2.1.1",
- "terser-webpack-plugin": "^5.3.7",
- "watchpack": "^2.4.0",
+ "terser-webpack-plugin": "^5.3.10",
+ "watchpack": "^2.4.1",
"webpack-sources": "^3.2.3"
},
"bin": {
@@ -6574,14 +6547,14 @@
}
},
"@jridgewell/gen-mapping": {
- "version": "0.3.3",
- "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz",
- "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==",
+ "version": "0.3.5",
+ "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz",
+ "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==",
"dev": true,
"requires": {
- "@jridgewell/set-array": "^1.0.1",
+ "@jridgewell/set-array": "^1.2.1",
"@jridgewell/sourcemap-codec": "^1.4.10",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/trace-mapping": "^0.3.24"
}
},
"@jridgewell/resolve-uri": {
@@ -6591,19 +6564,19 @@
"dev": true
},
"@jridgewell/set-array": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz",
- "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==",
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz",
+ "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==",
"dev": true
},
"@jridgewell/source-map": {
- "version": "0.3.5",
- "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.5.tgz",
- "integrity": "sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==",
+ "version": "0.3.6",
+ "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz",
+ "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==",
"dev": true,
"requires": {
- "@jridgewell/gen-mapping": "^0.3.0",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/gen-mapping": "^0.3.5",
+ "@jridgewell/trace-mapping": "^0.3.25"
}
},
"@jridgewell/sourcemap-codec": {
@@ -6613,21 +6586,13 @@
"dev": true
},
"@jridgewell/trace-mapping": {
- "version": "0.3.18",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz",
- "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==",
+ "version": "0.3.25",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz",
+ "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==",
"dev": true,
"requires": {
- "@jridgewell/resolve-uri": "3.1.0",
- "@jridgewell/sourcemap-codec": "1.4.14"
- },
- "dependencies": {
- "@jridgewell/sourcemap-codec": {
- "version": "1.4.14",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
- "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==",
- "dev": true
- }
+ "@jridgewell/resolve-uri": "^3.1.0",
+ "@jridgewell/sourcemap-codec": "^1.4.14"
}
},
"@lezer/common": {
@@ -6672,30 +6637,10 @@
"integrity": "sha512-3Yc1fUTs69MG/uZbJlLSI3JISMn2UV2rg+1D/vROUqZyh3l6iYHCs7GMp+M40ZD7yOdDbYjJcU1oTJhrc+dGKg==",
"dev": true
},
- "@types/eslint": {
- "version": "8.4.1",
- "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.1.tgz",
- "integrity": "sha512-GE44+DNEyxxh2Kc6ro/VkIj+9ma0pO0bwv9+uHSyBrikYOHr8zYcdPvnBOp1aw8s+CjRvuSx7CyWqRrNFQ59mA==",
- "dev": true,
- "requires": {
- "@types/estree": "*",
- "@types/json-schema": "*"
- }
- },
- "@types/eslint-scope": {
- "version": "3.7.3",
- "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.3.tgz",
- "integrity": "sha512-PB3ldyrcnAicT35TWPs5IcwKD8S333HMaa2VVv4+wdvebJkjWuW/xESoB8IwRcog8HYVYamb1g/R31Qv5Bx03g==",
- "dev": true,
- "requires": {
- "@types/eslint": "*",
- "@types/estree": "*"
- }
- },
"@types/estree": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz",
- "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==",
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz",
+ "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==",
"dev": true
},
"@types/json-schema": {
@@ -6711,9 +6656,9 @@
"devOptional": true
},
"@webassemblyjs/ast": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz",
- "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz",
+ "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==",
"dev": true,
"requires": {
"@webassemblyjs/helper-numbers": "1.11.6",
@@ -6733,9 +6678,9 @@
"dev": true
},
"@webassemblyjs/helper-buffer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz",
- "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz",
+ "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==",
"dev": true
},
"@webassemblyjs/helper-numbers": {
@@ -6756,15 +6701,15 @@
"dev": true
},
"@webassemblyjs/helper-wasm-section": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz",
- "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz",
+ "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6"
+ "@webassemblyjs/wasm-gen": "1.12.1"
}
},
"@webassemblyjs/ieee754": {
@@ -6792,28 +6737,28 @@
"dev": true
},
"@webassemblyjs/wasm-edit": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz",
- "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz",
+ "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/helper-wasm-section": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-opt": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6",
- "@webassemblyjs/wast-printer": "1.11.6"
+ "@webassemblyjs/helper-wasm-section": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-opt": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1",
+ "@webassemblyjs/wast-printer": "1.12.1"
}
},
"@webassemblyjs/wasm-gen": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz",
- "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz",
+ "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
"@webassemblyjs/leb128": "1.11.6",
@@ -6821,24 +6766,24 @@
}
},
"@webassemblyjs/wasm-opt": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz",
- "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz",
+ "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6"
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1"
}
},
"@webassemblyjs/wasm-parser": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz",
- "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz",
+ "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-api-error": "1.11.6",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
@@ -6847,12 +6792,12 @@
}
},
"@webassemblyjs/wast-printer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz",
- "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz",
+ "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@xtuc/long": "4.2.2"
}
},
@@ -6890,15 +6835,15 @@
"dev": true
},
"acorn": {
- "version": "8.10.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
- "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "version": "8.12.1",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz",
+ "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==",
"dev": true
},
- "acorn-import-assertions": {
- "version": "1.9.0",
- "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz",
- "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==",
+ "acorn-import-attributes": {
+ "version": "1.9.5",
+ "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz",
+ "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==",
"dev": true,
"requires": {}
},
@@ -7258,9 +7203,9 @@
"dev": true
},
"enhanced-resolve": {
- "version": "5.15.0",
- "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz",
- "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==",
+ "version": "5.17.1",
+ "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz",
+ "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==",
"dev": true,
"requires": {
"graceful-fs": "^4.2.4",
@@ -7523,9 +7468,9 @@
"dev": true
},
"graceful-fs": {
- "version": "4.2.9",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz",
- "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==",
+ "version": "4.2.11",
+ "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
+ "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
"dev": true
},
"graphiql": {
@@ -8484,9 +8429,9 @@
"dev": true
},
"serialize-javascript": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz",
- "integrity": "sha512-owoXEFjWRllis8/M1Q+Cw5k8ZH40e3zhp/ovX+Xr/vi1qj6QesbyXXViFbpNvWvPNAD62SutwEXavefrLJWj7w==",
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz",
+ "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==",
"dev": true,
"requires": {
"randombytes": "^2.1.0"
@@ -8613,9 +8558,9 @@
"dev": true
},
"terser": {
- "version": "5.19.0",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.0.tgz",
- "integrity": "sha512-JpcpGOQLOXm2jsomozdMDpd5f8ZHh1rR48OFgWUH3QsyZcfPgv2qDCYbcDEAYNd4OZRj2bWYKpwdll/udZCk/Q==",
+ "version": "5.31.6",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz",
+ "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==",
"dev": true,
"requires": {
"@jridgewell/source-map": "^0.3.3",
@@ -8633,16 +8578,16 @@
}
},
"terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"dev": true,
"requires": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
}
},
"to-fast-properties": {
@@ -8839,9 +8784,9 @@
"peer": true
},
"watchpack": {
- "version": "2.4.0",
- "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz",
- "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==",
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz",
+ "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==",
"dev": true,
"requires": {
"glob-to-regexp": "^0.4.1",
@@ -8849,34 +8794,33 @@
}
},
"webpack": {
- "version": "5.88.2",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.88.2.tgz",
- "integrity": "sha512-JmcgNZ1iKj+aiR0OvTYtWQqJwq37Pf683dY9bVORwVbUrDhLhdn/PlO2sHsFHPkj7sHNQF3JwaAkp49V+Sq1tQ==",
+ "version": "5.94.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz",
+ "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==",
"dev": true,
"requires": {
- "@types/eslint-scope": "^3.7.3",
- "@types/estree": "^1.0.0",
- "@webassemblyjs/ast": "^1.11.5",
- "@webassemblyjs/wasm-edit": "^1.11.5",
- "@webassemblyjs/wasm-parser": "^1.11.5",
+ "@types/estree": "^1.0.5",
+ "@webassemblyjs/ast": "^1.12.1",
+ "@webassemblyjs/wasm-edit": "^1.12.1",
+ "@webassemblyjs/wasm-parser": "^1.12.1",
"acorn": "^8.7.1",
- "acorn-import-assertions": "^1.9.0",
- "browserslist": "^4.14.5",
+ "acorn-import-attributes": "^1.9.5",
+ "browserslist": "^4.21.10",
"chrome-trace-event": "^1.0.2",
- "enhanced-resolve": "^5.15.0",
+ "enhanced-resolve": "^5.17.1",
"es-module-lexer": "^1.2.1",
"eslint-scope": "5.1.1",
"events": "^3.2.0",
"glob-to-regexp": "^0.4.1",
- "graceful-fs": "^4.2.9",
+ "graceful-fs": "^4.2.11",
"json-parse-even-better-errors": "^2.3.1",
"loader-runner": "^4.2.0",
"mime-types": "^2.1.27",
"neo-async": "^2.6.2",
"schema-utils": "^3.2.0",
"tapable": "^2.1.1",
- "terser-webpack-plugin": "^5.3.7",
- "watchpack": "^2.4.0",
+ "terser-webpack-plugin": "^5.3.10",
+ "watchpack": "^2.4.1",
"webpack-sources": "^3.2.3"
}
},
diff --git a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package.json b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package.json
index 81524d09c6b..145f7dc2ee6 100644
--- a/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package.json
+++ b/src/OrchardCore.Modules/OrchardCore.Apis.GraphQL/package.json
@@ -24,7 +24,7 @@
"style-loader": "^3.3.3",
"ts-loader": "^9.4.4",
"typescript": "^5.2.2",
- "webpack": "^5.88.2",
+ "webpack": "^5.94.0",
"webpack-cli": "^5.1.4"
},
"scripts": {
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailAdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailAdminMenu.cs
index f1a154e8d7f..95dcb31301d 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailAdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailAdminMenu.cs
@@ -5,7 +5,7 @@
namespace OrchardCore.AuditTrail.Navigation;
-public sealed class AuditTrailAdminMenu : INavigationProvider
+public sealed class AuditTrailAdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _routeValues = new()
{
@@ -20,13 +20,8 @@ public AuditTrailAdminMenu(IStringLocalizer stringLocalizer
S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Audit Trail"], NavigationConstants.AdminMenuAuditTrailPosition, configuration => configuration
.AddClass("audittrail")
@@ -36,6 +31,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
.LocalNav()
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailSettingsAdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailSettingsAdminMenu.cs
index 420c6376f6a..6f9ddd25673 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailSettingsAdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Navigation/AuditTrailSettingsAdminMenu.cs
@@ -5,7 +5,7 @@
namespace OrchardCore.AuditTrail.Navigation;
-public sealed class AuditTrailSettingsAdminMenu : INavigationProvider
+public sealed class AuditTrailSettingsAdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _routeValues = new()
{
@@ -20,13 +20,8 @@ public AuditTrailSettingsAdminMenu(IStringLocalizer
S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Settings"], settings => settings
@@ -40,6 +35,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListFilterProvider.cs b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListFilterProvider.cs
index 47dd816fdc2..9cee1010c33 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListFilterProvider.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListFilterProvider.cs
@@ -9,7 +9,6 @@
using OrchardCore.AuditTrail.ViewModels;
using OrchardCore.Modules;
using Parlot;
-using YesSql;
using YesSql.Filters.Query;
using YesSql.Services;
@@ -178,7 +177,7 @@ public void Build(QueryEngineBuilder builder)
var normalizedUserName = lookupNormalizer.NormalizeName(val);
query.With(x => x.NormalizedUserName.Contains(normalizedUserName));
- return new ValueTask>(query);
+ return ValueTask.FromResult(query);
},
(val, query, ctx) =>
{
@@ -187,7 +186,7 @@ public void Build(QueryEngineBuilder builder)
var normalizedUserName = lookupNormalizer.NormalizeName(val);
query.With(x => x.NormalizedUserName.NotContains(normalizedUserName));
- return new ValueTask>(query);
+ return ValueTask.FromResult(query);
}
)
)
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListQueryService.cs b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListQueryService.cs
index 4d74d31a419..45069577e40 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListQueryService.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Services/DefaultAuditTrailAdminListQueryService.cs
@@ -87,7 +87,7 @@ public async Task QueryAsync(int page, int pageSize,
}
}
- var localNow = await _localClock.LocalNowAsync;
+ var localNow = await _localClock.GetLocalNowAsync();
var startOfWeek = CultureInfo.CurrentUICulture.DateTimeFormat.FirstDayOfWeek;
options.AuditTrailDates =
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Startup.cs b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Startup.cs
index 684789e0ff1..8c76e521209 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/Startup.cs
@@ -17,7 +17,6 @@
using OrchardCore.Modules;
using OrchardCore.Navigation;
using OrchardCore.Security.Permissions;
-using OrchardCore.Settings;
using OrchardCore.Settings.Deployment;
using YesSql.Filters.Query;
@@ -43,12 +42,12 @@ public override void ConfigureServices(IServiceCollection services)
services.AddIndexProvider();
services.AddSingleton();
- services.AddScoped();
- services.AddScoped();
- services.AddScoped();
+ services.AddPermissionProvider();
+ services.AddNavigationProvider();
+ services.AddNavigationProvider();
- services.AddScoped, AuditTrailSettingsDisplayDriver>();
- services.AddScoped, AuditTrailTrimmingSettingsDisplayDriver>();
+ services.AddSiteDisplayDriver();
+ services.AddSiteDisplayDriver();
services.AddScoped, AuditTrailOptionsDisplayDriver>();
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/package-lock.json b/src/OrchardCore.Modules/OrchardCore.AuditTrail/package-lock.json
index 6fd119a3934..1d017f13aee 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/package-lock.json
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/package-lock.json
@@ -31,7 +31,7 @@
"style-loader": "^3.3.3",
"ts-loader": "^9.4.4",
"typescript": "^5.2.2",
- "webpack": "^5.88.2",
+ "webpack": "^5.94.0",
"webpack-cli": "^5.1.4"
}
},
@@ -1948,14 +1948,14 @@
"integrity": "sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA=="
},
"node_modules/@jridgewell/gen-mapping": {
- "version": "0.3.3",
- "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz",
- "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==",
+ "version": "0.3.5",
+ "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz",
+ "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==",
"dev": true,
"dependencies": {
- "@jridgewell/set-array": "^1.0.1",
+ "@jridgewell/set-array": "^1.2.1",
"@jridgewell/sourcemap-codec": "^1.4.10",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/trace-mapping": "^0.3.24"
},
"engines": {
"node": ">=6.0.0"
@@ -1971,22 +1971,22 @@
}
},
"node_modules/@jridgewell/set-array": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz",
- "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==",
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz",
+ "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==",
"dev": true,
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/@jridgewell/source-map": {
- "version": "0.3.5",
- "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.5.tgz",
- "integrity": "sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==",
+ "version": "0.3.6",
+ "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz",
+ "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==",
"dev": true,
"dependencies": {
- "@jridgewell/gen-mapping": "^0.3.0",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/gen-mapping": "^0.3.5",
+ "@jridgewell/trace-mapping": "^0.3.25"
}
},
"node_modules/@jridgewell/sourcemap-codec": {
@@ -1996,21 +1996,15 @@
"dev": true
},
"node_modules/@jridgewell/trace-mapping": {
- "version": "0.3.18",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz",
- "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==",
+ "version": "0.3.25",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz",
+ "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==",
"dev": true,
"dependencies": {
- "@jridgewell/resolve-uri": "3.1.0",
- "@jridgewell/sourcemap-codec": "1.4.14"
+ "@jridgewell/resolve-uri": "^3.1.0",
+ "@jridgewell/sourcemap-codec": "^1.4.14"
}
},
- "node_modules/@jridgewell/trace-mapping/node_modules/@jridgewell/sourcemap-codec": {
- "version": "1.4.14",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
- "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==",
- "dev": true
- },
"node_modules/@nicolo-ribaudo/chokidar-2": {
"version": "2.1.8-no-fsevents.3",
"resolved": "https://registry.npmjs.org/@nicolo-ribaudo/chokidar-2/-/chokidar-2-2.1.8-no-fsevents.3.tgz",
@@ -2037,30 +2031,10 @@
"url": "https://opencollective.com/popperjs"
}
},
- "node_modules/@types/eslint": {
- "version": "8.4.1",
- "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.1.tgz",
- "integrity": "sha512-GE44+DNEyxxh2Kc6ro/VkIj+9ma0pO0bwv9+uHSyBrikYOHr8zYcdPvnBOp1aw8s+CjRvuSx7CyWqRrNFQ59mA==",
- "dev": true,
- "dependencies": {
- "@types/estree": "*",
- "@types/json-schema": "*"
- }
- },
- "node_modules/@types/eslint-scope": {
- "version": "3.7.3",
- "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.3.tgz",
- "integrity": "sha512-PB3ldyrcnAicT35TWPs5IcwKD8S333HMaa2VVv4+wdvebJkjWuW/xESoB8IwRcog8HYVYamb1g/R31Qv5Bx03g==",
- "dev": true,
- "dependencies": {
- "@types/eslint": "*",
- "@types/estree": "*"
- }
- },
"node_modules/@types/estree": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz",
- "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==",
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz",
+ "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==",
"dev": true
},
"node_modules/@types/json-schema": {
@@ -2070,10 +2044,13 @@
"dev": true
},
"node_modules/@types/node": {
- "version": "20.4.1",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-20.4.1.tgz",
- "integrity": "sha512-JIzsAvJeA/5iY6Y/OxZbv1lUcc8dNSE77lb2gnBH+/PJ3lFR1Ccvgwl5JWnHAkNHcRsT0TbpVOsiMKZ1F/yyJg==",
- "dev": true
+ "version": "22.5.1",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.1.tgz",
+ "integrity": "sha512-KkHsxej0j9IW1KKOOAA/XBA0z08UFSrRQHErzEfA3Vgq57eXIMYboIlHJuYIfd+lwCQjtKqUu3UnmKbtUc9yRw==",
+ "dev": true,
+ "dependencies": {
+ "undici-types": "~6.19.2"
+ }
},
"node_modules/@types/parse-json": {
"version": "4.0.0",
@@ -2113,9 +2090,9 @@
"dev": true
},
"node_modules/@webassemblyjs/ast": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz",
- "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz",
+ "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==",
"dev": true,
"dependencies": {
"@webassemblyjs/helper-numbers": "1.11.6",
@@ -2135,9 +2112,9 @@
"dev": true
},
"node_modules/@webassemblyjs/helper-buffer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz",
- "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz",
+ "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==",
"dev": true
},
"node_modules/@webassemblyjs/helper-numbers": {
@@ -2158,15 +2135,15 @@
"dev": true
},
"node_modules/@webassemblyjs/helper-wasm-section": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz",
- "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz",
+ "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6"
+ "@webassemblyjs/wasm-gen": "1.12.1"
}
},
"node_modules/@webassemblyjs/ieee754": {
@@ -2194,28 +2171,28 @@
"dev": true
},
"node_modules/@webassemblyjs/wasm-edit": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz",
- "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz",
+ "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/helper-wasm-section": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-opt": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6",
- "@webassemblyjs/wast-printer": "1.11.6"
+ "@webassemblyjs/helper-wasm-section": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-opt": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1",
+ "@webassemblyjs/wast-printer": "1.12.1"
}
},
"node_modules/@webassemblyjs/wasm-gen": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz",
- "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz",
+ "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
"@webassemblyjs/leb128": "1.11.6",
@@ -2223,24 +2200,24 @@
}
},
"node_modules/@webassemblyjs/wasm-opt": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz",
- "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz",
+ "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6"
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1"
}
},
"node_modules/@webassemblyjs/wasm-parser": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz",
- "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz",
+ "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-api-error": "1.11.6",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
@@ -2249,12 +2226,12 @@
}
},
"node_modules/@webassemblyjs/wast-printer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz",
- "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz",
+ "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==",
"dev": true,
"dependencies": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@xtuc/long": "4.2.2"
}
},
@@ -2315,9 +2292,9 @@
"dev": true
},
"node_modules/acorn": {
- "version": "8.10.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
- "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "version": "8.12.1",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz",
+ "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==",
"dev": true,
"bin": {
"acorn": "bin/acorn"
@@ -2326,10 +2303,10 @@
"node": ">=0.4.0"
}
},
- "node_modules/acorn-import-assertions": {
- "version": "1.9.0",
- "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz",
- "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==",
+ "node_modules/acorn-import-attributes": {
+ "version": "1.9.5",
+ "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz",
+ "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==",
"dev": true,
"peerDependencies": {
"acorn": "^8"
@@ -2903,9 +2880,9 @@
}
},
"node_modules/enhanced-resolve": {
- "version": "5.15.0",
- "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz",
- "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==",
+ "version": "5.17.1",
+ "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz",
+ "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==",
"dev": true,
"dependencies": {
"graceful-fs": "^4.2.4",
@@ -3249,9 +3226,9 @@
}
},
"node_modules/graceful-fs": {
- "version": "4.2.9",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz",
- "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==",
+ "version": "4.2.11",
+ "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
+ "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
"dev": true
},
"node_modules/has": {
@@ -4616,9 +4593,9 @@
}
},
"node_modules/serialize-javascript": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz",
- "integrity": "sha512-owoXEFjWRllis8/M1Q+Cw5k8ZH40e3zhp/ovX+Xr/vi1qj6QesbyXXViFbpNvWvPNAD62SutwEXavefrLJWj7w==",
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz",
+ "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==",
"dev": true,
"dependencies": {
"randombytes": "^2.1.0"
@@ -4779,9 +4756,9 @@
}
},
"node_modules/terser": {
- "version": "5.19.0",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.0.tgz",
- "integrity": "sha512-JpcpGOQLOXm2jsomozdMDpd5f8ZHh1rR48OFgWUH3QsyZcfPgv2qDCYbcDEAYNd4OZRj2bWYKpwdll/udZCk/Q==",
+ "version": "5.31.6",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz",
+ "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==",
"dev": true,
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
@@ -4797,16 +4774,16 @@
}
},
"node_modules/terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"dev": true,
"dependencies": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
},
"engines": {
"node": ">= 10.13.0"
@@ -4988,6 +4965,12 @@
"url": "https://github.com/sponsors/ljharb"
}
},
+ "node_modules/undici-types": {
+ "version": "6.19.8",
+ "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz",
+ "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==",
+ "dev": true
+ },
"node_modules/unicode-canonical-property-names-ecmascript": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.0.tgz",
@@ -5088,9 +5071,9 @@
"dev": true
},
"node_modules/watchpack": {
- "version": "2.4.0",
- "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz",
- "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==",
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz",
+ "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==",
"dev": true,
"dependencies": {
"glob-to-regexp": "^0.4.1",
@@ -5101,34 +5084,33 @@
}
},
"node_modules/webpack": {
- "version": "5.88.2",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.88.2.tgz",
- "integrity": "sha512-JmcgNZ1iKj+aiR0OvTYtWQqJwq37Pf683dY9bVORwVbUrDhLhdn/PlO2sHsFHPkj7sHNQF3JwaAkp49V+Sq1tQ==",
+ "version": "5.94.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz",
+ "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==",
"dev": true,
"dependencies": {
- "@types/eslint-scope": "^3.7.3",
- "@types/estree": "^1.0.0",
- "@webassemblyjs/ast": "^1.11.5",
- "@webassemblyjs/wasm-edit": "^1.11.5",
- "@webassemblyjs/wasm-parser": "^1.11.5",
+ "@types/estree": "^1.0.5",
+ "@webassemblyjs/ast": "^1.12.1",
+ "@webassemblyjs/wasm-edit": "^1.12.1",
+ "@webassemblyjs/wasm-parser": "^1.12.1",
"acorn": "^8.7.1",
- "acorn-import-assertions": "^1.9.0",
- "browserslist": "^4.14.5",
+ "acorn-import-attributes": "^1.9.5",
+ "browserslist": "^4.21.10",
"chrome-trace-event": "^1.0.2",
- "enhanced-resolve": "^5.15.0",
+ "enhanced-resolve": "^5.17.1",
"es-module-lexer": "^1.2.1",
"eslint-scope": "5.1.1",
"events": "^3.2.0",
"glob-to-regexp": "^0.4.1",
- "graceful-fs": "^4.2.9",
+ "graceful-fs": "^4.2.11",
"json-parse-even-better-errors": "^2.3.1",
"loader-runner": "^4.2.0",
"mime-types": "^2.1.27",
"neo-async": "^2.6.2",
"schema-utils": "^3.2.0",
"tapable": "^2.1.1",
- "terser-webpack-plugin": "^5.3.7",
- "watchpack": "^2.4.0",
+ "terser-webpack-plugin": "^5.3.10",
+ "watchpack": "^2.4.1",
"webpack-sources": "^3.2.3"
},
"bin": {
@@ -6637,14 +6619,14 @@
"integrity": "sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA=="
},
"@jridgewell/gen-mapping": {
- "version": "0.3.3",
- "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz",
- "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==",
+ "version": "0.3.5",
+ "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz",
+ "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==",
"dev": true,
"requires": {
- "@jridgewell/set-array": "^1.0.1",
+ "@jridgewell/set-array": "^1.2.1",
"@jridgewell/sourcemap-codec": "^1.4.10",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/trace-mapping": "^0.3.24"
}
},
"@jridgewell/resolve-uri": {
@@ -6654,19 +6636,19 @@
"dev": true
},
"@jridgewell/set-array": {
- "version": "1.1.2",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz",
- "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==",
+ "version": "1.2.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz",
+ "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==",
"dev": true
},
"@jridgewell/source-map": {
- "version": "0.3.5",
- "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.5.tgz",
- "integrity": "sha512-UTYAUj/wviwdsMfzoSJspJxbkH5o1snzwX0//0ENX1u/55kkZZkcTZP6u9bwKGkv+dkk9at4m1Cpt0uY80kcpQ==",
+ "version": "0.3.6",
+ "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz",
+ "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==",
"dev": true,
"requires": {
- "@jridgewell/gen-mapping": "^0.3.0",
- "@jridgewell/trace-mapping": "^0.3.9"
+ "@jridgewell/gen-mapping": "^0.3.5",
+ "@jridgewell/trace-mapping": "^0.3.25"
}
},
"@jridgewell/sourcemap-codec": {
@@ -6676,21 +6658,13 @@
"dev": true
},
"@jridgewell/trace-mapping": {
- "version": "0.3.18",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz",
- "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==",
+ "version": "0.3.25",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz",
+ "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==",
"dev": true,
"requires": {
- "@jridgewell/resolve-uri": "3.1.0",
- "@jridgewell/sourcemap-codec": "1.4.14"
- },
- "dependencies": {
- "@jridgewell/sourcemap-codec": {
- "version": "1.4.14",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz",
- "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==",
- "dev": true
- }
+ "@jridgewell/resolve-uri": "^3.1.0",
+ "@jridgewell/sourcemap-codec": "^1.4.14"
}
},
"@nicolo-ribaudo/chokidar-2": {
@@ -6712,30 +6686,10 @@
"integrity": "sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==",
"peer": true
},
- "@types/eslint": {
- "version": "8.4.1",
- "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.1.tgz",
- "integrity": "sha512-GE44+DNEyxxh2Kc6ro/VkIj+9ma0pO0bwv9+uHSyBrikYOHr8zYcdPvnBOp1aw8s+CjRvuSx7CyWqRrNFQ59mA==",
- "dev": true,
- "requires": {
- "@types/estree": "*",
- "@types/json-schema": "*"
- }
- },
- "@types/eslint-scope": {
- "version": "3.7.3",
- "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.3.tgz",
- "integrity": "sha512-PB3ldyrcnAicT35TWPs5IcwKD8S333HMaa2VVv4+wdvebJkjWuW/xESoB8IwRcog8HYVYamb1g/R31Qv5Bx03g==",
- "dev": true,
- "requires": {
- "@types/eslint": "*",
- "@types/estree": "*"
- }
- },
"@types/estree": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz",
- "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==",
+ "version": "1.0.5",
+ "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz",
+ "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==",
"dev": true
},
"@types/json-schema": {
@@ -6745,10 +6699,13 @@
"dev": true
},
"@types/node": {
- "version": "20.4.1",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-20.4.1.tgz",
- "integrity": "sha512-JIzsAvJeA/5iY6Y/OxZbv1lUcc8dNSE77lb2gnBH+/PJ3lFR1Ccvgwl5JWnHAkNHcRsT0TbpVOsiMKZ1F/yyJg==",
- "dev": true
+ "version": "22.5.1",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-22.5.1.tgz",
+ "integrity": "sha512-KkHsxej0j9IW1KKOOAA/XBA0z08UFSrRQHErzEfA3Vgq57eXIMYboIlHJuYIfd+lwCQjtKqUu3UnmKbtUc9yRw==",
+ "dev": true,
+ "requires": {
+ "undici-types": "~6.19.2"
+ }
},
"@types/parse-json": {
"version": "4.0.0",
@@ -6788,9 +6745,9 @@
"dev": true
},
"@webassemblyjs/ast": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz",
- "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz",
+ "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==",
"dev": true,
"requires": {
"@webassemblyjs/helper-numbers": "1.11.6",
@@ -6810,9 +6767,9 @@
"dev": true
},
"@webassemblyjs/helper-buffer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz",
- "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz",
+ "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==",
"dev": true
},
"@webassemblyjs/helper-numbers": {
@@ -6833,15 +6790,15 @@
"dev": true
},
"@webassemblyjs/helper-wasm-section": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz",
- "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz",
+ "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6"
+ "@webassemblyjs/wasm-gen": "1.12.1"
}
},
"@webassemblyjs/ieee754": {
@@ -6869,28 +6826,28 @@
"dev": true
},
"@webassemblyjs/wasm-edit": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz",
- "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz",
+ "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
- "@webassemblyjs/helper-wasm-section": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-opt": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6",
- "@webassemblyjs/wast-printer": "1.11.6"
+ "@webassemblyjs/helper-wasm-section": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-opt": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1",
+ "@webassemblyjs/wast-printer": "1.12.1"
}
},
"@webassemblyjs/wasm-gen": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz",
- "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz",
+ "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
"@webassemblyjs/leb128": "1.11.6",
@@ -6898,24 +6855,24 @@
}
},
"@webassemblyjs/wasm-opt": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz",
- "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz",
+ "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
- "@webassemblyjs/helper-buffer": "1.11.6",
- "@webassemblyjs/wasm-gen": "1.11.6",
- "@webassemblyjs/wasm-parser": "1.11.6"
+ "@webassemblyjs/ast": "1.12.1",
+ "@webassemblyjs/helper-buffer": "1.12.1",
+ "@webassemblyjs/wasm-gen": "1.12.1",
+ "@webassemblyjs/wasm-parser": "1.12.1"
}
},
"@webassemblyjs/wasm-parser": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz",
- "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz",
+ "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@webassemblyjs/helper-api-error": "1.11.6",
"@webassemblyjs/helper-wasm-bytecode": "1.11.6",
"@webassemblyjs/ieee754": "1.11.6",
@@ -6924,12 +6881,12 @@
}
},
"@webassemblyjs/wast-printer": {
- "version": "1.11.6",
- "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz",
- "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==",
+ "version": "1.12.1",
+ "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz",
+ "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==",
"dev": true,
"requires": {
- "@webassemblyjs/ast": "1.11.6",
+ "@webassemblyjs/ast": "1.12.1",
"@xtuc/long": "4.2.2"
}
},
@@ -6967,15 +6924,15 @@
"dev": true
},
"acorn": {
- "version": "8.10.0",
- "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz",
- "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==",
+ "version": "8.12.1",
+ "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz",
+ "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==",
"dev": true
},
- "acorn-import-assertions": {
- "version": "1.9.0",
- "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz",
- "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==",
+ "acorn-import-attributes": {
+ "version": "1.9.5",
+ "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz",
+ "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==",
"dev": true,
"requires": {}
},
@@ -7395,9 +7352,9 @@
}
},
"enhanced-resolve": {
- "version": "5.15.0",
- "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz",
- "integrity": "sha512-LXYT42KJ7lpIKECr2mAXIaMldcNCh/7E0KBKOu4KSfkHmP+mZmSs+8V5gBAqisWBy0OO4W5Oyys0GO1Y8KtdKg==",
+ "version": "5.17.1",
+ "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz",
+ "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==",
"dev": true,
"requires": {
"graceful-fs": "^4.2.4",
@@ -7661,9 +7618,9 @@
"dev": true
},
"graceful-fs": {
- "version": "4.2.9",
- "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz",
- "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==",
+ "version": "4.2.11",
+ "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
+ "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
"dev": true
},
"has": {
@@ -8613,9 +8570,9 @@
"dev": true
},
"serialize-javascript": {
- "version": "6.0.1",
- "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz",
- "integrity": "sha512-owoXEFjWRllis8/M1Q+Cw5k8ZH40e3zhp/ovX+Xr/vi1qj6QesbyXXViFbpNvWvPNAD62SutwEXavefrLJWj7w==",
+ "version": "6.0.2",
+ "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz",
+ "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==",
"dev": true,
"requires": {
"randombytes": "^2.1.0"
@@ -8733,9 +8690,9 @@
"dev": true
},
"terser": {
- "version": "5.19.0",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.19.0.tgz",
- "integrity": "sha512-JpcpGOQLOXm2jsomozdMDpd5f8ZHh1rR48OFgWUH3QsyZcfPgv2qDCYbcDEAYNd4OZRj2bWYKpwdll/udZCk/Q==",
+ "version": "5.31.6",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz",
+ "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==",
"dev": true,
"requires": {
"@jridgewell/source-map": "^0.3.3",
@@ -8753,16 +8710,16 @@
}
},
"terser-webpack-plugin": {
- "version": "5.3.9",
- "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz",
- "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==",
+ "version": "5.3.10",
+ "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz",
+ "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==",
"dev": true,
"requires": {
- "@jridgewell/trace-mapping": "^0.3.17",
+ "@jridgewell/trace-mapping": "^0.3.20",
"jest-worker": "^27.4.5",
"schema-utils": "^3.1.1",
"serialize-javascript": "^6.0.1",
- "terser": "^5.16.8"
+ "terser": "^5.26.0"
}
},
"to-fast-properties": {
@@ -8869,6 +8826,12 @@
"which-boxed-primitive": "^1.0.2"
}
},
+ "undici-types": {
+ "version": "6.19.8",
+ "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.19.8.tgz",
+ "integrity": "sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==",
+ "dev": true
+ },
"unicode-canonical-property-names-ecmascript": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.0.tgz",
@@ -8937,9 +8900,9 @@
"dev": true
},
"watchpack": {
- "version": "2.4.0",
- "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz",
- "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==",
+ "version": "2.4.2",
+ "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz",
+ "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==",
"dev": true,
"requires": {
"glob-to-regexp": "^0.4.1",
@@ -8947,34 +8910,33 @@
}
},
"webpack": {
- "version": "5.88.2",
- "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.88.2.tgz",
- "integrity": "sha512-JmcgNZ1iKj+aiR0OvTYtWQqJwq37Pf683dY9bVORwVbUrDhLhdn/PlO2sHsFHPkj7sHNQF3JwaAkp49V+Sq1tQ==",
+ "version": "5.94.0",
+ "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz",
+ "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==",
"dev": true,
"requires": {
- "@types/eslint-scope": "^3.7.3",
- "@types/estree": "^1.0.0",
- "@webassemblyjs/ast": "^1.11.5",
- "@webassemblyjs/wasm-edit": "^1.11.5",
- "@webassemblyjs/wasm-parser": "^1.11.5",
+ "@types/estree": "^1.0.5",
+ "@webassemblyjs/ast": "^1.12.1",
+ "@webassemblyjs/wasm-edit": "^1.12.1",
+ "@webassemblyjs/wasm-parser": "^1.12.1",
"acorn": "^8.7.1",
- "acorn-import-assertions": "^1.9.0",
- "browserslist": "^4.14.5",
+ "acorn-import-attributes": "^1.9.5",
+ "browserslist": "^4.21.10",
"chrome-trace-event": "^1.0.2",
- "enhanced-resolve": "^5.15.0",
+ "enhanced-resolve": "^5.17.1",
"es-module-lexer": "^1.2.1",
"eslint-scope": "5.1.1",
"events": "^3.2.0",
"glob-to-regexp": "^0.4.1",
- "graceful-fs": "^4.2.9",
+ "graceful-fs": "^4.2.11",
"json-parse-even-better-errors": "^2.3.1",
"loader-runner": "^4.2.0",
"mime-types": "^2.1.27",
"neo-async": "^2.6.2",
"schema-utils": "^3.2.0",
"tapable": "^2.1.1",
- "terser-webpack-plugin": "^5.3.7",
- "watchpack": "^2.4.0",
+ "terser-webpack-plugin": "^5.3.10",
+ "watchpack": "^2.4.1",
"webpack-sources": "^3.2.3"
}
},
diff --git a/src/OrchardCore.Modules/OrchardCore.AuditTrail/package.json b/src/OrchardCore.Modules/OrchardCore.AuditTrail/package.json
index 480a5181055..0f57740c22d 100644
--- a/src/OrchardCore.Modules/OrchardCore.AuditTrail/package.json
+++ b/src/OrchardCore.Modules/OrchardCore.AuditTrail/package.json
@@ -27,7 +27,7 @@
"style-loader": "^3.3.3",
"ts-loader": "^9.4.4",
"typescript": "^5.2.2",
- "webpack": "^5.88.2",
+ "webpack": "^5.94.0",
"webpack-cli": "^5.1.4"
},
"scripts": {
diff --git a/src/OrchardCore.Modules/OrchardCore.AutoSetup/Startup.cs b/src/OrchardCore.Modules/OrchardCore.AutoSetup/Startup.cs
index ddc92f68d62..fe2567d190e 100644
--- a/src/OrchardCore.Modules/OrchardCore.AutoSetup/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.AutoSetup/Startup.cs
@@ -102,7 +102,7 @@ public override void Configure(IApplicationBuilder app, IEndpointRouteBuilder ro
stringBuilder.Append(error.ErrorMessage + ' ');
}
- _logger.LogError("AutoSetup did not start, configuration has following errors: {errors}", stringBuilder.ToString());
+ _logger.LogError("AutoSetup did not start, configuration has following errors: {Errors}", stringBuilder.ToString());
}
else if (string.IsNullOrWhiteSpace(options.AutoSetupPath))
{
diff --git a/src/OrchardCore.Modules/OrchardCore.Autoroute/Handlers/AutoroutePartHandler.cs b/src/OrchardCore.Modules/OrchardCore.Autoroute/Handlers/AutoroutePartHandler.cs
index a65e882d0ef..b14f8ce646c 100644
--- a/src/OrchardCore.Modules/OrchardCore.Autoroute/Handlers/AutoroutePartHandler.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Autoroute/Handlers/AutoroutePartHandler.cs
@@ -138,7 +138,7 @@ public override async Task UpdatedAsync(UpdateContentContext context, AutorouteP
await GenerateContainedPathsFromPatternAsync(context.UpdatingItem, part);
}
- public async override Task CloningAsync(CloneContentContext context, AutoroutePart part)
+ public override async Task CloningAsync(CloneContentContext context, AutoroutePart part)
{
var clonedPart = context.CloneContentItem.As();
clonedPart.Path = await GenerateUniqueAbsolutePathAsync(part.Path, context.CloneContentItem.ContentItemId);
diff --git a/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/ContentAutorouteShapeTableProvider.cs b/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/ContentAutorouteShapeTableProvider.cs
new file mode 100644
index 00000000000..6b1c1576843
--- /dev/null
+++ b/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/ContentAutorouteShapeTableProvider.cs
@@ -0,0 +1,35 @@
+using OrchardCore.Autoroute.Models;
+using OrchardCore.ContentManagement;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement.Utilities;
+
+namespace OrchardCore.Autoroute.Services;
+
+public sealed class ContentAutorouteShapeTableProvider : ShapeTableProvider
+{
+ public override ValueTask DiscoverAsync(ShapeTableBuilder builder)
+ {
+ builder.Describe("Content")
+ .OnDisplaying(displaying =>
+ {
+ var shape = displaying.Shape;
+ var contentItem = shape.GetProperty("ContentItem");
+
+ var autoroutePart = contentItem?.As();
+
+ if (autoroutePart != null)
+ {
+ var encodedSlug = autoroutePart.Path.EncodeAlternateElement().Replace("/", "__");
+
+ // Content__Slug__[Slug] e.g. Content-Slug-example, Content-Slug-blog-my-post
+ displaying.Shape.Metadata.Alternates.Add("Content__Slug__" + encodedSlug);
+
+ // Content_[DisplayType]__Slug__[Slug] e.g. Content-Slug-example.Summary, Content-Slug-blog-my-post.Summary
+ displaying.Shape.Metadata.Alternates.Add("Content_" + displaying.Shape.Metadata.DisplayType + "__Slug__" + encodedSlug);
+ }
+ });
+
+ return ValueTask.CompletedTask;
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/WidgetAutorouteShapeTableProvider.cs b/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/WidgetAutorouteShapeTableProvider.cs
new file mode 100644
index 00000000000..be4247f0fcb
--- /dev/null
+++ b/src/OrchardCore.Modules/OrchardCore.Autoroute/Services/WidgetAutorouteShapeTableProvider.cs
@@ -0,0 +1,35 @@
+using OrchardCore.Autoroute.Models;
+using OrchardCore.ContentManagement;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement.Utilities;
+
+namespace OrchardCore.Autoroute.Services;
+
+public sealed class WidgetAutorouteShapeTableProvider : ShapeTableProvider
+{
+ public override ValueTask DiscoverAsync(ShapeTableBuilder builder)
+ {
+ builder.Describe("Widget")
+ .OnDisplaying(displaying =>
+ {
+ var shape = displaying.Shape;
+ var contentItem = shape.GetProperty("ContentItem");
+
+ var autoroutePart = contentItem?.As();
+
+ if (autoroutePart != null)
+ {
+ var encodedSlug = autoroutePart.Path.EncodeAlternateElement().Replace("/", "__");
+
+ // Widget__Slug__[Slug] e.g. Widget-Slug-example, Widget-Slug-blog-my-post
+ displaying.Shape.Metadata.Alternates.Add("Widget__Slug__" + encodedSlug);
+
+ // Widget_[DisplayType]__Slug__[Slug] e.g. Widget-Slug-example.Summary, Widget-Slug-blog-my-post.Summary
+ displaying.Shape.Metadata.Alternates.Add("Widget_" + displaying.Shape.Metadata.DisplayType + "__Slug__" + encodedSlug);
+ }
+ });
+
+ return ValueTask.CompletedTask;
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.Autoroute/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Autoroute/Startup.cs
index 3f2634d1f45..c500a1ca040 100644
--- a/src/OrchardCore.Modules/OrchardCore.Autoroute/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Autoroute/Startup.cs
@@ -10,6 +10,7 @@
using OrchardCore.Autoroute.Indexing;
using OrchardCore.Autoroute.Models;
using OrchardCore.Autoroute.Routing;
+using OrchardCore.Autoroute.Services;
using OrchardCore.Autoroute.Settings;
using OrchardCore.Autoroute.Sitemaps;
using OrchardCore.Autoroute.ViewModels;
@@ -21,6 +22,8 @@
using OrchardCore.ContentTypes.Editors;
using OrchardCore.Data;
using OrchardCore.Data.Migration;
+using OrchardCore.DisplayManagement;
+using OrchardCore.DisplayManagement.Descriptors;
using OrchardCore.Indexing;
using OrchardCore.Liquid;
using OrchardCore.Modules;
@@ -52,7 +55,7 @@ public override void ConfigureServices(IServiceCollection services)
if (!slug.StartsWith('/'))
{
- slug = "/" + slug;
+ slug = '/' + slug;
}
(var found, var entry) = await autorouteEntries.TryGetEntryByPathAsync(slug);
@@ -74,7 +77,7 @@ public override void ConfigureServices(IServiceCollection services)
services.AddScoped();
services.AddScoped();
- services.AddScoped();
+ services.AddPermissionProvider();
services.AddScoped();
services.AddScoped();
@@ -113,3 +116,21 @@ public override void ConfigureServices(IServiceCollection services)
services.AddScoped();
}
}
+
+[RequireFeatures("OrchardCore.Contents")]
+public sealed class ContentAutourouteStartup : StartupBase
+{
+ public override void ConfigureServices(IServiceCollection services)
+ {
+ services.AddShapeTableProvider();
+ }
+}
+
+[RequireFeatures("OrchardCore.Widgets")]
+public sealed class WidgetAutourouteStartup : StartupBase
+{
+ public override void ConfigureServices(IServiceCollection services)
+ {
+ services.AddShapeTableProvider();
+ }
+}
diff --git a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/AdminMenu.cs
index d0b3c30881c..08f64b7ce73 100644
--- a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/AdminMenu.cs
@@ -3,19 +3,17 @@
namespace OrchardCore.BackgroundTasks;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
internal readonly IStringLocalizer S;
- public AdminMenu(IStringLocalizer localizer) => S = localizer;
-
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ public AdminMenu(IStringLocalizer stringLocalizer)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
+ S = stringLocalizer;
+ }
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
+ {
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Tasks"], S["Tasks"].PrefixPosition(), tasks => tasks
@@ -27,6 +25,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Startup.cs b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Startup.cs
index 65705a7a8ee..6511d01e1d9 100644
--- a/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.BackgroundTasks/Startup.cs
@@ -12,8 +12,8 @@ public override void ConfigureServices(IServiceCollection services)
{
services
.AddScoped()
- .AddScoped()
- .AddScoped()
+ .AddPermissionProvider()
+ .AddNavigationProvider()
.AddScoped();
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Media/Startup.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Media/Startup.cs
index d1844ad0fcc..ca546e5dc46 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Media/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Media/Startup.cs
@@ -1,5 +1,5 @@
using Microsoft.Extensions.DependencyInjection;
-using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement;
using OrchardCore.Modules;
namespace OrchardCore.ContentFields.Media;
@@ -9,6 +9,6 @@ public sealed class Startup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
- services.AddScoped();
+ services.AddShapeTableProvider();
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/BooleanFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/BooleanFieldSettingsDriver.cs
index ddf595f35a9..f7bb762d5be 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/BooleanFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/BooleanFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("BooleanFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Label = settings.Label;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateFieldSettingsDriver.cs
index 76c91f54e7b..c18631f184e 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("DateFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateTimeFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateTimeFieldSettingsDriver.cs
index 4637b788cc2..f6a080d75cb 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateTimeFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/DateTimeFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("DateTimeFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LinkFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LinkFieldSettingsDriver.cs
index fae978770ef..a829d214f43 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LinkFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LinkFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("LinkFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.HintLinkText = settings.HintLinkText;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LocalizationSetContentPickerFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LocalizationSetContentPickerFieldSettingsDriver.cs
index c97990ec069..bfcae5bfd5f 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LocalizationSetContentPickerFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/LocalizationSetContentPickerFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -15,7 +14,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("LocalizationSetContentPickerFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/NumericFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/NumericFieldSettingsDriver.cs
index a1d5e6584bb..4c402f89786 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/NumericFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/NumericFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("NumericFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TextFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TextFieldSettingsDriver.cs
index 69a36e7c2fe..4619633d152 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TextFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TextFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("TextFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TimeFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TimeFieldSettingsDriver.cs
index 7dc0ee25454..4cd8df6d16c 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TimeFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/TimeFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,7 +12,7 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("TimeFieldSettings_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
model.Hint = settings.Hint;
model.Required = settings.Required;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/UserPickerFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/UserPickerFieldSettingsDriver.cs
index c6fbb21ea96..71b4f6f00b1 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/UserPickerFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/UserPickerFieldSettingsDriver.cs
@@ -24,17 +24,15 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
model.Hint = settings.Hint;
model.Required = settings.Required;
model.Multiple = settings.Multiple;
- var roles = (await _roleService.GetRoleNamesAsync())
- .Except(RoleHelper.SystemRoleNames, StringComparer.OrdinalIgnoreCase)
- .Select(roleName => new RoleEntry
- {
- Role = roleName,
- IsSelected = settings.DisplayedRoles.Contains(roleName, StringComparer.OrdinalIgnoreCase)
- })
- .ToArray();
+ var roles = await _roleService.GetAssignableRolesAsync();
+ var roleEntries = roles.Select(role => new RoleEntry
+ {
+ Role = role.RoleName,
+ IsSelected = settings.DisplayedRoles.Contains(role.RoleName, StringComparer.OrdinalIgnoreCase),
+ }).ToArray();
- model.Roles = roles;
- model.DisplayAllUsers = settings.DisplayAllUsers || !roles.Where(x => x.IsSelected).Any();
+ model.Roles = roleEntries;
+ model.DisplayAllUsers = settings.DisplayAllUsers || !roleEntries.Where(x => x.IsSelected).Any();
}).Location("Content");
}
@@ -51,7 +49,12 @@ public override async Task UpdateAsync(ContentPartFieldDefinitio
Multiple = model.Multiple
};
- var selectedRoles = model.Roles.Where(x => x.IsSelected).Select(x => x.Role).ToArray();
+ var roles = await _roleService.GetAssignableRolesAsync();
+
+ var selectedRoles = model.Roles
+ .Where(x => x.IsSelected && roles.Any(y => y.RoleName == x.Role))
+ .Select(x => x.Role)
+ .ToArray();
if (model.DisplayAllUsers || selectedRoles.Length == 0)
{
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/YoutubeFieldSettingsDriver.cs b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/YoutubeFieldSettingsDriver.cs
index 587251dc49a..a9ad2f3d18a 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/YoutubeFieldSettingsDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentFields/Settings/YoutubeFieldSettingsDriver.cs
@@ -1,4 +1,3 @@
-using System.Text.Json.Nodes;
using OrchardCore.ContentFields.Fields;
using OrchardCore.ContentManagement.Metadata.Models;
using OrchardCore.ContentTypes.Editors;
@@ -13,14 +12,17 @@ public override IDisplayResult Edit(ContentPartFieldDefinition partFieldDefiniti
{
return Initialize("YoutubeFieldSetting_Edit", model =>
{
- var settings = partFieldDefinition.Settings.ToObject();
+ var settings = partFieldDefinition.GetSettings();
- model.Height = model.Height != default ? model.Height : 315;
- model.Width = model.Width != default ? model.Width : 560;
+ model.Hint = settings.Hint;
+ model.Label = settings.Label;
+ model.Height = settings.Height != default ? settings.Height : 315;
+ model.Width = settings.Width != default ? settings.Width : 560;
+ model.Required = settings.Required;
}).Location("Content");
}
- public async override Task UpdateAsync(ContentPartFieldDefinition partFieldDefinition, UpdatePartFieldEditorContext context)
+ public override async Task UpdateAsync(ContentPartFieldDefinition partFieldDefinition, UpdatePartFieldEditorContext context)
{
var model = new YoutubeFieldSettings();
await context.Updater.TryUpdateModelAsync(model, Prefix);
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/AdminMenu.cs
index ea0f1b77a91..d13935970c3 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/AdminMenu.cs
@@ -5,7 +5,7 @@
namespace OrchardCore.ContentLocalization;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _providersRouteValues = new()
{
@@ -21,18 +21,13 @@ public sealed class AdminMenu : INavigationProvider
internal readonly IStringLocalizer S;
- public AdminMenu(IStringLocalizer localizer)
+ public AdminMenu(IStringLocalizer stringLocalizer)
{
- S = localizer;
+ S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Settings"], settings => settings
@@ -55,6 +50,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Liquid/SwitchCultureUrlFilter.cs b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Liquid/SwitchCultureUrlFilter.cs
index 1dc6a3bb458..89afdf56bc1 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Liquid/SwitchCultureUrlFilter.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Liquid/SwitchCultureUrlFilter.cs
@@ -35,6 +35,6 @@ public ValueTask ProcessAsync(FluidValue input, FilterArguments argu
contentItemUrl = request.Path.Value,
queryStringValue = request.QueryString.Value,
});
- return new ValueTask(FluidValue.Create(url, context.Options));
+ return ValueTask.FromResult(FluidValue.Create(url, context.Options));
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/LocalizedContentItemsQueryProvider.cs b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/LocalizedContentItemsQueryProvider.cs
index ed8b8736efc..122db4ba656 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/LocalizedContentItemsQueryProvider.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/LocalizedContentItemsQueryProvider.cs
@@ -13,40 +13,41 @@ namespace OrchardCore.ContentLocalization.Sitemaps;
public class LocalizedContentItemsQueryProvider : IContentItemsQueryProvider
{
- private readonly ISession _session;
+ private readonly IStore _store;
private readonly IRouteableContentTypeCoordinator _routeableContentTypeCoordinator;
private readonly ILocalizationService _localizationService;
public LocalizedContentItemsQueryProvider(
- ISession session,
+ IStore store,
IRouteableContentTypeCoordinator routeableContentTypeCoordinator,
ILocalizationService localizationService
)
{
- _session = session;
+ _store = store;
_routeableContentTypeCoordinator = routeableContentTypeCoordinator;
_localizationService = localizationService;
}
- public async Task GetContentItemsAsync(ContentTypesSitemapSource source, ContentItemsQueryContext queryContext)
+ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, ContentItemsQueryContext context, int? skip = null, int? take = null)
{
var routeableContentTypeDefinitions = await _routeableContentTypeCoordinator.ListRoutableTypeDefinitionsAsync();
+ using var session = _store.CreateSession(withTracking: false);
+
+ IEnumerable contentItems = null;
if (source.IndexAll)
{
// Assumption here is that at least one content type will be localized.
var ctdNames = routeableContentTypeDefinitions.Select(ctd => ctd.Name);
- var queryResults = await _session.Query()
+ contentItems = await session.Query()
.With(x => x.Published && x.ContentType.IsIn(ctdNames))
.OrderBy(x => x.CreatedUtc)
+ .ThenBy(x => x.Id)
+ .Skip(skip ?? 0)
+ .Take(take ?? 0)
.ListAsync();
- queryContext.ContentItems = queryResults;
-
- // Provide all content items with localization as reference content items.
- queryContext.ReferenceContentItems = queryResults
- .Where(ci => ci.Has());
}
else if (source.LimitItems)
{
@@ -61,41 +62,31 @@ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, Content
if (contentType.Parts.Any(ctd => string.Equals(ctd.Name, nameof(LocalizationPart), StringComparison.Ordinal)))
{
- // Get all content items here for reference. Then reduce by default culture.
- // We know that the content item should be localized.
- // If it doesn't have a localization part, the content item should have been saved.
- var queryResults = await _session.Query()
- .With(ci => ci.ContentType == source.LimitedContentType.ContentTypeName && ci.Published)
- .OrderBy(ci => ci.CreatedUtc)
- .With()
- .ListAsync();
-
// When limiting items Content item is valid if it is for the default culture.
var defaultCulture = await _localizationService.GetDefaultCultureAsync();
- // Reduce by default culture.
- var items = queryResults
- .Where(ci => string.Equals(ci.As().Culture, defaultCulture, StringComparison.Ordinal))
- .Skip(source.LimitedContentType.Skip)
- .Take(source.LimitedContentType.Take);
-
- queryContext.ContentItems = items;
-
- // Provide all content items with localization as reference content items.
- queryContext.ReferenceContentItems = queryResults
- .Where(ci => ci.Has());
+ // Get all content items here for reference. Then reduce by default culture.
+ // We know that the content item should be localized.
+ // If it doesn't have a localization part, the content item should have been saved.
+ contentItems = await session.Query()
+ .With(ci => ci.ContentType == source.LimitedContentType.ContentTypeName && ci.Published)
+ .OrderBy(ci => ci.CreatedUtc)
+ .ThenBy(ci => ci.Id)
+ .With(x => x.Culture == defaultCulture)
+ .Take(take ?? 0)
+ .Skip(skip ?? 0)
+ .ListAsync();
}
else
{
// Content type is not localized. Produce standard results.
- var queryResults = await _session.Query()
+ contentItems = await session.Query()
.With(x => x.ContentType == source.LimitedContentType.ContentTypeName && x.Published)
.OrderBy(x => x.CreatedUtc)
- .Skip(source.LimitedContentType.Skip)
- .Take(source.LimitedContentType.Take)
+ .Skip(skip ?? 0)
+ .Take(take ?? 0)
.ListAsync();
- queryContext.ContentItems = queryResults;
}
}
else
@@ -106,16 +97,23 @@ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, Content
.Select(x => x.Name);
// No advantage here in reducing with localized index.
- var queryResults = await _session.Query()
+
+ contentItems = await session.Query()
.With(x => x.ContentType.IsIn(typesToIndex) && x.Published)
.OrderBy(x => x.CreatedUtc)
+ .ThenBy(x => x.Id)
+ .Skip(skip ?? 0)
+ .Take(take ?? 0)
.ListAsync();
- queryContext.ContentItems = queryResults;
+ }
+
+ if (contentItems != null)
+ {
+ context.ContentItems = contentItems;
// Provide all content items with localization as reference content items.
- queryContext.ReferenceContentItems = queryResults
- .Where(ci => ci.Has());
+ context.ReferenceContentItems = contentItems.Where(ci => ci.Has());
}
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/SitemapUrlHrefLangExtendedMetadataProvider.cs b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/SitemapUrlHrefLangExtendedMetadataProvider.cs
index cc0d943f6db..77b8450d880 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/SitemapUrlHrefLangExtendedMetadataProvider.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Sitemaps/SitemapUrlHrefLangExtendedMetadataProvider.cs
@@ -33,7 +33,9 @@ public async Task ApplyExtendedMetadataAsync(
XElement url)
{
var part = contentItem.As();
- if (part == null)
+ if (part == null ||
+ queryContext.ReferenceContentItems == null ||
+ !queryContext.ReferenceContentItems.Any())
{
return true;
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Startup.cs b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Startup.cs
index 2d7c4ac6f7e..5c66b843436 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentLocalization/Startup.cs
@@ -21,7 +21,6 @@
using OrchardCore.Modules;
using OrchardCore.Navigation;
using OrchardCore.Security.Permissions;
-using OrchardCore.Settings;
using OrchardCore.Sitemaps.Builders;
namespace OrchardCore.ContentLocalization;
@@ -40,7 +39,7 @@ public override void ConfigureServices(IServiceCollection services)
services.AddSingleton();
services.AddContentLocalization();
- services.AddScoped();
+ services.AddPermissionProvider();
services.AddScoped();
services.AddScoped();
@@ -62,10 +61,10 @@ public override void ConfigureServices(IServiceCollection services)
{
services.AddScoped, ContentCulturePickerNavbarDisplayDriver>();
services.AddLiquidFilter("switch_culture_url");
- services.AddScoped();
+ services.AddNavigationProvider();
services.AddScoped();
- services.AddScoped, ContentCulturePickerSettingsDriver>();
- services.AddScoped, ContentRequestCultureProviderSettingsDriver>();
+ services.AddSiteDisplayDriver();
+ services.AddSiteDisplayDriver();
services.Configure(options => options.AddInitialRequestCultureProvider(new ContentRequestCultureProvider()));
services.Configure(_shellConfiguration.GetSection("OrchardCore_ContentLocalization_CulturePickerOptions"));
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/AdminMenu.cs
index 7884038bc9b..02eec290c50 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/AdminMenu.cs
@@ -5,24 +5,19 @@
namespace OrchardCore.ContentTypes;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
private static readonly string _adminControllerName = typeof(AdminController).ControllerName();
internal readonly IStringLocalizer S;
- public AdminMenu(IStringLocalizer localizer)
+ public AdminMenu(IStringLocalizer stringLocalizer)
{
- S = localizer;
+ S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Content"], content => content
.Add(S["Content Definition"], S["Content Definition"].PrefixPosition("9"), contentDefinition => contentDefinition
@@ -39,6 +34,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ContentDefinitionDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ContentDefinitionDeploymentSource.cs
index 703f0522860..f499be5309c 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ContentDefinitionDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ContentDefinitionDeploymentSource.cs
@@ -4,7 +4,8 @@
namespace OrchardCore.ContentTypes.Deployment;
-public class ContentDefinitionDeploymentSource : IDeploymentSource
+public class ContentDefinitionDeploymentSource
+ : DeploymentSourceBase
{
private readonly IContentDefinitionStore _contentDefinitionStore;
@@ -13,24 +14,19 @@ public ContentDefinitionDeploymentSource(IContentDefinitionStore contentDefiniti
_contentDefinitionStore = contentDefinitionStore;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(ContentDefinitionDeploymentStep step, DeploymentPlanResult result)
{
- if (step is not ContentDefinitionDeploymentStep contentDefinitionStep)
- {
- return;
- }
-
var contentTypeDefinitionRecord = await _contentDefinitionStore.LoadContentDefinitionAsync();
- var contentTypes = contentDefinitionStep.IncludeAll
+ var contentTypes = step.IncludeAll
? contentTypeDefinitionRecord.ContentTypeDefinitionRecords
: contentTypeDefinitionRecord.ContentTypeDefinitionRecords
- .Where(x => contentDefinitionStep.ContentTypes.Contains(x.Name));
+ .Where(x => step.ContentTypes.Contains(x.Name));
- var contentParts = contentDefinitionStep.IncludeAll
+ var contentParts = step.IncludeAll
? contentTypeDefinitionRecord.ContentPartDefinitionRecords
: contentTypeDefinitionRecord.ContentPartDefinitionRecords
- .Where(x => contentDefinitionStep.ContentParts.Contains(x.Name));
+ .Where(x => step.ContentParts.Contains(x.Name));
result.Steps.Add(new JsonObject
{
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/DeleteContentDefinitionDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/DeleteContentDefinitionDeploymentSource.cs
index 4d021d43746..22e024d0107 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/DeleteContentDefinitionDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/DeleteContentDefinitionDeploymentSource.cs
@@ -3,20 +3,16 @@
namespace OrchardCore.ContentTypes.Deployment;
-public class DeleteContentDefinitionDeploymentSource : IDeploymentSource
+public class DeleteContentDefinitionDeploymentSource
+ : DeploymentSourceBase
{
- public Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override Task ProcessAsync(DeleteContentDefinitionDeploymentStep step, DeploymentPlanResult result)
{
- if (step is not DeleteContentDefinitionDeploymentStep deleteContentDefinitionStep)
- {
- return Task.CompletedTask;
- }
-
result.Steps.Add(new JsonObject
{
["name"] = "DeleteContentDefinition",
- ["ContentTypes"] = JArray.FromObject(deleteContentDefinitionStep.ContentTypes),
- ["ContentParts"] = JArray.FromObject(deleteContentDefinitionStep.ContentParts),
+ ["ContentTypes"] = JArray.FromObject(step.ContentTypes),
+ ["ContentParts"] = JArray.FromObject(step.ContentParts),
});
return Task.CompletedTask;
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ReplaceContentDefinitionDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ReplaceContentDefinitionDeploymentSource.cs
index 429b7805746..3d660902753 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ReplaceContentDefinitionDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Deployment/ReplaceContentDefinitionDeploymentSource.cs
@@ -4,7 +4,8 @@
namespace OrchardCore.ContentTypes.Deployment;
-public class ReplaceContentDefinitionDeploymentSource : IDeploymentSource
+public class ReplaceContentDefinitionDeploymentSource
+ : DeploymentSourceBase
{
private readonly IContentDefinitionStore _contentDefinitionStore;
@@ -13,24 +14,19 @@ public ReplaceContentDefinitionDeploymentSource(IContentDefinitionStore contentD
_contentDefinitionStore = contentDefinitionStore;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(ReplaceContentDefinitionDeploymentStep step, DeploymentPlanResult result)
{
- if (step is not ReplaceContentDefinitionDeploymentStep replaceContentDefinitionStep)
- {
- return;
- }
-
var contentTypeDefinitionRecord = await _contentDefinitionStore.LoadContentDefinitionAsync();
- var contentTypes = replaceContentDefinitionStep.IncludeAll
+ var contentTypes = step.IncludeAll
? contentTypeDefinitionRecord.ContentTypeDefinitionRecords
: contentTypeDefinitionRecord.ContentTypeDefinitionRecords
- .Where(x => replaceContentDefinitionStep.ContentTypes.Contains(x.Name));
+ .Where(x => step.ContentTypes.Contains(x.Name));
- var contentParts = replaceContentDefinitionStep.IncludeAll
+ var contentParts = step.IncludeAll
? contentTypeDefinitionRecord.ContentPartDefinitionRecords
: contentTypeDefinitionRecord.ContentPartDefinitionRecords
- .Where(x => replaceContentDefinitionStep.ContentParts.Contains(x.Name));
+ .Where(x => step.ContentParts.Contains(x.Name));
result.Steps.Add(new JsonObject
{
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ContentDefinitionStep.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ContentDefinitionStep.cs
index b42b7b73194..6e9e751f718 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ContentDefinitionStep.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ContentDefinitionStep.cs
@@ -11,7 +11,7 @@ namespace OrchardCore.ContentTypes.RecipeSteps;
///
/// This recipe step creates content definitions.
///
-public sealed class ContentDefinitionStep : IRecipeStepHandler
+public sealed class ContentDefinitionStep : NamedRecipeStepHandler
{
private readonly IContentDefinitionManager _contentDefinitionManager;
@@ -20,18 +20,14 @@ public sealed class ContentDefinitionStep : IRecipeStepHandler
public ContentDefinitionStep(
IContentDefinitionManager contentDefinitionManager,
IStringLocalizer stringLocalizer)
+ : base("ContentDefinition")
{
_contentDefinitionManager = contentDefinitionManager;
S = stringLocalizer;
}
- public async Task ExecuteAsync(RecipeExecutionContext context)
+ protected override async Task HandleAsync(RecipeExecutionContext context)
{
- if (!string.Equals(context.Name, "ContentDefinition", StringComparison.OrdinalIgnoreCase))
- {
- return;
- }
-
var step = context.Step.ToObject();
foreach (var contentType in step.ContentTypes)
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/DeleteContentDefinitionStep.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/DeleteContentDefinitionStep.cs
index 918ceb33a32..9ce53d9e213 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/DeleteContentDefinitionStep.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/DeleteContentDefinitionStep.cs
@@ -8,22 +8,18 @@ namespace OrchardCore.ContentTypes.RecipeSteps;
///
/// This recipe step deletes content definition records.
///
-public sealed class DeleteContentDefinitionStep : IRecipeStepHandler
+public sealed class DeleteContentDefinitionStep : NamedRecipeStepHandler
{
private readonly IContentDefinitionManager _contentDefinitionManager;
public DeleteContentDefinitionStep(IContentDefinitionManager contentDefinitionManager)
+ : base("DeleteContentDefinition")
{
_contentDefinitionManager = contentDefinitionManager;
}
- public async Task ExecuteAsync(RecipeExecutionContext context)
+ protected override async Task HandleAsync(RecipeExecutionContext context)
{
- if (!string.Equals(context.Name, "DeleteContentDefinition", StringComparison.OrdinalIgnoreCase))
- {
- return;
- }
-
var step = context.Step.ToObject();
foreach (var contentType in step.ContentTypes)
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ReplaceContentDefinitionStep.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ReplaceContentDefinitionStep.cs
index 63e072724e2..4e8d6990e3f 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ReplaceContentDefinitionStep.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/RecipeSteps/ReplaceContentDefinitionStep.cs
@@ -9,22 +9,18 @@ namespace OrchardCore.ContentTypes.RecipeSteps;
///
/// This recipe step replaces content definition records.
///
-public sealed class ReplaceContentDefinitionStep : IRecipeStepHandler
+public sealed class ReplaceContentDefinitionStep : NamedRecipeStepHandler
{
private readonly IContentDefinitionManager _contentDefinitionManager;
public ReplaceContentDefinitionStep(IContentDefinitionManager contentDefinitionManager)
+ : base("ReplaceContentDefinition")
{
_contentDefinitionManager = contentDefinitionManager;
}
- public async Task ExecuteAsync(RecipeExecutionContext context)
+ protected override async Task HandleAsync(RecipeExecutionContext context)
{
- if (!string.Equals(context.Name, "ReplaceContentDefinition", StringComparison.OrdinalIgnoreCase))
- {
- return;
- }
-
var step = context.Step.ToObject();
// Delete existing parts first, as deleting them later will clear any imported content types using them.
diff --git a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Startup.cs b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Startup.cs
index f56d7e70bbb..5de96f75766 100644
--- a/src/OrchardCore.Modules/OrchardCore.ContentTypes/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.ContentTypes/Startup.cs
@@ -19,8 +19,8 @@ public sealed class Startup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
- services.AddScoped();
- services.AddScoped();
+ services.AddPermissionProvider();
+ services.AddNavigationProvider();
services.AddScoped();
services.AddScoped();
services.AddScoped();
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/AdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.Contents/AdminMenu.cs
index 70d0c584538..8c0b556131f 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/AdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/AdminMenu.cs
@@ -14,7 +14,7 @@
namespace OrchardCore.Contents;
-public sealed class AdminMenu : INavigationProvider
+public sealed class AdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _routeValues = new()
{
@@ -45,7 +45,7 @@ public AdminMenu(
LinkGenerator linkGenerator,
IAuthorizationService authorizationService,
ISiteService siteService,
- IStringLocalizer localizer)
+ IStringLocalizer stringLocalizer)
{
_contentDefinitionManager = contentDefinitionManager;
_contentManager = contentManager;
@@ -53,16 +53,11 @@ public AdminMenu(
_linkGenerator = linkGenerator;
_authorizationService = authorizationService;
_siteService = siteService;
- S = localizer;
+ S = stringLocalizer;
}
- public async Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override async ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return;
- }
-
var context = _httpContextAccessor.HttpContext;
var contentTypeDefinitions = await _contentDefinitionManager.ListTypeDefinitionsAsync();
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Startup.cs
index 8e9e4d50b5c..c78786f0dc1 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/AuditTrail/Startup.cs
@@ -14,7 +14,6 @@
using OrchardCore.Data.Migration;
using OrchardCore.DisplayManagement.Handlers;
using OrchardCore.Modules;
-using OrchardCore.Settings;
namespace OrchardCore.Contents.AuditTrail;
@@ -32,7 +31,7 @@ public override void ConfigureServices(IServiceCollection services)
services.AddTransient, ContentAuditTrailEventConfiguration>();
services.AddScoped();
- services.AddScoped, ContentAuditTrailSettingsDisplayDriver>();
+ services.AddSiteDisplayDriver();
services.AddScoped, AuditTrailContentEventDisplayDriver>();
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/AddToDeploymentPlanController.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/AddToDeploymentPlanController.cs
index f7aa0e53480..4e6b20228a0 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/AddToDeploymentPlanController.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/AddToDeploymentPlanController.cs
@@ -126,7 +126,16 @@ await _authorizationService.AuthorizeAsync(User, OrchardCore.Deployment.CommonPe
return Forbid();
}
- var step = (ContentItemDeploymentStep)_factories.FirstOrDefault(x => x.Name == nameof(ContentItemDeploymentStep)).Create();
+
+ var step = (ContentItemDeploymentStep)_factories.FirstOrDefault(x => x.Name == nameof(ContentItemDeploymentStep))?.Create();
+
+ if (step is null)
+ {
+ await _notifier.WarningAsync(H["Couldn't add selected content to deployment plan."]);
+
+ return BadRequest();
+ }
+
step.ContentItemId = item.ContentItemId;
deploymentPlan.DeploymentSteps.Add(step);
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/ContentItemDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/ContentItemDeploymentSource.cs
index 10e58072baf..03b49f2c683 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/ContentItemDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AddToDeploymentPlan/ContentItemDeploymentSource.cs
@@ -4,7 +4,8 @@
namespace OrchardCore.Contents.Deployment.AddToDeploymentPlan;
-public class ContentItemDeploymentSource : IDeploymentSource
+public class ContentItemDeploymentSource
+ : DeploymentSourceBase
{
private readonly IContentManager _contentManager;
@@ -13,16 +14,14 @@ public ContentItemDeploymentSource(IContentManager contentManager)
_contentManager = contentManager;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(ContentItemDeploymentStep step, DeploymentPlanResult result)
{
- var contentItemDeploymentStep = step as ContentItemDeploymentStep;
-
- if (contentItemDeploymentStep == null || contentItemDeploymentStep.ContentItemId == null)
+ if (step.ContentItemId == null)
{
return;
}
- var contentItem = await _contentManager.GetAsync(contentItemDeploymentStep.ContentItemId);
+ var contentItem = await _contentManager.GetAsync(step.ContentItemId);
if (contentItem == null)
{
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AllContentDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AllContentDeploymentSource.cs
index 70fd21f462a..bf2019faca2 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AllContentDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/AllContentDeploymentSource.cs
@@ -6,7 +6,8 @@
namespace OrchardCore.Contents.Deployment;
-public class AllContentDeploymentSource : IDeploymentSource
+public class AllContentDeploymentSource
+ : DeploymentSourceBase
{
private readonly ISession _session;
@@ -15,15 +16,8 @@ public AllContentDeploymentSource(ISession session)
_session = session;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(AllContentDeploymentStep step, DeploymentPlanResult result)
{
- var allContentStep = step as AllContentDeploymentStep;
-
- if (allContentStep == null)
- {
- return;
- }
-
var data = new JsonArray();
result.Steps.Add(new JsonObject
{
@@ -35,10 +29,10 @@ public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlan
{
var objectData = JObject.FromObject(contentItem);
- // Don't serialize the Id as it could be interpreted as an updated object when added back to YesSql
+ // Don't serialize the Id as it could be interpreted as an updated object when added back to YesSql.
objectData.Remove(nameof(ContentItem.Id));
- if (allContentStep.ExportAsSetupRecipe)
+ if (step.ExportAsSetupRecipe)
{
objectData[nameof(ContentItem.Owner)] = "[js: parameters('AdminUserId')]";
objectData[nameof(ContentItem.Author)] = "[js: parameters('AdminUsername')]";
@@ -51,7 +45,5 @@ public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlan
data.Add(objectData);
}
-
- return;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ContentDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ContentDeploymentSource.cs
index 358c3ea1cf1..767605aae61 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ContentDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ContentDeploymentSource.cs
@@ -7,7 +7,8 @@
namespace OrchardCore.Contents.Deployment;
-public class ContentDeploymentSource : IDeploymentSource
+public class ContentDeploymentSource
+ : DeploymentSourceBase
{
private readonly ISession _session;
@@ -16,27 +17,19 @@ public ContentDeploymentSource(ISession session)
_session = session;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(ContentDeploymentStep step, DeploymentPlanResult result)
{
// TODO: Batch and create separate content files in the result.
-
- var contentStep = step as ContentDeploymentStep;
-
- if (contentStep == null)
- {
- return;
- }
-
var data = new JsonArray();
- foreach (var contentItem in await _session.Query(x => x.Published && x.ContentType.IsIn(contentStep.ContentTypes)).ListAsync())
+ foreach (var contentItem in await _session.Query(x => x.Published && x.ContentType.IsIn(step.ContentTypes)).ListAsync())
{
var objectData = JObject.FromObject(contentItem);
// Don't serialize the Id as it could be interpreted as an updated object when added back to YesSql.
objectData.Remove(nameof(ContentItem.Id));
- if (contentStep.ExportAsSetupRecipe)
+ if (step.ExportAsSetupRecipe)
{
objectData[nameof(ContentItem.Owner)] = "[js: parameters('AdminUserId')]";
objectData[nameof(ContentItem.Author)] = "[js: parameters('AdminUsername')]";
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetAdminMenu.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetAdminMenu.cs
index e2bc1d6911e..ea771404b90 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetAdminMenu.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetAdminMenu.cs
@@ -4,7 +4,7 @@
namespace OrchardCore.Contents.Deployment.ExportContentToDeploymentTarget;
-public sealed class ExportContentToDeploymentTargetAdminMenu : INavigationProvider
+public sealed class ExportContentToDeploymentTargetAdminMenu : AdminNavigationProvider
{
private static readonly RouteValueDictionary _routeValues = new()
{
@@ -14,18 +14,13 @@ public sealed class ExportContentToDeploymentTargetAdminMenu : INavigationProvid
internal readonly IStringLocalizer S;
- public ExportContentToDeploymentTargetAdminMenu(IStringLocalizer localizer)
+ public ExportContentToDeploymentTargetAdminMenu(IStringLocalizer stringLocalizer)
{
- S = localizer;
+ S = stringLocalizer;
}
- public Task BuildNavigationAsync(string name, NavigationBuilder builder)
+ protected override ValueTask BuildAsync(NavigationBuilder builder)
{
- if (!NavigationHelper.IsAdminMenu(name))
- {
- return Task.CompletedTask;
- }
-
builder
.Add(S["Configuration"], configuration => configuration
.Add(S["Import/Export"], S["Import/Export"].PrefixPosition(), import => import
@@ -39,6 +34,6 @@ public Task BuildNavigationAsync(string name, NavigationBuilder builder)
)
);
- return Task.CompletedTask;
+ return ValueTask.CompletedTask;
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetDeploymentSource.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetDeploymentSource.cs
index 9f4dc8d047f..fd9d265606c 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetDeploymentSource.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetDeploymentSource.cs
@@ -8,7 +8,8 @@
namespace OrchardCore.Contents.Deployment.ExportContentToDeploymentTarget;
-public class ExportContentToDeploymentTargetDeploymentSource : IDeploymentSource
+public class ExportContentToDeploymentTargetDeploymentSource
+ : DeploymentSourceBase
{
private readonly IContentManager _contentManager;
private readonly ISession _session;
@@ -24,15 +25,8 @@ public ExportContentToDeploymentTargetDeploymentSource(
_updateModelAccessor = updateModelAccessor;
}
- public async Task ProcessDeploymentStepAsync(DeploymentStep step, DeploymentPlanResult result)
+ protected override async Task ProcessAsync(ExportContentToDeploymentTargetDeploymentStep step, DeploymentPlanResult result)
{
- var exportContentToDeploymentTargetContentDeploymentStep = step as ExportContentToDeploymentTargetDeploymentStep;
-
- if (exportContentToDeploymentTargetContentDeploymentStep == null)
- {
- return;
- }
-
var data = new JsonArray();
result.Steps.Add(new JsonObject
{
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetStartup.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetStartup.cs
index 581c9a6bdb5..a95510782bd 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetStartup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Deployment/ExportContentToDeploymentTarget/ExportContentToDeploymentTargetStartup.cs
@@ -6,7 +6,6 @@
using OrchardCore.DisplayManagement.Handlers;
using OrchardCore.Modules;
using OrchardCore.Navigation;
-using OrchardCore.Settings;
using OrchardCore.Settings.Deployment;
namespace OrchardCore.Contents.Deployment.ExportContentToDeploymentTarget;
@@ -16,9 +15,9 @@ public sealed class ExportContentToDeploymentTargetStartup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
- services.AddScoped();
+ services.AddNavigationProvider();
- services.AddScoped, ExportContentToDeploymentTargetSettingsDisplayDriver>();
+ services.AddSiteDisplayDriver();
services.AddDeployment();
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/CreateEndpoint.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/CreateEndpoint.cs
index d76cb805893..d89deb2329e 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/CreateEndpoint.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/CreateEndpoint.cs
@@ -5,10 +5,12 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc.ModelBinding;
using Microsoft.AspNetCore.Routing;
+using Microsoft.Extensions.Options;
using OrchardCore.ContentManagement;
using OrchardCore.ContentManagement.Handlers;
using OrchardCore.ContentManagement.Metadata;
using OrchardCore.DisplayManagement.ModelBinding;
+using OrchardCore.Json;
using OrchardCore.Modules;
namespace OrchardCore.Contents.Endpoints.Api;
@@ -37,6 +39,7 @@ private static async Task HandleAsync(
IContentDefinitionManager contentDefinitionManager,
IUpdateModelAccessor updateModelAccessor,
HttpContext httpContext,
+ IOptions options,
bool draft = false)
{
if (!await authorizationService.AuthorizeAsync(httpContext.User, CommonPermissions.AccessContentApi))
@@ -123,7 +126,7 @@ private static async Task HandleAsync(
await contentManager.SaveDraftAsync(contentItem);
}
- return TypedResults.Ok(contentItem);
+ return Results.Json(contentItem, options.Value.SerializerOptions);
}
private static void AddValidationErrorsToModelState(ContentValidateResult result, ModelStateDictionary modelState)
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/DeleteEndpoint.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/DeleteEndpoint.cs
index c6b26c5e64e..677e725a607 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/DeleteEndpoint.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/DeleteEndpoint.cs
@@ -2,7 +2,9 @@
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Routing;
+using Microsoft.Extensions.Options;
using OrchardCore.ContentManagement;
+using OrchardCore.Json;
using OrchardCore.Modules;
namespace OrchardCore.Contents.Endpoints.Api;
@@ -23,7 +25,8 @@ private static async Task HandleAsync(
string contentItemId,
IContentManager contentManager,
IAuthorizationService authorizationService,
- HttpContext httpContext)
+ HttpContext httpContext,
+ IOptions options)
{
if (!await authorizationService.AuthorizeAsync(httpContext.User, CommonPermissions.AccessContentApi))
{
@@ -44,6 +47,6 @@ private static async Task HandleAsync(
await contentManager.RemoveAsync(contentItem);
- return TypedResults.Ok(contentItem);
+ return Results.Json(contentItem, options.Value.SerializerOptions);
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/GetEndpoint.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/GetEndpoint.cs
index 441f7d77ead..e3d7e870cbd 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/GetEndpoint.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Endpoints/Api/GetEndpoint.cs
@@ -2,7 +2,9 @@
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Routing;
+using Microsoft.Extensions.Options;
using OrchardCore.ContentManagement;
+using OrchardCore.Json;
using OrchardCore.Modules;
namespace OrchardCore.Contents.Endpoints.Api;
@@ -23,7 +25,8 @@ private static async Task HandleAsync(
string contentItemId,
IContentManager contentManager,
IAuthorizationService authorizationService,
- HttpContext httpContext)
+ HttpContext httpContext,
+ IOptions options)
{
if (!await authorizationService.AuthorizeAsync(httpContext.User, CommonPermissions.AccessContentApi))
{
@@ -42,6 +45,6 @@ private static async Task HandleAsync(
return httpContext.ChallengeOrForbid("Api");
}
- return TypedResults.Ok(contentItem);
+ return Results.Json(contentItem, options.Value.SerializerOptions);
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/BuildDisplayFilter.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/BuildDisplayFilter.cs
index 047dffea335..675c0834d44 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/BuildDisplayFilter.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/BuildDisplayFilter.cs
@@ -50,7 +50,7 @@ static async ValueTask Awaited(Task task, TemplateOptions op
// a 'ContentItem' is still created but with some null properties.
if (contentItem?.ContentItemId == null)
{
- return new ValueTask(NilValue.Instance);
+ return ValueTask.FromResult(NilValue.Instance);
}
// When {{ Model.ContentItem | shape_build_display | shape_render }} is called prevent unlimited recursions.
@@ -59,7 +59,7 @@ static async ValueTask Awaited(Task task, TemplateOptions op
var recursionLimit = maxRecursions.Type == FluidValues.Number ? Convert.ToInt32(maxRecursions.ToNumberValue()) : DefaultMaxContentItemRecursions;
if (_buildDisplayRecursionHelper.IsRecursive(contentItem, recursionLimit))
{
- return new ValueTask(NilValue.Instance);
+ return ValueTask.FromResult(NilValue.Instance);
}
var displayType = arguments["type"].Or(arguments.At(0)).ToStringValue();
@@ -67,7 +67,7 @@ static async ValueTask Awaited(Task task, TemplateOptions op
var task = _contentItemDisplayManager.BuildDisplayAsync(contentItem, _updateModelAccessor.ModelUpdater, displayType);
if (task.IsCompletedSuccessfully)
{
- return new ValueTask(FluidValue.Create(task.Result, ctx.Options));
+ return ValueTask.FromResult(FluidValue.Create(task.Result, ctx.Options));
}
return Awaited(task, ctx.Options);
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/DisplayTextFilter.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/DisplayTextFilter.cs
index 2b5bccc2542..4073c056268 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/DisplayTextFilter.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Liquid/DisplayTextFilter.cs
@@ -12,9 +12,9 @@ public static ValueTask DisplayText(FluidValue input, FilterArgument
if (contentItem == null)
{
- return new ValueTask(NilValue.Instance);
+ return ValueTask.FromResult(NilValue.Instance);
}
- return new ValueTask(new StringValue(contentItem.DisplayText ?? ""));
+ return ValueTask.FromResult(new StringValue(contentItem.DisplayText ?? string.Empty));
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Recipes/ContentStep.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Recipes/ContentStep.cs
index cc0d9ecb291..6a562959970 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Recipes/ContentStep.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Recipes/ContentStep.cs
@@ -10,15 +10,15 @@ namespace OrchardCore.Contents.Recipes;
///
/// This recipe step creates a set of content items.
///
-public sealed class ContentStep : IRecipeStepHandler
+public sealed class ContentStep : NamedRecipeStepHandler
{
- public Task ExecuteAsync(RecipeExecutionContext context)
+ public ContentStep()
+ : base("Content")
{
- if (!string.Equals(context.Name, "Content", StringComparison.OrdinalIgnoreCase))
- {
- return Task.CompletedTask;
- }
+ }
+ protected override Task HandleAsync(RecipeExecutionContext context)
+ {
var model = context.Step.ToObject();
var contentItems = model.Data.ToObject();
@@ -26,6 +26,7 @@ public Task ExecuteAsync(RecipeExecutionContext context)
if (ShellScope.Context.IsActivated)
{
var contentManager = ShellScope.Services.GetRequiredService();
+
return contentManager.ImportAsync(contentItems);
}
@@ -34,6 +35,7 @@ public Task ExecuteAsync(RecipeExecutionContext context)
ShellScope.AddDeferredTask(scope =>
{
var contentManager = scope.ServiceProvider.GetRequiredService();
+
return contentManager.ImportAsync(contentItems);
});
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListFilterProvider.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListFilterProvider.cs
index 40eaad9b702..6df9cfe1956 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListFilterProvider.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListFilterProvider.cs
@@ -51,7 +51,7 @@ public void Build(QueryEngineBuilder builder)
query.With(x => x.Latest);
}
- return new ValueTask>(query);
+ return ValueTask.FromResult>(query);
})
.MapTo((val, model) =>
{
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListQueryService.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListQueryService.cs
index b7ee9f20919..fa73bd927be 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListQueryService.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Services/DefaultContentsAdminListQueryService.cs
@@ -11,7 +11,7 @@ namespace OrchardCore.Contents.Services;
public class DefaultContentsAdminListQueryService : IContentsAdminListQueryService
{
- private readonly static string[] _operators = ["OR", "AND", "||", "&&"];
+ private static readonly string[] _operators = ["OR", "AND", "||", "&&"];
private readonly ISession _session;
private readonly IServiceProvider _serviceProvider;
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceBuilder.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceBuilder.cs
index 0cee33f36ea..406d4e1c816 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceBuilder.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceBuilder.cs
@@ -10,6 +10,8 @@ namespace OrchardCore.Contents.Sitemaps;
public class ContentTypesSitemapSourceBuilder : SitemapSourceBuilderBase
{
+ private const int _batchSize = 500;
+
private static readonly XNamespace _namespace = "http://www.sitemaps.org/schemas/sitemap/0.9";
private readonly IRouteableContentTypeCoordinator _routeableContentTypeCoordinator;
@@ -21,8 +23,7 @@ public ContentTypesSitemapSourceBuilder(
IRouteableContentTypeCoordinator routeableContentTypeCoordinator,
IContentManager contentManager,
IContentItemsQueryProvider contentItemsQueryProvider,
- IEnumerable sitemapContentItemExtendedMetadataProviders
- )
+ IEnumerable sitemapContentItemExtendedMetadataProviders)
{
_routeableContentTypeCoordinator = routeableContentTypeCoordinator;
_contentManager = contentManager;
@@ -32,22 +33,66 @@ IEnumerable sitemapContentItemExten
public override async Task BuildSourceAsync(ContentTypesSitemapSource source, SitemapBuilderContext context)
{
- var queryContext = new ContentItemsQueryContext();
- await _contentItemsQueryProvider.GetContentItemsAsync(source, queryContext);
-
foreach (var sciemp in _sitemapContentItemExtendedMetadataProviders)
{
context.Response.ResponseElement.Add(sciemp.GetExtendedAttribute);
}
- foreach (var contentItem in queryContext.ContentItems)
+ var maxAllowed = int.MaxValue;
+ var skip = 0;
+
+ if (source.LimitedContentType != null)
{
- var url = new XElement(_namespace + "url");
+ skip = source.LimitedContentType.Skip;
+
+ if (source.LimitedContentType.Take > 0)
+ {
+ maxAllowed = source.LimitedContentType.Take;
+ }
+ }
+
+ var total = 0;
+ var take = _batchSize;
+ var isLastBatch = false;
+
+ while (true)
+ {
+ if ((total + take) > maxAllowed)
+ {
+ take = total + take - maxAllowed;
+
+ isLastBatch = true;
+ }
+
+ var queryContext = new ContentItemsQueryContext();
+
+ await _contentItemsQueryProvider.GetContentItemsAsync(source, queryContext, skip, take);
- if (await BuildUrlsetMetadataAsync(source, context, queryContext, contentItem, url))
+ if (queryContext.ContentItems == null || !queryContext.ContentItems.Any())
{
- context.Response.ResponseElement.Add(url);
+ break;
}
+
+ var totalFound = queryContext.ContentItems.Count();
+
+ total += totalFound;
+
+ foreach (var contentItem in queryContext.ContentItems)
+ {
+ var url = new XElement(_namespace + "url");
+
+ if (await BuildUrlsetMetadataAsync(source, context, queryContext, contentItem, url))
+ {
+ context.Response.ResponseElement.Add(url);
+ }
+ }
+
+ if (isLastBatch)
+ {
+ break;
+ }
+
+ skip += take;
}
}
@@ -58,7 +103,9 @@ private async Task BuildUrlsetMetadataAsync(ContentTypesSitemapSource sour
if (await BuildExtendedMetadataAsync(context, queryContext, contentItem, url))
{
PopulateLastMod(contentItem, url);
+
await PopulateChangeFrequencyPriority(source, contentItem, url);
+
return true;
}
@@ -71,6 +118,7 @@ private async Task BuildUrlsetMetadataAsync(ContentTypesSitemapSource sour
private async Task BuildExtendedMetadataAsync(SitemapBuilderContext context, ContentItemsQueryContext queryContext, ContentItem contentItem, XElement url)
{
var succeeded = true;
+
foreach (var sc in _sitemapContentItemExtendedMetadataProviders)
{
if (!await sc.ApplyExtendedMetadataAsync(context, queryContext, contentItem, url))
@@ -78,6 +126,7 @@ private async Task BuildExtendedMetadataAsync(SitemapBuilderContext contex
succeeded = false;
}
}
+
return succeeded;
}
@@ -94,6 +143,7 @@ private async Task BuildUrlAsync(SitemapBuilderContext context, ContentIte
var loc = new XElement(_namespace + "loc");
loc.Add(locValue);
url.Add(loc);
+
return true;
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceDriver.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceDriver.cs
index 8e435eb5fc0..88de84d0ec4 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceDriver.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/ContentTypesSitemapSourceDriver.cs
@@ -67,7 +67,7 @@ public override async Task EditAsync(ContentTypesSitemapSource s
model.ChangeFrequency = sitemapSource.ChangeFrequency;
model.ContentTypes = entries;
model.LimitedContentTypes = limitedEntries;
- model.LimitedContentType = limitedCtd != null ? limitedCtd.Name : contentTypeDefinitions.FirstOrDefault().Name;
+ model.LimitedContentType = limitedCtd is null ? contentTypeDefinitions.FirstOrDefault()?.Name : limitedCtd.Name;
model.SitemapSource = sitemapSource;
}).Location("Content");
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/DefaultContentItemsQueryProvider.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/DefaultContentItemsQueryProvider.cs
index 9cf583441d3..be23e40f8f0 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/DefaultContentItemsQueryProvider.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Sitemaps/DefaultContentItemsQueryProvider.cs
@@ -10,32 +10,33 @@ namespace OrchardCore.Contents.Sitemaps;
public class DefaultContentItemsQueryProvider : IContentItemsQueryProvider
{
- private readonly ISession _session;
+ private readonly IStore _store;
private readonly IRouteableContentTypeCoordinator _routeableContentTypeCoordinator;
public DefaultContentItemsQueryProvider(
- ISession session,
- IRouteableContentTypeCoordinator routeableContentTypeCoordinator
- )
+ IStore store,
+ IRouteableContentTypeCoordinator routeableContentTypeCoordinator)
{
- _session = session;
+ _store = store;
_routeableContentTypeCoordinator = routeableContentTypeCoordinator;
}
- public async Task GetContentItemsAsync(ContentTypesSitemapSource source, ContentItemsQueryContext context)
+ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, ContentItemsQueryContext context, int? skip = null, int? take = null)
{
+ ArgumentNullException.ThrowIfNull(source);
+ ArgumentNullException.ThrowIfNull(context);
+
var routeableContentTypeDefinitions = await _routeableContentTypeCoordinator.ListRoutableTypeDefinitionsAsync();
+ using var session = _store.CreateSession(withTracking: false);
+
+ var query = session.Query();
+
if (source.IndexAll)
{
var rctdNames = routeableContentTypeDefinitions.Select(rctd => rctd.Name);
- var queryResults = await _session.Query()
- .With(x => x.Published && x.ContentType.IsIn(rctdNames))
- .OrderBy(x => x.CreatedUtc)
- .ListAsync();
-
- context.ContentItems = queryResults;
+ query = query.Where(x => x.Published && x.ContentType.IsIn(rctdNames));
}
else if (source.LimitItems)
{
@@ -43,17 +44,12 @@ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, Content
var typeIsValid = routeableContentTypeDefinitions
.Any(ctd => string.Equals(source.LimitedContentType.ContentTypeName, ctd.Name, StringComparison.Ordinal));
- if (typeIsValid)
+ if (!typeIsValid)
{
- var queryResults = await _session.Query()
- .With(x => x.ContentType == source.LimitedContentType.ContentTypeName && x.Published)
- .OrderBy(x => x.CreatedUtc)
- .Skip(source.LimitedContentType.Skip)
- .Take(source.LimitedContentType.Take)
- .ListAsync();
-
- context.ContentItems = queryResults;
+ return;
}
+
+ query = query.Where(x => x.ContentType == source.LimitedContentType.ContentTypeName && x.Published);
}
else
{
@@ -62,12 +58,14 @@ public async Task GetContentItemsAsync(ContentTypesSitemapSource source, Content
.Where(ctd => source.ContentTypes.Any(s => string.Equals(ctd.Name, s.ContentTypeName, StringComparison.Ordinal)))
.Select(x => x.Name);
- var queryResults = await _session.Query()
- .With(x => x.ContentType.IsIn(typesToIndex) && x.Published)
- .OrderBy(x => x.CreatedUtc)
- .ListAsync();
-
- context.ContentItems = queryResults;
+ query = query.Where(x => x.ContentType.IsIn(typesToIndex) && x.Published);
}
+
+ context.ContentItems = await query
+ .OrderBy(x => x.CreatedUtc)
+ .ThenBy(x => x.Id)
+ .Take(take ?? 0)
+ .Skip(skip ?? 0)
+ .ListAsync();
}
}
diff --git a/src/OrchardCore.Modules/OrchardCore.Contents/Startup.cs b/src/OrchardCore.Modules/OrchardCore.Contents/Startup.cs
index 2621bd74210..c16e7fb6092 100644
--- a/src/OrchardCore.Modules/OrchardCore.Contents/Startup.cs
+++ b/src/OrchardCore.Modules/OrchardCore.Contents/Startup.cs
@@ -14,6 +14,7 @@
using OrchardCore.Contents.AdminNodes;
using OrchardCore.Contents.AuditTrail.Settings;
using OrchardCore.Contents.Controllers;
+using OrchardCore.Contents.Core;
using OrchardCore.Contents.Deployment;
using OrchardCore.Contents.Drivers;
using OrchardCore.Contents.Endpoints.Api;
@@ -32,7 +33,7 @@
using OrchardCore.ContentTypes.Editors;
using OrchardCore.Data.Migration;
using OrchardCore.Deployment;
-using OrchardCore.DisplayManagement.Descriptors;
+using OrchardCore.DisplayManagement;
using OrchardCore.DisplayManagement.Handlers;
using OrchardCore.DisplayManagement.Liquid;
using OrchardCore.DisplayManagement.Liquid.Tags;
@@ -59,6 +60,7 @@ public sealed class Startup : StartupBase
{
public override void ConfigureServices(IServiceCollection services)
{
+ services.AddContentServices();
services.AddSingleton();
services.Configure