const assetBase = import.meta.env.BASE_URL || '/';

export function getPublicAssetUrl(path: string) {
  if (!path) {
    return assetBase;
  }
  const normalizedPath = path.startsWith('/') ? path.slice(1) : path;
  return `${assetBase}${normalizedPath}`;
}

export function getEmptyStateImageUrl(themeMode?: string) {
  return getPublicAssetUrl(`empty${themeMode === 'dark' ? '-dark' : ''}.png`);
}
