Showing 1 changed files with 9 additions and 3 deletions
+9 -3
scripts/host_manager.pl
@@ -3054,6 +3054,13 @@ sub app_html {
3054 3054
     .vhost-pill-row { display: flex; flex-wrap: wrap; gap: 4px; }
3055 3055
     .vhost-pill-row .pill { margin: 0; }
3056 3056
     .vhost-host-select { width: 100%; max-width: 100%; min-height: 34px; }
3057
+    .vhost-cert { display: grid; gap: 5px; min-width: 0; }
3058
+    .vhost-cert-main { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; align-items: center; }
3059
+    .vhost-cert-select { width: 100%; max-width: 100%; min-height: 34px; }
3060
+    .vhost-cert-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 24px; }
3061
+    .vhost-cert-links { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
3062
+    .vhost-cert-links .linkbtn { padding: 3px 7px; font-size: 12px; }
3063
+    .vhost-cert-validity { font-size: 12px; }
3057 3064
     .vhost-inline-editor { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(260px, 1fr) auto; gap: 8px; padding: 10px; border-bottom: 1px solid var(--line); background: #fff; }
3058 3065
     .vhost-delete { color: var(--bad); }
3059 3066
     .host-inline-row td { padding: 0; background: #fff; }
@@ -3907,7 +3914,7 @@ sub app_html {
3907 3914
       });
3908 3915
       document.querySelectorAll('[data-vhost-cert-issue]').forEach(button => {
3909 3916
         button.addEventListener('click', () => {
3910
-          issueVhostCertificate(button.dataset.vhostCertIssue || '', button.dataset.currentCertificate || '').catch(e => {
3917
+          issueVhostCertificate(button.dataset.vhostCertIssue || '', button.dataset.currentCertificate || '', button).catch(e => {
3911 3918
             if (!isAuthLost(e)) msg(e.message);
3912 3919
           });
3913 3920
         });
@@ -4042,11 +4049,10 @@ sub app_html {
4042 4049
       }
4043 4050
     }
4044 4051
 
4045
-    async function issueVhostCertificate(vhost, currentCertificateId) {
4052
+    async function issueVhostCertificate(vhost, currentCertificateId, button) {
4046 4053
       if (!await ensureAuthenticated('Autentifica-te inainte de emitere.')) return;
4047 4054
       if (!vhost) return;
4048 4055
       if (currentCertificateId && !confirm(`Issue a new certificate for ${vhost} and replace the current association?`)) return;
4049
-      const button = document.querySelector(`[data-vhost-cert-issue="${CSS.escape(vhost)}"]`);
4050 4056
       if (button) button.disabled = true;
4051 4057
       try {
4052 4058
         const result = await api('/api/vhosts/issue-certificate', {