diff --git a/src/components/CardView/index.tsx b/src/components/CardView/index.tsx new file mode 100644 index 0000000..c62c1e3 --- /dev/null +++ b/src/components/CardView/index.tsx @@ -0,0 +1,15 @@ +import type React from 'react'; +import './style.less'; + +interface Props { + style?: React.CSSProperties; + children: React.ReactNode; +} + +export default function CardView({ style, children }: Props) { + return ( +
+ {children} +
+ ); +} diff --git a/src/components/CardView/style.less b/src/components/CardView/style.less new file mode 100644 index 0000000..e595fb1 --- /dev/null +++ b/src/components/CardView/style.less @@ -0,0 +1,5 @@ +.card-view { + padding: 15px; + border-bottom: 1px solid #eee; + background-color: #fff; +} diff --git a/src/components/RowText/index.tsx b/src/components/RowText/index.tsx new file mode 100644 index 0000000..209a39d --- /dev/null +++ b/src/components/RowText/index.tsx @@ -0,0 +1,26 @@ +import React from 'react'; +import type { CSSProperties } from 'react'; +import { Row } from '@feewee/h5app-common'; + +import './style.less'; + +interface ComponentProps { + title: string; + content: string | number; + rowStyle?: CSSProperties; + titleStyle?: CSSProperties; + contentStyle?: CSSProperties; +} + +export default function RowText({ title, content, rowStyle, titleStyle, contentStyle }: ComponentProps) { + return ( + + + {title}: + + + {content} + + + ); +} diff --git a/src/components/RowText/style.less b/src/components/RowText/style.less new file mode 100644 index 0000000..216d95e --- /dev/null +++ b/src/components/RowText/style.less @@ -0,0 +1,29 @@ +.row-wrapper { + margin-bottom: 10px; +} + +.label { + color: #666; + font-size: 14px; + line-height: 14px; + font-weight: 500; +} + +.content { + color: #666; + font-size: 14px; + line-height: 14px; + font-weight: 500; + flex: 1; +} + +.labelBold { + color: #333; + font-size: 15px; + font-weight: bold; +} + +.contentBold { + .labelBold; + flex: 1; +} diff --git a/src/routes/rescue/handle/page.tsx b/src/routes/rescue/handle/page.tsx index 73aea97..8db2325 100644 --- a/src/routes/rescue/handle/page.tsx +++ b/src/routes/rescue/handle/page.tsx @@ -1,8 +1,11 @@ -import { helper, ListRow, Radio, IconFont, Space, PageProvider, Form, Input, TextArea, Uploader } from '@feewee/h5app-common'; -import { useSafeState } from 'ahooks'; import { useEffect } from 'react'; +import { useSafeState } from 'ahooks'; +import { helper, ListRow, Radio, IconFont, Space, PageProvider, Form, Input, TextArea, Uploader } from '@feewee/h5app-common'; import { useNavigate } from '@modern-js/runtime/router'; +import CardView from '@/components/CardView'; +import RowText from '@/components/RowText'; + const RadioGroup = Radio.Group; const Index = () => { @@ -11,26 +14,38 @@ const Index = () => { return ( helper.checkBack(() => navigate(-1))}> - - - - - +
+ + + + + + + + +
+ + + + + +
-
- - - 拖车 - 现场维修 - - - -