Skip to content

Commit

Permalink
Merge pull request #41008 from nextcloud/fix/36965-fix-trusted-server…
Browse files Browse the repository at this point in the history
…-input

Fix trusted server input field
  • Loading branch information
susnux authored Oct 20, 2023
2 parents a6d137c + 0af42db commit 4828ac3
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
10 changes: 9 additions & 1 deletion apps/federation/css/settings-admin.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,13 @@
}

#ocFederationAddServer #serverUrl {
width: 300px;
width: 270px;
}

.serverUrl-block {
max-width: 310px;
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
}
2 changes: 1 addition & 1 deletion apps/federation/js/settings-admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@

$btnAddServer.on('click', function() {
$btnAddServer.addClass('hidden');
$wrapper.find(".serverUrl").removeClass('hidden');
$inpServerUrl
.removeClass('hidden')
.focus();
});

Expand Down
11 changes: 8 additions & 3 deletions apps/federation/templates/settings-admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,14 @@
</ul>
<p id="ocFederationAddServer">
<button id="ocFederationAddServerButton" class=""><?php p($l->t('+ Add trusted server')); ?></button>
<input id="serverUrl" class="hidden" type="text" value="" placeholder="<?php p($l->t('Trusted server')); ?>" name="server_url"/>
<button id="ocFederationSubmit" class="hidden"><?php p($l->t('Add')); ?></button>
<span class="msg"></span>
<div class="serverUrl hidden">
<div class="serverUrl-block">
<label for="serverUrl"><?php p($l->t('Trusted server')); ?></label>
<input id="serverUrl" type="text" value="" placeholder="<?php p($l->t('Trusted server')); ?>" name="server_url"/>
<button id="ocFederationSubmit" class="hidden"><?php p($l->t('Add')); ?></button>
</div>
<span class="msg"></span>
</div>
</p>

</div>

0 comments on commit 4828ac3

Please sign in to comment.