various digest style updates and fixes
This commit is contained in:
parent
c7402c3898
commit
54b8564d98
33
digest.css
33
digest.css
|
@ -1,9 +1,9 @@
|
||||||
body#ttrssDigest {
|
body#ttrssDigest {
|
||||||
background : #fafafa;
|
|
||||||
color : black;
|
color : black;
|
||||||
font-family : sans-serif;
|
font-family : sans-serif;
|
||||||
font-size : 12px;
|
font-size : 12px;
|
||||||
margin : 0px;
|
margin : 0px;
|
||||||
|
background : url("images/tile.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
a {
|
a {
|
||||||
|
@ -62,7 +62,7 @@ a:hover {
|
||||||
#content {
|
#content {
|
||||||
position : absolute;
|
position : absolute;
|
||||||
left : 0px;
|
left : 0px;
|
||||||
top : 30px;
|
top : 0px;
|
||||||
right : 0px;
|
right : 0px;
|
||||||
bottom : 0px;
|
bottom : 0px;
|
||||||
-webkit-transition: left 0.2s linear, right 0.2s linear;
|
-webkit-transition: left 0.2s linear, right 0.2s linear;
|
||||||
|
@ -78,9 +78,6 @@ a:hover {
|
||||||
bottom : 0px;
|
bottom : 0px;
|
||||||
top : 30px;
|
top : 30px;
|
||||||
background : white;
|
background : white;
|
||||||
border-width : 0px 0px 0px 2px;
|
|
||||||
border-color : #e0e0e0;
|
|
||||||
border-style : solid;
|
|
||||||
z-index : -1;
|
z-index : -1;
|
||||||
opacity : 0;
|
opacity : 0;
|
||||||
-webkit-transition: opacity 0.2s linear;
|
-webkit-transition: opacity 0.2s linear;
|
||||||
|
@ -155,9 +152,10 @@ a:hover {
|
||||||
bottom : 0px;
|
bottom : 0px;
|
||||||
font-size : 14px;
|
font-size : 14px;
|
||||||
overflow : auto;
|
overflow : auto;
|
||||||
border-width : 0px 4px 0px 0px;
|
border-width : 0px 3px 0px 0px;
|
||||||
border-color : #e0e0e0;
|
border-color : #88b0f0;
|
||||||
border-style : solid;
|
border-style : solid;
|
||||||
|
background : #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
#feeds ul#feeds-content img {
|
#feeds ul#feeds-content img {
|
||||||
|
@ -170,41 +168,39 @@ a:hover {
|
||||||
#feeds ul#feeds-content div.unread-ctr {
|
#feeds ul#feeds-content div.unread-ctr {
|
||||||
color : #d0d0d0;
|
color : #d0d0d0;
|
||||||
padding-left : 10px;
|
padding-left : 10px;
|
||||||
display : inline;
|
float : right;
|
||||||
}
|
}
|
||||||
|
|
||||||
#feeds ul#feeds-content li {
|
#feeds ul#feeds-content li {
|
||||||
padding : 10px;
|
padding : 10px;
|
||||||
clear : both;
|
clear : both;
|
||||||
cursor : pointer;
|
cursor : pointer;
|
||||||
border-width : 1px 0px 1px 0px;
|
color : #303030;
|
||||||
border-color : transparent;
|
|
||||||
border-style : solid;
|
|
||||||
color : gray;
|
|
||||||
white-space : nowrap;
|
white-space : nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
#feeds ul#feeds-content li.selected {
|
#feeds ul#feeds-content li.selected {
|
||||||
background : white;
|
background : white;
|
||||||
border-color : #e0e0e0;
|
|
||||||
border-style : solid;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#feeds ul#feeds-content {
|
#feeds ul#feeds-content {
|
||||||
list-style-type : none;
|
list-style-type : none;
|
||||||
font-weight : bold;
|
font-weight : bold;
|
||||||
margin : 10px 10px 10px 10px;
|
margin : 0px;
|
||||||
padding : 0px;
|
padding : 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#headlines {
|
#headlines {
|
||||||
font-size : 14px;
|
font-size : 14px;
|
||||||
position : absolute;
|
position : absolute;
|
||||||
left : 302px;
|
left : 303px;
|
||||||
top : 0px;
|
top : 30px;
|
||||||
bottom : 0px;
|
bottom : 0px;
|
||||||
right : 0px;
|
right : 0px;
|
||||||
overflow : auto;
|
overflow : auto;
|
||||||
|
border-width : 0px 3px 0px 0px;
|
||||||
|
border-style : solid;
|
||||||
|
border-color : #88b0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#headlines h1 a {
|
#headlines h1 a {
|
||||||
|
@ -237,10 +233,10 @@ a:hover {
|
||||||
padding : 10px;
|
padding : 10px;
|
||||||
color : gray;
|
color : gray;
|
||||||
clear : left;
|
clear : left;
|
||||||
background : #eeeeee;
|
|
||||||
border-width : 0px 0px 1px 0px;
|
border-width : 0px 0px 1px 0px;
|
||||||
border-style : solid;
|
border-style : solid;
|
||||||
border-color : #e0e0e0;
|
border-color : #e0e0e0;
|
||||||
|
background : #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
#headlines ul#headlines-content a.title {
|
#headlines ul#headlines-content a.title {
|
||||||
|
@ -299,6 +295,7 @@ a:hover {
|
||||||
|
|
||||||
#headlines ul#headlines-content div.info {
|
#headlines ul#headlines-content div.info {
|
||||||
font-size : 11px;
|
font-size : 11px;
|
||||||
|
margin-top : 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#headlines ul#headlines-content div.info a {
|
#headlines ul#headlines-content div.info a {
|
||||||
|
|
|
@ -79,9 +79,6 @@
|
||||||
<?php echo __("Regular version") ?></a>
|
<?php echo __("Regular version") ?></a>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<span class="title">Tiny Tiny RSS</span>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="article"><div id="article-content"> </div></div>
|
<div id="article"><div id="article-content"> </div></div>
|
||||||
|
|
62
js/digest.js
62
js/digest.js
|
@ -261,18 +261,17 @@ function view(article_id) {
|
||||||
else
|
else
|
||||||
publ_part = "<img title='"+__("Publish article")+"' onclick=\"toggle_pub(this, "+article.id+")\" src='images/pub_unset.png'>";
|
publ_part = "<img title='"+__("Publish article")+"' onclick=\"toggle_pub(this, "+article.id+")\" src='images/pub_unset.png'>";
|
||||||
|
|
||||||
var tmp = "<div id=\"toolbar\">" +
|
var tmp = "<div id=\"inner\">" +
|
||||||
"<a target=\"_blank\" href=\""+article.url+"\">" + __("Original article") + "</a>" +
|
|
||||||
"<div style=\"float : right\"><a href=\"#\" onclick=\"close_article()\">" +
|
|
||||||
__("Close this panel") + "</a></div></div>" +
|
|
||||||
"<div id=\"inner\">" +
|
|
||||||
"<div id=\"ops\">" +
|
"<div id=\"ops\">" +
|
||||||
mark_part +
|
mark_part +
|
||||||
publ_part +
|
publ_part +
|
||||||
"</div>" +
|
"</div>" +
|
||||||
"<h1>" + article.title + "</h1>" +
|
"<h1>" + "<a target=\"_blank\" href=\""+article.url+"\">" +
|
||||||
|
article.title + "</a>" + "</h1>" +
|
||||||
"<div id=\"tags\">" +
|
"<div id=\"tags\">" +
|
||||||
tags_part +
|
tags_part +
|
||||||
|
"<div style=\"float : right\"><a href=\"#\" onclick=\"close_article()\">" +
|
||||||
|
__("close") + "</a></div>" +
|
||||||
"</div>" +
|
"</div>" +
|
||||||
article.content + "</div>";
|
article.content + "</div>";
|
||||||
|
|
||||||
|
@ -415,8 +414,12 @@ function add_feed_entry(feed) {
|
||||||
|
|
||||||
icon_part = "<img src='" + get_feed_icon(feed) + "'/>";
|
icon_part = "<img src='" + get_feed_icon(feed) + "'/>";
|
||||||
|
|
||||||
|
var title = (feed.title.length > 30) ?
|
||||||
|
feed.title.substring(0, 30) + "…" :
|
||||||
|
feed.title;
|
||||||
|
|
||||||
var tmp_html = "<li id=\"F-"+feed.id+"\" onclick=\"viewfeed("+feed.id+")\">" +
|
var tmp_html = "<li id=\"F-"+feed.id+"\" onclick=\"viewfeed("+feed.id+")\">" +
|
||||||
icon_part + feed.title +
|
icon_part + title +
|
||||||
"<div class='unread-ctr'>" + "<span class=\"unread\">" + feed.unread + "</span>" +
|
"<div class='unread-ctr'>" + "<span class=\"unread\">" + feed.unread + "</span>" +
|
||||||
"</div>" + "</li>";
|
"</div>" + "</li>";
|
||||||
|
|
||||||
|
@ -470,7 +473,7 @@ function add_headline_entry(article, feed, no_effects) {
|
||||||
"<div class='body'>" +
|
"<div class='body'>" +
|
||||||
"<div onclick=\"view("+article.id+")\" class='excerpt'>" +
|
"<div onclick=\"view("+article.id+")\" class='excerpt'>" +
|
||||||
article.excerpt + "</div>" +
|
article.excerpt + "</div>" +
|
||||||
"<div class='info'>";
|
"<div onclick=\"view("+article.id+")\" class='info'>";
|
||||||
|
|
||||||
/* tmp_html += "<a href=\#\" onclick=\"viewfeed("+feed.id+")\">" +
|
/* tmp_html += "<a href=\#\" onclick=\"viewfeed("+feed.id+")\">" +
|
||||||
feed.title + "</a> " + " @ "; */
|
feed.title + "</a> " + " @ "; */
|
||||||
|
@ -653,6 +656,8 @@ function init_second_stage() {
|
||||||
parse_feeds(transport);
|
parse_feeds(transport);
|
||||||
Element.hide("overlay");
|
Element.hide("overlay");
|
||||||
|
|
||||||
|
document.onkeydown = hotkey_handler;
|
||||||
|
|
||||||
window.setTimeout('viewfeed(-4)', 100);
|
window.setTimeout('viewfeed(-4)', 100);
|
||||||
_update_timeout = window.setTimeout('update()', 5*1000);
|
_update_timeout = window.setTimeout('update()', 5*1000);
|
||||||
} });
|
} });
|
||||||
|
@ -839,3 +844,44 @@ function toggle_select_article(elem) {
|
||||||
exception_error("toggle_select_article", e);
|
exception_error("toggle_select_article", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function hotkey_handler(e) {
|
||||||
|
try {
|
||||||
|
|
||||||
|
if (e.target.nodeName == "INPUT" || e.target.nodeName == "TEXTAREA") return;
|
||||||
|
|
||||||
|
var keycode = false;
|
||||||
|
var shift_key = false;
|
||||||
|
|
||||||
|
var cmdline = $('cmdline');
|
||||||
|
|
||||||
|
try {
|
||||||
|
shift_key = e.shiftKey;
|
||||||
|
} catch (e) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
if (window.event) {
|
||||||
|
keycode = window.event.keyCode;
|
||||||
|
} else if (e) {
|
||||||
|
keycode = e.which;
|
||||||
|
}
|
||||||
|
|
||||||
|
var keychar = String.fromCharCode(keycode);
|
||||||
|
|
||||||
|
if (keycode == 16) return; // ignore lone shift
|
||||||
|
if (keycode == 17) return; // ignore lone ctrl
|
||||||
|
|
||||||
|
switch (keycode) {
|
||||||
|
case 27: // esc
|
||||||
|
close_article();
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
console.log("KP: CODE=" + keycode + " CHAR=" + keychar);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
} catch (e) {
|
||||||
|
exception_error("hotkey_handler", e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue