Pillify permalinks to rooms and users (#10388)
This commit is contained in:
parent
d850c95099
commit
a86a8e7f8e
5 changed files with 128 additions and 105 deletions
|
@ -92,11 +92,8 @@ export default class TextualBody extends React.Component<IBodyProps, IState> {
|
|||
const showLineNumbers = SettingsStore.getValue("showCodeLineNumbers");
|
||||
this.activateSpoilers([content]);
|
||||
|
||||
// pillifyLinks BEFORE linkifyElement because plain room/user URLs in the composer
|
||||
// are still sent as plaintext URLs. If these are ever pillified in the composer,
|
||||
// we should be pillify them here by doing the linkifying BEFORE the pillifying.
|
||||
pillifyLinks([content], this.props.mxEvent, this.pills);
|
||||
HtmlUtils.linkifyElement(content);
|
||||
pillifyLinks([content], this.props.mxEvent, this.pills);
|
||||
|
||||
this.calculateUrlPreview();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue