mirror of
https://github.com/danbulant/Nertivia-Client
synced 2026-06-24 17:11:43 +00:00
commit
15a7d4733d
2 changed files with 6 additions and 2 deletions
|
|
@ -4,7 +4,7 @@ import config from "@/config.js";
|
||||||
export default (order) => { return {
|
export default (order) => { return {
|
||||||
order: order++,
|
order: order++,
|
||||||
match: function(source) {
|
match: function(source) {
|
||||||
return /^<:([\w\d_]+):([\w\d_]+)>/.exec(source)
|
return /^<:([\w\d_-]+):([\w\d_-]+)>/.exec(source)
|
||||||
},
|
},
|
||||||
|
|
||||||
parse: function(capture, parse, state) {
|
parse: function(capture, parse, state) {
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,11 @@ export default (order) => { return {
|
||||||
match: function(source) {
|
match: function(source) {
|
||||||
const match = linkify.match(source)
|
const match = linkify.match(source)
|
||||||
|
|
||||||
if(match === null) {
|
if(
|
||||||
|
match === null ||
|
||||||
|
match[0].index !== 0 ||
|
||||||
|
match.length === 0
|
||||||
|
) {
|
||||||
return null
|
return null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue