chore: run eslint
This commit is contained in:
parent
746bcde87a
commit
f979211d90
|
|
@ -286,7 +286,7 @@ for (const baseColor of ['slate', 'gray', 'zinc', 'neutral', 'stone', 'lime']) {
|
||||||
const color = scale
|
const color = scale
|
||||||
? colorsData[resolvedBase].find(
|
? colorsData[resolvedBase].find(
|
||||||
(item: any) => item.scale === Number.parseInt(scale),
|
(item: any) => item.scale === Number.parseInt(scale),
|
||||||
)
|
)
|
||||||
: colorsData[resolvedBase]
|
: colorsData[resolvedBase]
|
||||||
if (color)
|
if (color)
|
||||||
base.cssVars[mode][key] = color.hslChannel
|
base.cssVars[mode][key] = color.hslChannel
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,7 @@ export const add = new Command()
|
||||||
const config = await getConfig(cwd)
|
const config = await getConfig(cwd)
|
||||||
if (!config) {
|
if (!config) {
|
||||||
logger.warn(
|
logger.warn(
|
||||||
`Configuration is missing. Please run ${chalk.green( 'init' )} to create a components.json file.`,
|
`Configuration is missing. Please run ${chalk.green('init')} to create a components.json file.`,
|
||||||
)
|
)
|
||||||
process.exit(1)
|
process.exit(1)
|
||||||
}
|
}
|
||||||
|
|
@ -139,7 +139,7 @@ export const add = new Command()
|
||||||
}
|
}
|
||||||
|
|
||||||
for (const file of item.files) {
|
for (const file of item.files) {
|
||||||
let filePath = path.resolve(targetDir, file.name)
|
const filePath = path.resolve(targetDir, file.name)
|
||||||
|
|
||||||
// Run transformers.
|
// Run transformers.
|
||||||
const content = await transform({
|
const content = await transform({
|
||||||
|
|
|
||||||
|
|
@ -112,8 +112,8 @@ export async function promptForConfig(
|
||||||
name: 'framework',
|
name: 'framework',
|
||||||
message: `Which ${highlight('framework')} are you using?`,
|
message: `Which ${highlight('framework')} are you using?`,
|
||||||
choices: [
|
choices: [
|
||||||
{title: 'Nuxt', value: 'nuxt'},
|
{ title: 'Nuxt', value: 'nuxt' },
|
||||||
{title: 'Vite + Vue', value: 'vue'},
|
{ title: 'Vite + Vue', value: 'vue' },
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
@ -140,7 +140,7 @@ export async function promptForConfig(
|
||||||
type: 'text',
|
type: 'text',
|
||||||
name: 'tailwindCss',
|
name: 'tailwindCss',
|
||||||
message: `Where is your ${highlight('Tailwind CSS')} file?`,
|
message: `Where is your ${highlight('Tailwind CSS')} file?`,
|
||||||
initial: (prev,values) => defaultConfig?.tailwind.css ?? values.framework === 'nuxt' ? DEFAULT_TAILWIND_CSS_NUXT : DEFAULT_TAILWIND_CSS
|
initial: (prev, values) => defaultConfig?.tailwind.css ?? values.framework === 'nuxt' ? DEFAULT_TAILWIND_CSS_NUXT : DEFAULT_TAILWIND_CSS,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
type: 'toggle',
|
type: 'toggle',
|
||||||
|
|
@ -271,7 +271,7 @@ export async function runInit(cwd: string, config: Config) {
|
||||||
const packageManager = await getPackageManager(cwd)
|
const packageManager = await getPackageManager(cwd)
|
||||||
|
|
||||||
// TODO: add support for other icon libraries.
|
// TODO: add support for other icon libraries.
|
||||||
const deps = PROJECT_DEPENDENCIES.base.concat(
|
const deps = PROJECT_DEPENDENCIES.base.concat(
|
||||||
config.framework === 'nuxt' ? PROJECT_DEPENDENCIES.nuxt : PROJECT_DEPENDENCIES.vue,
|
config.framework === 'nuxt' ? PROJECT_DEPENDENCIES.nuxt : PROJECT_DEPENDENCIES.vue,
|
||||||
).concat(
|
).concat(
|
||||||
config.style === 'new-york' ? [] : ['lucide-vue-next'],
|
config.style === 'new-york' ? [] : ['lucide-vue-next'],
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user