aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2023-10-20 16:19:24 +0200
committerGitHub <noreply@github.com>2023-10-20 16:19:24 +0200
commit4828ac352145d2d3eb002e55631bac2d494c96a9 (patch)
tree87fa30b8eb0361873b256378b5b062058aa9d134
parenta6d137c9a7910841ba4e35b0286608ad4202a871 (diff)
parent0af42db2c7720ab93b0f0622d6c4c4ada94b0a4a (diff)
downloadnextcloud-server-4828ac352145d2d3eb002e55631bac2d494c96a9.tar.gz
nextcloud-server-4828ac352145d2d3eb002e55631bac2d494c96a9.zip
Merge pull request #41008 from nextcloud/fix/36965-fix-trusted-server-input
Fix trusted server input field
-rw-r--r--apps/federation/css/settings-admin.css10
-rw-r--r--apps/federation/js/settings-admin.js2
-rw-r--r--apps/federation/templates/settings-admin.php11
3 files changed, 18 insertions, 5 deletions
diff --git a/apps/federation/css/settings-admin.css b/apps/federation/css/settings-admin.css
index c4c846bd812..18d691f8eb1 100644
--- a/apps/federation/css/settings-admin.css
+++ b/apps/federation/css/settings-admin.css
@@ -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;
}
diff --git a/apps/federation/js/settings-admin.js b/apps/federation/js/settings-admin.js
index fed0f441e01..fd97bcefda5 100644
--- a/apps/federation/js/settings-admin.js
+++ b/apps/federation/js/settings-admin.js
@@ -45,8 +45,8 @@
$btnAddServer.on('click', function() {
$btnAddServer.addClass('hidden');
+ $wrapper.find(".serverUrl").removeClass('hidden');
$inpServerUrl
- .removeClass('hidden')
.focus();
});
diff --git a/apps/federation/templates/settings-admin.php b/apps/federation/templates/settings-admin.php
index 3fa7a02a02e..62922b19994 100644
--- a/apps/federation/templates/settings-admin.php
+++ b/apps/federation/templates/settings-admin.php
@@ -31,9 +31,14 @@ style('federation', 'settings-admin')
</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>