fix(bun): remove unecessary buntar in a bun bundle world

This commit is contained in:
Ruben Fiszel
2025-02-13 13:40:44 +01:00
parent dd695b40f4
commit 1be335f042
3 changed files with 21 additions and 5 deletions
@@ -196,10 +196,26 @@
}
function connectProperty(rawValue: string) {
arg.expr = getDefaultExpr(undefined, previousModuleId, rawValue)
arg.type = 'javascript'
propertyType = 'javascript'
monaco?.setCode(arg.expr)
// Extract path from variable('x') or resource('x') format
const varMatch = rawValue.match(/^variable\('([^']+)'\)$/)
const resourceMatch = rawValue.match(/^resource\('([^']+)'\)$/)
if (varMatch) {
arg.type = 'static'
propertyType = 'static'
arg.value = '$var:' + varMatch[1]
monacoTemplate?.setCode(arg.value)
} else if (resourceMatch) {
arg.type = 'static'
propertyType = 'static'
arg.value = '$res:' + resourceMatch[1]
monacoTemplate?.setCode(arg.value)
} else {
arg.expr = getDefaultExpr(undefined, previousModuleId, rawValue)
arg.type = 'javascript'
propertyType = 'javascript'
monaco?.setCode(arg.expr)
}
}
function onFocus() {
@@ -146,6 +146,7 @@
{pickableProperties}
allowCopy={!notSelectable && !$propPickerConfig}
on:select={({ detail }) => {
// console.log('selecting', detail)
dispatch('select', detail)
if ($propPickerConfig?.onSelect(detail)) {
$propPickerConfig?.clearFocus()
@@ -343,7 +343,6 @@
wrapperClasses="inline-flex whitespace-nowrap w-fit"
btnClasses="font-mono h-4 text-2xs font-thin px-1 rounded-[0.275rem]">-</Button
>
<ObjectViewer
{allowCopy}
pureViewer={!$propPickerConfig}