From 4c9aa6f4a47446d44344ea966614a260ab82ee1f Mon Sep 17 00:00:00 2001 From: Rizky Date: Mon, 19 Aug 2024 14:48:55 +0700 Subject: [PATCH] fix --- app/web/src/nova/ed/panel/side/prop-instance/prop-option.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/web/src/nova/ed/panel/side/prop-instance/prop-option.tsx b/app/web/src/nova/ed/panel/side/prop-instance/prop-option.tsx index b4419735..71a23595 100644 --- a/app/web/src/nova/ed/panel/side/prop-instance/prop-option.tsx +++ b/app/web/src/nova/ed/panel/side/prop-instance/prop-option.tsx @@ -96,7 +96,9 @@ export const EdPropInstanceOptions: FC<{ for (const [k, v] of Object.entries(meta.item.component.props)) { if (v.valueBuilt && v.valueBuilt.length > 3) { if (v.valueBuilt.startsWith(`const _jsxFileName = "";`)) { - v.valueBuilt = `(() => { ${v.valueBuilt} })()`; + v.valueBuilt = `(() => { ${v.valueBuilt.replace( + `const _jsxFileName = ""; return ` + )} })()`; } try {