зеркало из https://github.com/nextcloud/news.git
Align counter to the right and hide on hover
This commit is contained in:
Родитель
3d85e9477f
Коммит
072e5f18c9
|
@ -16,7 +16,7 @@
|
|||
#addfolder { background: url('%webroot%/core/img/places/folder.svg') no-repeat left center; padding-left: 20px !important; }
|
||||
#addfeed { background: url('%appswebroot%/apps/news/img/rss.svg') no-repeat left center; padding-left: 20px !important; }
|
||||
|
||||
#unreaditemcounter { position: relative; background: #5E5E5E; border-radius: 5px; padding: 0 5px; height: 90%; margin-top: auto; margin-bottom: auto; color: white; text-align: center; }
|
||||
#unreaditemcounter { position: relative; background: #5E5E5E; border-radius: 5px; padding: 0 5px; color: white; text-align: center; margin-right: 0.3em; }
|
||||
|
||||
ul.controls li { float: left; }
|
||||
|
||||
|
@ -44,7 +44,7 @@ ul#feedfoldermenu { position:fixed; margin-left: 0; bottom: 2.8em; border-left:1
|
|||
|
||||
li { padding: 0px !important; }
|
||||
li.menuItem { margin-left:0.7em; margin-right:0.7em; float: none !important; text-align: left; }
|
||||
li.feeds_list { margin-left: 20px !important; }
|
||||
li.feeds_list { margin-left: 20px !important; text-align: right; }
|
||||
|
||||
li.folder_list:hover { color: rgb(0, 0, 0) !important; background: none !important; }
|
||||
li.feeds_list:hover { background: none repeat scroll 0% 0% rgb(221, 221, 221) !important; }
|
||||
|
|
23
js/news.js
23
js/news.js
|
@ -153,7 +153,7 @@ News={
|
|||
updateAll:function() {
|
||||
$.post(OC.filePath('news', 'ajax', 'feedlist.php'),function(jsondata){
|
||||
if(jsondata.status == 'success'){
|
||||
|
||||
|
||||
}
|
||||
else{
|
||||
OC.dialogs.alert(jsondata.data.message, t('news', 'Error'));
|
||||
|
@ -196,24 +196,29 @@ $(document).ready(function(){
|
|||
}).next().hide();
|
||||
|
||||
var list = $('.collapsable,.feeds_list').hover(function() {
|
||||
var elem = $(this).find('#feeds_delete,#feeds_edit');
|
||||
if(elem.css('display') == 'none')
|
||||
elem.css('display', 'inline');
|
||||
else
|
||||
elem.css('display', 'none');
|
||||
var counter = $(this).find('#unreaditemcounter');
|
||||
var elem = $(this).find('#feeds_delete,#feeds_edit');
|
||||
if(elem.css('display') == 'none') {
|
||||
elem.css('display', 'inline');
|
||||
counter.css('display', 'none');
|
||||
}
|
||||
else {
|
||||
elem.css('display', 'none');
|
||||
counter.css('display', 'inline');
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
list.find('#feeds_delete').hide();
|
||||
list.find('#feeds_edit').hide();
|
||||
|
||||
|
||||
$('#addfeedfolder').click(function(event) {
|
||||
event.stopPropagation();
|
||||
});
|
||||
|
||||
|
||||
var updateInterval = 200000; //how often the feeds should update (in msec)
|
||||
setInterval('News.Feed.updateAll()', updateInterval);
|
||||
|
||||
|
||||
});
|
||||
|
||||
$(document).click(function(event) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче