index.tsx 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. /**
  2. * 知识库
  3. */
  4. import { View, Text } from "@tarojs/components";
  5. import { useState } from "react";
  6. import PageCustom from "@/components/page-custom/index";
  7. import NavBarNormal from "@/components/NavBarNormal/index";
  8. import WemetaTabs from "@/components/wemeta-tabs/index";
  9. import PersonalTab from './components/PersonalTab'
  10. import CompanyTab from './components/CompanyTab'
  11. import CorrectionList from './components/CorrectionList'
  12. import style from "./index.module.less";
  13. export default function Index() {
  14. const tabList = [
  15. {
  16. key: "1",
  17. label: "个人知识",
  18. children: <View className={style.tabContent}>
  19. <PersonalTab />
  20. </View> ,
  21. },
  22. {
  23. key: "2",
  24. label: "企业知识",
  25. children: <View className={style.tabContent}>
  26. <CompanyTab/>
  27. </View>,
  28. },
  29. {
  30. key: "3",
  31. label: "纠错记录",
  32. children: <View className={style.tabContent}>
  33. <CorrectionList />
  34. </View>,
  35. },
  36. ];
  37. return (
  38. <PageCustom>
  39. <NavBarNormal scrollFadeIn leftColumn={() => <Text className="text-16 font-medium">知识库</Text>}></NavBarNormal>
  40. <View className="w-full">
  41. <View className={style.container}>
  42. <WemetaTabs current="1" list={tabList} className="px-16"></WemetaTabs>
  43. </View>
  44. </View>
  45. </PageCustom>
  46. );
  47. }