|
|
|
@ -147972,37 +147972,46 @@ var App = /*#__PURE__*/function (_React$Component) {
|
|
|
|
var message = _hint$originalExcepti.message; // Filter out issues that destroy our quota and that are not informative enough to
|
|
|
|
var message = _hint$originalExcepti.message; // Filter out issues that destroy our quota and that are not informative enough to
|
|
|
|
// actually resolve.
|
|
|
|
// actually resolve.
|
|
|
|
|
|
|
|
|
|
|
|
if (message && (message.match(/Websocket/i) || message.match(/NotSupportedError/i) || message.match(/Non-Error promise rejection captured with keys: call, message, value/i) || message.match(/Cannot read property 'addChunk' of undefined/i))) {
|
|
|
|
if (message && (message.match(/Websocket/i) || message.match(/NotSupportedError/i) || message.match(/NotSupportedError: The element has no supported sources./i) || message.match(/Non-Error promise rejection captured with keys: call, message, value/i) || message.match(/Cannot read property 'addChunk' of undefined/i))) {
|
|
|
|
return null;
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return event;
|
|
|
|
return event;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
} // Load query param settings
|
|
|
|
} // Accept incoming preconfiguration via URL parameters and inject into application state.
|
|
|
|
|
|
|
|
// For example: iris?snapcast={"enabled":true,"host":"myserver.local"}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var configs = ['ui', 'spotify', 'pusher', 'snapcast', 'mopidy', 'google', 'lastfm', 'genius'];
|
|
|
|
|
|
|
|
var params = new URLSearchParams(window.location.search);
|
|
|
|
var params = new URLSearchParams(window.location.search);
|
|
|
|
var changed = [];
|
|
|
|
|
|
|
|
var urlParams = params.forEach(function (v, k) {
|
|
|
|
|
|
|
|
if (!configs.includes(k)) return;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
if (params) {
|
|
|
|
_util_storage__WEBPACK_IMPORTED_MODULE_51__["default"].set(k, JSON.parse(v));
|
|
|
|
params.forEach(function (value, key) {
|
|
|
|
changed.push(k);
|
|
|
|
try {
|
|
|
|
} catch (error) {
|
|
|
|
var json = JSON.parse(value);
|
|
|
|
console.error(error);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (changed.length > 0) {
|
|
|
|
switch (key) {
|
|
|
|
changed.forEach(function (k) {
|
|
|
|
case 'ui':
|
|
|
|
return params["delete"](k);
|
|
|
|
case 'spotify':
|
|
|
|
|
|
|
|
case 'pusher':
|
|
|
|
|
|
|
|
case 'snapcast':
|
|
|
|
|
|
|
|
case 'mopidy':
|
|
|
|
|
|
|
|
_this.props["".concat(key, "Actions")].set(json);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
} catch (e) {
|
|
|
|
|
|
|
|
console.error('Preconfiguration failed', {
|
|
|
|
|
|
|
|
e: e,
|
|
|
|
|
|
|
|
key: key,
|
|
|
|
|
|
|
|
value: value
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
var url = window.location.toString().replace(window.location.search, params.toString());
|
|
|
|
|
|
|
|
console.log("Settings changed, redirecting to ".concat(url), changed);
|
|
|
|
|
|
|
|
window.location.assign(url);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
_this.handleInstallPrompt = _this.handleInstallPrompt.bind(_assertThisInitialized(_this));
|
|
|
|
_this.handleInstallPrompt = _this.handleInstallPrompt.bind(_assertThisInitialized(_this));
|
|
|
|
@ -169754,11 +169763,12 @@ function reducer() {
|
|
|
|
/*!*******************************************!*\
|
|
|
|
/*!*******************************************!*\
|
|
|
|
!*** ./src/js/services/pusher/actions.js ***!
|
|
|
|
!*** ./src/js/services/pusher/actions.js ***!
|
|
|
|
\*******************************************/
|
|
|
|
\*******************************************/
|
|
|
|
/*! exports provided: setPort, setUsername, connect, disconnect, upgrade, reload, restart, localScan, getConnections, connectionAdded, updateConnection, connectionChanged, connectionRemoved, request, getConfig, getVersion, deliverBroadcast, deliverMessage, getRadio, startRadio, updateRadio, stopRadio, radioStarted, radioChanged, radioStopped, debug, getQueueMetadata, queueMetadataChanged, addQueueMetadata, getPinned, addPinned, removePinned, setPinned, pinnedUpdated, getCommands, setCommand, setCommands, removeCommand, runCommand, commandsUpdated */
|
|
|
|
/*! exports provided: set, setPort, setUsername, connect, disconnect, upgrade, reload, restart, localScan, getConnections, connectionAdded, updateConnection, connectionChanged, connectionRemoved, request, getConfig, getVersion, deliverBroadcast, deliverMessage, getRadio, startRadio, updateRadio, stopRadio, radioStarted, radioChanged, radioStopped, debug, getQueueMetadata, queueMetadataChanged, addQueueMetadata, getPinned, addPinned, removePinned, setPinned, pinnedUpdated, getCommands, setCommand, setCommands, removeCommand, runCommand, commandsUpdated */
|
|
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
|
|
|
|
|
|
|
|
|
|
"use strict";
|
|
|
|
"use strict";
|
|
|
|
__webpack_require__.r(__webpack_exports__);
|
|
|
|
__webpack_require__.r(__webpack_exports__);
|
|
|
|
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "set", function() { return set; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setPort", function() { return setPort; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setPort", function() { return setPort; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setUsername", function() { return setUsername; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setUsername", function() { return setUsername; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "connect", function() { return connect; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "connect", function() { return connect; });
|
|
|
|
@ -169799,6 +169809,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "removeCommand", function() { return removeCommand; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "removeCommand", function() { return removeCommand; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "runCommand", function() { return runCommand; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "runCommand", function() { return runCommand; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "commandsUpdated", function() { return commandsUpdated; });
|
|
|
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "commandsUpdated", function() { return commandsUpdated; });
|
|
|
|
|
|
|
|
function set(data) {
|
|
|
|
|
|
|
|
return {
|
|
|
|
|
|
|
|
type: 'PUSHER_SET',
|
|
|
|
|
|
|
|
data: data
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
function setPort(port) {
|
|
|
|
function setPort(port) {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
type: 'PUSHER_SET_PORT',
|
|
|
|
type: 'PUSHER_SET_PORT',
|
|
|
|
@ -170945,6 +170961,9 @@ function reducer() {
|
|
|
|
connecting: false
|
|
|
|
connecting: false
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
case 'PUSHER_SET':
|
|
|
|
|
|
|
|
return _objectSpread(_objectSpread({}, pusher), action.data);
|
|
|
|
|
|
|
|
|
|
|
|
case 'PUSHER_SET_PORT':
|
|
|
|
case 'PUSHER_SET_PORT':
|
|
|
|
return _objectSpread(_objectSpread({}, pusher), {}, {
|
|
|
|
return _objectSpread(_objectSpread({}, pusher), {}, {
|
|
|
|
port: action.port
|
|
|
|
port: action.port
|
|
|
|
|