mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-10-30 18:22:59 +00:00
BREAKING CHANGE: Simplified architecture from two themes to one - Deleted registry/new-york/ directory entirely - Flattened Index structure from Index[style][name] to Index[name] - Updated build-registry.mts to only build 'default' style - Updated registry/styles.ts to single style array - Removed style parameter from all registry functions: - getRegistryItem(name) - getRegistryComponent(name) - getBlock(name) - getAllBlocks() - Updated ComponentPreview to be server component (removed useConfig) - Updated BlockDisplay to remove styleName prop - Flattened /view route from /view/[style]/[name] to /view/[name] - Updated blocks page to remove style logic Benefits: - Simpler codebase (no dual theme complexity) - Faster builds (no duplicate component generation) - Clearer architecture (single source of truth) - Fixes build errors from style boundary issues
20 lines
410 B
TypeScript
20 lines
410 B
TypeScript
// Single theme system - only "default" style
|
|
export const styles = [
|
|
{
|
|
name: "default",
|
|
label: "Default",
|
|
},
|
|
] as const
|
|
|
|
export type Style = (typeof styles)[number]
|
|
|
|
export function getActiveStyle() {
|
|
// Always returns "default" in single theme system
|
|
return styles[0]
|
|
}
|
|
|
|
export function getStyle(name: string) {
|
|
// Always returns "default" since we only have one style
|
|
return styles[0]
|
|
}
|