style+banner

This commit is contained in:
caishi 2021-03-23 09:20:16 +08:00
parent 0290822ebf
commit 3384cd2703
13 changed files with 71 additions and 54 deletions

View File

@ -20,6 +20,7 @@ li.ant-menu-item{
background-color: #fff;
margin-bottom:18px;
min-height: 130px;
border:1px solid #eee;
.img{
margin-right: 20px;
width: 190px;
@ -61,6 +62,7 @@ li.ant-menu-item{
}
// Tabs
.tabsStyle{
border:1px solid #eee;
.ant-tabs-bar.ant-tabs-top-bar{
padding-left: 35px;
margin-bottom: 0px;

View File

@ -48,7 +48,7 @@ export default (props)=>{
</Short>
<Long>
<Gap>
<WhiteBack>
<WhiteBack style={{border:'1px solid #eee'}}>
<Switch>
<Route
path="/organize/:OIdentifier/group/:groupId/setting/project"

View File

@ -139,7 +139,7 @@ export default Form.create()(
}
return (
<Spin spinning={isSpin}>
<WhiteBack className="mb30">
<WhiteBack className="mb30" style={{border:"1px solid #eee"}}>
<Banner>{groupId ? "基本设置" : "新建团队"}</Banner>
<Div>
<Form>

View File

@ -48,6 +48,7 @@
max-width: 860px;
width: 72%;
margin-bottom: 30px;
border:1px solid #eee;
.head{
padding:16px 32px;
border-bottom: 1px solid #eee;
@ -109,6 +110,9 @@
padding-left: 20px;
box-sizing: border-box;
margin-bottom: 30px;
& > div{
border:1px solid #eee;
}
}
.box{
background:rgba(255,255,255,1);
@ -273,6 +277,9 @@
display: flex;
align-items: flex-start;
.g-sub-left{
&>div{
border:1px solid #eee;
}
background-color: #fff;
.g-desc{
padding:18px 20px;

View File

@ -68,7 +68,7 @@ function List(props){
return(
<div className="list">
<div className="list-l">
<div className="list-l">
<div>
<div className="head">
<div style={{width:"370px"}}>

View File

@ -54,8 +54,9 @@ export default (( props )=>{
<Setnav header={<Title>组织设置</Title>} nav={array}></Setnav>
</Short>
<Long>
<Gap>
<Switch>
<Gap >
<div style={{border:"1px solid #eee"}}>
<Switch>
<Route
path="/organize/:OIdentifier/setting/hooks"
render={() => (
@ -81,6 +82,7 @@ export default (( props )=>{
)}
></Route>
</Switch>
</div>
</Gap>
</Long>
</Box>

View File

@ -5,7 +5,7 @@ import GroupItems from './TeamGroupItems';
const limit = 14;
function TeamGroup({organizeDetail,history}){
return(
<div style={{background:"#fff",marginBottom:"30px"}}>
<div style={{background:"#fff",marginBottom:"30px",border:'1px solid #eee'}}>
<Banner>组织团队</Banner>
<GroupItems limit={limit} organizeDetail={organizeDetail} count={7} history={history}/>
</div>

View File

@ -33,7 +33,7 @@ function TeamMember({organizeDetail,current_user}){
}
return(
<WhiteBack style={{marginBottom:"30px"}}>
<WhiteBack style={{marginBottom:"30px",border:'1px solid #eee'}}>
<Banner>组织成员</Banner>
<Spin spinning={isSpin}>
<div style={{minHeight:"400px"}}>

View File

@ -31,12 +31,20 @@ $flex:flex;
display: $flex;
align-items: flex-start;
padding:20px 25px;
background-color:rgba(250,250,250,1)
}
& > div img{
width: 190px;
height: 90px;
margin-right: 20px
background-color:rgba(250,250,250,1);
.imgBox{
width: 190px;
height: 90px;
display: flex;
align-items: center;
justify-content: center;
margin-right: 20px;
background-color: #fff;
img{
max-width: 90%;
max-height: 90%;
}
}
}
.item-news{
display: $flex;

View File

@ -4,7 +4,7 @@ import { getImageUrl } from 'educoder';
function TeamItem({item,history}){
return(
<div onClick={()=>{history.push(`/organize/${item.name}`)}} style={{cursor:"pointer"}}>
<img alt="" src={getImageUrl(`images/${item.avatar_url}`)}/>
<div className="imgBox"><img alt="" src={getImageUrl(`images/${item.avatar_url}`)}/></div>
<div style={{flex:'1'}}>
<span className="mb5 font-18 color-grey-3 task-hide">{item.name}</span>
<div className="task-hide-2">

View File

@ -22,6 +22,7 @@
width:74%;
background: #fff;
padding:0px !important;
border:1px solid #eee;
}
.text-center{text-align: center;}

View File

@ -47,7 +47,7 @@ class NewHeader extends Component {
mydisplay: false,
headtypesonClickbool: false,
headtypess: "/",
mygetHelmetapi2: null,
settings: null,
goshowqqgtounp: false,
visiblemyss: false,
}
@ -497,7 +497,7 @@ class NewHeader extends Component {
//获取数据为空的时候
gettablogourlnull = () => {
this.setState({
mygetHelmetapi2: undefined
settings: undefined
});
var link = document.createElement('link'),
oldLink = document.getElementById('dynamic-favicon');
@ -535,7 +535,7 @@ class NewHeader extends Component {
var chromesettingArray = JSON.parse(localStorage.getItem('chromesetting'));
var chromesettingresponseArray = JSON.parse(localStorage.getItem('chromesettingresponse'));
this.setState({
mygetHelmetapi2: chromesettingArray
settings: chromesettingArray
});
if (chromesettingArray.tab_logo_url) {
this.gettablogourldata(chromesettingresponseArray);
@ -551,7 +551,7 @@ class NewHeader extends Component {
let url = "/setting.json";
axios.get(url).then((response) => {
if (response && response.data) {
this.setState({ mygetHelmetapi2: response.data.setting });
this.setState({ settings: response.data.setting });
// localStorage.setItem('chromesetting', JSON.stringify(response.data.setting));
// localStorage.setItem('chromesettingresponse', JSON.stringify(response));
try {
@ -574,13 +574,9 @@ class NewHeader extends Component {
matchpaths = (url) => {
const { match } = this.props;
if(url){
if (url.indexOf('forums') > -1 && match.path.indexOf('forums') > -1) {
if (match.path.indexOf(url) > -1) {
return true
} else if (url.indexOf('projects') > -1 && match.path.indexOf('projects') > -1) {
return true
} else if (url.indexOf('users') > -1 && match.path.indexOf('users') > -1) {
return true
} else {
}else {
return false
}
}
@ -609,7 +605,7 @@ class NewHeader extends Component {
showSearchOpentype,
headtypesonClickbool,
headtypess,
mygetHelmetapi2,
settings,
goshowqqgtounp,
} = this.state;
/*用户名称 用户头像url*/
@ -641,9 +637,9 @@ class NewHeader extends Component {
}
let headtypes = '/';
if (mygetHelmetapi2) {
if (mygetHelmetapi2.navbar) {
if (mygetHelmetapi2.navbar.length > 0) {
if (settings) {
if (settings.navbar) {
if (settings.navbar.length > 0) {
if (match.path === '/') {
if (headtypesonClickbool === false) {
headtypes = undefined;
@ -651,9 +647,9 @@ class NewHeader extends Component {
headtypes = headtypess;
}
} else {
for (var i = 0; i < mygetHelmetapi2.navbar.length; i++) {
if (match.path === mygetHelmetapi2.navbar[i].link) {
headtypes = mygetHelmetapi2.navbar[i].link;
for (var i = 0; i < settings.navbar.length; i++) {
if (match.path === settings.navbar[i].link) {
headtypes = settings.navbar[i].link;
break;
}
}
@ -708,20 +704,20 @@ class NewHeader extends Component {
<GotoQQgroup {...this.state} {...this.props} setgoshowqqgtounp={(bool) => this.setgoshowqqgtounp(bool)}></GotoQQgroup>
:""
}
<a href={mygetHelmetapi2 && mygetHelmetapi2.new_course.default_url} className={"fl mr30"} style={{minWidth:"45px"}}>
<a href={settings && settings.new_course.default_url} className={"fl mr30"} style={{minWidth:"45px"}}>
{
mygetHelmetapi2 && mygetHelmetapi2.nav_logo_url ?
<img alt="可控开源社区" className="logoimg" style={{ heigth: "40px" }} src={getImageUrl(mygetHelmetapi2.nav_logo_url)}></img>
settings && settings.nav_logo_url ?
<img alt="可控开源社区" className="logoimg" style={{ heigth: "40px" }} src={getImageUrl(settings.nav_logo_url)}></img>
:
<img alt="可控开源社区" className="logoimg" style={{ heigth: "40px" }} src={logo}></img>
}
</a>
<div className="head-nav pr" id={"head-navpre1"}>
{
mygetHelmetapi2 && mygetHelmetapi2.navbar && mygetHelmetapi2.navbar.length > 0 ?
settings && settings.navbar && settings.navbar.length > 0 ?
<ul id="header-nav">
{
mygetHelmetapi2.navbar && mygetHelmetapi2.navbar.map((item, key) => {
settings.navbar && settings.navbar.map((item, key) => {
var new_link = item.link;
var user_login = this.props.user && this.props.user.login;
var is_hidden = item.hidden
@ -760,11 +756,15 @@ class NewHeader extends Component {
<div className="edu-menu-list" style={{ top: '48px' }}>
<div className="overPart"></div>
{
coursestypes === true && this.props.user && this.props.user.main_site === false ? "" :
(coursestypes === true && this.props.user.main_site === false && (settings && !settings.add && (settings.add && settings.add.length === 0))) ? "" :
<ul className="edu-txt-center">
<li><Link to={"/projects/mirror/new"}>新建镜像项目</Link></li>
<li><Link to={"/projects/deposit/new"}>新建托管项目</Link></li>
<li><Link to={"/organize/new"}>新建组织</Link></li>
{
settings && settings.add && settings.add.map((item,key)=>{
return(
<li><a href={item.url}>{item.name}</a></li>
)
})
}
</ul>
}
</div>
@ -773,7 +773,7 @@ class NewHeader extends Component {
{this.props.user && this.props.user.login &&
<div className="ml30 edu-menu-panel">
{user && user.login &&
<a href={`${mygetHelmetapi2 && mygetHelmetapi2.new_course && mygetHelmetapi2.new_course.tiding_url}`} style={{ position: 'relative' }} target="_blank">
<a href={`${settings && settings.new_course && settings.new_course.tiding_url}`} style={{ position: 'relative' }} target="_blank">
<i className="iconfont icon-xiaoxilingdang color-grey-6"></i>
<span className="newslight" style={{ display: this.props.Headertop === undefined ? "none" : this.props.Headertop.new_message === true ? "block" : "none" }}>
</span>
@ -812,16 +812,16 @@ class NewHeader extends Component {
<span className="font-15">
<a onClick={() => this.educoderlogin()} className="mr5 color-grey-6">登录</a>
{
mygetHelmetapi2 && mygetHelmetapi2.new_course && mygetHelmetapi2.new_course.register_url &&
<span><em className="vertical-line"></em><a className="ml5 color-grey-6" href={`${mygetHelmetapi2.new_course.register_url}`} target="_blank"></a></span>
settings && settings.new_course && settings.new_course.register_url &&
<span><em className="vertical-line"></em><a className="ml5 color-grey-6" href={`${settings.new_course.register_url}`} target="_blank"></a></span>
}
</span>
: user.login === "" ?
<span className="font-15">
<a onClick={() => this.educoderlogin()} className="mr5 color-grey-6">登录</a>
{
mygetHelmetapi2 && mygetHelmetapi2.new_course && mygetHelmetapi2.new_course.register_url &&
<span><em className="vertical-line"></em><a className="color-grey-6 ml5" href={`${mygetHelmetapi2.new_course.register_url}`} target="_blank"></a></span>
settings && settings.new_course && settings.new_course.register_url &&
<span><em className="vertical-line"></em><a className="color-grey-6 ml5" href={`${settings.new_course.register_url}`} target="_blank"></a></span>
}
</span>
:
@ -833,16 +833,12 @@ class NewHeader extends Component {
</a>
<ul className="edu-menu-list" style={{ top: '60px', textAlign: 'center' }}>
<li className="bor-bottom-greyE" style={{cursor:"default",background:"#fff"}}>{this.props.current_user.username}</li>
<li>
<Link to={`/users/${this.props.current_user.login}`}>个人中心</Link>
</li>
{
mygetHelmetapi2 && mygetHelmetapi2.new_course && mygetHelmetapi2.new_course.my_courses &&
<li><a href={`${mygetHelmetapi2.new_course.my_courses}`} target="_blank">我的课程</a></li>
}
{
mygetHelmetapi2 && mygetHelmetapi2.new_course && mygetHelmetapi2.new_course.my_organ &&
<li><a href={`/users/${this.props.current_user.login}/organizes`} target="_blank">我的组织</a></li>
settings && settings.personal && settings.personal.length > 0 && settings.personal.map((item,key)=>{
return(
<li key={key}><a href={item.url} target="_blank">{item.name}</a></li>
)
})
}
<li className="bor-top-greyE">
<a onClick={() => this.educoderloginysl()}>退出</a>

View File

@ -31,6 +31,7 @@ body>.-task-title {
z-index: 10000;
background:rgba(255,255,255,1);
position: fixed;
box-shadow: 0px 0px 14px rgb(0 0 0 / 10%);
}
.headerContent{
width:1200px;