diff --git a/plugins/Sidebar/SidebarPlugin.py b/plugins/Sidebar/SidebarPlugin.py index 1f87bfc4..4bf716f2 100644 --- a/plugins/Sidebar/SidebarPlugin.py +++ b/plugins/Sidebar/SidebarPlugin.py @@ -137,7 +137,7 @@ class UiWebsocketPlugin(object): """)) def sidebarRenderFileStats(self, body, site): - body.append(_(u"<li><label>{_[Files]}</label><ul class='graph graph-stacked'>")) + body.append(_(u"<li><label>{_[Files]} <small><a href='#Site+directory' id='link-directory' class='link-right'>{_[Open site directory]}</a></small></label><ul class='graph graph-stacked'>")) extensions = ( ("html", "yellow"), @@ -418,10 +418,6 @@ class UiWebsocketPlugin(object): <li> <a href='#Save' class='button' id='button-settings'>{_[Save site settings]}</a> </li> - - <li> - <a href='#Directory' class='button' id='button-directory'>{_[Open site directory]}</a> - </li> """)) def sidebarRenderContents(self, body, site): diff --git a/plugins/Sidebar/media/Sidebar.coffee b/plugins/Sidebar/media/Sidebar.coffee index 6efa0928..e35f712b 100644 --- a/plugins/Sidebar/media/Sidebar.coffee +++ b/plugins/Sidebar/media/Sidebar.coffee @@ -352,9 +352,11 @@ class Sidebar extends Class @updateHtmlTag() return false + # Open site directory - @tag.find("#button-directory").off("click touchend").on "click touchend", => + @tag.find("#link-directory").off("click touchend").on "click touchend", => @wrapper.ws.cmd "serverShowdirectory", ["site", @wrapper.site_info.address] + return false # Sign and publish content.json $(document).on "click touchend", => diff --git a/plugins/Sidebar/media/Sidebar.css b/plugins/Sidebar/media/Sidebar.css index 895ba178..fa7ac7dc 100644 --- a/plugins/Sidebar/media/Sidebar.css +++ b/plugins/Sidebar/media/Sidebar.css @@ -11,6 +11,9 @@ #inner-iframe { transition: 0.3s ease-in-out; transform-origin: left; outline: 1px solid transparent; } .body-sidebar iframe { transform: rotateY(5deg); opacity: 0.8; pointer-events: none } /* translateX(-200px) scale(0.95)*/ +.sidebar .link-right { color: white; text-decoration: none; border-bottom: 1px solid #666; text-transform: uppercase; float: right; margin-right: 7px; margin-top: 1px; } +.sidebar .link-right:hover { border-color: #CCC; } +.sidebar .link-right:active { background-color: #444 } /* SIDEBAR */ .sidebar-container { width: 100%; height: 100%; overflow: hidden; position: fixed; } diff --git a/plugins/Sidebar/media/all.css b/plugins/Sidebar/media/all.css index 29398d36..fb793aa7 100644 --- a/plugins/Sidebar/media/all.css +++ b/plugins/Sidebar/media/all.css @@ -90,6 +90,9 @@ #inner-iframe { -webkit-transition: 0.3s ease-in-out; -moz-transition: 0.3s ease-in-out; -o-transition: 0.3s ease-in-out; -ms-transition: 0.3s ease-in-out; transition: 0.3s ease-in-out ; transform-origin: left; outline: 1px solid transparent; } .body-sidebar iframe { -webkit-transform: rotateY(5deg); -moz-transform: rotateY(5deg); -o-transform: rotateY(5deg); -ms-transform: rotateY(5deg); transform: rotateY(5deg) ; opacity: 0.8; pointer-events: none } /* translateX(-200px) scale(0.95)*/ +.sidebar .link-right { color: white; text-decoration: none; border-bottom: 1px solid #666; text-transform: uppercase; float: right; margin-right: 7px; margin-top: 1px; } +.sidebar .link-right:hover { border-color: #CCC; } +.sidebar .link-right:active { background-color: #444 } /* SIDEBAR */ .sidebar-container { width: 100%; height: 100%; overflow: hidden; position: fixed; } diff --git a/plugins/Sidebar/media/all.js b/plugins/Sidebar/media/all.js index 4486bfdf..db119ee7 100644 --- a/plugins/Sidebar/media/all.js +++ b/plugins/Sidebar/media/all.js @@ -691,9 +691,10 @@ window.initScrollable = function () { return false; }; })(this)); - this.tag.find("#button-directory").off("click touchend").on("click touchend", (function(_this) { + this.tag.find("#link-directory").off("click touchend").on("click touchend", (function(_this) { return function() { - return _this.wrapper.ws.cmd("serverShowdirectory", ["site", _this.wrapper.site_info.address]); + _this.wrapper.ws.cmd("serverShowdirectory", ["site", _this.wrapper.site_info.address]); + return false; }; })(this)); $(document).on("click touchend", (function(_this) { diff --git a/src/Config.py b/src/Config.py index 1488122c..d14f2738 100644 --- a/src/Config.py +++ b/src/Config.py @@ -10,7 +10,7 @@ class Config(object): def __init__(self, argv): self.version = "0.6.2" - self.rev = 3371 + self.rev = 3372 self.argv = argv self.action = None self.config_file = "zeronet.conf"