mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-04-23 18:08:05 +01:00
Biggest changes forced by this: alt tags for all images, resulting in new strings added to messages.json, and a new i18n paramter/prop added in a plot of places. Another change of note is that there are two new tslint.json files under ts/test and ts/styleguide to relax our rules a bit there. This required a change to our package.json script, as manually specifying the config file there made it ignore our tslint.json files in subdirectories
13 lines
465 B
TypeScript
13 lines
465 B
TypeScript
// tslint:disable-next-line: match-default-export-name
|
|
import linkTextInternal from '../../js/modules/link_text';
|
|
|
|
export const linkText = (value: string): string =>
|
|
linkTextInternal(value, { target: '_blank' });
|
|
|
|
export const replaceLineBreaks = (value: string): string =>
|
|
value.replace(/\r?\n/g, '<br>');
|
|
|
|
// NOTE: How can we use `lodash/fp` `compose` with type checking?
|
|
export const render = (value: string): string =>
|
|
replaceLineBreaks(linkText(value));
|