This commit is contained in:
Kevin
2025-06-20 13:14:42 -05:00
parent 137bee9c14
commit d53cf66409

View File

@ -159,7 +159,6 @@ export const ProjectExplorer = ({
setActiveIndex(domIndex) setActiveIndex(domIndex)
} }
useEffect(() => { useEffect(() => {
/** /**
* You are loading a new project, clear the internal state! * You are loading a new project, clear the internal state!
@ -226,12 +225,17 @@ export const ProjectExplorer = ({
icon = 'folderOpen' icon = 'folderOpen'
} }
const errorsAsKeyValue = Array.from(runtimeErrors, ([key, value]) => ({
const errorsAsKeyValue = Array.from(runtimeErrors, ([key, value]) => ({ key, value })); key,
const anyParentFolderHasError = errorsAsKeyValue.some(({key,value})=>{ value,
return key.indexOf(child.path) >= 0 }))
}) const anyParentFolderHasError = errorsAsKeyValue.some(
const hasRuntimeError = runtimeErrors.has(child.path) || anyParentFolderHasError ({ key, value }) => {
return key.indexOf(child.path) >= 0
}
)
const hasRuntimeError =
runtimeErrors.has(child.path) || anyParentFolderHasError
const row: FileExplorerRow = { const row: FileExplorerRow = {
// copy over all the other data that was built up to the DOM render row // copy over all the other data that was built up to the DOM render row