浏览代码

fix: var highlight problme (#214)

tags/0.3.1
Joel 2 年前
父节点
当前提交
17a1c05728
没有帐户链接到提交者的电子邮件

+ 3
- 2
web/app/components/app/configuration/features/chat-group/opening-statement/index.tsx 查看文件

}, [value]) }, [value])


const coloredContent = (tempValue || '') const coloredContent = (tempValue || '')
.replace(regex, varHighlightHTML({ name: '$1' })) // `<span class="${highLightClassName}">{{$1}}</span>`
.replace(/\n/g, '<br />')
.replace(/</g, '&lt;') .replace(/</g, '&lt;')
.replace(/>/g, '&gt;') .replace(/>/g, '&gt;')
.replace(regex, varHighlightHTML({ name: '$1' })) // `<span class="${highLightClassName}">{{$1}}</span>`
.replace(/\n/g, '<br />')




const handleEdit = () => { const handleEdit = () => {

+ 3
- 2
web/app/components/base/block-input/index.tsx 查看文件

}) })


const coloredContent = (currentValue || '') const coloredContent = (currentValue || '')
.replace(regex, varHighlightHTML({ name: '$1' })) // `<span class="${highLightClassName}">{{$1}}</span>`
.replace(/\n/g, '<br />')
.replace(/</g, '&lt;') .replace(/</g, '&lt;')
.replace(/>/g, '&gt;') .replace(/>/g, '&gt;')
.replace(regex, varHighlightHTML({ name: '$1' })) // `<span class="${highLightClassName}">{{$1}}</span>`
.replace(/\n/g, '<br />')


// Not use useCallback. That will cause out callback get old data. // Not use useCallback. That will cause out callback get old data.
const handleSubmit = () => { const handleSubmit = () => {

正在加载...
取消
保存