From 83e28112b2f3c231222e87c4645571d567a035a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Tue, 10 Dec 2019 18:45:35 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/App.js | 22 +- .../courses/coursesPublic/NewShixunModel.js | 13 +- .../courses/coursesPublic/Newshixunmodel.css | 21 +- public/react/src/modules/tpm/TPMBanner.js | 7 +- public/react/src/modules/tpm/TPMChallenge.js | 115 +++--- public/react/src/modules/tpm/TPMDataset.js | 268 +++++++++++++ public/react/src/modules/tpm/TPMIndex.js | 37 +- .../react/src/modules/tpm/component/TPMNav.js | 4 + .../Challenges/Challengesjupyter.js | 354 ++++++++++++++++++ .../Collaborators/Collaborators.css | 124 +++++- .../Collaborators/Collaborators.js | 121 ++++-- .../shixunchild/shixunchildCss/Challenges.css | 42 ++- .../src/modules/tpm/shixuns/ShixunCard.js | 31 ++ .../src/modules/tpm/shixuns/ShixunsIndex.js | 2 +- .../src/modules/tpm/tpmmodel/tpmmodel.css | 121 ++++++ public/react/src/search/SearchPage.js | 36 +- public/react/src/search/searchc.css | 43 ++- 17 files changed, 1227 insertions(+), 134 deletions(-) create mode 100644 public/react/src/modules/tpm/TPMDataset.js create mode 100644 public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js create mode 100644 public/react/src/modules/tpm/tpmmodel/tpmmodel.css diff --git a/public/react/src/App.js b/public/react/src/App.js index 2fa9e0765..0d24db7c2 100644 --- a/public/react/src/App.js +++ b/public/react/src/App.js @@ -358,7 +358,7 @@ class App extends Component { mydisplay:true, }) }; - + disableVideoContextMenu = () => { window.$( "body" ).on( "mousedown", "video", function(event) { if(event.which === 3) { @@ -577,14 +577,14 @@ class App extends Component { <Route path="/users/:username" render={ (props) => { - + return (<InfosIndex {...this.props} {...props} {...this.state} />) } }></Route> <Route path="/banks" render={ - (props) => { + (props) => { return (<BanksIndex {...this.props} {...props} {...this.state} />) } }></Route> @@ -615,7 +615,7 @@ class App extends Component { <Route path="/shixuns/:shixunId" component={TPMIndexComponent}> </Route> - {/*列表页*/} + {/*列表页 实训项目列表*/} <Route path="/shixuns" component={TPMShixunsIndexComponent}/> @@ -637,8 +637,8 @@ class App extends Component { <Route path="/moop_cases"render={ (props) => (<MoopCases {...this.props} {...props} {...this.state} />) }/> - - <Route path="/forums" + + <Route path="/forums" render={ (props)=>(<ForumsIndexComponent {...this.props} {...props} {...this.state}></ForumsIndexComponent>) } @@ -671,7 +671,7 @@ class App extends Component { (props)=>(<Ecs {...this.props} {...props} {...this.state}></Ecs>) }/> - <Route path="/problems/new/:id?" + <Route path="/problems/new/:id?" render={ (props) => { return (<NewOrEditTask {...this.props} {...props} {...this.state} />) @@ -679,11 +679,11 @@ class App extends Component { } /> <Route - path="/problems/:id/edit" + path="/problems/:id/edit" render={ (props) => (<NewOrEditTask {...this.props} {...props} {...this.state} />) } /> - <Route path="/myproblems/record_detail/:id" + <Route path="/myproblems/record_detail/:id" render={ (props) => (<RecordDetail {...this.props} {...props} {...this.state} />) } @@ -703,7 +703,7 @@ class App extends Component { (props)=>(<ShixunsHome {...this.props} {...props} {...this.state}></ShixunsHome>) } /> - <Route component={Shixunnopage}/> + <Route component={Shixunnopage}/> </Switch> </Router> @@ -825,4 +825,4 @@ moment.defineLocale('zh-cn', { doy: 4 // The week that contains Jan 4th is the first week of the year. } }); -export default SnackbarHOC()(App) ; \ No newline at end of file +export default SnackbarHOC()(App) ; diff --git a/public/react/src/modules/courses/coursesPublic/NewShixunModel.js b/public/react/src/modules/courses/coursesPublic/NewShixunModel.js index 99a8ad232..f5dfc089a 100644 --- a/public/react/src/modules/courses/coursesPublic/NewShixunModel.js +++ b/public/react/src/modules/courses/coursesPublic/NewShixunModel.js @@ -536,6 +536,17 @@ class NewShixunModel extends Component{ className="fl task-hide edu-txt-left mt3" name="shixun_homework[]" ></Checkbox> + { + this.props.type==='shixuns'? + <div className="myysljupyter fl ml15 mt3 intermediatecenter"> + <p className="myysljupytertest"> + Jupyter + </p> + </div> + :"" + } + + <a target="_blank" href={this.props.type==='shixuns'?`/shixuns/${item.identifier}/challenges`:`/paths/${item.id}`} className="ml15 fl font-16 color-dark maxwidth1100" dangerouslySetInnerHTML={{__html: item.title}} > @@ -681,4 +692,4 @@ export default NewShixunModel; // <span dangerouslySetInnerHTML={{__html: item}}>{}</span> // ) // })} -// </div>} \ No newline at end of file +// </div>} diff --git a/public/react/src/modules/courses/coursesPublic/Newshixunmodel.css b/public/react/src/modules/courses/coursesPublic/Newshixunmodel.css index 42595bf29..2bf7b363f 100644 --- a/public/react/src/modules/courses/coursesPublic/Newshixunmodel.css +++ b/public/react/src/modules/courses/coursesPublic/Newshixunmodel.css @@ -384,4 +384,23 @@ .newshixunmodels{ margin: 0 auto; -} \ No newline at end of file +} +.myysljupyter{ + width:48px; + height:22px; + background:#FF6802; + border-radius:2px 10px 10px 2px; +} +.myysljupytertest{ + width:39px; + height:16px; + font-size:12px; + color:#FFFFFF; + line-height:16px; +} +.intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + } diff --git a/public/react/src/modules/tpm/TPMBanner.js b/public/react/src/modules/tpm/TPMBanner.js index b660001c6..d025443cf 100644 --- a/public/react/src/modules/tpm/TPMBanner.js +++ b/public/react/src/modules/tpm/TPMBanner.js @@ -55,8 +55,9 @@ class TPMBanner extends Component { isIE:false, Forkvisibletype: false, isSpin:false, - Senttothevcaluetype:false - } + Senttothevcaluetype:false, + jupyterbool:false, + } } // star_info:[0, 0, 0, 0, 0, 0], @@ -656,7 +657,7 @@ class TPMBanner extends Component { {/*<span className="mt10">{shixunsDetails.experience}</span>*/} {/*</li>*/} <li> - <span>难度系数</span> + <span>难度级别</span> <span className="shixunsdiffcult mt10">{shixunsDetails.diffcult}</span> </li> diff --git a/public/react/src/modules/tpm/TPMChallenge.js b/public/react/src/modules/tpm/TPMChallenge.js index 847e8b965..630a233fd 100644 --- a/public/react/src/modules/tpm/TPMChallenge.js +++ b/public/react/src/modules/tpm/TPMChallenge.js @@ -1,54 +1,61 @@ -import React, { Component } from 'react'; -import { Redirect } from 'react-router'; - -import PropTypes from 'prop-types'; - -import { CircularProgress } from 'material-ui/Progress'; - -import './TPMShixunDiscuss.css' - -import Challenges from './shixunchild/Challenges/Challenges' - -import TPMRightSection from './component/TPMRightSection' - -import TPMNav from './component/TPMNav' - -class TPMChallenge extends Component { - constructor(props) { - super(props) - - } - - render() { - const { loadingContent, shixun, user, match - } = this.props; - return ( - <React.Fragment> - <div className="educontent clearfix mt30 mb80"> - - <div className="with65 fl edu-back-white" > - <TPMNav - match={match} - user={user} - shixun={shixun} - {...this.props} - ></TPMNav> - <Challenges - {...this.props} - /> - - </div> - - <div className="with35 fr pl20"> - <TPMRightSection - {...this.props} - /> - </div> - </div> - </React.Fragment> - - ); - } -} - -export default TPMChallenge; +import React, { Component } from 'react'; +import { Redirect } from 'react-router'; + +import PropTypes from 'prop-types'; + +import { CircularProgress } from 'material-ui/Progress'; + +import './TPMShixunDiscuss.css' + +import Challenges from './shixunchild/Challenges/Challenges' +import Challengesjupyter from './shixunchild/Challenges/Challengesjupyter' +import TPMRightSection from './component/TPMRightSection' + +import TPMNav from './component/TPMNav' + +class TPMChallenge extends Component { + constructor(props) { + super(props) + + } + + render() { + const { loadingContent, shixun, user, match,jupyterbool + } = this.props; + return ( + <React.Fragment> + <div className="educontent clearfix mt30 mb80"> + + <div className="with65 fl edu-back-white" > + <TPMNav + match={match} + user={user} + shixun={shixun} + {...this.props} + ></TPMNav> + { + jupyterbool===true? + <Challengesjupyter + {...this.props} + /> + : <Challenges + {...this.props} + /> + } + + + </div> + + <div className="with35 fr pl20"> + <TPMRightSection + {...this.props} + /> + </div> + </div> + </React.Fragment> + + ); + } +} + +export default TPMChallenge; diff --git a/public/react/src/modules/tpm/TPMDataset.js b/public/react/src/modules/tpm/TPMDataset.js new file mode 100644 index 000000000..bf35744fe --- /dev/null +++ b/public/react/src/modules/tpm/TPMDataset.js @@ -0,0 +1,268 @@ +import React, {Component} from 'react'; +import {Redirect} from 'react-router'; +import {List, Typography, Tag, Modal, Radio, Checkbox, Table, Pagination} from 'antd'; +import { NoneData } from 'educoder' + +import TPMRightSection from './component/TPMRightSection'; +import TPMNav from './component/TPMNav'; +import axios from 'axios'; +import './tpmmodel/tpmmodel.css' + +class TPMDataset extends Component { + constructor(props) { + super(props) + this.state = { + datas: [0, 1, 2, 3, 4, 5], + value: undefined, + columns: [ + { + title: '文件', + dataIndex: 'number', + key: 'number', + align: 'left', + className: " font-14 wenjiantit", + width: '300px', + render: (text, record) => ( + <div> + 文件名字 + </div> + ) + }, + { + title: '最后修改时间', + dataIndex: 'number', + key: 'number', + align: 'center', + className: "edu-txt-center font-14 zuihoushijian", + width: '125px', + render: (text, record) => ( + <div> + 2019-08-12 12:30 + </div> + ) + }, + { + title: '最后修改人', + dataIndex: 'number', + key: 'number', + align: 'center', + className: "edu-txt-center font-14 ", + render: (text, record) => ( + <div> + 张大大 + </div> + ) + }, + { + title: '文件大小', + dataIndex: 'number', + key: 'number', + align: 'center', + className: "edu-txt-center font-14 ", + render: (text, record) => ( + <div> + 1.88kb + </div> + ) + }, + ], + page: 1, + limit: 5, + selectedRowKeys: [], + mylistansum:30, + } + } + + componentDidMount() { + this.getdatas() + + } + + mysonChange = (e) => { + console.log(`全选checked = ${e.target.checked}`); + if (e.target.checked === true) { + this.setState({ + selectedRowKeys: this.state.datas, + }) + } else { + this.setState({ + selectedRowKeys: [], + }) + } + } + + + getdatas = () => { + + + } + + showModal = (id, status) => { + + }; + + handleOk = (id, editid) => { + + }; + + handleCancel = (e) => { + + }; + paginationonChanges = (pageNumber) => { + // //console.log('Page: '); + this.setState({ + page: pageNumber, + }) + } + onSelectChange = (selectedRowKeys, selectedRows) => { + console.log(`selectedRowKeys: ${selectedRowKeys}`, 'selectedRows: ', selectedRows); + this.setState( + { + selectedRowKeys + } + ); + + } + rowClassName = (record, index) => { + let className = 'light-row'; + if (index % 2 === 1) className = 'dark-row'; + return className; + } + + render() { + const {tpmLoading, shixun, user, match} = this.props; + const {columns, datas, page, limit, selectedRowKeys,mylistansum} = this.state; + const rowSelection = { + selectedRowKeys, + onChange: this.onSelectChange, + }; + // getCheckboxProps: record => ({ + // disabled: record.name === 'Disabled User', // Column configuration not to be checked + // name: record.name, + // }), + return ( + <React.Fragment> + <div className="tpmComment educontent clearfix mt30 mb80"> + + <div className="with65 fl edu-back-white commentsDelegateParent"> + + <TPMNav + match={match} + user={user} + shixun={shixun} + {...this.props} + ></TPMNav> + + <div className="padding20 edu-back-white mt20 " style={{minHeight: '463px'}}> + <div className="sortinxdirection"> + <div className="tpmwidth"><Checkbox onChange={this.mysonChange}>全选</Checkbox></div> + <div className="tpmwidth xaxisreverseorder"> + <div className="deletebuttom intermediatecenter "><p className="deletebuttomtest">上传文件</p></div> + { + mylistansum>0? + <div + className={selectedRowKeys.length > 0 ? "deletebutomtextcode intermediatecenter mr21" : "deletebutom intermediatecenter mr21"}> + <p className="deletebutomtext">删除</p></div> + :"" + } + </div> + </div> + <div className="mt24"> + <style>{` + .ant-spin-nested-loading > div > .ant-spin .ant-spin-dot { + top: 72%;} + } + .edu-table .ant-table-tbody > tr > td { + height: 42px; + } + .edu-table .ant-table-thead > tr > th{ + height: 42px; + } + .ysltableowss .ant-table-thead > tr > th{ + height: 42px; + } + .ysltableowss .ant-table-tbody > tr > td{ + height: 42px; + } + .ysltableowss .ant-table-thead > tr > th, .ant-table-tbody > tr > td { + padding: 9px; + } + .mysjysltable4 .ant-table-thead > tr > th, .ant-table-tbody > tr > td { + padding: 0px; + } + .ant-table-thead .ant-table-selection-column span{ + visibility:hidden; + } + .ant-table-thead > tr > th { + background:#FFFFFF !important; + } + .ant-table table { + width: 100%; + text-align: left; + border-radius: 4px 4px 0 0; + border-collapse: separate; + border-spacing: 0; + border-left: 1px solid #eeeeee; + border-top: 1px solid #eeeeee; + border-right: 1px solid #eeeeee; + } + `}</style> + {mylistansum===0? + <style> + { + ` + .ant-table-tbody{ + display:none; + } + .ant-table table { + border-bottom: 1px solid #eeeeee !important; + } + + ` + } + </style> + :"" + + } + <div className="edu-table edu-back-white ysltableowss"> + <Table + dataSource={datas} + columns={columns} + pagination={false} + className="mysjysltable4" + rowSelection={rowSelection} + rowClassName={this.rowClassName} + /> + </div> + { + mylistansum>5? + <div className="edu-txt-center mt40 mb20"> + <Pagination showQuickJumper current={page} + onChange={this.paginationonChanges} pageSize={limit} + total={mylistansum} + ></Pagination> + </div> + :"" + } + + { mylistansum===0? + <NoneData style={{width: '100%'}}></NoneData>:"" + } + + </div> + + + </div> + </div> + <div className="with35 fr pl20"> + <TPMRightSection + {...this.props} + /> + </div> + </div> + </React.Fragment> + ); + } +} + +export default TPMDataset; diff --git a/public/react/src/modules/tpm/TPMIndex.js b/public/react/src/modules/tpm/TPMIndex.js index 7fd389197..9c82e987d 100644 --- a/public/react/src/modules/tpm/TPMIndex.js +++ b/public/react/src/modules/tpm/TPMIndex.js @@ -27,7 +27,7 @@ import TPMPropaedeuticsComponent from './TPMPropaedeuticsComponent'; import TPMRanking_listComponent from './TPMRanking_listContainer'; import TPMCollaboratorsComponent from './TPMCollaboratorsContainer'; import Audit_situationComponent from './Audit_situationComponent'; - +import TPMDataset from './TPMDataset'; import '../page/tpiPage.css' const $ = window.$ @@ -142,6 +142,7 @@ class TPMIndex extends Component { identity:undefined, TPMRightSectionData:undefined, PropaedeuticsList: undefined, + tpmindexjupyterbool:false, } } @@ -192,7 +193,7 @@ class TPMIndex extends Component { propaedeutics:response.data.propaedeutics, status: response.data.shixun_status, secret_repository: response.data.secret_repository, - + }); } }).catch((error) => { @@ -259,8 +260,8 @@ class TPMIndex extends Component { axios.interceptors.request.eject(this.tpmContentResponseInterceptor); this.tpmContentResponseInterceptor = null; } - - + + setLoadingContent = (isLoadingContent) => { this.setState({ loadingContent: isLoadingContent }) } @@ -270,20 +271,29 @@ class TPMIndex extends Component { // } render() { + let url = window.location.href; let flag = url.indexOf("add_file")>-1; return ( <div className="newMain clearfix"> + {/*头部*/} { - !flag && + !flag && <TPMBanner {...this.props} {...this.state} ></TPMBanner> } - + {/*筛选*/} + {/*{*/} + {/* tpmindexjupyterbool===false?*/} + + {/* :""*/} + {/*}*/} + {/* */} + <Switch {...this.props}> - + <Route path="/shixuns/:shixunId/repository/:repoId/commits" render={ (props) => (<TPMRepositoryCommits {...this.props} {...this.state} {...props} />) @@ -294,7 +304,7 @@ class TPMIndex extends Component { }></Route> <Route exact path="/shixuns/:shixunId/challenges" render={ - (props) => (<TPMChallengeComponent {...this.props} {...this.state} {...props} + (props) => (<TPMChallengeComponent {...this.props} jupyterbool={true} {...this.state} {...props} />) }></Route> @@ -311,7 +321,7 @@ class TPMIndex extends Component { (props) => (<TPMRepositoryComponent {...this.props} {...this.state} {...props} secret_repository_tab={true} />) }></Route> - + {/* <Route exact path="/shixuns/:shixunId/propaedeutics" component={TPMPropaedeuticsComponent}></Route> */} <Route exact path="/shixuns/:shixunId/propaedeutics" render={ @@ -325,7 +335,7 @@ class TPMIndex extends Component { />) }></Route> - + {/* <Route exact path="/shixuns/:shixunId/repository/:shixunId/" component={TPMRepositoryComponent}></Route> */} @@ -342,12 +352,17 @@ class TPMIndex extends Component { (props) => (<TPMsettings {...this.props} {...this.state} {...props} />) }></Route> - + {/*实训项目条目塞选*/} <Route exact path="/shixuns/:shixunId/ranking_list" render={ (props) => (<TPMRanking_listComponent {...this.props} {...this.state} {...props} />) }></Route> + <Route exact path="/shixuns/:shixunId/dataset" render={ + (props) => (<TPMDataset {...this.props} {...this.state} {...props} + />) + }></Route> + <Route exact path="/shixuns/:shixunId/audit_situation" render={ (props) => (<Audit_situationComponent {...this.props} {...this.state} {...props} />) diff --git a/public/react/src/modules/tpm/component/TPMNav.js b/public/react/src/modules/tpm/component/TPMNav.js index ff8f57aa5..9696f49c6 100644 --- a/public/react/src/modules/tpm/component/TPMNav.js +++ b/public/react/src/modules/tpm/component/TPMNav.js @@ -36,6 +36,10 @@ class TPMNav extends Component { <Link to={`/shixuns/${shixunId}/collaborators`} className={`${match.url.indexOf('collaborators') != -1 ? 'active' : ''} fl mr40`}>合作者</Link> + {/*jupyter*/} + <Link to={`/shixuns/${shixunId}/dataset`} + className={`${match.url.indexOf('dataset') != -1 ? 'active' : ''} fl mr40`}>数据集</Link> + <Link to={`/shixuns/${shixunId}/shixun_discuss`} className={`${match.url.indexOf('shixun_discuss') != -1 ? 'active' : ''} fl mr40`}>评论</Link> diff --git a/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js b/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js new file mode 100644 index 000000000..3b7abf44b --- /dev/null +++ b/public/react/src/modules/tpm/shixunchild/Challenges/Challengesjupyter.js @@ -0,0 +1,354 @@ +import React, { Component } from 'react'; + +import { Redirect } from 'react-router'; + +import { BrowserRouter as Router, Route, Link, Switch } from "react-router-dom"; + +import PropTypes from 'prop-types'; + +import classNames from 'classnames'; + +import { getImageUrl ,markdownToHTML, configShareForCustom} from 'educoder' + +import { CircularProgress } from 'material-ui/Progress'; + +import { Modal, Spin, Tooltip ,message,Icon} from 'antd'; + +import 'antd/lib/pagination/style/index.css'; + +import '../shixunchildCss/Challenges.css' +import ReactDOM from 'react-dom'; +import axios from 'axios'; + +import AccountProfile from"../../../user/AccountProfile"; + +const $ = window.$; + + +class Challengesjupyter extends Component { + constructor(props) { + super(props) + this.state = { + ChallengesDataList: undefined, + operate: true, + startbtns: false, + iFrameHeight: '0px' + } + } + + ChallengesList = () => { + let id = this.props.match.params.shixunId; + let ChallengesURL = `/shixuns/` + id + `/challenges.json`; + + axios.get(ChallengesURL).then((response) => { + if (response.status === 200) { + if (response.data.status === 403||response.data.status === 401||response.data.status === 500) { + + }else{ + configShareForCustom(this.props.shixunsDetails.name, response.data.description) + this.setState({ + ChallengesDataList: response.data, + sumidtype: false, + }); + } + } + }).catch((error) => { + console.log(error) + }); + } + + componentDidMount() { + setTimeout(this.ChallengesList(), 1000); + // var iframe = + // document.getElementById('ifr1'); + // console.log("iframe||||||||"); + // console.log(iframe); + // if(iframe){ + // // var headertest=test.contentWindow.document.getElementById('header'); + // // console.log(headertest); + // var iwindow = iframe.contentWindow; + // var idoc = iwindow.document; + // console.log("window",iwindow);//获取iframe的window对象 + // console.log("windowwindow",iwindow.document.getElementById('header'));//获取iwindow.document对象 + // console.log("document",idoc); //获取iframe的document + // console.log("documentdocument",idoc.getElementById('header')); + // console.log("html",idoc.documentElement);//获取iframe的html + // console.log("head",idoc.head); //获取head + // console.log("body",idoc.body); //获取body + // } + + + } + + updatamakedown = (id) => { + + } + + // 关卡的上移下移操作 + operations = (sumid, type) => { + + } + delOperations = (sumid) => { + + } + + clonedelOperationss = () => { + + } + delOperationss = () => { + + } + + startgameid=(id)=>{ + + + + + } + + hidestartshixunsreplace=(url)=>{ + + + } + + //编辑实训题目选择题 + EditTraining=(type, ids, path)=>{ + + } + + //开始实战按钮 + startshixunCombat = (type, ids, id) => { + + + + + } + hidestartshixunCombattype=()=>{ + + } + + hideAccountProfile=()=>{ + + }; + + modifyjupyter=()=>{ + // var ifr =window.parent.frames["frame"].document; + // console.log(ifr); + + var ifr = window.document.getElementById("ifr1"); + console.log("modifyjupyter"); + console.log(ifr); + const iframe = window.document.getElementById('ifr1'); + console.log("modifyjupyter"); + const frameWindow = iframe.contentWindow; + console.log(frameWindow); + const frameDocument = frameWindow.document; + console.log(frameDocument); + + // window.addEventListener('load', () => { + // console.log('12313页面加载好了'); + // const iframe = document.getElementById('ifr1'); + // if (iframe && iframe.contentWindow && this.props.iframe_src) { + // console.log('32131231yes mounted'); + // console.log(iframe.contentWindow); + // } else { + // console.log('3242242not mounted') + // } + // }); + + // var editor; + // editor = document.getElementById("ifr1").contentWindow; + // console.log(editor); + + + + // window.onload = () => { + // var testwindow = + // document.getElementById('ifr1').contentWindow; + // + // } + + + + + // var iframe=window.frames["ifr1"]; + // // var title =${'ifr1'} + // console.log("iframe"); + // console.log(iframe); + // var frames = window.frames; // 或 // var frames = window.parent.frames; + // for (var i = 0; i < frames.length; i++) { + // // 在这对frames的一个frame做点什么 + // // frames[i].document.body.style.background = "red"; + // console.log(frames[i]); + // + // } + // var idoc = iframe.document; + // console.log(idoc); + // var iwindow = title.contentWindow; + // console.log("iwindow"); + // console.log(iwindow); + // var idoc = iwindow.document; + // console.log(idoc); + // window.addEventListener('message', receiveMessageFromParent, false); + // + // let messageButton = document.getElementById('message_button'); + // /* console.log('msg button', messageButton); annoataion cannot use \/\/ */ + // messageButton.addEventListener('click', function (e) { + // console.log('iframe send msg'); + // console.log('parent', window.parent); + // console.log('top container', window.top); + // window.parent.postMessage('This is child', '*'); + // }, false); + + + + + + + // var iframe = $('#ifr1'); + // console.log(iframe.context.find('#save-notbook')); + // console.log("iframe"); + // console.log(iframe) + // title.window.say(); //myFrame.say();也可 + // + // title.window.document.getElementById("button").value="保存并检查"; + //find button inside iframe + // let button = iframe.contents().find('#save-notbook'); + // //trigger button click + // button.trigger("click"); + // console.log("iframe||||||||"); + // if(iframe){ + // var iwindow = iframe.contentWindow; + // var idoc = iwindow.document; + // console.log("window",iwindow);//获取iframe的window对象 + // console.log("document",idoc); //获取iframe的document + // console.log("html",idoc.documentElement);//获取iframe的html + // console.log("head",idoc.head); //获取head + // console.log("body",idoc.body); //获取body + // } + // var test = + // document.getElementById('ifr1').contentWindow.document.getElementById('header'); + // test.style.background = "#333"; + + } + + render() { + let{ChallengesDataList}=this.state; + let id = this.props.match.params.shixunId; +// var deptObjs=document.getElementById("IFRAMEID").contentWindow.document.getElementById("TAGID"); +// //判断此元素是否存在 +// if(deptObjs!=null){ +// //设置该元素的样式或其他属性 +// deptObjs.setAttribute('style',' height: 20px !important;'); //!important用来提升指定样式条目的应用优先权 +// } +// var submitObj = document.getElementById('submit'); +// if(submitObj){ +// submitObj.style.color = 'green'; +// } +// const dom = document.getElementById('shutdown'); +// ReactDOM.unmountComponentAtNode(dom) +// // window.$('#picture_display').hide(); +// window.$('.data-tip-right').hide() +// window.onload=()=>{ +// debugger +// var _iframe = document.getElementById('header'); +// console.log(_iframe); +// // .contentWindow.document.getElementById('shutdown_widget') //get iframe下的id +// // _iframe.style.display= "none"; //修改样式 +// } + + + + + + return ( + <React.Fragment> + <div className="mt30 pl20 pr20" > + <p className="clearfix mb20"> + <span className="font-16 fl">简介</span> + <Tooltip placement="bottom" title={"编辑"}> + <a style={{ display: this.props.identity < 5 && ChallengesDataList&&ChallengesDataList.shixun_status < 3 ? "block" : 'none' }} + href={"/shixuns/" + id + "/settings?edit=1"} className="ring-green fr"> + <img src={getImageUrl("images/educoder/icon/edit.svg")} className="fl mt3 ml2" /> + </a> + </Tooltip> + + </p> + + <div className="justify break_full_word new_li " + id="challenge_editorMd_description"> + <p id="ReactMarkdown" style={{overflow:'hidden'}}> + {ChallengesDataList === undefined ? "" :ChallengesDataList&&ChallengesDataList.description===null?"": + <div className={"markdown-body"} dangerouslySetInnerHTML={{__html: markdownToHTML(ChallengesDataList.description).replace(/▁/g,"▁▁▁")}}></div> + } + </p> + <style> + { + ` + .intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + } + + .sortinxdirection{ + display: flex; + flex-direction:row; + } + + .xaxisreverseorder{ + display: flex; + flex-direction:row-reverse; + } + ` + } + </style> + + <div className="sortinxdirection mt60"> + <div className="renwuxiangssi sortinxdirection"> + <div><p className="renwuxiangqdiv">任务详情</p></div> <div><p className="renwuxiangqdivtest ml24">示例</p></div> + </div> + <div className="renwuxiangssit xaxisreverseorder"><div className="challenbaocun" onClick={()=>this.modifyjupyter()}><p className="challenbaocuntest">保存</p></div></div> + </div> + <style> + { + ` + iframe { + border-width: 0px; + border-style: inset; + border-color: initial; + border-image: initial; + } + iframe { + border-left: 1px solid #eeeeee; + border-top: 1px solid #eeeeee; + border-right: 1px solid #eeeeee; + border-bottom: 1px solid #eeeeee; + } + #header{ + visibility:hidden; + } + ` + } + </style> + <div className="mt35"> + {/*https://48888.jupyter.educoder.net/tree?*/} + + <div className="pb47"> + <iframe src="http://121.41.4.83:48888/tree?" scrolling="no" id="ifr1" name="frame" width="100%" height="700" frameborder="0" + + + ></iframe> + </div> + </div> + </div> + </div> + + </React.Fragment> + + ) + } +} + +export default Challengesjupyter; diff --git a/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.css b/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.css index 31917086f..4c45f581d 100644 --- a/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.css +++ b/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.css @@ -6,4 +6,126 @@ .line27{ line-height: 27px; vertical-align: 1px; -} \ No newline at end of file +} +/* 中间居中 */ +.intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; +} +/* 简单居中 */ +.intermediatecenterysls{ + display: flex; + align-items: center; +} +.spacearound{ + display: flex; + justify-content: space-around; + +} +.spacebetween{ + display: flex; + justify-content: space-between; +} +/* 头顶部居中 */ +.topcenter{ + display: -webkit-flex; + flex-direction: column; + align-items: center; + +} + + +/* x轴正方向排序 */ +/* 一 二 三 四 五 六 七 八 */ +.sortinxdirection{ + display: flex; + flex-direction:row; + +} +/* x轴反方向排序 */ +/* 八 七 六 五 四 三 二 一 */ +.xaxisreverseorder{ + display: flex; + flex-direction:row-reverse; +} +/* 垂直布局 正方向*/ +/* 一 + 二 + 三 + 四 + 五 + 六 + 七 + 八 */ +.verticallayout{ + display: flex; + flex-direction:column; +} +/* 垂直布局 反方向*/ +.reversedirection{ + display: flex; + flex-direction:column-reverse; +} + +.yslwushiwidth{ + width: 50%; +} +.yslwushiwidth90{ + width: 90%; +} +.yslwushiwidth10{ + width: 10%; +} +.yslwushiwidthbuton{ + width: 110px; +} +.yslwushiwidthcolortest{ + color: #A8A8A8; + font-size:16px; +} +.yslusername{ + color: #000000; + font-size: 18px; +} +.yslusercjz{ + width:60px; + height:28px; + border-radius:3px; + border:1px solid #F38B03; +} +.yslusercjztest{ + width:60px; + height:28px; + font-size:16px; + color:#F38B03; + line-height:28px; + text-align: center; +} +.w18{ + width: 18px; +} + +.maxnamewidth150{ + width: 150px; + max-width: 150px; + overflow:hidden; + text-overflow:ellipsis; + white-space:nowrap; + cursor: default; +} +.fabushixunwidth{ + color: #000000; + font-size: 16px; +} +.fabushixunwidthcolor{ + color: #4CACFF; + font-size: 16px; +} +.divfontexdivs{ + border-left: 1px solid #eeeeee; + border-top: 1px solid #eeeeee; + border-right: 1px solid #eeeeee; + border-bottom: 1px solid #eeeeee; +} diff --git a/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.js b/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.js index d67599bf1..51e56a601 100644 --- a/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.js +++ b/public/react/src/modules/tpm/shixunchild/Collaborators/Collaborators.js @@ -2,7 +2,7 @@ import React, { Component } from 'react'; import { Redirect } from 'react-router'; -import {Modal, Button, Radio, Input, Checkbox,message,Spin, Icon} from 'antd'; +import {Modal, Button, Radio, Input, Checkbox,message,Spin, Icon,Pagination} from 'antd'; import { BrowserRouter as Router, Route, Link, Switch } from "react-router-dom"; @@ -48,7 +48,9 @@ class Collaborators extends Component { user_name:undefined, school_name:undefined, spinnings:false, - useristrue:false + useristrue:false, + mylistansum:6, + limit:20, } } componentDidMount() { @@ -434,7 +436,10 @@ class Collaborators extends Component { collaboratorListsumtype, user_name, school_name, - useristrue + useristrue, + mylistansum, + page, + limit } = this.state; let {loadingContent} = this.props; const radioStyle = { @@ -448,18 +453,26 @@ class Collaborators extends Component { console.log(Searchadmin) return ( <React.Fragment> - <p className="clearfix mt30" - style={{display:this.props.identity<5?"block":"none"}} + <p className=" mt30 sortinxdirection" + style={{display:this.props.identity<5?"flex":"none"}} > - <a onClick={() => this.showCollaboratorsvisible("cooperation")} - className="edu-default-btn edu-greenback-btn fr mr20 height40" - data-remote="true"> - <span className={"line27"}>+ </span>添加合作者 - </a> - <a onClick={() => this.showCollaboratorsvisible("admin")} - style={{display:this.props.identity===1?"block":"none"}} - data-remote="true" - className="edu-default-btn edu-greenback-btn fr mr20 height40">更换管理员</a> + <div className="yslwushiwidth"> + <p className="edu-default-btn edu-greenback-btn ml20 height40 yslwushiwidthcolortest">共12人</p> + </div> + + <div className="yslwushiwidth xaxisreverseorder"> + <a onClick={() => this.showCollaboratorsvisible("cooperation")} + className="edu-default-btn edu-greenback-btn mr20 height40 yslwushiwidthbuton" + data-remote="true"> + <span className={"line27"}>+ </span>添加合作者 + </a> + <a onClick={() => this.showCollaboratorsvisible("admin")} + style={{display:this.props.identity===1?"flex":"none"}} + data-remote="true" + className="edu-default-btn edu-greenback-btn mr20 height40 yslwushiwidthbuton">更换管理员</a> + + </div> + </p> <Modal @@ -537,6 +550,8 @@ class Collaborators extends Component { <span className="fl edu-txt-w100 task-hide font-bd">职业</span> <span className="fl edu-txt-w180 task-hide font-bd ml80">单位</span> </p> + + <div className="mt5" style={{background: '#f7f9fd'}}> <Spin indicator={antIcon} spinning={this.state.spinnings}> <div className="clearfix"> @@ -584,39 +599,58 @@ class Collaborators extends Component { onClick={() => this.submit_add_collaborators_form()}>确定</a> </div> </Modal>:""} - + <style> + { + ` + .collaborators-item-middles{width: 100% !important; margin-left: 20px;} + .ysltithead{ + padding-bottom: 20px; + } + ` + } + </style> <div className="pl20" id="collaborators_list_info"> { collaboratorList===undefined?"":collaboratorList.map((item,key)=>{ if(key<collaboratorListsum){ return( - <div className="collaborators-item clearfix" key={key}> - <a href={item.user.user_url} target="_blank" className="mr20 fl"> - <img alt="用户头像" className="radius" height="80" src={getImageUrl("images/"+item.user.image_url)} width="80"/></a> - <div className="fl collaborators-item-middle"> - <p className="mb10"> - <a href={item.user.user_url} target="_blank">{item.user.name}</a> - - <span className="ml20" style={{display:this.props.power===false?"none":"inline-block"}}>{item.user.shixun_manager === true ? "(管理员)" : ""}</span> - </p> + <div className="collaborators-item clearfix sortinxdirection ysltithead" key={key}> + <a href={item.user.user_url} target="_blank" className="mr20 fl"> + <img alt="用户头像" className="radius" height="80" src={getImageUrl("images/"+item.user.image_url)} width="80"/></a> - <p className="color-grey-B2 font-12 mb10"><span className="mr20">{item.user.identity}</span><span>{item.user.school_name}</span></p> - <p className="mb10"> - <span className="mr20">发布 {item.user.user_shixuns_count}</span> - {/*<span>粉丝 */} - {/*<span id="user_h_fan_count">{item.user.fans_count}</span>*/} - {/*</span>*/} - </p> + <div className="fl collaborators-item-middles"> + <p className="mb10 "> + <a href={item.user.user_url} target="_blank" className="yslusername">{item.user.name}</a> - {/* <p className="color-grey-B2 task-hide">{item.user.brief_introduction}</p> */} + <span className={item&&item.user&&item.user.shixun_manager === true?"ml20 yslusercjz ":"ml20"} style={{display:this.props.power===false?"none":"inline-block"}}><p className="yslusercjztest">{item.user.shixun_manager === true ? "创建者" : ""}</p></span> + </p> + <p className="color-grey-B2 font-12 mb10 sortinxdirection mt14"> + <p className="yslwushiwidth90 sortinxdirection"> + <p className="mr20 font-16 w70">{item.user.identity}</p> + <p className={item.user.school_name===null||item.user.school_name===""?"":"mr40 font-16 maxnamewidth150"}>{item.user.school_name}</p> + <p className="fabushixunwidth">发布实训项目 <span className="fabushixunwidthcolor ml2">{item.user.user_shixuns_count}</span></p> + </p> + <div className="xaxisreverseorder yslwushiwidth10"> + {item.user.shixun_manager === true ? "" : + + <i className="iconfont icon-shanchu newbianji1 color-grey-c font-16 w40" + style={{display: this.props.power === false ? "none" : "block"}} + onClick={() => this.collaborators_delete(item.user.user_id)}> + </i> + } + </div> + </p> + {/*<p className="mb10">*/} + {/* */} + {/* /!*<span>粉丝 *!/*/} + {/* /!*<span id="user_h_fan_count">{item.user.fans_count}</span>*!/*/} + {/* /!*</span>*!/*/} + {/*</p>*/} + {/* <p className="color-grey-B2 task-hide">{item.user.brief_introduction}</p> */} </div> - - {item.user.shixun_manager === true ? "" : <a className="fr color-grey-c mr40 mt35 font-16" - style={{display: this.props.power === false ? "none" : "block"}} - onClick={() => this.collaborators_delete(item.user.user_id)}>删除</a>} {/*<a href="/watchers/unwatch?object_id=3039&object_type=user&shixun_id=61&target_id=3039" className="fr user_default_btn user_private_btn mt30 font-16 mr20" data-method="post" data-remote="true" rel="nofollow">取消关注</a>*/} </div> @@ -646,8 +680,19 @@ class Collaborators extends Component { <div className={collaboratorList.length>10&&collaboratorListsumtype===true?"":"none"} style={{textAlign:'center',borderTop:'1px solid #eee'}}> - <a className="loadMore" onClick={this.loadMore}>加载更多</a> - </div> + {/*<a className="loadMore" onClick={this.loadMore}>加载更多</a>*/} + { + mylistansum>5? + <div className="edu-txt-center mt40 mb40"> + <Pagination showQuickJumper current={page} + onChange={this.paginationonChanges} pageSize={limit} + total={mylistansum} + ></Pagination> + </div> + :"" + } + + </div> </React.Fragment> diff --git a/public/react/src/modules/tpm/shixunchild/shixunchildCss/Challenges.css b/public/react/src/modules/tpm/shixunchild/shixunchildCss/Challenges.css index 493a95301..1fe5bf652 100644 --- a/public/react/src/modules/tpm/shixunchild/shixunchildCss/Challenges.css +++ b/public/react/src/modules/tpm/shixunchild/shixunchildCss/Challenges.css @@ -25,4 +25,44 @@ .addshixuns{ height: 27px; line-height: 25px; -} \ No newline at end of file +} +.challenbaocun{ + width:80px; + height:30px; + background:#29BD8B; + border-radius:3px; +} +.challenbaocuntest{ + width:80px; + height:30px; + font-size:16px; + color:#FFFFFF; + text-align: center; + line-height:30px; +} +.renwuxiangqdiv{ + width:72px; + height:30px; + font-size:18px; + color:#000000; + line-height:30px; +} +.renwuxiangqdivtest{ + width:32px; + height:30px; + font-size:16px; + font-family:MicrosoftYaHei; + color:#4CACFF; + line-height:30px; +} + +.renwuxiangssi{ + width: 30%; +} +.renwuxiangssit{ + width: 70%; +} + +.pb47{ + padding-bottom: 47px; +} diff --git a/public/react/src/modules/tpm/shixuns/ShixunCard.js b/public/react/src/modules/tpm/shixuns/ShixunCard.js index 9f62ed6b7..19908d0dd 100644 --- a/public/react/src/modules/tpm/shixuns/ShixunCard.js +++ b/public/react/src/modules/tpm/shixuns/ShixunCard.js @@ -95,6 +95,33 @@ class ShixunCard extends Component { left: 10px; bottom: 125px; } + .tag-org{ + position: absolute; + left: 0px; + top: 20px; + } + .tag-org-name{ + width:66px; + height:28px; + background:#FF6802; + width:66px; + height:28px; + border-radius:0px 20px 20px 0px; + } + .tag-org-name-test{ + width:45px; + height:23px; + font-size:14px; + color:#FFFFFF; + line-height:19px; + margin-right: 6px; + } + .intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + } ` } </style> @@ -105,6 +132,10 @@ class ShixunCard extends Component { {/*<img style={{display:'block',height: '28px'}} src={require(`./shixunCss/tag2.png`)}/>*/} </div> } + <div className="tag-org"> + <p className="tag-org-name intermediatecenter"> <span className="tag-org-name-test">Jupyter</span></p> + {/*<img style={{display:'block',height: '28px'}} src={require(`./shixunCss/tag2.png`)}/>*/} + </div> <div className={item.power === false ? "closeSquare" : "none"}> <img src={getImageUrl("images/educoder/icon/lockclose.svg")} className="mt80 mb25"/> diff --git a/public/react/src/modules/tpm/shixuns/ShixunsIndex.js b/public/react/src/modules/tpm/shixuns/ShixunsIndex.js index 15579610d..581301766 100644 --- a/public/react/src/modules/tpm/shixuns/ShixunsIndex.js +++ b/public/react/src/modules/tpm/shixuns/ShixunsIndex.js @@ -404,7 +404,7 @@ class ShixunsIndex extends Component { {...this.state} OnSearchInput={this.OnSearchInput.bind(this)} /> - + {/*下方图片*/} <ShixunCard typepvisible={typepvisible} middleshixundata={middleshixundata.shixuns} diff --git a/public/react/src/modules/tpm/tpmmodel/tpmmodel.css b/public/react/src/modules/tpm/tpmmodel/tpmmodel.css new file mode 100644 index 000000000..b45f9e6b5 --- /dev/null +++ b/public/react/src/modules/tpm/tpmmodel/tpmmodel.css @@ -0,0 +1,121 @@ +.tpmborder{ + border: 1px solid; +} +/* 中间居中 */ +.intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; +} +/* 简单居中 */ +.intermediatecenterysls{ + display: flex; + align-items: center; +} +.spacearound{ + display: flex; + justify-content: space-around; + +} +.spacebetween{ + display: flex; + justify-content: space-between; +} +/* 头顶部居中 */ +.topcenter{ + display: -webkit-flex; + flex-direction: column; + align-items: center; + +} + + +/* x轴正方向排序 */ +/* 一 二 三 四 五 六 七 八 */ +.sortinxdirection{ + display: flex; + flex-direction:row; +} +/* x轴反方向排序 */ +/* 八 七 六 五 四 三 二 一 */ +.xaxisreverseorder{ + display: flex; + flex-direction:row-reverse; +} +/* 垂直布局 正方向*/ +/* 一 + 二 + 三 + 四 + 五 + 六 + 七 + 八 */ +.verticallayout{ + display: flex; + flex-direction:column; +} +/* 垂直布局 反方向*/ +.reversedirection{ + display: flex; + flex-direction:column-reverse; +} +.deletebutom{ + width:85px; + height:30px; + background:#C4C4C4; + border-radius:3px; +} +.deletebutomtext{ + width:28px; + height:19px; + font-size:14px; + color:#FFFFFF; + line-height:19px; +} +.deletebuttom{ + width:85px; + height:30px; + background:#29BD8B; + border-radius:3px; +} +.deletebuttomtest{ + width:56px; + height:19px; + font-size:14px; + color:#FFFFFF; + line-height:19px; +} +.tpmwidth{ + width: 50%; +} +.mr21{ + margin-right: 21px; +} + +.wenjiantit{ + width: 300px; +} +.zuihoushijian{ + width: 125px; +} +.zuihouxiugairen{ + width: 70px; +} +.wenjiandaxiao{ + width: 56px; +} +.deletebutomtextcode{ + width:85px; + height:30px; + background:#FF5555; + border-radius:3px; +} +.light-row{ + background: #F7F7F8; +} +.dark-row{ + background: #FFFFFF; + +} diff --git a/public/react/src/search/SearchPage.js b/public/react/src/search/SearchPage.js index 1bf1d83d4..1a2b43440 100644 --- a/public/react/src/search/SearchPage.js +++ b/public/react/src/search/SearchPage.js @@ -20,12 +20,13 @@ class SearchPage extends Component{ page:1, perpages:20, data:[], + jupyterbool:false, } } //切换tab changeTab=(e)=>{ - // course 课堂, shixun 开发社区 subject 实践课程 memo 交流问答 + // course 2 课堂, shixun 0 实训项目 subject 1 实践课程 memo 3交流问答 let types =""; if(parseInt(e.key)===0){ @@ -106,7 +107,7 @@ class SearchPage extends Component{ } }).then((response) => { this.setState({ loading: false }) - + if(response === undefined){ return @@ -193,10 +194,23 @@ class SearchPage extends Component{ <div className={"font-16 color-dark fl "} style={{width:"100%"}} > {/*标题*/} - <span className={"markdown-body fonttext"} - dangerouslySetInnerHTML={{__html:item.title}}/> + <div className="sortinxdirection jupytertextheig" style={{width:"100%"}}> + { + type==="shixun"? + <div className="jupytertext intermediatecenter "><p className="jupytertextp">Jupyter</p></div> + :"" + } + <span className={"markdown-body fonttext ml9"} + + dangerouslySetInnerHTML={{__html:item.title}}/> + </div> + {/*描述*/} <div> + + + + {item.content.content === undefined || item.content.content===0?"": item.content.content.map((item4, key4) => { return ( <span className={"markdown-body magr11 fontextcolor"} @@ -221,8 +235,8 @@ class SearchPage extends Component{ <div> {/*挑战名字*/} - - + + {item.content.challenge_names === undefined || item.content.challenge_names===0?"": item.content.challenge_names.map((item5, key5) => { return ( <div className={"df"}> @@ -269,13 +283,13 @@ class SearchPage extends Component{ {/* <span className="ziticor"> <i className="fa fa-user ziticor"></i><span className="ml10">主讲:{item.author_name}</span> </span> - <span className="ml10 ziticor "><span>{item.author_school_name}</span></span> + <span className="ml10 ziticor "><span>{item.author_school_name}</span></span> <span className="ml20 ziticor"> <i className="iconfont icon-shixunguanqia ziticor"></i> <span>任务: <span className="ml10 ziticor">{item.challenges_count===undefined?0:item.challenges_count}</span> </span> - </span> + </span> <span className="ml20 ziticor"> <i className="iconfont icon-chengyuan ziticor"></i> <span>学习人数: @@ -287,7 +301,7 @@ class SearchPage extends Component{ {/* <i className="fa fa-user ziticor"></i> */} <span className="">{item.author_name}</span></span> <span className="ml10 ziticor "><span>{item.author_school_name}</span> - </span> + </span> {!!item.challenges_count && <span className="ml20 ziticor"> {/* <i className="iconfont icon-shixunguanqia ziticor"></i> */} <span>任务: @@ -325,7 +339,7 @@ class SearchPage extends Component{ {/* <i className="iconfont icon-huifu1 ziticor"></i> */} <span>回复数:<span className="ml10 ziticor">{item.all_replies_count}</span></span> </span> } - + {/* <span className="ml20 ziticor"> <i className="iconfont icon-chengyuan ziticor"></i> <span> @@ -368,4 +382,4 @@ class SearchPage extends Component{ } } -export default SnackbarHOC() (TPMIndexHOC ( SearchPage )); \ No newline at end of file +export default SnackbarHOC() (TPMIndexHOC ( SearchPage )); diff --git a/public/react/src/search/searchc.css b/public/react/src/search/searchc.css index 15c34650b..f2fb9ce85 100644 --- a/public/react/src/search/searchc.css +++ b/public/react/src/search/searchc.css @@ -131,4 +131,45 @@ margin-top: 20px; display: flex; flex-direction:row; -} \ No newline at end of file +} +.jupytertext{ + width:54px; + height:24px; + background:#FF6802; + border-radius:2px 10px 10px 2px; + margin-top: 2px; + text-align: center; + +} +.jupytertextp{ + width:39px; + height:16px; + font-size:12px; + color:#FFFFFF; + line-height:16px; +} +/* x轴正方向排序 */ +/* 一 二 三 四 五 六 七 八 */ +.sortinxdirection{ + display: flex; + flex-direction:row; +} +/* x轴反方向排序 */ +/* 八 七 六 五 四 三 二 一 */ +.xaxisreverseorder{ + display: flex; + flex-direction:row-reverse; +} +.intermediatecenter{ + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; +} +.jupytertextheig{ + height: 32px; + line-height: 32px; +} +.ml9{ + margin-left: 9px; +}