diff --git a/Lombiq.VueJs.Samples/Lombiq.VueJs.Samples.csproj b/Lombiq.VueJs.Samples/Lombiq.VueJs.Samples.csproj index 5a1ac563..f3fc67dc 100644 --- a/Lombiq.VueJs.Samples/Lombiq.VueJs.Samples.csproj +++ b/Lombiq.VueJs.Samples/Lombiq.VueJs.Samples.csproj @@ -4,7 +4,7 @@ - net6.0 + net8.0 true $(DefaultItemExcludes);.git*;node_modules\** @@ -34,10 +34,10 @@ - - - - + + + + @@ -50,8 +50,8 @@ - - + + diff --git a/Lombiq.VueJs.Samples/Manifest.cs b/Lombiq.VueJs.Samples/Manifest.cs index 318659cc..b8f4102e 100644 --- a/Lombiq.VueJs.Samples/Manifest.cs +++ b/Lombiq.VueJs.Samples/Manifest.cs @@ -7,9 +7,9 @@ Version = "0.0.1", Description = "Samples for Lombiq Vue.js.", Category = "Vue.js", - Dependencies = new[] - { + Dependencies = + [ Lombiq.VueJs.Constants.FeatureIds.Area, "OrchardCore.ContentFields", - } + ] )] diff --git a/Lombiq.VueJs.Samples/Migrations/BusinessCardMigrations.cs b/Lombiq.VueJs.Samples/Migrations/BusinessCardMigrations.cs index 69406797..b65d84c2 100644 --- a/Lombiq.VueJs.Samples/Migrations/BusinessCardMigrations.cs +++ b/Lombiq.VueJs.Samples/Migrations/BusinessCardMigrations.cs @@ -3,6 +3,7 @@ using OrchardCore.ContentManagement.Metadata; using OrchardCore.ContentManagement.Metadata.Settings; using OrchardCore.Data.Migration; +using System.Threading.Tasks; namespace Lombiq.VueJs.Samples.Migrations; @@ -13,9 +14,9 @@ public class BusinessCardMigrations : DataMigration public BusinessCardMigrations(IContentDefinitionManager contentDefinitionManager) => _contentDefinitionManager = contentDefinitionManager; - public int Create() + public async Task CreateAsync() { - var businessCardPart = _contentDefinitionManager.AlterPartDefinition(partBuilder => partBuilder + var businessCardPart = await _contentDefinitionManager.AlterPartDefinitionAsync(partBuilder => partBuilder .WithField(model => model.FirstName, field => field .WithDisplayName("First name") .WithSettings(new TextFieldSettings { Required = true })) @@ -27,7 +28,7 @@ public int Create() .WithField(model => model.Phone, field => field .WithSettings(new TextFieldSettings { Required = true }))); - _contentDefinitionManager.AlterTypeDefinition(nameof(BusinessCard), typeBuilder => typeBuilder + await _contentDefinitionManager.AlterTypeDefinitionAsync(nameof(BusinessCard), typeBuilder => typeBuilder .DisplayedAs("Business card") .Creatable() .Listable() diff --git a/Lombiq.VueJs.Tests.UI/Assets/Media/DirectoryPlaceholder.cs b/Lombiq.VueJs.Tests.UI/Assets/Media/DirectoryPlaceholder.cs index 35c57e1e..5e3f5bd1 100644 --- a/Lombiq.VueJs.Tests.UI/Assets/Media/DirectoryPlaceholder.cs +++ b/Lombiq.VueJs.Tests.UI/Assets/Media/DirectoryPlaceholder.cs @@ -1,8 +1,6 @@ namespace Lombiq.VueJs.Tests.UI.Assets.Media; // This is a dummy class to easier access the requested resource. -#pragma warning disable S2094 // Classes should not be empty internal sealed class DirectoryPlaceholder -#pragma warning restore S2094 // Classes should not be empty { } diff --git a/Lombiq.VueJs.Tests.UI/Lombiq.VueJs.Tests.UI.csproj b/Lombiq.VueJs.Tests.UI/Lombiq.VueJs.Tests.UI.csproj index 12217996..de04eca4 100644 --- a/Lombiq.VueJs.Tests.UI/Lombiq.VueJs.Tests.UI.csproj +++ b/Lombiq.VueJs.Tests.UI/Lombiq.VueJs.Tests.UI.csproj @@ -1,7 +1,7 @@ - net6.0 + net8.0 @@ -25,7 +25,7 @@ - + diff --git a/Lombiq.VueJs/Assets/Scripts/helpers/process-helpers.js b/Lombiq.VueJs/Assets/Scripts/helpers/process-helpers.js index b4b4ba72..d936b541 100644 --- a/Lombiq.VueJs/Assets/Scripts/helpers/process-helpers.js +++ b/Lombiq.VueJs/Assets/Scripts/helpers/process-helpers.js @@ -1,6 +1,6 @@ const fs = require('fs'); -const getProjectDirectory = require('.nx/scripts/get-project-directory'); const { handleErrorObject, handleErrorMessage, handleWarningMessage } = require('.nx/scripts/handle-error'); +const getProjectDirectory = require('.nx/scripts/get-project-directory'); async function executeFunctionByCommandLineArgument(functions) { const [functionName, argumentOptionsJson] = process.argv.slice(2); diff --git a/Lombiq.VueJs/Lombiq.VueJs.csproj b/Lombiq.VueJs/Lombiq.VueJs.csproj index 1073b304..df9dff1f 100644 --- a/Lombiq.VueJs/Lombiq.VueJs.csproj +++ b/Lombiq.VueJs/Lombiq.VueJs.csproj @@ -3,7 +3,7 @@ - net6.0 + net8.0 true $(DefaultItemExcludes);.git*;node_modules\** @@ -46,9 +46,9 @@ - - - + + + @@ -57,8 +57,8 @@ - - + + diff --git a/Lombiq.VueJs/TagHelpers/VueComponentTagHelper.cs b/Lombiq.VueJs/TagHelpers/VueComponentTagHelper.cs index 939e9a23..c9bf2da0 100644 --- a/Lombiq.VueJs/TagHelpers/VueComponentTagHelper.cs +++ b/Lombiq.VueJs/TagHelpers/VueComponentTagHelper.cs @@ -62,7 +62,7 @@ await _displayHelper.ShapeExecuteAsync( output.TagName = null; } - private IEnumerable FindResourceNames() + private HashSet FindResourceNames() { var resourceNames = (Children?.Split(',') ?? Enumerable.Empty()) .SelectWhere(child => child.Trim(), child => !string.IsNullOrEmpty(child)) @@ -90,7 +90,7 @@ private static void AddShapesRecursively( .Where(dependency => !resourceNames.Contains(dependency)) .ToHashSet(); - if (!newDependencies.Any()) return; + if (newDependencies.Count == 0) return; resourceNames.AddRange(newDependencies); AddShapesRecursively(resourceNames, newDependencies, componentDependencies); diff --git a/Lombiq.VueJs/Views/_ViewImports.cshtml b/Lombiq.VueJs/Views/_ViewImports.cshtml index dc2cd41d..d4f14776 100644 --- a/Lombiq.VueJs/Views/_ViewImports.cshtml +++ b/Lombiq.VueJs/Views/_ViewImports.cshtml @@ -1,4 +1,4 @@ -@inherits OrchardCore.DisplayManagement.Razor.RazorPage +@inherits OrchardCore.DisplayManagement.Razor.RazorPage @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers @addTagHelper *, OrchardCore.Contents.TagHelpers