export function projectDisplayNameFromProjectId(projectId: string): string { const githubRemotePrefix = "remote:github.com/"; if (projectId.startsWith(githubRemotePrefix)) { return projectId.slice(githubRemotePrefix.length) || projectId; } const segments = projectId.split(/[\\/]/).filter(Boolean); return segments[segments.length - 1] || projectId; } export function projectIconPlaceholderLabelFromDisplayName(displayName: string): string { const trimmedDisplayName = displayName.trim(); if (!trimmedDisplayName) { return ""; } const segments = trimmedDisplayName.split("/").filter(Boolean); return segments[segments.length - 1] || trimmedDisplayName; }