Commit c4d88f85 authored by 田翔's avatar 田翔

fix: 标签颜色修复

parent 5638af02
{
"name": "panda-xform",
"version": "5.6.5",
"description": "5.6.5 代码优化",
"version": "5.6.6",
"description": "5.6.6 标签颜色修复",
"keywords": [
"panda-xform"
],
......
......@@ -3,7 +3,7 @@ import TagPack from '../../../../../components/TagPack'
const SelectView = (props) => {
const { value, sourceType, options } = props
const { value, sourceType, options, color } = props
let tag = value ? value.split(',') : []
if (sourceType === '手动输入') {
......@@ -11,11 +11,11 @@ const SelectView = (props) => {
<div>
{
tag.map((v, i) => {
let color = options.find(s => s.value === v)?.color
let itemColor = options.find(s => s.value === v)?.color
return (
<span key={v} style={{ margin: '0 5px' }}>
{
color ? <TagPack color={color} text={v} /> : v
color ? <TagPack color={itemColor} text={v} /> : v
}
</span>
)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment