fo-vue-ui 0.0.7 → 0.0.9
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/fo-vue-ui.js +27 -15
- package/dist/fo-vue-ui.umd.cjs +1 -1
- package/dist/style.css +1 -0
- package/package.json +1 -1
- package/src/components/ceshicomp/ceshicomp.vue +0 -6
- package/src/components/index.ts +3 -2
- package/dist/fo-vue-ui.css +0 -1
package/dist/fo-vue-ui.js
CHANGED
|
@@ -1,21 +1,33 @@
|
|
|
1
|
-
import {
|
|
2
|
-
const
|
|
3
|
-
const
|
|
4
|
-
for (const [
|
|
5
|
-
c
|
|
6
|
-
return
|
|
7
|
-
},
|
|
1
|
+
import { onMounted as a, getCurrentInstance as _, openBlock as i, createElementBlock as m } from "vue";
|
|
2
|
+
const p = (o, e) => {
|
|
3
|
+
const n = o.__vccOpts || o;
|
|
4
|
+
for (const [c, s] of e)
|
|
5
|
+
n[c] = s;
|
|
6
|
+
return n;
|
|
7
|
+
}, l = { class: "ceshicomp" }, r = /* @__PURE__ */ Object.assign({ name: "ceshicomp" }, {
|
|
8
8
|
__name: "ceshicomp",
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
setup(o) {
|
|
10
|
+
return a(() => {
|
|
11
|
+
const e = _();
|
|
12
|
+
console.log("组件内验证 name:", e == null ? void 0 : e.type.name);
|
|
13
|
+
}), (e, n) => (i(), m("div", l, "123"));
|
|
12
14
|
}
|
|
13
|
-
},
|
|
14
|
-
|
|
15
|
-
|
|
15
|
+
}), d = /* @__PURE__ */ p(r, [["__scopeId", "data-v-a1fa5810"]]), f = [d], t = (o) => {
|
|
16
|
+
f.forEach((e) => {
|
|
17
|
+
var c;
|
|
18
|
+
const n = e.__name || e.name;
|
|
19
|
+
if (console.log("install component", e.__name, e.name), n)
|
|
20
|
+
o.component(n, e);
|
|
21
|
+
else {
|
|
22
|
+
const s = ((c = e.__file) == null ? void 0 : c.split("/").pop()) || "未知组件";
|
|
23
|
+
console.warn(
|
|
24
|
+
`组件 ${s} 没有定义有效的 name 属性,请检查组件内的 name 定义`
|
|
25
|
+
);
|
|
26
|
+
}
|
|
16
27
|
});
|
|
17
28
|
};
|
|
18
|
-
typeof window < "u" && "Vue" in window &&
|
|
29
|
+
typeof window < "u" && "Vue" in window && t(window.Vue);
|
|
30
|
+
const h = { install: t };
|
|
19
31
|
export {
|
|
20
|
-
|
|
32
|
+
h as default
|
|
21
33
|
};
|
package/dist/fo-vue-ui.umd.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(n,t){typeof exports=="object"&&typeof module<"u"?module.exports=t(require("vue")):typeof define=="function"&&define.amd?define(["vue"],t):(n=typeof globalThis<"u"?globalThis:n||self,n["fo-vue-ui"]=t(n.Vue))})(this,function(n){"use strict";const t="",a=(s,e)=>{const o=s.__vccOpts||s;for(const[c,i]of e)o[c]=i;return o},p={class:"ceshicomp"},d=[a(Object.assign({name:"ceshicomp"},{__name:"ceshicomp",setup(s){return n.onMounted(()=>{const e=n.getCurrentInstance();console.log("组件内验证 name:",e==null?void 0:e.type.name)}),(e,o)=>(n.openBlock(),n.createElementBlock("div",p,"123"))}}),[["__scopeId","data-v-a1fa5810"]])],_=s=>{d.forEach(e=>{var c;const o=e.__name||e.name;if(console.log("install component",e.__name,e.name),o)s.component(o,e);else{const i=((c=e.__file)==null?void 0:c.split("/").pop())||"未知组件";console.warn(`组件 ${i} 没有定义有效的 name 属性,请检查组件内的 name 定义`)}})};return typeof window<"u"&&"Vue"in window&&_(window.Vue),{install:_}});
|
package/dist/style.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ceshicomp[data-v-a1fa5810]{width:100px;height:100px;background:red}
|
package/package.json
CHANGED
package/src/components/index.ts
CHANGED
|
@@ -6,7 +6,7 @@ const components = [ceshicomp]
|
|
|
6
6
|
const install = (app: App) => {
|
|
7
7
|
components.forEach((component) => {
|
|
8
8
|
const compName = component.__name || component.name
|
|
9
|
-
console.log("install component",
|
|
9
|
+
console.log("install component", component.__name, component.name)
|
|
10
10
|
if (compName) {
|
|
11
11
|
app.component(compName, component)
|
|
12
12
|
} else {
|
|
@@ -21,4 +21,5 @@ const install = (app: App) => {
|
|
|
21
21
|
if (typeof window !== "undefined" && "Vue" in window) {
|
|
22
22
|
install(window.Vue as App)
|
|
23
23
|
}
|
|
24
|
-
|
|
24
|
+
|
|
25
|
+
export default { install }
|
package/dist/fo-vue-ui.css
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.ceshicomp[data-v-80063cdc]{width:100px;height:100px;background:red}
|