Fixed minor things for track search provider

This commit is contained in:
Krateng 2020-09-25 04:42:19 +02:00
parent 616c24fb5b
commit 13f2746171
No known key found for this signature in database
GPG Key ID: 46735607861C6FCE
3 changed files with 6 additions and 3 deletions

View File

@ -10,7 +10,7 @@
<td class='icon'><div style="background-image:url('{{ img }}')"></div></td>
{% if "artists" in entity %}
{% if settings('TRACK_SEARCH_PROVIDER') != 'None' %}
{% if settings('TRACK_SEARCH_PROVIDER') is not none %}
<td class='searchProvider'>{{ links.link_search(entity) }}</td>
{% endif %}
<td class='track'>

View File

@ -61,7 +61,7 @@
{% macro link_search(entity) -%}
{% set track = entity.title %}
{% set artists = entity.artists|join(', ') %}
{% set artists = entity.artists|join(' ') %}
{% if settings('TRACK_SEARCH_PROVIDER') == 'YouTube' %}
{% set provider = 'https://www.youtube.com/results?search_query=' %}
@ -80,7 +80,7 @@
{% elif settings('TRACK_SEARCH_PROVIDER') == 'Apple' %}
{% set provider = 'https://music.apple.com/us/search/song?term=' %}
{% else %}
{% set provider = 'https://www.google.com/search?q=' %}
{% set provider = 'https://duckduckgo.com/?q=' %}
{% endif %}
{% set icon = '<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" class="w-6 h-6" viewBox="0 0 20 20"><path d="M18 3a1 1 0 00-1.196-.98l-10 2A1 1 0 006 5v9.114A4.369 4.369 0 005 14c-1.657 0-3 .895-3 2s1.343 2 3 2 3-.895 3-2V7.82l8-1.6v5.894A4.37 4.37 0 0015 12c-1.657 0-3 .895-3 2s1.343 2 3 2 3-.895 3-2V3z"/></svg>' %}

View File

@ -501,6 +501,9 @@ table.list td.searchProvider {
width: 20px;
padding-right: 5px;
}
table.list td.searchProvider svg {
height:17px;
}
table.list td.searchProvider:hover {
color: gold;