mirror of
https://github.com/Tencent/tmagic-editor.git
synced 2026-06-20 06:12:00 +00:00
fix(editor): sidebar 侧栏项 key 与 SideItemKey 常量对齐
确保侧栏配置与字段编辑时切换 tab 的 key 一致,避免硬编码字符串不一致。
This commit is contained in:
parent
c811908971
commit
8933c46b73
@ -257,7 +257,7 @@ const getItemConfig = (data: SideItem): SideComponent => {
|
||||
slots: {},
|
||||
},
|
||||
layer: {
|
||||
$key: 'layer',
|
||||
$key: SideItemKey.LAYER,
|
||||
type: 'component',
|
||||
icon: List,
|
||||
text: '已选组件',
|
||||
@ -277,7 +277,7 @@ const getItemConfig = (data: SideItem): SideComponent => {
|
||||
slots: {},
|
||||
},
|
||||
[SideItemKey.CODE_BLOCK]: {
|
||||
$key: 'code-block',
|
||||
$key: SideItemKey.CODE_BLOCK,
|
||||
type: 'component',
|
||||
icon: EditPen,
|
||||
text: '代码编辑',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user