From 0121e3fde3fe8420d2fb946d8e2bd904c47d7678 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20Lyngs=C3=B8?= Date: Wed, 17 Jun 2020 11:53:55 +0200 Subject: [PATCH] Unsupported block --- .../blockeditormodelobject.service.js | 2 +- .../unsupportedblock.editor.html | 17 +++-- .../unsupportedblock.editor.less | 65 ++++++++++++------- 3 files changed, 57 insertions(+), 27 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/common/services/blockeditormodelobject.service.js b/src/Umbraco.Web.UI.Client/src/common/services/blockeditormodelobject.service.js index 955e026da5..889dd40fab 100644 --- a/src/Umbraco.Web.UI.Client/src/common/services/blockeditormodelobject.service.js +++ b/src/Umbraco.Web.UI.Client/src/common/services/blockeditormodelobject.service.js @@ -564,7 +564,7 @@ if (blockConfiguration === null || contentScaffold === null) { blockConfiguration = { - label: "Unsupported Block ("+udi+")", + label: "Unsupported Block", unsupported: true }; contentScaffold = {}; diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.html b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.html index bdd7341528..61488ac859 100644 --- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.html +++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.html @@ -1,4 +1,13 @@ - +
+
+ + {{block.label}} +
+
+ This Block is no longer supported in this context.
+ You might want to remove this block, or contact your developer to take actions for making this block available again.

+ Learn about this circumstance on Our +
Block data:
+

+    
+
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.less b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.less index 214a8399fd..672a6d3ff4 100644 --- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.less +++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/blocklistentryeditors/unsupportedblock/unsupportedblock.editor.less @@ -5,32 +5,53 @@ margin-bottom: 4px; margin-top: 4px; width: 100%; - min-height: 48px; border: 1px solid @gray-9; border-radius: @baseBorderRadius; - cursor: pointer; - color: @ui-action-discreet-type; + > .__header { - text-align: left; - padding-left: 20px; - padding-bottom: 2px; - - user-select: none; - - transition: border-color 120ms; - - background-color: @ui-btn-negative; - color: @ui-btn-negative-type; - - i { - font-size: 22px; - margin-right: 5px; - display: inline-block; - vertical-align: middle; + display: flex; + align-items: center; + + padding-left: 20px; + padding-bottom: 2px; + min-height: 48px; + border-bottom: 1px solid @gray-9; + + background-color: @ui-btn-negative; + color: @ui-btn-negative-type; + + i { + font-size: 22px; + margin-right: 5px; + display: inline-block; + vertical-align: middle; + } + span { + display: inline-block; + vertical-align: middle; + } } - span { - display: inline-block; - vertical-align: middle; + + > .__body { + + padding: 20px; + + background-color: @red-washed; + + a { + text-decoration: underline; + color: @ui-action-type; + &:hover { + color:@ui-action-type-hover; + } + } + + pre { + border: none; + padding: 0; + background-color: transparent; + } + } }