This commit is contained in:
谢思 2025-12-26 17:56:38 +08:00
parent bd808636d9
commit 6f046968b4
5 changed files with 30 additions and 10 deletions

View File

@ -25,6 +25,25 @@ const OpenSourceCollaboration = ({isVisible}) => {
}
];
useEffect(() => {
const interval = setInterval(() => {
setActive(prevActive => {
return prevActive === 1 ? 2 : 1;
});
}, 6000);
//
return () => {
clearInterval(interval);
};
}, []);
useEffect(()=>{
if(isVisible){
setActive(1);
}
}, [isVisible])
const handleFeatureClick = (feature) => {
setSelectedFeature(selectedFeature === feature ? null : feature);
};

View File

@ -770,7 +770,7 @@
}
.software-left-item {
cursor: pointer;
// cursor: pointer;
max-height: max-content;
&.active {
@ -957,7 +957,7 @@
height: 40px;
left: 50%;
transform: translateX(-50%);
bottom: 150px;
bottom: -20px;
}
.content-wrapper {

View File

@ -136,7 +136,7 @@ function ProjectHomePage(props) {
<div className="font-60 p_h_title center pt70">开源软件仓库·<span className="p_h_title_text">护航菌事数智</span></div>
<div className="font-18 center mb40">汇聚全球顶尖开源力量构建安全协同创新的软件生态赋能菌事数字化转型与智能化升级</div>
<div className="df">
<div className="df color-white project_count flex1 FlexAJ">
<div className="color-white project_count flex1 FlexAJ" style={{justifyContent: count.length > 3 ? 'space-between' : 'space-around'}}>
{count.map((item, index)=>{
const logoIndex = index%5
return <Fragment>
@ -188,7 +188,7 @@ function ProjectHomePage(props) {
</div>}
<div className="flex1">
{/* 推荐仓库 */}
<div className="project_recommend">
{bannerProjects && !!bannerProjects.length && <div className="project_recommend mb20">
<Carousel autoplay ref={carouselEL} afterChange={setCurrent}>
{bannerProjects.map(i => {
const url = i.author ? `/${i.author.login}/${i.identifier}${i.author.login === "gh_mirrors" ? "/about" : "/about"}` : ``
@ -210,8 +210,8 @@ function ProjectHomePage(props) {
</div>
})}
</Carousel>
</div>
<div className="mb20 mt20 tipByCate_Popover_box">
</div>}
<div className="mb20 tipByCate_Popover_box">
{topicId && topicDetail && topicDetail.intro && <Popover
getPopupContainer={trigger => trigger.parentNode}
content={
@ -260,7 +260,7 @@ function ProjectHomePage(props) {
</div>
</Tooltip>} */}
{i.author && i.author.login !== "gh_mirrors" && <a className="download-icon mt10" href={url}><i className="iconfont icon-a-xiazai3 font-12 mr5 color-dark"></i>下载</a>}
<Button className="detail-but-black">查看详情</Button>
<Button className="detail-but-black" href={url}>查看详情</Button>
</div>
})}
</div> : <Nodata _html="暂无数据" />}

View File

@ -217,6 +217,7 @@
.detail-but-black {
line-height: 32px;
width: 88%;
color: #ffffff;
background-color: #2149d4;

View File

@ -129,14 +129,14 @@ function List(props) {
<div className="width1600 center">
<div className="font-60 font-bd forums-banner-title1">论坛交流·<span className="carousel-text">解锁头脑风暴</span></div>
<div className="font-18 mb35">开源动态社区前言新闻速递开启开源新视野</div>
{forumsDoMain && <Button className="add-forums" href={`${forumsDoMain}/forums/new`}>发布帖子</Button>}
{forumsDoMain && <Button className="add-forums font-18" href={`${forumsDoMain}/forums/new`}>发布帖子</Button>}
</div>
<div className="width1600 df pt70">
<Carousel autoplay infinite={0} className='forums-list-left-Carousel' afterChange={(current)=>{setActiveId(current)}}>
{forumsImgList && !!forumsImgList.length && <Carousel autoplay className='forums-list-left-Carousel' beforeChange={(_, nextId)=>{setActiveId(nextId)}}>
{forumsImgList.map((item, index)=>{
return <img src={httpUrl + item.memo_image_info.url} alt=''key={index}/>
})}
</Carousel>
</Carousel>}
<div className="forums-list1">
{forumsList.map((item, index) => (
<div className={`font-18 forums-list-item ${activeId === index ? 'forums-list-item-active' : ''}`} key={index}>