form-custom-test 3.0.10

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 ADDED
@@ -0,0 +1,179 @@
1
+ # Variant Form 3 For Vue 3.x
2
+ #### 一款高效的Vue 3低代码表单,可视化设计,一键生成源码,享受更多摸鱼时间。
3
+
4
+ ![image](https://ks3-cn-beijing.ksyuncs.com/vform-static/img/vform_demo.gif)
5
+
6
+ <br/>
7
+
8
+ ### 立即体验VForm 3
9
+ [在线Demo](http://120.92.142.115:81/vform3/)
10
+
11
+ ### 🎉🎉<mark>基于VForm3的全栈低代码平台已发布</mark>🎉🎉
12
+ ![meta_low_code](https://vform666.com/mele.png)
13
+ <br/>
14
+ [美乐低代码——立即进入](https://melecode.com/) (私有部署、开箱即用️,已开源✌✌)️
15
+
16
+ ### 立即体验VForm 3 Pro高级版(提供商业支持)
17
+ [VForm 3 Pro Demo](https://www.vform666.com/pro/)
18
+
19
+ ### 视频教程集合:
20
+ [B站观看](https://space.bilibili.com/626932375)
21
+
22
+ ### 适合Vue 2的版本看这里
23
+ [点此查看](https://gitee.com/vdpadmin/variant-form)
24
+
25
+ ### 友情链接
26
+
27
+ [Fantastic-admin](https://hooray.gitee.io/fantastic-admin/) —— 一款开箱即用的 Vue 中后台管理系统框架(支持Vue2/Vue3)
28
+
29
+ ### 功能一览
30
+ ```
31
+ > 拖拽式可视化表单设计;
32
+ > 支持PC、Pad、H5三种布局;
33
+ > 支持运行时动态加载表单;
34
+ > 支持表单复杂交互控制;
35
+ > 支持自定义CSS样式;
36
+ > 支持自定义校验逻辑;
37
+ > 支持国际化多语言;
38
+ > 可导出Vue组件、HTML源码;
39
+ > 可导出Vue的SFC单文件组件;
40
+ > 支持开发自定义组件;
41
+ > 支持响应式自适应布局;
42
+ > 支持VS Code插件;
43
+ > 更多功能等你探究...;
44
+ ```
45
+
46
+ ### 安装依赖
47
+ ```
48
+ npm install --registry=https://registry.npmmirror.com
49
+ ```
50
+
51
+ ### 开发调试
52
+ ```
53
+ npm run serve
54
+ ```
55
+
56
+ ### 生产打包
57
+ ```
58
+ npm run build
59
+ ```
60
+
61
+ ### 表单设计器 + 表单渲染器打包
62
+ ```
63
+ npm run lib
64
+ ```
65
+
66
+ ### 表单渲染器打包
67
+ ```
68
+ npm run lib-render
69
+ ```
70
+
71
+ ### 浏览器兼容性
72
+ ```Chrome(及同内核的浏览器如QQ浏览器、360浏览器等等),Firefox,Safari```
73
+
74
+ <br/>
75
+
76
+ ### 跟Vue 3.x项目集成
77
+
78
+ <br/>
79
+
80
+ #### 1. 安装包
81
+ ```bash
82
+ npm i vform3-builds
83
+ ```
84
+
85
+ ```bash
86
+ yarn add vform3-builds
87
+ ```
88
+
89
+ <br/>
90
+
91
+ #### 2. 引入并全局注册VForm 3组件
92
+ ```
93
+ import { createApp } from 'vue'
94
+ import App from './App.vue'
95
+
96
+ import ElementPlus from 'element-plus' //引入element-plus库
97
+ import 'element-plus/dist/index.css' //引入element-plus样式
98
+
99
+ import VForm3 from 'vform3-builds' //引入VForm 3库
100
+ import 'vform3-builds/dist/designer.style.css' //引入VForm3样式
101
+
102
+ const app = createApp(App)
103
+ app.use(ElementPlus) //全局注册element-plus
104
+ app.use(VForm3) //全局注册VForm 3(同时注册了v-form-designer和v-form-render组件)
105
+
106
+ app.mount('#app')
107
+ ```
108
+
109
+ <br/>
110
+
111
+ #### 3. 在Vue 3.x模板中使用表单设计器组件
112
+ ```bash
113
+ <template>
114
+ <v-form-designer ref="vfdRef"></v-form-designer>
115
+ </template>
116
+
117
+ <script setup>
118
+ const vfdRef = ref(null)
119
+ </script>
120
+
121
+ <style lang="scss">
122
+ body {
123
+ margin: 0; /* 如果页面出现垂直滚动条,则加入此行CSS以消除之 */
124
+ }
125
+ </style>
126
+ ```
127
+
128
+ <br/>
129
+
130
+ #### 4. 在Vue 3.x模板中使用表单渲染器组件
131
+ ```html
132
+ <template>
133
+ <div>
134
+ <v-form-render :form-json="formJson" :form-data="formData" :option-data="optionData" ref="vFormRef">
135
+ </v-form-render>
136
+ <el-button type="primary" @click="submitForm">Submit</el-button>
137
+ </div>
138
+ </template>
139
+ <script setup>
140
+ import { ref, reactive } from 'vue'
141
+ import { ElMessage } from 'element-plus'
142
+
143
+ const formJson = reactive({"widgetList":[],"formConfig":{"modelName":"formData","refName":"vForm","rulesName":"rules","labelWidth":80,"labelPosition":"left","size":"","labelAlign":"label-left-align","cssCode":"","customClass":"","functions":"","layoutType":"PC","jsonVersion":3,"onFormCreated":"","onFormMounted":"","onFormDataChange":""}})
144
+ const formData = reactive({})
145
+ const optionData = reactive({})
146
+ const vFormRef = ref(null)
147
+
148
+ const submitForm = () => {
149
+ vFormRef.value.getFormData().then(formData => {
150
+ // Form Validation OK
151
+ alert( JSON.stringify(formData) )
152
+ }).catch(error => {
153
+ // Form Validation failed
154
+ ElMessage.error(error)
155
+ })
156
+ }
157
+ </script>
158
+ ```
159
+
160
+ <br/>
161
+
162
+ ### 资源链接
163
+ <hr>
164
+
165
+ 文档官网:<a href="https://www.vform666.com/" target="_blank">https://www.vform666.com/</a>
166
+
167
+ 在线演示:<a href="http://120.92.142.115:81/vform3/" target="_blank">http://120.92.142.115:81/vform3/</a>
168
+
169
+ Github仓库:<a href="https://github.com/vform666/variant-form3-vite" target="_blank">https://github.com/vform666/variant-form3-vite</a>
170
+
171
+ Gitee仓库:<a href="https://gitee.com/vdpadmin/variant-form3-vite" target="_blank">https://gitee.com/vdpadmin/variant-form3-vite</a>
172
+
173
+ 更新日志:<a href="https://www.vform666.com/changelog.html" target="_blank">https://www.vform666.com/changelog.html</a>
174
+
175
+ 订阅Pro版:<a href="https://www.vform666.com/pro/" target="_blank">https://www.vform666.com/pro/</a>
176
+
177
+ 技术交流群:扫如下二维码加群
178
+
179
+ ![image](https://vform2022.ks3-cn-beijing.ksyuncs.com/vchat_qrcode.png)
Binary file