كيف يمكنني تغيير شكل الإحالة من @usernamefieldhere إلى @fullnamefieldhere ؟
على سبيل المثال، بدلاً من @OverseersMight سيظهر كـ @ John Doe. (إذا كان اسمي جون دو)
آسف على الإحالة، جون، لم أقصد الإشارة إليك…
Don
22 أغسطس 2021، 4:45ص
2
مرحبًا،
حاليًا لا يوجد هذا النوع من الخيارات في Discourse، لكن ربما يكون هذا الموضوع مفيدًا
It would look more elegent in posts if @leo (for example) was presented as (or at least the user had the option to present it as) “Leo” or “Leo McArdle”.
pfaffman
(Jay Pfaffman)
22 أغسطس 2021، 1:17م
3
أعتقد أنه إذا كنت لا تريد أن يستخدم الناس أسماء مستخدمين، فيجب عليك الحصول على إضافة تجعل اسم المستخدم مطابقًا لـ first_last.
هل لديك أي روابط لهذه الإضافة @pfaffman ؟ لقد وجدت هذا أيضًا،
@nachof I found a way to make it work: https://gist.github.com/jessicah/cd580bab64d89875a157579789b03511 by overriding _show() in component:user-card-contents. I’m guessing the leading underscore means we probably shouldn’t override it? But it seems to work: [image]
Perhaps there needs to be an entry point to optionally get the username from $target? Anyway, this was really a blocker from my POV to deploying to my wider community. Time to roll ahead
ويبدو أنه يعمل أيضًا.
شكرًا لك على كونك مساهمًا رائعًا في هذه المجتمع.
pfaffman
(Jay Pfaffman)
22 أغسطس 2021، 9:07م
5
واو! يبدو رائعًا. هذا حل أفضل من حلي لأنه لا يتطلب إضافة غير موجودة. لستُ ماهرًا جدًا في ابتكار حلول تتضمن Ember/JavaScript. عمل رائع!