Fix mentions not being stopped by >
This commit is contained in:
parent
b6d69ce0b5
commit
56373135c7
2 changed files with 5 additions and 1 deletions
|
|
@ -21,6 +21,9 @@ Procedure when bumping the version number:
|
||||||
- Respect colon-delimited emoji when calculating nick hue
|
- Respect colon-delimited emoji when calculating nick hue
|
||||||
- Display colon-delimited emoji in nicks and messages
|
- Display colon-delimited emoji in nicks and messages
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
- Mentions not being stopped by `>`
|
||||||
|
|
||||||
## v0.5.2 - 2023-01-14
|
## v0.5.2 - 2023-01-14
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,9 @@ use super::util;
|
||||||
fn nick_char(ch: char) -> bool {
|
fn nick_char(ch: char) -> bool {
|
||||||
// Closely following the heim mention regex:
|
// Closely following the heim mention regex:
|
||||||
// https://github.com/euphoria-io/heim/blob/978c921063e6b06012fc8d16d9fbf1b3a0be1191/client/lib/stores/chat.js#L14-L15
|
// https://github.com/euphoria-io/heim/blob/978c921063e6b06012fc8d16d9fbf1b3a0be1191/client/lib/stores/chat.js#L14-L15
|
||||||
|
// `>` has been experimentally confirmed to delimit mentions as well.
|
||||||
match ch {
|
match ch {
|
||||||
',' | '.' | '!' | '?' | ';' | '&' | '<' | '\'' | '"' => false,
|
',' | '.' | '!' | '?' | ';' | '&' | '<' | '>' | '\'' | '"' => false,
|
||||||
_ => !ch.is_whitespace(),
|
_ => !ch.is_whitespace(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue