From f0da4d2e79d86921e8f97e490b167dad0501ea60 Mon Sep 17 00:00:00 2001 From: shy Date: Sat, 28 Jun 2025 00:22:23 +0800 Subject: [PATCH] add some --- frame.js | 1 + index.css | 5 +++-- plugin/local/code/inner.js | 2 +- plugin/table.js | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/frame.js b/frame.js index f5c50970..a28417ec 100644 --- a/frame.js +++ b/frame.js @@ -1105,6 +1105,7 @@ Volcanos(chat.ONMOTION, { if (can.page.tagis(event.target, html.SELECT, html.INPUT, html.TEXTAREA)) { return } if (can.page.tagis(event.target, html.A) && can.user.isWebview) { return event.shiftKey? window.outopen(event.target.href): can.user.open(event.target.href) } if (can.page.tagis(event.target, html.IMG) && can.base.beginWith(event.target.title, web.HTTP)) { return can.user.open(event.target.title) } + if (can.page.tagis(event.target, "img.qrcode")) { return can.user.open(event.target.title) } can.onmotion.clearCarte(can) } }, diff --git a/index.css b/index.css index 617c7ec6..d94265c4 100644 --- a/index.css +++ b/index.css @@ -164,9 +164,10 @@ div.output div.code.qrcode>img.qrcode:hover { div.output div.code.qrcode>img.qrcode { box-shadow:var(--box-shadow); border-radius:10px; margin:10px 10px; height:220px; width:220px; + cursor:pointer; } -div.output div.code>img.avatar { - box-shadow:var(--box-shadow); border-radius:10px; border:solid 2px white; object-fit:cover; --qrcode-icon-height:32px; +// div.output div.code>img.avatar { box-shadow:var(--box-shadow); border:solid 2px white; } +div.output div.code>img.avatar { --qrcode-icon-height:32px; object-fit:cover; border-radius:10px; height:var(--qrcode-icon-height) !important; width:var(--qrcode-icon-height) !important; position:absolute; top:calc(50% - var(--qrcode-icon-height) / 2 - 12px); left:calc(50% - var(--qrcode-icon-height) / 2); } diff --git a/plugin/local/code/inner.js b/plugin/local/code/inner.js index 46695330..365972cb 100644 --- a/plugin/local/code/inner.js +++ b/plugin/local/code/inner.js @@ -263,7 +263,7 @@ Volcanos(chat.ONIMPORT, { }) }) }, layout: function(can) { - if (can.Conf(ctx.STYLE) == html.OUTPUT) { return can.page.style(can, can.ui.content, html.WIDTH, (can.Conf("__width")||can.ConfWidth())-(can.user.isMobile? 4: 2)) } + if (can.Conf(ctx.STYLE) == html.OUTPUT) { return can.page.style(can, can.ui.content, html.WIDTH, (can.Conf("__width")||can.ConfWidth())-(can.user.isMobile? 5: 2)) } if (can.isSimpleMode() && !can.page.tagis(can._fields, html.FIELDSET_FLOAT)) { can.page.style(can, can._output, html.MAX_HEIGHT, "") } if (can.isSimpleMode()) { can.ui.layout(can.ConfHeight(), can.ConfWidth()); return can.page.style(can, can.ui.content, html.WIDTH, can.ConfWidth()) } if (can.isCmdMode()) { can.page.style(can, can._output, html.HEIGHT, can.ConfHeight(can.page.height())) } diff --git a/plugin/table.js b/plugin/table.js index ddc770fb..0b3b649c 100644 --- a/plugin/table.js +++ b/plugin/table.js @@ -426,7 +426,7 @@ Volcanos(chat.ONIMPORT, { if (!can.user.isMobile || msg.IsDetail() && msg.Append("user_uid") && msg.Append("user_uid") != msg.Option("user.uid")) { can.page.Append(can, _action, [{view: [[html.ITEM, html.SPACE]]}]) var value = {user_uid: msg.Option("user.uid"), user_name: msg.Option(ice.MSG_USERNICK), user_avatar: can.misc.Resource(can, msg.Option("user.avatar"))} can.page.Append(can, _action, [{view: [[html.ITEM, "user_info"]], list: [ - {view: html.NAME, list: [{text: value.user_name.split("@")[0]}, can.onimport.timeView(can, value)]}, can.onimport.textView(can, value, USER_PLACE_ROLE), {img: value.user_avatar}, + {view: html.NAME, list: [{text: can.user.isMobile? value.user_name.split("@")[0]: value.user_name}, can.onimport.timeView(can, value)]}, can.onimport.textView(can, value, USER_PLACE_ROLE), {img: value.user_avatar}, ], onclick: function(event) { sub.sub.run(sub.sub.request(event, {uid: value.user_uid}), [ctx.ACTION, "userInfo"]) }}])