diff --git a/base/web/render.go b/base/web/render.go index 9af6f7af..93685776 100644 --- a/base/web/render.go +++ b/base/web/render.go @@ -175,5 +175,6 @@ const ( CODE_GIT_STATUS = "web.code.git.status" CODE_GIT_REPOS = "web.code.git.repos" CHAT_FAVOR = "web.chat.favor" + CHAT_FLOWS = "web.chat.flows" CHAT_IFRAME = "web.chat.iframe" ) diff --git a/base/web/flows.css b/core/chat/flows.css similarity index 100% rename from base/web/flows.css rename to core/chat/flows.css diff --git a/base/web/flows.go b/core/chat/flows.go similarity index 99% rename from base/web/flows.go rename to core/chat/flows.go index d4f480be..29e88807 100644 --- a/base/web/flows.go +++ b/core/chat/flows.go @@ -1,4 +1,4 @@ -package web +package chat import ( ice "shylinux.com/x/icebergs" diff --git a/base/web/flows.js b/core/chat/flows.js similarity index 98% rename from base/web/flows.js rename to core/chat/flows.js index 9d6f2a4c..beea210d 100644 --- a/base/web/flows.js +++ b/core/chat/flows.js @@ -96,8 +96,8 @@ Volcanos(chat.ONIMPORT, { rect.Value(html.CLASS, item.status) text.Value(html.CLASS, item.status) } - if (can.ui._height < y+height) { can.ui._height = y+height, can.onimport.layout(can), rect.scrollIntoView() } - if (can.ui._width < x+width) { can.ui._width = x+width, can.onimport.layout(can), rect.scrollIntoView() } + if (can.ui._height < y+height) { can.ui._height = y+height, can.onimport.layout(can), can.isCmdMode() && rect.scrollIntoView() } + if (can.ui._width < x+width) { can.ui._width = x+width, can.onimport.layout(can), can.isCmdMode() && rect.scrollIntoView() } }, layout: function(can) { if (can.page.isDisplay(can.ui.profile)) { var profile = can._profile_plugin @@ -124,7 +124,7 @@ Volcanos(chat.ONDETAIL, { if (_class.indexOf(html.SELECT) > -1) { target.Value(html.CLASS, _class.filter(function(c) { return c != html.SELECT }).join(lex.SP).trim()) } } }), can.page.Select(can, item._tr.parentNode, "", function(target) { can.page.ClassList.set(can, target, html.SELECT, target == item._tr) }) - item._rect.scrollIntoView() + can.isCmdMode() && item._rect.scrollIntoView() }, onclick: function(event, can, _sub, item) { switch (_sub.svg.style.cursor) { case "e-resize": can.Update(can.request(event, can.Action("direct") == "horizon"? {prev: item.hash}: {from: item.hash}), [ctx.ACTION, mdb.INSERT]); break diff --git a/core/chat/macos/applications.go b/core/chat/macos/applications.go index 494a173a..b5d07817 100644 --- a/core/chat/macos/applications.go +++ b/core/chat/macos/applications.go @@ -30,6 +30,7 @@ func init() { AppInstall(m, "", cli.RUNTIME, mdb.ICON, "usr/icons/info.png") AppInstall(m, "", web.DREAM, mdb.ICON, "usr/icons/Mission Control.png") AppInstall(m, "", web.CODE_VIMER, mdb.ICON, "usr/icons/vimer.png") + AppInstall(m, "", web.CHAT_FLOWS, mdb.ICON, "usr/icons/flows.png") AppInstall(m, "", web.CODE_COMPILE, mdb.ICON, "usr/icons/go.png") AppInstall(m, "", web.CODE_GIT_STATUS, mdb.ICON, "usr/icons/git.jpg") }}, diff --git a/core/chat/macos/desktop.go b/core/chat/macos/desktop.go index 7c555b38..abf84987 100644 --- a/core/chat/macos/desktop.go +++ b/core/chat/macos/desktop.go @@ -21,6 +21,7 @@ func init() { DeskAppend(m, "Photos", web.WIKI_FEEL) DeskAppend(m, "Grapher", web.WIKI_DRAW) DeskAppend(m, "Calendar", web.TEAM_PLAN, ctx.ARGS, team.MONTH) + DeskAppend(m, "flows", web.CHAT_FLOWS) } }}, ice.CTX_EXIT: {Hand: func(m *ice.Message, arg ...string) { mdb.HashExport(m) }},