yaolunmao / maotu-docs Goto Github PK
View Code? Open in Web Editor NEW基于vue3的web组态的引擎库——maotu的使用文档
Home Page: http://mt.yaolm.top/
基于vue3的web组态的引擎库——maotu的使用文档
Home Page: http://mt.yaolm.top/
mt-preview 页面独自渲染 ,按照文档 单独引入vue文件注册显示正常, 批量导入vue 文件,批量注册 页面不显示, 鼠标经过页面组件位置后该组件才显示,如果关闭showPopover,组件就不显示
oot@ubuntu:/usr/local/software/maotu/maotu# npm run serve
[email protected] serve
vue-cli-service serve
INFO Starting development server...
ERROR Failed to compile with 1 error 11:33:22 PM
error in ./src/App.vue?vue&type=template&id=7ba5bd90&ts=true
Module parse failed: Unexpected token (5:27)
File was processed with these loaders:
export function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {
| return (_openBlock(), _createElementBlock("div", _hoisted_1, [
| _createVNode($setup["MtEdit"])
ERROR in ./src/App.vue?vue&type=template&id=7ba5bd90&ts=true (./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/App.vue?vue&type=template&id=7ba5bd90&ts=true) 5:27
Module parse failed: Unexpected token (5:27)
File was processed with these loaders:
export function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {
| return (_openBlock(), _createElementBlock("div", _hoisted_1, [
| _createVNode($setup["MtEdit"])
@ ./src/App.vue?vue&type=template&id=7ba5bd90&ts=true 1:0-196 1:0-196
@ ./src/App.vue 1:0-72 6:68-74 16:71-18:3 17:29-35 16:2-18:4
@ ./src/main.js 2:0-28 3:10-13
webpack compiled with 1 error
如果vue组件中包含图片,拖动组件,松开鼠标后,组件就返回到原位置了。
比如有一个风扇组件,我想通过开关组件给这个风扇增加旋转动画或者停止旋转,如何实现呢?
TypeError: Cannot set properties of undefined (setting 'val')
at maotu.es.js:40792:12
at Array.map ()
at useExportJsonToDoneJson (maotu.es.js:40787:20)
at Proxy.setImportJson (maotu.es.js:41222:79)
at mycompoents.vue?t=1722332362367:10:39
at runtime-core.esm-bundler.js:1548:40
at callWithErrorHandling (runtime-core.esm-bundler.js:202:19)
at callWithAsyncErrorHandling (runtime-core.esm-bundler.js:209:17)
at hook.__weh.hook.__weh (runtime-core.esm-bundler.js:1528:19)
at flushPostFlushCbs (runtime-core.esm-bundler.js:386:32)
考虑到用户使用问题,希望不用用户填写自定义代码“$mtEventCallBack”,就能由程序员在画布中自己设置控件的点击事件,如何实现呢?
给组件加css样式不管用 比如直接在行内设置 :style="{width:'100%' height:'100%'}",MtPreview视图无法铺满页面空白处。
想实现在代码端就给开关绑定点击分合的动画,不用用户再去绑定了,可以实现吗?有说明文档就更好了,谢谢
使用组合后,组合里面的组件如何绑定通过props传递信息,试了
setItemAttrByID,不组合之前可以 传递到组件, 组合后传递不到组件
请问如何做图标开关切换,按照项目里的导入形式,拉到编辑器里面打不开 不知道为什么
一些 输出类 组件 如何从子组件 推送到 画布 父组件 , 比如 文本输入框, 滑块,如何读取子组件 实时输入的值,props只能单向 传输到子组件
{
id: "inputBox",
title: "输入框",
type: "vue",
thumbnail: "/svgs/input.svg",
width: 200,
height: 30,
props: {
modelValue: {
type: "input",
val: "输入框",
title: "文本",
},
},
events: [
{
id: "22",
type: "click",
action: "customCode",
change_attr: [],
custom_code: "$mtEventCallBack($item_info)",
trigger_rule: {
value: null,
},
},
],
},
{
id: "switch",
title: "开关",
type: "custom-svg",
thumbnail: "/svgs/switch.svg",
props: {
state: {
type: "switch",
val: false,
title: "开关",
},
},
events: [
{
id: "23",
type: "click",
action: "customCode",
change_attr: [],
custom_code:
"console.log('测试打印当前组件json',$item_info);\n$mtEventCallBack($item_info)",
trigger_rule: {
value: null,
},
},
],
},
返回,保存,预览三个按钮点击无效
ResizeObserver loop completed with undelivered notifications.
at handleError (webpack-internal:///./node_modules/webpack-dev-server/client/overlay.js:299:58)
at eval (webpack-internal:///./node_modules/webpack-dev-server/client/overlay.js:318:7)
请问下可以修改每个元件上面关联点的位置嘛,现在买个元件上面都是8个关联点的
设置背景图之后如何让图片大小拉伸至分辨率大小
目前组件 事件 有四个 单击 双击 鼠标移入 鼠标移出, 是否可以增加输入框聚焦 失焦 事件, 在本文框输入中如果用鼠标移出触发,存在文本框还在输出 ,而鼠标移动到别的地方的可能性,造成文本框输入不能触发。
WARN 12 deprecated subdependencies found: @humanwhocodes/[email protected], @humanwhocodes/[email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
这个报错,必需升级一下依赖么
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.