Merge remote-tracking branch 'origin/v12/dev' into v13/dev

# Conflicts:
#	src/Umbraco.Cms.Api.Management/ManagementApiComposer.cs
#	src/Umbraco.Core/CompatibilitySuppressions.xml
#	src/Umbraco.Infrastructure/CompatibilitySuppressions.xml
This commit is contained in:
Bjarke Berg
2023-04-19 11:23:50 +02:00
182 changed files with 6893 additions and 57 deletions

View File

@@ -0,0 +1,19 @@
using Umbraco.Cms.Core.PropertyEditors.ValueConverters;
namespace Umbraco.Cms.Core.Models.DeliveryApi;
public class ApiImageCropperValue
{
public ApiImageCropperValue(string url, ImageCropperValue.ImageCropperFocalPoint? focalPoint, IEnumerable<ImageCropperValue.ImageCropperCrop>? crops)
{
Url = url;
FocalPoint = focalPoint;
Crops = crops;
}
public string Url { get; }
public ImageCropperValue.ImageCropperFocalPoint? FocalPoint { get; }
public IEnumerable<ImageCropperValue.ImageCropperCrop>? Crops { get; }
}

View File

@@ -0,0 +1,32 @@
using Umbraco.Cms.Core.PropertyEditors.ValueConverters;
namespace Umbraco.Cms.Core.Models.DeliveryApi;
public class ApiMediaWithCrops : IApiMedia
{
private readonly IApiMedia _inner;
public ApiMediaWithCrops(
IApiMedia inner,
ImageCropperValue.ImageCropperFocalPoint? focalPoint,
IEnumerable<ImageCropperValue.ImageCropperCrop>? crops)
{
_inner = inner;
FocalPoint = focalPoint;
Crops = crops;
}
public Guid Id => _inner.Id;
public string Name => _inner.Name;
public string MediaType => _inner.MediaType;
public string Url => _inner.Url;
public IDictionary<string, object?> Properties => _inner.Properties;
public ImageCropperValue.ImageCropperFocalPoint? FocalPoint { get; }
public IEnumerable<ImageCropperValue.ImageCropperCrop>? Crops { get; }
}

View File

@@ -0,0 +1,20 @@
namespace Umbraco.Cms.Infrastructure.Models.DeliveryApi;
public class RichTextElement
{
public RichTextElement(string tag, string text, Dictionary<string, object> attributes, IEnumerable<RichTextElement> elements)
{
Tag = tag;
Text = text;
Attributes = attributes;
Elements = elements;
}
public string Tag { get; }
public string Text { get; }
public Dictionary<string, object> Attributes { get; }
public IEnumerable<RichTextElement> Elements { get; }
}