mirror of
https://github.com/Funkoala14/KnowledgeBase_OOIN.git
synced 2025-06-08 07:38:14 +08:00
35 lines
1.2 KiB
JavaScript
35 lines
1.2 KiB
JavaScript
import React from 'react';
|
|
import { Link } from 'react-router-dom';
|
|
|
|
/**
|
|
* 面包屑导航组件
|
|
*/
|
|
const Breadcrumb = ({ knowledgeBase, activeTab }) => {
|
|
return (
|
|
<div className='d-flex align-items-center mb-4 mt-3'>
|
|
<nav aria-label='breadcrumb'>
|
|
<ol className='breadcrumb mb-0'>
|
|
<li className='breadcrumb-item'>
|
|
<Link className='text-secondary text-decoration-none' to='/'>
|
|
知识库
|
|
</Link>
|
|
</li>
|
|
<li className='breadcrumb-item'>
|
|
<Link
|
|
className='text-secondary text-decoration-none'
|
|
to={`/knowledge-base/${knowledgeBase.id}`}
|
|
>
|
|
{knowledgeBase.name}
|
|
</Link>
|
|
</li>
|
|
<li className='breadcrumb-item active text-dark' aria-current='page'>
|
|
{activeTab === 'datasets' ? '数据集' : '设置'}
|
|
</li>
|
|
</ol>
|
|
</nav>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export default Breadcrumb;
|