@vtj/pro 0.8.16 → 0.8.17
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/@vtj/materials/assets/antdv/index.umd.js +2 -2
- package/dist/@vtj/materials/assets/charts/index.umd.js +2 -2
- package/dist/@vtj/materials/assets/element/index.umd.js +2 -2
- package/dist/@vtj/materials/assets/ui/index.umd.js +2 -2
- package/dist/@vtj/materials/deps/@vtj/charts/index.umd.js +2 -2
- package/dist/@vtj/materials/deps/@vtj/icons/index.umd.js +2 -2
- package/dist/@vtj/materials/deps/@vtj/ui/index.umd.js +2 -2
- package/dist/@vtj/materials/deps/@vtj/utils/index.umd.js +2 -2
- package/dist/assets/index-ByF1GlaH.js +1 -0
- package/dist/assets/{index-T7e3Ts-R.js → index-CPIxlRRl.js} +11 -11
- package/dist/assets/{index-UUuuteXI.css → index-pPiycE5T.css} +1 -1
- package/dist/assets/{index-ClDGmlHY.js → index-sXwSx2AY.js} +2 -2
- package/dist/assets/{preview-B3ihVvDL.js → preview-7UWHgZAz.js} +1 -1
- package/dist/index.html +1 -1
- package/package.json +10 -10
- package/src/extension.ts +5 -2
- package/dist/assets/index-D_Dk5dad.js +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__fileDeps=["./index-
|
|
2
|
-
import{d as f,S as n,u as p,ai as d,o as a,U as c,aF as _,_ as h,at as y}from"./@vue-pheekl12.js";import{z as v,E as g}from"./element-plus-DdvN1jqD.js";import{_ as m}from"./monaco-editor-B9w0R7jm.js";import{createRouter as O,createWebHashHistory as P}from"./vue-router-D533GGmG.js";import"./lodash-es-D0J8aJCM.js";import"./@vueuse-4_NYtZCP.js";import"./@element-plus-D6n2RTX_.js";import"./@popperjs-CsO2-mKt.js";import"./@ctrl-r5W6hzzQ.js";import"./dayjs-Cdlb6j_n.js";import"./async-validator-Cr9EP88T.js";import"./memoize-one-BdPwpGay.js";import"./normalize-wheel-es-B6fDCfyv.js";import"./@floating-ui-CYeB_Mhp.js";(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const e of document.querySelectorAll('link[rel="modulepreload"]'))o(e);new MutationObserver(e=>{for(const t of e)if(t.type==="childList")for(const i of t.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&o(i)}).observe(document,{childList:!0,subtree:!0});function s(e){const t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin==="use-credentials"?t.credentials="include":e.crossOrigin==="anonymous"?t.credentials="omit":t.credentials="same-origin",t}function o(e){if(e.ep)return;e.ep=!0;const t=s(e);fetch(e.href,t)}})();const E=f({__name:"app",setup(l){return(r,s)=>{const o=d("router-view");return a(),n(p(g),{locale:p(v)},{default:c(()=>[(a(),n(_,null,{default:c(()=>[h(o)]),_:1}))]),_:1},8,["locale"])}}}),L=[{path:"/",name:"home",component:()=>m(()=>import("./index-
|
|
1
|
+
const __vite__fileDeps=["./index-ByF1GlaH.js","./vue-router-D533GGmG.js","./@vue-pheekl12.js","./element-plus-DdvN1jqD.js","./lodash-es-D0J8aJCM.js","./@vueuse-4_NYtZCP.js","./@element-plus-D6n2RTX_.js","./@popperjs-CsO2-mKt.js","./@ctrl-r5W6hzzQ.js","./dayjs-Cdlb6j_n.js","./async-validator-Cr9EP88T.js","./memoize-one-BdPwpGay.js","./normalize-wheel-es-B6fDCfyv.js","./@floating-ui-CYeB_Mhp.js","./element-plus-Dj7XYlV7.css","./index-CPIxlRRl.js","./monaco-editor-B9w0R7jm.js","./monaco-editor-BgBQhOSF.css","./vue-CjubWy22.js","./mockjs-c-NHcvHM.js","./index-pPiycE5T.css","./index-D9EpXQVL.css","./preview-7UWHgZAz.js"],__vite__mapDeps=i=>i.map(i=>__vite__fileDeps[i]);
|
|
2
|
+
import{d as f,S as n,u as p,ai as d,o as a,U as c,aF as _,_ as h,at as y}from"./@vue-pheekl12.js";import{z as v,E as g}from"./element-plus-DdvN1jqD.js";import{_ as m}from"./monaco-editor-B9w0R7jm.js";import{createRouter as O,createWebHashHistory as P}from"./vue-router-D533GGmG.js";import"./lodash-es-D0J8aJCM.js";import"./@vueuse-4_NYtZCP.js";import"./@element-plus-D6n2RTX_.js";import"./@popperjs-CsO2-mKt.js";import"./@ctrl-r5W6hzzQ.js";import"./dayjs-Cdlb6j_n.js";import"./async-validator-Cr9EP88T.js";import"./memoize-one-BdPwpGay.js";import"./normalize-wheel-es-B6fDCfyv.js";import"./@floating-ui-CYeB_Mhp.js";(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const e of document.querySelectorAll('link[rel="modulepreload"]'))o(e);new MutationObserver(e=>{for(const t of e)if(t.type==="childList")for(const i of t.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&o(i)}).observe(document,{childList:!0,subtree:!0});function s(e){const t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin==="use-credentials"?t.credentials="include":e.crossOrigin==="anonymous"?t.credentials="omit":t.credentials="same-origin",t}function o(e){if(e.ep)return;e.ep=!0;const t=s(e);fetch(e.href,t)}})();const E=f({__name:"app",setup(l){return(r,s)=>{const o=d("router-view");return a(),n(p(g),{locale:p(v)},{default:c(()=>[(a(),n(_,null,{default:c(()=>[h(o)]),_:1}))]),_:1},8,["locale"])}}}),L=[{path:"/",name:"home",component:()=>m(()=>import("./index-ByF1GlaH.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21]),import.meta.url)},{path:"/preview/:id",name:"preview",component:()=>m(()=>import("./preview-7UWHgZAz.js"),__vite__mapDeps([22,16,17,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,18,19,20]),import.meta.url)}],w=O({history:P(),routes:L}),u=y(E);u.use(w);u.mount("#app");
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
const __vite__fileDeps=["./vue-CjubWy22.js","./@vue-pheekl12.js","./vue-router-D533GGmG.js","./element-plus-DdvN1jqD.js","./lodash-es-D0J8aJCM.js","./@vueuse-4_NYtZCP.js","./@element-plus-D6n2RTX_.js","./@popperjs-CsO2-mKt.js","./@ctrl-r5W6hzzQ.js","./dayjs-Cdlb6j_n.js","./async-validator-Cr9EP88T.js","./memoize-one-BdPwpGay.js","./normalize-wheel-es-B6fDCfyv.js","./@floating-ui-CYeB_Mhp.js","./element-plus-Dj7XYlV7.css"],__vite__mapDeps=i=>i.map(i=>__vite__fileDeps[i]);
|
|
2
|
-
import{_ as o}from"./monaco-editor-B9w0R7jm.js";import{useRoute as a}from"./vue-router-D533GGmG.js";import"./element-plus-DdvN1jqD.js";import{x as s,w as _,M as u}from"./index-
|
|
2
|
+
import{_ as o}from"./monaco-editor-B9w0R7jm.js";import{useRoute as a}from"./vue-router-D533GGmG.js";import"./element-plus-DdvN1jqD.js";import{x as s,w as _,M as u}from"./index-CPIxlRRl.js";import{d as c,r as d,S as l,W as v,X as f,o as R,i as E}from"./@vue-pheekl12.js";import"./lodash-es-D0J8aJCM.js";import"./@vueuse-4_NYtZCP.js";import"./@element-plus-D6n2RTX_.js";import"./@popperjs-CsO2-mKt.js";import"./@ctrl-r5W6hzzQ.js";import"./dayjs-Cdlb6j_n.js";import"./async-validator-Cr9EP88T.js";import"./memoize-one-BdPwpGay.js";import"./normalize-wheel-es-B6fDCfyv.js";import"./@floating-ui-CYeB_Mhp.js";import"./vue-CjubWy22.js";import"./mockjs-c-NHcvHM.js";const W=c({__name:"preview",setup(V){const m=new u,{provider:r,onReady:i}=s({mode:_.Runtime,service:m,dependencies:{Vue:()=>o(()=>import("./vue-CjubWy22.js").then(e=>e.V),__vite__mapDeps([0,1]),import.meta.url),VueRouter:()=>o(()=>import("./vue-router-D533GGmG.js"),__vite__mapDeps([2,1]),import.meta.url),ElementPlus:()=>o(()=>import("./element-plus-DdvN1jqD.js").then(e=>e.a),__vite__mapDeps([3,1,4,5,6,7,8,9,10,11,12,13,14]),import.meta.url)}}),p=a(),t=d(),n=E();return i(async()=>{n?.appContext.app.use(r),t.value=await r.getRenderComponent(p.params.id.toString())}),(e,C)=>t.value?(R(),l(v(t.value),{key:0})):f("",!0)}});export{W as default};
|
package/dist/index.html
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<meta http-equiv="Pragma" content="no-cache"/>
|
|
9
9
|
<meta http-equiv="Expires" content="0"/>
|
|
10
10
|
<title>低代码设计器 - VTJ.PRO</title>
|
|
11
|
-
<script type="module" crossorigin src="./assets/index-
|
|
11
|
+
<script type="module" crossorigin src="./assets/index-sXwSx2AY.js"></script>
|
|
12
12
|
<link rel="modulepreload" crossorigin href="./assets/@vue-pheekl12.js">
|
|
13
13
|
<link rel="modulepreload" crossorigin href="./assets/lodash-es-D0J8aJCM.js">
|
|
14
14
|
<link rel="modulepreload" crossorigin href="./assets/@vueuse-4_NYtZCP.js">
|
package/package.json
CHANGED
|
@@ -2,23 +2,23 @@
|
|
|
2
2
|
"name": "@vtj/pro",
|
|
3
3
|
"description": "VTJ.PRO",
|
|
4
4
|
"private": false,
|
|
5
|
-
"version": "0.8.
|
|
5
|
+
"version": "0.8.17",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"dependencies": {
|
|
8
|
-
"@vtj/core": "~0.8.
|
|
9
|
-
"@vtj/
|
|
10
|
-
"@vtj/
|
|
11
|
-
"@vtj/local": "~0.8.
|
|
12
|
-
"@vtj/renderer": "~0.8.
|
|
8
|
+
"@vtj/core": "~0.8.17",
|
|
9
|
+
"@vtj/materials": "~0.8.17",
|
|
10
|
+
"@vtj/designer": "~0.8.17",
|
|
11
|
+
"@vtj/local": "~0.8.17",
|
|
12
|
+
"@vtj/renderer": "~0.8.17"
|
|
13
13
|
},
|
|
14
14
|
"devDependencies": {
|
|
15
15
|
"vue": "~3.4.15",
|
|
16
16
|
"vue-router": "~4.3.0",
|
|
17
|
-
"@vtj/charts": "~0.8.
|
|
17
|
+
"@vtj/charts": "~0.8.17",
|
|
18
18
|
"@vtj/cli": "~0.8.4",
|
|
19
|
-
"@vtj/
|
|
20
|
-
"@vtj/
|
|
21
|
-
"@vtj/utils": "~0.8.
|
|
19
|
+
"@vtj/icons": "~0.8.17",
|
|
20
|
+
"@vtj/ui": "~0.8.17",
|
|
21
|
+
"@vtj/utils": "~0.8.17"
|
|
22
22
|
},
|
|
23
23
|
"exports": {
|
|
24
24
|
"./vite": {
|
package/src/extension.ts
CHANGED
|
@@ -11,6 +11,7 @@ import type { EngineOptions } from '@vtj/designer';
|
|
|
11
11
|
export interface ExtensionOptions {
|
|
12
12
|
urls: string[];
|
|
13
13
|
library: string;
|
|
14
|
+
params?: any[];
|
|
14
15
|
}
|
|
15
16
|
|
|
16
17
|
export type ExtensionFactory = () => Partial<EngineOptions> | void;
|
|
@@ -18,6 +19,7 @@ export type ExtensionFactory = () => Partial<EngineOptions> | void;
|
|
|
18
19
|
export class Extension {
|
|
19
20
|
private urls: string[] = [];
|
|
20
21
|
private library: string = '';
|
|
22
|
+
private params: any[] = [];
|
|
21
23
|
constructor(options: ExtensionOptions) {
|
|
22
24
|
const __VTJ_PRO__ = {
|
|
23
25
|
...core,
|
|
@@ -30,9 +32,10 @@ export class Extension {
|
|
|
30
32
|
(window as any).VtjUtils = VtjUtils;
|
|
31
33
|
(window as any).VtjIcons = VtjIcons;
|
|
32
34
|
(window as any).ElementPlus = ElementPlus;
|
|
33
|
-
const { urls, library } = options;
|
|
35
|
+
const { urls, library, params = [] } = options;
|
|
34
36
|
this.urls = urls;
|
|
35
37
|
this.library = library;
|
|
38
|
+
this.params = params;
|
|
36
39
|
}
|
|
37
40
|
async load(): Promise<Partial<EngineOptions> | undefined> {
|
|
38
41
|
const css = this.urls.filter((n) => renderer.isCSSUrl(n));
|
|
@@ -43,7 +46,7 @@ export class Extension {
|
|
|
43
46
|
.loadScriptUrl(scripts, this.library)
|
|
44
47
|
.catch(() => null);
|
|
45
48
|
if (output && typeof output === 'function') {
|
|
46
|
-
return output();
|
|
49
|
+
return output.apply(output, this.params);
|
|
47
50
|
}
|
|
48
51
|
}
|
|
49
52
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{useRoute as f}from"./vue-router-D533GGmG.js";import{a as w}from"./element-plus-DdvN1jqD.js";import{V as h,a as y,b as V,L as g,o as v,B as x,c as b,d as j,r as P,j as u,e as k,M as B}from"./index-T7e3Ts-R.js";import{V as E}from"./vue-CjubWy22.js";import{d as O,r as $,bO as _,f as C,c as F,o as I}from"./@vue-pheekl12.js";import"./lodash-es-D0J8aJCM.js";import"./@vueuse-4_NYtZCP.js";import"./@element-plus-D6n2RTX_.js";import"./@popperjs-CsO2-mKt.js";import"./@ctrl-r5W6hzzQ.js";import"./dayjs-Cdlb6j_n.js";import"./async-validator-Cr9EP88T.js";import"./memoize-one-BdPwpGay.js";import"./normalize-wheel-es-B6fDCfyv.js";import"./@floating-ui-CYeB_Mhp.js";import"./monaco-editor-B9w0R7jm.js";import"./mockjs-c-NHcvHM.js";class J{urls=[];library="";constructor(t){const o={...b,...j,...P};window.Vue=E,window.__VTJ_PRO__=o,window.VtjUtils=h,window.VtjIcons=y,window.ElementPlus=w;const{urls:e,library:n}=t;this.urls=e,this.library=n}async load(){const t=this.urls.filter(e=>V(e)),o=this.urls.filter(e=>g(e));if(v(t),o.length){const e=await x(o,this.library).catch(()=>null);if(e&&typeof e=="function")return e()}}}const R=O({__name:"index",async setup(s){let t,o;const e=f(),n=$(),l=new B,m=([t,o]=_(()=>l.getExtension().catch(()=>null)),t=await t,o(),t),d=m?([t,o]=_(()=>new J(m).load()),t=await t,o(),t):void 0;u.set("Switcher",{props:{onClick:r=>{const i=location.pathname;let p=i==="/@vtj/pro/"?"/":i;const a=r.currentFile;a&&a.type==="page"&&r.homepage!==a.id&&(p=`${p}#/page/${a.id}`),window.open(p,"VTJProject")}}}),u.set("Previewer",{props:{path:r=>`${location.pathname}#/preview/${r.id}`}});const c=new k({container:n,service:l,...d});return c.ready(()=>{c.openFile(e.query.id)}),C(()=>e.query.id,r=>{c.openFile(r)}),(r,i)=>(I(),F("div",{class:"designer",ref_key:"container",ref:n},null,512))}}),T=(s,t)=>{const o=s.__vccOpts||s;for(const[e,n]of t)o[e]=n;return o},tt=T(R,[["__scopeId","data-v-b233af06"]]);export{tt as default};
|