third login tip

This commit is contained in:
caishi 2022-12-09 14:45:38 +08:00
parent 56ff7958b4
commit 6a2d04c9a5
2 changed files with 10 additions and 6 deletions

View File

@ -1,7 +1,7 @@
import React, { Component } from 'react';
import Dialog from 'material-ui/Dialog';
import { notification } from 'antd';
import { notification , Tooltip } from 'antd';
import axios from 'axios';
import educoderLogo from './educoder.png';
@ -581,7 +581,9 @@ class LoginDialog extends Component {
{settings.third_party_new.map((item,key)=>{
return(
<a href={`${item.url}`} className="ml12 mr12">
<img src={item.name === "educoder" ? educoderLogo : item.name === "qq" ? qqlogo : item.name === "wechat" ? WeChatlogo : item.name === "gitee" ? giteelogo : item.name === "github" ? githublogo : ""} width="42px" alt={`${item.name}登录`} />
<Tooltip title={`使用${item.name === "qq" ? "QQ":item.name === "wechat" ? "微信" : item.name}账号登录`}>
<img src={item.name === "educoder" ? educoderLogo : item.name === "qq" ? qqlogo : item.name === "wechat" ? WeChatlogo : item.name === "gitee" ? giteelogo : item.name === "github" ? githublogo : ""} width="42px" alt={`${item.name}登录`} />
</Tooltip>
</a>
)
})

View File

@ -1,5 +1,5 @@
import React, { useEffect, useState } from "react";
import { Form, Input, Button, Checkbox } from "antd";
import { Form, Input, Button, Checkbox , Tooltip } from "antd";
import { Link } from "react-router-dom";
import axios from 'axios';
import educoderLogo from '../login/educoder.png';
@ -118,9 +118,11 @@ function Login(props){
<span className={"startlogin"}>&nbsp;快速登录&nbsp;</span>
{setting.third_party_new.map((item,key)=>{
return(
<a href={`${item.url}`} className="ml15 mr15">
<img src={item.name === "educoder" ? educoderLogo : item.name === "qq" ? qqlogo : item.name === "wechat" ? WeChatlogo : item.name === "gitee" ? giteelogo : item.name === "github" ? githublogo : ""} width="46px" alt={`${item.name}登录`} />
</a>
<a href={`${item.url}`} className="ml15 mr15">
<Tooltip title={`使用${item.name === "qq" ? "QQ":item.name === "wechat" ? "微信" : item.name}账号登录`}>
<img src={item.name === "educoder" ? educoderLogo : item.name === "qq" ? qqlogo : item.name === "wechat" ? WeChatlogo : item.name === "gitee" ? giteelogo : item.name === "github" ? githublogo : ""} width="46px" alt={`${item.name}登录`}/>
</Tooltip>
</a>
)
})
}