Browse Source

Bump 1.4.4

master
Leonie 1 month ago
parent
commit
7c575cb4ef
4 changed files with 22 additions and 9 deletions
  1. 1
    1
      config.xml
  2. 1
    1
      www/app.html
  3. 19
    6
      www/app.js
  4. 1
    1
      www/player.js

+ 1
- 1
config.xml View File

@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<widget id="com.Sommerlichter.nordcast" version="1.4.3" xmlns="http://www.w3.org/ns/widgets" xmlns:gap="http://phonegap.com/ns/1.0">
<widget id="com.Sommerlichter.nordcast" version="1.4.4" xmlns="http://www.w3.org/ns/widgets" xmlns:gap="http://phonegap.com/ns/1.0">
<name>Nordcast</name>
<description>
A new podcast app

+ 1
- 1
www/app.html View File

@@ -60,7 +60,7 @@
<p><span id="text__darkmode">Enable dark mode</span> <img src="darth.png" id="starwars" class="emoji"> <input id="cdark__mode" type="checkbox"></p>
<br />
<h2 id="text__about">About</h2>
<p>Nordcast 1.4.3</p>
<p>Nordcast 1.4.4</p>
<p><a href="#" onclick="window.open('https://nordcast.app', '_system'); return false;">Website</a> | <a href="#" onclick="window.open('https://git.koyu.space/koyu/nordcast', '_system'); return false;">Source code</a></p>
<p>&copy; koyu.space 2019</p>
</div>

+ 19
- 6
www/app.js View File

@@ -138,15 +138,27 @@ $(document).ready(function() {
});
$("#view__cast").show();
},200);
var feedtitle = callback.feed.title.split(" | ")[0].split(" - ")[0].split(" – ")[0];
$("#text__cast").html(twemoji.parse(feedtitle));
try {
var feedtitle = callback.feed.title.split(" | ")[0].split(" - ")[0].split(" – ")[0];
} catch(e) {
var feedtitle = callback.feed.title;
}
try {
$("#text__cast").html(twemoji.parse(feedtitle));
} catch (e) {
$("#text__cast").html(feedtitle);
}
if (callback.feed.subtitle === undefined || callback.feed.subtitle === "" || callback.feed.subtitle.includes("…")) {
$("#text__subtitle").hide();
} else {
$("#text__subtitle").html("<br><br>"+callback.feed.subtitle+"<br><br><br>");
$("#text__subtitle").show();
}
var author = callback.feed.author.split(" | ")[0].split(" - ")[0].split(" – ")[0];
try {
var author = callback.feed.author.split(" | ")[0].split(" - ")[0].split(" – ")[0];
} catch(e) {
var author = callback.feed.author;
}
if (author === "Nordisch Media Tobias Ain") {
author = "Nordisch Media";
}
@@ -185,7 +197,7 @@ $(document).ready(function() {
if (shownotes === "") {
shownotes = item.summary;
}
$("#podtable tbody").append("<tr><td><i onclick=\"playcast('"+podurl+"', '"+secret+"', '"+Base64.encode(item.title.replaceAll("'", ""))+"', '"+callback.feed.author.split(" | ")[0].split(" - ")[0].split(" – ")[0]+"', '"+callback.feed.image.href+"', '"+feed+"', '"+feedtitle+"')\" id=\"cast-"+secret+"\" class=\"playbutton ion-md-play\"></i></td><td>"+twemoji.parse(item.title)+"</td><td><a onclick=\"shownotes('"+Base64.encode(shownotes)+"')\"><i class=\"ion-md-information-circle-outline\" id=\"snbutton\"></i></a></td></tr>");
$("#podtable tbody").append("<tr><td><i onclick=\"playcast('"+podurl+"', '"+secret+"', '"+Base64.encode(item.title.replaceAll("'", ""))+"', '"+Base64.encode(callback.feed.author.split(" | ")[0].split(" - ")[0].split(" – ")[0])+"', '"+callback.feed.image.href+"', '"+feed+"', '"+Base64.encode(feedtitle)+"')\" id=\"cast-"+secret+"\" class=\"playbutton ion-md-play\"></i></td><td>"+twemoji.parse(item.title)+"</td><td><a onclick=\"shownotes('"+Base64.encode(shownotes)+"')\"><i class=\"ion-md-information-circle-outline\" id=\"snbutton\"></i></a></td></tr>");
});
$("#button__follow").click(function() {
var feed = Base64.decode(findGetParameter("cast")).split("\n")[0];
@@ -257,7 +269,8 @@ $(document).ready(function() {
$("#searchtable tbody").append("<tr><td><a class=\"cardlink\" data-cast=\""+Base64.encode(item.feedUrl)+"\"><img src=\""+item.artworkUrl100+"\" class=\"card__small\"></a></td><td><a class=\"cardlink\" data-cast=\""+Base64.encode(item.feedUrl)+"\" style=\"color:#333;\">"+twemoji.parse(item.collectionName)+"</a></td></tr>");
});
if (data["resultCount"] === 0) {
$("#searchtable").html("<p id=\"object__noresults\"><b id=\"error__noresults\">No results found.</b></p>")
$("#searchtable").html("<p id=\"object__noresults\"><b id=\"error__noresults\">No results found.</b></p>");
$("#view__"+findGetParameter("view")).show();
}
});
});
@@ -286,7 +299,7 @@ $(document).ready(function() {
$("img").on("load", function() {
$("#view__"+findGetParameter("view")).show();
});
},0);
},100);
$.get("views/mainview.html", function(data) {
$("#view__main").html(data.replaceAll("<style>\n#view__main {\n padding: 40px 20px 0px !important;\n}\n</style>", ""));
window.setTimeout(function() {

+ 1
- 1
www/player.js View File

@@ -66,7 +66,7 @@ function playcast(file, secret, title, author, podcover, feed, feedtitle) {
if (author === "Nordisch Media Tobias Ain") {
author = "Nordisch Media";
}
var podtitle = feedtitle + " - " + Base64.decode(title);
var podtitle = Base64.decode(feedtitle) + " - " + Base64.decode(title);
$("#podtitle").html(twemoji.parse(podtitle));
if (podtitle.length > 50) {
$("#podtitle").html("<marquee>"+$("#podtitle").html()+"<marquee>");

Loading…
Cancel
Save