@bsgoal/common 1.9.0 → 1.9.1
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/dist/index.mjs +12 -3
- package/dist/index.mjs.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/components/bsgoal-base-form/demo.vue +2 -2
- package/src/components/bsgoal-base-form/index.vue +16 -2
- package/src/directives/directiveBase.js +3 -2
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Author: canlong.shen
|
|
3
3
|
* @Date: 2023-04-10 15:00:00
|
|
4
4
|
* @LastEditors: canlong.shen
|
|
5
|
-
* @LastEditTime: 2023-05-22
|
|
5
|
+
* @LastEditTime: 2023-05-22 15:15:08
|
|
6
6
|
* @FilePath: \common\src\components\bsgoal-base-form\demo.vue
|
|
7
7
|
* @Description: 表单公共组件演示组件
|
|
8
8
|
*
|
|
@@ -34,7 +34,7 @@ const bindModel = ref({ prop1: '111', prop99: 1 ,prop101:'否'})
|
|
|
34
34
|
// 配置项
|
|
35
35
|
const configOptions = ref([
|
|
36
36
|
{
|
|
37
|
-
label: '
|
|
37
|
+
label: 'prop1011111111111111',
|
|
38
38
|
prop: 'prop101',
|
|
39
39
|
type: EnumType.CHECKBOX_SINGLE,
|
|
40
40
|
range: [
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Author: canlong.shen
|
|
3
3
|
* @Date: 2023-04-17 11:44:29
|
|
4
4
|
* @LastEditors: canlong.shen
|
|
5
|
-
* @LastEditTime: 2023-05-22
|
|
5
|
+
* @LastEditTime: 2023-05-22 15:37:49
|
|
6
6
|
* @FilePath: \common\src\components\bsgoal-base-form\index.vue
|
|
7
7
|
* @Description: 表单公共组件
|
|
8
8
|
*
|
|
@@ -87,6 +87,14 @@ const props = defineProps({
|
|
|
87
87
|
bindModel: {
|
|
88
88
|
type: [Object],
|
|
89
89
|
default: () => ({})
|
|
90
|
+
},
|
|
91
|
+
/**
|
|
92
|
+
* label 位置
|
|
93
|
+
*/
|
|
94
|
+
labelPosition: {
|
|
95
|
+
type: [String],
|
|
96
|
+
default: 'right',
|
|
97
|
+
validator: (v) => ['left', 'rightn', 'top'].includes(v)
|
|
90
98
|
}
|
|
91
99
|
})
|
|
92
100
|
|
|
@@ -343,7 +351,13 @@ defineExpose({
|
|
|
343
351
|
<div class="bsgoal-base-form">
|
|
344
352
|
<div class="base_form">
|
|
345
353
|
<!-- / 表单内容 -->
|
|
346
|
-
<el-form
|
|
354
|
+
<el-form
|
|
355
|
+
ref="EL_FORM_REF"
|
|
356
|
+
label-suffix=":"
|
|
357
|
+
:label-position="labelPosition"
|
|
358
|
+
:model="model"
|
|
359
|
+
v-align
|
|
360
|
+
>
|
|
347
361
|
<el-row>
|
|
348
362
|
<template
|
|
349
363
|
v-for="(
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Author: canlong.shen
|
|
3
3
|
* @Date: 2023-04-14 10:50:11
|
|
4
4
|
* @LastEditors: canlong.shen
|
|
5
|
-
* @LastEditTime: 2023-
|
|
5
|
+
* @LastEditTime: 2023-05-22 15:34:10
|
|
6
6
|
* @FilePath: \common\src\directives\directiveBase.js
|
|
7
7
|
* @Description: 常用的公共指令
|
|
8
8
|
*
|
|
@@ -62,7 +62,7 @@ const autoAlign = (el) => {
|
|
|
62
62
|
sortingLabelEl()
|
|
63
63
|
calcLabelWidth(labelElLeftList)
|
|
64
64
|
calcLabelWidth(labelElRightList)
|
|
65
|
-
},
|
|
65
|
+
}, 500)
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
export default {
|
|
@@ -71,6 +71,7 @@ export default {
|
|
|
71
71
|
*/
|
|
72
72
|
align: {
|
|
73
73
|
created(el) {
|
|
74
|
+
console.log('el',el);
|
|
74
75
|
window.addEventListener('resize', () => {
|
|
75
76
|
autoAlign(el)
|
|
76
77
|
})
|