[Mentions v2] Add new rule in ExpensiMark for room mentions#680
Merged
rlinoz merged 5 commits intoExpensify:mainfrom Apr 10, 2024
Merged
[Mentions v2] Add new rule in ExpensiMark for room mentions#680rlinoz merged 5 commits intoExpensify:mainfrom
rlinoz merged 5 commits intoExpensify:mainfrom
Conversation
rlinoz
requested changes
Apr 10, 2024
Contributor
Author
|
Thanks @rlinoz, I've added tests and comment |
Beamanator
requested changes
Apr 10, 2024
Contributor
Beamanator
left a comment
There was a problem hiding this comment.
Can we also add at least 1 test for room names with - since that will probably be a pretty common use-case? Ex: #room-name, maybe even #room-123
…hyphens and numbers
rlinoz
approved these changes
Apr 10, 2024
50 tasks
rojiphil
reviewed
Nov 11, 2024
| { | ||
| name: 'roomMentions', | ||
|
|
||
| regex: /(?<![^ \n*~_])(#[\p{Ll}0-9-]{1,80})/gmiu, |
There was a problem hiding this comment.
NAB but certain improvements were introduced as mentioned in this issue with respect to identifying room mentions.
rayane-d
reviewed
May 15, 2025
| { | ||
| name: 'roomMentions', | ||
|
|
||
| regex: /(?<![^ \n*~_])(#[\p{Ll}0-9-]{1,80})/gmiu, |
There was a problem hiding this comment.
In response to the issue Expensify/App#57195, we added in PR https://github.com/Expensify/expensify-common/pull/840/files the identification of room mentions with : before them.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Important
Room mentions consists of
#symbol followed by room name. Room name consist of any char sequence connected by hyphens (no spaces is allowed inside room name)Fixed Issues
$ Expensify/App#39538
Tests
I've created multiple unit tests to cover most of the possible usages of room/report mentions. Room mentions consists of
#symbol followed by room nameCheck if existing unit tests are not failing after my. changes, added additional tests to cover room mentions
QA
Room mentions are not yet visible inside E/App, so to validate this changes we should only check for regressions or other markdown rules
Room mention syntax is very similar to Heading syntax. Extensive testing of this aspeect of markdown parser is recommended. Moreover all other markdown rules should be untouched