Merge remote-tracking branch 'origin/netcore/dev' into netcore/netcore

# Conflicts:
#	build/NuSpecs/UmbracoCms.Web.nuspec
#	src/SolutionInfo.cs
#	src/Umbraco.Infrastructure/Logging/Serilog/LoggerConfigExtensions.cs
#	src/Umbraco.Infrastructure/PropertyEditors/NestedContentPropertyEditor.cs
#	src/Umbraco.Tests.AcceptanceTest/cypress/integration/Tour/backofficeTour.ts
#	src/Umbraco.Tests.AcceptanceTest/package.json
#	src/Umbraco.Tests/TestHelpers/TestObjects.cs
#	src/Umbraco.Web.BackOffice/Controllers/ContentTypeController.cs
#	src/Umbraco.Web.BackOffice/Controllers/ImageUrlGeneratorController.cs
#	src/Umbraco.Web.BackOffice/Controllers/ImagesController.cs
#	src/Umbraco.Web.BackOffice/Controllers/MediaController.cs
#	src/Umbraco.Web.BackOffice/Controllers/MemberTypeController.cs
#	src/Umbraco.Web.BackOffice/Controllers/RelationTypeController.cs
#	src/Umbraco.Web.BackOffice/Controllers/TemplateController.cs
#	src/Umbraco.Web.UI.Client/src/common/services/formhelper.service.js
#	src/Umbraco.Web.UI.Client/src/installer/steps/database.html
#	src/Umbraco.Web.UI.Client/src/less/components/tree/umb-tree.less
#	src/Umbraco.Web.UI.Client/src/less/components/umb-property-actions.less
#	src/Umbraco.Web.UI.Client/src/less/forms.less
#	src/Umbraco.Web.UI.Client/src/views/common/infiniteeditors/querybuilder/querybuilder.html
#	src/Umbraco.Web.UI.Client/src/views/common/infiniteeditors/treepicker/treepicker.html
#	src/Umbraco.Web.UI.Client/src/views/components/application/umb-navigation.html
#	src/Umbraco.Web.UI.Client/src/views/components/property/umb-property-actions.html
#	src/Umbraco.Web.UI.Client/src/views/content/overlays/publish.controller.js
#	src/Umbraco.Web.UI.Client/src/views/content/overlays/publishdescendants.html
#	src/Umbraco.Web.UI.Client/src/views/dictionary/edit.html
#	src/Umbraco.Web.UI.Client/src/views/dictionary/list.html
#	src/Umbraco.Web.UI.Client/src/views/logViewer/search.html
#	src/Umbraco.Web.UI.Client/src/views/media/media.edit.controller.js
#	src/Umbraco.Web.UI.Client/src/views/mediaTypes/edit.controller.js
#	src/Umbraco.Web.UI.Client/src/views/member/member.edit.controller.js
#	src/Umbraco.Web.UI.Client/src/views/memberTypes/edit.controller.js
#	src/Umbraco.Web.UI.Client/src/views/packages/views/repo.html
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/dialogs/layoutconfig.html
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/dialogs/rowconfig.html
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/layouts.prevalues.html
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/layouts/list/list.listviewlayout.controller.js
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/nestedcontent/nestedcontent.controller.js
#	src/Umbraco.Web.UI.Client/src/views/propertyeditors/userpicker/userpicker.controller.js
#	src/Umbraco.Web.UI.NetCore/umbraco/UmbracoBackOffice/Default.cshtml
#	src/Umbraco.Web.UI.NetCore/umbraco/config/lang/da.xml
#	src/Umbraco.Web.UI.NetCore/umbraco/config/lang/en.xml
#	src/Umbraco.Web.UI.NetCore/umbraco/config/lang/en_us.xml
#	src/Umbraco.Web.UI/Umbraco/config/lang/cs.xml
#	src/Umbraco.Web.UI/Views/Partials/Grid/Editors/Media.cshtml
#	src/Umbraco.Web.UI/config/umbracoSettings.config
#	src/Umbraco.Web/Editors/BackOfficeServerVariables.cs
#	src/Umbraco.Web/Editors/DictionaryController.cs
#	src/Umbraco.Web/Editors/LogController.cs
#	src/Umbraco.Web/Editors/MediaTypeController.cs
#	src/Umbraco.Web/Editors/MemberGroupController.cs
This commit is contained in:
Bjarke Berg
2020-09-09 19:13:37 +02:00
200 changed files with 5507 additions and 3661 deletions

View File

@@ -5,41 +5,126 @@ using Umbraco.Core.Models.PublishedContent;
namespace Umbraco.Core.Models.Blocks
{
/// <summary>
/// Represents a layout item for the Block List editor
/// Represents a layout item for the Block List editor.
/// </summary>
/// <seealso cref="Umbraco.Core.Models.Blocks.IBlockReference{Umbraco.Core.Models.PublishedContent.IPublishedElement}" />
[DataContract(Name = "block", Namespace = "")]
public class BlockListItem : IBlockReference<IPublishedElement>
{
/// <summary>
/// Initializes a new instance of the <see cref="BlockListItem" /> class.
/// </summary>
/// <param name="contentUdi">The content UDI.</param>
/// <param name="content">The content.</param>
/// <param name="settingsUdi">The settings UDI.</param>
/// <param name="settings">The settings.</param>
/// <exception cref="System.ArgumentNullException">contentUdi
/// or
/// content</exception>
public BlockListItem(Udi contentUdi, IPublishedElement content, Udi settingsUdi, IPublishedElement settings)
{
ContentUdi = contentUdi ?? throw new ArgumentNullException(nameof(contentUdi));
ContentUdi = contentUdi ?? throw new ArgumentNullException(nameof(contentUdi));
Content = content ?? throw new ArgumentNullException(nameof(content));
Settings = settings; // can be null
SettingsUdi = settingsUdi; // can be null
SettingsUdi = settingsUdi;
Settings = settings;
}
/// <summary>
/// The Id of the content data item
/// Gets the content UDI.
/// </summary>
/// <value>
/// The content UDI.
/// </value>
[DataMember(Name = "contentUdi")]
public Udi ContentUdi { get; }
/// <summary>
/// The Id of the settings data item
/// </summary>
[DataMember(Name = "settingsUdi")]
public Udi SettingsUdi { get; }
/// <summary>
/// The content data item referenced
/// Gets the content.
/// </summary>
/// <value>
/// The content.
/// </value>
[DataMember(Name = "content")]
public IPublishedElement Content { get; }
/// <summary>
/// The settings data item referenced
/// Gets the settings UDI.
/// </summary>
/// <value>
/// The settings UDI.
/// </value>
[DataMember(Name = "settingsUdi")]
public Udi SettingsUdi { get; }
/// <summary>
/// Gets the settings.
/// </summary>
/// <value>
/// The settings.
/// </value>
[DataMember(Name = "settings")]
public IPublishedElement Settings { get; }
}
/// <summary>
/// Represents a layout item with a generic content type for the Block List editor.
/// </summary>
/// <typeparam name="T">The type of the content.</typeparam>
/// <seealso cref="Umbraco.Core.Models.Blocks.IBlockReference{Umbraco.Core.Models.PublishedContent.IPublishedElement}" />
public class BlockListItem<T> : BlockListItem
where T : IPublishedElement
{
/// <summary>
/// Initializes a new instance of the <see cref="BlockListItem{T}" /> class.
/// </summary>
/// <param name="contentUdi">The content UDI.</param>
/// <param name="content">The content.</param>
/// <param name="settingsUdi">The settings UDI.</param>
/// <param name="settings">The settings.</param>
public BlockListItem(Udi contentUdi, T content, Udi settingsUdi, IPublishedElement settings)
: base(contentUdi, content, settingsUdi, settings)
{
Content = content;
}
/// <summary>
/// Gets the content.
/// </summary>
/// <value>
/// The content.
/// </value>
public new T Content { get; }
}
/// <summary>
/// Represents a layout item with generic content and settings types for the Block List editor.
/// </summary>
/// <typeparam name="TContent">The type of the content.</typeparam>
/// <typeparam name="TSettings">The type of the settings.</typeparam>
/// <seealso cref="Umbraco.Core.Models.Blocks.IBlockReference{Umbraco.Core.Models.PublishedContent.IPublishedElement}" />
public class BlockListItem<TContent, TSettings> : BlockListItem<TContent>
where TContent : IPublishedElement
where TSettings : IPublishedElement
{
/// <summary>
/// Initializes a new instance of the <see cref="BlockListItem{TContent, TSettings}" /> class.
/// </summary>
/// <param name="contentUdi">The content udi.</param>
/// <param name="content">The content.</param>
/// <param name="settingsUdi">The settings udi.</param>
/// <param name="settings">The settings.</param>
public BlockListItem(Udi contentUdi, TContent content, Udi settingsUdi, TSettings settings)
: base(contentUdi, content, settingsUdi, settings)
{
Settings = settings;
}
/// <summary>
/// Gets the settings.
/// </summary>
/// <value>
/// The settings.
/// </value>
public new TSettings Settings { get; }
}
}

View File

@@ -1,26 +1,37 @@
namespace Umbraco.Core.Models.Blocks
{
/// <summary>
/// Represents a data item reference for a Block editor implementation
/// </summary>
/// <typeparam name="TSettings"></typeparam>
/// <remarks>
/// see: https://github.com/umbraco/rfcs/blob/907f3758cf59a7b6781296a60d57d537b3b60b8c/cms/0011-block-data-structure.md#strongly-typed
/// </remarks>
public interface IBlockReference<TSettings> : IBlockReference
{
TSettings Settings { get; }
}
/// <summary>
/// Represents a data item reference for a Block Editor implementation
/// Represents a data item reference for a Block Editor implementation.
/// </summary>
/// <remarks>
/// see: https://github.com/umbraco/rfcs/blob/907f3758cf59a7b6781296a60d57d537b3b60b8c/cms/0011-block-data-structure.md#strongly-typed
/// See: https://github.com/umbraco/rfcs/blob/907f3758cf59a7b6781296a60d57d537b3b60b8c/cms/0011-block-data-structure.md#strongly-typed
/// </remarks>
public interface IBlockReference
{
/// <summary>
/// Gets the content UDI.
/// </summary>
/// <value>
/// The content UDI.
/// </value>
Udi ContentUdi { get; }
}
/// <summary>
/// Represents a data item reference with settings for a Block editor implementation.
/// </summary>
/// <typeparam name="TSettings">The type of the settings.</typeparam>
/// <remarks>
/// See: https://github.com/umbraco/rfcs/blob/907f3758cf59a7b6781296a60d57d537b3b60b8c/cms/0011-block-data-structure.md#strongly-typed
/// </remarks>
public interface IBlockReference<TSettings> : IBlockReference
{
/// <summary>
/// Gets the settings.
/// </summary>
/// <value>
/// The settings.
/// </value>
TSettings Settings { get; }
}
}

View File

@@ -7,6 +7,7 @@ using System.Runtime.Serialization;
namespace Umbraco.Core.Models
{
/// <summary>
/// Represents a collection of property values.
/// </summary>