autoforma 1.1.5 → 1.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +164 -159
- package/dist/components/AutoForm/AutoForm.types.d.ts +4 -5
- package/dist/components/AutoForm/context/FormContext.d.ts +1 -1
- package/dist/fields/renderers/CheckBoxFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/DateFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/DateTimeFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/NumberFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/SelectFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/SwitchFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/TagsFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/TextFieldRenderer.d.ts +2 -3
- package/dist/fields/renderers/TimeFieldRenderer.d.ts +2 -3
- package/dist/fields/types.d.ts +1 -4
- package/dist/index.cjs.js +4 -176
- package/dist/index.es.js +4077 -22322
- package/dist/stories/Basic.stories.d.ts +6 -0
- package/dist/stories/CustomFieldType.stories.d.ts +6 -0
- package/dist/stories/CustomizeField.stories.d.ts +6 -0
- package/dist/stories/DynamicSchema.stories.d.ts +6 -0
- package/dist/stories/Fields.stories.d.ts +11 -7
- package/dist/stories/Layouts.stories.d.ts +8 -0
- package/dist/stories/ReadOnly.stories.d.ts +6 -0
- package/dist/stories/Validation.stories.d.ts +7 -0
- package/dist/theme.d.ts +1 -1
- package/package.json +9 -16
- package/dist/fields/renderers/RichTextEditorFieldRenderer.d.ts +0 -4
- package/dist/stories/AutoForm.stories.d.ts +0 -9
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const Minimal: Story;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const CustomColorField: Story;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const CustomizeTextField: Story;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const ToggleFieldVisibility: Story;
|
|
@@ -1,12 +1,16 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
1
2
|
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { default as AutoForm } from '../components/AutoForm';
|
|
3
3
|
declare const meta: Meta<typeof AutoForm>;
|
|
4
4
|
export default meta;
|
|
5
5
|
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
-
export declare const
|
|
7
|
-
export declare const
|
|
8
|
-
export declare const
|
|
9
|
-
export declare const
|
|
10
|
-
export declare const
|
|
11
|
-
export declare const
|
|
6
|
+
export declare const Text: Story;
|
|
7
|
+
export declare const Number: Story;
|
|
8
|
+
export declare const Checkbox: Story;
|
|
9
|
+
export declare const Switch: Story;
|
|
10
|
+
export declare const Date: Story;
|
|
11
|
+
export declare const Time: Story;
|
|
12
|
+
export declare const DateTime: Story;
|
|
13
|
+
export declare const Select: Story;
|
|
14
|
+
export declare const Tags: Story;
|
|
12
15
|
export declare const ObjectField: Story;
|
|
16
|
+
export declare const ArrayField: Story;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const GridLayout: Story;
|
|
7
|
+
export declare const VerticalLayout: Story;
|
|
8
|
+
export declare const HorizontalLayout: Story;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const ReadOnlyForm: Story;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { default as AutoForm } from '../components/AutoForm/AutoForm';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
+
export default meta;
|
|
5
|
+
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
+
export declare const RequiredFields: Story;
|
|
7
|
+
export declare const InitialValuesWithValidation: Story;
|
package/dist/theme.d.ts
CHANGED
|
@@ -119,7 +119,7 @@ export declare const theme: {
|
|
|
119
119
|
xl?: string | undefined;
|
|
120
120
|
} | undefined;
|
|
121
121
|
respectReducedMotion?: boolean | undefined;
|
|
122
|
-
cursorType?: "
|
|
122
|
+
cursorType?: "pointer" | "default" | undefined;
|
|
123
123
|
defaultGradient?: {
|
|
124
124
|
from?: string | undefined;
|
|
125
125
|
to?: string | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "autoforma",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.7",
|
|
4
4
|
"description": "AutoForma is a dynamic form builder based on Mantine and React",
|
|
5
5
|
"main": "./dist/index.cjs.js",
|
|
6
6
|
"module": "./dist/index.es.js",
|
|
@@ -48,34 +48,28 @@
|
|
|
48
48
|
"vitest": "vitest run",
|
|
49
49
|
"vitest:watch": "vitest",
|
|
50
50
|
"test": "npm run typecheck && npm run prettier && npm run lint && npm run vitest && npm run build",
|
|
51
|
+
"dev": "vite --config vite.config.dev.ts",
|
|
51
52
|
"storybook": "storybook dev -p 6006",
|
|
52
53
|
"storybook:build": "storybook build",
|
|
53
|
-
"predeploy": "npm run build
|
|
54
|
-
"deploy-storybook": "gh-pages -d storybook-static"
|
|
55
|
-
"dev": "vite --config vite.config.dev.ts"
|
|
54
|
+
"predeploy": "npm run storybook:build",
|
|
55
|
+
"deploy-storybook": "gh-pages -d storybook-static"
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"@mantine/dates": "^8.3.2",
|
|
59
59
|
"@mantine/form": "^8.3.2",
|
|
60
60
|
"@mantine/hooks": "^8.3.2",
|
|
61
|
-
"@mantine/tiptap": "^8.3.2",
|
|
62
|
-
"@tiptap/extension-highlight": "^3.6.6",
|
|
63
|
-
"@tiptap/extension-link": "^3.6.6",
|
|
64
|
-
"@tiptap/extension-subscript": "^3.6.6",
|
|
65
|
-
"@tiptap/extension-superscript": "^3.6.6",
|
|
66
|
-
"@tiptap/extension-text-align": "^3.6.6",
|
|
67
|
-
"@tiptap/extension-underline": "^3.6.6",
|
|
68
|
-
"@tiptap/pm": "^3.6.6",
|
|
69
|
-
"@tiptap/react": "^3.6.6",
|
|
70
|
-
"@tiptap/starter-kit": "^3.6.6",
|
|
71
61
|
"dayjs": "^1.11.13",
|
|
72
|
-
"react-router-dom": "^7.4.0"
|
|
62
|
+
"react-router-dom": "^7.4.0",
|
|
63
|
+
"storybook": "^10.1.10"
|
|
73
64
|
},
|
|
74
65
|
"devDependencies": {
|
|
66
|
+
"@storybook/addon-docs": "^10.1.10",
|
|
67
|
+
"@storybook/react-vite": "^10.1.10",
|
|
75
68
|
"@types/node": "^24.10.1",
|
|
76
69
|
"@types/react": "^19.1.0",
|
|
77
70
|
"@types/react-dom": "^19.1.0",
|
|
78
71
|
"@vitejs/plugin-react": "^4.3.4",
|
|
72
|
+
"gh-pages": "^6.3.0",
|
|
79
73
|
"postcss-preset-mantine": "^1.18.0",
|
|
80
74
|
"typescript": "^5.8.2",
|
|
81
75
|
"vite": "^6.2.2",
|
|
@@ -87,7 +81,6 @@
|
|
|
87
81
|
"@mantine/dates": "^8.3.2",
|
|
88
82
|
"@mantine/form": "^8.3.2",
|
|
89
83
|
"@mantine/hooks": "^8.3.2",
|
|
90
|
-
"@mantine/tiptap": "^8.3.2",
|
|
91
84
|
"react": "^19.0.0",
|
|
92
85
|
"react-dom": "^19.0.0"
|
|
93
86
|
},
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { FieldRendererProps } from '../FieldRenderer/FieldRenderer.types';
|
|
2
|
-
type RichTextEditorFieldRendererProps<TValues extends Record<string, any> = Record<string, any>> = FieldRendererProps<TValues>;
|
|
3
|
-
export declare function RichTextEditorFieldRenderer<TValues extends Record<string, any> = Record<string, any>>({ field, form }: RichTextEditorFieldRendererProps<TValues>): import("react/jsx-runtime").JSX.Element;
|
|
4
|
-
export default RichTextEditorFieldRenderer;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { default as AutoForm } from '../components/AutoForm';
|
|
2
|
-
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
-
declare const meta: Meta<typeof AutoForm>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof AutoForm>;
|
|
6
|
-
export declare const Standard: Story;
|
|
7
|
-
export declare const ReadOnly: Story;
|
|
8
|
-
export declare const FormValidation: Story;
|
|
9
|
-
export declare const CustomizedForm: Story;
|