mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-04 05:10:19 +08:00
Show CustomGithubCorner in other pages.
This commit is contained in:
105
web/src/App.js
105
web/src/App.js
@ -425,9 +425,47 @@ class App extends Component {
|
|||||||
|
|
||||||
renderContent() {
|
renderContent() {
|
||||||
if (!Setting.isMobile()) {
|
if (!Setting.isMobile()) {
|
||||||
return (
|
return (
|
||||||
<div style={{display: 'flex', flex: 'auto',width:"100%",flexDirection: 'column'}}>
|
<div style={{display: 'flex', flex: 'auto',width:"100%",flexDirection: 'column'}}>
|
||||||
<Layout style={{display: 'flex', alignItems: 'stretch'}}>
|
<Layout style={{display: 'flex', alignItems: 'stretch'}}>
|
||||||
|
<Header style={{ padding: '0', marginBottom: '3px'}}>
|
||||||
|
{
|
||||||
|
Setting.isMobile() ? null : (
|
||||||
|
<Link to={"/"}>
|
||||||
|
<div className="logo" />
|
||||||
|
</Link>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
<Menu
|
||||||
|
// theme="dark"
|
||||||
|
mode={(Setting.isMobile() && this.isStartPages()) ? "inline" : "horizontal"}
|
||||||
|
selectedKeys={[`${this.state.selectedMenuKey}`]}
|
||||||
|
style={{ lineHeight: '64px'}}
|
||||||
|
>
|
||||||
|
{
|
||||||
|
this.renderMenu()
|
||||||
|
}
|
||||||
|
<div style = {{float: 'right'}}>
|
||||||
|
{
|
||||||
|
this.renderAccount()
|
||||||
|
}
|
||||||
|
<SelectLanguageBox/>
|
||||||
|
</div>
|
||||||
|
</Menu>
|
||||||
|
</Header>
|
||||||
|
<Layout style={{backgroundColor: "#f5f5f5", alignItems: 'stretch'}}>
|
||||||
|
<Card className="content-warp-card">
|
||||||
|
{
|
||||||
|
this.renderRouter()
|
||||||
|
}
|
||||||
|
</Card>
|
||||||
|
</Layout>
|
||||||
|
</Layout>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return(
|
||||||
|
<div>
|
||||||
<Header style={{ padding: '0', marginBottom: '3px'}}>
|
<Header style={{ padding: '0', marginBottom: '3px'}}>
|
||||||
{
|
{
|
||||||
Setting.isMobile() ? null : (
|
Setting.isMobile() ? null : (
|
||||||
@ -440,65 +478,26 @@ class App extends Component {
|
|||||||
// theme="dark"
|
// theme="dark"
|
||||||
mode={(Setting.isMobile() && this.isStartPages()) ? "inline" : "horizontal"}
|
mode={(Setting.isMobile() && this.isStartPages()) ? "inline" : "horizontal"}
|
||||||
selectedKeys={[`${this.state.selectedMenuKey}`]}
|
selectedKeys={[`${this.state.selectedMenuKey}`]}
|
||||||
style={{ lineHeight: '64px'}}
|
style={{ lineHeight: '64px' }}
|
||||||
>
|
>
|
||||||
{
|
{
|
||||||
this.renderMenu()
|
this.renderMenu()
|
||||||
}
|
}
|
||||||
<div style = {{float: 'right'}}>
|
<div style = {{float: 'right'}}>
|
||||||
{
|
{
|
||||||
this.renderAccount()
|
this.renderAccount()
|
||||||
}
|
}
|
||||||
<SelectLanguageBox/>
|
<SelectLanguageBox/>
|
||||||
</div>
|
</div>
|
||||||
</Menu>
|
</Menu>
|
||||||
</Header>
|
</Header>
|
||||||
<Layout style={{backgroundColor: "#f5f5f5", alignItems: 'stretch'}}>
|
|
||||||
<Card className="content-warp-card">
|
|
||||||
{
|
|
||||||
this.renderRouter()
|
|
||||||
}
|
|
||||||
</Card>
|
|
||||||
</Layout>
|
|
||||||
</Layout>
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
return(
|
|
||||||
<div>
|
|
||||||
<Header style={{ padding: '0', marginBottom: '3px'}}>
|
|
||||||
{
|
{
|
||||||
Setting.isMobile() ? null : (
|
this.renderRouter()
|
||||||
<Link to={"/"}>
|
|
||||||
<div className="logo" />
|
|
||||||
</Link>
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
<Menu
|
</div>
|
||||||
// theme="dark"
|
)
|
||||||
mode={(Setting.isMobile() && this.isStartPages()) ? "inline" : "horizontal"}
|
}
|
||||||
selectedKeys={[`${this.state.selectedMenuKey}`]}
|
|
||||||
style={{ lineHeight: '64px' }}
|
|
||||||
>
|
|
||||||
{
|
|
||||||
this.renderMenu()
|
|
||||||
}
|
|
||||||
<div style = {{float: 'right'}}>
|
|
||||||
{
|
|
||||||
this.renderAccount()
|
|
||||||
}
|
|
||||||
<SelectLanguageBox/>
|
|
||||||
</div>
|
|
||||||
</Menu>
|
|
||||||
</Header>
|
|
||||||
{
|
|
||||||
this.renderRouter()
|
|
||||||
}
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
renderFooter() {
|
renderFooter() {
|
||||||
// How to keep your footer where it belongs ?
|
// How to keep your footer where it belongs ?
|
||||||
|
@ -13,21 +13,16 @@
|
|||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { Button, Col, Divider, Form, Select, Input, Row, Steps } from "antd";
|
import {Button, Col, Divider, Form, Select, Input, Row, Steps} from "antd";
|
||||||
import * as AuthBackend from "./AuthBackend";
|
import * as AuthBackend from "./AuthBackend";
|
||||||
import * as ApplicationBackend from "../backend/ApplicationBackend";
|
import * as ApplicationBackend from "../backend/ApplicationBackend";
|
||||||
import * as Util from "./Util";
|
import * as Util from "./Util";
|
||||||
import * as Setting from "../Setting";
|
import * as Setting from "../Setting";
|
||||||
import i18next from "i18next";
|
import i18next from "i18next";
|
||||||
import { CountDownInput } from "../component/CountDownInput";
|
import {CountDownInput} from "../component/CountDownInput";
|
||||||
import * as UserBackend from "../backend/UserBackend";
|
import * as UserBackend from "../backend/UserBackend";
|
||||||
import {
|
import {CheckCircleOutlined, KeyOutlined, LockOutlined, SolutionOutlined, UserOutlined} from "@ant-design/icons";
|
||||||
CheckCircleOutlined,
|
import CustomGithubCorner from "../CustomGithubCorner";
|
||||||
KeyOutlined,
|
|
||||||
LockOutlined,
|
|
||||||
SolutionOutlined,
|
|
||||||
UserOutlined,
|
|
||||||
} from "@ant-design/icons";
|
|
||||||
|
|
||||||
const { Step } = Steps;
|
const { Step } = Steps;
|
||||||
const { Option } = Select;
|
const { Option } = Select;
|
||||||
@ -474,7 +469,7 @@ class ForgetPage extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<React.Fragment>
|
||||||
<Divider style={{ fontSize: "28px" }}>
|
<Divider style={{ fontSize: "28px" }}>
|
||||||
{i18next.t("forget:Retrieve password")}
|
{i18next.t("forget:Retrieve password")}
|
||||||
</Divider>
|
</Divider>
|
||||||
@ -512,7 +507,8 @@ class ForgetPage extends React.Component {
|
|||||||
</div>
|
</div>
|
||||||
</Col>
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
</>
|
<CustomGithubCorner />
|
||||||
|
</React.Fragment>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,7 @@ import LinkedInLoginButton from "./LinkedInLoginButton";
|
|||||||
import WeComLoginButton from "./WeComLoginButton";
|
import WeComLoginButton from "./WeComLoginButton";
|
||||||
import LarkLoginButton from "./LarkLoginButton";
|
import LarkLoginButton from "./LarkLoginButton";
|
||||||
import GitLabLoginButton from "./GitLabLoginButton";
|
import GitLabLoginButton from "./GitLabLoginButton";
|
||||||
|
import CustomGithubCorner from "../CustomGithubCorner";
|
||||||
|
|
||||||
class LoginPage extends React.Component {
|
class LoginPage extends React.Component {
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
@ -435,6 +436,7 @@ class LoginPage extends React.Component {
|
|||||||
{
|
{
|
||||||
Setting.renderHelmet(application)
|
Setting.renderHelmet(application)
|
||||||
}
|
}
|
||||||
|
<CustomGithubCorner />
|
||||||
{
|
{
|
||||||
Setting.renderLogo(application)
|
Setting.renderLogo(application)
|
||||||
}
|
}
|
||||||
|
@ -24,6 +24,7 @@ import * as ApplicationBackend from "../backend/ApplicationBackend";
|
|||||||
import * as UserBackend from "../backend/UserBackend";
|
import * as UserBackend from "../backend/UserBackend";
|
||||||
import {CountDownInput} from "../component/CountDownInput";
|
import {CountDownInput} from "../component/CountDownInput";
|
||||||
import SelectRegionBox from "../SelectRegionBox";
|
import SelectRegionBox from "../SelectRegionBox";
|
||||||
|
import CustomGithubCorner from "../CustomGithubCorner";
|
||||||
|
|
||||||
const formItemLayout = {
|
const formItemLayout = {
|
||||||
labelCol: {
|
labelCol: {
|
||||||
@ -528,6 +529,7 @@ class SignupPage extends React.Component {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
|
<CustomGithubCorner />
|
||||||
|
|
||||||
<Row>
|
<Row>
|
||||||
<Col span={24} style={{display: "flex", justifyContent: "center"}} >
|
<Col span={24} style={{display: "flex", justifyContent: "center"}} >
|
||||||
|
Reference in New Issue
Block a user