Sitesmith: AI site builder addon (frontend) #1

Merged
jknapp merged 10 commits from sitesmith-ai-builder into main 2026-05-24 17:11:03 +00:00
Showing only changes of commit 2ca1ff0cf9 - Show all commits

View File

@@ -29,7 +29,7 @@ const LayerNode: React.FC<LayerNodeProps> = ({ nodeId, depth }) => {
const resolvedName = typeof nodeType === 'object' && nodeType !== null && 'resolvedName' in nodeType const resolvedName = typeof nodeType === 'object' && nodeType !== null && 'resolvedName' in nodeType
? (nodeType as any).resolvedName ? (nodeType as any).resolvedName
: typeof nodeType === 'string' ? nodeType : undefined; : typeof nodeType === 'string' ? nodeType : undefined;
const displayName = node.data.displayName || resolvedName || 'Component'; const displayName = (node.data.props?.aiName as string) || node.data.displayName || (node.data.type as any)?.resolvedName || 'Node';
const childNodeIds: string[] = node.data.nodes || []; const childNodeIds: string[] = node.data.nodes || [];
const linkedNodeIds: string[] = Object.values(node.data.linkedNodes || {}) as string[]; const linkedNodeIds: string[] = Object.values(node.data.linkedNodes || {}) as string[];
const allChildren = [...childNodeIds, ...linkedNodeIds]; const allChildren = [...childNodeIds, ...linkedNodeIds];