feat: 新增蒙层组件
This commit is contained in:
@@ -1,11 +1,16 @@
|
||||
html,
|
||||
body,
|
||||
#app {
|
||||
#root {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
#app {
|
||||
#root {
|
||||
position: relative;
|
||||
overflow: auto;
|
||||
}
|
||||
}
|
||||
|
||||
#root::-webkit-scrollbar {
|
||||
width: 0 !important;
|
||||
display: none;
|
||||
}
|
||||
|
||||
@@ -47,6 +47,8 @@ const getLocalConfig = (): MApp[] => {
|
||||
}
|
||||
};
|
||||
|
||||
window.magicDSL = []
|
||||
|
||||
const app = new Core({
|
||||
config: ((getUrlParam('localPreview') ? getLocalConfig() : window.magicDSL) || [])[0] || {},
|
||||
curPage: getUrlParam('page'),
|
||||
|
||||
@@ -61,7 +61,10 @@ import(componentUrl).then(() => {
|
||||
};
|
||||
|
||||
const operations = {
|
||||
app,
|
||||
getApp() {
|
||||
return app;
|
||||
},
|
||||
|
||||
updateRootConfig(root: MApp) {
|
||||
console.log('update root config', root);
|
||||
app?.setConfig(root);
|
||||
|
||||
Reference in New Issue
Block a user