Merge remote-tracking branch 'origin/dev' into autoform
This commit is contained in:
commit
dffef69bb9
2
.github/workflows/test.yaml
vendored
2
.github/workflows/test.yaml
vendored
|
|
@ -24,7 +24,7 @@ jobs:
|
|||
- name: Setup Node.js environment
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 16
|
||||
node-version: 18
|
||||
|
||||
- uses: pnpm/action-setup@v2
|
||||
name: Install pnpm
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ function constructFiles(componentName: string, style: Style, sources: Record<str
|
|||
}
|
||||
})
|
||||
|
||||
// @ts-expect-error componentName migth not exist in Index
|
||||
// @ts-expect-error componentName might not exist in Index
|
||||
const registryDependencies = demoIndex[style][componentName as any]?.registryDependencies?.filter(i => i !== 'utils')
|
||||
|
||||
const files = {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "www",
|
||||
"type": "module",
|
||||
"version": "0.10.3",
|
||||
"version": "0.10.4",
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
|
|
@ -52,7 +52,7 @@
|
|||
"@iconify/vue": "^4.1.2",
|
||||
"@oxc-parser/wasm": "^0.1.0",
|
||||
"@shikijs/transformers": "^1.3.0",
|
||||
"@types/lodash.template": "^4.5.3",
|
||||
"@types/lodash-es": "^4.17.12",
|
||||
"@types/node": "^20.12.7",
|
||||
"@vitejs/plugin-vue": "^5.0.4",
|
||||
"@vitejs/plugin-vue-jsx": "^3.1.0",
|
||||
|
|
@ -60,7 +60,7 @@
|
|||
"@vue/compiler-dom": "^3.4.24",
|
||||
"@vue/tsconfig": "^0.5.1",
|
||||
"autoprefixer": "^10.4.19",
|
||||
"lodash.template": "^4.5.0",
|
||||
"lodash-es": "^4.17.21",
|
||||
"pathe": "^1.1.2",
|
||||
"rimraf": "^5.0.5",
|
||||
"shiki": "^1.3.0",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import fs from 'node:fs'
|
||||
import path, { basename } from 'node:path'
|
||||
import template from 'lodash.template'
|
||||
import { template } from 'lodash-es'
|
||||
import { rimraf } from 'rimraf'
|
||||
|
||||
import { colorMapping, colors } from '../src/lib/registry/colors'
|
||||
|
|
@ -40,7 +40,7 @@ for (const style of styles) {
|
|||
file => `../src/lib/registry/${style.name}/${file}`,
|
||||
)
|
||||
|
||||
const type = item.type.split(':')[1]
|
||||
// const type = item.type.split(':')[1]
|
||||
index += `
|
||||
"${item.name}": {
|
||||
name: "${item.name}",
|
||||
|
|
@ -396,4 +396,4 @@ fs.writeFileSync(
|
|||
'utf8',
|
||||
)
|
||||
|
||||
console.log('✅ Done!')
|
||||
console.log('✅ Done!!')
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ The `<Form />` component is a wrapper around the `vee-validate` library. It prov
|
|||
- Composable components for building forms.
|
||||
- A `<FormField />` component for building controlled form fields.
|
||||
- Form validation using `zod`.
|
||||
- Applies the correct `aria` attributes to form fields based on states, handle unqiue IDs
|
||||
- Applies the correct `aria` attributes to form fields based on states, handle unique IDs
|
||||
- Built to work with all Radix Vue components.
|
||||
- Bring your own schema library. We use `zod` but you can use any other supported schema validation you want, like [`yup`](https://github.com/jquense/yup) or [`valibot`](https://valibot.dev/).
|
||||
- **You have full control over the markup and styling.**
|
||||
|
|
@ -249,7 +249,7 @@ function onSubmit(values) {
|
|||
### Build your form
|
||||
|
||||
Based on last step we can either use `<Form />` component or `useForm` composable
|
||||
`useForm` is recommended cause values are typed automatically
|
||||
`useForm` is recommended because values are typed automatically
|
||||
|
||||
```vue:line-numbers {2}
|
||||
<script setup lang="ts">
|
||||
|
|
|
|||
|
|
@ -176,7 +176,7 @@ To do so, we have a helper function named [`useForwardPropsEmits`](https://www.r
|
|||
To be more clear, the function `useForwardPropsEmits` takes in props and an optional emit function, and returns a
|
||||
computed object that combines the parsed props and emits as props.
|
||||
|
||||
Here's an example from `Accordian` root component.
|
||||
Here's an example from `Accordion` root component.
|
||||
|
||||
```vue
|
||||
<script setup lang="ts">
|
||||
|
|
@ -200,7 +200,7 @@ const forwarded = useForwardPropsEmits(props, emits)
|
|||
</template>
|
||||
```
|
||||
|
||||
As you can see, `AccordionRootEmits` and `AccordionRootProps` types are imported from radix, combined with `useForwardPropsEmits` and then are binded using `v-bind` syntaxt.
|
||||
As you can see, `AccordionRootEmits` and `AccordionRootProps` types are imported from radix, combined with `useForwardPropsEmits` and then are binded using `v-bind` syntax.
|
||||
|
||||
### CSS Classes
|
||||
There are cases when we want to accept `class` as a prop in our `shadcn/vue` component and then combine it with a default tailwind class on our `radix-vue` component via `cn` utility function.
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ const onSubmit = handleSubmit((values) => {
|
|||
<template>
|
||||
<div>
|
||||
<h3 class="text-lg font-medium">
|
||||
Appearence
|
||||
Appearance
|
||||
</h3>
|
||||
<p class="text-sm text-muted-foreground">
|
||||
Customize the appearance of the app. Automatically switch between day and night themes.
|
||||
|
|
|
|||
|
|
@ -218,7 +218,7 @@ import {
|
|||
</MenubarRadioGroup>
|
||||
<MenubarSeparator />
|
||||
<MenubarItem inset>
|
||||
Manage Famliy...
|
||||
Manage Family...
|
||||
</MenubarItem>
|
||||
<MenubarSeparator />
|
||||
<MenubarItem inset>
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ function computeLineOpacity(val: any, index: number) {
|
|||
<CardHeader>
|
||||
<CardTitle>Exercise Minutes</CardTitle>
|
||||
<CardDescription>
|
||||
Your excercise minutes are ahead of where you normally are.
|
||||
Your exercise minutes are ahead of where you normally are.
|
||||
</CardDescription>
|
||||
</CardHeader>
|
||||
<CardContent class="pb-4">
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ const plugin = Autoplay({
|
|||
class="relative w-full max-w-xs"
|
||||
:plugins="[plugin]"
|
||||
@mouseenter="plugin.stop"
|
||||
@mouseleave="[plugin.reset(), plugin.play(), console.log('Runing')];"
|
||||
@mouseleave="[plugin.reset(), plugin.play(), console.log('Running')];"
|
||||
>
|
||||
<CarouselContent>
|
||||
<CarouselItem v-for="(_, index) in 5" :key="index">
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ function computeLineOpacity(val: any, index: number) {
|
|||
<CardHeader>
|
||||
<CardTitle>Exercise Minutes</CardTitle>
|
||||
<CardDescription>
|
||||
Your excercise minutes are ahead of where you normally are.
|
||||
Your exercise minutes are ahead of where you normally are.
|
||||
</CardDescription>
|
||||
</CardHeader>
|
||||
<CardContent class="pb-4">
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ const plugin = Autoplay({
|
|||
class="relative w-full max-w-xs"
|
||||
:plugins="[plugin]"
|
||||
@mouseenter="plugin.stop"
|
||||
@mouseleave="[plugin.reset(), plugin.play(), console.log('Runing')];"
|
||||
@mouseleave="[plugin.reset(), plugin.play(), console.log('Running')];"
|
||||
>
|
||||
<CarouselContent>
|
||||
<CarouselItem v-for="(_, index) in 5" :key="index">
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "shadcn-vue",
|
||||
"type": "module",
|
||||
"version": "0.10.3",
|
||||
"version": "0.10.4",
|
||||
"private": true,
|
||||
"packageManager": "pnpm@9.0.5",
|
||||
"license": "MIT",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "shadcn-vue",
|
||||
"type": "module",
|
||||
"version": "0.10.3",
|
||||
"version": "0.10.4",
|
||||
"description": "Add components to your apps.",
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
|
@ -55,7 +55,7 @@
|
|||
"diff": "^5.2.0",
|
||||
"fs-extra": "^11.2.0",
|
||||
"https-proxy-agent": "^7.0.4",
|
||||
"lodash.template": "^4.5.0",
|
||||
"lodash-es": "^4.17.21",
|
||||
"magic-string": "^0.30.10",
|
||||
"nypm": "^0.3.8",
|
||||
"ofetch": "^1.3.4",
|
||||
|
|
@ -71,7 +71,7 @@
|
|||
"@types/babel__core": "^7.20.5",
|
||||
"@types/diff": "^5.2.0",
|
||||
"@types/fs-extra": "^11.0.4",
|
||||
"@types/lodash.template": "^4.5.3",
|
||||
"@types/lodash-es": "^4.5.3",
|
||||
"@types/node": "^20.11.30",
|
||||
"@types/prompts": "^2.4.9",
|
||||
"@vitest/ui": "^0.34.4",
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import { existsSync, promises as fs } from 'node:fs'
|
|||
import process from 'node:process'
|
||||
import path from 'pathe'
|
||||
import { Command } from 'commander'
|
||||
import template from 'lodash.template'
|
||||
import { template } from 'lodash-es'
|
||||
import ora from 'ora'
|
||||
import prompts from 'prompts'
|
||||
import { z } from 'zod'
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "shadcn-nuxt",
|
||||
"type": "module",
|
||||
"version": "0.10.3",
|
||||
"version": "0.10.4",
|
||||
"description": "Add shadcn-vue module to Nuxt",
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
|
|
|
|||
|
|
@ -147,9 +147,9 @@ importers:
|
|||
'@shikijs/transformers':
|
||||
specifier: ^1.3.0
|
||||
version: 1.3.0
|
||||
'@types/lodash.template':
|
||||
specifier: ^4.5.3
|
||||
version: 4.5.3
|
||||
'@types/lodash-es':
|
||||
specifier: ^4.17.12
|
||||
version: 4.17.12
|
||||
'@types/node':
|
||||
specifier: ^20.12.7
|
||||
version: 20.12.7
|
||||
|
|
@ -171,9 +171,9 @@ importers:
|
|||
autoprefixer:
|
||||
specifier: ^10.4.19
|
||||
version: 10.4.19(postcss@8.4.38)
|
||||
lodash.template:
|
||||
specifier: ^4.5.0
|
||||
version: 4.5.0
|
||||
lodash-es:
|
||||
specifier: ^4.17.21
|
||||
version: 4.17.21
|
||||
pathe:
|
||||
specifier: ^1.1.2
|
||||
version: 1.1.2
|
||||
|
|
@ -237,9 +237,9 @@ importers:
|
|||
https-proxy-agent:
|
||||
specifier: ^7.0.4
|
||||
version: 7.0.4
|
||||
lodash.template:
|
||||
specifier: ^4.5.0
|
||||
version: 4.5.0
|
||||
lodash-es:
|
||||
specifier: ^4.17.21
|
||||
version: 4.17.21
|
||||
magic-string:
|
||||
specifier: ^0.30.10
|
||||
version: 0.30.10
|
||||
|
|
@ -280,9 +280,9 @@ importers:
|
|||
'@types/fs-extra':
|
||||
specifier: ^11.0.4
|
||||
version: 11.0.4
|
||||
'@types/lodash.template':
|
||||
'@types/lodash-es':
|
||||
specifier: ^4.5.3
|
||||
version: 4.5.3
|
||||
version: 4.17.12
|
||||
'@types/node':
|
||||
specifier: ^20.11.30
|
||||
version: 20.12.7
|
||||
|
|
@ -2052,8 +2052,8 @@ packages:
|
|||
'@types/linkify-it@3.0.5':
|
||||
resolution: {integrity: sha512-yg6E+u0/+Zjva+buc3EIb+29XEg4wltq7cSmd4Uc2EE/1nUVmxyzpX6gUXD0V8jIrG0r7YeOGVIbYRkxeooCtw==}
|
||||
|
||||
'@types/lodash.template@4.5.3':
|
||||
resolution: {integrity: sha512-Mo0UYKLu1oXgkV9TVoXZLlXXjyIXlW7ZQRxi/4gQJmzJr63dmicE8gG0OkPjYTKBrBic852q0JzqrtNUWLBIyA==}
|
||||
'@types/lodash-es@4.17.12':
|
||||
resolution: {integrity: sha512-0NgftHUcV4v34VhXm8QBSftKVXtbkBG3ViCjs6+eJ5a6y6Mi/jiFGPc1sC7QK+9BFhWrURE3EOggmWaSxL9OzQ==}
|
||||
|
||||
'@types/lodash@4.17.0':
|
||||
resolution: {integrity: sha512-t7dhREVv6dbNj0q17X12j7yDG4bD/DHYX7o5/DbDxobP0HnGPgpRz2Ej77aL7TZT3DSw13fqUTj8J4mMnqa7WA==}
|
||||
|
|
@ -4880,9 +4880,6 @@ packages:
|
|||
lodash-es@4.17.21:
|
||||
resolution: {integrity: sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==}
|
||||
|
||||
lodash._reinterpolate@3.0.0:
|
||||
resolution: {integrity: sha512-xYHt68QRoYGjeeM/XOE1uJtvXQAgvszfBhjV4yvsQH0u2i9I6cI6c6/eG4Hh3UAOVn0y/xAXwmTzEay49Q//HA==}
|
||||
|
||||
lodash.camelcase@4.3.0:
|
||||
resolution: {integrity: sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==}
|
||||
|
||||
|
|
@ -4916,12 +4913,6 @@ packages:
|
|||
lodash.startcase@4.4.0:
|
||||
resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==}
|
||||
|
||||
lodash.template@4.5.0:
|
||||
resolution: {integrity: sha512-84vYFxIkmidUiFxidA/KjjH9pAycqW+h980j7Fuz5qxRtO9pgB7MDFTdys1N7A5mcucRiDyEq4fusljItR1T/A==}
|
||||
|
||||
lodash.templatesettings@4.2.0:
|
||||
resolution: {integrity: sha512-stgLz+i3Aa9mZgnjr/O+v9ruKZsPsndy7qPZOchbqk2cnTU1ZaldKK+v7m54WoKIyxiuMZTKT2H81F8BeAc3ZQ==}
|
||||
|
||||
lodash.uniq@4.5.0:
|
||||
resolution: {integrity: sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==}
|
||||
|
||||
|
|
@ -9422,7 +9413,7 @@ snapshots:
|
|||
|
||||
'@types/linkify-it@3.0.5': {}
|
||||
|
||||
'@types/lodash.template@4.5.3':
|
||||
'@types/lodash-es@4.17.12':
|
||||
dependencies:
|
||||
'@types/lodash': 4.17.0
|
||||
|
||||
|
|
@ -12785,8 +12776,6 @@ snapshots:
|
|||
|
||||
lodash-es@4.17.21: {}
|
||||
|
||||
lodash._reinterpolate@3.0.0: {}
|
||||
|
||||
lodash.camelcase@4.3.0: {}
|
||||
|
||||
lodash.defaults@4.2.0: {}
|
||||
|
|
@ -12809,15 +12798,6 @@ snapshots:
|
|||
|
||||
lodash.startcase@4.4.0: {}
|
||||
|
||||
lodash.template@4.5.0:
|
||||
dependencies:
|
||||
lodash._reinterpolate: 3.0.0
|
||||
lodash.templatesettings: 4.2.0
|
||||
|
||||
lodash.templatesettings@4.2.0:
|
||||
dependencies:
|
||||
lodash._reinterpolate: 3.0.0
|
||||
|
||||
lodash.uniq@4.5.0: {}
|
||||
|
||||
lodash.upperfirst@4.3.1: {}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user