Move to react for newlines, emoji, and links in message body

This commit is contained in:
Scott Nonnenberg
2018-05-14 13:52:10 -07:00
parent 721935b0c8
commit 4e5c8965ff
15 changed files with 400 additions and 29 deletions

View File

@@ -0,0 +1,59 @@
### Plain text
```jsx
<MessageBody text="Plain text message" />
```
```jsx
<MessageBody text="Plain text message\n\nWith a new line." />
```
### Jumbo emoji
```jsx
<MessageBody text="🔥" />
```
```jsx
<MessageBody text="🔥🔥" />
```
```jsx
<MessageBody text="🔥🔥🔥🔥" />
```
```jsx
<MessageBody text="🔥🔥🔥🔥🔥🔥🔥🔥" />
```
```jsx
<MessageBody text="🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥" />
```
### Text and emoji
```jsx
<MessageBody text="Plain text 🔥message. With 🔥emoji🔥 sprinkled 🔥about" />
```
```jsx
<MessageBody text="🔥Message starting and ending with emoji🔥" />
```
### Links
```jsx
<MessageBody text="This before and after link. Before. https://somewhere.com After." />
```
```jsx
<MessageBody text="Link https://somewhere.com\nWhat do you think? How about this one? \n\nhttps://anotherlink.com" />
```
```jsx
<MessageBody text="Link https://somewhere.com\nWhat do you think? How about this one? \n\nhttps://anotherlink.com" />
```
```jsx
<MessageBody text="should not render as link:\nmailto:someone@somewhere.com\nftp://something.com\n//local/share\n\\local\share\n\nshould render as link:\ngithub.com\nhttps://blah.com" />
```