-
Notifications
You must be signed in to change notification settings - Fork 382
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10449 from notbakaneko/feature/chat-message-avoid…
…-nested-links Fix nested links rendering in chat messages
- Loading branch information
Showing
5 changed files
with
21 additions
and
17 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the GNU Affero General Public License v3.0. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
import { createRenderer, linkRenderer, transformLinkUri } from 'markdown/renderers'; | ||
import React from 'react'; | ||
import ReactMarkdown from 'react-markdown'; | ||
import remarkBreaks from 'remark-breaks'; | ||
import autolink from 'remark-plugins/autolink'; | ||
import disableConstructs, { DisabledType } from 'remark-plugins/disable-constructs'; | ||
import ImageLink from './image-link'; | ||
import { createRenderer, linkRenderer, transformLinkUri } from './renderers'; | ||
|
||
const components = Object.freeze({ | ||
a: linkRenderer, | ||
|
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the GNU Affero General Public License v3.0. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
import { timestampDecorator, transformLinkUri } from 'markdown/renderers'; | ||
import React from 'react'; | ||
import ReactMarkdown from 'react-markdown'; | ||
import rehypeTruncate from 'rehype-truncate'; | ||
import autolink from 'remark-plugins/autolink'; | ||
import disableConstructs, { DisabledType } from 'remark-plugins/disable-constructs'; | ||
import { maxMessagePreviewLength, propsFromHref } from 'utils/beatmapset-discussion-helper'; | ||
import { presence } from 'utils/string'; | ||
import { timestampDecorator, transformLinkUri } from './renderers'; | ||
|
||
const components = Object.freeze({ | ||
a: linkRenderer, | ||
|
This file contains 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
This file contains 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