标签防御: height:fit-content+maxHeight物理切断+12px小字号防重叠
This commit is contained in:
@ -343,31 +343,35 @@ export default function CreateProductDialog({ open, onClose, onCreated }: Props)
|
||||
/* ---- 成功页 ---- */
|
||||
<div className="py-4">
|
||||
<div id="label-print-area" style={{
|
||||
display: "flex", flexDirection: "column", width: "100%", maxWidth: 360,
|
||||
margin: "0 auto", padding: 12, boxSizing: "border-box", background: "#fff",
|
||||
fontFamily: "'Helvetica Neue', Helvetica, Arial, sans-serif",
|
||||
border: "1px solid #e5e7eb", borderRadius: 8
|
||||
display: 'flex', flexDirection: 'column', width: '100%', maxWidth: '360px',
|
||||
margin: '0 auto', padding: '12px', boxSizing: 'border-box', background: '#fff',
|
||||
fontFamily: 'monospace, "Helvetica Neue", Helvetica, sans-serif',
|
||||
border: '1px solid #e5e7eb', height: 'fit-content'
|
||||
}}>
|
||||
<div style={{ display: "flex", flexDirection: "row", alignItems: "flex-start", gap: 12, width: "100%" }}>
|
||||
<div style={{ flex: "0 0 110px", width: 110, height: 110 }}>
|
||||
<div style={{ display: 'flex', flexDirection: 'row', alignItems: 'flex-start', gap: '12px', width: '100%' }}>
|
||||
<div style={{ flex: '0 0 110px', width: '110px', height: '110px' }}>
|
||||
<img src={`/api/v1/products/qrcode/${createdSn}`} alt="QR"
|
||||
style={{ width: "100%", height: "100%", objectFit: "contain", display: "block" }} />
|
||||
style={{ width: '100%', height: '100%', objectFit: 'contain', display: 'block' }} />
|
||||
</div>
|
||||
<div style={{ flex: 1, minWidth: 0, display: "flex", flexDirection: "column", gap: 6 }}>
|
||||
<div style={{ fontSize: 14, fontWeight: 900, color: "#000", lineHeight: 1.2, wordBreak: "break-all",
|
||||
display: "-webkit-box", WebkitBoxOrient: "vertical", WebkitLineClamp: 3, overflow: "hidden" }}>
|
||||
<div style={{ flex: 1, minWidth: 0, display: 'flex', flexDirection: 'column', gap: '6px' }}>
|
||||
<div style={{ fontSize: '12px', fontWeight: 900, color: '#000', lineHeight: '1.4',
|
||||
wordBreak: 'break-all', display: '-webkit-box', WebkitLineClamp: 3,
|
||||
WebkitBoxOrient: 'vertical', overflow: 'hidden', maxHeight: '50px' }}>
|
||||
名: {selected?.material_name ?? ""}
|
||||
</div>
|
||||
<div style={{ fontSize: 14, fontWeight: 900, color: "#000", lineHeight: 1.2, wordBreak: "break-all" }}>
|
||||
<div style={{ fontSize: '12px', fontWeight: 900, color: '#000', lineHeight: '1.2',
|
||||
wordBreak: 'break-all', overflow: 'hidden', maxHeight: '30px' }}>
|
||||
规: {selected?.spec_model ?? ""}
|
||||
</div>
|
||||
<div style={{ fontSize: 14, fontWeight: 900, color: "#000", lineHeight: 1.2, wordBreak: "break-all" }}>
|
||||
<div style={{ fontSize: '12px', fontWeight: 900, color: '#000', lineHeight: '1.2',
|
||||
wordBreak: 'break-all', overflow: 'hidden', maxHeight: '30px' }}>
|
||||
单: {orderNo || "—"}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div style={{ width: "100%", marginTop: 12, paddingTop: 8, borderTop: "2px solid #000",
|
||||
textAlign: "center", fontSize: 18, fontWeight: 900, color: "#000", letterSpacing: 1 }}>
|
||||
<div style={{ width: '100%', marginTop: '12px', paddingTop: '8px',
|
||||
borderTop: '2px solid #000', textAlign: 'center', fontSize: '16px',
|
||||
fontWeight: 900, color: '#000', letterSpacing: '1px' }}>
|
||||
码: {createdSn}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user