Skip to content

Commit

Permalink
Accept user-supplied Connect URL in web gui
Browse files Browse the repository at this point in the history
  • Loading branch information
martinhpedersen committed May 1, 2024
1 parent 6dfb14e commit 3521664
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
7 changes: 3 additions & 4 deletions web/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -271,12 +271,11 @@ <h4 class="modal-title" id="myModalLabel">Connect to remote node...</h4>
</div>
</div>
</form>
<span
id="connectURLPreview"
<input
id="connectURLInput"
class="text-muted"
style="float: left; position: relative; bottom: 5px"
style="border: none; width: 80%; float: left; position: relative; bottom: 5px"
>
</span>
<span
id="qsyWarning"
class="text-danger"
Expand Down
7 changes: 5 additions & 2 deletions web/src/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,9 @@ function initConnectModal() {
$('#radioOnlyInput').change(onConnectInputChange);
$('#addrInput').change(onConnectInputChange);
$('#targetInput').change(onConnectInputChange);
$('#connectURLInput').change((e) => {
setConnectValues($(e.target).val())
});
$('#updateRmslistButton').click((e) => {
$(e.target).prop('disabled', true);
updateRmslist(true);
Expand Down Expand Up @@ -583,9 +586,9 @@ function setConnectValues(url) {
setConnectURL(url);
}

function getConnectURL() { return $('#connectURLPreview').text(); }
function getConnectURL() { return $('#connectURLInput').val(); }

function setConnectURL(url) { $('#connectURLPreview').text(url); }
function setConnectURL(url) { $('#connectURLInput').val(url); }

function buildConnectURL() {
let url =
Expand Down

0 comments on commit 3521664

Please sign in to comment.