summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rw-r--r--js/Article.js1
-rwxr-xr-xjs/Headlines.js34
-rw-r--r--js/PrefFilterTree.js12
3 files changed, 11 insertions, 36 deletions
diff --git a/js/Article.js b/js/Article.js
index f2c4007f5..507560ee4 100644
--- a/js/Article.js
+++ b/js/Article.js
@@ -233,7 +233,6 @@ define(["dojo/_base/declare"], function (declare) {
if (force || e.offsetTop + e.offsetHeight > (ctr.scrollTop + ctr.offsetHeight) ||
e.offsetTop < ctr.scrollTop) {
- // expanded cdm has a 4px margin now
ctr.scrollTop = e.offsetTop;
Element.hide("floatingTitle");
diff --git a/js/Headlines.js b/js/Headlines.js
index 00b7f88f4..e0caddc2a 100755
--- a/js/Headlines.js
+++ b/js/Headlines.js
@@ -173,15 +173,11 @@ define(["dojo/_base/declare"], function (declare) {
ft.setAttribute("data-article-id", id);
ft.innerHTML = header.innerHTML;
- ft.firstChild.innerHTML = "<img class='anchor marked-pic' src='images/page_white_go.png' " +
- "onclick=\"Article.cdmScrollToId(" + id + ", true)\">" + ft.firstChild.innerHTML;
- this.initFloatingMenu();
+ ft.select(".dijitCheckBox")[0].outerHTML = "<i class=\"material-icons anchor\" onclick=\"Article.cdmScrollToId(" + id + ", true)\">expand_more</i>";
- const cb = ft.select(".rchk")[0];
+ this.initFloatingMenu();
- if (cb)
- cb.parentNode.removeChild(cb);
}
if (row.hasClassName("Unread"))
@@ -498,19 +494,9 @@ define(["dojo/_base/declare"], function (declare) {
const row = $("RROW-" + id);
if (row) {
- const imgs = $$("img[class*=marked-pic][class*=marked-" + id + "]");
-
- imgs.each((img) => {
- if (!row.hasClassName("marked")) {
- img.src = img.src.replace("mark_unset", "mark_set");
- query.mark = 1;
- } else {
- img.src = img.src.replace("mark_set", "mark_unset");
- query.mark = 0;
- }
- });
row.toggleClassName("marked");
+ query.mark = row.hasClassName("marked") ? 1 : 0;
if (!client_only)
xhrPost("backend.php", query, (transport) => {
@@ -524,19 +510,8 @@ define(["dojo/_base/declare"], function (declare) {
if (row) {
const query = {op: "rpc", id: id, method: "publ"};
- const imgs = $$("img[class*=pub-pic][class*=pub-" + id + "]");
-
- imgs.each((img) => {
- if (!row.hasClassName("published")) {
- img.src = img.src.replace("pub_unset", "pub_set");
- query.pub = 1;
- } else {
- img.src = img.src.replace("pub_set", "pub_unset");
- query.pub = 0;
- }
- });
-
row.toggleClassName("published");
+ query.pub = row.hasClassName("published") ? 1 : 0;
if (!client_only)
xhrPost("backend.php", query, (transport) => {
@@ -1026,6 +1001,7 @@ define(["dojo/_base/declare"], function (declare) {
const menu = new dijit.Menu({
id: "floatingMenu",
+ selector: ".hlMenuAttach",
targetNodeIds: ["floatingTitle"]
});
diff --git a/js/PrefFilterTree.js b/js/PrefFilterTree.js
index be321fd21..f4fc8ecf2 100644
--- a/js/PrefFilterTree.js
+++ b/js/PrefFilterTree.js
@@ -23,13 +23,13 @@ define(["dojo/_base/declare", "dojo/dom-construct", "lib/CheckBoxTree"], functio
domConstruct.place(param, tnode.rowNode, 'next');
}
- if (this.model.store.getValue(args.item, 'id') != 'root') {
- const img = dojo.doc.createElement('img');
- img.src ='images/filter.png';
- img.className = 'marked-pic';
- tnode._filterIconNode = img;
+ /* if (this.model.store.getValue(args.item, 'id') != 'root') {
+ const i = dojo.doc.createElement('i');
+ i.className = 'material-icons filter';
+ i.innerHTML = 'label';
+ tnode._filterIconNode = i;
domConstruct.place(tnode._filterIconNode, tnode.labelNode, 'before');
- }
+ } */
return tnode;
},