diff --git a/base/cli/qrcode.go b/base/cli/qrcode.go
index b470474e..6b4dc0b8 100644
--- a/base/cli/qrcode.go
+++ b/base/cli/qrcode.go
@@ -54,9 +54,7 @@ func init() {
), Actions: ice.MergeActions(ice.Actions{
ice.CTX_INIT: {Hand: func(m *ice.Message, arg ...string) {
ice.AddRender(ice.RENDER_QRCODE, func(m *ice.Message, args ...ice.Any) string {
- if m.IsMobileUA() {
- m.Option(SIZE, "280")
- }
+ kit.If(m.IsMobileUA(), func() { m.Option(SIZE, "280") })
return m.Cmd(Prefix(QRCODE), kit.Simple(args...)).Result()
})
}},
@@ -66,6 +64,13 @@ func init() {
m.Push(arg[0], kit.SortedKey(_color_map))
}
}},
+ "view": {Name: "view text icon link", Hand: func(m *ice.Message, arg ...string) {
+ m.Echo("
")
+ defer m.Echo("
")
+ m.Cmdy("", arg[2])
+ m.Echo("
", arg[1])
+ m.Echo(arg[0])
+ }},
}), Hand: func(m *ice.Message, arg ...string) {
if m.IsCliUA() {
m.OptionDefault(FG, BLACK, BG, WHITE)
diff --git a/core/chat/header.go b/core/chat/header.go
index db72b77e..2c20b21f 100644
--- a/core/chat/header.go
+++ b/core/chat/header.go
@@ -141,7 +141,7 @@ func init() {
m.Echo(m.Option(ice.MSG_SESSID))
}
}},
- }, web.ApiAction(), mdb.ImportantHashAction(mdb.SHORT, mdb.NAME, mdb.FIELD, "time,type,name,help,icons,order,link,space,index,args")), Hand: func(m *ice.Message, arg ...string) {
+ }, web.ApiAction(), mdb.ImportantHashAction(mdb.SHORT, mdb.NAME, mdb.FIELD, "time,type,name,help,prompt,icons,order,link,space,index,args")), Hand: func(m *ice.Message, arg ...string) {
if kit.Contains(m.Option(ice.MSG_USERUA), "MicroMessenger") {
if m.Option(ice.MSG_USERNAME) == "" && m.Option("code") == "" && mdb.Config(m, "oauth") != "" {
m.ProcessOpen(mdb.Config(m, "oauth"))
diff --git a/core/wiki/portal.css b/core/wiki/portal.css
index b3c84085..8ecc58ab 100644
--- a/core/wiki/portal.css
+++ b/core/wiki/portal.css
@@ -2,7 +2,7 @@ $fieldset { --portal-max-width:1200px; --portal-header-height:64px; --portal-mai
$fieldset.home { --portal-max-width:1500px; }
$fieldset>div.header { display:none; }
$output { padding:0; }
-$output>div.header { background-color:var(--panel-bg-color); height:var(--portal-header-height); --hover-bg-color:var(--plugin-bg-color); }
+$output>div.header { box-shadow:var(--box-shadow); background-color:var(--panel-bg-color); height:var(--portal-header-height); --hover-bg-color:var(--plugin-bg-color); }
$output>div.header div.list { display:flex; }
$output>div.header div.story[data-name=navmenu] { --hover-fg-color:white; }
$output>div.header div.story div.item span { white-space:pre; overflow:hidden; }
@@ -13,7 +13,7 @@ $output>div.header div.story[data-name=navmenu] div.item:first-child { padding:v
$output>div.header div.story[data-name=navmenu] div.item:first-child { line-height:calc(var(--portal-header-height) - 2 * var(--legend-padding)); font-size:24px; font-weight:bold; }
$output>div.header div.story[data-name=navmenu] div.item:first-child img { margin-right:var(--button-margin); }
$output>div.header div.story[data-name=navmenu] div.item.select { background-color:var(--output-bg-color); }
-$output>div.header div.story[data-name=navmenu] div.item:hover { background-color:var(--output-bg-color); }
+$output>div.header div.story[data-name=navmenu] div.item:not(.space):hover { background-color:var(--output-bg-color); }
// $output>div.header div.story[data-name=navmenu] div.item.space { padding:0px; margin:0 var(--portal-main-padding); }
$output>div.header div.story[data-name=navmenu] div.item.space { padding:0px; width:20px; }
$output>div.layout { display:flex; justify-content:center; }
diff --git a/core/wiki/spark.go b/core/wiki/spark.go
index d4d7ac4d..7ad81b69 100644
--- a/core/wiki/spark.go
+++ b/core/wiki/spark.go
@@ -99,6 +99,8 @@ func init() {
}},
PROJECT: {Hand: func(m *ice.Message, arg ...string) { _spark_project(m, arg...) }},
PRODUCT: {Hand: func(m *ice.Message, arg ...string) { _spark_product(m, arg...) }},
+ "raw": {Hand: func(m *ice.Message, arg ...string) { m.Echo(arg[0], kit.TransArgs(arg[1:])...) }},
+ "html": {Hand: func(m *ice.Message, arg ...string) { m.Echo(arg[0], kit.TransArgs(arg[1:])...) }},
}), Hand: func(m *ice.Message, arg ...string) {
m.Option(mdb.META, "")
if kit.Ext(arg[0]) == "md" {
diff --git a/misc/wx/agent.js b/misc/wx/agent.js
index fa61f6d7..36da385d 100644
--- a/misc/wx/agent.js
+++ b/misc/wx/agent.js
@@ -8,7 +8,6 @@ Volcanos(chat.ONIMPORT, {
debug = false, can.onmotion.hidden(can, can._fields)
wx.config({debug: debug, signature: msg.Option("signature"), timestamp: msg.Option("timestamp"), nonceStr: msg.Option("noncestr"), appId: msg.Option("appid"),
jsApiList: can.core.Item({
- /*
getLocation: function(can, cb) { wx.getLocation({type: "gcj02", success: function (res) {
can.base.isFunc(cb) && cb({type: "gcj02", name: "当前位置", text: "当前位置", latitude: parseInt(res.latitude*100000), longitude: parseInt(res.longitude*100000) })
} }) },
@@ -28,7 +27,6 @@ Volcanos(chat.ONIMPORT, {
scanQRCode: function(can, cb) { wx.scanQRCode({needResult: cb? 1: 0, scanType: ["qrCode", "barCode"], success: function (res) {
can.base.isFunc(cb) && cb(can.base.ParseJSON(res.resultStr))
} }) },
- */
}, function(key, value) { return can.user.agent[key] = value, key }).concat([
"updateAppMessageShareData",
], can.user.isMobile? ["updateTimelineShareData"]: []), openTagList: ["wx-open-subscribe"],
@@ -50,6 +48,7 @@ Volcanos(chat.ONIMPORT, {
p = can.misc.Resource(can, icons||can.Conf(mdb.ICONS))||p; can.base.beginWith(p, "/") && (p = location.origin + p)
share(document.title, p, content, link)
}, can.user.agent.init(can.user.agent.cmd, can.user.agent._init_content, can.user.agent._init_icons)
+ location.pathname == "/" && can.onmotion.delay(can, function() { share(document.title, can.misc.Resource(can, can.user.info.favicon)) }, 300)
})
})
},