mirror of
https://shylinux.com/x/volcanos
synced 2025-04-25 16:58:06 +08:00
opt full
This commit is contained in:
parent
416a02869e
commit
52e78f66ef
1
frame.js
1
frame.js
@ -234,6 +234,7 @@ Volcanos("onappend", {help: "渲染引擎", list: [], _init: function(can, meta,
|
|||||||
return can.user.input(event, can, meta.feature[cmds[1]], function(ev, button, data, list, args) { var msg = can.request(event, {_handle: ice.TRUE}, can.Option())
|
return can.user.input(event, can, meta.feature[cmds[1]], function(ev, button, data, list, args) { var msg = can.request(event, {_handle: ice.TRUE}, can.Option())
|
||||||
can.Update(event, cmds.slice(0, 2).concat(args), cb||function() {
|
can.Update(event, cmds.slice(0, 2).concat(args), cb||function() {
|
||||||
if (can.core.CallFunc([can.sup, chat.ONIMPORT, ice.MSG_PROCESS], {can: can.sup, msg: msg})) { return }
|
if (can.core.CallFunc([can.sup, chat.ONIMPORT, ice.MSG_PROCESS], {can: can.sup, msg: msg})) { return }
|
||||||
|
if (can.core.CallFunc([can, chat.ONIMPORT, ice.MSG_PROCESS], {can: can, msg: msg})) { return }
|
||||||
if (msg.Result().length > 0 || msg.Length() > 0) {
|
if (msg.Result().length > 0 || msg.Length() > 0) {
|
||||||
can.onappend.table(can, msg)
|
can.onappend.table(can, msg)
|
||||||
can.onappend.board(can, msg)
|
can.onappend.board(can, msg)
|
||||||
|
@ -119,7 +119,10 @@ body.white fieldset.Action { color:black; }
|
|||||||
body.white fieldset.Action>div.action { color:white; }
|
body.white fieldset.Action>div.action { color:white; }
|
||||||
body.white fieldset.Action fieldset.plugin { background-color:#ffffff78; }
|
body.white fieldset.Action fieldset.plugin { background-color:#ffffff78; }
|
||||||
body.white fieldset.Action fieldset.plugin.full { background-color:#ffffffff; }
|
body.white fieldset.Action fieldset.plugin.full { background-color:#ffffffff; }
|
||||||
body.white fieldset.Action fieldset.plugin.Full { background-color:#cce0f4eb; }
|
body.white fieldset.Action fieldset.plugin.Full { background-color:#cce0f4eb; color:white; }
|
||||||
|
body.white fieldset.Action fieldset.story.Full { background-color:#cce0f4eb; color:white; }
|
||||||
|
body.white fieldset.Action fieldset.plugin.Full table.content { color:white; }
|
||||||
|
body.white fieldset.Action fieldset.story.Full table.content { color:white; }
|
||||||
body.white fieldset.Search table { color:white; }
|
body.white fieldset.Search table { color:white; }
|
||||||
body.white fieldset.word.float { background-color:aliceblue; color:black; }
|
body.white fieldset.word.float { background-color:aliceblue; color:black; }
|
||||||
|
|
||||||
|
@ -14,6 +14,12 @@ fieldset.Action.flow>div.output fieldset.plugin { float:left; }
|
|||||||
|
|
||||||
fieldset.Action div.output fieldset.plugin.Full { background-color:#073947f2; padding:0; margin:0; position:fixed; left:0; top:0; overflow:auto; z-index:1; }
|
fieldset.Action div.output fieldset.plugin.Full { background-color:#073947f2; padding:0; margin:0; position:fixed; left:0; top:0; overflow:auto; z-index:1; }
|
||||||
fieldset.Action div.output fieldset.plugin.Full>legend { float:left; }
|
fieldset.Action div.output fieldset.plugin.Full>legend { float:left; }
|
||||||
|
fieldset.Action div.output fieldset.story.Full { background-color:#073947f2; padding:0; margin:0; position:fixed; left:0; top:0; overflow:auto; z-index:1; }
|
||||||
|
fieldset.Action div.output fieldset.story.Full>legend { float:left; }
|
||||||
|
fieldset.Action>div.project.toggle {
|
||||||
|
background-color:cornsilk; opacity:0.8; color:teal; font-size: 28px; padding-top: 50px; height: 100px; width:20px; position: fixed; top: 200px;
|
||||||
|
border-top-right-radius:20px; border-bottom-right-radius:20px;
|
||||||
|
}
|
||||||
|
|
||||||
fieldset.panel.cmd>div.output>fieldset.plugin { padding:0; margin:0; }
|
fieldset.panel.cmd>div.output>fieldset.plugin { padding:0; margin:0; }
|
||||||
fieldset.panel.cmd>div.output>fieldset.plugin>legend { background-color:darkcyan; padding:0 10px; margin-right:3px; height:30px; float:left; }
|
fieldset.panel.cmd>div.output>fieldset.plugin>legend { background-color:darkcyan; padding:0 10px; margin-right:3px; height:30px; float:left; }
|
||||||
|
@ -90,6 +90,11 @@ Volcanos("onengine", {help: "解析引擎", list: [], _engine: function(event, p
|
|||||||
Volcanos("onaction", {help: "交互操作", list: [], _init: function(can, cb, target) {
|
Volcanos("onaction", {help: "交互操作", list: [], _init: function(can, cb, target) {
|
||||||
can.Conf(html.MARGIN_Y, 4*html.PLUGIN_MARGIN+2*html.ACTION_HEIGHT+html.ACTION_MARGIN)
|
can.Conf(html.MARGIN_Y, 4*html.PLUGIN_MARGIN+2*html.ACTION_HEIGHT+html.ACTION_MARGIN)
|
||||||
can.Conf(html.MARGIN_X, 4*html.PLUGIN_MARGIN)
|
can.Conf(html.MARGIN_X, 4*html.PLUGIN_MARGIN)
|
||||||
|
function toggle(view) { return !can.setRiver("display") }
|
||||||
|
var gt = "❯", lt = "❮", down = "˅", up = "˄"
|
||||||
|
can.page.Append(can, target, [{view: [[html.TOGGLE, chat.PROJECT]], list: [{text: [gt, html.DIV]}], onclick: function(event) {
|
||||||
|
event.target.innerHTML = toggle()? gt: lt
|
||||||
|
}}])
|
||||||
|
|
||||||
can.onengine.plugin(can, "info", shy("信息", {}, ["text", "list", "back"], function(msg, cmds) {
|
can.onengine.plugin(can, "info", shy("信息", {}, ["text", "list", "back"], function(msg, cmds) {
|
||||||
msg.Echo(JSON.stringify(can))
|
msg.Echo(JSON.stringify(can))
|
||||||
|
@ -62,6 +62,10 @@ Volcanos("onimport", {help: "导入数据", list: [], _init: function(can, msg,
|
|||||||
can.storm_list[can.core.Keys(river, meta.hash)] = target
|
can.storm_list[can.core.Keys(river, meta.hash)] = target
|
||||||
}}
|
}}
|
||||||
},
|
},
|
||||||
|
"display": function(event, can) {
|
||||||
|
var show = can.onmotion.toggle(can, can._target); can.onlayout._init(can)
|
||||||
|
return show
|
||||||
|
},
|
||||||
})
|
})
|
||||||
Volcanos("onengine", {help: "解析引擎", list: [], _engine: function(event, can, msg, panel, cmds, cb) {
|
Volcanos("onengine", {help: "解析引擎", list: [], _engine: function(event, can, msg, panel, cmds, cb) {
|
||||||
var list = can._root.river
|
var list = can._root.river
|
||||||
|
@ -191,6 +191,7 @@ Volcanos("onimport", {help: "导入数据", _init: function(can, msg, cb, target
|
|||||||
layout: function(can) {
|
layout: function(can) {
|
||||||
var height = can.ConfHeight()-(can.user.isMobile && can.user.mod.isCmd? (can.user.isLandscape()? 14: 54): 0)-(can.user.isWindows? 20: 0),
|
var height = can.ConfHeight()-(can.user.isMobile && can.user.mod.isCmd? (can.user.isLandscape()? 14: 54): 0)-(can.user.isWindows? 20: 0),
|
||||||
width = can.ConfWidth()-(can.user.isWindows && !can.user.mod.isCmd? 20: 0)+(can.user.isMobile && can.user.mod.isCmd && can.user.isLandscape()? 16: 0)
|
width = can.ConfWidth()-(can.user.isWindows && !can.user.mod.isCmd? 20: 0)+(can.user.isMobile && can.user.mod.isCmd && can.user.isLandscape()? 16: 0)
|
||||||
|
if (!height || height > window.innerHeight) { height = window.innerHeight - 200 }
|
||||||
if (can.user.isMobile && can.user.isLandscape() && height < 200) { height = 200 }
|
if (can.user.isMobile && can.user.isLandscape() && height < 200) { height = 200 }
|
||||||
|
|
||||||
can.page.styleWidth(can, can.ui.profile_output, can.profile_size[can.onexport.keys(can)]||(width-can.ui.project.offsetWidth)/2)
|
can.page.styleWidth(can, can.ui.profile_output, can.profile_size[can.onexport.keys(can)]||(width-can.ui.project.offsetWidth)/2)
|
||||||
|
@ -20,6 +20,7 @@ fieldset.word fieldset.story { margin:10px; }
|
|||||||
|
|
||||||
fieldset.word.float { padding:0; margin:0; width:-webkit-fill-available; position:fixed; left:0; top:0; z-index:10; }
|
fieldset.word.float { padding:0; margin:0; width:-webkit-fill-available; position:fixed; left:0; top:0; z-index:10; }
|
||||||
fieldset.word.float>div.action { display:contents; }
|
fieldset.word.float>div.action { display:contents; }
|
||||||
|
fieldset.word.float>div.status { clear:none; }
|
||||||
fieldset.word.float>div.output { background-color:#f0f8ff80; padding:20px; overflow:auto; }
|
fieldset.word.float>div.output { background-color:#f0f8ff80; padding:20px; overflow:auto; }
|
||||||
fieldset.word.float>div.output>div.project { background:cornsilk; padding:10px; position:fixed; left:0; top:25px; z-index:100; }
|
fieldset.word.float>div.output>div.project { background:cornsilk; padding:10px; position:fixed; left:0; top:25px; z-index:100; }
|
||||||
fieldset.word.float div.content div.page { margin-top:30px; display:none; }
|
fieldset.word.float div.content div.page { margin-top:30px; display:none; }
|
||||||
|
@ -89,10 +89,15 @@ Volcanos("onaction", {help: "交互操作", list: [
|
|||||||
mdb.NAME, meta.index, mdb.TEXT, JSON.stringify(can.Input([], true)),
|
mdb.NAME, meta.index, mdb.TEXT, JSON.stringify(can.Input([], true)),
|
||||||
])
|
])
|
||||||
},
|
},
|
||||||
"切换全屏": function(event, can) {
|
"切换全屏": function(event, can) { var sub = can._outputs[can._outputs.length-1]
|
||||||
if (can.page.ClassList.neg(can, can._target, "Full")) {
|
if (can.page.ClassList.neg(can, can._target, "Full")) {
|
||||||
can.page.style(can, can._output, "height", window.innerHeight-(can._status.innerText? 2: 1)*html.ACTION_HEIGHT, "min-width", window.innerWidth)
|
sub._height_bak = sub.ConfHeight(), sub._width_bak = sub.ConfWidth()
|
||||||
|
var height = window.innerHeight-(can._status.innerText? 2: 1)*html.ACTION_HEIGHT
|
||||||
|
can.page.style(can, can._output, "height", sub.ConfHeight(height), "min-width", sub.ConfWidth(window.innerWidth))
|
||||||
|
can.core.CallFunc([sub, "onimport.layout"], {can: sub})
|
||||||
} else {
|
} else {
|
||||||
|
sub.ConfHeight(sub._height_bak), sub.ConfWidth(sub._width_bak)
|
||||||
|
can.core.CallFunc([sub, "onimport.layout"], {can: sub})
|
||||||
can.page.style(can, can._output, "height", "", "min-width", "")
|
can.page.style(can, can._output, "height", "", "min-width", "")
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -5,7 +5,7 @@ Volcanos("onimport", {help: "导入数据", list: [], _init: function(can, msg,
|
|||||||
can.Conf(html.HEIGHT, can.Conf(html.HEIGHT)||200)
|
can.Conf(html.HEIGHT, can.Conf(html.HEIGHT)||200)
|
||||||
|
|
||||||
can.msg = msg, can.data = msg.Table(), can.onimport._sum(can)
|
can.msg = msg, can.data = msg.Table(), can.onimport._sum(can)
|
||||||
can.Action(html.HEIGHT, msg.Option(html.HEIGHT)||can.user.mod.isCmd? "max": can.user.isMobile&&can.user.isLandscape()? "200": "400")
|
can.Action(html.HEIGHT, msg.Option(html.HEIGHT)||"max")
|
||||||
can.Action("speed", parseInt(msg.Option("speed")||"100"))
|
can.Action("speed", parseInt(msg.Option("speed")||"100"))
|
||||||
|
|
||||||
can.require(["/plugin/local/wiki/draw.js", "/plugin/local/wiki/draw/path.js"], function() {
|
can.require(["/plugin/local/wiki/draw.js", "/plugin/local/wiki/draw/path.js"], function() {
|
||||||
@ -39,6 +39,9 @@ Volcanos("onimport", {help: "导入数据", list: [], _init: function(can, msg,
|
|||||||
})
|
})
|
||||||
can.Status({"from": begin, "commit": count, "total": add+del, "max": max})
|
can.Status({"from": begin, "commit": count, "total": add+del, "max": max})
|
||||||
},
|
},
|
||||||
|
layout: function(can) {
|
||||||
|
can.onaction[can.Action("view")]({}, can)
|
||||||
|
},
|
||||||
}, [""])
|
}, [""])
|
||||||
Volcanos("onaction", {help: "组件菜单", list: ["edit", ["view", "趋势图", "柱状图", "数据源"], ["height", "100", "200", "400", "600", "800", "max"], ["speed", "10", "20", "50", "100"]],
|
Volcanos("onaction", {help: "组件菜单", list: ["edit", ["view", "趋势图", "柱状图", "数据源"], ["height", "100", "200", "400", "600", "800", "max"], ["speed", "10", "20", "50", "100"]],
|
||||||
"edit": function(event, can) {
|
"edit": function(event, can) {
|
||||||
@ -46,7 +49,9 @@ Volcanos("onaction", {help: "组件菜单", list: ["edit", ["view", "趋势图",
|
|||||||
can.onmotion.toggle(can, can._status)
|
can.onmotion.toggle(can, can._status)
|
||||||
},
|
},
|
||||||
"趋势图": function(event, can) { var height = can.Action(html.HEIGHT)
|
"趋势图": function(event, can) { var height = can.Action(html.HEIGHT)
|
||||||
if (height == "max") { height = can.Conf(html.HEIGHT) }
|
if (height == "max") {
|
||||||
|
height = can.Conf(html.HEIGHT)
|
||||||
|
}
|
||||||
height = parseInt(height)
|
height = parseInt(height)
|
||||||
|
|
||||||
var space = 10, width = parseInt(can.Conf(html.WIDTH))
|
var space = 10, width = parseInt(can.Conf(html.WIDTH))
|
||||||
|
1
proto.js
1
proto.js
@ -334,6 +334,7 @@ var Volcanos = shy("火山架", {iceberg: "/chat/", volcano: "/frame.js", args:
|
|||||||
var msg = can.request({}, {trans: can.onaction._trans})
|
var msg = can.request({}, {trans: can.onaction._trans})
|
||||||
return can._menu = can.search(msg._event, [["Header", chat.ONIMPORT, "menu"], can._name].concat(list), cb)
|
return can._menu = can.search(msg._event, [["Header", chat.ONIMPORT, "menu"], can._name].concat(list), cb)
|
||||||
},
|
},
|
||||||
|
setRiver: function(key, value) { return can.set("River", key, value) },
|
||||||
setHeader: function(key, value) { return can.set("Header", key, value) },
|
setHeader: function(key, value) { return can.set("Header", key, value) },
|
||||||
getHeader: function(key, cb) { return can.get("Header", key, cb) },
|
getHeader: function(key, cb) { return can.get("Header", key, cb) },
|
||||||
getAction: function(key, cb) { return can.get("Action", key, cb) },
|
getAction: function(key, cb) { return can.get("Action", key, cb) },
|
||||||
|
Loading…
x
Reference in New Issue
Block a user