diff --git a/src/Add-on/ShareView/components/BoardMessageWidget.tsx b/src/Add-on/ShareView/components/BoardMessageWidget.tsx index a0e548982..6d42455bc 100644 --- a/src/Add-on/ShareView/components/BoardMessageWidget.tsx +++ b/src/Add-on/ShareView/components/BoardMessageWidget.tsx @@ -31,8 +31,10 @@ const BoardMessageWidget = (() => { e.stopPropagation(); }} - style={{ pointerEvents: 'auto', cursor: 'default' }} - >备注: + 备注: + = (props) => { const [open, setOpen] = useState(false); - function remarksToString(): string - { - let str = '{'; - props.remarks.forEach((item, i) => - { - str += `"${item[0]}": "${item[1]}"`; - if (i != props.remarks.length - 1) - { - str += ', '; - } - }); - str += '}'; - return str; - }; - return ( <> {Array.isArray(props.remarks) && props.remarks.length ? ( @@ -34,23 +19,21 @@ const BoardRemarksWidget: FC = (props) => style={{ cursor: 'pointer' }} onClick={(e) => { - if (props.isPhone) - { - e.stopPropagation(); - } + e.stopPropagation(); }} > - { - if (props.isPhone && props.remarks.length) - { - setOpen(true); - e.stopPropagation(); - } + setOpen(true); + e.stopPropagation(); }} > - {props.isPhone ? : remarksToString()} + @@ -58,10 +41,28 @@ const BoardRemarksWidget: FC = (props) => setOpen(false); }} title={`${props.name || "板件"} 备注`} - style={{ width: window.innerWidth <= 768 ? '80vw' : '600px', background: '#fff', paddingBottom: 16 }} + style={{ width: window.innerWidth <= 768 ? '90vw' : '600px', background: '#fff', paddingBottom: 16 }} > -
- {remarksToString()} +
+ + + + + + + + + {props.remarks.map((remark) => ( + + + + + ))} + +
备注名备注信息
{remark[0]}{remark[1]}
diff --git a/src/Add-on/ShareView/components/MaterialBottomSheet.tsx b/src/Add-on/ShareView/components/MaterialBottomSheet.tsx index ccd286db2..2c80bfbe6 100644 --- a/src/Add-on/ShareView/components/MaterialBottomSheet.tsx +++ b/src/Add-on/ShareView/components/MaterialBottomSheet.tsx @@ -202,11 +202,11 @@ const MaterialBottomSheet: React.FC = forwardRef((props, ref) => 名称 - 高度 - 宽度 + 高度 + 宽度 厚度 - 颜色 - 备注 + 颜色 + 备注 @@ -238,7 +238,7 @@ const MaterialBottomSheet: React.FC = forwardRef((props, ref) => {size.width} {size.thickness} {item.BoardProcessOption.color} - +