Skip to content

Commit f8c5505

Browse files
committed
Publish
1 parent 1db1baa commit f8c5505

File tree

4 files changed

+16
-15
lines changed

4 files changed

+16
-15
lines changed

.changeset/lemon-pumpkins-walk.md

-13
This file was deleted.

packages/ant/CHANGELOG.md

+14
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# @autoform/ant
22

3+
## 1.2.0
4+
5+
### Minor Changes
6+
7+
- 1db1baa: ### What the change is
8+
9+
- **Component:** Simplified logic, removed unnecessary context, and fixed date component bugs.
10+
- **React Integration:** Restored structure while keeping improvements; updated `AutoFormProps` to allow custom attributes.
11+
- **Testing:** Added Cypress tests (`ant-zod`) for validation.
12+
13+
### Why the change was made
14+
15+
- These changes refine implementation and fix existing issues.
16+
317
## 1.1.0
418

519
### Minor Changes

packages/ant/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@autoform/ant",
3-
"version": "1.1.0",
3+
"version": "1.2.0",
44
"main": "./dist/index.js",
55
"module": "./dist/index.mjs",
66
"types": "./dist/index.d.ts",

packages/shadcn/registry/autoform.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
{
6666
"path": "autoform/components/SelectField.tsx",
6767
"target": "components/ui/autoform/components/SelectField.tsx",
68-
"content": "import {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from \"@/components/ui/select\";\nimport { AutoFormFieldProps } from \"@autoform/react\";\nimport React from \"react\";\n\nexport const SelectField: React.FC<AutoFormFieldProps> = ({\n field,\n inputProps,\n error,\n id,\n}) => {\n const { key, ...props } = inputProps;\n\n return (\n <Select {...props}>\n <SelectTrigger id={id} className={error ? \"border-destructive\" : \"\"}>\n <SelectValue placeholder=\"Select an option\" />\n </SelectTrigger>\n <SelectContent>\n {(field.options || []).map(([key, label]) => (\n <SelectItem key={key} value={key}>\n {label}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n );\n};\n",
68+
"content": "import {\n Select,\n SelectContent,\n SelectItem,\n SelectTrigger,\n SelectValue,\n} from \"@/components/ui/select\";\nimport { AutoFormFieldProps } from \"@autoform/react\";\nimport React from \"react\";\n\nexport const SelectField: React.FC<AutoFormFieldProps> = ({\n field,\n inputProps,\n error,\n id,\n}) => {\n const { key, ...props } = inputProps;\n\n return (\n <Select\n {...props}\n onValueChange={(value) => {\n const syntheticEvent = {\n target: {\n value,\n name: field.key,\n },\n } as React.ChangeEvent<HTMLInputElement>;\n props.onChange(syntheticEvent);\n }}\n defaultValue={field.default}\n >\n <SelectTrigger id={id} className={error ? \"border-destructive\" : \"\"}>\n <SelectValue placeholder=\"Select an option\" />\n </SelectTrigger>\n <SelectContent>\n {(field.options || []).map(([key, label]) => (\n <SelectItem key={key} value={key}>\n {label}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n );\n};\n",
6969
"type": "registry:ui"
7070
},
7171
{

0 commit comments

Comments
 (0)