fix several issues, update to version 0.6.3
This commit is contained in:
parent
ceb3107643
commit
a6e5a2c4bb
@ -1,5 +1,9 @@
|
||||
## 0.6.3 –
|
||||
## 0.6.3 – 2018-09-08
|
||||
### Fixed
|
||||
- Fix table size issues for mobile clients
|
||||
[#72](https://git.project-insanity.org/onny/nextcloud-app-radio/issues/72) @onny
|
||||
- Include custom User-Agent header
|
||||
[#75](https://git.project-insanity.org/onny/nextcloud-app-radio/issues/75) @onny
|
||||
- Fix loading all favorites
|
||||
[#58](https://git.project-insanity.org/onny/nextcloud-app-radio/issues/58) @onny
|
||||
- Remember favorite stations sort order
|
||||
|
@ -76,14 +76,6 @@
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* make sure there's enough room for the file actions */
|
||||
#body-user #filestable {
|
||||
min-width: 688px; /* 768 (mobile break) - 80 (nav width) */
|
||||
}
|
||||
#body-user #controls {
|
||||
min-width: 688px; /* 768 (mobile break) - 80 (nav width) */
|
||||
}
|
||||
|
||||
#filestable tbody tr {
|
||||
background-color: #fff;
|
||||
height: 51px;
|
||||
|
1
img/folder_thumb.svg
Normal file
1
img/folder_thumb.svg
Normal file
@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" version="1.1" height="16"><path fill="#0082c9" d="m1.5 2c-0.25 0-0.5 0.25-0.5 0.5v11c0 0.26 0.24 0.5 0.5 0.5h13c0.26 0 0.5-0.241 0.5-0.5v-9c0-0.25-0.25-0.5-0.5-0.5h-6.5l-2-2z"/></svg>
|
After Width: | Height: | Size: 255 B |
28
js/main.js
28
js/main.js
@ -1,5 +1,7 @@
|
||||
var MODULE = (function (radio) {
|
||||
|
||||
var version = "0.6.3"
|
||||
|
||||
$(document).ready(function () {
|
||||
|
||||
// Scroll event handler
|
||||
@ -200,7 +202,7 @@ var MODULE = (function (radio) {
|
||||
|
||||
station_ids.forEach(function (station_id, idx) {
|
||||
var url = "https://www.radio-browser.info/webservice/json/stations/byid/"+station_ids[idx];
|
||||
$.getJSON( url , function( data ) {
|
||||
$.getJSON( url , {"User-Agent": "Nextcloud Radio/"+version }, function( data ) {
|
||||
|
||||
if (data.length === 0) {
|
||||
station_array = station_array.concat([{'id': station_id, 'name': 'Broken radio station entry :(', 'favicon': '', 'url': ''}])
|
||||
@ -246,6 +248,7 @@ var MODULE = (function (radio) {
|
||||
data: {
|
||||
name: query,
|
||||
limit: 20,
|
||||
"User-Agent": "Nextcloud Radio/"+version,
|
||||
offset: offset
|
||||
},
|
||||
dataType: 'json',
|
||||
@ -263,5 +266,28 @@ var MODULE = (function (radio) {
|
||||
radio.switch_menu(0);
|
||||
});
|
||||
|
||||
radio.action_load_categories = function (){
|
||||
$('#emptycontent').addClass('hidden');
|
||||
$('#filestable').show();
|
||||
$('.nofilterresults').addClass('hidden');
|
||||
$('.loading').addClass('hidden');
|
||||
$('tbody').append('<tr>\
|
||||
<td class="favcolumn">\
|
||||
<a href="#" class="favorite">\
|
||||
<span class="icon-stationfav"></span>\
|
||||
<span class="hidden-visually">Favorite</span>\
|
||||
</a>\
|
||||
</td>\
|
||||
<td class="filename">\
|
||||
<label for="select-files-3">\
|
||||
<div class="thumbnail" style="background-image:url(); background-size: 32px;"></div>\
|
||||
</label>\
|
||||
<a class="name" href="#">\
|
||||
<span class="nametext"><span class="innernametext">Languages</span></span>\
|
||||
</a>\
|
||||
</td>\
|
||||
</tr>');
|
||||
};
|
||||
|
||||
return radio;
|
||||
}(MODULE || {}));
|
||||
|
@ -16,6 +16,11 @@ var MODULE = (function (radio) {
|
||||
radio.switch_menu(2);
|
||||
});
|
||||
|
||||
$('a.nav-icon-systemtagsfilter').click(function(e) {
|
||||
e.preventDefault();
|
||||
radio.switch_menu(3);
|
||||
});
|
||||
|
||||
radio.load_menu_state = function() {
|
||||
var menu_state = 0;
|
||||
var baseUrl = OC.generateUrl('/apps/radio/getMenuState');
|
||||
@ -73,6 +78,11 @@ var MODULE = (function (radio) {
|
||||
$('li.nav-favorites').addClass('active');
|
||||
radio.action_load_favorites();
|
||||
break;
|
||||
case 2:
|
||||
history.pushState("", "", "#categories");
|
||||
$('li.nav-categories').addClass('active');
|
||||
radio.action_load_categories();
|
||||
break;
|
||||
}
|
||||
}, 500);
|
||||
};
|
||||
|
@ -2,10 +2,10 @@
|
||||
style('radio', 'main');
|
||||
script('radio', 'main');
|
||||
script('radio', 'navigation');
|
||||
script('radio', 'player');
|
||||
script('radio', 'player');
|
||||
?>
|
||||
|
||||
<div id="content" class="app-files" role="main">
|
||||
<div id="content" class="app-radio" role="main">
|
||||
<div id="app-navigation">
|
||||
<ul class="with-icon">
|
||||
<li data-id="files" class="nav-files">
|
||||
|
Loading…
Reference in New Issue
Block a user