diff --git a/frame.js b/frame.js index 2dfe1909..8983d6eb 100644 --- a/frame.js +++ b/frame.js @@ -342,10 +342,12 @@ Volcanos(chat.ONAPPEND, { if (msg.IsErr()) { return can.onappend.style(can, "warn", can.user.toastFailure(can, msg.Result())._target) } can.misc.Search(can, log.DEBUG) == ice.TRUE && can.base.beginWith(display, "/p/") && delete(Volcanos.meta.cache[display]) can.misc.Search(can, log.DEBUG) == ice.TRUE && can.base.beginWith(display, "/p/") && delete(Volcanos.meta.cache[display.split(".")[0]]) + var list = display.split(",").concat([msg.Option(ice.MSG_DISPLAY_CSS)||can.Conf("display_css")||undefined, chat.PLUGIN_TABLE_JS]) Volcanos(display, {_root: can._root, _follow: can.core.Keys(can._follow, display), _fields: can._target, _target: output, _path: display||chat.PLUGIN_TABLE_JS, _legend: can._legend, _option: can._option, _action: action||can._action, _output: output, _status: status||can._status, + sup: can, Update: can.Update, Option: can.Option, Action: can.Action, Status: can.Status, db: {hash: [""], value: {}}, ui: {layout: function() {}}, - }, display.split(",").concat([msg.Option(ice.MSG_DISPLAY_CSS)||can.Conf("display_css")||undefined, chat.PLUGIN_TABLE_JS]), function(sub) { sub.Conf(can.Conf()) + }, list, function(sub) { sub.Conf(can.Conf()) // sub.db.hash = can.base.getValid(can.isCmdMode()? can.misc.SearchHash(can): [], can.onexport.storage(can, "hash"))||[] sub.db.hash = can.base.getValid(can.isCmdMode()? can.misc.SearchHash(can): [])||[] var last = can.sub; last && can.core.CallFunc([last, "onaction.hidden"], {can: last}) diff --git a/lib/page.js b/lib/page.js index d31c2b63..8caf4524 100644 --- a/lib/page.js +++ b/lib/page.js @@ -36,6 +36,8 @@ Volcanos("page", { key == "className" && can.base.isArray(val) && (val = val.join(lex.SP)), !can.base.isObject(val)? (target[key] = val): can.core.Item(val, function(k, v) { if (can.base.isIn(k, "height", "width", "min-height", "max-height", "min-width", "max-width") && parseInt(v) < 0) { return target[key] && (target[key][k] = "") } if (can.base.isIn(k, "height", "width", "min-height", "max-height", "min-width", "max-width", "left", "top", "right", "bottom", "margin-left", "margin-top", "margin", "padding", "font-size") && v && (can.base.isNumber(v) || !can.base.endWith(v, "px"))) { v += "px" } + if (can.base.isIn(k, "background-image")) { v = "url("+v+")" } + if (can.base.isIn(k, "background")) { v = "url("+v+")" } target[key] && (target[key][k] = v) }) }); return target diff --git a/plugin/local/code/inner.js b/plugin/local/code/inner.js index 3c24e2ef..92d1b039 100644 --- a/plugin/local/code/inner.js +++ b/plugin/local/code/inner.js @@ -210,6 +210,7 @@ Volcanos(chat.ONIMPORT, { item.display_css = msg.Option(ice.MSG_DISPLAY_CSS) if (can.base.isIn(item.index, web.WIKI_WORD)) { item.style = html.OUTPUT } can.onimport.plug(can, item, function(sub) { + sub._load_display_always = true sub.onaction.close = function() { can.onmotion.hidden(can, target), can.onimport.layout(can) } sub.onexport.output = function(_sub, _msg) { can.base.isFunc(cb) && cb(_sub.sup, _msg) } }, target) diff --git a/proto.js b/proto.js index cdd7d1ee..82d699c8 100644 --- a/proto.js +++ b/proto.js @@ -43,7 +43,7 @@ var Volcanos = shy({iceberg: "", volcano: "", frame: chat.FRAME_JS, _cache: {}, if (name.indexOf("/require/") == 0 && meta.iceberg) { name = meta.iceberg+name } if (name.indexOf("/p/") == 0 && meta.iceberg) { name = meta.iceberg+name } if (name.indexOf("/v/") == 0 && meta.iceberg) { name = meta.iceberg+name } - meta.cache[name]? next(): meta._load(name, next) + (!can._follow || can._follow.indexOf("/plugin/local/code/vimer.js") == -1) && meta.cache[name]? next(): meta._load(name, next) }, request: function(event) { event = event||{}, event = event._event||event var msg = event._msg||can.misc.Message(event, can); event._msg = msg