woodao-pc-ui 0.0.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/README.md +24 -0
- package/babel.config.js +5 -0
- package/jsconfig.json +19 -0
- package/npm_package_error.log +169 -0
- package/npm_package_error2.log +169 -0
- package/npm_package_error3.log +16 -0
- package/package.json +54 -0
- package/public/favicon.ico +0 -0
- package/public/index.html +17 -0
- package/src/App.vue +28 -0
- package/src/assets/logo.png +0 -0
- package/src/main.js +4 -0
- package/src/package/form/baseForm.vue +347 -0
- package/src/package/form/baseFormItem.vue +352 -0
- package/src/package/form/formRender.tsx +16 -0
- package/src/package/form/index.ts +27 -0
- package/src/package/form/selectBySystemCode.vue +235 -0
- package/src/package/index.js +12 -0
- package/src/package/pig-button/index.vue +25 -0
- package/tsconfig.json +19 -0
- package/vue.config.js +4 -0
- package/woodao-pc-ui/demo.html +1 -0
- package/woodao-pc-ui/woodao-pc-ui.common.js +168 -0
- package/woodao-pc-ui/woodao-pc-ui.common.js.map +1 -0
- package/woodao-pc-ui/woodao-pc-ui.css +1 -0
- package/woodao-pc-ui/woodao-pc-ui.umd.js +186 -0
- package/woodao-pc-ui/woodao-pc-ui.umd.js.map +1 -0
- package/woodao-pc-ui/woodao-pc-ui.umd.min.js +2 -0
- package/woodao-pc-ui/woodao-pc-ui.umd.min.js.map +1 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ElInput } from "element-plus";
|
|
2
|
+
import { Ref, VNode } from "vue";
|
|
3
|
+
|
|
4
|
+
type RenderProps = {
|
|
5
|
+
render: (formItem: FormItem) => VNode;
|
|
6
|
+
formItem: FormItem;
|
|
7
|
+
[key: string]: any;
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export type FormRenderItem = FormItem & {
|
|
11
|
+
render?: (formItem: FormItem) => VNode;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export default function FormRender(props: RenderProps) {
|
|
15
|
+
return props.render(props.formItem || props["form-item"]);
|
|
16
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { App } from "vue";
|
|
2
|
+
import FormRender from "./formRender";
|
|
3
|
+
|
|
4
|
+
function getComponentName(key: string) {
|
|
5
|
+
if (!key) {
|
|
6
|
+
return "";
|
|
7
|
+
}
|
|
8
|
+
const paths = key.split("/");
|
|
9
|
+
const name = paths
|
|
10
|
+
.filter((it) => !!it && it !== ".")
|
|
11
|
+
.reverse()
|
|
12
|
+
.find((it) => it !== "index.vue" && it !== "index.ts" && it !== "index.js")
|
|
13
|
+
?.replace(".vue", "");
|
|
14
|
+
return name || "";
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export function registerComponents(app: App): void {
|
|
18
|
+
const components = require.context("./", true, /\.vue$/);
|
|
19
|
+
components.keys().forEach((it: string) => {
|
|
20
|
+
const component = components(it);
|
|
21
|
+
app.component(
|
|
22
|
+
component.default.name || getComponentName(it),
|
|
23
|
+
component.default
|
|
24
|
+
);
|
|
25
|
+
});
|
|
26
|
+
app.component("formRender", FormRender);
|
|
27
|
+
}
|
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<el-select
|
|
3
|
+
style="width: 100%"
|
|
4
|
+
:popper-append-to-body="isTransfer"
|
|
5
|
+
:multiple="multiple"
|
|
6
|
+
:size="size || 'small'"
|
|
7
|
+
:filterable="filterable"
|
|
8
|
+
:clearable="clearable"
|
|
9
|
+
v-model="item.value"
|
|
10
|
+
:disabled="disabled||readonly"
|
|
11
|
+
@change="change"
|
|
12
|
+
@visible-change="getData"
|
|
13
|
+
ref="selectBySystem"
|
|
14
|
+
:placeholder="`请选择${bindLabel}`"
|
|
15
|
+
|
|
16
|
+
>
|
|
17
|
+
<el-option
|
|
18
|
+
v-for="item in selectList"
|
|
19
|
+
:value="item.keyName"
|
|
20
|
+
:key="item.keyCode"
|
|
21
|
+
:label="item.keyName"
|
|
22
|
+
>
|
|
23
|
+
|
|
24
|
+
<div
|
|
25
|
+
style="max-width: 500px"
|
|
26
|
+
class="custom-option"
|
|
27
|
+
:title="item.keyName"
|
|
28
|
+
>
|
|
29
|
+
{{ item.keyName }}
|
|
30
|
+
</div>
|
|
31
|
+
|
|
32
|
+
</el-option>
|
|
33
|
+
</el-select>
|
|
34
|
+
</template>
|
|
35
|
+
|
|
36
|
+
<script>
|
|
37
|
+
import QueryCommand from "@/utils/queryCommand";
|
|
38
|
+
|
|
39
|
+
export default {
|
|
40
|
+
name: "selectBySystemCode",
|
|
41
|
+
data() {
|
|
42
|
+
return {
|
|
43
|
+
|
|
44
|
+
selectList: []
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
watch: {
|
|
48
|
+
sysCode(val) {
|
|
49
|
+
if (val != '' && val != undefined && val != null) {
|
|
50
|
+
|
|
51
|
+
this.getSelectData()
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
keyName(val) {
|
|
55
|
+
if (val != '' && val != undefined && val != null) {
|
|
56
|
+
if (this.moreSel) {
|
|
57
|
+
this.item.value = []
|
|
58
|
+
this.$forceUpdate()
|
|
59
|
+
}else if(this.isClear) {
|
|
60
|
+
|
|
61
|
+
console.log(this.isClear,'isClear')
|
|
62
|
+
this.item.value =''
|
|
63
|
+
}
|
|
64
|
+
this.getSelectDataByKeyName()
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
created() {
|
|
69
|
+
|
|
70
|
+
},
|
|
71
|
+
mounted() {
|
|
72
|
+
this.$nextTick(() => {
|
|
73
|
+
this.getData()
|
|
74
|
+
})
|
|
75
|
+
},
|
|
76
|
+
methods: {
|
|
77
|
+
getData() {
|
|
78
|
+
if (this.selectList.length == 0) {
|
|
79
|
+
if (this.sysCode != '' && this.sysCode != undefined && this.sysCode != null) {
|
|
80
|
+
this.getSelectData()
|
|
81
|
+
}
|
|
82
|
+
if (this.keyName != '' && this.keyName != undefined && this.keyName != null) {
|
|
83
|
+
this.getSelectDataByKeyName()
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
//根据dictCode 获取数据
|
|
88
|
+
getSelectData() {
|
|
89
|
+
let params = {};
|
|
90
|
+
let page = null;
|
|
91
|
+
let queryCommand = new QueryCommand({
|
|
92
|
+
url: SysConfigUtils.niftyUrl + '/pub/sys_dict/item/list/' + this.sysCode,
|
|
93
|
+
});
|
|
94
|
+
//执行查询操作
|
|
95
|
+
queryCommand.executeQuery({
|
|
96
|
+
page, params, successFun: (backData) => {
|
|
97
|
+
console.log(backData, 'backData')
|
|
98
|
+
this.selectList = backData
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
},
|
|
102
|
+
|
|
103
|
+
//根据KeyName 获取数据
|
|
104
|
+
getSelectDataByKeyName() {
|
|
105
|
+
console.log(SysConfigUtils.niftyUrl + '/pub/sys_dict/item/list_by_parent/'+this.keyName,'url')
|
|
106
|
+
let params = {};
|
|
107
|
+
let page = null;
|
|
108
|
+
let queryCommand = new QueryCommand({
|
|
109
|
+
url: SysConfigUtils.niftyUrl + '/pub/sys_dict/item/list_by_parent/'+this.keyName,
|
|
110
|
+
});
|
|
111
|
+
//执行查询操作
|
|
112
|
+
queryCommand.executeQuery({
|
|
113
|
+
page, params, successFun: (backData) => {
|
|
114
|
+
console.log(backData, 'keyName')
|
|
115
|
+
|
|
116
|
+
this.selectList = backData
|
|
117
|
+
this.$forceUpdate()
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
},
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
change(val) {
|
|
124
|
+
let oldVal = this.$refs.selectBySystem.value
|
|
125
|
+
//把选择的那一项传过去
|
|
126
|
+
let bindItem = {}
|
|
127
|
+
this.selectList.forEach((item, index) => {
|
|
128
|
+
if (val === item.keyCode) {
|
|
129
|
+
bindItem = item
|
|
130
|
+
}
|
|
131
|
+
})
|
|
132
|
+
let changeIndex = this.changeIndex
|
|
133
|
+
if (this.moreSel && (val.length == 0) && (oldVal[0] != undefined)) {
|
|
134
|
+
this.item.value = oldVal.split(",")
|
|
135
|
+
this.$forceUpdate()
|
|
136
|
+
}
|
|
137
|
+
this.$emit('selectChange', bindItem)
|
|
138
|
+
},
|
|
139
|
+
},
|
|
140
|
+
props: {
|
|
141
|
+
isClear:{
|
|
142
|
+
type: Boolean,
|
|
143
|
+
default: true,
|
|
144
|
+
},
|
|
145
|
+
size: {
|
|
146
|
+
type: String,
|
|
147
|
+
default: "default",
|
|
148
|
+
},
|
|
149
|
+
changeIndex: {
|
|
150
|
+
type: Number,
|
|
151
|
+
default: 0,
|
|
152
|
+
},
|
|
153
|
+
isTransfer: {
|
|
154
|
+
type: Boolean,
|
|
155
|
+
default: true,
|
|
156
|
+
},
|
|
157
|
+
clearable: {
|
|
158
|
+
type: Boolean,
|
|
159
|
+
default: true,
|
|
160
|
+
},
|
|
161
|
+
readonly: {
|
|
162
|
+
type: Boolean,
|
|
163
|
+
default: false,
|
|
164
|
+
},
|
|
165
|
+
multiple: {
|
|
166
|
+
type: Boolean,
|
|
167
|
+
default: false
|
|
168
|
+
},
|
|
169
|
+
filterable: {
|
|
170
|
+
type: Boolean,
|
|
171
|
+
default: true
|
|
172
|
+
},
|
|
173
|
+
|
|
174
|
+
item: {
|
|
175
|
+
type: Object,
|
|
176
|
+
default: () => {
|
|
177
|
+
return {
|
|
178
|
+
id: ''
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
},
|
|
182
|
+
bindValue: {
|
|
183
|
+
type: String,
|
|
184
|
+
default: ''
|
|
185
|
+
},
|
|
186
|
+
bindLabel: {
|
|
187
|
+
type: String,
|
|
188
|
+
default: ''
|
|
189
|
+
},
|
|
190
|
+
sysCode: {
|
|
191
|
+
type: String,
|
|
192
|
+
default: ''
|
|
193
|
+
},
|
|
194
|
+
keyName: {
|
|
195
|
+
type: String,
|
|
196
|
+
default: ''
|
|
197
|
+
},
|
|
198
|
+
|
|
199
|
+
disabled: {
|
|
200
|
+
type: Boolean,
|
|
201
|
+
default: false,
|
|
202
|
+
},
|
|
203
|
+
filterList: {
|
|
204
|
+
type: Array,
|
|
205
|
+
default: () => {
|
|
206
|
+
return []
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
},
|
|
210
|
+
}
|
|
211
|
+
</script>
|
|
212
|
+
|
|
213
|
+
<style scoped>
|
|
214
|
+
/* 覆盖 el-select 下拉选项的默认样式 */
|
|
215
|
+
::v-deep .el-select-dropdown__item {
|
|
216
|
+
padding: 8px 20px !important; /* 调整内边距 */
|
|
217
|
+
max-width: 500px !important; /* 设置最大宽度 */
|
|
218
|
+
white-space: normal !important; /* 允许换行 */
|
|
219
|
+
word-break: break-word !important; /* 强制断词换行 */
|
|
220
|
+
overflow: hidden !important; /* 隐藏溢出内容 */
|
|
221
|
+
text-overflow: ellipsis !important; /* 显示省略号 */
|
|
222
|
+
display: -webkit-box !important; /* 使用弹性盒子 */
|
|
223
|
+
-webkit-line-clamp: 2 !important; /* 限制显示2行 */
|
|
224
|
+
-webkit-box-orient: vertical !important;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
/* 鼠标悬停时显示完整内容 */
|
|
228
|
+
::v-deep .el-select-dropdown__item:hover {
|
|
229
|
+
overflow: visible !important; /* 显示全部内容 */
|
|
230
|
+
white-space: normal !important;
|
|
231
|
+
-webkit-line-clamp: unset !important;
|
|
232
|
+
padding: 12px 20px !important; /* 调整悬停时的内边距 */
|
|
233
|
+
}
|
|
234
|
+
</style>
|
|
235
|
+
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import PigButton from "./pig-button/index.vue"; // 引入封装好的组件
|
|
2
|
+
// import BaseForm from "./form/baseForm.vue"; // 引入封装好的组件
|
|
3
|
+
const coms = [PigButton]; // 将来如果有其他组件,都可以写到这个数组里
|
|
4
|
+
|
|
5
|
+
// 批量注册组件
|
|
6
|
+
const install = function (Vue) {
|
|
7
|
+
coms.forEach((com) => {
|
|
8
|
+
Vue.component(com.name, com);
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export default install; // 这个方法以后再使用的时候可以被use调用
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
|
|
2
|
+
<template>
|
|
3
|
+
<div>
|
|
4
|
+
<button>我是测试按钮</button>
|
|
5
|
+
</div>
|
|
6
|
+
</template>
|
|
7
|
+
|
|
8
|
+
<script>
|
|
9
|
+
export default {
|
|
10
|
+
name: 'pig-button', //组件名
|
|
11
|
+
}
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
<style scoped>
|
|
15
|
+
button {
|
|
16
|
+
width: 100px;
|
|
17
|
+
height: 50px;
|
|
18
|
+
display: flex;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
border: none;
|
|
22
|
+
border-radius: 10px;
|
|
23
|
+
cursor: pointer;
|
|
24
|
+
}
|
|
25
|
+
</style>
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "esnext",
|
|
4
|
+
"module": "esnext",
|
|
5
|
+
"moduleResolution": "node",
|
|
6
|
+
"strict": true,
|
|
7
|
+
"jsx": "preserve",
|
|
8
|
+
"sourceMap": true,
|
|
9
|
+
"resolveJsonModule": true,
|
|
10
|
+
"esModuleInterop": true,
|
|
11
|
+
"lib": ["esnext", "dom"],
|
|
12
|
+
"baseUrl": ".",
|
|
13
|
+
"paths": {
|
|
14
|
+
"@/*": ["src/*"]
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"],
|
|
18
|
+
"exclude": ["node_modules"]
|
|
19
|
+
}
|
package/vue.config.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!doctype html><meta charset="utf-8"><title>woodao-pc-ui demo</title><script src="./woodao-pc-ui.umd.js"></script><link rel="stylesheet" href="./woodao-pc-ui.css"><script>console.log(woodao-pc-ui)</script>
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
/******/ (function() { // webpackBootstrap
|
|
2
|
+
/******/ "use strict";
|
|
3
|
+
/******/ var __webpack_modules__ = ({
|
|
4
|
+
|
|
5
|
+
/***/ 241:
|
|
6
|
+
/***/ (function(__unused_webpack_module, exports) {
|
|
7
|
+
|
|
8
|
+
var __webpack_unused_export__;
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
__webpack_unused_export__ = ({
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
// runtime helper for setting properties on components
|
|
15
|
+
// in a tree-shakable way
|
|
16
|
+
exports.A = (sfc, props) => {
|
|
17
|
+
const target = sfc.__vccOpts || sfc;
|
|
18
|
+
for (const [key, val] of props) {
|
|
19
|
+
target[key] = val;
|
|
20
|
+
}
|
|
21
|
+
return target;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
/***/ })
|
|
25
|
+
|
|
26
|
+
/******/ });
|
|
27
|
+
/************************************************************************/
|
|
28
|
+
/******/ // The module cache
|
|
29
|
+
/******/ var __webpack_module_cache__ = {};
|
|
30
|
+
/******/
|
|
31
|
+
/******/ // The require function
|
|
32
|
+
/******/ function __webpack_require__(moduleId) {
|
|
33
|
+
/******/ // Check if module is in cache
|
|
34
|
+
/******/ var cachedModule = __webpack_module_cache__[moduleId];
|
|
35
|
+
/******/ if (cachedModule !== undefined) {
|
|
36
|
+
/******/ return cachedModule.exports;
|
|
37
|
+
/******/ }
|
|
38
|
+
/******/ // Create a new module (and put it into the cache)
|
|
39
|
+
/******/ var module = __webpack_module_cache__[moduleId] = {
|
|
40
|
+
/******/ // no module.id needed
|
|
41
|
+
/******/ // no module.loaded needed
|
|
42
|
+
/******/ exports: {}
|
|
43
|
+
/******/ };
|
|
44
|
+
/******/
|
|
45
|
+
/******/ // Execute the module function
|
|
46
|
+
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
|
|
47
|
+
/******/
|
|
48
|
+
/******/ // Return the exports of the module
|
|
49
|
+
/******/ return module.exports;
|
|
50
|
+
/******/ }
|
|
51
|
+
/******/
|
|
52
|
+
/************************************************************************/
|
|
53
|
+
/******/ /* webpack/runtime/define property getters */
|
|
54
|
+
/******/ !function() {
|
|
55
|
+
/******/ // define getter functions for harmony exports
|
|
56
|
+
/******/ __webpack_require__.d = function(exports, definition) {
|
|
57
|
+
/******/ for(var key in definition) {
|
|
58
|
+
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
|
|
59
|
+
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
|
|
60
|
+
/******/ }
|
|
61
|
+
/******/ }
|
|
62
|
+
/******/ };
|
|
63
|
+
/******/ }();
|
|
64
|
+
/******/
|
|
65
|
+
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
|
66
|
+
/******/ !function() {
|
|
67
|
+
/******/ __webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }
|
|
68
|
+
/******/ }();
|
|
69
|
+
/******/
|
|
70
|
+
/******/ /* webpack/runtime/make namespace object */
|
|
71
|
+
/******/ !function() {
|
|
72
|
+
/******/ // define __esModule on exports
|
|
73
|
+
/******/ __webpack_require__.r = function(exports) {
|
|
74
|
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
|
75
|
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
76
|
+
/******/ }
|
|
77
|
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
|
78
|
+
/******/ };
|
|
79
|
+
/******/ }();
|
|
80
|
+
/******/
|
|
81
|
+
/******/ /* webpack/runtime/publicPath */
|
|
82
|
+
/******/ !function() {
|
|
83
|
+
/******/ __webpack_require__.p = "";
|
|
84
|
+
/******/ }();
|
|
85
|
+
/******/
|
|
86
|
+
/************************************************************************/
|
|
87
|
+
var __webpack_exports__ = {};
|
|
88
|
+
// ESM COMPAT FLAG
|
|
89
|
+
__webpack_require__.r(__webpack_exports__);
|
|
90
|
+
|
|
91
|
+
// EXPORTS
|
|
92
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
93
|
+
"default": function() { return /* binding */ entry_lib; }
|
|
94
|
+
});
|
|
95
|
+
|
|
96
|
+
;// ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
|
|
97
|
+
/* eslint-disable no-var */
|
|
98
|
+
// This file is imported into lib/wc client bundles.
|
|
99
|
+
|
|
100
|
+
if (typeof window !== 'undefined') {
|
|
101
|
+
var currentScript = window.document.currentScript
|
|
102
|
+
if (false) // removed by dead control flow
|
|
103
|
+
{ var getCurrentScript; }
|
|
104
|
+
|
|
105
|
+
var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
|
|
106
|
+
if (src) {
|
|
107
|
+
__webpack_require__.p = src[1] // eslint-disable-line
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// Indicate to webpack that this file can be concatenated
|
|
112
|
+
/* harmony default export */ var setPublicPath = (null);
|
|
113
|
+
|
|
114
|
+
;// external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
|
|
115
|
+
var external_commonjs_vue_commonjs2_vue_root_Vue_namespaceObject = require("vue");
|
|
116
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/package/pig-button/index.vue?vue&type=template&id=4717dde7&scoped=true
|
|
117
|
+
|
|
118
|
+
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
119
|
+
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_namespaceObject.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_namespaceObject.createElementBlock)("div", null, _cache[0] || (_cache[0] = [(0,external_commonjs_vue_commonjs2_vue_root_Vue_namespaceObject.createElementVNode)("button", null, "我是测试按钮", -1)]));
|
|
120
|
+
}
|
|
121
|
+
;// ./src/package/pig-button/index.vue?vue&type=template&id=4717dde7&scoped=true
|
|
122
|
+
|
|
123
|
+
;// ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/package/pig-button/index.vue?vue&type=script&lang=js
|
|
124
|
+
/* harmony default export */ var pig_buttonvue_type_script_lang_js = ({
|
|
125
|
+
name: 'pig-button' //组件名
|
|
126
|
+
});
|
|
127
|
+
;// ./src/package/pig-button/index.vue?vue&type=script&lang=js
|
|
128
|
+
|
|
129
|
+
;// ./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-12.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/package/pig-button/index.vue?vue&type=style&index=0&id=4717dde7&scoped=true&lang=css
|
|
130
|
+
// extracted by mini-css-extract-plugin
|
|
131
|
+
|
|
132
|
+
;// ./src/package/pig-button/index.vue?vue&type=style&index=0&id=4717dde7&scoped=true&lang=css
|
|
133
|
+
|
|
134
|
+
// EXTERNAL MODULE: ./node_modules/vue-loader/dist/exportHelper.js
|
|
135
|
+
var exportHelper = __webpack_require__(241);
|
|
136
|
+
;// ./src/package/pig-button/index.vue
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
;
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
const __exports__ = /*#__PURE__*/(0,exportHelper/* default */.A)(pig_buttonvue_type_script_lang_js, [['render',render],['__scopeId',"data-v-4717dde7"]])
|
|
145
|
+
|
|
146
|
+
/* harmony default export */ var pig_button = (__exports__);
|
|
147
|
+
;// ./src/package/index.js
|
|
148
|
+
// 引入封装好的组件
|
|
149
|
+
// import BaseForm from "./form/baseForm.vue"; // 引入封装好的组件
|
|
150
|
+
const coms = [pig_button]; // 将来如果有其他组件,都可以写到这个数组里
|
|
151
|
+
|
|
152
|
+
// 批量注册组件
|
|
153
|
+
const install = function (Vue) {
|
|
154
|
+
coms.forEach(com => {
|
|
155
|
+
Vue.component(com.name, com);
|
|
156
|
+
});
|
|
157
|
+
};
|
|
158
|
+
/* harmony default export */ var src_package = (install); // 这个方法以后再使用的时候可以被use调用
|
|
159
|
+
;// ./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
/* harmony default export */ var entry_lib = (src_package);
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
module.exports = __webpack_exports__;
|
|
166
|
+
/******/ })()
|
|
167
|
+
;
|
|
168
|
+
//# sourceMappingURL=woodao-pc-ui.common.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"woodao-pc-ui.common.js","mappings":";;;;;;;;AAAa;;AACbA,6BAA6C;EAAEG,KAAK,EAAE;AAAK,CAAC,CAAC;AAC7D;AACA;AACAD,SAAe,GAAG,CAACG,GAAG,EAAEC,KAAK,KAAK;EAC9B,MAAMC,MAAM,GAAGF,GAAG,CAACG,SAAS,IAAIH,GAAG;EACnC,KAAK,MAAM,CAACI,GAAG,EAAEC,GAAG,CAAC,IAAIJ,KAAK,EAAE;IAC5BC,MAAM,CAACE,GAAG,CAAC,GAAGC,GAAG;EACrB;EACA,OAAOH,MAAM;AACjB,CAAC,C;;;;;;UCVD;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;;WCtBA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,8CAA8C,yD;;;;;WCA9C;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA,2B;;;;;;;;;;;;;;ACAA;AACA;;AAEA;AACA;AACA,MAAM,KAAuC,EAAE;AAAA,yBAQ5C;;AAEH;AACA;AACA,IAAI,qBAAuB;AAC3B;AACA;;AAEA;AACA,kDAAe,IAAI;;;ACtBnB,IAAI,4DAA4B,kB;;;;uFCE9BI,mFAAA,CAEM,aAAAC,MAAA,QAAAA,MAAA,OADJC,mFAAA,CAAuB,gBAAf,QAAM,M;;;;;AAKlB,sEAAe;EACbC,IAAI,EAAE,YAAY,CAAE;AACtB,CAAC,E;;AEV0P,C;;ACA3P;;;;;;;AEA8E;AACtB;AACL;;AAEnD,CAA4E;;AAEO;AACnF,iCAAiC,+BAAe,CAAC,iCAAM,aAAa,MAAM;;AAE1E,+CAAe,W;;ACTgC,CAAC;AAChD;AACA,MAAME,IAAI,GAAG,CAACD,UAAS,CAAC,CAAC,CAAC;;AAE1B;AACA,MAAME,OAAO,GAAG,SAAAA,CAAUC,GAAG,EAAE;EAC3BF,IAAI,CAACG,OAAO,CAAEC,GAAG,IAAK;IAClBF,GAAG,CAACG,SAAS,CAACD,GAAG,CAACN,IAAI,EAAEM,GAAG,CAAC;EAChC,CAAC,CAAC;AACN,CAAC;AAED,gDAAeH,OAAO,EAAC,CAAC,uB;;ACXA;AACA;AACxB,8CAAe,WAAG;AACI","sources":["webpack://woodao-pc-ui/./node_modules/vue-loader/dist/exportHelper.js","webpack://woodao-pc-ui/webpack/bootstrap","webpack://woodao-pc-ui/webpack/runtime/define property getters","webpack://woodao-pc-ui/webpack/runtime/hasOwnProperty shorthand","webpack://woodao-pc-ui/webpack/runtime/make namespace object","webpack://woodao-pc-ui/webpack/runtime/publicPath","webpack://woodao-pc-ui/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://woodao-pc-ui/external commonjs2 {\"commonjs\":\"vue\",\"commonjs2\":\"vue\",\"root\":\"Vue\"}","webpack://woodao-pc-ui/./src/package/pig-button/index.vue","webpack://woodao-pc-ui/./src/package/pig-button/index.vue?d828","webpack://woodao-pc-ui/./src/package/pig-button/index.vue?c4ee","webpack://woodao-pc-ui/./src/package/pig-button/index.vue?a17f","webpack://woodao-pc-ui/./src/package/pig-button/index.vue?0d0c","webpack://woodao-pc-ui/./src/package/pig-button/index.vue?8fd1","webpack://woodao-pc-ui/./src/package/index.js","webpack://woodao-pc-ui/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n// runtime helper for setting properties on components\n// in a tree-shakable way\nexports.default = (sfc, props) => {\n const target = sfc.__vccOpts || sfc;\n for (const [key, val] of props) {\n target[key] = val;\n }\n return target;\n};\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.p = \"\";","/* eslint-disable no-var */\n// This file is imported into lib/wc client bundles.\n\nif (typeof window !== 'undefined') {\n var currentScript = window.document.currentScript\n if (process.env.NEED_CURRENTSCRIPT_POLYFILL) {\n var getCurrentScript = require('@soda/get-current-script')\n currentScript = getCurrentScript()\n\n // for backward compatibility, because previously we directly included the polyfill\n if (!('currentScript' in document)) {\n Object.defineProperty(document, 'currentScript', { get: getCurrentScript })\n }\n }\n\n var src = currentScript && currentScript.src.match(/(.+\\/)[^/]+\\.js(\\?.*)?$/)\n if (src) {\n __webpack_public_path__ = src[1] // eslint-disable-line\n }\n}\n\n// Indicate to webpack that this file can be concatenated\nexport default null\n","var __WEBPACK_NAMESPACE_OBJECT__ = require(\"vue\");","\r\n<template>\r\n <div>\r\n <button>我是测试按钮</button>\r\n </div>\r\n</template>\r\n\r\n<script>\r\nexport default {\r\n name: 'pig-button', //组件名\r\n}\r\n</script>\r\n\r\n<style scoped>\r\nbutton {\r\n width: 100px;\r\n height: 50px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n border: none;\r\n border-radius: 10px;\r\n cursor: pointer;\r\n}\r\n</style>\r\n","export * from \"-!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!../../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./index.vue?vue&type=template&id=4717dde7&scoped=true\"","export { default } from \"-!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./index.vue?vue&type=script&lang=js\"; export * from \"-!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!../../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./index.vue?vue&type=script&lang=js\"","// extracted by mini-css-extract-plugin\nexport {};","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-12.use[0]!../../../node_modules/css-loader/dist/cjs.js??clonedRuleSet-12.use[1]!../../../node_modules/vue-loader/dist/stylePostLoader.js!../../../node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-12.use[2]!../../../node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./index.vue?vue&type=style&index=0&id=4717dde7&scoped=true&lang=css\"","import { render } from \"./index.vue?vue&type=template&id=4717dde7&scoped=true\"\nimport script from \"./index.vue?vue&type=script&lang=js\"\nexport * from \"./index.vue?vue&type=script&lang=js\"\n\nimport \"./index.vue?vue&type=style&index=0&id=4717dde7&scoped=true&lang=css\"\n\nimport exportComponent from \"../../../node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render],['__scopeId',\"data-v-4717dde7\"]])\n\nexport default __exports__","import PigButton from \"./pig-button/index.vue\"; // 引入封装好的组件\r\n// import BaseForm from \"./form/baseForm.vue\"; // 引入封装好的组件\r\nconst coms = [PigButton]; // 将来如果有其他组件,都可以写到这个数组里\r\n\r\n// 批量注册组件\r\nconst install = function (Vue) {\r\n coms.forEach((com) => {\r\n Vue.component(com.name, com);\r\n });\r\n};\r\n\r\nexport default install; // 这个方法以后再使用的时候可以被use调用\r\n","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"names":["Object","defineProperty","exports","value","default","sfc","props","target","__vccOpts","key","val","_createElementBlock","_cache","_createElementVNode","name","PigButton","coms","install","Vue","forEach","com","component"],"sourceRoot":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
button[data-v-4717dde7]{width:100px;height:50px;display:flex;align-items:center;justify-content:center;border:none;border-radius:10px;cursor:pointer}
|