From: Alexander Ebert Date: Fri, 12 Aug 2016 13:45:50 +0000 (+0200) Subject: Using alternate approach to deal with mentions X-Git-Tag: 3.0.0_Beta_1~764 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8fdca4dc05a4bfde83d45bf2f6f1064d447f729e;p=GitHub%2FWoltLab%2FWCF.git Using alternate approach to deal with mentions Using a custom element has too many drawbacks and issues, all though being far more elegant, it is just not worth it. --- diff --git a/com.woltlab.wcf/bbcode.xml b/com.woltlab.wcf/bbcode.xml index 994191ce16..405afd3774 100644 --- a/com.woltlab.wcf/bbcode.xml +++ b/com.woltlab.wcf/bbcode.xml @@ -227,5 +227,15 @@ + + + wcf\system\bbcode\UserBBCode + + + ^\d+$ + 1 + + + diff --git a/com.woltlab.wcf/objectType.xml b/com.woltlab.wcf/objectType.xml index 7e8e7d8253..238c692a73 100644 --- a/com.woltlab.wcf/objectType.xml +++ b/com.woltlab.wcf/objectType.xml @@ -770,6 +770,11 @@ com.woltlab.wcf.message.embeddedObject wcf\system\message\embedded\object\MediaMessageEmbeddedObjectHandler + + com.woltlab.wcf.user + com.woltlab.wcf.message.embeddedObject + wcf\system\message\embedded\object\UserMessageEmbeddedObjectHandler + diff --git a/com.woltlab.wcf/templates/htmlNodeWoltlabMention.tpl b/com.woltlab.wcf/templates/htmlNodeWoltlabMention.tpl deleted file mode 100644 index ac2b3d7e47..0000000000 --- a/com.woltlab.wcf/templates/htmlNodeWoltlabMention.tpl +++ /dev/null @@ -1,7 +0,0 @@ -{if $userProfile === null} - {* user no longer exists, use plain output rather than using a broken link *} - @{$username} -{else} - {* non-breaking space below to prevent wrapping of user avatar and username *} - {@$userProfile->getAvatar()->getImageTag(16)} {$userProfile->username} -{/if} \ No newline at end of file diff --git a/com.woltlab.wcf/templates/userBBCodeTag.tpl b/com.woltlab.wcf/templates/userBBCodeTag.tpl new file mode 100644 index 0000000000..540243b6c1 --- /dev/null +++ b/com.woltlab.wcf/templates/userBBCodeTag.tpl @@ -0,0 +1,7 @@ +{if $userProfile === null} + {* user no longer exists, use plain output rather than using a broken link *} + @{$username} +{else} + {* non-breaking space below to prevent wrapping of user avatar and username *} + {@$userProfile->getAvatar()->getImageTag(16)} {$userProfile->username} +{/if} diff --git a/com.woltlab.wcf/templates/wysiwyg.tpl b/com.woltlab.wcf/templates/wysiwyg.tpl index ac556360d4..00ed92391c 100644 --- a/com.woltlab.wcf/templates/wysiwyg.tpl +++ b/com.woltlab.wcf/templates/wysiwyg.tpl @@ -1,25 +1,3 @@ - -