1
0
forked from x/volcanos
This commit is contained in:
IT 老营长 @云轩领航-创始人 2023-09-30 08:58:38 +08:00
parent 79b82f7c5a
commit f5fcce9505
3 changed files with 9 additions and 9 deletions

View File

@ -51,11 +51,11 @@ Volcanos("user", {
this.isMobile? location.href = url: null
},
close: function(url) { return window.close() },
theme: function(can, name) {
can.base.isString(name) && (name = [name]) || name || []
can.user.mod.cmd && name.push(can.user.mod.cmd.replaceAll(".", " "))
can.user.language(can) && name.push(can.core.Split(can.user.language(can), "-")[0]), can.user.mod.isCmd && name.push(chat.CMD), can.user.isWebview && name.push(html.WEBVIEW)
can.user.isWindows && name.push("windows"), can.user.isMobile && name.push(html.MOBILE) && can.user.isLandscape() && name.push(html.LANDSCAPE)
theme: function(can, name) { can.base.isString(name) && (name = [name]) || name || []
can.user.language(can) && name.push(can.core.Split(can.user.language(can), "-")[0])
can.user.mod.isCmd && name.push(chat.CMD), can.user.mod.cmd && name.push(can.user.mod.cmd.replaceAll(".", " "))
can.user.isMobile && name.push(html.MOBILE) && can.user.isLandscape() && name.push(html.LANDSCAPE)
can.user.isWebview && name.push(html.WEBVIEW), can.user.isWindows && name.push("windows")
can.page.styleClass(can, document.body, name.join(lex.SP))
},
title: function(text) { if (window.webview) { return title(text) } return text && (document.title = text), document.title },

View File

@ -61,9 +61,8 @@ Volcanos(chat.ONACTION, {_init: function(can) {
msg.Option(nfs.SCRIPT) && can.require(can.base.Obj(msg.Option(nfs.SCRIPT)), function(can) { can.onaction.source(can, msg) })
lang(msg, function() { can.onmotion.clear(can), can.onimport._init(can, can.request(), can._output), can.onengine.signal(can, chat.ONLOGIN) })
}
can.run(can.request({}, {_method: http.GET}), [], function(msg) {
lang(msg), can.page.requireModules(can, [msg.Option(mdb.ICONS)])
can.require(can.core.List(msg["theme.list"], function(item) { return "src/template/web.chat.header/theme/"+item }))
can.run(can.request({}, {_method: http.GET}), [], function(msg) { lang(msg)
can.require(can.core.List(msg["theme.list"], function(item) { return "src/template/web.chat.header/theme/"+item }), function() { can.page.requireModules(can, [msg.Option(mdb.ICONS)]) })
can.onaction._menus[1] = [chat.THEME, ice.AUTO].concat(can.core.List(msg["theme.list"], function(item) { return can.base.trimSuffix(item, ".css") }))
can.onaction._menus[2] = [aaa.LANGUAGE, ice.AUTO].concat(can.core.List(msg["language.list"], function(item) { return can.base.trimSuffix(item, ".js") }))
if (can.base.beginWith(location.pathname, "/wiki/portal/", "/chat/cmd/web.wiki.portal/", "/chat/cmd/web.chat.oauth.client", "/chat/pod/20230511-golang-story/cmd/web.code.gitea.client")) { return show(msg) }

View File

@ -57,7 +57,8 @@ Volcanos(chat.ONIMPORT, {
Volcanos(chat.ONACTION, {list: [
"刷新数据", "刷新界面",
"切换浮动", "切换全屏",
"远程控制", "共享工具",
// "远程控制", "共享工具",
"共享工具",
"打开链接", "生成链接",
"生成脚本", "生成图片",
["视图", "参数", "操作", "状态", "专注", "项目", "预览", "演示"],