All URILink and LinksSentences now define URI type

This commit is contained in:
James Barnsley
2021-01-09 22:52:45 +13:00
parent 67889670a1
commit a8c6b8b9e6
22 changed files with 152 additions and 127 deletions

View File

@ -4,8 +4,8 @@ import { uriType as uriTypeHelper } from '../util/helpers';
export default memo((props) => {
let to = null;
let { uri } = props;
const uriType = uriTypeHelper(uri);
let { uri, type } = props;
const uriType = type || uriTypeHelper(uri);
if (!props.unencoded) {
uri = encodeURIComponent(uri);
}