# مُنشئ النصوص باستخدام Markdown فقط: لا يمكن التأكيد على سطر من النص بكلمة عريضة في النهاية

**URL:** <https://meta.discourse.org/t/markdown-only-composer-cant-emphasize-line-of-text-with-a-bold-word-at-the-end/358800>\
**Category:** Bug\
**Tags:** composer\
**Created:** [25 مارس 2025، 5:49م UTC](https://meta.discourse.org/t/markdown-only-composer-cant-emphasize-line-of-text-with-a-bold-word-at-the-end/358800 "2025-03-25T17:49:33Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Lhc\_fl](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lhc_fl/32/268115_2.png) [@Lhc\_fl](https://meta.discourse.org/u/Lhc_fl)\
**Post date:** [12 أغسطس 2025، 3:15ص UTC](https://meta.discourse.org/t/markdown-only-composer-cant-emphasize-line-of-text-with-a-bold-word-at-the-end/358800/2 "2025-08-12T03:15:28Z")

</div>

لقد قمت بالتحقق ووجدت أن الخطأ يجب أن يكون في هذا السطر

> <https://github.com/discourse/discourse/blob/main/app/assets/javascripts/discourse/app/lib/textarea-text-manipulation.js#L289>

إنه لا يكتشف العلامات على كلا الجانبين، ولكنه يكتشف العلامة الموجودة على اليمين (الذيل) فقط. إذا ظهرت علامة على الجانب الأيمن من النص المحدد، فإنها تدخل في كتلة الحذف  
هذا يعني أن `something**` ستصبح `mething` بالضغط على `ctrl + b`  
لقد قمت بإنشاء طلب سحب لإصلاح ذلك

> <https://github.com/discourse/discourse/pull/34243>
>
> …d text
> 
> In the current Textarea Editor \`applySurround\`, only the right side i…s checked. That means if you write \`something\*\*\`, pressing \`Ctrl + B\` will unexpectedly turn it into \`mething\`, since the \`TextareaTextManipulation\` detected the double asterisk \`\*\*\` on the right and thought \`something\*\*\` was the bold syntax, so it removed it.
> 
> This commit fixes the bug here.
> 
> Related meta topic: https://meta.discourse.org/t/-/358800

---

_[View the full topic](https://meta.discourse.org/t/markdown-only-composer-cant-emphasize-line-of-text-with-a-bold-word-at-the-end/358800)._
