FeedMonkey HTML5 RSS Feed Reader

Check-in [703769dde1]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Add option to invoke Mozilla's "reader view" mode on articles.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/clean | trunk | master
Files: files | file ages | folders
SHA3-256:703769dde1f727df7af3b3042ed73fec697ce6f0a6fb27e9b261882773c16b6a
User & Date: vandys 2019-04-21 00:08:32
Context
2019-07-27
14:35
Fiddle the saved state of reader mode check-in: 9af73d7e32 user: vandys tags: origin/clean, trunk, master
2019-04-21
00:08
Add option to invoke Mozilla's "reader view" mode on articles. check-in: 703769dde1 user: vandys tags: origin/clean, trunk, master
2019-04-20
17:24
Whoops, class method for login attempt. check-in: 14d57ed185 user: vandys tags: origin/clean, trunk, master
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to index.html.

43
44
45
46
47
48
49


50
51
52
53
54
55
56
        <a class="button small" href="#font-bigger"><span class="icon">&#11014;</span></a>
      </li>
      <li><a href="#color-white" class="color-white button"><span class="icon">&#59290;</span> White</a></li>
      <li><a href="#color-blue" class="color-blue button"><span class="icon">&#59290;</span> Blue</a></li>
      <li><a href="#color-yellow" class="color-yellow button"><span class="icon">&#59290;</span> Yellow</a></li>
      <li><a href="#color-black" class="color-black button"><span class="icon">&#59290;</span> Black</a></li>
      <li><a href="#color-red" class="color-red button"><span class="icon">&#59290;</span> Red (default)</a></li>


      <li class="reset-info"><a href="#reset-info" class="button"><span class="icon">&#59160;</span> View those info bubbles again</a></li>
      <li><a href="#logout" class="button"><span class="icon">&#59201;</span> Log out</a></li>
      <li class="version"><span class="icon">&#59141;</span> You're running version <em id="version"></em></li>
      <li class="madeby"><span class="icon">&#59141;</span> Made by <a href="http://jabs.nu/" target="_blank">Jabs Nu</a></li>
      <li class="icons"><span class="icon">&#128325;</span> Icons by <a href="http://www.entypo.com/" target="_blank">Entypo</a></li>
    </ul>
  </article>







>
>







43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
        <a class="button small" href="#font-bigger"><span class="icon">&#11014;</span></a>
      </li>
      <li><a href="#color-white" class="color-white button"><span class="icon">&#59290;</span> White</a></li>
      <li><a href="#color-blue" class="color-blue button"><span class="icon">&#59290;</span> Blue</a></li>
      <li><a href="#color-yellow" class="color-yellow button"><span class="icon">&#59290;</span> Yellow</a></li>
      <li><a href="#color-black" class="color-black button"><span class="icon">&#59290;</span> Black</a></li>
      <li><a href="#color-red" class="color-red button"><span class="icon">&#59290;</span> Red (default)</a></li>
      <li><button id="readerbtn" onclick="toggleReader();"
       >Use Reader Mode</button></li>
      <li class="reset-info"><a href="#reset-info" class="button"><span class="icon">&#59160;</span> View those info bubbles again</a></li>
      <li><a href="#logout" class="button"><span class="icon">&#59201;</span> Log out</a></li>
      <li class="version"><span class="icon">&#59141;</span> You're running version <em id="version"></em></li>
      <li class="madeby"><span class="icon">&#59141;</span> Made by <a href="http://jabs.nu/" target="_blank">Jabs Nu</a></li>
      <li class="icons"><span class="icon">&#128325;</span> Icons by <a href="http://www.entypo.com/" target="_blank">Entypo</a></li>
    </ul>
  </article>

Changes to js/App.js.

8
9
10
11
12
13
14













15
16
17
18
19
20
21
..
31
32
33
34
35
36
37






38
39
40
41
42
43
44
...
413
414
415
416
417
418
419

420
421
422
423
424
425
426
427
    const e = document.getElementById("feed" + feedid.toString());
    if (e.style.display == "none") {
	e.style.display = "";
    } else {
	e.style.display = "none";
    }
}














class App {
    constructor() {
	this.login = new Login(this);
	this.currentIndex = -1;

	let color = localStorage.color;
................................................................................
	}
	this.numArticles(numArticles);
	let maxDownload = localStorage.maxDownload;
	if (!maxDownload) {
	    maxDownload = 500000;
	}
	this.maxDownload(maxDownload);






    }

    authenticate() {
    }

    handle_hashchange(e) {
	// do not reload page
................................................................................
	const page_id = "#full";

	$(page_id + " .date").innerHTML =
	    (new Date(parseInt(article.updated, 10) * 1000)).toLocaleString();

	const title = $(page_id + " .title");
	title.innerHTML = article.title;

	title.href = article.link;

	$(page_id + " .feed_title").innerHTML = article.feed_title;

	$(page_id + " .author").innerHTML = "";
	if (article.author && article.author.length > 0) {
	    $(page_id + " .author").innerHTML = "&ndash; " + article.author; 
	}







>
>
>
>
>
>
>
>
>
>
>
>
>







 







>
>
>
>
>
>







 







>
|







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
..
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
...
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
    const e = document.getElementById("feed" + feedid.toString());
    if (e.style.display == "none") {
	e.style.display = "";
    } else {
	e.style.display = "none";
    }
}

// Toggle whether reader mode should be called when you
//  open an article
var reader_mode = false;
function toggleReader() {
    if (reader_mode) {
	localStorage.reader = reader_mode = false;
	readerbtn.style.backgroundColor = "Grey";
    } else {
	localStorage.reader = reader_mode = true;
	readerbtn.style.backgroundColor = "LightGreen";
    }
}

class App {
    constructor() {
	this.login = new Login(this);
	this.currentIndex = -1;

	let color = localStorage.color;
................................................................................
	}
	this.numArticles(numArticles);
	let maxDownload = localStorage.maxDownload;
	if (!maxDownload) {
	    maxDownload = 500000;
	}
	this.maxDownload(maxDownload);

	// Set the inversion of our saved reader value,
	//  then use our toggle function to get the UI
	//  set to the right color.
	reader_mode = !(localStorage.reader || false);
	toggleReader();
    }

    authenticate() {
    }

    handle_hashchange(e) {
	// do not reload page
................................................................................
	const page_id = "#full";

	$(page_id + " .date").innerHTML =
	    (new Date(parseInt(article.updated, 10) * 1000)).toLocaleString();

	const title = $(page_id + " .title");
	title.innerHTML = article.title;
	title.href = (reader_mode ? "about:reader?url=" : "") +
	    article.link;

	$(page_id + " .feed_title").innerHTML = article.feed_title;

	$(page_id + " .author").innerHTML = "";
	if (article.author && article.author.length > 0) {
	    $(page_id + " .author").innerHTML = "&ndash; " + article.author; 
	}