page.js 12 KB

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