diff --git a/src/main/resources/static/css/fileSelect.css b/src/main/resources/static/css/fileSelect.css index 7e5553443..579135c3d 100644 --- a/src/main/resources/static/css/fileSelect.css +++ b/src/main/resources/static/css/fileSelect.css @@ -274,10 +274,8 @@ .googleDriveButton { - position: absolute; - bottom: 15px; - right: 5px; - width: 5%; + width: 2.5rem; + pointer-events: auto; } .googleDriveButton img { width:100% diff --git a/src/main/resources/static/js/googleFilePicker.js b/src/main/resources/static/js/googleFilePicker.js index 042242699..d9b02fdf1 100644 --- a/src/main/resources/static/js/googleFilePicker.js +++ b/src/main/resources/static/js/googleFilePicker.js @@ -4,6 +4,8 @@ let tokenClient; let accessToken = sessionStorage.getItem(SESSION_STORAGE_ID); + document.getElementById("google-drive-button").addEventListener('click', onGoogleDriveButtonClick); + /** * Callback after api.js is loaded. */ @@ -33,7 +35,9 @@ /** * Sign in the user upon button click. */ - function handleAuthClick() { + function onGoogleDriveButtonClick(e) { + + e.stopPropagation(); tokenClient.callback = (response) => { if (response.error !== undefined) { diff --git a/src/main/resources/templates/fragments/common.html b/src/main/resources/templates/fragments/common.html index b0004cba2..f39c5d704 100644 --- a/src/main/resources/templates/fragments/common.html +++ b/src/main/resources/templates/fragments/common.html @@ -229,7 +229,7 @@ };
-
- -
- google drive +
+ google drive +