daily: 2021-09-26
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
export default function Row({
|
||||
children,
|
||||
type,
|
||||
editable,
|
||||
offset,
|
||||
offsetX,
|
||||
offsetY,
|
||||
...props
|
||||
}) {
|
||||
offsetX = (offset?.x ?? offsetX) | 0;
|
||||
offsetY = (offset?.y ?? offsetY) | 0;
|
||||
return (
|
||||
<g
|
||||
type={type}
|
||||
transform={`translate(${offsetX},${offsetY})`}
|
||||
style={
|
||||
editable
|
||||
? {
|
||||
cursor: "pointer",
|
||||
}
|
||||
: null
|
||||
}
|
||||
{...props}
|
||||
>
|
||||
{children}
|
||||
</g>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user