Add writefull "AI Assistance" section GitOrigin-RevId: c6d4cb60601c0b808cde96f29f6b79b26f631906
21 lines
642 B
TypeScript
21 lines
642 B
TypeScript
import { TabPane } from 'react-bootstrap'
|
|
import { SettingsTab } from '../context/types'
|
|
import SettingsSection from './settings-section'
|
|
import { Fragment } from 'react'
|
|
|
|
export default function SettingsTabPane({ tab }: { tab: SettingsTab }) {
|
|
const { key, sections } = tab
|
|
return (
|
|
<TabPane eventKey={key} key={key}>
|
|
{sections.map(section => (
|
|
<SettingsSection key={section.key} title={section.title}>
|
|
{section.settings.map(
|
|
({ key, component, hidden }) =>
|
|
!hidden && <Fragment key={key}>{component}</Fragment>
|
|
)}
|
|
</SettingsSection>
|
|
))}
|
|
</TabPane>
|
|
)
|
|
}
|