Filled shapes may be selected from the center (#440)

This commit is contained in:
Steve Ruiz 2021-12-08 14:20:22 +00:00 committed by GitHub
parent 52ae47371d
commit 86c651764c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View file

@ -99,7 +99,7 @@ export class DrawUtil extends TDShapeUtil<T, E> {
<SVGContainer ref={ref} id={shape.id + '_svg'} {...events}>
<g opacity={isGhost ? GHOSTED_OPACITY : 1}>
<path
className={shouldFill && isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
className={shouldFill || isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
d={pathTDSnapshot}
/>
{shouldFill && (

View file

@ -69,7 +69,7 @@ export class EllipseUtil extends TDShapeUtil<T, E> {
/>
)}
<ellipse
className={isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
className={style.isFilled || isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
cx={radiusX}
cy={radiusY}
rx={radiusX}

View file

@ -64,7 +64,7 @@ export class RectangleUtil extends TDShapeUtil<T, E> {
/>
)}
<path
className={isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
className={style.isFilled || isSelected ? 'tl-fill-hitarea' : 'tl-stroke-hitarea'}
d={indicatorPath}
/>
<path