mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-07-02 08:58:36 +00:00
Merge pull request #9897 from shadcn-ui/shadcn/fix-cli
fix(shadcn): fallback style resolving issue
This commit is contained in:
5
.changeset/dark-lemons-invite.md
Normal file
5
.changeset/dark-lemons-invite.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"shadcn": patch
|
||||
---
|
||||
|
||||
fix fallback style resolving issue
|
||||
@@ -80,10 +80,11 @@ export function ProjectForm({
|
||||
|
||||
const commands = React.useMemo(() => {
|
||||
const presetFlag = ` --preset ${presetCode}`
|
||||
const baseFlag = params.base !== "radix" ? ` --base ${params.base}` : ""
|
||||
const templateFlag = ` --template ${framework}`
|
||||
const monorepoFlag = isMonorepo ? " --monorepo" : ""
|
||||
const rtlFlag = params.rtl ? " --rtl" : ""
|
||||
const flags = `${presetFlag}${templateFlag}${monorepoFlag}${rtlFlag}`
|
||||
const flags = `${presetFlag}${baseFlag}${templateFlag}${monorepoFlag}${rtlFlag}`
|
||||
|
||||
return IS_LOCAL_DEV && !process.env.NEXT_PUBLIC_RC
|
||||
? {
|
||||
@@ -98,7 +99,7 @@ export function ProjectForm({
|
||||
yarn: `yarn dlx shadcn${SHADCN_VERSION} init${flags}`,
|
||||
bun: `bunx --bun shadcn${SHADCN_VERSION} init${flags}`,
|
||||
}
|
||||
}, [framework, isMonorepo, params.rtl, presetCode])
|
||||
}, [framework, isMonorepo, params.base, params.rtl, presetCode])
|
||||
|
||||
const command = commands[packageManager]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user