Removing control_url, will now be included in stream path itself

This commit is contained in:
James Barnsley
2021-10-23 20:42:46 +13:00
parent 3b1609d5b8
commit 11cd13f576
17 changed files with 131 additions and 376 deletions

View File

@ -3,7 +3,7 @@ import pathlib
from mopidy import config, ext
__version__ = "3.59.1"
__version__ = "3.60.0"
logger = logging.getLogger(__name__)
@ -27,7 +27,6 @@ class Extension(ext.Extension):
schema["enabled"] = config.Boolean()
schema["country"] = config.String()
schema["locale"] = config.String()
schema["control_url"] = config.String()
schema["snapcast_enabled"] = config.Boolean()
schema["snapcast_host"] = config.String()
schema["snapcast_port"] = config.String()

View File

@ -1152,40 +1152,6 @@ class IrisCore(pykka.ThreadingActor):
logger.debug(error)
return error
##
# Get a summary of this server's state.
# This is a collection of RPC-available requests, but those cannot be called via CORS, so this
# serves as a proxy for other Mopidy instances to be able to collect states.
##
async def get_server_state(self, *args, **kwargs):
callback = kwargs.get("callback", False)
request = kwargs.get("request", False)
current_track = self.core.playback.get_current_track().get()
if current_track:
# We dump the JSON to convert the Track to JSON, but we need to then loads back to JSON
# for the response.
current_track = json.loads(json.dumps(current_track, cls=ModelJSONEncoder))
images = self.core.library.get_images([current_track["uri"]]).get()
if images:
current_track["images"] = json.loads(
json.dumps(
images[current_track["uri"]],
cls=ModelJSONEncoder
)
)
response = {
"snapcast_stream": self.config["iris"]["snapcast_stream"],
"playback_state": self.core.playback.get_state().get(),
"current_track": current_track,
}
if callback:
callback(response)
else:
return response
##
# Send our current track data to the configured Snapcast server's stream
# Uses snapcast server and stream details as defined in configuration

View File

@ -2,7 +2,6 @@
enabled = true
country = NZ
locale = en_NZ
control_url = http://localhost:6680
snapcast_enabled = true
snapcast_host = localhost
snapcast_port = 1780

View File

@ -3767,6 +3767,22 @@ h5 {
font-weight: 700;
}
h1 > a,
h2 > a,
h3 > a,
h4 > a,
h5 > a {
color: inherit;
text-decoration: none;
}
h1 > a:hover,
h2 > a:hover,
h3 > a:hover,
h4 > a:hover,
h5 > a:hover {
text-decoration: underline;
}
p a {
color: inherit;
}
@ -3786,10 +3802,19 @@ p a:hover {
.no-results {
text-align: center;
padding: 40px;
color: #383734;
color: #a3a19f;
font-style: italic;
font-size: 1.2rem;
}
.light-theme .no-results {
color: #383734;
}
@media (prefers-color-scheme: light) {
.auto-theme .no-results {
color: #383734;
}
}
.placeholder {
display: inline-block;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -115,8 +115,8 @@
// Release details
// These are automatically injected to built HTML
var build = "1634950029";
var version = "3.59.1";
var build = "1634974444";
var version = "3.60.0";
// Construct the script tag
var js = document.createElement("script");

View File

@ -1,5 +1,5 @@
{
"manifest_version": "3.59.1",
"manifest_version": "3.60.0",
"short_name": "Iris",
"name": "Iris",
"icons": [