From 76d030b0bce1c332afde1ea390693411cb63d1c0 Mon Sep 17 00:00:00 2001 From: shy Date: Wed, 20 Dec 2023 23:59:59 +0800 Subject: [PATCH] opt repos --- index.css | 2 +- lib/misc.js | 1 + lib/user.js | 3 +-- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/index.css b/index.css index f72d23f8..d02c57fe 100644 --- a/index.css +++ b/index.css @@ -36,7 +36,7 @@ body { --river-width:var(--project-width); --project-width:230px; --input-width:120px; --button-width:60px; --action-height:32px; --status-height:var(--action-height); --footer-height:var(--action-height); --header-height:48px; --plug-width:800px; --plug-height:480px; --story-height:var(--plug-height); --float-height:var(--story-height); --float-width:1000px; --desktop-width:1200px; --desktop-height:684px; - --textarea-height:96px; --qrcode-height:320px; --iframe-height:420px; --desktop-icon-size:80px; + --textarea-height:96px; --qrcode-height:360px; --iframe-height:420px; --desktop-icon-size:80px; --river-margin:80px; --action-margin:200px; --plugin-padding:10px; --plugin-margin:var(--plugin-padding); --legend-padding:20px; --title-margin:var(--legend-padding); diff --git a/lib/misc.js b/lib/misc.js index 894e2926..35250b3a 100644 --- a/lib/misc.js +++ b/lib/misc.js @@ -145,6 +145,7 @@ Volcanos("misc", { } try { xhr.send(data) } catch(e) { can.misc.Warn(e), cbs && cbs(e) } }, WSS: function(can, args, cb, onopen, onclose, onerror, _msg) { if (can.user.isIE) { return } + args.debug = can.misc.Search(can, ice.MSG_DEBUG) args.text = location.pathname+location.search, args.module = "shylinux.com/x/volcanos", args.version = can.base.trimPrefix(window._version, "?_v=") var msg = can.request(); can.page.exportValue(can, msg), can.core.List(msg.Option(), function(value) { args[value] = msg.Option(value) }) var url = location.protocol.replace(ice.HTTP, "ws")+"//"+location.host+"/space/"; if (url.indexOf(html.CHROME) == 0) { url = "ws://localhost:9020/space/" } diff --git a/lib/user.js b/lib/user.js index 0272aaea..64f7f501 100644 --- a/lib/user.js +++ b/lib/user.js @@ -279,8 +279,7 @@ Volcanos("user", { } } }) var ui = can.onappend.tabview(can, list, _list, can.page.Append(can, document.body, [{view: "input login float flex"}])._target) can.page.style(can, ui._target, {left: (window.innerWidth-ui._target.offsetWidth)/2, top: can.user.isMobile? can.user.isLandscape()? 0 :48 :window.innerHeight/8}) - var _cmd = "space login "+arg[0]; ui.display = can.page.Append(can, ui._target, [html.DISPLAY])._target - can.onappend.style(can, html.FLEX, ui.display) + var _cmd = "space login "+arg[0]; ui.display = can.page.Append(can, ui._target, [html.DISPLAY])._target, can.onappend.style(can, html.FLEX, ui.display) can.page.Appends(can, ui.display, [{text: ["或命令行授权: ", html.LABEL]}, {text: ["$ "+_cmd, "", html.ITEM], title: "点击复制,并后台执行此命令,即可登录", style: {cursor: "copy"}, onclick: function() { can.user.copy(event, can, _cmd) }}]) can.page.Append(can, ui.display, [{text: ["或第三方授权: ", html.LABEL]}, {view: [["sso", html.FLEX]], list: msg.Table(function(value) { return value.type == "oauth" && {view: [[html.ITEM, html.FLEX]], title: "点击跳转,授权登录", list: [{img: can.misc.Resource(can, value.icons)}, {text: value.name}], onclick: function() { can.user.jumps(value.link) }}