mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-10 19:14:16 +00:00
move explore
page to home
This commit is contained in:
parent
480d5eefd6
commit
eab2c8d91f
@ -7,16 +7,19 @@ const envOrigins = {
|
|||||||
"development": {
|
"development": {
|
||||||
mainApi: `http://${window.location.hostname}:3000`,
|
mainApi: `http://${window.location.hostname}:3000`,
|
||||||
authApi: `http://${window.location.hostname}:4000`,
|
authApi: `http://${window.location.hostname}:4000`,
|
||||||
|
contentApi: `http://${window.location.hostname}:3050`,
|
||||||
streamingApi: `http://${window.location.hostname}:3002`,
|
streamingApi: `http://${window.location.hostname}:3002`,
|
||||||
},
|
},
|
||||||
"indev": {
|
"indev": {
|
||||||
mainApi: "https://indev_api.comty.pw",
|
mainApi: "https://indev_api.comty.pw",
|
||||||
authApi: `http://indev_auth.comty.pw`,
|
authApi: `http://indev_auth.comty.pw`,
|
||||||
|
contentApi: `http://indev_content.comty.pw`,
|
||||||
streamingApi: "https://indev_live.comty.pw",
|
streamingApi: "https://indev_live.comty.pw",
|
||||||
},
|
},
|
||||||
"nightly": {
|
"nightly": {
|
||||||
mainApi: "https://nightly_api.comty.pw",
|
mainApi: "https://nightly_api.comty.pw",
|
||||||
authApi: `https://nightly_auth.comty.pw`,
|
authApi: `https://nightly_auth.comty.pw`,
|
||||||
|
contentApi: `https://nightly_content.comty.pw`,
|
||||||
streamingApi: "https://nightly_live.comty.pw"
|
streamingApi: "https://nightly_live.comty.pw"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -40,7 +43,7 @@ export default {
|
|||||||
app: {
|
app: {
|
||||||
title: packagejson.name,
|
title: packagejson.name,
|
||||||
siteName: "Comty",
|
siteName: "Comty",
|
||||||
mainPath: "/main",
|
mainPath: "/home",
|
||||||
storage: {
|
storage: {
|
||||||
basics: "user",
|
basics: "user",
|
||||||
token: "token",
|
token: "token",
|
||||||
|
@ -17,8 +17,7 @@
|
|||||||
"style.compactMode": false,
|
"style.compactMode": false,
|
||||||
"language": "en",
|
"language": "en",
|
||||||
"sidebarKeys": [
|
"sidebarKeys": [
|
||||||
"main",
|
"home",
|
||||||
"explore",
|
|
||||||
"saved",
|
"saved",
|
||||||
"marketplace",
|
"marketplace",
|
||||||
"streams"
|
"streams"
|
||||||
|
@ -1,14 +1,9 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"id": "main",
|
"id": "home",
|
||||||
"title": "Dashboard",
|
"title": "Home",
|
||||||
"icon": "Home"
|
"icon": "Home"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"id": "explore",
|
|
||||||
"title": "Explore",
|
|
||||||
"icon": "Compass"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"id": "saved",
|
"id": "saved",
|
||||||
"title": "Saved",
|
"title": "Saved",
|
||||||
|
@ -116,7 +116,7 @@ export default class Login extends React.Component {
|
|||||||
<div className="session_card">
|
<div className="session_card">
|
||||||
@{this.props.session.username}
|
@{this.props.session.username}
|
||||||
</div>
|
</div>
|
||||||
<antd.Button type="primary" onClick={() => window.app.setLocation(config.app?.mainPath ?? "/main")} >Go to main</antd.Button>
|
<antd.Button type="primary" onClick={() => window.app.setLocation(config.app?.mainPath ?? "/home")} >Go to main</antd.Button>
|
||||||
</div>}
|
</div>}
|
||||||
<FormGenerator
|
<FormGenerator
|
||||||
name="normal_login"
|
name="normal_login"
|
||||||
|
@ -1,42 +0,0 @@
|
|||||||
import React from "react"
|
|
||||||
import * as antd from "antd"
|
|
||||||
|
|
||||||
import { AppSearcher, Clock } from "components"
|
|
||||||
import { Translation } from "react-i18next"
|
|
||||||
|
|
||||||
import "./index.less"
|
|
||||||
|
|
||||||
// TODO: Customizable main menu
|
|
||||||
export default class Main extends React.Component {
|
|
||||||
render() {
|
|
||||||
const user = this.props.user ?? {}
|
|
||||||
|
|
||||||
return (
|
|
||||||
<div className="dashboard">
|
|
||||||
<div className="header">
|
|
||||||
<div>
|
|
||||||
<antd.Avatar
|
|
||||||
shape="square"
|
|
||||||
src={user.avatar}
|
|
||||||
size={window.isMobile ? undefined : 120}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<div>
|
|
||||||
<Clock />
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<Translation>{
|
|
||||||
(t) => <h1>{t("main_welcome")} {user.fullName ?? user.username ?? "Guest"}</h1>
|
|
||||||
}</Translation>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{!window.isMobile && <div>
|
|
||||||
<AppSearcher />
|
|
||||||
</div>}
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,51 +0,0 @@
|
|||||||
.dashboard {
|
|
||||||
padding: 20px;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
|
|
||||||
h1 {
|
|
||||||
font-size: 28px;
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
> div {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.header {
|
|
||||||
display: flex;
|
|
||||||
|
|
||||||
> div {
|
|
||||||
margin-right: 20px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.content {
|
|
||||||
> div {
|
|
||||||
margin-left: 20px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.quick_actions {
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
|
|
||||||
> div {
|
|
||||||
margin: 6px 10px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.widgets {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
|
|
||||||
.widget {
|
|
||||||
//background-color: var(--background-color-accent);
|
|
||||||
//padding: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
> div {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user