Updates the HTML Razor Partial View for grid cell items that use Embed

It has been recently updated in 8.2.0 that the Value stored is a JSON object containing width, height & the raw HTML returned by the oEmbed

Fixes #7178
This commit is contained in:
Warren Buckley
2019-12-19 16:01:55 +00:00
parent 0b6f1f6e11
commit 1fc2c89ea6

View File

@@ -1,7 +1,14 @@
@model dynamic
@using Umbraco.Web.Templates
@{
var embedValue = string.Empty;
try {
embedValue = Model.value.preview;
} catch(Exception ex) {
embedValue = Model.value;
}
}
<div class="video-wrapper">
@Html.Raw(Model.value)
@Html.Raw(embedValue)
</div>