diff options
| author | Akihiko Odaki <nekomanma@pixiv.co.jp> | 2018-04-02 12:58:53 +0900 |
|---|---|---|
| committer | Akihiko Odaki <nekomanma@pixiv.co.jp> | 2018-04-02 12:58:53 +0900 |
| commit | 5b9f3701f58ca00c151498d16b6a839a91ba8643 (patch) | |
| tree | d32620bf206288b204060672a0088b4b0c7fa5eb /src/common/text/parse/elements/link.ts | |
| parent | Merge branch 'master' of https://github.com/syuilo/misskey (diff) | |
| download | misskey-5b9f3701f58ca00c151498d16b6a839a91ba8643.tar.gz misskey-5b9f3701f58ca00c151498d16b6a839a91ba8643.tar.bz2 misskey-5b9f3701f58ca00c151498d16b6a839a91ba8643.zip | |
Abolish common and misc directories
Diffstat (limited to 'src/common/text/parse/elements/link.ts')
| -rw-r--r-- | src/common/text/parse/elements/link.ts | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/src/common/text/parse/elements/link.ts b/src/common/text/parse/elements/link.ts deleted file mode 100644 index 35563ddc3d..0000000000 --- a/src/common/text/parse/elements/link.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * Link - */ - -module.exports = text => { - const match = text.match(/^\??\[([^\[\]]+?)\]\((https?:\/\/[\w\/:%#@\$&\?!\(\)\[\]~\.=\+\-]+?)\)/); - if (!match) return null; - const silent = text[0] == '?'; - const link = match[0]; - const title = match[1]; - const url = match[2]; - return { - type: 'link', - content: link, - title: title, - url: url, - silent: silent - }; -}; |