mirror of https://github.com/msgbyte/tailchat
feat: 增加更多的bbcode tag标签
parent
711bf187c3
commit
f6f66aa4bf
@ -0,0 +1,10 @@
|
||||
import React from 'react';
|
||||
import type { TagProps } from '../bbcode/type';
|
||||
|
||||
export const DeleteTag: React.FC<TagProps> = React.memo((props) => {
|
||||
const { node } = props;
|
||||
const text = node.content.join('');
|
||||
|
||||
return <del>{text}</del>;
|
||||
});
|
||||
DeleteTag.displayName = 'DeleteTag';
|
@ -0,0 +1,10 @@
|
||||
import React from 'react';
|
||||
import type { TagProps } from '../bbcode/type';
|
||||
|
||||
export const ItalicTag: React.FC<TagProps> = React.memo((props) => {
|
||||
const { node } = props;
|
||||
const text = node.content.join('');
|
||||
|
||||
return <i>{text}</i>;
|
||||
});
|
||||
ItalicTag.displayName = 'ItalicTag';
|
@ -0,0 +1,10 @@
|
||||
import React from 'react';
|
||||
import type { TagProps } from '../bbcode/type';
|
||||
|
||||
export const UnderlinedTag: React.FC<TagProps> = React.memo((props) => {
|
||||
const { node } = props;
|
||||
const text = node.content.join('');
|
||||
|
||||
return <ins>{text}</ins>;
|
||||
});
|
||||
UnderlinedTag.displayName = 'UnderlinedTag';
|
Loading…
Reference in New Issue