fix alignment on hsInput in safari
authorAjay Bura <ajbura@gmail.com>
Sat, 6 Nov 2021 12:55:56 +0000 (18:25 +0530)
committerAjay Bura <ajbura@gmail.com>
Sat, 6 Nov 2021 12:55:56 +0000 (18:25 +0530)
Signed-off-by: Ajay Bura <ajbura@gmail.com>
src/app/templates/auth/Auth.jsx
src/app/templates/auth/Auth.scss

index b73a1983099496c723388697a4517151f9781056..214ca480ab315205e91136e92bd7adeb2750bfd7 100644 (file)
@@ -87,7 +87,8 @@ function Homeserver({ onChange }) {
   }, [hs]);
 
   useEffect(async () => {
-    const configFileUrl = `${window.location.href}/config.json`;
+    const link = window.location.href;
+    const configFileUrl = `${link}${link[link.length - 1] === '/' ? '' : '/'}config.json`;
     try {
       const result = await (await fetch(configFileUrl, { method: 'GET' })).json();
       const selectedHs = result?.defaultHomeserver;
index e872d0ceaeb677eca18d9f88552f0daeff902405..cb539428da1805480ad9ea1db14d8b2fc826f663 100644 (file)
 .homeserver-form {
   display: flex;
   margin-bottom: var(--sp-extra-tight);
-  line-height: 0;
+  align-items: flex-end;
   & > .input-container {
     flex: 1;
+    line-height: 0;
     & .input {
       border-right: unset;
       border-radius: var(--bo-radius) 0 0 var(--bo-radius);
@@ -67,7 +68,6 @@
   }
   & .ic-btn {
     height: 46px;
-    align-self: flex-end;
     border: 1px solid var(--bg-surface-border);
     border-radius: 0 var(--bo-radius) var(--bo-radius) 0;
   }