Commit 1826a78e by libai

测试

parent 9a8a29de
...@@ -41,10 +41,10 @@ ...@@ -41,10 +41,10 @@
margin-top: 0px; margin-top: 0px;
cursor: pointer; cursor: pointer;
} }
.google-login-btn .abcRioButton { .buttonDiv {
height: 70px !important; height: 70px !important;
width: 390px !important; width: 390px !important;
opacity: 0; opacity: 0 !important;
} }
.more-login { .more-login {
text-align: center; text-align: center;
......
...@@ -40,11 +40,12 @@ ...@@ -40,11 +40,12 @@
margin: 0 auto; margin: 0 auto;
margin-top: 0px; margin-top: 0px;
cursor: pointer; cursor: pointer;
.abcRioButton {
}
.buttonDiv{
height: 70px !important; height: 70px !important;
width: 390px !important; width: 390px !important;
opacity: 0; opacity: 0 !important;
}
} }
.more-login{ .more-login{
text-align: center; text-align: center;
......
...@@ -5,7 +5,7 @@ function loginGo(){ ...@@ -5,7 +5,7 @@ function loginGo(){
html+=' <div style="display: none;" class="login-box1">'; html+=' <div style="display: none;" class="login-box1">';
html+=' <div class="login-title">登入</div>'; html+=' <div class="login-title">登入</div>';
html+=' <div class="phone-login-btn"></div>'; html+=' <div class="phone-login-btn"></div>';
html+=' <div class="google-login-btn" id="buttonDiv"></div>'; html+=' <div class="google-login-btn" ><div id="buttonDiv"></div></div>';
html+=' <div class="more-login"><img src="https://www.footseen.xyz/yazhaiTest/images/more-login.png" alt=""></div>'; html+=' <div class="more-login"><img src="https://www.footseen.xyz/yazhaiTest/images/more-login.png" alt=""></div>';
html+=' <div class="more-login-box">'; html+=' <div class="more-login-box">';
html+=' <div class="more-login-icon"><img src="https://www.footseen.xyz/yazhaiTest/images/login-icon2.png" alt=""></div>'; html+=' <div class="more-login-icon"><img src="https://www.footseen.xyz/yazhaiTest/images/login-icon2.png" alt=""></div>';
...@@ -128,7 +128,17 @@ function loginGo(){ ...@@ -128,7 +128,17 @@ function loginGo(){
function handleCredentialResponse(response) { function handleCredentialResponse(response) {
console.log("Encoded JWT ID token: " + response.credential); console.log("Encoded JWT ID token: " + response.credential);
} }
window.onload = function () {
google.accounts.id.initialize({
client_id: "YOUR_GOOGLE_CLIENT_ID",
callback: handleCredentialResponse
});
google.accounts.id.renderButton(
document.getElementById("buttonDiv"),
{ theme: "outline", size: "large" } // customization attributes
);
google.accounts.id.prompt(); // also display the One Tap dialog
}
var html=[]; var html=[];
html+='<div style="display: none;" class=nav-login-btn>登入/註冊</div>'; html+='<div style="display: none;" class=nav-login-btn>登入/註冊</div>';
...@@ -232,18 +242,8 @@ function loginGo(){ ...@@ -232,18 +242,8 @@ function loginGo(){
layer.closeAll() layer.closeAll()
} }
}) })
window.onload = function () {
google.accounts.id.initialize({
client_id: "YOUR_GOOGLE_CLIENT_ID",
callback: handleCredentialResponse
});
google.accounts.id.renderButton(
document.getElementById("buttonDiv"),
{ theme: "outline", size: "large" } // customization attributes
);
google.accounts.id.prompt(); // also display the One Tap dialog
}
console.log(2121)
}) })
var jsSrc =(navigator.language || navigator.browserLanguage).toLowerCase(); var jsSrc =(navigator.language || navigator.browserLanguage).toLowerCase();
if(jsSrc.indexOf('zh-cn')!=-1){ if(jsSrc.indexOf('zh-cn')!=-1){
......
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
</script> </script>
<head> <head>
<meta charset="utf-8"/> <meta charset="utf-8"/>
<meta name="google-signin-scope" content="profile email"> <!-- <meta name="google-signin-scope" content="profile email">
<meta name="google-signin-client_id" content="534183685500-ag0vai0jh6todldi4rg6lvp0gcsojk0n.apps.googleusercontent.com"> <meta name="google-signin-client_id" content="534183685500-ag0vai0jh6todldi4rg6lvp0gcsojk0n.apps.googleusercontent.com"> -->
<meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/> <meta name="viewport" content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no"/>
<meta name="apple-mobile-web-app-capable" content="yes"> <meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent"> <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment