page.js 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327
  1. import React from 'react';
  2. import './index.less';
  3. import Page from '@src/containers/Page';
  4. import Continue from '../../../components/Continue';
  5. import Tabs from '../../../components/Tabs';
  6. import Module from '../../../components/Module';
  7. import Division from '../../../components/Division';
  8. import Panel, { BuyPanel, WaitPanel, SmallPanel, SmallWaitPanel, SmallBuyPanel } from '../../../components/Panel';
  9. import Card, { Card1 } from '../../../components/Card';
  10. import List from '../../../components/List';
  11. import ListTable from '../../../components/ListTable';
  12. import ProgressText from '../../../components/ProgressText';
  13. import IconButton from '../../../components/IconButton';
  14. import Step from '../../../components/Step';
  15. import OtherAnswer from '../../../components/OtherAnswer';
  16. import QAList from '../../../components/QAList';
  17. import Select from '../../../components/Select';
  18. import Video from '../../../components/Video';
  19. export default class extends Page {
  20. renderView() {
  21. return (
  22. <div>
  23. <Video src="/01.mp4" />
  24. <Continue date={'2019-04-29 16:30'} data={{}} />
  25. <div className="content">
  26. <Select list={[{ title: '123' }, { title: '321' }]} />
  27. <Select theme="white" list={[{ title: '123' }, { title: '321' }]} />
  28. <Select theme="default" list={[{ title: '123' }, { title: '321' }]} />
  29. <Division col="3" type="compact">
  30. <SmallPanel
  31. title="千行 CAT"
  32. lock
  33. data={{ info: [{ title: '123', number: '123', unit: '1' }, { title: '123', number: '123', unit: '1' }] }}
  34. />
  35. <SmallWaitPanel title="千行 CAT" />
  36. <SmallBuyPanel title="千行 CAT" />
  37. </Division>
  38. <Division col="2">
  39. <WaitPanel
  40. title="OG"
  41. col="3"
  42. data={{
  43. info: [
  44. { title: '123', number: 123, unit: '%' },
  45. { title: '123', number: 123, unit: '%' },
  46. { title: '123', number: 123, unit: '%' },
  47. { title: '123', number: 123, unit: '%' },
  48. ],
  49. desc: ['最近换库:2019-07-20 ,已换库10天', '最后更新:2019-07-28 00:28:49'],
  50. children: [
  51. { progress: 10, title: '测试' },
  52. { progress: 10, title: '测试' },
  53. { progress: 0, title: '测试' },
  54. ],
  55. }}
  56. />
  57. <Panel
  58. title="OG"
  59. col="3"
  60. data={{
  61. info: [
  62. { title: '123', number: 123, unit: '%' },
  63. { title: '123', number: 123, unit: '%' },
  64. { title: '123', number: 123, unit: '%' },
  65. { title: '123', number: 123, unit: '%' },
  66. ],
  67. desc: ['最近换库:2019-07-20 ,已换库10天', '最后更新:2019-07-28 00:28:49'],
  68. children: [
  69. { progress: 10, title: '测试' },
  70. { progress: 10, title: '测试' },
  71. { progress: 0, title: '测试' },
  72. ],
  73. }}
  74. />
  75. <BuyPanel title="OG" />
  76. </Division>
  77. <QAList data={[]} />
  78. <Tabs
  79. type="tag"
  80. active="main"
  81. space={5}
  82. tabs={[
  83. { key: 'main', name: '首页', path: '/' },
  84. { key: 'ready', name: 'GetReady', path: '/' },
  85. { key: 'exercise', name: '练习', path: '/' },
  86. { key: 'cat', name: 'CAT模考', path: '/' },
  87. { key: 'item', name: '题库', path: '/' },
  88. { key: 'machine', name: '换库&机经', path: '/' },
  89. ]}
  90. />
  91. <Module className="m-t-2">
  92. <Tabs
  93. type="card"
  94. active="main"
  95. tabs={[
  96. { key: 'main', name: '首页', path: '/' },
  97. { key: 'ready', name: 'GetReady', path: '/' },
  98. { key: 'exercise', name: '练习', path: '/' },
  99. { key: 'cat', name: 'CAT模考', path: '/' },
  100. { key: 'item', name: '题库', path: '/' },
  101. { key: 'machine', name: '换库&机经', path: '/' },
  102. ]}
  103. />
  104. <Tabs
  105. active="main"
  106. tabs={[
  107. { key: 'main', name: '首页', path: '/' },
  108. { key: 'ready', name: 'GetReady', path: '/' },
  109. { key: 'exercise', name: '练习', path: '/' },
  110. { key: 'cat', name: 'CAT模考', path: '/' },
  111. { key: 'item', name: '题库', path: '/' },
  112. ]}
  113. />
  114. </Module>
  115. <Module>
  116. <Tabs
  117. active="main"
  118. border
  119. width="180px"
  120. space="0"
  121. tabs={[
  122. { key: 'main', name: '首页', path: '/' },
  123. { key: 'ready', name: 'GetReady', path: '/' },
  124. { key: 'exercise', name: '练习', path: '/' },
  125. { key: 'cat', name: 'CAT模考', path: '/' },
  126. { key: 'item', name: '题库', path: '/' },
  127. ]}
  128. />
  129. <Tabs
  130. active="main"
  131. type="text"
  132. tabs={[
  133. { key: 'main', name: '首页', path: '/' },
  134. { key: 'ready', name: 'GetReady', path: '/' },
  135. { key: 'exercise', name: '练习', path: '/' },
  136. { key: 'cat', name: 'CAT模考', path: '/' },
  137. { key: 'item', name: '题库', path: '/' },
  138. ]}
  139. />
  140. </Module>
  141. <Module>
  142. <Step
  143. list={[
  144. '「1」前言',
  145. '「2」重新认识',
  146. '「3」基本元素',
  147. '「4」简单变长',
  148. '「5」练习',
  149. '「6」翻译',
  150. '「7」附录',
  151. ]}
  152. step="4"
  153. />
  154. </Module>
  155. <Division col="2">
  156. <Panel
  157. title="OG"
  158. col="3"
  159. data={{
  160. info: [
  161. { title: '123', number: 123, unit: '%' },
  162. { title: '123', number: 123, unit: '%' },
  163. { title: '123', number: 123, unit: '%' },
  164. { title: '123', number: 123, unit: '%' },
  165. ],
  166. desc: ['最近换库:2019-07-20 ,已换库10天', '最后更新:2019-07-28 00:28:49'],
  167. children: [
  168. { progress: 10, title: '测试' },
  169. { progress: 10, title: '测试' },
  170. { progress: 0, title: '测试' },
  171. ],
  172. }}
  173. />
  174. <Panel
  175. title="OG"
  176. col="4"
  177. data={{
  178. info: [
  179. { title: '123', number: 123 },
  180. { title: '123', number: 123 },
  181. { title: '123', number: 123 },
  182. { title: '123', number: 123 },
  183. ],
  184. children: [
  185. { progress: 10, title: '测试' },
  186. { progress: 10, title: '测试' },
  187. { progress: 0, title: '测试' },
  188. ],
  189. }}
  190. />
  191. </Division>
  192. <Division col="3">
  193. <Card1 title="句改 SC" data={{ status: 'open', qrCode: '123' }} />
  194. <Card1 title="句改 SC" tag="视频课程" data={{ status: 'stop' }} />
  195. <Card1 title="句改 SC" tag="视频课程" data={{ status: 'open' }} />
  196. <Card1
  197. title="句改 SC"
  198. tag="视频课程"
  199. data={{
  200. status: 'ing',
  201. list: [
  202. { progress: 30, title: '课时5:掌握语法结构', status: 'start' },
  203. { progress: 40, title: '课时5:掌握语法结构', status: 'ing' },
  204. ],
  205. }}
  206. />
  207. <Card1 title="句改 SC" tag="视频课程" data={{ status: 'ing', list: [] }} />
  208. <Card1 title="句改 SC" tag="视频课程" data={{ status: 'end' }} />
  209. </Division>
  210. <Division col="3">
  211. <Card title="句改 SC" data={{ status: 'buy', desc: ['名师讲解', '精进学习', '提升成绩'] }} />
  212. <Card title="句改 SC" data={{ status: 'open' }} />
  213. <Card
  214. title="句改 SC"
  215. data={{
  216. status: 'ing',
  217. list: [
  218. { progress: 30, date: '2019-04-22', status: 'start' },
  219. { progress: 40, date: '2019-04-22', status: 'ing' },
  220. ],
  221. }}
  222. />
  223. <Card title="句改 SC" data={{ status: 'ing', list: [] }} />
  224. <Card title="句改 SC" data={{ status: 'end' }} />
  225. </Division>
  226. <List
  227. position="Chapter4"
  228. title="简单句如何变长难句"
  229. list={[{ progress: 30, title: '什么样的句子叫长难句,长难句的基本特征。', position: 'Part 1' }]}
  230. />
  231. <ListTable
  232. position="Chapter5"
  233. title="练习"
  234. filters={[
  235. { type: 'radio', checked: 'first', list: [{ key: 'first', title: 123 }, { key: 'two', title: 321 }] },
  236. { type: 'select', checked: 'first', list: [{ key: 'first', title: 123 }, { key: 'two', title: 321 }] },
  237. ]}
  238. data={[{}]}
  239. columns={[
  240. {
  241. title: '练习册',
  242. width: 250,
  243. align: 'left',
  244. render: () => {
  245. return (
  246. <div className="table-row">
  247. <div className="night f-s-16">OG18 综合:第1-20题</div>
  248. <div>
  249. <ProgressText progress="30" size="small" />
  250. </div>
  251. </div>
  252. );
  253. },
  254. },
  255. {
  256. title: '正确率',
  257. width: 150,
  258. align: 'left',
  259. render: () => {
  260. return (
  261. <div className="table-row">
  262. <div className="night f-s-16 f-w-b">--</div>
  263. <div className="f-s-12">全站55%</div>
  264. </div>
  265. );
  266. },
  267. },
  268. {
  269. title: '全站用时',
  270. width: 150,
  271. align: 'left',
  272. render: () => {
  273. return (
  274. <div className="table-row">
  275. <div className="night f-s-16 f-w-b">55%</div>
  276. <div className="f-s-12">全站56s</div>
  277. </div>
  278. );
  279. },
  280. },
  281. {
  282. title: '最近做题',
  283. width: 150,
  284. align: 'left',
  285. render: () => {
  286. return (
  287. <div className="table-row">
  288. <div>2019-04-28</div>
  289. <div>07:30</div>
  290. </div>
  291. );
  292. },
  293. },
  294. {
  295. title: '操作',
  296. width: 180,
  297. align: 'left',
  298. render: () => {
  299. return (
  300. <div className="table-row p-t-1">
  301. <IconButton className="m-r-2" type="continue" tip="Continue" />
  302. <IconButton type="restart" tip="Restart" />
  303. </div>
  304. );
  305. },
  306. },
  307. {
  308. title: '报告',
  309. width: 30,
  310. align: 'right',
  311. render: () => {
  312. return (
  313. <div className="table-row p-t-1">
  314. <IconButton type="report" tip="Report" />
  315. </div>
  316. );
  317. },
  318. },
  319. ]}
  320. />
  321. <OtherAnswer data={{ content: '123123', answer: '123123123' }} />
  322. </div>
  323. </div>
  324. );
  325. }
  326. }