wiki:需要使用最新版gitee,暂时隐藏入口

This commit is contained in:
谢思 2024-01-30 14:45:29 +08:00
parent d0b126edbb
commit 9925e4e563
6 changed files with 38 additions and 9 deletions

View File

@ -131,8 +131,8 @@ function DetailBanner({ history,list , owner , projectsId ,showNotification , ur
<span>维基(Wiki)</span>
</Link>
</li>
}
{
} */}
{/* {
item.menu_name === "services" &&
<li className={pathname === "server" ? "active" : ""}>
<Link className='newTab' to={{ pathname: `/${owner}/${projectsId}/service`, state }}>

View File

@ -94,7 +94,7 @@ export default Form.create()(({ form, history, showNotification, projectDetail,
const helper = useCallback(
(label, name, rules, widget, initialValue, rightComponent) => (
<Form.Item label={label} className="mb0">
<Form.Item label={label} className="mb0" wrapperCol={{span: 18}}>
{getFieldDecorator(name, { rules, initialValue, validateFirst: true, })(widget)}
{rightComponent}
</Form.Item>
@ -330,7 +330,7 @@ export default Form.create()(({ form, history, showNotification, projectDetail,
/>
)}
<Form.Item className="mb0 wiki-md">
<Form.Item className="mb0 wiki-md" wrapperCol={{span: 18}}>
<MDEditor
placeholder={"请输入wiki内容"}
height={500}

View File

@ -8,9 +8,8 @@ body {
background: rgba(255,255,255,1);
}
.wiki-main {
width: 1200px;
min-height: 400px;
margin: 20px auto 60px;
margin: 20px;
.ant-btn-primary {
background-color: $wikiColor;

View File

@ -3,10 +3,10 @@
flex-flow: column nowrap;
justify-content: center;
align-items: center;
width: 1200px;
min-height: 400px;
// width: 1200px;
min-height: 70vh;
padding: 20px;
margin: 20px auto;
margin: 20px;
background: rgba(250, 252, 255, 1);
font-family: "PingFangSC-Medium";
border-radius: 4px;

View File

@ -181,6 +181,22 @@ export function findNodeByKey(list, key){
return undefined;
}
// 找到children中有相同key的数组
export function findBrotherNodesByKey(list, key){
for (let index = 0; index < list.length; index++) {
const element = list[index];
if (element.key == key) {
return list;
}else if (element.children && element.children.length) {
let result = findBrotherNodesByKey(element.children, key);
if (result.length) {
return result;
}
}
}
return [];
}
// 找到children中有相同key的数组
export function findNodeByChildrenKey(list, key){
for (let index = 0; index < list.length; index++) {

View File

@ -422,6 +422,20 @@ export default function Sidebar(props) {
}
}
function findBrotherNodesByKey(list, key){
for (let index = 0; index < list.length; index++) {
const element = list[index];
if (element.key == key) {
return list;
}else if (element.children && element.children.length) {
let result = findBrotherNodesByKey(element.children, key);
if (result.length) {
return result;
}
}
}
return [];
}
function onDrop(info){
// dragNode: node: